/* ╔══════════════════════════════════════════════════════════╗
   ║  EnamDoc Landing Page — Professional CSS v2             ║
   ║  Dark/Light theme · Animations · Cool Effects           ║
   ╚══════════════════════════════════════════════════════════╝ */

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

:root {
  --blue: #2563EB;
  --blue-dark: #1d4ed8;
  --blue-light: #dbeafe;
  --green: #10b981;
  --green-light: #d1fae5;
  --purple: #7c3aed;
  --purple-light: #ede9fe;
  --orange: #f59e0b;
  --orange-light: #fef3c7;
  --pink: #ec4899;
  --pink-light: #fce7f3;
  --teal: #14b8a6;
  --teal-light: #ccfbf1;
  --indigo: #6366f1;
  --indigo-light: #e0e7ff;
  --red: #ef4444;
  --red-light: #fee2e2;
  --radius: 16px;
  --radius-sm: 10px;
  --radius-lg: 24px;
  --shadow-sm: 0 1px 3px rgba(0,0,0,.06), 0 1px 2px rgba(0,0,0,.04);
  --shadow: 0 4px 6px -1px rgba(0,0,0,.07), 0 2px 4px -2px rgba(0,0,0,.05);
  --shadow-lg: 0 20px 40px -12px rgba(0,0,0,.12);
  --shadow-xl: 0 25px 50px -12px rgba(0,0,0,.15);
  --transition: 0.3s cubic-bezier(.4,0,.2,1);
}

/* ─── Light Theme (default) ──────────────────────────────── */
[data-theme="light"] {
  --bg-primary: #ffffff;
  --bg-secondary: #f8fafc;
  --bg-card: #ffffff;
  --bg-card-hover: #f8fafc;
  --bg-nav: rgba(255,255,255,0.8);
  --bg-nav-mobile: #ffffff;
  --text-primary: #0f172a;
  --text-secondary: #334155;
  --text-muted: #64748b;
  --text-faint: #94a3b8;
  --border-color: #e2e8f0;
  --border-subtle: #f1f5f9;
  --glow-color: rgba(37,99,235,0.15);
  --card-border: #e2e8f0;
  --card-bg: #ffffff;
  --section-alt: #f8fafc;
  --footer-border: #f1f5f9;
  --gradient-mesh-1: rgba(37,99,235,0.08);
  --gradient-mesh-2: rgba(124,58,237,0.06);
  --gradient-mesh-3: rgba(236,72,153,0.05);
}

/* ─── Dark Theme ─────────────────────────────────────────── */
[data-theme="dark"] {
  --bg-primary: #0a0a0f;
  --bg-secondary: #111118;
  --bg-card: #16161f;
  --bg-card-hover: #1e1e2a;
  --bg-nav: rgba(10,10,15,0.85);
  --bg-nav-mobile: #111118;
  --text-primary: #f1f5f9;
  --text-secondary: #cbd5e1;
  --text-muted: #94a3b8;
  --text-faint: #64748b;
  --border-color: #1e293b;
  --border-subtle: #1a1a25;
  --glow-color: rgba(37,99,235,0.25);
  --card-border: #1e293b;
  --card-bg: #16161f;
  --section-alt: #111118;
  --footer-border: #1a1a25;
  --gradient-mesh-1: rgba(37,99,235,0.12);
  --gradient-mesh-2: rgba(124,58,237,0.10);
  --gradient-mesh-3: rgba(236,72,153,0.08);

  --blue-light: rgba(37,99,235,0.15);
  --green-light: rgba(16,185,129,0.15);
  --purple-light: rgba(124,58,237,0.15);
  --orange-light: rgba(245,158,11,0.15);
  --pink-light: rgba(236,72,153,0.15);
  --teal-light: rgba(20,184,166,0.15);
  --indigo-light: rgba(99,102,241,0.15);
  --red-light: rgba(239,68,68,0.15);
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  color: var(--text-primary);
  background: var(--bg-primary);
  line-height: 1.6;
  overflow-x: hidden;
  transition: background 0.5s ease, color 0.5s ease;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

a { text-decoration: none; color: inherit; }
img { max-width: 100%; display: block; }

/* ─── Page Loader ────────────────────────────────────────── */
.page-loader {
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: var(--bg-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity 0.6s ease, visibility 0.6s ease;
}
.page-loader.hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}
.loader-content {
  text-align: center;
}
.loader-tooth {
  font-size: 3.5rem;
  animation: loader-bounce 1s ease-in-out infinite;
}
@keyframes loader-bounce {
  0%, 100% { transform: translateY(0) scale(1); }
  50% { transform: translateY(-20px) scale(1.1); }
}
.loader-bar {
  width: 120px;
  height: 4px;
  background: var(--border-color);
  border-radius: 4px;
  margin-top: 20px;
  overflow: hidden;
}
.loader-progress {
  width: 0%;
  height: 100%;
  background: linear-gradient(90deg, var(--blue), var(--purple));
  border-radius: 4px;
  animation: loader-fill 1.5s ease forwards;
}
@keyframes loader-fill {
  0% { width: 0%; }
  100% { width: 100%; }
}

/* ─── Scroll Progress Bar ────────────────────────────────── */
.scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 3px;
  width: 0%;
  background: linear-gradient(90deg, var(--blue), var(--purple), var(--pink));
  z-index: 1001;
  transition: width 0.05s linear;
  border-radius: 0 2px 2px 0;
}

