/* ---------- tokens ---------- */
:root {
  color-scheme: dark;
  --page: #0d0d0d; --surface: #1a1a19; --surface-2: #232321; --raise: #2a2a28;
  --ink: #f0efec; --ink-2: #c3c2b7; --muted: #8f8d87;
  --grid: #2c2c2a; --axis: #383835; --border: rgba(255,255,255,.10);
  --accent: #3987e5; --accent-ink: #86b6ef; --accent-wash: rgba(57,135,229,.14);
  --s1: #3987e5; --s2: #d95926; --s3: #199e70;
  --good: #0ca30c; --warning: #fab219; --serious: #ec835a; --critical: #d03b3b;
  --shadow: 0 1px 0 rgba(255,255,255,.03) inset, 0 12px 32px rgba(0,0,0,.35);
  --sans: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --mono: ui-monospace, "Cascadia Mono", "SF Mono", Consolas, monospace;
  --side: 248px;
}
:root[data-theme="light"] {
  color-scheme: light;
  --page: #f4f4f1; --surface: #fcfcfb; --surface-2: #f0efec; --raise: #e9e8e3;
  --ink: #0b0b0b; --ink-2: #52514e; --muted: #6f6d68;
  --grid: #e1e0d9; --axis: #c3c2b7; --border: rgba(11,11,11,.12);
  --accent: #2a78d6; --accent-ink: #1c5cab; --accent-wash: rgba(42,120,214,.10);
  --s1: #2a78d6; --s2: #eb6834; --s3: #1baf7a;
  --shadow: 0 1px 2px rgba(11,11,11,.05), 0 8px 24px rgba(11,11,11,.06);
}

/* ---------- base ---------- */
* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 76px; }
body {
  margin: 0; background: var(--page); color: var(--ink);
  font: 16px/1.6 var(--sans); -webkit-font-smoothing: antialiased;
  background-image: radial-gradient(1200px 500px at 70% -10%, var(--accent-wash), transparent 70%);
  background-repeat: no-repeat;
}
h1, h2, h3, p, figure, ul { margin: 0; }
h1 { font-size: clamp(32px, 4.6vw, 54px); line-height: 1.08; letter-spacing: -.02em; font-weight: 650; max-width: 19ch; text-wrap: balance; }
h2 { font-size: clamp(24px, 2.6vw, 32px); line-height: 1.2; letter-spacing: -.01em; font-weight: 650; text-wrap: balance; }
h3 { font-size: 17px; line-height: 1.35; font-weight: 600; }
a { color: var(--accent-ink); text-underline-offset: 3px; }
button { font: inherit; color: inherit; cursor: pointer; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 6px; }
[hidden] { display: none !important; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--surface); padding: 8px 12px; border-radius: 8px; z-index: 50; }
.skip:focus { left: 8px; }

.eyebrow { font: 500 12px/1.4 var(--mono); letter-spacing: .08em; text-transform: uppercase; color: var(--accent-ink); }
.sub { color: var(--ink-2); max-width: 72ch; }
.fine { font-size: 13px; color: var(--muted); max-width: 90ch; }
.note { font-size: 14px; color: var(--ink-2); }

/* ---------- shell ---------- */
.side {
  position: fixed; inset: 0 auto 0 0; width: var(--side); padding: 22px 16px;
  background: var(--surface); border-right: 1px solid var(--border);
  display: flex; flex-direction: column; gap: 26px; z-index: 20;
}
.brand { display: flex; gap: 12px; align-items: center; text-decoration: none; color: var(--ink); }
.brand strong { display: block; font-size: 15px; line-height: 1.2; }
.brand small { color: var(--muted); font-size: 12px; }
.brand-mark { width: 36px; height: 36px; border-radius: 9px; background: var(--surface-2); border: 1px solid var(--border); display: flex; align-items: flex-end; justify-content: center; gap: 3px; padding: 8px 0; flex: none; }
.brand-mark i { width: 5px; border-radius: 2px; background: var(--s1); }
.brand-mark i:nth-child(1) { height: 40%; } .brand-mark i:nth-child(2) { height: 70%; } .brand-mark i:nth-child(3) { height: 100%; background: var(--s3); }
.nav { display: flex; flex-direction: column; gap: 2px; }
.nav a { display: flex; gap: 12px; align-items: baseline; padding: 9px 10px; border-radius: 8px; color: var(--ink-2); text-decoration: none; font-size: 14px; white-space: nowrap; }
.nav a span { font: 500 11px var(--mono); color: var(--muted); }
.nav a:hover { background: var(--surface-2); color: var(--ink); }
.nav a.is-active { background: var(--accent-wash); color: var(--ink); }
.nav a.is-active span { color: var(--accent-ink); }
.side-foot { margin-top: auto; font-size: 12px; color: var(--muted); line-height: 1.7; }
.dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--good); margin-right: 4px; }

