/* Access Controller marketing site - single stylesheet.
   Palette matches the product UI: deep navy, sky-blue accent, amber CTA. */

:root {
  --bg: #0b1220;
  --bg-2: #0f1a2e;
  --bg-3: #142238;
  --line: rgba(148, 178, 214, 0.14);
  --line-strong: rgba(148, 178, 214, 0.28);
  --text: #eef3fa;
  --muted: #9fb0c8;
  --dim: #6f82a0;
  --accent: #38bdf8;
  --accent-deep: #0ea5e9;
  --accent-soft: rgba(56, 189, 248, 0.14);
  --cta: #f59e0b;
  --cta-hover: #fbbf24;
  --ok: #34d399;
  --bad: #fb7185;
  --font-display: "Bricolage Grotesque", "Segoe UI", "Helvetica Neue", Arial, sans-serif;
  --font-body: "Source Sans 3", "Segoe UI", "Helvetica Neue", Arial, sans-serif;
  --font-mono: "JetBrains Mono", "Cascadia Code", Consolas, "Courier New", monospace;
  --radius: 14px;
  --radius-lg: 22px;
  --shadow: 0 30px 80px -20px rgba(0, 0, 0, 0.7), 0 0 0 1px rgba(148, 178, 214, 0.12);
  --max: 1180px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 18px;
  line-height: 1.6;
  overflow-x: hidden;
}
body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background:
    radial-gradient(900px 500px at 15% -10%, rgba(56, 189, 248, 0.16), transparent 60%),
    radial-gradient(700px 500px at 100% 10%, rgba(14, 165, 233, 0.09), transparent 60%);
}
body > * { position: relative; z-index: 1; }

img, svg { max-width: 100%; height: auto; display: block; }
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -0.02em;
  margin: 0 0 0.5em;
}
h1 { font-size: clamp(2.4rem, 6vw, 4.4rem); }
h2 { font-size: clamp(1.9rem, 4vw, 2.9rem); }
h3 { font-size: 1.3rem; letter-spacing: -0.01em; }
p { margin: 0 0 1em; }
.lead { font-size: 1.25rem; color: var(--muted); max-width: 46ch; }
.muted { color: var(--muted); }
.mono { font-family: var(--font-mono); font-size: 0.9em; }
code {
  font-family: var(--font-mono);
  font-size: 0.85em;
  background: var(--bg-3);
  border: 1px solid var(--line);
  padding: 0.1em 0.4em;
  border-radius: 6px;
}
.skip {
  position: absolute; left: -999px; top: 8px;
  background: var(--cta); color: #000; padding: 8px 14px; border-radius: 8px; z-index: 100;
}
.skip:focus { left: 8px; }

