/* ═══════════════════════════════════════════════
   COLOR TOKENS & SYSTEM
═══════════════════════════════════════════════ */
:root {
  --bg:           #0a0a0a;
  --bg-alt:       #101010;
  --bg-card:      rgba(15, 15, 15, 0.8);

  --surface:      rgba(10, 10, 10, 0.85);
  --surface-border: rgba(79, 195, 255, 0.18);

  --ink:          #f1f1f1;
  --ink-sub:      #cccccc;
  --ink-muted:    #888888;
  --ink-light:    #444444;

  /* Accent tokens preserved under legacy `--amber*` names
     so all existing rules pick up the new palette automatically. */
  --accent:       #4fc3ff;
  --accent-purple:#764ba2;
  --amber:        #4fc3ff;
  --amber-light:  #7dd8ff;
  --amber-dark:   #764ba2;

  --rule:         rgba(255, 255, 255, 0.07);
  --shadow:       0 20px 50px rgba(0, 0, 0, 0.6);

  /* the fonts are loaded by app/layout.tsx (next/font): headings, text,
     and the labels and readouts (telemetry, chips, tags, the terminal) */
  --font-serif:   var(--font-display), 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  --font-sans:    var(--font-body), 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  --font-mono:    var(--font-code), 'Courier New', monospace;

  --transition:   0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

/* ═══════════════════════════════════════════════
   RESET & BASE STYLES
═══════════════════════════════════════════════ */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  /* iOS shows this behind the body during elastic overscroll — keep it dark
     so a fast finger-flick past the last section can't flash white. */
  background-color: var(--bg);
  overscroll-behavior: none;
}

body {
  font-family: var(--font-sans);
  color: var(--ink);
  overflow-x: hidden;
  overscroll-behavior: none;
  transition: background-color var(--transition), color var(--transition);
}

::selection {
  background: var(--amber);
  color: #ffffff;
}

::-webkit-scrollbar {
  width: 8px;
}
::-webkit-scrollbar-track {
  background: rgba(255, 255, 255, 0.03);
}
::-webkit-scrollbar-thumb {
  background: var(--amber);
  border-radius: 10px;
}

/* ═══════════════════════════════════════════════
   CALCULATOR-FLANKING SIDE BUTTON RAILS
   Absolute inside #sticky-viewport so they stay
   pinned with the 3D calculator and scroll away
   naturally once the 3D beat ends.
═══════════════════════════════════════════════ */

/* ═══════════════════════════════════════════════
   STAGE & CANVAS PLAYER
═══════════════════════════════════════════════ */
#stage {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 5;
  pointer-events: none;
  background: transparent;
  transform-style: preserve-3d;
  transform-origin: center center;
  will-change: transform;
}

#calcCanvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
  z-index: 5;
  background: transparent;
}

/* Model-download spinner overlay — pinned to the sticky viewport, hidden
   once the first 3D frame is decoded so the canvas can take over. */
#model-loader {
  position: absolute;
  inset: 0;
  z-index: 90;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 18px;
  pointer-events: none;
  background: radial-gradient(closest-side, rgba(10,10,10,0.55), rgba(10,10,10,0));
  transition: opacity 0.4s ease, visibility 0s linear 0.4s;
}
#model-loader.hidden {
  opacity: 0;
  visibility: hidden;
}
#model-loader .spinner {
  width: 54px;
  height: 54px;
  border-radius: 50%;
  border: 3px solid rgba(255, 255, 255, 0.12);
  border-top-color: var(--amber);
  border-right-color: var(--amber);
  animation: modelSpin 0.9s linear infinite;
  box-shadow: 0 0 24px rgba(79, 195, 255, 0.25);
}
/* Lock page scroll while the 3D model is still streaming in.
   Removed automatically once all frames have been processed. */
html.model-loading,
html.model-loading body {
  overflow: hidden !important;
}

/* Persistent load progress pill — top of the sticky viewport, glass style.
   Visible from 0% to 100% so the user always sees load state even while the
   calc idle animation is looping underneath. Fades out on completion. */
#load-progress-chip {
  position: absolute;
  top: 22px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 95;
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 8px 16px;
  border-radius: 999px;
  background: rgba(10, 10, 10, 0.75);
  border: 1px solid rgba(79, 195, 255, 0.35);
  backdrop-filter: blur(12px);
  box-shadow: 0 6px 22px rgba(0, 0, 0, 0.55), 0 0 18px rgba(79, 195, 255, 0.18);
  pointer-events: none;
  transition: opacity 0.5s ease, transform 0.5s ease;
  will-change: opacity, transform;
}
#load-progress-chip.done {
  opacity: 0;
  transform: translateX(-50%) translateY(-16px);
}
#load-progress-chip .chip-label {
  font-family: var(--font-sans);
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: #cbd5e1;
}
#load-progress-chip .chip-bar {
  width: 140px;
  height: 4px;
  background: rgba(255, 255, 255, 0.09);
  border-radius: 999px;
  overflow: hidden;
}
#load-progress-chip .chip-fill {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, #4fc3ff, #764ba2);
  border-radius: 999px;
  transition: width 0.25s ease;
  box-shadow: 0 0 10px rgba(79, 195, 255, 0.55);
}
#load-progress-chip .chip-pct {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 700;
  color: #4fc3ff;
  min-width: 3.4ch;
  text-align: right;
}
/* "Load full mode": the full-resolution frames (useCalculator.ts keeps it
   until it's pressed or the chip goes). The chip lets clicks through; the button takes them. */
#load-progress-chip .chip-full {
  pointer-events: auto;
  appearance: none;
  margin: 0;
  padding: 5px 11px;
  font-family: var(--font-sans);
  font-size: 0.6rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  white-space: nowrap;
  color: #4fc3ff;
  background: rgba(79, 195, 255, 0.1);
  border: 1px solid rgba(79, 195, 255, 0.45);
  border-radius: 999px;
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease, box-shadow 0.2s ease;
}
#load-progress-chip .chip-full:hover,
#load-progress-chip .chip-full:focus-visible {
  color: #fff;
  background: linear-gradient(90deg, #4fc3ff, #764ba2);
  box-shadow: 0 0 14px rgba(79, 195, 255, 0.45);
}
#load-progress-chip .chip-full:focus-visible {
  outline: 2px solid #4fc3ff;
  outline-offset: 2px;
}
#load-progress-chip .chip-full[hidden],
#load-progress-chip.done .chip-full {
  display: none;
}
@media (max-width: 720px) {
  #load-progress-chip {
    top: 12px;
    padding: 6px 12px;
    gap: 8px;
  }
  /* under the chip, not beside it: the chip can't get wider without
     reaching the menu button on a phone */
  #load-progress-chip .chip-full {
    position: absolute;
    top: calc(100% + 6px);
    left: 50%;
    transform: translateX(-50%);
    padding: 5px 11px;
    font-size: 0.56rem;
    letter-spacing: 0.12em;
    background: rgba(10, 10, 10, 0.82);
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.5);
  }
  #load-progress-chip .chip-bar {
    width: 90px;
    height: 3px;
  }
  #load-progress-chip .chip-label {
    display: none;
  }
}

#model-loader .loader-label {
  font-family: var(--font-sans);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--ink-sub);
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.6);
}
@keyframes modelSpin {
  to { transform: rotate(360deg); }
}

#reticleCanvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
  z-index: 6;
}

/* ═══════════════════════════════════════════════
   GIANT 3D DEPTH TYPOGRAPHY SYSTEM
═══════════════════════════════════════════════ */
.depth-typography-container {
  position: absolute;
  inset: 0;
  width: 100vw;
  height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
  overflow: hidden;
}

#depth-typography-back {
  z-index: 3; /* Behind stage canvas (z-index: 5) */
}

#depth-typography-front {
  z-index: 6; /* In front of stage canvas (z-index: 5) */
}

.depth-title {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-family: var(--font-archivo), 'Archivo Black', var(--font-sans);
  font-weight: 900;
  line-height: 0.9;
  letter-spacing: -0.035em;
  text-transform: uppercase;
  text-align: center;
  white-space: nowrap;
  color: #ffffff;
  opacity: 0;
  visibility: hidden;
  will-change: transform, opacity;
  width: 100vw;
  padding: 0;
  box-sizing: border-box;
  user-select: none;
}

#title-more-colors, #title-more-colors-front {
  font-size: clamp(4.0rem, 12.1vw, 240px);
}

#title-more-control, #title-more-control-front {
  font-size: clamp(3.0rem, 9.6vw, 190px);
}

#title-more-protection, #title-more-protection-front {
  font-size: clamp(3.2rem, 9.15vw, 185px);
}

#title-know-love-op2, #title-know-love-op2-front,
#title-know-love-op4, #title-know-love-op4-front {
  font-size: clamp(2.2rem, 6.2vw, 120px);
  line-height: 1.02;
  letter-spacing: -0.035em;
  text-transform: uppercase;
  text-align: center;
  white-space: nowrap;
  padding: 0.2em 0.4em;
}

.depth-title-multiline .know-love-line1 {
  margin-bottom: 0.04em;
}

.depth-title-multiline .know-love-line2 {
  line-height: 1.15;
  padding-top: 0.05em;
}

