/* ============================================================
   Mia Assistant — Marketing site
   Design system + components + animations
   ============================================================ */

:root {
  --c-primary: #4361ee;
  --c-primary-dark: #2f4ad9;
  --c-primary-light: #6b8df5;
  --c-primary-soft: #eef2ff;

  --c-accent: #7c3aed;
  --c-accent-soft: #f5f0ff;

  --c-success: #2d7a56;
  --c-success-soft: #e8f6ef;

  --c-danger: #e74c3c;

  --c-ink-900: #1a2332;
  --c-ink-800: #2c3e50;
  --c-ink-700: #4a5568;
  --c-ink-500: #6b7b8d;
  --c-ink-400: #95a0ad;
  --c-ink-300: #bcc5d0;
  --c-ink-200: #e8edf2;
  --c-ink-100: #f5f7fb;
  --c-ink-50:  #fafbfd;

  --c-bg: #ffffff;

  --shadow-sm: 0 1px 2px rgba(15, 23, 42, 0.04);
  --shadow-md: 0 4px 16px rgba(15, 23, 42, 0.06);
  --shadow-lg: 0 12px 40px rgba(15, 23, 42, 0.08);
  --shadow-xl: 0 24px 60px rgba(15, 23, 42, 0.12);
  --shadow-glow: 0 8px 30px rgba(67, 97, 238, 0.18);

  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  --radius-full: 999px;

  --gradient-primary: linear-gradient(135deg, #4361ee 0%, #6b8df5 100%);
  --gradient-hero: linear-gradient(150deg, #4361ee 0%, #5a7bf2 50%, #6b8df5 100%);

  --ease: cubic-bezier(0.4, 0, 0.2, 1);
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-bounce: cubic-bezier(0.34, 1.56, 0.64, 1);
}

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

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

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-weight: 400;
  line-height: 1.65;
  color: var(--c-ink-800);
  background: var(--c-bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

img, svg { display: block; max-width: 100%; }

a {
  color: var(--c-primary);
  text-decoration: none;
  transition: color 0.2s var(--ease);
}
a:hover { color: var(--c-primary-dark); }

button {
  font-family: inherit;
  cursor: pointer;
  border: none;
  background: none;
}

ul { list-style: none; }

h1, h2, h3, h4, h5, h6 {
  font-weight: 800;
  line-height: 1.2;
  letter-spacing: -0.02em;
  color: var(--c-ink-900);
}

::selection {
  background: var(--c-primary);
  color: white;
}

/* ============================================================
   LAYOUT
   ============================================================ */
.container {
  width: 100%;
  max-width: 1140px;
  margin: 0 auto;
  padding: 0 24px;
}

.section-eyebrow {
  display: inline-block;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--c-primary);
  margin-bottom: 14px;
}

.section-title {
  font-size: clamp(28px, 4vw, 42px);
  font-weight: 800;
  margin-bottom: 16px;
  color: var(--c-ink-900);
}

.section-sub {
  font-size: 17px;
  color: var(--c-ink-500);
  margin-bottom: 48px;
  max-width: 640px;
}

/* ============================================================
   BUTTONS
   ============================================================ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 14px 26px;
  border-radius: var(--radius-md);
  font-weight: 700;
  font-size: 15px;
  letter-spacing: 0.2px;
  transition: all 0.25s var(--ease-out);
  white-space: nowrap;
  cursor: pointer;
  text-decoration: none;
  position: relative;
  overflow: hidden;
}

.btn::after {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at center, rgba(255, 255, 255, 0.4), transparent 70%);
  opacity: 0;
  transition: opacity 0.4s var(--ease);
  pointer-events: none;
}
.btn:hover::after { opacity: 1; }

.btn-primary {
  background: var(--gradient-primary);
  color: white;
  box-shadow: var(--shadow-glow);
}
.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 14px 40px rgba(67, 97, 238, 0.32);
  color: white;
}

.btn-secondary {
  background: var(--c-primary-soft);
  color: var(--c-primary);
}
.btn-secondary:hover {
  background: #e0e7ff;
  color: var(--c-primary-dark);
}

.btn-ghost {
  background: transparent;
  color: var(--c-ink-800);
  border: 2px solid var(--c-ink-200);
}
.btn-ghost:hover {
  border-color: var(--c-primary);
  color: var(--c-primary);
}

.btn-white {
  background: white;
  color: var(--c-primary);
  box-shadow: var(--shadow-xl);
}
.btn-white:hover {
  transform: translateY(-2px);
  background: #f8f9ff;
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.18);
}

.btn-lg { padding: 16px 32px; font-size: 16px; }
.btn-xl { padding: 20px 44px; font-size: 18px; border-radius: var(--radius-lg); }
.btn-block { width: 100%; }

.btn-primary-sm {
  background: var(--gradient-primary);
  color: white;
  padding: 10px 18px;
  border-radius: var(--radius-sm);
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s var(--ease);
}
.btn-primary-sm:hover { transform: translateY(-1px); box-shadow: var(--shadow-glow); }

.btn-ghost-sm {
  background: transparent;
  color: var(--c-ink-700);
  padding: 10px 18px;
  border: 1px solid var(--c-ink-200);
  border-radius: var(--radius-sm);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s var(--ease);
}
.btn-ghost-sm:hover { border-color: var(--c-ink-400); color: var(--c-ink-900); }

/* ============================================================
   NAV
   ============================================================ */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  padding: 20px 0;
  transition: all 0.3s var(--ease);
  background: rgba(255, 255, 255, 0);
  backdrop-filter: blur(0);
}
.nav.is-scrolled {
  padding: 12px 0;
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: saturate(180%) blur(16px);
  -webkit-backdrop-filter: saturate(180%) blur(16px);
  border-bottom: 1px solid var(--c-ink-200);
  box-shadow: var(--shadow-sm);
}

.nav-inner {
  max-width: 1140px;
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  align-items: center;
  gap: 32px;
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--c-ink-900);
  font-weight: 800;
  font-size: 18px;
  letter-spacing: -0.5px;
  white-space: nowrap;
}
.nav-logo:hover { color: var(--c-ink-900); }

