/* KWARIX — the one stylesheet for every page.
   Brand tokens (brand/guide/kwarix-colour-specification.json): gold #C9A24B, obsidian #0B0D12,
   ivory #F4EFE6. Gold is the default theme; [data-theme="blue"] is the alternative.
   The deploy gate scans this file. Nothing here may hide, shrink or move content, except the
   three rules marked "gate-pinned", which scripts/site.mjs matches byte for byte (PINNED_CSS)
   and whose classes it allows only on their own elements. */

:root {
  color-scheme: dark;
  --gold: #C9A24B;
  --obsidian: #0B0D12;
  --ivory: #F4EFE6;

  --bg: var(--obsidian);
  --ink: var(--gold);
  --ink-hot: #F4E3B0;
  --ink-dim: #A38440;
  --text: var(--ivory);
  --text-2: #C5C2BC;
  --text-3: #9B9995;
  --field-line: #816935;
  --error: #F2B8A0;
  --line: rgba(201, 162, 75, 0.24);
  --line-strong: rgba(201, 162, 75, 0.5);
  --plate: rgba(11, 13, 18, 0.8);
  --tint: rgba(201, 162, 75, 0.12);
  --ink-rgb: 201, 162, 75;

  --font-sans: "Avenir Next", "Segoe UI", system-ui, -apple-system, Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-mono: ui-monospace, "SF Mono", Menlo, Consolas, "Liberation Mono", monospace;
  --font-ar: "Geeza Pro", "Noto Sans Arabic", "Segoe UI", Tahoma, sans-serif;
  --gutter: clamp(16px, 4vw, 48px);
}

:root[data-theme="blue"] {
  --bg: #070C14;
  --ink: #4FA8D8;
  --ink-hot: #CDEBFF;
  --ink-dim: #4189B1;
  --text: #E6F1FF;
  --text-2: #B9C3D0;
  --text-3: #919AA6;
  --field-line: #346D8E;
  --error: #F2B8A0;
  --line: rgba(79, 168, 216, 0.24);
  --line-strong: rgba(79, 168, 216, 0.5);
  --plate: rgba(7, 12, 20, 0.8);
  --tint: rgba(79, 168, 216, 0.12);
  --ink-rgb: 79, 168, 216;
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text-2);
  font: 400 18px/1.55 var(--font-sans);
  -webkit-font-smoothing: antialiased;
  overflow-wrap: break-word;
}

:root[lang="ar"] body { font-family: var(--font-ar); }

::selection { background: rgba(var(--ink-rgb), 0.35); color: var(--text); }

a { color: var(--ink); text-decoration-color: var(--line-strong); text-underline-offset: 3px; }
a:hover { color: var(--ink-hot); text-decoration-color: currentColor; }
:focus-visible { outline: 2px solid var(--ink-hot); outline-offset: 3px; border-radius: 2px; }

h1, h2, h3 { margin: 0 0 .5em; color: var(--text); font-weight: 600; line-height: 1.15; text-wrap: balance; }
h1 { font-size: clamp(34px, 5.4vw, 60px); letter-spacing: -.01em; }
h2 { font-size: clamp(28px, 3.6vw, 48px); line-height: 1.1; color: var(--ink); }
h3 { font-size: 19px; }
p { margin: 0 0 1em; }
ul, ol { margin: 0 0 1em; padding-inline-start: 20px; }
[id] { scroll-margin-top: 24px; }

.wrap { width: 100%; max-width: 1360px; margin: 0 auto; padding: 0 var(--gutter); }
.wrap.narrow { max-width: 960px; }

/* gate-pinned: the skip link stays out of sight until it has keyboard focus */
.skip-link:not(:focus) { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }

.skip-link { display: block; padding: 12px var(--gutter); background: var(--ink-hot); color: var(--obsidian); font: 600 14px/1.4 var(--font-mono); }

.ribbon {
  margin: 0;
  padding: 8px var(--gutter);
  background: var(--ink-hot);
  color: var(--obsidian);
  font: 700 12px/1.4 var(--font-mono);
  letter-spacing: .16em;
  text-align: center;
}

/* Header */
.site-head { border-bottom: 1px solid var(--line); }
.site-head__row { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 28px; min-height: 76px; padding-top: 14px; padding-bottom: 14px; }
.brand { display: inline-flex; padding: 6px 0; color: var(--ink); text-decoration: none; }
/* The lockup's thinnest stroke (the small emblem's 14-unit arcs) stays at least one device pixel
   at 1x, and KWARIX's capitals (250 of 400 units) read at 22.5 px (20 px on a phone). */
.lockup { display: block; height: 36px; width: auto; aspect-ratio: 2015 / 400; color: var(--ink); }
.site-nav ul { display: flex; flex-wrap: wrap; gap: 4px 24px; margin: 0; padding: 0; list-style: none; }
.site-nav a:not(.btn) { display: inline-block; padding: 10px 0; color: var(--text-2); font: 600 12px/1.2 var(--font-mono); letter-spacing: .24em; text-transform: uppercase; text-decoration: none; }
.site-nav a:not(.btn):hover { color: var(--ink-hot); }
.site-nav a[aria-current] { color: var(--ink-hot); text-decoration: underline; text-decoration-color: var(--ink); text-underline-offset: 8px; }
.site-nav [lang="ar"], :root[lang="ar"] .site-nav a { font-family: var(--font-ar); font-size: 15px; letter-spacing: 0; text-transform: none; }
@media (max-width: 480px) { .lockup { height: 32px; } .site-nav ul { gap: 4px 16px; } .site-nav a { letter-spacing: .14em; } }

