/* ═══════════════════════════════════════════════════════════
   WakeAct — Promotional Site
   Complete Stylesheet
   ═══════════════════════════════════════════════════════════ */

/* ── CSS Custom Properties ── */
:root {
  --bg: #f5f0e8;
  --card: #faf7f1;
  --foreground: #3a2520;
  --muted: #e8e0d4;
  --muted-fg: #8a6b60;
  --accent: #d4a84b;
  --border: #ddd5c8;
  --primary: #e85d3a;
  --primary-rgb: 232,93,58;
  --secondary: #c74a2e;
  --brand-light: #f29474;
  --tab-puzzles: #f59e0b;
  --tab-sleep: #8b7ec8;
  --tab-gamification: #22c55e;
  --tab-blocking: #ef4465;
  --tab-social: #3b82f6;
  --success: #22c55e;
  --destructive: #ef4444;
  --radius: 12px;
  --radius-lg: 16px;
  --transition: 0.3s ease;
  --nav-h: 64px;
  --section-pad: clamp(48px, 8vw, 100px) 0;
}

[data-theme="dark"] {
  --bg: #1e1916;
  --card: #2a2420;
  --foreground: #ede5da;
  --muted: #3a322c;
  --muted-fg: #b09888;
  --accent: #e4bc64;
  --border: #453a34;
}

/* ── Reset ── */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'Segoe UI', Roboto, sans-serif;
  background: var(--bg);
  color: var(--foreground);
  line-height: 1.6;
  transition: background-color var(--transition), color var(--transition);
  overflow-x: hidden;
}
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }
button { font: inherit; cursor: pointer; border: none; background: none; color: inherit; }
ul { list-style: none; }

/* ── Skip Link ── */
.skip-link {
  position: absolute; top: -100px; left: 16px; z-index: 9999;
  background: var(--primary); color: #fff; padding: 8px 16px; border-radius: 8px;
  font-weight: 600; transition: top var(--transition);
}
.skip-link:focus { top: 8px; }

/* ── Scroll Progress ── */
.scroll-progress {
  position: fixed; top: 0; left: 0; width: 100%; height: 3px; z-index: 1001;
  background: linear-gradient(90deg, var(--primary), var(--accent), var(--primary));
  background-size: 200% 100%;
  animation: progressShimmer 3s ease infinite;
  transform-origin: left; transform: scaleX(var(--scroll, 0));
  pointer-events: none;
  box-shadow: 0 0 8px rgba(var(--primary-rgb), 0.4);
  will-change: transform;
}
@keyframes progressShimmer {
  0%, 100% { background-position: 0% 0%; }
  50% { background-position: 200% 0%; }
}

/* ── Container ── */
.container { max-width: 1200px; margin: 0 auto; padding: 0 clamp(16px, 4vw, 24px); }

/* ── Section ── */
.section { padding: var(--section-pad); position: relative; }
.section-head { text-align: center; margin-bottom: 56px; }
.section-label {
  display: inline-block; font-size: 0.8rem; font-weight: 700; text-transform: uppercase;
  letter-spacing: 0.12em; color: var(--primary); margin-bottom: 12px;
  padding: 4px 12px; border-radius: 4px;
  background: rgba(var(--primary-rgb), 0.08);
  position: relative; cursor: default;
}
.section-label::after {
  content: ''; position: absolute; bottom: 0; left: 50%; width: 0; height: 2px;
  background: var(--primary); border-radius: 1px;
  transition: width 0.3s ease, left 0.3s ease;
}
.section-label:hover::after { width: 60%; left: 20%; }
.section-head h2 { font-size: clamp(2rem, 4.5vw, 3rem); font-weight: 900; line-height: 1.15; letter-spacing: -0.02em; }
.section-sub { font-size: 1.1rem; color: var(--muted-fg); max-width: 600px; margin: 12px auto 0; }

/* ── Glass Card ── */
.glass {
  background: rgba(250,247,241,0.5);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  border: 1.5px solid rgba(221,213,200,0.5);
  border-radius: var(--radius-lg);
  box-shadow: 0 4px 16px rgba(0,0,0,0.06);
  transition: border-color var(--transition), box-shadow var(--transition), transform var(--transition);
}
[data-theme="dark"] .glass {
  background: rgba(42,36,32,0.6);
  border-color: rgba(69,58,52,0.6);
}
.glass:hover { transform: translateY(-2px); box-shadow: 0 8px 24px rgba(0,0,0,0.1); }

/* ── Buttons ── */
.btn-primary {
  display: inline-flex; align-items: center; gap: 10px;
  background: var(--primary); color: #fff;
  padding: 14px 28px; border-radius: 100px;
  font-size: 1rem; font-weight: 600;
  transition: background var(--transition), transform var(--transition), box-shadow var(--transition);
}
.btn-primary:hover { background: #c74a2e; transform: translateY(-3px) scale(1.02); box-shadow: 0 8px 24px rgba(var(--primary-rgb),0.3); }
.btn-glow { box-shadow: 0 4px 12px rgba(var(--primary-rgb),0.25), 0 8px 24px rgba(var(--primary-rgb),0.1); }
.btn-glow:hover { box-shadow: 0 6px 20px rgba(var(--primary-rgb),0.35), 0 12px 36px rgba(var(--primary-rgb),0.15); }
.btn-coming-soon { opacity: 0.6; cursor: default; pointer-events: none; }

/* ── iOS Download Button ── */
@keyframes btn-ios-bounce {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-3px); }
}
@keyframes btn-ios-shimmer {
  0% { left: -100%; }
  100% { left: 100%; }
}
.btn-ios-download {
  display: inline-flex; align-items: center; gap: 14px;
  padding: 14px 30px; border-radius: 100px;
  font-size: 1.05rem; font-weight: 700;
  color: #fff; text-decoration: none;
  background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 60%, #a33a20 100%);
  border: 2px solid rgba(255,255,255,0.15);
  box-shadow:
    0 4px 16px rgba(var(--primary-rgb), 0.35),
    0 1px 3px rgba(0,0,0,0.1),
    inset 0 1px 0 rgba(255,255,255,0.2);
  transition: all 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
  position: relative; overflow: hidden;
  animation: btn-ios-bounce 3s ease-in-out infinite;
}
.btn-ios-download::after {
  content: '';
  position: absolute; top: 0; left: -100%;
  width: 60%; height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.15), transparent);
  animation: btn-ios-shimmer 4s ease-in-out infinite;
  pointer-events: none;
}
.btn-ios-download:hover {
  transform: translateY(-5px) scale(1.05);
  box-shadow:
    0 8px 28px rgba(var(--primary-rgb), 0.45),
    0 4px 10px rgba(0,0,0,0.1),
    inset 0 1px 0 rgba(255,255,255,0.25);
  border-color: var(--accent);
  animation: none;
}
.btn-ios-download:active { transform: translateY(-1px) scale(0.97); animation: none; }
.btn-ios-download .btn-ios-icon {
  display: flex; align-items: center; justify-content: center;
  width: 34px; height: 34px; border-radius: 10px;
  background: rgba(255,255,255,0.18); flex-shrink: 0;
  backdrop-filter: blur(4px);
}
.btn-ios-download .btn-ios-text {
  display: flex; flex-direction: column; align-items: flex-start; line-height: 1.2;
}
.btn-ios-download .btn-ios-label {
  font-size: 0.62rem; font-weight: 600; text-transform: uppercase;
  letter-spacing: 0.1em; opacity: 0.85;
}
.btn-ios-download .btn-ios-title {
  font-size: 1.15rem; font-weight: 800; letter-spacing: -0.01em;
}
.btn-ios-download.btn-large { padding: 18px 38px; border-radius: 100px; }
.btn-ios-download.btn-large .btn-ios-icon { width: 40px; height: 40px; border-radius: 12px; }
.btn-ios-download.btn-large .btn-ios-title { font-size: 1.3rem; }
.btn-ios-download.btn-large .btn-ios-label { font-size: 0.68rem; }

.btn-ghost {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 14px 24px; border-radius: 100px;
  border: 2px solid var(--primary); color: var(--primary);
  font-weight: 600; transition: all var(--transition);
}
.btn-ghost:hover { background: rgba(var(--primary-rgb),0.1); transform: translateY(-2px); box-shadow: 0 4px 16px rgba(var(--primary-rgb),0.12); }
.btn-large { padding: 18px 36px; font-size: 1.15rem; }

/* ── Ripple Effect ── */
.btn-primary, .btn-ghost, .nav-cta, .contact-email-btn, .mobile-cta {
  position: relative; overflow: hidden;
}
.ripple-effect {
  position: absolute; border-radius: 50%;
  background: rgba(255,255,255,0.35);
  transform: scale(0);
  animation: ripple 0.6s ease-out forwards;
  pointer-events: none;
}
@keyframes ripple {
  to { transform: scale(4); opacity: 0; }
}

/* ── Scroll Reveal ── */
[data-reveal] { opacity: 0; transform: translateY(30px); transition: opacity 0.7s ease, transform 0.7s ease; backface-visibility: hidden; -webkit-backface-visibility: hidden; }
[data-reveal].visible { opacity: 1; transform: none; }
[data-reveal="scale"] { opacity: 0; transform: scale(0.85); transition: opacity 0.7s ease, transform 0.7s ease; backface-visibility: hidden; -webkit-backface-visibility: hidden; }
[data-reveal="scale"].visible { opacity: 1; transform: none; }
[data-reveal="slide-left"] { opacity: 0; transform: translateX(-60px); transition: opacity 0.7s ease, transform 0.7s ease; backface-visibility: hidden; -webkit-backface-visibility: hidden; }
[data-reveal="slide-left"].visible { opacity: 1; transform: none; }
[data-reveal="slide-right"] { opacity: 0; transform: translateX(60px); transition: opacity 0.7s ease, transform 0.7s ease; backface-visibility: hidden; -webkit-backface-visibility: hidden; }
[data-reveal="slide-right"].visible { opacity: 1; transform: none; }
[data-reveal-stagger] > * { opacity: 0; transform: translateY(30px) scale(0.95); transition: opacity 0.6s cubic-bezier(0.16, 1, 0.3, 1), transform 0.6s cubic-bezier(0.16, 1, 0.3, 1); backface-visibility: hidden; -webkit-backface-visibility: hidden; }
[data-reveal-stagger].visible > * { opacity: 1; transform: none; }
[data-reveal-stagger].visible > *:nth-child(1) { transition-delay: 0s; }
[data-reveal-stagger].visible > *:nth-child(2) { transition-delay: 0.12s; }
[data-reveal-stagger].visible > *:nth-child(3) { transition-delay: 0.12s; }
[data-reveal-stagger].visible > *:nth-child(4) { transition-delay: 0.24s; }
[data-reveal-stagger].visible > *:nth-child(5) { transition-delay: 0.36s; }
[data-reveal-stagger].visible > *:nth-child(6) { transition-delay: 0.48s; }

/* ══════════════════════════════════════════════════
   NAVIGATION
   ══════════════════════════════════════════════════ */
