/* Hallmark · macrostructure: studied-DNA (approved PatchPlay mockups 01–08) · tone: playful-tactile · anchor hue: red
 * theme: studied-DNA (source: image, 8 approved mockups) · font: Plus Jakarta Sans (single family)
 * nav: N1a (2 destinations + CTA, as approved) · footer: Ft2 legal strip (RO)
 * pre-emit critique: P4 H4 E4 S4 R4 V4 (after audit 2026-11-05, was E2)
 * slop: 57/57 checked · accepted exceptions from approved mockups: 6 centred hero, 7 pure white paper, 23 red 3D objects, 42 N1a
 * generated: ChatGPT imagegen (8 objects, user-supplied 2026-11-05) · post-processed: alpha residue cut <16, trimmed, WebP, CSS contact shadow
 * contrast: pass (40–41) · mobile: pass (34, 49, 50–57) · hero fit: pass (44) at 1280×800 and 375×667
 */
@import url("tokens.css");

/* Plus Jakarta Sans, self-hosted (SIL OFL 1.1, fonts/OFL.txt): one variable woff2 per subset,
   weights 400–800. latin-ext carries the Romanian ă ș ț; latin carries â î. No Google Fonts request. */
@font-face { font-family: "Plus Jakarta Sans"; font-style: normal; font-weight: 400 800; font-display: swap;
  src: url("../fonts/plus-jakarta-sans-latin-ext.woff2") format("woff2"); 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-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "Plus Jakarta Sans"; font-style: normal; font-weight: 400 800; font-display: swap;
  src: url("../fonts/plus-jakarta-sans-latin.woff2") format("woff2"); 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; }

*, *::before, *::after { box-sizing: border-box; }
html, body { overflow-x: clip; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--color-paper);
  color: var(--color-ink);
  font-family: var(--font-sans);
  font-size: var(--text-md);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
[hidden] { display: none !important; }
a { color: inherit; }
button, input, select, textarea { font: inherit; color: inherit; }
:focus-visible { outline: 3px solid var(--color-focus); outline-offset: 3px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: var(--space-4); top: -60px; background: var(--color-ink); color: var(--color-paper); padding: var(--space-2) var(--space-4); border-radius: var(--radius-sm); z-index: 10; }
.skip:focus { top: var(--space-4); }

.wrap { width: min(1180px, 100% - 2 * var(--space-5)); margin-inline: auto; }

/* ---------- header ---------- */
.site-header .wrap { border-bottom: 1px solid var(--color-line); }
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; gap: var(--space-4); min-height: 76px; }
.logo { display: inline-flex; align-items: center; color: var(--color-ink); text-decoration: none; line-height: 0; border-radius: var(--radius-sm); }
.logo svg { height: 44px; width: auto; display: block; overflow: visible; }
.logo .r { fill: var(--color-red); }
.logo .rs { stroke: var(--color-red); }
.logo-foot svg { height: 28px; }
.nav { display: flex; align-items: center; gap: var(--space-6); }
.nav a:not(.btn) { text-decoration: none; font-weight: 600; font-size: var(--text-sm); white-space: nowrap; }
.nav a:not(.btn):hover { color: var(--color-red); }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: var(--space-2);
  min-height: 44px; padding: 0 var(--space-5);
  border: 0; border-radius: var(--radius-pill);
  background: var(--color-red); color: var(--color-on-red);
  font-weight: 700; font-size: var(--text-sm); text-decoration: none; white-space: nowrap; cursor: pointer;
  box-shadow: var(--shadow-btn);
  transition: transform var(--dur-fast) var(--ease-out), background-color var(--dur-fast) var(--ease-out);
}
.btn:hover { background: var(--color-red-deep); }
.btn:active { transform: translateY(1px) scale(0.99); }
.btn:disabled, .btn[aria-disabled="true"] { opacity: 0.55; cursor: not-allowed; }
.btn-lg { min-height: 60px; padding: 0 var(--space-7); font-size: var(--text-lg); }
.btn-block { width: 100%; }

