/* ============================================================================
   SkillNarrative — full stylesheet.
   Ports the Next.js original's design system 1:1 (tailwind.config.ts tokens +
   app/globals.css) into plain CSS: brand navy #1B4B7A + sky #5B9BF5,
   Space Grotesk headings + Inter body, card/chip/btn primitives, per-skill
   theme variables, and every motion utility (marquee, pulse, drift, blueprint
   grid, nav underline, word reveal, tilt, count-up, reveal-on-scroll).
   ========================================================================== */

/* ── Tokens ─────────────────────────────────────────────────────────────── */
:root {
  --font-heading: "Space Grotesk", system-ui, sans-serif;
  --font-body: "Inter", system-ui, sans-serif;

  --navy: #1b4b7a;
  --navy-deep: #12395e;
  --navy-soft: #eaf1f9;
  --sky: #5b9bf5;
  --sky-soft: #eaf2fe;
  --ink: #0f1e2e;
  --muted: #5a6b7b;
  --surface: #f7faff;
  --line: #e2e9f2;
  --success: #16a34a;
  --warn: #d97706;
  --danger: #dc2626;
  --whatsapp: #25d366;

  --radius-lg: 0.625rem;
  --radius-xl: 0.875rem;
  --radius-2xl: 1.125rem;
  --radius-3xl: 1.5rem;

  --shadow-card: 0 1px 2px rgba(15, 30, 46, 0.04), 0 8px 24px rgba(15, 30, 46, 0.06);
  --shadow-card-hover: 0 2px 4px rgba(15, 30, 46, 0.06), 0 16px 40px rgba(27, 75, 122, 0.12);

  --brand-gradient: linear-gradient(135deg, #1b4b7a 0%, #5b9bf5 100%);

  /* Per-skill theme — overridden on skill pages (see includes/functions.php). */
  --skill: #1b4b7a;
  --skill-deep: #12395e;
  --skill-soft: #eaf1f9;
}

/* ── Base ───────────────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; border-color: var(--line); }
* { margin: 0; padding: 0; }

/* The hidden attribute must ALWAYS win — author display rules (flex/grid on
   modals, buttons, badges) would otherwise override the UA's display:none,
   leaving invisible full-screen overlays that swallow every click. */
[hidden] { display: none !important; }

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
  color-scheme: light;
  -webkit-tap-highlight-color: transparent;
}

body {
  background: #fff;
  font-family: var(--font-body);
  color: var(--ink);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  font-size: 1rem;
  line-height: 1.5;
  overscroll-behavior-y: none;
}
.page-body { display: flex; min-height: 100dvh; flex-direction: column; }
.main-page { flex: 1; }
.main-roadmap { flex: 1; overflow: hidden; }

h1, h2, h3, h4, h5 {
  font-family: var(--font-heading);
  letter-spacing: -0.025em;
  font-weight: 700;
}
/* Responsive section h2 (text-2xl → sm:text-3xl, same as the original). */
main h2 { font-size: 1.5rem; line-height: 2rem; }
@media (min-width: 640px) { main h2 { font-size: 1.875rem; line-height: 2.25rem; } }

a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
button { font: inherit; color: inherit; background: none; border: none; cursor: pointer; }
ul { list-style: none; }
code { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; }

