/* ==========================================================================
   Vortic Scale website styles
   Direction: 02c Blueprint with Spiral O logo
   ========================================================================== */

/* ---------- Fonts (self-hosted, SIL Open Font License) ---------- */
@font-face {
  font-family: "Archivo";
  font-style: normal;
  font-display: swap;
  font-weight: 100 900;
  font-stretch: 62% 125%;
  src: url("../fonts/archivo-variable-latin.woff2") format("woff2-variations"),
       url("../fonts/archivo-variable-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;
}
@font-face {
  font-family: "Archivo";
  font-style: normal;
  font-display: swap;
  font-weight: 100 900;
  font-stretch: 62% 125%;
  src: url("../fonts/archivo-variable-latin-ext.woff2") format("woff2-variations"),
       url("../fonts/archivo-variable-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, 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: "JetBrains Mono";
  font-style: normal;
  font-display: swap;
  font-weight: 100 800;
  src: url("../fonts/jetbrains-mono-variable-latin.woff2") format("woff2-variations"),
       url("../fonts/jetbrains-mono-variable-latin.woff2") format("woff2");
}

/* ---------- Design tokens ---------- */
:root {
  --ink: #121418;
  --graphite: #4B5059;
  --signal: #E8501C;
  --signal-deep: #C2410C;
  --rule: #CFCFC7;
  --grid-line: #E2E2DA;
  --paper: #F2F2EE;
  --canvas: #FAFAF7;
  --white: #FFFFFF;
  --haze: #B4B6AE;

  --font-body: "Archivo", "Helvetica Neue", Arial, sans-serif;
  --font-mono: "JetBrains Mono", SFMono-Regular, Menlo, Consolas, monospace;

  --fs-display: clamp(2.375rem, 1.4rem + 3vw, 3.375rem);
  --fs-h1: clamp(2.25rem, 1.6rem + 2.6vw, 3.5rem);
  --fs-h2: clamp(1.75rem, 1.35rem + 1.6vw, 2.5rem);
  --fs-h3: 1.25rem;
  --fs-lead: clamp(1.0625rem, 1rem + 0.35vw, 1.25rem);
  --fs-body: 1.0625rem;
  --fs-small: 0.9375rem;
  --fs-label: 0.8125rem;

  --gutter: clamp(20px, 5vw, 64px);
  --content-max: 1200px;
  --section-y: clamp(64px, 8vw, 120px);
  --radius: 2px;
  --header-h: 76px;
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body {
  margin: 0;
  background: var(--canvas);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: var(--fs-body);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img, svg { display: block; max-width: 100%; }
h1, h2, h3, h4 { margin: 0; line-height: 1.1; font-weight: 800; }
h1, h2 { font-stretch: 112%; letter-spacing: -0.01em; text-wrap: balance; }
h3 { font-size: var(--fs-h3); font-weight: 700; font-stretch: 108%; line-height: 1.25; }
p { margin: 0; }
p, li { text-wrap: pretty; }
a { color: var(--ink); text-decoration-color: var(--signal); text-decoration-thickness: 2px; text-underline-offset: 4px; }
a:hover { color: var(--graphite); }
:focus-visible { outline: 3px solid var(--signal); outline-offset: 3px; }
::selection { background: var(--signal); color: var(--white); }

.visually-hidden {
  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-link {
  position: absolute; left: 16px; top: -100px; z-index: 100;
  background: var(--ink); color: var(--paper); padding: 12px 18px; text-decoration: none; font-weight: 600;
}
.skip-link:focus { top: 16px; color: var(--paper); }

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

.mono { font-family: var(--font-mono); }
.label {
  font-family: var(--font-mono); font-size: var(--fs-label); letter-spacing: 0.12em;
  text-transform: uppercase; color: var(--graphite); font-weight: 500;
}
.eyebrow {
  font-family: var(--font-mono); font-size: var(--fs-label); letter-spacing: 0.14em;
  text-transform: uppercase; color: var(--ink); font-weight: 500;
}
.eyebrow::before { content: "[ "; }
.eyebrow::after { content: " ]"; }
.accent { color: var(--signal); }
.lead { font-size: var(--fs-lead); line-height: 1.55; color: var(--graphite); max-width: 62ch; }

.bp-grid {
  background-color: var(--paper);
  background-image:
    linear-gradient(var(--grid-line) 1px, transparent 1px),
    linear-gradient(90deg, var(--grid-line) 1px, transparent 1px);
  background-size: 40px 40px;
  background-position: -1px -1px;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 52px; padding: 0 26px; border-radius: var(--radius);
  font-family: var(--font-body); font-size: 1rem; font-weight: 600; line-height: 1.2;
  text-decoration: none; border: 1.5px solid var(--ink); cursor: pointer;
  transition: background-color 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}
.btn--primary { background: var(--ink); color: var(--paper); }
.btn--primary:hover { background: #2A2E35; border-color: #2A2E35; color: var(--white); }
.btn--secondary { background: var(--paper); color: var(--ink); }
.btn--secondary:hover { background: var(--white); color: var(--ink); }
.btn--small { min-height: 44px; padding: 0 18px; font-size: 0.9375rem; }
.btn--on-ink { background: var(--paper); color: var(--ink); border-color: var(--paper); }
.btn--on-ink:hover { background: var(--white); border-color: var(--white); color: var(--ink); }
.btn--ghost-on-ink { background: transparent; color: var(--paper); border-color: #4A4E57; }
.btn--ghost-on-ink:hover { border-color: var(--paper); color: var(--white); }
.btn .dot { width: 8px; height: 8px; background: var(--signal); flex: none; }
.btn-row { display: flex; flex-wrap: wrap; gap: 16px; }

.text-link {
  display: inline-flex; align-items: center; gap: 8px; min-height: 44px;
  font-weight: 600; color: var(--ink); text-decoration: underline;
  text-decoration-color: var(--signal); text-decoration-thickness: 2px; text-underline-offset: 6px;
}
.text-link:hover { color: var(--graphite); }
.arrow { display: inline-block; width: 16px; height: 16px; flex: none; }

/* ---------- Logo ---------- */
.logo { display: inline-flex; align-items: center; text-decoration: none; color: var(--ink); }
.logo img { height: 18px; width: auto; }
.site-footer .logo img { height: 20px; }

/* ---------- Header ---------- */
.site-header { position: relative; z-index: 20; }
.site-header__bar {
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
  min-height: var(--header-h); padding-block: 16px;
}
.site-nav { display: flex; align-items: center; gap: clamp(20px, 2.6vw, 36px); }
.site-nav__links { display: flex; align-items: center; gap: clamp(20px, 2.6vw, 32px); list-style: none; margin: 0; padding: 0; }
.site-nav__links > li > a,
.nav-item > a {
  display: inline-flex; align-items: center; min-height: 44px;
  font-family: var(--font-mono); font-size: 0.8125rem; letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--ink); text-decoration: none; border-bottom: 2px solid transparent;
}
.site-nav__links > li > a:hover,
.nav-item > a:hover { border-bottom-color: var(--ink); color: var(--ink); }
.site-nav__links > li > a[aria-current],
.nav-item > a[aria-current] { border-bottom-color: var(--signal); }
.nav-toggle {
  display: none; align-items: center; justify-content: center; width: 48px; height: 48px;
  background: transparent; border: 1.5px solid var(--ink); border-radius: var(--radius); cursor: pointer; color: var(--ink);
}
.nav-toggle svg { width: 22px; height: 22px; }
.nav-toggle .icon-close { display: none; }

/* Services dropdown */
.has-sub { position: relative; }
.nav-item { display: flex; align-items: center; gap: 2px; }
.sub-toggle {
  display: inline-flex; align-items: center; justify-content: center; width: 28px; height: 44px; padding: 0;
  background: transparent; border: 0; color: var(--ink); cursor: pointer; border-radius: var(--radius);
}
.sub-toggle svg { width: 12px; height: 12px; transition: transform 0.15s ease; }
.has-sub.is-open .sub-toggle svg { transform: rotate(180deg); }
.subnav { display: none; position: absolute; top: 100%; left: -24px; width: min(640px, calc(100vw - 2 * var(--gutter))); padding-top: 10px; z-index: 30; }
.has-sub.is-open .subnav { display: block; }
.subnav__panel {
  background: var(--white); border: 1px solid var(--ink); border-top: 3px solid var(--signal);
  border-radius: var(--radius); box-shadow: 0 24px 48px -24px rgba(18, 20, 24, 0.35);
}
.subnav__grid { list-style: none; margin: 0; padding: 8px; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 4px; }
.subnav__item {
  display: flex; flex-direction: column; gap: 4px; height: 100%; padding: 14px 16px;
  text-decoration: none; color: var(--ink); border-radius: var(--radius); border-left: 2px solid transparent;
}
.subnav__item:hover, .subnav__item:focus-visible { background: var(--paper); border-left-color: var(--ink); color: var(--ink); }
.subnav__item[aria-current="page"] { background: var(--paper); border-left-color: var(--signal); }
.subnav__item .label { font-size: 0.6875rem; }
.subnav__item strong { font-size: 0.9375rem; font-weight: 700; font-stretch: 108%; line-height: 1.3; }
.subnav__desc { font-size: 0.8125rem; line-height: 1.45; color: var(--graphite); }
.subnav__foot {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 16px;
  padding: 4px 24px 8px; border-top: 1px solid var(--rule);
}
.subnav__foot .text-link { font-size: 0.9375rem; }
.subnav__foot .label { font-size: 0.6875rem; }

@media (hover: hover) and (min-width: 961px) {
  .has-sub:hover .subnav { display: block; }
  .has-sub:hover .sub-toggle svg { transform: rotate(180deg); }
}

@media (max-width: 960px) {
  .nav-toggle { display: inline-flex; }
  .site-nav {
    display: none; position: absolute; left: 0; right: 0; top: 100%;
    flex-direction: column; align-items: stretch; gap: 0;
    background: var(--canvas); border-top: 1px solid var(--ink); border-bottom: 1px solid var(--ink);
    padding: 8px var(--gutter) 24px;
    box-shadow: 0 24px 40px -24px rgba(18, 20, 24, 0.25);
    max-height: calc(100vh - var(--header-h)); overflow-y: auto;
  }
  .site-header.is-open .site-nav { display: flex; }
  .site-header.is-open .nav-toggle .icon-open { display: none; }
  .site-header.is-open .nav-toggle .icon-close { display: block; }
  .site-nav__links { flex-direction: column; align-items: stretch; gap: 0; }
  .site-nav__links > li > a { width: 100%; min-height: 56px; border-bottom: 1px solid var(--rule); font-size: 0.9375rem; }
  .site-nav__links > li > a[aria-current] { border-bottom-color: var(--rule); color: var(--signal-deep); }
  .nav-item { border-bottom: 1px solid var(--rule); }
  .nav-item > a { flex: 1; min-height: 56px; border-bottom: 0; font-size: 0.9375rem; }
  .nav-item > a[aria-current] { color: var(--signal-deep); }
  .sub-toggle { width: 56px; height: 56px; border-left: 1px solid var(--rule); border-radius: 0; }
  .sub-toggle svg { width: 14px; height: 14px; }
  .subnav { position: static; width: auto; padding: 0; }
  .subnav__panel { background: transparent; border: 0; box-shadow: none; border-radius: 0; }
  .subnav__grid { grid-template-columns: minmax(0, 1fr); padding: 4px 0 8px; gap: 0; }
  .subnav__item { flex-direction: row; align-items: center; min-height: 48px; padding: 8px 0 8px 16px; border-left: 2px solid var(--rule); }
  .subnav__item .label, .subnav__desc { display: none; }
  .subnav__item strong { font-weight: 600; font-stretch: 100%; }
  .subnav__foot { display: none; }
  .site-nav .btn { margin-top: 20px; width: 100%; }
}

/* ---------- Spiral graphic ---------- */
.spiral-clip { position: absolute; inset: 0; overflow: hidden; pointer-events: none; z-index: 0; }
.spiral { position: absolute; pointer-events: none; max-width: none; }
.spiral .arc { fill: none; stroke: var(--ink); stroke-linecap: round; }
.spiral .arc-core { fill: none; stroke: var(--signal); stroke-linecap: round; }
.spiral .guide { fill: none; stroke: #BDBDB4; stroke-dasharray: 4 6; }
.spiral .core-dot { fill: var(--signal); }
.spiral .cross { stroke: var(--ink); stroke-width: 1.5; }

/* ---------- Home hero ---------- */
.hero { position: relative; z-index: 2; border-bottom: 1px solid var(--ink); }
.hero .spiral { width: 1400px; height: 1400px; top: -320px; right: -660px; }
.hero__inner { position: relative; z-index: 1; display: flex; flex-direction: column; min-height: 720px; padding-bottom: 40px; }
.hero__content { margin-top: clamp(40px, 6vw, 76px); max-width: 1000px; display: flex; flex-direction: column; gap: 24px; }
.hero h1 { font-size: var(--fs-display); line-height: 1.04; }
.hero h1 span { display: block; }
.hero .lead { max-width: 620px; }
.hero .btn-row { margin-top: 8px; }

@media (max-width: 1100px) {
  .hero .spiral { width: 1100px; height: 1100px; top: -260px; right: -620px; opacity: 0.85; }
}
@media (max-width: 720px) {
  .hero__inner { min-height: 0; }
  .hero .spiral { width: 760px; height: 760px; top: -200px; right: -440px; opacity: 0.55; }
}

/* ---------- Timeline (engagement strip) ---------- */
.timeline { margin-top: auto; padding-top: 64px; display: flex; flex-direction: column; gap: 10px; }
.timeline__phases, .timeline__weeks { display: grid; grid-template-columns: repeat(15, minmax(0, 1fr)); column-gap: 6px; }
.timeline__phase { border-top: 4px solid var(--ink); padding-top: 10px; display: flex; flex-direction: column; gap: 4px; }
.timeline__phase--1 { grid-column: span 2; }
.timeline__phase--2 { grid-column: span 3; }
.timeline__phase--3 { grid-column: span 7; border-top-color: var(--signal); }
.timeline__phase--4 { grid-column: span 3; border-top-style: dashed; }
.timeline__num { font-family: var(--font-mono); font-size: 0.75rem; color: var(--graphite); }
.timeline__name { font-size: 0.9375rem; font-weight: 600; line-height: 1.3; }
.timeline__when { display: none; font-family: var(--font-mono); font-size: 0.75rem; color: var(--graphite); }
.timeline__weeks { font-family: var(--font-mono); font-size: 0.75rem; color: var(--graphite); }
.timeline__weeks span { border-left: 1px solid var(--ink); padding-left: 5px; height: 20px; white-space: nowrap; }
.timeline__weeks .timeline__post { grid-column: span 3; border-left-style: dashed; }

@media (max-width: 860px) {
  .timeline__weeks { display: none; }
  .timeline__phases { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px 16px; }
  .timeline__phase { grid-column: auto !important; }
  .timeline__when { display: block; }
}
@media (max-width: 340px) {
  .timeline__phases { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 480px) {
  .eyebrow { font-size: 0.75rem; letter-spacing: 0.08em; }
}

/* ---------- Inner page hero ---------- */
.page-hero { position: relative; z-index: 2; border-bottom: 1px solid var(--ink); }
.page-hero .spiral { width: 900px; height: 900px; top: -230px; right: -470px; opacity: 0.9; }
.page-hero__inner { position: relative; z-index: 1; padding-top: clamp(32px, 5vw, 64px); padding-bottom: clamp(56px, 7vw, 96px); display: flex; flex-direction: column; gap: 20px; max-width: 860px; }
.page-hero h1 { font-size: var(--fs-h1); }
.breadcrumb { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; margin: 0; padding: 0; font-family: var(--font-mono); font-size: 0.75rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--graphite); }
.breadcrumb li + li::before { content: "/"; margin-right: 8px; color: var(--rule); }
.breadcrumb a { color: var(--graphite); text-decoration: none; }
.breadcrumb a:hover { color: var(--ink); text-decoration: underline; }
@media (max-width: 720px) {
  .page-hero .spiral { width: 560px; height: 560px; top: -150px; right: -330px; opacity: 0.5; }
}

/* ---------- Sections ---------- */
.section { padding-block: var(--section-y); }
.section--white { background: var(--white); border-block: 1px solid var(--rule); }
.section--ink { background: var(--ink); color: var(--paper); }
.section--ink .label { color: var(--haze); }
.section--ink .lead { color: var(--haze); }
.section-head { display: flex; flex-direction: column; gap: 16px; margin-bottom: clamp(32px, 4vw, 56px); max-width: 760px; }
.section-head h2 { font-size: var(--fs-h2); }
.section-head--split { max-width: none; flex-direction: row; justify-content: space-between; align-items: flex-end; gap: 32px; flex-wrap: wrap; }
.section-head--split > div { display: flex; flex-direction: column; gap: 16px; max-width: 720px; }

/* ---------- Cards ---------- */
.card-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; }
.card-grid--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.card-grid--4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
@media (max-width: 1024px) { .card-grid--4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 900px) { .card-grid { grid-template-columns: minmax(0, 1fr); } .card-grid--4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px) { .card-grid--4 { grid-template-columns: minmax(0, 1fr); } }

.card {
  background: var(--white); border: 1px solid var(--rule); border-top: 3px solid var(--ink);
  border-radius: var(--radius); padding: clamp(24px, 3vw, 32px);
  display: flex; flex-direction: column; gap: 12px;
}
.card h3 { margin-top: 4px; }
.card p { color: var(--graphite); font-size: var(--fs-small); line-height: 1.6; }
.card .text-link { margin-top: auto; padding-top: 8px; }
.card--signal { border-top-color: var(--signal); }
.card--plain { border-top-width: 1px; }
.card ul { margin: 4px 0 0; }

.section--ink .card { background: #1B1E23; border-color: #2E323A; border-top-color: var(--paper); }
.section--ink .card p { color: var(--haze); }

/* ---------- Lists ---------- */
.ticks { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 12px; }
.ticks li { position: relative; padding-left: 22px; line-height: 1.5; }
.ticks li::before { content: ""; position: absolute; left: 0; top: 0.5em; width: 8px; height: 8px; background: var(--signal); }
.ticks--small li { font-size: var(--fs-small); color: var(--graphite); }
.section--ink .ticks li { color: var(--paper); }

/* ---------- Split layout ---------- */
.split { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(32px, 6vw, 96px); align-items: start; }
.split--even { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.split--form { grid-template-columns: minmax(0, 7fr) minmax(0, 4fr); }
@media (max-width: 900px) { .split, .split--even, .split--form { grid-template-columns: minmax(0, 1fr); } }
.stack { display: flex; flex-direction: column; gap: 20px; }
.stack--lg { gap: 32px; }

/* ---------- Pillars (numbered statements) ---------- */
.pillars { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); border-top: 1px solid var(--ink); }
.pillar { padding: 28px 28px 8px 0; display: flex; flex-direction: column; gap: 10px; }
.pillar + .pillar { padding-left: 28px; border-left: 1px solid var(--rule); }
.pillar p { color: var(--graphite); font-size: var(--fs-small); }
@media (max-width: 900px) {
  .pillars { grid-template-columns: minmax(0, 1fr); }
  .pillar, .pillar + .pillar { padding: 24px 0; border-left: 0; border-bottom: 1px solid var(--rule); }
}
.section--ink .pillars { border-top-color: var(--paper); }
.section--ink .pillar + .pillar { border-left-color: #2E323A; }
.section--ink .pillar p { color: var(--haze); }
@media (max-width: 900px) { .section--ink .pillar, .section--ink .pillar + .pillar { border-bottom-color: #2E323A; } }

/* ---------- Phases (approach) ---------- */
.phases { display: flex; flex-direction: column; gap: 24px; }
.phase {
  display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 8fr); gap: clamp(24px, 4vw, 64px);
  background: var(--white); border: 1px solid var(--rule); border-top: 4px solid var(--ink);
  border-radius: var(--radius); padding: clamp(24px, 3.5vw, 40px);
}
.phase--active { border-top-color: var(--signal); }
.phase--ongoing { border-top-style: dashed; }
.phase__meta { display: flex; flex-direction: column; gap: 12px; align-items: flex-start; }
.phase__meta h3 { font-size: clamp(1.375rem, 1.1rem + 0.9vw, 1.75rem); font-weight: 800; font-stretch: 112%; }
.tag {
  display: inline-flex; align-items: center; min-height: 28px; padding: 0 10px;
  font-family: var(--font-mono); font-size: 0.75rem; letter-spacing: 0.06em;
  background: var(--paper); border: 1px solid var(--rule); color: var(--ink);
}
.phase__body { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px 40px; }
.phase__body h4 { font-family: var(--font-mono); font-size: var(--fs-label); letter-spacing: 0.12em; text-transform: uppercase; color: var(--graphite); font-weight: 500; margin-bottom: 14px; }
@media (max-width: 960px) {
  .phase { grid-template-columns: minmax(0, 1fr); }
  .phase__body { grid-template-columns: minmax(0, 1fr); }
}

/* ---------- Phase rail (compact four-step summary) ---------- */
.rail { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0; border-top: 1px solid var(--ink); }
.rail__step { padding: 24px 24px 0 0; display: flex; flex-direction: column; gap: 8px; position: relative; }
.rail__step::before { content: ""; position: absolute; top: -6px; left: 0; width: 11px; height: 11px; background: var(--ink); }
.rail__step--active::before { background: var(--signal); }
.rail__step p { color: var(--graphite); font-size: var(--fs-small); }
.section--ink .rail { border-top-color: #4A4E57; }
.section--ink .rail__step::before { background: var(--paper); }
.section--ink .rail__step--active::before { background: var(--signal); }
.section--ink .rail__step p { color: var(--haze); }
@media (max-width: 900px) {
  .rail { grid-template-columns: repeat(2, minmax(0, 1fr)); row-gap: 32px; }
}
@media (max-width: 520px) {
  .rail { grid-template-columns: minmax(0, 1fr); border-top: 0; border-left: 1px solid var(--ink); padding-left: 0; }
  .rail__step { padding: 0 0 0 24px; }
  .rail__step::before { top: 6px; left: -6px; }
  .section--ink .rail { border-left-color: #4A4E57; }
}

/* ---------- Fact rows ---------- */
.facts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0; border: 1px solid var(--rule); background: var(--white); }
.fact { padding: 24px; display: flex; flex-direction: column; gap: 8px; }
.fact + .fact { border-left: 1px solid var(--rule); }
.fact strong { font-size: 1.0625rem; font-stretch: 108%; }
.fact span { color: var(--graphite); font-size: var(--fs-small); }
.facts--stack { grid-template-columns: minmax(0, 1fr); }
.facts--stack .fact + .fact { border-left: 0; border-top: 1px solid var(--rule); }
@media (max-width: 760px) {
  .facts { grid-template-columns: minmax(0, 1fr); }
  .fact + .fact { border-left: 0; border-top: 1px solid var(--rule); }
}

/* ---------- Chips ---------- */
.chips { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; margin: 0; padding: 0; }
.chips li { font-family: var(--font-mono); font-size: 0.8125rem; padding: 6px 12px; background: var(--paper); border: 1px solid var(--rule); }
.section--ink .chips li { background: transparent; border-color: #4A4E57; color: var(--paper); }

/* ---------- Quote / pitch ---------- */
.pitch { font-size: clamp(1.5rem, 1.1rem + 1.6vw, 2.25rem); line-height: 1.25; font-weight: 700; font-stretch: 108%; max-width: 30ch; margin: 0; }
.pitch .accent { color: var(--signal); }

/* ---------- CTA band ---------- */
.cta-band { position: relative; background: var(--ink); color: var(--paper); }
.cta-band .spiral { width: 900px; height: 900px; top: -260px; right: -380px; }
.cta-band .spiral .arc { stroke: var(--paper); }
.cta-band .spiral .guide { stroke: #3A3E46; }
.cta-band .spiral .cross { stroke: var(--paper); }
.cta-band__inner { position: relative; z-index: 1; padding-block: clamp(64px, 8vw, 112px); display: flex; flex-direction: column; gap: 24px; max-width: 720px; }
.cta-band h2 { font-size: var(--fs-h2); }
.cta-band .lead { color: var(--haze); }
.cta-band .label { color: var(--haze); }
@media (max-width: 720px) { .cta-band .spiral { width: 600px; height: 600px; top: -180px; right: -360px; opacity: 0.45; } }

/* ---------- Articles / prose ---------- */
.prose { max-width: 70ch; font-size: 1.125rem; line-height: 1.7; }
.prose > * + * { margin-top: 1.1em; }
.prose h2 { font-size: clamp(1.5rem, 1.25rem + 1vw, 1.875rem); margin-top: 2em; }
.prose h3 { margin-top: 1.6em; }
.prose ul, .prose ol { padding-left: 1.25em; }
.prose li + li { margin-top: 0.4em; }
.prose li::marker { color: var(--signal); }
.prose blockquote { margin-left: 0; padding: 4px 0 4px 20px; border-left: 3px solid var(--signal); font-size: 1.25rem; font-weight: 600; font-stretch: 105%; }
.prose code { font-family: var(--font-mono); font-size: 0.9em; background: var(--paper); border: 1px solid var(--rule); padding: 1px 6px; }
.article-meta { display: flex; flex-wrap: wrap; gap: 8px 20px; font-family: var(--font-mono); font-size: 0.8125rem; color: var(--graphite); letter-spacing: 0.04em; }
.article-layout { display: grid; grid-template-columns: minmax(0, 1fr) 280px; gap: clamp(32px, 6vw, 96px); align-items: start; }
.article-aside { position: sticky; top: 24px; display: flex; flex-direction: column; gap: 16px; padding: 24px; background: var(--white); border: 1px solid var(--rule); border-top: 3px solid var(--signal); }
.article-aside p { font-size: var(--fs-small); color: var(--graphite); }
@media (max-width: 960px) { .article-layout { grid-template-columns: minmax(0, 1fr); } .article-aside { position: static; } }

.post-list { display: flex; flex-direction: column; border-top: 1px solid var(--ink); }
.post {
  display: grid; grid-template-columns: 180px minmax(0, 1fr) auto; gap: 24px 40px; align-items: start;
  padding: 32px 0; border-bottom: 1px solid var(--rule);
}
.post h2 { font-size: clamp(1.375rem, 1.15rem + 0.8vw, 1.75rem); font-stretch: 108%; }
.post h2 a { text-decoration: none; }
.post h2 a:hover { text-decoration: underline; text-decoration-color: var(--signal); }
.post p { color: var(--graphite); margin-top: 10px; max-width: 64ch; }
@media (max-width: 860px) { .post { grid-template-columns: minmax(0, 1fr); gap: 12px; } }

/* ---------- Forms ---------- */
.form { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px 24px; }
.field { display: flex; flex-direction: column; gap: 8px; }
.field--full { grid-column: 1 / -1; }
.field label, .field legend { font-weight: 600; font-size: 0.9375rem; }
.field .hint { font-size: 0.875rem; color: var(--graphite); }
.field input, .field select, .field textarea {
  width: 100%; min-height: 52px; padding: 12px 14px;
  font: inherit; font-size: 1rem; color: var(--ink);
  background: var(--white); border: 1.5px solid #8E9189; border-radius: var(--radius);
}
.field textarea { min-height: 150px; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus { outline: 3px solid var(--signal); outline-offset: 1px; border-color: var(--ink); }
.field fieldset { border: 0; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.check { display: flex; align-items: flex-start; gap: 12px; min-height: 32px; font-size: 0.9375rem; font-weight: 400; }
.check input { width: 20px; height: 20px; min-height: 0; margin: 2px 0 0; accent-color: var(--ink); flex: none; }
.form__actions { grid-column: 1 / -1; display: flex; flex-wrap: wrap; align-items: center; gap: 16px 24px; }
.form__note { font-size: 0.875rem; color: var(--graphite); max-width: 52ch; }
.form-status { grid-column: 1 / -1; padding: 16px 18px; border: 1px solid var(--rule); border-left: 4px solid var(--signal); background: var(--white); }
.form-status[hidden] { display: none; }
@media (max-width: 640px) { .form { grid-template-columns: minmax(0, 1fr); } }

.panel { background: var(--white); border: 1px solid var(--rule); border-top: 3px solid var(--ink); padding: clamp(24px, 4vw, 48px); border-radius: var(--radius); }

.steps { list-style: none; margin: 0; padding: 0; counter-reset: step; display: flex; flex-direction: column; gap: 0; border-top: 1px solid var(--ink); }
.steps li { counter-increment: step; display: grid; grid-template-columns: 44px minmax(0, 1fr); gap: 16px; padding: 20px 0; border-bottom: 1px solid var(--rule); }
.steps li::before { content: "0" counter(step); font-family: var(--font-mono); font-size: 0.875rem; color: var(--signal-deep); padding-top: 2px; }
.steps strong { display: block; margin-bottom: 4px; }
.steps span { color: var(--graphite); font-size: var(--fs-small); }

/* ---------- Footer ---------- */
.site-footer { background: var(--ink); color: var(--haze); font-size: var(--fs-small); }
.site-footer a { color: var(--paper); text-decoration: none; }
.site-footer a:hover { color: var(--white); text-decoration: underline; text-decoration-color: var(--signal); }
.site-footer__top { display: grid; grid-template-columns: minmax(0, 4fr) repeat(3, minmax(0, 2fr)); gap: 40px; padding-block: 72px 56px; }
.site-footer__brand { display: flex; flex-direction: column; gap: 18px; max-width: 340px; }
.site-footer h2 { font-family: var(--font-mono); font-size: 0.75rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--haze); font-weight: 500; margin-bottom: 14px; font-stretch: 100%; }
.site-footer ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 4px; }
.site-footer li a { display: inline-flex; min-height: 36px; align-items: center; }
.site-footer__bottom { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px 24px; padding-block: 24px 32px; border-top: 1px solid #2E323A; font-family: var(--font-mono); font-size: 0.75rem; letter-spacing: 0.04em; }
@media (max-width: 900px) { .site-footer__top { grid-template-columns: repeat(2, minmax(0, 1fr)); } .site-footer__brand { grid-column: 1 / -1; } }
@media (max-width: 480px) { .site-footer__top { grid-template-columns: minmax(0, 1fr); padding-block: 56px 40px; } }

/* ---------- 404 ---------- */
.not-found { position: relative; z-index: 2; min-height: 100vh; display: flex; flex-direction: column; }
.not-found .spiral { width: 1000px; height: 1000px; top: 50%; right: -420px; margin-top: -500px; }
.not-found__body { position: relative; z-index: 1; flex: 1; display: flex; flex-direction: column; justify-content: center; gap: 24px; padding-block: 48px 96px; max-width: 720px; }
@media (max-width: 720px) { .not-found .spiral { width: 600px; height: 600px; margin-top: -300px; right: -360px; opacity: 0.5; } }

/* ---------- Utilities ---------- */
.mt-0 { margin-top: 0; }
.mt-2 { margin-top: 8px; }
.mt-4 { margin-top: 16px; }
.mt-6 { margin-top: 32px; }
.mt-8 { margin-top: 48px; }
.center { text-align: center; }
.divider { height: 1px; background: var(--rule); border: 0; margin: 0; }

.h2 { font-size: var(--fs-h2); }
