.dashboard-window {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 16px;
  margin: 8px 0 20px;
}
.info-button[data-tip-dismissed='true'] + .info-tooltip {
  visibility: hidden;
  opacity: 0;
}
.global-period {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--muted);
  font-size: 13px;
  font-variant-numeric: tabular-nums;
}
.dashboard-window .info-tooltip {
  right: 0;
  top: calc(100% + 8px);
  white-space: pre-line;
}
.result-summary {
  border: 1px solid var(--line);
  border-radius: var(--radius-panel);
  padding: 26px 28px 0;
  margin-bottom: 28px;
  background: #050506;
}
.summary-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 28px;
  padding-bottom: 24px;
}
.summary-stat {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 10px;
  padding-left: 28px;
  border-left: 1px solid var(--line);
  min-width: 0;
}
.summary-main {
  padding-left: 0;
  border-left: 0;
}
.summary-label {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--muted);
  font-size: 13px;
}
.summary-stat > strong {
  font-size: 32px;
  line-height: 1.1;
  letter-spacing: -0.025em;
  font-variant-numeric: tabular-nums;
}
.summary-support {
  color: var(--muted);
  font-size: 12px;
}
.summary-comparison {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px 28px;
  border-top: 1px solid var(--line);
  padding: 16px 0;
  font-size: 13px;
  color: var(--muted);
}
.comparison-toggle {
  display: none;
}
.mobile-notice {
  position: fixed;
  inset: auto 0 0;
  margin: 0 auto max(16px, env(safe-area-inset-bottom));
  width: calc(100% - 32px);
  max-width: 480px;
  max-height: calc(100dvh - 32px);
  overflow: auto;
  box-sizing: border-box;
  padding: 28px 22px 22px;
  border: 1px solid #38383b;
  border-radius: 18px;
  background: #111113;
  color: var(--text);
  box-shadow: 0 16px 64px #0008;
}
.mobile-notice::backdrop {
  background: #0009;
}
.mobile-notice h2 {
  margin: 0 32px 14px 0;
  font-size: 21px;
  line-height: 1.3;
  letter-spacing: -0.02em;
}
.mobile-notice p {
  margin: 0 0 22px;
  color: #bcbcc5;
  font-size: 14px;
  line-height: 1.65;
}
.mobile-notice-close {
  position: absolute;
  right: 8px;
  top: 8px;
  width: 44px;
  height: 44px;
  border: 0;
  background: transparent;
  color: #bcbcc5;
  font-size: 26px;
  cursor: pointer;
}
.mobile-notice-continue {
  display: block;
  width: 100%;
  min-height: 48px;
  border: 1px solid #444449;
  border-radius: 24px;
  background: #2b2b2f;
  color: var(--text);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
}
.mobile-notice button:focus-visible {
  outline: 2px solid var(--blue);
  outline-offset: 3px;
}
.comparison-label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.comparison-value strong {
  margin-left: 6px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}
