/* ROK · Red Global de Odontopediatría Infantil
   Paleta del logo: verde salvia + azul grisáceo. Tipografía: Montserrat (texto) + Poppins (etiquetas en mayúsculas). */

:root {
  --sage: #8BBF9F;
  --sage-600: #4E8F6B;
  --sage-700: #3F7D5C;
  --sage-800: #336A4C;
  --sage-100: #E6F1EA;
  --sage-50: #F1F7F3;
  --slate: #6A8CA6;
  --slate-300: #8FAFC2;
  --slate-100: #E4ECF2;
  --beige: #F6F1E9;
  --beige-200: #EDE5D8;
  --ink: #2C3A34;
  --muted: #5E6C66;
  --line: #E2DDD2;
  --white: #fff;
  --radius: 20px;
  --radius-sm: 12px;
  --shadow: 0 10px 30px -12px rgba(44, 58, 52, .18);
  --font: 'Montserrat', 'Inter', 'Segoe UI', system-ui, -apple-system, sans-serif;
  --font-label: 'Poppins', 'Montserrat', 'Segoe UI', system-ui, -apple-system, sans-serif;
  --header-h: 76px;
  --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
  --ease-io: cubic-bezier(0.77, 0, 0.175, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font);
  font-size: 1.0625rem;
  line-height: 1.7;
  color: var(--ink);
  background: var(--white);
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--sage-700); text-underline-offset: 3px; }
a:hover { color: var(--sage-800); }
h1, h2, h3 { font-weight: 600; line-height: 1.2; letter-spacing: -.01em; margin: 0 0 .6em; color: var(--ink); }
h1 { font-size: clamp(2rem, 4.4vw, 3.2rem); }
h2 { font-size: clamp(1.6rem, 3vw, 2.25rem); }
h3 { font-size: 1.15rem; }
p { margin: 0 0 1em; }
ul, ol { margin: 0; padding: 0; list-style: none; }
:focus-visible { outline: 3px solid var(--slate); outline-offset: 3px; border-radius: 6px; }

