/* YE·BLOG v1.1.23 & /market 视觉融合层 + ?embed=1 无缝嵌入模式
 * 仅作用于视觉变量、卡片质感、语义对比度与嵌入态布局；严禁改动任何计算、核验门禁或数据口径。 */
:root {
  --ye-paper: #faf7f5;
  --ye-paper-deep: #f4eeeb;
  --ye-surface: #fffcfa;
  --ye-ink: #1c1917;
  --ye-text: #44403c;
  --ye-muted: #78716c;
  --ye-blush: #e85d6f;
  --ye-red: #e85d6f;
  --ye-pink: #fff0f2;
  --ye-stroke: rgba(232, 93, 111, 0.18);
  --ye-rule: rgba(232, 93, 111, 0.14);
  --ye-shadow: 0 8px 26px -14px rgba(68, 38, 42, 0.1), 0 1px 2px rgba(68, 38, 42, 0.04);

  --ui-surface: #fffcfa;
  --ui-inset: #faf5f3;
  --ui-border: rgba(232, 93, 111, 0.16);
  --ui-text: #1c1917;
  --ui-muted: #78716c;
  --ui-accent: #d63f54;
  --ui-rose: #e85d6f;
  --ui-rose-text: #b65061;
  --ui-radius: 10px;
  --ui-font: -apple-system, BlinkMacSystemFont, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  font-family: var(--ui-font);
  color: var(--ye-ink);
  background: var(--ye-paper);
}

html,
body {
  background-color: #faf7f5;
  color: #1c1917;
  font-family: var(--ui-font);
  font-feature-settings: "tnum" 1, "cv02" 1, "cv03" 1;
}

body {
  background-image:
    radial-gradient(ellipse at 50% 45%, rgba(232, 93, 111, 0.055), transparent 70%),
    radial-gradient(ellipse at 82% 82%, rgba(232, 99, 158, 0.035), transparent 70%);
  background-attachment: fixed;
}

.site {
  background: transparent;
}

.shell {
  max-width: 1160px;
}

/* 独立访问顶栏：贴合 YE·BLOG 暖杏纸白与渐隐蔷薇底线 */
.topbar {
  background: rgba(250, 247, 245, 0.96);
  backdrop-filter: blur(8px);
}

.topbar::after {
  background: linear-gradient(
    90deg,
    rgba(232, 93, 111, 0) 0%,
    rgba(232, 93, 111, 0.28) 22%,
    rgba(232, 93, 111, 0.55) 50%,
    rgba(232, 93, 111, 0.28) 78%,
    rgba(232, 93, 111, 0) 100%
  );
}

.blog-identity {
  color: #78716c;
}

.blog-identity:hover {
  color: #e85d6f;
}

.blog-mark {
  color: #e85d6f;
}

.brand-icon {
  border-color: rgba(232, 93, 111, 0.28);
  background: #fff0f2;
  color: #b65061;
}

.brand strong {
  color: #1c1917;
}

.brand span {
  color: #78716c;
}

.header-button,
.data-refresh-button {
  border: 1px solid rgba(232, 93, 111, 0.3);
  background: #fff0f2;
  color: #b65061;
  border-radius: 8px;
  font-weight: 500;
  transition: background-color 0.16s ease, border-color 0.16s ease, color 0.16s ease;
}

.header-button:hover,
.data-refresh-button:hover {
  background: #fce3e7;
  border-color: rgba(232, 93, 111, 0.48);
}

#shareHome {
  border: 1px solid rgba(232, 93, 111, 0.22);
  background: #faf5f3;
  color: #57534e;
}

#shareHome:hover {
  border-color: rgba(232, 93, 111, 0.42);
  background: #fff0f2;
  color: #b65061;
}

/* 独立态页面标题行 */
.single-page .compact-page-title h1 {
  color: #1c1917;
}

.annual-issue-stats b {
  color: #d63f54;
}