.container { width: min(var(--max), calc(100% - 2.5rem)); margin: 0 auto; }
.section { padding: clamp(4rem, 9vw, 7.5rem) 0; }
[id] { scroll-margin-top: 84px; }
.section.tight { padding: clamp(2.5rem, 6vw, 4.5rem) 0; }
.section.alt { background: linear-gradient(180deg, transparent, rgba(15, 26, 46, 0.7) 20%, rgba(15, 26, 46, 0.7) 80%, transparent); }
.section-head { max-width: 62ch; margin-bottom: clamp(2rem, 5vw, 3.5rem); }
.section-head.center { margin-left: auto; margin-right: auto; text-align: center; }
.section-head .lead { margin-left: auto; margin-right: auto; }
.eyebrow {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 1rem;
}
.eyebrow::before { content: "// "; opacity: 0.6; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 0.5rem;
  padding: 0.85rem 1.5rem;
  border-radius: 999px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1rem;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.15s ease, background 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease;
  white-space: nowrap;
}
.btn:hover { text-decoration: none; transform: translateY(-1px); }
.btn-primary { background: var(--cta); color: #1a1200; box-shadow: 0 10px 30px -10px rgba(245, 158, 11, 0.6); }
.btn-primary:hover { background: var(--cta-hover); }
.btn-ghost { color: var(--text); border-color: var(--line-strong); background: rgba(255, 255, 255, 0.02); }
.btn-ghost:hover { border-color: var(--accent); background: var(--accent-soft); }
.btn-accent { background: var(--accent); color: #04121c; }
.btn-accent:hover { background: #5cc9fa; }
.btn-lg { padding: 1.05rem 1.9rem; font-size: 1.1rem; }
.btn-sm { padding: 0.55rem 1rem; font-size: 0.9rem; }
.cta-row { display: flex; flex-wrap: wrap; gap: 0.9rem; align-items: center; }

/* ---------- Navigation ---------- */
.nav {
  position: sticky; top: 0; z-index: 50;
  background: rgba(11, 18, 32, 0.78);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
}
.nav-inner { display: flex; align-items: center; gap: 1.5rem; height: 72px; }
.brand { display: inline-flex; align-items: center; gap: 0.6rem; color: var(--text); font-family: var(--font-display); font-weight: 800; font-size: 1.15rem; letter-spacing: -0.01em; }
.brand:hover { text-decoration: none; }
.brand svg { width: 34px; height: 34px; }
.brand b { color: var(--accent); font-weight: 800; }
.nav-links { display: flex; align-items: center; gap: 0.2rem; margin-left: auto; list-style: none; padding: 0; margin-top: 0; margin-bottom: 0; }
.nav-links a { color: var(--muted); padding: 0.5rem 0.85rem; border-radius: 8px; font-weight: 600; font-size: 0.98rem; white-space: nowrap; }
.nav-links a:hover, .nav-links a[aria-current="page"] { color: var(--text); background: rgba(255, 255, 255, 0.05); text-decoration: none; }
.nav-links .btn { margin-left: 0.5rem; color: #1a1200; }
.nav-toggle {
  display: none; margin-left: auto;
  width: 44px; height: 44px; border-radius: 10px;
  border: 1px solid var(--line-strong); background: transparent; color: var(--text); cursor: pointer;
}
.nav-toggle span { display: block; width: 20px; height: 2px; background: currentColor; margin: 4px auto; transition: transform 0.2s, opacity 0.2s; }
.nav-open .nav-toggle span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.nav-open .nav-toggle span:nth-child(2) { opacity: 0; }
.nav-open .nav-toggle span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }
/* The bar carries eight links plus a basket, so the hamburger takes over
   earlier than the usual tablet breakpoint. */
@media (max-width: 1040px) {
  .nav-toggle { display: block; }
  .nav-links {
    display: none; position: absolute; left: 0; right: 0; top: 72px;
    flex-direction: column; align-items: stretch; gap: 0.2rem;
    background: var(--bg-2); border-bottom: 1px solid var(--line);
    padding: 0.8rem 1.25rem 1.2rem;
  }
  .nav-open .nav-links { display: flex; }
  .nav-links a { padding: 0.8rem 0.9rem; font-size: 1.05rem; }
  .nav-links .btn { margin: 0.5rem 0 0; justify-content: center; }
}

/* ---------- Hero ---------- */
.hero { padding: clamp(3.5rem, 8vw, 6.5rem) 0 clamp(2rem, 5vw, 4rem); position: relative; }
.hero::after {
  content: "";
  position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background-image: linear-gradient(rgba(148, 178, 214, 0.06) 1px, transparent 1px), linear-gradient(90deg, rgba(148, 178, 214, 0.06) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: radial-gradient(ellipse 70% 60% at 50% 30%, #000 30%, transparent 75%);
  -webkit-mask-image: radial-gradient(ellipse 70% 60% at 50% 30%, #000 30%, transparent 75%);
}
.hero-grid { display: grid; gap: 3rem; align-items: center; }
.hero h1 { max-width: 14ch; }
.hero h1 em { font-style: normal; color: var(--accent); }
.hero .lead { font-size: 1.3rem; max-width: 50ch; }
.hero-badges { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-top: 1.5rem; }
.pill {
  display: inline-flex; align-items: center; gap: 0.4rem;
  padding: 0.35rem 0.8rem; border-radius: 999px;
  border: 1px solid var(--line-strong); font-size: 0.9rem; color: var(--muted);
}
.pill::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--ok); box-shadow: 0 0 10px var(--ok); }
.hero-visual { margin-top: clamp(2rem, 5vw, 4rem); }

/* ---------- Browser frame ---------- */
.frame {
  background: #0a1020;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
  position: relative;
}
.frame-bar {
  display: flex; align-items: center; gap: 0.5rem;
  padding: 0.55rem 0.9rem;
  background: linear-gradient(180deg, #172640, #111d33);
  border-bottom: 1px solid var(--line);
}
.frame-bar i { width: 11px; height: 11px; border-radius: 50%; background: #2c3d5c; display: block; }
.frame-bar i:nth-child(1) { background: #ff5f57; } .frame-bar i:nth-child(2) { background: #febc2e; } .frame-bar i:nth-child(3) { background: #28c840; }
.frame-bar span {
  margin-left: 0.6rem; flex: 1; max-width: 420px;
  font-family: var(--font-mono); font-size: 0.72rem; color: var(--dim);
  background: rgba(0, 0, 0, 0.3); border-radius: 6px; padding: 0.25rem 0.7rem;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.frame a.shot { display: block; cursor: zoom-in; }
.frame img { width: 100%; height: auto; display: block; }
.frame.tall { max-height: 640px; }
/* Portrait phone screenshots: cap the width so a tall shot does not dominate a row. */
.frame.phone { max-width: 300px; margin-left: auto; margin-right: auto; }
.frame.tall .shot { max-height: 600px; overflow: hidden; }
.frame.tall .shot::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 120px;
  background: linear-gradient(transparent, #0a1020);
  pointer-events: none;
}
.frame.tall .shot { position: relative; }
.frame-glow { position: relative; }
.frame-glow::before {
  content: ""; position: absolute; inset: -12% -8% -8%; z-index: -1; filter: blur(60px);
  background: radial-gradient(closest-side, rgba(56, 189, 248, 0.22), transparent);
}
figcaption { color: var(--muted); font-size: 0.95rem; margin-top: 0.9rem; }
figure { margin: 0; }

/* ---------- Grids and cards ---------- */
.grid { display: grid; gap: 1.25rem; }
.grid-2 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 340px), 1fr)); }
.grid-3 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr)); }
.grid-4 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 230px), 1fr)); }
.card {
  background: linear-gradient(160deg, rgba(20, 34, 56, 0.9), rgba(15, 26, 46, 0.6));
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.6rem;
  transition: border-color 0.2s, transform 0.2s;
}
.card:hover { border-color: var(--line-strong); transform: translateY(-2px); }
.card h3 { margin-top: 0.9rem; }
.card p { color: var(--muted); margin-bottom: 0; font-size: 1rem; }
.card ul { color: var(--muted); font-size: 1rem; padding-left: 1.1rem; margin: 0.5rem 0 0; }
.card li { margin: 0.3rem 0; }
.icon {
  width: 44px; height: 44px; border-radius: 11px;
  background: var(--accent-soft); color: var(--accent);
  display: grid; place-items: center;
  border: 1px solid rgba(56, 189, 248, 0.25);
}
.icon svg { width: 22px; height: 22px; }
.card.big { padding: 2.2rem; }
.card.accent { border-color: rgba(56, 189, 248, 0.4); background: linear-gradient(160deg, rgba(56, 189, 248, 0.12), rgba(15, 26, 46, 0.6)); }
.card.warm { border-color: rgba(245, 158, 11, 0.4); background: linear-gradient(160deg, rgba(245, 158, 11, 0.1), rgba(15, 26, 46, 0.6)); }

