/* Cybrix.AI — site styles. Plain CSS, no framework. */

:root {
  --bg: #07080a;
  --bg-1: #0a0c0f;
  --surface: #0e1115;
  --surface-2: #13171d;
  --line: #1c2129;
  --line-2: #2a313b;
  --text: #e9edf2;
  --muted: #a3adba;
  --dim: #75808e;
  --accent: #39a9ff;
  --accent-2: #7cc6ff;
  --accent-ink: #03111d;
  --accent-soft: rgba(57, 169, 255, .10);
  --accent-line: rgba(57, 169, 255, .35);
  --ok: #3ddc97;
  --warn: #f2b84b;
  --info: #8fb8ff;

  --sans: "Geist", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;

  --wrap: 1200px;
  --gutter: clamp(16px, 4vw, 40px);
  --radius: 14px;
  --radius-sm: 8px;
  --ease: cubic-bezier(.2, .7, .2, 1);
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 84px; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 400 16px/1.65 var(--sans);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}
/* Engineering-paper grid, fading out down the page */
body::before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 1400px;
  pointer-events: none;
  z-index: -1;
  background-image:
    linear-gradient(to right, rgba(255,255,255,.035) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(255,255,255,.035) 1px, transparent 1px);
  background-size: 56px 56px;
  background-position: center top;
  -webkit-mask-image: radial-gradient(ellipse 80% 60% at 50% 0%, #000 30%, transparent 75%);
          mask-image: radial-gradient(ellipse 80% 60% at 50% 0%, #000 30%, transparent 75%);
}
body::after {
  content: "";
  position: absolute;
  left: 50%;
  top: -320px;
  width: 1100px;
  height: 700px;
  transform: translateX(-50%);
  pointer-events: none;
  z-index: -1;
  background: radial-gradient(closest-side, rgba(57,169,255,.16), rgba(57,169,255,0));
  filter: blur(10px);
}

[hidden] { display: none !important; }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--accent-2); text-decoration: none; text-underline-offset: 3px; }
a:hover { color: #fff; }
p a, .prose a, .points a, .svc-cols li a { text-decoration: underline; text-decoration-color: var(--accent-line); }
p a:hover, .prose a:hover, .points a:hover { text-decoration-color: currentColor; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 4px; }
::selection { background: rgba(57,169,255,.35); color: #fff; }

h1, h2, h3, h4 { margin: 0 0 .5em; line-height: 1.12; letter-spacing: -.02em; font-weight: 600; color: #fff; }
h1 { font-size: clamp(2.3rem, 1.25rem + 4.2vw, 4.25rem); letter-spacing: -.045em; line-height: 1.02; }
h2 { font-size: clamp(1.8rem, 1.2rem + 2.2vw, 2.9rem); letter-spacing: -.035em; }
h3 { font-size: 1.22rem; letter-spacing: -.015em; }
p { margin: 0 0 1em; }
code, kbd, pre, .mono { font-family: var(--mono); font-feature-settings: "calt" 1, "liga" 1; }
code { font-size: .9em; background: var(--surface-2); border: 1px solid var(--line); padding: .1em .38em; border-radius: 5px; color: var(--accent-2); }
.small { font-size: .85rem; }
.muted { color: var(--muted); }
.accent { color: var(--accent); }
.sr-only { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }

.skip { position: absolute; left: 12px; top: -60px; z-index: 100; background: var(--accent); color: var(--accent-ink); padding: 10px 16px; border-radius: 8px; font-weight: 600; }
.skip:focus { top: 12px; color: var(--accent-ink); }

.wrap { width: 100%; max-width: calc(var(--wrap) + 2 * var(--gutter)); margin: 0 auto; padding: 0 var(--gutter); }

/* ---------- header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(7, 8, 10, .6);
  -webkit-backdrop-filter: saturate(160%) blur(14px);
          backdrop-filter: saturate(160%) blur(14px);
  border-bottom: 1px solid transparent;
  transition: border-color .3s, background .3s;
}
.site-header.is-scrolled { border-bottom-color: var(--line); background: rgba(7, 8, 10, .82); }
.site-header:has(.site-nav.is-open) { background: var(--bg); -webkit-backdrop-filter: none; backdrop-filter: none; }
.nav-row { display: flex; align-items: center; justify-content: space-between; height: 68px; gap: 24px; }
.brand { display: inline-flex; align-items: center; gap: 10px; color: #fff; font-weight: 600; font-size: 1.12rem; letter-spacing: -.02em; }
.brand:hover { color: #fff; }
.brand img { width: 30px; height: 30px; }
.brand-dot { color: var(--accent); }
.site-nav { display: flex; align-items: center; gap: 28px; }
.site-nav ul { display: flex; gap: 4px; list-style: none; margin: 0; padding: 0; }
.site-nav ul a { display: block; padding: 8px 12px; border-radius: 8px; color: var(--muted); font-size: .94rem; font-weight: 500; transition: color .2s, background .2s; }
.site-nav ul a:hover { color: #fff; background: rgba(255,255,255,.04); }
.site-nav ul a[aria-current="page"] { color: #fff; }
.site-nav ul a[aria-current="page"]::before { content: "▸ "; color: var(--accent); font-family: var(--mono); }
.nav-toggle { display: none; background: none; border: 1px solid var(--line-2); border-radius: 10px; width: 44px; height: 44px; color: #fff; cursor: pointer; place-items: center; }
.nav-toggle .bars, .nav-toggle .bars::before, .nav-toggle .bars::after { display: block; width: 18px; height: 1.5px; background: currentColor; border-radius: 2px; transition: transform .3s var(--ease), opacity .2s; position: relative; }
.nav-toggle .bars::before, .nav-toggle .bars::after { content: ""; position: absolute; left: 0; }
.nav-toggle .bars::before { top: -6px; }
.nav-toggle .bars::after { top: 6px; }
.nav-toggle[aria-expanded="true"] .bars { background: transparent; }
.nav-toggle[aria-expanded="true"] .bars::before { transform: translateY(6px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] .bars::after { transform: translateY(-6px) rotate(-45deg); }

@media (max-width: 920px) {
  .nav-toggle { display: grid; }
  .site-nav {
    position: absolute; left: 0; right: 0; top: 68px;
    flex-direction: column; align-items: stretch; gap: 16px;
    padding: 16px var(--gutter) 24px;
    background: var(--bg);
    border-bottom: 1px solid var(--line);
    box-shadow: 0 30px 60px rgba(0, 0, 0, .6);
    display: none;
  }
  .site-nav.is-open { display: flex; }
  .site-nav ul { flex-direction: column; gap: 0; }
  .site-nav ul a { padding: 14px 4px; font-size: 1.05rem; border-bottom: 1px solid var(--line); border-radius: 0; }
  .site-nav .btn { justify-content: center; }
}

/* ---------- buttons ---------- */
.btn {
  --b: var(--line-2);
  display: inline-flex; align-items: center; gap: 10px;
  padding: 13px 20px; border-radius: 10px;
  font: 600 .96rem/1 var(--sans); letter-spacing: -.005em;
  border: 1px solid var(--b); color: #fff; background: transparent;
  cursor: pointer; white-space: nowrap;
  transition: transform .2s var(--ease), background .2s, border-color .2s, box-shadow .25s, color .2s;
}
.btn:hover { transform: translateY(-1px); color: #fff; border-color: #3a4350; background: rgba(255,255,255,.03); }
.btn-primary { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); box-shadow: 0 0 0 0 rgba(57,169,255,0), 0 8px 30px -10px rgba(57,169,255,.6); }
.btn-primary:hover { background: #5cb9ff; border-color: #5cb9ff; color: var(--accent-ink); box-shadow: 0 0 0 4px rgba(57,169,255,.15), 0 10px 36px -8px rgba(57,169,255,.7); }
.btn-sm { padding: 10px 14px; font-size: .88rem; }
.btn .mono { font-weight: 500; font-size: .88em; }
.btn-row { display: flex; flex-wrap: wrap; gap: 12px; }

/* ---------- common bits ---------- */
.eyebrow {
  display: inline-flex; align-items: center; gap: 10px;
  font: 500 .78rem/1 var(--mono); letter-spacing: .08em; text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 20px;
}
.eyebrow::before { content: ""; width: 18px; height: 1px; background: currentColor; opacity: .7; }
.pill {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 6px 12px 6px 10px; border-radius: 999px;
  border: 1px solid var(--line-2); background: rgba(14,17,21,.7);
  font: 500 .8rem/1.2 var(--mono); color: var(--muted);
}
.pill strong { color: #fff; font-weight: 600; }
.dot { display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: var(--dim); margin-right: 8px; vertical-align: middle; flex: none; }
.dot-ok { background: var(--ok); box-shadow: 0 0 0 3px rgba(61,220,151,.15); }
.dot-warn { background: var(--warn); box-shadow: 0 0 0 3px rgba(242,184,75,.14); }
.dot-info { background: var(--info); box-shadow: 0 0 0 3px rgba(143,184,255,.14); }
.dot-dim { background: var(--dim); }
.dot-pulse { animation: pulse 2.4s var(--ease) infinite; }
@keyframes pulse { 0%, 100% { box-shadow: 0 0 0 3px rgba(61,220,151,.15); } 50% { box-shadow: 0 0 0 6px rgba(61,220,151,0); } }
.tag { display: inline-block; font: 500 .74rem/1 var(--mono); color: var(--muted); border: 1px solid var(--line-2); border-radius: 6px; padding: 5px 8px; }
.tags { display: flex; flex-wrap: wrap; gap: 6px; list-style: none; margin: 0; padding: 0; }
.caret { display: inline-block; width: .55em; height: 1.05em; background: var(--accent); vertical-align: -.15em; margin-left: .25em; animation: blink 1.1s steps(1) infinite; }
@keyframes blink { 50% { opacity: 0; } }

.section { padding: clamp(64px, 8vw, 108px) 0; position: relative; }
.section + .section { border-top: 1px solid var(--line); }
.section-head { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 24px 64px; align-items: end; margin-bottom: clamp(36px, 5vw, 56px); }
.section-head h2 { margin: 0; max-width: 19ch; }
.section-head p { margin: 0; color: var(--muted); font-size: 1.08rem; max-width: 52ch; }
.section-index { font: 500 .78rem/1 var(--mono); color: var(--dim); letter-spacing: .06em; margin-bottom: 16px; display: block; }
.section-index b { color: var(--accent); font-weight: 500; }
@media (max-width: 820px) { .section-head { grid-template-columns: 1fr; } }

.card {
  position: relative;
  background: linear-gradient(180deg, rgba(255,255,255,.018), rgba(255,255,255,0)), var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 28px;
  transition: border-color .3s, transform .3s var(--ease), background .3s;
  isolation: isolate;
}
.card::before { /* pointer spotlight, positioned by site.js */
  content: ""; position: absolute; inset: -1px; border-radius: inherit; z-index: -1; pointer-events: none;
  background: radial-gradient(420px circle at var(--mx, 50%) var(--my, -200px), rgba(57,169,255,.09), transparent 45%);
  opacity: 0; transition: opacity .3s;
}
.card:hover { border-color: #28313c; }
.card:hover::before { opacity: 1; }
a.card { display: block; color: inherit; }
a.card:hover { transform: translateY(-2px); }

/* ---------- hero ---------- */
.hero { padding: clamp(56px, 9vw, 112px) 0 clamp(64px, 8vw, 104px); }
.hero-grid { display: grid; grid-template-columns: minmax(0, 1.12fr) minmax(0, .88fr); gap: clamp(40px, 6vw, 72px); align-items: center; }
.hero h1 { margin-bottom: 24px; }
.hero h1 .grad { background: linear-gradient(92deg, #fff 10%, var(--accent-2) 55%, var(--accent) 90%); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero .lede { font-size: clamp(1.08rem, 1rem + .35vw, 1.24rem); color: var(--muted); max-width: 56ch; margin-bottom: 32px; }
.hero .btn-row { margin-bottom: 36px; }
.hero-meta { display: flex; flex-wrap: wrap; gap: 10px; }
@media (max-width: 980px) { .hero-grid { grid-template-columns: 1fr; } }

/* terminal */
.terminal {
  margin: 0;
  background: linear-gradient(180deg, #0d1014, #090b0e);
  border: 1px solid var(--line-2);
  border-radius: var(--radius);
  box-shadow: 0 40px 120px -40px rgba(57,169,255,.28), 0 0 0 1px rgba(255,255,255,.02) inset;
  overflow: hidden;
  min-width: 0;
}
.term-bar { display: flex; align-items: center; gap: 8px; padding: 12px 16px; border-bottom: 1px solid var(--line); background: rgba(255,255,255,.015); }
.term-bar i { width: 11px; height: 11px; border-radius: 50%; background: #2a3039; display: block; }
.term-bar i:nth-child(1) { background: #ff5f57; opacity: .8; }
.term-bar i:nth-child(2) { background: #febc2e; opacity: .8; }
.term-bar i:nth-child(3) { background: #28c840; opacity: .8; }
.term-bar span { margin-left: 10px; font: 500 .76rem/1 var(--mono); color: var(--dim); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.term-body {
  margin: 0; padding: 20px 20px 24px;
  font: 400 .84rem/1.75 var(--mono);
  color: var(--muted);
  white-space: pre-wrap; word-break: break-word;
  min-height: 368px;
}
.term-body .ln { display: block; }
.term-body .p { color: var(--accent); }
.term-body .p::before { content: "❯ "; color: var(--accent); }
.term-body .pc::before { content: ""; }
.term-body .c { color: #fff; }
.term-body .ok { color: var(--ok); }
.term-body .warn { color: var(--warn); }
.term-body .k { color: var(--accent-2); }
.term-body .d { color: var(--dim); }
.term-body .gap { height: .8em; }
@media (max-width: 520px) { .term-body { font-size: .72rem; min-height: 0; padding: 16px; } .case-viz pre { font-size: .7rem; padding: 16px 18px; } }

/* marquee of tech */
.stackline { border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); background: rgba(10,12,15,.6); overflow: hidden; }
.stackline-track { display: flex; gap: 48px; width: max-content; padding: 18px 0; animation: marquee 48s linear infinite; }
.stackline:hover .stackline-track { animation-play-state: paused; }
.stackline-track span { font: 500 .84rem/1 var(--mono); color: var(--dim); white-space: nowrap; }
.stackline-track span::before { content: "◆"; color: var(--accent); opacity: .55; margin-right: 12px; font-size: .6rem; vertical-align: .15em; }
@keyframes marquee { to { transform: translateX(-50%); } }

/* ---------- deadline banner ---------- */
.deadline {
  display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 28px; align-items: center;
  padding: 24px 28px; border-radius: var(--radius);
  border: 1px solid var(--accent-line);
  background: linear-gradient(90deg, rgba(57,169,255,.10), rgba(57,169,255,.02) 60%), var(--surface);
}
.deadline-count { font: 600 2.6rem/1 var(--mono); color: #fff; letter-spacing: -.04em; text-align: center; min-width: 4ch; }
.deadline-count small { display: block; font: 500 .7rem/1.4 var(--mono); letter-spacing: .1em; text-transform: uppercase; color: var(--accent); margin-top: 6px; }
.deadline h2 { font-size: 1.28rem; margin: 0 0 4px; letter-spacing: -.015em; }
.deadline p { margin: 0; color: var(--muted); }
@media (max-width: 760px) { .deadline { grid-template-columns: 1fr; gap: 16px; text-align: left; } .deadline-count { text-align: left; } }

/* ---------- services ---------- */
.services-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.service { display: flex; flex-direction: column; min-height: 100%; }
.service .num { font: 500 .78rem/1 var(--mono); color: var(--dim); margin-bottom: 28px; display: flex; justify-content: space-between; }
.service .num b { color: var(--accent); font-weight: 500; }
.service .icon { width: 44px; height: 44px; border-radius: 10px; display: grid; place-items: center; border: 1px solid var(--line-2); background: var(--surface-2); color: var(--accent); margin-bottom: 20px; }
.service .icon svg { width: 22px; height: 22px; }
.service h3 { margin-bottom: 10px; }
.service p { color: var(--muted); font-size: .97rem; }
.service ul { list-style: none; padding: 0; margin: auto 0 0; padding-top: 12px; border-top: 1px dashed var(--line-2); }
.service li { font: 400 .8rem/1.5 var(--mono); color: var(--muted); padding: 5px 0; }
.service li::before { content: "+ "; color: var(--accent); }
.service-cta { background: linear-gradient(160deg, rgba(57,169,255,.16), rgba(57,169,255,.03) 60%), var(--surface); border-color: var(--accent-line); }
.service-cta:hover { border-color: var(--accent); }
.service-cta .link { margin-top: auto; font: 600 .92rem/1 var(--sans); color: #fff; display: inline-flex; gap: 8px; align-items: center; }
@media (max-width: 1000px) { .services-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 640px) { .services-grid { grid-template-columns: 1fr; } }

/* ---------- work / case studies ---------- */
.work-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.case { display: flex; flex-direction: column; padding: 0; overflow: hidden; }
.case-body { padding: 28px; display: flex; flex-direction: column; flex: 1; }
.case .kicker { font: 500 .76rem/1 var(--mono); color: var(--dim); margin-bottom: 14px; letter-spacing: .04em; }
.case-head { display: flex; justify-content: space-between; gap: 16px; align-items: flex-start; }
.case-head img { width: 52px; height: 52px; border-radius: 12px; border: 1px solid var(--line-2); flex: none; }
.case .kicker b { color: var(--accent); font-weight: 500; }
.case h3 { font-size: 1.4rem; margin-bottom: 12px; }
.case p { color: var(--muted); }
.case ul.points { list-style: none; padding: 0; margin: 0 0 20px; }
.case ul.points li { position: relative; padding: 6px 0 6px 22px; color: var(--muted); font-size: .95rem; }
.case ul.points li::before { content: "→"; position: absolute; left: 0; color: var(--accent); font-family: var(--mono); }
.case .tags { margin-top: auto; }
.case-viz { border-bottom: 1px solid var(--line); background: #090b0e; }
.case-viz pre { margin: 0; padding: 20px 24px; font: 400 .78rem/1.7 var(--mono); color: var(--muted); overflow-x: auto; white-space: pre; }
.case-viz .k { color: var(--accent-2); }
.case-viz .s { color: #b5e3a1; }
.case-viz .n { color: #f2b84b; }
.case-viz .d { color: var(--dim); }
.case-viz .ok { color: var(--ok); }
.case-wide { grid-column: 1 / -1; display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr); }
.case-wide .case-viz { border-bottom: 0; border-left: 1px solid var(--line); order: 2; padding: 28px; display: flex; flex-direction: column; justify-content: center; gap: 16px; }
.mosaic { display: grid; grid-template-columns: repeat(9, minmax(0, 1fr)); gap: 10px; }
.mosaic .you { display: grid; place-items: center; border-style: dashed; color: var(--accent); font: 500 .72rem/1.1 var(--mono); text-align: center; background: transparent; }
@media (max-width: 1100px) and (min-width: 901px) { .mosaic { grid-template-columns: repeat(7, minmax(0, 1fr)); } }
@media (max-width: 560px) { .mosaic { grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 8px; } }
.mosaic a { display: block; border-radius: 12px; overflow: hidden; border: 1px solid var(--line-2); aspect-ratio: 1; background: var(--surface-2); transition: transform .25s var(--ease), border-color .25s; }
.mosaic a:hover { transform: translateY(-2px) scale(1.04); border-color: var(--accent); }
.mosaic img { width: 100%; height: 100%; object-fit: cover; }
.mosaic-caption { font: 500 .76rem/1.5 var(--mono); color: var(--dim); display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
@media (max-width: 900px) {
  .work-grid { grid-template-columns: 1fr; }
  .case-wide { grid-template-columns: 1fr; }
  .case-wide .case-viz { order: 0; border-left: 0; border-bottom: 1px solid var(--line); }
}
.work-foot { margin-top: 28px; display: flex; flex-wrap: wrap; gap: 12px; justify-content: space-between; align-items: center; color: var(--muted); }

/* ---------- process ---------- */
.steps { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0; list-style: none; margin: 0; padding: 0; counter-reset: step; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; background: var(--surface); }
.step { padding: 28px 26px 30px; position: relative; border-right: 1px solid var(--line); }
.step:last-child { border-right: 0; }
.step .n { font: 600 .78rem/1 var(--mono); color: var(--accent); display: flex; align-items: center; gap: 10px; margin-bottom: 22px; }
.step .n::after { content: ""; flex: 1; height: 1px; background: linear-gradient(90deg, var(--accent-line), transparent); }
.step h3 { font-size: 1.12rem; margin-bottom: 8px; }
.step p { color: var(--muted); font-size: .95rem; margin: 0; }
.step .out { margin-top: 16px; font: 400 .76rem/1.5 var(--mono); color: var(--dim); }
.step .out b { color: var(--muted); font-weight: 500; }
@media (max-width: 980px) { .steps { grid-template-columns: repeat(2, minmax(0, 1fr)); } .step:nth-child(2) { border-right: 0; } .step:nth-child(-n+2) { border-bottom: 1px solid var(--line); } }
@media (max-width: 600px) { .steps { grid-template-columns: 1fr; } .step { border-right: 0; border-bottom: 1px solid var(--line); } .step:last-child { border-bottom: 0; } }

/* ---------- toolbox ---------- */
.toolbox { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.toolbox .card { padding: 22px 24px; }
.toolbox h3 { font: 500 .76rem/1 var(--mono); color: var(--accent); letter-spacing: .08em; text-transform: uppercase; margin-bottom: 16px; }
.toolbox ul { list-style: none; margin: 0; padding: 0; }
.toolbox li { font: 400 .88rem/1.5 var(--mono); color: var(--text); padding: 6px 0; border-bottom: 1px solid var(--line); }
.toolbox li:last-child { border-bottom: 0; }
@media (max-width: 1000px) { .toolbox { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 520px) { .toolbox { grid-template-columns: 1fr; } }

/* ---------- about ---------- */
.about-grid { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); gap: clamp(32px, 6vw, 80px); align-items: start; }
.about-grid .prose p { color: var(--muted); font-size: 1.08rem; }
.about-grid .prose p:first-of-type { color: var(--text); font-size: 1.22rem; }
.facts { margin: 0; padding: 0; }
.facts pre { margin: 0; padding: 24px; font: 400 .84rem/1.9 var(--mono); color: var(--muted); white-space: pre-wrap; }
.facts .k { color: var(--accent-2); }
.facts .s { color: #b5e3a1; }
.facts .n { color: var(--warn); }
.facts .d { color: var(--dim); }
.facts a { color: #b5e3a1; text-decoration: underline; text-decoration-color: rgba(181,227,161,.35); }
@media (max-width: 900px) { .about-grid { grid-template-columns: 1fr; } }

/* ---------- contact ---------- */
.contact { padding: clamp(56px, 7vw, 96px) 0; border-top: 1px solid var(--line); }
.contact-box {
  position: relative; overflow: hidden;
  border: 1px solid var(--line-2); border-radius: 20px;
  padding: clamp(32px, 6vw, 72px);
  background:
    radial-gradient(600px circle at 100% 0%, rgba(57,169,255,.16), transparent 60%),
    linear-gradient(180deg, rgba(255,255,255,.02), transparent),
    var(--surface);
  display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, .8fr); gap: clamp(32px, 5vw, 64px); align-items: center;
}
.contact-box::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background-image: linear-gradient(to right, rgba(255,255,255,.03) 1px, transparent 1px), linear-gradient(to bottom, rgba(255,255,255,.03) 1px, transparent 1px);
  background-size: 28px 28px;
  -webkit-mask-image: linear-gradient(120deg, transparent 40%, #000);
          mask-image: linear-gradient(120deg, transparent 40%, #000);
}
.contact-box > * { position: relative; z-index: 1; }
.contact-box h2 { max-width: 14ch; }
.contact-box .lede { color: var(--muted); font-size: 1.1rem; max-width: 48ch; margin-bottom: 28px; }
.email-line { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-top: 18px; font: 500 .9rem/1 var(--mono); color: var(--muted); }
.email-line a { color: #fff; }
.copy-btn { font: 500 .78rem/1 var(--mono); color: var(--muted); background: var(--surface-2); border: 1px solid var(--line-2); border-radius: 6px; padding: 7px 10px; cursor: pointer; }
.copy-btn:hover { color: #fff; border-color: #3a4350; }
.brief { padding: 22px 24px; border: 1px dashed var(--line-2); border-radius: var(--radius); background: rgba(7,8,10,.5); }
.brief ol { list-style: none; margin: 0; padding: 0; counter-reset: b; }
.brief-title { font: 500 .76rem/1 var(--mono); color: var(--accent); text-transform: uppercase; letter-spacing: .08em; margin-bottom: 14px; display: block; }
.brief li { counter-increment: b; display: grid; grid-template-columns: 28px 1fr; padding: 8px 0; color: var(--muted); font-size: .96rem; border-bottom: 1px solid var(--line); }
.brief li:last-child { border-bottom: 0; }
.brief li::before { content: "0" counter(b); font: 500 .78rem/1.9 var(--mono); color: var(--dim); }
@media (max-width: 900px) { .contact-box { grid-template-columns: 1fr; } }

/* ---------- page hero (inner pages) ---------- */
.page-hero { padding: clamp(56px, 8vw, 96px) 0 clamp(40px, 5vw, 56px); }
.page-hero h1 { font-size: clamp(2.2rem, 1.3rem + 3.6vw, 3.9rem); max-width: 18ch; margin-bottom: 20px; }
.page-hero .lede { color: var(--muted); font-size: clamp(1.05rem, 1rem + .3vw, 1.2rem); max-width: 62ch; margin: 0; }
.crumbs { font: 500 .78rem/1 var(--mono); color: var(--dim); margin-bottom: 22px; }
.crumbs a { color: var(--dim); text-decoration: none; }
.crumbs a:hover { color: #fff; }
.crumbs span { color: var(--accent); }

/* ---------- services page ---------- */
.svc { display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr); gap: clamp(28px, 5vw, 72px); padding: clamp(48px, 6vw, 72px) 0; border-top: 1px solid var(--line); }
.svc:first-of-type { border-top: 0; }
.svc-head { position: sticky; top: 100px; align-self: start; }
.svc-head .num { font: 500 .8rem/1 var(--mono); color: var(--accent); margin-bottom: 18px; display: block; }
.svc-head h2 { font-size: clamp(1.6rem, 1.1rem + 1.6vw, 2.3rem); }
.svc-head p { color: var(--muted); }
.svc-cols { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.svc-cols .card { padding: 22px 24px; }
.svc-cols h3 { font: 500 .76rem/1 var(--mono); color: var(--accent); letter-spacing: .08em; text-transform: uppercase; margin-bottom: 14px; }
.svc-cols ul { margin: 0; padding: 0; list-style: none; }
.svc-cols li { padding: 6px 0 6px 18px; position: relative; color: var(--muted); font-size: .95rem; }
.svc-cols li::before { content: "›"; position: absolute; left: 2px; color: var(--accent); font-family: var(--mono); }
.svc-proof { grid-column: 1 / -1; display: flex; gap: 14px; align-items: flex-start; padding: 18px 22px; border-radius: var(--radius); border: 1px solid var(--line); background: #0a0c0f; color: var(--muted); font-size: .95rem; }
.svc-proof .mono { color: var(--accent); font-size: .78rem; white-space: nowrap; padding-top: 3px; }
.svc-proof p { margin: 0; }
@media (max-width: 900px) { .svc { grid-template-columns: 1fr; } .svc-head { position: static; } }
@media (max-width: 600px) { .svc-cols { grid-template-columns: 1fr; } .svc-proof { flex-direction: column; gap: 6px; } }

.faq { display: grid; gap: 12px; max-width: 880px; }
.faq details { border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); padding: 0 22px; transition: border-color .2s; }
.faq details[open] { border-color: var(--line-2); }
.faq summary { cursor: pointer; list-style: none; padding: 20px 0; font-weight: 600; color: #fff; display: flex; justify-content: space-between; gap: 16px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font-family: var(--mono); color: var(--accent); font-size: 1.2rem; line-height: 1; transition: transform .2s; }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p { color: var(--muted); margin: 0 0 20px; }

/* ---------- plugins page ---------- */
.stats { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 28px; }
.notice { display: grid; grid-template-columns: auto 1fr; gap: 16px; align-items: start; padding: 20px 22px; border-radius: var(--radius); border: 1px solid rgba(242,184,75,.3); background: linear-gradient(90deg, rgba(242,184,75,.08), rgba(242,184,75,.02)); color: var(--muted); margin-bottom: 32px; }
.notice .mono { color: var(--warn); font-size: .78rem; padding-top: 3px; white-space: nowrap; }
.notice p { margin: 0; }
@media (max-width: 640px) { .notice { grid-template-columns: 1fr; gap: 8px; } }
.notice strong { color: #fff; }
.toolbar { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; justify-content: space-between; margin-bottom: 20px; }
.filters { display: flex; flex-wrap: wrap; gap: 6px; }
.filter { font: 500 .8rem/1 var(--mono); color: var(--muted); background: transparent; border: 1px solid var(--line-2); border-radius: 999px; padding: 9px 14px; cursor: pointer; transition: all .2s; }
.filter:hover { color: #fff; border-color: #3a4350; }
.filter[aria-pressed="true"] { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.filter .c { opacity: .7; margin-left: 4px; }
.search { position: relative; flex: 1 1 240px; max-width: 340px; }
.search input { width: 100%; font: 400 .88rem/1 var(--mono); color: #fff; background: var(--surface); border: 1px solid var(--line-2); border-radius: 10px; padding: 12px 14px 12px 36px; }
.search input::placeholder { color: var(--dim); }
.search input:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px rgba(57,169,255,.18); }
.search::before { content: "/"; position: absolute; left: 14px; top: 50%; transform: translateY(-50%); font: 500 .9rem/1 var(--mono); color: var(--accent); }
.plugin-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); gap: 16px; }
.plugin { display: flex; flex-direction: column; padding: 22px; scroll-margin-top: 96px; }
.plugin:target { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(57,169,255,.15); }
.plugin-top { display: flex; gap: 14px; align-items: center; margin-bottom: 16px; }
.plugin-top img { width: 56px; height: 56px; border-radius: 12px; object-fit: cover; border: 1px solid var(--line-2); background: var(--surface-2); flex: none; }
.plugin-top.tight { margin: 0; }
.plugin-top h3 { font-size: 1.06rem; margin: 4px 0 0; letter-spacing: -.015em; }
.plugin-top h2 { font-size: 1.06rem; margin: 0 0 4px; letter-spacing: -.015em; }
.plugin .was { font: 400 .74rem/1.3 var(--mono); color: var(--dim); }
.status { display: inline-flex; align-items: center; font: 500 .74rem/1 var(--mono); color: var(--muted); }
.status .dot { margin-right: 7px; }
.plugin p { color: var(--muted); font-size: .93rem; flex: 1; margin-bottom: 16px; }
.plugin-foot { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 10px; padding-top: 14px; border-top: 1px dashed var(--line-2); }
.plugin-links { display: flex; flex-wrap: wrap; gap: 10px; }
.plugin-links a { font: 500 .8rem/1 var(--mono); text-decoration: none; }
.plugin-links a.primary { color: var(--accent); }
.plugin-links a.secondary { color: var(--muted); }
.plugin-links a:hover { color: #fff; }
.empty { display: none; padding: 40px; text-align: center; color: var(--muted); font-family: var(--mono); border: 1px dashed var(--line-2); border-radius: var(--radius); }
.empty.is-shown { display: block; }

/* ---------- legal pages ---------- */
.legal { max-width: 780px; padding-bottom: clamp(64px, 8vw, 104px); }
.legal .prose { color: var(--muted); font-size: 1.02rem; }
.legal .prose h2 { font-size: 1.2rem; color: #fff; margin: 2.2em 0 .6em; letter-spacing: -.01em; display: flex; gap: 12px; align-items: baseline; }
.legal .prose h2 .n { font: 500 .8rem/1 var(--mono); color: var(--accent); }
.legal .meta { font: 400 .82rem/1.6 var(--mono); color: var(--dim); padding: 14px 18px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); display: inline-block; margin-bottom: 8px; }
.legal .toc { font: 400 .84rem/1.9 var(--mono); list-style: none; margin: 24px 0 0; padding: 0; columns: 2; column-gap: 32px; }
.legal .toc a { color: var(--muted); text-decoration: none; }
.legal .toc a:hover { color: #fff; }
@media (max-width: 560px) { .legal .toc { columns: 1; } }

/* ---------- migration page ---------- */
.split { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.compare h3 { display: flex; align-items: center; gap: 10px; }
.compare ul { list-style: none; margin: 0; padding: 0; }
.compare li { padding: 9px 0; border-bottom: 1px solid var(--line); color: var(--muted); font-size: .96rem; display: grid; grid-template-columns: 22px 1fr; }
.compare li:last-child { border-bottom: 0; }
.compare li::before { font-family: var(--mono); }
.compare.before li::before { content: "–"; color: var(--dim); }
.compare.after li::before { content: "+"; color: var(--accent); }
.compare.after { border-color: var(--accent-line); }
.checklist { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; list-style: none; margin: 0; padding: 0; counter-reset: c; }
.checklist li { counter-increment: c; }
.checklist .card { height: 100%; }
.checklist .card::after { content: "0" counter(c); position: absolute; top: 24px; right: 26px; font: 500 .78rem/1 var(--mono); color: var(--dim); }
.checklist h3 { font-size: 1.06rem; padding-right: 32px; }
.checklist p { color: var(--muted); font-size: .95rem; margin: 0; }
@media (max-width: 900px) { .split { grid-template-columns: 1fr; } .checklist { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 600px) { .checklist { grid-template-columns: 1fr; } }

/* ---------- 404 ---------- */
.nf { min-height: 60vh; display: grid; place-items: center; text-align: left; padding: 80px 0; }
.nf pre { font: 400 .92rem/1.8 var(--mono); color: var(--muted); margin: 0 0 28px; white-space: pre-wrap; }
.nf .err { color: #ff6b6b; }

/* ---------- footer ---------- */
.site-footer { border-top: 1px solid var(--line); background: var(--bg-1); padding: 56px 0 28px; }
.footer-grid { display: grid; grid-template-columns: minmax(0, 1.5fr) repeat(3, minmax(0, 1fr)); gap: 32px; }
.footer-brand p { color: var(--muted); max-width: 34ch; margin: 16px 0 8px; font-size: .95rem; }
.footer-brand .mono a { color: var(--accent-2); text-decoration: none; }
.footer-h { font: 500 .74rem/1 var(--mono); color: var(--dim); letter-spacing: .1em; text-transform: uppercase; margin-bottom: 16px; }
.site-footer ul { list-style: none; margin: 0; padding: 0; }
.site-footer li a { display: inline-flex; align-items: center; padding: 5px 0; color: var(--muted); font-size: .93rem; text-decoration: none; }
.site-footer li a:hover { color: #fff; }
.footer-base { position: relative; margin-top: 48px; padding-top: 22px; display: flex; flex-wrap: wrap; gap: 12px; justify-content: space-between; color: var(--dim); font-size: .78rem; }
.footer-base::before { content: ""; position: absolute; top: 0; left: var(--gutter); right: var(--gutter); height: 1px; background: var(--line); }
.footer-base .caret { width: .5em; height: 1em; opacity: .8; }
@media (max-width: 860px) { .footer-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } .footer-brand { grid-column: 1 / -1; } }
@media (max-width: 420px) { .footer-grid { grid-template-columns: 1fr; } }

/* ---------- reveal on scroll (only when JS + motion allowed) ---------- */
.js-motion [data-reveal] { opacity: 0; transform: translateY(18px); transition: opacity .7s var(--ease), transform .7s var(--ease); transition-delay: var(--d, 0s); }
.js-motion [data-reveal].is-in { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; }
  .stackline-track { animation: none; flex-wrap: wrap; width: auto; justify-content: center; gap: 16px 32px; padding: 18px var(--gutter); }
  .stackline-track [aria-hidden="true"] { display: none; }
  .caret { animation: none; }
}
@media print {
  body::before, body::after, .site-header, .site-footer, .contact { display: none; }
  body { background: #fff; color: #000; }
}