/* ─── Cursor Glow ────────────────────────────────────────── */
.cursor-glow {
  position: fixed;
  width: 600px;
  height: 600px;
  border-radius: 50%;
  background: radial-gradient(circle, var(--glow-color) 0%, transparent 70%);
  pointer-events: none;
  z-index: 0;
  transform: translate(-50%, -50%);
  opacity: 0;
  transition: opacity 0.3s ease;
}
.cursor-glow.active {
  opacity: 1;
}

/* ─── Scroll Reveal ─────────────────────────────────────── */
.reveal {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 0.8s cubic-bezier(.16,1,.3,1), transform 0.8s cubic-bezier(.16,1,.3,1);
}
.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}
.reveal-right {
  opacity: 0;
  transform: translateX(60px);
  transition: opacity 0.8s cubic-bezier(.16,1,.3,1) 0.15s, transform 0.8s cubic-bezier(.16,1,.3,1) 0.15s;
}
.reveal-right.visible {
  opacity: 1;
  transform: translateX(0);
}
.reveal-float {
  opacity: 0;
  transform: scale(0.8) translateY(20px);
  transition: opacity 0.6s ease 0.5s, transform 0.6s cubic-bezier(.34,1.56,.64,1) 0.5s;
}
.reveal-float.visible {
  opacity: 1;
  transform: scale(1) translateY(0);
}

/* ─── Text Reveal Animation ──────────────────────────────── */
.text-reveal-line {
  display: block;
  overflow: hidden;
}
.text-reveal-inner {
  display: inline-block;
  transform: translateY(110%);
  transition: transform 1s cubic-bezier(.16,1,.3,1);
}
.reveal.visible .text-reveal-inner {
  transform: translateY(0);
}
.reveal.visible .text-reveal-line:nth-child(2) .text-reveal-inner {
  transition-delay: 0.15s;
}

/* ─── Theme Toggle ──────────────────────────────────────── */
.theme-toggle {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  border: 1.5px solid var(--border-color);
  background: var(--bg-card);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition);
  position: relative;
  overflow: hidden;
}
.theme-toggle:hover {
  border-color: var(--blue);
  transform: rotate(180deg);
  box-shadow: 0 0 20px var(--glow-color);
}
.theme-icon {
  width: 20px;
  height: 20px;
  position: absolute;
  transition: all 0.5s cubic-bezier(.34,1.56,.64,1);
}
[data-theme="light"] .theme-icon.sun {
  opacity: 1;
  transform: rotate(0deg) scale(1);
}
[data-theme="light"] .theme-icon.moon {
  opacity: 0;
  transform: rotate(-90deg) scale(0.5);
}
[data-theme="dark"] .theme-icon.sun {
  opacity: 0;
  transform: rotate(90deg) scale(0.5);
}
[data-theme="dark"] .theme-icon.moon {
  opacity: 1;
  transform: rotate(0deg) scale(1);
  stroke: #f1f5f9;
}
.nav-right {
  display: flex;
  align-items: center;
  gap: 12px;
}

