/* ============================================================
   DRA. SOFÍA RAMOS — Landing Page v2
   Geriatra | Especialista en Trastornos del Sueño
   ============================================================
   Estructura tipo plantilla médica profesional (barra superior +
   header sólido, hero con panel de imagen, tarjetas de servicio
   con ícono superpuesto, formulario de cita, footer de columnas)
   construida sobre la paleta corporativa de la marca:
   noche profunda -> azul medio -> celeste -> bruma -> blanco.
   ============================================================ */

:root {
  --night-950: #141d33;
  --night-800: #1f2e4f;
  --slate-600: #324879;
  --sky-vivid: #a3c3ea;
  --sky-300:   #8eb4e3;
  --sky-100:   #c4d7f0;
  --mist-100:  #d9e2f4;
  --mist-50:   #eef2fa;
  --paper-0:   #fcfcfc;

  --ink-900: #16213b;
  --ink-700: #3d4a68;
  --ink-500: #5d6b8a;
  --on-dark-100: #f4f7fc;
  --on-dark-300: #c2d0e8;
  --on-dark-500: #8695b8;

  --font-display: 'Cormorant Garamond', 'Georgia', serif;
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;

  --space-xs: 0.5rem;
  --space-sm: 1rem;
  --space-md: 1.75rem;
  --space-lg: 3rem;
  --space-xl: 5.5rem;

  --radius-sm: 10px;
  --radius-md: 18px;
  --radius-lg: 26px;
  --shadow-soft: 0 24px 60px -24px rgba(20, 29, 51, 0.32);
  --shadow-card: 0 14px 34px -18px rgba(20, 29, 51, 0.28);
  --shadow-lift: 0 26px 50px -20px rgba(20, 29, 51, 0.4);

  --ease: cubic-bezier(0.16, 1, 0.3, 1);
  --container: 1200px;
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
}

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--ink-900);
  background: var(--paper-0);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  font-size: 16.5px;
  line-height: 1.65;
}

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 600;
  color: inherit;
  margin: 0;
  line-height: 1.15;
}
p { margin: 0; }
ul { margin: 0; padding: 0; list-style: none; }
a { color: inherit; text-decoration: none; }
img, svg { max-width: 100%; display: block; }
button { font-family: inherit; cursor: pointer; }
input, select { font-family: inherit; font-size: inherit; }

.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: clamp(1.25rem, 4vw, 2.5rem);
}
section { position: relative; }

/* ---------- Texto y encabezados de sección ---------- */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.6em;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--slate-600);
  margin-bottom: 0.7rem;
  font-style: italic;
  font-family: var(--font-display);
  font-size: 1.05rem;
  letter-spacing: 0.02em;
  text-transform: none;
  font-weight: 600;
}
.on-dark .eyebrow { color: var(--sky-300); }

.section-head { max-width: 640px; margin-bottom: var(--space-lg); }
.section-head.center { margin-inline: auto; text-align: center; }

h2.section-title {
  font-size: clamp(1.9rem, 3.2vw, 2.6rem);
  font-weight: 700;
  font-family: var(--font-body);
  letter-spacing: -0.01em;
  color: var(--night-950);
}
.on-dark h2.section-title { color: var(--on-dark-100); }

.section-lede { margin-top: var(--space-sm); color: var(--ink-500); font-size: 1.04rem; max-width: 56ch; }
.section-head.center .section-lede { margin-inline: auto; }
.on-dark .section-lede { color: var(--on-dark-300); }

a:focus-visible, button:focus-visible, summary:focus-visible, input:focus-visible, select:focus-visible {
  outline: 2px solid var(--sky-300);
  outline-offset: 3px;
  border-radius: 4px;
}

/* ---------- Botones ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.55em;
  padding: 0.95em 1.85em;
  border-radius: 999px;
  font-size: 0.96rem; font-weight: 600;
  border: 1px solid transparent;
  transition: transform 0.35s var(--ease), background 0.3s var(--ease), box-shadow 0.3s var(--ease), border-color 0.3s var(--ease), color .3s var(--ease);
  white-space: nowrap;
}
.btn:hover { transform: translateY(-2px); }
.btn:active { transform: translateY(0); }

.btn-primary { background: var(--sky-vivid); color: var(--night-950); box-shadow: 0 16px 30px -14px rgba(50,72,121,0.4); }
.btn-primary:hover { background: var(--sky-300); }
/* En secciones claras el botón necesita un borde propio para no perderse contra el fondo pálido */
.site-header .btn-primary, .appointment .btn-primary { box-shadow: 0 16px 30px -14px rgba(50,72,121,0.4), 0 0 0 1px rgba(20,29,51,0.08); }

