/* ============================================================
   Belmo — Homepage v3 (Figma redesign, 2026-08)
   Light theme · DM Sans · blue #2563EB · teal #10A699
   Used by index.html only — other pages keep styles-refresh.css
   ============================================================ */

:root {
  --ink: #15181E;
  --body: #56575F;
  --muted: #6B7280;
  --faint: #9AA3B5;
  --border: #E3EAF5;
  --border-soft: #ECECEC;
  --blue: #2563EB;
  --blue-deep: #1E40AF;
  --blue-tint: #E5EDFB;
  --teal: #10A699;
  --green: #16A34A;
  --amber: #D97706;
  --red: #DC2626;
  --bg: #FFFFFF;
  --bg-soft: #F5F8FD;
  --bg-band: #EFF4FB;
  --tile-line: #E8EEF7;
  --footer-bg: #15181E;
  --footer-deep: #10131A;

  --font-display: "DM Sans", system-ui, sans-serif;
  --font-body: "DM Sans", system-ui, sans-serif;
  --font-ui: "Geist", system-ui, sans-serif;
  --font-mono: "Geist Mono", ui-monospace, "SF Mono", monospace;

  --r-sm: 8px;
  --r-md: 12px;
  --r-lg: 16px;

  --shadow-card: 0 1px 2px rgba(21, 24, 30, 0.04);
  --shadow-float: 0 12px 32px rgba(21, 24, 30, 0.10), 0 2px 8px rgba(21, 24, 30, 0.06);
  --shadow-window: 0 24px 64px rgba(21, 24, 30, 0.10), 0 4px 16px rgba(21, 24, 30, 0.05);

  --container: 1280px;
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
html, body { overflow-x: clip; }
body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  color: var(--body);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
h1, h2, h3, h4, h5 { margin: 0; font-family: var(--font-display); font-weight: 500; color: var(--ink); line-height: 1.12; letter-spacing: -0.02em; }
p { margin: 0; }
button { font: inherit; background: none; border: 0; cursor: pointer; color: inherit; padding: 0; }

.container { max-width: var(--container); margin: 0 auto; padding: 0 40px; }
.text-balance { text-wrap: balance; }

/* ---------- Reveal animation ---------- */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity .7s cubic-bezier(.2,.7,.2,1), transform .7s cubic-bezier(.2,.7,.2,1); }
.reveal.in { opacity: 1; transform: none; }

/* ---------- Scroll-triggered blur-in reveal ----------
   Applied only to sections below the initial viewport, so the hero (and the
   LCP element) paints immediately. Content is always present and always
   rendered — scrolling only toggles a class. Animates opacity/filter/transform
   only, so nothing triggers layout. */
.reveal-blur {
  opacity: 0;
  filter: blur(8px);
  transform: translateY(14px);
  transition:
    opacity 520ms cubic-bezier(.2,.7,.2,1),
    filter 520ms cubic-bezier(.2,.7,.2,1),
    transform 520ms cubic-bezier(.2,.7,.2,1);
  will-change: opacity, filter, transform;
}
.reveal-blur.is-revealed { opacity: 1; filter: blur(0); transform: none; }
/* added once the transition has finished, so the hint is dropped afterwards */
.reveal-blur.is-settled { will-change: auto; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  .reveal-blur {
    opacity: 1; filter: none; transform: none;
    transition: none; will-change: auto;
  }
  .marquee-track { animation: none !important; }
  .hero-line .hero-line-blue { animation: none; transform: none; }
  .hero-line::after, .svc-progress::before, .hero-float,
  .pill-live .dot, .pill-live--blue .dot { animation: none !important; }
  .tile-logo { animation: none !important; opacity: var(--tile-logo-peak) !important; }
  .cta-tile { animation: none !important; }
  .mobile-menu, .menu-scrim, .mobile-menu a.mm-link, .mobile-menu .mm-actions { transition-duration: .01s !important; transition-delay: 0s !important; }
  .reveal .meter-fill { transform: none; transition: none; }
}

