@import url("https://fonts.googleapis.com/css2?family=Anybody:wdth,wght@50..150,300..900&family=Hanken+Grotesk:ital,wght@0,400;0,500;0,600;0,700;1,400&display=swap");

:root {
  --fog: #f2f3f8;
  --paper: #fbfbfe;
  --ink: #10142e;
  --slate: #545b78;
  --hair: #d8dbe8;
  --ultra: #3a2bff;
  --ultra-soft: #e6e3ff;
  --night: #0f1330;
  --night-2: #181d44;
  --night-line: #2c3268;
  --found: #ffe14d;
  --mint: #3ee0b5;
  --display: "Anybody", "Hanken Grotesk", system-ui, sans-serif;
  --body: "Hanken Grotesk", system-ui, sans-serif;
  --measure: 64ch;
  --ease: cubic-bezier(.2, .8, .2, 1);
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body { margin: 0; background: var(--fog); color: var(--ink); font: 400 1.0625rem/1.62 var(--body); }
a { color: var(--ultra); text-underline-offset: .2em; text-decoration-thickness: 1.5px; }
:focus-visible { outline: 3px solid var(--ultra); outline-offset: 3px; border-radius: 3px; }
img, svg { display: block; max-width: 100%; }
.wrap { max-width: 1160px; margin: 0 auto; padding: 0 1.25rem; }
p, li { max-width: var(--measure); }

/* ---------- top ---------- */
header.top { position: sticky; top: 0; z-index: 20; backdrop-filter: saturate(1.4) blur(14px); -webkit-backdrop-filter: saturate(1.4) blur(14px); background: color-mix(in srgb, var(--fog) 78%, transparent); border-bottom: 1px solid transparent; transition: border-color .3s; }
header.top.scrolled { border-bottom-color: var(--hair); }
header.top .wrap { display: flex; align-items: center; justify-content: space-between; gap: 1rem; height: 64px; }
.wordmark { display: inline-flex; align-items: center; gap: .55rem; font: 800 1.35rem/1 var(--display); font-stretch: 118%; letter-spacing: -.01em; color: var(--ink); text-decoration: none; }
.wordmark .glyph { width: 26px; height: 26px; }
header.top nav { display: flex; gap: 1.4rem; align-items: center; }
header.top nav a { color: var(--slate); text-decoration: none; font-weight: 500; font-size: .95rem; }
header.top nav a:hover { color: var(--ink); }
header.top nav a.cta { color: var(--paper); background: var(--ink); padding: .5rem .95rem; border-radius: 999px; }
@media (max-width: 720px) { header.top nav a:not(.cta) { display: none; } }

/* ---------- type ---------- */
h1, h2, h3 { font-family: var(--display); letter-spacing: -.02em; margin: 0; }
h1 { font-weight: 800; font-size: clamp(2.6rem, 6.6vw, 5.4rem); line-height: .98; font-stretch: 112%; }
h2 { font-weight: 750; font-size: clamp(1.9rem, 3.8vw, 3rem); line-height: 1.02; font-stretch: 108%; margin-bottom: 1rem; }
h3 { font-weight: 700; font-size: 1.2rem; line-height: 1.2; font-stretch: 104%; margin-bottom: .35rem; }
.lede { font-size: clamp(1.1rem, 1.6vw, 1.3rem); color: var(--slate); max-width: 44ch; margin: 1.5rem 0 2rem; }
.kicker { color: var(--slate); max-width: 56ch; }

/* ---------- hero ---------- */
.hero { padding: 4.5rem 0 3rem; display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr); gap: 3rem; align-items: center; }
@media (max-width: 920px) { .hero { grid-template-columns: 1fr; padding-top: 2.5rem; } }
.hero h1 .stretch { display: inline-block; color: var(--ultra); font-stretch: 50%; transition: font-stretch 1.6s var(--ease); }
.hero.ready h1 .stretch { font-stretch: 150%; }
.hero .actions { display: flex; flex-wrap: wrap; gap: .75rem; align-items: center; }
.btn { display: inline-flex; align-items: center; gap: .5rem; font: 600 1rem var(--body); padding: .85rem 1.3rem; border-radius: 999px; text-decoration: none; border: 1.5px solid var(--ink); color: var(--ink); background: transparent; transition: transform .2s var(--ease), background .2s; }
.btn.primary { background: var(--ultra); border-color: var(--ultra); color: #fff; }
.btn:hover { transform: translateY(-2px); }

/* The engine at work: a back catalogue scanned, lines found, a new short assembled, read at day 7. */
.engine { position: relative; background: radial-gradient(120% 90% at 20% 0%, var(--night-2), var(--night) 60%); border-radius: 28px; padding: 1.4rem; color: #e9ebff; min-height: 540px; overflow: hidden; box-shadow: 0 40px 80px -40px rgba(24, 20, 90, .55); }
.engine .label { font-size: .8rem; color: #9aa0d6; }
.catalogue { position: relative; display: grid; grid-auto-flow: column; grid-auto-columns: 132px; gap: 10px; overflow: hidden; mask-image: linear-gradient(90deg, transparent, #000 10%, #000 90%, transparent); margin: .6rem 0 0; }
.catalogue .track { display: flex; gap: 10px; width: max-content; animation: drift 40s linear infinite; }
.clip { width: 132px; height: 74px; border-radius: 10px; background: var(--night-2); border: 1px solid var(--night-line); padding: 8px; display: flex; flex-direction: column; justify-content: space-between; flex: none; }
.clip .wave { display: flex; align-items: center; gap: 2px; height: 30px; }
.clip .wave i { flex: 1; background: #5a61a8; border-radius: 2px; }
.clip .ts { font-size: .7rem; color: #7d84c2; }
.clip.hit { border-color: var(--found); }
.clip.hit .wave i { background: var(--found); }
.clip.hit .ts { color: var(--found); }
@keyframes drift { to { transform: translateX(-50%); } }
.scan { position: absolute; top: 0; bottom: 0; width: 2px; left: 12%; background: linear-gradient(transparent, var(--mint), transparent); box-shadow: 0 0 18px var(--mint); animation: scan 5.5s var(--ease) infinite alternate; }
@keyframes scan { to { left: 86%; } }

.assembly { display: grid; grid-template-columns: 190px minmax(0, 1fr); gap: 1.2rem; margin-top: 1.4rem; align-items: start; }
@media (max-width: 520px) { .assembly { grid-template-columns: 1fr; } .phone { margin: 0 auto; } }
.phone { width: 190px; aspect-ratio: 9 / 16; border-radius: 26px; background: linear-gradient(160deg, #262d6b, #11163a); border: 6px solid #05071a; position: relative; overflow: hidden; }
.phone .scene { position: absolute; inset: 0; background: radial-gradient(70% 45% at 50% 38%, rgba(62, 224, 181, .35), transparent 70%), radial-gradient(60% 40% at 40% 80%, rgba(58, 43, 255, .45), transparent 70%); }
.phone .cap { position: absolute; left: 10px; right: 10px; bottom: 26%; text-align: center; font: 800 1.02rem/1.15 var(--display); font-stretch: 120%; text-transform: none; color: #fff; text-shadow: 0 2px 0 #000, 0 0 12px rgba(0, 0, 0, .6); }
.phone .cap span { opacity: .18; transition: opacity .25s, color .25s; }
.phone .cap span.on { opacity: 1; }
.phone .cap span.now { color: var(--found); }
.phone .bar { position: absolute; left: 10px; right: 10px; bottom: 12px; height: 3px; background: rgba(255, 255, 255, .2); border-radius: 3px; overflow: hidden; }
.phone .bar i { display: block; height: 100%; width: 0; background: #fff; }
.phone.play .bar i { animation: fill 6s linear infinite; }
@keyframes fill { to { width: 100%; } }
.lines { list-style: none; margin: 0; padding: 0; display: grid; gap: .55rem; }
.lines li { font-size: .92rem; background: rgba(255, 255, 255, .04); border: 1px solid var(--night-line); border-radius: 12px; padding: .6rem .75rem; color: #c9cdf5; transform: translateX(14px); opacity: 0; transition: transform .6s var(--ease), opacity .6s var(--ease), border-color .4s; }
.lines li.in { transform: none; opacity: 1; }
.lines li.lit { border-color: var(--found); color: #fff; }
.lines li .t { color: var(--found); font-variant-numeric: tabular-nums; margin-right: .4rem; font-weight: 600; }
.day7 { margin-top: .8rem; background: var(--paper); color: var(--ink); border-radius: 14px; padding: .8rem .9rem; transform: translateY(18px) scale(.98); opacity: 0; transition: transform .7s var(--ease), opacity .7s var(--ease); }
.day7.in { transform: none; opacity: 1; }
.day7 .head { display: flex; justify-content: space-between; font-size: .8rem; color: var(--slate); margin-bottom: .45rem; }
.meter { display: grid; grid-template-columns: 5.2rem minmax(0, 1fr) 2.8rem; align-items: center; gap: .5rem; font-size: .82rem; margin: .25rem 0; }
.meter .track2 { height: 7px; background: var(--ultra-soft); border-radius: 7px; overflow: hidden; }
.meter .track2 i { display: block; height: 100%; width: 0; background: var(--ultra); border-radius: 7px; transition: width 1.2s var(--ease); }
.meter b { text-align: right; font-variant-numeric: tabular-nums; }

/* ---------- sections ---------- */
section.band { padding: 6rem 0; }
section.band.night { background: var(--night); color: #e9ebff; }
section.band.night .kicker, section.band.night p { color: #b7bbe6; }
section.band.night a { color: var(--found); }
.split { display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); gap: 4rem; align-items: start; }
@media (max-width: 920px) { .split { grid-template-columns: 1fr; gap: 2rem; } }

/* how it works: a sticky picture that changes with the step in view */
.flow { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 4rem; margin-top: 2.5rem; }
@media (max-width: 920px) { .flow { grid-template-columns: 1fr; } .flow .stage { display: none; } }
.flow .steps { list-style: none; padding: 0; margin: 0; counter-reset: s; }
.flow .steps li { counter-increment: s; padding: 2.2rem 0 2.2rem 3.4rem; border-top: 1px solid var(--night-line); position: relative; opacity: .45; transition: opacity .5s var(--ease); max-width: none; }
.flow .steps li.active { opacity: 1; }
.flow .steps li::before { content: counter(s); position: absolute; left: 0; top: 2.15rem; width: 2.2rem; height: 2.2rem; border-radius: 50%; display: grid; place-items: center; font: 700 1rem var(--display); border: 1.5px solid var(--night-line); color: #9aa0d6; transition: all .5s var(--ease); }
.flow .steps li.active::before { background: var(--found); border-color: var(--found); color: var(--night); }
.flow .steps h3 { color: #fff; font-size: 1.45rem; }
.flow .stage { position: sticky; top: 110px; height: 420px; border-radius: 24px; background: var(--night-2); border: 1px solid var(--night-line); overflow: hidden; }
.flow .stage .pane { position: absolute; inset: 0; padding: 1.8rem; opacity: 0; transform: translateY(16px); transition: opacity .6s var(--ease), transform .6s var(--ease); }
.flow .stage .pane.on { opacity: 1; transform: none; }
.pane .row { display: flex; justify-content: space-between; gap: 1rem; padding: .7rem 0; border-bottom: 1px solid var(--night-line); font-size: .95rem; color: #d7daf8; }
.pane .row b { color: var(--found); font-weight: 600; }
.pane .big { font: 800 2.2rem/1.05 var(--display); font-stretch: 115%; color: #fff; margin: .4rem 0 1rem; }
.pane .chip { display: inline-block; font-size: .8rem; padding: .25rem .6rem; border-radius: 999px; border: 1px solid var(--night-line); color: #b7bbe6; margin: 0 .35rem .35rem 0; }
.pane .chip.hot { border-color: var(--found); color: var(--found); }

/* the Monday page */
.report { background: var(--paper); border: 1px solid var(--hair); border-radius: 24px; padding: 1.6rem; box-shadow: 0 30px 60px -45px rgba(16, 20, 46, .45); }
.report .top-row { display: flex; justify-content: space-between; align-items: baseline; gap: 1rem; flex-wrap: wrap; }
.report .sample { font-size: .8rem; color: var(--slate); border: 1px dashed var(--hair); padding: .2rem .55rem; border-radius: 999px; }
.report table { width: 100%; border-collapse: collapse; margin-top: 1rem; font-size: .95rem; }
.report th, .report td { text-align: left; padding: .7rem .5rem .7rem 0; border-bottom: 1px solid var(--hair); vertical-align: middle; }
.report th { font-weight: 600; color: var(--slate); font-size: .85rem; }
.report td.num { font-variant-numeric: tabular-nums; font-weight: 600; }
.report .spark { height: 8px; background: var(--ultra-soft); border-radius: 8px; overflow: hidden; min-width: 90px; }
.report .spark i { display: block; height: 100%; width: 0; background: var(--ultra); transition: width 1.3s var(--ease); }
.report .won { background: var(--found); padding: .05rem .4rem; border-radius: 6px; font-size: .8rem; font-weight: 600; }
.report .next { margin-top: 1rem; font-size: .98rem; }

/* principles */
.principles { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 2.5rem; margin-top: 2.5rem; }
@media (max-width: 820px) { .principles { grid-template-columns: 1fr; } }
.principles div { border-top: 3px solid var(--ink); padding-top: 1rem; }
.principles p { color: var(--slate); margin: .3rem 0 0; }

/* access table */
table.access { border-collapse: collapse; width: 100%; font-size: .96rem; margin: 1.5rem 0 1rem; }
table.access th, table.access td { text-align: left; vertical-align: top; padding: .9rem 1rem .9rem 0; border-bottom: 1px solid var(--hair); }
table.access th { font-weight: 600; color: var(--slate); font-size: .88rem; }
table.access code { font-size: .82em; background: var(--ultra-soft); color: var(--ink); padding: .1rem .35rem; border-radius: 5px; line-height: 2; }
@media (max-width: 720px) { table.access thead { display: none; } table.access td { display: block; padding: .25rem 0; border: 0; } table.access tr { display: block; padding: .9rem 0; border-bottom: 1px solid var(--hair); } }

/* who */
.who { display: grid; grid-template-columns: 120px minmax(0, 1fr); gap: 2rem; align-items: start; }
.who .mono { width: 120px; height: 120px; border-radius: 28px; background: var(--ink); display: grid; place-items: center; }
@media (max-width: 560px) { .who { grid-template-columns: 1fr; } }

/* reveal on scroll */
.reveal { opacity: .35; transform: translateY(28px); transition: opacity .9s var(--ease), transform .9s var(--ease); }
.reveal.in { opacity: 1; transform: none; }
@supports (animation-timeline: view()) {
  .rise { animation: rise linear both; animation-timeline: view(); animation-range: entry 0% cover 30%; }
  @keyframes rise { from { opacity: .35; transform: translateY(14px); } }
}

/* ---------- documents ---------- */
.doc { padding: 3.5rem 0 2rem; max-width: 760px; }
.doc h1 { font-size: clamp(2.2rem, 5vw, 3.4rem); font-stretch: 110%; margin-bottom: .6rem; }
.doc h2 { font-size: 1.45rem; font-stretch: 104%; margin: 2.4rem 0 .6rem; }
.doc h3 { font-size: 1.1rem; margin-top: 1.4rem; }
.doc .updated { color: var(--slate); }
.doc .steps { list-style: none; padding: 0; counter-reset: s; }
.doc .steps li { counter-increment: s; position: relative; padding-left: 2.6rem; margin-bottom: 1.1rem; }
.doc .steps li::before { content: counter(s); position: absolute; left: 0; top: .1rem; width: 1.8rem; height: 1.8rem; border-radius: 50%; background: var(--ultra); color: #fff; display: grid; place-items: center; font: 700 .9rem var(--display); }
.doc .steps b { display: block; }
.caption { color: var(--slate); font-size: .9rem; }

.codebox { background: var(--paper); border: 1px solid var(--hair); border-radius: 18px; padding: 1.4rem; max-width: 640px; }
.codebox output { display: block; font: 600 1.05rem/1.5 ui-monospace, SFMono-Regular, Menlo, monospace; word-break: break-all; margin: .4rem 0 1rem; background: var(--ultra-soft); padding: .6rem .8rem; border-radius: 10px; }
button.copy { font: 600 1rem var(--body); background: var(--ultra); color: #fff; border: 0; border-radius: 999px; padding: .7rem 1.2rem; cursor: pointer; }

/* ---------- footer ---------- */
footer.bottom { background: var(--night); color: #b7bbe6; padding: 4rem 0 3rem; margin-top: 0; }
footer.bottom .cols { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 2rem; }
@media (max-width: 720px) { footer.bottom .cols { grid-template-columns: 1fr; } }
footer.bottom .wordmark { color: #fff; }
footer.bottom h4 { font: 700 1rem var(--display); color: #fff; margin: 0 0 .7rem; }
footer.bottom a { color: #d7daf8; text-decoration: none; display: block; margin: .3rem 0; }
footer.bottom a:hover { color: var(--found); }
footer.bottom .fine { margin-top: 3rem; font-size: .88rem; color: #7d84c2; }
footer.bottom.doc-foot { margin-top: 4rem; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .reveal, .lines li, .day7 { opacity: 1; transform: none; }
  .hero h1 .stretch { font-stretch: 150%; }
}
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