.btn-accent { background: var(--sky-vivid); color: var(--night-950); box-shadow: 0 16px 30px -14px rgba(142,180,227,0.6); }
.btn-accent:hover { background: var(--sky-300); }
.appointment .btn-accent { box-shadow: 0 16px 30px -14px rgba(142,180,227,0.6), 0 0 0 1px rgba(20,29,51,0.08); }

.btn-ghost-dark { border-color: rgba(244, 247, 252, 0.35); color: var(--on-dark-100); }
.btn-ghost-dark:hover { border-color: var(--sky-vivid); color: var(--sky-vivid); background: rgba(163, 195, 234, 0.1); }

.btn-outline { border-color: var(--slate-600); color: var(--slate-600); }
.btn-outline:hover { background: var(--sky-vivid); border-color: var(--sky-vivid); color: var(--night-950); }

.btn-sm { padding: 0.68em 1.35em; font-size: 0.86rem; }
.btn-block { width: 100%; }

.icon-circle-btn {
  width: 46px; height: 46px; border-radius: 50%;
  display: inline-flex; align-items: center; justify-content: center;
  background: var(--mist-100); color: var(--slate-600);
  flex-shrink: 0;
  transition: background 0.35s var(--ease), color 0.35s var(--ease), transform 0.35s var(--ease);
}
.icon-circle-btn svg { width: 18px; height: 18px; }
a:hover > .icon-circle-btn, .icon-circle-btn:hover { background: var(--slate-600); color: var(--on-dark-100); transform: rotate(-40deg); }

/* ============================================================
   TOP BAR
   ============================================================ */
.topbar {
  background: var(--night-950);
  color: var(--on-dark-300);
  font-size: 0.84rem;
  padding: 0.55rem 0;
}
.topbar .container { display: flex; align-items: center; justify-content: space-between; gap: 1rem; flex-wrap: wrap; }
.topbar-left { display: flex; align-items: center; gap: 1.6rem; flex-wrap: wrap; }
.topbar-item { display: flex; align-items: center; gap: 0.5em; }
.topbar-item svg { width: 14px; height: 14px; color: var(--sky-300); flex-shrink: 0; }
.topbar-right { display: flex; align-items: center; gap: 0.5em; }
.topbar-right a {
  display: inline-flex; align-items: center; gap: 0.4em;
  font-weight: 600; color: var(--on-dark-100);
  padding: 0.3em 0.85em;
  border-radius: 999px;
  background: rgba(142, 180, 227, 0.16);
  transition: background 0.3s var(--ease);
}
.topbar-right a:hover { background: rgba(142, 180, 227, 0.3); }
.topbar-right svg { width: 13px; height: 13px; }

/* ============================================================
   HEADER
   ============================================================ */
.site-header {
  position: sticky; top: 0; z-index: 110;
  background: var(--paper-0);
  padding: 0.4rem 0;
  border-bottom: 1px solid rgba(20,29,51,0.06);
  transition: box-shadow 0.35s var(--ease), padding 0.35s var(--ease);
}
.site-header.is-scrolled { box-shadow: 0 12px 30px -22px rgba(20,29,51,0.4); padding: 0.75rem 0; }
.site-header .container { display: flex; align-items: center; justify-content: space-between; gap: 1.5rem; }

.brand { display: flex; align-items: center; gap: 0.8rem; }
.brand-mark { width: 40px; height: 40px; flex-shrink: 0; color: var(--slate-600); }
.site-logo { height: 75px; width: 250px; display: block; flex-shrink: 0; }
.brand-text { display: flex; flex-direction: column; line-height: 1.1; }
.brand-name { font-family: var(--font-display); font-size: 1.28rem; letter-spacing: 0.02em; color: var(--night-950); font-weight: 600; }
.brand-sub { font-size: 0.62rem; letter-spacing: 0.13em; text-transform: uppercase; color: var(--slate-600); margin-top: 3px; font-weight: 600; }