.main { margin-left: var(--side); min-width: 0; }
.topbar {
  position: sticky; top: 0; z-index: 15; display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 10px clamp(16px, 4vw, 48px); background: color-mix(in srgb, var(--page) 84%, transparent);
  backdrop-filter: blur(12px); border-bottom: 1px solid var(--border);
}
.lens { display: flex; align-items: center; gap: 12px; min-width: 0; flex-wrap: wrap; }
.lens-label { font: 500 11px var(--mono); letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.seg { display: inline-flex; background: var(--surface-2); border: 1px solid var(--border); border-radius: 10px; padding: 3px; gap: 2px; max-width: 100%; }
.seg.wrap { flex-wrap: wrap; }
.seg button { border: 0; background: none; padding: 7px 12px; border-radius: 7px; font-size: 13.5px; color: var(--ink-2); line-height: 1.25; }
.seg button:hover { color: var(--ink); }
.seg button[aria-pressed="true"] { background: var(--surface); color: var(--ink); box-shadow: 0 0 0 1px var(--border), 0 1px 3px rgba(0,0,0,.25); font-weight: 600; }
.icon-btn { display: inline-flex; gap: 8px; align-items: center; border: 1px solid var(--border); background: var(--surface-2); border-radius: 10px; padding: 8px 12px; font-size: 13.5px; color: var(--ink-2); flex: none; }
.icon-btn:hover { color: var(--ink); }

main { padding: 0 clamp(16px, 4vw, 48px); max-width: 1240px; }
section { padding: 64px 0 8px; display: grid; gap: 20px; }
.sec-head { display: grid; gap: 10px; margin-bottom: 4px; }
.foot { padding: 48px clamp(16px, 4vw, 48px) 40px; color: var(--muted); font-size: 13px; }

/* ---------- hero ---------- */
.hero { padding-top: 56px; gap: 22px; }
.lede { font-size: clamp(17px, 1.5vw, 19px); color: var(--ink-2); max-width: 68ch; }
.cta { display: flex; flex-wrap: wrap; gap: 10px; }
.context { font-size: 14px; color: var(--muted); max-width: 80ch; }
.btn { display: inline-flex; align-items: center; justify-content: center; padding: 10px 16px; border-radius: 10px; border: 1px solid var(--border); background: var(--surface-2); color: var(--ink); text-decoration: none; font-size: 14.5px; font-weight: 550; transition: transform .15s, background .15s; }
.btn:hover { background: var(--raise); transform: translateY(-1px); }
.btn.primary { background: var(--accent); border-color: transparent; color: #fff; }
.btn.primary:hover { filter: brightness(1.08); background: var(--accent); }

/* ---------- cards, tiles ---------- */
.card { background: var(--surface); border: 1px solid var(--border); border-radius: 14px; padding: 22px; box-shadow: var(--shadow); min-width: 0; }
.grid { display: grid; gap: 16px; }
.g2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.g3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.tiles { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 12px; margin-top: 10px; }
.tiles.mini { grid-template-columns: repeat(4, minmax(0, 1fr)); margin: 0; }
.tile { background: var(--surface); border: 1px solid var(--border); border-radius: 12px; padding: 14px 16px; box-shadow: var(--shadow); min-width: 0; }
.tiles.mini .tile { background: var(--surface-2); box-shadow: none; }
.tile-k { font: 500 11px var(--mono); letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.tile-v { font-size: 34px; font-weight: 650; letter-spacing: -.02em; line-height: 1.2; margin-top: 4px; white-space: nowrap; }
.tile-v small { font-size: 14px; font-weight: 500; color: var(--ink-2); letter-spacing: 0; margin-left: 5px; }
.tile-d { font-size: 13px; color: var(--ink-2); line-height: 1.45; margin-top: 4px; }
.chip { display: inline-block; justify-self: start; font: 500 11px var(--mono); letter-spacing: .05em; text-transform: uppercase; color: var(--accent-ink); background: var(--accent-wash); padding: 3px 8px; border-radius: 6px; }
.work { display: grid; gap: 10px; align-content: start; transition: transform .18s, border-color .18s; }
.work:hover { transform: translateY(-2px); border-color: color-mix(in srgb, var(--accent) 50%, var(--border)); }
.work p { color: var(--ink-2); font-size: 14.5px; }
.more { color: var(--ink-2); font-size: 14.5px; }

/* ---------- role fit ---------- */
.fit { display: grid; grid-template-columns: minmax(240px, 5fr) 7fr; gap: 0; padding: 0; overflow: hidden; }
.fit-list { display: flex; flex-direction: column; padding: 10px; gap: 2px; border-right: 1px solid var(--border); background: var(--surface-2); }
.fit-list button { display: grid; grid-template-columns: 1fr auto; gap: 10px; align-items: center; text-align: left; border: 0; background: none; padding: 11px 12px; border-radius: 9px; font-size: 14.5px; color: var(--ink-2); line-height: 1.35; }
.fit-list button:hover { color: var(--ink); background: var(--raise); }
.fit-list button[aria-selected="true"] { background: var(--surface); color: var(--ink); font-weight: 600; box-shadow: 0 0 0 1px var(--border); }
.fit-list .n { font: 500 11px var(--mono); color: var(--muted); background: var(--page); border: 1px solid var(--border); border-radius: 999px; padding: 1px 8px; white-space: nowrap; }
.fit-list button[aria-selected="true"] .n { color: var(--accent-ink); }
.fit-detail { padding: 24px; display: grid; gap: 14px; align-content: start; }
.fit-detail .ask { color: var(--ink-2); font-size: 14.5px; border-left: 2px solid var(--accent); padding-left: 12px; }
.ev { display: grid; gap: 10px; list-style: none; padding: 0; }
.ev li { display: grid; grid-template-columns: auto 1fr; gap: 12px; padding: 12px 14px; background: var(--surface-2); border: 1px solid var(--border); border-radius: 10px; animation: rise .3s both; }
.ev li:nth-child(2) { animation-delay: .04s; } .ev li:nth-child(3) { animation-delay: .08s; } .ev li:nth-child(4) { animation-delay: .12s; } .ev li:nth-child(5) { animation-delay: .16s; }
.ev .where { font: 500 11px var(--mono); letter-spacing: .04em; text-transform: uppercase; color: var(--muted); width: 84px; padding-top: 3px; }
.ev p { font-size: 14.5px; }
@keyframes rise { from { opacity: 0; transform: translateY(6px); } }

/* ---------- coverage model ---------- */
.model { display: grid; gap: 16px; }
.model-head { display: grid; gap: 6px; }
.model-head p { color: var(--ink-2); font-size: 14.5px; max-width: 72ch; }
.tier-frame { display: block; width: 100%; height: 600px; border: 0; background: transparent; }

/* ---------- charts ---------- */
.filters { display: flex; flex-wrap: wrap; gap: 12px 20px; align-items: center; }
.slider { display: inline-flex; align-items: center; gap: 8px; font-size: 13.5px; color: var(--ink-2); }
.slider output { font-family: var(--mono); color: var(--ink); margin-left: 4px; }
.slider input { accent-color: var(--accent); width: 150px; }
.lab, .dash { display: grid; gap: 18px; }
.stat-row { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.stat { background: var(--surface-2); border-radius: 10px; padding: 12px 14px; }
.stat b { display: block; font-size: 28px; font-weight: 650; line-height: 1.2; }
.stat span { font-size: 13px; color: var(--ink-2); }
.legend { display: flex; flex-wrap: wrap; gap: 6px 18px; font-size: 13px; color: var(--ink-2); }
.legend span { display: inline-flex; align-items: center; gap: 7px; }
.sw { width: 10px; height: 10px; border-radius: 3px; display: inline-block; }
.sw.s1 { background: var(--s1); } .sw.s2 { background: var(--s2); } .sw.s3 { background: var(--s3); }
.lg-line { width: 18px; height: 2px; background: var(--s1); }
.lg-dash { width: 18px; height: 0; border-top: 2px dashed var(--muted); }
.lg-true, .lg-false, .lg-miss { width: 11px; height: 11px; border-radius: 50%; }
.lg-true { background: var(--good); }
.lg-false { border: 2px solid var(--warning); }
.lg-miss { background: var(--critical); border-radius: 2px; transform: rotate(45deg) scale(.85); }
.chart { width: 100%; height: 300px; position: relative; }
.chart svg { display: block; width: 100%; height: 100%; overflow: visible; }
.chart text { font: 11px var(--sans); fill: var(--muted); font-variant-numeric: tabular-nums; }

.dash-head { display: grid; grid-template-columns: 1fr auto; gap: 20px; align-items: start; }
.dash-head > div:first-child { display: grid; gap: 10px; }
.dash-head p { color: var(--ink-2); font-size: 15px; max-width: 70ch; }
.dash-head h3 { font-size: 21px; }
.dash-links { display: grid; gap: 8px; justify-items: stretch; max-width: 240px; }
.dash-links small { color: var(--muted); font-size: 12.5px; line-height: 1.4; }
.panel { background: var(--surface-2); border-radius: 12px; padding: 18px; display: grid; gap: 14px; align-content: start; min-width: 0; }
.panel figcaption { display: grid; gap: 2px; }
.panel figcaption b { font-size: 15px; }
.panel figcaption span { font-size: 13px; color: var(--ink-2); }

.hbars, .gbars, .meters { display: grid; gap: 12px; }
.hbar { display: grid; grid-template-columns: 92px 1fr 86px; gap: 10px; align-items: center; font-size: 13.5px; cursor: default; }
.hbar .lab-t { display: flex; align-items: center; gap: 7px; color: var(--ink-2); }
.hbar .ico { font-size: 11px; width: 12px; text-align: center; }
.track { height: 14px; border-radius: 4px; background: color-mix(in srgb, var(--grid) 70%, transparent); overflow: hidden; }
.fill { height: 100%; border-radius: 0 4px 4px 0; width: 0; transition: width .6s cubic-bezier(.2,.7,.2,1); }
.hbar .val { text-align: right; font-variant-numeric: tabular-nums; color: var(--ink); }
.hbar .val small { color: var(--muted); margin-left: 4px; }
.hbar:hover .track, .grow:hover .track { outline: 1px solid var(--axis); }
.r-Low { background: var(--good); } .r-Moderate { background: var(--warning); } .r-High { background: var(--serious); } .r-Extreme { background: var(--critical); }

.hist { display: flex; align-items: flex-end; gap: 2px; height: 170px; border-bottom: 1px solid var(--axis); }
.hist .col { flex: 1; display: flex; flex-direction: column; justify-content: flex-end; align-items: center; height: 100%; gap: 4px; }
.hist .col i { display: block; width: 100%; max-width: 44px; background: var(--s1); border-radius: 4px 4px 0 0; height: 0; transition: height .6s cubic-bezier(.2,.7,.2,1); }
.hist .col:hover i { filter: brightness(1.2); }
.hist .col span { font-size: 11px; color: var(--muted); font-variant-numeric: tabular-nums; }
.hist-axis { display: flex; justify-content: space-between; font-size: 11px; color: var(--muted); margin-top: -8px; }

.grow { display: grid; grid-template-columns: 92px 1fr; gap: 10px; align-items: center; font-size: 13.5px; }
.grow .pair { display: grid; gap: 2px; }
.grow .line { display: grid; grid-template-columns: 1fr 48px; gap: 8px; align-items: center; }
.grow .track { height: 9px; }
.grow .fill.c { background: var(--s1); } .grow .fill.l { background: var(--s2); }
.grow .v { font-size: 12.5px; text-align: right; font-variant-numeric: tabular-nums; color: var(--ink-2); }
.meter { display: grid; gap: 6px; font-size: 13.5px; }
.meter .top { display: flex; justify-content: space-between; gap: 10px; color: var(--ink-2); }
.meter .top b { color: var(--ink); font-variant-numeric: tabular-nums; }
.meter .fill { background: var(--s1); }
.meter .track { height: 9px; }

.tbl summary { cursor: pointer; font-size: 13.5px; color: var(--accent-ink); }
.tbl table { border-collapse: collapse; margin-top: 12px; font-size: 13.5px; width: 100%; max-width: 640px; }
.tbl th, .tbl td { text-align: right; padding: 6px 10px; border-bottom: 1px solid var(--grid); font-variant-numeric: tabular-nums; }
.tbl th:first-child, .tbl td:first-child { text-align: left; }
.tbl th { color: var(--ink-2); font-weight: 600; }
.tbl div { overflow-x: auto; }

/* ---------- atlas ---------- */
.atlas-body { display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 8fr); gap: 14px 20px; align-items: start; }
.steps { grid-column: 1 / -1; display: flex; gap: 6px; flex-wrap: wrap; }
.steps button { flex: 1 1 110px; display: grid; gap: 2px; text-align: left; border: 1px solid var(--border); background: var(--surface-2); border-radius: 10px; padding: 10px 12px; font-size: 14.5px; font-weight: 600; color: var(--ink-2); }
.steps button span { font: 500 11px var(--mono); color: var(--muted); }
.steps button:hover { background: var(--raise); }
.steps button.is-on { border-color: var(--accent); background: var(--accent-wash); color: var(--ink); }
.steps button.is-on span { color: var(--accent-ink); }
.step-panel { display: grid; gap: 8px; align-content: start; padding: 6px 2px; }
.step-panel h4 { margin: 0; font-size: 19px; }
.step-panel p { color: var(--ink-2); font-size: 15px; }
.atlas img { width: 100%; height: auto; border-radius: 10px; border: 1px solid var(--border); display: block; }

/* ---------- timeline ---------- */
.tl { display: grid; gap: 8px; margin-top: 14px; }
.tl-row { display: grid; grid-template-columns: 190px 1fr; gap: 12px; align-items: center; font-size: 13.5px; }
.tl-row .name { color: var(--ink-2); line-height: 1.3; }
.tl-track { position: relative; height: 22px; background-image: linear-gradient(to right, var(--grid) 1px, transparent 1px); background-size: calc(100% / 6.2) 100%; }
.tl-seg { position: absolute; top: 2px; bottom: 2px; border-radius: 4px; border: 0; padding: 0; box-shadow: 0 0 0 1px var(--surface); min-width: 4px; }
.tl-seg:hover, .tl-seg:focus-visible { filter: brightness(1.2); }
.tl-seg.k1 { background: var(--s1); } .tl-seg.k2 { background: var(--s2); } .tl-seg.k3 { background: var(--s3); }
.tl-axis { position: relative; height: 18px; font-size: 11px; color: var(--muted); font-variant-numeric: tabular-nums; }
.tl-axis span { position: absolute; transform: translateX(-50%); }

/* ---------- skills, lists, form ---------- */
.tags { display: flex; flex-wrap: wrap; gap: 8px; }
.tag { font-size: 13.5px; padding: 6px 11px; border-radius: 999px; background: var(--surface-2); border: 1px solid var(--border); color: var(--ink); transition: opacity .2s, transform .2s; }
.tag.dim { opacity: .22; }
.list { list-style: none; padding: 0; display: grid; gap: 12px; margin-top: 14px; }
.list li { display: grid; gap: 2px; font-size: 14.5px; }
.list li span { color: var(--ink-2); font-size: 13.5px; }
.form { display: grid; gap: 14px; }
.form label { display: grid; gap: 6px; font-size: 13.5px; color: var(--ink-2); }
.form input:not([type=checkbox]), .form textarea { font: inherit; color: var(--ink); background: var(--surface-2); border: 1px solid var(--border); border-radius: 9px; padding: 10px 12px; width: 100%; }
.form fieldset { border: 0; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 8px 18px; }
.form legend { font-size: 13.5px; color: var(--ink-2); margin-bottom: 8px; padding: 0; }
.form .ck { display: inline-flex; grid-template-columns: none; align-items: center; gap: 8px; color: var(--ink); }
.form .ck input { accent-color: var(--accent); width: 16px; height: 16px; }
.form .btn { justify-self: start; border: 0; }
.contact-side { display: grid; gap: 14px; align-content: start; justify-items: start; }
.contact-side p { color: var(--ink-2); }
.links { margin-top: 4px; }

/* ---------- tooltip ---------- */
.tip { position: fixed; z-index: 60; pointer-events: none; background: var(--raise); color: var(--ink); border: 1px solid var(--border); border-radius: 9px; padding: 8px 11px; font-size: 13px; line-height: 1.45; max-width: 280px; box-shadow: 0 8px 24px rgba(0,0,0,.35); }
.tip b { display: block; }
.tip span { color: var(--ink-2); }

/* ---------- motion: load, scroll reveal, hover ---------- */
@keyframes rise2 { from { opacity: 0; transform: translateY(22px); } }
@keyframes growx { from { transform: scaleX(0); opacity: 0; } }
@keyframes growy { from { transform: scaleY(0); } }
@keyframes pop { from { transform: scale(0); opacity: 0; } 60% { transform: scale(1.35); } }
@keyframes draw { to { stroke-dashoffset: 0; } }
@keyframes fadein { from { opacity: 0; } }
@keyframes sheen { to { transform: translateX(520%) skewX(-20deg); } }
@keyframes pulse { 50% { box-shadow: 0 0 0 6px transparent; } }

/* on load */
.hero > * { animation: rise2 .7s cubic-bezier(.2,.7,.2,1) backwards; }
.hero > :nth-child(2), .hero > :nth-child(3) { animation-delay: .08s; }
.hero > :nth-child(4), .hero > :nth-child(5) { animation-delay: .18s; }
.hero > .cta { animation-delay: .28s; }
.hero > .context { animation-delay: .36s; }
.hero > .tiles { animation: none; }
.hero .tile { animation: rise2 .6s cubic-bezier(.2,.7,.2,1) backwards; }
.hero .tile:nth-child(1) { animation-delay: .42s; } .hero .tile:nth-child(2) { animation-delay: .49s; }
.hero .tile:nth-child(3) { animation-delay: .56s; } .hero .tile:nth-child(4) { animation-delay: .63s; }
.hero .tile:nth-child(5) { animation-delay: .70s; } .hero .tile:nth-child(6) { animation-delay: .77s; }
.side .nav a { animation: fadein .5s backwards; }
.side .nav a:nth-child(2) { animation-delay: .05s; } .side .nav a:nth-child(3) { animation-delay: .1s; }
.side .nav a:nth-child(4) { animation-delay: .15s; } .side .nav a:nth-child(5) { animation-delay: .2s; }
.side .nav a:nth-child(6) { animation-delay: .25s; } .side .nav a:nth-child(7) { animation-delay: .3s; }
.side .nav a:nth-child(8) { animation-delay: .35s; }
.brand-mark i { transform-origin: bottom; animation: growy .6s cubic-bezier(.2,.9,.3,1.4) backwards; }
.brand-mark i:nth-child(2) { animation-delay: .12s; } .brand-mark i:nth-child(3) { animation-delay: .24s; }
.brand:hover .brand-mark i { animation-name: none; }
.brand-mark i { transition: transform .3s cubic-bezier(.2,.9,.3,1.4); }
.brand:hover .brand-mark i { transform: scaleY(1.25); }
.brand:hover .brand-mark i:nth-child(2) { transition-delay: .06s; } .brand:hover .brand-mark i:nth-child(3) { transition-delay: .12s; }
.dot { box-shadow: 0 0 0 0 var(--good); animation: pulse 2.4s infinite; }
span[data-lens-text]:not([hidden]) { animation: fadein .5s; }

/* hero photo */
.hero > .hero-top { animation: none; display: grid; grid-template-columns: minmax(0, 1fr) minmax(200px, 290px); gap: clamp(24px, 4vw, 56px); align-items: center; }
.hero-text { display: grid; gap: 22px; min-width: 0; }
.hero-text > * { animation: rise2 .7s cubic-bezier(.2,.7,.2,1) backwards; }
.hero-text > :nth-child(2), .hero-text > :nth-child(3) { animation-delay: .08s; }
.hero-text > :nth-child(4), .hero-text > :nth-child(5) { animation-delay: .18s; }
.hero-text > .cta { animation-delay: .28s; }
.hero-text > .context { animation-delay: .36s; }
.hero-photo { position: relative; aspect-ratio: 62 / 100; border-radius: 18px; overflow: hidden; border: 1px solid var(--border); background: var(--surface-2); box-shadow: var(--shadow), 0 30px 60px -30px var(--accent); animation: rise2 .9s cubic-bezier(.2,.7,.2,1) .25s backwards; }
.hero-photo img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .8s cubic-bezier(.2,.7,.2,1); }
.hero-photo:hover img { transform: scale(1.04); }
.hero-photo figcaption { position: absolute; inset: auto 0 0 0; padding: 48px 16px 14px; display: grid; gap: 1px; color: #fff; background: linear-gradient(to top, rgba(0,0,0,.72), transparent); }
.hero-photo figcaption b { font-size: 15px; }
.hero-photo figcaption span { font: 500 11px var(--mono); letter-spacing: .06em; text-transform: uppercase; opacity: .85; }
@media (max-width: 900px) {
  .hero > .hero-top { grid-template-columns: 1fr; }
  .hero-photo { order: -1; width: min(210px, 55%); }
}

/* scroll reveal (classes are added by app.js) */
.rv { opacity: 0; }
.rv.in { opacity: 1; animation: rise2 .65s cubic-bezier(.2,.7,.2,1) backwards; animation-delay: var(--d, 0s); }
.chart:not(.seen) svg { visibility: hidden; }
.chart.draw .ln { animation: draw 1.8s ease-out forwards; }
.chart.draw .mk { transform-box: fill-box; transform-origin: center; animation: pop .45s backwards; animation-delay: 1.5s; }
.chart.draw .mkd { animation: fadein .45s backwards; animation-delay: 1.5s; }
.tl:not(.in) .tl-seg { opacity: 0; }
.tl.in .tl-seg { transform-origin: left; animation: growx .7s cubic-bezier(.2,.7,.2,1) backwards; animation-delay: calc(var(--r, 0) * 90ms + var(--s, 0) * 120ms); }

/* hover */
.tile, .panel, .stat, .work { background-repeat: no-repeat; transition: transform .2s cubic-bezier(.2,.7,.2,1), border-color .2s, box-shadow .2s; }
.tile:hover, .work:hover, .panel:hover, .stat:hover { background-image: radial-gradient(280px circle at var(--mx, 50%) var(--my, 0%), var(--accent-wash), transparent 70%); }
.tile:hover { transform: translateY(-4px); border-color: color-mix(in srgb, var(--accent) 55%, var(--border)); }
.tile-v span { display: inline-block; transition: transform .25s cubic-bezier(.2,.9,.3,1.4), color .2s; transform-origin: left bottom; }
.tile:hover .tile-v span { transform: scale(1.1); color: var(--accent-ink); }
.work:hover { transform: translateY(-5px); box-shadow: var(--shadow), 0 18px 40px -18px var(--accent); }
.work .chip { transition: transform .25s; }
.work:hover .chip { transform: translateX(4px); }
.work h3 { transition: color .2s; }
.work:hover h3 { color: var(--accent-ink); }
.stat b { transition: transform .25s cubic-bezier(.2,.9,.3,1.4); transform-origin: left bottom; }
.stat:hover b { transform: scale(1.08); }
.nav a { transition: transform .18s, background .18s, color .18s; }
.nav a:hover { transform: translateX(4px); }
.btn { position: relative; overflow: hidden; }
.btn.primary::after { content: ""; position: absolute; top: 0; bottom: 0; left: -50%; width: 40%; background: linear-gradient(90deg, transparent, rgba(255,255,255,.35), transparent); transform: skewX(-20deg); }
.btn.primary:hover::after { animation: sheen .7s; }
.btn:hover { transform: translateY(-2px); box-shadow: 0 8px 20px -10px var(--accent); }
.btn:active { transform: translateY(0) scale(.98); }
.icon-btn svg { transition: transform .4s cubic-bezier(.2,.9,.3,1.4); }
.icon-btn:hover svg { transform: rotate(-35deg) scale(1.15); }
.seg button { transition: background .2s, color .2s, box-shadow .2s; }
.fit-list button { transition: background .18s, color .18s, transform .18s; }
.fit-list button:hover { transform: translateX(3px); }
.fit-list .n { transition: transform .2s, color .2s; }
.fit-list button:hover .n { transform: scale(1.08); color: var(--accent-ink); }
.ev li { transition: transform .2s, border-color .2s; }
.ev li:hover { transform: translateX(4px); border-color: color-mix(in srgb, var(--accent) 50%, var(--border)); }
.steps button { transition: transform .2s, background .2s, border-color .2s; }
.steps button:hover { transform: translateY(-3px); }
.step-panel > * { animation: rise .35s both; }
.hbar, .grow { transition: transform .2s; }
.hbar:hover, .grow:hover { transform: translateX(4px); }
.fill { transition: width .6s cubic-bezier(.2,.7,.2,1), filter .2s; }
.hbar:hover .fill, .grow:hover .fill, .meter:hover .fill { filter: brightness(1.2) saturate(1.15); }
.hist .col i { transform-origin: bottom; transition: height .6s cubic-bezier(.2,.7,.2,1), transform .2s cubic-bezier(.2,.9,.3,1.4), filter .2s; }
.hist .col:hover i { transform: scaleY(1.05) scaleX(1.06); }
.hist .col span { transition: color .2s, transform .2s; }
.hist .col:hover span { color: var(--ink); transform: translateY(-3px); }
.tl-seg { transition: transform .18s cubic-bezier(.2,.9,.3,1.4), filter .18s; }
.tl-seg:hover, .tl-seg:focus-visible { transform: scaleY(1.3); }
.tl-row .name { transition: color .2s; }
.tl-row:hover .name { color: var(--ink); }
.tag { cursor: default; }
.tag:not(.dim):hover { transform: translateY(-3px); border-color: var(--accent); background: var(--accent-wash); }
.atlas img { transition: transform .5s cubic-bezier(.2,.7,.2,1), box-shadow .3s; }
.atlas img:hover { transform: scale(1.02); box-shadow: 0 18px 40px -16px rgba(0,0,0,.6); }
.list.links a { display: inline-block; transition: transform .18s; }
.list.links a:hover { transform: translateX(4px); }

/* ---------- responsive ---------- */
@media (max-width: 1180px) {
  .tiles { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .g3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 900px) {
  .side { position: sticky; top: 0; inset: auto; width: auto; flex-direction: row; align-items: center; gap: 14px; padding: 8px 16px; border-right: 0; border-bottom: 1px solid var(--border); overflow: hidden; }
  .side-foot, .brand small { display: none; }
  .brand-mark { width: 30px; height: 30px; padding: 6px 0; }
  .brand strong { white-space: nowrap; font-size: 14px; }
  .nav { flex-direction: row; overflow-x: auto; scrollbar-width: none; min-width: 0; }
  .nav::-webkit-scrollbar { display: none; }
  .nav a { padding: 7px 10px; font-size: 13.5px; }
  .nav a span { display: none; }
  .main { margin-left: 0; }
  .topbar { position: static; }
  html { scroll-padding-top: 60px; }
  .fit { grid-template-columns: 1fr; }
  .fit-list { border-right: 0; border-bottom: 1px solid var(--border); }
  .g2, .atlas-body { grid-template-columns: 1fr; }
  .dash-head { grid-template-columns: 1fr; }
  .dash-links { max-width: none; grid-auto-flow: row; justify-items: start; }
}
@media (max-width: 640px) {
  section { padding-top: 48px; }
  .card { padding: 16px; }
  .tiles, .tiles.mini { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .tile-v { font-size: 28px; }
  .g3 { grid-template-columns: 1fr; }
  .lens-label, .icon-btn span { display: none; }
  .seg button { padding: 7px 9px; font-size: 12.5px; }
  .stat b { font-size: 22px; }
  .tl-row { grid-template-columns: 1fr; gap: 3px; }
  .tl-axis-row .name { display: none; }
  .hbar { grid-template-columns: 84px 1fr 74px; }
  .chart { height: 240px; }
  .ev li { grid-template-columns: 1fr; gap: 4px; }
  .ev .where { width: auto; }
  .fit-detail { padding: 16px; }
}
@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; }
  html { scroll-behavior: auto; }
}
@media print {
  .side, .topbar, .tip { display: none; }
  .main { margin: 0; }
}