:focus-visible {
  outline: 2px solid var(--sky);
  outline-offset: 2px;
  border-radius: 4px;
}
::selection { background: #1b4b7a; color: #fff; }

/* ── Layout primitives ──────────────────────────────────────────────────── */
.container-page {
  margin: 0 auto;
  width: 100%;
  max-width: 72rem;
  padding-left: max(1.25rem, env(safe-area-inset-left));
  padding-right: max(1.25rem, env(safe-area-inset-right));
}
@media (min-width: 640px) { .container-page { padding-left: max(1.5rem, env(safe-area-inset-left)); padding-right: max(1.5rem, env(safe-area-inset-right)); } }
@media (min-width: 1024px) { .container-page { padding-left: max(2rem, env(safe-area-inset-left)); padding-right: max(2rem, env(safe-area-inset-right)); } }

.section-pad { padding-top: 4rem; padding-bottom: 4rem; }
.page-pad { padding-top: 3rem; padding-bottom: 3rem; }
.page-pad-lg { padding-top: 3.5rem; padding-bottom: 3.5rem; }
@media (min-width: 640px) { .page-pad-lg { padding-top: 5rem; padding-bottom: 5rem; } }

.mt-2 { margin-top: 0.5rem; } .mt-3 { margin-top: 0.75rem; } .mt-4 { margin-top: 1rem; }
.mt-5 { margin-top: 1.25rem; } .mt-6 { margin-top: 1.5rem; } .mt-7 { margin-top: 1.75rem; }
.mt-8 { margin-top: 2rem; } .mt-16 { margin-top: 4rem; }

.band-surface { background: var(--surface); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }

.page-h1 { font-size: 1.875rem; line-height: 2.25rem; }
@media (min-width: 640px) { .page-h1 { font-size: 2.25rem; line-height: 2.5rem; } }

.section-sub { color: var(--muted); }
.section-head-center { max-width: 36rem; margin: 0 auto; text-align: center; }
.section-head-row { margin-bottom: 2rem; display: flex; align-items: flex-end; justify-content: space-between; gap: 1rem; }
.section-head-row .section-sub { margin-top: 0.375rem; font-size: 0.875rem; }

.view-all-link {
  display: none;
  align-items: center; gap: 0.375rem;
  font-size: 0.875rem; font-weight: 600; color: var(--navy);
  flex-shrink: 0;
}
.view-all-link:hover { text-decoration: underline; }
@media (min-width: 640px) { .view-all-link { display: inline-flex; } }
.faq-more .view-all-link, .dash-more .view-all-link { display: inline-flex; }

/* ── Buttons (globals.css @layer components) ────────────────────────────── */
.btn {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  border-radius: var(--radius-xl);
  padding: 0 1.25rem;
  font-size: 0.875rem;
  font-weight: 600;
  transition: all 0.2s;
  cursor: pointer;
}
.btn:disabled { cursor: not-allowed; opacity: 0.5; }

.btn-primary { background: var(--navy); color: #fff; box-shadow: var(--shadow-card); }
.btn-primary:hover { background: var(--navy-deep); box-shadow: var(--shadow-card-hover); }
.btn-primary:active { transform: scale(0.98); }

.btn-accent { background: var(--skill); color: #fff; box-shadow: var(--shadow-card); }
.btn-accent:hover { box-shadow: var(--shadow-card-hover); }
.btn-accent:active { transform: scale(0.98); }

.btn-ghost { border: 1px solid var(--line); background: #fff; color: var(--ink); }
.btn-ghost:hover { border-color: var(--sky); background: var(--sky-soft); }

.btn-whatsapp { background: var(--whatsapp); color: #fff; }
.btn-whatsapp:hover { filter: brightness(0.95); }

.btn-onnavy { background: #fff; color: var(--navy); }
.btn-onnavy:hover { background: rgba(255, 255, 255, 0.9); }

.btn-outline-white { border: 1px solid rgba(255, 255, 255, 0.3); color: #fff; }
.btn-outline-white:hover { background: rgba(255, 255, 255, 0.1); }

.btn-comingsoon { border: 1px solid var(--line); background: var(--surface); color: var(--muted); }

.btn-full { width: 100%; }
.btn-hero { height: 3rem; padding: 0 1.75rem; font-size: 1rem; }
.btn-nav { min-height: 40px; height: 40px; padding: 0 1rem; margin-left: 0.5rem; }
.btn-sm { min-height: 36px; height: 36px; padding: 0 0.75rem; }

/* CTA arrow nudges right on hover (group-hover:translate-x-1) */
.arrow-nudge { transition: transform 0.2s; }
.btn-group-arrow:hover .arrow-nudge { transform: translateX(4px); }

/* ── Cards & chips ──────────────────────────────────────────────────────── */
.card {
  border-radius: var(--radius-2xl);
  border: 1px solid var(--line);
  background: #fff;
  box-shadow: var(--shadow-card);
}

.chip {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  border-radius: 9999px;
  padding: 0.25rem 0.75rem;
  font-size: 0.75rem;
  font-weight: 500;
}
.chip svg { flex-shrink: 0; }
.chip-hero { border: 1px solid var(--line); background: #fff; color: var(--navy); box-shadow: var(--shadow-card); }
.chip-sky { background: var(--sky-soft); color: var(--navy); }
.chip-success { background: rgba(22, 163, 74, 0.1); color: var(--success); }
.chip-muted { border: 1px solid var(--line); background: var(--surface); color: var(--muted); }
.chip-platform { background: rgba(15, 30, 46, 0.05); color: rgba(15, 30, 46, 0.7); }
.chip-onbtn { background: rgba(255, 255, 255, 0.2); color: #fff; }
.chip-onskill { background: rgba(255, 255, 255, 0.15); color: #fff; }

/* Per-skill theming helpers (read the --skill* vars) */
.skill-text { color: var(--skill); }
.skill-soft-bg { background-color: var(--skill-soft); }
.skill-chip { background-color: var(--skill-soft); color: var(--skill); }
.skill-text-link { color: var(--skill); font-weight: 600; }
.skill-text-link:hover { text-decoration: underline; }
.text-navy { color: var(--navy); }
.text-muted { color: var(--muted); }
.text-success { color: var(--success); }
.text-sky { color: var(--sky); }
.text-whatsapp { color: var(--whatsapp); }
.inline-icon { display: inline; vertical-align: -2px; margin-left: 0.25rem; }

.tile-icon {
  display: grid; place-items: center; flex-shrink: 0;
  width: 2.75rem; height: 2.75rem;
  border-radius: var(--radius-xl);
}
.tile-sky { background: var(--sky-soft); color: var(--navy); }
.tile-navy { background: var(--navy); color: #fff; width: 3rem; height: 3rem; border-radius: var(--radius-2xl); }

/* ── Forms ──────────────────────────────────────────────────────────────── */
.input {
  min-height: 44px;
  width: 100%;
  border-radius: var(--radius-xl);
  border: 1px solid var(--line);
  background: #fff;
  padding: 0 1rem;
  font-size: 0.875rem;
  font-family: inherit;
  color: var(--ink);
  outline: none;
}
.input:focus { border-color: var(--sky); box-shadow: 0 0 0 2px rgba(91, 155, 245, 0.3); }
.input-admin:focus { border-color: var(--navy); box-shadow: 0 0 0 2px rgba(27, 75, 122, 0.2); }
.input-area { padding: 0.625rem 1rem; resize: vertical; min-height: 60px; }

/* ── Header / navbar ────────────────────────────────────────────────────── */
.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  border-bottom: 1px solid rgba(226, 233, 242, 0.8);
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  padding-top: env(safe-area-inset-top);
  transition: box-shadow 0.3s;
}
.site-header.scrolled { box-shadow: var(--shadow-card); }

.navbar { display: flex; height: 4rem; align-items: center; justify-content: space-between; }

.logo { display: inline-flex; align-items: center; gap: 0.625rem; }
.brand-mark { width: 2.25rem; height: 2.25rem; border-radius: 22%; object-fit: cover; }
.brand-mark-lg { width: 2.75rem; height: 2.75rem; }
.logo-word { font-family: var(--font-heading); font-size: 1.125rem; font-weight: 700; color: var(--ink); }
.logo-accent { color: var(--navy); }

.nav-desktop { display: none; align-items: center; gap: 0.25rem; }
@media (min-width: 768px) { .nav-desktop { display: flex; } }

.nav-item {
  position: relative;
  border-radius: var(--radius-lg);
  padding: 0.5rem 0.75rem;
  font-size: 0.875rem;
  font-weight: 500;
  transition: color 0.2s;
}
.nav-item-active { background: var(--sky-soft); color: var(--navy); }
.nav-link { color: var(--muted); }
.nav-link:hover { color: var(--ink); }
/* Navbar links: underline slides in from the left on hover. */
.nav-link::after {
  content: "";
  position: absolute;
  left: 12px; right: 12px; bottom: 5px;
  height: 2px;
  border-radius: 2px;
  background: var(--sky);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.25s ease;
}
.nav-link:hover::after { transform: scaleX(1); }

.nav-toggle {
  display: grid;
  place-items: center;
  width: 2.75rem; height: 2.75rem;
  border-radius: var(--radius-xl);
  color: var(--ink);
}
@media (min-width: 768px) { .nav-toggle { display: none; } }

.nav-drawer { border-top: 1px solid var(--line); background: #fff; }
@media (min-width: 768px) { .nav-drawer { display: none !important; } }
.nav-drawer-inner { display: flex; flex-direction: column; gap: 0.25rem; padding-top: 0.75rem; padding-bottom: 0.75rem; }
.nav-drawer-link {
  display: flex; align-items: center; gap: 0.5rem;
  border-radius: var(--radius-lg);
  padding: 0.75rem;
  font-size: 1rem; font-weight: 500; color: var(--ink);
}
.nav-drawer-link:hover { background: var(--surface); }
.nav-drawer-link svg { flex-shrink: 0; }
.nav-drawer-auth, .nav-drawer-install { margin-top: 0.25rem; }

/* ── Hero ───────────────────────────────────────────────────────────────── */
.hero { position: relative; overflow: hidden; border-bottom: 1px solid var(--line); background: var(--surface); }

/* Fine blueprint grid texture, masked toward the edges. */
.hero-grid-backdrop {
  position: absolute; inset: 0; pointer-events: none;
  background-image:
    linear-gradient(to right, rgba(27, 75, 122, 0.06) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(27, 75, 122, 0.06) 1px, transparent 1px);
  background-size: 44px 44px;
  -webkit-mask-image: radial-gradient(ellipse 90% 70% at 50% 38%, black 25%, transparent 78%);
  mask-image: radial-gradient(ellipse 90% 70% at 50% 38%, black 25%, transparent 78%);
}
/* Two static brand washes — layered depth, zero per-frame paint cost. */
.hero-wash {
  position: absolute; inset: 0; pointer-events: none;
  background:
    radial-gradient(ellipse 45% 55% at 82% 18%, rgba(91, 155, 245, 0.12), transparent 70%),
    radial-gradient(ellipse 40% 45% at 8% 90%, rgba(27, 75, 122, 0.07), transparent 70%);
}

.hero-inner {
  position: relative;
  display: grid;
  align-items: center;
  gap: 2.5rem;
  padding-top: 4rem; padding-bottom: 4rem;
}
@media (min-width: 640px) { .hero-inner { padding-top: 5rem; padding-bottom: 5rem; } }
@media (min-width: 1024px) {
  .hero-inner { grid-template-columns: 1fr 1fr; gap: 2.5rem; padding-top: 6rem; padding-bottom: 6rem; }
}

.hero-copy { position: relative; z-index: 10; text-align: center; }
@media (min-width: 1024px) { .hero-copy { text-align: left; } }

.hero-headline {
  margin-top: 1.25rem;
  font-size: 2.25rem;
  line-height: 1.14;
  font-weight: 700;
  text-wrap: balance;
}
@media (min-width: 640px) { .hero-headline { font-size: 3rem; } }
@media (min-width: 1024px) { .hero-headline { font-size: 3.75rem; } }
/* The two Words groups flow INLINE as one wrapping paragraph (exactly like
   the original's inline word spans) — never as two forced block lines.
   Before JS splits the words the spans are plain inline (a real box, so the
   gradient background-clip paints); after the split they become `contents`
   and each word's inner span carries the gradient — same as the original,
   where every gradient word has its own bg-clip span. */
.hero-headline:not(.words-ready) .headline-line { display: inline; }
.words-ready .headline-line { display: contents; }
.hero-headline:not(.words-ready) .headline-gradient,
.headline-gradient .word-inner {
  background: var(--brand-gradient);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
/* Word-by-word clip reveal: each word sits in an overflow-hidden clip and
   slides up into view (transform-only — text stays visible without JS). */
.word-clip {
  display: inline-block;
  overflow: hidden;
  vertical-align: bottom;
  padding-bottom: 0.12em;
  margin-bottom: -0.12em;
}
.word-inner { display: inline-block; will-change: transform; }
.words-ready .word-inner { transform: translateY(110%); }
.words-ready .word-inner.word-shown { transform: translateY(0); transition: transform 0.55s cubic-bezier(0.22, 1, 0.36, 1); }

.hero-sub {
  margin: 1.25rem auto 0;
  max-width: 36rem;
  color: var(--muted);
  font-size: 1rem;
  text-wrap: pretty;
}
@media (min-width: 640px) { .hero-sub { font-size: 1.125rem; } }
@media (min-width: 1024px) { .hero-sub { margin-left: 0; margin-right: 0; } }

.hero-ctas { margin-top: 2rem; display: flex; flex-direction: column; justify-content: center; gap: 0.75rem; }
@media (min-width: 640px) { .hero-ctas { flex-direction: row; } }
@media (min-width: 1024px) { .hero-ctas { justify-content: flex-start; } }

.hero-note { margin-top: 1.25rem; font-size: 0.75rem; color: var(--muted); }

.hero-laptop-mobile { margin-top: 3rem; padding: 0 0.5rem; }
@media (min-width: 1024px) { .hero-laptop-mobile { display: none; } }
.hero-laptop-desktop { position: relative; z-index: 10; display: none; }
@media (min-width: 1024px) { .hero-laptop-desktop { display: block; } }

/* fadeUp reveal (mirrors lib/motion fadeUp — transform-only, always visible) */
.reveal-item { transform: translateY(18px); }
.reveal-item.revealed, html.no-js .reveal-item { transform: translateY(0); transition: transform 0.45s cubic-bezier(0.22, 1, 0.36, 1); }
.reveal-stagger .reveal-child { transform: translateY(18px); }
.reveal-stagger.revealed .reveal-child { transform: translateY(0); transition: transform 0.45s cubic-bezier(0.22, 1, 0.36, 1); }
.reveal-stagger.revealed .reveal-child:nth-child(1) { transition-delay: 0.05s; }
.reveal-stagger.revealed .reveal-child:nth-child(2) { transition-delay: 0.11s; }
.reveal-stagger.revealed .reveal-child:nth-child(3) { transition-delay: 0.17s; }
.reveal-stagger.revealed .reveal-child:nth-child(4) { transition-delay: 0.23s; }
.reveal-stagger.revealed .reveal-child:nth-child(5) { transition-delay: 0.29s; }
.reveal-stagger.revealed .reveal-child:nth-child(6) { transition-delay: 0.35s; }
.reveal-stagger.revealed .reveal-child:nth-child(7) { transition-delay: 0.41s; }
.reveal-stagger.revealed .reveal-child:nth-child(8) { transition-delay: 0.47s; }
.reveal-stagger.revealed .reveal-child:nth-child(9) { transition-delay: 0.53s; }
.reveal-stagger.revealed .reveal-child:nth-child(10) { transition-delay: 0.59s; }
.reveal-stagger.revealed .reveal-child:nth-child(11) { transition-delay: 0.65s; }
.reveal-stagger.revealed .reveal-child:nth-child(12) { transition-delay: 0.71s; }
.reveal-stagger.revealed .reveal-child:nth-child(n+13) { transition-delay: 0.77s; }

/* ── 3D laptop (Laptop3D.tsx) ───────────────────────────────────────────── */
.laptop-wrap { position: relative; width: 100%; perspective: 1400px; }
.laptop-mobile-size { max-width: 440px; margin: 0 auto; }
.laptop-desktop-size { max-width: 600px; margin: 0 auto; }
.laptop-tilt { position: relative; transform-style: preserve-3d; transition: transform 0.15s ease-out; will-change: transform; }
.laptop-svg { width: 100%; display: block; }

/* Screen content aligned to the inner screen rect (117,19 406×270 of 640×412) */
.laptop-screen {
  position: absolute;
  left: 18.28125%;      /* 117/640 */
  top: 4.6116505%;      /* 19/412  */
  width: 63.4375%;      /* 406/640 */
  height: 65.53398%;    /* 270/412 */
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border-radius: 7px;
  background: #0b1220;
}
.editor-bar {
  display: flex; align-items: center; gap: 0.375rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  padding: 0.375rem 0.75rem;
}
.dot { width: 0.5rem; height: 0.5rem; border-radius: 9999px; }
.dot-red { background: #ff5f57; } .dot-yellow { background: #febc2e; } .dot-green { background: #28c840; }
.editor-file { margin-left: 0.5rem; font-size: 10px; font-weight: 500; color: rgba(255, 255, 255, 0.45); }
.editor-badge {
  margin-left: auto;
  display: grid; place-items: center;
  width: 1rem; height: 1rem;
  border-radius: 0.25rem;
  background: rgba(255, 255, 255, 0.1);
  font-size: 8px; font-weight: 700; color: rgba(255, 255, 255, 0.7);
}
.editor-body { flex: 1; padding: 0.5rem 0.75rem; overflow: hidden; }
.editor-code { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 11px; line-height: 1.55; }
@media (min-width: 640px) { .editor-code { font-size: 12.5px; } }
.code-line { display: flex; }
.code-ln {
  margin-right: 0.75rem;
  width: 0.75rem;
  flex-shrink: 0;
  user-select: none;
  text-align: right;
  color: rgba(255, 255, 255, 0.2);
}
.code-text { white-space: pre; }
.code-cursor {
  display: inline-block;
  width: 6px; height: 13px;
  margin-left: 1px;
  transform: translateY(2px);
  background: #5b9bf5;
  animation: sn-blink 1s step-start infinite;
}
@keyframes sn-blink { 50% { opacity: 0; } }
/* token colours (match the original's tailwind arbitrary values) */
.tok-kw { color: #c792ea; } .tok-fn { color: #82aaff; } .tok-str { color: #c3e88d; }
.tok-obj { color: #ffcb6b; } .tok-pun { color: rgba(255, 255, 255, 0.7); } .tok-var { color: rgba(255, 255, 255, 0.9); }

.editor-status {
  display: flex; align-items: center; gap: 0.375rem;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  background: #0e1626;
  padding: 0.25rem 0.75rem;
}
.status-text { font-size: 9px; font-weight: 500; color: rgba(255, 255, 255, 0.5); }
.status-lang { margin-left: auto; font-size: 9px; font-weight: 500; color: rgba(255, 255, 255, 0.35); }
.editor-sheen {
  position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(115deg, rgba(255, 255, 255, 0.07) 0%, rgba(255, 255, 255, 0.02) 28%, transparent 45%);
}

.laptop-chip {
  position: absolute;
  display: flex; align-items: center; gap: 0.375rem;
  border-radius: var(--radius-xl);
  border: 1px solid var(--line);
  background: #fff;
  padding: 0.375rem 0.625rem;
  box-shadow: var(--shadow-card);
  font-size: 10px; font-weight: 600; color: var(--ink);
}
@media (min-width: 640px) { .laptop-chip { font-size: 0.75rem; } }
.laptop-chip-left { left: -0.25rem; top: 16%; }
.laptop-chip-right { right: -0.25rem; top: 52%; }
@media (min-width: 640px) { .laptop-chip-left { left: -1rem; } .laptop-chip-right { right: -1rem; } }

/* ── Tech marquee ───────────────────────────────────────────────────────── */
.marquee {
  overflow: hidden;
  border-bottom: 1px solid var(--line);
  background: #fff;
  padding: 1rem 0;
  -webkit-mask-image: linear-gradient(90deg, transparent, black 10%, black 90%, transparent);
  mask-image: linear-gradient(90deg, transparent, black 10%, black 90%, transparent);
}
.marquee-track { display: flex; width: max-content; }
@keyframes sn-marquee { to { transform: translateX(-50%); } }
.sn-marquee { animation: sn-marquee 38s linear infinite; }
.sn-marquee:hover { animation-play-state: paused; }
.marquee-row { display: flex; flex: none; align-items: center; gap: 2rem; padding-right: 2rem; }
.marquee-row li {
  display: flex; align-items: center; gap: 2rem;
  white-space: nowrap;
  font-size: 0.875rem; font-weight: 600; letter-spacing: 0.025em; color: var(--muted);
}
.marquee-dot { width: 0.25rem; height: 0.25rem; border-radius: 9999px; background: var(--line); }

/* ── Stats band ─────────────────────────────────────────────────────────── */
.stats-band { border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); background: var(--surface); }
.stats-grid {
  display: grid; grid-template-columns: repeat(2, 1fr); gap: 1.5rem;
  padding-top: 2.5rem; padding-bottom: 2.5rem;
}
@media (min-width: 640px) { .stats-grid { grid-template-columns: repeat(4, 1fr); } }
.stat { text-align: center; }
.stat-value { font-family: var(--font-heading); font-size: 1.875rem; font-weight: 700; color: var(--navy); font-variant-numeric: tabular-nums; }
@media (min-width: 640px) { .stat-value { font-size: 2.25rem; } }
.stat-label { margin-top: 0.25rem; font-size: 0.875rem; color: var(--muted); }

/* ── Skill browser (toggle + grid) ──────────────────────────────────────── */
.platform-row {
  margin-bottom: 1.5rem;
  display: flex; flex-direction: column; align-items: center; gap: 0.5rem;
}
@media (min-width: 640px) { .platform-row { flex-direction: row; justify-content: flex-start; } }
.platform-label { font-size: 0.875rem; font-weight: 500; color: var(--muted); }

.platform-toggle {
  position: relative;
  display: inline-flex;
  border-radius: 9999px;
  border: 1px solid var(--line);
  background: #fff;
  padding: 0.25rem;
  box-shadow: var(--shadow-card);
}
.platform-toggle button {
  position: relative;
  z-index: 1;
  display: inline-flex; align-items: center; gap: 0.5rem;
  border-radius: 9999px;
  padding: 0.5rem 1rem;
  font-size: 0.875rem; font-weight: 600;
  color: var(--muted);
  transition: color 0.2s;
}
.platform-toggle button:hover { color: var(--ink); }
.platform-toggle button.platform-active { color: #fff; }
.platform-toggle button svg { width: 16px; height: 16px; flex-shrink: 0; }
.platform-count {
  border-radius: 9999px;
  padding: 0 0.375rem;
  font-size: 0.75rem;
  font-variant-numeric: tabular-nums;
  background: var(--surface); color: var(--muted);
}
/* Narrow phones: tighten the toggle so all three tabs fit a 360–400px
   viewport without clipping (icon sizes are already constrained to 16px). */
@media (max-width: 430px) {
  .platform-toggle button { padding: 0.5rem 0.55rem; gap: 0.3rem; font-size: 0.8125rem; }
  .platform-count { padding: 0 0.25rem; }
}
.platform-active .platform-count { background: rgba(255, 255, 255, 0.2); color: #fff; }
/* Sliding pill — positioned by JS, springs between buttons. */
.platform-pill {
  position: absolute;
  top: 0.25rem; bottom: 0.25rem; left: 0;
  border-radius: 9999px;
  background: var(--navy);
  box-shadow: var(--shadow-card);
  transition: transform 0.35s cubic-bezier(0.34, 1.3, 0.64, 1), width 0.35s cubic-bezier(0.34, 1.3, 0.64, 1);
  will-change: transform, width;
}

.skill-grid { display: grid; grid-template-columns: 1fr; gap: 1.25rem; }
@media (min-width: 640px) { .skill-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .skill-grid { grid-template-columns: repeat(3, 1fr); } }

/* ── Skill card ─────────────────────────────────────────────────────────── */
.tilt-card { perspective: 800px; height: 100%; }
.tilt-inner-active { will-change: transform; }
.skill-card {
  position: relative;
  display: flex; flex-direction: column;
  height: 100%;
  overflow: hidden;
  padding: 1.25rem;
  transition: box-shadow 0.3s, transform 0.2s ease-out;
}
.skill-card:hover { box-shadow: var(--shadow-card-hover); }
.skill-card-accent {
  position: absolute; inset: 0 0 auto 0;
  height: 0.25rem;
  background: var(--skill);
  transition: height 0.3s;
}
.skill-card:hover .skill-card-accent { height: 0.375rem; }
.skill-card-top { position: relative; display: flex; align-items: flex-start; justify-content: space-between; }
.skill-card-icon {
  display: grid; place-items: center;
  width: 3rem; height: 3rem;
  border-radius: var(--radius-xl);
  background: var(--skill);
  color: #fff;
  transition: transform 0.3s;
}
.skill-card:hover .skill-card-icon { transform: rotate(-3deg) scale(1.05); }
.skill-card-titlerow { position: relative; margin-top: 1rem; display: flex; align-items: center; gap: 0.5rem; }
.skill-card-titlerow .chip-platform svg { width: 14px; height: 14px; }
.skill-card-title { font-size: 1.125rem; font-weight: 700; }
.skill-card-title a { display: inline-block; padding: 0.75rem 0; margin: -0.75rem 0; } /* 44px tap target, no layout shift */
.skill-card-title a:hover { text-decoration: underline; }
.skill-card-desc {
  position: relative;
  margin-top: 0.375rem;
  flex: 1;
  font-size: 0.875rem; color: var(--muted);
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.skill-card-price { position: relative; margin-top: 0.75rem; font-size: 0.75rem; font-weight: 500; color: var(--muted); }
.skill-card-actions { position: relative; margin-top: 1rem; }

.browser-empty { padding: 2.5rem; text-align: center; }
.empty-icon {
  margin: 0 auto;
  display: grid; place-items: center;
  width: 3.5rem; height: 3.5rem;
  border-radius: var(--radius-2xl);
  background: var(--sky-soft); color: var(--navy);
}
.empty-title { margin-top: 1rem; font-size: 1.25rem; font-weight: 700; }
.empty-title-lg { margin-top: 1rem; font-size: 1.5rem; font-weight: 700; }
.empty-desc { margin: 0.5rem auto 0; max-width: 24rem; color: var(--muted); }
.empty-cta { display: inline-flex; }
.browser-empty .btn, .dash-signedout .btn, .notfound .btn, .dr-empty .btn { display: inline-flex; }

/* ── About teaser / values / tiers / features ───────────────────────────── */
.about-teaser { display: grid; gap: 2.5rem; }
@media (min-width: 1024px) { .about-teaser { grid-template-columns: 1fr 1.1fr; align-items: center; gap: 4rem; } }
.about-points { display: grid; gap: 1rem; }
@media (min-width: 640px) { .about-points { grid-template-columns: repeat(2, 1fr); } }
.about-point { padding: 1.25rem; }
.about-point .tile-icon { width: 2.5rem; height: 2.5rem; }
.about-point h3 { margin-top: 0.75rem; font-size: 0.875rem; }
.about-point p { margin-top: 0.25rem; font-size: 0.75rem; color: var(--muted); }

.tiers-grid { margin-top: 2.5rem; display: grid; gap: 1.25rem; }
@media (min-width: 640px) { .tiers-grid { grid-template-columns: repeat(3, 1fr); } }
.tier-card { padding: 1.5rem; text-align: center; }
.tier-card .tile-icon { margin: 0 auto; }
.tier-card h3 { margin-top: 1rem; }
.tier-price { margin-top: 0.25rem; font-family: var(--font-heading); font-size: 1.125rem; font-weight: 700; color: var(--navy); }
.tier-desc { margin-top: 0.5rem; font-size: 0.875rem; color: var(--muted); }
.tiers-footnote { margin-top: 2rem; text-align: center; font-size: 0.875rem; color: var(--muted); }

/* How it works */
.hiw-wrap { position: relative; margin-top: 2.5rem; }
.hiw-line {
  position: absolute;
  left: 12%; right: 12%; top: 3rem;
  height: 1px;
  display: none;
  transform-origin: left;
  transform: scaleX(0);
  background: linear-gradient(to right, rgba(27, 75, 122, 0.25), rgba(91, 155, 245, 0.6), rgba(27, 75, 122, 0.25));
}
@media (min-width: 640px) { .hiw-line { display: block; } }
.hiw-line.drawn { transform: scaleX(1); transition: transform 0.9s cubic-bezier(0.22, 1, 0.36, 1) 0.2s; }
.hiw-grid { position: relative; display: grid; gap: 1.25rem; }
@media (min-width: 640px) { .hiw-grid { grid-template-columns: repeat(3, 1fr); } }
.hiw-card {
  position: relative;
  height: 100%;
  padding: 1.5rem;
  transition: box-shadow 0.3s;
}
.hiw-card:hover { box-shadow: var(--shadow-card-hover); }
/* Big outlined step number — depth without weight */
.hiw-number {
  position: absolute; right: 1.25rem; top: 1rem;
  font-family: var(--font-heading);
  font-size: 3rem; font-weight: 700;
  color: transparent;
  -webkit-text-stroke: 1.5px var(--line);
  transition: -webkit-text-stroke-color 0.3s;
}
.hiw-card:hover .hiw-number { -webkit-text-stroke-color: var(--sky); }
.hiw-icon { transition: transform 0.3s; }
.hiw-card:hover .hiw-icon { transform: rotate(-3deg) scale(1.05); }
.hiw-card h3 { margin-top: 1rem; font-size: 1.125rem; }
.hiw-card p { margin-top: 0.375rem; font-size: 0.875rem; color: var(--muted); }

/* Feature showcase / values / perks cards */
.features-grid { margin-top: 2.5rem; display: grid; gap: 1.25rem; }
@media (min-width: 640px) { .features-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .features-grid { grid-template-columns: repeat(3, 1fr); } }
.feature-card { display: flex; gap: 1rem; height: 100%; padding: 1.25rem; }
.feature-card h3, .feature-card .feature-h { font-size: 1rem; font-weight: 700; font-family: var(--font-heading); }
.feature-card p { margin-top: 0.25rem; font-size: 0.875rem; color: var(--muted); }

/* FAQ */
.faq-preview { margin: 2rem auto 0; max-width: 42rem; }
.faq-more { margin-top: 1.5rem; text-align: center; }
.faq-page-list { margin: 2.5rem auto 0; max-width: 42rem; }
.faq-accordion {
  border-radius: var(--radius-2xl);
  border: 1px solid var(--line);
  background: #fff;
  overflow: hidden;
}
.faq-item + .faq-item { border-top: 1px solid var(--line); }
.faq-q {
  display: flex; width: 100%;
  align-items: center; justify-content: space-between; gap: 1rem;
  padding: 1rem 1.25rem;
  text-align: left;
  font-weight: 600; color: var(--ink);
}
.faq-chevron { flex-shrink: 0; color: var(--muted); transition: transform 0.2s; }
.faq-chevron-open { transform: rotate(180deg); }
.faq-a { overflow: hidden; transition: height 0.2s ease-out; }
.faq-a p { padding: 0 1.25rem 1rem; font-size: 0.875rem; color: var(--muted); }
.faq-cta {
  margin: 2.5rem auto 0; max-width: 42rem;
  border-radius: var(--radius-2xl);
  border: 1px solid var(--line);
  background: var(--surface);
  padding: 1.5rem;
  text-align: center;
}
.faq-cta-q { font-size: 0.875rem; color: var(--muted); }
.faq-cta-btn { margin-top: 0.75rem; height: 2.75rem; display: inline-flex; }

/* CTA band */
.cta-band {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius-3xl);
  background: var(--navy);
  padding: 3.5rem 1.5rem;
  text-align: center;
  color: #fff;
}
@media (min-width: 640px) { .cta-band { padding-left: 3rem; padding-right: 3rem; } }
/* Slow drifting dot field — motion you feel more than see */
.cta-dots {
  position: absolute; inset: -2rem; pointer-events: none;
  background-image: radial-gradient(circle, rgba(255, 255, 255, 0.13) 1.2px, transparent 1.2px);
  background-size: 24px 24px;
}
@keyframes sn-drift { to { transform: translate3d(-24px, -24px, 0); } }
.sn-drift { animation: sn-drift 6s linear infinite; }
.cta-title { position: relative; margin: 0 auto; max-width: 42rem; font-size: 1.875rem; }
@media (min-width: 640px) { .cta-title { font-size: 2.25rem; } }
.cta-sub { position: relative; margin: 0.75rem auto 0; max-width: 32rem; color: rgba(255, 255, 255, 0.9); }
.cta-actions { position: relative; margin-top: 2rem; display: flex; justify-content: center; }

/* ── Catalog / dashboard ────────────────────────────────────────────────── */
.catalog-head { margin-bottom: 2rem; max-width: 42rem; }
.dash-head { margin-bottom: 2rem; }
.dash-welcome { font-size: 0.875rem; font-weight: 500; color: var(--sky); }
.dash-signedout { text-align: center; padding-top: 5rem; padding-bottom: 5rem; }
.dash-grid { display: grid; gap: 1.25rem; }
@media (min-width: 640px) { .dash-grid { grid-template-columns: repeat(2, 1fr); } }
.dash-card { padding: 1.5rem; }
.dash-card-top { display: flex; align-items: flex-start; justify-content: space-between; }
.dash-card-icon { width: 3rem; height: 3rem; border-radius: var(--radius-2xl); }
.dash-card-title { margin-top: 1rem; font-size: 1.125rem; }
.dash-card-progress { margin-top: 1rem; }
.dash-more { margin-top: 2rem; }

/* Progress bar (ProgressBar.tsx) */
.progress-labels {
  margin-bottom: 0.375rem;
  display: flex; align-items: center; justify-content: space-between;
  font-size: 0.75rem; font-weight: 500; color: var(--muted);
}
.progress-num { font-variant-numeric: tabular-nums; }
.progress-track { height: 0.625rem; width: 100%; overflow: hidden; border-radius: 9999px; background: var(--line); }
.progress-fill {
  height: 100%; border-radius: 9999px;
  background: var(--skill);
  width: 0;
  transition: width 0.6s ease-out;
}

/* ── Login ──────────────────────────────────────────────────────────────── */
.login-wrap { margin: 0 auto; max-width: 28rem; }
.login-card { padding: 1.5rem; }
@media (min-width: 640px) { .login-card { padding: 2rem; } }
.login-title { font-size: 1.5rem; }
.login-sub { margin-top: 0.375rem; font-size: 0.875rem; color: var(--muted); }
.google-form { margin-top: 1.5rem; }
.login-divider {
  margin: 1.25rem 0;
  display: flex; align-items: center; gap: 0.75rem;
  font-size: 0.75rem; color: var(--muted);
}
.login-divider span { height: 1px; flex: 1; background: var(--line); }
.login-form { display: flex; flex-direction: column; gap: 0.75rem; }
.login-label { display: block; font-size: 0.875rem; font-weight: 500; color: var(--ink); }
.login-hint { text-align: center; font-size: 0.75rem; color: var(--muted); }
.login-msg { margin-top: 1rem; border-radius: var(--radius-xl); padding: 0.75rem 1rem; font-size: 0.875rem; }
.login-msg-ok { background: var(--sky-soft); color: var(--navy); }
.login-msg-error { background: rgba(220, 38, 38, 0.1); color: var(--danger); }
.login-preview-note { margin-top: 1rem; text-align: center; font-size: 0.75rem; color: var(--muted); }
.login-preview-note code { background: var(--surface); padding: 0.125rem 0.25rem; border-radius: 0.25rem; }

/* ── Skill hub ──────────────────────────────────────────────────────────── */
.hub-pad { padding-top: 2rem; padding-bottom: 2rem; }
@media (min-width: 640px) { .hub-pad { padding-top: 2.5rem; padding-bottom: 2.5rem; } }
.hub-backlink { font-size: 0.875rem; font-weight: 500; color: var(--muted); }
.hub-backlink:hover { color: var(--navy); }
.hub-header { margin-top: 1rem; overflow: hidden; }
.hub-banner { background: var(--skill); padding: 1.5rem; color: #fff; }
@media (min-width: 640px) { .hub-banner { padding: 2rem; } }
.hub-banner-row { display: flex; align-items: flex-start; gap: 1rem; }
.hub-banner-icon {
  display: grid; place-items: center; flex-shrink: 0;
  width: 3.5rem; height: 3.5rem;
  border-radius: var(--radius-2xl);
  background: rgba(255, 255, 255, 0.15);
}
.hub-title { margin-top: 0.5rem; font-size: 1.5rem; color: #fff; }
@media (min-width: 640px) { .hub-title { font-size: 1.875rem; } }
.hub-desc { margin-top: 0.25rem; max-width: 36rem; font-size: 0.875rem; color: rgba(255, 255, 255, 0.85); }
.hub-progress { padding: 1.5rem; }
@media (min-width: 640px) { .hub-progress { padding: 2rem; } }
.hub-progress-note { margin-top: 0.5rem; font-size: 0.75rem; color: var(--muted); }

.hub-grid { margin-top: 1.5rem; display: grid; grid-template-columns: 1fr; gap: 1rem; }
@media (min-width: 640px) { .hub-grid { grid-template-columns: repeat(2, 1fr); } }
.hub-btn {
  display: flex; align-items: center; gap: 1rem;
  padding: 1.25rem;
  transition: box-shadow 0.3s, transform 0.2s ease-out;
}
.hub-btn:hover { box-shadow: var(--shadow-card-hover); transform: translateY(-3px); }
.hub-btn-icon {
  display: grid; place-items: center; flex-shrink: 0;
  width: 3rem; height: 3rem;
  border-radius: var(--radius-2xl);
  transition: transform 0.3s;
}
.hub-btn:hover .hub-btn-icon { transform: rotate(-3deg) scale(1.05); }
.hub-btn-text { min-width: 0; flex: 1; }
.hub-btn-label { display: block; font-family: var(--font-heading); font-size: 1rem; font-weight: 700; color: var(--ink); }
.hub-btn-desc { display: block; font-size: 0.875rem; color: var(--muted); }
.hub-btn-arrow { flex-shrink: 0; color: var(--muted); transition: transform 0.2s; }
.hub-btn:hover .hub-btn-arrow { transform: translateX(4px); }
.hub-btn-disabled { cursor: not-allowed; opacity: 0.6; }
.hub-btn-disabled:hover { box-shadow: var(--shadow-card); transform: none; }

/* Access gate */
.gate-card { margin: 0 auto; max-width: 28rem; text-align: center; }
.gate-lock { margin: 0 auto; display: grid; place-items: center; width: 3.5rem; height: 3.5rem; border-radius: var(--radius-2xl); }
.gate-title { margin-top: 1rem; display: flex; align-items: center; justify-content: center; gap: 0.5rem; font-size: 1.5rem; }
.gate-desc { margin: 0.5rem auto 0; max-width: 24rem; color: var(--muted); }
.gate-actions { margin-top: 1.5rem; display: flex; justify-content: center; }
.gate-back { margin-top: 1.5rem; display: inline-block; font-size: 0.875rem; font-weight: 500; color: var(--muted); }
.gate-back:hover { color: var(--navy); }

/* ── Roadmap canvas ─────────────────────────────────────────────────────── */
.roadmap-root {
  position: relative;
  height: calc(100dvh - 4rem);
  min-height: 480px;
  width: 100%;
  user-select: none;
  overflow: hidden;
  background: var(--surface);
}
.roadmap-viewport {
  position: absolute; inset: 0;
  cursor: grab;
  touch-action: none;
  transition: opacity 0.2s;
  opacity: 0; /* revealed once the first layout pass picks the right layout */
}
.roadmap-viewport.rc-ready { opacity: 1; }
.roadmap-viewport.rc-panning { cursor: grabbing; }

/* dotted grid — a large fixed tile moved purely via transform (GPU) */
.rc-grid {
  position: absolute; left: 0; top: 0;
  width: 4800px; height: 4800px;
  margin-left: -2400px; margin-top: -2400px;
  pointer-events: none;
  transform-origin: 0 0;
  will-change: transform;
  background-image: radial-gradient(circle, rgba(27, 75, 122, 0.16) 1.4px, transparent 1.4px);
  background-size: 24px 24px;
}
/* soft vignette so the grid fades toward the edges (under the nodes) */
.rc-vignette {
  position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(ellipse at center, transparent 55%, rgba(247, 250, 255, 0.85) 100%);
}
.rc-world { position: absolute; left: 0; top: 0; transform-origin: 0 0; will-change: transform; }

.rc-svg { position: absolute; left: 0; top: 0; overflow: visible; pointer-events: none; transition: opacity 0.3s; }

/* centre node */
.rc-centre {
  position: absolute;
  transform: translate(-50%, -50%);
  left: 0; top: 0;
}
@keyframes sn-pulse {
  0% { transform: scale(1); opacity: 0.8; }
  70% { transform: scale(1.16); opacity: 0; }
  100% { transform: scale(1.16); opacity: 0; }
}
.rc-pulse {
  position: absolute; inset: -0.5rem;
  border-radius: 22px;
  border: 1px solid color-mix(in srgb, var(--skill) 45%, transparent);
  pointer-events: none;
  animation: sn-pulse 2.8s ease-out infinite;
}
.rc-centre-btn {
  position: relative;
  width: 224px;
  border-radius: var(--radius-2xl);
  padding: 1.25rem 1.5rem;
  text-align: center;
  color: #fff;
  background: var(--skill);
  box-shadow: var(--shadow-card-hover);
  transition: transform 0.15s;
}
.rc-centre-btn:hover { transform: translateY(-2px); }
.rc-centre-btn:active { transform: scale(0.98); }
.rc-centre-kicker { font-size: 10px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.16em; color: rgba(255, 255, 255, 0.75); }
.rc-centre-name { margin-top: 0.25rem; font-family: var(--font-heading); font-size: 1.25rem; font-weight: 700; line-height: 1.25; }
.rc-centre-progress { margin: 0.75rem auto 0; display: flex; width: fit-content; align-items: center; gap: 0.5rem; }
.rc-centre-track { position: relative; height: 0.375rem; width: 7rem; overflow: hidden; border-radius: 9999px; background: rgba(255, 255, 255, 0.25); }
.rc-centre-fill { position: absolute; inset: 0 auto 0 0; border-radius: 9999px; background: #fff; transition: width 0.5s; }
.rc-centre-pct { font-size: 11px; font-weight: 700; font-variant-numeric: tabular-nums; color: #fff; }
.rc-centre-hint { margin-top: 0.5rem; font-size: 10px; font-weight: 500; color: rgba(255, 255, 255, 0.7); }

/* module nodes */
.rc-node {
  position: absolute;
  width: 204px;
  transform: translate(-50%, -50%);
  z-index: 10;
  transition: opacity 0.25s, scale 0.25s;
}
.rc-node.rc-open { z-index: 30; }
.rc-node.rc-collapsed { opacity: 0; scale: 0.3; pointer-events: none; }
.rc-node-card {
  position: relative;
  width: 100%;
  overflow: hidden;
  text-align: left;
  cursor: grab;
  border-radius: var(--radius-2xl);
  border: 1px solid var(--line);
  background: #fff;
  box-shadow: var(--shadow-card);
  transition: box-shadow 0.2s, transform 0.15s, border-color 0.2s;
}
.rc-node-card:hover { box-shadow: var(--shadow-card-hover); transform: translateY(-2px); }
.rc-node-card:active { cursor: grabbing; transform: scale(0.98); }
.rc-node.rc-open .rc-node-card { border-color: var(--skill); }
.rc-node-accent { position: absolute; inset: 0 0 auto 0; height: 0.25rem; background: var(--skill); }
.rc-node-check {
  position: absolute; right: 0.625rem; top: 0.625rem;
  border-radius: 9999px; background: #fff; color: var(--success);
  box-shadow: 0 1px 2px rgba(15, 30, 46, 0.1);
  display: grid; place-items: center;
}
.rc-node-row { position: relative; display: flex; align-items: center; gap: 0.625rem; padding: 1rem 0.875rem 0.625rem; }
.rc-node-num {
  display: grid; place-items: center; flex-shrink: 0;
  width: 2.25rem; height: 2.25rem;
  border-radius: var(--radius-lg);
  background: var(--skill);
  font-family: var(--font-heading); font-size: 0.75rem; font-weight: 700; color: #fff;
}
.rc-node-text { min-width: 0; flex: 1; }
.rc-node-title {
  display: block;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  font-family: var(--font-heading); font-weight: 700; line-height: 1.25; color: var(--ink);
}
.rc-node-blurb { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 11px; color: var(--muted); }
.rc-node-icons { display: flex; flex-shrink: 0; align-items: center; gap: 0.25rem; }
.rc-node-move { color: rgba(90, 107, 123, 0.4); }
.rc-node-chevron { color: var(--muted); transition: transform 0.2s; }
.rc-node.rc-open .rc-node-chevron { transform: rotate(180deg); }
.rc-node-progressrow { display: flex; align-items: center; gap: 0.5rem; padding: 0 0.875rem 0.75rem; }
.rc-node-track { position: relative; height: 0.25rem; flex: 1; overflow: hidden; border-radius: 9999px; background: var(--line); }
.rc-node-fill { position: absolute; inset: 0 auto 0 0; border-radius: 9999px; background: var(--skill); transition: width 0.5s; }
.rc-node-count { font-size: 10px; font-weight: 600; font-variant-numeric: tabular-nums; color: var(--muted); }
.rc-node-count.rc-complete { color: var(--success); }

/* lesson dropdown */
.rc-lessons {
  position: absolute; left: 50%; z-index: 40;
  width: 248px;
  transform: translateX(-50%);
  overflow: hidden;
  border-radius: var(--radius-2xl);
  border: 1px solid var(--line);
  background: #fff;
  box-shadow: var(--shadow-card-hover);
  opacity: 0;
  transition: opacity 0.18s ease-out, transform 0.18s ease-out;
}
.rc-lessons.rc-below { top: 100%; margin-top: 0.5rem; transform: translateX(-50%) translateY(-8px) scale(0.96); }
.rc-lessons.rc-above { bottom: 100%; margin-bottom: 0.5rem; transform: translateX(-50%) translateY(8px) scale(0.96); }
.rc-lessons.rc-lessons-in { opacity: 1; transform: translateX(-50%) translateY(0) scale(1); }
.rc-lessons-head {
  display: flex; align-items: center; justify-content: space-between;
  border-bottom: 1px solid var(--line);
  padding: 0.5rem 0.75rem;
}
.rc-lessons-title { font-size: 11px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.05em; color: var(--muted); }
.rc-lessons-count { font-size: 11px; font-weight: 600; font-variant-numeric: tabular-nums; color: var(--muted); }
.rc-lesson {
  display: flex; align-items: center; gap: 0.5rem;
  border-bottom: 1px solid var(--line);
  padding: 0.625rem 0.75rem;
}
.rc-lesson:last-child { border-bottom: 0; }
.rc-lesson:hover { background: var(--surface); }
.rc-lesson-check {
  display: grid; place-items: center; flex-shrink: 0;
  width: 1.25rem; height: 1.25rem;
  border-radius: 9999px;
  border: 1px solid var(--line);
  color: transparent;
}
.rc-lesson-check.rc-done { border-color: var(--skill); background: var(--skill); color: #fff; }
.rc-lesson-link {
  display: flex; min-width: 0; flex: 1; align-items: center; gap: 0.5rem;
  font-size: 0.875rem; color: var(--ink);
}
.rc-lesson-link:hover { color: var(--skill); }
.rc-lesson-link svg { flex-shrink: 0; }
.rc-lesson-title { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* overlay chrome */
.rc-overlay {
  position: absolute; inset: 0;
  display: flex; flex-direction: column; justify-content: space-between;
  padding: 0.75rem;
  pointer-events: none;
}
@media (min-width: 640px) { .rc-overlay { padding: 1rem; } }
.rc-overlay-top { display: flex; align-items: center; justify-content: space-between; gap: 0.5rem; }
.rc-overlay-bottom { display: flex; align-items: center; justify-content: flex-end; gap: 0.5rem; }
.rc-chip {
  display: inline-flex; align-items: center; gap: 0.375rem;
  border-radius: var(--radius-xl);
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.9);
  padding: 0.5rem 0.75rem;
  font-size: 0.875rem; font-weight: 500; color: var(--ink);
  box-shadow: var(--shadow-card);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}
.rc-link { pointer-events: auto; }
.rc-link:hover { background: #fff; }
.rc-progress { gap: 0.5rem; }
.rc-progress-track { position: relative; height: 0.375rem; width: 5rem; overflow: hidden; border-radius: 9999px; background: var(--line); }
@media (min-width: 640px) { .rc-progress-track { width: 7rem; } }
.rc-progress-fill { position: absolute; inset: 0 auto 0 0; border-radius: 9999px; background: var(--skill); transition: width 0.5s; width: 0; }
.rc-progress-num { font-size: 0.75rem; font-weight: 600; font-variant-numeric: tabular-nums; }
.rc-progress-detail { display: none; font-size: 0.75rem; color: var(--muted); }
@media (min-width: 640px) { .rc-progress-detail { display: inline; } }
.rc-hint {
  display: none;
  border: 0;
  background: rgba(255, 255, 255, 0.8);
  padding: 0.375rem 0.75rem;
  font-size: 0.75rem; font-weight: 500; color: var(--muted);
}
@media (min-width: 768px) { .rc-hint { display: inline-flex; } }
.rc-zoom {
  pointer-events: auto;
  display: flex; flex-direction: column;
  overflow: hidden;
  border-radius: var(--radius-xl);
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.9);
  box-shadow: var(--shadow-card);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}
.rc-zoom button { display: grid; place-items: center; width: 2.5rem; height: 2.5rem; color: var(--ink); }
.rc-zoom button:hover { background: var(--surface); }
.rc-zoom button + button { border-top: 1px solid var(--line); }
.rc-reset {
  pointer-events: auto;
  display: grid; place-items: center;
  width: 2.5rem; height: 2.5rem;
  border-radius: var(--radius-xl);
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.9);
  color: var(--ink);
  box-shadow: var(--shadow-card);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}
.rc-reset:hover { background: var(--surface); }

.roadmap-empty {
  display: flex; height: 60vh; min-height: 420px;
  flex-direction: column; align-items: center; justify-content: center;
  border-radius: var(--radius-2xl);
  border: 1px solid var(--line);
  background: var(--surface);
  text-align: center;
}
.roadmap-empty-title { font-size: 1.125rem; font-weight: 700; }
.roadmap-empty-desc { margin-top: 0.25rem; max-width: 24rem; font-size: 0.875rem; color: var(--muted); }

/* ── Doc reader ─────────────────────────────────────────────────────────── */
.dr-pad { padding-top: 2rem; padding-bottom: 2rem; }
.dr-readbar {
  position: fixed;
  left: 0; right: 0; top: 4rem;
  z-index: 30;
  height: 2px;
  transform-origin: left;
  transform: scaleX(0);
  background: var(--skill);
}
.dr-headrow { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0.75rem; }
.dr-back { display: inline-flex; align-items: center; gap: 0.375rem; font-size: 0.875rem; font-weight: 500; color: var(--muted); }
.dr-back:hover { color: var(--navy); }
.dr-kind { display: inline-flex; align-items: center; gap: 0.5rem; font-size: 0.875rem; font-weight: 600; color: var(--navy); }

.dr-tabs { margin-top: 1rem; display: flex; gap: 0.5rem; overflow-x: auto; padding-bottom: 0.25rem; }
.dr-tab {
  white-space: nowrap;
  border-radius: 9999px;
  padding: 0.5rem 1rem;
  font-size: 0.875rem; font-weight: 500;
  border: 1px solid var(--line);
  background: #fff; color: var(--muted);
  transition: border-color 0.2s;
}
.dr-tab:hover { border-color: var(--sky); }
.dr-tab-active { background: var(--navy); color: #fff; border-color: var(--navy); }

.dr-toolbar {
  position: sticky; top: 4rem; z-index: 20;
  margin-top: 1rem;
  display: flex; flex-direction: column; gap: 0.5rem;
  border-radius: var(--radius-xl);
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.9);
  padding: 0.5rem;
  box-shadow: var(--shadow-card);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}
.dr-toolbar-row { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0.5rem; }
.dr-zoom { display: flex; align-items: center; gap: 0.25rem; }
.dr-iconbtn { display: grid; place-items: center; width: 2.25rem; height: 2.25rem; border-radius: var(--radius-lg); color: var(--ink); }
.dr-iconbtn:hover { background: var(--surface); }
.dr-zoomval { width: 3rem; text-align: center; font-size: 0.875rem; font-variant-numeric: tabular-nums; color: var(--muted); }
.dr-tools { display: flex; align-items: center; gap: 0.5rem; }
.dr-tool-highlight { min-height: 36px; height: 2.25rem; padding: 0 0.75rem; font-size: 0.875rem; border: 1px solid var(--line); background: #fff; color: var(--ink); }
.dr-tool-highlight:hover { background: var(--surface); }
.dr-tool-highlight.dr-on { background: var(--navy); color: #fff; border-color: var(--navy); }
.dr-hl-swatch { display: inline-block; width: 0.875rem; height: 0.875rem; border-radius: 9999px; }
.dr-tool-clear { min-height: 36px; height: 2.25rem; padding: 0 0.75rem; font-size: 0.875rem; border: 1px solid var(--line); background: #fff; color: var(--ink); }
.dr-tool-clear:hover { background: var(--surface); }
.dr-tool-print { min-height: 36px; height: 2.25rem; padding: 0 0.75rem; font-size: 0.875rem; }
.dr-tool-label { display: none; }
@media (min-width: 640px) { .dr-tool-label { display: inline; } }

.dr-picker {
  display: flex; flex-wrap: wrap; align-items: center;
  column-gap: 1rem; row-gap: 0.5rem;
  border-top: 1px solid var(--line);
  padding: 0.5rem 0.25rem 0;
}
.dr-picker-group { display: flex; align-items: center; gap: 0.375rem; }
.dr-picker-label { font-size: 11px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.05em; color: var(--muted); margin-right: 0.125rem; }
.dr-swatch { width: 1.75rem; height: 1.75rem; border-radius: 9999px; transition: transform 0.15s, box-shadow 0.15s; }
.dr-swatch:hover { transform: scale(1.05); }
.dr-swatch-active { transform: scale(1.1); box-shadow: 0 0 0 2px #fff, 0 0 0 4px var(--ink); }
.dr-swatch-yellow { background: #fcd34d; } .dr-swatch-green { background: #6ee7b7; }
.dr-swatch-blue { background: #7dd3fc; } .dr-swatch-pink { background: #f9a8d4; }
.dr-swatch-purple { background: #d8b4fe; }
.dr-stylebtn { display: grid; place-items: center; width: 2.25rem; height: 2.25rem; border-radius: var(--radius-lg); color: var(--ink); transition: background 0.15s, color 0.15s; }
.dr-stylebtn:hover { background: var(--surface); }
.dr-stylebtn-active { background: var(--navy); color: #fff; }

.dr-layout { margin-top: 1.5rem; }
@media (min-width: 1024px) {
  .dr-layout { display: grid; grid-template-columns: 230px minmax(0, 1fr); gap: 2rem; }
}
.dr-sidebar { display: none; }
@media (min-width: 1024px) { .dr-sidebar { display: block; } }
.dr-toc { position: sticky; top: 8rem; }
.dr-toc-title { display: flex; align-items: center; gap: 0.375rem; font-size: 0.75rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.05em; color: var(--muted); }
.dr-toc-list { margin-top: 0.75rem; border-left: 1px solid var(--line); }
.dr-toc-list li + li { margin-top: 0.125rem; }
.dr-toc-list a {
  display: block;
  border-left: 2px solid transparent;
  padding: 0.375rem 0 0.375rem 0.75rem;
  font-size: 0.875rem; line-height: 1.375; color: var(--muted);
  transition: color 0.2s, border-color 0.2s;
}
.dr-toc-list a:hover { border-color: var(--skill); color: var(--ink); }
.dr-toc-list a.dr-toc-active { border-color: var(--skill); font-weight: 600; color: var(--ink); }

.dr-doc { margin: 0 auto; width: 100%; max-width: 48rem; }
.dr-doc > * + * { margin-top: 1.25rem; }
.dr-doc.dr-hl-on { cursor: text; }

.dr-mtoc-btn {
  display: flex; min-height: 44px; width: 100%;
  align-items: center; justify-content: space-between; gap: 0.5rem;
  border-radius: var(--radius-xl);
  border: 1px solid var(--line);
  background: #fff;
  padding: 0.625rem 1rem;
  font-size: 0.875rem; font-weight: 600; color: var(--ink);
  box-shadow: var(--shadow-card);
}
.dr-mtoc-left { display: flex; align-items: center; gap: 0.5rem; }
.dr-mtoc-count { border-radius: 9999px; background: var(--surface); padding: 0 0.375rem; font-size: 0.75rem; font-weight: 500; font-variant-numeric: tabular-nums; color: var(--muted); }
.dr-mtoc-chevron { color: var(--muted); transition: transform 0.2s; }
.dr-mtoc-btn[aria-expanded="true"] .dr-mtoc-chevron { transform: rotate(180deg); }
.dr-mtoc-list { margin-top: 0.5rem; overflow: hidden; border-radius: var(--radius-xl); border: 1px solid var(--line); background: #fff; box-shadow: var(--shadow-card); }
.dr-mtoc-list a {
  display: flex; min-height: 44px; align-items: center; gap: 0.625rem;
  border-bottom: 1px solid var(--line);
  padding: 0.625rem 1rem;
  font-size: 0.875rem; color: var(--muted);
}
.dr-mtoc-list li:last-child a { border-bottom: 0; }
.dr-mtoc-list a:hover { background: var(--surface); }
.dr-mtoc-num { font-weight: 600; font-variant-numeric: tabular-nums; }
@media (min-width: 1024px) { .dr-mobiletoc { display: none; } }

.dr-titlecard {
  border-radius: var(--radius-2xl);
  border: 1px solid var(--line);
  background: #fff;
  padding: 1.5rem;
  box-shadow: var(--shadow-card);
}
@media (min-width: 640px) { .dr-titlecard { padding: 2rem; } }
.dr-title { margin-top: 0.75rem; font-size: 1.5rem; color: var(--ink); }
@media (min-width: 640px) { .dr-title { font-size: 1.875rem; } }
.dr-meta { margin-top: 0.25rem; font-size: 0.875rem; color: var(--muted); }
.dr-intro { margin-top: 1.25rem; border-top: 1px solid var(--line); padding-top: 1.25rem; line-height: 1.625; color: var(--ink); }
.dr-intro > * + * { margin-top: 1rem; }

.dr-section {
  overflow: hidden;
  border-radius: var(--radius-2xl);
  border: 1px solid var(--line);
  background: #fff;
  box-shadow: var(--shadow-card);
  scroll-margin-top: 8rem;
}
.dr-section-head {
  display: flex; align-items: center; gap: 0.75rem;
  border-bottom: 1px solid var(--line);
  background: var(--surface);
  padding: 0.875rem 1.25rem;
}
@media (min-width: 640px) { .dr-section-head { padding-left: 1.75rem; padding-right: 1.75rem; } }
.dr-section-num {
  display: grid; place-items: center; flex-shrink: 0;
  width: 1.75rem; height: 1.75rem;
  border-radius: var(--radius-lg);
  background: var(--skill);
  font-size: 0.75rem; font-weight: 700; color: #fff;
}
.dr-section-heading { font-size: 1.125rem; line-height: 1.375; color: var(--ink); }
.dr-section-body { padding: 1.25rem; line-height: 1.625; color: var(--ink); }
@media (min-width: 640px) { .dr-section-body { padding: 1.75rem; } }
.dr-section-body > * + * { margin-top: 1rem; }

.dr-h3 { padding-top: 0.5rem; font-size: 1rem; }
.dr-list { list-style: disc; padding-left: 1.25rem; }
.dr-list li { margin-top: 0.375rem; }
.dr-list li::marker { color: var(--muted); }
.dr-code {
  overflow-x: auto;
  white-space: pre-wrap;
  border-radius: var(--radius-xl);
  background: #0f1a2b;
  padding: 0.875rem 1rem;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.85em;
  line-height: 1.625;
  color: #f1f5f9;
}

/* Highlight marks (5 colors × 4 styles, painter's algorithm in docreader.js) */
mark { background: transparent; color: var(--ink); }
.dr-hl-on mark { cursor: pointer; }
.mk-fill { border-radius: 0.25rem; padding: 0 0.125rem; }
.mk-fill-yellow { background: rgba(253, 230, 138, 0.8); } .mk-fill-green { background: rgba(167, 243, 208, 0.8); }
.mk-fill-blue { background: rgba(186, 230, 253, 0.8); } .mk-fill-pink { background: rgba(251, 207, 232, 0.8); }
.mk-fill-purple { background: rgba(233, 213, 255, 0.8); }
.mk-soft-yellow { background: rgba(253, 230, 138, 0.35); } .mk-soft-green { background: rgba(167, 243, 208, 0.35); }
.mk-soft-blue { background: rgba(186, 230, 253, 0.35); } .mk-soft-pink { background: rgba(251, 207, 232, 0.35); }
.mk-soft-purple { background: rgba(233, 213, 255, 0.35); }
.mk-underline { text-decoration-line: underline; text-decoration-thickness: 2px; text-underline-offset: 2px; }
.mk-underline-yellow { text-decoration-color: #d97706; } .mk-underline-green { text-decoration-color: #059669; }
.mk-underline-blue { text-decoration-color: #0284c7; } .mk-underline-pink { text-decoration-color: #db2777; }
.mk-underline-purple { text-decoration-color: #9333ea; }
.mk-circle { border-radius: 0.375rem; padding: 0 0.25rem; box-decoration-break: clone; -webkit-box-decoration-break: clone; }
.mk-circle-yellow { box-shadow: inset 0 0 0 2px #d97706; } .mk-circle-green { box-shadow: inset 0 0 0 2px #059669; }
.mk-circle-blue { box-shadow: inset 0 0 0 2px #0284c7; } .mk-circle-pink { box-shadow: inset 0 0 0 2px #db2777; }
.mk-circle-purple { box-shadow: inset 0 0 0 2px #9333ea; }
.mk-star-glyph { display: inline-block; width: 0.75rem; height: 0.75rem; margin-right: 0.125rem; transform: translateY(-1px); }
.mk-star-yellow { color: #d97706; } .mk-star-green { color: #059669; }
.mk-star-blue { color: #0284c7; } .mk-star-pink { color: #db2777; }
.mk-star-purple { color: #9333ea; }

.dr-pager { display: flex; align-items: center; justify-content: space-between; gap: 0.75rem; padding-top: 0.25rem; }
.dr-pager-btn { min-width: 0; max-width: 48%; font-size: 0.875rem; }
.dr-pager-next { margin-left: auto; }
.dr-pager-icon { flex-shrink: 0; }
.dr-pager-title { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.dr-hlhint { margin: 0.75rem auto 0; max-width: 48rem; text-align: center; font-size: 0.75rem; color: var(--muted); }
.dr-empty { text-align: center; }

/* ── About / contact / community / legal ────────────────────────────────── */
.about-hero { margin: 0 auto; max-width: 42rem; text-align: center; }
.about-lead { color: var(--muted); text-wrap: pretty; }
@media (min-width: 640px) { .about-lead { font-size: 1.125rem; } }
.about-numbers { margin: 2.5rem auto 0; display: grid; max-width: 42rem; grid-template-columns: repeat(3, 1fr); gap: 1rem; }
.about-number { padding: 1rem; text-align: center; }
.about-number-value { font-family: var(--font-heading); font-size: 1.875rem; font-weight: 700; color: var(--navy); }
.about-number-label { margin-top: 0.25rem; font-size: 0.75rem; color: var(--muted); }
.about-story { margin: 0 auto; display: grid; max-width: 56rem; gap: 2.5rem; }
@media (min-width: 640px) { .about-story { grid-template-columns: auto 1fr; } }
.about-story-icon { margin: 0 auto; width: 3.5rem; height: 3.5rem; border-radius: var(--radius-2xl); }
@media (min-width: 640px) { .about-story-icon { margin: 0; } }
.about-story-text { margin-top: 0.75rem; color: var(--muted); }
.about-story-text p + p { margin-top: 1rem; }
.about-values { margin: 2rem auto 0; display: grid; max-width: 56rem; gap: 1.25rem; }
@media (min-width: 640px) { .about-values { grid-template-columns: repeat(2, 1fr); } }
.about-trust {
  margin: 0 auto; display: flex; max-width: 48rem;
  flex-direction: column; align-items: center; gap: 0.75rem;
  border-radius: var(--radius-2xl);
  border: 1px solid var(--line);
  background: var(--surface);
  padding: 1.5rem;
  text-align: center;
}
@media (min-width: 640px) { .about-trust { flex-direction: row; text-align: left; } }
.about-trust-icon {
  display: grid; place-items: center; flex-shrink: 0;
  width: 2.75rem; height: 2.75rem;
  border-radius: var(--radius-xl);
  background: #fff; color: var(--navy);
  box-shadow: var(--shadow-card);
}
.about-trust p { font-size: 0.875rem; color: var(--muted); }
.about-cta, .community-cta {
  margin: 0 auto; max-width: 42rem;
  border-radius: var(--radius-3xl);
  background: var(--navy);
  padding: 2.5rem 1.5rem;
  text-align: center; color: #fff;
}
.community-cta { margin-top: 3rem; }
.about-cta-actions { margin-top: 1.5rem; display: flex; flex-direction: column; justify-content: center; gap: 0.75rem; }
@media (min-width: 640px) { .about-cta-actions { flex-direction: row; } }

.contact-badge {
  margin: 0 auto;
  display: grid; place-items: center;
  width: 4rem; height: 4rem;
  border-radius: var(--radius-3xl);
  background: rgba(37, 211, 102, 0.1);
  color: var(--whatsapp);
}
.section-head-center .btn { display: inline-flex; }
.contact-reasons { margin: 3.5rem auto 0; display: grid; max-width: 56rem; gap: 1.25rem; }
@media (min-width: 640px) { .contact-reasons { grid-template-columns: repeat(3, 1fr); } }
.contact-card { padding: 1.25rem; }
.contact-card h2 { margin-top: 0.75rem; font-size: 1rem; font-family: var(--font-heading); }
.contact-card p { margin-top: 0.25rem; font-size: 0.875rem; color: var(--muted); }
.contact-footnote { margin: 3rem auto 0; max-width: 28rem; text-align: center; font-size: 0.875rem; color: var(--muted); }
.community-note { margin-top: 0.75rem; font-size: 0.75rem; color: var(--muted); }
.community-perks { margin: 3.5rem auto 0; display: grid; max-width: 56rem; gap: 1.25rem; }
@media (min-width: 640px) { .community-perks { grid-template-columns: repeat(2, 1fr); } }

.legal-wrap { margin: 0 auto; max-width: 48rem; }
.legal-date { margin-top: 0.5rem; font-size: 0.875rem; color: var(--muted); }
.legal-notice {
  margin: 0 auto 2rem;
  display: flex; max-width: 48rem; align-items: flex-start; gap: 0.75rem;
  border-radius: var(--radius-xl);
  border: 1px solid rgba(217, 119, 6, 0.3);
  background: rgba(217, 119, 6, 0.1);
  padding: 0.75rem 1rem;
  font-size: 0.875rem; color: var(--ink);
}
.legal-notice-icon { margin-top: 0.125rem; flex-shrink: 0; color: var(--warn); }
.legal-sections { font-size: 0.875rem; line-height: 1.625; color: var(--muted); }
.legal-sections section + section { margin-top: 2rem; }
.legal-sections h2 { font-size: 1.125rem; color: var(--ink); }
.legal-sections p { margin-top: 0.5rem; }

.notfound { padding-top: 6rem; padding-bottom: 6rem; text-align: center; }
.notfound-code { font-family: var(--font-heading); font-size: 3.75rem; font-weight: 700; color: var(--navy); }
.notfound .empty-icon { margin: 0 auto; }

/* ── Footer ─────────────────────────────────────────────────────────────── */
.site-footer { margin-top: 4rem; border-top: 1px solid var(--line); background: var(--surface); }
.footer-grid { display: grid; gap: 2.5rem; padding-top: 3rem; padding-bottom: 3rem; }
@media (min-width: 640px) { .footer-grid { grid-template-columns: 1.3fr 1fr 1fr 1fr; } }
.footer-brand { max-width: 24rem; }
.footer-tagline { margin-top: 0.75rem; font-size: 0.875rem; color: var(--muted); }
.footer-col-title { font-size: 0.75rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.025em; color: var(--ink); }
.footer-links { margin-top: 0.75rem; }
.footer-links li + li { margin-top: 0.625rem; }
.footer-links a { font-size: 0.875rem; color: var(--muted); }
.footer-links a:hover { color: var(--navy); }
.footer-bottom { border-top: 1px solid var(--line); }
.footer-bottom-inner {
  display: flex; flex-direction: column; gap: 0.5rem;
  padding-top: 1rem; padding-bottom: 1rem;
  font-size: 0.75rem; color: var(--muted);
}
@media (min-width: 640px) { .footer-bottom-inner { flex-direction: row; align-items: center; justify-content: space-between; } }

/* ── Modals (paywall + iOS install sheet) ───────────────────────────────── */
.modal-root {
  position: fixed; inset: 0; z-index: 100;
  display: flex; align-items: flex-end; justify-content: center;
  opacity: 0;
  transition: opacity 0.2s;
}
@media (min-width: 640px) { .modal-root { align-items: center; } }
.modal-root.modal-in { opacity: 1; }
.modal-scrim {
  position: absolute; inset: 0;
  background: rgba(15, 30, 46, 0.5);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
}
.modal-sheet {
  position: relative; z-index: 10;
  width: 100%; max-width: 28rem;
  overflow: hidden;
  border-bottom-left-radius: 0; border-bottom-right-radius: 0;
  border-top-left-radius: var(--radius-3xl); border-top-right-radius: var(--radius-3xl);
  padding: 1.5rem;
  padding-bottom: max(1.5rem, calc(1rem + env(safe-area-inset-bottom)));
  transform: translateY(40px) scale(0.98);
  transition: transform 0.3s cubic-bezier(0.2, 0.9, 0.3, 1.2);
}
@media (min-width: 640px) { .modal-sheet { border-radius: var(--radius-3xl); padding: 1.75rem; max-width: 24rem; } }
.paywall-sheet { max-width: 28rem; }
@media (min-width: 640px) { .paywall-sheet { max-width: 28rem; } }
.modal-in .modal-sheet { transform: translateY(0) scale(1); }
.modal-close {
  position: absolute; right: 1rem; top: 1rem;
  display: grid; place-items: center;
  width: 2.25rem; height: 2.25rem;
  border-radius: var(--radius-lg);
  color: var(--muted);
}
.modal-close:hover { background: var(--surface); }

.paywall-title { margin-top: 0.75rem; font-size: 1.25rem; }
.paywall-sub { margin-top: 0.25rem; font-size: 0.875rem; color: var(--muted); }
.paywall-plans { margin-top: 1.25rem; display: flex; flex-direction: column; gap: 0.75rem; }
.plan-option {
  display: flex; width: 100%;
  align-items: center; justify-content: space-between;
  border-radius: var(--radius-2xl);
  border: 2px solid var(--line);
  background: #fff;
  padding: 1rem;
  text-align: left;
  transition: border-color 0.2s, background 0.2s;
}
.plan-option:hover { border-color: var(--sky); }
.plan-option.plan-selected { border-color: var(--navy); background: var(--sky-soft); }
.plan-name { display: block; font-weight: 600; color: var(--ink); }
.plan-sub { display: block; margin-top: 0.125rem; font-size: 0.75rem; color: var(--muted); }
.plan-right { text-align: right; }
.plan-price { display: block; font-family: var(--font-heading); font-weight: 700; color: var(--navy); }
.plan-radio {
  margin-top: 0.25rem;
  display: inline-grid; place-items: center;
  width: 1.25rem; height: 1.25rem;
  border-radius: 9999px;
  border: 1px solid var(--line);
  color: transparent;
}
.plan-selected .plan-radio { border-color: var(--navy); background: var(--navy); color: #fff; }
.paywall-pay { margin-top: 1.5rem; }
.paywall-note { margin-top: 0.75rem; text-align: center; font-size: 0.75rem; color: var(--muted); }
.paywall-error { margin-top: 0.75rem; border-radius: var(--radius-xl); background: rgba(220, 38, 38, 0.1); padding: 0.5rem 1rem; font-size: 0.875rem; color: var(--danger); }
.paywall-done { padding: 0.5rem; text-align: center; }
.done-badge {
  margin: 0 auto;
  display: grid; place-items: center;
  width: 3.5rem; height: 3.5rem;
  border-radius: 9999px;
  background: rgba(22, 163, 74, 0.1);
}
.done-title { margin-top: 1rem; font-size: 1.25rem; }
.done-msg { margin-top: 0.5rem; font-size: 0.875rem; color: var(--muted); }
.done-start { margin-top: 1.5rem; }

.sheet-title { font-size: 1.125rem; }
.sheet-sub { margin-top: 0.25rem; font-size: 0.875rem; color: var(--muted); }
.sheet-steps { margin-top: 1.25rem; list-style: none; }
.sheet-steps li { display: flex; align-items: center; gap: 0.75rem; }
.sheet-steps li + li { margin-top: 1rem; }
.sheet-step-icon {
  display: grid; place-items: center; flex-shrink: 0;
  width: 2.25rem; height: 2.25rem;
  border-radius: var(--radius-xl);
  background: var(--sky-soft); color: var(--navy);
}
.sheet-steps span:last-child { font-size: 0.875rem; }
.sheet-got-it { margin-top: 1.5rem; }

/* spinner */
@keyframes sn-spin { to { transform: rotate(360deg); } }
.spin { animation: sn-spin 1s linear infinite; }

/* ── Admin panel ────────────────────────────────────────────────────────── */
.admin-body { min-height: 100dvh; background: var(--surface); padding-bottom: 5rem; }
.admin-topbar {
  position: sticky; top: 0; z-index: 30;
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}
.admin-topbar-inner {
  margin: 0 auto; display: flex; max-width: 64rem;
  align-items: center; justify-content: space-between;
  padding: 0.75rem 1.25rem;
}
.admin-brand { display: flex; align-items: center; gap: 0.625rem; }
.admin-brand .brand-mark { width: 2rem; height: 2rem; }
.admin-brand-name { font-family: var(--font-heading); font-weight: 700; }
.admin-topbar-actions { display: flex; align-items: center; gap: 0.5rem; }
.admin-main { margin: 0 auto; max-width: 64rem; padding: 2rem 1.25rem; }
.admin-main section + section, .admin-main .mt-8 { margin-top: 2rem; }
.admin-section-head { margin-bottom: 1rem; display: flex; align-items: center; justify-content: space-between; gap: 0.75rem; }
.admin-h1 { font-size: 1.5rem; }
.admin-h2 { display: flex; align-items: center; gap: 0.5rem; font-size: 1.25rem; }
.admin-sub { font-size: 0.875rem; color: var(--muted); }
.admin-save { flex-shrink: 0; }
.admin-msg {
  margin-bottom: 1rem;
  display: flex; align-items: center; gap: 0.5rem;
  border-radius: var(--radius-xl);
  padding: 0.75rem 1rem;
  font-size: 0.875rem;
}
.admin-msg-ok { background: rgba(22, 163, 74, 0.1); color: var(--success); }
.admin-msg-error { background: rgba(220, 38, 38, 0.1); color: var(--danger); }
.admin-skills { display: flex; flex-direction: column; gap: 1rem; }
.admin-skill, .admin-card { padding: 1.25rem; margin-top: 0.75rem; }
.admin-skills .admin-skill { margin-top: 0; }
.admin-skill-head { margin-bottom: 0.75rem; display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 0.5rem; }
.admin-slug { border-radius: 0.25rem; background: var(--surface); padding: 0.125rem 0.5rem; font-size: 0.75rem; color: var(--muted); }
.admin-selects { display: flex; align-items: center; gap: 0.75rem; flex-wrap: wrap; }
.admin-inline-label { display: flex; align-items: center; gap: 0.5rem; font-size: 0.75rem; font-weight: 500; color: var(--muted); }
.admin-select { border-radius: var(--radius-lg); border: 1px solid var(--line); background: #fff; padding: 0.25rem 0.5rem; font-size: 0.875rem; font-family: inherit; color: var(--ink); }
.admin-field { display: block; margin-bottom: 0.75rem; }
.admin-label { display: block; margin-bottom: 0.25rem; font-size: 0.75rem; font-weight: 600; color: var(--muted); }
.admin-3col { display: grid; gap: 0.75rem; }
@media (min-width: 640px) { .admin-3col { grid-template-columns: repeat(3, 1fr); } }
.admin-2col { display: grid; gap: 0.75rem; }
@media (min-width: 640px) { .admin-2col { grid-template-columns: repeat(2, 1fr); } }
.admin-note { font-size: 0.875rem; color: var(--muted); }
.admin-note code { background: var(--surface); padding: 0.125rem 0.25rem; border-radius: 0.25rem; font-size: 0.8em; }
.admin-account .admin-msg { margin-bottom: 0.75rem; }
.admin-login-wrap { display: grid; min-height: 100dvh; place-items: center; padding: 0 1.25rem; }
.admin-login-box { width: 100%; max-width: 24rem; }
.admin-login-head { margin-bottom: 1.5rem; display: flex; flex-direction: column; align-items: center; gap: 0.75rem; text-align: center; }
.admin-login-title { font-size: 1.25rem; }
.admin-login-sub { font-size: 0.875rem; color: var(--muted); }
.admin-login-form { display: flex; flex-direction: column; gap: 1rem; padding: 1.5rem; }

/* ── Print (Download-PDF prints only the document, cleanly) ─────────────── */
@media print {
  body { background: #fff; }
  body * { visibility: hidden; }
  .printable, .printable * { visibility: visible; }
  .printable {
    position: absolute; left: 0; top: 0;
    width: 100%; margin: 0;
    border: none; box-shadow: none;
    font-size: 12pt;
  }
  .print-hidden, .print-hidden * { display: none !important; }
  mark { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
}

/* ═══════════════════════════════════════════════════════════════════════════
   ENHANCEMENT PASS — precision motion + depth (Stripe/Linear grade).
   Everything below is additive, transform/opacity-only, gated to fine
   pointers where it's cursor-driven, and killed by prefers-reduced-motion.
   ═══════════════════════════════════════════════════════════════════════════ */

/* ── Buttons: lift on hover, spring press ───────────────────────────────── */
.btn { transition: transform 0.2s cubic-bezier(0.34, 1.56, 0.64, 1), background 0.2s, box-shadow 0.25s, border-color 0.2s, color 0.2s; }
.btn-primary:hover, .btn-accent:hover, .btn-whatsapp:hover, .btn-onnavy:hover { transform: translateY(-1px); }
.btn-primary:active, .btn-accent:active, .btn-whatsapp:active, .btn-onnavy:active { transform: translateY(0) scale(0.97); }
/* Magnetic CTAs — JS drives --magx/--magy toward the cursor. */
[data-magnetic] { transform: translate(var(--magx, 0px), var(--magy, 0px)); transition: transform 0.28s cubic-bezier(0.34, 1.56, 0.64, 1); will-change: transform; }
[data-magnetic]:active { transform: translate(var(--magx, 0px), var(--magy, 0px)) scale(0.97); }

/* ── Cursor-spotlight cards (Linear-style border/fill glow) ─────────────── */
.spot-card { position: relative; }
.spot-card::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.35s ease;
  background: radial-gradient(240px circle at var(--sx, 50%) var(--sy, 50%), rgba(91, 155, 245, 0.1), transparent 65%);
}
.spot-card::before {
  content: "";
  position: absolute;
  inset: -1px;
  border-radius: inherit;
  padding: 1px;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.35s ease;
  background: radial-gradient(200px circle at var(--sx, 50%) var(--sy, 50%), rgba(91, 155, 245, 0.55), transparent 70%);
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  mask-composite: exclude;
}
@media (pointer: fine) {
  .spot-card.spot-on::after, .spot-card.spot-on::before { opacity: 1; }
}
/* Skill cards clip their accent bar with overflow:hidden — the ring sits
   inside; other cards inherit their radius so the ring hugs the border. */

/* ── 3D depth layers inside tilt cards ──────────────────────────────────── */
@media (pointer: fine) {
  .tilt-card > * { transform-style: preserve-3d; }
  .skill-card-icon, .skill-card-title, .hiw-card .tile-icon, .feature-card .tile-icon { transition: transform 0.3s cubic-bezier(0.22, 1, 0.36, 1); }
  .tilt-card:hover .skill-card-icon { transform: rotate(-3deg) scale(1.05) translateZ(28px); }
  .tilt-card:hover .skill-card-title { transform: translateZ(16px); }
  .tilt-card:hover .hiw-card .tile-icon,
  .tilt-card:hover .feature-card .tile-icon { transform: rotate(-3deg) scale(1.05) translateZ(22px); }
}

/* ── Hero: breathing brand washes + parallax grid + chip depth ──────────── */
@keyframes sn-breathe {
  0% { transform: translate3d(0, 0, 0) scale(1); opacity: 0.85; }
  100% { transform: translate3d(0, -12px, 0) scale(1.05); opacity: 1; }
}
.hero-wash { animation: sn-breathe 14s ease-in-out infinite alternate; will-change: transform, opacity; }
.hero-grid-backdrop { will-change: transform; }
.laptop-chip { transition: transform 0.25s cubic-bezier(0.22, 1, 0.36, 1); will-change: transform; }

/* ── Section headings: gradient ink bar draws in on first view ──────────── */
.section-head-center h2::after, .section-head-row h2::after, .catalog-head .page-h1::after {
  content: "";
  display: block;
  width: 2.75rem;
  height: 3px;
  margin-top: 0.625rem;
  border-radius: 3px;
  background: var(--brand-gradient);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.7s cubic-bezier(0.22, 1, 0.36, 1) 0.15s;
}
.section-head-center h2::after { margin-left: auto; margin-right: auto; transform-origin: center; }
.h2-inked::after { transform: scaleX(1) !important; }
/* Headings on dark bands keep the bar white-ish */
.cta-band h2::after, .about-cta h2::after, .community-cta h2::after { display: none; }

/* ── CTA band: soft cursor glow over the navy field ─────────────────────── */
.cta-band { --sx: 50%; --sy: 50%; }
.cta-band::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.4s ease;
  background: radial-gradient(320px circle at var(--sx) var(--sy), rgba(255, 255, 255, 0.09), transparent 70%);
}
@media (pointer: fine) { .cta-band.spot-on::after { opacity: 1; } }

/* ── Roadmap: load-in choreography ──────────────────────────────────────── */
.rc-node.rc-enter { scale: 0.82; opacity: 0; }
.rc-node { transition: opacity 0.4s cubic-bezier(0.22, 1, 0.36, 1), scale 0.4s cubic-bezier(0.34, 1.4, 0.64, 1); }
.rc-centre-btn.rc-enter { scale: 0.9; opacity: 0; }
.rc-centre-btn { transition: transform 0.15s, scale 0.45s cubic-bezier(0.34, 1.4, 0.64, 1), opacity 0.45s ease; }

/* ── Micro: logo, footer links ──────────────────────────────────────────── */
.brand-mark { transition: transform 0.25s cubic-bezier(0.34, 1.56, 0.64, 1); }
.logo:hover .brand-mark { transform: scale(1.07) rotate(-4deg); }
.footer-links a { position: relative; }
.footer-links a::after {
  content: "";
  position: absolute;
  left: 0; right: auto; bottom: -2px;
  width: 100%;
  height: 1.5px;
  border-radius: 2px;
  background: var(--sky);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.25s ease;
}
.footer-links a:hover::after { transform: scaleX(1); }

/* ── Doc reader: section cards get a soft settle on first view ──────────── */
.dr-section { transition: box-shadow 0.3s; }
.dr-section:hover { box-shadow: var(--shadow-card-hover); }

/* ── Reduced motion — kill non-essential animation ──────────────────────── */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
  .reveal-item, .reveal-stagger .reveal-child, .words-ready .word-inner { transform: none !important; }
  .rc-node.rc-enter, .rc-centre-btn.rc-enter { scale: 1 !important; opacity: 1 !important; }
  [data-magnetic] { transform: none !important; }
  .section-head-center h2::after, .section-head-row h2::after, .catalog-head .page-h1::after { transform: scaleX(1) !important; }
  .spot-card::before, .spot-card::after, .cta-band::after { opacity: 0 !important; }
}