.nav {
  position: fixed; top: 0; left: 0; width: 100%; height: var(--nav-h); z-index: 1000;
  background: rgba(237,232,220,0.85); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid transparent; transition: all var(--transition);
}
[data-theme="dark"] .nav { background: rgba(28,25,30,0.88); }
.nav.scrolled { border-bottom-color: var(--border); box-shadow: 0 2px 16px rgba(0,0,0,0.06); }
.nav-inner { max-width: 1200px; margin: 0 auto; padding: 0 24px; height: 100%; display: flex; align-items: center; justify-content: space-between; }
.nav-brand { display: flex; align-items: center; gap: 10px; font-weight: 700; font-size: 1.15rem; color: var(--primary); }
.nav-logo { border-radius: 8px; }
.nav-links { display: flex; gap: 28px; }
.nav-links a { font-size: 0.88rem; font-weight: 500; color: var(--muted-fg); transition: color var(--transition); position: relative; }
.nav-links a::after {
  content: ''; position: absolute; bottom: -4px; left: 0; width: 0; height: 2px;
  background: var(--primary); transition: width var(--transition);
}
.nav-links a:hover, .nav-links a.active { color: var(--foreground); }
.nav-links a:hover::after, .nav-links a.active::after { width: 100%; }
.nav-actions { display: flex; align-items: center; gap: 12px; }
.nav-cta {
  background: var(--primary); color: #fff; padding: 8px 20px; border-radius: 100px;
  font-size: 0.85rem; font-weight: 600; transition: background var(--transition);
}
.nav-cta:hover { background: #2fa584; }
.theme-toggle {
  width: 36px; height: 36px; border-radius: 50%; display: flex; align-items: center; justify-content: center;
  transition: background var(--transition);
}
.theme-toggle:hover { background: rgba(var(--primary-rgb),0.1); }
.icon-moon { display: none; }
[data-theme="dark"] .icon-sun { display: none; }
[data-theme="dark"] .icon-moon { display: block; }
.hamburger { display: none; flex-direction: column; gap: 5px; width: 24px; padding: 4px 0; }
.hamburger span { display: block; height: 2px; background: var(--foreground); border-radius: 2px; transition: all var(--transition); }
.hamburger.active span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.hamburger.active span:nth-child(2) { opacity: 0; }
.hamburger.active span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* Mobile Menu */
.mobile-menu {
  position: fixed; inset: 0; z-index: 999;
  background: rgba(28,25,30,0.96); backdrop-filter: blur(24px); -webkit-backdrop-filter: blur(24px);
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 28px;
  opacity: 0; pointer-events: none; transition: opacity var(--transition);
}
.mobile-menu.open { opacity: 1; pointer-events: all; }
.mobile-menu a {
  font-size: 1.5rem; font-weight: 600; color: #fff;
  opacity: 0; transform: translateY(20px);
  transition: opacity 0.3s ease, transform 0.3s ease, color var(--transition);
}
.mobile-menu.open a { opacity: 1; transform: translateY(0); }
.mobile-menu.open a:nth-child(1) { transition-delay: 0.05s; }
.mobile-menu.open a:nth-child(2) { transition-delay: 0.1s; }
.mobile-menu.open a:nth-child(3) { transition-delay: 0.15s; }
.mobile-menu.open a:nth-child(4) { transition-delay: 0.2s; }
.mobile-menu.open a:nth-child(5) { transition-delay: 0.25s; }
.mobile-menu.open a:nth-child(6) { transition-delay: 0.3s; }
.mobile-menu.open a:nth-child(7) { transition-delay: 0.35s; }
.mobile-menu.open a:nth-child(8) { transition-delay: 0.4s; }
.mobile-menu.open a:nth-child(9) { transition-delay: 0.45s; }
.mobile-menu a:hover { color: var(--primary); }
.mobile-cta {
  margin-top: 16px; background: var(--primary); color: #fff !important;
  padding: 14px 32px; border-radius: 100px; font-size: 1.1rem;
}

/* ══════════════════════════════════════════════════
   HERO
   ══════════════════════════════════════════════════ */
.hero {
  min-height: 100vh; position: relative; overflow: hidden;
  display: flex; align-items: center; padding: calc(var(--nav-h) + 40px) 0 80px;
}
.hero::before, .hero::after {
  content: ''; position: absolute; border-radius: 50%;
  opacity: 0.06; pointer-events: none; z-index: 0;
}
.hero::before {
  width: 500px; height: 500px;
  background: radial-gradient(circle, var(--primary) 0%, transparent 70%);
  top: -100px; right: -200px;
  animation: floatBlob 8s ease-in-out infinite;
}
.hero::after {
  width: 400px; height: 400px;
  background: radial-gradient(circle, var(--accent) 0%, transparent 70%);
  bottom: -100px; left: -150px;
  animation: floatBlob 10s ease-in-out infinite reverse;
}
[data-theme="dark"] .hero::before, [data-theme="dark"] .hero::after { opacity: 0.04; }
@keyframes floatBlob {
  0%, 100% { transform: translate(0, 0); }
  50% { transform: translate(30px, -20px); }
}

.hero-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: center; position: relative; z-index: 2; }
.hero-badge {
  display: inline-block; background: var(--primary); color: #fff;
  padding: 8px 20px; border-radius: 100px; font-size: 0.82rem; font-weight: 700; margin-bottom: 24px;
  box-shadow: 0 4px 12px rgba(var(--primary-rgb), 0.25);
  transform: rotate(-2deg); transition: transform 0.3s ease;
}
.hero-badge:hover { transform: rotate(0deg) scale(1.05); }
[data-theme="dark"] .hero-badge { box-shadow: 0 4px 12px rgba(0,0,0,0.3); }
.hero h1 { font-size: clamp(2.4rem, 6vw, 4rem); font-weight: 900; line-height: 1.1; margin-bottom: 24px; letter-spacing: -0.03em; }
.hero-highlight {
  background: linear-gradient(135deg, var(--primary), var(--brand-light), var(--accent), var(--primary));
  background-size: 300% 300%;
  -webkit-background-clip: text; -webkit-text-fill-color: transparent;
  background-clip: text;
  animation: gradientText 6s ease infinite;
}
@keyframes gradientText {
  0%, 100% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
}

/* ── Split-Text Hero Animation ── */
.split-animated .word { display: inline-block; white-space: nowrap; }
.split-animated .char {
  display: inline-block;
  opacity: 0; transform: translateY(20px);
  animation: charReveal 0.5s cubic-bezier(0.16, 1, 0.3, 1) forwards;
  animation-delay: calc(var(--char-index) * 0.02s);
}
@keyframes charReveal {
  to { opacity: 1; transform: translateY(0); }
}
.hero-desc { font-size: 1.15rem; color: var(--muted-fg); max-width: 520px; margin-bottom: 28px; line-height: 1.7; }
.hero-actions { display: flex; gap: 16px; flex-wrap: wrap; margin-bottom: 32px; }
.hero-stats { display: flex; gap: 12px; flex-wrap: wrap; }
.stat-pill { padding: 8px 16px; border-radius: 100px; font-size: 0.82rem; font-weight: 500; display: flex; align-items: center; gap: 6px; }
.stat-icon { font-size: 1rem; }

/* Hero Phones */
.hero-phones { position: relative; height: 520px; display: flex; align-items: center; justify-content: center; }
.phone-mockup {
  border-radius: 36px; border: 3px solid var(--border); overflow: hidden; position: relative;
  box-shadow: 0 8px 32px rgba(0,0,0,0.1), 0 2px 8px rgba(0,0,0,0.06);
  background: #000; transition: transform 0.15s ease-out;
  backface-visibility: hidden; -webkit-backface-visibility: hidden;
  transform: translateZ(0);
}
[data-theme="dark"] .phone-mockup { border-color: var(--border); }
.phone-mockup img { width: 100%; height: 100%; object-fit: cover; }
.phone-back { width: 220px; position: absolute; left: 0; transform: rotate(-8deg); z-index: 1; animation: phoneBob 5s ease-in-out infinite 0.5s; }
.phone-mid { width: 240px; position: relative; z-index: 2; animation: phoneBob 4s ease-in-out infinite; }
.phone-front { width: 220px; position: absolute; right: 0; transform: rotate(8deg); z-index: 3; animation: phoneBob 4.5s ease-in-out infinite 1s; }
@keyframes phoneBob {
  0%, 100% { transform: translateY(0) var(--phone-rotate, rotate(0deg)); }
  50% { transform: translateY(-6px) var(--phone-rotate, rotate(0deg)); }
}
.phone-back { --phone-rotate: rotate(-8deg); }
.phone-front { --phone-rotate: rotate(8deg); }
.phone-large { width: 300px; }
.phone-small { width: 180px; }

/* ── Interactive Demo Shared (from problem cards, now in tabs) ── */

.demo-btn {
  padding: 8px 20px;
  border-radius: 100px;
  border: 1.5px solid var(--primary);
  background: transparent;
  color: var(--primary);
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition);
}
.demo-btn:hover {
  background: var(--primary);
  color: #fff;
  transform: scale(1.05);
}
.demo-btn.active {
  background: var(--primary);
  color: #fff;
  pointer-events: none;
}

/* — Task Breakdown Demo — */
.task-big {
  padding: 10px 16px;
  border-radius: var(--radius);
  background: var(--muted);
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--foreground);
  display: flex;
  align-items: center;
  gap: 8px;
  transition: all 0.5s ease;
  width: 100%;
  justify-content: center;
}
.task-big.splitting {
  opacity: 0;
  transform: scale(0.8);
}
.task-icon { font-size: 1.1rem; }

.task-split-container {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  width: 100%;
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.6s ease, opacity 0.4s ease;
  opacity: 0;
}
.task-split-container.visible {
  max-height: 200px;
  opacity: 1;
}

.task-small {
  padding: 8px 12px;
  border-radius: 8px;
  background: rgba(var(--primary-rgb), 0.1);
  border: 1px solid rgba(var(--primary-rgb), 0.25);
  font-size: 0.78rem;
  font-weight: 500;
  color: var(--foreground);
  display: flex;
  align-items: center;
  gap: 6px;
  opacity: 0;
  transform: translateY(10px);
  transition: all 0.4s ease;
  transition-delay: calc(var(--delay) * 0.15s);
}
.task-split-container.visible .task-small {
  opacity: 1;
  transform: translateY(0);
}
.task-energy {
  font-size: 0.7rem;
  color: var(--accent);
  font-weight: 700;
  white-space: nowrap;
}

/* — Brain Rot / Shield Demo — */
.shield-ring {
  position: relative;
  width: 100px;
  height: 100px;
}
.shield-svg { width: 100%; height: 100%; transform: rotate(-90deg); }
.shield-fill {
  transition: stroke-dashoffset 1.5s ease;
}
.shield-score {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--primary);
}

.blocked-apps {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: center;
}
.blocked-app {
  padding: 6px 14px;
  border-radius: 100px;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--muted-fg);
  background: var(--muted);
  display: flex;
  align-items: center;
  gap: 5px;
  transition: all 0.4s ease;
  transition-delay: calc(var(--delay) * 0.2s);
}
.blocked-app.blocked {
  background: rgba(239, 68, 68, 0.12);
  color: var(--destructive);
  text-decoration: line-through;
}

/* — Water Tracker Demo — */
.water-tracker { width: 100%; }
.water-glasses {
  display: flex;
  gap: 6px;
  justify-content: center;
  margin-bottom: 8px;
}
.water-glass {
  width: 36px;
  height: 48px;
  background: none;
  border: none;
  cursor: pointer;
  transition: transform 0.2s ease;
  padding: 0;
}
.water-glass:hover { transform: scale(1.15); }
.water-glass svg { width: 100%; height: 100%; }
.water-level {
  transition: opacity 0.4s ease, d 0.4s ease;
}
.water-glass.filled .water-level {
  opacity: 0.6;
}
.water-glass.filled svg path:first-child {
  stroke: var(--primary);
}
@keyframes waterBounce {
  0%, 100% { transform: scale(1); }
  40% { transform: scale(1.2) translateY(-4px); }
}
.water-glass.just-filled {
  animation: waterBounce 0.4s ease;
}
.water-count {
  text-align: center;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--muted-fg);
}
.water-count span {
  color: var(--primary);
  font-size: 0.95rem;
}

.med-reminder {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  border-radius: var(--radius);
  background: var(--muted);
  cursor: pointer;
  transition: all 0.3s ease;
  width: 100%;
  justify-content: center;
}
.med-reminder:hover { background: rgba(var(--primary-rgb), 0.1); }
.med-pill-icon { font-size: 1.1rem; }
.med-text { font-size: 0.82rem; font-weight: 600; color: var(--foreground); }
.med-check {
  font-size: 1rem;
  font-weight: 700;
  color: var(--primary);
  opacity: 0;
  transform: scale(0);
  transition: all 0.35s ease;
}
.med-reminder.confirmed {
  background: rgba(var(--primary-rgb), 0.12);
  border: 1px solid rgba(var(--primary-rgb), 0.3);
}
.med-reminder.confirmed .med-check {
  opacity: 1;
  transform: scale(1);
}
.med-reminder.confirmed .med-text {
  color: var(--primary);
}

/* — Burnout Gauge Demo — */
.burnout-gauge {
  position: relative;
  width: 140px;
  height: 90px;
  display: flex;
  flex-direction: column;
  align-items: center;
}
.gauge-svg { width: 100%; height: 100%; }
.gauge-fill {
  transition: stroke-dashoffset 2s ease;
}
.gauge-label {
  position: absolute;
  bottom: 4px;
  font-size: 1.4rem;
  font-weight: 800;
  color: var(--foreground);
}
.gauge-status {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--muted-fg);
  margin-top: -2px;
}
.gauge-status.warning { color: var(--accent); }
.gauge-status.good { color: var(--primary); }

.burnout-factors {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  width: 100%;
}
.mini-factor {
  display: flex;
  align-items: center;
  gap: 8px;
}
.mini-factor span {
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--muted-fg);
  width: 42px;
  text-align: right;
  flex-shrink: 0;
}
.mini-bar {
  flex: 1;
  height: 6px;
  border-radius: 3px;
  background: var(--muted);
  overflow: hidden;
}
.mini-fill {
  height: 100%;
  border-radius: 3px;
  width: 0%;
  background: var(--primary);
  transition: width 1.5s ease;
}
.mini-fill.animated {
  width: calc(var(--target) * 1%);
}

/* ══════════════════════════════════════════════════
   FEATURES — Real App Showcase
   ══════════════════════════════════════════════════ */
.section-features {
  background: var(--bg);
}