/* 主卡片：与 /market .terminal-card 保持同一材质与圆角阴影 */
.single-page .card {
  background: #fffcfa;
  border: 1px solid rgba(232, 93, 111, 0.16);
  border-radius: 16px;
  box-shadow: 0 8px 26px -14px rgba(68, 38, 42, 0.1), 0 1px 2px rgba(68, 38, 42, 0.04);
}

.single-page .compact-layout .card-head h3 {
  color: #1c1917;
}

.single-page .card-head p {
  color: #78716c;
}

.inline-button,
.notice-line a,
.bottom-note a,
.rules-sources a,
.source-link,
.footer a,
.monthly-assumptions button {
  color: #b65061;
}

.inline-button:hover,
.bottom-note a:hover,
.rules-sources a:hover,
.footer a:hover {
  color: #d63f54;
}

/* 内嵌子卡片与浅暖底块 */
.single-page :is(
  .threshold-tile,
  .published-funding-tile,
  .published-total,
  .funding-schedule,
  .historical-yield-tile,
  #yieldTable > .yield-tile
),
.single-page .cap-outcomes > div,
.single-page .calc-form .funding-timeline .funding-schedule {
  background: #faf5f3;
  border: 1px solid rgba(232, 93, 111, 0.16);
  border-radius: 10px;
  box-shadow: none;
}

.single-page .compact-results .published-total {
  background: linear-gradient(135deg, #fffcfa 0%, #fff4f5 100%);
  border-color: rgba(232, 93, 111, 0.22);
}

.single-page .published-funding-tile.over-cap {
  background: #fff0f2;
  border-color: rgba(232, 93, 111, 0.3);
}

/* 左列：下拉选择器与工具按钮 */
.issue-picker-trigger,
.input-wrap input,
.form-row select {
  background: #fffcfa;
  border-color: rgba(232, 93, 111, 0.22);
  color: #1c1917;
  border-radius: 10px;
}

.issue-picker-trigger[aria-expanded="true"],
.input-wrap input:focus,
.form-row select:focus {
  border-color: #e85d6f;
  box-shadow: 0 0 0 3px rgba(232, 93, 111, 0.14);
}

.issue-picker-chevron {
  color: #e85d6f;
}

.issue-picker-panel {
  background: #fffcfa;
  border: 1px solid rgba(232, 93, 111, 0.24);
  border-radius: 12px;
  box-shadow: 0 14px 34px -10px rgba(68, 38, 42, 0.18);
  color: #44403c;
}

.issue-picker-search-label {
  border-bottom-color: rgba(232, 93, 111, 0.14);
}

.issue-picker-search-label input {
  border-color: rgba(232, 93, 111, 0.2);
  background: #faf7f5;
  color: #1c1917;
}

.issue-picker-option.is-active {
  background: #faf5f3;
  border-color: rgba(232, 93, 111, 0.18);
}

.issue-picker-option[aria-selected="true"] {
  background: #fff0f2;
  border-color: rgba(232, 93, 111, 0.35);
  color: #b65061;
}

.single-page .resource-links > .data-disclosure {
  border: 1px solid rgba(232, 93, 111, 0.18);
  background: #faf5f3;
  border-radius: 10px;
  box-shadow: none;
}

.single-page .resource-links > .data-disclosure > summary {
  color: #44403c;
  border-radius: 10px;
}

.single-page .resource-links > .data-disclosure > summary:hover {
  background: #fff0f2;
  color: #b65061;
}

.single-page .resource-links > .data-disclosure > summary::after,
.single-page .secondary-tools > button::after {
  background: rgba(232, 93, 111, 0.14);
  color: #b65061;
}

.single-page .secondary-tools {
  border-top-color: rgba(232, 93, 111, 0.16);
}

.single-page .secondary-tools > button,
.single-page .secondary-tools > #openIpoRules {
  border: 1px solid rgba(232, 93, 111, 0.18);
  background: #faf5f3;
  color: #44403c;
  border-radius: 10px;
  box-shadow: none;
}