/* ---------- Two-column feature spotlight ---------- */
.split { display: grid; gap: 3rem; align-items: center; }
@media (min-width: 900px) {
  .split { grid-template-columns: 1fr 1.15fr; }
  .split.flip > :first-child { order: 2; }
}
.split .lead { font-size: 1.15rem; }
.checks { list-style: none; padding: 0; margin: 1.2rem 0 0; }
.checks li { position: relative; padding-left: 1.9rem; margin: 0.6rem 0; color: var(--muted); }
.checks li::before {
  content: ""; position: absolute; left: 0; top: 0.45em; width: 18px; height: 18px; border-radius: 50%;
  background: var(--accent-soft); border: 1px solid rgba(56, 189, 248, 0.5);
}
.checks li::after {
  content: ""; position: absolute; left: 6px; top: calc(0.45em + 4px); width: 5px; height: 8px;
  border: solid var(--accent); border-width: 0 2px 2px 0; transform: rotate(45deg);
}
.checks strong { color: var(--text); }

/* ---------- Drop-in diagram ---------- */
.dropin { display: grid; gap: 2rem; align-items: center; }
@media (min-width: 960px) { .dropin { grid-template-columns: 1fr 1fr; gap: 3.5rem; } }
.diagram {
  background: radial-gradient(ellipse at 50% 0%, rgba(56, 189, 248, 0.08), transparent 70%), var(--bg-2);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 1.25rem;
}
.diagram svg { width: 100%; height: auto; font-family: var(--font-mono); }
.brands { display: flex; flex-wrap: wrap; gap: 0.5rem; margin: 1.2rem 0 0; }
.brands span {
  font-family: var(--font-mono); font-size: 0.82rem; color: var(--muted);
  border: 1px dashed var(--line-strong); border-radius: 8px; padding: 0.3rem 0.7rem;
}
.brands span.you { border-style: solid; border-color: var(--accent); color: var(--accent); }

/* ---------- Stats strip ---------- */
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 200px), 1fr)); gap: 1rem; margin-top: 3rem; }
.stat { border-top: 2px solid var(--accent); padding-top: 0.9rem; }
.stat b { font-family: var(--font-display); font-size: 1.9rem; display: block; letter-spacing: -0.02em; }
.stat span { color: var(--muted); font-size: 0.95rem; }