/* ---------- hero ---------- */
.wires-host { position: relative; isolation: isolate; }
.wires { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; z-index: 2; overflow: visible; }
.hero { padding-block: var(--space-6) var(--space-7); text-align: center; }
.hero h1 { font-size: var(--text-hero); line-height: 1.08; letter-spacing: -0.022em; font-weight: 800; margin: 0 auto; overflow-wrap: anywhere; min-width: 0; text-wrap: balance; }
.hl { color: var(--color-red); }
.hero .lede { margin: var(--space-3) 0 0; font-size: var(--text-lg); color: var(--color-ink-2); }

.stage {
  margin-top: var(--space-6);
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(200px, 262px) minmax(0, 1fr);
  gap: var(--space-8); align-items: center;
}
.services { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--space-5); position: relative; z-index: 3; }
.stage > .services { width: 100%; max-width: 340px; }
.stage > .services:first-child { justify-self: start; }
.stage > .services:last-child { justify-self: end; }
.svc {
  display: flex; align-items: center; gap: var(--space-4);
  min-height: 68px; padding: 0 var(--space-5);
  border: 1px solid var(--color-silver); border-radius: var(--radius-md);
  background: var(--color-paper); box-shadow: var(--shadow-card);
  text-decoration: none; font-weight: 700; font-size: var(--text-lg);
  transition: border-color var(--dur-fast) var(--ease-out), background-color var(--dur-fast) var(--ease-out), transform var(--dur-fast) var(--ease-out);
}
.svc svg.ico { width: 28px; height: 28px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.svc .label { flex: 1; min-width: 0; text-align: left; white-space: nowrap; }
.svc .arrow { width: 22px; height: 22px; flex: none; fill: none; stroke: var(--color-ink-2); stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; transition: transform var(--dur-fast) var(--ease-out); }
.svc:hover .arrow, .svc:focus-visible .arrow { transform: translateX(3px); }
.svc.is-active { border-color: var(--color-red); background: var(--color-red-wash); color: var(--color-red-deep); }
.svc.is-active .arrow { stroke: var(--color-red-deep); }
.svc:active { transform: scale(0.99); }

.console { position: relative; z-index: 1; justify-self: center; width: 100%; aspect-ratio: 262 / 420; pointer-events: none; }
/* square 3D render (img/centrala-3d.webp): the device sits in the middle, the margins overflow the column */
.console img { position: absolute; top: 0; left: -30.15%; width: 160.3%; max-width: none; height: auto; }
/* one soft contact shadow under every 3D object, added in CSS so the assets stay shadow-free */
.console::after { content: ""; position: absolute; left: 6%; right: 16%; bottom: 11%; height: 5%; border-radius: 50%; background: radial-gradient(closest-side, var(--shadow-ground), transparent); z-index: -1; }
.q-art::after { content: ""; position: absolute; left: 12%; right: 12%; bottom: -2%; height: 7%; border-radius: 50%; background: radial-gradient(closest-side, var(--shadow-ground), transparent); z-index: -1; }
/* Name plate: covers the CENTRALA lettering between the two screws of the chrome plate on
   img/centrala-3d.webp (plate inner area x .3164-.5527, y .1631-.2158 of the image box) with the same
   brushed chrome, and carries the approved lockup as if engraved. Positions follow the image box:
   desktop image = 160.3% of the console width at left -30.15%, mobile = 136% at left -18%, top -6%. */
.plate-logo {
  position: absolute; z-index: 1; pointer-events: none;
  left: 20.57%; width: 37.88%; top: 16.31%; height: 5.27%;
  display: flex; align-items: center; justify-content: center;
  background: linear-gradient(180deg, #c6c6c7 0%, #c2c2c2 30%, #bdbdbd 70%, #b9b9b9 100%);
  -webkit-mask-image: linear-gradient(90deg, transparent 0, #000 7%, #000 93%, transparent 100%);
  mask-image: linear-gradient(90deg, transparent 0, #000 7%, #000 93%, transparent 100%);
  color: #26262a;
}
.plate-logo svg { height: 88%; max-width: 90%; width: auto; display: block; overflow: visible; filter: drop-shadow(0 0.06em 0 rgba(255, 255, 255, 0.55)); }
/* contact page: portrait img/centrala.webp, the plate box is the .q-art box (plate inner x .1875-.5938, y .0868-.1513) */
.q-art-sm .plate-logo { left: 18.75%; width: 40.63%; top: 8.68%; height: 6.45%; }
.plate-logo .r { fill: var(--color-red-deep); }
.plate-logo .rs { stroke: var(--color-red-deep); }
.console .led {
  position: absolute; width: 9px; height: 9px; border-radius: 50%; translate: -50% -50%;
  background: var(--color-red); box-shadow: var(--shadow-led);
  opacity: 0; transition: opacity var(--dur-mid) var(--ease-out);
}
.console .led.on { opacity: 1; }

.hero-cta { margin-top: var(--space-5); }

/* cable */
/* thick glossy cable, built from five strokes: page shadow, dark underside, body, glow, specular line */
.cable-ground, .cable-edge, .cable-body, .cable-glow, .cable-spec { fill: none; stroke-linecap: round; stroke-linejoin: round; }
.cable-ground { stroke: var(--shadow-ground); stroke-width: 14; opacity: 0.9; }
.cable-edge { stroke: var(--color-red-shadow); stroke-width: 15; }
.cable-body { stroke: var(--color-red); stroke-width: 12; }
.cable-glow { stroke: var(--color-red-hi); stroke-width: 5; opacity: 0.55; }
.cable-spec { stroke: var(--color-cable-shine); stroke-width: 2.2; opacity: 0.95; }
/* a light pulse runs along the cable when a service is clicked */
.signal { fill: var(--color-paper); filter: drop-shadow(0 0 4px var(--color-paper)) drop-shadow(0 0 8px var(--color-red-hi)); }
.svc.is-plugged { animation: plugged var(--dur-mid) var(--ease-out); }
@keyframes plugged { 30% { transform: translateX(calc(var(--nudge, 0px))); } }
.svc[data-side="left"].is-plugged { --nudge: -2px; }
.svc[data-side="right"].is-plugged { --nudge: 2px; }

/* ---------- calculator ---------- */
.calc { padding-block: var(--space-9) var(--space-8); text-align: center; border-top: 1px solid var(--color-line); }
.calc h2, .about h2 { font-size: var(--text-2xl); letter-spacing: -0.02em; line-height: 1.1; margin: 0; font-weight: 800; overflow-wrap: anywhere; min-width: 0; text-wrap: balance; }
.controls { margin: var(--space-7) auto 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--space-6); max-width: 980px; }
.control { display: grid; gap: var(--space-3); justify-items: center; }
.control .ctl-label { font-weight: 700; font-size: var(--text-md); }
.stepper { display: inline-flex; align-items: center; gap: var(--space-2); padding: var(--space-1); border-radius: var(--radius-pill); background: var(--well); box-shadow: var(--shadow-well); }
.stepper output { min-width: 5.5ch; font-weight: 800; font-size: var(--text-xl); font-variant-numeric: tabular-nums; }
.step {
  width: 52px; height: 44px; border: 0; border-radius: var(--radius-pill); cursor: pointer;
  background: var(--gloss-red);
  box-shadow: var(--shadow-knob);
  display: grid; place-items: center;
  transition: transform var(--dur-fast) var(--ease-out), box-shadow var(--dur-fast) var(--ease-out);
}
.step svg { width: 20px; height: 20px; stroke: var(--color-on-red); stroke-width: 3.2; stroke-linecap: round; fill: none; }
.step:active { transform: scale(0.92, 0.86); box-shadow: var(--shadow-knob-press); }
.step:disabled { filter: grayscale(1); opacity: 0.55; cursor: not-allowed; }

.toggle { display: inline-grid; grid-template-columns: 1fr 1fr; padding: var(--space-1); border-radius: var(--radius-pill); background: var(--well); box-shadow: var(--shadow-well); }
.toggle input { position: absolute; opacity: 0; pointer-events: none; }
.toggle label { padding: var(--space-2) var(--space-5); border-radius: var(--radius-pill); font-weight: 800; font-size: var(--text-lg); cursor: pointer; white-space: nowrap; transition: background-color var(--dur-fast) var(--ease-out), color var(--dur-fast) var(--ease-out); }
.toggle input:checked + label { background: var(--gloss-red); color: var(--color-on-red); box-shadow: var(--shadow-knob-flat); }
/* the red knob slides between "1 din 3" and "1 din 5" */
@supports selector(:has(*)) {
  .toggle { position: relative; isolation: isolate; }
  .toggle::before { content: ""; position: absolute; z-index: -1; top: var(--space-1); bottom: var(--space-1); left: var(--space-1); width: calc(50% - var(--space-1)); border-radius: var(--radius-pill); background: var(--gloss-red); box-shadow: var(--shadow-knob-flat); transition: transform 240ms cubic-bezier(0.77, 0, 0.175, 1); }
  .toggle:has(input:nth-of-type(2):checked)::before { transform: translateX(100%); }
  .toggle input:checked + label { background: none; box-shadow: none; }
}
.toggle input:focus-visible + label { outline: 3px solid var(--color-focus); outline-offset: 2px; }

.result { margin-top: var(--space-7); }
.result .r-label { font-weight: 800; font-size: var(--text-xl); margin: 0; }
/* Astra coin calculator (js/calculator.js via js/coins-init.js): the canvas layer covers the controls and
   the result so coins can drop from the "+" buttons; #coin-stage is the fixed number space (no layout jump). */
/* Astra's calculator cable (cables.js): the section sits above the cable canvas (z 2), as in the package README */
section.calc { position: relative; z-index: 3; }
.calc-body { position: relative; isolation: isolate; }
.calc-body .controls { position: relative; z-index: 2; }
.coin-layer { position: absolute; inset: 0; z-index: 1; pointer-events: none; }
.coin-layer canvas { display: block; width: 100%; height: 100%; pointer-events: none; }
.coin-stage { position: relative; margin: var(--space-4) auto 0; width: 100%; max-width: 760px; height: 270px; display: grid; place-items: center; }
@media (min-width: 1440px) { .coin-stage { height: 310px; } }
@media (max-width: 700px) { .coin-stage { height: 200px; } }
.coin-stage .num-html { margin: 0; display: none; font-weight: 800; font-size: clamp(3rem, 2rem + 6vw, 7rem); letter-spacing: -0.04em; color: var(--color-red); line-height: 1; font-variant-numeric: tabular-nums; }
.coin-stage .num-html small { font-size: 0.4em; color: var(--color-silver-lo); letter-spacing: 0; margin-left: 0.15em; }
.coin-stage.coins-fallback .num-html { display: block; font-size: clamp(3.25rem, 1.5rem + 8vw, 8.25rem); }
.per { margin: var(--space-2) 0 0; font-weight: 700; font-size: var(--text-xl); color: var(--color-ink); }
.year { margin: var(--space-1) 0 0; font-weight: 700; font-size: var(--text-lg); color: var(--color-ink-2); }
.calc .btn { margin-top: var(--space-6); }
.method { margin: var(--space-5) auto 0; max-width: 62ch; font-size: var(--text-xs); color: var(--color-ink-2); }

/* ---------- about ---------- */
.about { padding-block: var(--space-9); border-top: 1px solid var(--color-line); }
.about .grid { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: var(--space-8); align-items: start; }
.about p { margin: var(--space-4) 0 0; color: var(--color-ink-2); max-width: 52ch; }
/* the three steps hang on one red cable, each on a chrome jack */
.steps { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--space-6); counter-reset: s; position: relative; }
.steps::before { content: ""; position: absolute; left: 19px; top: 20px; bottom: 20px; width: 6px; border-radius: var(--radius-pill); background: var(--color-red); box-shadow: inset 2px 0 0 var(--color-cable-shine), 1px 0 0 var(--color-red-shadow); }
.steps li { counter-increment: s; position: relative; display: grid; grid-template-columns: 44px minmax(0, 1fr); gap: var(--space-5); align-items: center; }
.steps li::before { content: counter(s); width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; font-weight: 800; color: var(--color-ink); background: var(--well); border: 3px solid var(--color-paper); box-shadow: var(--shadow-jack); position: relative; }
/* about: once in view the cable draws down and each jack lights as it is reached (html.motion is set by js/home.js) */
/* GSAP ScrollTrigger path: the cable follows the scroll, each jack lights when the cable reaches it */
html.gsap-steps .steps::before { transform-origin: top; transform: scaleY(var(--line, 1)); }
html.gsap-steps .steps li::before { opacity: 0; transform: scale(0.6); transition: opacity 240ms ease-out, transform 480ms cubic-bezier(0.16, 1, 0.3, 1); }
html.gsap-steps .steps li > div { opacity: 0; transform: translateX(-10px); transition: opacity 360ms ease-out, transform 520ms cubic-bezier(0.16, 1, 0.3, 1); }
html.gsap-steps .steps li.is-lit::before, html.gsap-steps .steps li.is-lit > div { opacity: 1; transform: none; }
html.motion .steps::before { transform-origin: top; transform: scaleY(0); transition: transform 1100ms cubic-bezier(0.16, 1, 0.3, 1); }
html.motion .steps li::before { opacity: 0; transform: scale(0.6); transition: opacity 240ms ease-out, transform 480ms cubic-bezier(0.16, 1, 0.3, 1); }
html.motion .steps li > div { opacity: 0; transform: translateX(-10px); transition: opacity 360ms ease-out, transform 520ms cubic-bezier(0.16, 1, 0.3, 1); }
html.motion .steps.is-on::before { transform: none; }
html.motion .steps.is-on li::before, html.motion .steps.is-on li > div { opacity: 1; transform: none; }
html.motion .steps.is-on li:nth-child(2)::before, html.motion .steps.is-on li:nth-child(2) > div { transition-delay: 330ms; }
html.motion .steps.is-on li:nth-child(3)::before, html.motion .steps.is-on li:nth-child(3) > div { transition-delay: 660ms; }
.steps h3 { margin: 0; font-size: var(--text-lg); letter-spacing: -0.01em; }
.steps p { margin: var(--space-1) 0 0; font-size: var(--text-sm); }

/* ---------- footer ---------- */
.site-footer { border-top: 1px solid var(--color-line); padding-block: var(--space-7); font-size: var(--text-sm); color: var(--color-ink-2); }
.site-footer .wrap { display: flex; flex-wrap: wrap; gap: var(--space-5) var(--space-7); align-items: center; justify-content: space-between; }
.site-footer .legal { margin: 0; }
.site-footer nav { display: flex; flex-wrap: wrap; gap: var(--space-5); }
.site-footer nav a { white-space: nowrap; }
.tbd { background: var(--color-tbd-bg); color: var(--color-tbd-ink); padding: 0 var(--space-1); border-radius: var(--space-1); }

/* ---------- quote page ---------- */
.quote { padding-block: var(--space-5) var(--space-8); }
.back { display: inline-flex; align-items: center; gap: var(--space-2); font-weight: 600; text-decoration: none; min-height: 44px; }
.back svg { width: 20px; height: 20px; stroke: currentColor; stroke-width: 2; fill: none; stroke-linecap: round; stroke-linejoin: round; }
.back:hover { color: var(--color-red); }
.q-grid { position: relative; isolation: isolate; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.12fr); gap: 0; align-items: start; }
.q-side { padding-right: var(--space-6); }
.q-side .back { margin-bottom: var(--space-6); }
.q-kicker { margin: 0; color: var(--color-red-deep); font-weight: 800; font-size: var(--text-sm); text-transform: uppercase; letter-spacing: 0.06em; }
.q-side h1 { margin: var(--space-2) 0 0; font-size: var(--text-display); line-height: 1.04; letter-spacing: -0.022em; font-weight: 800; overflow-wrap: anywhere; min-width: 0; }
.q-side h1.h-long { font-size: var(--text-2xl); }
.q-side .lede { margin: var(--space-3) 0 0; font-size: var(--text-lg); color: var(--color-ink-2); }
.q-art { margin: var(--space-6) 0 0; position: relative; z-index: 1; width: fit-content; max-width: 100%; }
.q-art img { position: relative; width: auto; max-width: min(100%, 440px); max-height: 400px; height: auto; }
.q-art-sm img { max-height: 300px; }
/* Three.js cables (js/cables.js): canvas at z-index 2 between the objects (1) and cards / form (3) */
.cables-fallback[hidden] { display: none; }
.cables-pending > .wires { visibility: hidden; }
/* intro: the cable joins after the console and services have landed (js/home.js) */
.wires-host .pixelplay-cables, .wires-host > .wires { transition: opacity 260ms cubic-bezier(0.16, 1, 0.3, 1); }
.wires-host.is-intro .pixelplay-cables, .wires-host.is-intro > .wires { opacity: 0; transition: none; }
.q-grid.cable-hold .pixelplay-cables { opacity: 0 !important; }
.q-wire { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; z-index: 2; overflow: visible; }

.form-card { position: relative; z-index: 3; border: 1px solid var(--color-silver); border-radius: var(--radius-lg); padding: var(--space-5) var(--space-6); background: var(--color-paper); box-shadow: var(--shadow-card); }
.form-card h2 { margin: 0 0 var(--space-4); font-size: var(--text-xl); letter-spacing: -0.02em; }
.field { display: grid; gap: var(--space-1); margin-bottom: var(--space-2); min-width: 0; }
.field > label, .field > legend, .field .f-label { font-weight: 700; font-size: var(--text-sm); }
.req { color: var(--color-red-deep); }
.opt { font-weight: 500; color: var(--color-ink-2); }
fieldset.field { border: 0; padding: 0; margin: 0 0 var(--space-3); }
fieldset.field legend { padding: 0; margin-bottom: var(--space-2); }
.hint { font-size: var(--text-xs); color: var(--color-ink-2); font-weight: 500; }
.row-2 { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 0 var(--space-4); align-items: start; }
.input, .select, .textarea {
  width: 100%; min-height: 46px; padding: 0 var(--space-4);
  border: 1px solid var(--color-field); border-radius: var(--radius-sm); background: var(--color-paper); color: var(--color-ink);
  outline: 2px solid transparent; outline-offset: 1px;
  transition: border-color var(--dur-fast) var(--ease-out);
}
.textarea { min-height: 72px; padding: var(--space-3) var(--space-4); resize: vertical; }
.select { appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23111114' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 14px center; background-size: 20px; padding-right: var(--space-7); }
.input:hover, .select:hover, .textarea:hover { border-color: var(--color-ink-2); }
.input:focus-visible, .select:focus-visible, .textarea:focus-visible { outline: 2px solid var(--color-focus); outline-offset: 1px; border-color: var(--color-ink); }
.field.has-error .input { border-color: var(--color-red-deep); }
.err { display: block; min-height: 1lh; color: var(--color-red-deep); font-size: var(--text-xs); font-weight: 600; line-height: 1.4; }

.chips { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--space-2); }
.chip input { position: absolute; opacity: 0; pointer-events: none; }
.chip span {
  display: flex; align-items: center; justify-content: center; gap: var(--space-1); min-height: 46px; padding: var(--space-1) var(--space-3); text-align: center;
  border: 1px solid var(--color-field); border-radius: var(--radius-sm); cursor: pointer; font-weight: 600; font-size: var(--text-sm); line-height: 1.2;
  transition: border-color var(--dur-fast) var(--ease-out), background-color var(--dur-fast) var(--ease-out), color var(--dur-fast) var(--ease-out);
}
.chip span:hover { border-color: var(--color-ink-2); }
.chip input:checked + span { border-color: var(--color-red); background: var(--color-red-wash); color: var(--color-red-deep); }
.chip input:checked + span::before { content: "✓"; font-weight: 800; }
.chip input:focus-visible + span { outline: 3px solid var(--color-focus); outline-offset: 2px; }
.consent { margin: 0 0 var(--space-3); font-size: var(--text-xs); color: var(--color-ink-2); }
.form-status { margin: var(--space-4) 0 0; padding: var(--space-4); border-radius: var(--radius-sm); font-size: var(--text-sm); display: none; }
.form-status.is-shown { display: block; }
.form-status.ok { background: var(--color-ok-bg); color: var(--color-ok-ink); }
.form-status.bad { background: var(--color-red-wash); color: var(--color-red-deep); }
.btn.is-loading { pointer-events: none; opacity: 0.8; }
/* sending: a light signal runs along the button; sent: the confirmation slides up and its check draws itself */
.btn.is-loading { position: relative; overflow: hidden; }
.btn.is-loading::after { content: ""; position: absolute; left: 0; bottom: 0; width: 30%; height: 3px; border-radius: var(--radius-pill); background: var(--color-red-hi); animation: pp-signal 1100ms linear infinite; }
@keyframes pp-signal { from { transform: translateX(-100%); } to { transform: translateX(340%); } }
.form-status.ok.is-shown { display: flex; gap: var(--space-3); align-items: flex-start; animation: pp-plug 520ms cubic-bezier(0.23, 1, 0.32, 1) both; }
.ok-jack { flex: none; width: 24px; height: 24px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.ok-jack path { stroke-dasharray: 16; stroke-dashoffset: 16; animation: pp-draw 360ms cubic-bezier(0.23, 1, 0.32, 1) 200ms forwards; }
@keyframes pp-plug { from { opacity: 0; transform: translateY(8px); } }
@keyframes pp-draw { to { stroke-dashoffset: 0; } }

/* smooth anchor scroll for the header links */
@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }
/* Lenis (js/smooth-scroll.js) drives the wheel scroll; native smooth scrolling must not fight it */
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }
.lenis.lenis-smooth [data-lenis-prevent] { overscroll-behavior: contain; }
.lenis.lenis-stopped { overflow: hidden; }
[id] { scroll-margin-top: var(--space-5); }
.form-card .btn-lg { min-height: 52px; }