/* ---------- Grid-tile background motif ---------- */
.tiles {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='72' height='72'%3E%3Crect x='1.5' y='1.5' width='69' height='69' rx='14' fill='none' stroke='%23E8EEF7' stroke-width='1.5'/%3E%3C/svg%3E");
  background-size: 72px 72px;
}
.tiles--fade-l { -webkit-mask-image: linear-gradient(to left, #000 30%, transparent 85%); mask-image: linear-gradient(to left, #000 30%, transparent 85%); }
.tiles--fade-c { -webkit-mask-image: radial-gradient(ellipse 90% 80% at 50% 50%, transparent 42%, #000 78%); mask-image: radial-gradient(ellipse 90% 80% at 50% 50%, transparent 42%, #000 78%); }

/* Hero tile clusters (Figma 197:113): larger white cells grouped in patches */
.stage-tiles {
  position: absolute; pointer-events: none; z-index: 1;
  /* every edge dissolves — none of these clusters actually runs off-screen */
  --mask-x: linear-gradient(to right, transparent 0%, #000 24%, #000 76%, transparent 100%);
  --mask-y: linear-gradient(to bottom, transparent 0%, #000 24%, #000 76%, transparent 100%);
  -webkit-mask-image: var(--mask-y), var(--mask-x);
  mask-image: var(--mask-y), var(--mask-x);
  -webkit-mask-composite: source-in;
  mask-composite: intersect;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='97' height='97'%3E%3Crect x='1' y='1' width='94' height='94' rx='18' fill='%23FFFFFF' stroke='%23E9EEF7' stroke-width='1.5'/%3E%3C/svg%3E");
  background-size: 97px 97px;
}
/* Ghost logos sit on the 97px cell grid above: each one is exactly one cell,
   so the mark is always centred in its tile. Place with --col / --row. */
.tile-logo {
  --tile-logo-peak: .10;
  position: absolute;
  left: calc(var(--col, 0) * 97px);
  top: calc(var(--row, 0) * 97px);
  box-sizing: border-box;
  width: 97px; height: 97px;
  padding: 26px;
  object-fit: contain;
  filter: grayscale(1);
  opacity: 0;
  animation: tile-logo-fade 9s ease-in-out infinite;
  animation-delay: var(--d, 0s);
}
@keyframes tile-logo-fade {
  0%, 100% { opacity: 0; }
  50% { opacity: var(--tile-logo-peak); }
}

/* Cursor highlight on background tiles (cell position set from JS) */
.tile-hi {
  position: absolute; top: 0; left: 0; pointer-events: none;
  background: rgba(37, 99, 235, .06);
  border: 1.5px solid rgba(37, 99, 235, .38);
  box-shadow: 0 0 20px rgba(37, 99, 235, .14), inset 0 0 14px rgba(37, 99, 235, .07);
  opacity: 0;
  transition: transform .16s cubic-bezier(.3,.7,.3,1), opacity .25s ease;
  will-change: transform, opacity;
}
.tile-ghost {
  position: absolute; top: 0; left: 0; pointer-events: none;
  background: rgba(37, 99, 235, .10);
  animation: tile-ghost-fade .7s ease-out forwards;
}
@keyframes tile-ghost-fade {
  from { opacity: 1; }
  to { opacity: 0; }
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font-family: var(--font-display); font-weight: 500; font-size: 15px; line-height: 1;
  border-radius: var(--r-sm); padding: 0 22px; height: 48px;
  transition: background .18s ease, color .18s ease, border-color .18s ease, transform .18s ease, box-shadow .18s ease;
  white-space: nowrap;
}
.btn .arrow { width: 14px; height: 14px; transition: transform .18s ease; }
.btn:hover .arrow { transform: translateX(3px); }
.btn-primary { background: var(--blue); color: #fff; }
.btn-primary:hover { background: var(--blue-deep); }
.btn-secondary { background: #F1F4F9; color: var(--ink); }
.btn-secondary:hover { background: #E7ECF4; }
/* white surface so the secondary CTA lifts off the tinted section — themed, not inline */
.btn-secondary--solid { background: #fff; border: 1px solid var(--border); }
.btn-secondary--solid:hover { background: #F1F4F9; }
.btn-ink { background: var(--ink); color: #fff; }
.btn-ink:hover { background: #2A2F3A; }
.btn-ghost { background: transparent; color: var(--ink); }
.btn-ghost:hover { background: #F1F4F9; }
.btn-sm { height: 40px; padding: 0 16px; font-size: 14px; }
.btn-lg { height: 52px; padding: 0 26px; font-size: 16px; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 60;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid transparent;
  transition: border-color .2s ease, box-shadow .2s ease;
}
.site-header.scrolled { border-bottom-color: var(--border); box-shadow: 0 1px 12px rgba(21,24,30,.04); }
.nav { display: flex; align-items: center; gap: 32px; height: 76px; }
.brand { display: inline-flex; align-items: center; flex-shrink: 0; }
.brand-img { height: 30px; width: auto; }
.nav-links { display: flex; align-items: center; gap: 6px; margin: 0 auto; }
.nav-link {
  font-family: var(--font-display); font-size: 15px; font-weight: 500; color: var(--muted);
  padding: 8px 13px; border-radius: 999px; transition: color .15s ease, background .15s ease;
}
.nav-link:hover { color: var(--ink); background: #F1F4F9; }
.nav-link.is-active { color: var(--ink); }
.nav-cta { display: flex; align-items: center; gap: 10px; flex-shrink: 0; }
.btn-icon {
  display: inline-flex; align-items: center; justify-content: center;
  width: 40px; height: 40px; border-radius: var(--r-sm);
  background: #F1F4F9; color: var(--ink); transition: background .15s ease;
}
.btn-icon:hover { background: #E7ECF4; }
.nav-burger { display: none; }

/* Mobile menu */
.mobile-menu {
  position: fixed; z-index: 55; inset: 76px 0 auto 0;
  background: #fff; border-bottom: 1px solid var(--border);
  padding: 12px 24px 24px; box-shadow: 0 24px 48px rgba(21,24,30,.08);
  opacity: 0; visibility: hidden; transform: translateY(-12px);
  transition: opacity .26s cubic-bezier(.2,.7,.2,1), transform .26s cubic-bezier(.2,.7,.2,1), visibility 0s linear .26s;
}
.mobile-menu.open {
  opacity: 1; visibility: visible; transform: none;
  transition: opacity .26s cubic-bezier(.2,.7,.2,1), transform .26s cubic-bezier(.2,.7,.2,1), visibility 0s;
}
/* blurred scrim behind the panel */
.menu-scrim {
  position: fixed; inset: 0; z-index: 54;
  background: rgba(21,24,30,.28);
  backdrop-filter: blur(7px); -webkit-backdrop-filter: blur(7px);
  opacity: 0; visibility: hidden;
  transition: opacity .26s ease, visibility 0s linear .26s;
}
.menu-scrim.open { opacity: 1; visibility: visible; transition: opacity .26s ease, visibility 0s; }
/* links ease in behind the panel */
.mobile-menu a.mm-link, .mobile-menu .mm-actions {
  opacity: 0; transform: translateY(6px);
  transition: opacity .3s ease, transform .3s cubic-bezier(.2,.7,.2,1);
}
.mobile-menu.open a.mm-link, .mobile-menu.open .mm-actions { opacity: 1; transform: none; }
.mobile-menu.open a.mm-link:nth-of-type(1) { transition-delay: .04s; }
.mobile-menu.open a.mm-link:nth-of-type(2) { transition-delay: .07s; }
.mobile-menu.open a.mm-link:nth-of-type(3) { transition-delay: .10s; }
.mobile-menu.open a.mm-link:nth-of-type(4) { transition-delay: .13s; }
.mobile-menu.open a.mm-link:nth-of-type(5) { transition-delay: .16s; }
.mobile-menu.open a.mm-link:nth-of-type(6) { transition-delay: .19s; }
.mobile-menu.open .mm-actions { transition-delay: .22s; }
.mobile-menu a.mm-link { display: block; font-family: var(--font-display); font-weight: 500; font-size: 17px; color: var(--ink); padding: 12px 4px; border-bottom: 1px solid #F1F4F9; }
.mobile-menu .mm-actions { display: grid; gap: 10px; margin-top: 16px; }

/* ---------- Hero ---------- */
.hero { position: relative; overflow: hidden; background: linear-gradient(180deg, #FFFFFF 0%, #FBFCFE 100%); }
.hero-inner { position: relative; display: grid; grid-template-columns: minmax(0, 46%) minmax(0, 54%); align-items: center; min-height: 640px; padding-top: 56px; padding-bottom: 84px; }
.hero-copy { position: relative; z-index: 2; }
.hero-title { font-size: clamp(42px, 4.6vw, 66px); font-weight: 500; letter-spacing: -0.025em; }
.hero-title em { font-style: normal; color: var(--blue); }
.hero-sub { margin-top: 24px; max-width: 480px; font-size: 18px; line-height: 1.6; color: var(--body); }
.hero-actions { display: flex; align-items: center; gap: 14px; margin-top: 32px; flex-wrap: wrap; }
.hero-trust { display: flex; align-items: center; gap: 26px; flex-wrap: wrap; margin-top: 72px; }
.hero-trust span { display: inline-flex; align-items: center; gap: 8px; font-size: 14.5px; font-weight: 500; font-family: var(--font-display); color: var(--ink); }
.hero-trust svg { width: 15px; height: 15px; color: var(--blue); flex-shrink: 0; }

/* Hero visual */
.hero-stage { position: relative; z-index: 1; height: 560px; }

/* Tile clusters around the mockup */
.stage-tiles--tr {
  top: -18px; right: max(-120px, calc((100vw - var(--container)) / -2)); width: 390px; height: 292px;
}
.stage-tiles--b {
  bottom: -46px; left: 12%; right: max(-120px, calc((100vw - var(--container)) / -2)); height: 292px;
}
.stage-tiles--l {
  top: 336px; left: -9%; width: 196px; height: 196px;
}

/* Connector line from crumb down through the stage */
/* z-index 0 keeps the connector line behind the tile clusters (z-index 1) */
/* stops at the floating card (top: 300px) — it connects the crumb to it, nothing below */
.hero-line { position: absolute; top: 92px; left: calc(4% + 40px); width: 2px; height: 215px; z-index: 0; }
.hero-line .hero-line-blue {
  position: absolute; inset: 0; width: 100%;
  background: var(--blue); transform-origin: top; transform: scaleY(0);
  animation: line-draw .9s cubic-bezier(.3,.7,.2,1) .5s forwards;
}
/* same sweep as .svc-progress::before, running down instead of across */
.hero-line { overflow: hidden; }
.hero-line::after {
  content: ""; position: absolute; left: 0; top: 0; width: 100%; height: 45%;
  border-radius: 999px;
  /* a light pulse — a blue sweep would be invisible on an already-blue line */
  background: linear-gradient(180deg, transparent 0%, rgba(226,238,255,.95) 50%, transparent 100%);
  animation: line-sweep 2.6s cubic-bezier(.4,.2,.3,1) 1.6s infinite;
}
@keyframes line-draw { to { transform: scaleY(1); } }
@keyframes line-sweep {
  0% { transform: translateY(-110%); }
  60% { transform: translateY(230%); }
  100% { transform: translateY(230%); }
}

.hero-crumb {
  position: absolute; top: 40px; left: 4%; z-index: 4;
  display: inline-flex; align-items: center; gap: 10px;
  background: var(--ink); color: #fff; border-radius: 10px;
  padding: 12px 16px; font-family: var(--font-display); font-size: 14px;
  box-shadow: var(--shadow-float);
}
.hero-crumb b { font-weight: 600; }
.hero-crumb .crumb-path { color: #9AA3B5; font-weight: 400; }
.hero-crumb .pill-live { margin-left: 14px; }
.pill-live {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 12px; font-weight: 500; color: #fff;
  background: rgba(255,255,255,.14); border-radius: 999px; padding: 4px 10px;
}
.pill-live .dot { width: 6px; height: 6px; border-radius: 50%; background: #fff; animation: dot-pulse 2.4s ease-out infinite; }
@keyframes dot-pulse {
  0% { box-shadow: 0 0 0 0 rgba(255,255,255,.35); }
  70% { box-shadow: 0 0 0 6px rgba(255,255,255,0); }
  100% { box-shadow: 0 0 0 0 rgba(255,255,255,0); }
}
.hero-window {
  position: absolute; top: 128px; left: 14%; right: max(-120px, calc((100vw - var(--container)) / -2));
  background: #fff; border: 1px solid var(--border); border-radius: 14px 0 0 14px;
  border-right: 0; box-shadow: var(--shadow-window); overflow: hidden; z-index: 2;
}
.hero-window .window-bar { padding: 22px 22px 16px; border-bottom: 0; }
.hero-window .window-body { padding-top: 6px; }
.hero-window .svc {
  border: 1px solid #ECF1F8; border-radius: 10px; padding: 13px 16px;
  position: relative; background: #fff;
}
.hero-window .svc + .svc { margin-top: 8px; }

/* Deploy progress line on the building row */
.svc-progress {
  position: absolute; left: 16px; right: 16px; top: -5px; height: 2px;
  border-radius: 999px; background: #E5EDFB; overflow: hidden;
}
.svc-progress::before {
  content: ""; position: absolute; inset: 0; width: 45%; border-radius: 999px;
  background: linear-gradient(90deg, rgba(37,99,235,.15), var(--blue));
  animation: progress-sweep 2.2s cubic-bezier(.4,.2,.3,1) infinite;
}
@keyframes progress-sweep {
  0% { transform: translateX(-110%); }
  60% { transform: translateX(230%); }
  100% { transform: translateX(230%); }
}

.hero-float {
  position: absolute; top: 300px; left: -4%; z-index: 4;
  display: flex; align-items: center; gap: 14px;
  background: #fff; border: 1px solid #EAF0F8; border-radius: 14px;
  box-shadow: var(--shadow-float); padding: 16px 20px; min-width: 400px;
  animation: float-y 6s ease-in-out 1.8s infinite;
}
.hero-float .svc-region { margin-left: auto; }
@keyframes float-y {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-7px); }
}
.pill-live--blue {
  display: inline-flex; align-items: center; gap: 6px; margin-left: 10px;
  font-size: 12px; font-weight: 500; color: var(--ink);
  background: var(--blue-tint); border-radius: 999px; padding: 5px 11px;
}
.pill-live--blue .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--blue); animation: dot-pulse-blue 2.4s ease-out infinite; }
@keyframes dot-pulse-blue {
  0% { box-shadow: 0 0 0 0 rgba(37,99,235,.30); }
  70% { box-shadow: 0 0 0 6px rgba(37,99,235,0); }
  100% { box-shadow: 0 0 0 0 rgba(37,99,235,0); }
}

/* ---------- Window chrome (shared mockup) ---------- */
.window-bar { display: flex; align-items: center; gap: 14px; padding: 13px 18px; border-bottom: 1px solid #EEF2F8; }
.window-dots { display: inline-flex; gap: 6px; }
.window-dots span { width: 10px; height: 10px; border-radius: 50%; }
.window-dots span:nth-child(1) { background: #FF5F57; }
.window-dots span:nth-child(2) { background: #FEBC2E; }
.window-dots span:nth-child(3) { background: #28C840; }
.window-url {
  font-family: var(--font-mono); font-size: 11.5px; color: var(--faint);
  background: #F6F8FC; border: 1px solid #EEF2F8; border-radius: 6px; padding: 5px 12px;
}
.window-url--r { margin-left: auto; background: none; border: 0; }
.window-body { padding: 20px 22px; }
.dash-title { font-family: var(--font-display); font-size: 15px; font-weight: 500; color: var(--ink); margin-bottom: 14px; }

/* Service rows */
.svc-list { display: grid; }
.svc { display: flex; align-items: center; gap: 12px; padding: 13px 4px; border-top: 1px solid #F0F3F9; }
.svc:first-child { border-top: 0; }
.svc-tech {
  width: 30px; height: 30px; border-radius: 8px; flex-shrink: 0;
  display: inline-flex; align-items: center; justify-content: center;
  font-family: var(--font-ui); font-size: 12px; font-weight: 600; color: #fff;
}
.svc-tech--n { background: #10B981; }
.svc-tech--p { background: #D946EF; }
.svc-tech--s { background: #F97316; }
.svc-tech--w { background: #6366F1; }
.svc-name { font-family: var(--font-display); font-size: 14px; font-weight: 500; color: var(--ink); line-height: 1.3; }
.svc-meta { font-family: var(--font-ui); font-size: 11.5px; color: var(--faint); }
.svc-region { font-family: var(--font-mono); font-size: 10.5px; color: var(--faint); }
.svc-pill {
  font-family: var(--font-ui); font-size: 10.5px; font-weight: 600; letter-spacing: .04em;
  border-radius: 999px; padding: 4px 10px; margin-left: 8px;
}
.svc-pill--live { background: #E8F7F0; color: var(--green); }
.svc-pill--build { background: #FEF6E7; color: var(--amber); }
.svc-r { display: flex; align-items: center; margin-left: auto; }

/* ---------- Stack marquee ---------- */
.stack-strip { border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); background: #FBFCFE; padding: 26px 0; position: relative; z-index: 2; overflow: hidden; }
.stack-strip-inner { display: flex; align-items: center; gap: 34px; max-width: 100%; }
.stack-label { flex-shrink: 0; font-family: var(--font-display); font-weight: 500; font-size: 16px; color: var(--ink); padding-left: 40px; }
.marquee { overflow: hidden; flex: 1; min-width: 0; width: 100%; -webkit-mask-image: linear-gradient(to right, transparent, #000 6%, #000 94%, transparent); mask-image: linear-gradient(to right, transparent, #000 6%, #000 94%, transparent); }
.marquee-track { display: flex; gap: 12px; width: max-content; animation: marquee 46s linear infinite; }
.marquee:hover .marquee-track { animation-play-state: paused; }
@keyframes marquee { to { transform: translateX(-50%); } }
.marquee-item {
  display: inline-flex; align-items: center; gap: 8px; flex-shrink: 0;
  font-family: var(--font-display); font-size: 14px; font-weight: 500; color: var(--ink);
  background: #fff; border: 1px solid var(--border); border-radius: 999px; padding: 9px 18px;
  transition: border-color .15s ease, box-shadow .15s ease;
}
.marquee-item:hover { border-color: var(--blue); box-shadow: 0 2px 8px rgba(37,99,235,.10); }
.marquee-item .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--blue); }

/* Brand marks in the stack pills (sprite lives just after <body>) */
.ti-sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
.marquee-item .mi-ico { width: 15px; height: 15px; flex: none; fill: currentColor; }
.ti-nextjs { color: #000000; }
.ti-react { color: #61DAFB; }
.ti-nodejs { color: #5FA04E; }
.ti-python { color: #3776AB; }
.ti-django { color: #092E20; }
.ti-flask { color: #3BABC3; }
.ti-ruby { color: #CC342D; }
.ti-rails { color: #D30001; }
.ti-go { color: #00ADD8; }
.ti-rust { color: #000000; }
.ti-docker { color: #2496ED; }
.ti-static-site { color: #E34F26; }
.ti-claude-code { color: #D97757; }
.ti-cursor-app { color: #000000; }
.ti-nuxt { color: #00DC82; }
.ti-express { color: #0A0A0A; }
.ti-lovable-app { color: #FF6B57; }

/* ---------- Sections ---------- */
.section { position: relative; padding: clamp(72px, 9vw, 128px) 0; }
.section-head { max-width: 720px; margin: 0 auto clamp(44px, 5vw, 72px); text-align: center; }
.section-head--left { margin: 0 0 clamp(40px, 5vw, 64px); text-align: left; }
.section-title { font-size: clamp(36px, 4.4vw, 60px); letter-spacing: -0.025em; }
.section-sub { margin: 22px auto 0; max-width: 560px; font-size: 17px; color: var(--body); }
.section-head--left .section-sub { margin-left: 0; }
.eyebrow {
  display: inline-block; font-family: var(--font-ui); font-size: 12px; font-weight: 600;
  letter-spacing: .1em; text-transform: uppercase; color: var(--teal); margin-bottom: 14px;
}

/* ---------- Bento features ---------- */
.bento { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 20px; }
.bento-card {
  grid-column: span 2; min-width: 0; display: flex; flex-direction: column;
  background: #fff; border: 1px solid var(--border); border-radius: var(--r-lg);
  padding: 30px 30px 26px; box-shadow: var(--shadow-card);
  transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease;
}
.bento-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-float); border-color: #D6E0F2; }
.bento-card--wide { grid-column: span 3; }
.bento-card h3 { font-size: 21px; margin-bottom: 10px; }
.bento-card > p { font-size: 15px; line-height: 1.6; color: var(--body); max-width: 40ch; }
.bento-visual { margin-top: auto; padding-top: 24px; }
.bento-frame { background: #fff; border: 1px solid #EBF0F8; border-radius: var(--r-md); overflow: hidden; box-shadow: var(--shadow-card); }

/* Bento mockup bits */
.mock-logline { display: flex; gap: 10px; font-family: var(--font-mono); font-size: 11px; line-height: 2; color: var(--muted); white-space: nowrap; }
.mock-logline .t { color: var(--faint); }
.mock-logline .lvl-info { color: var(--blue); }
.mock-logline .lvl-warn { color: var(--amber); }
.mock-logline .lvl-err { color: var(--red); }
.mock-logline .lvl-ok { color: var(--green); }
.telegram-toast {
  display: flex; gap: 12px; align-items: flex-start;
  background: var(--ink); color: #fff; border-radius: var(--r-md); padding: 13px 16px;
  box-shadow: var(--shadow-float);
}
.telegram-toast .tg-avatar {
  width: 30px; height: 30px; border-radius: 50%; flex-shrink: 0;
  background: var(--blue); display: flex; align-items: center; justify-content: center;
}
.telegram-toast .tg-avatar img { width: 15px; }
.telegram-toast .tg-h { font-family: var(--font-display); font-size: 13px; font-weight: 600; }
.telegram-toast .tg-b { font-family: var(--font-ui); font-size: 12px; color: #C6CBD6; line-height: 1.45; margin-top: 2px; }

.meter { display: flex; align-items: center; gap: 12px; padding: 9px 0; border-bottom: 1px solid #F0F3F9; }
.meter:last-child { border-bottom: 0; }
.meter-label { flex: 0 0 76px; font-family: var(--font-ui); font-size: 12px; color: var(--muted); }
.meter-bar { flex: 1; height: 6px; border-radius: 999px; background: #EDF1F8; overflow: hidden; }
.meter-fill { height: 100%; border-radius: 999px; background: var(--blue); }
.reveal .meter-fill { transform: scaleX(0); transform-origin: left; transition: transform 1s cubic-bezier(.3,.7,.2,1) .35s; }
.reveal.in .meter-fill { transform: scaleX(1); }
.meter-fill--teal { background: var(--teal); }
.meter-fill--green { background: var(--green); }
.meter-fill--violet { background: #7C6FF0; }
.meter-val { flex: 0 0 44px; text-align: right; font-family: var(--font-mono); font-size: 11px; color: var(--ink); }

.commit { display: flex; align-items: center; gap: 12px; padding: 11px 14px; border: 1px solid #EBF0F8; border-radius: 10px; background: #fff; }
.commit + .commit { margin-top: 8px; }
.commit--current { border-color: var(--blue); box-shadow: 0 0 0 3px rgba(37,99,235,.08); }
.commit-sha { font-family: var(--font-mono); font-size: 13px; font-weight: 500; color: var(--ink); }
.commit-msg { font-family: var(--font-ui); font-size: 11.5px; color: var(--faint); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.commit-when { margin-left: auto; font-family: var(--font-ui); font-size: 11px; color: var(--faint); flex-shrink: 0; }
.commit-pill {
  margin-left: auto; flex-shrink: 0; display: inline-flex; align-items: center; gap: 6px;
  font-family: var(--font-ui); font-size: 11px; font-weight: 600; color: var(--blue);
  background: var(--blue-tint); border-radius: 999px; padding: 4px 10px;
}
.commit-pill .dot { width: 6px; height: 6px; border-radius: 50%; background: var(--blue); }

.spec-row { display: flex; align-items: center; gap: 10px; padding: 12px 16px; border-bottom: 1px solid #F0F3F9; font-family: var(--font-ui); font-size: 13px; color: var(--muted); }
.spec-row:last-child { border-bottom: 0; }
.spec-row svg { width: 14px; height: 14px; color: var(--faint); flex-shrink: 0; }
.spec-row b { margin-left: auto; font-family: var(--font-display); font-weight: 500; color: var(--ink); }
.conn-chip {
  display: flex; align-items: center; gap: 10px; margin-top: 10px;
  border: 1px solid var(--blue); border-radius: 10px; padding: 11px 14px;
  box-shadow: 0 0 0 3px rgba(37,99,235,.07);
}
.conn-chip .ci { width: 26px; height: 26px; border-radius: 8px; background: #E6F6F4; color: var(--teal); display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.conn-chip .ci svg { width: 13px; height: 13px; }
.conn-h { font-family: var(--font-display); font-size: 13px; font-weight: 500; color: var(--ink); }
.conn-s { font-family: var(--font-mono); font-size: 10px; color: var(--faint); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 230px; }

.redis-term { background: #fff; }
.redis-line { display: flex; gap: 10px; font-family: var(--font-mono); font-size: 11px; line-height: 2.1; }
.redis-line .ln { color: #C3CAD8; width: 16px; text-align: right; flex-shrink: 0; }
.redis-line .cmd { color: var(--teal); }
.redis-line .arg { color: var(--muted); }
.redis-line .ok { color: var(--green); }

.logsearch { display: flex; align-items: center; gap: 8px; border: 1px solid #EBF0F8; background: #F8FAFD; border-radius: 8px; padding: 9px 12px; font-family: var(--font-mono); font-size: 11px; color: var(--muted); }
.logsearch svg { width: 13px; height: 13px; color: var(--faint); flex-shrink: 0; }

.domain-row {
  display: flex; align-items: center; gap: 12px;
  border: 1px solid #EBF0F8; border-radius: 10px; background: #fff; padding: 12px 14px;
}
.domain-row + .domain-row { margin-top: 8px; }
.domain-row .di { width: 30px; height: 30px; border-radius: 8px; background: #E6F6F4; color: var(--teal); display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.domain-row .di svg { width: 14px; height: 14px; }
.domain-h { font-family: var(--font-display); font-size: 13.5px; font-weight: 500; color: var(--ink); }
.domain-s { font-family: var(--font-ui); font-size: 11px; color: var(--faint); }
.domain-ok { margin-left: auto; width: 20px; height: 20px; border-radius: 50%; background: #E8F7F0; color: var(--green); display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.domain-ok svg { width: 11px; height: 11px; }
.domain-add {
  display: flex; align-items: center; justify-content: center; gap: 8px; margin-top: 10px;
  background: var(--blue); color: #fff; border-radius: 10px; padding: 12px;
  font-family: var(--font-display); font-size: 14px; font-weight: 500;
}
.domain-add svg { width: 14px; height: 14px; }

/* ---------- Steps ---------- */
.steps-band { background: var(--bg-soft); }
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: clamp(28px, 4vw, 56px); }
.step-eyebrow { font-family: var(--font-mono); font-size: 12.5px; font-weight: 500; letter-spacing: .08em; color: var(--teal); text-transform: uppercase; }
.step h3 { font-size: 21px; margin: 12px 0 10px; }
.step > p { font-size: 15px; line-height: 1.65; color: var(--body); }
.step-term {
  margin-top: 22px; background: #fff; border: 1px solid var(--border); border-radius: var(--r-md);
  padding: 16px 18px; box-shadow: var(--shadow-card);
}
.term-line { display: flex; align-items: center; gap: 10px; font-family: var(--font-mono); font-size: 12px; line-height: 2.1; color: var(--faint); }
.term-line .sym { width: 14px; flex-shrink: 0; text-align: center; }
.term-line .sym--check { color: var(--blue); }
.term-line .sym--run { color: var(--blue); }
.term-line .sym--ok { color: var(--green); }
.term-line.term-cmd { color: var(--ink); font-weight: 500; }
.term-line.term-cmd .sym { color: var(--faint); }

/* ---------- Personas ---------- */
.personas { display: grid; grid-template-columns: repeat(3, 1fr); gap: 56px 64px; }
.persona-icon { display: block; width: 34px; height: 34px; color: var(--blue); margin-bottom: 20px; }
.persona-icon svg { width: 100%; height: 100%; }
.persona h3 { font-size: 20px; margin-bottom: 10px; }
.persona h3 a { transition: color .15s ease; }
.persona h3 a:hover { color: var(--blue); }
.persona p { font-size: 15px; line-height: 1.65; color: var(--body); max-width: 38ch; }

/* ---------- Comparison ---------- */
.compare-wrap { max-width: 1180px; margin: 0 auto; }
.compare { display: grid; grid-template-columns: minmax(180px, 1.2fr) 1fr 1fr 1fr; align-items: start; }
.compare-rows { display: contents; }
.cmp-cell {
  height: 61px; display: flex; align-items: center;
  border-bottom: 1px solid #EDF1F8; font-size: 15.5px;
}
.cmp-cell--head { height: 88px; justify-content: center; border-bottom: 1px solid #EDF1F8; font-family: var(--font-display); font-weight: 500; font-size: 17px; color: var(--ink); }
.cmp-cell--head a:hover { color: var(--blue); }
/* Rival brand marks in the compare header */
.rival-brand { display: inline-flex; align-items: center; transition: opacity .15s ease; }
.rival-brand:hover { opacity: .65; }
.rival-ico { width: 22px; height: 22px; fill: currentColor; }
.ti-render { color: #000000; }
.rival-wordmark { font-family: var(--font-display); font-weight: 700; letter-spacing: -0.01em; }
/* Heroku's mark is trademark-restricted (not in simple-icons) — brand wordmark instead */
.rival-wordmark--heroku { color: #430098; font-size: 19px; }
.cmp-cell--label { font-family: var(--font-display); font-weight: 500; color: var(--ink); padding-right: 20px; }
.cmp-cell--rival { color: var(--muted); font-size: 14.5px; padding-right: 16px; }
.compare-belmo {
  background: linear-gradient(168deg, var(--blue) 0%, #1D74D8 46%, var(--teal) 100%);
  border-radius: var(--r-lg); color: #fff;
  margin: -14px 28px 0 0; padding: 0 22px 14px;
  box-shadow: 0 20px 48px rgba(37, 99, 235, .28);
  position: relative; z-index: 1;
}
.compare-belmo .cb-head { height: 102px; display: flex; align-items: center; justify-content: center; }
.compare-belmo .cb-head img { height: 28px; width: auto; }
.compare-belmo .cb-row {
  height: 61px; display: flex; align-items: center; gap: 9px;
  border-top: 1px solid rgba(255,255,255,.16);
  font-family: var(--font-display); font-weight: 500; font-size: 15px;
}
.compare-belmo .cb-row svg { width: 13px; height: 13px; flex-shrink: 0; opacity: .85; }

/* ---------- Infrastructure ---------- */
.infra-band { background: var(--bg-band); overflow: hidden; }
.infra-band .tiles { left: 55%; top: 0; height: 60%; }
.infra-head { max-width: 640px; position: relative; z-index: 1; }
.infra-badges { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin: clamp(36px, 4vw, 56px) 0; position: relative; z-index: 1; }
.infra-badge {
  display: flex; align-items: center; gap: 14px;
  background: #fff; border: 1px solid var(--border); border-radius: var(--r-md); padding: 18px 20px;
  box-shadow: var(--shadow-card);
}
.infra-badge svg { width: 22px; height: 22px; color: var(--blue); flex-shrink: 0; }
.infra-badge .b-h { font-family: var(--font-display); font-size: 14.5px; font-weight: 600; color: var(--ink); line-height: 1.3; }
.infra-badge .b-s { font-family: var(--font-ui); font-size: 12px; color: var(--muted); }
.infra-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 44px 40px; position: relative; z-index: 1; }
.infra-item svg { width: 30px; height: 30px; color: var(--blue); margin-bottom: 16px; }
.infra-item h3 { font-size: 17.5px; font-weight: 500; margin-bottom: 7px; }
.infra-item p { font-size: 14px; line-height: 1.6; color: var(--body); }

/* ---------- Definition (GEO) ---------- */
.definition { max-width: 880px; margin: 0 auto; }
.definition .lead { font-size: 15px; line-height: 1.75; color: var(--body); }
.definition .lead strong { color: var(--ink); font-weight: 500; }

/* ---------- FAQ ---------- */
.faq-grid { display: grid; grid-template-columns: minmax(260px, 4fr) 7fr; gap: clamp(36px, 5vw, 80px); align-items: start; }
.faq-intro h2 { font-size: clamp(36px, 4vw, 56px); }
.faq-intro p { margin-top: 20px; font-size: 16px; color: var(--body); max-width: 34ch; }
.faq details { border: 1px solid var(--border); border-radius: var(--r-md); background: #fff; transition: border-color .2s ease; }
.faq details + details { margin-top: 10px; }
.faq details[open] { border-color: #D6E0F2; }
.faq summary {
  list-style: none; cursor: pointer; display: flex; align-items: center; gap: 16px;
  font-family: var(--font-display); font-size: 16.5px; font-weight: 500; color: var(--ink);
  padding: 20px 22px;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: ""; margin-left: auto; flex-shrink: 0; width: 10px; height: 10px;
  border-right: 1.8px solid var(--muted); border-bottom: 1.8px solid var(--muted);
  transform: rotate(45deg); transition: transform .2s ease; translate: 0 -2px;
}
.faq details[open] summary::after { transform: rotate(-135deg); translate: 0 2px; }
.faq details p { padding: 0 22px 20px; font-size: 15px; line-height: 1.65; color: var(--body); }
.faq details a { color: var(--blue); }

/* ---------- Final CTA ---------- */
.cta { position: relative; overflow: hidden; background: linear-gradient(180deg, #F7FAFE 0%, #FFFFFF 100%); border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); padding: clamp(84px, 10vw, 140px) 0; }
.cta .tiles { opacity: .8; }
.cta-inner { position: relative; z-index: 1; text-align: center; max-width: 660px; margin: 0 auto; }
.cta-inner h2 { font-size: clamp(40px, 4.8vw, 64px); }
.cta-inner p { margin: 22px auto 0; max-width: 460px; font-size: 17px; color: var(--body); }
.cta-actions { display: flex; justify-content: center; gap: 14px; margin-top: 36px; flex-wrap: wrap; }
.cta-tile {
  position: absolute; width: 76px; height: 76px; border-radius: 18px;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 16px 36px rgba(21,24,30,.16); z-index: 1;
}
.cta-tile img, .cta-tile svg { width: 36px; height: 36px; }
/* drift uses `translate`, not `transform`, so it composes with each tile's inline rotate() */
.cta-tile { animation: cta-drift var(--dur, 10s) ease-in-out infinite; animation-delay: var(--d, 0s); }
@keyframes cta-drift {
  0%, 100% { translate: 0 0; }
  50% { translate: 0 -14px; }
}
.cta-tile--blue { background: linear-gradient(160deg, #3B82F6, var(--blue)); }
.cta-tile--teal { background: linear-gradient(160deg, #14B8A9, #0D9488); color: #fff; }
.cta-tile--sm { width: 60px; height: 60px; border-radius: 15px; }
.cta-tile--sm img, .cta-tile--sm svg { width: 28px; height: 28px; }

/* ---------- Footer ---------- */
.footer { background: var(--footer-bg); color: #B9BFCB; }
.footer-main { display: grid; grid-template-columns: 3.4fr repeat(5, 1.7fr); gap: 40px 32px; padding: clamp(56px, 6vw, 80px) 0 48px; }
.footer-brand img { height: 30px; width: auto; }
.footer-brand p { margin-top: 20px; font-size: 14px; line-height: 1.65; color: #8E96A5; max-width: 26ch; }
.footer-social { display: flex; gap: 10px; margin-top: 26px; }
.footer-social a {
  width: 40px; height: 40px; border-radius: 50%; background: #23262E;
  display: inline-flex; align-items: center; justify-content: center; color: #fff;
  transition: background .15s ease;
}
.footer-social a:hover { background: var(--blue); }
.footer-social svg { width: 17px; height: 17px; }
.footer-col h5 { font-family: var(--font-display); font-size: 13.5px; font-weight: 600; color: #fff; margin: 0 0 18px; }
/* columns are <details open>; the marker only shows once they collapse on mobile */
.footer-col > summary { list-style: none; }
.footer-col > summary::-webkit-details-marker { display: none; }
.footer-col > summary::marker { content: ""; }
.footer-col ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 11px; }
.footer-col a { font-size: 13.5px; color: #9AA1AF; transition: color .15s ease; }
.footer-col a:hover { color: #fff; }
.footer-bottom { background: var(--footer-deep); }
.footer-bottom .container { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding-top: 18px; padding-bottom: 18px; font-size: 13px; color: #8E96A5; }
.footer-bottom a { color: #B9BFCB; }
.footer-bottom a:hover { color: #fff; }

/* ============================================================
   Responsive
   ============================================================ */
@media (max-width: 1160px) {
  .bento-card { grid-column: span 3; }
  .bento-card--wide { grid-column: span 3; }
  .footer-main { grid-template-columns: repeat(3, 1fr); }
  .footer-brand { grid-column: 1 / -1; }
}

@media (max-width: 1020px) {
  .nav-links, .nav-cta .btn-ghost { display: none; }
  .site-header {
    background: #fff;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    border-bottom-color: var(--border);
  }
  .nav { justify-content: space-between; gap: 12px; }
  .nav-cta { gap: 8px; }
  .nav-burger {
    display: inline-flex; flex-direction: column; justify-content: center; gap: 5px;
    width: 42px; height: 42px; border-radius: var(--r-sm); background: var(--ink);
    align-items: center;
  }
  .nav-burger span { display: block; width: 18px; height: 2px; background: #fff; border-radius: 2px; transition: transform .2s ease, opacity .2s ease; }
  .nav-burger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
  .nav-burger.open span:nth-child(2) { opacity: 0; }
  .nav-burger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

  .hero-inner { grid-template-columns: 1fr; min-height: 0; padding-top: 40px; padding-bottom: 0; }
  .hero-line, .stage-tiles--tr, .stage-tiles--l { display: none; }
  .stage-tiles--b { bottom: -20px; left: -24px; right: -24px; height: 240px; }
  .hero-copy { text-align: center; display: flex; flex-direction: column; align-items: center; }
  .hero-sub { max-width: 560px; }
  .hero-actions { justify-content: center; width: 100%; }
  .hero-trust { justify-content: center; margin-top: 40px; }
  .hero-stage { height: auto; margin-top: 48px; padding-bottom: 56px; }
  .hero-crumb { position: static; display: flex; width: fit-content; margin: 0 auto 18px; }
  .hero-window { position: relative; top: 0; left: 0; right: 0; border-radius: 14px; border-right: 1px solid var(--border); }
  .hero-float { position: relative; top: 0; left: 0; z-index: 4; margin: 16px auto 0; max-width: 420px; min-width: 0; animation: none; }

  .steps { grid-template-columns: 1fr; gap: 44px; }
  .personas { grid-template-columns: repeat(2, 1fr); gap: 44px 40px; }
  .infra-badges { grid-template-columns: repeat(2, 1fr); }
  .infra-grid { grid-template-columns: repeat(2, 1fr); gap: 36px 28px; }
  .faq-grid { grid-template-columns: 1fr; }
  .faq-intro p { max-width: 60ch; }
}

@media (max-width: 720px) {
  .container { padding: 0 24px; }
  .hero-inner { padding-top: 32px; }
  .nav { height: 68px; }
  .nav-cta .btn-ink { display: none; }
  .mobile-menu { inset: 68px 0 auto 0; }
  .hero-float { padding: 14px 16px; gap: 12px; width: 100%; }
  .hero-float .svc-region { display: none; }
  .hero-float > div { min-width: 0; flex: 1; }
  .hero-float .svc-name { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  /* full width now, so the meta line no longer needs truncating */
  .hero-float .svc-meta { white-space: normal; }
  .hero-title { font-size: clamp(38px, 10.5vw, 46px); }
  .hero-actions { flex-direction: column; align-items: stretch; }
  .hero-actions .btn { width: 100%; }
  .hero-trust { gap: 14px 20px; }

  .stack-strip-inner { flex-direction: column; gap: 18px; }
  .stack-label { padding-left: 0; }

  .bento { grid-template-columns: minmax(0, 1fr); }
  .bento-card, .bento-card--wide { grid-column: auto; min-width: 0; }
  .bento-card { padding: 24px 20px 22px; }
  .bento-card > * { min-width: 0; max-width: 100%; }
  /* wide mono content scrolls in its own box rather than blowing out the card */
  .mock, .redis-term .redis-line, .bento-frame { max-width: 100%; }
  .mock { overflow-x: auto; -webkit-overflow-scrolling: touch; }
  .mock-logline { font-size: 10.5px; }
  .conn-s { max-width: 100%; }

  .personas { grid-template-columns: 1fr; gap: 40px; }

  /* three data columns don't fit a phone: let the table scroll in its own box
     at a width where nothing wraps mid-word, and keep the labels readable */
  .compare-wrap {
    overflow-x: auto; -webkit-overflow-scrolling: touch;
    margin-inline: -24px; padding-inline: 24px;
    scroll-snap-type: x proximity;
  }
  .compare { grid-template-columns: minmax(148px, 1.3fr) 1.15fr 1fr 1fr; min-width: 545px; }
  .cmp-cell, .cb-row, .cmp-cell--head, .cb-head { scroll-snap-align: start; }
  .rival-ico { width: 19px; height: 19px; }
  .rival-wordmark--heroku { font-size: 16px; }
  .cmp-cell { font-size: 12px; height: 64px; line-height: 1.35; }
  .cmp-cell--head { font-size: 12.5px; height: 76px; }
  .cmp-cell--label { padding-right: 10px; }
  .cmp-cell--rival { font-size: 11.5px; padding-right: 8px; }
  .compare-belmo { margin: -10px 10px 0 0; padding: 0 12px 10px; border-radius: var(--r-md); }
  .compare-belmo .cb-head { height: 86px; }
  .compare-belmo .cb-head img { height: 20px; }
  .compare-belmo .cb-row { height: 64px; font-size: 11.5px; gap: 6px; }
  .compare-belmo .cb-row svg { width: 11px; height: 11px; }

  .infra-badges { grid-template-columns: 1fr; }
  .infra-grid { grid-template-columns: repeat(2, 1fr); }

  .cta-tile { display: none; }

  /* Collapse the link columns into accordions — keeps every link, but the
     footer stops being a 40-row scroll on a phone. JS closes them at this width. */
  .footer-main { grid-template-columns: 1fr; gap: 0; padding-bottom: 28px; }
  .footer-brand { margin-bottom: 20px; }
  .footer-col { border-top: 1px solid #23262E; }
  .footer-col > summary {
    display: flex; align-items: center; justify-content: space-between;
    padding: 16px 0; cursor: pointer; -webkit-tap-highlight-color: transparent;
  }
  .footer-col > summary h5 { margin: 0; }
  .footer-col > summary::after {
    content: ""; width: 7px; height: 7px; margin-right: 6px;
    border-right: 1.6px solid #8E96A5; border-bottom: 1.6px solid #8E96A5;
    transform: translateY(-2px) rotate(45deg); transition: transform .2s ease;
  }
  .footer-col[open] > summary::after { transform: translateY(1px) rotate(-135deg); }
  .footer-col ul { padding-bottom: 20px; }
  .footer-bottom .container { flex-direction: column; gap: 6px; text-align: center; }
}

/* ============================================================
   Dark mode — data-theme stamped on <html> by inline head script
   (localStorage "belmo-theme", falls back to system preference)
   ============================================================ */

:root[data-theme="dark"] {
  color-scheme: dark;
  --ink: #EEF2F8;
  --body: #A6AEBD;
  --muted: #8B94A6;
  --faint: #626C80;
  --border: #232B39;
  --border-soft: #1F2632;
  --blue: #3B82F6;
  --blue-deep: #2563EB;
  --blue-tint: rgba(59, 130, 246, .16);
  --teal: #17B3A6;
  --green: #34C97B;
  --amber: #F0A34A;
  --red: #F16A6A;
  --bg: #0E1117;
  --bg-soft: #11161F;
  --bg-band: #10151D;
  --tile-line: #222A38;
  --footer-bg: #0B0E13;
  --footer-deep: #080A0E;
  --shadow-card: 0 1px 2px rgba(0, 0, 0, .3);
  --shadow-float: 0 12px 32px rgba(0, 0, 0, .45), 0 2px 8px rgba(0, 0, 0, .3);
  --shadow-window: 0 24px 64px rgba(0, 0, 0, .5), 0 4px 16px rgba(0, 0, 0, .35);
}

/* White logo in dark mode (blue monochrome SVG → white via filter) */
[data-theme="dark"] .brand-img { filter: brightness(0) invert(1); }

/* Theme toggle icon swap */
.theme-toggle .icon-sun { display: none; }
[data-theme="dark"] .theme-toggle .icon-sun { display: block; }
[data-theme="dark"] .theme-toggle .icon-moon { display: none; }

/* Buttons & chrome */
[data-theme="dark"] .btn-secondary { background: #1C2330; }
[data-theme="dark"] .btn-secondary:hover { background: #232B3B; }
[data-theme="dark"] .btn-secondary--solid { background: #1C2330; border-color: #2A3444; }
[data-theme="dark"] .btn-secondary--solid:hover { background: #232B3B; }
[data-theme="dark"] .btn-ghost:hover { background: #1C2330; }
[data-theme="dark"] .btn-ink { background: #EEF2F8; color: #12151B; }
[data-theme="dark"] .btn-ink:hover { background: #FFFFFF; }
[data-theme="dark"] .btn-icon { background: #1C2330; }
[data-theme="dark"] .btn-icon:hover { background: #242D3D; }
[data-theme="dark"] .site-header { background: rgba(14, 17, 23, .9); }
[data-theme="dark"] .nav-link:hover { background: #1C2330; }
[data-theme="dark"] .mobile-menu { background: var(--bg); }
[data-theme="dark"] .mobile-menu a.mm-link { border-bottom-color: #1B2230; }
[data-theme="dark"] .nav-burger { background: #EEF2F8; }
[data-theme="dark"] .nav-burger span { background: #12151B; }

/* Hero */
[data-theme="dark"] .hero { background: linear-gradient(180deg, #0E1117 0%, #10141C 100%); }
[data-theme="dark"] .tiles {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='72' height='72'%3E%3Crect x='1.5' y='1.5' width='69' height='69' rx='14' fill='none' stroke='%23222A38' stroke-width='1.5'/%3E%3C/svg%3E");
}
[data-theme="dark"] .stage-tiles {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='97' height='97'%3E%3Crect x='1' y='1' width='94' height='94' rx='18' fill='%23131824' stroke='%23242E3F' stroke-width='1.5'/%3E%3C/svg%3E");
}
[data-theme="dark"] .tile-logo { filter: grayscale(1) brightness(3); --tile-logo-peak: .09; }
[data-theme="dark"] .tile-hi { background: rgba(59, 130, 246, .10); border-color: rgba(59, 130, 246, .55); }
[data-theme="dark"] .tile-ghost { background: rgba(59, 130, 246, .15); }
[data-theme="dark"] .hero-crumb { background: #1A212D; border: 1px solid var(--border); }
[data-theme="dark"] .hero-window { background: #141924; }
[data-theme="dark"] .hero-window .svc { background: #171D28; border-color: #232C3B; }
[data-theme="dark"] .hero-float { background: #171D28; border-color: #242D3C; }
[data-theme="dark"] .svc-progress { background: rgba(59, 130, 246, .18); }

/* Shared mockup chrome */
[data-theme="dark"] .window-bar { border-bottom-color: #1F2735; }
[data-theme="dark"] .window-url { background: #10151F; border-color: #1F2735; }
[data-theme="dark"] .svc-pill--live { background: rgba(52, 201, 123, .14); }
[data-theme="dark"] .svc-pill--build { background: rgba(240, 163, 74, .14); }

/* Stack strip */
[data-theme="dark"] .stack-strip { background: #0F131B; }
[data-theme="dark"] .marquee-item { background: #151A23; border-color: #232B39; }
[data-theme="dark"] .marquee-item:hover { border-color: var(--blue); box-shadow: 0 2px 8px rgba(59, 130, 246, .18); }
/* near-black brand marks would vanish on the dark pills */
[data-theme="dark"] .ti-nextjs,
[data-theme="dark"] .ti-rust,
[data-theme="dark"] .ti-cursor-app,
[data-theme="dark"] .ti-express { color: #FFFFFF; }
[data-theme="dark"] .ti-django { color: #44B78B; }
[data-theme="dark"] .ti-python { color: #4B8BBE; }
[data-theme="dark"] .ti-ruby { color: #E0554E; }
[data-theme="dark"] .ti-rails { color: #E8352F; }

/* Bento */
[data-theme="dark"] .bento-card { background: #12161F; }
[data-theme="dark"] .bento-card:hover { border-color: #33405A; }
[data-theme="dark"] .bento-frame { background: #171C26; border-color: #222A38; }
[data-theme="dark"] .telegram-toast { background: #1C232F; }
[data-theme="dark"] .meter-bar { background: #232B3A; }
[data-theme="dark"] .commit { background: #171D28; border-color: #232C3B; }
[data-theme="dark"] .commit--current { border-color: var(--blue); }
[data-theme="dark"] .spec-row { border-bottom-color: #1F2735; }
[data-theme="dark"] .conn-chip .ci { background: rgba(23, 179, 166, .15); }
[data-theme="dark"] .redis-line .ln { color: #43506A; }
[data-theme="dark"] .logsearch { background: #10151F; border-color: #222A38; }
[data-theme="dark"] .domain-row { background: #171D28; border-color: #232C3B; }
[data-theme="dark"] .domain-row .di { background: rgba(23, 179, 166, .15); }
[data-theme="dark"] .domain-ok { background: rgba(52, 201, 123, .15); }

/* Steps */
[data-theme="dark"] .step-term { background: #131822; }

/* Comparison */
[data-theme="dark"] .cmp-cell { border-bottom-color: #1E2634; }
[data-theme="dark"] .cmp-cell--head { border-bottom-color: #1E2634; }
[data-theme="dark"] .ti-render { color: #FFFFFF; }
[data-theme="dark"] .rival-wordmark--heroku { color: #A78BFA; }
[data-theme="dark"] .compare-belmo { box-shadow: 0 20px 48px rgba(37, 99, 235, .18); }

/* Infra */
[data-theme="dark"] .infra-badge { background: #131822; }

/* FAQ */
[data-theme="dark"] .faq details { background: #12161F; }
[data-theme="dark"] .faq details[open] { border-color: #33405A; }

/* CTA */
[data-theme="dark"] .cta { background: linear-gradient(180deg, #10141C 0%, #0E1117 100%); }

/* Mobile header stays solid in dark */
@media (max-width: 1020px) {
  [data-theme="dark"] .site-header { background: var(--bg); border-bottom-color: var(--border); }
}
