:root {
  color-scheme: light;
  --canvas: #F7F9F8;
  --surface: #FFFFFF;
  --subtle: #EEF3F1;
  --ink: #0B1F1D;
  --text: #24302D;
  --muted: #56625E;
  --line: #D6DDDA;
  --line-soft: #E6ECE9;
  --brand: #0F766E;
  --brand-hover: #115E59;
  --brand-tint: #E3F4F0;
  --brand-deep: #042F2E;
  --on-deep: #E6F6F3;
  --on-deep-muted: #9CCFC6;
  --link: #0F766E;
  --btn-bg: #0F766E;
  --btn-fg: #FFFFFF;
  --btn-hover: #115E59;
  --signal: #F59E0B;
  --yes: #0F766E;
  --no: #B4413A;
  --shadow: 0 1px 2px rgba(11, 31, 29, .06), 0 18px 40px -18px rgba(11, 31, 29, .28);
  --radius: 10px;
  --font-display: "Fraunces", Georgia, "Times New Roman", serif;
  --font-body: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, "Cascadia Mono", Consolas, monospace;
  --wrap: 1200px;
  --gutter: clamp(16px, 4vw, 40px);
  --header-h: 64px;
}
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 16px); -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } *, *::before, *::after { transition: none !important; animation: none !important; } }
body {
  margin: 0;
  background: var(--canvas);
  color: var(--text);
  font: 400 16px/1.6 var(--font-body);
  font-feature-settings: "cv11", "ss01";
  text-rendering: optimizeLegibility;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--link); text-underline-offset: 3px; text-decoration-thickness: 1px; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 2px solid var(--brand); outline-offset: 3px; border-radius: 4px; }
h1, h2, h3, h4 { color: var(--ink); text-wrap: balance; margin: 0; }
h1, h2 { font-family: var(--font-display); font-weight: 500; letter-spacing: -0.015em; font-variation-settings: "opsz" 120; }
h3 { font: 600 1.25rem/1.3 var(--font-body); letter-spacing: -0.01em; }
p { margin: 0; }
ul { margin: 0; padding: 0; }
.wrap { width: 100%; max-width: var(--wrap); margin-inline: auto; padding-inline: var(--gutter); }
.mono { font-family: var(--font-mono); font-size: .8125rem; letter-spacing: .02em; }
.eyebrow { font: 500 .75rem/1.4 var(--font-mono); letter-spacing: .08em; text-transform: uppercase; color: var(--brand); }
.skip { position: absolute; left: -9999px; top: 8px; background: var(--surface); color: var(--ink); padding: 8px 12px; z-index: 100; }
.skip:focus { left: 8px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ── Buttons ─────────────────────────────────── */
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  min-height: 44px; padding: 10px 18px; border-radius: 8px;
  font: 600 .9375rem/1.2 var(--font-body); text-decoration: none;
  border: 1px solid transparent; transition: background-color .15s, border-color .15s, color .15s;
}
.btn-primary { background: var(--btn-bg); color: var(--btn-fg); }
.btn-primary:hover { background: var(--btn-hover); }
.btn-ghost { background: transparent; color: var(--ink); border-color: var(--line); }
.btn-ghost:hover { border-color: var(--brand); color: var(--brand); }

/* ── Header ──────────────────────────────────── */
.site-header {
  position: sticky; top: env(safe-area-inset-top, 0px); z-index: 50;
  background: color-mix(in srgb, var(--canvas) 88%, transparent);
  backdrop-filter: saturate(1.4) blur(10px); -webkit-backdrop-filter: saturate(1.4) blur(10px);
  border-bottom: 1px solid var(--line-soft);
}
.site-header .wrap { display: flex; align-items: center; gap: 24px; min-height: var(--header-h); }
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--ink); text-decoration: none; font: 600 1.125rem/1 var(--font-body); letter-spacing: -0.01em; }
.brand img { width: 32px; height: 32px; border-radius: 8px; }
.nav { display: flex; gap: 4px; margin-left: auto; }
.nav a { color: var(--muted); text-decoration: none; font-size: .9375rem; padding: 8px 10px; border-radius: 6px; }
.nav a:hover { color: var(--ink); background: var(--subtle); }
.site-header .btn { min-height: 40px; padding: 8px 14px; }
.menu { display: none; margin-left: auto; }
.menu summary { list-style: none; cursor: pointer; padding: 8px 12px; border: 1px solid var(--line); border-radius: 8px; font-weight: 500; color: var(--ink); }
.menu summary::-webkit-details-marker { display: none; }
.menu[open] .menu-panel { display: grid; }
.menu-panel { display: none; position: absolute; right: var(--gutter); left: var(--gutter); top: calc(var(--header-h) - 4px); gap: 2px; padding: 8px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); }
.menu-panel a { padding: 12px; color: var(--ink); text-decoration: none; border-radius: 6px; }
.menu-panel a:hover { background: var(--subtle); }
@media (max-width: 960px) {
  .nav, .site-header .btn-primary { display: none; }
  .menu { display: block; }
}