/* ─ Tab bar with sliding pill indicator ─ */
.feat-tabs {
  display: flex;
  justify-content: center;
  gap: 6px;
  margin-bottom: 48px;
  flex-wrap: wrap;
  position: relative;
}
.tab-indicator {
  position: absolute;
  height: 100%;
  border-radius: 100px;
  background: var(--tab-puzzles);
  transition: left 0.4s cubic-bezier(0.4, 0, 0.2, 1),
              width 0.4s cubic-bezier(0.4, 0, 0.2, 1),
              background 0.4s ease;
  z-index: 0;
  top: 0;
  will-change: left, width;
}
.feat-tab {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 10px 22px;
  border-radius: 100px;
  font-size: 0.88rem;
  font-weight: 600;
  background: transparent;
  color: var(--muted-fg);
  transition: color 0.3s ease;
  position: relative;
  z-index: 1;
}
.feat-tab:hover { color: var(--foreground); }
.feat-tab.active { color: #fff; }
.feat-tab svg { transition: stroke 0.3s ease; }
.feat-tab.active svg { stroke: #fff; }

/* ─ Panel container ─ */
.feat-panels { position: relative; }
.feat-panel {
  display: none;
}
.feat-panel.active {
  display: block;
  animation: panelReveal 0.5s ease;
}
@keyframes panelReveal {
  from { opacity: 0; transform: translateY(16px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ─ Panel inner: phone + info side by side ─ */
.feat-panel-inner {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 56px;
  align-items: center;
}
.feat-phone {
  display: flex;
  justify-content: center;
}
.phone-frame {
  width: 280px;
  border-radius: 40px;
  overflow: hidden;
  background: #1c1c1e;
  padding: 12px;
  box-shadow: 0 8px 32px rgba(0,0,0,0.12), 0 2px 8px rgba(0,0,0,0.08);
  flex-shrink: 0;
}
.phone-frame img {
  width: 100%;
  border-radius: 28px;
  display: block;
}
.phone-frame-settings {
  background: var(--card);
  border: 1.5px solid var(--border);
  padding: 20px 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

/* ─ Feature info column ─ */
.feat-info h3 {
  font-size: clamp(1.3rem, 2.5vw, 1.6rem);
  font-weight: 800;
  margin-bottom: 12px;
}
.feat-list {
  list-style: none;
  padding: 0;
  margin: 0 0 24px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.feat-list li {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  opacity: 0; transform: translateX(-12px);
  animation: featItemIn 0.4s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}
.feat-list li:nth-child(1) { animation-delay: 0.1s; }
.feat-list li:nth-child(2) { animation-delay: 0.18s; }
.feat-list li:nth-child(3) { animation-delay: 0.26s; }
.feat-list li:nth-child(4) { animation-delay: 0.34s; }
.feat-list li:nth-child(5) { animation-delay: 0.42s; }
@keyframes featItemIn { to { opacity: 1; transform: translateX(0); } }
.feat-list li > span {
  font-size: 1.2rem;
  flex-shrink: 0;
  margin-top: 2px;
}
.feat-list li strong {
  display: block;
  font-size: 0.92rem;
  font-weight: 700;
  margin-bottom: 3px;
  color: var(--foreground);
}
.feat-list li p {
  font-size: 0.84rem;
  color: var(--muted-fg);
  line-height: 1.6;
  margin: 0;
}
.feat-badge {
  display: inline-block;
  padding: 8px 16px;
  background: linear-gradient(135deg, rgba(var(--primary-rgb), 0.08), rgba(212,168,75,0.08));
  background-size: 300% 300%;
  animation: badgeShimmer 4s ease infinite;
  border-radius: 100px;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--muted-fg);
  border: 1px solid rgba(var(--primary-rgb), 0.12);
}
@keyframes badgeShimmer {
  0%, 100% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
}

/* ─ Settings toggle demo (inside phone frame) ─ */
/* Settings toggle styles kept for Settings tab demo */
.settings-toggle-list { display: flex; flex-direction: column; gap: 2px; }
.settings-toggle-row {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 12px; border-radius: 10px; background: var(--bg);
  border: 1px solid var(--border); cursor: pointer; transition: all 0.3s ease;
}
.settings-toggle-row:hover { border-color: var(--tab-settings); transform: translateX(3px); }
.settings-toggle-icon {
  width: 32px; height: 32px; border-radius: 8px;
  background: rgba(139,92,246,0.1);
  display: flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.settings-toggle-info { flex: 1; display: flex; flex-direction: column; gap: 1px; }
.settings-toggle-name { font-size: 0.82rem; font-weight: 600; color: var(--foreground); }
.settings-toggle-desc { font-size: 0.68rem; color: var(--muted-fg); }
.settings-switch {
  width: 40px; height: 22px; border-radius: 11px; background: var(--muted);
  position: relative; transition: background 0.3s ease; flex-shrink: 0; cursor: pointer;
}
.settings-switch.active { background: var(--tab-settings); }
.settings-switch-thumb {
  width: 18px; height: 18px; border-radius: 50%; background: #fff;
  position: absolute; top: 2px; left: 2px;
  transition: transform 0.3s cubic-bezier(0.4,0,0.2,1);
  box-shadow: 0 1px 3px rgba(0,0,0,0.2);
}
.settings-switch.active .settings-switch-thumb { transform: translateX(18px); }
.settings-security-badge {
  display: flex; align-items: center; justify-content: center; gap: 6px;
  font-size: 0.72rem; font-weight: 600; color: var(--primary);
  padding: 8px; border-radius: 8px; background: rgba(var(--primary-rgb),0.06);
}

/* ══════════════════════════════════════════════════
   HOW IT WORKS
   ══════════════════════════════════════════════════ */
.section-how { background: var(--card); }
.how-steps { display: flex; align-items: flex-start; justify-content: center; gap: 0; }
.how-step { display: flex; flex-direction: column; align-items: center; text-align: center; max-width: 260px; }
.step-number {
  width: 48px; height: 48px; border-radius: 50%;
  background: linear-gradient(135deg, var(--primary), var(--accent)); color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.15rem; font-weight: 800; margin-bottom: 20px;
  box-shadow: 0 4px 16px rgba(var(--primary-rgb), 0.3);
}
.how-step {
  transition: transform var(--transition), box-shadow var(--transition);
  padding: 20px 16px; border-radius: var(--radius-lg);
}
.how-step:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 28px rgba(0,0,0,0.08);
  background: rgba(var(--primary-rgb), 0.03);
}
.how-step h3 { font-size: 1.15rem; font-weight: 700; margin-top: 16px; margin-bottom: 8px; }
.how-step p { font-size: 0.88rem; color: var(--muted-fg); line-height: 1.5; }
.how-connector { width: 80px; display: flex; align-items: center; padding-top: 100px; flex-shrink: 0; }
.how-connector svg { width: 100%; height: 24px; animation: connectorPulse 2s ease-in-out infinite; }
.dash-anim { animation: dashMove 2s linear infinite; }
@keyframes dashMove { to { stroke-dashoffset: -20; } }
@keyframes connectorPulse { 0%, 100% { opacity: 0.5; } 50% { opacity: 1; } }

/* ══════════════════════════════════════════════════
   AI COACH
   ══════════════════════════════════════════════════ */
.section-ai { background: var(--bg); }
.ai-grid { display: grid; grid-template-columns: 2fr 3fr; gap: 56px; align-items: center; }
.ai-phone-col { display: flex; justify-content: center; }
.ai-details-col .section-label { margin-bottom: 8px; }
.ai-details-col h2 { font-size: clamp(1.6rem, 3vw, 2.2rem); font-weight: 800; line-height: 1.2; margin-bottom: 16px; }
.ai-subtitle { font-size: 1rem; color: var(--muted-fg); margin-bottom: 24px; line-height: 1.6; }
.ai-personalities { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-bottom: 24px; }
.personality-card {
  padding: 14px; border-left: 3px solid var(--p-color);
  background: var(--card); border-radius: 0 var(--radius) var(--radius) 0;
  transition: all var(--transition);
}
.personality-card:hover { transform: translateX(4px); }
.personality-emoji { font-size: 1.2rem; margin-right: 6px; display: inline-block; transition: transform 0.3s ease; }
.personality-card:hover .personality-emoji { animation: emojiWiggle 0.3s ease; }
@keyframes emojiWiggle { 0%, 100% { transform: rotate(0deg); } 25% { transform: rotate(-12deg); } 75% { transform: rotate(12deg); } }
.personality-card strong { display: block; font-size: 0.85rem; margin-bottom: 2px; }
.personality-card > span { font-size: 0.78rem; color: var(--muted-fg); }

/* Chat demo */
.ai-chat-demo { display: flex; flex-direction: column; gap: 12px; margin-bottom: 24px; }
.chat-bubble { padding: 14px 18px; border-radius: 18px; font-size: 0.9rem; line-height: 1.5; max-width: 85%; }
.chat-user { background: var(--primary); color: #fff; align-self: flex-end; border-bottom-right-radius: 4px; }
.chat-ai { background: var(--card); border: 1px solid var(--border); align-self: flex-start; border-bottom-left-radius: 4px; }
.ai-meta { display: flex; flex-wrap: wrap; gap: 16px; align-items: center; }
.ai-badge { padding: 10px 16px; font-size: 0.82rem; font-weight: 500; }
.ai-stat { font-size: 0.9rem; color: var(--muted-fg); }
.ai-stat strong { font-size: 1.4rem; color: var(--primary); font-weight: 800; }

/* AI Capabilities Preview */
.ai-capabilities-preview {
  margin-top: 48px;
  padding-top: 40px;
  border-top: 1px solid var(--border);
}
.ai-cap-heading {
  text-align: center;
  font-size: 0.92rem;
  color: var(--muted-fg);
  margin-bottom: 24px;
  letter-spacing: 0.01em;
}
.ai-cap-heading strong { color: var(--primary); font-weight: 700; }
.ai-cap-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
}
.ai-cap-card {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 16px;
  border-left: 3px solid var(--cap-color, var(--primary));
  border-radius: 0 var(--radius) var(--radius) 0;
  text-decoration: none;
  color: inherit;
  transition: transform var(--transition), box-shadow var(--transition);
}
.ai-cap-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(0,0,0,0.1);
}
.ai-cap-icon { font-size: 1.3rem; flex-shrink: 0; margin-top: 1px; }
.ai-cap-card strong {
  display: block;
  font-size: 0.85rem;
  font-weight: 700;
  margin-bottom: 3px;
  color: var(--foreground);
}
.ai-cap-card span {
  font-size: 0.78rem;
  color: var(--muted-fg);
  line-height: 1.4;
}
.ai-cap-cta { text-align: center; margin-top: 28px; }

/* ══════════════════════════════════════════════════
   STATS + FOUNDER
   ══════════════════════════════════════════════════ */
.section-stats { background: var(--card); }
.stats-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; margin-bottom: 56px; }
.stat-card {
  padding: 32px 16px; text-align: center;
  border-left: 3px solid var(--stat-color, var(--primary));
  transition: box-shadow var(--transition), transform var(--transition);
}
.stat-card:hover {
  box-shadow: inset 0 0 40px rgba(var(--stat-color-rgb, var(--primary-rgb)), 0.06), 0 8px 24px rgba(0,0,0,0.08);
}
.stat-number {
  display: block; font-size: clamp(2.5rem, 5vw, 3.5rem); font-weight: 800; line-height: 1; margin-bottom: 8px;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
}
/* Stat pop-in when stagger fires */
[data-reveal-stagger].visible .stat-card .stat-number {
  animation: statPop 0.6s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}
@keyframes statPop {
  from { transform: scale(0.5) translateY(20px); opacity: 0; }
  to { transform: scale(1) translateY(0); opacity: 1; }
}
.stat-label { font-size: 0.85rem; color: var(--muted-fg); font-weight: 500; }
.founder-block { text-align: center; max-width: 700px; margin: 0 auto; }
.founder-avatar { margin: 0 auto 20px; width: 64px; height: 64px; border-radius: 16px; overflow: hidden; }
.founder-avatar img { width: 100%; height: 100%; object-fit: cover; }
.founder-quote {
  font-size: 1.05rem; font-style: italic; line-height: 1.7;
  color: var(--foreground); margin-bottom: 16px;
  padding: 0 20px; position: relative;
}
.founder-quote::before { content: '"'; position: absolute; left: 0; top: -4px; font-size: 2rem; color: var(--primary); opacity: 0.3; }
.founder-info { font-size: 0.9rem; color: var(--muted-fg); }
.founder-info strong { color: var(--foreground); }
.founder-links { display: flex; gap: 12px; justify-content: center; margin-top: 6px; }
.founder-links a { color: var(--primary); font-weight: 500; }
.founder-links a:hover { text-decoration: underline; }

/* ══════════════════════════════════════════════════
   PRIVACY
   ══════════════════════════════════════════════════ */
.section-privacy { background: var(--bg); }

/* — Privacy Pipeline — */
.privacy-pipeline {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 24px;
  margin-bottom: 48px;
}

.pipeline-track {
  position: relative;
  width: 100%;
  max-width: 700px;
  height: 6px;
  margin: 0 auto;
}
.pipeline-line {
  position: absolute;
  top: 0;
  left: 5%;
  right: 5%;
  height: 100%;
  border-radius: 3px;
  background: var(--muted);
  overflow: hidden;
}
.pipeline-line::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
  width: 0%;
  border-radius: 3px;
  background: linear-gradient(90deg, var(--primary), var(--accent));
  transition: width 0.6s ease;
}
.privacy-pipeline.animating .pipeline-line::after {
  width: 100%;
  transition: width 3s ease;
}

.pipeline-packet {
  position: absolute;
  top: 50%;
  left: 5%;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--primary);
  box-shadow: 0 0 12px rgba(var(--primary-rgb), 0.6);
  transform: translate(-50%, -50%);
  opacity: 0;
  transition: none;
  z-index: 2;
}
.privacy-pipeline.animating .pipeline-packet {
  opacity: 1;
  animation: packetTravel 3s ease forwards;
}
@keyframes packetTravel {
  0% { left: 5%; }
  25% { left: 35%; }
  50% { left: 65%; }
  75% { left: 95%; }
  100% { left: 95%; opacity: 0; }
}

.pipeline-stages {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  width: 100%;
  max-width: 700px;
}
.pipeline-stage {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 4px;
  opacity: 0.4;
  transform: scale(0.95);
  transition: all 0.4s ease;
}
.pipeline-stage.lit {
  opacity: 1;
  transform: scale(1);
}
.stage-icon-wrap {
  position: relative;
  width: 52px;
  height: 52px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 4px;
}
.stage-icon {
  font-size: 2rem;
  position: relative;
  z-index: 1;
}
.stage-pulse {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  border: 2px solid var(--stage-color, var(--primary));
  opacity: 0;
  transform: scale(0.8);
  transition: all 0.4s ease;
}
.pipeline-stage.lit .stage-pulse {
  opacity: 1;
  transform: scale(1);
  animation: stagePulse 1.5s ease infinite;
}
@keyframes stagePulse {
  0%, 100% { opacity: 0.4; transform: scale(1); }
  50% { opacity: 0; transform: scale(1.4); }
}
/* Pipeline stage color accents */
.pipeline-stage {
  border-top: 2px solid var(--stage-color, var(--primary));
  padding-top: 16px;
}
.pipeline-stage strong { color: var(--stage-color, var(--foreground)); }
.pipeline-stage strong {
  font-size: 0.88rem;
  font-weight: 700;
}
.pipeline-stage > span {
  font-size: 0.72rem;
  color: var(--muted-fg);
}
.stage-detail {
  font-size: 0.72rem;
  color: var(--primary);
  line-height: 1.4;
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  transition: max-height 0.4s ease, opacity 0.3s ease, margin 0.3s ease;
  margin-top: 0;
}
.pipeline-stage.lit .stage-detail {
  max-height: 80px;
  opacity: 1;
  margin-top: 6px;
}
.pipeline-replay-btn {
  margin-top: 8px;
}

/* — Trust Badges (flip cards) — */
.trust-badges {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}
.trust-badge {
  position: relative;
  padding: 0;
  perspective: 600px;
  min-height: 160px;
  cursor: pointer;
}
.trust-badge-front,
.trust-badge-back {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 24px 16px;
  border-radius: var(--radius-lg);
  backface-visibility: hidden;
  transition: transform 0.5s ease;
}
.trust-badge-front {
  transform: rotateY(0deg);
  position: relative;
}
.trust-badge-front::after {
  content: ''; position: absolute; inset: 0; border-radius: var(--radius-lg);
  background: linear-gradient(135deg, transparent 30%, rgba(var(--primary-rgb), 0.12) 50%, transparent 70%);
  background-size: 300% 300%; opacity: 0;
  transition: opacity 0.3s ease;
}
.trust-badge:hover .trust-badge-front::after {
  opacity: 1;
  animation: shimmerSweep 1.5s ease;
}
@keyframes shimmerSweep {
  from { background-position: 200% 200%; }
  to { background-position: -100% -100%; }
}
.trust-badge-back {
  transform: rotateY(180deg);
  background: rgba(var(--primary-rgb), 0.08);
  border: 1.5px solid rgba(var(--primary-rgb), 0.2);
  border-radius: var(--radius-lg);
  gap: 8px;
}
.trust-badge:hover .trust-badge-front,
.trust-badge:focus .trust-badge-front {
  transform: rotateY(-180deg);
}
.trust-badge:hover .trust-badge-back,
.trust-badge:focus .trust-badge-back {
  transform: rotateY(0deg);
}
.trust-icon {
  font-size: 2rem;
  display: block;
  margin-bottom: 12px;
}
.trust-badge strong {
  display: block;
  font-size: 0.9rem;
  margin-bottom: 6px;
}
.trust-badge-front > span {
  font-size: 0.8rem;
  color: var(--muted-fg);
  line-height: 1.4;
}
.trust-back-icon {
  font-size: 1.5rem;
}
.trust-badge-back > span {
  font-size: 0.78rem;
  color: var(--foreground);
  line-height: 1.5;
}

/* ══════════════════════════════════════════════════
   ARCHITECTURE (EXPANDABLE)
   ══════════════════════════════════════════════════ */
.section-arch { background: var(--card); }
.arch-toggle {
  width: 100%; display: flex; justify-content: space-between; align-items: center;
  padding: 20px 24px; border-radius: var(--radius-lg);
  background: var(--muted); font-size: 1rem; font-weight: 600;
  transition: all var(--transition);
}
.arch-toggle:hover { background: var(--border); }
.arch-toggle-label { display: flex; align-items: center; gap: 10px; }
.arch-chevron { transition: transform var(--transition); }
.section-arch.expanded .arch-chevron { transform: rotate(180deg); }
.arch-content {
  max-height: 0; overflow: hidden;
  transition: max-height 0.6s ease, padding 0.4s ease;
  padding: 0 4px;
}
.section-arch.expanded .arch-content { max-height: 20000px; padding-top: 32px; }
.arch-section { margin-bottom: 48px; }
.arch-section h3 { font-size: 1.3rem; font-weight: 700; margin-bottom: 12px; }
.arch-desc { color: var(--muted-fg); margin-bottom: 20px; line-height: 1.6; }

/* ── Interactive Architecture Diagram ── */
.arch-diagram { position: relative; }
.arch-svg-lines { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; z-index: 0; }
.arch-diagram-layer { position: relative; z-index: 1; margin-bottom: 4px; }
.arch-layer-title {
  display: flex; align-items: center; gap: 8px;
  padding: 10px 16px; border-left: 4px solid var(--layer-color);
  background: var(--bg); border-radius: 0 var(--radius) var(--radius) 0;
  font-weight: 600; font-size: 0.95rem; margin-bottom: 12px;
}
.layer-icon { font-size: 1.2rem; }
.layer-tag {
  font-size: 0.72rem; font-weight: 500; color: var(--muted-fg);
  background: var(--muted); padding: 2px 8px; border-radius: 4px; margin-left: auto;
}
.arch-nodes { display: flex; flex-wrap: wrap; gap: 8px; padding: 0 8px; margin-bottom: 8px; }
.arch-nodes-wrap { gap: 8px; }
.arch-node {
  display: flex; align-items: center; gap: 6px;
  padding: 8px 14px; border-radius: var(--radius);
  background: var(--bg); border: 1.5px solid var(--border);
  font-size: 0.82rem; font-weight: 500;
  cursor: pointer; transition: all var(--transition); position: relative;
}
.arch-node:hover { border-color: var(--primary); transform: translateY(-2px); box-shadow: 0 4px 12px rgba(0,0,0,0.08); }
.arch-node.selected { border-color: var(--primary); background: rgba(var(--primary-rgb),0.08); box-shadow: 0 0 0 3px rgba(var(--primary-rgb),0.15); }
.arch-node.highlighted { border-color: var(--accent); background: rgba(212,168,75,0.06); }
.arch-node.dimmed { opacity: 0.35; transform: scale(0.97); }
.node-icon {
  width: 28px; height: 28px; border-radius: 6px;
  display: flex; align-items: center; justify-content: center;
  background: rgba(var(--primary-rgb),0.08); font-size: 0.9rem;
}
.node-name { white-space: nowrap; }

/* Node detail panels */
.arch-node-detail {
  display: none; padding: 14px 18px; margin: 4px 8px 12px;
  border-radius: var(--radius); border-left: 3px solid var(--primary);
  background: var(--bg); font-size: 0.85rem; line-height: 1.6;
  animation: fadeIn 0.3s ease;
}
.arch-node-detail.open { display: block; }
.arch-node-detail strong { display: block; font-size: 0.9rem; color: var(--primary); margin-bottom: 4px; }
.arch-node-detail p { color: var(--muted-fg); margin: 0; }

/* Diagram connectors */
.arch-diagram-connector { padding: 0 8px; opacity: 0.5; }

/* ── Data Flow Tabs ── */
.flow-tabs {
  display: flex; gap: 6px; margin-bottom: 24px; flex-wrap: wrap;
}
.flow-tab {
  padding: 8px 18px; border-radius: 100px;
  font-size: 0.82rem; font-weight: 600;
  background: var(--muted); color: var(--muted-fg);
  transition: all var(--transition);
}
.flow-tab:hover { color: var(--foreground); }
.flow-tab.active { background: var(--primary); color: #fff; }

.flow-panels { position: relative; }
.flow-panel { display: none; }
.flow-panel.active { display: block; animation: fadeIn 0.4s ease; }

/* Flow diagrams */
.flow-diagram {
  display: flex; align-items: center; gap: 4px; flex-wrap: wrap;
  padding: 24px 16px; background: var(--bg); border-radius: var(--radius-lg);
  overflow-x: auto;
}
.flow-diagram-vertical {
  flex-direction: column; align-items: center;
}
.flow-step {
  display: flex; align-items: center; gap: 10px;
  padding: 12px 16px; border-radius: var(--radius);
  background: var(--card); border: 1.5px solid var(--border);
  min-width: 120px; flex-shrink: 0;
  transition: all var(--transition);
}
.flow-step:hover { border-color: var(--primary); transform: translateY(-2px); }
.flow-step-success { border-color: var(--success); background: rgba(34,197,94,0.05); }
.flow-step-icon {
  width: 36px; height: 36px; border-radius: 8px;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.2rem; flex-shrink: 0;
  background: rgba(var(--primary-rgb),0.08);
}
.flow-step-text { display: flex; flex-direction: column; }
.flow-step-text strong { font-size: 0.82rem; font-weight: 600; }
.flow-step-text span { font-size: 0.72rem; color: var(--muted-fg); line-height: 1.3; }
.flow-arrow { flex-shrink: 0; }
.flow-arrow-down { flex-shrink: 0; }

/* ── Tech Stack Layers ── */
.tech-stack-layers { display: flex; flex-direction: column; gap: 0; }
.tech-layer { display: flex; align-items: center; gap: 16px; }
.tech-layer-label {
  width: 140px; flex-shrink: 0; display: flex; align-items: center; gap: 8px;
  font-size: 0.78rem; font-weight: 700; color: var(--tl-color);
}
.tech-layer-dot {
  width: 8px; height: 8px; border-radius: 50%; background: var(--tl-color); flex-shrink: 0;
}
.tech-layer-cards { display: flex; flex-wrap: wrap; gap: 10px; flex: 1; }
.tech-card-v2 {
  position: relative; display: flex; align-items: center; gap: 10px;
  padding: 10px 14px; flex: 1; min-width: 180px; cursor: default;
}
.tech-card-icon {
  width: 44px; height: 44px; border-radius: 10px; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
  background: rgba(var(--primary-rgb), 0.06);
  color: var(--tc-color, var(--primary));
}
.tech-card-text { min-width: 0; }
.tech-card-text strong { display: block; font-size: 0.88rem; font-weight: 700; }
.tech-stat { display: block; font-size: 0.72rem; color: var(--muted-fg); }
.tech-card-detail {
  position: absolute; bottom: calc(100% + 6px); left: 50%; transform: translateX(-50%);
  background: var(--card); color: var(--foreground); font-size: 0.72rem; line-height: 1.4;
  padding: 8px 12px; border-radius: 6px; white-space: nowrap; max-width: 300px;
  border: 1px solid var(--border); box-shadow: 0 4px 12px rgba(0,0,0,0.3);
  opacity: 0; pointer-events: none; transition: opacity 0.2s ease; z-index: 10;
}
.tech-card-v2:hover .tech-card-detail { opacity: 1; }
.tech-layer-connector { text-align: center; padding: 0 0 0 140px; }

/* ── Siri Demo ── */
.siri-demo-display {
  display: flex; flex-direction: column; align-items: center; gap: 16px;
  padding: 32px 24px; margin-bottom: 20px; text-align: center;
}
.siri-waveform { display: flex; align-items: center; gap: 3px; height: 28px; }
.siri-waveform span {
  width: 3px; border-radius: 2px; background: var(--primary);
  animation: siriWave 1.2s ease-in-out infinite;
  opacity: 0.4;
}
.siri-waveform.active span { opacity: 1; }
.siri-waveform span:nth-child(1) { height: 8px; animation-delay: 0s; }
.siri-waveform span:nth-child(2) { height: 16px; animation-delay: 0.15s; }
.siri-waveform span:nth-child(3) { height: 24px; animation-delay: 0.3s; }
.siri-waveform span:nth-child(4) { height: 16px; animation-delay: 0.45s; }
.siri-waveform span:nth-child(5) { height: 8px; animation-delay: 0.6s; }
@keyframes siriWave {
  0%, 100% { transform: scaleY(0.4); }
  50% { transform: scaleY(1); }
}
.siri-prompt {
  font-size: 1.2rem; font-weight: 600; color: var(--foreground);
  min-height: 1.5em;
}
.siri-typed { color: var(--primary); }
.siri-cursor {
  color: var(--primary); font-weight: 400;
  animation: blink 0.8s step-end infinite;
}
@keyframes blink { 50% { opacity: 0; } }
.siri-response {
  font-size: 0.9rem; color: var(--muted-fg); padding: 10px 20px;
  border-radius: var(--radius); max-width: 400px;
  opacity: 0; transform: translateY(6px);
  transition: opacity 0.4s ease, transform 0.4s ease;
}
.siri-response.visible { opacity: 1; transform: translateY(0); }
.siri-chips { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; }
.siri-chip {
  padding: 8px 16px; border-radius: 20px; font-size: 0.8rem; font-weight: 600;
  background: var(--muted); color: var(--foreground); border: 1px solid var(--border);
  cursor: pointer; transition: all 0.2s ease;
}
.siri-chip:hover, .siri-chip.active {
  background: rgba(var(--primary-rgb), 0.15); border-color: var(--primary); color: var(--primary);
}

/* ── Edge Function Cards ── */
.edge-legend { display: flex; gap: 16px; margin-bottom: 16px; flex-wrap: wrap; }
.edge-legend-item {
  display: flex; align-items: center; gap: 6px; font-size: 0.78rem; font-weight: 600;
  color: var(--el-color);
}
.edge-legend-item::before {
  content: ''; width: 10px; height: 10px; border-radius: 3px; background: var(--el-color);
}
.edge-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
.edge-card {
  text-align: left; cursor: pointer; padding: 12px 16px; border-left: 3px solid var(--ec-color);
  transition: all 0.2s ease;
}
.edge-card:hover { border-color: var(--ec-color); background: rgba(var(--primary-rgb), 0.03); }
.edge-card-header { display: flex; align-items: center; gap: 10px; }
.edge-card-emoji { font-size: 1.2rem; flex-shrink: 0; }
.edge-card-title { flex: 1; min-width: 0; }
.edge-card-title code {
  font-family: 'SF Mono', 'Fira Code', Consolas, monospace;
  font-size: 0.8rem; font-weight: 600; color: var(--ec-color); display: block;
}
.edge-card-title span { font-size: 0.72rem; color: var(--muted-fg); }
.edge-chevron {
  font-size: 1.2rem; color: var(--muted-fg); transition: transform 0.2s ease; flex-shrink: 0;
}
.edge-card[aria-expanded="true"] .edge-chevron { transform: rotate(90deg); }
.edge-card-detail {
  font-size: 0.78rem; color: var(--muted-fg); line-height: 1.5;
  max-height: 0; overflow: hidden; transition: max-height 0.3s ease, margin-top 0.3s ease;
  margin-top: 0;
}
.edge-card[aria-expanded="true"] .edge-card-detail { max-height: 80px; margin-top: 10px; }

/* ── Architecture Responsive ── */
@media (max-width: 1024px) {
  .tech-layer { flex-direction: column; align-items: flex-start; gap: 8px; }
  .tech-layer-label { width: auto; }
  .tech-layer-connector { padding-left: 0; }
}
@media (max-width: 768px) {
  .arch-nodes { gap: 6px; }
  .arch-node { padding: 6px 10px; font-size: 0.78rem; }
  .node-icon { width: 24px; height: 24px; font-size: 0.8rem; }
  .flow-diagram { padding: 16px 12px; gap: 4px; }
  .flow-step { padding: 10px 12px; min-width: 100px; }
  .flow-step-text strong { font-size: 0.78rem; }
  .flow-step-text span { font-size: 0.68rem; }
  .edge-grid { grid-template-columns: 1fr; }
  .tech-card-v2 { min-width: 140px; }
  .siri-prompt { font-size: 1rem; }
}
@media (max-width: 480px) {
  .flow-diagram { flex-direction: column; align-items: center; }
  .flow-arrow { transform: rotate(90deg); }
  .siri-prompt { font-size: 0.9rem; }
  .siri-demo-display { padding: 20px 16px; }
  .tech-card-detail { white-space: normal; }
}

/* ══════════════════════════════════════════════════
   COMPARISON TABLE
   ══════════════════════════════════════════════════ */
.section-compare { background: var(--bg); }
.compare-wrap { overflow-x: hidden; border-radius: var(--radius-lg); border: 1px solid var(--border); }
.compare-table { width: 100%; border-collapse: collapse; text-align: center; font-size: 0.88rem; }
.compare-table th, .compare-table td { padding: 12px 16px; border-bottom: 1px solid var(--border); }
.compare-table th { font-weight: 600; background: var(--muted); position: sticky; top: 0; }
.compare-table td:first-child { text-align: left; font-weight: 500; }
.col-highlight { background: rgba(var(--primary-rgb),0.06); box-shadow: inset 0 0 0 0 transparent; }
.compare-table th.col-highlight {
  background: linear-gradient(180deg, rgba(var(--primary-rgb),0.18), rgba(var(--primary-rgb),0.1));
  color: var(--primary); font-weight: 800; font-size: 0.92rem;
}
.check { font-weight: 700; font-size: 1rem; display: inline-block; }
.check.yes { color: var(--success); }
.check.no { color: var(--muted-fg); opacity: 0.5; }
.check.partial { color: var(--accent); }
.compare-table tbody tr:hover { background: rgba(var(--primary-rgb),0.03); }
/* Check mark pop-in with row stagger */
.compare-wrap[data-reveal].visible .check.yes {
  animation: checkPop 0.4s cubic-bezier(0.16, 1, 0.3, 1) both;
}
.compare-wrap[data-reveal] .check.yes { transform: scale(0); opacity: 0; }
.compare-table tbody tr:nth-child(1) .check.yes { animation-delay: 0.05s; }
.compare-table tbody tr:nth-child(2) .check.yes { animation-delay: 0.1s; }
.compare-table tbody tr:nth-child(3) .check.yes { animation-delay: 0.15s; }
.compare-table tbody tr:nth-child(4) .check.yes { animation-delay: 0.2s; }
.compare-table tbody tr:nth-child(5) .check.yes { animation-delay: 0.25s; }
.compare-table tbody tr:nth-child(6) .check.yes { animation-delay: 0.3s; }
.compare-table tbody tr:nth-child(7) .check.yes { animation-delay: 0.35s; }
.compare-table tbody tr:nth-child(8) .check.yes { animation-delay: 0.4s; }
.compare-table tbody tr:nth-child(9) .check.yes { animation-delay: 0.45s; }
.compare-table tbody tr:nth-child(10) .check.yes { animation-delay: 0.5s; }
.compare-table tbody tr:nth-child(11) .check.yes { animation-delay: 0.55s; }
.compare-table tbody tr:nth-child(12) .check.yes { animation-delay: 0.6s; }
.compare-table tbody tr:nth-child(13) .check.yes { animation-delay: 0.65s; }
.compare-table tbody tr:nth-child(14) .check.yes { animation-delay: 0.7s; }
.compare-table tbody tr:nth-child(15) .check.yes { animation-delay: 0.75s; }
@keyframes checkPop {
  from { transform: scale(0); opacity: 0; }
  to { transform: scale(1); opacity: 1; }
}

/* ══════════════════════════════════════════════════
   DOWNLOAD CTA
   ══════════════════════════════════════════════════ */
.section-download {
  position: relative; text-align: center;
  padding: 80px 0; overflow: hidden;
  background: linear-gradient(135deg, rgba(var(--primary-rgb), 0.06) 0%, var(--bg) 50%, rgba(212,168,75,0.06) 100%);
}
.section-download::before {
  content: ''; position: absolute; inset: 0;
  background: radial-gradient(ellipse at center, rgba(var(--primary-rgb), 0.08), transparent 70%);
  pointer-events: none;
}
[data-theme="dark"] .section-download::before {
  background: radial-gradient(ellipse at center, rgba(var(--primary-rgb), 0.04), transparent 70%);
}
.download-content { position: relative; z-index: 2; }
.download-content h2 { font-size: clamp(2rem, 5vw, 3.2rem); font-weight: 900; margin-bottom: 16px; letter-spacing: -0.02em; }
.download-content p { font-size: 1.1rem; color: var(--muted-fg); margin-bottom: 32px; }
.download-buttons {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}
.android-badge { display: inline-block; font-size: 0.88rem; color: var(--muted-fg); }

/* ══════════════════════════════════════════════════
   CONTACT / COMMUNITY
   ══════════════════════════════════════════════════ */
.section-contact { background: var(--bg); }
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 32px;
  margin-top: 48px;
}
.contact-card {
  background: var(--card);
  border: 1.5px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 40px 32px;
}
.contact-card-main {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 16px;
}
.contact-icon { font-size: 2.5rem; display: inline-block; transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1); }
.contact-card:hover .contact-icon { animation: iconBounce 0.4s ease; }
@keyframes iconBounce { 0% { transform: scale(1); } 40% { transform: scale(1.25); } 70% { transform: scale(0.95); } 100% { transform: scale(1); } }
.contact-card-main h3 {
  font-size: 1.4rem;
  font-weight: 800;
}
.contact-card-main > p {
  font-size: 0.95rem;
  color: var(--muted-fg);
  line-height: 1.7;
  max-width: 360px;
}
.contact-email-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-top: 8px;
  padding: 14px 28px;
  background: var(--primary);
  color: #fff;
  font-weight: 700;
  font-size: 1rem;
  border-radius: 100px;
  transition: transform var(--transition), box-shadow var(--transition);
}
.contact-email-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 24px rgba(var(--primary-rgb), 0.3);
}
.contact-reasons {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.contact-reason {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  padding: 20px 24px;
  background: var(--card);
  border: 1.5px solid var(--border);
  border-left: 3px solid var(--reason-color, var(--primary));
  border-radius: var(--radius);
  transition: border-color var(--transition), transform var(--transition), box-shadow var(--transition);
}
.contact-reason:hover {
  border-color: var(--reason-color, var(--primary));
  border-left-color: var(--reason-color, var(--primary));
  transform: translateY(-2px);
  box-shadow: 0 4px 16px rgba(0,0,0,0.06);
}
.contact-reason > span {
  font-size: 1.4rem;
  flex-shrink: 0;
  margin-top: 2px;
}
.contact-reason strong {
  display: block;
  font-size: 0.95rem;
  font-weight: 700;
  margin-bottom: 4px;
}
.contact-reason p {
  font-size: 0.85rem;
  color: var(--muted-fg);
  line-height: 1.55;
}
.contact-footer-note {
  text-align: center;
  margin-top: 32px;
  font-size: 0.88rem;
  color: var(--muted-fg);
  font-weight: 600;
  font-style: italic;
}

/* ══════════════════════════════════════════════════
   FOOTER
   ══════════════════════════════════════════════════ */
.footer { background: #28242b; color: rgba(255,255,255,0.7); padding: 64px 0 0; }
[data-theme="dark"] .footer { background: #1a171c; }
.footer-grid {
  display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 40px; padding-bottom: 40px;
  border-bottom: none; position: relative;
}
.footer-grid::after {
  content: ''; position: absolute; bottom: 0; left: 0; right: 0; height: 2px;
  background: linear-gradient(90deg, transparent, var(--primary), var(--accent), var(--primary), transparent);
  opacity: 0.5;
}
.footer-logo-link { display: flex; align-items: center; gap: 10px; color: #fff; font-weight: 700; font-size: 1.15rem; margin-bottom: 8px; }
.footer-logo-img { border-radius: 8px; }
.footer-brand p { font-size: 0.88rem; color: rgba(255,255,255,0.5); margin-bottom: 16px; }
.footer-social { display: flex; gap: 12px; }
.footer-social a { color: rgba(255,255,255,0.5); transition: color var(--transition), transform var(--transition); display: inline-block; }
.footer-social a:hover { color: var(--primary); transform: scale(1.2) translateY(-2px); }
.footer-col h5 { font-size: 0.9rem; font-weight: 600; color: #fff; margin-bottom: 14px; }
.footer-col a { display: block; font-size: 0.85rem; color: rgba(255,255,255,0.45); padding: 3px 0; transition: color var(--transition); }
.footer-col a:hover { color: var(--primary); }
.footer-bottom {
  display: flex; flex-wrap: wrap; justify-content: center; gap: 8px 24px;
  padding: 20px 0; font-size: 0.78rem; color: rgba(255,255,255,0.3); text-align: center;
}
.footer-bottom a { color: rgba(255,255,255,0.4); }
.footer-bottom a:hover { color: var(--primary); }
.footer-breathe {
  animation: breathe 3s ease-in-out infinite;
}
.footer-heart {
  display: inline-block;
  animation: heartPulse 1.2s ease-in-out infinite;
  font-size: 1em;
}
@keyframes heartPulse {
  0%, 100% { transform: scale(1); }
  15% { transform: scale(1.3); }
  30% { transform: scale(1); }
  45% { transform: scale(1.2); }
  60% { transform: scale(1); }
}
@keyframes breathe {
  0%, 100% { opacity: 0.4; }
  50% { opacity: 1; }
}

/* ══════════════════════════════════════════════════
   LEGAL PAGES (Privacy Policy, Terms of Service)
   ══════════════════════════════════════════════════ */

/* ── Hero ── */
.legal-hero {
  padding-top: calc(var(--nav-h) + 48px);
  padding-bottom: 0;
  overflow: hidden;
}
.legal-hero-inner {
  text-align: center;
  margin-bottom: 48px;
}
.legal-hero-inner h1 {
  font-size: clamp(2.2rem, 5vw, 3.2rem);
  font-weight: 800;
  line-height: 1.15;
  margin-bottom: 12px;
}
.legal-updated {
  display: inline-block;
  margin-top: 12px;
  padding: 6px 16px;
  border-radius: 100px;
  background: var(--muted);
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--muted-fg);
}

/* ── Highlight Cards ── */
.legal-highlights {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}
.legal-highlight {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 24px 16px;
  gap: 6px;
}
.legal-highlight-icon {
  font-size: 1.8rem;
  margin-bottom: 4px;
}
.legal-highlight strong {
  font-size: 0.92rem;
  font-weight: 700;
}
.legal-highlight > span {
  font-size: 0.78rem;
  color: var(--muted-fg);
  line-height: 1.4;
}

/* ── Body Layout: Sidebar TOC + Content ── */
.legal-body {
  padding-top: 56px;
}
.legal-layout {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 56px;
  align-items: start;
}

/* ── Table of Contents ── */
.legal-toc {
  position: sticky;
  top: calc(var(--nav-h) + 24px);
  max-height: calc(100vh - var(--nav-h) - 48px);
  overflow-y: auto;
}
.legal-toc nav {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.legal-toc-title {
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted-fg);
  margin-bottom: 8px;
  padding-left: 12px;
}
.legal-toc-link {
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--muted-fg);
  padding: 6px 12px;
  border-left: 2px solid transparent;
  border-radius: 0 6px 6px 0;
  transition: all var(--transition);
  line-height: 1.4;
}
.legal-toc-link:hover {
  color: var(--foreground);
  background: rgba(var(--primary-rgb), 0.04);
}
.legal-toc-link.active {
  color: var(--primary);
  font-weight: 600;
  border-left-color: var(--primary);
  background: rgba(var(--primary-rgb), 0.06);
}

/* ── Content Column ── */
.legal-content {
  max-width: 800px;
  min-width: 0;
}

/* ── Section Blocks ── */
.legal-block {
  margin-bottom: 48px;
  padding-bottom: 48px;
  border-bottom: 1px solid var(--border);
}
.legal-block:last-child {
  border-bottom: none;
  margin-bottom: 0;
}
.legal-block h2 {
  font-size: 1.5rem;
  font-weight: 800;
  margin-bottom: 20px;
  color: var(--foreground);
  display: flex;
  align-items: center;
  gap: 10px;
  line-height: 1.3;
}
.legal-block-icon {
  font-size: 1.3rem;
}
.legal-block h3 {
  font-size: 1.1rem;
  font-weight: 600;
  margin: 20px 0 10px;
  color: var(--foreground);
}
.legal-block p {
  font-size: 0.95rem;
  line-height: 1.8;
  color: var(--muted-fg);
  margin-bottom: 14px;
}
.legal-block > ul {
  list-style: none;
  padding-left: 0;
  margin-bottom: 16px;
}
.legal-block > ul > li {
  font-size: 0.95rem;
  line-height: 1.8;
  color: var(--muted-fg);
  margin-bottom: 8px;
  padding-left: 20px;
  position: relative;
}
.legal-block > ul > li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 11px;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--primary);
}
.legal-block > ul > li strong,
.legal-block ul li strong {
  color: var(--foreground);
}
.legal-block a {
  color: var(--primary);
  text-decoration: underline;
  text-decoration-color: rgba(var(--primary-rgb), 0.3);
  text-underline-offset: 2px;
  transition: text-decoration-color var(--transition);
}
.legal-block a:hover {
  text-decoration-color: var(--primary);
}

/* ── Accordion ── */
.legal-accordion {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.legal-accordion-btn {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  text-align: left;
  padding: 14px 18px;
  border-radius: var(--radius);
  background: var(--card);
  border: 1.5px solid var(--border);
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--foreground);
  cursor: pointer;
  transition: all var(--transition);
}
.legal-accordion-btn:hover {
  border-color: var(--primary);
  background: rgba(var(--primary-rgb), 0.03);
}
.legal-accordion-btn[aria-expanded="true"] {
  border-color: var(--primary);
  background: rgba(var(--primary-rgb), 0.06);
}
.legal-accordion-icon {
  font-size: 1.2rem;
  flex-shrink: 0;
}
.legal-accordion-btn > span:nth-child(2) {
  flex: 1;
}
.legal-accordion-chevron {
  flex-shrink: 0;
  transition: transform var(--transition);
  color: var(--muted-fg);
}
.legal-accordion-btn[aria-expanded="true"] .legal-accordion-chevron {
  transform: rotate(180deg);
  color: var(--primary);
}
.legal-accordion-panel {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s ease, padding 0.3s ease;
  padding: 0 18px;
}
.legal-accordion-panel.open {
  max-height: 800px;
  padding: 16px 18px;
}
.legal-accordion-panel ul {
  list-style: none;
  padding: 0;
  margin: 0;
}
.legal-accordion-panel ul li {
  font-size: 0.92rem;
  line-height: 1.75;
  color: var(--muted-fg);
  margin-bottom: 10px;
  padding-left: 18px;
  position: relative;
}
.legal-accordion-panel ul li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 10px;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--primary);
}