/* ---------- Steps ---------- */
.steps { display: grid; gap: 1.25rem; counter-reset: step; }
@media (min-width: 800px) { .steps { grid-template-columns: repeat(4, 1fr); } }
.step { position: relative; padding: 1.6rem 1.4rem 1.4rem; border: 1px solid var(--line); border-radius: var(--radius); background: rgba(15, 26, 46, 0.6); }
.step::before {
  counter-increment: step; content: "0" counter(step);
  font-family: var(--font-mono); font-size: 0.8rem; letter-spacing: 0.15em; color: var(--accent);
  display: block; margin-bottom: 0.9rem;
}
.step h3 { font-size: 1.15rem; }
.step p { color: var(--muted); font-size: 1rem; margin: 0; }

/* ---------- Pricing ---------- */
.price-grid { display: grid; gap: 1.25rem; }
@media (min-width: 800px) { .price-grid { grid-template-columns: 1fr 1fr; } }
.price { padding: 2rem; }
.price .amount { font-family: var(--font-display); font-size: 2.4rem; letter-spacing: -0.03em; margin: 0.6rem 0 0.2rem; }
.price .amount small { font-size: 1rem; color: var(--muted); font-family: var(--font-body); letter-spacing: 0; }
.price .per { color: var(--muted); font-size: 0.95rem; }
.price .checks { margin-top: 1.4rem; margin-bottom: 1.6rem; }

/* ---------- FAQ ---------- */
.faq { max-width: 820px; margin: 0 auto; }
.faq details { border-bottom: 1px solid var(--line); padding: 0.4rem 0; }
.faq summary {
  cursor: pointer; list-style: none; padding: 0.9rem 2.2rem 0.9rem 0; position: relative;
  font-family: var(--font-display); font-weight: 700; font-size: 1.12rem;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+"; position: absolute; right: 0.2rem; top: 0.75rem;
  font-family: var(--font-mono); color: var(--accent); font-size: 1.4rem; transition: transform 0.2s;
}
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p { color: var(--muted); margin: 0 0 1rem; max-width: 70ch; }

/* ---------- Forms ---------- */
.form { display: grid; gap: 1rem; }
.form-row { display: grid; gap: 1rem; }
@media (min-width: 640px) { .form-row { grid-template-columns: 1fr 1fr; } }
label { display: block; font-weight: 600; font-size: 0.95rem; margin-bottom: 0.35rem; }
label small { color: var(--dim); font-weight: 400; }
input, select, textarea {
  width: 100%; font: inherit; color: var(--text);
  background: rgba(11, 18, 32, 0.8); border: 1px solid var(--line-strong); border-radius: 10px;
  padding: 0.75rem 0.9rem; transition: border-color 0.15s, box-shadow 0.15s;
}
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
select { appearance: none; -webkit-appearance: none; background-image: linear-gradient(45deg, transparent 50%, var(--muted) 50%), linear-gradient(135deg, var(--muted) 50%, transparent 50%); background-position: calc(100% - 20px) 50%, calc(100% - 15px) 50%; background-size: 5px 5px; background-repeat: no-repeat; padding-right: 2.4rem; }
textarea { min-height: 150px; resize: vertical; }
.hp { position: absolute; left: -9999px; top: -9999px; height: 0; width: 0; overflow: hidden; }
.form-note { color: var(--dim); font-size: 0.9rem; }
.flash { padding: 1rem 1.2rem; border-radius: 10px; margin-bottom: 1.2rem; border: 1px solid; display: none; }
.flash.ok { display: block; border-color: rgba(52, 211, 153, 0.5); background: rgba(52, 211, 153, 0.1); color: #bff2dc; }
.flash.err { display: block; border-color: rgba(251, 113, 133, 0.5); background: rgba(251, 113, 133, 0.1); color: #ffd0d8; }
.contact-side p { color: var(--muted); }
.contact-side strong { color: var(--text); }

/* ---------- Tables ---------- */
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); }
table { border-collapse: collapse; width: 100%; font-size: 0.98rem; }
th, td { text-align: left; padding: 0.8rem 1rem; border-bottom: 1px solid var(--line); vertical-align: top; }
th { font-family: var(--font-mono); font-size: 0.75rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--accent); background: rgba(56, 189, 248, 0.05); }
tr:last-child td { border-bottom: 0; }
td code { white-space: nowrap; }

/* ---------- Callouts ---------- */
.callout {
  border-left: 3px solid var(--cta); background: rgba(245, 158, 11, 0.07);
  padding: 1.1rem 1.4rem; border-radius: 0 12px 12px 0; color: var(--muted);
}
.callout.info { border-left-color: var(--accent); background: var(--accent-soft); }
.callout strong { color: var(--text); }
.callout p:last-child { margin-bottom: 0; }