.single-page .secondary-tools > #openMonthly {
  border-color: rgba(232, 93, 111, 0.28);
  background: #fff0f2;
  color: #b65061;
}

.single-page .secondary-tools > button:hover {
  background: #fce3e7;
  border-color: rgba(232, 93, 111, 0.4);
  color: #9f2d42;
}

.funding-timeline {
  border-top-color: rgba(232, 93, 111, 0.16);
}

.funding-arrow,
.single-page .funding-timeline .compact-schedule .funding-days em {
  color: #e85d6f;
}

.single-page .calc-form .funding-timeline .compact-schedule .funding-days {
  border-top-color: rgba(232, 93, 111, 0.16);
}

/* 右列：测算情景与收益高亮 */
.single-page .compact-scenario-pills {
  background: #faf5f3;
  border-color: rgba(232, 93, 111, 0.16);
  border-radius: 10px;
}

.single-page .compact-scenario-pills button {
  color: #78716c;
  border-radius: 7px;
}

.single-page .compact-scenario-pills button.chosen {
  background: #fffcfa;
  border-color: rgba(232, 93, 111, 0.45);
  color: #b65061;
  box-shadow: 0 2px 6px rgba(232, 93, 111, 0.08);
}

.custom-scenario-cell.is-editing {
  background: #fffcfa;
  border-color: rgba(232, 93, 111, 0.45);
}

.custom-scenario-cell.is-editing:focus-within {
  border-color: #e85d6f;
  box-shadow: 0 0 0 2px rgba(232, 93, 111, 0.14);
}

.custom-inline-input {
  border-bottom-color: rgba(232, 93, 111, 0.35);
}

.custom-inline-input input {
  color: #b65061;
  caret-color: #e85d6f;
}

.single-page .scenario-baseline #marketEstimate,
.single-page .ratio-summary > strong,
.single-page .published-total > strong,
.single-page #yieldTable > .yield-tile > strong,
.single-page .cap-outcomes strong,
.single-page .historical-yield-tile > strong,
.single-page .historical-yield-tile .sale-return-block > strong,
.single-page .published-funding-tile > strong {
  color: #d63f54;
}

.single-page .funding-yield,
.first-day-panel {
  border-top-color: rgba(232, 93, 111, 0.15);
  background: transparent;
}

body[data-data-mode="published"] .single-page .funding-yield {
  background: linear-gradient(125deg, #fffcfa, #faf5f3);
}

.yield-tile {
  border-left-color: rgba(232, 93, 111, 0.18);
}

.published-funding {
  border-top-color: rgba(232, 93, 111, 0.16);
}

.published-result-grid > div + div,
.first-day-values > div + div,
#historicalYields .sale-option + .sale-option,
#historicalYields .sale-return-block,
#historicalYields .sale-pair-title,
.profit100-summary {
  border-color: rgba(232, 93, 111, 0.16);
}

.funding-tier-nav button {
  border-color: rgba(232, 93, 111, 0.24);
  background: #fffcfa;
  color: #b65061;
  border-radius: 6px;
}

.funding-tier-nav button:hover {
  background: #fff0f2;
}

/* 保留清晰金融状态与涨跌语义色（绝不把状态强行改粉） */
.single-page .result-status {
  border-radius: 6px;
  background: #fff0f2;
  border: 1px solid rgba(232, 93, 111, 0.26);
  color: #b65061;
}

body[data-data-mode="published"] .compact-results .result-status,
.record-status.published {
  color: #15803d;
  border-color: rgba(22, 163, 74, 0.26);
  background: #ecfdf5;
}

.return-up,
.sale-change .is-up,
.first-day-values .is-up,
#historicalYields .yield-figure > .return-up {
  color: #d63f54 !important;
}

.return-down,
.sale-change .is-down,
.first-day-values .is-down {
  color: #15805b !important;
}

.return-flat,
.sale-change .is-flat,
.first-day-values .is-flat {
  color: #78716c !important;
}