/* ── Callout Box ── */
.legal-callout {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  padding: 20px 24px;
  border-radius: var(--radius-lg);
  background: rgba(var(--primary-rgb), 0.06);
  border: 1.5px solid rgba(var(--primary-rgb), 0.15);
  margin-bottom: 20px;
}
.legal-callout-accent {
  background: rgba(212, 168, 75, 0.06);
  border-color: rgba(212, 168, 75, 0.2);
}
.legal-callout-icon {
  font-size: 1.6rem;
  flex-shrink: 0;
  margin-top: 2px;
}
.legal-callout strong {
  display: block;
  font-size: 1rem;
  font-weight: 700;
  color: var(--foreground);
  margin-bottom: 4px;
}
.legal-callout p {
  font-size: 0.92rem;
  line-height: 1.7;
  color: var(--muted-fg);
  margin: 0;
}

/* ── Security Cards ── */
.legal-cards {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-bottom: 16px;
}
.legal-card {
  padding: 24px 20px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.legal-card-icon {
  font-size: 1.6rem;
}
.legal-card strong {
  font-size: 0.95rem;
  font-weight: 700;
}
.legal-card p {
  font-size: 0.85rem;
  line-height: 1.65;
  color: var(--muted-fg);
  margin: 0;
}

/* ── Data Flow Visualization ── */
.legal-flow {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0;
  margin: 24px 0;
}
.legal-flow-step {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 18px 24px;
  border-radius: var(--radius-lg);
  background: var(--card);
  border: 1.5px solid var(--border);
  width: 100%;
  max-width: 480px;
  transition: border-color var(--transition), transform var(--transition);
}
.legal-flow-step:hover {
  border-color: var(--primary);
  transform: translateY(-2px);
}
.legal-flow-icon {
  font-size: 1.6rem;
  flex-shrink: 0;
}
.legal-flow-step div {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.legal-flow-step strong {
  font-size: 0.92rem;
  font-weight: 700;
}
.legal-flow-step span {
  font-size: 0.82rem;
  color: var(--muted-fg);
  line-height: 1.5;
}
.legal-flow-arrow {
  padding: 6px 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* ── Third-Party Table ── */
.legal-table-wrap {
  overflow-x: auto;
  border-radius: var(--radius-lg);
  border: 1.5px solid var(--border);
  margin-bottom: 16px;
}
.legal-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
}
.legal-table th,
.legal-table td {
  padding: 14px 18px;
  text-align: left;
  border-bottom: 1px solid var(--border);
}
.legal-table th {
  font-weight: 700;
  font-size: 0.82rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--muted-fg);
  background: var(--muted);
}
.legal-table tbody tr {
  transition: background var(--transition);
}
.legal-table tbody tr:hover {
  background: rgba(var(--primary-rgb), 0.03);
}
.legal-table tbody tr:last-child td {
  border-bottom: none;
}
.legal-table td {
  color: var(--muted-fg);
}
.legal-table td strong {
  color: var(--foreground);
}

/* ── Rights Grid ── */
.legal-rights-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
.legal-right {
  padding: 20px;
  border-radius: var(--radius);
  background: var(--card);
  border: 1.5px solid var(--border);
  transition: border-color var(--transition), transform var(--transition);
}
.legal-right:hover {
  border-color: var(--primary);
  transform: translateY(-2px);
}
.legal-right strong {
  display: block;
  font-size: 0.92rem;
  font-weight: 700;
  margin-bottom: 6px;
  color: var(--foreground);
}
.legal-right p {
  font-size: 0.85rem;
  line-height: 1.65;
  color: var(--muted-fg);
  margin: 0;
}

/* ── Contact Grid ── */
.legal-contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
.legal-contact-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 28px 20px;
  gap: 6px;
  cursor: default;
  text-decoration: none;
}
a.legal-contact-card {
  cursor: pointer;
}
a.legal-contact-card:hover {
  border-color: var(--primary);
}
.legal-contact-card-icon {
  font-size: 1.6rem;
  margin-bottom: 4px;
}
.legal-contact-card strong {
  font-size: 0.92rem;
  font-weight: 700;
}
.legal-contact-card span {
  font-size: 0.85rem;
  color: var(--muted-fg);
  line-height: 1.5;
}

