/* Account review: observations, evidence and decisions share one visual rhythm. */
.review-workspace {
  --review-ink: #18343c;
  --review-muted: #65767a;
  --review-line: #e0e8e8;
  --review-teal: #187d79;
  --review-navy: #18383f;
  --review-amber: #986321;
  display: grid;
  gap: 24px;
  color: var(--review-ink);
  min-width: 0;
}
.review-workspace *, .review-workspace *::before, .review-workspace *::after { box-sizing: border-box; }
.review-workspace h2, .review-workspace h3, .review-workspace h4 { color: inherit; }
.review-workspace h3 { font-size: 1rem; line-height: 1.6; letter-spacing: -.025em; font-weight: 700; }
.review-workspace h4 { margin: 0; font-size: .875rem; line-height: 1.65; font-weight: 650; }
.review-workspace p { overflow-wrap: anywhere; }
.review-workspace .summary-note { color: var(--review-muted); line-height: 1.75; font-size: .75rem; margin: 15px 0 0; }
.review-workspace button, .review-workspace a, .review-workspace select { transition: background-color .15s ease, border-color .15s ease, color .15s ease; }
.review-workspace :is(button, a, select, summary):focus-visible { outline: 3px solid #67b9b1; outline-offset: 3px; }
.review-workspace .secondary { color: #34575b; border: 1px solid #d8e2e1; border-radius: 8px; background: #fff; padding: 9px 13px; font-size: .8125rem; }
.review-workspace .secondary:hover { background: #f1f7f5; border-color: #adc6c3; filter: none; }
.review-workspace button:disabled { cursor: not-allowed; }

.review-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 20px; min-width: 0; }
.review-identity { min-width: 0; }
.review-identity h2 { font-size: 1.375rem; font-weight: 720; letter-spacing: -.035em; line-height: 1.4; }
.review-meta { color: var(--review-muted); font-size: .75rem; line-height: 1.6; margin: 7px 0 0; }
.review-controls { display: flex; align-items: flex-end; justify-content: flex-end; gap: 10px; flex-shrink: 0; }
.review-controls label { display: grid; gap: 5px; font-size: .6875rem; font-weight: 500; color: var(--review-muted); }
.review-controls select { max-width: 190px; padding: 8px 28px 8px 10px; border-color: #d8e2e1; font-size: .8125rem; border-radius: 8px; color: var(--review-ink); min-height: 37px; }
.review-controls > button { min-height: 37px; white-space: nowrap; }
.review-freshness { padding: 13px 17px; border: 1px solid var(--review-line); border-radius: 10px; background: #f5f8f7; font-size: .75rem; line-height: 1.8; }
.review-freshness > div { display: flex; flex-wrap: wrap; gap: 5px 20px; }
.review-freshness strong { color: var(--review-teal); }
.review-freshness p { margin: 5px 0 0; color: var(--review-muted); }
.review-freshness.stale { background: #fff7e9; border-color: #e9d7b6; }
.review-freshness.stale strong { color: var(--review-amber); }

.review-hero { display: grid; grid-template-columns: minmax(0, 1fr) 200px; gap: 30px; padding: 29px 31px; border-radius: 16px; background: var(--review-navy); color: #f3f8f6; box-shadow: 0 8px 24px #163a3e0b; overflow: hidden; }
.review-headline .eyebrow { color: #9fc6be; font-size: .6875rem; letter-spacing: .07em; font-weight: 550; margin: 0 0 12px; }
.review-headline h2 { max-width: 750px; font-size: clamp(1.25rem, 1.65vw, 1.625rem); font-weight: 650; line-height: 1.6; letter-spacing: -.03em; }
.review-headline > p:last-child { margin: 12px 0 0; max-width: 790px; font-size: .8125rem; color: #c5d8d4; line-height: 1.85; }
.review-signal { align-self: stretch; display: flex; flex-direction: column; justify-content: center; border-left: 1px solid #426067; padding-left: 28px; }
.review-status { font-size: .75rem; color: #c1d5d0; }
.review-signal > strong { display: block; font-variant-numeric: tabular-nums; font-size: 2.125rem; letter-spacing: -.06em; line-height: 1.35; margin: 7px 0 10px; font-weight: 650; color: #e8f2de; }
.review-signal small { color: #a9c1bc; line-height: 1.8; font-size: .6875rem; }

.review-kpis { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.review-kpi { background: #fff; border: 1px solid var(--review-line); border-radius: 12px; padding: 20px 20px 17px; min-width: 0; }
.review-kpi .metric-label { font-size: .8125rem; color: #536d71; }
.review-kpi .metric-value { display: block; margin: 10px 0 9px; font-size: clamp(1.625rem, 2.25vw, 2.25rem); font-weight: 650; line-height: 1.1; letter-spacing: -.045em; font-variant-numeric: tabular-nums; }
.review-kpi:first-child .metric-value { color: var(--review-teal); }
.review-kpi .metric-change { display: inline-block; padding: 3px 6px; margin-left: -6px; border-radius: 4px; font-size: .6875rem; font-weight: 550; line-height: 1.5; font-variant-numeric: tabular-nums; }
.review-kpi .metric-change.up { background: #edf5ef; color: #38705a; }
.review-kpi .metric-change.down { background: #faf0e9; color: #9b5e38; }
.review-kpi .metric-change.neutral { color: var(--review-muted); }
.review-kpi .metric-note { color: var(--review-muted); font-size: .6875rem; margin: 8px 0 0; line-height: 1.65; }

.review-grid { display: grid; gap: 20px; min-width: 0; }
.review-grid.two-columns { grid-template-columns: minmax(0, 1.16fr) minmax(0, 1fr); }
.review-card { min-width: 0; padding: 23px 24px; border: 1px solid var(--review-line); border-radius: 13px; background: #fff; }
.review-card-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 14px; margin-bottom: 18px; }
.review-card-head > div:first-child { min-width: 0; }
.review-card-head p { color: var(--review-muted); font-size: .75rem; margin: 5px 0 0; line-height: 1.75; }
.review-card-head > :is(button, a) { flex-shrink: 0; }
.review-card-head > .detail-link { margin-top: 4px; }
.review-tabs { display: inline-flex; align-items: center; gap: 2px; padding: 3px; background: #f0f4f3; border-radius: 7px; flex-shrink: 0; max-width: 100%; }
.review-tabs button { padding: 6px 9px; border: 0; border-radius: 5px; color: #6c7c80; font-size: .6875rem; font-weight: 500; line-height: 1.4; white-space: nowrap; background: transparent; }
.review-tabs button:hover { color: var(--review-teal); background: #e3eeeb; filter: none; }
.review-tabs button.active, .review-tabs button[aria-pressed="true"] { background: #fff; color: #246561; box-shadow: 0 1px 4px #294b4f12; font-weight: 650; }
.review-card > .review-tabs { margin-bottom: 14px; }

.review-chart { width: 100%; margin: 11px 0 0; min-width: 0; }
.review-chart svg { display: block; width: 100%; height: auto; overflow: visible; }
.review-chart text { font-family: inherit; font-size: 13px; fill: #718287; font-weight: 400; }
.review-chart .gridline { stroke: #e9efed; stroke-width: 1; stroke-dasharray: 3 5; }
.review-chart .axis { stroke: #d5e0de; stroke-width: 1; }
.review-chart .trend-line { stroke: var(--review-teal); fill: none; stroke-width: 3; stroke-linejoin: round; stroke-linecap: round; }
.review-chart .comparison-line { stroke: #afbcbf; fill: none; stroke-width: 2; stroke-dasharray: 5 5; stroke-linejoin: round; stroke-linecap: round; }
.review-chart .trend-line ~ circle { fill: var(--review-teal); stroke: #fff; stroke-width: 1.8; }
.review-chart circle[fill="#3c938d"] { fill: #21887c; }
.review-chart circle[fill="#93add6"] { fill: #90a8bc; }
.review-chart circle { cursor: help; }
.review-chart circle:hover, .review-chart circle:focus-visible { stroke: #173d43; stroke-width: 2.5; opacity: 1; outline: none; }
.review-legend { display: flex; flex-wrap: wrap; column-gap: 16px; row-gap: 6px; color: #6a7e80; font-size: .6875rem; margin-top: 3px; line-height: 1.5; }
.review-legend > span { display: inline-flex; align-items: center; }
.review-legend i { display: inline-block; width: 14px; height: 3px; background: var(--review-teal); margin-right: 5px; border-radius: 2px; flex-shrink: 0; }
.review-legend i.previous { background: none; border-top: 2px dashed #a9b9bb; height: 0; border-radius: 0; }
.review-stat-line { margin: 0 0 12px; color: #6d7e82; font-size: .6875rem; line-height: 1.8; }
.review-stat-line strong { display: block; margin-top: 5px; color: #315f60; font-size: .75rem; font-weight: 550; }
.review-tooltip { background: #18383f; color: #f5faf8; border-radius: 8px; padding: 9px 12px; font-size: .75rem; line-height: 1.65; box-shadow: 0 8px 25px #16383c20; max-width: 290px; pointer-events: none; }

.review-story-list { display: grid; gap: 0; }
.review-story { display: flex; align-items: flex-start; gap: 12px; padding: 15px 0; border-bottom: 1px solid #eaf0ee; }
.review-story:first-child { padding-top: 0; }
.review-story:last-child { padding-bottom: 0; border-bottom: 0; }
.review-story .story-index { flex-shrink: 0; margin-top: 2px; min-width: 24px; color: #93aaa7; font-size: .75rem; line-height: 1.9; font-variant-numeric: tabular-nums; font-weight: 600; }
.review-story .story-body { min-width: 0; flex: 1; }
.review-story .story-body p { margin: 6px 0; font-size: .8125rem; line-height: 1.8; color: #68797d; }
.review-story .story-body p strong { font-weight: 600; color: #36575c; font-variant-numeric: tabular-nums; }
.review-story .story-body > .review-badge { margin-bottom: 6px; }
.review-badge { display: inline-flex; align-items: center; padding: 3px 7px; border-radius: 4px; background: #faf1df; color: #8b622c; font-size: .625rem; line-height: 1.5; font-weight: 550; }
.review-badge.fact { background: #eaf4ef; color: #34715e; }
.review-badge.unknown { background: #f0f2f1; color: #74807c; }
.review-workspace .detail-link { display: inline-block; padding: 3px 0; border: 0; border-radius: 2px; background: transparent; color: #297570; font-size: .6875rem; line-height: 1.6; font-weight: 550; text-align: left; text-decoration: none; }
.review-workspace .detail-link:hover { color: #124e4b; background: transparent; text-decoration: underline; text-underline-offset: 3px; filter: none; }
.review-empty { color: var(--review-muted); font-size: .8125rem; line-height: 1.9; margin: 6px 0 0; padding: 18px 20px; background: #f6f8f7; border-radius: 8px; }

.review-journey { display: grid; grid-template-columns: minmax(0, 1fr) minmax(115px, .73fr) minmax(0, 1fr) minmax(0, 1.12fr); gap: 15px; align-items: stretch; padding: 5px 0 1px; }
.review-workspace .journey-step { padding: 18px; border-radius: 9px; background: #f5f8f7; min-width: 0; }
.review-workspace .journey-step:first-child { background: #edf6f2; }
.review-workspace .journey-step h4 { color: #56716f; font-size: .6875rem; font-weight: 500; }
.review-workspace .journey-step > strong { display: block; color: #264d4d; font-variant-numeric: tabular-nums; font-weight: 650; font-size: clamp(1.25rem, 1.6vw, 1.75rem); letter-spacing: -.045em; line-height: 1.2; margin: 12px 0 10px; overflow-wrap: anywhere; }
.review-workspace .journey-step > p { font-size: .6875rem; color: #72827f; line-height: 1.9; margin: 0 0 13px; }
.review-workspace .journey-gap { position: relative; align-self: center; padding: 30px 3px 12px; font-size: .6875rem; line-height: 1.9; text-align: center; color: #95743b; }
.review-workspace .journey-gap::before { content: ""; position: absolute; left: 4px; right: 4px; top: 13px; border-top: 1px dashed #cbb68c; }
.review-workspace .journey-gap::after { content: "?"; position: absolute; left: calc(50% - 10px); top: 3px; width: 20px; height: 20px; display: grid; place-items: center; border: 1px solid #dfcda7; border-radius: 50%; background: #fffaf0; color: #a37d34; font-size: .6875rem; }

.review-priorities { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.review-action { position: relative; min-width: 0; display: flex; flex-direction: column; align-items: flex-start; padding: 22px; border: 1px solid #e9dfc8; border-radius: 11px; background: #fffcf5; }
.review-action .action-step { position: absolute; right: 20px; top: 19px; color: #cabb98; font-size: 1rem; font-weight: 500; font-variant-numeric: tabular-nums; }
.review-action .action-label { color: #977744; font-size: .625rem; font-weight: 550; letter-spacing: .04em; margin: 0 28px 13px 0; }
.review-action > h4 { color: #584f3a; font-size: .9375rem; }
.review-action > p { color: #7e7666; font-size: .75rem; line-height: 1.85; margin: 10px 0 7px; }
.review-action .action-evidence { margin-bottom: 15px; }
.review-action .action-next { width: 100%; border-top: 1px solid #eadfc8; padding: 13px 0 0; margin-top: auto; }
.review-action .action-next > strong { font-size: .6875rem; font-weight: 550; color: #8a6b38; }
.review-action .action-next > p { font-size: .75rem; color: #7e7666; line-height: 1.8; margin: 5px 0 13px; }
.review-action > .detail-link { color: #8f692d; }
.review-action > .detail-link:hover { color: #634514; }
.review-priorities > .review-empty { grid-column: 1 / -1; }

.review-quality { background: #f8f4e9; color: #857040; border: 1px solid #eae2ce; border-radius: 8px; padding: 13px 17px; font-size: .6875rem; line-height: 1.9; }
.review-quality > span { color: #9b8967; }
.review-disclosure { border: 1px solid var(--review-line); border-radius: 11px; background: #fff; min-width: 0; overflow: hidden; }
.review-disclosure > summary { padding: 18px 22px; cursor: pointer; color: #54716f; font-size: .8125rem; font-weight: 550; line-height: 1.7; }
.review-disclosure > summary::marker { color: #8ca6a1; }
.review-disclosure > summary:hover { background: #f6f9f7; }
.review-disclosure[open] > summary { border-bottom: 1px solid var(--review-line); }
.review-disclosure-body { padding: 24px; min-width: 0; }
.review-disclosure-body .panel { border-color: var(--review-line); }
.review-disclosure-body .kpis { gap: 10px; }
.review-disclosure-body .kpi { padding: 14px; }
.review-disclosure-body .kpi-value { font-size: 1.625rem; }
.review-disclosure-body .table-wrap { max-width: 100%; }

@media (max-width: 1350px) and (min-width: 761px) {
  .review-card { padding: 20px; }
  .review-grid.two-columns { grid-template-columns: minmax(0, 1.08fr) minmax(0, 1fr); }
  .review-card-head:has(.review-tabs) { flex-wrap: wrap; gap: 10px; }
  .review-card-head > .review-tabs { margin-left: auto; }
  .review-controls select { max-width: 160px; }
  .review-hero { grid-template-columns: minmax(0, 1fr) 165px; gap: 23px; padding: 25px; }
  .review-signal { padding-left: 23px; }
  .review-signal > strong { font-size: 1.875rem; }
  .review-journey { gap: 10px; grid-template-columns: minmax(0, 1fr) minmax(90px, .65fr) minmax(0, 1fr) minmax(0, 1.05fr); }
  .review-workspace .journey-step { padding: 14px 12px; }
  .review-action { padding: 19px; }
}
@media (max-width: 1050px) and (min-width: 761px) {
  .review-toolbar { flex-wrap: wrap; gap: 15px; }
  .review-controls { justify-content: flex-start; }
  .review-grid.two-columns { grid-template-columns: minmax(0, 1fr); }
  .review-card-head:has(.review-tabs) { flex-wrap: nowrap; }
  .review-chart { max-width: 720px; margin-left: auto; margin-right: auto; }
  .review-hero { grid-template-columns: minmax(0, 1fr) 150px; }
  .review-signal { padding-left: 20px; }
  .review-kpis { gap: 11px; }
  .review-kpi { padding: 17px 13px; }
  .review-priorities { grid-template-columns: minmax(0, 1fr); gap: 12px; }
  .review-action .action-evidence { margin-bottom: 7px; }
  .review-action .action-next { margin-top: 10px; }
}
@media (max-width: 760px) {
  .review-workspace { gap: 19px; }
  .review-toolbar { align-items: flex-start; flex-direction: column; gap: 15px; }
  .review-identity h2 { font-size: 1.25rem; }
  .review-controls { width: 100%; justify-content: flex-start; gap: 8px; flex-wrap: wrap; }
  .review-controls label { flex: 1; }
  .review-controls select { max-width: 100%; width: 100%; font-size: .75rem; }
  .review-controls > button { font-size: .75rem; padding-left: 11px; padding-right: 11px; }
  .review-hero { grid-template-columns: minmax(0, 1fr); gap: 20px; padding: 22px; border-radius: 12px; }
  .review-headline h2 { font-size: 1.25rem; }
  .review-headline > p:last-child { font-size: .75rem; }
  .review-signal { border-left: none; border-top: 1px solid #426067; padding: 15px 0 0; display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; column-gap: 16px; }
  .review-signal .review-status { grid-column: 1; }
  .review-signal > strong { grid-column: 2; grid-row: 1 / 3; font-size: 1.875rem; margin: 0; }
  .review-signal small { grid-column: 1; margin-top: 5px; font-size: .625rem; }
  .review-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 11px; }
  .review-kpi { padding: 17px 16px; border-radius: 9px; }
  .review-kpi .metric-value { font-size: 1.8125rem; }
  .review-kpi .metric-label { font-size: .75rem; }
  .review-kpi .metric-note { font-size: .625rem; }
  .review-grid.two-columns { grid-template-columns: minmax(0, 1fr); gap: 19px; }
  .review-card { padding: 20px 17px; border-radius: 10px; }
  .review-card-head { flex-wrap: wrap; gap: 12px; margin-bottom: 17px; }
  .review-card-head h3 { font-size: .9375rem; }
  .review-card-head > .review-tabs { margin-left: auto; }
  .review-card-head > :is(a, button) { flex-shrink: 1; }
  .review-card-head p { font-size: .6875rem; }
  .review-chart text { font-size: 13px; }
  .review-legend { row-gap: 7px; font-size: .625rem; }
  .review-story { gap: 9px; }
  .review-story .story-index { min-width: 20px; }
  .review-story .story-body p { font-size: .75rem; }
  .review-workspace .detail-link { font-size: .75rem; padding: 5px 0; }
  .review-journey { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 11px; }
  .review-workspace .journey-step:first-child { grid-column: 1 / -1; }
  .review-workspace .journey-gap { grid-column: 1 / -1; padding: 27px 15px 7px; }
  .review-workspace .journey-gap::before { left: 20%; right: 20%; }
  .review-workspace .journey-step { padding: 17px 13px; }
  .review-workspace .journey-step:first-child > strong { font-size: 1.8125rem; }
  .review-workspace .journey-step > strong { font-size: 1.5rem; }
  .review-workspace .journey-step > p { font-size: .6875rem; }
  .review-priorities { grid-template-columns: minmax(0, 1fr); gap: 13px; }
  .review-action { padding: 21px; }
  .review-action .action-evidence { margin-bottom: 10px; }
  .review-action .action-next { margin-top: 5px; }
  .review-disclosure > summary { padding: 17px; font-size: .75rem; }
  .review-disclosure-body { padding: 16px; }
  .review-disclosure-body .kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .review-empty { padding: 16px; font-size: .75rem; }
}
@media (max-width: 380px) {
  .review-controls > button { width: 100%; }
  .review-signal { grid-template-columns: minmax(0, 1fr); }
  .review-signal > strong { grid-column: 1; grid-row: auto; margin-top: 9px; }
  .review-signal small { grid-row: 3; }
  .review-journey { grid-template-columns: minmax(0, 1fr); }
}
@media (prefers-reduced-motion: reduce) {
  .review-workspace button, .review-workspace a, .review-workspace select { transition: none; }
}
@media print {
  .review-workspace { gap: 16px; }
  .review-workspace .review-controls, .review-workspace .review-tabs, .review-workspace .detail-link, .review-workspace button { display: none; }
  .review-hero { background: #f0f5f2; color: #18343c; box-shadow: none; border: 1px solid #cadbd4; }
  .review-hero .eyebrow, .review-hero p, .review-hero strong, .review-hero span, .review-hero small { color: #31534d; }
  .review-card, .review-action, .review-kpis, .review-hero { break-inside: avoid; }
  .review-grid.two-columns { grid-template-columns: minmax(0, 1fr); }
}

/* Keep the account decision above the fold; controls remain available. */
main.review-mode .heading { margin-bottom: 16px; }
main.review-mode .heading > div > .eyebrow { display: none; }
main.review-mode > #source-notice { display: none; }
main.review-mode > .toolbar { margin-bottom: 20px; }
.review-cohort-control { display: flex; align-items: center; gap: 10px; color: #65767a; margin: 14px 0; }
.review-chart [role=button] { cursor: pointer; }
.review-chart [role=button]:focus-visible { stroke: #18343c; stroke-width: 3px; outline: none; }