.annual-flag,
.single-page .annual-flag,
.monthly-dialog .annual-flag {
  background: #fff0f2;
  color: #b65061;
  border: 1px solid rgba(232, 93, 111, 0.25);
  border-radius: 5px;
  padding: 1px 6px;
}

/* 发行进度时间轴 */
.issuance-progress {
  border-top-color: rgba(232, 93, 111, 0.15);
}

.issuance-progress-heading h4 {
  color: #44403c;
}

.issuance-progress li.segment-past::after {
  background: #e85d6f;
}

.issuance-progress li.is-past,
.issuance-progress li.is-today {
  color: #b65061;
}

.issuance-progress li.is-past .progress-node,
.issuance-progress li.is-today .progress-node {
  background: #e85d6f;
}

.issuance-progress li[aria-current="step"] .progress-node {
  box-shadow: 0 0 0 3px #fff0f2;
}

/* 底部测算口径说明折叠区 */
.calculation-notes > summary {
  padding: 10px 14px;
  border-radius: 12px;
  background: #fffcfa;
  border: 1px solid rgba(232, 93, 111, 0.16);
  color: #57534e;
  font-size: 12px;
  font-weight: 500;
  transition: border-color 0.16s ease, background-color 0.16s ease;
}

.calculation-notes > summary:hover {
  border-color: rgba(232, 93, 111, 0.34);
  background: #fff8f9;
}

.calculation-notes > summary span {
  color: #78716c;
  font-weight: 400;
}

.bottom-note,
.calculation-notes .bottom-note {
  background: #fffcfa;
  border: 1px solid rgba(232, 93, 111, 0.16);
  border-radius: 14px;
  color: #57534e;
  padding: 16px 18px;
}

/* 全部弹窗（详情 / 全部新股 / 打新规则 / 月度测算 / 分享） */
.data-modal,
.share-dialog,
.monthly-dialog {
  background: #fffcfa;
  border: 1px solid rgba(232, 93, 111, 0.24);
  border-radius: 16px;
  box-shadow: 0 24px 60px rgba(28, 25, 23, 0.22);
  color: #44403c;
}

.data-modal::backdrop,
.share-dialog::backdrop {
  background: rgba(28, 25, 23, 0.32);
  backdrop-filter: blur(3px);
}

.data-modal .modal-head {
  border-bottom-color: rgba(232, 93, 111, 0.15);
}

.data-modal .modal-head h3,
.monthly-dialog .monthly-head h3,
.share-dialog h2,
.share-tools h3 {
  color: #1c1917;
}

.data-modal .modal-close,
.share-close {
  border: 1px solid rgba(232, 93, 111, 0.25);
  background: #faf5f3;
  color: #78716c;
}

.data-modal .modal-close:hover,
.share-close:hover {
  background: #fff0f2;
  color: #b65061;
  border-color: rgba(232, 93, 111, 0.42);
}

.data-modal .metric,
.monthly-dialog .monthly-stat,
.monthly-summary > div.monthly-stat {
  background: #faf5f3;
  border: 1px solid rgba(232, 93, 111, 0.18);
  border-radius: 10px;
}

.monthly-summary > div.monthly-stat {
  border-left: 3px solid #e85d6f;
}

.monthly-table,
.monthly-table th,
.monthly-table td,
.data-table th,
.data-table td {
  border-color: rgba(232, 93, 111, 0.14);
}

.monthly-table th,
.data-table th {
  background: #faf5f3;
  color: #57534e;
}

.current-record td {
  background: #fff0f2;
}

.monthly-controls select,
.monthly-controls button,
.library-tools input,
.library-tools select {
  background: #fffcfa;
  border-color: rgba(232, 93, 111, 0.22);
  color: #1c1917;
  border-radius: 8px;
}

.monthly-controls button:hover {
  background: #fff0f2;
  border-color: rgba(232, 93, 111, 0.4);
  color: #b65061;
}

.broker-time-hint {
  border: 1px solid rgba(232, 93, 111, 0.2);
  border-left: 3px solid #e85d6f;
  background: #fff6f7;
  border-radius: 8px;
}

