/* ==========================================================================
   Octocode Engineering — site stylesheet
   One file, no build step. Sections:
   1 Fonts · 2 Tokens · 3 Base · 4 Stage (background imagery) · 5 Header & trace
   6 Menu · 7 Layout primitives · 8 Home sections · 9 Product-page sections
   10 Footer · 11 Legal pages · 12 Motion · 13 Draft mode · 14 Reduced motion
   ========================================================================== */

/* 1 · Fonts — self-hosted (no Google Fonts CDN: avoids transferring visitor IPs to a third party) */
@font-face {
  font-family: "Geist";
  src: url("../fonts/geist-latin-wght-normal.woff2") format("woff2-variations");
  font-weight: 100 900; font-style: normal; font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Geist";
  src: url("../fonts/geist-latin-ext-wght-normal.woff2") format("woff2-variations");
  font-weight: 100 900; font-style: normal; font-display: swap;
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Geist Mono";
  src: url("../fonts/geist-mono-latin-wght-normal.woff2") format("woff2-variations");
  font-weight: 100 900; font-style: normal; font-display: swap;
}

/* 2 · Tokens */
:root {
  /* brand palette (from the Octocode exposé) */
  --ink: #0B2A3B;          /* brandDark — text, marks */
  --teal: #2E8B8B;         /* brandAccent — links, active states */
  --mist: #EAF2F1;         /* brandLight — quiet surfaces */
  --paper: #F7FBFA;        /* page ground behind imagery */
  --pulse: #F0457A;        /* R-peak marker colour — used only for the scroll-trace head */
  --ink-2: rgb(11 42 59 / .72);
  --ink-3: rgb(11 42 59 / .52);
  --hair: rgb(11 42 59 / .12);

  --glass: rgb(255 255 255 / .56);
  --glass-strong: rgb(255 255 255 / .78);
  --glass-edge: rgb(255 255 255 / .75);
  --blur: blur(22px) saturate(1.6);

  --font: "Geist", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "Geist Mono", ui-monospace, "SF Mono", Menlo, Consolas, monospace;

  /* type scale (≈ perfect fourth, fluid at the top end) */
  --t-display: clamp(3.1rem, 1.6rem + 6.4vw, 8rem);
  --t-h1: clamp(2.4rem, 1.5rem + 3.6vw, 4.75rem);
  --t-h2: clamp(1.9rem, 1.3rem + 2.2vw, 3.2rem);
  --t-h3: clamp(1.3rem, 1.1rem + .6vw, 1.6rem);
  --t-lead: clamp(1.15rem, 1.02rem + .5vw, 1.45rem);
  --t-body: 1.0625rem;
  --t-small: .875rem;

  --gutter: clamp(16px, 4vw, 48px);
  --max: 1240px;
  --header-h: 64px;
  --r-lg: 32px;
  --r-md: 20px;
  --r-sm: 12px;

  /* springs: underdamped step responses (ζ = .62 → ~8% overshoot, ζ = .85 → settle) */
  --spring: linear(0, 0.0201, 0.0735, 0.1504, 0.2424, 0.3427, 0.4453, 0.5459, 0.6409, 0.728, 0.8057, 0.8731, 0.93, 0.9765, 1.0133, 1.0411, 1.061, 1.074, 1.0811, 1.0835, 1.0821, 1.0779, 1.0716, 1.064, 1.0557, 1.0471, 1.0387, 1.0307, 1.0233, 1.0168, 1.0111, 1.0062, 1.0023, 0.9991, 0.9967, 0.995, 0.9939, 0.9933, 0.993, 0.9931, 0.9935, 0.994, 0.9946, 0.9953, 0.996, 0.9967, 0.9974, 1);
  --spring-soft: linear(0, 0.0133, 0.0484, 0.0988, 0.1594, 0.2261, 0.2956, 0.3655, 0.4338, 0.4993, 0.5609, 0.6182, 0.6706, 0.7182, 0.7609, 0.7989, 0.8325, 0.8618, 0.8872, 0.909, 0.9277, 0.9434, 0.9567, 0.9676, 0.9767, 0.984, 0.9899, 0.9945, 0.9982, 1.0009, 1.0029, 1.0044, 1.0054, 1.0059, 1.0062, 1.0063, 1.0062, 1.0059, 1.0056, 1.0052, 1.0048, 1.0043, 1.0039, 1.0035, 1.0031, 1.0027, 1.0023, 1);
  --ease-out: cubic-bezier(.16, 1, .3, 1);
  --d-spring: 900ms;
  color-scheme: light;
}