.main-nav { display: flex; align-items: center; gap: var(--space-lg); }
.nav-links { display: flex; gap: 1.9rem; }
.nav-links a {
  font-size: 0.92rem; font-weight: 600; color: var(--ink-700);
  position: relative; padding: 0.3rem 0;
  transition: color 0.25s var(--ease);
}
.nav-links a::after {
  content: ""; position: absolute; left: 0; right: 100%; bottom: -2px;
  height: 2px; background: var(--sky-300);
  transition: right 0.3s var(--ease);
}
.nav-links a:hover { color: var(--night-950); }
.nav-links a:hover::after { right: 0; }

.nav-cta { display: flex; align-items: center; gap: 1rem; }
.nav-toggle { display: none; background: none; border: none; width: 40px; height: 34px; position: relative; z-index: 110; }
.nav-toggle span, .nav-toggle span::before, .nav-toggle span::after {
  content: ""; position: absolute; left: 4px; right: 4px; height: 2px; background: var(--night-950);
  transition: transform 0.3s var(--ease), opacity 0.3s var(--ease), top 0.3s var(--ease);
}
.nav-toggle span { top: 16px; }
.nav-toggle span::before { top: -9px; }
.nav-toggle span::after { top: 9px; }
.nav-toggle.is-open span { background: transparent; }
.nav-toggle.is-open span::before { top: 0; transform: rotate(45deg); background: var(--night-950); }
.nav-toggle.is-open span::after { top: 0; transform: rotate(-45deg); background: var(--night-950); }

.mobile-nav {
  position: fixed; inset: 0; background: var(--night-950); z-index: 105;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2rem;
  padding: 6.5rem 1.5rem 2rem;
  overflow-y: auto;
  opacity: 0; visibility: hidden; transition: opacity 0.4s var(--ease);
}
.mobile-nav.is-open { opacity: 1; visibility: visible; }
.mobile-nav a { font-family: var(--font-display); font-size: 1.7rem; font-style: italic; color: var(--on-dark-100); }
.mobile-nav .btn { margin-top: 1rem; }

/* ============================================================
   HERO
   ============================================================ */
.hero {
  position: relative;
  min-height: min(88vh, 760px);
  display: flex;
  align-items: center;
  overflow: hidden;
  padding: clamp(7rem, 14vw, 9rem) 0 clamp(3rem, 8vw, 5rem);
  color: var(--on-dark-100);
}
.hero-bg {
  position: absolute; inset: 0; z-index: 0;
}
.hero-bg img {
  width: 100%; height: 100%; object-fit: cover; object-position: 78% 22%;
}
.hero-bg::after {
  content: "";
  position: absolute; inset: 0;
  background:
    linear-gradient(100deg, rgba(14,20,36,0.94) 0%, rgba(14,20,36,0.82) 28%, rgba(14,20,36,0.45) 52%, rgba(14,20,36,0.18) 70%, rgba(14,20,36,0.35) 100%),
    linear-gradient(to top, rgba(14,20,36,0.55) 0%, rgba(14,20,36,0) 30%);
}
.hero .container { position: relative; z-index: 1; width: 100%; }

.hero-copy { max-width: 620px; }
.hero-copy .eyebrow { color: var(--sky-100); }
.hero-title { font-family: var(--font-body); font-size: clamp(2.5rem, 5vw, 3.5rem); font-weight: 800; letter-spacing: -0.02em; color: var(--on-dark-100); text-shadow: 0 2px 24px rgba(0,0,0,0.18); }
.hero-title em { font-style: italic; color: var(--sky-100); font-family: var(--font-display); font-weight: 600; }
.hero-lede { margin-top: var(--space-md); font-size: 1.12rem; color: var(--on-dark-300); max-width: 48ch; }
.hero-actions { margin-top: var(--space-lg); display: flex; align-items: center; flex-wrap: wrap; gap: 1.3rem; }
.hero-doctor { margin-top: var(--space-lg); display: flex; align-items: center; gap: 0.9rem; color: var(--on-dark-300); font-size: 0.92rem; }
.hero-doctor strong { color: var(--on-dark-100); font-weight: 700; }
.hero-doctor .dot { width: 5px; height: 5px; border-radius: 50%; background: var(--sky-300); }