.broker-time-hint strong,
.ipo-rules-content h4 {
  color: #b65061;
}

.share-kind-switch {
  background: #faf5f3;
  border: 1px solid rgba(232, 93, 111, 0.14);
}

.share-kind-switch button {
  background: transparent;
  color: #78716c;
}

.share-kind-switch button[aria-pressed="true"] {
  background: #fffcfa;
  color: #b65061;
  box-shadow: 0 2px 6px rgba(232, 93, 111, 0.1);
}

.share-action-grid button {
  border-color: rgba(232, 93, 111, 0.28);
  background: #faf5f3;
  color: #57534e;
}

.share-action-grid button:hover {
  background: #fff0f2;
  color: #b65061;
}

.share-action-grid .share-primary {
  background: #e85d6f;
  border-color: #e85d6f;
  color: #fff;
}

.share-action-grid .share-primary:hover {
  background: #d64b5e;
  color: #fff;
}

.footer {
  border-top-color: rgba(232, 93, 111, 0.16);
}

/* ============================================================================
 * ?embed=1 无缝嵌入模式：隐藏顶栏/页脚，零左右留白，顶部收敛为 /market 同款状态条
 * ========================================================================== */
html[data-embed="1"],
html[data-embed="1"] body,
html[data-embed="1"] .site {
  background: transparent !important;
  background-image: none !important;
  min-height: 0 !important;
}

html[data-embed="1"] .topbar,
html[data-embed="1"] .footer {
  display: none !important;
}

html[data-embed="1"] .shell {
  max-width: none !important;
  width: 100% !important;
  padding: 0 !important;
  margin: 0 !important;
}

html[data-embed="1"] .single-page .compact-page-title {
  margin: 0 0 14px;
  padding: 10px 16px;
  background: #fffcfa;
  border: 1px solid rgba(232, 93, 111, 0.16);
  border-radius: 16px;
  box-shadow: 0 8px 26px -14px rgba(68, 38, 42, 0.1), 0 1px 2px rgba(68, 38, 42, 0.04);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px 14px;
}

html[data-embed="1"] .compact-page-title .page-title-group {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px 14px;
  min-width: 0;
}

html[data-embed="1"] .single-page .compact-page-title h1 {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  font-weight: 600;
  line-height: 1.4;
  color: #1c1917;
  margin: 0;
}

html[data-embed="1"] .single-page .compact-page-title h1::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 9999px;
  background: #e85d6f;
  flex-shrink: 0;
}

html[data-embed="1"] .annual-issue-stats {
  font-size: 11px;
  color: #78716c;
}

html[data-embed="1"] .annual-issue-stats b {
  font-size: 14px;
}

html[data-embed="1"] .embed-toolbar-actions {
  display: inline-flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  margin-left: auto;
}

html[data-embed="1"] .embed-toolbar-actions .data-refresh-button {
  padding: 6px 12px;
  min-height: 32px;
  font-size: 12px;
  border-radius: 8px;
  line-height: 1.4;
}

html[data-embed="1"] .embed-action-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  min-height: 32px;
  padding: 6px 11px;
  border: 1px solid rgba(232, 93, 111, 0.18);
  border-radius: 8px;
  background: #faf5f3;
  color: #57534e;
  font-family: inherit;
  font-size: 12px;
  font-weight: 500;
  line-height: 1.4;
  white-space: nowrap;
  cursor: pointer;
  text-decoration: none;
  transition: background-color 0.16s ease, border-color 0.16s ease, color 0.16s ease;
}

html[data-embed="1"] .embed-action-btn:hover {
  border-color: rgba(232, 93, 111, 0.4);
  background: #fff0f2;
  color: #b65061;
}

html[data-embed="1"] .calculation-notes {
  margin: 12px 0 4px;
}

/* 长 iframe 弹窗视口居中对齐：跟随父页面传入的可见视口位置定位 */
html[data-embed="1"] dialog[open] {
  top: var(--embed-dialog-top, 24px);
  bottom: auto;
  margin-top: 0;
  margin-bottom: 0;
  max-height: var(--embed-dialog-max-h, calc(100vh - 40px));
}