.nav-logo-mark {
  width: 36px;
  height: 36px;
  background: var(--gradient-primary);
  border-radius: 10px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-weight: 900;
  font-size: 18px;
  box-shadow: var(--shadow-glow);
  transition: transform 0.3s var(--ease-bounce);
}
.nav-logo:hover .nav-logo-mark { transform: rotate(-8deg) scale(1.05); }

.nav-links {
  display: flex;
  gap: 28px;
  margin-left: auto;
}
.nav-links a {
  color: var(--c-ink-700);
  font-weight: 500;
  font-size: 15px;
  position: relative;
}
.nav-links a::after {
  content: '';
  position: absolute;
  left: 0; bottom: -4px;
  width: 100%;
  height: 2px;
  background: var(--c-primary);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.3s var(--ease);
}
.nav-links a:hover { color: var(--c-ink-900); }
.nav-links a:hover::after { transform: scaleX(1); }

.nav-cta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: #25D366;
  color: white;
  padding: 10px 18px;
  border-radius: var(--radius-md);
  font-weight: 700;
  font-size: 14px;
  transition: all 0.25s var(--ease);
  box-shadow: 0 4px 14px rgba(37, 211, 102, 0.3);
}
.nav-cta:hover {
  transform: translateY(-1px);
  box-shadow: 0 8px 22px rgba(37, 211, 102, 0.45);
  background: #20bf5b;
  color: white;
}

.nav-burger {
  display: none;
  flex-direction: column;
  gap: 5px;
  padding: 8px;
}
.nav-burger span {
  width: 22px;
  height: 2px;
  background: var(--c-ink-800);
  border-radius: 2px;
  transition: all 0.3s var(--ease);
}

/* ============================================================
   HERO
   ============================================================ */
.hero {
  position: relative;
  padding: 140px 24px 100px;
  overflow: hidden;
  display: grid;
  grid-template-columns: 1fr 420px;
  gap: 64px;
  max-width: 1240px;
  margin: 0 auto;
  align-items: center;
}

.hero-bg {
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  overflow: hidden;
}