/* ── Hero ────────────────────────────────────── */
.hero { padding-block: clamp(40px, 7vw, 88px) clamp(40px, 6vw, 72px); }
.hero .wrap { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.12fr); gap: clamp(32px, 5vw, 64px); align-items: center; }
.hero h1 { font-size: clamp(2.25rem, 4.6vw, 3.75rem); line-height: 1.04; margin-block: 16px 20px; }
.hero h1 em { font-style: italic; color: var(--brand); font-weight: 400; }
.lead { font-size: 1.125rem; line-height: 1.6; color: var(--text); max-width: 60ch; }
.hero-cta { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }
.badges { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 28px; list-style: none; }
.badges li { font: 500 .8125rem/1 var(--font-mono); color: var(--ink); padding: 8px 10px; border: 1px solid var(--line); border-radius: 999px; background: var(--surface); display: inline-flex; align-items: center; gap: 8px; }
.badges li::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--brand); }
.hero-figure { position: relative; margin: 0; }
.hero-frame { position: relative; }
.hero-frame::before {
  content: ""; position: absolute; inset: 28px -18px -18px 28px; border-radius: 14px;
  background:
    repeating-linear-gradient(90deg, transparent 0 47px, color-mix(in srgb, var(--on-deep) 8%, transparent) 47px 48px),
    repeating-linear-gradient(0deg, transparent 0 47px, color-mix(in srgb, var(--on-deep) 8%, transparent) 47px 48px),
    var(--brand-deep);
}
.hero-figure img { position: relative; border-radius: var(--radius); border: 1px solid var(--line); box-shadow: var(--shadow); width: 100%; background: var(--surface); }
.hero-figure figcaption { position: relative; margin-top: 34px; color: var(--muted); }
.hero-figure figcaption b { color: var(--ink); font-weight: 500; }
.signal-dot { position: absolute; top: -8px; right: -8px; width: 18px; height: 18px; border-radius: 50%; background: var(--signal); border: 3px solid var(--canvas); z-index: 1; }
@media (max-width: 1080px) { .hero .wrap { grid-template-columns: minmax(0, 1fr); } .hero-figure { margin-right: 18px; } }

/* ── Key facts ───────────────────────────────── */
.section { padding-block: clamp(56px, 8vw, 104px); }
.section-head { max-width: 760px; margin-bottom: clamp(28px, 4vw, 48px); }
.section-head h2 { font-size: clamp(1.875rem, 3.4vw, 2.75rem); line-height: 1.1; margin-top: 10px; }
.section-head p { margin-top: 16px; color: var(--muted); font-size: 1.0625rem; max-width: 64ch; }
.facts { border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); background: var(--surface); }
.figures { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); list-style: none; }
.figures li { padding: 28px 20px; border-left: 1px solid var(--line-soft); }
.figures li:first-child { border-left: 0; padding-left: 0; }
.figures b { display: block; font: 500 clamp(2rem, 3.2vw, 2.75rem)/1 var(--font-display); color: var(--ink); font-variant-numeric: tabular-nums; font-variation-settings: "opsz" 144; }
.figures span { display: block; margin-top: 8px; font-size: .875rem; color: var(--muted); line-height: 1.4; }
@media (max-width: 980px) { .figures { grid-template-columns: repeat(3, minmax(0, 1fr)); } .figures li:nth-child(4) { border-left: 0; padding-left: 0; } .figures li:nth-child(n+4) { border-top: 1px solid var(--line-soft); } }
@media (max-width: 560px) { .figures { grid-template-columns: repeat(2, minmax(0, 1fr)); } .figures li { border-left: 0 !important; padding-left: 0 !important; border-top: 1px solid var(--line-soft); } .figures li:nth-child(-n+2) { border-top: 0; } .figures li:nth-child(even) { padding-left: 16px !important; } }