/* ---------- CTA band ---------- */
.band {
  border: 1px solid rgba(56, 189, 248, 0.35);
  border-radius: var(--radius-lg);
  padding: clamp(2rem, 5vw, 3.5rem);
  background: radial-gradient(ellipse at 20% 0%, rgba(56, 189, 248, 0.2), transparent 55%), radial-gradient(ellipse at 100% 100%, rgba(245, 158, 11, 0.12), transparent 50%), var(--bg-2);
  display: grid; gap: 1.5rem; align-items: center;
}
@media (min-width: 900px) { .band { grid-template-columns: 1.4fr 1fr; } }
.band h2 { margin-bottom: 0.4rem; }
.band p { color: var(--muted); margin: 0; }
.band .cta-row { justify-content: flex-start; }
@media (min-width: 900px) { .band .cta-row { justify-content: flex-end; } }

/* ---------- Page header ---------- */
.page-head { padding: clamp(3rem, 7vw, 5.5rem) 0 clamp(1rem, 3vw, 2rem); }
.page-head h1 { max-width: 18ch; }

/* ---------- Prose ---------- */
.prose { max-width: 760px; }
.prose h2 { font-size: 1.6rem; margin-top: 2.2rem; }
.prose h3 { margin-top: 1.6rem; }
.prose p, .prose li { color: var(--muted); }
.prose strong { color: var(--text); }

/* ---------- Footer ---------- */
.footer { border-top: 1px solid var(--line); padding: 3rem 0 2rem; color: var(--muted); font-size: 0.95rem; }
.footer-grid { display: grid; gap: 2rem; }
@media (min-width: 800px) { .footer-grid { grid-template-columns: 1.6fr 1fr 1fr 1fr; } }
.footer h4 { font-size: 0.8rem; letter-spacing: 0.15em; text-transform: uppercase; font-family: var(--font-mono); color: var(--accent); margin-bottom: 0.8rem; font-weight: 600; }
.footer ul { list-style: none; padding: 0; margin: 0; }
.footer li { margin: 0.4rem 0; }
.footer a { color: var(--muted); }
.footer a:hover { color: var(--text); }
.footer-bottom { margin-top: 2.5rem; padding-top: 1.2rem; border-top: 1px solid var(--line); display: flex; flex-wrap: wrap; gap: 1rem; justify-content: space-between; font-size: 0.88rem; color: var(--dim); }

/* ---------- Lightbox ---------- */
.lightbox {
  position: fixed; inset: 0; z-index: 100; background: rgba(4, 8, 16, 0.92);
  display: none; align-items: center; justify-content: center; padding: 2rem; cursor: zoom-out;
}
.lightbox.open { display: flex; }
.lightbox img { max-width: 100%; max-height: 100%; border-radius: 10px; box-shadow: var(--shadow); }
.lightbox button {
  position: absolute; top: 1rem; right: 1rem; width: 44px; height: 44px; border-radius: 50%;
  background: rgba(255, 255, 255, 0.1); border: 1px solid var(--line-strong); color: #fff; font-size: 1.4rem; cursor: pointer;
}

/* ---------- Reveal on scroll ---------- */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity 0.6s ease, transform 0.6s ease; }
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { .reveal { opacity: 1; transform: none; transition: none; } }
.no-js .reveal { opacity: 1; transform: none; }

/* ---------- Hero screenshot entrance ---------- */
@keyframes rise { from { opacity: 0; transform: translateY(30px) scale(0.98); } to { opacity: 1; transform: none; } }
.hero-visual { animation: rise 0.9s cubic-bezier(0.2, 0.8, 0.2, 1) 0.15s both; }
@media (prefers-reduced-motion: reduce) { .hero-visual { animation: none; } }

/* ---------- Utilities ---------- */
.mt-1 { margin-top: 1rem; } .mt-2 { margin-top: 2rem; } .mt-3 { margin-top: 3rem; }
.center { text-align: center; }
.small { font-size: 0.9rem; }
.hidden { display: none !important; }

/* =====================================================================
   Hardware: labelled board figure
   The overlay SVG uses the picture's own pixel grid (viewBox 0 0 1400 1060)
   so a callout dot can be placed at an exact spot on the board render.
   Below 700px the leaders and margin labels are hidden, the dots grow and
   the numbered legend under the picture takes over.
   ===================================================================== */