/* ── UNIFIED SHARED WORD TYPOGRAPHY ACROSS ALL LAYERS (SOLID & STROKE) ── */
.word-silver { color: #C0BFBC; }
.word-calc { color: #ffffff; }
.word-know { color: #4fc3ff; text-shadow: 0 0 14px rgba(79, 195, 255, 0.35); }
.word-amp {
  font-family: var(--font-fraunces), 'Fraunces', 'Playfair Display', serif !important;
  font-style: italic !important;
  font-weight: 400 !important;
  font-size: 1.08em !important;
  color: #fb7185;
  margin: 0 0.08em;
  vertical-align: baseline;
  display: inline-block;
}
.word-love {
  font-family: var(--font-fraunces), 'Fraunces', serif !important;
  font-style: italic !important;
  font-weight: 900 !important;
  background: linear-gradient(135deg, #fda4af 0%, #fb7185 45%, #f43f5e 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  letter-spacing: -0.01em !important;
  display: inline-block;
  padding-top: 0.15em;
  padding-bottom: 0.10em;
  padding-right: 0.15em;
  margin-top: -0.15em;
  margin-bottom: -0.10em;
  margin-right: -0.15em;
  filter: drop-shadow(0 0 10px rgba(244, 63, 94, 0.35));
}

/* 4. MORE Word: #C0BFBC */
.word-more {
  color: #C0BFBC;
  display: inline;
}

/* 1. COLORS Individual Letter 50% White Mixes */
.word-colors {
  display: inline;
}
.col-c  { color: rgb(141, 175, 218); } /* #1A5FB4 50% mix with white */
.col-o1 { color: rgb(246, 153, 157); } /* #ED333B 50% mix with white */
.col-l  { color: rgb(128, 204, 255); } /* #0098FF 50% mix with white */
.col-o2 { color: rgb(255, 201, 237); } /* #FF92DA 50% mix with white */
.col-r  { color: rgb(204, 224, 248); } /* #99C1F1 50% mix with white */
.col-s  { color: rgb(255, 149, 225); } /* #FF2BC2 50% mix with white */

/* 2. Flourished Serif Font for CONTROL (Cinzel Decorative) */
.word-control {
  font-family: var(--font-cinzel), 'Cinzel Decorative', serif !important;
  font-style: normal !important;
  font-weight: 900 !important;
  text-transform: uppercase !important;
  font-size: 1.0em !important;
  letter-spacing: 0.015em !important;
  margin-left: 0.15em;
  vertical-align: baseline;
  display: inline-block;
}

/* 3. PROTECTION: Bold Heavy Color Shade */
.word-protection {
  color: #4fc3ff; /* Luminous metallic cyan/blue heavy hue */
  text-shadow: 0 0 35px rgba(79, 195, 255, 0.4);
  display: inline;
}

/* ── FRONT STROKE OVERRIDE: PERFECT MATCHING GLYPH STROKE ── */
.depth-title-stroke {
  color: transparent !important;
  -webkit-text-stroke: 3px rgba(255, 255, 255, 0.70) !important;
  -webkit-text-fill-color: transparent !important;
  background: none !important;
  -webkit-background-clip: unset !important;
  text-shadow: none !important;
  filter: none !important;
}
.depth-title-stroke * {
  color: transparent !important;
  -webkit-text-stroke: 3px rgba(255, 255, 255, 0.70) !important;
  -webkit-text-fill-color: transparent !important;
  background: none !important;
  -webkit-background-clip: unset !important;
  text-shadow: none !important;
  filter: none !important;
}

/* ── ALL IN THE CALCULATOR YOU KNOW & LOVE (FULL FRONT SOLID STATEMENT) ── */
.depth-title-front-solid {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-family: var(--font-archivo), 'Archivo Black', var(--font-sans);
  font-weight: 900;
  line-height: 1.02;
  letter-spacing: -0.035em;
  text-transform: uppercase;
  text-align: center;
  white-space: nowrap;
  z-index: 65;
  pointer-events: none;
  opacity: 0;
  visibility: hidden;
  font-size: clamp(2.2rem, 6.2vw, 120px);
  padding: 0.2em 0.4em;
  filter: drop-shadow(0 6px 16px rgba(0, 0, 0, 0.75));
}

.depth-title-front-solid .know-love-line1 {
  margin-bottom: 0.04em;
  display: block;
  white-space: nowrap;
}

.depth-title-front-solid .know-love-line1 .word-silver {
  display: inline;
  font-size: inherit;
  letter-spacing: inherit;
  color: #C0BFBC;
}

.depth-title-front-solid .know-love-line1 .word-calc {
  display: inline;
  font-size: inherit;
  letter-spacing: inherit;
  color: #ffffff;
}

.depth-title-front-solid .know-love-line2 {
  line-height: 1.15;
  padding-top: 0.05em;
  display: block;
  white-space: nowrap;
}

/* ═══════════════════════════════════════════════
   SCROLL CONTAINER TRACK
═══════════════════════════════════════════════ */
#scroll-track {
  position: relative;
  z-index: 2;
  /* 795 frames + 100vh curtain slide-over distance: 13200px for the old
     675, longer by the 120 graph frames so a frame keeps its scroll length */
  height: 15900px;
}

#sticky-viewport {
  position: sticky;
  top: 0;
  /* Use dvh where supported so mobile address-bar show/hide doesn't leave
     the calc rendered past the visible viewport (fixes "only see bottom
     half of the frame" on iOS/Android). */
  height: 100vh;
  height: 100dvh;
  overflow: hidden;
  pointer-events: none;
  z-index: 2;
  transition: opacity 0.25s linear;
}

/* ═══════════════════════════════════════════════
   SCREEN FEATURE CARD & ITEM HIGHLIGHT SYSTEM
═══════════════════════════════════════════════ */
.screen-card-large {
  width: min(834px, 43.5vw) !important;
  padding: 24px 30px !important;
  border-radius: 20px !important;
  background: rgba(11, 20, 36, 0.88) !important;
  border: 1px solid rgba(79, 195, 255, 0.22) !important;
  backdrop-filter: blur(20px) !important;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.6), inset 0 1px 1px rgba(255, 255, 255, 0.1);
}

.screen-feature-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 8px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding-top: 12px;
}

.feature-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 6px 10px;
  border-radius: 8px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1), scale 0.45s cubic-bezier(0.34, 1.56, 0.64, 1);
  cursor: pointer;
  pointer-events: auto;
  user-select: none;
}
@media (hover: hover) {
    .feature-item:hover {
      background: rgba(79, 195, 255, 0.08);
      transform: translateX(4px);
    }
}
@media (hover: hover) {
    .feature-item:hover .feature-label {
      color: #bae6fd;
    }
}
.feature-item:last-child {
  border-bottom: none;
}

.feature-bullet {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: #1e293b;
  border: 2px solid #475569;
  box-shadow: none;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  flex-shrink: 0;
}

.feature-label {
  font-family: var(--font-sans);
  font-size: 1.2rem;
  font-weight: 500;
  color: #475569;
  letter-spacing: -0.01em;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ACTIVE HIGHLIGHT STATE — Bright whitish text & cyan glowing bullet! */
.feature-item.active .feature-bullet {
  background: #4fc3ff;
  border-color: #e0f2fe;
  box-shadow: 0 0 14px rgba(79, 195, 255, 0.9), 0 0 4px #4fc3ff;
}

.feature-item.active .feature-label {
  color: #ffffff;
  font-weight: 700;
  text-shadow: 0 0 12px rgba(255, 255, 255, 0.4);
  transform: translateX(4px);
}

/* ═══════════════════════════════════════════════
   STORY CARDS SYSTEM & FULL-SCREEN VIEWPORT MASKING
═══════════════════════════════════════════════ */
#viewport-mask-left, #viewport-mask-right {
  position: fixed;
  inset: 0;
  width: 100vw;
  height: 100vh;
  pointer-events: none;
  z-index: 2;
}

.story-card {
  position: fixed;
  top: 50%;
  width: min(400px, 40vw);
  pointer-events: auto;
  will-change: transform;
}

/* Card 1: Left-aligned hero layout beside the centered calculator */
#card-1 {
  left: 5vw;
  right: auto;
  width: min(460px, 34vw);
  max-width: 480px;
  padding: 0 !important;
  background: transparent !important;
  border: none !important;
  box-shadow: none !important;
  backdrop-filter: none !important;
  transform: translateY(-50%);
  opacity: 0;
  visibility: hidden;
  display: flex;
  flex-direction: column;
  z-index: 10;
}

#card-1 .card-heading {
  font-family: var(--font-serif);
  font-size: clamp(2.4rem, 3.4vw, 3.4rem);
  line-height: 1.08;
  font-weight: 800;
  letter-spacing: -0.025em;
  color: #ffffff;
  margin-bottom: 18px;
  max-width: 100%;
}

/* Big brand logo pinned over the calculator in the center of #stage.
   Fades out on scroll past the hero beat (see updateCardBeatsAndMasking). */
#hero-logo {
  position: absolute;
  top: 50%;
  right: 6vw;
  left: auto;
  transform: translateY(-50%);
  width: clamp(220px, 24vw, 380px);
  height: auto;
  z-index: 6;
  pointer-events: none;
  filter: drop-shadow(0 18px 48px rgba(79, 195, 255, 0.45)) drop-shadow(0 0 24px rgba(118, 75, 162, 0.25));
  transition: opacity 0.35s ease, transform 0.35s ease;
  will-change: opacity, transform;
}
@media (max-width: 900px) {
  #hero-logo {
    display: none !important;
  }
}

#card-1 .card-heading em {
  font-style: italic;
  color: #4fc3ff;
}

#card-1 .card-description {
  font-size: 1.02rem;
  line-height: 1.6;
  color: #a0a0a0;
  max-width: 100%;
  margin-bottom: 24px;
}

/* Hero Right-Side Telemetry HUD Deck */
#hero-telemetry-right {
  position: absolute;
  top: 50%;
  right: 5vw;
  transform: translateY(-50%);
  width: min(300px, 23vw);
  display: flex;
  flex-direction: column;
  gap: 10px;
  z-index: 10;
  pointer-events: auto;
  transition: opacity 0.3s ease, transform 0.3s ease;
}

.hero-telemetry-header {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 4px 4px 4px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  margin-bottom: 2px;
}

.telemetry-radar-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #10b981;
  box-shadow: 0 0 8px #10b981;
  animation: radarPulse 1.8s infinite ease-in-out;
}
@keyframes radarPulse {
  0%, 100% { opacity: 0.5; transform: scale(0.9); }
  50% { opacity: 1; transform: scale(1.3); }
}

.telemetry-hdr-title {
  font-family: var(--font-mono);
  font-size: 0.60rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: #a0a0a0;
}

#hero-telemetry-right .hw-metric-card {
  background: rgba(11, 20, 36, 0.82);
  border: 1px solid rgba(79, 195, 255, 0.22);
  backdrop-filter: blur(20px);
  padding: 12px 16px;
  border-radius: 14px;
  box-shadow: 0 12px 30px rgba(0,0,0,0.5);
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}
@media (hover: hover) {
    #hero-telemetry-right .hw-metric-card:hover {
      background: rgba(18, 32, 58, 0.88);
      border-color: rgba(79, 195, 255, 0.5);
      transform: translateX(-4px);
      box-shadow: 0 15px 35px rgba(0,0,0,0.7), 0 0 15px rgba(79, 195, 255, 0.15);
    }
}

.hw-metric-sub {
  font-family: var(--font-mono);
  font-size: 0.56rem;
  color: #64748b;
  letter-spacing: 0.04em;
  margin-top: 3px;
}

.hero-telemetry-strip {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding-top: 8px;
  margin-top: 4px;
  display: flex;
  flex-direction: column;
  gap: 5px;
  padding-left: 4px;
  padding-right: 4px;
}

.telemetry-strip-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-family: var(--font-mono);
  font-size: 0.58rem;
}
.telemetry-strip-row .strip-key {
  color: #64748b;
  letter-spacing: 0.08em;
}
.telemetry-strip-row .strip-val {
  color: #bae6fd;
  font-weight: 500;
}