/* ─── Navbar ────────────────────────────────────────────── */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: var(--bg-nav);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid transparent;
  transition: all var(--transition);
}
.navbar.scrolled {
  border-bottom: 1px solid var(--border-color);
  box-shadow: 0 1px 3px rgba(0,0,0,.04);
}
[data-theme="dark"] .navbar.scrolled {
  box-shadow: 0 1px 12px rgba(0,0,0,.3);
}
.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
}
.nav-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  font-size: 1.3rem;
  color: var(--text-primary);
}
.logo-icon {
  font-size: 1.6rem;
  line-height: 1;
}
.nav-links {
  display: flex;
  align-items: center;
  gap: 32px;
}
.nav-links a {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text-muted);
  transition: color var(--transition);
  position: relative;
}
.nav-links a:hover { color: var(--text-primary); }
.nav-links a::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--blue);
  border-radius: 1px;
  transition: width var(--transition);
}
.nav-links a:hover::after { width: 100%; }
.nav-cta {
  background: var(--blue) !important;
  color: white !important;
  padding: 10px 22px !important;
  border-radius: 100px !important;
  font-weight: 600 !important;
  transition: all var(--transition) !important;
}
.nav-cta::after { display: none !important; }
.nav-cta:hover {
  background: var(--blue-dark) !important;
  transform: translateY(-1px);
  box-shadow: 0 4px 20px rgba(37, 99, 235, 0.45);
}
.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
}
.nav-toggle span {
  width: 22px;
  height: 2px;
  background: var(--text-primary);
  border-radius: 2px;
  transition: var(--transition);
}

/* ─── Hero ──────────────────────────────────────────────── */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding: 120px 0 80px;
  overflow: hidden;
  background: var(--bg-primary);
}

/* Particle Canvas */
.hero-particles {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
}

/* Animated Gradient Orbs */
.hero-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  pointer-events: none;
  z-index: 0;
  will-change: transform;
}
.hero-orb-1 {
  width: 500px;
  height: 500px;
  background: var(--gradient-mesh-1);
  top: -100px;
  right: -100px;
  animation: orb-float-1 12s ease-in-out infinite;
}
.hero-orb-2 {
  width: 400px;
  height: 400px;
  background: var(--gradient-mesh-2);
  bottom: -50px;
  left: -100px;
  animation: orb-float-2 15s ease-in-out infinite;
}
.hero-orb-3 {
  width: 300px;
  height: 300px;
  background: var(--gradient-mesh-3);
  top: 40%;
  left: 50%;
  animation: orb-float-3 10s ease-in-out infinite;
}
@keyframes orb-float-1 {
  0%, 100% { transform: translate(0, 0) scale(1); }
  33% { transform: translate(-40px, 30px) scale(1.1); }
  66% { transform: translate(20px, -20px) scale(0.95); }
}
@keyframes orb-float-2 {
  0%, 100% { transform: translate(0, 0) scale(1); }
  33% { transform: translate(30px, -25px) scale(1.05); }
  66% { transform: translate(-20px, 15px) scale(0.9); }
}
@keyframes orb-float-3 {
  0%, 100% { transform: translate(0, 0) scale(1); }
  50% { transform: translate(-30px, 20px) scale(1.15); }
}