@media (max-width: 750px) {
  html[data-embed="1"] .single-page .compact-page-title {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    padding: 10px 12px;
    gap: 8px 10px;
  }

  html[data-embed="1"] .compact-page-title .page-title-group {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 4px 10px;
  }

  html[data-embed="1"] .embed-toolbar-actions {
    width: auto;
    margin-left: auto;
    justify-content: flex-end;
  }

  html[data-embed="1"] .embed-toolbar-actions #refreshData.data-refresh-button,
  html[data-embed="1"] .embed-toolbar-actions .data-refresh-button,
  html[data-embed="1"] .embed-action-btn {
    min-height: 36px;
    height: 36px;
    padding: 6px 11px;
  }
}


/* ============================================================================
 * 2026-11-29 深度排版重构：双列均衡 · 3栏KPI带 · 双段四价卡 · 弹窗与口径卡片化
 * ========================================================================== */

/* 1. 桌面双列比例均衡（960px 以上），独立模式左侧吸顶消除长短脚视觉空白 */
@media (min-width: 960px) {
  .single-page .compact-layout {
    grid-template-columns: minmax(330px, 0.78fr) minmax(0, 1.22fr);
    gap: 18px;
    align-items: start;
  }

  html:not([data-embed="1"]) .single-page .compact-layout > .calc-form {
    position: sticky;
    top: 80px;
  }
}

/* 2. 「申购结果」顶部紧凑 3 栏 KPI 指标带（桌面同排齐平，手机自然回落） */
.single-page .compact-results .published-content {
  padding: 0 20px 14px;
}

.single-page .compact-results .published-total {
  margin: 0 0 10px;
  padding: 12px 15px;
  border-radius: 12px;
}

.single-page .compact-results .published-result-grid {
  background: #faf5f3;
  border: 1px solid rgba(232, 93, 111, 0.16);
  border-radius: 12px;
  padding: 11px 14px;
  gap: 14px;
  align-items: center;
}

.single-page .compact-results .published-result-grid > div + div {
  padding-left: 14px;
  border-left: 1px solid rgba(232, 93, 111, 0.16);
}

.single-page .compact-results .published-result-grid span {
  font-size: 10.5px;
  color: #78716c;
}

.single-page .compact-results .published-result-grid strong {
  font-size: 20px;
  line-height: 1.25;
  color: #1c1917;
}

@media (min-width: 680px) {
  .single-page .compact-results .published-content:not([hidden]) {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.45fr);
    gap: 12px;
    align-items: stretch;
  }

  .single-page .compact-results .published-total {
    margin: 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: flex-start;
    gap: 4px;
    padding: 12px 16px;
  }

  .single-page .compact-results .published-total > strong {
    display: inline-flex;
    align-items: baseline;
    font-size: 26px;
    line-height: 1.2;
  }

  .single-page .compact-results .published-total > small {
    font-size: 10.5px;
  }

  .single-page .compact-results .published-funding {
    grid-column: 1 / -1;
    margin-top: 2px;
    padding-top: 12px;
  }
}

/* 3. 顶格获配与资金档位精修：无档位隐藏空区与冗余标题，单档位收窄 */
#publishedFunding[data-empty-tiers="1"] .funding-target-title,
#publishedFunding[data-empty-tiers="1"] .funding-tier-toolbar,
#publishedFunding[data-empty-tiers="1"] .published-funding-rows {
  display: none !important;
}

#publishedFunding[data-empty-tiers="1"] #publishedFundingNotice {
  margin: 10px 0 0;
  padding: 9px 12px;
  border-radius: 9px;
  background: #faf5f3;
  border: 1px dashed rgba(232, 93, 111, 0.24);
  font-size: 11px;
  color: #78716c;
  line-height: 1.65;
}