/* Card 2: left side
   Opaque surface (z-index: 20) so as it slides out from under the calculator,
   it physically covers / eats Card 1 underneath (z-index: 10) with ZERO fading. */
#card-2 {
  left: 5vw;
  /* Right edge must stay left of L_A dividing line, which dips to ~33vw
     during frames 114-161. width caps so left+width <= 32vw on every
     desktop breakpoint (1200-1920px+) while leaving room for the 2x2
     metrics grid (~150px per cell). */
  width: min(360px, 27vw);
  padding: 28px 22px 24px !important;
  border-radius: 20px !important;
  background: #080f1e !important;
  border: 1px solid rgba(79, 195, 255, 0.35) !important;
  backdrop-filter: blur(24px) saturate(180%) !important;
  box-shadow: 0 25px 60px rgba(0,0,0,0.95), inset 0 1px 1px rgba(255,255,255,0.15) !important;
  visibility: hidden;
  transform: translateY(-50%) translateX(24vw);
  display: flex;
  flex-direction: column;
  z-index: 20;
}

.card-header-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(79, 195, 255, 0.1);
  border: 1px solid rgba(79, 195, 255, 0.25);
  padding: 4px 10px;
  border-radius: 100px;
  width: fit-content;
  margin-bottom: 14px;
}

.badge-pulse-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #4fc3ff;
  box-shadow: 0 0 8px #4fc3ff;
}

.badge-text {
  font-family: var(--font-mono);
  font-size: 0.62rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: #7dd8ff;
  font-weight: 600;
}

#card-2 .card-heading {
  font-size: 2.15rem !important;
  line-height: 1.12 !important;
  font-weight: 800 !important;
  margin-bottom: 12px !important;
  letter-spacing: -0.02em !important;
}

#card-2 .card-description {
  font-size: 0.88rem !important;
  line-height: 1.55 !important;
  color: #a0a0a0 !important;
  margin-bottom: 20px !important;
}

/* Modernized Hardware Metric Cards Grid */
.hw-metrics-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-bottom: 18px;
}

.hw-metric-card {
  background: rgba(15, 23, 42, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  padding: 12px 14px;
  transition: border-color 0.2s, background 0.2s;
}

@media (hover: hover) {
    .hw-metric-card:hover {
      background: rgba(30, 41, 59, 0.7);
      border-color: rgba(79, 195, 255, 0.4);
    }
}

.hw-metric-val {
  font-family: var(--font-serif);
  font-size: 1.35rem;
  font-weight: 800;
  color: #ffffff;
  line-height: 1;
  margin-bottom: 4px;
  display: flex;
  align-items: baseline;
  gap: 4px;
}

.hw-metric-val span {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  color: #4fc3ff;
  font-weight: 600;
}

.hw-metric-label {
  font-family: var(--font-mono);
  font-size: 0.60rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #64748b;
}

/* Architectural Spec Strip at Bottom */
.hw-spec-strip {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding-top: 14px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.hw-spec-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-family: var(--font-mono);
  font-size: 0.62rem;
  color: #a0a0a0;
}

.hw-spec-row .spec-key {
  color: #64748b;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.hw-spec-row .spec-val {
  color: #bae6fd;
  font-weight: 500;
}

/* ── CARD 3 ARTISTIC REFINEMENT ── */
.ai-chip-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 12px;
  width: 100%;
}

.ai-chip-card {
  background: rgba(15, 23, 42, 0.65);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  padding: 10px 12px;
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 10px;
  transition: all 0.25s ease;
  min-width: 0;
  overflow: hidden;
}

.ai-chip-logo {
  width: 32px;
  height: 32px;
  flex-shrink: 0;
  object-fit: contain;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.06);
  padding: 4px;
  filter: drop-shadow(0 2px 6px rgba(0, 0, 0, 0.4));
}

.ai-chip-card.active .ai-chip-logo {
  background: rgba(79, 195, 255, 0.14);
  box-shadow: 0 0 12px rgba(79, 195, 255, 0.35);
}

.ai-chip-body {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
  flex: 1 1 0;
  overflow: hidden;
}

.ai-chip-card.active {
  background: rgba(14, 165, 233, 0.12);
  border-color: rgba(79, 195, 255, 0.5);
  box-shadow: 0 0 16px rgba(79, 195, 255, 0.15);
}

.ai-chip-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.ai-chip-name {
  font-family: var(--font-mono);
  font-size: 0.82rem;
  font-weight: 700;
  color: #ffffff;
  letter-spacing: -0.01em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
  display: block;
}

.ai-chip-card.active .ai-chip-name {
  color: #4fc3ff;
}

.ai-chip-tag {
  font-family: var(--font-mono);
  font-size: 0.55rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  padding: 2px 6px;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.06);
  color: #a0a0a0;
  align-self: flex-start;
  max-width: 100%;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.ai-chip-card.active .ai-chip-tag {
  background: #764ba2;
  color: #ffffff;
}

.ai-chip-sub {
  font-family: var(--font-mono);
  font-size: 0.60rem;
  color: #64748b;
  letter-spacing: 0.05em;
}

/* ── AI PROVIDER ORBIT (Card 3 slide 2) ───── */
.ai-orbit-wrap {
  position: relative;
  width: 100%;
  aspect-ratio: 1;
  max-width: 340px;
  margin: 26px auto 6px;
  --orbit-r: 132px;
  --orbit-node: 58px;
}

.ai-orbit-svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  overflow: visible;
}

.ai-orbit-svg .ai-orbit-lines,
.ai-orbit-ring {
  transform-origin: 50% 50%;
  animation: aiOrbitSpin 22s linear infinite;
}

.ai-orbit-ring {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.ai-orbit-node {
  position: absolute;
  top: 50%;
  left: 50%;
  width: var(--orbit-node);
  height: var(--orbit-node);
  margin-top: calc(var(--orbit-node) / -2);
  margin-left: calc(var(--orbit-node) / -2);
  transform: rotate(var(--angle)) translateY(calc(var(--orbit-r) * -1));
}

.ai-orbit-icon {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  background: rgba(15, 23, 42, 0.9);
  border: 1px solid rgba(79, 195, 255, 0.45);
  box-shadow: 0 0 14px rgba(79, 195, 255, 0.22), inset 0 0 10px rgba(118, 75, 162, 0.18);
  display: flex;
  align-items: center;
  justify-content: center;
  transform-origin: 50% 50%;
  animation: aiOrbitCounter 22s linear infinite;
}

.ai-orbit-icon img {
  width: 62%;
  height: 62%;
  object-fit: contain;
  /* the node is turned to its place on the ring (--angle) and the icon
     undoes the ring's spin; this undoes the node's turn, so every logo
     stands upright wherever it sits */
  transform: rotate(calc(-1 * var(--angle, 0deg)));
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.55));
}

.ai-orbit-center {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 78px;
  height: 78px;
  margin: -39px 0 0 -39px;
  border-radius: 50%;
  background: radial-gradient(circle at 50% 40%, rgba(79, 195, 255, 0.32) 0%, rgba(15, 23, 42, 0.95) 70%);
  border: 1px solid rgba(79, 195, 255, 0.6);
  box-shadow: 0 0 26px rgba(79, 195, 255, 0.35), inset 0 0 20px rgba(118, 75, 162, 0.35);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2;
}

.ai-orbit-center img {
  width: 60%;
  height: 60%;
  object-fit: contain;
  filter: drop-shadow(0 2px 6px rgba(0, 0, 0, 0.6));
}

@keyframes aiOrbitSpin {
  from { transform: rotate(0deg); }
  to   { transform: rotate(360deg); }
}
@keyframes aiOrbitCounter {
  from { transform: rotate(0deg); }
  to   { transform: rotate(-360deg); }
}

@media (prefers-reduced-motion: reduce) {
  .ai-orbit-svg .ai-orbit-lines,
  .ai-orbit-ring,
  .ai-orbit-icon {
    animation: none;
  }
}

/* Card 3: Merged Screen LaTeX/Markdown & Multi-Model AI Card */
#card-3 {
  right: 6vw;
  left: auto;
  width: min(834px, 43.5vw);
  padding: 24px 30px !important;
  visibility: hidden;
  transform: translateY(-50%) translateX(-35vw);
}

/* Card-3 uses an overlapping grid so both slides share the same cell,
   the outer card auto-sizes to the taller slide, and no content is clipped. */
.card-internal-viewport {
  position: relative;
  width: 100%;
}

.card-internal-slider {
  display: grid;
  grid-template-columns: 1fr;
  width: 100%;
}

.card-slide {
  grid-column: 1;
  grid-row: 1;
  width: 100%;
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  will-change: opacity;
  transition: opacity 0.25s ease;
  pointer-events: auto;
}

#card-3 .card-heading {
  font-family: var(--font-serif) !important;
  font-size: 2.15rem !important;
  line-height: 1.12 !important;
  font-weight: 800 !important;
  letter-spacing: -0.02em !important;
  color: #ffffff !important;
  margin-bottom: 10px !important;
}
#card-3 .card-heading em {
  font-style: italic;
  color: #4fc3ff;
}

#card-3 .card-description {
  font-size: 0.92rem !important;
  line-height: 1.55 !important;
  color: #a0a0a0 !important;
  max-width: 100% !important;
  margin-bottom: 14px !important;
}

/* Cards 4,5: right side */
#card-4, #card-5 {
  right: 6vw;
  left: auto;
  width: min(440px, 38vw);
  visibility: hidden;
  transform: translateY(-50%) translateX(-35vw);
}

.card-glass {
  background: var(--surface);
  backdrop-filter: blur(32px) saturate(180%);
  border: 1px solid var(--surface-border);
  border-radius: 6px;
  padding: 30px 34px;
  box-shadow: var(--shadow);
  transition: background var(--transition), border-color var(--transition), box-shadow var(--transition);
}

.card-tag {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--amber);
  margin-bottom: 14px;
  display: block;
}

.card-heading {
  font-family: var(--font-serif);
  font-size: 1.8rem;
  font-weight: 800;
  line-height: 1.18;
  color: var(--ink);
  margin-bottom: 14px;
}
.card-heading em {
  font-style: italic;
  color: var(--amber);
}

.card-description {
  font-size: 0.9rem;
  line-height: 1.75;
  color: var(--ink-sub);
  margin-bottom: 24px;
}

.card-stats-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-top: 20px;
  padding-top: 20px;
  border-top: 1px solid var(--rule);
}
.stat-box {
  display: flex;
  flex-direction: column;
}
.stat-val {
  font-family: var(--font-serif);
  font-size: 1.35rem;
  font-weight: 800;
  color: var(--ink);
}
.stat-key {
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-muted);
  margin-top: 2px;
}