/* ── Back to Top Button ── */
.legal-back-to-top {
  position: fixed;
  bottom: 32px;
  right: 32px;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--primary);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 16px rgba(var(--primary-rgb), 0.3);
  opacity: 0;
  pointer-events: none;
  transform: translateY(12px);
  transition: opacity var(--transition), transform var(--transition), background var(--transition);
  z-index: 100;
  cursor: pointer;
  border: none;
}
.legal-back-to-top.visible {
  opacity: 1;
  pointer-events: all;
  transform: translateY(0);
}
.legal-back-to-top:hover {
  background: #2fa584;
  transform: translateY(-2px);
}

/* ══════════════════════════════════════════════════
   TEAM PAGE
   ══════════════════════════════════════════════════ */
/* ── Team Hero Gradient Text ── */
.legal-hero-inner .team-hero-title {
  background: linear-gradient(135deg, var(--primary), var(--accent), var(--primary));
  background-size: 200% 200%;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  animation: gradientShift 4s ease infinite;
}

@keyframes gradientShift {
  0%, 100% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
}

/* ── Team Profile Layout ── */
.team-profile {
  max-width: 720px;
  margin: 0 auto;
  text-align: center;
}

/* ── Staggered Profile Entrance ── */
.team-profile[data-reveal-left] {
  opacity: 0;
  transform: translateX(-60px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}
.team-profile[data-reveal-left].visible {
  opacity: 1;
  transform: translateX(0);
}
.team-profile[data-reveal-right] {
  opacity: 0;
  transform: translateX(60px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}
.team-profile[data-reveal-right].visible {
  opacity: 1;
  transform: translateX(0);
}

/* ── Animated Photo Ring ── */
.team-photo-wrap {
  position: relative;
  width: 200px;
  height: 200px;
  margin: 0 auto 28px;
  border-radius: 50%;
  padding: 5px;
  background: conic-gradient(var(--primary), var(--accent), var(--primary));
  animation: spinBorder 4s linear infinite;
  box-shadow: 0 8px 32px rgba(var(--primary-rgb), 0.18);
}

@keyframes spinBorder {
  to { transform: rotate(360deg); }
}

.team-photo-wrap:hover {
  animation-play-state: paused;
}

.team-photo-inner {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  overflow: hidden;
  background: var(--bg);
}

.team-photo {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.4s ease;
}

.team-photo-wrap:hover .team-photo {
  transform: scale(1.08);
}

/* ── Team Info ── */
.team-info {
  margin-bottom: 12px;
}

.team-name {
  font-size: 1.8rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  margin-bottom: 4px;
}

.team-role {
  font-size: 1rem;
  font-weight: 600;
  color: var(--primary);
  margin-bottom: 8px;
}

.team-tagline {
  font-size: 0.95rem;
  color: var(--muted-fg);
  font-style: italic;
}

/* ── Fun Facts Chips ── */
.team-facts {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
  margin-bottom: 32px;
}

.team-fact {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 6px 14px;
  border-radius: 100px;
  font-size: 0.78rem;
  font-weight: 600;
  background: var(--muted);
  color: var(--foreground);
  border: 1px solid var(--border);
  transition: transform var(--transition), box-shadow var(--transition);
}

.team-fact:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.team-fact-emoji {
  font-size: 0.9rem;
}

/* ── Bio with Read More ── */
.team-bio {
  text-align: left;
  margin-bottom: 40px;
}

.team-bio p {
  font-size: 0.95rem;
  line-height: 1.75;
  color: var(--foreground);
  margin-bottom: 16px;
}

.team-bio-extra {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.6s ease;
}

.team-bio-extra.expanded {
  max-height: 600px;
}

.team-bio-toggle {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 20px;
  border: 1px solid var(--border);
  border-radius: 100px;
  background: transparent;
  color: var(--primary);
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  transition: background var(--transition), transform var(--transition);
  margin-top: 4px;
}

.team-bio-toggle:hover {
  background: rgba(var(--primary-rgb), 0.08);
  transform: translateY(-1px);
}

.team-bio-toggle svg {
  transition: transform var(--transition);
}

.team-bio-toggle.active svg {
  transform: rotate(180deg);
}

/* ── Link Cards Grid ── */
.team-links {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
  text-align: left;
}

.team-link-card {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 18px 20px;
  border-radius: var(--radius);
  text-decoration: none;
  color: inherit;
  position: relative;
  overflow: hidden;
  transition: transform var(--transition), box-shadow var(--transition), border-color var(--transition);
}

.team-link-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.1);
}