.hero-blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  opacity: 0.4;
  animation: float 20s ease-in-out infinite;
}
.hero-blob-1 {
  top: -10%; left: -10%;
  width: 480px; height: 480px;
  background: radial-gradient(circle, #6b8df5 0%, transparent 70%);
}
.hero-blob-2 {
  top: 20%; right: -10%;
  width: 380px; height: 380px;
  background: radial-gradient(circle, #c5a8f5 0%, transparent 70%);
  animation-delay: -7s;
  animation-duration: 25s;
}
.hero-blob-3 {
  bottom: -15%; left: 30%;
  width: 420px; height: 420px;
  background: radial-gradient(circle, #a8bcf5 0%, transparent 70%);
  animation-delay: -14s;
  animation-duration: 30s;
}

@keyframes float {
  0%, 100% { transform: translate(0, 0) scale(1); }
  33%      { transform: translate(40px, -30px) scale(1.05); }
  66%      { transform: translate(-30px, 40px) scale(0.95); }
}

.hero-grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(to right, rgba(67, 97, 238, 0.04) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(67, 97, 238, 0.04) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: radial-gradient(ellipse 60% 70% at 50% 30%, black 30%, transparent 80%);
  -webkit-mask-image: radial-gradient(ellipse 60% 70% at 50% 30%, black 30%, transparent 80%);
}

.hero-inner {
  position: relative;
  z-index: 1;
}

.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: white;
  border: 1px solid var(--c-ink-200);
  padding: 8px 16px;
  border-radius: var(--radius-full);
  font-size: 13px;
  font-weight: 600;
  color: var(--c-ink-700);
  margin-bottom: 24px;
  box-shadow: var(--shadow-sm);
}

.pulse-dot {
  width: 8px;
  height: 8px;
  background: var(--c-primary);
  border-radius: 50%;
  position: relative;
  flex-shrink: 0;
}
.pulse-dot::before {
  content: '';
  position: absolute;
  inset: -4px;
  border-radius: 50%;
  background: var(--c-primary);
  opacity: 0.4;
  animation: pulse 2s ease-in-out infinite;
}
@keyframes pulse {
  0%, 100% { transform: scale(1); opacity: 0.4; }
  50%      { transform: scale(1.6); opacity: 0; }
}

.hero-title {
  font-size: clamp(36px, 5.5vw, 60px);
  font-weight: 900;
  line-height: 1.05;
  margin-bottom: 20px;
  letter-spacing: -0.03em;
}
.hero-highlight {
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  position: relative;
}

.hero-tagline {
  font-size: 19px;
  color: var(--c-ink-500);
  margin-bottom: 36px;
  max-width: 540px;
  line-height: 1.6;
}
.hero-tagline strong { color: var(--c-ink-900); font-weight: 700; }

.hero-ctas {
  display: flex;
  gap: 14px;
  margin-bottom: 28px;
  flex-wrap: wrap;
}

.hero-trust {
  display: flex;
  gap: 22px;
  flex-wrap: wrap;
}
.trust-item {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  color: var(--c-ink-500);
}
.trust-check {
  color: var(--c-success);
  font-weight: 800;
}

/* Phone mockup */
.hero-mock {
  position: relative;
  z-index: 1;
  display: flex;
  justify-content: center;
  align-items: center;
  perspective: 1000px;
}

.phone {
  width: 320px;
  height: 620px;
  background: linear-gradient(145deg, #1a2332 0%, #2c3e50 100%);
  border-radius: 44px;
  padding: 14px;
  box-shadow:
    0 30px 80px rgba(15, 23, 42, 0.4),
    inset 0 0 0 2px rgba(255, 255, 255, 0.08);
  position: relative;
  animation: phoneFloat 6s ease-in-out infinite;
  transform: rotate(-3deg);
}
@keyframes phoneFloat {
  0%, 100% { transform: rotate(-3deg) translateY(0); }
  50%      { transform: rotate(-3deg) translateY(-12px); }
}

.phone-notch {
  position: absolute;
  top: 14px;
  left: 50%;
  transform: translateX(-50%);
  width: 100px;
  height: 22px;
  background: #0a0e15;
  border-radius: 12px;
  z-index: 2;
}

.phone-screen {
  width: 100%;
  height: 100%;
  background: #075E54;
  border-radius: 32px;
  overflow: hidden;
  position: relative;
  display: flex;
  flex-direction: column;
}

.phone-bar {
  background: #128C7E;
  padding: 36px 16px 12px;
  display: flex;
  align-items: center;
  gap: 12px;
  color: white;
  flex-shrink: 0;
}
.phone-avatar {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: var(--gradient-primary);
  color: white;
  font-weight: 900;
  display: flex;
  align-items: center;
  justify-content: center;
}
.phone-name { font-weight: 700; font-size: 15px; }
.phone-status {
  font-size: 11px;
  opacity: 0.8;
  display: flex;
  align-items: center;
  gap: 5px;
}
.phone-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #6dd5b0;
}

.phone-chat {
  flex: 1;
  background:
    linear-gradient(rgba(229, 221, 213, 0.92), rgba(229, 221, 213, 0.92)),
    repeating-linear-gradient(45deg, #d9cdc1 0 2px, transparent 2px 14px);
  padding: 16px 12px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  overflow: hidden;
}

.bubble {
  max-width: 78%;
  padding: 8px 12px;
  border-radius: 12px;
  font-size: 13px;
  line-height: 1.4;
  box-shadow: 0 1px 1px rgba(0, 0, 0, 0.08);
  opacity: 0;
  transform: translateY(8px);
  animation: bubbleIn 0.35s var(--ease-out) forwards;
}
.bubble.user {
  background: #DCF8C6;
  align-self: flex-end;
  color: #2c3e50;
  border-bottom-right-radius: 2px;
}
.bubble.bot {
  background: white;
  align-self: flex-start;
  color: #2c3e50;
  border-bottom-left-radius: 2px;
}
.bubble.typing {
  display: inline-flex;
  gap: 4px;
  padding: 12px 14px;
}
.bubble.typing span {
  width: 6px;
  height: 6px;
  background: var(--c-ink-400);
  border-radius: 50%;
  animation: typingDot 1.2s infinite ease-in-out;
}
.bubble.typing span:nth-child(2) { animation-delay: 0.15s; }
.bubble.typing span:nth-child(3) { animation-delay: 0.3s; }
@keyframes typingDot {
  0%, 60%, 100% { transform: scale(0.7); opacity: 0.4; }
  30%           { transform: scale(1); opacity: 1; }
}
@keyframes bubbleIn {
  to { opacity: 1; transform: translateY(0); }
}

/* ============================================================
   COMPARISON STRIP
   ============================================================ */
.strip {
  background: linear-gradient(135deg, #2c3e50 0%, #1a2332 100%);
  color: white;
  padding: 36px 24px;
  position: relative;
  overflow: hidden;
}
.strip::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at 20% 50%, rgba(67, 97, 238, 0.2) 0%, transparent 60%);
  pointer-events: none;
}
.strip-inner {
  max-width: 920px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 24px;
  position: relative;
}
.strip-item {
  text-align: center;
  flex: 1;
}
.strip-label {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 2px;
  opacity: 0.6;
  margin-bottom: 8px;
  font-weight: 600;
}
.strip-value {
  font-size: clamp(24px, 4vw, 36px);
  font-weight: 800;
  letter-spacing: -0.5px;
}
.strip-crossed {
  text-decoration: line-through;
  text-decoration-color: var(--c-danger);
  text-decoration-thickness: 3px;
  opacity: 0.7;
}
.strip-highlight {
  color: #6dd5b0;
}
.strip-divider {
  color: var(--c-ink-400);
  opacity: 0.5;
}

/* ============================================================
   PROBLEM SECTION
   ============================================================ */
.problem {
  padding: 100px 0;
  background: var(--c-ink-50);
}
.problem-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
}
.problem-card {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 22px;
  background: white;
  border-radius: var(--radius-lg);
  border: 1px solid var(--c-ink-200);
  border-left: 4px solid #e67e7e;
  transition: all 0.3s var(--ease);
}
.problem-card:hover {
  transform: translateX(4px);
  box-shadow: var(--shadow-md);
}
.problem-icon {
  width: 40px;
  height: 40px;
  background: #fdf5f5;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  flex-shrink: 0;
}
.problem-card p { color: var(--c-ink-700); font-size: 15px; line-height: 1.55; }

/* ============================================================
   FEATURES
   ============================================================ */
.features {
  padding: 100px 0;
  background: white;
}
.features-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
}
.feature-card {
  padding: 32px;
  background: white;
  border-radius: var(--radius-xl);
  border: 1px solid var(--c-ink-200);
  transition: all 0.4s var(--ease);
  position: relative;
  overflow: hidden;
}
.feature-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 4px;
  background: var(--gradient-primary);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.4s var(--ease);
}
.feature-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-lg);
  border-color: transparent;
}
.feature-card:hover::before { transform: scaleX(1); }

