/* Dr. Rómulo Barboza · Otorrinolaringólogo
   Sistema: tonos cálidos + verde azulado médico. Figtree (texto) + Source Serif 4 (titulares). */

/* Fuentes alojadas en el propio servidor (más rápido, sin terceros) */
@font-face { font-family: "Figtree"; font-style: normal; font-weight: 300 900; font-display: swap; src: url("/fonts/figtree-latin-wght-normal.woff2") format("woff2"); }
@font-face { font-family: "Source Serif 4"; font-style: normal; font-weight: 200 900; font-display: swap; src: url("/fonts/source-serif-4-latin-wght-normal.woff2") format("woff2"); }
@font-face { font-family: "Source Serif 4"; font-style: italic; font-weight: 200 900; font-display: swap; src: url("/fonts/source-serif-4-latin-wght-italic.woff2") format("woff2"); }

:root {
  --bg: #FBF8F4;
  --sand: #F3ECE3;
  --sand-2: #EADFD2;
  --surface: #FFFFFF;
  --ink: #12282B;
  --ink-2: #455A5D;
  --line: #E4DACE;

  --teal-950: #082C2F;
  --teal-900: #0B3B3F;
  --teal-700: #0F5E63;
  --teal-600: #137078;
  --teal-100: #DDECEA;
  --teal-50: #EEF6F5;

  --wa: #157A42;
  --wa-hover: #10663A;
  --clay: #B4643E;
  --danger: #B42318;
  --ok: #157A42;

  --font-sans: "Figtree", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --font-serif: "Source Serif 4", Georgia, "Times New Roman", serif;

  --r-sm: 10px;
  --r-md: 16px;
  --r-lg: 24px;
  --r-pill: 999px;

  --shadow-sm: 0 1px 2px rgb(18 40 43 / .06), 0 1px 1px rgb(18 40 43 / .04);
  --shadow-md: 0 10px 30px -12px rgb(18 40 43 / .22);
  --shadow-lg: 0 30px 60px -24px rgb(18 40 43 / .35);

  --ease: cubic-bezier(.2, .7, .2, 1);
  --header-h: 72px;
  --container: 1160px;
  --gutter: clamp(16px, 4vw, 32px);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 12px); }
body {
  margin: 0;
  font-family: var(--font-sans);
  font-size: 1.0625rem;
  line-height: 1.65;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--teal-700); text-underline-offset: 3px; }
a:hover { color: var(--teal-900); }
h1, h2, h3 { margin: 0; line-height: 1.15; color: var(--ink); }
h1, h2 { font-family: var(--font-serif); font-weight: 600; letter-spacing: -.015em; }
h2 { font-size: clamp(1.75rem, 3.2vw + .6rem, 2.6rem); }
h3 { font-size: 1.125rem; font-weight: 700; letter-spacing: -.005em; }
p { margin: 0; }
:where(ul[role="list"], ol[role="list"]) { list-style: none; margin: 0; padding: 0; }
figure { margin: 0; }

:focus-visible { outline: 3px solid var(--teal-600); outline-offset: 3px; border-radius: 6px; }

.icon {
  width: 1.25em; height: 1.25em; flex: none;
  fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round;
}

.container { width: 100%; max-width: var(--container); margin-inline: auto; padding-inline: var(--gutter); }

.skip-link {
  position: absolute; left: 12px; top: -60px; z-index: 100;
  background: var(--teal-900); color: #fff; padding: 10px 16px; border-radius: var(--r-sm);
}
.skip-link:focus { top: 12px; }