/* 3 · Base */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; background: var(--paper); }
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }
.lenis.lenis-stopped { overflow: clip; }
body {
  margin: 0; min-height: 100svh;
  font: 400 var(--t-body)/1.6 var(--font);
  font-feature-settings: "ss01", "cv11";
  color: var(--ink); background: transparent; /* ground colour lives on <html> so the fixed stage shows through */
  -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale;
  overflow-x: clip;
}
img, svg, picture { display: block; max-width: 100%; }
a { color: inherit; text-decoration-thickness: 1px; text-underline-offset: .2em; }
p { margin: 0 0 1em; max-width: 62ch; }
h1, h2, h3 { margin: 0; font-weight: 600; letter-spacing: -.035em; line-height: 1.02; text-wrap: balance; }
h2 { font-size: var(--t-h2); }
h3 { font-size: var(--t-h3); letter-spacing: -.02em; line-height: 1.2; }
:focus-visible { outline: 2.5px solid var(--teal); outline-offset: 3px; border-radius: 6px; }
::selection { background: rgb(46 139 139 / .22); }
.skip { position: absolute; left: 12px; top: -60px; z-index: 100; padding: 10px 14px; border-radius: var(--r-sm); background: var(--ink); color: #fff; text-decoration: none; transition: top .3s var(--ease-out); }
.skip:focus { top: 12px; }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* 4 · Stage — the full-viewport project imagery behind everything */
.stage { position: fixed; inset: 0; z-index: -2; overflow: hidden; background: var(--paper); }
.stage__layer {
  position: absolute; inset: -6vh 0; margin: 0;
  opacity: 0; transform: scale(1.06);
  transition: opacity 1.1s var(--ease-out), transform 2.2s var(--spring-soft);
  will-change: opacity, transform;
}
.stage__layer.is-active { opacity: 1; transform: scale(1); }
.stage__layer img, .stage__layer picture { width: 100%; height: 100%; object-fit: cover; }
.stage__layer img { transform: translate3d(0, var(--py, 0px), 0); will-change: transform; }
/* legibility veil — set per section via data-veil="left|full|soft|none" */
.veil {
  position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background: linear-gradient(90deg, rgb(247 251 250 / .93) 0%, rgb(247 251 250 / .8) 36%, rgb(247 251 250 / .35) 56%, rgb(247 251 250 / 0) 72%);
  transition: opacity .9s var(--ease-out);
  opacity: 1;
}
.veil::after { content: ""; position: absolute; inset: 0; background: rgb(247 251 250 / .7); opacity: 0; transition: opacity .9s var(--ease-out); }
html[data-veil="none"] .veil { opacity: 0; }
html[data-veil="full"] .veil::after { opacity: 1; }
html[data-veil="soft"] .veil { opacity: .55; }
/* hero: detailed renders sit behind large headlines, so the calm zone reaches further right */
.veil::before { content: ""; position: absolute; inset: 0; opacity: 0; transition: opacity .9s var(--ease-out);
  background: linear-gradient(90deg, rgb(247 251 250 / .9) 0%, rgb(247 251 250 / .82) 44%, rgb(247 251 250 / .45) 64%, rgb(247 251 250 / 0) 84%); }
html[data-veil="hero"] .veil::before { opacity: 1; }

/* 5 · Header & scroll trace */
.header {
  position: fixed; inset: 0 0 auto; z-index: 40; height: var(--header-h);
  display: flex; align-items: center;
  background: rgb(247 251 250 / .38);
  -webkit-backdrop-filter: var(--blur); backdrop-filter: var(--blur);
  transition: background-color .5s var(--ease-out);
}
html.is-scrolled .header { background: rgb(247 251 250 / .72); }
.header__inner { width: 100%; max-width: calc(var(--max) + 2 * var(--gutter)); margin-inline: auto; padding-inline: var(--gutter); display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.brand { display: inline-flex; align-items: center; gap: 12px; text-decoration: none; font-weight: 600; letter-spacing: -.02em; font-size: 1.02rem; }
.brand img { width: auto; height: 36px; shape-rendering: geometricPrecision; }
.footer .brand img { height: 44px; }
@media (max-width: 560px) { .brand img { height: 32px; } }
.brand__sub { font-weight: 400; color: var(--ink-3); }
.trace { position: absolute; left: 0; right: 0; bottom: -7px; width: 100%; height: 14px; pointer-events: none; overflow: visible; }
.trace path { fill: none; stroke-width: 1.5; stroke-linejoin: round; stroke-linecap: round; vector-effect: non-scaling-stroke; }
.trace__ghost { stroke: var(--hair); }
.trace__live { stroke: var(--teal); }
.trace__head { fill: var(--pulse); }
.trace__halo { fill: var(--pulse); opacity: .25; transform-box: fill-box; transform-origin: center; }
html.is-beat .trace__halo { animation: beat .7s var(--spring) 1; }
@keyframes beat { 0% { transform: scale(1); opacity: .35; } 100% { transform: scale(3.2); opacity: 0; } }

/* 6 · Menu (dropdown) */
.menu { position: relative; }
.menu__button {
  display: inline-flex; align-items: center; gap: 10px; height: 40px; padding: 0 14px 0 16px;
  border: 1px solid var(--hair); border-radius: 999px; background: var(--glass-strong);
  font: 500 .95rem/1 var(--font); color: var(--ink); cursor: pointer;
  transition: transform .5s var(--spring), background-color .3s;
}
.menu__button:hover { background: #fff; }
.menu__button:active { transform: scale(.96); }
.menu__icon { width: 14px; height: 14px; position: relative; }
.menu__icon::before, .menu__icon::after { content: ""; position: absolute; left: 0; right: 0; height: 1.6px; border-radius: 2px; background: currentColor; transition: transform .6s var(--spring); }
.menu__icon::before { top: 4px; }
.menu__icon::after { bottom: 4px; }
.menu[data-open] .menu__icon::before { transform: translateY(2.7px) rotate(45deg); }
.menu[data-open] .menu__icon::after { transform: translateY(-2.7px) rotate(-45deg); }
.menu__panel {
  position: absolute; right: 0; top: calc(100% + 12px); width: min(380px, calc(100vw - 2 * var(--gutter)));
  padding: 8px; border-radius: 24px;
  background: var(--glass-strong); border: 1px solid var(--glass-edge);
  -webkit-backdrop-filter: var(--blur); backdrop-filter: var(--blur);
  box-shadow: 0 1px 2px rgb(11 42 59 / .06), 0 24px 60px -12px rgb(11 42 59 / .22);
  transform-origin: top right;
  opacity: 0; transform: translateY(-6px) scale(.94); visibility: hidden;
  transition: opacity .25s var(--ease-out), transform .7s var(--spring), visibility 0s .25s;
}
.menu[data-open] .menu__panel { opacity: 1; transform: none; visibility: visible; transition: opacity .25s var(--ease-out), transform .7s var(--spring), visibility 0s; }
.menu__list { list-style: none; margin: 0; padding: 0; }
.menu__link {
  display: grid; grid-template-columns: 1fr auto; gap: 2px 12px; align-items: center;
  padding: 12px 14px; border-radius: 16px; text-decoration: none;
  transition: background-color .25s, transform .5s var(--spring);
}
.menu__link:hover { background: rgb(46 139 139 / .09); }
.menu__link:active { transform: scale(.98); }
.menu__title { font-weight: 550; letter-spacing: -.01em; }
.menu__desc { grid-column: 1; font-size: var(--t-small); color: var(--ink-3); line-height: 1.35; }
.menu__link[aria-current="page"] .menu__title::after { content: ""; display: inline-block; width: 6px; height: 6px; margin-left: 8px; border-radius: 50%; background: var(--teal); vertical-align: middle; }
.menu__sep { height: 1px; margin: 6px 14px; background: var(--hair); }
/* items cascade in when the panel opens */
.menu__list > li { opacity: 0; transform: translateY(-4px); transition: opacity .2s, transform .6s var(--spring); }
.menu[data-open] .menu__list > li { opacity: 1; transform: none; }
.menu[data-open] .menu__list > li:nth-child(2) { transition-delay: 30ms; }
.menu[data-open] .menu__list > li:nth-child(3) { transition-delay: 60ms; }
.menu[data-open] .menu__list > li:nth-child(4) { transition-delay: 90ms; }
.menu[data-open] .menu__list > li:nth-child(5) { transition-delay: 120ms; }
.menu[data-open] .menu__list > li:nth-child(6) { transition-delay: 150ms; }

/* 7 · Layout primitives */
.wrap { width: 100%; max-width: calc(var(--max) + 2 * var(--gutter)); margin-inline: auto; padding-inline: var(--gutter); }
.section { position: relative; padding-block: clamp(6rem, 16vh, 11rem); }
.pane {
  background: var(--glass); border: 1px solid var(--glass-edge); border-radius: var(--r-lg);
  -webkit-backdrop-filter: var(--blur); backdrop-filter: var(--blur);
  box-shadow: 0 1px 1px rgb(11 42 59 / .04), 0 30px 80px -30px rgb(11 42 59 / .18);
  padding: clamp(28px, 4vw, 56px);
}
.lead { font-size: var(--t-lead); line-height: 1.45; letter-spacing: -.012em; color: var(--ink-2); max-width: 36ch; }
.kicker { font-size: var(--t-small); font-weight: 500; color: var(--teal); margin: 0 0 18px; letter-spacing: 0; }
.button {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px; height: 52px; padding: 0 26px;
  border-radius: 999px; border: 1px solid transparent; text-decoration: none;
  font: 550 1rem/1 var(--font); letter-spacing: -.01em; cursor: pointer;
  transition: transform .6s var(--spring), background-color .3s, box-shadow .3s;
}
.button:hover { transform: translateY(-2px) scale(1.02); }
.button:active { transform: scale(.97); transition-duration: .15s; }
.button--primary { background: var(--ink); color: #fff; box-shadow: 0 10px 30px -10px rgb(11 42 59 / .5); }
.button--primary:hover { background: #0f3a50; }
.button--quiet { background: var(--glass-strong); border-color: var(--hair); color: var(--ink); -webkit-backdrop-filter: var(--blur); backdrop-filter: var(--blur); }
.actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 36px; }

/* 8 · Home sections ------------------------------------------------------- */
.hero { min-height: 100svh; display: flex; align-items: flex-end; padding-block: calc(var(--header-h) + 8vh) clamp(56px, 11vh, 120px); }
.hero__title { font-size: var(--t-display); letter-spacing: -.055em; line-height: .92; font-weight: 600; } /* line breaks are explicit (.line), so no width cap */
.hero__title .line { display: block; overflow: clip; padding-bottom: .06em; }
.hero__title .line > span { display: inline-block; }
.hero .lead { margin-top: 28px; }
.scroll-cue { position: absolute; left: 50%; bottom: 26px; width: 22px; height: 36px; margin-left: -11px; border: 1.6px solid var(--ink-3); border-radius: 12px; }
.scroll-cue::after { content: ""; position: absolute; left: 50%; top: 7px; width: 3px; height: 7px; margin-left: -1.5px; border-radius: 2px; background: var(--ink-2); animation: cue 2.2s var(--ease-out) infinite; }
@keyframes cue { 0% { transform: translateY(0); opacity: 0; } 25% { opacity: 1; } 70% { transform: translateY(10px); opacity: 0; } 100% { opacity: 0; } }
html.is-scrolled .scroll-cue { opacity: 0; transition: opacity .4s; }

/* scroll-scrubbed statement */
.scrub { height: 230vh; padding: 0; }
.scrub__sticky { position: sticky; top: 0; height: 100svh; display: flex; align-items: center; }
.scrub__text { font-size: var(--t-h1); font-weight: 600; letter-spacing: -.04em; line-height: 1.08; max-width: 20ch; margin: 0; }
.scrub__text .w { opacity: .16; transition: opacity .35s linear; }
.scrub__text .w.is-lit { opacity: 1; }

/* category tiles — two deliberately unequal tiles, image inside, alternating */
.cats { display: grid; gap: clamp(20px, 3vw, 32px); }
.cat {
  position: relative; display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); align-items: stretch;
  min-height: min(78vh, 680px); border-radius: var(--r-lg); overflow: hidden; text-decoration: none;
  background: var(--glass-strong); border: 1px solid var(--glass-edge);
  -webkit-backdrop-filter: var(--blur); backdrop-filter: var(--blur);
  box-shadow: 0 40px 90px -40px rgb(11 42 59 / .3);
  transform: scale(var(--tile-s, 1)); transform-origin: center bottom;
}
.cat:nth-child(even) { grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); }
.cat:nth-child(even) .cat__media { order: -1; }
.cat__body { display: flex; flex-direction: column; justify-content: space-between; gap: 32px; padding: clamp(28px, 4vw, 56px); }
.cat__body h2 { font-size: var(--t-h2); }
.cat__body p { color: var(--ink-2); margin-top: 18px; }
.cat__more { display: inline-flex; align-items: center; gap: 10px; font-weight: 550; color: var(--teal); }
.cat__more svg { transition: transform .6s var(--spring); }
.cat:hover .cat__more svg { transform: translateX(5px); }
.cat__media { position: relative; overflow: hidden; }
.cat__media img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transform: scale(1.04); transition: transform 1.2s var(--spring-soft); }
.cat:hover .cat__media img { transform: scale(1.09); }

/* engagement steps — a real sequence, so numbered */
.steps { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(32px, 6vw, 96px); align-items: start; }
.steps__aside { position: sticky; top: calc(var(--header-h) + 12vh); }
.steps__aside h2 { margin-bottom: 20px; }
.steps__count { font: 500 clamp(5rem, 12vw, 10rem)/1 var(--mono); letter-spacing: -.06em; color: var(--teal); margin-top: 32px; height: 1em; overflow: hidden; }
.steps__count span { display: block; transition: transform .8s var(--spring); transform: translateY(calc(var(--step, 0) * -1em)); }
.steps__list { list-style: none; margin: 0; padding: 0; display: grid; gap: 22vh; padding-block: 8vh 20vh; }
.step { opacity: .32; transform: scale(.97); transform-origin: left center; transition: opacity .6s var(--ease-out), transform .9s var(--spring); }
.step.is-current { opacity: 1; transform: none; }
.step h3 { margin-bottom: 12px; }
.step p { color: var(--ink-2); }

/* principles — three statements, separated by hairlines rather than cards */
.principles { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0; margin-top: 56px; }
.principle { padding: 28px 28px 8px 0; border-top: 1px solid var(--hair); }
.principle + .principle { padding-left: 28px; border-left: 1px solid var(--hair); }
.principle h3 { margin-bottom: 12px; }
.principle p { color: var(--ink-2); font-size: 1rem; }

/* contact */
.contact { text-align: left; }
.contact__mail { display: inline-block; margin-top: 18px; font-size: var(--t-h1); font-weight: 600; letter-spacing: -.045em; line-height: 1.05; text-decoration: none; background: linear-gradient(currentColor, currentColor) 0 100% / 0 2px no-repeat; transition: background-size .8s var(--spring); word-break: break-word; }
.contact__mail:hover { background-size: 100% 2px; }
.contact__meta { margin-top: 28px; color: var(--ink-2); }

/* 9 · Product pages ------------------------------------------------------- */
.page-hero { min-height: 92svh; display: flex; align-items: flex-end; padding-block: calc(var(--header-h) + 10vh) clamp(56px, 10vh, 110px); }
.page-hero h1 { font-size: var(--t-display); letter-spacing: -.055em; line-height: .92; }
.page-hero .lead { margin-top: 28px; }
.crumb { display: inline-flex; align-items: center; gap: 8px; margin-bottom: 26px; font-size: var(--t-small); color: var(--ink-2); text-decoration: none; }
.crumb:hover { color: var(--ink); }

.overview { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(32px, 6vw, 96px); }
.overview__body p { font-size: 1.125rem; }

/* feature scroller: text steps on the left, a sticky media frame on the right.
   Each feature also swaps the page background via data-bg. */
.features { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(32px, 6vw, 96px); }
.feature { min-height: 78vh; display: flex; flex-direction: column; justify-content: center; opacity: .35; transition: opacity .6s var(--ease-out); }
.feature.is-current { opacity: 1; }
.feature h3 { font-size: var(--t-h2); letter-spacing: -.035em; line-height: 1.05; margin-bottom: 18px; }
.feature p { color: var(--ink-2); }
.frame { position: sticky; top: calc(var(--header-h) + 8vh); height: min(72vh, 640px); border-radius: var(--r-lg); overflow: hidden; background: var(--mist); border: 1px solid var(--glass-edge); box-shadow: 0 40px 90px -40px rgb(11 42 59 / .35); }
.frame__img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; transform: scale(1.08); transition: opacity .8s var(--ease-out), transform 1.4s var(--spring-soft); }
.frame__img.is-current { opacity: 1; transform: scale(1); }
.frame__caption { position: absolute; left: 16px; bottom: 16px; padding: 8px 12px; border-radius: 999px; font-size: .8rem; background: var(--glass-strong); -webkit-backdrop-filter: var(--blur); backdrop-filter: var(--blur); }