.feature-icon {
  width: 56px;
  height: 56px;
  background: var(--c-primary);
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 26px;
  margin-bottom: 18px;
  transition: transform 0.3s var(--ease-bounce);
}
.feature-card:hover .feature-icon { transform: scale(1.08) rotate(-4deg); }
.feature-icon-purple { background: var(--c-accent); }

.feature-card h3 {
  font-size: 19px;
  font-weight: 700;
  margin-bottom: 10px;
  color: var(--c-ink-900);
}
.feature-card p {
  font-size: 15px;
  color: var(--c-ink-500);
  line-height: 1.6;
}
.feature-card strong { color: var(--c-ink-800); font-weight: 700; }

/* Premium feature highlight */
.feature-premium {
  grid-column: 1 / -1;
  background: linear-gradient(135deg, #faf5ff 0%, #f5f0ff 100%);
  border-color: #c5a8f5;
}
.feature-premium::before { background: var(--c-accent); }
.feature-premium-badge {
  position: absolute;
  top: 24px;
  right: 24px;
  background: var(--c-accent);
  color: white;
  font-size: 11px;
  font-weight: 700;
  padding: 5px 12px;
  border-radius: var(--radius-full);
  text-transform: uppercase;
  letter-spacing: 1px;
}
.feature-premium-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  margin-top: 18px;
}
.feature-premium-grid > div {
  background: white;
  padding: 16px;
  border-radius: var(--radius-md);
  border: 1px solid #e8dffa;
}
.feature-premium-grid strong {
  color: var(--c-accent);
  display: block;
  margin-bottom: 6px;
  font-size: 14px;
}
.feature-premium-grid p { font-size: 13px; line-height: 1.5; }
.feature-premium-note {
  margin-top: 18px;
  padding-top: 16px;
  border-top: 1px solid #e8dffa;
  color: var(--c-accent);
  font-size: 13px;
  font-weight: 600;
}

