/* ============================================================
   Dra. Patricia Rubinstein — Psicóloga Humanista y Psicosomática
   Design system compartido (index · aeronáutica · sobre mí)
   ============================================================ */

:root {
  /* Paleta */
  --azul: #0F4C81;
  --azul-claro: #2E86C1;
  --verde: #2E8B57;
  --verde-suave: #6FCF97;
  --verde-texto: #1E6B43;          /* verde oscurecido para texto pequeño (AA) */
  --fondo: #F7FAFC;
  --fondo-2: #EEF4F8;
  --ink: #313D4F;                  /* texto principal, más oscuro que antes */
  --ink-deep: #16233A;             /* titulares y fondos oscuros */
  --gris: #E5E7EB;
  --gris-2: #C3CAD4;
  --muted: #4D5A6B;                /* gris de apoyo con contraste AA */
  --card: #FFFFFF;
  --line: rgba(15,76,129,.12);
  --shadow-soft: 0 24px 60px -32px rgba(15,76,129,.25);
  --shadow-card: 0 14px 40px -24px rgba(15,76,129,.2);

  /* Radios */
  --r-lg: 26px;
  --r-md: 16px;
  --r-sm: 10px;

  /* Layout */
  --maxw: 1240px;

  /* Tipografía — UNA SOLA familia en todo el sitio: Lora.
     Elegante en titulares y legible en texto corrido. */
  --serif: 'Lora', Georgia, serif;
  --sans: 'Lora', Georgia, serif;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--sans);
  font-weight: 400;
  font-size: 18px;
  color: var(--ink);
  background: var(--fondo);
  line-height: 1.7;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }

/* ============ TIPOGRAFÍA ============ */

h1, h2, h3, h4, .display {
  font-family: var(--serif);
  font-weight: 500;
  font-style: normal;
  letter-spacing: -0.01em;
  line-height: 1.1;
  color: var(--ink-deep);
}
h1 em, h2 em, h3 em, blockquote em {
  font-style: italic;
  font-weight: 500;
  color: var(--azul);
}

/* Números de estadísticas, pasos y tarjetas: SIEMPRE el mismo estilo */
.num-display {
  font-family: var(--serif);
  font-weight: 500;
  font-style: normal;
  line-height: 1;
  color: var(--azul);
}

.eyebrow {
  font-family: var(--sans);
  text-transform: uppercase;
  letter-spacing: .2em;
  font-size: 13px;
  font-weight: 700;
  color: var(--verde-texto);
}

.container { max-width: var(--maxw); margin: 0 auto; padding: 0 28px; }

/* ============ TOPBAR ============ */
.topbar {
  background: var(--ink-deep);
  color: rgba(255,255,255,.92);
  font-size: 13.5px;
  padding: 9px 0;
}
.topbar .row {
  display: flex; justify-content: space-between; align-items: center; gap: 20px;
  flex-wrap: wrap;
}
.topbar a { opacity: .9; transition: opacity .2s; }
.topbar a:hover { opacity: 1; }
.topbar .pill {
  display: inline-flex; align-items: center; gap: 8px;
  background: rgba(111,207,151,.18); padding: 4px 14px; border-radius: 999px;
  font-size: 12.5px; font-weight: 600; color: #fff; border: 1px solid rgba(111,207,151,.4);
  transition: background .3s;
}
.topbar .pill:hover { background: rgba(111,207,151,.32); }

/* ============ NAV ============ */
.nav {
  position: sticky; top: 0; z-index: 50;
  background: rgba(247,250,252,.88);
  backdrop-filter: blur(14px) saturate(1.1);
  -webkit-backdrop-filter: blur(14px) saturate(1.1);
  border-bottom: 1px solid var(--line);
}
.nav-inner {
  display: flex; align-items: center; justify-content: space-between;
  height: 80px; gap: 18px;
}
.brand {
  display: flex; align-items: center; gap: 12px;
  font-family: var(--serif);
  font-weight: 500; font-size: 23px; letter-spacing: -.01em;
  color: var(--ink-deep);
}
.brand .mark {
  width: 50px; height: 50px; border-radius: 50%; flex: 0 0 auto;
  overflow: hidden;
  filter: drop-shadow(0 4px 10px rgba(15,76,129,.25));
}
.brand .mark img { width: 100%; height: 100%; object-fit: cover; }
.brand small {
  display: block; font-family: var(--sans); font-size: 10.5px;
  letter-spacing: .16em; text-transform: uppercase; color: var(--muted);
  font-weight: 600; margin-top: 3px;
}
.brand .wrap { line-height: 1; }