.math-terminal {
  background: #060913;
  color: #e2e8f0;
  border: 1px solid rgba(255, 255, 255, 0.08);
  font-family: var(--font-mono);
  font-size: 0.78rem;
  line-height: 1.8;
  padding: 20px 22px;
  border-radius: 4px;
  margin-top: 18px;
}
.math-terminal .dim { color: #64748b; }
.math-terminal .highlight { color: #4fc3ff; font-weight: 600; }
.math-terminal .success { color: #34d399; }

.card-buttons {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

/* the hero's six buttons wrapped 2, 3 and then "Docs" alone; on a screen
   wide enough for "Shop Calculators" in half the row they're three even
   pairs (below that, and on phones, they wrap as before) */
@media (min-width: 1100px) {
  #card-1 .card-buttons {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    max-width: 420px;
  }

  #card-1 .card-buttons > a {
    text-align: center;
    white-space: nowrap;
    padding-inline: 14px;
  }
}

/* narrower: each row's buttons stretch to its full width, so the rows line up */
@media (min-width: 901px) and (max-width: 1099px) {
  #card-1 .card-buttons > a {
    flex: 1 1 auto;
    text-align: center;
  }
}

.btn-main {
  font-family: var(--font-sans);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #f1f1f1;
  background: #0a0a0a;
  border: 1px solid rgba(79, 195, 255, 0.3);
  padding: 12px 28px;
  cursor: pointer;
  border-radius: 3px;
  transition: all 0.2s, scale 0.45s cubic-bezier(0.34, 1.56, 0.64, 1);
  text-decoration: none;
  display: inline-block;
}
@media (hover: hover) {
    .btn-main:hover {
      background: #764ba2;
      border-color: #764ba2;
      color: #ffffff;
      transform: translateY(-2px);
    }
}

.btn-dash {
  font-family: var(--font-sans);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #ffffff;
  background: linear-gradient(135deg, #764ba2 0%, #1a0a2e 100%);
  border: 1px solid #764ba2;
  padding: 12px 28px;
  cursor: pointer;
  border-radius: 3px;
  transition: all 0.2s, scale 0.45s cubic-bezier(0.34, 1.56, 0.64, 1);
  text-decoration: none;
  display: inline-block;
  box-shadow: 0 4px 14px rgba(118, 75, 162, 0.35);
}
@media (hover: hover) {
    .btn-dash:hover {
      background: linear-gradient(135deg, #8a5cbf 0%, #0a0a0a 100%);
      transform: translateY(-2px);
      box-shadow: 0 6px 20px rgba(118, 75, 162, 0.55);
    }
}

.btn-outline {
  font-family: var(--font-sans);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-sub);
  background: transparent;
  border: 1px solid var(--rule);
  padding: 12px 24px;
  cursor: pointer;
  border-radius: 3px;
  transition: all 0.2s, scale 0.45s cubic-bezier(0.34, 1.56, 0.64, 1);
  text-decoration: none;
  display: inline-block;
}
@media (hover: hover) {
    .btn-outline:hover {
      border-color: var(--amber);
      color: var(--amber);
    }
}

/* ═══════════════════════════════════════════════
   PROGRESS BAR & SCROLL CUE
═══════════════════════════════════════════════ */
#progress-track {
  position: absolute;
  bottom: 0; left: 0; right: 0;
  height: 3px;
  background: var(--rule);
  z-index: 999 !important;
}
#progress-bar {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, var(--amber-dark), var(--amber));
  transition: width 0.05s linear;
}

#scroll-cue {
  position: absolute;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 6px 14px;
  background: transparent;
  border: none;
  z-index: 30;
  pointer-events: none;
  transition: opacity 0.4s cubic-bezier(0.4, 0, 0.2, 1), transform 0.4s;
}
#scroll-cue.hidden {
  opacity: 0;
  transform: translateX(-50%) translateY(10px);
}

.cue-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #4fc3ff;
  box-shadow: 0 0 8px #4fc3ff, 0 0 16px rgba(79, 195, 255, 0.6);
  animation: cuePulseDot 1.8s infinite alternate ease-in-out;
}
@keyframes cuePulseDot {
  0% { transform: scale(0.8); opacity: 0.6; }
  100% { transform: scale(1.3); opacity: 1; }
}

.cue-label {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: #ffffff;
  text-shadow: 0 0 10px rgba(79, 195, 255, 0.85), 0 0 22px rgba(79, 195, 255, 0.45);
  white-space: nowrap;
}

.cue-arrow {
  display: flex;
  align-items: center;
  justify-content: center;
  color: #4fc3ff;
  filter: drop-shadow(0 0 6px #4fc3ff);
  animation: cueArrowBounce 1.6s infinite ease-in-out;
}
@keyframes cueArrowBounce {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(3px); }
}

/* ── REASSEMBLE CINEMATIC TAGLINE (Frames 388-464) ── */
.reassemble-tagline-container {
  position: absolute;
  bottom: 7vh;
  left: 50%;
  transform: translateX(-50%);
  text-align: center;
  z-index: 50;
  pointer-events: none;
  opacity: 0;
  visibility: hidden;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}