/* ============================================================
   HOW IT WORKS
   ============================================================ */
.how {
  padding: 100px 0;
  background: var(--c-ink-100);
  position: relative;
}
.how .container { text-align: center; }
.how .section-eyebrow,
.how .section-title { display: block; }
.how .section-title { margin-bottom: 56px; }

.how-steps {
  display: flex;
  align-items: stretch;
  gap: 16px;
  margin-top: 24px;
}
.how-step {
  flex: 1;
  background: white;
  padding: 36px 24px;
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-md);
  text-align: center;
  position: relative;
  transition: all 0.3s var(--ease);
}
.how-step:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-lg);
}
.how-step-number {
  width: 56px;
  height: 56px;
  background: var(--gradient-primary);
  color: white;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  font-weight: 900;
  margin-bottom: 18px;
  box-shadow: var(--shadow-glow);
}
.how-step h3 { font-size: 17px; margin-bottom: 8px; color: var(--c-ink-900); }
.how-step p { color: var(--c-ink-500); font-size: 14px; line-height: 1.55; }

.how-arrow {
  display: flex;
  align-items: center;
  color: var(--c-primary);
  opacity: 0.5;
  flex-shrink: 0;
}

/* ============================================================
   CHAT EXAMPLE
   ============================================================ */
.chat {
  padding: 100px 0;
  background: linear-gradient(135deg, #1a2332 0%, #2c3e50 100%);
  color: white;
  position: relative;
  overflow: hidden;
}
.chat::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 20% 30%, rgba(67, 97, 238, 0.15) 0%, transparent 50%),
    radial-gradient(circle at 80% 70%, rgba(124, 58, 237, 0.12) 0%, transparent 50%);
  pointer-events: none;
}
.chat .container { position: relative; text-align: center; }
.chat-eyebrow { color: #9fb3c8 !important; }
.chat-title { color: white !important; margin-bottom: 48px; }

.chat-stage {
  max-width: 540px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 12px;
  min-height: 380px;
}
.stage-bubble {
  max-width: 80%;
  padding: 14px 20px;
  border-radius: 18px;
  font-size: 15px;
  line-height: 1.5;
  text-align: left;
  opacity: 0;
  transform: translateY(8px);
  animation: bubbleIn 0.4s var(--ease-out) forwards;
}
.stage-bubble.user {
  background: var(--c-primary);
  color: white;
  align-self: flex-end;
  border-bottom-right-radius: 4px;
}
.stage-bubble.bot {
  background: #3d5166;
  color: white;
  align-self: flex-start;
  border-bottom-left-radius: 4px;
}
.stage-typing {
  background: #3d5166;
  align-self: flex-start;
  padding: 16px 20px;
  border-radius: 18px;
  border-bottom-left-radius: 4px;
  display: inline-flex;
  gap: 5px;
  opacity: 0;
  animation: bubbleIn 0.3s var(--ease-out) forwards;
  width: fit-content;
}
.stage-typing span {
  width: 7px;
  height: 7px;
  background: white;
  border-radius: 50%;
  opacity: 0.7;
  animation: typingDot 1.2s infinite ease-in-out;
}
.stage-typing span:nth-child(2) { animation-delay: 0.15s; }
.stage-typing span:nth-child(3) { animation-delay: 0.3s; }

/* ============================================================
   COMPARISON TABLE
   ============================================================ */
.compare {
  padding: 100px 0;
  background: var(--c-ink-50);
}
.compare .container { text-align: center; }
.compare .section-title { margin-bottom: 40px; }

.compare-table-wrap {
  max-width: 880px;
  margin: 0 auto;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  background: white;
}
.compare-table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
}
.compare-table th,
.compare-table td {
  padding: 16px 22px;
  font-size: 14px;
}
.compare-table thead th {
  background: var(--gradient-primary);
  color: white;
  font-weight: 700;
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.compare-table thead th.compare-mia { background: var(--c-primary-dark); }
.compare-table tbody tr { transition: background 0.2s var(--ease); }
.compare-table tbody tr:hover { background: var(--c-ink-50); }
.compare-table tbody td {
  border-bottom: 1px solid var(--c-ink-200);
  color: var(--c-ink-700);
}
.compare-table tbody tr:last-child td { border-bottom: none; }
.compare-table .compare-mia {
  background: var(--c-primary-soft);
  color: var(--c-primary);
  font-weight: 700;
}

/* ============================================================
   PRICING
   ============================================================ */
.pricing {
  padding: 100px 0;
  background: white;
}
.pricing .container { text-align: center; }

.tier-cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
  align-items: stretch;
  margin-top: 40px;
  text-align: left;
}
.tier-card {
  position: relative;
  padding: 34px 28px;
  background: white;
  border: 2px solid var(--c-ink-200);
  border-radius: var(--radius-xl);
  display: flex;
  flex-direction: column;
  transition: all 0.4s var(--ease);
}
.tier-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