.hero-bg-blur {
  position: absolute;
  top: -200px;
  right: -200px;
  width: 700px;
  height: 700px;
  background: radial-gradient(circle, var(--gradient-mesh-1) 0%, transparent 70%);
  border-radius: 50%;
  pointer-events: none;
}
.hero-grid-pattern {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(37,99,235,0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(37,99,235,0.03) 1px, transparent 1px);
  background-size: 60px 60px;
  mask-image: radial-gradient(ellipse at 60% 40%, black 30%, transparent 70%);
  -webkit-mask-image: radial-gradient(ellipse at 60% 40%, black 30%, transparent 70%);
  pointer-events: none;
}
[data-theme="dark"] .hero-grid-pattern {
  background-image:
    linear-gradient(rgba(37,99,235,0.06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(37,99,235,0.06) 1px, transparent 1px);
}
.hero-inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
  position: relative;
  z-index: 1;
}
.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--green-light);
  color: #047857;
  font-size: 0.82rem;
  font-weight: 600;
  padding: 8px 18px;
  border-radius: 100px;
  margin-bottom: 24px;
}
[data-theme="dark"] .hero-badge {
  color: var(--green);
}
.badge-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--green);
  animation: pulse-dot 2s infinite;
}
@keyframes pulse-dot {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.5; transform: scale(1.5); }
}
.hero-title {
  font-size: clamp(2.5rem, 5vw, 4rem);
  font-weight: 900;
  line-height: 1.1;
  letter-spacing: -0.03em;
  color: var(--text-primary);
  margin-bottom: 20px;
}
.gradient-text {
  background: linear-gradient(135deg, var(--blue) 0%, #7c3aed 50%, var(--pink) 100%);
  background-size: 200% 200%;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  animation: gradient-shift 4s ease infinite;
}
@keyframes gradient-shift {
  0%, 100% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
}
.hero-subtitle {
  font-size: 1.15rem;
  color: var(--text-muted);
  line-height: 1.7;
  max-width: 520px;
  margin-bottom: 36px;
}
.hero-actions {
  display: flex;
  gap: 16px;
  margin-bottom: 48px;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 600;
  border-radius: 100px;
  cursor: pointer;
  transition: all var(--transition);
  border: none;
  font-family: inherit;
  position: relative;
  overflow: hidden;
}
.btn::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(45deg, transparent, rgba(255,255,255,0.15), transparent);
  transform: translateX(-100%);
  transition: transform 0.6s ease;
}
.btn:hover::before {
  transform: translateX(100%);
}
.btn-lg {
  padding: 16px 32px;
  font-size: 1rem;
}
.btn-primary {
  background: var(--blue);
  color: white;
  box-shadow: 0 4px 14px rgba(37,99,235,0.3);
}
.btn-primary:hover {
  background: var(--blue-dark);
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(37,99,235,0.5);
}
.btn-ghost {
  background: transparent;
  color: var(--text-secondary);
  border: 1.5px solid var(--border-color);
}
.btn-ghost:hover {
  border-color: var(--blue);
  background: var(--blue-light);
  color: var(--blue);
}

/* Hero Stats */
.hero-stats {
  display: flex;
  align-items: center;
  gap: 24px;
}
.stat-item {
  text-align: center;
}
.stat-number {
  display: block;
  font-size: 2rem;
  font-weight: 800;
  color: var(--text-primary);
  line-height: 1;
}
.stat-suffix {
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--blue);
}
.stat-label {
  display: block;
  font-size: 0.8rem;
  color: var(--text-faint);
  font-weight: 500;
  margin-top: 4px;
}
.stat-divider {
  width: 1px;
  height: 40px;
  background: var(--border-color);
}

/* Hero Phone Mockup */
.hero-visual {
  position: relative;
  display: flex;
  justify-content: center;
}
.phone-mockup {
  position: relative;
  z-index: 2;
}
.phone-frame {
  width: 280px;
  height: 560px;
  background: var(--text-primary);
  border-radius: 40px;
  padding: 12px;
  box-shadow: var(--shadow-xl), 0 0 0 1px rgba(255,255,255,.1) inset, 0 0 80px rgba(37,99,235,0.1);
  position: relative;
  transition: box-shadow 0.5s ease;
}
[data-theme="dark"] .phone-frame {
  background: #1a1a2e;
  box-shadow: var(--shadow-xl), 0 0 0 1px rgba(255,255,255,.05) inset, 0 0 100px rgba(37,99,235,0.15);
}
.phone-notch {
  width: 120px;
  height: 28px;
  background: var(--text-primary);
  border-radius: 0 0 18px 18px;
  position: absolute;
  top: 12px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 3;
}
[data-theme="dark"] .phone-notch { background: #1a1a2e; }
.phone-screen {
  width: 100%;
  height: 100%;
  background: var(--bg-card);
  border-radius: 30px;
  padding: 40px 16px 16px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

/* Mock UI elements */
.mock-header {
  display: flex;
  align-items: center;
  gap: 10px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border-subtle);
}
.mock-avatar {
  width: 36px; height: 36px; border-radius: 50%;
  background: linear-gradient(135deg, var(--blue-light), var(--blue));
  animation: mock-shimmer 2s ease-in-out infinite;
}
@keyframes mock-shimmer {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.6; }
}
.mock-avatar.sm { width: 28px; height: 28px; }
.mock-avatar.blue { background: linear-gradient(135deg, var(--indigo-light), var(--indigo)); }
.mock-text-sm { width: 80px; height: 14px; border-radius: 8px; background: var(--border-color); }
.mock-card {
  background: var(--bg-secondary);
  border-radius: var(--radius-sm);
  padding: 12px;
}
.mock-card.small { padding: 10px; }
.mock-img {
  width: 100%;
  height: 120px;
  border-radius: 8px;
  background: linear-gradient(135deg, var(--blue-light) 0%, var(--purple-light) 100%);
  margin-bottom: 10px;
}
.mock-text { width: 100%; height: 10px; border-radius: 6px; background: var(--border-color); margin-bottom: 6px; }
.mock-text.short { width: 60%; }
.mock-actions { display: flex; gap: 8px; margin-top: 8px; }
.mock-action-btn { width: 28px; height: 28px; border-radius: 50%; background: var(--border-color); }
.mock-action-btn.heart { background: var(--red-light); }
.mock-row { display: flex; align-items: center; gap: 10px; }
.mock-lines { flex: 1; }

