/* ===== Tokens ===== */
:root {
  --ink: #02031d;
  --bg: #ffffff;
  --mist: #efeeee;
  --ash: #d5d5d4;
  --smoke: #a0a09f;
  --muted: #6e6e6d;
  --rule: #e0e0e0;
  --accent: #cbdd18;
  --font-sans: "Zalando Sans", "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-mono: "Geist Mono", ui-monospace, "SFMono-Regular", Consolas, monospace;
  --grid-max: 1440px;
  --margin: 40px;
  --gutter: 20px;
  --ease: cubic-bezier(.22, 1, .36, 1);
  --nav-h: 76px;
}
@media (max-width: 760px) {
  :root { --margin: 16px; --nav-h: 64px; }
}

/* ===== Base ===== */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-sans);
  font-weight: 400;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
h1, h2, h3, p { margin: 0; }
a { color: inherit; text-decoration: none; }
img, svg, canvas { display: block; }
::selection { background: var(--ink); color: #fff; }

.grid {
  width: 100%;
  max-width: var(--grid-max);
  margin: 0 auto;
  padding: 0 var(--margin);
}

.section { padding: 140px 0; }
.section--soft { background: var(--mist); }
@media (max-width: 760px) { .section { padding: 88px 0; } }

/* ===== Type ===== */
.label {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: #757574;
  margin-bottom: 28px;
  display: flex;
  align-items: center;
  gap: 10px;
}
.label::before { content: ""; width: 8px; height: 8px; background: currentColor; }
.label--light { color: rgba(255,255,255,.7); }

.display {
  font-size: clamp(36px, 5vw, 72px);
  font-weight: 400;
  line-height: 1.04;
  letter-spacing: -.03em;
  max-width: 18ch;
}
.display--light { color: #fff; }
.col-wide { max-width: 22ch; }
p.col-wide { max-width: 62ch; margin-top: 32px; }
.body-lg { font-size: clamp(17px, 1.4vw, 20px); line-height: 1.5; }
.muted { color: var(--muted); }

/* ===== Buttons ===== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 500;
  letter-spacing: .04em;
  text-transform: uppercase;
  padding: 11px 18px;
  border: 1px solid transparent;
  border-radius: 2px;
  cursor: pointer;
  transition: background .25s var(--ease), color .25s var(--ease), border-color .25s var(--ease);
  white-space: nowrap;
}
.btn--light { background: #fff; color: var(--ink); }
.btn--light:hover { background: var(--ash); }
.btn--ghost { background: rgba(255,255,255,.1); color: #fff; border-color: rgba(255,255,255,.2); backdrop-filter: blur(8px); }
.btn--ghost:hover { background: rgba(255,255,255,.2); }
.btn--dark { background: var(--ink); color: #fff; }
.btn--dark:hover { background: #686868; }
.btn--block { width: 100%; padding: 15px 18px; }

/* ===== Nav ===== */
.nav {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 50;
  color: #fff;
  transition: background .35s var(--ease), color .35s var(--ease), box-shadow .35s var(--ease);
}
.nav__inner {
  max-width: var(--grid-max);
  margin: 0 auto;
  padding: 0 var(--margin);
  height: var(--nav-h);
  display: flex;
  align-items: center;
  gap: 32px;
}
.nav.is-solid { background: rgba(255,255,255,.92); color: var(--ink); backdrop-filter: blur(12px); box-shadow: 0 1px 0 var(--rule); }
.nav.is-solid .btn--ghost { color: var(--ink); background: var(--mist); border-color: transparent; }
.nav.is-solid .btn--ghost:hover { background: var(--ash); }
.nav.is-solid .btn--light { background: var(--ink); color: #fff; }
.nav.is-solid .btn--light:hover { background: #686868; }

.logo { display: flex; align-items: center; gap: 12px; font-weight: 500; }
.logo__mark { width: 20px; height: 24px; fill: none; stroke: currentColor; stroke-width: 2.6; }
.logo__type { font-size: 17px; letter-spacing: -.01em; white-space: nowrap; }

.nav__links { display: flex; gap: 28px; margin-left: auto; }
.nav__links a {
  font-family: var(--font-mono);
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: .04em;
  opacity: .8;
  transition: opacity .2s;
}
.nav__links a:hover { opacity: 1; }
.nav__cta { display: flex; gap: 10px; }
.nav__menu {
  display: none;
  margin-left: auto;
  font-family: var(--font-mono);
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: .04em;
  background: none;
  border: 1px solid currentColor;
  color: inherit;
  padding: 8px 14px;
  border-radius: 2px;
  cursor: pointer;
}
.mobile-menu {
  background: var(--ink);
  color: #fff;
  padding: 16px var(--margin) 28px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.mobile-menu[hidden] { display: none; }
.mobile-menu a:not(.btn) { padding: 12px 0; font-size: 22px; border-bottom: 1px solid rgba(255,255,255,.12); }
.mobile-menu .btn { margin-top: 18px; }
@media (max-width: 980px) {
  .nav__links, .nav__cta { display: none; }
  .nav__menu { display: inline-block; }
  .logo__type { font-size: 15px; }
}

/* ===== Hero ===== */
.hero {
  position: relative;
  min-height: 100svh;
  background: var(--ink);
  color: #fff;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  overflow: hidden;
}
.hero__canvas { position: absolute; inset: 0; width: 100%; height: 100%; }
.hero__shade {
  position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(2,3,29,.55) 0%, rgba(2,3,29,0) 30%, rgba(2,3,29,0) 55%, rgba(2,3,29,.85) 100%);
  pointer-events: none;
}
.hero__content { position: relative; padding-top: 160px; padding-bottom: 120px; }
.hero__title {
  font-size: clamp(48px, 9vw, 144px);
  font-weight: 400;
  line-height: .95;
  letter-spacing: -.045em;
}
.hero__title-sub { color: rgba(255,255,255,.55); }
.hero__lead { max-width: 46ch; margin-top: 36px; font-size: clamp(17px, 1.5vw, 21px); color: rgba(255,255,255,.82); }
.hero__actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 40px; }

.hero__ticker {
  position: relative;
  border-top: 1px solid rgba(255,255,255,.14);
  padding: 18px 0;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: .08em;
  color: rgba(255,255,255,.55);
  white-space: nowrap;
  overflow: hidden;
}
.hero__track { display: flex; gap: 56px; padding-right: 56px; flex-shrink: 0; animation: ticker 40s linear infinite; }
.hero__ticker span::before { content: "■ "; color: var(--accent); }
@keyframes ticker { to { transform: translateX(-50%); } }

/* ===== Problem + diagram ===== */
.two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--gutter) 60px;
  margin-top: 48px;
  max-width: 1100px;
}
@media (max-width: 760px) { .two-col { grid-template-columns: 1fr; } }

.diagram {
  margin: 88px 0 0;
  display: grid;
  grid-template-columns: 1fr 80px 1fr;
  align-items: stretch;
  gap: 0;
}
.diagram__side {
  border: 1px solid var(--rule);
  padding: 32px;
  display: flex;
  flex-direction: column;
  gap: 28px;
}
.diagram__side--dark { background: var(--ink); color: #fff; border-color: var(--ink); }
.diagram__cap { font-family: var(--font-mono); font-size: 12px; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.diagram__side--dark .diagram__cap { color: rgba(255,255,255,.6); }
.diagram__arrow { display: grid; place-items: center; }
.diagram__arrow svg { width: 52px; fill: none; stroke: var(--ink); stroke-width: 1.5; }
.diagram__notes { list-style: none; margin: auto 0 0; padding: 0; display: grid; gap: 8px; font-size: 15px; }
.diagram__notes li::before { content: "— "; color: var(--smoke); }

.stack { display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px; }
.chip-box {
  font-family: var(--font-mono);
  font-size: 12px;
  border: 1px dashed var(--smoke);
  padding: 14px 12px;
  text-align: center;
  color: var(--muted);
  background: #fafafa;
}
.chip-box--row { grid-column: 1 / -1; display: grid; grid-template-columns: repeat(6, 1fr); gap: 6px; padding: 8px; }
.chip-box--row span { border: 1px solid var(--ash); padding: 6px 0; background: #fff; }
.chip-box--ghost { grid-column: 1 / -1; border-style: dotted; background: transparent; }

.asic { position: relative; margin: 14px auto; width: min(100%, 360px); aspect-ratio: 1; padding: 22px; }
.asic__pins {
  position: absolute; left: 22px; right: 22px; height: 14px;
  background: repeating-linear-gradient(90deg, rgba(255,255,255,.55) 0 6px, transparent 6px 16px);
}
.asic__pins--t { top: 8px; }
.asic__pins--b { bottom: 8px; }
.asic::before, .asic::after {
  content: ""; position: absolute; top: 22px; bottom: 22px; width: 14px;
  background: repeating-linear-gradient(180deg, rgba(255,255,255,.55) 0 6px, transparent 6px 16px);
}
.asic::before { left: 8px; }
.asic::after { right: 8px; }
.asic__die {
  position: relative;
  height: 100%;
  border: 1px solid rgba(255,255,255,.35);
  background: #0c0e33;
  padding: 12px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-template-rows: 1.4fr 1fr 1fr;
  gap: 8px;
}
.asic__block {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: .04em;
  border: 1px solid rgba(255,255,255,.22);
  display: grid;
  place-items: center;
  text-align: center;
  padding: 4px;
  color: rgba(255,255,255,.85);
  background: rgba(255,255,255,.03);
}
.asic__block--npu {
  grid-column: 1 / -1;
  color: var(--ink);
  background: var(--accent);
  border-color: var(--accent);
  font-weight: 500;
  animation: pulse 3.2s ease-in-out infinite;
}
@keyframes pulse { 50% { box-shadow: 0 0 0 6px rgba(203,221,24,.15), 0 0 40px rgba(203,221,24,.3); } }

@media (max-width: 900px) {
  .diagram { grid-template-columns: 1fr; }
  .diagram__arrow { height: 64px; }
  .diagram__arrow svg { transform: rotate(90deg); }
  .diagram__side { padding: 22px; }
}

/* ===== Statement ===== */
.statement__big {
  font-size: clamp(26px, 3.4vw, 50px);
  line-height: 1.15;
  letter-spacing: -.025em;
  max-width: 30ch;
}
.statement__big em { font-style: normal; background: linear-gradient(transparent 62%, var(--accent) 62%); }
.statement__tag { margin-top: 40px; font-family: var(--font-mono); font-size: 14px; text-transform: uppercase; letter-spacing: .08em; }
.stats {
  margin-top: 96px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border-top: 1px solid var(--ash);
}
.stat { padding: 32px 32px 0 0; display: grid; gap: 14px; }
.stat + .stat { padding-left: 32px; border-left: 1px solid var(--ash); }
.stat__num { font-size: clamp(44px, 5vw, 76px); line-height: 1; letter-spacing: -.04em; }
.stat__txt { color: var(--muted); max-width: 28ch; }
@media (max-width: 760px) {
  .stats { grid-template-columns: 1fr; }
  .stat, .stat + .stat { padding: 28px 0; border-left: 0; border-bottom: 1px solid var(--ash); }
}

/* ===== Research cards ===== */
.section-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 32px;
  flex-wrap: wrap;
}
.section-head .body-lg { max-width: 36ch; }
.cards {
  margin-top: 72px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--gutter);
}
@media (max-width: 980px) { .cards { grid-template-columns: 1fr; } }
.card { display: flex; flex-direction: column; }
.card__media {
  aspect-ratio: 400 / 300;
  background: var(--ink);
  overflow: hidden;
  margin-bottom: 24px;
  position: relative;
  display: grid;
  place-items: center;
}
.card__media svg { width: 100%; height: 100%; }
.card__eyebrow { font-family: var(--font-mono); font-size: 12px; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.card__title { margin-top: 12px; font-size: 26px; font-weight: 400; letter-spacing: -.02em; line-height: 1.15; }
.card__body { margin-top: 14px; color: var(--muted); max-width: 42ch; }

.wave path { fill: none; stroke-width: 2; stroke-dasharray: 8 6; animation: dash 6s linear infinite; }
.wave__a { stroke: var(--accent); }
.wave__b { stroke: #81ce40; opacity: .8; animation-duration: 7s !important; }
.wave__c { stroke: #34b06a; opacity: .65; animation-duration: 8s !important; }
@keyframes dash { to { stroke-dashoffset: -140; } }

.pwm path { fill: none; stroke: #fff; stroke-width: 2; stroke-dasharray: 900; stroke-dashoffset: 900; animation: draw 4.5s var(--ease) infinite; }
.pwm path:nth-child(2) { stroke: var(--accent); animation-delay: .4s; }
.pwm path:nth-child(3) { stroke: rgba(255,255,255,.5); animation-delay: .8s; }
@keyframes draw { 60%, 100% { stroke-dashoffset: 0; } }

.net line { stroke: rgba(255,255,255,.18); stroke-width: 1; }
.net circle { fill: #fff; }
.net circle.on { fill: var(--accent); }

/* ===== Mission ===== */
.mission {
  position: relative;
  background: var(--ink);
  color: #fff;
  padding: 160px 0;
  overflow: hidden;
}
.mission__media { position: absolute; inset: 0; opacity: .9; }
.mission__media canvas { width: 100%; height: 100%; }
.mission__content { position: relative; }
.mission__text { max-width: 54ch; margin-top: 32px; color: rgba(255,255,255,.75); }
.mission__verbs {
  margin-top: 72px;
  font-size: clamp(28px, 4vw, 56px);
  letter-spacing: -.03em;
  display: flex;
  flex-wrap: wrap;
  gap: 0 .4em;
}
.mission__verbs span:nth-child(odd) { color: rgba(255,255,255,.45); }

/* ===== Applications ===== */
.apps { list-style: none; padding: 0; margin: 64px 0 0; border-top: 1px solid var(--rule); }
.app {
  display: grid;
  grid-template-columns: 60px 1fr 1.2fr;
  gap: 20px;
  align-items: baseline;
  padding: 28px 0;
  border-bottom: 1px solid var(--rule);
  transition: padding .35s var(--ease), background .35s var(--ease);
}
.app:hover { background: var(--mist); padding-left: 16px; padding-right: 16px; }
.app__idx { font-family: var(--font-mono); font-size: 12px; color: var(--muted); }
.app__name { font-size: clamp(22px, 2.4vw, 32px); letter-spacing: -.02em; }
.app__desc { color: var(--muted); }
@media (max-width: 760px) {
  .app { grid-template-columns: 32px 1fr; }
  .app__desc { grid-column: 2; }
}

/* ===== Articles ===== */
.articles { margin-top: 64px; display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--gutter); }
@media (max-width: 980px) { .articles { grid-template-columns: 1fr; } }
.article { cursor: default; }
.article__media { height: 250px; background: var(--ink); margin-bottom: 20px; overflow: hidden; transition: transform .6s var(--ease); }
.article:hover .article__media { transform: scale(.985); }
.article__media--1 { background: radial-gradient(circle at 30% 40%, #2f517f, transparent 55%), radial-gradient(circle at 75% 70%, #34b06a, transparent 50%), var(--ink); }
.article__media--2 { background: radial-gradient(circle at 70% 30%, #cbdd18, transparent 45%), radial-gradient(circle at 20% 80%, #21817f, transparent 55%), var(--ink); }
.article__media--3 { background: radial-gradient(circle at 50% 50%, #5f1761, transparent 55%), radial-gradient(circle at 85% 20%, #f5890a, transparent 45%), var(--ink); }
.article__meta { display: flex; justify-content: space-between; font-family: var(--font-mono); font-size: 12px; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); }
.article__title { margin-top: 12px; font-size: 22px; font-weight: 400; letter-spacing: -.015em; line-height: 1.25; max-width: 28ch; }

/* ===== Team ===== */
.disciplines {
  margin-top: 64px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--gutter);
}
.discipline {
  aspect-ratio: 4 / 3;
  background: var(--mist);
  padding: 24px;
  display: flex;
  align-items: flex-end;
  font-size: 20px;
  letter-spacing: -.01em;
  position: relative;
  overflow: hidden;
  transition: background .4s var(--ease), color .4s var(--ease);
}
.discipline::before {
  content: "";
  position: absolute; top: 24px; left: 24px;
  width: 36px; height: 36px;
  border: 1px solid currentColor;
  opacity: .35;
  background: repeating-linear-gradient(45deg, currentColor 0 1px, transparent 1px 6px);
}
.discipline:hover { background: var(--ink); color: #fff; }
@media (max-width: 760px) { .disciplines { grid-template-columns: 1fr 1fr; } .discipline { font-size: 16px; padding: 16px; } .discipline::before { top: 16px; left: 16px; } }

/* ===== CTA ===== */
.cta { position: relative; background: var(--ink); min-height: 640px; display: flex; align-items: flex-end; overflow: hidden; }
.cta__canvas { position: absolute; inset: 0; width: 100%; height: 100%; }
.cta__content { position: relative; padding-top: 140px; padding-bottom: 100px; }
.cta .display { max-width: 20ch; }

/* ===== Contact ===== */
.contact { display: grid; grid-template-columns: 1fr 1fr; gap: 60px; }
.contact__intro .body-lg { margin-top: 28px; max-width: 44ch; }
@media (max-width: 900px) { .contact { grid-template-columns: 1fr; } }
.form { display: grid; gap: 20px; align-content: start; }
.form__type { border: 0; padding: 0; margin: 0 0 8px; display: flex; flex-wrap: wrap; gap: 8px; }
.form__type legend { font-family: var(--font-mono); font-size: 12px; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); margin-bottom: 12px; padding: 0; }
.form__type label { cursor: pointer; }
.form__type input { position: absolute; opacity: 0; pointer-events: none; }
.form__type span {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: .04em;
  padding: 9px 14px;
  background: var(--mist);
  border-radius: 2px;
  transition: background .2s, color .2s;
}
.form__type input:checked + span { background: var(--ink); color: #fff; }
.form__type input:focus-visible + span { outline: 2px solid var(--ink); outline-offset: 2px; }
.field { display: grid; gap: 8px; }
.field span { font-family: var(--font-mono); font-size: 12px; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); }
.field input, .field textarea {
  font: inherit;
  font-size: 17px;
  color: var(--ink);
  background: transparent;
  border: 0;
  border-bottom: 1px solid var(--ash);
  padding: 10px 0;
  border-radius: 0;
  resize: vertical;
  transition: border-color .2s;
}
.field input:focus, .field textarea:focus { outline: none; border-bottom-color: var(--ink); }
.field.has-error input, .field.has-error textarea { border-bottom-color: #aa1c2c; }
.form__error { color: #aa1c2c; font-size: 14px; }
.form__note { font-family: var(--font-mono); font-size: 12px; color: var(--muted); text-transform: uppercase; letter-spacing: .06em; }

/* ===== Footer ===== */
.footer { background: var(--ink); color: #fff; padding: 96px 0 32px; overflow: hidden; }
.footer__top { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 40px; }
.footer__tag p { font-size: 22px; max-width: 24ch; letter-spacing: -.01em; }
.footer__mail { display: inline-block; margin-top: 20px; font-family: var(--font-mono); font-size: 13px; color: rgba(255,255,255,.7); border-bottom: 1px solid rgba(255,255,255,.3); }
.footer__mail:hover { color: #fff; }
.footer__links { display: grid; gap: 10px; align-content: start; font-family: var(--font-mono); font-size: 13px; text-transform: uppercase; letter-spacing: .04em; }
.footer__links a { color: rgba(255,255,255,.7); }
.footer__links a:hover { color: #fff; }
.footer__wordmark {
  margin-top: 140px;
  font-size: clamp(36px, 8.6vw, 132px);
  line-height: .9;
  letter-spacing: -.05em;
  white-space: nowrap;
}
.footer__bottom {
  margin-top: 40px;
  padding-top: 20px;
  border-top: 1px solid rgba(255,255,255,.14);
  display: flex;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  font-family: var(--font-mono);
  font-size: 12px;
  color: rgba(255,255,255,.6);
  text-transform: uppercase;
  letter-spacing: .04em;
}
.footer__bottom a:hover { color: #fff; }
@media (max-width: 760px) {
  .footer__top { grid-template-columns: 1fr 1fr; }
  .footer__tag { grid-column: 1 / -1; }
  .footer__wordmark { margin-top: 80px; white-space: normal; }
}

/* ===== Reveal motion ===== */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity .72s var(--ease), transform .72s var(--ease); }
.reveal.is-in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  *, *::before, *::after { animation: none !important; }
  html { scroll-behavior: auto; }
}
@media (max-width: 900px) { .mission__media { opacity: .35; } }
