/* ============================================================
   BitDigo Landing Page — Design System
   Brand: Indigo  #4B0082 · Bitcoin  #F7931A
   ============================================================ */

/* ---------- Tokens ---------- */
:root {
  --indigo-400: #8b5cf6;
  --indigo-500: #6d28d9;
  --indigo-600: #5b21b6;
  --indigo-700: #4b0082;
  --indigo-900: #2a0148;
  --btc: #f7931a;
  --btc-soft: #ffb454;

  --maxw: 1200px;
  --narrow: 820px;
  --r-sm: 10px;
  --r-md: 16px;
  --r-lg: 24px;
  --r-xl: 32px;
  --r-full: 999px;

  --gutter: clamp(1.1rem, 4vw, 2.5rem);
  --sec-y: clamp(4.5rem, 11vw, 8.5rem);

  --font-sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
  /* Chanthavong is MTS Lao's own typeface and the primary Lao face.
     Noto Sans Lao is the webfont fallback; the rest are common faces
     already installed on Lao-market machines. */
  --font-lao: "Chanthavong", "Noto Sans Lao", "Phetsarath OT", "Saysettha OT", sans-serif;

  --ease: cubic-bezier(0.4, 0, 0.2, 1);
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --t-fast: 0.18s var(--ease);
  --t: 0.32s var(--ease-out);

  --z-header: 100;
  --z-toast: 200;
}

/* Dark theme (default — brand-locked) */
[data-theme="dark"] {
  --bg: #08050f;
  --bg-alt: #0d0919;
  --bg-band: #0a0715;
  --surface: rgba(255, 255, 255, 0.035);
  --surface-2: rgba(255, 255, 255, 0.06);
  --surface-solid: #140d24;
  --border: rgba(255, 255, 255, 0.09);
  --border-strong: rgba(255, 255, 255, 0.16);
  --text: #f4f1fa;
  --text-soft: #b6aecb;
  --text-mute: #7f7699;
  --accent: var(--indigo-400);
  --accent-2: var(--btc);
  --accent-contrast: #fff;
  --shadow-sm: 0 2px 10px rgba(0, 0, 0, 0.4);
  --shadow-md: 0 12px 32px rgba(0, 0, 0, 0.5);
  --shadow-lg: 0 28px 70px rgba(0, 0, 0, 0.62);
  --glow: 0 0 0 1px rgba(139, 92, 246, 0.28), 0 18px 55px rgba(109, 40, 217, 0.32);
  --code-bg: #0b0718;
  --grid-line: rgba(255, 255, 255, 0.032);
  color-scheme: dark;
}

/* Light theme */
[data-theme="light"] {
  --bg: #f7f5fb;
  --bg-alt: #ffffff;
  --bg-band: #efeaf8;
  --surface: rgba(75, 0, 130, 0.035);
  --surface-2: rgba(75, 0, 130, 0.07);
  --surface-solid: #ffffff;
  --border: rgba(75, 0, 130, 0.13);
  --border-strong: rgba(75, 0, 130, 0.24);
  --text: #170b2c;
  --text-soft: #574a72;
  --text-mute: #7a6e92;
  --accent: var(--indigo-700);
  --accent-2: #d97706;
  --accent-contrast: #fff;
  --shadow-sm: 0 2px 10px rgba(75, 0, 130, 0.07);
  --shadow-md: 0 12px 32px rgba(75, 0, 130, 0.11);
  --shadow-lg: 0 28px 70px rgba(75, 0, 130, 0.15);
  --glow: 0 0 0 1px rgba(75, 0, 130, 0.18), 0 18px 55px rgba(75, 0, 130, 0.16);
  --code-bg: #160e26;
  --grid-line: rgba(75, 0, 130, 0.05);
  color-scheme: light;
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; padding: 0; }

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: 88px;
}

body {
  font-family: var(--font-sans);
  background: var(--bg);
  color: var(--text);
  line-height: 1.65;
  font-size: clamp(1rem, 0.96rem + 0.2vw, 1.0625rem);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  transition: background-color var(--t), color var(--t);
}

body.nav-open { overflow: hidden; }

img, svg { display: block; max-width: 100%; }
img { height: auto; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
ul, ol { list-style: none; }

h1, h2, h3, h4 {
  line-height: 1.12;
  font-weight: 800;
  letter-spacing: -0.025em;
  text-wrap: balance;
}

p { text-wrap: pretty; }
code, pre { font-family: var(--font-mono); }
strong { font-weight: 700; color: var(--text); }

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 4px;
}