.board-figure { position: relative; max-width: 1040px; margin: 0 auto; }
.board-figure > .board-img {
  display: block; width: 100%; height: auto;
  border-radius: var(--radius); border: 1px solid var(--line);
  background: #0e1526;
}
.board-overlay {
  position: absolute; left: 0; top: 0; width: 100%; height: 100%;
  overflow: visible; pointer-events: none;
}
.board-overlay .leader { fill: none; stroke: var(--accent); stroke-width: 2.2; stroke-opacity: 0.9; }
.board-overlay .eth-outline { fill: none; stroke: var(--accent); stroke-width: 2.4; stroke-dasharray: 10 7; stroke-opacity: 0.9; }
.board-overlay .dot circle { fill: var(--accent); stroke: #04121c; stroke-width: 2.5; }
.board-overlay .dot text {
  fill: #04121c; text-anchor: middle; dominant-baseline: central;
  font-family: var(--font-mono); font-size: 17px; font-weight: 700;
}
.board-overlay .lbl {
  fill: var(--text); font-family: var(--font-body); font-size: 19px; font-weight: 600;
  paint-order: stroke; stroke: rgba(11, 18, 32, 0.85); stroke-width: 4px; stroke-linejoin: round;
}
.board-caption { color: var(--muted); font-size: 0.95rem; margin-top: 1rem; text-align: center; }
.board-legend { display: none; list-style: none; padding: 0; margin: 1.4rem 0 0; gap: 0.45rem 1.2rem; }
.board-legend li { position: relative; padding-left: 2.3rem; color: var(--muted); font-size: 0.98rem; }
.board-legend b {
  position: absolute; left: 0; top: 0.15em;
  width: 1.7rem; height: 1.7rem; border-radius: 50%;
  background: var(--accent); color: #04121c;
  font-family: var(--font-mono); font-size: 0.8rem; font-weight: 700;
  display: grid; place-items: center;
}
.board-legend strong { color: var(--text); }
@media (max-width: 700px) {
  .board-overlay .leader, .board-overlay .lbl { display: none; }
  .board-overlay .dot { transform-box: fill-box; transform-origin: 50% 50%; transform: scale(2.6); }
  .board-legend { display: grid; }
  .board-caption { text-align: left; }
}

/* ---------- Product matrix ---------- */
.matrix th, .matrix td { white-space: nowrap; }
.matrix tbody th {
  background: transparent; color: var(--text);
  font-family: var(--font-body); font-size: 0.98rem; letter-spacing: 0;
  text-transform: none; font-weight: 600; white-space: normal; min-width: 12rem;
}
.matrix td { text-align: center; color: var(--muted); }
.matrix .yes { color: var(--ok); font-weight: 700; }
.matrix .no { color: var(--dim); }
.matrix .opt { color: var(--cta); font-weight: 700; }
.matrix tfoot td { text-align: center; white-space: normal; }
.matrix-key { color: var(--dim); font-size: 0.9rem; margin-top: 0.8rem; }
/* Row of build photographs at the head of the matrix, one per column. */
.matrix .shot-cell { padding: 0.7rem; vertical-align: middle; }
.matrix .shot-cell img {
  display: block; margin: 0 auto; width: 100%; height: auto;
  min-width: 8.5rem; max-width: 14rem;
  border: 1px solid var(--line); border-radius: 10px; background: #0e1526;
}
@media (max-width: 760px) { .matrix .shot-cell img { min-width: 7.5rem; } }
/* Three-quarter board shot under the hardware page heading. */
.board-hero { margin-top: clamp(1.6rem, 4vw, 2.6rem); }

/* =====================================================================
   Shop
   ===================================================================== */
.shop-note { margin-bottom: 2rem; }
.shop-cat { margin-top: clamp(2.5rem, 5vw, 4rem); }
.shop-cat > h2 { margin-bottom: 0.3rem; }
.shop-cat > p { color: var(--muted); max-width: 60ch; }
.shop-grid { display: grid; gap: 1.25rem; margin-top: 1.6rem; grid-template-columns: repeat(auto-fill, minmax(min(100%, 260px), 1fr)); }

.product {
  display: flex; flex-direction: column;
  background: linear-gradient(160deg, rgba(20, 34, 56, 0.9), rgba(15, 26, 46, 0.6));
  border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden; transition: border-color 0.2s, transform 0.2s;
}
.product:hover { border-color: var(--line-strong); transform: translateY(-2px); }
.product-media { background: #0e1526; border-bottom: 1px solid var(--line); aspect-ratio: 4 / 3; display: grid; place-items: center; overflow: hidden; }
.product-media img { width: 100%; height: 100%; object-fit: cover; }
.product-body { padding: 1.1rem 1.2rem 1.2rem; display: flex; flex-direction: column; flex: 1; }
.product h3 { font-size: 1.08rem; margin: 0 0 0.35rem; }
.product .short { color: var(--muted); font-size: 0.94rem; margin: 0 0 0.7rem; }
.product .desc { color: var(--muted); font-size: 0.9rem; margin: 0 0 0.9rem; }
.product .meta { display: flex; flex-wrap: wrap; gap: 0.4rem; margin-bottom: 0.9rem; }
.product .meta span {
  font-family: var(--font-mono); font-size: 0.72rem; color: var(--muted);
  border: 1px solid var(--line); border-radius: 6px; padding: 0.2rem 0.5rem;
}
.product .price-tag { margin-top: auto; }
.product .price-ex { font-family: var(--font-display); font-size: 1.5rem; letter-spacing: -0.02em; display: block; }
.product .price-inc { color: var(--dim); font-size: 0.85rem; }
.product .was { color: var(--dim); font-size: 0.85rem; text-decoration: line-through; margin-left: 0.4rem; }
.product .buy { display: flex; gap: 0.5rem; align-items: center; margin-top: 0.9rem; }
.product .buy .btn { flex: 1; justify-content: center; }
.qty { display: inline-flex; align-items: center; border: 1px solid var(--line-strong); border-radius: 999px; overflow: hidden; }
.qty button {
  width: 34px; height: 38px; border: 0; background: transparent; color: var(--text);
  font-size: 1.1rem; line-height: 1; cursor: pointer;
}
.qty button:hover { background: rgba(255, 255, 255, 0.06); }
.qty span { min-width: 1.6rem; text-align: center; font-family: var(--font-mono); font-size: 0.9rem; }
.product.bundle { border-color: rgba(245, 158, 11, 0.45); background: linear-gradient(160deg, rgba(245, 158, 11, 0.12), rgba(15, 26, 46, 0.65)); }
.bundle-parts { list-style: none; padding: 0; margin: 0 0 0.9rem; color: var(--muted); font-size: 0.9rem; }
.bundle-parts li { padding-left: 1.1rem; position: relative; margin: 0.2rem 0; }
.bundle-parts li::before { content: "+"; position: absolute; left: 0; color: var(--cta); font-family: var(--font-mono); }
.featured-kit { display: grid; gap: 0; }
@media (min-width: 860px) { .featured-kit { grid-template-columns: 1.05fr 1fr; align-items: stretch; } }
.featured-kit .product-media { aspect-ratio: auto; border-bottom: 0; border-right: 1px solid var(--line); min-height: 260px; }
@media (max-width: 859px) { .featured-kit .product-media { border-right: 0; border-bottom: 1px solid var(--line); aspect-ratio: 4 / 3; min-height: 0; } }
.featured-kit .product-body { padding: 1.8rem; }
.featured-kit h3 { font-size: 1.6rem; }
.shop-loading { color: var(--muted); font-family: var(--font-mono); font-size: 0.9rem; }

/* ---------- Basket button in the header ---------- */
.basket-btn {
  position: relative; display: inline-flex; align-items: center; gap: 0.45rem;
  height: 42px; padding: 0 0.85rem; margin-left: 0.35rem;
  border-radius: 999px; border: 1px solid var(--line-strong);
  background: rgba(255, 255, 255, 0.03); color: var(--text);
  font-family: var(--font-body); font-size: 0.95rem; font-weight: 600; cursor: pointer;
  transition: border-color 0.15s, background 0.15s;
}
.basket-btn:hover { border-color: var(--accent); background: var(--accent-soft); }
.basket-btn svg { width: 20px; height: 20px; }
.basket-count {
  min-width: 22px; height: 22px; padding: 0 6px; border-radius: 999px;
  background: var(--cta); color: #1a1200;
  font-family: var(--font-mono); font-size: 0.72rem; font-weight: 700; line-height: 22px; text-align: center;
}
.basket-btn[data-empty="1"] .basket-count { background: rgba(255, 255, 255, 0.08); color: var(--dim); }
@media (max-width: 1040px) {
  .basket-btn { margin-left: auto; }
  .nav-toggle { margin-left: 0.35rem; }
}
@media (max-width: 420px) { .basket-btn .basket-word { display: none; } }

/* ---------- Basket drawer ---------- */
.basket-backdrop {
  position: fixed; inset: 0; z-index: 90; background: rgba(4, 8, 16, 0.66);
  opacity: 0; visibility: hidden; transition: opacity 0.25s ease, visibility 0.25s;
}
body.basket-open .basket-backdrop { opacity: 1; visibility: visible; }
.basket-drawer {
  position: fixed; top: 0; right: 0; z-index: 95;
  width: min(430px, 100%); height: 100%;
  display: flex; flex-direction: column;
  background: var(--bg-2); border-left: 1px solid var(--line-strong);
  box-shadow: -30px 0 80px -30px rgba(0, 0, 0, 0.8);
  transform: translateX(102%); transition: transform 0.28s cubic-bezier(0.2, 0.8, 0.2, 1);
}
body.basket-open .basket-drawer { transform: none; }
@media (prefers-reduced-motion: reduce) { .basket-drawer { transition: none; } }
.basket-head { display: flex; align-items: center; gap: 1rem; padding: 1.1rem 1.25rem; border-bottom: 1px solid var(--line); }
.basket-head h2 { margin: 0; font-size: 1.25rem; }
.basket-close {
  margin-left: auto; width: 40px; height: 40px; border-radius: 10px;
  border: 1px solid var(--line-strong); background: transparent; color: var(--text);
  font-size: 1.3rem; line-height: 1; cursor: pointer;
}
.basket-close:hover { border-color: var(--accent); }
.basket-body { flex: 1; overflow-y: auto; padding: 1rem 1.25rem; }
.basket-empty { color: var(--muted); }
.basket-line { display: grid; grid-template-columns: 54px 1fr auto; gap: 0.8rem; align-items: center; padding: 0.85rem 0; border-bottom: 1px solid var(--line); }
.basket-line img { width: 54px; height: 44px; object-fit: cover; border-radius: 8px; background: #0e1526; }
.basket-line .n { font-size: 0.95rem; font-weight: 600; }
.basket-line .p { color: var(--muted); font-size: 0.85rem; }
.basket-line .qty { transform: scale(0.86); transform-origin: right center; }
.basket-line .rm { display: block; margin-top: 0.3rem; background: none; border: 0; color: var(--dim); font-size: 0.8rem; cursor: pointer; text-align: right; width: 100%; }
.basket-line .rm:hover { color: var(--bad); }
.basket-warn { border-left: 3px solid var(--bad); background: rgba(251, 113, 133, 0.1); color: #ffd0d8; padding: 0.8rem 1rem; border-radius: 0 10px 10px 0; font-size: 0.9rem; margin-top: 1rem; }
.basket-foot { border-top: 1px solid var(--line); padding: 1rem 1.25rem 1.25rem; background: rgba(11, 18, 32, 0.5); }
.basket-tot { display: flex; justify-content: space-between; gap: 1rem; color: var(--muted); font-size: 0.92rem; margin: 0.25rem 0; }
.basket-tot.grand { color: var(--text); font-family: var(--font-display); font-size: 1.25rem; font-weight: 700; margin-top: 0.6rem; padding-top: 0.6rem; border-top: 1px solid var(--line); }
.basket-foot .btn { width: 100%; justify-content: center; margin-top: 0.9rem; }
.basket-foot .note { color: var(--dim); font-size: 0.82rem; margin: 0.7rem 0 0; text-align: center; }

/* ---------- Order result pages ---------- */
.result { max-width: 640px; margin: 0 auto; text-align: center; }
.result .mark {
  width: 88px; height: 88px; border-radius: 50%; margin: 0 auto 1.5rem;
  display: grid; place-items: center; border: 2px solid var(--ok); color: var(--ok);
  background: rgba(52, 211, 153, 0.1);
}
.result.cancelled .mark { border-color: var(--cta); color: var(--cta); background: rgba(245, 158, 11, 0.1); }
.result .mark svg { width: 44px; height: 44px; }
.result .cta-row { justify-content: center; margin-top: 1.8rem; }

/* ---------- Matrix and shop, small-screen and detail tweaks ---------- */
.matrix thead th { text-align: center; }
.matrix thead th:first-child { width: 1%; }
@media (max-width: 760px) {
  .matrix tbody th { min-width: 9.5rem; font-size: 0.9rem; }
  .matrix th, .matrix td { padding: 0.6rem 0.7rem; font-size: 0.9rem; }
}
/* Line-drawn product SVGs want breathing room; the board photo wants to fill. */
.product-media img[src$=".svg"] { object-fit: contain; padding: 10%; }
.featured-kit .product-media img[src$=".svg"] { padding: 6%; max-height: 340px; }
/* The featured panel is as tall as its text, so a board shot is shown whole
   rather than cropped; its own backdrop matches the panel behind it. */
.featured-kit .product-media img { object-fit: contain; max-height: 380px; }
@media (min-width: 1041px) and (max-width: 1200px) {
  .nav-links a { padding: 0.5rem 0.6rem; font-size: 0.94rem; }
  .basket-btn { padding: 0 0.7rem; }
}