/* Shared type */
.overline { margin-bottom: 28px; color: var(--ink-dim); font: 600 12px/1.4 var(--font-mono); letter-spacing: .34em; text-transform: uppercase; }
.crumbs ol { display: flex; flex-wrap: wrap; gap: 4px 8px; margin: 0 0 20px; padding: 0; list-style: none; color: var(--text-3); font: 400 12px/1.6 var(--font-mono); letter-spacing: .06em; }
.crumbs a { color: var(--text-2); }
.crumbs a:hover { color: var(--ink-hot); }
.sector-list li + li { margin-top: 6px; }
.lede { max-width: 40em; color: var(--text-2); font-size: clamp(18px, 2vw, 21px); }
.meta-line { color: var(--ink-dim); font: 600 12px/1.5 var(--font-mono); letter-spacing: .2em; text-transform: uppercase; }
:root[lang="ar"] .overline { font-family: var(--font-ar); font-size: 15px; letter-spacing: 0; }

/* Buttons: primary is the only filled element, one per screen */
.actions { display: flex; flex-wrap: wrap; gap: 12px; margin: 28px 0 0; }
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 12px 24px;
  border: 1px solid var(--ink);
  border-radius: 999px;
  font: 600 12px/1.2 var(--font-mono);
  letter-spacing: .2em;
  text-transform: uppercase;
  text-decoration: none;
  cursor: pointer;
  transition: background-color .2s, color .2s, border-color .2s, box-shadow .2s;
}
.btn--primary { background: var(--ink); color: var(--bg); }
.btn--primary:hover { border-color: var(--ink-hot); background: var(--ink-hot); color: var(--bg); box-shadow: 0 0 24px rgba(var(--ink-rgb), 0.45); }
.btn--secondary { background: var(--plate); color: var(--ink); } /* a plate, so ripple crests never run through the label */
.btn--secondary:hover { border-color: var(--ink-hot); color: var(--ink-hot); box-shadow: 0 0 18px rgba(var(--ink-rgb), 0.3); }
.btn:disabled { border-color: var(--line-strong); background: none; color: var(--text-3); box-shadow: none; cursor: not-allowed; }
:root[lang="ar"] .btn { font-family: var(--font-ar); font-size: 15px; letter-spacing: 0; text-transform: none; }

/* Sections */
.band { padding: clamp(72px, 9vw, 128px) 0; }
.band + .band { border-top: 1px solid var(--line); }
.page-head { padding: clamp(56px, 9vw, 120px) 0 clamp(28px, 4vw, 48px); }
.section-head { max-width: 760px; margin-bottom: 36px; }
.section-head .lede { margin-bottom: 0; }

.emblem { display: block; height: auto; color: var(--ink); }
/* The full emblem from 96 px up (its 6-unit strokes stay near 2 px at 1x); below that, the small one. */
.emblem--hero { width: clamp(128px, 12vw, 160px); margin-bottom: 28px; }
.emblem--about { width: clamp(112px, 12vw, 144px); }
.emblem--foot { width: 40px; }
.emblem--404 { width: 112px; margin: 0 auto 28px; }

/* Hero: the glyph ripple sits behind the copy; the control tower stands beside it */
.hero { position: relative; display: flex; align-items: center; min-height: clamp(560px, 80vh, 820px); overflow: hidden; border-bottom: 1px solid var(--line); touch-action: pan-y; }

/* gate-pinned: the ripple canvas fills the hero behind its text */
.hero__field { position: absolute; inset: 0; width: 100%; height: 100%; }

/* gate-pinned: the page-wide ripple field, fixed to the viewport behind all content (z-index is
   pinned here and nowhere else, so it can never paint over the ribbon or the company details) */
.page__field { position: fixed; inset: 0; width: 100%; height: 100%; z-index: -1; pointer-events: none; }

.hero__grid { position: relative; display: grid; grid-template-columns: minmax(0, 1fr); gap: 40px; align-items: center; padding-top: 64px; padding-bottom: 64px; }
@media (min-width: 960px) { .hero__grid { grid-template-columns: minmax(0, 11fr) minmax(0, 9fr); gap: 56px; } }
.hero__copy .overline { margin-bottom: 22px; }
.hero__title { max-width: 14em; color: var(--text); font-size: clamp(36px, 4.6vw, 64px); line-height: 1.08; letter-spacing: -0.015em; text-shadow: 0 0 18px var(--bg), 0 0 42px var(--bg); }
.hero__sub { max-width: 30em; color: var(--text-2); font-size: clamp(18px, 2vw, 21px); text-shadow: 0 0 12px var(--bg); }
.hero__small { max-width: 36em; margin: 24px 0 0; color: var(--ink-dim); font: 400 13px/1.7 var(--font-mono); letter-spacing: .04em; text-shadow: 0 0 10px var(--bg); }
/* The Arabic page keeps the centred one-column hero (src/pages/ar/index.html). */
.hero__inner { position: relative; display: flex; flex-direction: column; align-items: center; padding-top: 72px; padding-bottom: 72px; text-align: center; }
.hero .actions { margin-top: 28px; }
.hero__credit { max-width: 42em; margin: 44px 0 0; color: var(--ink-dim); font: 400 13px/1.7 var(--font-mono); letter-spacing: .04em; text-shadow: 0 0 10px var(--bg); }
:root[lang="ar"] .hero__credit { font-family: var(--font-ar); font-size: 16px; letter-spacing: 0; }