/* Floating cards */
.float-card {
  position: absolute;
  display: flex;
  align-items: center;
  gap: 12px;
  background: var(--bg-card);
  padding: 14px 18px;
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  z-index: 3;
  border: 1px solid var(--border-subtle);
  white-space: nowrap;
}
[data-theme="dark"] .float-card {
  box-shadow: 0 20px 40px rgba(0,0,0,.4);
}
.float-card-1 { top: 60px; left: -60px; animation: float-y 4s ease-in-out infinite; }
.float-card-2 { bottom: 140px; right: -40px; animation: float-y 4s ease-in-out infinite 1s; }
.float-card-3 { bottom: 40px; left: -40px; animation: float-y 4s ease-in-out infinite 2s; }

@keyframes float-y {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-10px); }
}

.float-icon {
  width: 40px;
  height: 40px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
}
.float-icon.green { background: var(--green-light); }
.float-icon.blue { background: var(--blue-light); }
.float-icon.purple { background: var(--purple-light); }
.float-title { font-weight: 700; font-size: 0.85rem; color: var(--text-primary); }
.float-desc { font-size: 0.75rem; color: var(--text-faint); }

/* Scroll hint */
.hero-scroll-hint {
  position: absolute;
  bottom: 32px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 2;
}
.scroll-mouse {
  width: 26px;
  height: 40px;
  border: 2px solid var(--text-faint);
  border-radius: 14px;
  display: flex;
  justify-content: center;
  padding-top: 8px;
}
.scroll-dot {
  width: 4px;
  height: 8px;
  background: var(--text-faint);
  border-radius: 4px;
  animation: scroll-hint 2s infinite;
}
@keyframes scroll-hint {
  0% { opacity: 1; transform: translateY(0); }
  100% { opacity: 0; transform: translateY(12px); }
}

/* ─── Trust Bar / Marquee ───────────────────────────────── */
.trust-bar {
  padding: 48px 0;
  border-bottom: 1px solid var(--border-subtle);
  background: var(--bg-primary);
  overflow: hidden;
}
.trust-label {
  text-align: center;
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--text-faint);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 24px;
}
.marquee-wrap {
  overflow: hidden;
  mask-image: linear-gradient(to right, transparent, black 10%, black 90%, transparent);
  -webkit-mask-image: linear-gradient(to right, transparent, black 10%, black 90%, transparent);
}
.marquee-track {
  display: flex;
  gap: 48px;
  width: max-content;
  animation: marquee 25s linear infinite;
}
@keyframes marquee {
  0% { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}
.trust-item {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text-faint);
  transition: color var(--transition);
  flex-shrink: 0;
}
.trust-item:hover { color: var(--text-muted); }

/* ─── Section Headers ───────────────────────────────────── */
.section-header {
  text-align: center;
  max-width: 640px;
  margin: 0 auto 64px;
}
.section-tag {
  display: inline-block;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--blue);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 12px;
}
.section-title {
  font-size: clamp(1.8rem, 3.5vw, 2.8rem);
  font-weight: 800;
  color: var(--text-primary);
  letter-spacing: -0.02em;
  line-height: 1.15;
  margin-bottom: 16px;
}
.section-subtitle {
  font-size: 1.1rem;
  color: var(--text-muted);
  line-height: 1.7;
}