@media (min-width: 680px) {
  #publishedFunding .published-funding-rows[data-tier-count="1"] {
    grid-auto-columns: minmax(220px, 280px);
  }
}

/* 4. 「收益与年化」标题栏成组右对齐，消除中间悬空 */
.single-page .funding-yield-heading {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: flex-start;
  gap: 4px 0;
  margin-bottom: 10px;
}

.single-page .funding-yield-heading h3 {
  margin-right: auto;
  padding-right: 10px;
}

.single-page .funding-yield-heading > span,
.single-page #fundingListingDate {
  font-size: 10.5px;
  color: #78716c;
  line-height: 1.4;
}

/* 5. 首日四价卖出对照卡深度重构：上下双段（主实操 vs 辅回看）+ 横向紧凑数据流 */
.single-page .compact-results .funding-yield {
  padding: 13px 20px 15px;
}

#historicalYields {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 10px;
}

#historicalYields .sale-pair {
  padding: 12px 14px;
  border-radius: 12px;
  min-width: 0;
}

#historicalYields .sale-pair[data-pair="session"] {
  background: #fffcfa;
  border: 1px solid rgba(232, 93, 111, 0.22);
}

#historicalYields .sale-pair[data-pair="extremes"] {
  background: #faf5f3;
  border: 1px solid rgba(232, 93, 111, 0.14);
}

#historicalYields .sale-pair-title {
  margin: 0 0 10px;
  padding-bottom: 7px;
  border-bottom: 1px solid rgba(232, 93, 111, 0.14);
  font-size: 11.5px;
  font-weight: 600;
  color: #57534e;
}

#historicalYields .sale-pair-options {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0;
}

#historicalYields .sale-option {
  display: flex;
  flex-direction: column;
  gap: 0;
  padding: 0 14px 0 0;
  min-width: 0;
}

#historicalYields .sale-option + .sale-option {
  padding: 0 0 0 14px;
  border-left: 1px solid rgba(232, 93, 111, 0.14);
}

#historicalYields .sale-option-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 8px;
}

#historicalYields .sale-option h4 {
  margin: 0;
  font-size: 12.5px;
  font-weight: 600;
  color: #1c1917;
  line-height: 1.4;
}

#historicalYields .sale-change {
  margin: 0;
  min-height: 0;
  line-height: 1.2;
}

#historicalYields .sale-change small {
  display: inline-block;
  padding: 2px 7px;
  border-radius: 999px;
  font-size: 10.5px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

#historicalYields .sale-change .is-up {
  background: #fff0f2;
  color: #d63f54;
}

#historicalYields .sale-change .is-down {
  background: #ecfdf5;
  color: #15805b;
}

#historicalYields .sale-change .is-flat {
  background: #f5f5f4;
  color: #78716c;
}

#historicalYields .sale-metrics-row {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
}

#historicalYields .sale-price-row {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
  margin: 0;
}

#historicalYields .sale-price-row > span {
  font-size: 10px;
  color: #78716c;
}

#historicalYields .sale-price-row strong {
  font-family: var(--ui-font);
  font-size: 19px;
  font-weight: 700;
  line-height: 1.25;
  color: #1c1917;
  font-variant-numeric: tabular-nums;
}

#historicalYields .sale-profit {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  text-align: right;
  gap: 2px;
  margin: 0;
  padding: 0;
}

#historicalYields .sale-profit > span {
  font-size: 10px;
  color: #78716c;
}

#historicalYields .sale-profit > b {
  font-family: var(--ui-font);
  font-size: 13.5px;
  font-weight: 600;
  line-height: 1.25;
  font-variant-numeric: tabular-nums;
}

#historicalYields .sale-return-block {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 4px 10px;
  margin: 9px 0 0;
  padding: 8px 0 0;
  border-top: 1px dashed rgba(232, 93, 111, 0.18);
}

#historicalYields .yield-figure {
  display: inline-flex;
  flex-direction: row;
  align-items: center;
  flex-wrap: nowrap;
  gap: 6px;
}