.eyebrow {
  font-size: .8125rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase;
  color: var(--teal-700); margin-bottom: 14px;
}
.eyebrow-light { color: #9FD3CF; }

/* ---------- Botones ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .55em;
  min-height: 48px; padding: 12px 22px;
  border-radius: var(--r-pill); border: 1.5px solid transparent;
  font: 600 1rem/1.2 var(--font-sans); text-decoration: none; cursor: pointer;
  transition: background-color .2s var(--ease), color .2s var(--ease), border-color .2s var(--ease), transform .15s var(--ease), box-shadow .2s var(--ease);
  touch-action: manipulation;
}
.btn:active { transform: scale(.98); }
.btn-lg { min-height: 54px; padding: 14px 26px; font-size: 1.0625rem; }
.btn-wa { background: var(--wa); color: #fff; box-shadow: 0 8px 20px -10px rgb(21 122 66 / .7); }
.btn-wa:hover { background: var(--wa-hover); color: #fff; }
.btn-primary { background: var(--teal-700); color: #fff; }
.btn-primary:hover { background: var(--teal-900); color: #fff; }
.btn-ghost { background: transparent; color: var(--ink); border-color: var(--sand-2); background: var(--surface); }
.btn-ghost:hover { border-color: var(--teal-700); color: var(--teal-900); }
.btn[disabled] { opacity: .55; cursor: progress; }

/* ---------- Encabezado ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgb(251 248 244 / .86);
  backdrop-filter: saturate(1.4) blur(12px);
  -webkit-backdrop-filter: saturate(1.4) blur(12px);
  border-bottom: 1px solid transparent;
  transition: border-color .2s var(--ease), box-shadow .2s var(--ease);
}
.site-header.is-scrolled { border-bottom-color: var(--line); box-shadow: var(--shadow-sm); }
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 24px; min-height: var(--header-h); }

.brand { display: inline-flex; align-items: center; gap: 12px; text-decoration: none; color: var(--ink); }
.brand-mark {
  display: grid; place-items: center; width: 42px; height: 42px; border-radius: 12px;
  background: var(--teal-700); color: var(--bg);
  font: 600 1.05rem/1 var(--font-serif); letter-spacing: .02em;
}
.brand-text { display: flex; flex-direction: column; line-height: 1.2; }
.brand-text strong { font-size: 1rem; font-weight: 700; }
.brand-text small { font-size: .8125rem; color: var(--ink-2); }
.brand-logo { display: block; width: 48px; height: auto; flex: none; }
.brand-footer-logo { display: inline-block; }
.brand-footer-logo img { display: block; width: min(300px, 100%); height: auto; }
.footer-phd { margin: 10px 0 0; font-size: .875rem; color: #9FBFBB; }

.site-nav { display: flex; align-items: center; gap: 28px; }
.site-nav ul { display: flex; gap: 4px; list-style: none; margin: 0; padding: 0; }
.site-nav ul a {
  display: inline-block; padding: 10px 12px; border-radius: var(--r-sm);
  color: var(--ink-2); font-weight: 500; text-decoration: none; font-size: .975rem;
  transition: color .2s var(--ease), background-color .2s var(--ease);
}
.site-nav ul a:hover { color: var(--ink); background: var(--sand); }
.nav-cta { min-height: 44px; padding: 10px 18px; font-size: .95rem; }

.menu-toggle {
  display: none; width: 48px; height: 48px; border-radius: 12px;
  border: 1px solid var(--line); background: var(--surface); color: var(--ink); cursor: pointer;
  align-items: center; justify-content: center;
}
.menu-toggle .icon-close { display: none; }
.menu-toggle[aria-expanded="true"] .icon-open { display: none; }
.menu-toggle[aria-expanded="true"] .icon-close { display: block; }

@media (max-width: 959px) {
  .menu-toggle { display: inline-flex; }
  .site-nav {
    position: fixed; inset: var(--header-h) 0 auto 0;
    flex-direction: column; align-items: stretch; gap: 16px;
    padding: 16px var(--gutter) 24px;
    background: var(--bg); border-bottom: 1px solid var(--line); box-shadow: var(--shadow-md);
    opacity: 0; transform: translateY(-8px); pointer-events: none; visibility: hidden;
    transition: opacity .2s var(--ease), transform .2s var(--ease), visibility 0s linear .2s;
  }
  .site-nav.is-open { opacity: 1; transform: none; pointer-events: auto; visibility: visible; transition-delay: 0s; }
  .site-nav ul { flex-direction: column; gap: 0; }
  .site-nav ul a { display: block; padding: 14px 8px; font-size: 1.0625rem; color: var(--ink); border-bottom: 1px solid var(--line); border-radius: 0; }
  .nav-cta { min-height: 52px; }
}

/* ---------- Hero ---------- */
.hero { position: relative; padding: clamp(32px, 6vw, 80px) 0 clamp(48px, 7vw, 96px); overflow: hidden; }
.hero::before {
  content: ""; position: absolute; inset: auto -10% -40% auto; width: 60vw; height: 60vw; max-width: 720px; max-height: 720px;
  background: radial-gradient(closest-side, rgb(15 94 99 / .10), transparent 70%); pointer-events: none;
}
.hero-grid { position: relative; display: grid; gap: clamp(36px, 5vw, 64px); align-items: center; }
.hero h1 { font-size: clamp(2.2rem, 4.6vw + .6rem, 3.9rem); line-height: 1.06; }
.hero h1 em { font-style: italic; font-weight: 500; color: var(--teal-700); }
.lead { margin-top: 22px; font-size: clamp(1.0625rem, .5vw + 1rem, 1.2rem); color: var(--ink-2); max-width: 36rem; }
.lead strong { color: var(--ink); font-weight: 600; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 30px; }
.hero-facts { display: flex; flex-wrap: wrap; gap: 10px 22px; margin-top: 26px; color: var(--ink-2); font-size: .975rem; }
.hero-facts li { display: inline-flex; align-items: center; gap: 8px; }
.hero-facts .icon { color: var(--teal-700); stroke-width: 2.4; width: 1.05em; height: 1.05em; }

.hero-photo { position: relative; justify-self: center; width: min(100%, 420px); }
.hero-photo picture img {
  width: 100%; aspect-ratio: 4 / 5; object-fit: cover;
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-lg);
  background: var(--sand-2);
}
.status-card {
  position: absolute; left: -18px; bottom: 28px; right: 24px; max-width: 330px;
  display: flex; align-items: flex-start; gap: 12px;
  padding: 14px 16px; border-radius: var(--r-md);
  background: rgb(255 255 255 / .94); box-shadow: var(--shadow-md); border: 1px solid var(--line);
  backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
}
.status-card strong { display: block; font-size: .95rem; }
.status-card small { display: block; font-size: .8125rem; color: var(--ink-2); line-height: 1.4; margin-top: 2px; }
.status-dot { width: 10px; height: 10px; margin-top: 6px; border-radius: 50%; background: var(--ink-2); flex: none; }
.status-dot.is-open { background: var(--ok); box-shadow: 0 0 0 4px rgb(21 122 66 / .18); }
.status-dot.is-closed { background: var(--clay); }