/* ─── Features ──────────────────────────────────────────── */
.features {
  padding: 120px 0;
  background: var(--bg-primary);
}
.features-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}
.feature-card {
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  border-radius: var(--radius);
  padding: 32px 24px;
  transition: all var(--transition);
  position: relative;
  overflow: hidden;
}
.card-glow {
  position: absolute;
  inset: 0;
  opacity: 0;
  background: radial-gradient(circle at var(--mouse-x, 50%) var(--mouse-y, 50%), var(--glow-color) 0%, transparent 60%);
  transition: opacity 0.4s ease;
  pointer-events: none;
}
.feature-card:hover .card-glow {
  opacity: 1;
}
.feature-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-lg);
  border-color: rgba(37,99,235,0.3);
}
[data-theme="dark"] .feature-card:hover {
  box-shadow: 0 20px 40px rgba(0,0,0,.4);
  border-color: rgba(37,99,235,0.4);
}
.feature-icon {
  width: 52px;
  height: 52px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
  transition: transform 0.3s ease;
}
.feature-card:hover .feature-icon {
  transform: scale(1.1) rotate(-3deg);
}
.feature-icon svg { width: 26px; height: 26px; }
.feature-icon.blue { background: var(--blue-light); color: var(--blue); }
.feature-icon.green { background: var(--green-light); color: var(--green); }
.feature-icon.purple { background: var(--purple-light); color: var(--purple); }
.feature-icon.orange { background: var(--orange-light); color: var(--orange); }
.feature-icon.pink { background: var(--pink-light); color: var(--pink); }
.feature-icon.teal { background: var(--teal-light); color: var(--teal); }
.feature-icon.indigo { background: var(--indigo-light); color: var(--indigo); }
.feature-icon.red { background: var(--red-light); color: var(--red); }

.feature-card h3 {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 10px;
}
.feature-card p {
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.6;
}