.reassemble-tagline-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 14px;
  background: rgba(15, 23, 42, 0.82);
  border: 1px solid rgba(79, 195, 255, 0.4);
  border-radius: 999px;
  backdrop-filter: blur(10px);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.6);
  font-family: var(--font-mono);
  font-size: 0.65rem;
  letter-spacing: 0.14em;
  color: #4fc3ff;
  text-transform: uppercase;
}
.reassemble-tagline-title {
  font-family: var(--font-serif);
  font-size: clamp(1.4rem, 2.6vw, 2.3rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  color: #f1f1f1;
  text-shadow: 0 4px 24px rgba(0, 0, 0, 0.95), 0 0 35px rgba(79, 195, 255, 0.35);
  margin: 0;
  white-space: nowrap;
}
.reassemble-tagline-title em {
  font-style: italic;
  color: #4fc3ff;
  font-family: var(--font-serif);
}

/* ═══════════════════════════════════════════════
   BELOW-SCROLL SECTIONS
═══════════════════════════════════════════════ */
.content-section {
  position: relative;
  z-index: 2;
  background: var(--bg);
  transition: background var(--transition);
}
.content-section.alt {
  background: var(--bg-alt);
}

.container {
  max-width: 1140px;
  margin: 0 auto;
  padding: 96px 48px;
}

.section-header-centered {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  margin: 0 auto 48px auto;
  max-width: 760px;
}

.section-tag {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(79, 195, 255, 0.1);
  border: 1px solid rgba(79, 195, 255, 0.25);
  padding: 4px 12px;
  border-radius: 100px;
  width: fit-content;
  margin: 0 auto 16px auto;
  font-family: var(--font-mono);
  font-size: 0.65rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: #7dd8ff;
  font-weight: 700;
}

.section-title {
  font-family: var(--font-serif);
  font-size: clamp(2.2rem, 3.8vw, 3.2rem);
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.02em;
  color: #ffffff;
  margin: 0 auto 16px auto;
  max-width: 26ch;
  text-align: center;
  text-wrap: balance;
}
.section-title em {
  font-style: italic;
  color: #4fc3ff;
}

.section-sub {
  font-size: 1.0rem;
  line-height: 1.7;
  color: #a0a0a0;
  max-width: 58ch;
  text-align: center;
  margin: 0 auto 48px auto;
}

/* ═══════════════════════════════════════════════
   INSIDE THE DEVICE SHOWCASE SECTION (CALC.NINJA 1:1 STYLE)
═══════════════════════════════════════════════ */
.chapter-info {
  z-index: 80;
  position: relative;
  margin-top: -100vh; /* Slides smoothly UP OVER the pinned 3D canvas */
  border-top: 1px solid rgba(79, 195, 255, 0.22);
  border-top-left-radius: clamp(24px, 3.5vw, 40px);
  border-top-right-radius: clamp(24px, 3.5vw, 40px);
  box-shadow: 0 -4px 12px rgba(0, 0, 0, 0.4);
  background: radial-gradient(60% 50% at 50% 18%, rgba(79, 195, 255, 0.16), rgba(0, 0, 0, 0) 65%),
              radial-gradient(70% 40% at 50% 100%, rgba(118, 75, 162, 0.06), rgba(0, 0, 0, 0) 60%),
              linear-gradient(rgb(10, 10, 10) 0%, rgb(12, 12, 12) 50%, rgb(8, 8, 8) 100%);
  grid-template-rows: auto auto;
  place-items: center;
  gap: clamp(40px, 6vh, 60px);
  padding: clamp(96px, 14vh, 160px) clamp(24px, 6vw, 96px);
  display: grid;
}

/* Bare variant: keeps the slide-up-over-canvas behavior but drops the
   black background panel and section header — only the sliding cards render. */
.chapter-info-bare {
  z-index: 80;
  position: relative;
  margin-top: -100vh;
  background: transparent;
  border: none;
  box-shadow: none;
  padding: clamp(80px, 12vh, 140px) clamp(24px, 6vw, 96px);
  display: block;
}

.info-intro {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  width: min(720px, 100%);
  margin: 0 auto;
}
.info-intro .section-sub {
  margin-bottom: 0;
}

.info-features {
  display: flex;
  flex-direction: column;
  gap: 36px;
  width: min(940px, 100%);
  margin: 0px auto;
  padding: 0px;
  list-style: none;
}

.feature-row {
  text-align: left;
  isolation: isolate;
  grid-template-columns: 240px 1fr;
  align-items: center;
  gap: clamp(28px, 4vw, 54px);
  padding: clamp(28px, 3.8vh, 44px) clamp(24px, 3vw, 40px);
  background: rgba(10, 10, 10, 0.55);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 24px;
  box-shadow: 0 16px 36px -12px rgba(0, 0, 0, 0.5), inset 0 1px 0 rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(16px);
  transition: border-color 0.35s ease, box-shadow 0.35s ease, background 0.35s ease;
  display: grid;
  position: relative;
  overflow: hidden;
  will-change: transform;
  transform-style: preserve-3d;
}

.feature-row::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(400px circle at var(--shine-x, 50%) var(--shine-y, 50%), color-mix(in srgb, var(--feature-accent, #74e6ff) 12%, transparent) 0%, transparent 70%);
  opacity: 0;
  transition: opacity 0.4s ease;
  pointer-events: none;
  z-index: 0;
}

@media (hover: hover) {
    .feature-row:hover::before {
      opacity: 1;
    }
}

@media (hover: hover) {
    .feature-row:hover {
      border-color: color-mix(in srgb, var(--feature-accent, #74e6ff) 40%, rgba(255, 255, 255, 0.15));
      box-shadow: 0 20px 48px -12px color-mix(in srgb, var(--feature-accent, #74e6ff) 18%, rgba(0, 0, 0, 0.7)),
              inset 0 1px 0 rgba(255, 255, 255, 0.2);
    }
}

/* Alternating Zigzag Layout (Even rows: Text on Left, Visual on Right) */
.feature-row.row-reverse {
  grid-template-columns: 1fr 240px;
}
.feature-row.row-reverse .feature-glyph {
  order: 2;
}
.feature-row.row-reverse .feature-text {
  order: 1;
}

.feature-glyph {
  min-height: 140px;
  justify-content: center;
  align-items: center;
  display: flex;
  position: relative;
  z-index: 1;
}

.feature-text {
  flex-direction: column;
  display: flex;
  position: relative;
  z-index: 1;
}

.feature-text .feature-kicker {
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--feature-accent, #74e6ff);
  margin: 0px 0px 8px;
  font-size: 11px;
  font-weight: 750;
  line-height: 1.2;
  font-family: var(--font-mono);
  display: flex;
  align-items: center;
  gap: 8px;
}
.feature-kicker-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
  box-shadow: 0 0 8px currentColor;
}

.feature-text h3 {
  letter-spacing: -0.018em;
  color: #ffffff;
  text-wrap: balance;
  margin: 0px 0px 10px;
  font-size: clamp(21px, 2.1vw, 26px);
  font-weight: 750;
  line-height: 1.22;
  font-family: var(--font-serif);
}

.feature-text p {
  color: rgba(220, 238, 255, 0.68);
  max-width: 50ch;
  margin: 0px;
  font-size: 14.5px;
  font-weight: 450;
  line-height: 1.62;
  font-family: var(--font-sans);
}

.feature-snap  { --feature-accent: #74e6ff; }
.feature-panic { --feature-accent: #ff9f43; }
.feature-chat  { --feature-accent: #c084fc; }
.feature-web   { --feature-accent: #82e7c1; }
.feature-wifi  { --feature-accent: #88d6ff; }
.feature-notes { --feature-accent: #ffd986; }

/* ── 1 & 2: AUTHENTIC TI-84 LCD SCREEN BEZEL ─── */
.lcd-mini {
  border-radius: 10px;
  width: 190px;
  position: relative;
  overflow: hidden;
  box-shadow: rgba(160, 200, 150, 0.22) 0px 0px 0px 1px,
              rgba(0, 0, 0, 0.6) 0px 14px 28px -8px,
              rgba(120, 180, 110, 0.25) 0px 0px 24px -4px;
  aspect-ratio: 96 / 64;
  background: #5b6f54;
  border: 2px solid rgba(255, 255, 255, 0.12);
}
.lcd-mini .screen-video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.lcd-mini::after {
  content: "";
  pointer-events: none;
  background-image: radial-gradient(120% 100%, rgba(0, 0, 0, 0) 60%, rgba(0, 0, 0, 0.22) 100%),
                    repeating-linear-gradient(0deg, rgba(0, 0, 0, 0.05) 0px, rgba(0, 0, 0, 0.05) 1px, transparent 1px, transparent 3px);
  position: absolute;
  inset: 0px;
}

/* ── 3: REFINED DUAL-BUBBLE CHAT CLIPART ─────── */
.clipart-chat-card {
  width: 215px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 4px;
}
.chat-bubble-row {
  display: flex;
  align-items: flex-end;
  gap: 8px;
}
.chat-bubble-self {
  justify-content: flex-end;
}
.chat-bubble-peer {
  justify-content: flex-start;
}
.chat-avatar {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: linear-gradient(135deg, #334155, #1e293b);
  border: 1px solid rgba(255, 255, 255, 0.18);
  color: #a0a0a0;
  font-size: 10px;
  font-weight: 750;
  display: grid;
  place-items: center;
  flex-shrink: 0;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
}
.chat-avatar-self {
  background: linear-gradient(135deg, #a855f7, #6366f1);
  color: #ffffff;
  font-size: 9.5px;
}
.chat-bubble-body {
  padding: 8px 12px;
  max-width: 155px;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.35);
  backdrop-filter: blur(8px);
}
.chat-bubble-self .chat-bubble-body {
  background: linear-gradient(135deg, rgba(168, 85, 247, 0.5), rgba(99, 102, 241, 0.45));
  border: 1px solid rgba(192, 132, 252, 0.4);
  border-radius: 14px 14px 2px 14px;
}
.chat-bubble-peer .chat-bubble-body {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 14px 14px 14px 2px;
}
.chat-author {
  font-size: 9px;
  font-weight: 750;
  color: #a0a0a0;
  display: block;
  margin-bottom: 2px;
  font-family: var(--font-mono);
  letter-spacing: 0.04em;
}
.chat-msg {
  font-size: 11.5px;
  font-weight: 500;
  line-height: 1.35;
  color: #ffffff;
  margin: 0;
}

/* ── 4: HARDWARE MOCKUP (LAPTOP + PHONE) ──────── */
.device-mock-mini {
  transform-origin: 50% center;
  gap: 12px;
  transform: scale(0.95);
}
.device-mock-row {
  justify-content: center;
  align-items: flex-end;
  gap: 16px;
  width: 100%;
  display: flex;
}
.device-laptop {
  filter: drop-shadow(rgba(0, 0, 0, 0.5) 0px 14px 24px);
  flex: 0 0 auto;
  width: 185px;
  position: relative;
}
.laptop-screen {
  background: linear-gradient(rgb(28, 38, 50) 0%, rgb(13, 20, 28) 100%);
  border-width: 1px 1px medium;
  border-style: solid solid none;
  border-color: rgba(255, 255, 255, 0.12) rgba(255, 255, 255, 0.12) currentcolor;
  border-radius: 10px 10px 3px 3px;
  place-items: center;
  width: 100%;
  height: 118px;
  display: grid;
  position: relative;
  overflow: hidden;
  box-shadow: rgba(255, 255, 255, 0.18) 0px 1px inset, rgb(10, 17, 24) 0px 0px 0px 5px inset;
}
.laptop-lip {
  background: linear-gradient(rgb(42, 50, 61), rgb(22, 28, 37));
  border-left: 1px solid rgba(255, 255, 255, 0.08);
  border-right: 1px solid rgba(255, 255, 255, 0.08);
  height: 4px;
}
.laptop-base {
  background: linear-gradient(rgb(58, 66, 80) 0%, rgb(26, 32, 41) 100%);
  border-radius: 0px 0px 6px 6px;
  width: 116%;
  height: 7px;
  margin-left: -8%;
  position: relative;
  box-shadow: rgba(255, 255, 255, 0.08) 0px 1px inset;
}
.laptop-base::after {
  content: "";
  background: rgba(0, 0, 0, 0.45);
  border-radius: 0px 0px 4px 4px;
  width: 36px;
  height: 3px;
  position: absolute;
  top: 0px;
  left: 50%;
  transform: translate(-50%);
}
.device-phone {
  filter: drop-shadow(rgba(0, 0, 0, 0.5) 0px 12px 18px);
  background: linear-gradient(160deg, rgb(42, 50, 61) 0%, rgb(26, 32, 41) 100%);
  border-radius: 14px;
  flex: 0 0 auto;
  width: 60px;
  height: 124px;
  padding: 4px;
  position: relative;
  box-shadow: rgba(255, 255, 255, 0.18) 0px 1px inset, rgba(255, 255, 255, 0.08) 0px 0px 0px 1px inset;
}
.phone-screen {
  background: linear-gradient(rgb(14, 21, 29) 0%, rgb(6, 11, 18) 100%);
  border-radius: 11px;
  place-items: center;
  width: 100%;
  height: 100%;
  display: grid;
  position: relative;
  overflow: hidden;
}
.phone-notch {
  background: rgb(0, 0, 0);
  border-radius: 999px;
  width: 20px;
  height: 4px;
  position: absolute;
  top: 4px;
  left: 50%;
  transform: translate(-50%);
}
.device-logo {
  filter: drop-shadow(rgba(116, 196, 255, 0.45) 0px 4px 10px);
  width: 55%;
  max-height: 75%;
  height: auto;
  border-radius: 6px;
  object-fit: contain;
}
.device-phone .device-logo {
  width: 70%;
  max-height: 80%;
  border-radius: 4px;
}

/* ── 5: TACTILE WIRELESS MODULE CLIPART ──────── */
.clipart-wifi-card {
  width: 195px;
  background: linear-gradient(160deg, rgba(30, 41, 59, 0.75), rgba(15, 23, 42, 0.9));
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 14px;
  padding: 16px 14px 12px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  box-shadow: 0 14px 30px -8px rgba(0, 0, 0, 0.5), inset 0 1px 0 rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(10px);
  transition: transform 0.3s ease;
}
@media (hover: hover) {
    .clipart-wifi-card:hover {
      transform: translateY(-2px) scale(1.02);
    }
}
.wifi-card-antenna-svg {
  width: 135px;
  height: 56px;
  filter: drop-shadow(0 6px 16px rgba(79, 195, 255, 0.35));
}
.wifi-radio-wave {
  animation: wifi-radiate 2.4s ease-in-out infinite;
}
.radio-wave-left-1, .radio-wave-right-1 { animation-delay: 0s; }
.radio-wave-left-2, .radio-wave-right-2 { animation-delay: 0.35s; }
.radio-wave-left-3, .radio-wave-right-3 { animation-delay: 0.7s; }
.wifi-card-pill {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(79, 195, 255, 0.08);
  border: 1px solid rgba(79, 195, 255, 0.25);
  font-family: var(--font-mono);
  font-size: 9.5px;
  font-weight: 700;
  color: #7dd8ff;
  letter-spacing: 0.05em;
}
.wifi-card-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #4fc3ff;
  box-shadow: 0 0 8px #4fc3ff;
  animation: wifi-pulse-dot 1.6s infinite alternate;
}
@keyframes wifi-radiate {
  0%, 100% { opacity: 0.35; }
  50% { opacity: 1; }
}
@keyframes wifi-pulse-dot {
  0% { transform: scale(0.9); opacity: 0.8; }
  100% { transform: scale(1.1); opacity: 1; }
}

/* ── 6: FRESH ENGINEERING SLATE MEMO CLIPART ─── */
.clipart-notes-pad {
  width: 175px;
  background: linear-gradient(160deg, rgba(30, 41, 59, 0.75), rgba(15, 23, 42, 0.9));
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 12px;
  padding: 24px 14px 14px;
  position: relative;
  box-shadow: 0 14px 30px -8px rgba(0, 0, 0, 0.5), inset 0 1px 0 rgba(255, 255, 255, 0.15);
  transform: rotate(-1.5deg);
  transition: transform 0.3s ease;
}
@media (hover: hover) {
    .clipart-notes-pad:hover {
      transform: rotate(0deg) scale(1.03);
    }
}
.notes-clip {
  position: absolute;
  top: -8px;
  left: 50%;
  transform: translateX(-50%);
  width: 48px;
  height: 16px;
  background: linear-gradient(180deg, #a0a0a0, #475569);
  border-radius: 4px;
  border: 1px solid rgba(255, 255, 255, 0.3);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.4);
}
.notes-header-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
  padding-bottom: 6px;
  border-bottom: 1px dashed rgba(255, 255, 255, 0.12);
  font-family: var(--font-mono);
  font-size: 9px;
  color: #a0a0a0;
}
.notes-tag {
  background: rgba(251, 191, 36, 0.15);
  border: 1px solid rgba(251, 191, 36, 0.3);
  color: #fbbf24;
  padding: 1px 5px;
  border-radius: 4px;
  font-weight: 700;
}
.notes-entry {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 9px;
}
.notes-entry:last-child {
  margin-bottom: 0;
}
.notes-check {
  color: #34d399;
  font-size: 10px;
  font-weight: 800;
}
.notes-bullet {
  color: #fbbf24;
  font-size: 9px;
}
.notes-line {
  height: 5px;
  background: rgba(255, 255, 255, 0.2);
  border-radius: 3px;
}
.notes-line.highlight {
  background: linear-gradient(90deg, #fbbf24, #f59e0b);
  box-shadow: 0 0 8px rgba(251, 191, 36, 0.4);
}
.w-85 { width: 85%; }
.w-75 { width: 75%; }
.w-65 { width: 65%; }
.w-50 { width: 50%; }

@media (width <= 768px) {
  .feature-row, .feature-row.row-reverse {
    text-align: center;
    grid-template-columns: 1fr !important;
    justify-items: center;
    gap: 20px;
    padding: 26px 18px;
  }
  .feature-row.row-reverse .feature-glyph {
    order: 0 !important;
  }
  .feature-row.row-reverse .feature-text {
    order: 1 !important;
  }
  .feature-text .feature-kicker {
    justify-content: center;
  }
  .feature-text p {
    max-width: 100%;
  }
  .feature-glyph { min-height: 90px; }
  .feature-text { align-items: center; }
  .feature-text p { max-width: 40ch; }
  .device-laptop { width: 170px; }
  .device-phone { width: 56px; height: 116px; }

  .bento-grid {
    grid-template-columns: 1fr !important;
  }
  .bento-card:nth-child(n) {
    grid-column: span 1 !important;
    min-height: 200px !important;
  }
}

/* ── SLIDE-IN COMPACT CARDS (INSIDE THE DEVICE) ───── */
.compact-info-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 20px;
  width: min(1080px, 100%);
  margin: 40px auto 0 auto;
  padding: 0 20px;
  box-sizing: border-box;
}

.compact-info-card {
  background: rgba(15, 15, 15, 0.8);
  border: 1px solid rgba(255, 255, 255, 0.08);
  padding: 26px 24px;
  border-radius: 14px;
  backdrop-filter: blur(12px);
  transition: transform 0.35s ease, border-color 0.35s ease, box-shadow 0.35s ease, background 0.35s ease;
  position: relative;
  overflow: hidden;
}

@media (hover: hover) {
    .compact-info-card:hover {
      transform: translateY(-4px);
      border-color: rgba(79, 195, 255, 0.35);
      background: rgba(20, 20, 20, 0.9);
      box-shadow: 0 18px 36px rgba(0, 0, 0, 0.55), 0 0 22px rgba(79, 195, 255, 0.12);
    }
}

.compact-info-card .compact-info-icon {
  font-size: 1.8rem;
  line-height: 1;
  display: block;
  margin-bottom: 14px;
}

.compact-info-card h3 {
  font-family: var(--font-serif);
  color: #ffffff;
  font-size: 1.15rem;
  font-weight: 700;
  line-height: 1.25;
  margin: 0 0 10px 0;
  letter-spacing: -0.01em;
}

.compact-info-card p {
  font-size: 0.9rem;
  line-height: 1.55;
  color: #a0a0a0;
  margin: 0;
}

/* Reveal / slide-in animation (mirrors index_old's IntersectionObserver reveal) */
.reveal {
  opacity: 0;
  visibility: hidden;
  transition: opacity 1.2s cubic-bezier(0.19, 1, 0.22, 1),
              transform 1.2s cubic-bezier(0.19, 1, 0.22, 1);
  will-change: transform, opacity;
}
.reveal.slide-up    { transform: translateY(80px); }
.reveal.slide-left  { transform: translateX(-120px); }
.reveal.slide-right { transform: translateX(120px); }
/* Cards waiting to slide in sit 120px off the side. Unclipped, that made
   the page wider than a phone's screen: the phone zoomed out, and the
   pinned 3D canvas (sized to the zoomed-out window) was cut off halfway.
   clip, not hidden: it keeps these sections from becoming scrollers.
   Every section is clipped, not only the ones with cards, since anything
   wider on a phone (bigger system text, say) does the same; the viewport
   tag's minimum-scale=1 also stops the zoom-out if something still is.
   Touch screens (they zoom; tablets in landscape too) and narrow windows
   only: a desktop with a mouse keeps the cards sliding in unclipped. */
@media (any-pointer: coarse), (max-width: 900px) {
  #scroll-track,
  #info,
  .imported-sections,
  .privacy-notice,
  body > footer {
    overflow-x: clip;
  }
}
.reveal.active {
  opacity: 1;
  visibility: visible;
  transform: translate(0, 0);
}

/* ── BENTO GRID (auto-fit, index_old style) ───── */
.bento-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 20px;
  margin: 80px 0;
}

.bento-card {
  background: rgba(15, 15, 15, 0.75);
  border: 1px solid rgba(79, 195, 255, 0.18);
  backdrop-filter: blur(20px);
  padding: 32px 30px;
  border-radius: 16px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  min-height: 220px;
  position: relative;
  overflow: hidden;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.45);
  transition: background 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
  will-change: transform;
  transform-style: preserve-3d;
}
@media (hover: hover) {
    .bento-card:hover {
      background: rgba(20, 20, 20, 0.9);
      border-color: rgba(79, 195, 255, 0.45);
      box-shadow: 0 20px 45px rgba(0, 0, 0, 0.6), 0 0 25px rgba(79, 195, 255, 0.12);
    }
}

.bento-card:nth-child(1) {
  grid-column: span 7;
  min-height: 300px;
}
.bento-card:nth-child(2) {
  grid-column: span 5;
  min-height: 300px;
}
.bento-card:nth-child(3) {
  grid-column: span 4;
  min-height: 230px;
}
.bento-card:nth-child(4) {
  grid-column: span 4;
  min-height: 230px;
}
.bento-card:nth-child(5) {
  grid-column: span 4;
  min-height: 230px;
}

.bento-tag {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: #4fc3ff;
  margin-bottom: 12px;
  font-weight: 700;
  display: block;
}

.bento-title {
  font-family: var(--font-serif);
  font-size: 1.4rem;
  font-weight: 700;
  color: #ffffff;
  line-height: 1.25;
  margin-bottom: 10px;
}

.bento-desc {
  font-size: 0.88rem;
  line-height: 1.6;
  color: #a0a0a0;
  margin: 0;
}

/* ── PRICING CARDS (REFERENCE LAYOUT & FLOATING BADGE) ── */
.pricing-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
  align-items: stretch;
}

.price-box {
  background: rgba(15, 15, 15, 0.75);
  border: 1px solid rgba(79, 195, 255, 0.18);
  backdrop-filter: blur(20px);
  padding: 40px 32px;
  border-radius: 20px;
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: background 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
  will-change: transform;
  transform-style: preserve-3d;
}
@media (hover: hover) {
    .price-box:hover {
      background: rgba(20, 20, 20, 0.9);
      border-color: rgba(79, 195, 255, 0.45);
      box-shadow: 0 20px 45px rgba(0, 0, 0, 0.5), 0 0 25px rgba(79, 195, 255, 0.12);
    }
}

/* Elevated Most Popular Card with Soft Glow */
.price-box.popular {
  background: rgba(10, 10, 10, 0.92);
  border: 1.5px solid rgba(79, 195, 255, 0.55);
  box-shadow: 0 0 50px rgba(79, 195, 255, 0.16), 0 24px 60px rgba(0, 0, 0, 0.7);
}
@media (hover: hover) {
    .price-box.popular:hover {
      box-shadow: 0 0 60px rgba(79, 195, 255, 0.25), 0 28px 70px rgba(0, 0, 0, 0.8);
    }
}

/* Floating Badge Overlapping Top-Right Border */
.price-badge-floating {
  position: absolute;
  top: -14px;
  right: 28px;
  font-family: var(--font-mono);
  font-size: 0.65rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #ffffff;
  background: linear-gradient(135deg, #764ba2, #0369a1);
  border: 1px solid rgba(255, 255, 255, 0.3);
  padding: 5px 14px;
  border-radius: 9999px;
  font-weight: 800;
  box-shadow: 0 4px 14px rgba(118, 75, 162, 0.5);
  z-index: 10;
}

.price-amount {
  font-family: var(--font-serif);
  font-size: 3.4rem;
  font-weight: 800;
  color: #ffffff;
  line-height: 1;
  margin-bottom: 14px;
  display: flex;
  align-items: flex-start;
  gap: 2px;
}

.price-cur {
  font-size: 1.5rem;
  line-height: 1.2;
  color: #a0a0a0;
}

.price-plan-name {
  font-family: var(--font-sans);
  font-size: 1.3rem;
  font-weight: 700;
  color: #ffffff;
  margin-bottom: 10px;
}

.price-info {
  font-size: 0.88rem;
  line-height: 1.6;
  color: #a0a0a0;
  margin-bottom: 24px;
  min-height: 56px;
}

.price-divider {
  width: 100%;
  height: 1px;
  background: rgba(255, 255, 255, 0.1);
  margin-bottom: 24px;
}

.price-features {
  list-style: none;
  margin: 0 0 32px 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 14px;
  flex-grow: 1;
}
.price-features li {
  font-size: 0.88rem;
  color: #cbd5e1;
  display: flex;
  align-items: center;
  gap: 12px;
  line-height: 1.4;
}
.price-features li .feature-icon {
  color: #4fc3ff;
  font-size: 0.85rem;
  font-weight: 800;
  flex-shrink: 0;
}

.price-btn {
  width: 100%;
  padding: 14px 20px;
  font-family: var(--font-sans);
  font-size: 0.88rem;
  font-weight: 600;
  border-radius: 10px;
  cursor: pointer;
  transition: all 0.25s ease, scale 0.45s cubic-bezier(0.34, 1.56, 0.64, 1);
  text-align: center;
  border: 1px solid rgba(255, 255, 255, 0.2);
  background: rgba(255, 255, 255, 0.05);
  color: #ffffff;
}
@media (hover: hover) {
    .price-btn:hover {
      background: rgba(255, 255, 255, 0.12);
      border-color: rgba(255, 255, 255, 0.4);
      transform: translateY(-2px);
    }
}
.price-box.popular .price-btn {
  background: #4fc3ff;
  color: #000000;
  border-color: #4fc3ff;
  font-weight: 700;
  box-shadow: 0 4px 16px rgba(79, 195, 255, 0.35);
}
@media (hover: hover) {
    .price-box.popular .price-btn:hover {
      background: #7dd8ff;
      border-color: #7dd8ff;
      box-shadow: 0 6px 22px rgba(79, 195, 255, 0.5);
    }
}

/* ═══════════════════════════════════════════════
   RESPONSIVE DESIGN SYSTEM (MOBILE & TABLET)
═══════════════════════════════════════════════ */
@media (max-width: 900px) {
  /* Viewport Masking Reset */
  #viewport-mask-left, #viewport-mask-right {
    clip-path: none !important;
    z-index: 25 !important;
  }

  /* Story Cards Container. No internal scroll — touch must pass through to
     the page so the scroll-track can drive the calc animation. */
  .story-card {
    position: fixed !important;
    top: 56px !important;
    bottom: auto !important;
    left: 16px !important;
    right: 16px !important;
    width: auto !important;
    max-width: calc(100vw - 32px) !important;
    transform: none !important;
    z-index: 30 !important;
  }

  /* Card 1: Mobile Hero (Text at Top) */
  #card-1 {
    left: 16px !important;
    right: 16px !important;
    top: 68px !important;
    bottom: auto !important;
    width: auto !important;
    max-width: calc(100vw - 32px) !important;
    padding: 14px 16px !important;
    border-radius: 16px !important;
    transform: none !important;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    box-sizing: border-box !important;
  }
  #card-1 .card-header-badge {
    margin-bottom: 8px !important;
  }
  #card-1 .card-heading {
    font-size: clamp(1.45rem, 4.8vw, 1.85rem) !important;
    line-height: 1.18 !important;
    margin-bottom: 8px !important;
  }
  #card-1 .card-description {
    font-size: 0.78rem !important;
    line-height: 1.45 !important;
    margin-bottom: 12px !important;
    max-width: 320px;
  }
  #card-1 .hw-metrics-grid {
    width: 100% !important;
    gap: 8px !important;
    margin-bottom: 12px !important;
    max-width: 340px;
  }
  #card-1 .hw-metric-card {
    padding: 6px 10px !important;
    border-radius: 8px !important;
  }
  #card-1 .hw-metric-val {
    font-size: 0.95rem !important;
  }
  #card-1 .hw-metric-lbl {
    font-size: 0.58rem !important;
  }
  #card-1 .card-buttons {
    width: 100% !important;
    max-width: 360px !important;
    display: flex !important;
    flex-wrap: wrap !important;
    gap: 8px !important;
    justify-content: center !important;
  }
  #card-1 .btn-main, #card-1 .btn-outline, #card-1 .btn-dash {
    padding: 9px 14px !important;
    font-size: 0.68rem !important;
    text-align: center !important;
    white-space: nowrap !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
  }
}