@media (min-width: 960px) {
  .hero-grid { grid-template-columns: 1.15fr .85fr; }
  .hero-photo { justify-self: end; }
}
@media (max-width: 959px) {
  .hero-photo { width: min(88%, 360px); }
  .status-card { left: -8px; right: -8px; }
}

/* ---------- Franja de confianza ---------- */
.trust { border-block: 1px solid var(--line); background: var(--surface); }
.trust-grid { display: grid; grid-template-columns: repeat(2, 1fr); }
.trust-grid > div { padding: 22px 12px; display: flex; flex-direction: column; gap: 2px; text-align: center; }
.trust-grid strong { font: 600 clamp(1.5rem, 2vw + 1rem, 2rem)/1.1 var(--font-serif); color: var(--teal-700); }
.trust-grid > div > span { font-size: .9rem; color: var(--ink-2); }
.trust-grid > div:nth-child(odd) { border-right: 1px solid var(--line); }
.trust-grid > div:nth-child(-n+2) { border-bottom: 1px solid var(--line); }
@media (min-width: 768px) {
  .trust-grid { grid-template-columns: repeat(4, 1fr); }
  .trust-grid > div { border: 0 !important; padding: 28px 12px; }
  .trust-grid > div + div { border-left: 1px solid var(--line) !important; }
}

/* ---------- Secciones ---------- */
.section { padding: clamp(64px, 9vw, 112px) 0; }
.section-sand { background: var(--sand); }
.section-teal { background: var(--teal-900); color: #E6F1F0; }
.section-head { max-width: 44rem; margin-bottom: clamp(32px, 4vw, 48px); }
.section-head > p:not(.eyebrow) { margin-top: 14px; color: var(--ink-2); font-size: 1.0625rem; }

/* Síntomas */
.symptoms { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 240px), 1fr)); gap: 12px; }
.symptoms a {
  display: flex; align-items: center; gap: 12px; min-height: 60px; padding: 14px 18px;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-md);
  color: var(--ink); font-weight: 600; text-decoration: none; line-height: 1.3;
  transition: border-color .2s var(--ease), box-shadow .2s var(--ease), transform .2s var(--ease);
}
.symptoms a .icon { color: var(--teal-700); width: 22px; height: 22px; }
.symptoms a::after {
  content: ""; margin-left: auto; width: 18px; height: 18px; flex: none; opacity: .45;
  background: currentColor;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12h14'/%3E%3Cpath d='m12 5 7 7-7 7'/%3E%3C/svg%3E") center / contain no-repeat;
          mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12h14'/%3E%3Cpath d='m12 5 7 7-7 7'/%3E%3C/svg%3E") center / contain no-repeat;
  transition: transform .2s var(--ease), opacity .2s var(--ease);
}
.symptoms a:hover { border-color: var(--teal-700); box-shadow: var(--shadow-md); color: var(--ink); }
.symptoms a:hover::after { transform: translateX(3px); opacity: 1; color: var(--teal-700); }

/* Especialidades */
.cards { display: grid; gap: 16px; grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr)); }
.card {
  background: var(--surface); border-radius: var(--r-lg); padding: 28px;
  border: 1px solid var(--line);
}
.card-icon {
  display: grid; place-items: center; width: 52px; height: 52px; border-radius: 14px;
  background: var(--teal-50); color: var(--teal-700); margin-bottom: 20px;
}
.card-icon .icon { width: 26px; height: 26px; }
.card h3 { font-size: 1.25rem; margin-bottom: 8px; }
.card p { color: var(--ink-2); font-size: 1rem; }

/* Procedimientos */
.split { display: grid; gap: clamp(36px, 5vw, 72px); align-items: center; }
.split-media img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; border-radius: var(--r-lg); box-shadow: var(--shadow-md); }
.split h2 { margin-bottom: 28px; }
.steps-list { list-style: none; margin: 0; padding: 0; counter-reset: step; }
.steps-list li { position: relative; padding: 20px 0 20px 64px; border-top: 1px solid var(--line); counter-increment: step; }
.steps-list li:last-child { border-bottom: 1px solid var(--line); }
.steps-list li::before {
  content: counter(step, decimal-leading-zero); position: absolute; left: 0; top: 20px;
  font: 600 1.5rem/1 var(--font-serif); color: var(--clay);
}
.steps-list h3 { margin-bottom: 6px; }
.steps-list p { color: var(--ink-2); font-size: 1rem; }
@media (min-width: 960px) {
  .split { grid-template-columns: .9fr 1.1fr; }
}
@media (max-width: 959px) {
  .split-media img { aspect-ratio: 3 / 2; }
}