.tier-recommended {
  border-color: var(--c-primary);
  box-shadow: var(--shadow-glow);
  transform: scale(1.04);
}
.tier-recommended:hover {
  transform: scale(1.04) translateY(-4px);
}

.tier-premium {
  background: linear-gradient(180deg, #faf5ff 0%, white 60%);
  border-color: #d4bdfa;
}

.tier-badge {
  position: absolute;
  top: -14px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--gradient-primary);
  color: white;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  padding: 6px 18px;
  border-radius: var(--radius-full);
  white-space: nowrap;
  box-shadow: var(--shadow-glow);
}

.tier-name {
  font-size: 18px;
  font-weight: 700;
  color: var(--c-ink-800);
  margin-bottom: 4px;
}

.tier-price {
  display: flex;
  align-items: baseline;
  gap: 4px;
  margin-bottom: 10px;
}
.tier-price-amount {
  font-size: 48px;
  font-weight: 900;
  color: var(--c-ink-900);
  letter-spacing: -1px;
}
.tier-recommended .tier-price-amount {
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}
.tier-premium .tier-price-amount { color: var(--c-accent); }
.tier-price-period {
  font-size: 16px;
  color: var(--c-ink-500);
  font-weight: 500;
}

.tier-blurb {
  font-size: 14px;
  color: var(--c-ink-500);
  margin-bottom: 22px;
  padding-bottom: 22px;
  border-bottom: 1px solid var(--c-ink-200);
}

.tier-features {
  flex: 1;
  margin-bottom: 24px;
}
.tier-features li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 14px;
  padding: 7px 0;
  color: var(--c-ink-700);
  line-height: 1.45;
}
.tier-check {
  color: var(--c-primary);
  font-weight: 800;
  flex-shrink: 0;
  margin-top: 1px;
}
.tier-premium .tier-check { color: var(--c-accent); }
.tier-disabled { color: var(--c-ink-300); text-decoration: line-through; }
.tier-cross { color: var(--c-ink-300); flex-shrink: 0; margin-top: 1px; }

.pricing-note {
  font-size: 13px;
  color: var(--c-ink-400);
  margin-top: 32px;
}

/* ============================================================
   GUARANTEE
   ============================================================ */
.guarantee { padding: 60px 0; background: white; }
.guarantee-card {
  max-width: 720px;
  margin: 0 auto;
  background: var(--c-success-soft);
  border: 2px solid #7cc5a8;
  border-radius: var(--radius-xl);
  padding: 40px;
  text-align: center;
}
.guarantee-icon { font-size: 48px; margin-bottom: 14px; }
.guarantee-card h3 {
  font-size: 22px;
  font-weight: 700;
  color: var(--c-success);
  margin-bottom: 10px;
}
.guarantee-card p { color: var(--c-ink-700); font-size: 15px; }

/* ============================================================
   FAQ
   ============================================================ */