@media (max-width: 900px) and (max-height: 700px) {
  #card-1, #card-2, #card-3 {
    top: 52px !important;
    padding: 8px 10px !important;
  }
  #card-1 .card-heading, #card-2 .card-heading, #card-3 .card-heading {
    font-size: 1.15rem !important;
    margin-bottom: 3px !important;
  }
  #card-1 .card-description, #card-2 .card-description, #card-3 .card-description {
    font-size: 0.68rem !important;
    margin-bottom: 4px !important;
    max-width: 290px;
  }
  #card-1 .hw-metrics-grid, #card-2 .hw-metrics-grid {
    margin-bottom: 4px !important;
    gap: 3px !important;
  }
  #card-1 .hw-metric-card, #card-2 .hw-metric-card {
    padding: 3px 5px !important;
  }
  #card-1 .btn-main, #card-1 .btn-outline, #card-1 .btn-dash {
    padding: 5px 4px !important;
    font-size: 0.58rem !important;
  }
  #card-3 .card-internal-viewport {
    height: auto !important;
  }
  #card-3 .card-internal-slider {
    height: auto !important;
  }
  #card-3 .card-slide {
    height: auto !important;
  }
}

@media (max-width: 900px) {
  #scroll-cue {
    display: none !important;
  }

  /* Card 2: Mobile Optics Top Card */
  #card-2 {
    left: 16px !important;
    right: 16px !important;
    top: 68px !important;
    bottom: auto !important;
    width: auto !important;
    max-width: calc(100vw - 32px) !important;
    padding: 14px 16px !important;
    border-radius: 16px !important;
    box-sizing: border-box !important;
  }
  #card-2 .card-header-badge {
    margin-bottom: 6px !important;
  }
  #card-2 .card-heading {
    font-size: 1.25rem !important;
    line-height: 1.18 !important;
    margin-bottom: 4px !important;
  }
  #card-2 .card-description {
    font-size: 0.74rem !important;
    line-height: 1.4 !important;
    margin-bottom: 10px !important;
  }
  #card-2 .hw-metrics-grid {
    gap: 6px !important;
  }
  #card-2 .hw-metric-card {
    padding: 6px 8px !important;
    border-radius: 8px !important;
  }
  #card-2 .hw-metric-val {
    font-size: 0.90rem !important;
  }
  #card-2 .hw-metric-lbl {
    font-size: 0.55rem !important;
  }
  #card-2 .hw-spec-strip {
    display: none !important;
  }

  /* Card 3: Mobile Screen & AI Top Card */
  .screen-card-large {
    width: auto !important;
  }
  #card-3 {
    left: 16px !important;
    right: 16px !important;
    top: 68px !important;
    bottom: auto !important;
    width: auto !important;
    max-width: calc(100vw - 32px) !important;
    padding: 14px 16px !important;
    border-radius: 16px !important;
    box-sizing: border-box !important;
  }
  #card-3 .card-internal-viewport {
    height: auto !important;
    min-height: 0 !important;
  }
  #card-3 .card-internal-slider {
    height: auto !important;
  }
  #card-3 .card-slide {
    height: auto !important;
    min-height: 0 !important;
    display: flex !important;
    flex-direction: column !important;
    justify-content: flex-start !important;
    box-sizing: border-box !important;
    padding-bottom: 6px !important;
  }
  #card-3 .card-header-badge {
    margin-bottom: 6px !important;
  }
  #card-3 .card-heading {
    font-size: 1.25rem !important;
    line-height: 1.18 !important;
    margin-bottom: 4px !important;
  }
  #card-3 .card-description {
    font-size: 0.74rem !important;
    line-height: 1.4 !important;
    margin-bottom: 10px !important;
  }
  .screen-feature-list {
    display: flex !important;
    flex-direction: column !important;
    gap: 5px !important;
  }
  .feature-item {
    padding: 6px 10px !important;
    font-size: 0.74rem !important;
    border-radius: 8px !important;
  }
  .feature-bullet {
    width: 6px !important;
    height: 6px !important;
    margin-right: 8px !important;
  }
  .feature-label {
    font-size: 0.74rem !important;
  }
  .feature-tag {
    font-size: 0.54rem !important;
    padding: 2px 4px !important;
  }
  .ai-chip-grid {
    display: grid !important;
    grid-template-columns: 1fr 1fr !important;
    gap: 8px !important;
  }
  .ai-chip-card {
    padding: 6px 8px !important;
    border-radius: 8px !important;
  }
  .ai-chip-name {
    font-size: 0.70rem !important;
  }
  .ai-chip-tag {
    font-size: 0.54rem !important;
    padding: 2px 4px !important;
  }
  .ai-chip-sub {
    font-size: 0.58rem !important;
    margin-top: 2px !important;
  }

  .ai-orbit-wrap {
    max-width: 240px !important;
    --orbit-r: 92px !important;
    --orbit-node: 44px !important;
    margin: 18px auto 4px !important;
  }
  .ai-orbit-center {
    width: 58px !important;
    height: 58px !important;
    margin: -29px 0 0 -29px !important;
  }

  /* 3D Depth Typography on Mobile: 2-line stacked layout reaching edge-to-edge (~2-5px screen margin) */
  .depth-title {
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    width: 100vw !important;
    max-width: 100vw !important;
    text-align: center !important;
    line-height: 0.90 !important;
    padding: 0 !important;
    left: 50% !important;
    white-space: normal !important;
  }
  .depth-title .word-more {
    display: block !important;
    font-size: clamp(3.8rem, 18.5vw, 5.6rem) !important;
    letter-spacing: -0.03em !important;
    margin-bottom: 2px !important;
  }
  #title-more-colors .word-colors, #title-more-colors-front .word-colors {
    display: block !important;
    font-size: clamp(4.15rem, 20.2vw, 5.8rem) !important;
    letter-spacing: -0.04em !important;
    margin-left: 0 !important;
  }
  #title-more-control .word-control, #title-more-control-front .word-control {
    display: block !important;
    font-size: clamp(2.80rem, 13.6vw, 4.1rem) !important;
    letter-spacing: 0.005em !important;
    margin-left: 0 !important;
    transform: translateX(-0.24em) !important;
  }
  #title-more-protection .word-protection, #title-more-protection-front .word-protection {
    display: block !important;
    font-size: clamp(2.85rem, 13.8vw, 4.2rem) !important;
    letter-spacing: -0.025em !important;
    margin-left: 0 !important;
  }
  .depth-title-stroke {
    -webkit-text-stroke: 1.2px rgba(255, 255, 255, 0.70) !important;
  }
  .depth-title-front-solid {
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    width: 100vw !important;
    max-width: 100vw !important;
    text-align: center !important;
    left: 50% !important;
    padding: 0 !important;
  }
  .depth-title-front-solid .know-love-line1 {
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    width: 100vw !important;
    margin-bottom: 2px !important;
  }
  .depth-title-front-solid .know-love-line1 .word-silver {
    display: block !important;
    width: 100vw !important;
    font-family: var(--font-archivo), 'Archivo Black', var(--font-sans) !important;
    font-size: clamp(2.2rem, 11.2vw, 3.4rem) !important;
    letter-spacing: 0.04em !important;
    color: #C0BFBC !important;
    text-transform: uppercase !important;
    line-height: 0.92 !important;
    text-align: center !important;
    white-space: nowrap !important;
  }
  .depth-title-front-solid .know-love-line1 .word-calc {
    display: block !important;
    width: 100vw !important;
    font-family: var(--font-archivo), 'Archivo Black', var(--font-sans) !important;
    font-size: clamp(2.55rem, 12.8vw, 3.8rem) !important;
    letter-spacing: -0.025em !important;
    color: #ffffff !important;
    text-transform: uppercase !important;
    line-height: 0.92 !important;
    text-align: center !important;
    white-space: nowrap !important;
  }
  .depth-title-front-solid .know-love-line2 {
    display: block !important;
    width: 100vw !important;
    font-size: clamp(1.75rem, 8.8vw, 2.7rem) !important;
    letter-spacing: -0.015em !important;
    line-height: 1.05 !important;
    white-space: nowrap !important;
    text-align: center !important;
  }

  /* Below the Fold Content Sections */
  .content-section {
    padding: 70px 20px !important;
  }
  .section-title {
    font-size: clamp(1.8rem, 6.5vw, 2.5rem) !important;
    line-height: 1.15 !important;
  }
  .section-sub {
    font-size: 0.9rem !important;
    margin-bottom: 36px !important;
  }
  .bento-grid {
    grid-template-columns: 1fr !important;
    gap: 16px !important;
  }
  .bento-card {
    grid-column: span 1 !important;
    padding: 24px 20px !important;
  }
  .pricing-grid {
    grid-template-columns: 1fr !important;
    gap: 20px !important;
  }
  .price-box {
    padding: 30px 22px !important;
  }
  footer {
    padding: 30px 20px !important;
    flex-direction: column;
    gap: 16px;
    text-align: center;
  }
}

