.report { display: grid; gap: clamp(56px, 8vw, 96px); padding: clamp(32px, 5vw, 64px) 0 80px; }
.report[aria-busy='true'] { opacity: 0; }
.report { transition: opacity 0.6s var(--ease); }
.r-hero { display: grid; gap: 18px; }
.r-title { font-size: clamp(2.6rem, 6vw, 4.5rem); max-width: 16ch; }
.kpis { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-top: 18px; }
.kpi { padding: 22px 22px 20px; display: grid; gap: 6px; border-radius: var(--radius); background: var(--surface); box-shadow: var(--shadow), inset 0 0 0 1px var(--line); }
.kpi b { font-size: clamp(2.2rem, 4vw, 3.2rem); font-weight: 300; letter-spacing: -0.03em; line-height: 1; }
.kpi span { color: var(--muted); font-size: 14px; }
.kpi.dark { background: var(--pill); color: var(--pill-ink); box-shadow: var(--shadow); }
.kpi.dark span { color: oklch(75% 0 0); }
.kpi.glow b { background: linear-gradient(90deg, var(--accent-strong), var(--heat-3)); -webkit-background-clip: text; background-clip: text; color: transparent; }

.r-block { display: grid; gap: 28px; }
.r-head { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; align-items: end; }
.r-head > div:first-child { display: grid; gap: 12px; }
.r-head > p { max-width: 52ch; justify-self: end; }
.map-box { padding: 18px 18px 22px; }
.map-bar { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; color: var(--lb-muted); padding: 2px 6px 6px; }

/* top 3 */
.top3 { display: grid; gap: 16px; }
.t3 { display: grid; grid-template-columns: 120px 1.3fr 1fr; gap: 28px; padding: 28px; position: relative; overflow: hidden; }
.t3 .rank { font-size: 104px; font-weight: 200; line-height: 0.85; letter-spacing: -0.06em; color: var(--ink); }
.t3:first-child { background: var(--pill); color: var(--pill-ink); }
.t3:first-child .muted, .t3:first-child .why p { color: oklch(76% 0 0); }
.t3:first-child .deps span { background: oklch(100% 0 0 / 0.08); box-shadow: inset 0 0 0 1px oklch(100% 0 0 / 0.12); color: oklch(88% 0 0); }
.t3:first-child .rank { color: var(--glow); }
.t3:first-child blockquote { border-color: var(--glow); color: oklch(85% 0 0); }
.t3 h3 { font-size: 1.6rem; font-weight: 300; letter-spacing: -0.02em; }
.t3 .main { display: grid; gap: 12px; align-content: start; }
.t3 .idea { font-size: 16px; }
.t3 .step { font-size: 14px; }
.t3 .step b { font-weight: 500; }
.t3 .why { display: grid; gap: 14px; align-content: start; }
.t3 .big { display: flex; align-items: baseline; gap: 8px; }
.t3 .big b { font-size: 52px; font-weight: 300; letter-spacing: -0.03em; line-height: 1; }
.meter { height: 6px; border-radius: 99px; background: oklch(50% 0 0 / 0.15); overflow: hidden; }
.meter i { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--heat-2), var(--heat-4)); width: 0; transition: width 1.4s var(--ease); }
.meter.in i { width: var(--w); }
.stats { display: flex; gap: 18px; flex-wrap: wrap; font-size: 13px; }
.stats span { display: inline-flex; gap: 6px; align-items: center; }
.diff { display: inline-flex; gap: 3px; }
.diff i { width: 7px; height: 7px; border-radius: 50%; background: oklch(50% 0 0 / 0.2); }
.diff i.on { background: currentColor; }
.deps { display: flex; flex-wrap: wrap; gap: 6px; }
.deps span { font-family: var(--mono); font-size: 11px; padding: 3px 9px; border-radius: 99px; background: var(--surface-2); box-shadow: inset 0 0 0 1px var(--line); color: var(--ink-2); }
blockquote { margin: 0; padding-left: 14px; border-left: 2px solid var(--accent); font-style: italic; color: var(--ink-2); font-size: 15px; }
blockquote cite { display: block; font-style: normal; font-size: 12px; color: var(--muted); margin-top: 4px; font-family: var(--mono); }
.synth { justify-self: end; display: flex; align-items: center; gap: 10px; }
.synth .muted { font-size: 13px; }

/* panes */
.two { grid-template-columns: 1fr 1fr; gap: 20px; }
.pane { padding: 24px; display: grid; gap: 18px; align-content: start; }
.pane-head { display: grid; gap: 8px; }
#sankey svg, #matrix svg { width: 100%; height: auto; overflow: visible; }
.sk-node rect { rx: 3; }
.sk-label { font-size: 11.5px; fill: var(--ink-2); paint-order: stroke; stroke: var(--surface); stroke-width: 3px; stroke-linejoin: round; }
.sk-value { font-family: var(--mono); font-size: 18px; fill: var(--ink); }
.sk-link { fill: none; mix-blend-mode: multiply; transition: stroke-opacity 0.2s; }
.sk-link:hover { stroke-opacity: 0.8 !important; }
.mx-axis { font-family: var(--mono); font-size: 10.5px; fill: var(--muted); }
.mx-grid { stroke: var(--line); }
.mx-q { font-size: 12px; fill: var(--muted); }
.mx-q.win { fill: var(--accent-strong); font-weight: 500; }
.mx-dot circle { stroke: white; stroke-width: 1.5; transition: r 0.3s var(--ease); cursor: pointer; }
.mx-dot text { font-size: 11px; fill: var(--ink-2); pointer-events: none; }
.mx-dot:hover circle { stroke: var(--ink); }

