/* v4 — the combined edition.
   Layout: light workshop page under a steel entry door. A header pipeline (collect → manage → publish → visualize)
   tracks the reader; numbered § sections borrow the datasheet voice; one orange accent ties it together. */
:root {
  --bg: #eef0f2;
  --surface: #ffffff;
  --ink: #16191d;
  --muted: #5b636d;
  --line: #d5dae0;
  --soft: #e6e9ed;
  --orange: #ff5a1f;      /* the one accent: robot orange */
  --steel: #1b1e22;
  --hazard: #f5c400;      /* door edge only */
  --pcb: #13513e;         /* circuit board only */
  --ok: #17a05d;
  --bad: #d23c2f;
  --display: "Chakra Petch", "Barlow", system-ui, sans-serif;
  --sans: "Barlow", system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "JetBrains Mono", ui-monospace, Menlo, monospace;
  color-scheme: light;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 76px; }
body {
  margin: 0; color: var(--ink); font: 400 18px/1.6 var(--sans); overflow-x: hidden;
  background: radial-gradient(circle, rgba(22,25,29,.07) 1px, transparent 1.2px) 0 0 / 28px 28px, var(--bg);
}
body.locked { overflow: hidden; }
a { color: inherit; }
:focus-visible { outline: 3px solid var(--orange); outline-offset: 3px; }
::selection { background: var(--orange); color: #fff; }
.mono { font-family: var(--mono); }
.dim { color: var(--muted); }

/* =================== GATE =================== */
#gate { position: fixed; inset: 0; z-index: 60; pointer-events: none; }
.gate-panel {
  position: absolute; inset: 0; pointer-events: auto; cursor: grab; touch-action: none; user-select: none;
  background: repeating-linear-gradient(90deg, rgba(255,255,255,.018) 0 2px, transparent 2px 5px), linear-gradient(115deg, #2a2e34, #1b1e22 45%, #24282e);
  box-shadow: 30px 0 60px rgba(0,0,0,.35); display: grid; place-items: center; color: #e9ecef; will-change: transform;
}
.gate-panel.dragging { cursor: grabbing; }
.gate-panel.release { transition: transform .5s cubic-bezier(.3,1.4,.5,1); }
.gate-panel.open { transition: transform .95s cubic-bezier(.7,0,.2,1); transform: translateX(105%) !important; }
.hazard { position: absolute; top: 0; bottom: 0; right: 0; width: 28px; background: repeating-linear-gradient(-45deg, var(--hazard) 0 16px, var(--steel) 16px 32px); }
.rivet { position: absolute; width: 12px; height: 12px; border-radius: 50%; background: radial-gradient(circle at 35% 35%, #8b939c, #3b4148); }
.rivet.tl { top: 22px; left: 22px; } .rivet.tr { top: 22px; right: 50px; } .rivet.bl { bottom: 22px; left: 22px; } .rivet.br { bottom: 22px; right: 50px; }
.gate-inner { width: min(660px, 84vw); padding-right: 28px; }
.gate-id { font-size: 12px; letter-spacing: .14em; color: #8b939c; margin: 0 0 18px; }
.gate-title { font: 700 clamp(60px, 12vw, 132px)/.9 var(--display); margin: 0; text-transform: uppercase; }
.gate-sub { color: #aab2bb; font-size: clamp(16px, 2vw, 20px); margin: 18px 0 30px; }
.gate-status { display: flex; align-items: center; gap: 10px; font-size: 13px; color: #aab2bb; margin-bottom: 12px; text-transform: uppercase; letter-spacing: .08em; }
.gate-status i { width: 10px; height: 10px; border-radius: 50%; background: #e5484d; box-shadow: 0 0 10px #e5484d; transition: all .2s; }
.gate-status i.go { background: #3ddc97; box-shadow: 0 0 12px #3ddc97; }
.gate-status b { margin-left: auto; color: #fff; font-weight: 500; font-variant-numeric: tabular-nums; }
.track-wrap { position: relative; padding-top: 30px; }
.track { position: relative; height: 72px; border-radius: 36px; background: #121417; border: 1px solid #3b4148; box-shadow: inset 0 2px 8px rgba(0,0,0,.6); overflow: hidden; }
.track-fill { position: absolute; left: 0; top: 0; bottom: 0; width: 0; background: linear-gradient(90deg, rgba(255,90,31,.12), rgba(255,90,31,.45)); }
.track-label { position: absolute; inset: 0; display: grid; place-items: center; padding-left: 60px; white-space: nowrap;
  font: 600 15px var(--display); letter-spacing: .12em; text-transform: uppercase;
  background: linear-gradient(90deg, #6f7780 0 40%, #fff 50%, #6f7780 60% 100%) 0 0 / 300% 100%; -webkit-background-clip: text; background-clip: text; color: transparent; animation: shine 2.4s linear infinite; }
@keyframes shine { from { background-position: 100% 0; } to { background-position: -50% 0; } }
.knob { position: absolute; left: 4px; top: 4px; width: 64px; height: 64px; border-radius: 50%; border: 0; cursor: grab; touch-action: none; z-index: 2;
  background: var(--orange); box-shadow: 0 6px 18px rgba(255,90,31,.45), inset 0 -3px 0 rgba(0,0,0,.18); display: grid; place-items: center; }
.knob svg { width: 28px; height: 28px; fill: none; stroke: #fff; stroke-width: 2.6; stroke-linecap: round; stroke-linejoin: round; }
.knob.nudge { animation: nudge 1.2s ease-in-out; }
@keyframes nudge { 30% { transform: translateX(26px); } 60% { transform: translateX(0); } 75% { transform: translateX(10px); } }
/* the engineer, pushing the handle */
.man { position: absolute; left: -48px; bottom: -6px; width: 58px; height: 76px; overflow: visible; z-index: 3; pointer-events: none; }
.man path, .man circle { fill: none; stroke: #e9ecef; stroke-width: 4; stroke-linecap: round; stroke-linejoin: round; }
.man .head { fill: #1b1e22; }
.man .cap { stroke: var(--orange); stroke-width: 3.5; }
.man .leg, .man .arm { transform-box: view-box; }
.man .leg { transform-origin: 26px 52px; } .man .arm { transform-origin: 38px 30px; }
.man.walk .leg.front { animation: stepF .45s ease-in-out infinite alternate; }
.man.walk .leg.back { animation: stepB .45s ease-in-out infinite alternate; }
.man.walk .body { animation: bob .22s ease-in-out infinite alternate; }
@keyframes stepF { from { transform: rotate(-22deg); } to { transform: rotate(14deg); } }
@keyframes stepB { from { transform: rotate(16deg); } to { transform: rotate(-20deg); } }
@keyframes bob { to { transform: translateY(-1.5px); } }
.gate-hint { font-size: 12px; color: #6f7780; margin-top: 14px; text-align: center; }
.gate-skip { position: absolute; right: 84px; bottom: 16px; pointer-events: auto; background: none; border: 0; color: #8b939c; font-size: 12px; cursor: pointer; letter-spacing: .1em; text-transform: uppercase; }
.gate-skip:hover { color: #fff; }

#site, .top { transition: transform .9s cubic-bezier(.2,.8,.2,1), opacity .9s; }
body.locked #site, body.locked .top { transform: scale(.96); opacity: .6; }

/* =================== HEADER =================== */
.top {
  position: fixed; top: 0; left: 0; right: 0; z-index: 30; display: flex; align-items: center; gap: 22px;
  padding: calc(12px + env(safe-area-inset-top, 0px)) max(20px, 3vw) 12px;
  background: rgba(238,240,242,.88); backdrop-filter: blur(10px); border-bottom: 1px solid var(--line);
}
.logo { display: flex; align-items: center; gap: 8px; font: 700 18px var(--display); text-decoration: none; white-space: nowrap; }
.logo span:last-child { color: var(--muted); font-weight: 500; }
.logo-mark { width: 13px; height: 13px; background: var(--orange); border-radius: 3px; transform: rotate(45deg); }
.pipe { list-style: none; margin: 0 0 0 auto; padding: 0; display: flex; align-items: center; }
.pipe li { display: flex; align-items: center; }
.pipe li + li::before { content: ""; width: 18px; height: 2px; background: var(--line); transition: background .3s; }
.pipe li.on + li::before { background: var(--ink); }
.pipe a { display: flex; align-items: center; gap: 8px; text-decoration: none; padding: 6px 12px; border-radius: 20px; border: 1px solid var(--line); background: var(--surface); color: var(--muted); transition: all .3s; font-variant-numeric: tabular-nums; }
.pipe i { width: 8px; height: 8px; border-radius: 50%; border: 2px solid var(--line); transition: all .3s; }
.pipe .pn { font: 600 12px var(--display); letter-spacing: .08em; text-transform: uppercase; }
.pipe b { font: 500 12px var(--mono); color: var(--ink); min-width: 2ch; }
.pipe li.on a { color: var(--ink); border-color: var(--ink); }
.pipe li.on i { background: var(--ink); border-color: var(--ink); }
.pipe li.cur a { background: var(--steel); color: #fff; border-color: var(--steel); }
.pipe li.cur b { color: #ffb18f; }
.pipe li.cur i { background: var(--orange); border-color: var(--orange); animation: blink 1s infinite; }
@keyframes blink { 50% { opacity: .35; } }
.page { font-size: 12px; color: var(--muted); white-space: nowrap; font-variant-numeric: tabular-nums; }
.progress { position: absolute; left: 0; bottom: -1px; height: 2px; width: 0; background: var(--orange); }

/* =================== COMMON =================== */
.kicker { font-size: 13px; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); margin: 0 0 14px; }
.sn { color: var(--orange); font-weight: 600; margin-right: 10px; }
h2, h3 { margin: 0; text-wrap: balance; }
.sec { max-width: 1280px; margin: 0 auto; padding: 110px max(20px, 4vw) 90px; }
.sec-head { max-width: 760px; margin-bottom: 36px; }
.sec-head h2, .pin-text h2 { font: 700 clamp(32px, 4.2vw, 54px)/1.05 var(--display); }
.sec-sub { color: var(--muted); margin: 14px 0 0; max-width: 64ch; }
.btn { display: inline-flex; align-items: center; font: 600 16px var(--sans); text-decoration: none; padding: 13px 22px; border-radius: 8px; border: 2px solid var(--ink); background: var(--ink); color: #fff; cursor: pointer; transition: transform .2s, background .2s, border-color .2s, color .2s; }
.btn:hover { transform: translateY(-2px); background: var(--orange); border-color: var(--orange); }
.btn.ghost { background: transparent; color: var(--ink); }
.btn.ghost:hover { color: #fff; }
.note { font-size: 12px; color: var(--muted); margin-top: 16px; }
.tip { position: absolute; pointer-events: none; background: var(--ink); color: #fff; font: 12px var(--mono); padding: 6px 9px; border-radius: 4px; max-width: 260px; transform: translate(-50%, -115%); z-index: 5; }

/* =================== HERO =================== */
.hero { position: relative; min-height: 100vh; max-width: 1280px; margin: 0 auto; padding: 110px max(20px, 4vw) 70px; display: grid; grid-template-columns: 1.05fr .95fr; gap: 36px; align-items: center; }
.hero .kicker { color: var(--orange); }
.hero-title { font: 700 clamp(40px, 4.8vw, 66px)/1.02 var(--display); }
.hero-title em { font-style: normal; color: var(--orange); }
.lede { font-size: clamp(18px, 1.6vw, 21px); color: #3b434c; max-width: 54ch; margin: 24px 0 0; }
.lede b { color: var(--ink); font-weight: 600; }
.hero-cta { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 30px; }
.hero-stats { display: flex; gap: 36px; margin: 38px 0 0; flex-wrap: wrap; }
.hero-stats div { border-left: 3px solid var(--orange); padding-left: 12px; }
.hero-stats dt { font: 700 30px var(--display); font-variant-numeric: tabular-nums; }
.hero-stats dd { margin: 0; color: var(--muted); font-size: 14px; }
.arm-wrap { margin: 0; min-width: 0; }
#arm { width: 100%; height: auto; display: block; background: var(--surface); border: 1px solid var(--line); border-radius: 16px; cursor: crosshair; }
#arm .gridline { stroke: #edf0f2; }
#arm .reach { fill: none; stroke: #e1e5ea; stroke-width: 1.5; stroke-dasharray: 4 6; }
#arm .base { fill: var(--steel); } #arm .base2 { fill: #3b4148; }
#arm .link { stroke: var(--orange); stroke-width: 34; stroke-linecap: round; } #arm .link.l2 { stroke-width: 24; }
#arm .joint { fill: var(--steel); stroke: #fff; stroke-width: 4; } #arm .joint.small { stroke-width: 3; }
#arm .joint-dot { fill: var(--orange); }
#arm .finger { fill: none; stroke: var(--steel); stroke-width: 8; stroke-linecap: round; stroke-linejoin: round; }
#arm .tgt { fill: rgba(255,90,31,.12); stroke: var(--orange); stroke-width: 2; } #arm .tgt-x { stroke: var(--orange); stroke-width: 2; }
.arm-hud { display: flex; gap: 18px; flex-wrap: wrap; font-size: 12px; color: var(--muted); margin-top: 10px; padding: 0 4px; }
.arm-hud b { color: var(--ink); font-weight: 500; font-variant-numeric: tabular-nums; }
.scroll-hint { position: absolute; left: 50%; bottom: 22px; transform: translateX(-50%); font-size: 12px; color: var(--muted); text-decoration: none; display: flex; flex-direction: column; align-items: center; gap: 8px; }
.scroll-hint i { width: 1px; height: 34px; background: linear-gradient(var(--ink), transparent); animation: drip 1.8s infinite; }
@keyframes drip { 0% { transform: scaleY(0); transform-origin: top; } 50% { transform: scaleY(1); transform-origin: top; } 51% { transform-origin: bottom; } 100% { transform: scaleY(0); transform-origin: bottom; } }

/* =================== §1 ABOUT =================== */
.about { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; align-items: stretch; }
.card-plain { background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 26px; }
.prose p { margin: 0 0 14px; max-width: 62ch; } .prose p:last-child { margin: 0; }
.prose b { font-weight: 600; }
.json { margin: 0; background: var(--steel); color: #d7dce1; border-radius: 16px; padding: 26px; font: 14px/1.85 var(--mono); white-space: pre-wrap; overflow-x: auto; min-width: 0; }
.json::after { content: "}"; } .json code::before { content: "{\A"; white-space: pre; }
.json .k { color: #8fa3b5; } .json .s { color: #ffb18f; } .json .n { color: #8fd6ae; }

/* =================== §2 PINOUT =================== */
.pinout { height: 400vh; position: relative; }
.pin-sticky { position: sticky; top: 64px; height: calc(100vh - 64px); max-width: 1280px; margin: 0 auto; padding: 24px max(20px, 4vw); display: grid; grid-template-columns: 1fr 1.2fr; gap: 40px; align-items: center; }
.pin-steps { list-style: none; margin: 26px 0 0; padding: 0; display: grid; gap: 4px; }
.pin-steps li { padding: 12px 16px; border-left: 3px solid var(--line); color: var(--muted); border-radius: 0 10px 10px 0; transition: all .3s; }
.pin-steps li b { display: block; font: 700 16px var(--display); }
.pin-steps li span { font-size: 15px; }
.pin-steps li.on { border-color: var(--orange); color: var(--ink); }
.pin-steps li.cur { background: var(--surface); box-shadow: 0 6px 18px -12px rgba(22,25,29,.4); }
.pin-hint { font-size: 12px; color: var(--muted); margin-top: 16px; }
.pin-fig { margin: 0; position: relative; min-width: 0; }
#chip { width: 100%; height: auto; max-height: calc(100vh - 120px); display: block; }
#chip .body { fill: var(--steel); }
#chip .dot { fill: #3a4048; }
#chip .mark { font: 700 26px var(--display); fill: #fff; text-anchor: middle; letter-spacing: .02em; }
#chip .mark2 { font: 500 11px var(--mono); fill: #a7adb5; text-anchor: middle; }
#chip .pad { fill: #c9cdd2; transition: fill .3s; }
#chip .trace { fill: none; stroke: var(--orange); stroke-width: 2.2; stroke-linecap: round; }
#chip .plabel { font: 500 12.5px var(--mono); fill: var(--muted); transition: fill .3s; }
#chip .pnum { font: 500 9px var(--mono); fill: #8b939c; }
#chip .side-on .pad { fill: var(--orange); }
#chip .side-on .plabel { fill: var(--ink); font-weight: 600; }
#chip g.pin:hover .plabel { fill: var(--orange); }

/* =================== §3 DEVICE =================== */
.sim { display: grid; grid-template-columns: .9fr 1.1fr; gap: 20px; align-items: start; }
.sim > div { min-width: 0; display: grid; grid-template-columns: minmax(0, 1fr); gap: 20px; }
.board-card, .shadow-card { background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 18px; }
.board { width: 100%; height: auto; display: block; }
.board .pcb { fill: var(--pcb); }
.board .holes circle { fill: var(--surface); stroke: #c9a227; stroke-width: 2; }
.board .trace path { fill: none; stroke: #2f7a5f; stroke-width: 3; }
.board .mcu { fill: #1b1f24; stroke: #c9cdd2; }
.board .mk { font: 700 13px var(--display); fill: #fff; text-anchor: middle; }
.board .mk.sm { font: 500 9px var(--mono); fill: #a7adb5; }
.board .part { fill: #e9ecef; stroke: #1b1f24; }
.board .lbl { font: 600 9px var(--mono); fill: #e7efe9; text-anchor: middle; } .board .lbl.dark { fill: #1b1f24; }
.board .led { fill: #3d4a44; transition: fill .2s; } .board .led.on { fill: #ffe066; }
.board .led-glow { fill: transparent; transition: fill .2s; } .board .led-glow.on { fill: rgba(255,224,102,.35); }
#relayBox.on { fill: #ffd9c2; stroke: var(--orange); }
.board .wifi { fill: none; stroke: #e7efe9; stroke-width: 2.5; stroke-linecap: round; } .board .wifi-dot { fill: #e7efe9; }
.board .off .wifi { stroke: #7f8e87; } .board .off .wifi-dot { fill: #7f8e87; }
.controls { display: grid; gap: 14px; margin-top: 16px; }
.sw { display: flex; align-items: center; gap: 12px; font-size: 16px; cursor: pointer; }
.sw input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.sw span { width: 42px; height: 24px; border-radius: 12px; background: var(--line); position: relative; transition: background .2s; flex: none; }
.sw span::after { content: ""; position: absolute; top: 3px; left: 3px; width: 18px; height: 18px; border-radius: 50%; background: #fff; transition: transform .2s; box-shadow: 0 1px 2px rgba(0,0,0,.2); }
.sw input:checked + span { background: var(--orange); }
.sw input:checked + span::after { transform: translateX(18px); }
.sw input:focus-visible + span { outline: 3px solid var(--orange); outline-offset: 2px; }
.rng { display: grid; grid-template-columns: 1fr auto; gap: 6px; font-size: 16px; }
.rng b { font: 600 13px var(--mono); }
.rng input { grid-column: 1 / -1; width: 100%; accent-color: var(--orange); }
.card-head { display: flex; justify-content: space-between; font-size: 12px; color: var(--muted); margin-bottom: 8px; }
#shadow { margin: 0; font-size: 12.5px; line-height: 1.6; white-space: pre; overflow-x: auto; color: #3b434c; }
#shadow .k { color: #8b939c; } #shadow .v { color: var(--ink); font-weight: 600; } #shadow .delta { background: rgba(255,90,31,.14); color: #b8400f; border-radius: 3px; }
.kpis { display: grid; grid-template-columns: repeat(4, 1fr); background: var(--surface); border: 1px solid var(--line); border-radius: 16px; overflow: hidden; }
.kpis div { padding: 14px 16px; border-right: 1px solid var(--line); min-width: 0; }
.kpis div:last-child { border-right: 0; }
.kpis span { display: block; font-size: 13px; color: var(--muted); }
.kpis b { font: 600 19px var(--mono); font-variant-numeric: tabular-nums; white-space: nowrap; }
.kpis b.ok { color: var(--ok); } .kpis b.bad { color: var(--bad); } .kpis b.hot { color: var(--orange); }
.chartbox { background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 16px 16px 10px; position: relative; }
.chart-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; font-size: 14px; flex-wrap: wrap; }
.legend { display: flex; align-items: center; gap: 6px; font-size: 12px; color: var(--muted); }
.legend i { display: inline-block; width: 14px; height: 2px; margin-left: 8px; }
.lg-t { background: var(--orange); } .lg-s { background: repeating-linear-gradient(90deg, var(--muted) 0 3px, transparent 3px 6px); }
#simChart { width: 100%; height: 170px; display: block; margin-top: 8px; cursor: crosshair; }
.console { background: #0f1215; color: #d7dce1; border-radius: 16px; overflow: hidden; }
.console-head { display: flex; justify-content: space-between; gap: 10px; font-size: 11px; padding: 10px 14px; color: #8b939c; border-bottom: 1px solid #22272d; }
#log { list-style: none; margin: 0; padding: 10px 14px; font-size: 12px; height: 190px; overflow: hidden; display: flex; flex-direction: column; justify-content: flex-end; }
#log li { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; animation: in .25s ease-out; }
#log .t { color: #6b737c; } #log .up { color: #ffb18f; } #log .dn { color: #7cc4ff; } #log .sys { color: #8fd6ae; } #log .wr { color: #ff8a7a; }
@keyframes in { from { opacity: 0; transform: translateY(4px); } }

/* =================== §4 PROJECTS =================== */
.filters { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 22px; }
.chip { font: 600 14px var(--sans); padding: 8px 16px; border-radius: 20px; border: 1px solid var(--line); background: var(--surface); color: var(--ink); cursor: pointer; transition: all .2s; }
.chip:hover { border-color: var(--ink); }
.chip.on { background: var(--ink); color: #fff; border-color: var(--ink); }
.projects { display: grid; grid-template-columns: repeat(2, 1fr); gap: 18px; }
.proj { position: relative; background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 24px; display: flex; flex-direction: column; gap: 12px; transition: transform .3s, box-shadow .3s, border-color .3s, opacity .6s; transform-style: preserve-3d; }
.proj:hover { box-shadow: 0 24px 44px -24px rgba(22,25,29,.4); border-color: #c3cad2; }
.proj::after { content: ""; position: absolute; inset: 0; border-radius: 16px; pointer-events: none; opacity: 0; transition: opacity .3s; background: radial-gradient(380px circle at var(--mx, 50%) var(--my, 50%), rgba(255,90,31,.07), transparent 45%); }
.proj:hover::after { opacity: 1; }
.proj.hide { display: none; }
.proj-top { display: flex; justify-content: space-between; font-size: 12px; color: var(--muted); }
.pid { color: var(--orange); font-weight: 500; }
.proj h3 { font: 700 24px/1.15 var(--display); }
.proj p { margin: 0; color: #3b434c; font-size: 16px; }
.spark { width: 100%; height: 64px; display: block; }
.impact { list-style: none; margin: 0; padding: 12px 0 0; border-top: 1px dashed var(--line); display: flex; gap: 22px; flex-wrap: wrap; font-size: 14px; color: var(--muted); }
.impact b { display: block; font: 700 20px var(--display); color: var(--ink); }
.tags { display: flex; gap: 6px; flex-wrap: wrap; margin-top: auto; padding-top: 4px; }
.tags span { font: 500 12px var(--mono); padding: 4px 9px; border-radius: 5px; background: var(--bg); color: #3b434c; }

/* =================== §5 SPECS =================== */
.specs { display: grid; grid-template-columns: 1.1fr .9fr; gap: 24px; align-items: start; }
.tbl-wrap { overflow-x: auto; background: var(--surface); border: 1px solid var(--line); border-radius: 16px; min-width: 0; }
table.spec { width: 100%; border-collapse: collapse; font-size: 15px; font-variant-numeric: tabular-nums; }
.spec th { text-align: left; font: 600 12px var(--display); text-transform: uppercase; letter-spacing: .08em; padding: 12px 14px; border-bottom: 2px solid var(--ink); white-space: nowrap; }
.spec td { padding: 11px 14px; border-bottom: 1px solid var(--line); vertical-align: top; }
.spec tbody tr:last-child td { border-bottom: 0; }
.spec tbody tr:hover { background: #fbf4f0; }
.spec .r { text-align: right; font-family: var(--mono); font-size: 14px; }
.spec td:first-child { font-weight: 600; }
.rev td:nth-child(2) { white-space: nowrap; color: var(--muted); font-size: 13px; }
.rev td:first-child { color: var(--orange); }

/* =================== CONTACT =================== */
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.mail-card { background: var(--steel); color: #fff; border-radius: 16px; padding: 28px; display: flex; flex-direction: column; align-items: flex-start; gap: 14px; }
.mail-card .label { color: #8b939c; font-size: 12px; text-transform: uppercase; letter-spacing: .1em; }
.mail { font: 700 clamp(20px, 2.4vw, 30px) var(--display); text-decoration: none; word-break: break-all; }
.mail:hover { color: var(--orange); }
.mail-card .btn { background: var(--orange); border-color: var(--orange); }
.mail-card .btn:hover { background: #fff; color: var(--ink); border-color: #fff; }
.copied { font-size: 12px; color: #3ddc97; min-height: 1.2em; }
.links { list-style: none; margin: 0; padding: 0; background: var(--surface); border: 1px solid var(--line); border-radius: 16px; overflow: hidden; }
.links li + li { border-top: 1px solid var(--line); }
.links a, .links .vers { display: flex; justify-content: space-between; gap: 12px; padding: 18px 22px; text-decoration: none; font-weight: 600; flex-wrap: wrap; }
.links > li > a { transition: background .2s, padding .2s; }
.links > li > a:hover { background: var(--bg); padding-left: 28px; }
.links .mono { font-size: 13px; font-weight: 400; color: var(--muted); }
.links .vers a { display: inline; padding: 0; color: var(--ink); text-decoration-color: var(--orange); text-underline-offset: 3px; }
.legal { margin-top: 56px; font-size: 11px; color: var(--muted); border-top: 1px solid var(--line); padding-top: 14px; }

/* reveal */
.rv { opacity: 0; transform: translateY(22px); transition: opacity .6s, transform .6s; }
.rv.in { opacity: 1; transform: none; }
.proj.rv.in { transform: none; }

/* =================== RESPONSIVE =================== */
@media (max-width: 1100px) {
  .pipe .pn { display: none; }
  .pipe a { padding: 6px 10px; }
}
@media (max-width: 960px) {
  .hero, .about, .sim, .specs, .contact-grid { grid-template-columns: 1fr; }
  .projects { grid-template-columns: 1fr; }
}
@media (max-width: 760px) {
  .pinout { height: auto; }
  .pin-sticky { position: static; height: auto; grid-template-columns: 1fr; padding: 90px 16px 40px; }
  .pin-steps li { border-color: var(--orange); color: var(--ink); }
}
@media (max-width: 640px) {
  body { font-size: 16px; }
  .top { gap: 10px; padding-left: 14px; padding-right: 14px; }
  .logo span:last-child { display: none; }
  .page { display: none; }
  .pipe li + li::before { width: 6px; }
  .pipe a { padding: 5px 7px; gap: 5px; }
  .pipe b { font-size: 11px; }
  .sec { padding: 84px 16px 64px; }
  .hero { padding: 96px 16px 64px; }
  .kpis { grid-template-columns: repeat(2, 1fr); }
  .kpis div:nth-child(2) { border-right: 0; }
  .kpis div:nth-child(-n+2) { border-bottom: 1px solid var(--line); }
  .gate-inner { padding-right: 34px; }
  .track { height: 64px; } .knob { width: 56px; height: 56px; }
  .scroll-hint { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  html { scroll-behavior: auto; }
  .rv { opacity: 1; transform: none; }
}