/* specification sheet — the one place mono is used, because these are data */
.specs { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 clamp(24px, 4vw, 64px); margin: 48px 0 0; }
.specs > div { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 3fr); gap: 16px; padding: 18px 0; border-top: 1px solid var(--hair); }
.specs dt { color: var(--ink-3); font-size: .95rem; }
.specs dd { margin: 0; font: 450 .95rem/1.5 var(--mono); letter-spacing: -.01em; }

.status { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(32px, 6vw, 96px); align-items: start; }
.timeline { list-style: none; margin: 0; padding: 0; position: relative; }
.timeline::before { content: ""; position: absolute; left: 6px; top: 8px; bottom: 8px; width: 1.5px; background: var(--hair); }
.timeline li { position: relative; padding: 0 0 28px 34px; }
.timeline li::before { content: ""; position: absolute; left: 0; top: 6px; width: 13px; height: 13px; border-radius: 50%; background: var(--paper); border: 1.5px solid var(--teal); }
.timeline li[data-done]::before { background: var(--teal); }
.timeline strong { display: block; font-weight: 550; }
.timeline span { color: var(--ink-2); }

/* 10 · Footer */
.footer { position: relative; padding-block: 72px 40px; background: rgb(247 251 250 / .86); -webkit-backdrop-filter: var(--blur); backdrop-filter: var(--blur); border-top: 1px solid var(--hair); font-size: var(--t-small); color: var(--ink-2); }
.footer__grid { display: grid; grid-template-columns: minmax(0, 2fr) repeat(2, minmax(0, 1fr)); gap: 40px; }
.footer h2 { font-size: 1rem; letter-spacing: -.01em; margin-bottom: 14px; color: var(--ink); }
.footer ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.footer a { text-decoration: none; }
.footer a:hover { color: var(--ink); text-decoration: underline; }
.footer__legal { margin-top: 56px; padding-top: 24px; border-top: 1px solid var(--hair); display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; }
.footer__legal p { margin: 0; max-width: none; }