.comparison-value.selected {
  color: var(--text);
}
.result-summary .info-tooltip {
  left: 0;
  top: calc(100% + 8px);
}
.dashboard-window .info-button[aria-expanded='true'] + .info-tooltip,
.result-summary .info-button[aria-expanded='true'] + .info-tooltip {
  visibility: visible;
  opacity: 1;
}
.market-heading {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 8px 20px;
}
.market-period {
  color: var(--muted);
  font-size: 12px;
  font-variant-numeric: tabular-nums;
}
.market-quotes {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 20px;
  margin: 18px 0 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius-panel);
  padding: 20px;
}
.market-quote {
  border-left: 1px solid var(--line);
  padding-left: 20px;
  min-width: 0;
}
.market-quote:first-child {
  border-left: 0;
  padding-left: 0;
}
.market-quote h3 {
  font-size: 13px;
  font-weight: 400;
  color: var(--muted);
  margin: 0 0 10px;
}
.market-quote > strong {
  font-size: 24px;
  font-variant-numeric: tabular-nums;
}
.market-quote-date {
  font-size: 11px;
  color: var(--muted);
}
.market-reference-details > summary,
.market-news > summary {
  cursor: pointer;
  color: var(--blue);
  font-size: 13px;
}
.market-reference-details {
  margin-bottom: 24px;
}
.market-table-wrap {
  overflow-x: auto;
  margin-top: 12px;
}
.market-reference-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}
.market-reference-table th,
.market-reference-table td {
  padding: 14px 16px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  white-space: nowrap;
  font-weight: 400;
}
.market-reference-table thead th {
  color: var(--muted);
  font-size: 12px;
}
.market-reference-table tbody th {
  font-weight: 600;
}
.market-reference-table .market-number,
.market-reference-table thead th:nth-child(4),
.market-reference-table thead th:nth-child(5) {
  text-align: right;
  font-variant-numeric: tabular-nums;
}
.market-reference-table a,
.market-event-headline a {
  color: var(--blue);
}
.market-event-preview {
  margin-top: 20px;
}
.market-event-preview h3 {
  font-size: 15px;
  margin: 0 0 12px;
}
.market-event-headline {
  display: grid;
  grid-template-columns: 100px minmax(0, 1fr) auto;
  align-items: baseline;
  gap: 12px;
  border-top: 1px solid var(--line);
  padding: 12px 0;
  font-size: 13px;
}
.market-event-headline p {
  margin: 0;
  line-height: 1.5;
}
.market-event-date {
  color: var(--muted);
  font-size: 12px;
}
.market-event-timing {
  display: block;
  color: var(--muted);
  font-size: 12px;
  margin-top: 4px;
}
@media (max-width: 700px) {
  .intro {
    padding: 24px 0 8px;
  }
  .intro-title-row {
    align-items: flex-start;
    gap: 4px;
  }
  .intro-title-row h1 {
    font-size: 28px;
    line-height: 1.2;
  }
  .intro .audit-access {
    font-size: 12px;
  }
  .dashboard-window {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
  }
  .dashboard-window .window-switch {
    width: 100%;
  }
  .dashboard-window .window-switch button {
    flex: 1;
    min-height: 44px;
  }
  .global-period {
    width: 100%;
    justify-content: space-between;
    padding-left: 4px;
  }
  .result-summary {
    padding: 4px 18px 0;
  }
  .summary-stats {
    display: block;
    padding-bottom: 0;
  }
  .summary-main {
    grid-column: 1 / -1;
  }
  .summary-stat {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    padding-left: 0;
    border-left: 0;
    padding-top: 10px;
    padding-bottom: 10px;
    gap: 0 8px;
  }
  .summary-stat + .summary-stat {
    border-top: 1px solid var(--line);
  }
  .summary-stat > strong {
    font-size: 24px;
    text-align: right;
    grid-column: 2;
    grid-row: 1;
  }
  #summary-window-label {
    display: none;
  }
  #metric-up-count {
    grid-column: 2;
    text-align: right;
    margin-top: 2px;
    font-size: 11px;
  }
  .summary-label {
    gap: 0;
    white-space: nowrap;
    font-size: 12px;
  }
  .summary-comparison {
    display: none;
    gap: 8px;
    padding: 0 0 16px;
    border-top: 0;
  }
  .summary-comparison.mobile-expanded {
    display: grid;
  }
  .comparison-toggle {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    min-height: 48px;
    padding: 8px 0;
    background: transparent;
    border: 0;
    border-top: 1px solid var(--line);
    color: var(--muted);
    font-size: 12px;
    cursor: pointer;
  }
  .comparison-toggle[aria-expanded='true'] > span {
    transform: rotate(180deg);
  }
  .global-period .info-tooltip,
  .heatmap-section .info-tooltip,
  .result-summary .info-tooltip,
  .result-summary .info-button:hover + .info-tooltip,
  .result-summary .info-button:focus-visible + .info-tooltip,
  .dashboard-window .info-button[aria-expanded='true'] + .info-tooltip,
  .result-summary .info-button[aria-expanded='true'] + .info-tooltip {
    position: fixed;
    top: auto;
    bottom: 20px;
    left: 16px;
    right: 16px;
    width: auto;
    max-width: none;
    z-index: 30;
  }
  .market-quotes {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px 12px;
    padding: 18px;
  }
  .market-quote,
  .market-quote:first-child {
    border-left: 0;
    padding-left: 0;
  }
  .market-quote > strong {
    font-size: 22px;
  }
  .market-event-headline {
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 0 12px;
    align-items: center;
    padding: 10px 0 16px;
  }
  .market-event-headline > p {
    grid-column: 1 / -1;
    grid-row: 2;
    line-height: 1.5;
  }
  .market-event-date {
    font-size: 12px;
  }
  .market-event-headline a {
    grid-column: 2;
    grid-row: 1;
    display: flex;
    align-items: center;
    min-height: 44px;
    padding: 8px 0 8px 12px;
  }
  .market-heading {
    flex-direction: column;
    align-items: flex-start;
    gap: 0;
  }
  .market-heading > .market-period {
    margin: 0 0 12px;
  }
  .market-reference-details > summary,
  .market-news > summary {
    min-height: 44px;
    padding: 12px 0;
  }
  .ranking-section .section-head {
    align-items: flex-start;
    gap: 12px;
  }
  .ranking-section .section-head h2 {
    font-size: 24px;
    line-height: 1.25;
  }
  .ranking-title-row {
    display: block;
  }
  .ranking-title-row > a {
    flex-shrink: 0;
    min-height: 44px;
    display: inline-flex;
    align-items: center;
  }
}