.hero-badge-card {
  position: absolute; right: clamp(1.25rem, 4vw, 2.5rem); bottom: clamp(1.5rem, 4vw, 2.75rem); z-index: 2;
  background: var(--paper-0); border-radius: var(--radius-md);
  box-shadow: var(--shadow-lift);
  padding: 1.1rem 1.3rem;
  display: flex; align-items: center; gap: 0.9rem;
  max-width: 250px;
}
.hero-badge-icon {
  width: 44px; height: 44px; border-radius: 12px; flex-shrink: 0;
  background: var(--mist-100); color: var(--slate-600);
  display: flex; align-items: center; justify-content: center;
}
.hero-badge-icon svg { width: 22px; height: 22px; }
.hero-badge-card strong { display: block; font-size: 0.88rem; color: var(--night-950); line-height: 1.3; }
.hero-badge-card span { font-size: 0.76rem; color: var(--ink-500); }

/* Fotografías reales dentro de los marcos (Sobre mí y tarjetas de servicio) */
.promo-frame img.frame-photo,
.service-visual img.frame-photo {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
}
.photo-tint {
  position: absolute; inset: 0;
  background: linear-gradient(165deg, rgba(20,29,51,0.5), rgba(50,72,121,0.16) 55%, rgba(20,29,51,0.08));
  mix-blend-mode: multiply;
  pointer-events: none;
}

/* ============================================================
   SERVICIOS
   ============================================================ */
.services { background: var(--mist-50); padding: var(--space-xl) 0; }
.services-grid { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: clamp(1.6rem, 3vw, 2.4rem); }

.service-card {
  background: var(--paper-0); border-radius: var(--radius-lg);
  overflow: hidden; box-shadow: var(--shadow-card);
  display: flex; flex-direction: column;
  transition: transform 0.4s var(--ease), box-shadow 0.4s var(--ease);
}
.service-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-lift); }

.service-visual {
  position: relative; aspect-ratio: 16/9;
  background: linear-gradient(150deg, var(--night-950), var(--slate-600) 75%);
  display: flex; align-items: center; justify-content: center;
  overflow: hidden;
}
.service-icon-wrap { position: relative; height: 0; }
.service-icon {
  position: absolute; left: 2.2rem; top: -28px;
  width: 58px; height: 58px; border-radius: 50%;
  background: var(--paper-0); color: var(--slate-600);
  display: flex; align-items: center; justify-content: center;
  box-shadow: var(--shadow-card);
  border: 4px solid var(--paper-0);
}
.service-icon svg { width: 26px; height: 26px; }

.service-body { padding: 2.6rem 2.2rem 2.2rem; display: flex; flex-direction: column; flex-grow: 1; }
.service-card h3 { font-size: 1.5rem; font-family: var(--font-body); font-weight: 700; color: var(--night-950); letter-spacing: -0.01em; }
.service-kicker { font-size: 0.85rem; color: var(--ink-500); margin: 0.55rem 0 1.1rem; font-weight: 500; }

.service-list { display: grid; grid-template-columns: 1fr 1fr; gap: 0.55rem 1rem; margin-bottom: 1.6rem; }
.service-list li { display: flex; align-items: flex-start; gap: 0.55em; font-size: 0.9rem; color: var(--ink-700); }
.service-list svg { width: 14px; height: 14px; flex-shrink: 0; margin-top: 0.28em; color: var(--slate-600); }

.service-footer { margin-top: auto; display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding-top: 0.4rem; }
.service-footer .btn { flex-shrink: 0; }

/* ============================================================
   PROMO / SOBRE LA DOCTORA
   ============================================================ */
.promo { background: var(--paper-0); padding: var(--space-xl) 0; }
.promo .container { display: grid; grid-template-columns: minmax(0,0.85fr) minmax(0,1.15fr); gap: clamp(2.5rem, 6vw, 5rem); align-items: center; }