/* Per-card accent colors */
.team-link-card[data-accent="green"] { border-left: 3px solid var(--primary); }
.team-link-card[data-accent="pink"] { border-left: 3px solid #e1306c; }
.team-link-card[data-accent="blue"] { border-left: 3px solid #0a66c2; }
.team-link-card[data-accent="gold"] { border-left: 3px solid var(--accent); }

.team-link-card[data-accent="green"] .team-link-icon { background: rgba(var(--primary-rgb), 0.1); color: var(--primary); }
.team-link-card[data-accent="pink"] .team-link-icon { background: rgba(225, 48, 108, 0.1); color: #e1306c; }
.team-link-card[data-accent="blue"] .team-link-icon { background: rgba(10, 102, 194, 0.1); color: #0a66c2; }
.team-link-card[data-accent="gold"] .team-link-icon { background: rgba(212, 168, 75, 0.1); color: var(--accent); }

/* Hover icon pulse */
.team-link-card:hover .team-link-icon {
  animation: iconPulse 0.6s ease;
}

@keyframes iconPulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.15); }
}

/* Hover arrow indicator */
.team-link-arrow {
  position: absolute;
  right: 16px;
  opacity: 0;
  transform: translateX(-8px);
  transition: opacity var(--transition), transform var(--transition);
  color: var(--muted-fg);
}

.team-link-card:hover .team-link-arrow {
  opacity: 1;
  transform: translateX(0);
}

.team-link-icon {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: rgba(var(--primary-rgb), 0.1);
  color: var(--primary);
  transition: transform 0.3s ease;
}

.team-link-text {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.team-link-card strong {
  display: block;
  font-size: 0.88rem;
  font-weight: 700;
  margin-bottom: 2px;
}

.team-link-card span {
  font-size: 0.78rem;
  color: var(--muted-fg);
}

/* ── Divider ── */
.team-divider {
  width: 80px;
  height: 3px;
  background: linear-gradient(90deg, var(--primary), var(--accent));
  border-radius: 3px;
  margin: 0 auto 60px;
}

.team-photo-placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, rgba(var(--primary-rgb), 0.12), rgba(var(--primary-rgb), 0.04));
  color: var(--primary);
}

/* ── Wobble Animation ── */
@keyframes wobble {
  0%, 100% { transform: rotate(0deg); }
  25% { transform: rotate(-5deg); }
  75% { transform: rotate(5deg); }
}
.hero-badge:hover { animation: wobble 0.5s ease; }
.stat-pill:hover .stat-icon { animation: wobble 0.4s ease; display: inline-block; }
.pipeline-stage:hover .stage-icon { animation: wobble 0.5s ease; }

/* ── Section Dividers ── */
.section-divider {
  position: relative; margin-top: -1px; line-height: 0; overflow: hidden;
}
.section-divider svg {
  width: 100%; height: clamp(40px, 5vw, 80px); display: block;
}

/* ── Touch Targets ── */
@media (pointer: coarse) {
  .feat-tab { min-height: 44px; min-width: 44px; }
  .theme-toggle { width: 44px; height: 44px; }
  .nav-cta { min-height: 44px; padding: 10px 20px; }
  .water-glass { min-width: 44px; min-height: 44px; }
  .settings-toggle-row { min-height: 48px; }
  .ai-cat-link { min-height: 44px; padding: 10px 16px; }
  .demo-btn { min-height: 44px; padding: 10px 18px; }
}