::selection { background: var(--indigo-600); color: #fff; }

.skip-link {
  position: fixed; top: -100px; left: 1rem; z-index: 999;
  background: var(--indigo-700); color: #fff;
  padding: 0.75rem 1.25rem; border-radius: var(--r-sm);
  font-weight: 600; transition: top var(--t-fast);
}
.skip-link:focus { top: 1rem; }

/* ---------- Icons ---------- */
.ico {
  width: 1.15em; height: 1.15em; flex: 0 0 auto;
  fill: none; stroke: currentColor; stroke-width: 1.9;
  stroke-linecap: round; stroke-linejoin: round;
}
/* Vectors that are solid glyphs */
.brand ~ * .ico[fill], .socials .ico, .card__link .ico:only-child { stroke: none; }

/* Solar (Iconify) icons — mask-based, so they inherit font size and
   `currentColor` exactly like a glyph. Registry lives in icons.css. */
.icon {
  display: inline-block;
  flex: 0 0 auto;
  width: 1em;
  height: 1em;
  vertical-align: -0.125em;
  background-color: currentColor;
  -webkit-mask: var(--icon) center / contain no-repeat;
  mask: var(--icon) center / contain no-repeat;
  speak: never;
}
.icon--xs { width: 0.72em; height: 0.72em; vertical-align: -0.05em; }

/* ---------- Layout ---------- */
.container {
  width: 100%; max-width: var(--maxw);
  margin-inline: auto;
  padding-inline: var(--gutter);
}
.container--narrow { max-width: var(--narrow); }

.section {
  position: relative;
  padding-block: var(--sec-y);
}
.section--alt { background: var(--bg-alt); }
.section--alt::before,
.section--alt::after {
  content: ""; position: absolute; inset-inline: 0; height: 1px;
  background: linear-gradient(90deg, transparent, var(--border), transparent);
}
.section--alt::before { top: 0; }
.section--alt::after { bottom: 0; }
.section--band { background: var(--bg-band); }

/* ---------- Background FX ---------- */
.bg-fx {
  position: fixed; inset: 0; z-index: -1;
  pointer-events: none; overflow: hidden;
}
.bg-grid {
  position: absolute; inset: -10%;
  background-image:
    linear-gradient(var(--grid-line) 1px, transparent 1px),
    linear-gradient(90deg, var(--grid-line) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: radial-gradient(ellipse 90% 65% at 50% 0%, #000 20%, transparent 78%);
  -webkit-mask-image: radial-gradient(ellipse 90% 65% at 50% 0%, #000 20%, transparent 78%);
}
.bg-glow {
  position: absolute; border-radius: 50%;
  filter: blur(90px); opacity: 0.5;
  will-change: transform;
}
.bg-glow--1 {
  width: 46vw; height: 46vw; min-width: 340px; min-height: 340px;
  background: radial-gradient(circle, rgba(109, 40, 217, 0.55), transparent 68%);
  top: -14vw; left: -8vw;
}
.bg-glow--2 {
  width: 38vw; height: 38vw; min-width: 280px; min-height: 280px;
  background: radial-gradient(circle, rgba(75, 0, 130, 0.6), transparent 68%);
  top: 26vw; right: -12vw;
}
.bg-glow--3 {
  width: 30vw; height: 30vw; min-width: 240px; min-height: 240px;
  background: radial-gradient(circle, rgba(247, 147, 26, 0.22), transparent 68%);
  bottom: 6vw; left: 16vw;
}
[data-theme="light"] .bg-glow { opacity: 0.3; }
[data-theme="light"] .bg-glow--3 { opacity: 0.22; }

.bg-noise {
  position: absolute; inset: 0; opacity: 0.035;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3'/%3E%3C/filter%3E%3Crect width='140' height='140' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* ---------- Scroll progress ---------- */
.scroll-progress {
  position: fixed; top: 0; left: 0; right: 0; height: 2px;
  z-index: calc(var(--z-header) + 1);
  background: transparent; pointer-events: none;
}
.scroll-progress span {
  display: block; height: 100%; width: 0;
  background: linear-gradient(90deg, var(--indigo-600), var(--indigo-400), var(--btc));
}

/* ---------- Header ---------- */
.site-header {
  position: fixed; top: 0; left: 0; right: 0;
  z-index: var(--z-header);
  padding-block: 0.85rem;
  transition: background-color var(--t), backdrop-filter var(--t),
              border-color var(--t), padding var(--t), box-shadow var(--t);
  border-bottom: 1px solid transparent;
}
.site-header.is-stuck {
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  backdrop-filter: blur(18px) saturate(160%);
  -webkit-backdrop-filter: blur(18px) saturate(160%);
  border-bottom-color: var(--border);
  padding-block: 0.55rem;
  box-shadow: var(--shadow-sm);
}

.header-inner {
  display: flex; align-items: center; gap: 1rem;
  justify-content: space-between;
}

.brand { display: inline-flex; align-items: center; gap: 0.7rem; flex: 0 0 auto; }
.brand__mark {
  width: 38px; height: 38px; border-radius: 9px;
  background: #fff; padding: 3px;
  box-shadow: 0 0 0 1px var(--border), var(--shadow-sm);
  transition: transform var(--t);
  display: flex; align-items: center; justify-content: center;
}
.brand:hover .brand__mark { transform: rotate(-6deg) scale(1.06); }
.brand__name {
  font-weight: 900; letter-spacing: 0.14em; font-size: 1.02rem;
  background: linear-gradient(100deg, var(--text) 20%, var(--accent) 120%);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* Nav */
.nav { display: flex; align-items: center; gap: 1.5rem; }
.nav__list { display: flex; align-items: center; gap: 0.15rem; }

.nav__link {
  position: relative; display: inline-block;
  padding: 0.5rem 0.8rem; border-radius: var(--r-full);
  font-size: 0.9rem; font-weight: 500; color: var(--text-soft);
  transition: color var(--t-fast), background-color var(--t-fast);
}
.nav__link:hover { color: var(--text); background: var(--surface); }
.nav__link.is-current { color: var(--text); font-weight: 600; }
.nav__link.is-current::after {
  content: ""; position: absolute; left: 50%; bottom: 1px;
  transform: translateX(-50%);
  width: 18px; height: 2px; border-radius: 2px;
  background: linear-gradient(90deg, var(--accent), var(--btc));
}

.nav__actions { display: flex; align-items: center; gap: 0.55rem; }

.header-tools { display: flex; align-items: center; gap: 0.5rem; flex: 0 0 auto; }

.theme-toggle, .nav-toggle {
  display: grid; place-items: center;
  width: 40px; height: 40px; flex: 0 0 auto;
  border: 1px solid var(--border); border-radius: var(--r-sm);
  background: var(--surface); color: var(--text-soft);
  cursor: pointer; transition: all var(--t-fast);
}
.theme-toggle:hover, .nav-toggle:hover {
  color: var(--text); border-color: var(--border-strong);
  background: var(--surface-2); transform: translateY(-1px);
}
.theme-toggle .icon { width: 18px; height: 18px; }
[data-theme="dark"] .theme-toggle [data-icon="solar:sun-linear"] { display: none; }
[data-theme="light"] .theme-toggle [data-icon="solar:moon-linear"] { display: none; }

/* ---------- Language switcher ---------- */
.lang-switch { position: relative; }

.lang-switch__btn {
  display: inline-flex; align-items: center; gap: 0.42rem;
  height: 36px; padding: 0 0.7rem;
  border: 1px solid var(--border); border-radius: var(--r-sm);
  background: var(--surface); color: var(--text-soft);
  font-size: 0.83rem; font-weight: 600; cursor: pointer;
  transition: all var(--t-fast);
}
.lang-switch__btn:hover {
  color: var(--text); border-color: var(--border-strong);
  background: var(--surface-2);
}
.lang-switch__btn .icon { width: 15px; height: 15px; }
.lang-switch__code { letter-spacing: 0.02em; min-width: 1.9em; text-align: center; }

.lang-switch__menu {
  position: absolute; top: calc(100% + 0.45rem); right: 0;
  z-index: 20; min-width: 190px;
  padding: 0.35rem;
  border: 1px solid var(--border-strong); border-radius: var(--r-md);
  background: var(--surface-solid);
  box-shadow: var(--shadow-lg);
  animation: fadeUp 0.18s var(--ease-out) both;
}
.lang-switch__menu[hidden] { display: none; }

.lang-switch__opt {
  display: flex; align-items: center; justify-content: space-between;
  gap: 0.75rem; width: 100%;
  padding: 0.58rem 0.7rem;
  border: none; border-radius: var(--r-sm);
  background: transparent; color: var(--text-soft);
  font-size: 0.9rem; font-weight: 500;
  text-align: left; cursor: pointer;
  transition: background-color var(--t-fast), color var(--t-fast);
}
.lang-switch__opt:hover { background: var(--surface-2); color: var(--text); }
.lang-switch__opt[aria-selected="true"] {
  color: var(--text); font-weight: 700;
  background: linear-gradient(120deg, rgba(109, 40, 217, 0.16), rgba(247, 147, 26, 0.08));
}
.lang-switch__opt[aria-selected="true"]::before {
  content: ""; width: 6px; height: 6px; border-radius: 50%;
  background: var(--accent); margin-right: -0.35rem;
}
.lang-switch__native { flex: 1 1 auto; }
.lang-switch__tag {
  font-family: var(--font-mono); font-size: 0.7rem;
  letter-spacing: 0.06em; color: var(--text-mute);
}

.nav-toggle { display: none; }
.nav-toggle__bars { display: grid; gap: 4px; width: 18px; }
.nav-toggle__bars i {
  display: block; height: 2px; border-radius: 2px;
  background: currentColor; transition: transform var(--t), opacity var(--t-fast);
}
.nav-toggle[aria-expanded="true"] .nav-toggle__bars i:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] .nav-toggle__bars i:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] .nav-toggle__bars i:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

/* ---------- Buttons ---------- */
.btn {
  --btn-bg: transparent;
  position: relative; display: inline-flex; align-items: center; justify-content: center;
  gap: 0.5rem; padding: 0.72rem 1.35rem;
  border-radius: var(--r-full); border: 1px solid transparent;
  font-weight: 600; font-size: 0.94rem; letter-spacing: -0.01em;
  cursor: pointer; white-space: nowrap;
  transition: transform var(--t-fast), box-shadow var(--t), background-color var(--t-fast),
              border-color var(--t-fast), color var(--t-fast);
}
.btn:active { transform: translateY(1px) scale(0.99); }
.btn--sm { padding: 0.55rem 1rem; font-size: 0.86rem; }
.btn--lg { padding: 0.92rem 1.8rem; font-size: 1rem; }

.btn--primary {
  background: linear-gradient(120deg, var(--indigo-600), var(--indigo-400));
  color: #fff;
  box-shadow: 0 8px 24px rgba(109, 40, 217, 0.35);
}
.btn--primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 14px 34px rgba(109, 40, 217, 0.48);
}
[data-theme="light"] .btn--primary {
  background: linear-gradient(120deg, var(--indigo-700), var(--indigo-500));
}

.btn--outline {
  border-color: var(--border-strong); color: var(--text);
  background: var(--surface);
}
.btn--outline:hover {
  border-color: var(--accent); color: var(--accent);
  background: var(--surface-2); transform: translateY(-2px);
}

.btn--ghost { color: var(--text-soft); }
.btn--ghost:hover { color: var(--text); background: var(--surface); }

/* ---------- Hero ---------- */
.hero { position: relative; padding-top: clamp(7rem, 15vw, 10.5rem); padding-bottom: 0; }

/* The orbiting chips sweep past the hero's right edge on mid-size
   viewports (the orb is ~420px wide inside a grid column that is
   narrower between ~740px and ~1100px). Clipping the decorative
   visual here keeps the chips from widening the document and
   producing a horizontal scrollbar; the chips simply fade out at the
   edge instead. Scoped to the visual so nothing else is affected. */
.hero__visual { overflow: hidden; }

.hero__grid {
  display: grid; gap: clamp(2.5rem, 6vw, 4rem);
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
  align-items: center;
  padding-bottom: clamp(3rem, 7vw, 5.5rem);
}

.badge {
  display: inline-flex; align-items: center; gap: 0.55rem;
  padding: 0.42rem 0.95rem 0.42rem 0.7rem;
  border: 1px solid var(--border); border-radius: var(--r-full);
  background: var(--surface);
  font-size: 0.8rem; font-weight: 500; color: var(--text-soft);
  letter-spacing: 0.01em; margin-bottom: 1.5rem;
}
.badge__dot {
  width: 7px; height: 7px; border-radius: 50%;
  background: var(--btc); box-shadow: 0 0 0 0 rgba(247, 147, 26, 0.6);
  animation: pulse 2.2s var(--ease) infinite;
}
@keyframes pulse {
  0%   { box-shadow: 0 0 0 0 rgba(247, 147, 26, 0.55); }
  70%  { box-shadow: 0 0 0 9px rgba(247, 147, 26, 0); }
  100% { box-shadow: 0 0 0 0 rgba(247, 147, 26, 0); }
}

.hero__title {
  font-size: clamp(2.5rem, 1.5rem + 4.6vw, 4.6rem);
  font-weight: 900; letter-spacing: -0.04em; line-height: 1.04;
  margin-bottom: 1.4rem;
}
.grad {
  background: linear-gradient(100deg, var(--indigo-400) 0%, var(--indigo-600) 45%, var(--btc) 105%);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent;
}
[data-theme="light"] .grad {
  background: linear-gradient(100deg, var(--indigo-700) 0%, var(--indigo-500) 50%, var(--btc) 105%);
  -webkit-background-clip: text; background-clip: text;
}

.hero__lede {
  font-size: clamp(1.02rem, 0.97rem + 0.35vw, 1.2rem);
  color: var(--text-soft); max-width: 56ch; margin-bottom: 2.2rem;
}
.hero__lede strong { color: var(--text); }

.hero__cta { display: flex; flex-wrap: wrap; gap: 0.85rem; margin-bottom: 3rem; }

.hero__stats {
  display: grid; grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1.25rem;
  padding-top: 1.9rem; border-top: 1px solid var(--border);
}
.stat__value {
  font-size: clamp(1.35rem, 1.15rem + 0.9vw, 1.85rem);
  font-weight: 800; letter-spacing: -0.03em;
  font-variant-numeric: tabular-nums;
  background: linear-gradient(120deg, var(--text), var(--accent));
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent;
}
.stat__value--sm { font-size: clamp(1rem, 0.9rem + 0.5vw, 1.2rem); }
.stat__label {
  font-size: 0.76rem; text-transform: uppercase;
  letter-spacing: 0.09em; color: var(--text-mute); font-weight: 600;
  margin-bottom: 0.2rem;
}

/* Hero visual — CSS orbit */
.hero__visual { position: relative; display: grid; place-items: center; min-height: 380px; }
.orb {
  position: relative; width: min(100%, 420px); aspect-ratio: 1;
  display: grid; place-items: center;
}
.orb__core {
  position: relative; z-index: 3;
  width: 40%; aspect-ratio: 1; border-radius: 50%;
  background: radial-gradient(circle at 32% 28%, #fff, #ece7f7 70%);
  display: grid; place-items: center;
  box-shadow: var(--glow), inset 0 0 0 1px var(--border);
  animation: float 7s var(--ease) infinite;
}
.orb__core img { width: 62%; height: 62%; object-fit: contain; border-radius: 50%; }
@keyframes float {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(-14px); }
}

.orb__ring {
  position: absolute; border-radius: 50%;
  border: 1px dashed var(--border-strong);
}
.orb__ring--outer { inset: 0; animation: spin 44s linear infinite; }
.orb__ring--inner { inset: 17%; border-style: solid; border-color: var(--border); animation: spin 30s linear infinite reverse; }
@keyframes spin { to { transform: rotate(360deg); } }

.chip {
  position: absolute; white-space: nowrap;
  display: inline-flex; align-items: center; gap: 0.35rem;
  padding: 0.4rem 0.8rem; border-radius: var(--r-full);
  background: color-mix(in srgb, var(--surface-solid) 88%, transparent);
  border: 1px solid var(--border-strong);
  font-size: 0.76rem; font-weight: 600; color: var(--text);
  box-shadow: var(--shadow-md);
  backdrop-filter: blur(8px);
  animation: spin 44s linear infinite reverse;
}
.chip .icon { width: 13px; height: 13px; color: var(--accent); }
.orb__ring--inner .chip { animation: spin 30s linear infinite; }

.chip--1 { top: -13px; left: 50%; translate: -50% 0; }
.chip--2 { top: 50%; right: -18px; translate: 0 -50%; }
.chip--3 { bottom: -13px; left: 50%; translate: -50% 0; }
.chip--4 { top: 50%; left: -18px; translate: 0 -50%; }
.chip--5 { top: -11px; left: 50%; translate: -50% 0; }
.chip--6 { bottom: -11px; left: 50%; translate: -50% 0; }

.orb__platform {
  position: absolute; bottom: 2%; left: 50%; translate: -50% 0;
  width: 62%; height: 42px; border-radius: 50%;
  background: radial-gradient(ellipse, rgba(109, 40, 217, 0.4), transparent 70%);
  filter: blur(14px);
}

/* ---------- Marquee ---------- */
.marquee {
  position: relative; overflow: hidden;
  border-top: 1px solid var(--border); border-bottom: 1px solid var(--border);
  background: var(--bg-alt);
  padding-block: 1.05rem;
  mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
}
.marquee__track {
  display: flex; align-items: center; gap: 2rem;
  width: max-content;
  animation: marquee 46s linear infinite;
}
.marquee:hover .marquee__track { animation-play-state: paused; }
@keyframes marquee { to { transform: translateX(-50%); } }
.marquee__item {
  font-size: 0.86rem; font-weight: 600; letter-spacing: 0.05em;
  color: var(--text-soft); text-transform: uppercase; white-space: nowrap;
}
.marquee__sep { color: var(--accent); font-size: 0.55rem; opacity: 0.7; }

/* ---------- Section head ---------- */
.section__head {
  max-width: 720px; margin-bottom: clamp(2.5rem, 5vw, 4rem);
}
.eyebrow {
  display: inline-block;
  font-size: 0.78rem; font-weight: 700; text-transform: uppercase;
  letter-spacing: 0.16em; color: var(--accent); margin-bottom: 0.85rem;
}
.section__title {
  font-size: clamp(1.85rem, 1.3rem + 2.4vw, 3.1rem);
  margin-bottom: 1rem;
}
.section__lede { color: var(--text-soft); font-size: 1.05rem; max-width: 62ch; }

/* ---------- Pillars ---------- */
.pillars {
  display: grid; gap: 1.25rem;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}
.pillar {
  position: relative; padding: 1.9rem 1.6rem;
  border: 1px solid var(--border); border-radius: var(--r-lg);
  background: var(--surface);
  overflow: hidden;
  transition: transform var(--t), border-color var(--t), background-color var(--t), box-shadow var(--t);
}
.pillar::before {
  content: ""; position: absolute; inset: 0 0 auto 0; height: 2px;
  background: linear-gradient(90deg, var(--accent), var(--btc));
  transform: scaleX(0); transform-origin: left;
  transition: transform var(--t);
}
.pillar:hover {
  transform: translateY(-5px);
  border-color: var(--border-strong);
  background: var(--surface-2);
  box-shadow: var(--shadow-md);
}
.pillar:hover::before { transform: scaleX(1); }
.pillar__icon {
  display: grid; place-items: center;
  width: 46px; height: 46px; margin-bottom: 1.1rem;
  border-radius: 13px;
  background: linear-gradient(135deg, rgba(109, 40, 217, 0.24), rgba(247, 147, 26, 0.16));
  border: 1px solid var(--border-strong);
  color: var(--accent);
}
.pillar__icon .icon { width: 22px; height: 22px; }
.pillar__title { font-size: 1.18rem; margin-bottom: 0.55rem; }
.pillar__text { color: var(--text-soft); font-size: 0.95rem; }

/* ---------- Product cards ---------- */
.cards {
  display: grid; gap: 1.35rem;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
}
.card {
  position: relative; display: flex; flex-direction: column;
  padding: 1.75rem 1.6rem; border: 1px solid var(--border);
  border-radius: var(--r-lg); background: var(--surface);
  transition: transform var(--t), border-color var(--t), box-shadow var(--t), background-color var(--t);
}
.card:hover {
  transform: translateY(-6px);
  border-color: var(--border-strong);
  background: var(--surface-2);
  box-shadow: var(--shadow-lg);
}
.card__top {
  display: flex; align-items: center; justify-content: space-between;
  gap: 1rem; margin-bottom: 1.1rem;
}
.card__badge {
  padding: 0.25rem 0.7rem; border-radius: var(--r-full);
  background: var(--surface-2); border: 1px solid var(--border);
  font-size: 0.7rem; font-weight: 700; text-transform: uppercase;
  letter-spacing: 0.1em; color: var(--text-soft);
}
.card__badge--accent {
  background: linear-gradient(120deg, rgba(109, 40, 217, 0.3), rgba(247, 147, 26, 0.22));
  color: var(--text); border-color: var(--border-strong);
}
.card__ver { font-family: var(--font-mono); font-size: 0.76rem; color: var(--text-mute); }
.card__title { font-size: 1.28rem; margin-bottom: 0.7rem; }
.card__text { color: var(--text-soft); font-size: 0.94rem; margin-bottom: 1.2rem; }

.chips { display: flex; flex-wrap: wrap; gap: 0.4rem; margin-bottom: 1.35rem; }
.chips li {
  padding: 0.22rem 0.62rem; border-radius: var(--r-full);
  background: var(--surface-2); border: 1px solid var(--border);
  font-size: 0.72rem; font-weight: 500; color: var(--text-soft);
}

.card__link {
  margin-top: auto; display: inline-flex; align-items: center; gap: 0.4rem;
  font-weight: 600; font-size: 0.9rem; color: var(--accent);
  transition: gap var(--t-fast);
}
.card__link:hover { gap: 0.7rem; }
.card__link .icon { width: 15px; height: 15px; color: var(--accent); }

/* Also in the lab */
.also {
  margin-top: 2.5rem; padding: 1.5rem 1.75rem;
  border: 1px dashed var(--border-strong); border-radius: var(--r-lg);
  background: var(--surface);
}
.also__label {
  display: block; font-size: 0.74rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: 0.14em;
  color: var(--text-mute); margin-bottom: 0.9rem;
}
.also__list {
  display: grid; gap: 0.6rem 2rem;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}
.also__list li { color: var(--text-soft); font-size: 0.9rem; }

/* ---------- Nostr tabs ---------- */
.nostr {
  border: 1px solid var(--border); border-radius: var(--r-xl);
  background: var(--surface); overflow: hidden;
}
.nostr__tabs {
  display: flex; gap: 0.35rem; overflow-x: auto;
  padding: 0.75rem 0.75rem 0;
  border-bottom: 1px solid var(--border);
  scrollbar-width: none;
}
.nostr__tabs::-webkit-scrollbar { display: none; }
.tab {
  flex: 0 0 auto; padding: 0.62rem 1.15rem;
  border: none; background: transparent; cursor: pointer;
  border-radius: var(--r-sm) var(--r-sm) 0 0;
  font-weight: 600; font-size: 0.9rem; color: var(--text-mute);
  position: relative; transition: color var(--t-fast), background-color var(--t-fast);
}
.tab:hover { color: var(--text); background: var(--surface); }
.tab.is-active { color: var(--text); }
.tab.is-active::after {
  content: ""; position: absolute; left: 0.75rem; right: 0.75rem; bottom: -1px;
  height: 2px; border-radius: 2px;
  background: linear-gradient(90deg, var(--accent), var(--btc));
}

.nostr__panels { position: relative; }
.panel {
  display: grid; gap: 2rem;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  padding: clamp(1.5rem, 3.5vw, 2.5rem);
  animation: fadeUp 0.4s var(--ease-out) both;
}
.panel[hidden] { display: none; }
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: none; }
}
.panel__body h3 { font-size: 1.3rem; margin-bottom: 0.8rem; }
.panel__body p { color: var(--text-soft); font-size: 0.95rem; margin-bottom: 1.15rem; }
.panel__body em { color: var(--accent); font-style: normal; font-weight: 600; }

.ticks { display: grid; gap: 0.55rem; }
.ticks li {
  position: relative; padding-left: 1.6rem;
  font-size: 0.9rem; color: var(--text-soft);
}
.ticks li::before {
  content: ""; position: absolute; left: 0; top: 0.52em;
  width: 15px; height: 9px;
  border-left: 2px solid var(--accent);
  border-bottom: 2px solid var(--accent);
  transform: rotate(-45deg);
}
.ticks code {
  font-size: 0.82rem; padding: 0.08em 0.4em;
  background: var(--surface-2); border-radius: 5px; color: var(--text);
}

.panel__code, .snippet {
  border: 1px solid var(--border); border-radius: var(--r-md);
  background: var(--code-bg); overflow: hidden;
  align-self: start; box-shadow: var(--shadow-md);
}
.code__head {
  display: flex; align-items: center; justify-content: space-between;
  gap: 1rem; padding: 0.6rem 0.95rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.03);
}
.code__head span {
  font-family: var(--font-mono); font-size: 0.75rem;
  color: #a89ec4; letter-spacing: 0.04em;
}
.copy {
  padding: 0.22rem 0.7rem; border-radius: var(--r-full);
  border: 1px solid rgba(255, 255, 255, 0.16);
  background: rgba(255, 255, 255, 0.06);
  color: #cfc7e4; font-size: 0.72rem; font-weight: 600;
  cursor: pointer; transition: all var(--t-fast);
}
.copy:hover { background: rgba(255, 255, 255, 0.14); color: #fff; }
.copy.is-done { background: rgba(247, 147, 26, 0.22); color: var(--btc-soft); border-color: rgba(247, 147, 26, 0.5); }

.panel__code pre, .snippet pre {
  margin: 0; padding: 1.05rem 1.15rem; overflow-x: auto;
  font-size: 0.82rem; line-height: 1.75; color: #d9d3ec;
  white-space: pre;
}
.panel__code code, .snippet code { font-family: var(--font-mono); }
.panel__code em { color: var(--btc-soft); font-style: normal; }

/* ---------- Impact band ---------- */
.impact {
  display: grid; gap: 1.25rem;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  text-align: center;
}
.impact__item {
  padding: 1.6rem 1rem;
  border: 1px solid var(--border); border-radius: var(--r-lg);
  background: var(--surface);
  transition: transform var(--t-fast), border-color var(--t-fast);
}
.impact__item:hover { transform: translateY(-3px); border-color: var(--border-strong); }
.impact__num {
  display: block;
  font-size: clamp(2rem, 1.4rem + 2.4vw, 3rem);
  font-weight: 900; letter-spacing: -0.04em;
  font-variant-numeric: tabular-nums;
  background: linear-gradient(120deg, var(--accent), var(--btc));
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent;
  line-height: 1.1; margin-bottom: 0.35rem;
}
.impact__label {
  font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.1em;
  color: var(--text-mute); font-weight: 600;
}

/* ---------- Contribute ---------- */
.contribute {
  display: grid; gap: 1.5rem;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  align-items: start;
}
.repo-list { display: grid; gap: 0.6rem; }
.repo {
  display: flex; align-items: center; gap: 1rem;
  padding: 0.95rem 1.15rem;
  border: 1px solid var(--border); border-radius: var(--r-md);
  background: var(--surface);
  transition: all var(--t-fast);
}
.repo:hover {
  border-color: var(--accent); background: var(--surface-2);
  transform: translateX(4px);
}
.repo__name { font-weight: 700; font-size: 0.96rem; flex: 0 0 auto; }
.repo__meta {
  display: inline-flex; align-items: center; gap: 0.5rem;
  font-size: 0.82rem; color: var(--text-mute); margin-left: auto;
}
.repo__arrow { width: 15px; height: 15px; color: var(--text-mute); transition: color var(--t-fast), transform var(--t-fast); }
.repo:hover .repo__arrow { color: var(--accent); transform: translate(2px, -2px); }

.also__ico { width: 16px; height: 16px; color: var(--accent); margin-right: 0.55rem; }
.also__list li { display: flex; align-items: center; }

.lang { display: inline-flex; align-items: center; gap: 0.35rem; font-weight: 600; color: var(--text-soft); }
.lang::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: currentColor; }
.lang--svelte { color: #ff3e00; }
.lang--kotlin { color: #a97bff; }
.lang--vue { color: #42b883; }
.lang--ts { color: #3178c6; }

.steps {
  padding: 1.75rem; border: 1px solid var(--border);
  border-radius: var(--r-lg); background: var(--surface);
}
.steps__title { font-size: 1.15rem; margin-bottom: 1.2rem; }
.steps__list { display: grid; gap: 0.9rem; margin-bottom: 1.6rem; }
.steps__list li { display: flex; align-items: flex-start; gap: 0.85rem; font-size: 0.92rem; color: var(--text-soft); }
.steps__n {
  display: grid; place-items: center; flex: 0 0 auto;
  width: 26px; height: 26px; border-radius: 50%;
  background: linear-gradient(120deg, var(--indigo-600), var(--indigo-400));
  color: #fff; font-size: 0.78rem; font-weight: 700;
}
.steps__list code {
  font-size: 0.82rem; padding: 0.1em 0.42em;
  background: var(--surface-2); border-radius: 5px; color: var(--text);
}
.snippet pre { font-size: 0.8rem; }

/* CTA strip */
.cta-strip {
  margin-top: 2.5rem; padding: 1.75rem 2rem;
  border: 1px solid var(--border-strong); border-radius: var(--r-lg);
  background: linear-gradient(120deg, rgba(109, 40, 217, 0.14), rgba(247, 147, 26, 0.09));
  display: flex; flex-wrap: wrap; align-items: center;
  justify-content: space-between; gap: 1.5rem;
}
.cta-strip h3 { font-size: 1.28rem; margin-bottom: 0.3rem; }
.cta-strip p { color: var(--text-soft); font-size: 0.93rem; }
.cta-strip__actions { display: flex; flex-wrap: wrap; gap: 0.7rem; }

/* ---------- Timeline ---------- */
.timeline { position: relative; display: grid; gap: 1.1rem; padding-left: 2rem; }
.timeline::before {
  content: ""; position: absolute; left: 7px; top: 8px; bottom: 8px;
  width: 2px; border-radius: 2px;
  background: linear-gradient(180deg, var(--accent), var(--btc), transparent);
}
.tl { position: relative; }
.tl__dot {
  position: absolute; left: -2rem; top: 1.6rem;
  width: 16px; height: 16px; border-radius: 50%;
  background: var(--bg-alt); border: 2px solid var(--border-strong);
  transform: translateX(1px);
}
.tl__dot--done { background: var(--accent); border-color: var(--accent); box-shadow: 0 0 0 4px rgba(109, 40, 217, 0.22); }
.tl__dot--active { background: var(--btc); border-color: var(--btc); box-shadow: 0 0 0 4px rgba(247, 147, 26, 0.22); animation: pulse 2.4s infinite; }
.tl__card {
  padding: 1.4rem 1.6rem; border: 1px solid var(--border);
  border-radius: var(--r-md); background: var(--surface);
  transition: transform var(--t-fast), border-color var(--t-fast);
}
.tl__card:hover { transform: translateX(5px); border-color: var(--border-strong); }
.tl__phase {
  font-family: var(--font-mono); font-size: 0.74rem; font-weight: 600;
  letter-spacing: 0.08em; text-transform: uppercase; color: var(--accent);
}
.tl__card h3 { font-size: 1.1rem; margin: 0.35rem 0 0.45rem; }
.tl__card p { color: var(--text-soft); font-size: 0.9rem; margin-bottom: 0.85rem; }

.status {
  display: inline-block; padding: 0.2rem 0.68rem;
  border-radius: var(--r-full); font-size: 0.72rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: 0.08em;
  border: 1px solid var(--border-strong); color: var(--text-soft);
  background: var(--surface-2);
}
.status--done { color: #6ee7b7; border-color: rgba(110, 231, 183, 0.35); background: rgba(110, 231, 183, 0.1); }
.status--active { color: var(--btc-soft); border-color: rgba(247, 147, 26, 0.4); background: rgba(247, 147, 26, 0.12); }
[data-theme="light"] .status--done { color: #047857; }
[data-theme="light"] .status--active { color: #b45309; }

/* ---------- FAQ ---------- */
.faq { display: grid; gap: 0.7rem; }
.faq__item {
  border: 1px solid var(--border); border-radius: var(--r-md);
  background: var(--surface); overflow: hidden;
  transition: border-color var(--t-fast), background-color var(--t-fast);
}
.faq__item:hover { border-color: var(--border-strong); }
.faq__item[open] { background: var(--surface-2); border-color: var(--border-strong); }
.faq__q {
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
  padding: 1.1rem 1.35rem; cursor: pointer;
  font-weight: 600; font-size: 1rem; color: var(--text);
  list-style: none; transition: color var(--t-fast);
}
.faq__q::-webkit-details-marker { display: none; }
.faq__chev { width: 17px; height: 17px; color: var(--text-mute); transition: transform var(--t), color var(--t-fast); }
.faq__item[open] .faq__chev { transform: rotate(180deg); color: var(--accent); }
.faq__a { padding: 0 1.35rem 1.25rem; animation: fadeUp 0.3s var(--ease-out) both; }
.faq__a p { color: var(--text-soft); font-size: 0.94rem; }
.faq__a a { color: var(--accent); font-weight: 600; text-decoration: underline; text-underline-offset: 3px; }

/* ---------- Final CTA ---------- */
.final { padding-bottom: clamp(4rem, 9vw, 7rem); }
.final__card {
  position: relative; overflow: hidden; text-align: center;
  padding: clamp(3rem, 7vw, 5rem) clamp(1.5rem, 5vw, 4rem);
  border: 1px solid var(--border-strong); border-radius: var(--r-xl);
  background: var(--bg-alt);
  box-shadow: var(--shadow-lg);
}
.final__glow {
  position: absolute; top: -55%; left: 50%; translate: -50% 0;
  width: 130%; aspect-ratio: 2/1; border-radius: 50%;
  background: radial-gradient(ellipse, rgba(109, 40, 217, 0.4), transparent 66%);
  filter: blur(50px); pointer-events: none;
}
.final__title { position: relative; font-size: clamp(1.9rem, 1.3rem + 2.6vw, 3.1rem); margin-bottom: 1.1rem; }
.final__text { position: relative; color: var(--text-soft); max-width: 56ch; margin: 0 auto 2.2rem; font-size: 1.05rem; }
.final__actions { position: relative; display: flex; flex-wrap: wrap; gap: 0.85rem; justify-content: center; }

/* ---------- Footer ---------- */
.footer {
  border-top: 1px solid var(--border);
  background: var(--bg-alt);
  padding-top: clamp(3rem, 6vw, 4.5rem);
}
.footer__grid {
  display: grid; gap: 2.5rem;
  grid-template-columns: minmax(0, 1.7fr) repeat(3, minmax(0, 1fr));
  padding-bottom: 3rem;
}
.footer__brand .brand { margin-bottom: 1rem; }
.footer__tag { color: var(--text-soft); font-size: 0.9rem; max-width: 42ch; margin-bottom: 1.4rem; }

.socials { display: flex; gap: 0.5rem; }
.socials a {
  display: grid; place-items: center;
  width: 40px; height: 40px; border-radius: var(--r-sm);
  border: 1px solid var(--border); background: var(--surface);
  color: var(--text-soft);
  transition: all var(--t-fast);
}
.socials a:hover {
  color: #fff; border-color: transparent;
  background: linear-gradient(120deg, var(--indigo-600), var(--indigo-400));
  transform: translateY(-3px);
}
.socials .ico { width: 18px; height: 18px; stroke: none; fill: currentColor; }

.footer__col h4 {
  font-size: 0.78rem; text-transform: uppercase;
  letter-spacing: 0.14em; color: var(--text-mute);
  margin-bottom: 1.1rem; font-weight: 700;
}
.footer__col ul { display: grid; gap: 0.65rem; }
.footer__col a {
  font-size: 0.9rem; color: var(--text-soft);
  transition: color var(--t-fast), padding-left var(--t-fast);
}
.footer__col a:hover { color: var(--accent); padding-left: 4px; }

.footer__bottom {
  display: flex; flex-wrap: wrap; gap: 0.75rem;
  align-items: center; justify-content: space-between;
  padding-block: 1.5rem;
  border-top: 1px solid var(--border);
  font-size: 0.83rem; color: var(--text-mute);
}
.footer__proto { display: inline-flex; align-items: center; gap: 0.35rem; }
.dot-purple, .dot-orange {
  display: inline-block; width: 8px; height: 8px; border-radius: 50%;
}
.dot-purple { background: var(--indigo-400); }
.dot-orange { background: var(--btc); }

/* ---------- To top / toast ---------- */
.to-top {
  position: fixed; right: clamp(1rem, 3vw, 1.75rem); bottom: clamp(1rem, 3vw, 1.75rem);
  z-index: var(--z-toast);
  display: grid; place-items: center;
  width: 46px; height: 46px; border-radius: var(--r-md);
  border: 1px solid var(--border-strong);
  background: color-mix(in srgb, var(--surface-solid) 88%, transparent);
  backdrop-filter: blur(12px);
  color: var(--text); cursor: pointer;
  box-shadow: var(--shadow-md);
  transition: transform var(--t-fast), background-color var(--t-fast), opacity var(--t);
}
.to-top:hover {
  transform: translateY(-4px);
  background: linear-gradient(120deg, var(--indigo-600), var(--indigo-400));
  color: #fff; border-color: transparent;
}
.to-top[hidden] { display: none; }
.to-top .icon { width: 19px; height: 19px; }

.toast {
  position: fixed; left: 50%; bottom: 2rem; translate: -50% 0;
  z-index: var(--z-toast);
  padding: 0.75rem 1.4rem; border-radius: var(--r-full);
  background: var(--surface-solid); color: var(--text);
  border: 1px solid var(--border-strong);
  box-shadow: var(--shadow-lg);
  font-size: 0.88rem; font-weight: 600;
  animation: toastIn 0.3s var(--ease-out) both;
}
.toast[hidden] { display: none; }
@keyframes toastIn {
  from { opacity: 0; transform: translateY(14px); }
  to   { opacity: 1; transform: none; }
}

/* ---------- Reveal ---------- */
.reveal { opacity: 0; transform: translateY(22px); }
.reveal.is-visible {
  opacity: 1; transform: none;
  transition: opacity 0.7s var(--ease-out), transform 0.7s var(--ease-out);
  transition-delay: var(--reveal-delay, 0ms);
}

/* ============================================================
   Responsive
   ============================================================ */

/* Tablet */
@media (max-width: 1040px) {
  .footer__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .footer__brand { grid-column: 1 / -1; }
}

@media (max-width: 960px) {
  .hero__grid { grid-template-columns: 1fr; }
  .hero__visual { order: -1; min-height: 320px; }
  .orb { width: min(88%, 360px); }
  .hero__stats { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.5rem 1rem; }
  .panel { grid-template-columns: 1fr; gap: 1.5rem; }
  .contribute { grid-template-columns: 1fr; }
}

/* Mobile nav */
@media (max-width: 880px) {
  .nav-toggle { display: grid; }

  .nav {
    position: fixed; inset: 0;
    flex-direction: column; align-items: stretch; justify-content: flex-start;
    gap: 0;
    padding: 5.5rem var(--gutter) 2rem;
    background: color-mix(in srgb, var(--bg) 96%, transparent);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    opacity: 0; visibility: hidden; transform: translateY(-12px);
    transition: opacity var(--t), transform var(--t), visibility var(--t);
    overflow-y: auto;
  }
  .nav.is-open { opacity: 1; visibility: visible; transform: none; }

  .nav__list {
    flex-direction: column; align-items: stretch; gap: 0.25rem;
    width: 100%; padding-bottom: 1.5rem;
    border-bottom: 1px solid var(--border);
  }
  .nav__link {
    display: block; padding: 0.95rem 1rem;
    font-size: 1.15rem; font-weight: 600; border-radius: var(--r-md);
  }
  .nav__link.is-current::after { display: none; }

  .nav__actions { padding-top: 1.5rem; flex-direction: column; align-items: stretch; }
  .nav__actions .btn { width: 100%; padding-block: 0.85rem; font-size: 0.95rem; }
}

/* Small tablet / large phone */
@media (max-width: 700px) {
  :root { --gutter: 1.25rem; }

  .hero { padding-top: 6rem; }
  .hero__stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .hero__cta { flex-direction: column; align-items: stretch; }
  .hero__cta .btn { width: 100%; }

  .chip { font-size: 0.68rem; padding: 0.32rem 0.65rem; }

  .cta-strip { flex-direction: column; align-items: stretch; text-align: center; }
  .cta-strip__actions { flex-direction: column; }
  .cta-strip__actions .btn { width: 100%; }

  .final__actions { flex-direction: column; align-items: stretch; }
  .final__actions .btn { width: 100%; }

  .also__list { grid-template-columns: 1fr; }
  .repo__meta { display: none; }
  .timeline { padding-left: 1.75rem; }
  .tl__dot { left: -1.75rem; }
}

/* Phone */
@media (max-width: 480px) {
  :root { --gutter: 1.1rem; --radius: 14px; }

  .brand__name { font-size: 0.92rem; letter-spacing: 0.1em; }
  .hero__title { letter-spacing: -0.03em; }
  .hero__stats { gap: 1.25rem 0.75rem; }
  .stat__label { font-size: 0.68rem; }
  .orb { width: 100%; }
  .orb__core { width: 46%; }
  /* Pull orbit chips inward so they are not clipped at the viewport edge */
  .chip--1, .chip--3 { top: -8px; }
  .chip--2 { right: -6px; }
  .chip--4 { left: -6px; }
  .chip--5 { top: -7px; }
  .chip--6 { bottom: -7px; }
  .panel, .card, .pillar, .steps { padding: 1.4rem 1.2rem; }
  .footer__grid { grid-template-columns: 1fr; gap: 2rem; }
  .footer__bottom { flex-direction: column; text-align: center; }
  .to-top { width: 42px; height: 42px; }
}

/* Landscape phones */
@media (max-height: 480px) and (orientation: landscape) {
  .hero { padding-top: 5.5rem; }
  .nav { padding-top: 4.5rem; }
}

/* ---------- Motion & print ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
  .reveal { opacity: 1; transform: none; }
  .marquee__track { animation: none; }
}

@media print {
  .site-header, .bg-fx, .marquee, .to-top, .scroll-progress, .final__glow { display: none !important; }
  body { background: #fff; color: #000; }
  .reveal { opacity: 1; transform: none; }
  .section { padding-block: 2rem; break-inside: avoid; }
}

/* ============================================================
   Lao (Lao script) typography
   ------------------------------------------------------------
   Deliberately last in the file. Several component rules below use
   single-class selectors (e.g. `.hero__lede strong`) that tie with
   `:lang(lo) strong` on specificity, so source order decides — and
   the Lao overrides must win.

   Chanthavong (MTS Lao's own typeface) is the primary Lao face. It
   ships a single 400 weight, which drives two decisions:
     · headings are set to 400 instead of 700–900, and
     · font-synthesis is disabled, because the browser's faked bold
       smears Lao's stacked vowels and tone marks into the base glyph.
   Hierarchy is carried by size and colour rather than weight.

   Lao also stacks marks above and below the baseline, so leading is
   looser and letter-spacing is reset — tracking detaches combining
   marks from the character they belong to.
   ============================================================ */
:lang(lo) {
  font-family: var(--font-lao), var(--font-sans);
  line-height: 1.9;
  font-synthesis: none;
}

/* Chanthavong has no bold, so every element that would be bold is
   reset to 400 rather than left to the browser's synthetic bold. */
:lang(lo) h1, :lang(lo) h2, :lang(lo) h3, :lang(lo) h4,
:lang(lo) strong, :lang(lo) b,
:lang(lo) .eyebrow, :lang(lo) .badge, :lang(lo) .card__badge,
:lang(lo) .status, :lang(lo) .impact__label, :lang(lo) .stat__label,
:lang(lo) .tl__phase, :lang(lo) .faq__q, :lang(lo) .steps__n,
:lang(lo) .also__label, :lang(lo) .marquee__item, :lang(lo) .chip,
:lang(lo) .btn, :lang(lo) .nav__link, :lang(lo) .repo__name,
:lang(lo) .lang-switch__btn, :lang(lo) .lang-switch__opt,
:lang(lo) .card__title, :lang(lo) .pillar__title, :lang(lo) .steps__title,
:lang(lo) .cta-strip h3, :lang(lo) .final__title, :lang(lo) .footer__col h4,
:lang(lo) .stat__value, :lang(lo) .impact__num, :lang(lo) .brand__name {
  font-weight: 400;
}

:lang(lo) h1, :lang(lo) h2, :lang(lo) h3, :lang(lo) h4 {
  line-height: 1.6;
  letter-spacing: 0;
}
:lang(lo) .hero__title { line-height: 1.42; letter-spacing: 0; }
:lang(lo) .section__title { line-height: 1.5; }

:lang(lo) .badge,
:lang(lo) .eyebrow,
:lang(lo) .stat__label,
:lang(lo) .card__badge,
:lang(lo) .impact__label,
:lang(lo) .status,
:lang(lo) .footer__col h4 {
  letter-spacing: 0.02em;
}

/* Emphasis without weight: <strong> takes the accent colour instead.
   Must come after `.hero__lede strong` and the global `strong` rule. */
:lang(lo) strong, :lang(lo) b { color: var(--accent); }

/* Latin-only runs keep the Latin faces so mixed lines stay even. */
:lang(lo) code, :lang(lo) pre, :lang(lo) .lang-switch__tag,
:lang(lo) .card__ver, :lang(lo) .repo__name {
  font-family: var(--font-mono);
  line-height: 1.7;
}
:lang(lo) .brand__name, :lang(lo) .stat__value, :lang(lo) .impact__num {
  font-family: var(--font-sans);
}