/* ═══════════════════════════════════════════════
   FOOTER
═══════════════════════════════════════════════ */
footer {
  border-top: 1px solid var(--rule);
  padding: 48px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: var(--bg);
}
.footer-logo {
  font-family: var(--font-serif);
  font-weight: 800;
  font-size: 1.1rem;
  color: var(--ink);
}
.footer-logo span { color: var(--amber); }

.footer-copy {
  font-size: 0.78rem;
  color: var(--ink-muted);
}

/* ── INDEX_OLD IMPORTED SECTIONS ───── */
.imported-sections {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
  color: #eee;
  position: relative;
  z-index: 3;
}

.video-feature-row {
  display: flex;
  align-items: center;
  gap: 50px;
  margin: 120px 0;
}
.small-video-wrap {
  flex: 0 0 320px;
  border-radius: 15px;
  overflow: hidden;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.1);
}
.viewer-video-small {
  width: 100%;
  display: block;
  /* the clip's own shape (488x480), so the box has its size before the
     clip loads (LazyVideo loads it when it scrolls into view) */
  aspect-ratio: 488 / 480;
  background: #0b1418;
}
/* the PCB row: a transparent 3D render of the whole board (about 2.5:1),
   so it gets a wider slot than the videos and no card around it */
.pcb-shot {
  flex: 0 0 min(540px, 50%);
  min-width: 0;
}
.pcb-shot img {
  display: block;
  width: 100%;
  height: auto;
  filter: drop-shadow(0 18px 28px rgba(0, 0, 0, 0.55));
}
.text-content-small h2 {
  font-family: var(--font-serif);
  font-size: 2rem;
  color: #fff;
  margin: 0 0 14px 0;
  letter-spacing: -0.01em;
}
.text-content-small p {
  font-size: 1rem;
  line-height: 1.6;
  color: #a0a0a0;
}