/* ─── Roles ─────────────────────────────────────────────── */
.roles {
  padding: 120px 0;
  background: var(--section-alt);
}
.roles-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
  align-items: start;
}
.role-card {
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  border-radius: var(--radius-lg);
  padding: 40px 32px;
  text-align: center;
  transition: all var(--transition);
  position: relative;
}
.role-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}
[data-theme="dark"] .role-card:hover {
  box-shadow: 0 20px 40px rgba(0,0,0,.4);
}
.role-card.featured {
  border-color: var(--blue);
  box-shadow: 0 0 0 1px var(--blue), var(--shadow-lg);
  transform: scale(1.04);
}
[data-theme="dark"] .role-card.featured {
  box-shadow: 0 0 0 1px var(--blue), 0 0 40px rgba(37,99,235,0.15);
}
.role-card.featured:hover {
  transform: scale(1.04) translateY(-4px);
}
.role-badge {
  position: absolute;
  top: -14px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--blue);
  color: white;
  font-size: 0.75rem;
  font-weight: 700;
  padding: 6px 20px;
  border-radius: 100px;
  white-space: nowrap;
  animation: badge-glow 2s ease-in-out infinite;
}
@keyframes badge-glow {
  0%, 100% { box-shadow: 0 0 10px rgba(37,99,235,0.3); }
  50% { box-shadow: 0 0 25px rgba(37,99,235,0.6); }
}
.role-icon-wrap {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 20px;
  transition: transform 0.5s cubic-bezier(.34,1.56,.64,1);
}
.role-card:hover .role-icon-wrap {
  transform: scale(1.15) rotate(5deg);
}
.role-icon-wrap.dentist { background: linear-gradient(135deg, var(--green-light), #a7f3d0); }
.role-icon-wrap.student { background: linear-gradient(135deg, var(--blue-light), #93c5fd); }
.role-icon-wrap.patient { background: linear-gradient(135deg, var(--orange-light), #fde68a); }
.role-emoji { font-size: 2rem; }

.role-card h3 {
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--text-primary);
  margin-bottom: 10px;
}
.role-desc {
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.6;
  margin-bottom: 24px;
}
.role-features {
  list-style: none;
  text-align: left;
}
.role-features li {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.88rem;
  color: var(--text-secondary);
  padding: 8px 0;
  border-top: 1px solid var(--border-subtle);
}
.check {
  color: var(--green);
  font-weight: 700;
  font-size: 0.9rem;
}

/* ─── How It Works ──────────────────────────────────────── */
.how-it-works {
  padding: 120px 0;
  background: var(--bg-primary);
}
.steps-timeline {
  max-width: 680px;
  margin: 0 auto;
  position: relative;
}
.steps-timeline::before {
  content: '';
  position: absolute;
  left: 32px;
  top: 0;
  bottom: 0;
  width: 2px;
  background: linear-gradient(to bottom, var(--blue), var(--purple));
  border-radius: 2px;
}
.step-item {
  display: flex;
  gap: 28px;
  align-items: flex-start;
  padding: 24px 0;
  position: relative;
}
.step-number {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: var(--bg-card);
  border: 2px solid var(--blue);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  font-weight: 800;
  color: var(--blue);
  flex-shrink: 0;
  position: relative;
  z-index: 1;
  transition: all 0.4s ease;
}
.step-item:hover .step-number {
  background: var(--blue);
  color: white;
  box-shadow: 0 0 20px rgba(37,99,235,0.4);
  transform: scale(1.1);
}
.step-content h3 {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 6px;
  margin-top: 8px;
}
.step-content p {
  font-size: 0.95rem;
  color: var(--text-muted);
  line-height: 1.7;
}

/* ─── Tech Stack ────────────────────────────────────────── */
.tech {
  padding: 120px 0;
  background: var(--section-alt);
}
.tech-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}
.tech-card {
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  border-radius: var(--radius);
  padding: 32px 24px;
  text-align: center;
  transition: all var(--transition);
  position: relative;
  overflow: hidden;
}
.tech-card::before {
  content: '';
  position: absolute;
  inset: -1px;
  border-radius: var(--radius);
  padding: 1px;
  background: linear-gradient(135deg, transparent, transparent);
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  opacity: 0;
  transition: opacity 0.4s ease, background 0.4s ease;
}
.tech-card:hover::before {
  opacity: 1;
  background: linear-gradient(135deg, var(--blue), var(--purple));
}
.tech-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow);
}
[data-theme="dark"] .tech-card:hover {
  box-shadow: 0 10px 30px rgba(0,0,0,.4);
}
.tech-icon {
  font-size: 2rem;
  margin-bottom: 14px;
  transition: transform 0.5s cubic-bezier(.34,1.56,.64,1);
}
.tech-card:hover .tech-icon {
  transform: scale(1.3);
}
.tech-card h4 {
  font-size: 1rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 4px;
}
.tech-card p {
  font-size: 0.82rem;
  color: var(--text-faint);
}

/* ─── Download CTA ──────────────────────────────────────── */
.download {
  padding: 120px 0 80px;
  background: var(--bg-primary);
}
.download-card {
  position: relative;
  background: var(--text-primary);
  border-radius: 32px;
  padding: 80px 60px;
  text-align: center;
  overflow: hidden;
}
[data-theme="dark"] .download-card {
  background: #16161f;
  border: 1px solid var(--border-color);
}
.download-bg-glow {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 20% 50%, rgba(37,99,235,0.2) 0%, transparent 50%),
    radial-gradient(circle at 80% 50%, rgba(124,58,237,0.2) 0%, transparent 50%);
  pointer-events: none;
  animation: glow-pulse 4s ease-in-out infinite;
}
@keyframes glow-pulse {
  0%, 100% { opacity: 0.7; }
  50% { opacity: 1; }
}
.download-content {
  position: relative;
  z-index: 1;
}
.download-content h2 {
  font-size: clamp(1.6rem, 3vw, 2.4rem);
  font-weight: 800;
  color: white;
  letter-spacing: -0.02em;
  margin-bottom: 16px;
  line-height: 1.2;
}
[data-theme="dark"] .download-content h2 { color: var(--text-primary); }
.download-content p {
  font-size: 1.05rem;
  color: rgba(255,255,255,0.6);
  max-width: 520px;
  margin: 0 auto 36px;
  line-height: 1.7;
}
[data-theme="dark"] .download-content p { color: var(--text-muted); }
.download-buttons {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
}
.store-btn {
  display: flex;
  align-items: center;
  gap: 14px;
  background: white;
  color: var(--text-primary);
  padding: 14px 28px;
  border-radius: 14px;
  transition: all var(--transition);
}
[data-theme="dark"] .store-btn {
  background: var(--bg-primary);
  border: 1px solid var(--border-color);
}
.store-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(0,0,0,.3);
}
.store-btn div { text-align: left; }
.store-label {
  display: block;
  font-size: 0.65rem;
  font-weight: 500;
  color: var(--text-faint);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
.store-name {
  display: block;
  font-size: 1.1rem;
  font-weight: 700;
  line-height: 1.2;
}

/* ─── Footer ────────────────────────────────────────────── */
.footer {
  padding: 80px 0 40px;
  border-top: 1px solid var(--footer-border);
  background: var(--bg-primary);
}
.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 48px;
  margin-bottom: 48px;
}
.footer-desc {
  font-size: 0.9rem;
  color: var(--text-faint);
  line-height: 1.7;
  margin-top: 12px;
  max-width: 300px;
}
.footer-links-group h4 {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 16px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}
.footer-links-group a {
  display: block;
  font-size: 0.9rem;
  color: var(--text-muted);
  padding: 6px 0;
  transition: color var(--transition);
}
.footer-links-group a:hover { color: var(--blue); }
.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 32px;
  border-top: 1px solid var(--footer-border);
}
.footer-bottom p {
  font-size: 0.82rem;
  color: var(--text-faint);
}
.footer-socials {
  display: flex;
  gap: 16px;
}
.footer-socials a {
  color: var(--text-faint);
  transition: all var(--transition);
}
.footer-socials a:hover {
  color: var(--blue);
  transform: translateY(-2px);
}