/* 11 · Legal pages */
.legal { padding-block: calc(var(--header-h) + 12vh) 12vh; }
.legal .pane { max-width: 760px; }
.legal h1 { font-size: var(--t-h1); margin-bottom: 36px; }
.legal h2 { font-size: 1.15rem; letter-spacing: -.01em; margin: 32px 0 8px; }
.legal address { font-style: normal; }

/* 12 · Motion — page entrance, reveals, page leave */
[data-reveal] { opacity: 0; transform: translateY(28px) scale(.985); transition: opacity .8s var(--ease-out), transform var(--d-spring) var(--spring); transition-delay: var(--delay, 0ms); }
[data-reveal].is-in { opacity: 1; transform: none; }
.hero__title .line > span, .page-hero h1 .line > span { transform: translateY(105%); transition: transform 1.1s var(--spring); transition-delay: var(--delay, 0ms); }
html.is-loaded .hero__title .line > span, html.is-loaded .page-hero h1 .line > span { transform: none; }
.page-hero h1 .line { display: block; overflow: clip; padding-bottom: .06em; }
main { transition: opacity .35s var(--ease-out), transform .45s var(--ease-out), filter .35s; }
html.is-leaving main { opacity: 0; transform: translateY(-12px) scale(.99); filter: blur(4px); }
html.is-leaving .stage { opacity: .6; transition: opacity .35s; }