#historicalYields .yield-figure strong {
  font-family: var(--ui-font);
  font-size: 22px;
  font-weight: 700;
  line-height: 1.2;
}

#historicalYields .sale-return-block > small {
  margin: 0;
  font-size: 10.5px;
  color: #78716c;
  white-space: nowrap;
}

.sale-reference-note {
  margin-top: 9px;
  font-size: 10px;
  color: #78716c;
  line-height: 1.6;
}

@media (max-width: 750px) {
  .single-page .compact-results .published-content {
    padding: 0 16px 14px;
  }

  .single-page .compact-results .funding-yield {
    padding: 12px 16px 14px;
  }

  #historicalYields .yield-figure {
    flex-direction: row;
    align-items: center;
    gap: 5px;
  }

  #historicalYields .yield-figure strong {
    font-size: 21px;
  }
}

@media (max-width: 640px) {
  #historicalYields .sale-pair {
    padding: 12px;
  }

  #historicalYields .sale-pair-options {
    grid-template-columns: minmax(0, 1fr);
    gap: 12px;
  }

  #historicalYields .sale-option {
    padding: 0;
  }

  #historicalYields .sale-option + .sale-option {
    padding: 12px 0 0;
    border-left: 0;
    border-top: 1px dashed rgba(232, 93, 111, 0.2);
  }

  #historicalYields .sale-profit {
    align-items: flex-end !important;
    text-align: right;
  }

  #historicalYields .sale-option .sale-return-block {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
  }

  #historicalYields .sale-option .sale-return-block > small {
    text-align: right;
  }
}

/* 6. 弹窗排版精修：月度测算一屏完整展示 + 详情卡字号/网格均衡 */
.monthly-dialog .monthly-table {
  max-height: min(50vh, 460px);
}

.monthly-dialog .monthly-table th,
.monthly-dialog .monthly-table td {
  padding: 8px 10px;
}

.monthly-dialog .monthly-table td.yield-cell strong {
  display: inline-block;
  font-family: var(--ui-font);
  font-size: 14px;
  font-weight: 700;
  margin-top: 2px;
}

.monthly-dialog .monthly-table td.yield-cell .month-sale-change {
  margin: 2px 0 4px;
}

.monthly-dialog .monthly-table td small {
  margin-top: 2px;
  line-height: 1.45;
}

.data-modal .data-disclosure-content .metric {
  min-height: 76px;
  padding: 11px 12px;
}

.data-modal .data-disclosure-content .metric strong {
  font-size: clamp(14px, 1.35vw, 17px);
  line-height: 1.35;
  white-space: normal;
  overflow-wrap: anywhere;
}

.data-modal .data-disclosure-content .detail-grid {
  grid-template-columns: repeat(auto-fill, minmax(148px, 1fr));
  gap: 14px 12px;
}

/* 7. 底部「测算口径与日期依据」结构化分块卡片 */
.calculation-notes .bottom-note {
  display: grid;
  gap: 10px;
  padding: 12px;
  background: #faf5f3;
}

.calculation-notes .notes-group {
  background: #fffcfa;
  border: 1px solid rgba(232, 93, 111, 0.14);
  border-radius: 12px;
  padding: 12px 14px;
}

.calculation-notes .notes-group h4 {
  display: flex;
  align-items: center;
  gap: 7px;
  margin: 0 0 8px;
  padding-bottom: 6px;
  border-bottom: 1px solid rgba(232, 93, 111, 0.12);
  font-size: 12px;
  font-weight: 600;
  color: #1c1917;
}

.calculation-notes .notes-group h4::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 999px;
  background: #e85d6f;
  flex-shrink: 0;
}

.calculation-notes .notes-group p {
  margin: 5px 0 0;
  font-size: 11px;
  line-height: 1.75;
  color: #57534e;
}

.calculation-notes .notes-group .notes-links {
  margin-top: 8px;
  padding-top: 7px;
  border-top: 1px dashed rgba(232, 93, 111, 0.16);
}

[hidden] {
  display: none !important;
}