/* process list */
.plist { display: grid; gap: 8px; }
.prow { border-radius: 16px; background: var(--surface); box-shadow: var(--shadow-sm), inset 0 0 0 1px var(--line); }
.prow summary { display: grid; grid-template-columns: minmax(180px, 1.2fr) 2fr 110px 80px; gap: 20px; align-items: center; padding: 16px 20px; cursor: pointer; list-style: none; }
.prow summary::-webkit-details-marker { display: none; }
.prow summary::after { display: none; }
.prow .pname b { display: block; font-weight: 500; }
.prow .pname span { font-size: 12.5px; color: var(--muted); }
.hbar { position: relative; height: 26px; border-radius: 8px; background: var(--surface-2); box-shadow: inset 0 0 0 1px var(--line); overflow: hidden; }
.hbar .h { position: absolute; inset: 0 auto 0 0; border-radius: inherit; background: oklch(80% 0 0); width: 0; transition: width 1.2s var(--ease); }
.hbar .a { position: absolute; inset: 0 auto 0 0; border-radius: inherit; width: 0; transition: width 1.2s var(--ease) 0.15s; }
.hbar.in .h { width: var(--hw); }
.hbar.in .a { width: var(--aw); }
.hbar em { position: absolute; left: 10px; top: 50%; transform: translateY(-50%); font-style: normal; font-family: var(--mono); font-size: 11.5px; color: var(--ink); mix-blend-mode: multiply; }
.prow .auto { font-family: var(--mono); font-size: 13px; text-align: right; }
.prow .pbody { padding: 0 20px 18px; display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.prow .pbody h4 { margin: 0 0 6px; font-weight: 500; font-size: 13px; color: var(--muted); }
.prow[open] { box-shadow: var(--shadow), inset 0 0 0 1px var(--line-strong); }

.tools-cloud { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.tools-cloud span { padding: 6px 14px; border-radius: 99px; background: var(--surface-2); box-shadow: inset 0 0 0 1px var(--line); white-space: nowrap; }
.tools-cloud span b { font-family: var(--mono); font-weight: 400; font-size: 0.75em; color: var(--muted); margin-left: 6px; }
.people { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; }
.person { display: flex; align-items: center; gap: 10px; }
.avatar { width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; font-size: 13px; font-weight: 500; background: var(--accent-soft); color: var(--accent-strong); flex: none; }
.person.pending .avatar { background: var(--surface-2); color: var(--muted); box-shadow: inset 0 0 0 1px var(--line); }
.person div { display: grid; line-height: 1.25; }
.person small { color: var(--muted); font-size: 12px; }
.method { padding: 24px 28px; gap: 10px; }
.method-text { color: var(--ink-2); font-size: 14.5px; max-width: 90ch; }
.empty-state { padding: 48px; text-align: center; display: grid; gap: 12px; justify-items: center; }

@media (max-width: 960px) {
  .kpis { grid-template-columns: 1fr 1fr; }
  .r-head { grid-template-columns: 1fr; }
  .r-head > p, .synth { justify-self: start; }
  .t3 { grid-template-columns: 1fr; gap: 16px; }
  .t3 .rank { font-size: 64px; }
  .two { grid-template-columns: 1fr; }
  .prow summary { grid-template-columns: 1fr 70px; }
  .prow summary .hbar { grid-column: 1 / -1; grid-row: 2; }
  .prow summary .dcol { display: none; }
  .prow .pbody { grid-template-columns: 1fr; }
}
@page { size: A4; margin: 12mm 10mm; }
@media print {
  html { zoom: 0.78; }
  .nav, .synth, .footer { display: none; }
  body { background: white; }
  .report { padding-top: 0; }
  .r-block { break-inside: auto; }
  .r-block > h2, .r-block > .eyebrow { break-after: avoid; }
  .t3, .wish, .rung, .prow, .card, .lightbox, .wish-notes > *, svg { break-inside: avoid; }
  .card { box-shadow: none; border: 1px solid #e5e5ea; }
  .t3 .build, .rung .btn { display: none; }
  details.prow > .pbody { display: none; }
}

/* wish list: what the team itself wants gone */
.wish-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 14px; }
.wish { padding: 20px 22px; display: grid; gap: 6px; }
.wish b { font-size: 17px; font-weight: 600; letter-spacing: -0.015em; }
.wish span { font-size: 13px; }
.wish-hours { color: var(--accent-strong); font-weight: 600; }
.wish-notes { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 14px; margin-top: 18px; }

/* next step ladder */
.ladder { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.rung { padding: 26px; display: grid; gap: 10px; align-content: start; justify-items: start; }
.rung-n { width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; font-weight: 700; font-size: 14px; background: var(--surface-2); }
.rung.current { background: #000; color: #f5f5f7; }
.rung.current .muted { color: #a1a1a6; }
.rung.current .rung-n { background: rgba(255, 255, 255, 0.12); }
.rung.current .chip { background: rgba(255, 255, 255, 0.1); color: #f5f5f7; box-shadow: none; }
.t3 .build { justify-self: start; margin-top: 4px; }
.t3:first-child .build { background: #fff; color: #000; }
@media (max-width: 960px) { .ladder { grid-template-columns: 1fr; } }

/* system scan */
.scan-block { display: grid; gap: 18px; }
.scan-table { padding: 4px 22px; }
.scan-row { display: grid; grid-template-columns: minmax(0, 1.5fr) repeat(3, minmax(0, 0.75fr)) minmax(0, 1.5fr); gap: 18px; padding: 18px 0; border-bottom: 1px solid rgba(0, 0, 0, 0.07); align-items: start; }
.scan-row:last-child { border-bottom: 0; }
.scan-row small { display: block; color: var(--muted); font-size: 12.5px; margin-top: 4px; line-height: 1.45; }
.sr-main b { font-size: 15.5px; font-weight: 600; letter-spacing: -0.01em; }
.sr-stat b { display: block; font-size: 19px; font-weight: 600; letter-spacing: -0.02em; white-space: nowrap; }
.sr-stat span { display: block; font-size: 12.5px; color: var(--muted); line-height: 1.35; margin-top: 2px; }
@media (max-width: 900px) {
  .scan-row { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
  .sr-main, .sr-check { grid-column: 1 / -1; }
}
.check { display: inline-block; font-size: 12.5px; font-weight: 600; padding: 2px 10px; border-radius: 99px; background: rgba(0, 0, 0, 0.05); }
.check.plausible { background: var(--accent-soft); color: var(--accent-strong); }
.check.interview_high, .check.interview_low { background: #fff3e0; color: #9a5b00; }
.scan-new .eyebrow, .scan-notes .eyebrow { margin-bottom: 10px; }
.scan-new-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 14px; }
.scan-new-grid p { margin: 4px 0 0; font-size: 14px; color: var(--ink-2, #3a3a3c); }
.scan-notes { padding: 20px 22px; }
.scan-notes ul { margin: 0 0 10px; padding-left: 18px; display: grid; gap: 6px; font-size: 14.5px; }
@media print { .scan-row { break-inside: avoid; } }

/* Reference style: greige cards, white tiles, lime for the headline numbers and #1 */
.kpi { box-shadow: none; }
.kpi b { font-weight: 400; letter-spacing: -0.04em; }
.kpi.glow { background: var(--lime); }
.kpi.glow b { background: none; color: var(--ink); -webkit-background-clip: initial; background-clip: initial; }
.kpi.glow span { color: rgba(22, 22, 22, 0.7); }
.kpi.dark { background: var(--ink); }
.t3:first-child { background: var(--lime); color: var(--ink); }
.t3:first-child .muted, .t3:first-child .why p { color: rgba(22, 22, 22, 0.7); }
.t3:first-child .deps span { background: rgba(255, 255, 255, 0.6); box-shadow: none; color: var(--ink); }
.t3:first-child .rank { color: var(--ink); }
.t3:first-child blockquote { border-color: var(--ink); color: var(--ink-2); }
.t3:first-child .build { background: var(--ink); color: #fff; }
.t3:first-child .meter { background: rgba(255, 255, 255, 0.6); }
.t3:first-child .meter i { background: var(--ink); }
.t3 h3, .t3 .big b, .t3 .rank { font-weight: 400; }
.meter { background: #fff; }
.meter i { background: var(--lime); box-shadow: inset 0 0 0 1px rgba(22, 22, 22, 0.15); }
blockquote { border-left-color: var(--lime); border-left-width: 3px; }
.mx-q.win { fill: var(--ink); }
.avatar { background: var(--lime); color: var(--ink); }
.wish-hours { color: var(--ink); }
.rung.current { background: var(--lime); color: var(--ink); }
.rung.current .muted { color: rgba(22, 22, 22, 0.7); }
.rung.current .rung-n { background: #fff; }
.rung.current .chip { background: #fff; color: var(--ink); }
.deps span { background: #fff; box-shadow: none; }
.scan-table, .scan-notes { background: var(--surface); }
.check.plausible { background: var(--lime); color: var(--ink); }
@media print { .card { border: 0; } }

/* phones: keep ranges on one line, buttons on one line */
@media (max-width: 640px) {
  .t3 .big { flex-direction: column; align-items: flex-start; gap: 4px; }
  .t3 .big b { font-size: 44px; white-space: nowrap; }
  .kpi b { font-size: 2rem; white-space: nowrap; }
  .nav .btn, .nav button { white-space: nowrap; }
}