/* 13 · Draft mode (?draft in the URL) — shows every content slot to fill in another project */
html.is-draft [data-slot] { outline: 1.5px dashed rgb(240 69 122 / .7); outline-offset: 6px; border-radius: 6px; position: relative; }
html.is-draft [data-slot]::before { content: attr(data-slot); position: absolute; top: -26px; left: 0; z-index: 5; padding: 2px 8px; border-radius: 6px; background: var(--pulse); color: #fff; font: 500 11px/1.5 var(--mono); white-space: nowrap; }
html.is-draft [data-bg]::after { content: "bg: " attr(data-bg); position: absolute; right: var(--gutter); top: 80px; padding: 2px 8px; border-radius: 6px; background: var(--ink); color: #fff; font: 500 11px/1.5 var(--mono); }

/* Responsive */
@media (max-width: 900px) {
  .cat, .cat:nth-child(even) { grid-template-columns: 1fr; min-height: 0; }
  .cat:nth-child(even) .cat__media { order: 0; }
  .cat__media { min-height: 46vh; order: -1; }
  .steps, .overview, .features, .status { grid-template-columns: 1fr; }
  .steps__aside { position: relative; top: 0; }
  .steps__count { display: none; }
  .steps__list { gap: 48px; padding-block: 0; }
  .step { opacity: 1; transform: none; }
  .principles { grid-template-columns: 1fr; }
  .principle + .principle { padding-left: 0; border-left: 0; }
  .features { gap: 0; }
  .features__media { order: -1; position: sticky; top: calc(var(--header-h) + 12px); z-index: 2; }
  .frame { position: relative; top: 0; height: 36vh; }
  .features__text { padding-top: 4vh; }
  .feature { min-height: 70vh; }
  .specs { grid-template-columns: 1fr; }
  .footer__grid { grid-template-columns: 1fr 1fr; }
  .footer__grid > :first-child { grid-column: 1 / -1; }
  .veil { background: linear-gradient(180deg, rgb(247 251 250 / .25) 0%, rgb(247 251 250 / .82) 60%, rgb(247 251 250 / .92) 100%); }
  .scrub { height: 200vh; }
  .scrub__text { font-size: var(--t-h2); }
}
@media (max-width: 560px) {
  :root { --header-h: 58px; }
  .brand__sub { display: none; }
  .hero__title, .page-hero h1 { letter-spacing: -.05em; }
  .actions .button { flex: 1 1 100%; }
}

/* 14 · Reduced motion: no smooth-scroll hijack, no parallax, instant state changes */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; transition-delay: 0ms !important; }
  [data-reveal] { opacity: 1; transform: none; }
  .hero__title .line > span, .page-hero h1 .line > span { transform: none; }
  .stage__layer img { transform: none !important; }
  .scrub { height: auto; }
  .scrub__sticky { position: relative; height: auto; padding-block: 20vh; }
  .scrub__text .w { opacity: 1; }
  .cat { transform: none !important; }
}