/* ─── 3D Tilt Card Effect ────────────────────────────────── */
.tilt-card {
  transform-style: preserve-3d;
  perspective: 1000px;
}

/* ═══════════ RESPONSIVE ═══════════ */
@media (max-width: 1024px) {
  .features-grid { grid-template-columns: repeat(2, 1fr); }
  .tech-grid { grid-template-columns: repeat(2, 1fr); }
  .hero-inner { gap: 40px; }
}

@media (max-width: 768px) {
  .nav-links { display: none; }
  .nav-links.open {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: 72px;
    left: 0;
    right: 0;
    background: var(--bg-nav-mobile);
    padding: 24px;
    gap: 16px;
    border-bottom: 1px solid var(--border-color);
    box-shadow: var(--shadow-lg);
    animation: slideDown 0.3s ease;
  }
  @keyframes slideDown {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
  }
  .nav-toggle { display: flex; }

  .hero { padding: 100px 0 60px; min-height: auto; }
  .hero-inner {
    grid-template-columns: 1fr;
    text-align: center;
  }
  .hero-subtitle { margin: 0 auto 36px; }
  .hero-actions { justify-content: center; }
  .hero-stats { justify-content: center; }
  .hero-visual { margin-top: 40px; }
  .float-card-1 { left: 0; top: 20px; }
  .float-card-2 { right: 0; }
  .float-card-3 { left: 0; }

  .roles-grid {
    grid-template-columns: 1fr;
    max-width: 400px;
    margin: 0 auto;
  }
  .role-card.featured { transform: none; }
  .role-card.featured:hover { transform: translateY(-4px); }

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

  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 32px;
  }
  .footer-brand { grid-column: 1 / -1; }
  .footer-bottom { flex-direction: column; gap: 16px; text-align: center; }

  .download-card { padding: 60px 32px; border-radius: 24px; }

  .hero-scroll-hint { display: none; }
  
  .cursor-glow { display: none; }

  .hero-orb-1 { width: 300px; height: 300px; }
  .hero-orb-2 { width: 200px; height: 200px; }
  .hero-orb-3 { display: none; }
}

@media (max-width: 480px) {
  .hero-title { font-size: 2.2rem; }
  .hero-actions { flex-direction: column; align-items: center; }
  .hero-stats { flex-wrap: wrap; gap: 16px; }
  .stat-divider { display: none; }
  .phone-frame { width: 240px; height: 480px; }
  .download-buttons { flex-direction: column; align-items: center; }
  .tech-grid { grid-template-columns: 1fr 1fr; gap: 12px; }
  .steps-timeline::before { left: 24px; }
  .step-number { width: 48px; height: 48px; font-size: 0.9rem; }
}

/* ─── Smooth Transitions for Theme Switch ────────────────── */
.navbar, .feature-card, .role-card, .tech-card, .download-card, .store-btn,
.float-card, .phone-screen, .phone-frame, .mock-card, .hero-badge,
section, footer, .step-number, .btn-ghost {
  transition: background 0.5s ease, color 0.5s ease, border-color 0.5s ease, box-shadow 0.5s ease;
}