/* index_old .compact-card (distinct from .compact-info-card) */
.compact-card {
  background: rgba(15, 15, 15, 0.8);
  border: 1px solid rgba(255, 255, 255, 0.08);
  padding: 25px;
  border-radius: 12px;
  backdrop-filter: blur(10px);
}
.compact-card h3 {
  font-family: var(--font-serif);
  color: #fff;
  font-size: 1.1rem;
  margin: 0 0 10px 0;
}
.compact-card p {
  font-size: 0.9rem;
  line-height: 1.55;
  color: #a0a0a0;
  margin: 0;
}
.compact-card a {
  color: #4fc3ff;
  text-decoration: none;
}
@media (hover: hover) {
    .compact-card a:hover { text-decoration: underline; }
}

.spec-card {
  background: linear-gradient(145deg, rgba(30, 30, 30, 0.8) 0%, rgba(10, 10, 10, 0.8) 100%);
  border: 1px solid rgba(255, 255, 255, 0.05);
  padding: 25px;
  border-radius: 15px;
}
.spec-card h3 {
  font-family: var(--font-serif);
  color: #fff;
  font-size: 1.1rem;
  margin: 0;
}
.spec-list {
  list-style: none;
  padding: 0;
  margin: 15px 0 0 0;
}
.spec-list li {
  font-size: 0.85rem;
  color: #888;
  padding: 8px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}
.spec-list li b { color: #fff; }

.wide-card {
  grid-column: span 2;
  background: rgba(118, 75, 162, 0.1);
  border: 1px solid rgba(118, 75, 162, 0.3);
  padding: 30px;
  border-radius: 15px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
}
.wide-card h3 {
  font-family: var(--font-serif);
  color: #fff;
  margin: 0 0 5px 0;
}
.wide-card p {
  color: #a0a0a0;
  margin: 0;
}

.status-dot {
  width: 8px;
  height: 8px;
  background: #00ff64;
  border-radius: 50%;
  box-shadow: 0 0 10px #00ff64;
  animation: statusPulse 2s infinite;
}
@keyframes statusPulse {
  0%   { opacity: 1; }
  50%  { opacity: 0.4; }
  100% { opacity: 1; }
}

/* The home page's buttons: the site's main-button finish (feel.css adds the
   gloss, the shine and the glow in --glow), a glass one and a blue one */
.btn-obsidian {
  --glow: 79, 195, 255;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 24px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 12px;
  color: #fff;
  background: rgba(255, 255, 255, 0.05);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  text-decoration: none;
  backdrop-filter: blur(6px);
}
/* (.compact-card a would turn the label blue) */
.compact-card a.btn-obsidian:not(.primary) {
  color: #fff;
}
@media (hover: hover) {
    .btn-obsidian:not(.primary):hover {
      border-color: rgba(var(--glow), 0.6);
      background: rgba(var(--glow), 0.1);
    }
    .compact-card a.btn-obsidian:hover {
      text-decoration: none;
    }
}
.btn-obsidian.primary {
  background: linear-gradient(180deg, #8ad9ff 0%, #4fc3ff 100%);
  color: #04131c;
  border-color: rgba(255, 255, 255, 0.35);
}
@media (hover: hover) {
    .btn-obsidian.primary:hover {
      background: linear-gradient(180deg, #a3e2ff 0%, #66ccff 100%);
    }
}
/* the System Status link: green, like the dot in it */
.btn-obsidian--status {
  --glow: 0, 255, 100;
  border-color: rgba(0, 255, 100, 0.3);
}
.compact-card a.btn-obsidian--status,
.btn-obsidian--status {
  color: #00ff64;
}
/* Discord's own blurple */
.btn-obsidian--discord {
  --glow: 88, 101, 242;
}

/* the closing call to action: two big buttons side by side; on a phone
   they stack, each the full width, so neither wraps its text */
.cta-actions {
  display: flex;
  gap: 20px;
  justify-content: center;
  flex-wrap: wrap;
}
.btn-obsidian--lg {
  padding: 15px 40px;
  font-size: 1.05rem;
  white-space: nowrap;
}
@media (max-width: 520px) {
  .cta-actions {
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
    width: 100%;
    max-width: 340px;
    margin: 0 auto;
  }
  /* full width here, so the text fits on one line on most phones; on the
     narrowest it wraps (nowrap pushed the page 14px wider at 360px) */
  .btn-obsidian--lg {
    padding: 15px 20px;
    font-size: 1rem;
    white-space: normal;
    text-align: center;
  }
}
@media (max-width: 370px) {
  .btn-obsidian--lg {
    padding: 15px 12px;
    font-size: 0.92rem;
    letter-spacing: 0.03em;
  }
}

/* Carousel */
.carousel-feature-block {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 50px;
  align-items: center;
}
.carousel-feature-block .text-content h2 {
  font-family: var(--font-serif);
  color: #fff;
  font-size: 2rem;
  margin: 0 0 16px 0;
}
.carousel-feature-block .text-content p {
  color: #a0a0a0;
  font-size: 1rem;
  line-height: 1.6;
  margin: 0 0 12px 0;
}
.carousel-container {
  position: relative;
  overflow: hidden;
  border-radius: 15px;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.1);
}
.carousel-track {
  display: flex;
  transition: transform 0.6s cubic-bezier(0.19, 1, 0.22, 1);
  will-change: transform;
}
.carousel-track img {
  width: 100%;
  flex: 0 0 100%;
  display: block;
  object-fit: cover;
}
.carousel-button {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(0, 0, 0, 0.55);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.15);
  width: 40px;
  height: 40px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 1.1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s ease, scale 0.45s cubic-bezier(0.34, 1.56, 0.64, 1);
}
@media (hover: hover) {
    .carousel-button:hover { background: rgba(79, 195, 255, 0.35); }
}
.carousel-button.prev { left: 12px; }
.carousel-button.next { right: 12px; }

@media (max-width: 768px) {
  .video-feature-row {
    flex-direction: column !important;
    gap: 20px;
    margin: 60px 0;
    text-align: center;
  }
  .small-video-wrap {
    flex: 0 0 auto;
    width: 100%;
    max-width: 320px;
    margin: 0 auto;
  }
  .pcb-shot {
    flex: 0 0 auto;
    width: 100%;
  }
  .text-content-small h2 { font-size: 1.5rem; }
  .wide-card {
    grid-column: span 1 !important;
    flex-direction: column;
    text-align: center;
    gap: 20px;
  }
  .carousel-feature-block {
    grid-template-columns: 1fr;
    gap: 30px;
  }
}

/* Extra-narrow phones: collapse remaining 2-col grids that still feel
   "spread out" at ~375px. Also pull the giant scroll-track in a bit so
   the tail after the story ends can't be surfed into empty space. */
@media (max-width: 520px) {
  /* Trim the scroll-track tail on phones so the animation's last frame
     doesn't sit frozen through a long "black" scroll before the footer
     section comes into view. */
  #scroll-track { height: 8680px; }
  .hw-metrics-grid { grid-template-columns: 1fr !important; }
  #card-2 .hw-metrics-grid { grid-template-columns: 1fr 1fr !important; }
}