.faq {
  padding: 100px 0;
  background: var(--c-ink-50);
}
.faq .container { max-width: 820px; }
.faq-list {
  margin-top: 32px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.faq-item {
  background: white;
  border: 1px solid var(--c-ink-200);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: all 0.3s var(--ease);
}
.faq-item:hover { border-color: var(--c-primary-light); }
.faq-item[open] { box-shadow: var(--shadow-md); border-color: var(--c-primary); }
.faq-item summary {
  list-style: none;
  cursor: pointer;
  padding: 20px 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-weight: 600;
  color: var(--c-ink-900);
  font-size: 16px;
  position: relative;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after {
  content: '+';
  font-size: 24px;
  font-weight: 300;
  color: var(--c-primary);
  transition: transform 0.3s var(--ease);
  flex-shrink: 0;
  margin-left: 16px;
}
.faq-item[open] summary::after { transform: rotate(45deg); }
.faq-item p {
  padding: 0 24px 22px;
  color: var(--c-ink-700);
  font-size: 15px;
  line-height: 1.65;
}

/* ============================================================
   FINAL CTA
   ============================================================ */
.cta-final {
  padding: 100px 24px;
  background: var(--gradient-hero);
  color: white;
  text-align: center;
  position: relative;
  overflow: hidden;
}
.cta-final-bg {
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 0.7;
}
.cta-final-inner { position: relative; z-index: 1; }
.cta-final h2 {
  font-size: clamp(30px, 4.5vw, 44px);
  margin-bottom: 14px;
  color: white;
  font-weight: 900;
}
.cta-final p {
  font-size: 18px;
  opacity: 0.9;
  margin-bottom: 36px;
}
.cta-final .btn-white { background: #25D366; color: white; }
.cta-final .btn-white:hover { background: #20bf5b; }

.cta-final-contact {
  margin-top: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  font-size: 15px;
  opacity: 0.95;
  flex-wrap: wrap;
}
.cta-final-contact a {
  color: white;
  font-weight: 600;
  border-bottom: 1px solid rgba(255, 255, 255, 0.4);
  padding-bottom: 1px;
}
.cta-final-contact a:hover { color: white; border-bottom-color: white; }

/* ============================================================
   FOOTER
   ============================================================ */
.footer {
  background: #0f172a;
  color: var(--c-ink-300);
  padding: 64px 0 0;
}
.footer-inner {
  display: grid;
  grid-template-columns: 1.3fr 2fr;
  gap: 60px;
  padding-bottom: 48px;
}
.footer-brand p {
  margin-top: 16px;
  font-size: 14px;
  line-height: 1.6;
  color: var(--c-ink-400);
  max-width: 320px;
}
.footer .nav-logo,
.footer .nav-logo:hover { color: white; }

.footer-cols {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
}
.footer-col h4 {
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: white;
  margin-bottom: 16px;
}
.footer-col ul { display: flex; flex-direction: column; gap: 10px; }
.footer-col a {
  color: var(--c-ink-300);
  font-size: 14px;
  transition: color 0.2s var(--ease);
}
.footer-col a:hover { color: white; }

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding: 24px 0;
}
.footer-bottom p {
  text-align: center;
  font-size: 13px;
  color: var(--c-ink-400);
}

/* ============================================================
   COOKIE BANNER
   ============================================================ */
.cookie-banner {
  position: fixed;
  bottom: 16px;
  left: 16px;
  right: 16px;
  z-index: 200;
  max-width: 640px;
  margin: 0 auto;
  background: white;
  border-radius: var(--radius-lg);
  box-shadow: 0 24px 60px rgba(15, 23, 42, 0.18);
  border: 1px solid var(--c-ink-200);
  animation: cookieIn 0.5s var(--ease-out);
}
.cookie-banner[hidden] { display: none; }

@keyframes cookieIn {
  from { transform: translateY(60px); opacity: 0; }
  to   { transform: translateY(0);    opacity: 1; }
}

.cookie-inner {
  padding: 18px 22px;
  display: flex;
  align-items: center;
  gap: 20px;
  flex-wrap: wrap;
}
.cookie-text { flex: 1; min-width: 220px; }
.cookie-text strong {
  display: block;
  font-size: 14px;
  margin-bottom: 4px;
  color: var(--c-ink-900);
}
.cookie-text p {
  font-size: 13px;
  color: var(--c-ink-500);
  line-height: 1.5;
}
.cookie-text a { color: var(--c-primary); font-weight: 600; }
.cookie-actions {
  display: flex;
  gap: 8px;
  flex-shrink: 0;
}

/* ============================================================
   LEGAL PAGES (Aviso legal, Privacidad, Cookies)
   ============================================================ */
.legal-hero {
  padding: 140px 24px 48px;
  background: linear-gradient(180deg, var(--c-primary-soft) 0%, white 100%);
  text-align: center;
}
.legal-hero h1 {
  font-size: clamp(28px, 4vw, 40px);
  margin-bottom: 8px;
}
.legal-hero p {
  color: var(--c-ink-500);
  font-size: 15px;
}

.legal-content {
  max-width: 760px;
  margin: 0 auto;
  padding: 48px 24px 80px;
  font-size: 15.5px;
  line-height: 1.75;
  color: var(--c-ink-700);
}
.legal-content h2 {
  font-size: 22px;
  margin: 36px 0 14px;
  color: var(--c-ink-900);
  padding-top: 8px;
}
.legal-content h2:first-child { margin-top: 0; }
.legal-content h3 {
  font-size: 17px;
  margin: 24px 0 10px;
  color: var(--c-ink-900);
  font-weight: 700;
}
.legal-content p { margin-bottom: 14px; }
.legal-content ul,
.legal-content ol {
  margin: 0 0 16px 22px;
  padding-left: 0;
  list-style: disc;
}
.legal-content ol { list-style: decimal; }
.legal-content li { margin-bottom: 6px; }
.legal-content strong { color: var(--c-ink-900); }
.legal-content a {
  color: var(--c-primary);
  text-decoration: underline;
  text-decoration-color: rgba(67, 97, 238, 0.3);
  text-underline-offset: 3px;
}
.legal-content a:hover { text-decoration-color: var(--c-primary); }
.legal-content table {
  width: 100%;
  border-collapse: collapse;
  margin: 16px 0 20px;
  font-size: 14px;
}
.legal-content th,
.legal-content td {
  padding: 10px 14px;
  border: 1px solid var(--c-ink-200);
  text-align: left;
  vertical-align: top;
}
.legal-content th {
  background: var(--c-ink-50);
  font-weight: 700;
  color: var(--c-ink-900);
}
.legal-meta {
  margin-top: 40px;
  padding: 16px 20px;
  background: var(--c-ink-50);
  border-radius: var(--radius-md);
  font-size: 13px;
  color: var(--c-ink-500);
}
.legal-placeholder {
  background: #fff7e6;
  border: 1px dashed #f0b042;
  padding: 2px 6px;
  border-radius: 4px;
  font-family: 'SF Mono', 'Monaco', monospace;
  font-size: 0.9em;
  color: #92621a;
}

/* ============================================================
   REVEAL ANIMATIONS (Intersection Observer adds .is-visible)
   ============================================================ */
.reveal,
.reveal-up {
  opacity: 0;
  transform: translateY(24px);
  transition:
    opacity 0.7s var(--ease-out),
    transform 0.7s var(--ease-out);
  transition-delay: var(--delay, 0ms);
}
.reveal.is-visible,
.reveal-up.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* Skip animation for users who prefer 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;
  }
  .reveal, .reveal-up { opacity: 1; transform: none; }
}

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 980px) {
  .hero {
    grid-template-columns: 1fr;
    gap: 48px;
    padding: 110px 24px 64px;
    text-align: center;
  }
  .hero-mock { transform: scale(0.85); }
  .hero-tagline { margin-left: auto; margin-right: auto; }
  .hero-trust { justify-content: center; }
  .hero-ctas { justify-content: center; }
  .footer-inner { grid-template-columns: 1fr; gap: 40px; }
}