/* ══════════════════════════════════════════════════
   RESPONSIVE — 1024px
   ══════════════════════════════════════════════════ */
@media (max-width: 1024px) {
  .hero-grid { grid-template-columns: 1fr; text-align: center; }
  .hero-content { order: 1; }
  .hero-phones { order: 2; height: 400px; margin-top: 32px; }
  .hero-desc { margin-left: auto; margin-right: auto; }
  .hero-actions { justify-content: center; }
  .hero-stats { justify-content: center; }
  .hero h1 br { display: none; }
  .ai-grid { grid-template-columns: 1fr; gap: 40px; }
  .ai-phone-col { order: 2; }
  .ai-details-col { order: 1; text-align: center; }
  .ai-personalities { max-width: 400px; margin-left: auto; margin-right: auto; margin-bottom: 24px; }
  .ai-chat-demo { max-width: 500px; margin-left: auto; margin-right: auto; margin-bottom: 24px; }
  .ai-meta { justify-content: center; }
  .ai-cap-grid { grid-template-columns: repeat(2, 1fr); }
  .trust-badges { grid-template-columns: repeat(2, 1fr); }
  .trust-badge { min-height: 140px; }
  .pipeline-stages { grid-template-columns: repeat(2, 1fr); gap: 20px; }
  .pipeline-track { display: none; }
  .footer-grid { grid-template-columns: repeat(2, 1fr); }
  /* Team — 1024px: side-by-side layout */
  .team-profile {
    max-width: 900px;
    display: grid;
    grid-template-columns: 220px 1fr;
    grid-template-rows: auto auto auto;
    gap: 0 40px;
    text-align: left;
  }
  .team-photo-wrap {
    grid-row: 1 / 3;
    grid-column: 1;
    margin: 0;
    align-self: start;
  }
  .team-info { grid-column: 2; margin-bottom: 16px; }
  .team-facts { justify-content: flex-start; grid-column: 2; }
  .team-bio { grid-column: 1 / -1; }
  .team-links { grid-column: 1 / -1; }
  /* Legal — 1024px */
  .legal-highlights { grid-template-columns: repeat(2, 1fr); }
  .legal-layout { grid-template-columns: 200px 1fr; gap: 40px; }
}

/* ══════════════════════════════════════════════════
   RESPONSIVE — 1024px (nav collapse)
   ══════════════════════════════════════════════════ */
@media (max-width: 1024px) {
  .nav-links { display: none; }
  .nav-cta { display: none; }
  .hamburger { display: flex; }
}

/* ══════════════════════════════════════════════════
   RESPONSIVE — 768px
   ══════════════════════════════════════════════════ */
@media (max-width: 768px) {
  :root { --nav-h: 60px; }
  .hero-phones { height: 320px; }
  .phone-back { width: 160px; }
  .phone-mid { width: 180px; }
  .phone-front { width: 160px; }
  .phone-large { width: 240px; }
  .how-steps { flex-direction: column; align-items: center; gap: 8px; }
  .how-connector { width: 24px; height: 40px; padding-top: 0; transform: rotate(90deg); }
  .phone-small { width: 160px; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .pipeline-stages { grid-template-columns: repeat(2, 1fr); gap: 16px; }
  .pipeline-track { display: none; }
  .trust-badges { grid-template-columns: 1fr 1fr; }
  .trust-badge { min-height: 130px; }
  .footer-grid { grid-template-columns: 1fr; gap: 28px; }
  .ai-personalities { grid-template-columns: 1fr; }
  .ai-cap-grid { grid-template-columns: 1fr; }
  .contact-grid { grid-template-columns: 1fr; }
  /* Team — 768px */
  .team-profile {
    display: block;
    max-width: 720px;
    text-align: center;
  }
  .team-photo-wrap { width: 160px; height: 160px; margin: 0 auto 28px; }
  .team-facts { justify-content: center; }
  .team-links { grid-template-columns: 1fr; }
  .team-name { font-size: 1.5rem; }
  .team-profile[data-reveal-left],
  .team-profile[data-reveal-right] { transform: translateY(30px); }
  .team-profile[data-reveal-left].visible,
  .team-profile[data-reveal-right].visible { transform: translateY(0); }
  /* Legal — 768px */
  .legal-layout { grid-template-columns: 1fr; gap: 0; }
  .legal-toc {
    position: relative; top: auto;
    max-height: none; overflow: visible;
    margin-bottom: 32px; padding: 16px 0;
    border-bottom: 1px solid var(--border);
  }
  .legal-toc nav {
    flex-direction: row; flex-wrap: wrap; gap: 6px;
  }
  .legal-toc-title { display: none; }
  .legal-toc-link {
    padding: 6px 14px; border-left: none;
    border-radius: 100px; background: var(--muted); font-size: 0.78rem;
  }
  .legal-toc-link.active {
    background: rgba(var(--primary-rgb), 0.12); border-left: none;
  }
  .legal-highlights { grid-template-columns: repeat(2, 1fr); }
  .legal-cards { grid-template-columns: 1fr; }
  .legal-rights-grid { grid-template-columns: 1fr; }
  .legal-contact-grid { grid-template-columns: 1fr 1fr; }
  /* Features — 768px */
  .feat-panel-inner { grid-template-columns: 1fr; gap: 32px; }
  .feat-phone { order: -1; }
  .phone-frame { width: 240px; }
  .feat-tabs { gap: 4px; }
  .tab-indicator { display: none; }
  .feat-tab { background: var(--muted); }
  .feat-tab.active { background: var(--tab-color); }
}

/* ══════════════════════════════════════════════════
   RESPONSIVE — 480px
   ══════════════════════════════════════════════════ */
@media (max-width: 480px) {
  .hero h1 { font-size: 2rem; }
  .hero-desc { font-size: 1rem; }
  .hero-actions { flex-direction: column; align-items: center; }
  .hero-stats { gap: 8px; }
  .stat-pill { padding: 6px 12px; font-size: 0.75rem; }
  .hero-phones { height: 260px; }
  .phone-back { width: 130px; }
  .phone-mid { width: 150px; }
  .phone-front { width: 130px; }
  .phone-large { width: 200px; }
  .section-head h2 { font-size: 1.5rem; }
  .stats-grid { gap: 12px; }
  .stat-number { font-size: 2.2rem; }
  .compare-table { font-size: 0.78rem; }
  .compare-table th, .compare-table td { padding: 8px 10px; }
  .download-content h2 { font-size: 1.5rem; }
  .pipeline-stages { grid-template-columns: 1fr 1fr; gap: 12px; }
  .stage-icon { font-size: 1.6rem; }
  .pipeline-stage strong { font-size: 0.78rem; }
  .trust-badges { grid-template-columns: 1fr; }
  .trust-badge { min-height: 120px; }
  /* Features — 480px */
  .feat-tab { padding: 8px 14px; font-size: 0.78rem; }
  .feat-tabs { gap: 4px; overflow-x: auto; flex-wrap: nowrap; justify-content: flex-start; padding-bottom: 8px; }
  .phone-frame { width: 220px; }
  .feat-info h3 { font-size: 1.3rem; }
  .feat-list li strong { font-size: 0.85rem; }
  .feat-list li p { font-size: 0.8rem; }
  .settings-toggle-row { padding: 8px 10px; }
  .contact-card { padding: 28px 20px; }
  .contact-reason { padding: 16px 18px; gap: 12px; }
  .contact-email-btn { padding: 12px 24px; font-size: 0.9rem; }
  /* Team — 480px */
  .team-photo-wrap { width: 140px; height: 140px; }
  .team-name { font-size: 1.35rem; }
  .team-bio p { font-size: 0.9rem; }
  .team-facts { flex-wrap: nowrap; overflow-x: auto; justify-content: flex-start; padding-bottom: 8px; -webkit-overflow-scrolling: touch; }
  .team-fact { white-space: nowrap; flex-shrink: 0; }
  .team-link-card { padding: 16px 18px; }
  /* Legal — 480px */
  .legal-hero-inner h1 { font-size: 1.8rem; }
  .legal-highlights { grid-template-columns: 1fr 1fr; gap: 10px; }
  .legal-highlight { padding: 16px 12px; }
  .legal-highlight-icon { font-size: 1.4rem; }
  .legal-highlight strong { font-size: 0.82rem; }
  .legal-highlight > span { font-size: 0.72rem; }
  .legal-block h2 { font-size: 1.25rem; }
  .legal-flow-step { padding: 14px 16px; }
  .legal-contact-grid { grid-template-columns: 1fr; }
  .legal-table { font-size: 0.82rem; }
  .legal-table th, .legal-table td { padding: 10px 12px; }
  .legal-back-to-top { bottom: 20px; right: 20px; width: 40px; height: 40px; }
}

/* ══════════════════════════════════════════════════
   REDUCED MOTION
   ══════════════════════════════════════════════════ */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
  [data-reveal], [data-reveal="scale"], [data-reveal="slide-left"], [data-reveal="slide-right"],
  [data-reveal-stagger] > *, [data-reveal-left], [data-reveal-right] { opacity: 1; transform: none; }
  .split-animated .char { opacity: 1; transform: none; animation: none; }
  .hero::before, .hero::after { animation: none; }
  .hero-highlight { animation: none; }
  .hero-badge { transform: none; }
  .mobile-menu a { opacity: 1; transform: none; transition-delay: 0s !important; }
  .dash-anim { animation: none; }
  .tab-indicator { transition: none; }
  .scroll-progress { animation: none; box-shadow: none; }
  /* Round 2 additions */
  .phone-back, .phone-mid, .phone-front { animation: none; }
  .feat-list li { opacity: 1; transform: none; animation: none; }
  .feat-badge { animation: none; }
  .how-connector svg { animation: none; }
  .compare-wrap[data-reveal] .check.yes { transform: none; opacity: 1; animation: none; }
  .stat-number { animation: none; }
  .cursor-sparkle { display: none; }
}

/* ══════════════════════════════════════════════════
   LATEST UPDATES SNAPSHOT (Home Page)
   ══════════════════════════════════════════════════ */
.updates-platform-status {
  display: flex;
  gap: 16px;
  justify-content: center;
  margin-bottom: 32px;
  flex-wrap: wrap;
}
.updates-platform-card {
  display: flex;
  align-items: center;
  gap: 12px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 14px 24px;
  text-decoration: none;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.updates-platform-card--ios {
  cursor: pointer;
  border-color: var(--primary);
}
.updates-platform-card--ios:hover {
  box-shadow: 0 2px 12px rgba(93,164,139,0.18);
  border-color: var(--primary);
}
.updates-platform-card--android {
  opacity: 0.5;
}
.updates-platform-icon {
  color: var(--primary);
  display: flex;
  flex-shrink: 0;
}
.updates-platform-card--android .updates-platform-icon {
  color: var(--muted);
}
.updates-platform-arrow {
  color: var(--primary);
  flex-shrink: 0;
  margin-left: 4px;
}
.updates-platform-info {
  display: flex;
  flex-direction: column;
  gap: 3px;
}
.updates-platform-name {
  font-weight: 700;
  font-size: 0.9rem;
  color: var(--heading);
}
.updates-platform-versions {
  font-size: 0.82rem;
  color: var(--text);
}
.updates-platform-versions strong {
  color: var(--heading);
  font-weight: 700;
}
.updates-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin-bottom: 32px;
}
.update-card {
  background: var(--card);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  padding: 24px;
  transition: border-color var(--transition), transform var(--transition);
}
.update-card:hover {
  border-color: var(--primary);
  transform: translateY(-3px);
}
.update-card--highlight {
  border-left: 3px solid var(--primary);
}
.update-card--submitted {
  background: linear-gradient(135deg, var(--card) 0%, rgba(212,168,75,0.12) 50%, rgba(58,183,149,0.08) 100%);
  border: 1px solid rgba(212,168,75,0.35);
  border-left: 4px solid var(--accent, #d4a84b);
  box-shadow: 0 4px 24px rgba(212,168,75,0.1);
  position: relative;
}
.update-card--submitted:hover {
  border-color: var(--accent, #d4a84b);
  box-shadow: 0 8px 32px rgba(212,168,75,0.18);
}
[data-theme="dark"] .update-card--submitted {
  background: linear-gradient(135deg, var(--card) 0%, rgba(212,168,75,0.08) 50%, rgba(58,183,149,0.05) 100%);
  border-color: rgba(212,168,75,0.3);
  border-left-color: var(--accent, #d4a84b);
}
.update-card-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--accent, #d4a84b);
  color: #fff;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  padding: 5px 12px;
  border-radius: 20px;
  margin-bottom: 8px;
  text-transform: uppercase;
}
.update-card-badge svg {
  flex-shrink: 0;
}
.update-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
}
.update-card-date {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--muted-fg);
}
.update-card-version {
  padding: 2px 10px;
  border-radius: 100px;
  background: rgba(var(--primary-rgb), 0.12);
  color: var(--primary);
  font-size: 0.72rem;
  font-weight: 700;
}
.update-card h3 {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--foreground);
  margin: 0 0 8px;
  line-height: 1.35;
}
.update-card p {
  font-size: 0.85rem;
  line-height: 1.6;
  color: var(--muted-fg);
  margin: 0 0 14px;
}
.update-card p code {
  font-size: 0.78rem;
  padding: 1px 5px;
  border-radius: 4px;
  background: var(--muted);
  color: var(--foreground);
}
.update-card-tags {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.update-card-tags span {
  display: inline-block;
  padding: 2px 10px;
  border-radius: 100px;
  background: var(--muted);
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--muted-fg);
}
.update-card-tags .progress-tag {
  font-size: 0.7rem;
  font-weight: 700;
}
.updates-cta {
  text-align: center;
}
.updates-view-all {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 10px 24px;
  border-radius: 100px;
  background: rgba(var(--primary-rgb), 0.08);
  color: var(--primary);
  font-size: 0.9rem;
  font-weight: 700;
  transition: all var(--transition);
}
.updates-view-all:hover {
  background: rgba(var(--primary-rgb), 0.16);
  transform: translateX(3px);
}
@media (max-width: 768px) {
  .updates-grid {
    grid-template-columns: 1fr;
  }
}