.promo-visual { position: relative; }
.promo-frame {
  aspect-ratio: 4/4.6;
  border-radius: 24px 130px 24px 24px;
  background: linear-gradient(165deg, var(--mist-100), var(--mist-50) 60%);
  border: 1px solid rgba(50,72,121,0.1);
  display: flex; align-items: center; justify-content: center;
  overflow: hidden; position: relative;
}
.promo-badge-card {
  position: absolute; right: -6%; top: -8%; z-index: 2;
  background: var(--night-950); color: var(--on-dark-100);
  border-radius: var(--radius-md); box-shadow: var(--shadow-lift);
  padding: 1rem 1.2rem; display: flex; align-items: center; gap: 0.8rem; max-width: 230px;
}
.promo-badge-card svg { width: 26px; height: 26px; color: var(--sky-300); flex-shrink: 0; }
.promo-badge-card span { font-size: 0.82rem; color: var(--on-dark-300); line-height: 1.4; }

.promo-badges { display: flex; flex-wrap: wrap; gap: 0.7rem; margin: var(--space-md) 0 var(--space-md); }
.badge {
  display: inline-flex; align-items: center; gap: 0.5em;
  padding: 0.55em 1.05em; border-radius: 999px;
  background: var(--mist-100); color: var(--slate-600);
  font-size: 0.86rem; font-weight: 600;
}
.badge svg { width: 15px; height: 15px; }

.promo-body p + p { margin-top: 1rem; }
.promo-body { color: var(--ink-700); }