.container { width: min(100% - 32px, 1160px); margin-inline: auto; }
.narrow { max-width: 760px; }
.center { text-align: center; margin-inline: auto; }
.muted { color: var(--muted); }
.hp { position: absolute; left: -9999px; opacity: 0; height: 0; width: 0; }

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

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255, 255, 255, .92);
  -webkit-backdrop-filter: saturate(1.4) blur(12px); backdrop-filter: saturate(1.4) blur(12px);
  border-bottom: 1px solid var(--line);
}
.header-inner { display: flex; align-items: center; justify-content: space-between; min-height: var(--header-h); gap: 24px; }
.brand img { height: 52px; width: auto; }
.site-nav { display: flex; align-items: center; gap: 28px; }
.site-nav ul { display: flex; gap: 6px; }
.site-nav ul a {
  display: block; padding: 8px 14px; border-radius: 999px;
  color: var(--ink); text-decoration: none; font-weight: 500; font-size: .95rem;
  transition: background .2s, color .2s;
}
.site-nav ul a[aria-current="page"] { background: var(--sage-100); color: var(--sage-800); font-weight: 600; }
.nav-actions { display: flex; align-items: center; gap: 14px; }
.lang-switch { display: inline-flex; border: 1px solid var(--line); border-radius: 999px; padding: 3px; }
.lang-switch button {
  font: 600 .78rem var(--font); letter-spacing: .04em; border: 0; background: transparent; color: var(--muted);
  padding: 5px 11px; border-radius: 999px; cursor: pointer;
}
.lang-switch button[aria-pressed="true"] { background: var(--sage-700); color: #fff; }
.nav-toggle { display: none; background: none; border: 0; padding: 10px; cursor: pointer; }
.nav-toggle span { display: block; width: 24px; height: 2px; background: var(--ink); margin: 5px 0; border-radius: 2px; transition: transform 200ms var(--ease-io), opacity 200ms ease; }
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font: 600 .98rem var(--font); text-decoration: none; cursor: pointer;
  padding: 14px 28px; border-radius: 999px; border: 2px solid transparent;
  transition: transform 160ms var(--ease-out), background-color 160ms ease, color 160ms ease, border-color 160ms ease;
}
.btn-sm { padding: 9px 20px; font-size: .9rem; }
.btn-primary { background: var(--sage-700); color: #fff; box-shadow: 0 8px 20px -10px var(--sage-700); }
.btn-ghost { border-color: var(--sage-700); color: var(--sage-800); background: transparent; }
.btn-light { background: #fff; color: var(--sage-800); }
.btn-outline-light { border-color: #fff; color: #fff; }
.btn-row { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 28px; }
.btn-row.center { justify-content: center; }

/* ---------- Layout blocks ---------- */
.section { padding: clamp(56px, 8vw, 104px) 0; }
.tint { background: var(--beige); }
.section-head { max-width: 680px; margin: 0 auto 48px; }
.eyebrow { font-family: var(--font-label); font-size: .8rem; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: var(--sage-700); margin-bottom: 14px; }
.lead { font-size: 1.15rem; color: var(--muted); }

.hero { padding: clamp(40px, 6vw, 88px) 0 clamp(48px, 7vw, 96px); background:
  radial-gradient(1200px 500px at 85% -10%, var(--slate-100), transparent 60%),
  linear-gradient(180deg, var(--sage-50), #fff); overflow: hidden; }
.hero-grid { display: grid; grid-template-columns: 1.1fr .9fr; gap: clamp(32px, 6vw, 80px); align-items: center; }
.hero-copy h1 { margin-bottom: .5em; }
.hero-visual { position: relative; max-width: 440px; margin-inline: auto; width: 100%; }
.arch { border-radius: 999px 999px 28px 28px; overflow: hidden; aspect-ratio: 4 / 5.2; box-shadow: var(--shadow); border: 8px solid #fff; background: var(--sage-100); }
.arch img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 30%; }
.chip {
  position: absolute; display: inline-flex; align-items: center; gap: 10px;
  background: #fff; border-radius: 999px; padding: 10px 18px 10px 12px;
  font-size: .85rem; font-weight: 600; color: var(--ink); box-shadow: var(--shadow);
}
.chip svg { width: 28px; height: 28px; padding: 5px; border-radius: 50%; background: var(--sage-100); color: var(--sage-700); flex: none; }
.chip-a { left: -28px; top: 22%; }
.chip-b { right: -20px; bottom: 12%; }
.chip-b svg { background: var(--slate-100); color: var(--slate); }

.intro { padding-block: clamp(40px, 6vw, 72px); }
.statement { font-size: clamp(1.3rem, 2.6vw, 1.85rem); line-height: 1.45; font-weight: 500; color: var(--sage-800); margin: 0; }

.split { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(32px, 6vw, 80px); align-items: center; }
.split-media img { border-radius: var(--radius); box-shadow: var(--shadow); width: 100%; object-fit: cover; }
.how .split-media img { aspect-ratio: 4 / 5; border-radius: 200px 200px var(--radius) var(--radius); }
.split-body h2 { margin-bottom: .5em; }
.split-body h3 { margin-top: 1.4em; color: var(--sage-800); }

.steps { margin: 28px 0 32px; display: grid; gap: 18px; counter-reset: s; }
.steps li { display: flex; gap: 16px; align-items: flex-start; }
.steps h3 { margin: 0 0 4px; font-size: 1.05rem; }
.steps p { margin: 0; color: var(--muted); font-size: .98rem; }
.step-icon { flex: none; width: 48px; height: 48px; border-radius: 50%; display: grid; place-items: center; background: var(--sage-100); color: var(--sage-700); }
.step-icon svg, .card-icon svg { width: 24px; height: 24px; }
.steps li:nth-child(2) .step-icon { background: var(--slate-100); color: var(--slate); }

.cta-band {
  position: relative; padding: clamp(64px, 9vw, 112px) 0; color: #fff; text-align: center;
  background: var(--sage-800) center / cover no-repeat;
}
.cta-band h2 { color: #fff; }
.cta-band p { color: rgba(255, 255, 255, .92); font-size: 1.1rem; }

.page-hero { padding: clamp(48px, 7vw, 96px) 0 clamp(36px, 5vw, 64px); background:
  radial-gradient(900px 380px at 50% -20%, var(--slate-100), transparent 70%), linear-gradient(180deg, var(--sage-50), #fff); }
.page-hero .lead { margin-bottom: 0; }

/* ---------- Cards ---------- */
.card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 28px; }
.card h3, .card h2 { margin-bottom: .45em; }
.card p { color: var(--muted); margin: 0; font-size: .98rem; }
.card-icon { width: 52px; height: 52px; border-radius: 16px; display: grid; place-items: center; background: var(--sage-100); color: var(--sage-700); margin-bottom: 18px; }
.two-col, .grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 24px; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.grid-4 .card:nth-child(even) .card-icon { background: var(--slate-100); color: var(--slate); }
.card-feature { padding: 36px; background: linear-gradient(160deg, var(--sage-50), #fff); }
.card-feature h2 { font-size: 1.6rem; }
.card-feature p { font-size: 1.08rem; }
.values { background: var(--sage-50); }
.service h2 { font-size: 1.3rem; }
.service:nth-child(even) .card-icon { background: var(--slate-100); color: var(--slate); }

.ticks li { position: relative; padding-left: 30px; margin-bottom: 12px; color: var(--muted); }
.ticks li::before {
  content: ""; position: absolute; left: 0; top: .5em; width: 18px; height: 18px; border-radius: 50%;
  background: var(--sage-100) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%233F7D5C' stroke-width='3.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m5 12 5 5 9-10'/%3E%3C/svg%3E") center / 11px no-repeat;
}
.ticks li:last-child { margin-bottom: 0; }

.standards { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; counter-reset: st; }
.standards .card { display: flex; gap: 18px; align-items: flex-start; }
.standards h3 { margin-bottom: .3em; }
.num { flex: none; width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; font-weight: 700; color: #fff; background: var(--sage-700); }
.standards li:nth-child(even) .num { background: var(--slate); }

/* ---------- Directorio ---------- */
.clinic-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 22px; }
.clinic-card { display: flex; flex-direction: column; gap: 10px; }
.clinic-card .seal { align-self: flex-start; display: inline-flex; gap: 6px; align-items: center; font-size: .78rem; font-weight: 700; color: var(--sage-800); background: var(--sage-100); padding: 4px 12px 4px 8px; border-radius: 999px; }
.clinic-card .seal svg { width: 16px; height: 16px; }
.clinic-card h3 { margin: 4px 0 0; }
.clinic-meta { color: var(--muted); font-size: .92rem; }
.tags { display: flex; flex-wrap: wrap; gap: 6px; }
.tags span { font-size: .78rem; background: var(--slate-100); color: #3d5a72; padding: 3px 10px; border-radius: 999px; }
.clinic-actions { display: grid; gap: 8px; margin-top: auto; padding-top: 10px; }
.empty-state { max-width: 640px; margin: 0 auto; text-align: center; background: var(--beige); border: 1.5px dashed var(--beige-200); border-radius: var(--radius); padding: 44px 28px; }
.empty-state .card-icon { margin-inline: auto; }
.empty-state p { color: var(--muted); }
.note { font-size: .88rem; color: var(--muted); font-style: italic; }

/* ---------- Quiz ---------- */
.quiz { background: #fff; border-radius: var(--radius); padding: clamp(28px, 5vw, 48px); box-shadow: var(--shadow); }
.quiz-options { display: grid; gap: 12px; margin-top: 28px; }
.quiz-opt {
  display: flex; align-items: center; gap: 14px; text-align: left; width: 100%;
  font: 500 1rem var(--font); color: var(--ink); background: var(--sage-50);
  border: 2px solid transparent; border-radius: var(--radius-sm); padding: 14px 18px; cursor: pointer; transition: border-color 160ms ease, background-color 160ms ease, transform 160ms var(--ease-out);
}
.quiz-opt:active:not(:disabled) { transform: scale(.985); }
.quiz-opt:disabled { cursor: default; opacity: .65; }
.quiz-opt.is-correct { background: var(--sage-100); border-color: var(--sage-600); opacity: 1; }
.quiz-opt.is-wrong { background: #FBEDEA; border-color: #D98F82; opacity: 1; }
.quiz-letter { flex: none; width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; background: #fff; font-weight: 700; color: var(--sage-700); }
.result { margin-top: 24px; padding: 18px 20px; border-radius: var(--radius-sm); }
.result strong { display: block; margin-bottom: 4px; }
.result-ok { background: var(--sage-100); color: #234c37; }
.result-no { background: var(--slate-100); color: #2f4a5f; }
.quiz-result .btn { margin-top: 14px; }

/* ---------- Contact / forms ---------- */
.contact-grid { display: grid; grid-template-columns: .85fr 1.15fr; gap: clamp(28px, 5vw, 64px); align-items: start; }
.contact-info h2 { font-size: 1.5rem; }
.contact-links { margin: 28px 0; display: grid; gap: 14px; }
.contact-links li { display: flex; align-items: center; gap: 12px; }
.contact-links svg { width: 22px; height: 22px; color: var(--sage-700); flex: none; }
.form-card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: clamp(24px, 4vw, 40px); box-shadow: var(--shadow); }
.form-card h2 { font-size: 1.6rem; }
.form { display: grid; gap: 18px; margin-top: 24px; }
.field label { display: block; font-weight: 600; font-size: .92rem; margin-bottom: 6px; }
.field small { display: block; color: var(--muted); font-size: .8rem; margin-top: 4px; }
input[type=text], input[type=email], select, textarea {
  width: 100%; font: 400 1rem var(--font); color: var(--ink); background: #fff;
  border: 1.5px solid #CFC9BC; border-radius: var(--radius-sm); padding: 12px 14px; transition: border-color .2s, box-shadow .2s;
}
textarea { resize: vertical; min-height: 110px; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--sage-600); box-shadow: 0 0 0 4px var(--sage-100); }
.field.has-error input, .field.has-error select, .field.has-error textarea { border-color: #C45B4B; }
.check { display: flex; gap: 12px; align-items: flex-start; font-size: .88rem; color: var(--muted); cursor: pointer; }
.check input { flex: none; width: 20px; height: 20px; margin-top: 2px; accent-color: var(--sage-700); }
.form-status { margin: 0; font-size: .95rem; font-weight: 500; min-height: 1.4em; }
.form-status.ok { color: var(--sage-800); }
.form-status.err { color: #B04A3B; }
.form-status.info { color: #3d5a72; }

.dialog { border: 0; border-radius: var(--radius); padding: 0; width: min(94vw, 520px); box-shadow: 0 30px 80px -20px rgba(0, 0, 0, .4); }
.dialog .form { margin: 0; padding: 32px; position: relative; }
.dialog h2 { font-size: 1.3rem; margin-right: 32px; }
.dialog-close { position: absolute; right: 14px; top: 10px; font-size: 2rem; line-height: 1; background: none; border: 0; cursor: pointer; color: var(--muted); padding: 4px 10px; }

/* ---------- Footer ---------- */
.site-footer { background: var(--sage-700); color: rgba(255, 255, 255, .92); padding: 64px 0 0; }
.site-footer a { color: #fff; text-decoration: none; }
.site-footer a:hover { text-decoration: underline; }
.footer-grid { display: grid; grid-template-columns: 1.6fr 1fr 1fr; gap: 40px; padding-bottom: 44px; }
.footer-brand img { width: 200px; height: auto; margin-bottom: 14px; }
.footer-tag { font-weight: 600; margin-bottom: 6px; }
.footer-quote { font-style: italic; opacity: .9; max-width: 34ch; }
.footer-title { font-family: var(--font-label); font-size: .8rem; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: #fff; opacity: .75; margin-bottom: 14px; }
.site-footer li { margin-bottom: 8px; }
.footer-bottom { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; padding: 20px 0 28px; border-top: 1px solid rgba(255, 255, 255, .22); font-size: .88rem; }
.footer-bottom p { margin: 0; }
.legal { display: flex; gap: 20px; }
.legal li { margin: 0; }

/* ---------- Motion (ver bloque final) ---------- */

/* ---------- Responsive ---------- */
@media (max-width: 960px) {
  .nav-toggle { display: block; }
  .site-nav {
    position: absolute; left: 0; right: 0; top: 100%; background: #fff; border-bottom: 1px solid var(--line);
    flex-direction: column; align-items: stretch; gap: 16px; padding: 16px;
    display: none; box-shadow: var(--shadow);
  }
  .site-nav ul { flex-direction: column; }
  .site-nav ul a { padding: 12px 16px; }
  .nav-actions { justify-content: space-between; }
  .hero-grid, .split, .contact-grid { grid-template-columns: 1fr; }
  .hero-visual { max-width: 380px; order: -1; }
  .chip-a { left: -8px; } .chip-b { right: -8px; }
  .how .split-media { max-width: 420px; margin-inline: auto; }
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .footer-brand { grid-column: 1 / -1; }
}
@media (max-width: 640px) {
  body { font-size: 1rem; }
  .brand img { height: 44px; }
  .two-col, .grid-2, .standards, .grid-4 { grid-template-columns: 1fr; }
  .btn-row .btn { width: 100%; }
  .chip { font-size: .78rem; padding: 8px 14px 8px 8px; }
  .footer-grid { grid-template-columns: 1fr; }
  .footer-bottom { flex-direction: column; }
}

/* ---------- WordPress / contenido genérico ---------- */
.admin-bar .site-header { top: 32px; }
@media (max-width: 782px) { .admin-bar .site-header { top: 46px; } }
.prose h2 { margin-top: 1.6em; font-size: 1.4rem; }
.prose h3 { margin-top: 1.4em; }
.prose ul { list-style: disc; padding-left: 1.4em; margin-bottom: 1em; }
.prose ol { list-style: decimal; padding-left: 1.4em; margin-bottom: 1em; }
.prose li { margin-bottom: .4em; }

/* =====================================================================
   IDENTIDAD ROK · arco, avión, mapa, tipografía con personalidad
   ===================================================================== */

/* Tipografía: solo Montserrat (guía de marca) */
.statement { line-height: 1.45; }

/* Ilustraciones propias (dos tonos con la paleta del logo) */
.il { width: 36px; height: 36px; display: block; }
.il-a { fill: var(--sage-600); }
.il-b { fill: var(--slate); }
.il-c { fill: var(--sage); }
.il-line { fill: none; stroke: var(--slate-300); stroke-width: 2.4; stroke-linecap: round; }
.card-icon { width: 64px; height: 64px; border-radius: 22px; }
.card-icon .il { width: 38px; height: 38px; }
.step-icon { width: 72px; height: 72px; }
.step-icon .il { width: 42px; height: 42px; }

/* Hero: el arco del logo se dibuja al cargar */
.hero { position: relative; }
.hero-grid { position: relative; z-index: 1; }

/* Entrada del hero: CSS puro (visible aunque falle el JS), escalonada 70 ms */
.enter { animation: rise .55s var(--ease-out) backwards; animation-delay: calc(var(--i, 0) * 70ms); }
@keyframes rise { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }

/* Aparición al hacer scroll: rápida, salida fuerte, recorrido corto */
.js .reveal { opacity: 0; transform: translateY(12px); transition: opacity 500ms var(--ease-out), transform 500ms var(--ease-out); transition-delay: var(--d, 0ms); }
.js .reveal.in { opacity: 1; transform: none; }
.stagger > :nth-child(2) { --d: 60ms; }
.stagger > :nth-child(3) { --d: 120ms; }
.stagger > :nth-child(4) { --d: 180ms; }

/* Divisores con forma de arco entre secciones */
.tint, .cta-band, .values { position: relative; }
.tint::before, .cta-band::before, .values::before {
  content: ""; position: absolute; left: -4%; right: -4%; top: -1px; height: clamp(22px, 4vw, 54px);
  background: var(--arc-bg, #fff); border-radius: 0 0 50% 50% / 0 0 100% 100%; z-index: 0;
}
.values + .worldmap-section, .cta-band { --arc-bg: #fff; }
.values + .cta-band { --arc-bg: var(--sage-50); }
.tint > .container, .values > .container, .cta-band > .container { position: relative; z-index: 1; }
.tint, .values { padding-top: clamp(72px, 9vw, 120px); }

/* Recorrido "Cómo funciona": el avión sigue el arco al hacer scroll */
.journey { margin-top: clamp(40px, 6vw, 80px); }
.journey-svg { display: block; width: 100%; height: auto; overflow: visible; }
.j-track { fill: none; stroke: var(--slate-300); stroke-width: 5; stroke-linecap: round; stroke-dasharray: .1 15; opacity: .8; }
.j-node { fill: var(--sage-100); stroke: var(--sage-700); stroke-width: 4; }
.journey-steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; margin-top: 8px; text-align: center; }
.journey-steps li { display: flex; flex-direction: column; align-items: center; }
.journey-steps h3 { margin: 14px 0 6px; }
.journey-steps p { color: var(--muted); font-size: .98rem; max-width: 30ch; margin: 0; }
.journey-steps .step-icon { border-radius: 24px; }
.journey-steps li:nth-child(2) .step-icon { background: var(--slate-100); }

/* Mapa de puntos: Barcelona conecta con el mundo */
.worldmap-section { padding-bottom: clamp(56px, 7vw, 96px); }
.worldmap { display: block; width: 100%; height: auto; }
.wm-dots { fill: none; stroke: var(--slate-100); stroke-width: 6; stroke-linecap: round; }
.wm-arc { fill: none; stroke: var(--sage-700); stroke-width: 2.6; stroke-linecap: round; }
.wm-pin { fill: #fff; stroke: var(--slate); stroke-width: 3; }
.wm-core { fill: var(--sage-700); stroke: #fff; stroke-width: 3; }
.wm-label { font: 600 17px var(--font); fill: var(--sage-800); }
.stages { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-top: 32px; }
.stages li { display: flex; gap: 14px; align-items: flex-start; }
.stages h3 { margin: 0 0 4px; font-size: 1.02rem; }
.stages p { margin: 0; color: var(--muted); font-size: .95rem; }
.stage-n { flex: none; width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; font-weight: 700; color: #fff; background: var(--sage-700); }
.stages li:nth-child(2) .stage-n { background: var(--slate); }
.stages li:nth-child(3) .stage-n { background: var(--sage); color: var(--ink); }
.dir { position: relative; overflow: hidden; }
.dir-bg { position: absolute; inset: 0; opacity: .55; pointer-events: none; display: grid; align-items: center; }
.dir-bg .wm-arc { stroke: var(--slate-300); }
.dir > .container { position: relative; z-index: 1; }

/* Interacción: solo con puntero real (en táctil el hover "se queda pegado") */
@media (hover: hover) and (pointer: fine) {
  .btn:hover { transform: translateY(-2px); }
  .btn-primary:hover { background: var(--sage-800); color: #fff; }
  .btn-ghost:hover { background: var(--sage-50); color: var(--sage-800); }
  .btn-light:hover { background: var(--beige); color: var(--sage-800); }
  .btn-outline-light:hover { background: rgba(255, 255, 255, .16); color: #fff; }
  .site-nav ul a:hover { background: var(--sage-50); color: var(--sage-800); }
  .quiz-opt:hover:not(:disabled) { border-color: var(--sage); transform: translateX(3px); }
  .clinic-card:hover { border-color: var(--sage); }
}
.btn:active { transform: scale(.97); }
.clinic-card { transition: border-color 160ms ease; }
.result:not([hidden]) { animation: rise .3s var(--ease-out) both; }

/* Formulario en ventana: entra y sale con transición (modal centrado, escala 0,96) */
.dialog { opacity: 0; transform: scale(.96); transition: opacity 200ms var(--ease-out), transform 200ms var(--ease-out), overlay 200ms allow-discrete, display 200ms allow-discrete; }
.dialog[open] { opacity: 1; transform: none; }
.dialog::backdrop { background: rgba(44, 58, 52, 0); transition: background-color 200ms ease, overlay 200ms allow-discrete, display 200ms allow-discrete; }
.dialog[open]::backdrop { background: rgba(44, 58, 52, .55); }
@starting-style {
  .dialog[open] { opacity: 0; transform: scale(.96); }
  .dialog[open]::backdrop { background: rgba(44, 58, 52, 0); }
}

@media (max-width: 960px) {
  .site-nav { opacity: 0; transform: translateY(-6px); transition: opacity 180ms var(--ease-out), transform 180ms var(--ease-out), display 180ms allow-discrete; }
  .site-nav.open { display: flex; opacity: 1; transform: none; }
  @starting-style { .site-nav.open { opacity: 0; transform: translateY(-6px); } }
}
@media (max-width: 720px) {
    .journey-svg { display: none; }
  .journey-steps { grid-template-columns: 1fr; gap: 26px; text-align: left; padding-left: 26px; border-left: 3px dotted var(--slate-300); }
  .journey-steps li { flex-direction: row; flex-wrap: wrap; align-items: center; column-gap: 16px; position: relative; }
  .journey-steps li .step-icon { flex: none; width: 60px; height: 60px; }
  .journey-steps li h3 { flex: 1; margin: 0; }
  .journey-steps li p { flex-basis: 100%; max-width: none; margin-top: 8px; }
  .stages { grid-template-columns: 1fr; }
}

/* =====================================================================
   INTERACCIÓN Y ANIMACIÓN (v1.2)
   ===================================================================== */
[hidden] { display: none !important; }

/* Subrayado de rotulador que se dibuja bajo las palabras clave de los titulares */
.hl { padding: 0 .06em; background: linear-gradient(transparent 62%, rgba(139, 191, 159, .5) 62%) no-repeat left / 0% 100%; -webkit-box-decoration-break: clone; box-decoration-break: clone; }
.enter .hl { animation: hl-draw .8s var(--ease-out) .9s forwards; }
.reveal.in .hl { background-size: 100% 100%; transition: background-size .8s var(--ease-out) .35s; }
@keyframes hl-draw { to { background-size: 100% 100%; } }

/* Selector "Soy familia / Soy profesional" */
.aud { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; margin: 2px 0 18px; }
.aud-label { font-weight: 600; font-size: .92rem; color: var(--muted); }
.aud-switch { position: relative; display: grid; grid-template-columns: 1fr 1fr; background: #fff; border: 1.5px solid var(--line); border-radius: 999px; padding: 4px; box-shadow: var(--shadow); }
.aud-switch button { position: relative; z-index: 1; border: 0; background: none; font: 600 .92rem var(--font); padding: 10px 22px; border-radius: 999px; color: var(--muted); cursor: pointer; white-space: nowrap; transition: color 200ms ease; }
.aud-switch button[aria-pressed="true"] { color: #fff; }
.aud-thumb { position: absolute; z-index: 0; top: 4px; bottom: 4px; left: 4px; width: calc(50% - 4px); border-radius: 999px; background: var(--sage-700); transition: transform 320ms var(--ease-out); }
.aud-switch[data-active="pro"] .aud-thumb { transform: translateX(100%); }
.is-swapping { opacity: 0; transform: translateY(4px); transition: opacity 120ms ease, transform 120ms ease; }
.swap-in { animation: rise .28s var(--ease-out) backwards; }
.split-body [data-aud-swap] { margin-bottom: 1em; }

/* Cifras que cuentan al aparecer */
.stats { padding: clamp(8px, 2vw, 24px) 0 clamp(40px, 6vw, 72px); }
.stats-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.stats-grid li { text-align: center; padding: 28px 16px; border-radius: var(--radius); background: var(--sage-50); }
.stats-grid li:nth-child(even) { background: var(--slate-100); }
.stat-n { display: block; font-size: clamp(2.4rem, 5vw, 3.4rem); font-weight: 600; line-height: 1; color: var(--sage-700); font-variant-numeric: tabular-nums; margin-bottom: 12px; }
.stats-grid li:nth-child(even) .stat-n { color: #456A85; }
.stat-l { display: block; max-width: 22ch; margin-inline: auto; color: var(--muted); font-size: .95rem; line-height: 1.4; }

/* Tarjetas que reaccionan al cursor (inclinación + brillo) */
.card, .arch { position: relative; overflow: hidden; isolation: isolate; }
.glow { position: absolute; left: 0; top: 0; width: 240px; height: 240px; border-radius: 50%; pointer-events: none; opacity: 0; z-index: -1; transition: opacity 250ms ease; background: radial-gradient(circle, rgba(139, 191, 159, .38), transparent 66%); }
.arch .glow { z-index: 1; mix-blend-mode: soft-light; background: radial-gradient(circle, rgba(255, 255, 255, .85), transparent 66%); }
.glow.on { opacity: 1; }
.card-icon, .step-icon { transition: transform 260ms var(--ease-out); }
@media (hover: hover) and (pointer: fine) {
  .card:hover .card-icon { transform: translateY(-3px) rotate(-6deg) scale(1.07); }
  .journey-steps li:hover .step-icon { transform: translateY(-4px) rotate(-5deg); }
  .aud-switch button[aria-pressed="false"]:hover { color: var(--sage-800); }
}

/* Los números de los estándares "saltan" al aparecer, en cascada */
.standards .reveal.in .num { animation: pop .5s var(--ease-out) backwards; animation-delay: calc(var(--d, 0ms) + 200ms); }
@keyframes pop { from { transform: scale(.55); opacity: 0; } to { transform: none; opacity: 1; } }

/* Preguntas frecuentes desplegables */
.faq { max-width: 820px; margin: 0 auto; display: grid; gap: 12px; }
.faq-item { background: #fff; border: 1px solid var(--line); border-radius: var(--radius-sm); transition: border-color 200ms ease; }
.faq-item.open { border-color: var(--sage); }
.faq-item h3 { margin: 0; font-size: 1rem; }
.faq-q { display: flex; align-items: center; justify-content: space-between; gap: 16px; width: 100%; padding: 18px 20px; background: none; border: 0; font: 600 1.02rem var(--font); color: var(--ink); text-align: left; cursor: pointer; }
.faq-icon { flex: none; position: relative; width: 30px; height: 30px; border-radius: 50%; background: var(--sage-100); transition: transform 280ms var(--ease-out), background-color 200ms ease; }
.faq-icon::before, .faq-icon::after { content: ""; position: absolute; left: 50%; top: 50%; width: 12px; height: 2px; border-radius: 2px; background: var(--sage-700); transform: translate(-50%, -50%); }
.faq-icon::after { transform: translate(-50%, -50%) rotate(90deg); }
.faq-item.open .faq-icon { transform: rotate(45deg); background: var(--sage); }
.faq-a { display: grid; grid-template-rows: 0fr; visibility: hidden; transition: grid-template-rows 300ms var(--ease-out), visibility 0s linear 300ms; }
.faq-item.open .faq-a { grid-template-rows: 1fr; visibility: visible; transition: grid-template-rows 300ms var(--ease-out), visibility 0s; }
.faq-a > div { overflow: hidden; }
.faq-a p { margin: 0; padding: 0 20px 20px; color: var(--muted); }

@media (max-width: 960px) { .stats-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 520px) {
  .stats-grid { gap: 12px; }
  .stats-grid li { padding: 22px 10px; }
  .aud-switch button { padding: 10px 16px; }
}

/* Movimiento reducido: menos y más suave, no cero (se conservan los cambios de color) */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .js .reveal { opacity: 1; transform: none; transition: none; }
  .enter, .result:not([hidden]), .swap-in, .standards .reveal.in .num { animation: none; opacity: 1; transform: none; }
  .hl, .enter .hl, .reveal.in .hl { animation: none; background-size: 100% 100%; transition: none; }
  .btn, .quiz-opt { transition: background-color 160ms ease, color 160ms ease, border-color 160ms ease; }
  .btn:hover, .btn:active, .quiz-opt:hover, .quiz-opt:active { transform: none; }
  .card:hover .card-icon, .journey-steps li:hover .step-icon { transform: none; }
  .aud-thumb { transition: none; }
  .is-swapping { transform: none; }
  .faq-a, .faq-item.open .faq-a, .faq-icon { transition: none; }
  .dialog, .dialog[open] { transform: none; transition: opacity 150ms ease; }
  .site-nav, .site-nav.open { transform: none; }
  .nav-toggle span { transition: opacity 150ms ease; }
}

/* Mapa de Sobre ROK: más compacto */
.worldmap-wrap:not(.is-bg) { max-width: 640px; margin-inline: auto; }
.worldmap-section .stages { max-width: 900px; margin-inline: auto; }
.worldmap-section .section-head { margin-bottom: 32px; }