/* The control tower card (home hero, right): the live scope, the event feed, the legend */
.tower-card { padding: 18px; border: 1px solid var(--line); border-radius: 4px; background: var(--plate); }
.tower-card__head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 8px; margin: 0 0 12px; color: var(--text-3); font: 600 11px/1.4 var(--font-mono); letter-spacing: .16em; text-transform: uppercase; }
.tag { display: inline-block; padding: 3px 8px; border: 1px solid var(--line-strong); border-radius: 3px; color: var(--ink-hot); font: 600 10px/1.5 var(--font-mono); letter-spacing: .14em; text-transform: uppercase; }
.feed { margin: 14px 0 0; padding: 0; list-style: none; }
.feed li { margin: 0 0 8px; padding: 9px 12px; border: 1px solid var(--line); border-radius: 3px; color: var(--text-2); font: 500 13px/1.45 var(--font-mono); }
.feed li:first-child { border-color: var(--line-strong); color: var(--text); }
.feed__glyph { color: var(--ink); font-weight: 600; }
.legend { display: flex; flex-wrap: wrap; gap: 6px 14px; margin: 12px 0 0; color: var(--text-3); font: 400 12px/1.6 var(--font-mono); }

/* The live scope (js/radar.js) replaces the static one inside this square; without the script the
   static drawing stays. In the card's flow, never over text. */
.radar { display: block; width: 100%; max-width: 480px; height: auto; margin: 0 auto; }
.tower__radar { width: 100%; max-width: 560px; aspect-ratio: 1 / 1; margin: 0 auto; }
.tower__radar .radar { max-width: none; }
.tower__canvas { display: block; width: 100%; height: 100%; }
.radar__ring { fill: none; stroke: var(--line-strong); stroke-width: 1; }
.radar__cross { fill: none; stroke: var(--line); stroke-width: 1; }
.radar__sweep { fill: none; stroke: var(--ink); stroke-width: 2; }
.radar__pt { fill: none; stroke: var(--ink); stroke-width: 2; }
.radar__pt--solid { fill: var(--ink); }
.radar__halo { fill: none; stroke: var(--ink-hot); stroke-width: 2; stroke-dasharray: 3 4; }
.radar__hub { fill: var(--ink); }
.radar-legend { margin: 16px 0 0; color: var(--ink-dim); font: 600 12px/1.6 var(--font-mono); letter-spacing: .12em; text-align: center; }

/* Sources: footnote marks in the text, the numbered list, the mono notes */
.src, .source-line { color: var(--text-3); font: 500 12px/1.6 var(--font-mono); letter-spacing: .02em; }
.source-line { margin: 12px 0 0; }
.fn-ref { padding: 0 1px; color: var(--ink); font-size: 14px; text-decoration: none; }
.sources { max-width: 60em; margin: 24px 0 0; padding: 0; list-style: none; color: var(--text-3); font: 400 13px/1.7 var(--font-mono); }
.sources li { margin: 4px 0; }
.sources a { color: var(--text-2); }
.sources-block h2 { font-size: clamp(20px, 2.4vw, 26px); }
.mono-note { max-width: 46em; color: var(--text-3); font: 400 13px/1.7 var(--font-mono); letter-spacing: .04em; }