/* ---------- legal page ---------- */
.prose { padding-block: var(--space-8); max-width: 70ch; }
.prose h1 { font-size: var(--text-2xl); letter-spacing: -0.03em; }
.prose .updated { margin: 0 0 var(--space-6); font-size: var(--text-sm); color: var(--color-ink-2); }
.prose h2 { margin: var(--space-7) 0 var(--space-3); font-size: var(--text-xl); letter-spacing: -0.02em; line-height: 1.2; }
.prose p, .prose li { color: var(--color-ink-2); line-height: 1.65; }
.prose ul { margin: var(--space-3) 0; padding-left: 1.2em; display: grid; gap: var(--space-2); }
.prose strong { color: var(--color-ink); }
.prose a { color: var(--color-red-deep); text-underline-offset: 0.18em; }

/* ---------- responsive ---------- */
@media (max-width: 960px) {
  .hero .wrap { display: flex; flex-direction: column; align-items: center; }
  .stage { display: contents; }
  .console { order: 1; width: min(250px, 64vw); aspect-ratio: 250 / 305; margin-top: var(--space-5); }
  .console img { width: 136%; left: -18%; top: -6%; }
  .plate-logo { left: 25.03%; width: 32.14%; top: 12.19%; height: 5.88%; }
  .console::after { left: 8%; right: 14%; bottom: 4%; }
  .cables-fallback, .pixelplay-cables { display: none !important; }
  .console .led { display: none; }
  .hero-cta { order: 2; }
  .services { order: 3; width: 100%; gap: var(--space-3); margin-top: var(--space-3); }
  .services:first-of-type { margin-top: var(--space-6); }
  .wires .hero-wire { display: none; }
  .about .grid { grid-template-columns: minmax(0, 1fr); gap: var(--space-6); }
  .q-grid { grid-template-columns: minmax(0, 1fr); }
  .q-side { padding: 0; }
  .q-side .back { margin-bottom: var(--space-4); }
  .q-art { margin: var(--space-4) auto var(--space-5); }
  .q-art img { max-height: 240px; }
}
@media (max-width: 760px) {
  .controls { grid-template-columns: minmax(0, 1fr); gap: var(--space-5); }
  .nav { gap: var(--space-4); }
  .nav a.hide-sm { display: none; }
  .hero { padding-top: var(--space-6); }
  .btn-lg { min-height: 54px; padding: 0 var(--space-5); font-size: var(--text-md); }
  .row-2 { grid-template-columns: minmax(0, 1fr); }
  .form-card { padding: var(--space-5); }
}
@media (max-width: 420px) {
  .logo svg { height: 30px; }
  .nav a:not(.btn) { display: none; }
  .nav .btn { padding: 0 var(--space-4); }
  .chips { grid-template-columns: minmax(0, 1fr); }
  .svc { font-size: var(--text-md); }
  .toggle label { padding: var(--space-2) var(--space-4); }
}
@media (prefers-reduced-motion: reduce) {
  .btn.is-loading::after { display: none; }
  *, *::before, *::after { transition-duration: 1ms !important; animation-duration: 1ms !important; }
}