.menu { display: flex; align-items: center; gap: 30px; }
.menu a {
  font-size: 15.5px; font-weight: 500; color: var(--ink);
  position: relative; padding: 6px 0; transition: color .2s;
}
.menu a::after {
  content: ""; position: absolute; left: 0; right: 100%; bottom: 0; height: 2px;
  background: var(--azul); transition: right .25s ease; border-radius: 2px;
}
.menu a:hover, .menu a.current { color: var(--azul); }
.menu a:hover::after, .menu a.current::after { right: 0; }

/* ============ BOTONES ============ */
.cta {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 14px 26px; border-radius: 999px;
  background: var(--azul); color: #fff;
  font-size: 15px; font-weight: 600; letter-spacing: .01em;
  transition: transform .2s ease, background .2s ease, box-shadow .2s ease;
  box-shadow: 0 6px 22px -10px rgba(15,76,129,.5);
}
.cta:hover { transform: translateY(-2px); background: var(--azul-claro); }
.cta.light { background: var(--verde); }
.cta.light:hover { background: #256F46; }
.cta.ghost { background: transparent; color: var(--ink-deep); border: 1.5px solid var(--ink-deep); box-shadow: none; }
.cta.ghost:hover { background: var(--ink-deep); color: #fff; }
.cta.on-dark { background: #fff; color: var(--ink-deep); }
.cta.on-dark:hover { background: var(--verde-suave); color: var(--ink-deep); }
.icn { width: 20px; height: 20px; stroke-width: 1.8; flex: 0 0 auto; }

/* ============ BURGER + MENÚ MÓVIL ============ */
.burger {
  display: none; width: 46px; height: 46px; border-radius: 50%;
  border: 1px solid var(--ink-deep); background: transparent; color: var(--ink-deep);
  cursor: pointer; position: relative; z-index: 52; padding: 0;
  transition: background .4s, color .4s, transform .5s cubic-bezier(.16,1,.3,1);
}
.burger:hover { transform: scale(1.05); }
.burger span {
  position: absolute; left: 50%; width: 17px; height: 1.8px; background: currentColor;
  border-radius: 2px; transform: translateX(-50%);
  transition: transform .6s cubic-bezier(.65,0,.35,1), top .35s cubic-bezier(.65,0,.35,1) .15s, width .35s cubic-bezier(.65,0,.35,1);
}
.burger span:nth-child(1) { top: calc(50% - 4px); }
.burger span:nth-child(2) { top: calc(50% + 3px); width: 11px; left: calc(50% - 5.5px); transform: none; }
.nav.menu-open .burger { background: var(--azul); border-color: var(--azul); color: #fff; }
.nav.menu-open .burger span:nth-child(1) { top: 50%; transform: translateX(-50%) rotate(45deg); transition: top .35s cubic-bezier(.65,0,.35,1), transform .6s cubic-bezier(.65,0,.35,1) .15s; }
.nav.menu-open .burger span:nth-child(2) { top: 50%; width: 17px; left: calc(50% - 8.5px); transform: rotate(-45deg); transition: top .35s cubic-bezier(.65,0,.35,1), width .35s cubic-bezier(.65,0,.35,1), transform .6s cubic-bezier(.65,0,.35,1) .15s; }

.mobile-menu {
  position: fixed; inset: 0; z-index: 45;
  background: radial-gradient(circle at 80% 18%, #164370 0%, var(--ink-deep) 65%, #0a1520 100%);
  color: #fff;
  clip-path: circle(0% at calc(100% - 44px) 43px);
  transition: clip-path .9s cubic-bezier(.65,0,.35,1);
  pointer-events: none; overflow: hidden;
}
.mobile-menu::before {
  content: ""; position: absolute; inset: 0;
  background:
    radial-gradient(circle at 12% 90%, rgba(111,207,151,.12), transparent 50%),
    radial-gradient(circle at 90% 10%, rgba(46,134,193,.18), transparent 60%);
  pointer-events: none;
}
.mobile-menu.open { clip-path: circle(160% at calc(100% - 44px) 43px); pointer-events: auto; }
.mobile-menu-inner {
  position: relative; height: 100%;
  display: flex; flex-direction: column; justify-content: space-between;
  padding: 7rem 28px 2.5rem;
}
.mobile-menu nav { display: flex; flex-direction: column; gap: .2rem; }
.mobile-menu nav a {
  display: block; font-family: var(--serif);
  font-weight: 500;
  font-size: clamp(2.1rem, 8vw, 3.6rem);
  line-height: 1.12; letter-spacing: -.02em; color: #fff;
  padding: .25rem 0; opacity: 0; transform: translateY(40px);
  transition: opacity .7s cubic-bezier(.16,1,.3,1), transform .7s cubic-bezier(.16,1,.3,1);
}
.mobile-menu nav a em { font-style: italic; color: var(--verde-suave); }
.mobile-menu nav a .idx {
  font-family: var(--sans); font-size: .7rem; letter-spacing: .22em;
  vertical-align: super; color: var(--verde-suave); margin-right: .6rem; font-weight: 600;
}
.mobile-menu.open nav a { opacity: 1; transform: translateY(0); }
.mobile-menu.open nav a:nth-child(1) { transition-delay: .35s; }
.mobile-menu.open nav a:nth-child(2) { transition-delay: .42s; }
.mobile-menu.open nav a:nth-child(3) { transition-delay: .49s; }
.mobile-menu.open nav a:nth-child(4) { transition-delay: .56s; }
.mobile-menu.open nav a:nth-child(5) { transition-delay: .63s; }
.mobile-menu.open nav a:nth-child(6) { transition-delay: .7s; }
.mobile-menu.open nav a:nth-child(7) { transition-delay: .77s; }
.mobile-menu .meta {
  display: grid; grid-template-columns: 1fr 1fr; gap: 1.4rem;
  border-top: 1px solid rgba(255,255,255,.14); padding-top: 1.6rem;
  opacity: 0; transform: translateY(20px);
  transition: opacity .7s cubic-bezier(.16,1,.3,1) .8s, transform .7s cubic-bezier(.16,1,.3,1) .8s;
}
.mobile-menu.open .meta { opacity: 1; transform: translateY(0); }
.mobile-menu .meta .label { font-size: 11px; letter-spacing: .22em; text-transform: uppercase; color: rgba(255,255,255,.6); margin-bottom: .4rem; display: block; font-weight: 600; }
.mobile-menu .meta div > span:last-child { font-family: var(--serif); font-size: 1rem; line-height: 1.4; color: #fff; }
.mobile-menu .meta em { font-style: italic; color: var(--verde-suave); }

/* ============ SECCIONES BASE ============ */
section { padding: 110px 0; position: relative; }
.section-head { max-width: 800px; margin-bottom: 64px; }
.section-head .eyebrow { margin-bottom: 18px; display: inline-flex; align-items: center; gap: 10px; }
.section-head .eyebrow::before { content: ""; width: 28px; height: 2px; background: var(--verde); display: inline-block; }
.section-head h2 {
  font-size: clamp(40px, 5vw, 64px);
  margin-bottom: 20px;
}
.section-head p { font-size: 19px; color: var(--muted); max-width: 640px; line-height: 1.7; }
.section-head.centered { margin-left: auto; margin-right: auto; text-align: center; }
.section-head.centered p { margin-left: auto; margin-right: auto; }
.section-head.centered .eyebrow::before { display: none; }

/* Cabecera de subpágina */
.page-hero {
  padding: 90px 0 70px;
  background:
    radial-gradient(55% 90% at 85% 10%, rgba(46,134,193,.1), transparent 60%),
    radial-gradient(50% 80% at 8% 90%, rgba(111,207,151,.12), transparent 55%),
    var(--fondo);
}
.page-hero .eyebrow { margin-bottom: 18px; display: inline-flex; align-items: center; gap: 10px; }
.page-hero .eyebrow::before { content: ""; width: 28px; height: 2px; background: var(--verde); }
.page-hero h1 { font-size: clamp(44px, 6vw, 84px); margin-bottom: 24px; }
.page-hero p.lead { font-size: 20px; color: var(--ink); max-width: 620px; line-height: 1.7; }
.page-hero.dark {
  background:
    radial-gradient(circle at 85% 15%, rgba(46,134,193,.22), transparent 55%),
    radial-gradient(circle at 10% 90%, rgba(46,139,87,.16), transparent 50%),
    var(--ink-deep);
  color: #fff;
}
.page-hero.dark h1 { color: #fff; }
.page-hero.dark h1 em { color: var(--verde-suave); }
.page-hero.dark p.lead { color: rgba(255,255,255,.85); }
.page-hero.dark .eyebrow { color: var(--verde-suave); }
.page-hero.dark .eyebrow::before { background: var(--verde-suave); }

.breadcrumb {
  display: flex; align-items: center; gap: 8px; width: fit-content;
  font-size: 13.5px; font-weight: 600; color: var(--muted);
  margin-bottom: 26px;
}
.breadcrumb a { color: var(--azul); transition: opacity .2s; }
.breadcrumb a:hover { opacity: .75; }
.page-hero.dark .breadcrumb { color: rgba(255,255,255,.65); }
.page-hero.dark .breadcrumb a { color: var(--verde-suave); }

/* ============ TICKER ============ */
.ticker {
  background: var(--ink-deep); color: rgba(255,255,255,.92);
  padding: 22px 0; overflow: hidden; border-top: 1px solid rgba(255,255,255,.06);
}
.ticker-track {
  display: flex; gap: 60px; white-space: nowrap;
  animation: ticker 24s linear infinite;
  font-family: var(--serif); font-size: 26px; font-style: italic;
  font-weight: 500;
}
.ticker-track span { display: inline-flex; align-items: center; gap: 60px; }
.ticker-track i { color: var(--verde-suave); font-style: normal; font-size: 14px; letter-spacing: .3em; text-transform: uppercase; }
@keyframes ticker { 0% { transform: translateX(0); } 100% { transform: translateX(-50%); } }

/* ============ STATS (números unificados) ============ */
.stats-row {
  display: flex; gap: 40px; flex-wrap: wrap; padding-top: 30px;
  border-top: 1px solid var(--line);
}
.stats-row .item { display: flex; flex-direction: column; gap: 4px; }
.stats-row .item b {
  font-family: var(--serif); font-size: 42px; font-weight: 500; font-style: normal;
  color: var(--ink-deep); line-height: 1;
}
.stats-row .item span {
  font-size: 13px; color: var(--muted); text-transform: uppercase;
  letter-spacing: .14em; font-weight: 600;
}

/* ============ UBICACIONES ============ */
#ubicaciones { background: var(--fondo-2); }
.cita-notice {
  display: flex; align-items: center; justify-content: center; gap: 12px;
  background: #fff; border: 1.5px solid var(--verde);
  border-radius: 999px; padding: 14px 28px;
  font-size: 16px; font-weight: 600; color: var(--verde-texto);
  width: fit-content; margin: 0 auto 54px;
  box-shadow: var(--shadow-card);
}
.cita-notice .icn { color: var(--verde); }
.loc-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 28px; }
.loc-card {
  background: #fff; border: 1px solid var(--line); border-radius: var(--r-lg);
  padding: 42px 40px; display: flex; flex-direction: column; gap: 0;
  transition: transform .3s, box-shadow .3s;
}
.loc-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-soft); }
.loc-card .loc-ico {
  width: 54px; height: 54px; border-radius: 16px;
  background: rgba(15,76,129,.08); color: var(--azul);
  display: grid; place-items: center; margin-bottom: 24px;
}
.loc-card .loc-ico .icn { width: 26px; height: 26px; }
.loc-card:nth-child(2) .loc-ico { background: rgba(46,139,87,.1); color: var(--verde); }
.loc-card .loc-region {
  font-size: 13px; letter-spacing: .18em; text-transform: uppercase;
  font-weight: 700; color: var(--verde-texto); margin-bottom: 8px;
}
.loc-card h3 { font-size: 30px; margin-bottom: 12px; }
.loc-card p { font-size: 17px; color: var(--muted); line-height: 1.65; margin-bottom: 26px; }
.loc-card .loc-map {
  border-radius: var(--r-md); overflow: hidden; margin-bottom: 26px;
  aspect-ratio: 16/9; border: 1px solid var(--line); background: var(--fondo-2);
}
.loc-card .loc-map iframe { width: 100%; height: 100%; border: 0; display: block; }
.loc-card .loc-actions { margin-top: auto; display: flex; gap: 12px; flex-wrap: wrap; }
.map-link {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 13px 22px; border-radius: 999px;
  border: 1.5px solid var(--azul); color: var(--azul);
  font-size: 14.5px; font-weight: 600;
  transition: background .25s, color .25s;
}
.map-link:hover { background: var(--azul); color: #fff; }
.map-link .icn { width: 17px; height: 17px; }

/* ============ CTA BAND ============ */
.cta-band {
  background:
    radial-gradient(circle at 82% 20%, rgba(46,134,193,.25), transparent 55%),
    radial-gradient(circle at 12% 85%, rgba(46,139,87,.2), transparent 50%),
    var(--ink-deep);
  color: #fff; text-align: center;
  padding: 96px 0;
}
.cta-band h2 { color: #fff; font-size: clamp(38px, 4.6vw, 60px); margin-bottom: 18px; }
.cta-band h2 em { color: var(--verde-suave); }
.cta-band p { color: rgba(255,255,255,.82); font-size: 18px; max-width: 560px; margin: 0 auto 36px; }
.cta-band .actions { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }

/* ============ FOOTER ============ */
footer {
  background: var(--ink-deep); color: rgba(255,255,255,.75); padding: 44px 0;
  border-top: 1px solid rgba(255,255,255,.08);
}
footer .row { display: flex; justify-content: space-between; gap: 20px; flex-wrap: wrap; font-size: 13.5px; align-items: center; }
footer .row .legal-center { width: 100%; text-align: center; margin-top: 18px; padding-top: 18px; border-top: 1px solid rgba(255,255,255,.08); }
footer a:hover { color: #fff; }
footer .social-links { display: flex; gap: 16px; align-items: center; }
footer .social-links a {
  width: 38px; height: 38px; border-radius: 50%;
  background: rgba(255,255,255,.08); display: grid; place-items: center;
  transition: background .3s, transform .3s;
}
footer .social-links a:hover { background: var(--azul); transform: translateY(-2px); }
footer .social-links a svg { width: 18px; height: 18px; }

/* ============ WHATSAPP FAB ============ */
.wa-float {
  position: fixed; bottom: 24px; right: 24px;
  width: 60px; height: 60px; border-radius: 50%;
  background: #25D366; display: flex; align-items: center; justify-content: center;
  z-index: 60;
  box-shadow: 0 12px 35px -10px rgba(37,211,102,.7);
  animation: waPulse 2.5s ease-in-out infinite;
  transition: transform .4s cubic-bezier(.16,1,.3,1);
}
.wa-float:hover { transform: scale(1.08); animation: none; }
.wa-float svg { width: 28px; height: 28px; fill: #fff; }
@keyframes waPulse {
  0%, 100% { box-shadow: 0 12px 35px -10px rgba(37,211,102,.7), 0 0 0 0 rgba(37,211,102,.4); }
  50% { box-shadow: 0 12px 35px -10px rgba(37,211,102,.7), 0 0 0 10px rgba(37,211,102,0); }
}

/* ============ REVEAL ============ */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity .8s ease, transform .8s ease; }
.reveal.in { opacity: 1; transform: none; }

/* ============ RESPONSIVE COMPARTIDO ============ */
@media (max-width: 1000px) {
  .loc-grid { grid-template-columns: 1fr; }
}
@media (max-width: 900px) {
  section { padding: 84px 0; }
  .page-hero { padding: 64px 0 56px; }
}
@media (max-width: 760px) {
  .menu, .nav .cta { display: none; }
  .burger { display: inline-grid; place-items: center; }
  .topbar { display: none; }
  .ticker-track { font-size: 20px; gap: 40px; }
  .ticker-track span { gap: 40px; }
  .wa-float { width: 56px; height: 56px; bottom: 18px; right: 18px; }
  .stats-row { gap: 26px; }
  .stats-row .item b { font-size: 34px; }
  .container { padding: 0 20px; }
  .loc-card { padding: 32px 26px; }
  .cita-notice { font-size: 14.5px; padding: 12px 20px; text-align: center; }
}