.spec { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 48px; margin: 0; }
.spec div { display: grid; grid-template-columns: 11rem minmax(0, 1fr); gap: 16px; padding: 14px 0; border-bottom: 1px solid var(--line-soft); }
.spec dt { font: 500 .8125rem/1.5 var(--font-mono); color: var(--muted); text-transform: uppercase; letter-spacing: .05em; padding-top: 2px; }
.spec dd { margin: 0; color: var(--ink); }
@media (max-width: 860px) { .spec { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 480px) { .spec div { grid-template-columns: minmax(0, 1fr); gap: 4px; } }

/* ── Modules layout (sidebar mirrors the app) ── */
.modules-shell { display: grid; grid-template-columns: 236px minmax(0, 1fr); gap: clamp(32px, 4vw, 56px); align-items: start; }
.app-nav { position: sticky; top: calc(var(--header-h) + 20px + env(safe-area-inset-top, 0px)); max-height: calc(100vh - var(--header-h) - 40px); overflow-y: auto; padding: 12px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
.app-nav p { font: 500 .6875rem/1 var(--font-mono); letter-spacing: .08em; text-transform: uppercase; color: var(--muted); padding: 14px 10px 6px; }
.app-nav p:first-child { padding-top: 4px; }
.app-nav a { display: block; padding: 6px 10px; border-radius: 6px; color: var(--text); text-decoration: none; font-size: .875rem; line-height: 1.35; }
.app-nav a:hover { background: var(--subtle); color: var(--ink); }
.app-nav a[aria-current="true"] { background: var(--brand-tint); color: var(--brand); font-weight: 600; }
@media (max-width: 1080px) {
  .modules-shell { grid-template-columns: minmax(0, 1fr); }
  .app-nav { position: static; max-height: none; display: flex; flex-wrap: wrap; gap: 6px; padding: 14px; }
  .app-nav p { width: 100%; padding: 8px 2px 2px; }
  .app-nav a { border: 1px solid var(--line); border-radius: 999px; padding: 6px 12px; }
}

.group { padding-top: 8px; }
.group + .group { margin-top: clamp(56px, 7vw, 96px); }
.group-head { display: flex; align-items: baseline; gap: 16px; border-bottom: 1px solid var(--ink); padding-bottom: 14px; margin-bottom: 8px; }
.group-head h2 { font-size: clamp(1.625rem, 2.8vw, 2.25rem); line-height: 1.1; }
.group-head .mono { color: var(--muted); margin-left: auto; white-space: nowrap; }
.group-intro { color: var(--muted); max-width: 64ch; margin-top: 16px; }

.module { padding-block: clamp(36px, 4vw, 52px); border-bottom: 1px solid var(--line-soft); }
.module:last-child { border-bottom: 0; }
.module-head { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); gap: 20px 40px; }
.module h3 { grid-column: 1 / -1; font-size: 1.375rem; }
.module h3 small { font: 500 .75rem/1 var(--font-mono); color: var(--muted); letter-spacing: .04em; margin-left: 10px; vertical-align: 3px; }
.module .answer { color: var(--text); }
.ticks { list-style: none; display: grid; gap: 8px; font-size: .9375rem; }
.ticks li { position: relative; padding-left: 20px; }
.ticks li::before { content: ""; position: absolute; left: 0; top: .62em; width: 8px; height: 2px; background: var(--brand); }
@media (max-width: 760px) { .module-head { grid-template-columns: minmax(0, 1fr); } }

.shot { margin: 28px 0 0; }
.shot img { width: 100%; border-radius: var(--radius); border: 1px solid var(--line); box-shadow: var(--shadow); background: var(--surface); }
.shot figcaption { margin-top: 12px; color: var(--muted); font-size: .875rem; }
.shot-pair { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
@media (max-width: 760px) { .shot-pair { grid-template-columns: minmax(0, 1fr); } }

.mini-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr)); gap: 16px; margin-top: 36px; }
.mini { padding: 22px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); scroll-margin-top: calc(var(--header-h) + 16px); }
.mini h3 { font-size: 1.125rem; margin-bottom: 10px; }
.mini p { color: var(--text); font-size: .9375rem; }
.mini .ticks { margin-top: 14px; font-size: .875rem; }