@media (max-width: 760px) {
  html { scroll-padding-top: 72px; }
  .nav-inner { gap: 12px; }
  .nav-links { display: none; }
  .nav-cta { padding: 9px 14px; font-size: 13px; white-space: nowrap; }
  /* Hide burger — CTA + scrolling is enough on a one-page site */
  .nav-burger { display: none; }

  .hero { padding: 100px 20px 56px; }
  .hero-blob { filter: blur(60px); }
  .hero-mock { display: none; }

  .strip-inner { flex-direction: column; gap: 20px; }
  .strip-divider { transform: rotate(90deg); }

  .problem,
  .features,
  .how,
  .chat,
  .compare,
  .pricing,
  .faq { padding: 64px 0; }
  .problem-grid,
  .features-grid { grid-template-columns: 1fr; }
  .feature-premium-grid { grid-template-columns: 1fr; }

  .how-steps { flex-direction: column; }
  .how-arrow { transform: rotate(90deg); margin: 0 auto; }

  .compare-table th,
  .compare-table td { padding: 12px 14px; font-size: 13px; }

  .tier-cards { grid-template-columns: 1fr; gap: 16px; }
  .tier-recommended { transform: none; }
  .tier-recommended:hover { transform: translateY(-4px); }

  .footer-cols { grid-template-columns: 1fr; gap: 28px; }

  .cookie-inner { flex-direction: column; align-items: stretch; }
  .cookie-actions { justify-content: stretch; }
  .cookie-actions button { flex: 1; }

  .cta-final { padding: 64px 20px; }
}