/* ══════════════════════════════════════════════════
   PROGRESS PAGE
   ══════════════════════════════════════════════════ */

/* ── Platform Badge ── */
.progress-platform-badge {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-top: 20px;
  flex-wrap: wrap;
}
.progress-platform-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 16px;
  border-radius: 100px;
  font-size: 0.82rem;
  font-weight: 700;
}
.progress-platform-tag--active {
  background: rgba(var(--primary-rgb), 0.12);
  color: var(--primary);
}
.progress-platform-tag--soon {
  background: var(--muted);
  color: var(--muted-fg);
}
.progress-platform-pill {
  display: inline-block;
  padding: 2px 10px;
  border-radius: 100px;
  background: rgba(var(--primary-rgb), 0.12);
  color: var(--primary);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.03em;
}

/* ── Hero Stats ── */
.progress-stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-top: 32px;
}
.progress-stat-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 24px 16px;
  background: var(--card);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
}
.progress-stat-value {
  font-size: 1.6rem;
  font-weight: 800;
  color: var(--primary);
  line-height: 1.2;
}
.progress-stat-label {
  font-size: 0.82rem;
  color: var(--muted-fg);
  font-weight: 500;
  margin-top: 4px;
}

/* ── Timeline Section ── */
.progress-timeline-section {
  padding-bottom: 0;
}

/* ── Date Groups ── */
.progress-date-group {
  margin-bottom: 48px;
}
.progress-date-group:last-child {
  margin-bottom: 0;
}
.progress-date-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 24px;
  padding-bottom: 12px;
  border-bottom: 2px solid var(--border);
}
.progress-date-header h2 {
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--foreground);
  margin: 0;
}
.progress-date-badge {
  display: inline-block;
  padding: 3px 12px;
  border-radius: 100px;
  background: var(--primary);
  color: #fff;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

/* ── Entry Cards ── */
.progress-entry {
  display: grid;
  grid-template-columns: 100px 1fr;
  gap: 20px;
  margin-bottom: 16px;
  position: relative;
}
.progress-entry::before {
  content: '';
  position: absolute;
  left: 100px;
  top: 0;
  bottom: -16px;
  width: 2px;
  background: var(--border);
}
.progress-entry:last-child::before {
  display: none;
}
.progress-entry-time {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--muted-fg);
  padding-top: 18px;
  text-align: right;
}
.progress-entry-body {
  background: var(--card);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  padding: 20px 24px;
  position: relative;
  transition: border-color var(--transition);
}
.progress-entry-body:hover {
  border-color: var(--primary);
}
.progress-entry--major .progress-entry-body {
  border-left: 3px solid var(--primary);
}
.progress-entry--milestone .progress-entry-body {
  border-left: 4px solid var(--accent);
  background: linear-gradient(135deg, var(--card) 0%, rgba(212,168,75,0.1) 100%);
  box-shadow: 0 4px 24px rgba(212,168,75,0.12);
}
.progress-milestone-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--accent);
  color: #fff;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  padding: 6px 14px;
  border-radius: 20px;
  margin-bottom: 12px;
  text-transform: uppercase;
}
.progress-milestone-badge svg {
  flex-shrink: 0;
}

/* ── Entry Header ── */
.progress-entry-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 8px;
}
.progress-entry-header h3 {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--foreground);
  margin: 0;
  line-height: 1.35;
}
.progress-entry-version {
  flex-shrink: 0;
  padding: 2px 10px;
  border-radius: 100px;
  background: rgba(var(--primary-rgb), 0.12);
  color: var(--primary);
  font-size: 0.72rem;
  font-weight: 700;
  white-space: nowrap;
}
.progress-entry-tag {
  flex-shrink: 0;
  padding: 2px 10px;
  border-radius: 100px;
  font-size: 0.72rem;
  font-weight: 700;
  white-space: nowrap;
}
.progress-entry-tag--fix {
  background: rgba(239,68,68,0.1);
  color: var(--destructive);
}

/* ── Entry Scope ── */
.progress-entry-scope {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 10px;
}
.progress-entry-scope span {
  display: inline-block;
  padding: 2px 10px;
  border-radius: 100px;
  background: var(--muted);
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--muted-fg);
}

/* ── Entry Summary ── */
.progress-entry-summary {
  font-size: 0.9rem;
  line-height: 1.6;
  color: var(--muted-fg);
  margin: 0;
}
.progress-entry-summary code {
  font-size: 0.82rem;
  padding: 1px 5px;
  border-radius: 4px;
  background: var(--muted);
  color: var(--foreground);
}

/* ── Detail Toggle ── */
.progress-detail-toggle {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 12px;
  padding: 6px 14px;
  border: 1px solid var(--border);
  border-radius: 100px;
  background: transparent;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--primary);
  cursor: pointer;
  transition: all var(--transition);
}
.progress-detail-toggle:hover {
  background: rgba(var(--primary-rgb), 0.08);
  border-color: var(--primary);
}
.progress-detail-toggle.active svg {
  transform: rotate(180deg);
}
.progress-detail-toggle svg {
  transition: transform var(--transition);
}

/* ── Detail Content ── */
.progress-detail-content {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s ease, margin 0.3s ease, padding 0.3s ease;
}
.progress-detail-content.expanded {
  max-height: 3000px;
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
}

/* ── Detail Tracks ── */
.progress-detail-track {
  margin-bottom: 16px;
}
.progress-detail-track:last-child {
  margin-bottom: 0;
}
.progress-detail-track h4 {
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--foreground);
  margin: 0 0 8px;
}
.progress-detail-track ul {
  list-style: none;
  padding: 0;
  margin: 0;
}
.progress-detail-track li {
  position: relative;
  padding-left: 16px;
  margin-bottom: 6px;
  font-size: 0.84rem;
  line-height: 1.55;
  color: var(--muted-fg);
}
.progress-detail-track li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 8px;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--primary);
}
.progress-detail-track li strong {
  color: var(--foreground);
  font-weight: 600;
}
.progress-detail-track li code {
  font-size: 0.78rem;
  padding: 1px 5px;
  border-radius: 4px;
  background: var(--muted);
  color: var(--foreground);
}

/* ── Files Changed ── */
.progress-files-changed {
  margin-top: 16px;
  padding-top: 12px;
  border-top: 1px dashed var(--border);
}
.progress-files-changed h4 {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--muted-fg);
  margin: 0 0 8px;
}
.progress-file-list {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.progress-file-list code {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 6px;
  background: var(--muted);
  font-size: 0.72rem;
  color: var(--muted-fg);
  white-space: nowrap;
}

/* ── Category Tags ── */
.progress-entry-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 8px;
  margin-bottom: 4px;
}
.progress-tag {
  display: inline-block;
  padding: 2px 10px;
  border-radius: 100px;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  white-space: nowrap;
}
.progress-tag--bugfix {
  background: rgba(239,68,68,0.12);
  color: #dc2626;
}
[data-theme="dark"] .progress-tag--bugfix {
  background: rgba(239,68,68,0.18);
  color: #f87171;
}
.progress-tag--feature {
  background: rgba(58,183,149,0.12);
  color: #0d9488;
}
[data-theme="dark"] .progress-tag--feature {
  background: rgba(58,183,149,0.18);
  color: #5eead4;
}
.progress-tag--improvement {
  background: rgba(34,197,94,0.12);
  color: #16a34a;
}
[data-theme="dark"] .progress-tag--improvement {
  background: rgba(34,197,94,0.18);
  color: #4ade80;
}
.progress-tag--release {
  background: rgba(212,168,75,0.15);
  color: #b8860b;
}
[data-theme="dark"] .progress-tag--release {
  background: rgba(212,168,75,0.2);
  color: #e4bc64;
}
.progress-tag--stability {
  background: rgba(139,92,246,0.12);
  color: #7c3aed;
}
[data-theme="dark"] .progress-tag--stability {
  background: rgba(139,92,246,0.18);
  color: #a78bfa;
}
.progress-tag--accessibility {
  background: rgba(245,158,11,0.12);
  color: #d97706;
}
[data-theme="dark"] .progress-tag--accessibility {
  background: rgba(245,158,11,0.18);
  color: #fbbf24;
}
.progress-tag--docs {
  background: var(--muted);
  color: var(--muted-fg);
}

/* ── Filter Toolbar ── */
.progress-filter-toolbar {
  position: sticky;
  top: var(--nav-h);
  z-index: 90;
  background: var(--bg);
  border-bottom: 1px solid var(--border);
  padding: 16px 0;
  transition: background-color var(--transition), border-color var(--transition);
}
.progress-filter-toolbar .container {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.progress-filter-row {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}
.progress-filter-search {
  flex: 1;
  min-width: 180px;
  max-width: 320px;
  padding: 8px 14px 8px 36px;
  border: 1px solid var(--border);
  border-radius: 100px;
  background: var(--card);
  color: var(--foreground);
  font-size: 0.85rem;
  font-family: inherit;
  outline: none;
  transition: border-color var(--transition), box-shadow var(--transition);
}
.progress-filter-search:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(var(--primary-rgb), 0.15);
}
.progress-filter-search-wrap {
  position: relative;
  flex: 1;
  min-width: 180px;
  max-width: 320px;
}
.progress-filter-search-wrap svg {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--muted-fg);
  pointer-events: none;
}
.progress-filter-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  flex: 1;
}
.progress-filter-pill {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 6px 14px;
  border: 1px solid var(--border);
  border-radius: 100px;
  background: transparent;
  color: var(--muted-fg);
  font-size: 0.78rem;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition);
  white-space: nowrap;
}
.progress-filter-pill:hover {
  border-color: var(--primary);
  color: var(--primary);
}
.progress-filter-pill.active {
  background: var(--primary);
  border-color: var(--primary);
  color: #fff;
}
.progress-filter-sort {
  padding: 8px 14px;
  border: 1px solid var(--border);
  border-radius: 100px;
  background: var(--card);
  color: var(--foreground);
  font-size: 0.8rem;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  outline: none;
  transition: border-color var(--transition);
}
.progress-filter-sort:focus {
  border-color: var(--primary);
}
.progress-filter-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.progress-filter-count {
  font-size: 0.8rem;
  color: var(--muted-fg);
  font-weight: 500;
}
.progress-filter-clear {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--primary);
  cursor: pointer;
  background: none;
  border: none;
  padding: 4px 8px;
  border-radius: 6px;
  transition: background var(--transition);
  display: none;
}
.progress-filter-clear.visible {
  display: inline-block;
}
.progress-filter-clear:hover {
  background: rgba(var(--primary-rgb), 0.08);
}

/* ── No Results ── */
.progress-no-results {
  display: none;
  text-align: center;
  padding: 48px 24px;
  color: var(--muted-fg);
}
.progress-no-results.visible {
  display: block;
}
.progress-no-results svg {
  margin-bottom: 12px;
  opacity: 0.4;
}
.progress-no-results p {
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 4px;
}
.progress-no-results small {
  font-size: 0.85rem;
  opacity: 0.7;
}

/* Hide entries/groups when filtering */
.progress-entry.filter-hidden {
  display: none;
}
.progress-date-group.filter-hidden {
  display: none;
}

@media (max-width: 768px) {
  .progress-filter-row {
    flex-direction: column;
    align-items: stretch;
  }
  .progress-filter-search-wrap {
    max-width: 100%;
  }
  .progress-filter-pills {
    overflow-x: auto;
    flex-wrap: nowrap;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    padding-bottom: 4px;
  }
  .progress-filter-pills::-webkit-scrollbar {
    display: none;
  }
  .progress-filter-sort {
    align-self: flex-start;
  }
}

/* ── Codebase Stats Section ── */
.progress-codebase-section {
  padding-top: 48px;
}
.progress-codebase-header {
  text-align: center;
  margin-bottom: 32px;
}
.progress-codebase-header h2 {
  font-size: clamp(1.6rem, 3.5vw, 2.2rem);
  font-weight: 800;
  margin-bottom: 8px;
}
.progress-codebase-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}
.progress-codebase-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 24px 12px;
  background: var(--card);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  transition: border-color var(--transition), transform var(--transition);
}
.progress-codebase-card:hover {
  border-color: var(--primary);
  transform: translateY(-2px);
}
.progress-codebase-icon {
  font-size: 1.5rem;
  margin-bottom: 6px;
}
.progress-codebase-value {
  font-size: 1.4rem;
  font-weight: 800;
  color: var(--primary);
  line-height: 1.2;
}
.progress-codebase-label {
  font-size: 0.78rem;
  color: var(--muted-fg);
  font-weight: 500;
  margin-top: 2px;
}

/* ── Progress Page Responsive ── */
@media (max-width: 768px) {
  .progress-stats {
    grid-template-columns: repeat(2, 1fr);
  }
  .progress-entry {
    grid-template-columns: 1fr;
    gap: 0;
  }
  .progress-entry::before {
    display: none;
  }
  .progress-entry-time {
    text-align: left;
    padding: 0;
    margin-bottom: 4px;
  }
  .progress-entry-body {
    padding: 16px;
  }
  .progress-entry-header {
    flex-direction: column;
    gap: 6px;
  }
  .progress-codebase-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}
@media (max-width: 480px) {
  .progress-stats {
    grid-template-columns: 1fr 1fr;
    gap: 10px;
  }
  .progress-stat-card {
    padding: 16px 12px;
  }
  .progress-stat-value {
    font-size: 1.3rem;
  }
  .progress-codebase-grid {
    grid-template-columns: 1fr 1fr;
    gap: 10px;
  }
}