/* Tooth-state legend */
.legend { margin-top: 28px; display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 210px), 1fr)); gap: 12px; }
.legend section { padding: 16px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); }
.legend h4 { font: 500 .6875rem/1 var(--font-mono); letter-spacing: .08em; text-transform: uppercase; color: var(--muted); margin-bottom: 12px; }
.legend ul { list-style: none; display: flex; flex-wrap: wrap; gap: 6px; }
.legend li { font-size: .8125rem; padding: 4px 9px 4px 7px; border-radius: 6px; background: var(--subtle); color: var(--ink); display: inline-flex; align-items: center; gap: 6px; }
.legend li i { width: 9px; height: 9px; border-radius: 2px; background: var(--c); box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .15); flex: none; }
.legend kbd { font: 500 .6875rem/1 var(--font-mono); color: var(--muted); }

/* ── Deep band (AI) ──────────────────────────── */
.band { background: var(--brand-deep); color: var(--on-deep); }
.band h2, .band h3 { color: #FFFFFF; }
.band .eyebrow { color: var(--on-deep-muted); }
.band .section-head p { color: var(--on-deep-muted); }
.ai-cols { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
.ai-col { padding: 28px; border: 1px solid color-mix(in srgb, var(--on-deep) 18%, transparent); border-radius: var(--radius); }
.ai-col h3 { margin-bottom: 6px; }
.ai-col > p { color: var(--on-deep-muted); font-size: .9375rem; }
.ai-col .ticks { margin-top: 18px; color: var(--on-deep); }
.ai-col .ticks li::before { background: var(--signal); }
.ai-note { margin-top: 24px; display: inline-flex; gap: 10px; align-items: center; padding: 10px 14px; border-radius: 8px; background: color-mix(in srgb, var(--signal) 16%, transparent); color: #FFFFFF; font-size: .9375rem; }
.ai-note b { font-family: var(--font-mono); font-weight: 500; font-size: .8125rem; color: var(--signal); }
@media (max-width: 760px) { .ai-cols { grid-template-columns: minmax(0, 1fr); } }

/* ── Security ────────────────────────────────── */
.sec-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr)); gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.sec-item { background: var(--surface); padding: 24px; }
.sec-item .mono { color: var(--brand); display: block; margin-bottom: 10px; font-weight: 500; }
.sec-item h3 { font-size: 1.0625rem; margin-bottom: 8px; }
.sec-item p { font-size: .9375rem; color: var(--muted); }

/* ── LAN diagram ─────────────────────────────── */
.lan { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); gap: 40px; align-items: center; }
.diagram { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); padding: 16px; }
.diagram svg { display: block; width: 100%; min-width: 560px; height: auto; }
.d-box { fill: var(--surface); stroke: var(--line); stroke-width: 1.5; }
.d-owner { fill: var(--brand-tint); stroke: var(--brand); stroke-width: 1.5; }
.d-usb { fill: var(--subtle); stroke: var(--line); stroke-dasharray: 5 4; }
.d-link { stroke: var(--brand); stroke-width: 1.5; fill: none; }
.d-dash { stroke: var(--muted); stroke-width: 1.5; stroke-dasharray: 4 4; fill: none; }
.d-title { fill: var(--ink); font: 600 14px var(--font-body); }
.d-text { fill: var(--muted); font: 400 12.5px var(--font-body); }
.d-label { fill: var(--brand); font: 500 11.5px var(--font-mono); }
@media (max-width: 900px) { .lan { grid-template-columns: minmax(0, 1fr); } }

/* ── Steps (HowTo) ───────────────────────────── */
.steps { list-style: none; counter-reset: step; display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 16px; padding: 0; margin: 0; }
.steps li { counter-increment: step; padding: 22px 20px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
.steps li::before { content: counter(step); display: block; font: 500 2rem/1 var(--font-display); color: var(--brand); margin-bottom: 14px; }
.steps h3 { font-size: 1rem; margin-bottom: 8px; }
.steps p { font-size: .875rem; color: var(--muted); }
.steps code { font: 500 .78rem var(--font-mono); color: var(--ink); background: var(--subtle); padding: 1px 4px; border-radius: 4px; word-break: break-all; }
@media (max-width: 1080px) { .steps { grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr)); } }