/* The Leak Calculator (js/calc.js creates the fields; the page carries the words) */
.calc { max-width: 880px; padding: clamp(22px, 3vw, 36px); border: 1px solid var(--line-strong); border-radius: 4px; background: var(--plate); }
.calc__grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: 18px 28px; margin: 0 0 22px; }
@media (min-width: 720px) { .calc__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.calc__field label { display: block; margin-bottom: 8px; color: var(--ink-dim); font: 600 11px/1.4 var(--font-mono); letter-spacing: .2em; text-transform: uppercase; }
.calc__field input { width: 100%; padding: 8px 2px 10px; border: 0; border-bottom: 1px solid var(--field-line); border-radius: 0; background: none; color: var(--text); font: 600 22px/1.3 var(--font-mono); appearance: textfield; }
.calc__field input:focus { border-bottom-color: var(--ink); box-shadow: 0 8px 12px -8px rgba(var(--ink-rgb), 0.55); }
.calc__out { margin: 0; color: var(--text); font-size: clamp(22px, 2.6vw, 30px); font-weight: 600; line-height: 1.3; text-wrap: balance; }
.calc__out strong { color: var(--ink-hot); font-variant-numeric: tabular-nums; }
.calc__working { max-width: 54em; margin: 16px 0 0; color: var(--text-3); font: 400 13px/1.7 var(--font-mono); letter-spacing: .02em; }
.leaks { display: grid; grid-template-columns: minmax(0, 1fr); gap: 16px; margin: 40px 0 0; padding: 0; list-style: none; }
@media (min-width: 860px) { .leaks { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.leak { padding-top: 16px; border-top: 2px solid var(--ink); }
.leak strong { display: block; margin-bottom: 6px; color: var(--text); font-size: 20px; line-height: 1.3; }
.leak p { margin: 0; font-size: 16px; }

/* Tell-Show-Tell modules, and the sample panels inside them */
.modules { display: grid; grid-template-columns: minmax(0, 1fr); gap: 18px; margin: 0; padding: 0; list-style: none; }
@media (min-width: 900px) { .modules { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.module { display: flex; flex-direction: column; padding: 22px; border: 1px solid var(--line); border-radius: 4px; background: var(--plate); }
.module h3 { color: var(--ink); font-size: 18px; }
.module__tell { color: var(--text); font-style: italic; }
.module p:last-child { margin-bottom: 0; }
.show { margin: 6px 0 18px; padding: 14px; border: 1px solid var(--line); border-radius: 3px; background: var(--bg); }
.show ul { margin: 0; padding: 0; list-style: none; }
.bubble { max-width: 88%; margin: 0 0 8px; padding: 8px 11px; border-radius: 10px; color: var(--text-2); font-size: 14px; line-height: 1.4; }
.bubble--in { border: 1px solid var(--line); border-bottom-left-radius: 3px; }
.bubble--out { margin-inline-start: auto; background: var(--tint); color: var(--text); border-bottom-right-radius: 3px; }
.bubble__who { display: block; margin-bottom: 3px; color: var(--ink); font: 600 10px/1.4 var(--font-mono); letter-spacing: .14em; text-transform: uppercase; }
.brow { display: flex; justify-content: space-between; align-items: center; gap: 10px; margin: 0 0 6px; padding: 8px 10px; border: 1px solid var(--line); border-radius: 3px; color: var(--text-2); font-size: 14px; }
.brow__status { color: var(--text-3); font: 400 12px/1.5 var(--font-mono); text-align: end; }
.dot { margin-inline-end: 8px; font-size: 12px; }
.dot--ok { color: var(--ink-dim); }
.dot--warn { color: var(--ink-hot); }
.dot--bad { color: var(--error); }
.brow--hot { border-color: var(--error); color: var(--text); }
.intake { margin: 0; padding: 0; list-style: none; }
.intake li { display: grid; grid-template-columns: 7em minmax(0, 1fr); gap: 10px; padding: 6px 0; border-top: 1px solid var(--line); font-size: 14px; }
.intake li:first-child { border-top: 0; }
.intake__k { color: var(--ink-dim); font: 600 11px/1.9 var(--font-mono); letter-spacing: .12em; text-transform: uppercase; }
.more-link { margin: 18px 0 0; font: 600 12px/1.4 var(--font-mono); letter-spacing: .14em; text-transform: uppercase; }

/* The alternatives (a definition list read as rows) */
.alt { margin: 0; }
.alt__row { display: grid; grid-template-columns: minmax(0, 1fr); gap: 4px 28px; padding: 16px 0; border-top: 1px solid var(--line); }
@media (min-width: 720px) { .alt__row { grid-template-columns: 12em minmax(0, 1fr); } }
.alt dt { color: var(--text); font-weight: 600; }
.alt dd { margin: 0; color: var(--text-2); }
.alt__close { margin: 28px 0 0; color: var(--text); font-size: clamp(19px, 2vw, 22px); font-weight: 600; max-width: 40em; }

/* Why most AI projects stall: three cards */
.stall { display: grid; grid-template-columns: minmax(0, 1fr); gap: 18px; margin: 0; padding: 0; list-style: none; }
@media (min-width: 860px) { .stall { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.stall li { padding: 22px; border: 1px solid var(--line); border-radius: 4px; background: var(--plate); }
.stall .src { display: block; margin-bottom: 12px; }
.stall h3 { color: var(--text); font-size: 20px; }
.stall p { margin: 0; font-size: 16px; }

/* Where to start: The First System band and the three-step plan */
.first-system { max-width: 880px; padding: clamp(24px, 3vw, 40px); border: 1px solid var(--line); border-inline-start: 4px solid var(--ink); border-radius: 4px; background: var(--plate); }
.first-system h3 { color: var(--ink); font-size: clamp(22px, 2.4vw, 28px); }
.first-system p { max-width: 40em; }
.first-system p:last-child { margin-bottom: 0; }
.plan { display: grid; grid-template-columns: minmax(0, 1fr); gap: 16px; margin: 36px 0 0; padding: 0; list-style: none; }
@media (min-width: 860px) { .plan { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.plan li { padding-top: 16px; border-top: 1px solid var(--line-strong); }
.plan__num { display: block; margin-bottom: 8px; color: var(--ink); font: 600 13px/1.4 var(--font-mono); letter-spacing: .2em; }
.plan strong { display: block; margin-bottom: 6px; color: var(--text); font-size: 19px; }
.plan p { margin: 0; font-size: 16px; }
.small-line { max-width: 46em; margin: 28px 0 0; color: var(--text-3); font-size: 15px; }

/* Two columns of plain lists */
.two-col { display: grid; grid-template-columns: minmax(0, 1fr); gap: 28px 56px; }
@media (min-width: 860px) { .two-col { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.two-col h3 { color: var(--ink); font-size: 18px; }

/* Tiles: trust, stance, principles, the honesty tile */
.tiles { display: grid; grid-template-columns: minmax(0, 1fr); gap: 16px; margin: 0; padding: 0; list-style: none; }
@media (min-width: 640px) { .tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 960px) { .tiles { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.tile { padding: 20px 22px; border: 1px solid var(--line); border-radius: 4px; background: var(--plate); }
.tile h3 { margin: 0 0 8px; color: var(--text); font-size: 18px; font-weight: 600; line-height: 1.3; }
.tile p { margin: 0; color: var(--text-2); font-size: 15px; }
.honesty-tile { max-width: 46em; margin: 28px 0 0; padding: 18px 22px; border: 1px solid var(--line-strong); border-radius: 4px; background: var(--plate); color: var(--text); font-size: 18px; font-weight: 600; }
.honesty-tile__mark { margin-inline-end: 12px; color: var(--ink); }

/* Industry tabs on the home page (js/tabs.js) and the panels they reveal */
.tabs__list { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 22px; padding: 0; list-style: none; }
.tabs__tab { padding: 10px 16px; border: 1px solid var(--line-strong); border-radius: 999px; background: var(--plate); color: var(--text-2); font: 600 12px/1.2 var(--font-mono); letter-spacing: .12em; text-transform: uppercase; cursor: pointer; }
.tabs__tab:hover { border-color: var(--ink-hot); color: var(--ink-hot); }
.tabs__tab[aria-selected="true"] { border-color: var(--ink-hot); background: var(--tint); color: var(--ink-hot); }
.tabs__panel { margin: 0 0 18px; padding: clamp(22px, 3vw, 36px); border: 1px solid var(--line); border-radius: 4px; background: var(--plate); }
.tabs__panel h3 { color: var(--ink-dim); font: 600 12px/1.4 var(--font-mono); letter-spacing: .24em; text-transform: uppercase; }
.tabs__quote { max-width: 30em; color: var(--text); font-size: clamp(20px, 2.4vw, 28px); font-weight: 500; line-height: 1.3; }
.stat { max-width: 40em; margin: 18px 0 22px; color: var(--text-2); font-size: 16px; }
.stat__figure { display: block; color: var(--ink); font-family: var(--font-sans); font-size: clamp(28px, 3.2vw, 42px); font-weight: 600; line-height: 1.1; font-variant-numeric: tabular-nums; }
.stat .src { display: block; margin-top: 4px; }
.ind-card__stat { margin: 0 0 10px; font-size: 15px; }
.ind-card__stat .stat__figure { font-size: 24px; }
.ind-card__what { color: var(--text); font-size: 16px; }

/* Before and after */
.ba-grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: 14px; margin: 18px 0 0; padding: 0; list-style: none; }
@media (min-width: 760px) { .ba-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.ba-item { padding: 14px 16px; border: 1px solid var(--line); border-radius: 4px; background: var(--bg); }
.ba-item__title { margin: 0 0 8px; color: var(--text); font-size: 16px; font-weight: 600; }
.ba-line { display: grid; grid-template-columns: 4.5em minmax(0, 1fr); gap: 10px; margin: 0 0 6px; font-size: 15px; line-height: 1.45; }
.ba-line__label { color: var(--text-3); font: 600 10px/1.9 var(--font-mono); letter-spacing: .14em; text-transform: uppercase; }
.ba-line--after { color: var(--text); }
.ba-line--after .ba-line__label { color: var(--ink); }

/* FAQ: the list on /faq, the six short answers on the home page */
.faq { margin: 0; }
.faq__item { padding: 20px 0; border-top: 1px solid var(--line); }
.faq dt { margin: 0 0 8px; color: var(--text); font-size: clamp(19px, 2vw, 23px); font-weight: 600; line-height: 1.3; }
.faq dd { margin: 0; max-width: 46em; color: var(--text-2); }
.faq--short { display: grid; grid-template-columns: minmax(0, 1fr); gap: 0 40px; }
@media (min-width: 860px) { .faq--short { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.faq--short dt { font-size: 18px; }
.faq--short dd { font-size: 16px; }

/* The close */
.band--closing { border-top: 1px solid var(--line); text-align: center; }
.band--closing .actions { justify-content: center; }
.band--closing .lede { margin: 0 auto; }
.last-line { margin: 32px 0 0; color: var(--text-3); font: 400 13px/1.7 var(--font-mono); letter-spacing: .04em; }
.close-email { margin: 28px 0 12px; }
.copy-email { color: var(--ink); overflow-wrap: anywhere; text-decoration-color: var(--line-strong); text-underline-offset: 6px; }
.copy-email:hover { color: var(--ink-hot); }
.close-email .copy-email { font-family: var(--font-mono); font-weight: 600; font-size: clamp(20px, 2.4vw, 28px); line-height: 1.3; }
.reply-line { color: var(--text-3); font-size: 15px; }
.consultant-line { max-width: 40em; margin: 18px auto 0; color: var(--text-2); font-size: 16px; }

/* Industry pages (content v5 §5): the case-study template */
.scenario-tag { color: var(--ink-hot); }
.industry__headline { max-width: 20em; font-size: clamp(30px, 4.5vw, 56px); line-height: 1.12; font-weight: 500; }
.industry { padding-bottom: clamp(56px, 8vw, 104px); }
.industry > section { padding: 40px 0; border-top: 1px solid var(--line); }
.industry__cost h2 { font-size: clamp(20px, 2.4vw, 26px); color: var(--ink-dim); }
.cost-strip { display: grid; grid-template-columns: minmax(0, 1fr); gap: 20px; margin: 0 0 36px; padding: 0; list-style: none; }
@media (min-width: 860px) { .cost-strip { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.cost-item { padding-inline-start: 16px; border-inline-start: 2px solid var(--ink); }
.cost-item__figure { display: block; margin-bottom: 6px; color: var(--ink); font-family: var(--font-sans); font-size: clamp(26px, 3vw, 38px); font-weight: 600; line-height: 1.1; font-variant-numeric: tabular-nums; }
.cost-item__line { color: var(--text-2); font-size: 15px; line-height: 1.5; }
.d3 { color: var(--text); font-size: clamp(22px, 2.8vw, 32px); font-weight: 600; line-height: 1.2; text-wrap: balance; }
.industry__problem { display: grid; grid-template-columns: minmax(0, 1fr); gap: 32px; align-items: start; }
@media (min-width: 960px) { .industry__problem { grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: 56px; } }
.industry__text p { max-width: 40em; }
.industry__scope .radar { max-width: 343px; }
@media (min-width: 960px) { .industry__scope .radar { max-width: 420px; } }
.scene-grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: 32px; align-items: start; }
@media (min-width: 960px) { .scene-grid--board { grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: 56px; } }
.scene { max-width: 44em; margin: 18px 0 0; padding: 0 0 0 24px; border-inline-start: 2px solid var(--line-strong); list-style: none; }
.scene li { margin: 0 0 24px; }
.scene__time { display: block; margin-bottom: 6px; color: var(--ink); font: 600 12px/1.4 var(--font-mono); letter-spacing: .16em; text-transform: uppercase; }
.scene p { margin: 0; color: var(--text); font-size: 17px; line-height: 1.55; }
.board { padding: 18px; border: 1px solid var(--line); border-radius: 4px; background: var(--plate); }
.board__head { display: flex; justify-content: space-between; align-items: center; gap: 8px; margin: 0 0 12px; color: var(--text-3); font: 600 11px/1.4 var(--font-mono); letter-spacing: .16em; text-transform: uppercase; }
.board__rows { margin: 0; padding: 0; list-style: none; }
.ticks { margin: 18px 0 0; padding: 0; list-style: none; }
.ticks li { display: flex; gap: 12px; align-items: flex-start; margin: 0 0 10px; color: var(--text); }
.tick { color: var(--ink); font-weight: 600; }
.through { display: flex; flex-wrap: wrap; gap: 10px; margin: 18px 0 0; padding: 0; list-style: none; }
.through a { display: inline-block; padding: 9px 16px; border: 1px solid var(--line-strong); border-radius: 999px; color: var(--text-2); font: 600 11px/1.4 var(--font-mono); letter-spacing: .14em; text-transform: uppercase; text-decoration: none; }
.through a:hover { border-color: var(--ink); color: var(--ink-hot); }
.d2 { color: var(--text); font-size: clamp(28px, 4.5vw, 64px); font-weight: 600; line-height: 1.05; letter-spacing: -.01em; text-wrap: balance; }
.industry__closing { max-width: 18em; margin: 56px 0 0; }
.industry__contact { padding-top: 8px; }
.industry__contact .consultant-line { margin-inline-start: 0; }
.proof-line { color: var(--text-2); font-style: italic; }

/* Industries index */
.ind-cards { display: grid; grid-template-columns: minmax(0, 1fr); gap: 16px; margin: 36px 0 0; padding: 0; list-style: none; }
@media (min-width: 640px) { .ind-cards { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1100px) { .ind-cards { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.ind-card { padding: 24px 22px; border: 1px solid var(--line); border-radius: 4px; background: var(--plate); transition: border-color .2s; }
.ind-card:hover, .ind-card:focus-within { border-color: var(--ink); }
.ind-card h2, .ind-card h3 { margin: 0 0 12px; color: var(--text); font-size: 22px; line-height: 1.25; }
.ind-card h2 a, .ind-card h3 a { color: var(--text); text-decoration: none; }
.ind-card h2 a:hover, .ind-card h3 a:hover { color: var(--ink-hot); }
.ind-card__pain { color: var(--ink); font-style: italic; }
.ind-card p { font-size: 16px; }
.ind-card__link { margin: 14px 0 0; font: 600 12px/1.4 var(--font-mono); letter-spacing: .14em; text-transform: uppercase; }

/* Services: three tiers of thirteen */
.tier { padding: 44px 0 12px; border-top: 1px solid var(--line-strong); }
.tier > h2 { margin-bottom: 6px; }
.tier__lede { max-width: 40em; margin-bottom: 28px; color: var(--text-2); }
.svc { margin: 0; padding: 0; list-style: none; }
.svc__item { display: grid; grid-template-columns: minmax(0, 1fr); gap: 6px 40px; padding: 24px 0; border-top: 1px solid var(--line); }
@media (min-width: 900px) { .svc__item { grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); } }
.svc__item h3 { margin: 0 0 6px; color: var(--text); font-size: 21px; }
.svc__item h3 a { color: var(--text); text-decoration: none; }
.svc__item h3 a:hover { color: var(--ink-hot); }
.svc__line { margin: 0 0 10px; color: var(--text-2); }
.svc__for { margin: 0; color: var(--ink-dim); font: 600 12px/1.6 var(--font-mono); letter-spacing: .12em; }
.svc__list { margin: 0; padding-inline-start: 18px; color: var(--text-2); font-size: 15px; }
.svc__list li + li { margin-top: 4px; }
.supply-line { margin: 40px 0 0; padding-top: 18px; border-top: 1px solid var(--line); color: var(--text-3); font-size: 14px; }

/* Products */
.product { display: grid; grid-template-columns: auto 1fr; gap: 20px 28px; align-items: start; max-width: 880px; padding: clamp(22px, 3vw, 36px); border: 1px solid var(--line); border-radius: 4px; background: var(--plate); }
.product__logo { display: block; width: 69px; height: auto; }
.product__body p { max-width: 40em; }
@media (max-width: 560px) { .product { grid-template-columns: 1fr; } }
.products-page { padding-bottom: clamp(56px, 8vw, 104px); }
.product--page h2 { color: var(--text); }
.products-more { margin-top: 44px; padding-top: 28px; border-top: 1px solid var(--line); }
.products-more h2 { font-size: clamp(20px, 2.4vw, 26px); }
.demo-label { margin: 16px 0 0; color: var(--text-3); font-size: 15px; }
.product__features { margin: 0 0 8px; }
.product__features li + li { margin-top: 6px; }

/* Engineering: the architecture and boundary drawings, the seven blocks */
.arch { margin: 36px 0 40px; padding: 22px; border: 1px solid var(--line); border-radius: 4px; background: var(--plate); font-family: var(--font-mono); }
.arch__row { display: grid; grid-template-columns: minmax(0, 1fr); gap: 10px; align-items: center; }
@media (min-width: 900px) { .arch__row { grid-template-columns: minmax(0, 3fr) auto minmax(0, 3fr) auto minmax(0, 4fr); gap: 14px; } }
.arch__box { padding: 14px 16px; border: 1px solid var(--line-strong); border-radius: 3px; }
.arch__box--core { border-color: var(--ink); }
.arch__box--yours { border-style: dashed; }
.arch__stack { display: grid; gap: 10px; }
.arch__name { display: block; color: var(--ink); font-size: 12px; font-weight: 600; letter-spacing: .2em; }
.arch__parts { display: block; margin-top: 4px; color: var(--text-2); font-size: 13px; line-height: 1.5; }
.arch__arrow { color: var(--ink); font-size: 18px; text-align: center; }
.arch__rails { margin: 18px 0 0; padding-top: 14px; border-top: 1px solid var(--line-strong); color: var(--ink-dim); font-size: 12px; font-weight: 600; letter-spacing: .2em; text-align: center; }
.arch__note { margin: 14px 0 0; color: var(--text-3); font-size: 13px; line-height: 1.6; }
.eng-blocks { display: grid; grid-template-columns: minmax(0, 1fr); gap: 0 48px; }
@media (min-width: 900px) { .eng-blocks { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.eng-block { padding: 22px 0; border-top: 1px solid var(--line); }
.eng-block h3 { color: var(--ink); font-size: 20px; }
.eng-block p { margin: 0; font-size: 17px; }
.eng-block ul { margin: 0; padding-inline-start: 18px; font-size: 16px; }

/* About and legal prose */
.page-head--seal { display: flex; flex-direction: column; align-items: flex-start; gap: 28px; }
.prose { padding-bottom: clamp(56px, 8vw, 104px); }
.prose section { margin: 0 0 44px; }
.prose p, .prose li { max-width: 40em; }
.legal h2 { font-size: clamp(20px, 2.4vw, 26px); }
.terms li { margin-bottom: 14px; }
.terms strong { color: var(--text); }
.rules { max-width: 46em; margin: 20px 0 0; padding-inline-start: 22px; }
.rules li { margin: 10px 0; border-bottom: 1px solid var(--line); padding-bottom: 10px; }
.rules strong { color: var(--text); }

/* Licence day: the company details block on the legal pages */
.entity { margin: 32px 0 44px; padding: 24px 28px; border: 1px solid var(--line-strong); border-radius: 4px; background: var(--plate); }
.entity h2 { font-size: 20px; }
.entity__grid { display: grid; gap: 14px; margin: 0; }
.entity__row dt { color: var(--ink-dim); font: 600 12px/1.6 var(--font-mono); letter-spacing: .2em; text-transform: uppercase; }
.entity__row dd { margin: 0; color: var(--text); font-weight: 600; }
.legal-name { color: var(--ink-hot); }

/* Contact block and form */
.reach { display: flex; flex-wrap: wrap; align-items: baseline; gap: 8px 14px; margin: 18px 0 0; }
.reach a:not(.btn) { font-size: 20px; }
.send-list { margin: 18px 0 0; padding: 0; list-style: none; }
.send-list li { display: flex; gap: 12px; align-items: flex-start; margin: 0 0 10px; color: var(--text); }

.form__grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0 28px; }
@media (max-width: 640px) { .form__grid { grid-template-columns: 1fr; } }
.field { margin-bottom: 22px; }
.field--wide { grid-column: 1 / -1; }
.field label { display: block; margin-bottom: 8px; color: var(--ink-dim); font: 600 11px/1.4 var(--font-mono); letter-spacing: .24em; text-transform: uppercase; }
.field input, .field textarea, .field select {
  width: 100%;
  padding: 8px 2px 10px;
  border: 0;
  border-bottom: 1px solid var(--field-line);
  border-radius: 0;
  background: none;
  color: var(--text);
  font: 400 16px/1.5 var(--font-sans);
  appearance: none;
  transition: border-color .2s, box-shadow .2s;
}
.field input:focus, .field textarea:focus, .field select:focus { border-bottom-color: var(--ink); box-shadow: 0 8px 12px -8px rgba(var(--ink-rgb), 0.55); }
.field input[aria-invalid="true"], .field textarea[aria-invalid="true"] { border-bottom-color: var(--error); }
.field select { cursor: pointer; }
.field select option { background: var(--bg); color: var(--text); }
.field textarea { min-height: 128px; resize: vertical; }
.field ::placeholder { color: var(--text-3); }
.field__help { margin: 8px 0 0; color: var(--text-3); font-size: 14px; }
.field__error { margin: 6px 0 0; color: var(--error); font-size: 14px; }
.field__error:empty { margin: 0; }

/* gate-pinned: the honeypot field is for bots only */
.hp { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }

.form__actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 20px; margin-top: 8px; }
.form__status { margin: 0; color: var(--text); }
.form__privacy { max-width: 48em; margin: 18px 0 0; color: var(--text-3); font-size: 14px; }

/* 404 */
.notfound { padding: clamp(72px, 12vw, 160px) 0; text-align: center; }
.notfound .actions { justify-content: center; }

/* Footer */
.site-foot { padding: 40px 0 48px; border-top: 1px solid var(--line); color: var(--text-3); font-size: 14px; }
.site-foot p { margin: 0; }
.site-foot__grid { display: grid; grid-template-columns: 1fr; gap: 22px 40px; align-items: center; }
@media (min-width: 860px) { .site-foot__grid { grid-template-columns: auto 1fr auto; } .site-foot__note { grid-column: 1 / 3; } }
.site-foot__brand { display: flex; align-items: center; gap: 14px; }
.site-foot__place { color: var(--text-2); font: 600 12px/1.6 var(--font-mono); letter-spacing: .2em; }
.site-foot__nav ul { display: flex; flex-wrap: wrap; gap: 10px 22px; margin: 0; padding: 0; list-style: none; }
.site-foot__nav a { color: var(--text-2); }
.site-foot__nav a:hover { color: var(--ink-hot); }
.site-foot .site-foot__email { margin: 0 0 24px; }
.site-foot__email .copy-email { font-family: var(--font-mono); font-weight: 600; font-size: 18px; line-height: 1.5; }
.site-foot .site-foot__colophon { color: var(--text-3); font: 400 12px/1.6 var(--font-mono); letter-spacing: .04em; }
@media (min-width: 860px) { .site-foot__colophon { grid-column: 1 / 3; } }

.site-nav .site-nav__cta { padding: 9px 16px; min-height: 0; font-size: 11px; letter-spacing: .2em; }

/* Latin names inside Arabic text stay on one line ("ABS Twin", "abstwin.com"). */
[dir="rtl"] bdi[lang="en"] { white-space: nowrap; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .btn, .ind-card, .field input, .field textarea, .field select { transition: none; }
}

/* Glossary terms (src/glossary.json) and their bubble (js/tooltip.js). */
.term { text-decoration: underline dotted var(--ink-dim); text-decoration-thickness: 1px; text-underline-offset: 4px; cursor: help; }
.term:hover, .term:focus-visible { color: var(--ink-hot); text-decoration-color: var(--ink); }

/* gate-pinned: the glossary bubble is fixed to the viewport; the script places it beside its term */
.tip { position: fixed; left: 0; top: 0; }

.tip { max-width: 300px; padding: 10px 12px; border: 1px solid var(--line-strong); border-radius: 4px; background: var(--bg); color: var(--text); font: 400 14px/1.45 var(--font-sans); letter-spacing: 0; text-transform: none; box-shadow: 0 6px 24px rgba(0, 0, 0, 0.45); pointer-events: none; }

/* An open launch value (src/launch-values.json): visible in previews, refused in production. */
.lv-mark { display: inline-block; padding: 2px 8px; border: 1px solid var(--error); border-radius: 3px; color: var(--error); font: 600 11px/1.5 var(--font-mono); letter-spacing: .08em; }