.promo-contact {
  margin-top: var(--space-md);
  display: flex; align-items: center; gap: 1.6rem; flex-wrap: wrap;
  padding-top: var(--space-md);
  border-top: 1px solid rgba(20,29,51,0.08);
}
.promo-contact-item { display: flex; align-items: center; gap: 0.85rem; }
.promo-contact-icon {
  width: 48px; height: 48px; border-radius: 50%;
  background: var(--night-950); color: var(--sky-300);
  display: flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.promo-contact-icon svg { width: 20px; height: 20px; }
.promo-contact-text span { display: block; font-size: 0.76rem; color: var(--ink-500); text-transform: uppercase; letter-spacing: 0.06em; }
.promo-contact-text strong { font-size: 1.1rem; color: var(--night-950); font-family: var(--font-display); font-style: italic; }

/* ============================================================
   SÍNTOMAS
   ============================================================ */
.symptoms { background: var(--night-950); padding: var(--space-xl) 0; }
.symptoms-grid { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: clamp(1.6rem, 3vw, 2.4rem); margin-bottom: var(--space-lg); }
.symptom-panel { background: var(--night-800); color: var(--on-dark-100); border-radius: var(--radius-lg); padding: clamp(2rem, 3vw, 2.6rem); border: 1px solid rgba(142,180,227,0.12); }
.symptom-panel.alt { background: var(--slate-600); border-color: rgba(142,180,227,0.2); }
.symptom-panel-head { display: flex; align-items: center; gap: 1rem; margin-bottom: 1.4rem; }
.symptom-panel-icon { width: 52px; height: 52px; border-radius: 14px; background: rgba(142,180,227,0.14); color: var(--sky-300); display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.symptom-panel-icon svg { width: 24px; height: 24px; }
.symptom-panel h3 { font-size: 1.4rem; font-family: var(--font-body); font-weight: 700; color: var(--on-dark-100); }
.symptom-list { display: flex; flex-direction: column; gap: 0.85rem; }
.symptom-list li { display: flex; align-items: flex-start; gap: 0.75em; font-size: 0.97rem; color: var(--on-dark-300); }
.symptom-list svg { width: 17px; height: 17px; flex-shrink: 0; margin-top: 0.2em; color: var(--sky-300); }

.symptoms-closing { text-align: center; max-width: 60ch; margin-inline: auto; }
.symptoms-closing p { font-size: 1.1rem; color: var(--on-dark-300); margin-bottom: var(--space-md); }

/* ============================================================
   AGENDAR CITA (checklist + formulario)
   ============================================================ */
.appointment { background: var(--mist-50); padding: var(--space-xl) 0; }
.appointment .container { display: grid; grid-template-columns: minmax(0,0.95fr) minmax(0,1.05fr); gap: clamp(2.5rem, 5vw, 4rem); align-items: start; }

.appointment-checklist { display: grid; grid-template-columns: 1fr 1fr; gap: 0.9rem 1.4rem; margin: var(--space-md) 0 var(--space-lg); }
.appointment-checklist li { display: flex; align-items: flex-start; gap: 0.6em; font-size: 0.95rem; color: var(--ink-700); font-weight: 500; }
.appointment-checklist svg { width: 17px; height: 17px; color: var(--slate-600); flex-shrink: 0; margin-top: 0.2em; }

.booking-card { background: var(--night-950); border-radius: var(--radius-lg); overflow: hidden; box-shadow: var(--shadow-lift); }
.booking-card-head {
  background: var(--slate-600); padding: 1.7rem 2rem;
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
}
.booking-card-head h3 { font-family: var(--font-body); font-size: 1.25rem; font-weight: 700; color: var(--on-dark-100); }
.booking-card-head p { font-size: 0.86rem; color: var(--on-dark-300); margin-top: 0.3rem; }
.booking-card-head .icon-circle-btn { background: rgba(244,247,252,0.16); color: var(--on-dark-100); }

.booking-form { padding: 2rem; display: flex; flex-direction: column; gap: 1rem; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.field { display: flex; flex-direction: column; gap: 0.5rem; }
.field label { font-size: 0.78rem; font-weight: 600; letter-spacing: 0.04em; text-transform: uppercase; color: var(--on-dark-500); }
.field input, .field select {
  background: rgba(244,247,252,0.06); border: 1px solid rgba(142,180,227,0.22);
  border-radius: 10px; padding: 0.85em 1em; color: var(--on-dark-100);
  transition: border-color 0.3s var(--ease), background 0.3s var(--ease);
}
.field input::placeholder { color: var(--on-dark-500); }
.field input:focus, .field select:focus { border-color: var(--sky-300); background: rgba(244,247,252,0.1); outline: none; }
.field select option { color: var(--night-950); }

.booking-form .btn { margin-top: 0.4rem; }
.booking-note { font-size: 0.8rem; color: var(--on-dark-500); text-align: center; margin-top: -0.2rem; }

/* ============================================================
   FAQ
   ============================================================ */
.faq { background: var(--paper-0); padding: var(--space-xl) 0; }
.faq-list { max-width: 820px; margin-inline: auto; display: flex; flex-direction: column; gap: 0.9rem; }
.faq-item { background: var(--mist-50); border-radius: var(--radius-md); overflow: hidden; border: 1px solid rgba(20,29,51,0.05); }
.faq-question {
  width: 100%; display: flex; align-items: center; justify-content: space-between; gap: 1rem;
  padding: 1.3rem 1.6rem; background: none; border: none; text-align: left;
  font-family: var(--font-body); font-size: 1.02rem; font-weight: 600; color: var(--night-950);
}
.faq-icon {
  width: 32px; height: 32px; flex-shrink: 0; border-radius: 50%;
  background: var(--paper-0); color: var(--slate-600);
  display: flex; align-items: center; justify-content: center;
  transition: transform 0.4s var(--ease), background 0.4s var(--ease), color .4s var(--ease);
  box-shadow: 0 4px 12px -4px rgba(20,29,51,0.15);
}
.faq-icon svg { width: 14px; height: 14px; }
.faq-item[data-open="true"] .faq-icon { transform: rotate(135deg); background: var(--slate-600); color: var(--on-dark-100); }

.faq-answer-wrap { display: grid; grid-template-rows: 0fr; transition: grid-template-rows 0.45s var(--ease); }
.faq-item[data-open="true"] .faq-answer-wrap { grid-template-rows: 1fr; }
.faq-answer-inner { overflow: hidden; }
.faq-answer { padding: 0 1.6rem 1.4rem; color: var(--ink-500); font-size: 0.97rem; max-width: 68ch; }

/* ============================================================
   UBICACIÓN
   ============================================================ */
.location { background: var(--mist-50); padding: var(--space-xl) 0; }
.location-grid { display: grid; grid-template-columns: minmax(0,0.95fr) minmax(0,1.05fr); gap: clamp(2rem, 5vw, 4rem); align-items: start; }

.location-info-grid { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 1.4rem; }
.info-block { background: var(--paper-0); border-radius: var(--radius-md); padding: 1.5rem 1.6rem; box-shadow: var(--shadow-card); }
.info-block-icon { width: 40px; height: 40px; border-radius: 10px; background: var(--mist-100); color: var(--slate-600); display: flex; align-items: center; justify-content: center; margin-bottom: 0.9rem; }
.info-block-icon svg { width: 19px; height: 19px; }
.info-block h4 { font-size: 0.78rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--slate-600); font-weight: 700; margin-bottom: 0.6rem; }
.info-block p, .info-block ul { color: var(--ink-700); font-size: 0.95rem; }
.info-block ul li { margin-bottom: 0.25rem; }
.info-block ul li:last-child { margin-bottom: 0; }
.info-block.full { grid-column: 1 / -1; }

.map-card { border-radius: var(--radius-lg); overflow: hidden; box-shadow: var(--shadow-card); background: var(--paper-0); }
.map-card iframe { display: block; width: 100%; aspect-ratio: 4/3; border: 0; }
.map-footer { padding: 1.1rem 1.4rem; display: flex; align-items: center; justify-content: space-between; gap: 1rem; border-top: 1px solid rgba(20,29,51,0.06); }
.map-footer span { font-size: 0.9rem; color: var(--ink-700); font-weight: 500; }

.location-cta { margin-top: var(--space-lg); text-align: center; }

/* ============================================================
   FOOTER
   ============================================================ */
.site-footer { background: var(--night-950); color: var(--on-dark-300); padding: var(--space-lg) 0 var(--space-sm); }
.footer-top { display: grid; grid-template-columns: 1.3fr 0.85fr 0.95fr 0.95fr; gap: clamp(2rem, 4vw, 3rem); padding-bottom: var(--space-lg); border-bottom: 1px solid rgba(142,180,227,0.14); }
.footer-brand { display: flex; flex-direction: column; align-items: flex-start; gap: 0.9rem; }
.footer-brand .brand-mark { color: var(--sky-300); }
.footer-brand .brand-name { color: var(--on-dark-100); }
.footer-brand p { font-size: 0.92rem; color: var(--on-dark-500); max-width: 34ch; }

.footer-heading { font-size: 0.76rem; letter-spacing: 0.1em; text-transform: uppercase; color: var(--sky-300); font-weight: 700; margin-bottom: 1.1rem; }
.footer-links { display: flex; flex-direction: column; gap: 0.65rem; }
.footer-links a, .footer-links span { font-size: 0.92rem; transition: color 0.25s var(--ease); }
.footer-links a:hover { color: var(--on-dark-100); }
.footer-links .muted { color: var(--on-dark-500); }

.footer-contact-number { font-family: var(--font-display); font-style: italic; font-size: 1.5rem; color: var(--on-dark-100); margin-bottom: 0.9rem; }

.footer-bottom { padding-top: var(--space-sm); display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 0.8rem; font-size: 0.83rem; color: var(--on-dark-500); }

/* ============================================================
   WHATSAPP FLOTANTE
   ============================================================ */
.whatsapp-widget {
  position: fixed; right: 1.4rem; bottom: 1.4rem; z-index: 90;
}

.whatsapp-float {
  position: relative;
  width: 58px; height: 58px; border-radius: 50%;
  background: var(--slate-600); color: var(--on-dark-100);
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 14px 34px -12px rgba(20, 29, 51, 0.55);
  transition: transform 0.35s var(--ease), background 0.3s var(--ease);
}
.whatsapp-widget:hover .whatsapp-float, .whatsapp-float:focus-visible { transform: translateY(-3px) scale(1.04); background: var(--night-950); }
.whatsapp-float svg { width: 27px; height: 27px; }
.whatsapp-float::before {
  content: ""; position: absolute; inset: 0; border-radius: 50%;
  border: 1px solid var(--slate-600); animation: pulse-ring 2.6s ease-out infinite;
}
@keyframes pulse-ring { 0% { transform: scale(1); opacity: 0.6; } 100% { transform: scale(1.55); opacity: 0; } }

/* ---------- Tarjeta emergente del widget de WhatsApp ---------- */
.whatsapp-popup {
  position: absolute; right: 0; bottom: calc(100% + 0.9rem);
  width: min(280px, calc(100vw - 2.8rem));
  background: var(--paper-0);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lift);
  overflow: hidden;
  transform-origin: bottom right;
  opacity: 0; visibility: hidden; transform: translateY(14px) scale(0.94);
  transition: opacity 0.3s var(--ease), transform 0.3s var(--ease), visibility 0.3s;
  pointer-events: none;
}
.whatsapp-widget:hover .whatsapp-popup,
.whatsapp-widget:focus-within .whatsapp-popup {
  opacity: 1; visibility: visible; transform: translateY(0) scale(1);
  pointer-events: auto;
}

.whatsapp-popup-head { background: var(--night-950); color: var(--on-dark-100); padding: 1rem 1.2rem; }
.whatsapp-popup-head strong { display: block; font-family: var(--font-display); font-size: 1.08rem; font-weight: 600; }
.whatsapp-popup-head span { display: block; font-size: 0.78rem; color: var(--sky-300); margin-top: 2px; }
.whatsapp-popup-head small { display: block; margin-top: 0.6rem; font-size: 0.72rem; color: var(--on-dark-500); }

.whatsapp-popup-body { padding: 1rem 1.2rem; }
.whatsapp-bubble {
  background: var(--mist-100); color: var(--ink-700);
  border-radius: var(--radius-sm) var(--radius-sm) var(--radius-sm) 4px;
  padding: 0.7rem 0.9rem; font-size: 0.86rem; line-height: 1.5;
}

.whatsapp-popup-cta {
  margin: 0 1.2rem 1.2rem;
  display: flex; align-items: center; justify-content: center; gap: 0.5em;
  background: #25d366; color: #fff;
  padding: 0.7em 1em; border-radius: 999px;
  font-weight: 600; font-size: 0.9rem;
  transition: background 0.3s var(--ease), transform 0.35s var(--ease);
}
.whatsapp-popup-cta:hover { background: #1ebd5a; transform: translateY(-2px); }
.whatsapp-popup-cta svg { width: 18px; height: 18px; }

/* ============================================================
   REVEAL ON SCROLL
   ============================================================ */
[data-reveal] { opacity: 0; transform: translateY(26px); transition: opacity 0.8s var(--ease), transform 0.8s var(--ease); }
[data-reveal].in-view { opacity: 1; transform: translateY(0); }

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 1024px) {
  .promo .container, .location-grid { grid-template-columns: 1fr; }
  .promo-visual { max-width: 380px; margin-inline: auto; width: 100%; }
  .footer-top { grid-template-columns: 1fr 1fr; row-gap: 2.4rem; }
}

@media (max-width: 900px) {
  .hero { flex-direction: column; justify-content: center; gap: 0; }
  .hero-copy { max-width: 100%; text-align: center; }
  .hero-copy .eyebrow, .hero-doctor, .hero-actions { justify-content: center; }
  .hero-lede { margin-inline: auto; }
  .hero-bg::after {
    background:
      linear-gradient(180deg, rgba(14,20,36,0.55) 0%, rgba(14,20,36,0.72) 45%, rgba(14,20,36,0.9) 100%);
  }
  .hero-badge-card { position: static; margin: 2rem auto 0; }
  .appointment .container { grid-template-columns: 1fr; }
}

@media (max-width: 860px) {
  .topbar { display: none; }
  .nav-links { display: none; }
  .nav-toggle { display: block; }
  .nav-cta .btn-primary { display: none; }

  .services-grid, .symptoms-grid { grid-template-columns: 1fr; }
  .location-info-grid { grid-template-columns: 1fr 1fr; }
  .footer-top { grid-template-columns: 1fr; gap: 2.2rem; }
  .footer-bottom { flex-direction: column; align-items: flex-start; }
  .form-row { grid-template-columns: 1fr; }
  .appointment-checklist { grid-template-columns: 1fr; }
}

@media (max-width: 560px) {
  body { font-size: 16px; }
  .location-info-grid { grid-template-columns: 1fr; }
  .map-footer { flex-direction: column; align-items: flex-start; }
  .hero-badge-card { max-width: 260px; width: 100%; }
  .promo-badge-card { max-width: 190px; right: 4%; }
}