/* ── Comparison table ────────────────────────── */
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); }
table { border-collapse: collapse; width: 100%; min-width: 640px; font-size: .9375rem; }
caption { text-align: left; padding: 16px 20px; color: var(--muted); font-size: .875rem; border-bottom: 1px solid var(--line); }
th, td { padding: 14px 20px; text-align: left; border-bottom: 1px solid var(--line-soft); vertical-align: top; }
thead th { font: 500 .75rem/1.3 var(--font-mono); letter-spacing: .06em; text-transform: uppercase; color: var(--muted); background: var(--subtle); }
thead th.us { color: var(--brand); }
tbody th { font-weight: 500; color: var(--ink); }
tbody tr:last-child th, tbody tr:last-child td { border-bottom: 0; }
td.us { background: color-mix(in srgb, var(--brand-tint) 60%, transparent); color: var(--ink); font-weight: 500; }
.y::before, .n::before, .m::before { display: inline-block; width: 1.1em; font-weight: 700; }
.y::before { content: "✓"; color: var(--yes); }
.n::before { content: "✕"; color: var(--no); }
.m::before { content: "~"; color: var(--muted); }

/* ── Multilingual ────────────────────────────── */
.lang { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.4fr); gap: 48px; align-items: center; }
.lang-list { list-style: none; display: grid; gap: 10px; margin-top: 24px; }
.lang-list li { display: flex; gap: 14px; align-items: baseline; padding-bottom: 10px; border-bottom: 1px solid var(--line-soft); }
.lang-list b { font: 500 .8125rem var(--font-mono); color: var(--brand); width: 2.5rem; flex: none; }
.ar { font-family: "Segoe UI", Tahoma, "Noto Naskh Arabic", "Geeza Pro", Arial, sans-serif; }
@media (max-width: 900px) { .lang { grid-template-columns: minmax(0, 1fr); } }

/* ── FAQ ─────────────────────────────────────── */
.faq { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 2fr); gap: 48px; align-items: start; }
.faq-list { border-top: 1px solid var(--line); }
.faq-list details { border-bottom: 1px solid var(--line); }
.faq-list summary { cursor: pointer; list-style: none; padding: 20px 40px 20px 0; position: relative; font: 600 1.0625rem/1.4 var(--font-body); color: var(--ink); }
.faq-list summary::-webkit-details-marker { display: none; }
.faq-list summary::after { content: "+"; position: absolute; right: 4px; top: 16px; font: 400 1.5rem/1 var(--font-body); color: var(--brand); transition: transform .2s; }
.faq-list details[open] summary::after { transform: rotate(45deg); }
.faq-list .a { padding: 0 0 22px; color: var(--text); max-width: 68ch; }
.faq-list .a p + p { margin-top: 10px; }
@media (max-width: 900px) { .faq { grid-template-columns: minmax(0, 1fr); gap: 24px; } }

/* ── CTA + footer ────────────────────────────── */
.cta { background: var(--brand-deep); color: var(--on-deep); border-radius: 16px; padding: clamp(32px, 5vw, 64px); display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: 32px; align-items: center; }
.cta h2 { color: #FFFFFF; font-size: clamp(1.75rem, 3.2vw, 2.5rem); line-height: 1.1; }
.cta p { color: var(--on-deep-muted); margin-top: 14px; max-width: 54ch; }
.cta .contact { display: grid; gap: 14px; justify-items: start; }
.cta .btn-primary { background: #FFFFFF; color: #042F2E; }
.cta .btn-primary:hover { background: #CCFBF1; }
.cta .mail { font: 500 1rem var(--font-mono); color: #FFFFFF; user-select: all; }
@media (max-width: 860px) { .cta { grid-template-columns: minmax(0, 1fr); } }
.site-footer { border-top: 1px solid var(--line); margin-top: clamp(56px, 8vw, 104px); padding-block: 48px calc(32px + env(safe-area-inset-bottom, 0px)); color: var(--muted); font-size: .9375rem; }
.foot-grid { display: grid; grid-template-columns: minmax(0, 1.6fr) repeat(3, minmax(0, 1fr)); gap: 32px; }
.foot-grid h2 { font: 500 .75rem/1 var(--font-mono); letter-spacing: .08em; text-transform: uppercase; color: var(--ink); margin-bottom: 14px; }
.foot-grid ul { list-style: none; display: grid; gap: 8px; }
.foot-grid a { color: var(--muted); text-decoration: none; }
.foot-grid a:hover { color: var(--brand); }
.foot-base { display: flex; flex-wrap: wrap; gap: 12px 24px; justify-content: space-between; margin-top: 40px; padding-top: 20px; border-top: 1px solid var(--line-soft); font-size: .8125rem; }
@media (max-width: 860px) { .foot-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } .foot-grid > div:first-child { grid-column: 1 / -1; } }