/* 15 · Language switch, German typography, illustration note */
.header__actions { display: flex; align-items: center; gap: 8px; }
.lang {
  display: inline-flex; align-items: center; justify-content: center; height: 40px; min-width: 44px; padding: 0 12px;
  border-radius: 999px; border: 1px solid var(--hair); background: var(--glass-strong);
  font: 550 .85rem/1 var(--font); letter-spacing: .02em; color: var(--ink-2); text-decoration: none;
  transition: transform .5s var(--spring), color .2s, background-color .3s;
}
.lang:hover { color: var(--ink); background: #fff; }
.lang:active { transform: scale(.94); }
/* German compounds ("Qualitätsprüfung", "Physiologische") can exceed the line at display sizes:
   let the browser hyphenate rather than clip */
html[lang="de"] h1, html[lang="de"] h2, html[lang="de"] .scrub__text, html[lang="de"] .contact__mail { hyphens: auto; -webkit-hyphens: auto; hyphenate-limit-chars: 10 4 4; }
html[lang="de"] .contact__mail { hyphens: manual; }
.frame__note { position: absolute; left: 14px; right: 14px; bottom: 14px; z-index: 2; margin: 0; width: fit-content; max-width: calc(100% - 28px); padding: 7px 12px; border-radius: 12px; font-size: .78rem; line-height: 1.4; color: var(--ink-2); background: var(--glass-strong); -webkit-backdrop-filter: var(--blur); backdrop-filter: var(--blur); }
/* German display copy runs ~20% longer than English */
html[lang="de"] { --t-display: clamp(2.6rem, 1.3rem + 5.4vw, 6.6rem); }
@media (max-width: 560px) {
  :root { --t-display: clamp(2.5rem, 1.2rem + 6.4vw, 3.4rem); }
  .lang { height: 36px; min-width: 40px; padding: 0 10px; }
  .menu__button { height: 36px; }
}

/* 16 · Concept badge and disclaimer (illustrations are not real results) */
.concept-badge {
  display: inline-flex; align-items: center; gap: 8px; margin: 28px 0 0; padding: 6px 12px 6px 10px;
  border-radius: 999px; border: 1px solid var(--hair); background: var(--glass);
  -webkit-backdrop-filter: var(--blur); backdrop-filter: var(--blur);
  font-size: .8rem; line-height: 1.3; color: var(--ink-2); max-width: none;
}
.concept-badge::before { content: ""; width: 7px; height: 7px; border-radius: 50%; border: 1.5px solid var(--teal); flex: none; }
.section--tight { padding-block: 0 clamp(3rem, 8vh, 5rem); }
.disclaimer {
  max-width: 820px; border-radius: var(--r-md); border: 1px solid var(--glass-edge);
  background: var(--glass); -webkit-backdrop-filter: var(--blur); backdrop-filter: var(--blur);
  font-size: .9rem; line-height: 1.55; color: var(--ink-2);
}
.disclaimer summary { list-style: none; cursor: pointer; display: grid; gap: 6px; padding: 18px 22px; border-radius: var(--r-md); }
.disclaimer summary::-webkit-details-marker { display: none; }
.disclaimer__lead strong { color: var(--ink); font-weight: 600; }
.disclaimer__more { display: inline-flex; align-items: center; gap: 8px; font-size: .82rem; font-weight: 550; color: var(--teal); }
.disclaimer__more::after { content: ""; width: 7px; height: 7px; border-right: 1.6px solid currentColor; border-bottom: 1.6px solid currentColor; transform: translateY(-2px) rotate(45deg); transition: transform .6s var(--spring); }
.disclaimer[open] .disclaimer__more::after { transform: translateY(1px) rotate(225deg); }
.disclaimer__body { padding: 0 22px 18px; }
.disclaimer__body p { margin: 0 0 .7em; max-width: 70ch; }
.disclaimer__body p:last-child { margin-bottom: 0; }
/* smooth open: animate the details content height where supported, otherwise a spring fade-in */
.disclaimer[open] .disclaimer__body { animation: disc-in .7s var(--spring); }
@keyframes disc-in { from { opacity: 0; transform: translateY(-6px); } to { opacity: 1; transform: none; } }
@supports (interpolate-size: allow-keywords) {
  .disclaimer { interpolate-size: allow-keywords; }
  .disclaimer::details-content { block-size: 0; overflow: clip; transition: block-size .6s var(--spring-soft), content-visibility .6s allow-discrete; }
  .disclaimer[open]::details-content { block-size: auto; }
}

/* 17 · Language flags */
.lang { gap: 7px; }
.lang__flag { width: 20px; height: 12px; border-radius: 2.5px; box-shadow: 0 0 0 1px rgb(11 42 59 / .14); flex: none; overflow: hidden; }

/* 18 · Founder portrait and publications */
.founder__photo { display: block; width: min(320px, 70%); aspect-ratio: 4 / 5; margin-bottom: 28px; border-radius: var(--r-lg); overflow: hidden; border: 1px solid var(--glass-edge); box-shadow: 0 30px 70px -30px rgb(11 42 59 / .35); background: var(--mist); }
.founder__photo img { width: 100%; height: 100%; object-fit: cover; }
.pubs { list-style: none; margin: 0; padding: 0; display: grid; gap: 0; }
.pub { padding: 26px 0; border-top: 1px solid var(--hair); }
.pub:last-child { border-bottom: 1px solid var(--hair); }
.pub__title { font-size: 1.2rem; line-height: 1.3; letter-spacing: -.015em; margin-bottom: 8px; hyphens: manual; }
.pub__title a { text-decoration: none; background: linear-gradient(currentColor, currentColor) 0 100% / 0 1.5px no-repeat; transition: background-size .7s var(--spring); }
.pub__title a:hover { background-size: 100% 1.5px; }
.pub__venue { margin: 0 0 6px; font-weight: 550; color: var(--ink); font-size: .95rem; }
.pub__authors { margin: 0 0 10px; font-size: .88rem; color: var(--ink-3); }
.pub__authors strong { color: var(--ink); font-weight: 600; }
.pub__role { margin: 0 0 12px; font-size: .95rem; color: var(--ink-2); }
.pub__link { display: inline-flex; gap: 6px; align-items: center; font-size: .9rem; font-weight: 550; color: var(--teal); text-decoration: none; }
.pub__link:hover { text-decoration: underline; }
.pub__link--pending { color: var(--ink-3); font-weight: 450; }