/* Doctor */
.doctor { display: grid; gap: 32px; }
.section-teal h2 { color: #fff; font-size: clamp(2rem, 3.6vw + .5rem, 3rem); }
.doctor-role { margin-top: 10px; color: #A9CFCB; }
.doctor-body > p { color: #CFE3E1; }
.doctor blockquote { margin: 0 0 28px; padding: 0; }
.doctor blockquote p {
  font: italic 500 clamp(1.35rem, 1.6vw + .9rem, 1.85rem)/1.35 var(--font-serif); color: #fff;
}
.doctor-points { display: grid; gap: 10px; margin-top: 28px; }
.doctor-points li { display: flex; gap: 10px; align-items: center; color: #fff; font-weight: 500; }
.doctor-points .icon { color: #7FC7C0; stroke-width: 2.4; }
.social-links { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 32px; }
.social-links .ig-link { flex: 1 1 200px; max-width: 280px; }
.ig-link {
  display: inline-flex; align-items: center; gap: 14px;
  padding: 14px 20px 14px 16px; border-radius: var(--r-md);
  border: 1px solid rgb(255 255 255 / .18); background: rgb(255 255 255 / .06);
  color: #fff; text-decoration: none;
  transition: background-color .2s var(--ease), border-color .2s var(--ease);
}
.ig-link:hover { background: rgb(255 255 255 / .12); border-color: rgb(255 255 255 / .35); color: #fff; }
.ig-link .icon { width: 28px; height: 28px; color: #7FC7C0; }
.ig-link strong { display: block; font-weight: 700; }
.ig-link small { display: block; font-size: .875rem; color: #A9CFCB; }
.footer-ig { display: inline-flex; align-items: center; gap: 8px; }
@media (min-width: 960px) {
  .doctor { grid-template-columns: .8fr 1.2fr; gap: 72px; }
}

/* Cómo agendar */
.how { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr)); counter-reset: none; }
.how li { padding: 28px; border-radius: var(--r-lg); background: var(--surface); border: 1px solid var(--line); }
.how-n {
  display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%;
  background: var(--teal-700); color: #fff; font: 600 1.1rem/1 var(--font-serif); margin-bottom: 18px;
}
.how h3 { margin-bottom: 6px; }
.how p { color: var(--ink-2); font-size: 1rem; }

/* Ubicación */
.location { display: grid; gap: 40px; align-items: stretch; }
.info-list { display: grid; gap: 14px; margin: 24px 0 28px; }
.info-list li { display: flex; gap: 12px; align-items: flex-start; }
.info-list .icon { color: var(--teal-700); margin-top: 3px; }
.info-list a { color: var(--ink); font-weight: 600; text-decoration-color: var(--sand-2); }
.hours { width: 100%; border-collapse: collapse; margin-bottom: 28px; background: var(--surface); border-radius: var(--r-md); overflow: hidden; border: 1px solid var(--line); }
.hours caption { display: flex; align-items: center; gap: 8px; text-align: left; font-weight: 700; padding-bottom: 10px; }
.hours caption .icon { color: var(--teal-700); }
.hours th, .hours td { padding: 11px 16px; text-align: left; font-size: .975rem; border-top: 1px solid var(--line); }
.hours tr:first-child th, .hours tr:first-child td { border-top: 0; }
.hours th { font-weight: 500; }
.hours td { text-align: right; font-variant-numeric: tabular-nums; }
.hours td.closed { color: var(--ink-2); }
.hours tr.is-today { background: var(--teal-50); }
.hours tr.is-today th { font-weight: 700; }
.hours tr.is-today th::after { content: " · hoy"; color: var(--teal-700); font-weight: 600; font-size: .85em; }
.map { min-height: 360px; border-radius: var(--r-lg); overflow: hidden; border: 1px solid var(--line); background: var(--sand-2); box-shadow: var(--shadow-md); }
.map iframe { width: 100%; height: 100%; min-height: 360px; border: 0; display: block; }
@media (min-width: 960px) {
  .location { grid-template-columns: .9fr 1.1fr; gap: 56px; }
}

/* Formulario */
.appointment { display: grid; gap: 40px; }
.appointment-intro > p:not(.eyebrow) { color: var(--ink-2); margin-top: 14px; }
.appointment-direct { margin-top: 24px; }
.appointment-direct a { display: inline-flex; align-items: center; gap: 10px; font-weight: 600; min-height: 44px; }
.note { margin-top: 24px; font-size: .9rem; padding: 14px 16px; border-radius: var(--r-sm); background: var(--sand); color: var(--ink-2) !important; }

.form {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg);
  padding: clamp(22px, 3vw, 36px); box-shadow: var(--shadow-md);
  display: grid; gap: 18px;
}
.field { display: grid; gap: 6px; }
.field-row { display: grid; gap: 18px; }
@media (min-width: 640px) { .field-row { grid-template-columns: 1fr 1fr; } }
.field label { font-weight: 600; font-size: .95rem; }
.field label span[aria-hidden] { color: var(--clay); }
.optional { font-weight: 400; color: var(--ink-2); }
.field input, .field select, .field textarea {
  width: 100%; min-height: 50px; padding: 12px 14px;
  font: 400 1rem/1.4 var(--font-sans); color: var(--ink);
  background: var(--bg); border: 1.5px solid var(--line); border-radius: var(--r-sm);
  transition: border-color .2s var(--ease), box-shadow .2s var(--ease), background-color .2s var(--ease);
  appearance: none;
}
.field select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23455A5D' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 14px center; background-size: 18px; padding-right: 44px;
}
.field textarea { resize: vertical; min-height: 110px; }
.field input::placeholder, .field textarea::placeholder { color: #8A9799; }
.field input:focus, .field select:focus, .field textarea:focus {
  outline: none; border-color: var(--teal-600); background: #fff; box-shadow: 0 0 0 4px rgb(19 112 120 / .15);
}
.field.has-error input, .field.has-error select { border-color: var(--danger); }
.field-error { color: var(--danger); font-size: .875rem; min-height: 0; }
.field-error:empty { display: none; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.form-actions { display: grid; gap: 10px; margin-top: 4px; }
@media (min-width: 640px) { .form-actions { grid-template-columns: 1.2fr 1fr; } }
.form-status { font-weight: 600; font-size: .95rem; }
.form-status:empty { display: none; }
.form-status.is-ok { color: var(--ok); }
.form-status.is-error { color: var(--danger); }
.form-privacy { font-size: .85rem; color: var(--ink-2); }
@media (min-width: 960px) {
  .appointment { grid-template-columns: .85fr 1.15fr; gap: 72px; align-items: start; }
  .appointment-intro { position: sticky; top: calc(var(--header-h) + 32px); }
}

/* FAQ */
.faq-wrap { max-width: 860px; }
.faq { display: grid; gap: 10px; }
.faq details { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-md); }
.faq summary {
  display: flex; justify-content: space-between; align-items: center; gap: 16px;
  min-height: 60px; padding: 16px 20px; cursor: pointer; font-weight: 600; list-style: none;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: ""; width: 20px; height: 20px; flex: none; background: var(--teal-700);
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='M12 5v14M5 12h14'/%3E%3C/svg%3E") center / contain no-repeat;
          mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='M12 5v14M5 12h14'/%3E%3C/svg%3E") center / contain no-repeat;
  transition: transform .25s var(--ease);
}
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p { padding: 0 20px 20px; color: var(--ink-2); }

/* Footer */
.site-footer { background: var(--teal-950); color: #B9D2CF; padding: 64px 0 0; }
.site-footer a { color: #E6F1F0; text-decoration: none; }
.site-footer a:hover { text-decoration: underline; color: #fff; }
.footer-grid { display: grid; gap: 36px; padding-bottom: 40px; }
.footer-grid p { margin-top: 18px; max-width: 26rem; font-size: .975rem; }
.footer-grid ul { display: grid; gap: 8px; font-size: .975rem; }
.footer-title { font: 700 .8125rem/1 var(--font-sans); letter-spacing: .12em; text-transform: uppercase; color: #7FC7C0; margin-bottom: 16px; }
.brand-footer { color: #fff; }
.brand-footer .brand-text small { color: #9FBFBB; }
.brand-footer .brand-mark { background: var(--bg); color: var(--teal-900); }
.footer-bottom { border-top: 1px solid rgb(255 255 255 / .1); padding-block: 22px; font-size: .875rem; color: #8FB0AC; }
@media (min-width: 768px) { .footer-grid { grid-template-columns: 1.4fr 1fr 1fr; } }

/* Barra fija móvil */
.mobile-bar { display: none; }
@media (max-width: 767px) {
  body { padding-bottom: calc(76px + env(safe-area-inset-bottom)); }
  .mobile-bar {
    display: grid; grid-template-columns: 1fr 1.3fr 52px; gap: 8px;
    position: fixed; inset: auto 0 0 0; z-index: 40;
    padding: 10px var(--gutter) calc(10px + env(safe-area-inset-bottom));
    background: rgb(251 248 244 / .95); border-top: 1px solid var(--line);
    backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  }
  .mobile-bar .btn { min-height: 52px; }
  .nav-cta { display: none; }
  .hero-actions .btn { flex: 1 1 100%; }
}

.btn-icon { padding: 0; width: 52px; }
.btn-block { width: 100%; }
.btn-urgent { background: var(--danger); color: #fff; box-shadow: 0 8px 20px -10px rgb(180 35 24 / .7); }
.btn-urgent:hover { background: #8F1C13; color: #fff; }
.link-btn {
  background: none; border: 0; padding: 10px 0; min-height: 44px; cursor: pointer;
  font: 600 .975rem/1.2 var(--font-sans); color: var(--teal-700); text-decoration: underline; text-underline-offset: 3px;
}
.link-btn:hover { color: var(--teal-900); }

/* Enlace de urgencias en el menú */
.nav-urgent { display: inline-flex !important; align-items: center; gap: 8px; color: var(--danger) !important; font-weight: 600 !important; }
.urgent-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--danger); box-shadow: 0 0 0 3px rgb(180 35 24 / .18); }

/* ---------- Guía de síntomas ---------- */
.symptom-groups { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(min(100%, 250px), 1fr)); }
.symptom-group { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 22px; }
.symptom-group h3 { display: flex; align-items: center; gap: 10px; font-size: 1.0625rem; margin-bottom: 12px; }
.sg-icon { display: grid; place-items: center; width: 38px; height: 38px; border-radius: 11px; background: var(--teal-50); color: var(--teal-700); }
.symptom-group ul { display: grid; gap: 6px; }
.symptom-group button {
  width: 100%; display: flex; align-items: center; justify-content: space-between; gap: 10px;
  min-height: 48px; padding: 10px 14px; text-align: left; cursor: pointer;
  background: var(--bg); border: 1px solid transparent; border-radius: var(--r-sm);
  font: 600 .975rem/1.3 var(--font-sans); color: var(--ink);
  transition: border-color .2s var(--ease), background-color .2s var(--ease);
}
.symptom-group button::after {
  content: ""; width: 16px; height: 16px; flex: none; background: var(--teal-700); opacity: .55;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m9 18 6-6-6-6'/%3E%3C/svg%3E") center / contain no-repeat;
          mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m9 18 6-6-6-6'/%3E%3C/svg%3E") center / contain no-repeat;
  transition: transform .2s var(--ease), opacity .2s var(--ease);
}
.symptom-group button:hover { border-color: var(--teal-700); background: var(--teal-50); }
.symptom-group button:hover::after { transform: translateX(2px); opacity: 1; }
.guides-disclaimer { margin-top: 18px; font-size: .9rem; color: var(--ink-2); }

/* Ventana de guía */
.guide-dialog {
  width: min(680px, calc(100% - 32px)); max-height: min(86vh, 860px); padding: 0;
  border: 0; border-radius: var(--r-lg); background: var(--surface); color: var(--ink);
  box-shadow: var(--shadow-lg); overflow: hidden;
}
.guide-dialog[open] { display: flex; flex-direction: column; animation: dlg-in .22s var(--ease); }
.guide-dialog::backdrop { background: rgb(8 44 47 / .55); }
@keyframes dlg-in { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }
.gd-head { display: flex; align-items: center; justify-content: space-between; padding: 18px 20px 0 24px; }
.gd-head .eyebrow { margin: 0; }
.gd-close { width: 44px; height: 44px; display: grid; place-items: center; border-radius: 12px; border: 1px solid var(--line); background: var(--surface); color: var(--ink); cursor: pointer; }
.gd-close:hover { background: var(--sand); }
.gd-body { padding: 8px 24px 8px; overflow-y: auto; }
.gd-body h3 { font: 600 clamp(1.5rem, 2vw + 1rem, 1.9rem)/1.15 var(--font-serif); margin-bottom: 12px; }
.gd-body > .guide > p:first-of-type { color: var(--ink-2); }
.guide-cols { display: grid; gap: 14px; margin: 20px 0; }
@media (min-width: 560px) { .guide-cols { grid-template-columns: 1fr 1fr; } }
.guide-cols > div { background: var(--bg); border-radius: var(--r-md); padding: 16px 18px; }
.guide-cols h4 { margin: 0 0 8px; font-size: .8125rem; letter-spacing: .1em; text-transform: uppercase; color: var(--teal-700); }
.guide-cols ul { margin: 0; padding-left: 1.1em; display: grid; gap: 4px; font-size: .975rem; }
.guide-alert, .guide-tip { margin: 0 0 8px; padding: 14px 16px; border-radius: var(--r-md); font-size: .975rem; border-left: 4px solid; }
.guide-alert { background: #FFF6E8; border-color: #C9862A; }
.guide-alert-red { background: #FDF0EE; border-color: var(--danger); }
.guide-tip { background: var(--teal-50); border-color: var(--teal-700); }
.gd-actions { display: flex; flex-wrap: wrap; gap: 10px; padding: 16px 24px 22px; border-top: 1px solid var(--line); background: var(--surface); }
.gd-actions .btn { flex: 1 1 220px; }
@media (max-width: 559px) {
  .guide-dialog { width: 100%; max-width: 100%; max-height: 92dvh; margin: auto 0 0; border-radius: var(--r-lg) var(--r-lg) 0 0; }
  .gd-actions { padding-bottom: calc(18px + env(safe-area-inset-bottom)); }
}

/* ---------- Urgencias ---------- */
.section-urgent { background: #FBF1EE; border-block: 1px solid #F0D5CF; }
.eyebrow-urgent { display: inline-flex; align-items: center; gap: 8px; color: var(--danger); }
.urgent-head { display: grid; gap: 24px; align-items: end; margin-bottom: 32px; }
.urgent-head > div > p:not(.eyebrow) { margin-top: 12px; color: var(--ink-2); font-size: 1.0625rem; max-width: 40rem; }
.urgent-actions { display: flex; flex-wrap: wrap; gap: 12px; }
@media (min-width: 960px) { .urgent-head { grid-template-columns: 1.3fr auto; } }
.urgent-grid { display: grid; gap: 16px; }
@media (min-width: 860px) { .urgent-card ul { grid-template-columns: 1fr 1fr; column-gap: 40px; } }
.urgent-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 26px; }
.urgent-card-red { border: 2px solid var(--danger); }
.urgent-card h3 { margin-bottom: 14px; }
.urgent-card-red h3 { color: var(--danger); }
.urgent-card ul { margin: 0; padding-left: 1.15em; display: grid; gap: 8px; color: var(--ink); }
.urgent-911 { display: inline-flex; align-items: center; gap: 8px; margin-top: 18px; min-height: 44px; font-weight: 700; color: var(--danger); }

/* ---------- Especialidades (8) ---------- */
.cards-4 { grid-template-columns: repeat(auto-fill, minmax(min(100%, 250px), 1fr)); }

/* ---------- Doctor ---------- */
.doctor-badges { display: grid; gap: 12px; margin-top: 28px; }
.doctor-badges li { display: flex; gap: 12px; align-items: flex-start; color: #DCEBEA; font-size: .975rem; }
.doctor-badges .icon { color: #7FC7C0; margin-top: 2px; }

/* ---------- Trayectoria ---------- */
.career { display: grid; gap: 48px; }
@media (min-width: 960px) { .career { grid-template-columns: 1.1fr .9fr; gap: 64px; } }
.career h2 { margin-bottom: 28px; }
.timeline { position: relative; display: grid; gap: 0; }
.timeline li { position: relative; display: grid; grid-template-columns: 112px 1fr; gap: 16px; padding: 0 0 26px; }
.timeline li::before { content: ""; position: absolute; left: 119px; top: 8px; bottom: -8px; width: 2px; background: var(--line); }
.timeline li:last-child::before { display: none; }
.timeline li > div { position: relative; padding-left: 22px; }
.timeline li > div::before { content: ""; position: absolute; left: -2px; top: 7px; width: 12px; height: 12px; border-radius: 50%; background: var(--surface); border: 3px solid var(--teal-700); }
.tl-year { font: 600 .95rem/1.4 var(--font-sans); color: var(--clay); font-variant-numeric: tabular-nums; padding-top: 2px; }
.timeline h3 { font-size: 1.0625rem; margin-bottom: 4px; }
.timeline p { color: var(--ink-2); font-size: .975rem; }
@media (max-width: 559px) {
  .timeline li { grid-template-columns: 1fr; gap: 2px; padding-left: 22px; }
  .timeline li::before { left: 5px; }
  .timeline li > div { padding-left: 0; }
  .timeline li > div::before { left: -22px; top: -18px; }
}
.career-side { display: grid; gap: 16px; align-content: start; }
.side-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 24px; }
.side-card h3 { display: flex; align-items: center; gap: 10px; margin-bottom: 16px; }
.side-card h3 .icon { color: var(--teal-700); }
.pubs { display: grid; gap: 16px; }
.pubs a { font-weight: 600; color: var(--ink); text-decoration: none; line-height: 1.4; }
.pubs a .icon { width: 1em; height: 1em; color: var(--teal-700); vertical-align: -2px; }
.pubs a:hover { color: var(--teal-700); text-decoration: underline; }
.pubs span { display: block; margin-top: 4px; font-size: .875rem; color: var(--ink-2); line-height: 1.5; overflow-wrap: anywhere; }
.orcid { display: inline-block; margin-top: 16px; font-size: .9rem; font-weight: 600; min-height: 24px; }
.checks { display: grid; gap: 10px; }
.checks li { position: relative; padding-left: 26px; font-size: .975rem; }
.checks li::before {
  content: ""; position: absolute; left: 0; top: 4px; width: 16px; height: 16px; background: var(--teal-700);
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 6 9 17l-5-5'/%3E%3C/svg%3E") center / contain no-repeat;
          mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 6 9 17l-5-5'/%3E%3C/svg%3E") center / contain no-repeat;
}
.courses { margin-top: 18px; border-top: 1px solid var(--line); padding-top: 6px; }
.courses summary { cursor: pointer; min-height: 44px; display: flex; align-items: center; font-weight: 600; color: var(--teal-700); }
.courses ul { display: grid; gap: 8px; padding-top: 6px; font-size: .925rem; color: var(--ink-2); }
.courses strong { color: var(--ink); font-variant-numeric: tabular-nums; }

/* ---------- Reserva ---------- */
.how-mini { display: grid; gap: 10px; margin-top: 22px; }
.how-mini li { display: flex; align-items: center; gap: 12px; font-weight: 600; }
.how-mini span { display: grid; place-items: center; width: 30px; height: 30px; border-radius: 50%; background: var(--teal-700); color: #fff; font-size: .875rem; }
.appointment-direct { display: grid; gap: 4px; }
.note { display: block; background: var(--surface); }
.note .icon { color: var(--danger); vertical-align: -4px; margin-right: 6px; }

.booking { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); padding: clamp(20px, 3vw, 32px); box-shadow: var(--shadow-md); display: grid; gap: 26px; }
.booking .form { background: none; border: 0; box-shadow: none; padding: 0; }
.booking-block { display: grid; gap: 14px; }
.booking-block[hidden] { display: none; }
.booking-label { display: flex; align-items: center; gap: 10px; font-weight: 700; font-size: 1.0625rem; }
.bl-n { display: grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; background: var(--teal-50); color: var(--teal-700); font-size: .875rem; flex: none; }
.booking-loading { color: var(--ink-2); }
.days { display: grid; gap: 8px; grid-template-columns: repeat(auto-fill, minmax(78px, 1fr)); }
.day-btn, .slot-btn {
  border: 1.5px solid var(--line); background: var(--bg); color: var(--ink); border-radius: var(--r-md);
  cursor: pointer; font-family: var(--font-sans); transition: border-color .15s var(--ease), background-color .15s var(--ease), color .15s var(--ease);
}
.day-btn { display: grid; gap: 1px; justify-items: center; padding: 10px 4px; min-height: 82px; }
.day-btn .d-wd { font-size: .8125rem; text-transform: uppercase; letter-spacing: .06em; color: var(--ink-2); }
.day-btn .d-num { font: 600 1.4rem/1.1 var(--font-serif); }
.day-btn .d-mon { font-size: .8125rem; color: var(--ink-2); }
.day-btn .d-free { font-size: .75rem; color: var(--teal-700); font-weight: 600; margin-top: 2px; }
.day-btn:hover:not(:disabled), .slot-btn:hover:not(:disabled) { border-color: var(--teal-700); }
.day-btn[aria-pressed="true"], .slot-btn[aria-pressed="true"] { background: var(--teal-700); border-color: var(--teal-700); color: #fff; }
.day-btn[aria-pressed="true"] .d-wd, .day-btn[aria-pressed="true"] .d-mon, .day-btn[aria-pressed="true"] .d-free { color: #D5ECEA; }
.day-btn:disabled { opacity: .5; cursor: not-allowed; }
.day-btn:disabled .d-free { color: var(--ink-2); }
.slots { display: grid; gap: 8px; grid-template-columns: repeat(auto-fill, minmax(88px, 1fr)); }
.slot-btn { min-height: 48px; font-weight: 600; font-size: 1rem; font-variant-numeric: tabular-nums; }
.booking-summary { padding: 12px 14px; border-radius: var(--r-sm); background: var(--teal-50); color: var(--teal-900); font-weight: 600; }
.booking-done { text-align: center; display: grid; gap: 10px; justify-items: center; padding: 8px 0; }
.booking-done[hidden], .booking-error[hidden] { display: none; }
.booking-done:focus { outline: none; }
.done-icon { display: grid; place-items: center; width: 64px; height: 64px; border-radius: 50%; background: #E3F3E9; color: var(--ok); }
.done-icon .icon { width: 32px; height: 32px; stroke-width: 2.6; }
.booking-done h3 { font: 600 1.6rem/1.2 var(--font-serif); }
.done-when { font-size: 1.125rem; font-weight: 600; color: var(--teal-900); }
.done-note { color: var(--ink-2); max-width: 30rem; }
.done-actions { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; margin-top: 6px; }
.booking-error { display: grid; gap: 14px; justify-items: start; }

.consent { display: flex; gap: 10px; align-items: flex-start; font-size: .925rem; color: var(--ink-2); font-weight: 400 !important; cursor: pointer; }
.field .consent input { width: 22px; height: 22px; min-height: 22px; padding: 0; margin-top: 1px; appearance: auto; accent-color: var(--teal-700); flex: none; }
.footer-bottom a { color: #CFE3E1; text-decoration: underline; text-underline-offset: 3px; }
.legal { max-width: 760px; }
.legal h1 { font-family: var(--font-serif); font-size: clamp(2rem, 3vw + 1rem, 2.6rem); margin-bottom: 8px; }
.legal h2 { font-size: 1.25rem; margin: 28px 0 8px; font-family: var(--font-sans); font-weight: 700; }
.legal p, .legal li { color: var(--ink-2); }
.legal ul { padding-left: 1.2em; display: grid; gap: 6px; }

.verify-form { margin: 20px 0; display: grid; gap: 8px; }
.verify-form label { font-weight: 600; }
.verify-row { display: flex; gap: 10px; flex-wrap: wrap; }
.verify-row input { flex: 1 1 200px; min-height: 50px; padding: 12px 14px; font: 600 1.05rem var(--font-sans); letter-spacing: .06em; border: 1.5px solid var(--line); border-radius: var(--r-sm); background: var(--surface); }
.verify-box { padding: 18px 20px; border-radius: var(--r-md); border-left: 6px solid; background: var(--surface); }
.verify-box strong { display: block; font-size: 1.25rem; margin-bottom: 4px; }
.verify-box p { margin: 0; color: var(--ink-2); }
.verify-box.is-valid { border-color: var(--ok); }
.verify-box.is-valid strong { color: var(--ok); }
.verify-box.is-void { border-color: var(--danger); background: #FDF0EE; }
.verify-box.is-void strong { color: var(--danger); }
.verify-box.is-unknown { border-color: var(--sand-2); }

/* Aparición suave al hacer scroll */
.reveal { opacity: 0; transform: translateY(14px); transition: opacity .6s var(--ease), transform .6s var(--ease); }
.reveal.is-visible { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: .01ms !important; animation-duration: .01ms !important; }
  .reveal { opacity: 1; transform: none; }
}

.sprite { position: absolute; width: 0; height: 0; overflow: hidden; }

[tabindex="-1"]:focus { outline: none; }

/* Marca del proveedor del sistema */
.powered { margin: 6px 0 0; font-size: .8125rem; }
.footer-bottom .powered { color: #7FA29E; }
.footer-bottom .powered a { color: #B9D2CF; }
.powered-bar { padding: 28px 16px 36px; text-align: center; color: var(--ink-2); }
.powered-bar a { color: inherit; text-underline-offset: 3px; }
