/* Veterinaria Lucero — página de muestra (negocio ficticio)
   Idea: el dorado del lucero y el azul de la noche son los colores del cielo.
   De día el sol recorre el reloj; de noche, la luna. Las emergencias se atienden las 24 horas. */

@font-face { font-family: "Gabarito"; src: url("assets/fonts/gabarito.woff2") format("woff2"); font-weight: 400 900; font-display: swap; }
@font-face { font-family: "Onest"; src: url("assets/fonts/onest.woff2") format("woff2"); font-weight: 400 700; font-display: swap; }

:root {
  /* marca: fijos en los dos temas */
  --orange: #F6B13C;
  --plum: #142C3D;
  --purple: #2F72A1;
  /* tema de día */
  --bg: #F8FCFF;
  --surface: #FFFFFF;
  --tint: #E9F4FC;
  --ink: #142C3D;
  --muted: #586B79;
  --line: #DBE8F1;
  --line-strong: #BBCFDE;
  --orange-text: #9A5B00;
  --purple-soft: #60A8DB;
  --purple-field: #2F72A1;
  --foot: #102B3E;
  --moon: #2F72A1;
  --ok: #0F7F53;
  --shadow: 0 26px 60px -28px rgba(30, 80, 116, .4);
  --display: "Gabarito", "Trebuchet MS", system-ui, sans-serif;
  --body: "Onest", system-ui, -apple-system, "Segoe UI", sans-serif;
  --lift: 44px;
  --top-h: 70px;
  --pad: clamp(60px, 8.5vw, 108px);
  color-scheme: light;
}
:root[data-theme="night"] {
  --bg: #0B1C28;
  --surface: #142837;
  --tint: #102534;
  --ink: #F2F8FD;
  --muted: #ABC1D0;
  --line: #223847;
  --line-strong: #3C5C73;
  --orange-text: #FFC14D;
  --purple-soft: #97D1FB;
  --purple-field: #1F547A;
  --foot: #06121A;
  --moon: #FFFCC2;
  --ok: #54DCA6;
  --shadow: 0 26px 60px -28px rgba(0, 0, 0, .75);
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { overflow-x: clip; scroll-behavior: smooth; scroll-padding-top: calc(var(--top-h) + 8px); -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font: 400 1.0625rem/1.55 var(--body);
  transition: background-color .6s ease, color .6s ease;
  -webkit-font-smoothing: antialiased; overflow-x: hidden;
}
img { display: block; max-width: 100%; height: auto; }
h1, h2, h3, p, ul, ol, dl, dd, figure, blockquote { margin: 0; padding: 0; }
ul, ol { list-style: none; }
a { color: inherit; }
button, input { font: inherit; color: inherit; }
button { cursor: pointer; }
svg { fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
:focus-visible { outline: 3px solid var(--purple-soft); outline-offset: 3px; border-radius: 8px; }
[hidden] { display: none !important; }

.wrap { width: min(100% - 2 * clamp(20px, 4.5vw, 44px), 1160px); margin-inline: auto; }
.skip { position: absolute; left: 12px; top: -60px; background: var(--plum); color: #fff; padding: 10px 16px; border-radius: 10px; z-index: 100; }
.skip:focus { top: 12px; }

/* ── Botones ── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 54px; padding: 0 28px; border-radius: 999px; border: 1.5px solid transparent;
  font-weight: 600; font-size: 1rem; text-decoration: none; white-space: nowrap;
  transition: transform .18s ease, background-color .2s ease, border-color .2s ease, box-shadow .2s ease;
}
.btn svg { width: 20px; height: 20px; flex: none; }
.btn:active { transform: scale(.97); }
.btn--primary { background: var(--orange); color: var(--plum); box-shadow: 0 14px 30px -14px rgba(255, 180, 46, .9); }
.btn--primary:hover { background: #F8C15E; }
.btn--ghost { border-color: var(--line-strong); background: color-mix(in srgb, var(--surface) 55%, transparent); }
.btn--ghost:hover { border-color: var(--ink); }
.btn--dark { background: var(--plum); color: #fff; }
.btn--dark:hover { background: #23445C; }
.btn--line { border-color: rgba(20, 44, 61, .45); background: transparent; color: var(--plum); min-height: 46px; padding: 0 22px; }
.btn--line:hover { border-color: var(--plum); }
.btn--urgent { background: var(--ink); color: var(--bg); min-height: 44px; padding: 0 18px; font-size: .95rem; }

.icon-btn {
  position: relative; display: grid; place-items: center; width: 44px; height: 44px; flex: none;
  border-radius: 50%; border: 1.5px solid var(--line-strong); background: color-mix(in srgb, var(--surface) 55%, transparent);
  transition: border-color .2s ease, transform .18s ease;
}
.icon-btn:hover { border-color: var(--ink); }
.icon-btn:active { transform: scale(.94); }
.icon-btn svg { width: 21px; height: 21px; }
[data-theme="day"] .i-moon, [data-theme="night"] .i-sun { display: none; }

/* ── Cabecera: transparente sobre el cielo, sólida al bajar ── */
.top { position: sticky; top: 0; z-index: 40; border-bottom: 1px solid transparent; transition: background-color .35s ease, border-color .35s ease; }
.top.is-stuck {
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px); border-bottom-color: var(--line);
}
.top__in { display: flex; align-items: center; gap: 20px; height: var(--top-h); }
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--ink); text-decoration: none; }
.brand__mark { width: 42px; height: 42px; flex: none; }
.brand__mark circle { fill: #142C3D; stroke: rgba(246, 177, 60, .35); stroke-width: 1.5; }
.brand__mark path { fill: var(--orange); }
.brand__name { display: grid; font: 800 1.5rem/1 var(--display); letter-spacing: -.01em; }
.brand__name small { margin-top: 3px; font: 600 .66rem/1.1 var(--body); letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.nav { display: none; gap: 28px; margin-left: auto; font-weight: 500; font-size: .98rem; }
.nav a { text-decoration: none; padding: 8px 0; border-bottom: 2px solid transparent; transition: border-color .2s ease; }
.nav a:hover { border-bottom-color: var(--orange); }
.top__actions { display: flex; align-items: center; gap: 10px; margin-left: auto; }
.top__call { display: none; }
.cart-btn__n {
  position: absolute; top: -5px; right: -5px; min-width: 21px; height: 21px; padding: 0 5px;
  display: grid; place-items: center; border-radius: 999px;
  background: var(--orange); color: var(--plum); font-size: .75rem; font-weight: 700;
}
.cart-btn.bump { animation: bump .4s ease; }
@keyframes bump { 40% { transform: scale(1.18); } }

/* ── Primera pantalla ── */
.hero {
  position: relative; isolation: isolate; overflow: hidden;
  margin-top: calc(-1 * var(--top-h));
  padding: calc(var(--top-h) + clamp(28px, 6vw, 76px)) 0 calc(var(--lift) + clamp(52px, 8vw, 104px));
}
.sky { position: absolute; inset: 0; z-index: -1; pointer-events: none; }
.sky::before, .sky::after { content: ""; position: absolute; inset: 0; transition: opacity .9s ease; }
.sky::before { background: linear-gradient(180deg, #C9E7FD 0%, #E0F1FE 34%, #FFF3D2 72%, #FFEAAF 100%); }
.sky::after { background: linear-gradient(180deg, #06151F 0%, #0D283B 42%, #1F547A 100%); opacity: 0; }
[data-theme="night"] .sky::after { opacity: 1; }
.sky__glow {
  position: absolute; z-index: 1; right: -12%; top: 4%; width: min(88vw, 820px); aspect-ratio: 1; border-radius: 50%;
  background: radial-gradient(closest-side, rgba(255, 180, 46, .5), rgba(255, 180, 46, .16) 55%, transparent 72%);
  animation: breathe 9s ease-in-out infinite;
}
[data-theme="night"] .sky__glow { background: radial-gradient(closest-side, rgba(106, 189, 249, .5), rgba(106, 189, 249, .14) 55%, transparent 72%); }
@keyframes breathe { 50% { transform: scale(1.09); } }

.star { position: absolute; z-index: 1; width: var(--s); height: var(--s); border-radius: 50%; background: #fff; opacity: 0; transition: opacity .9s ease; }
[data-theme="night"] .star { opacity: var(--o); animation: twinkle var(--d) ease-in-out var(--w) infinite; }
@keyframes twinkle { 50% { opacity: .12; transform: scale(.7); } }

.cloud {
  position: absolute; z-index: 1; left: 0; height: 46px; width: 170px; border-radius: 999px; background: #fff; opacity: .62;
  animation: drift linear infinite; transition: opacity .9s ease;
}
.cloud::before, .cloud::after { content: ""; position: absolute; background: #fff; border-radius: 50%; }
.cloud::before { width: 70px; height: 70px; left: 28px; top: -32px; }
.cloud::after { width: 54px; height: 54px; left: 84px; top: -20px; }
.cloud--a { top: 16%; animation-duration: 95s; animation-delay: -30s; }
.cloud--b { top: 44%; scale: .62; animation-duration: 130s; animation-delay: -90s; opacity: .5; }
.cloud--c { top: 70%; scale: .8; animation-duration: 110s; animation-delay: -62s; opacity: .45; }
[data-theme="night"] .cloud { opacity: 0; }
@keyframes drift { from { transform: translateX(-240px); } to { transform: translateX(calc(100vw + 240px)); } }

.hero__in { display: grid; gap: clamp(30px, 5vw, 56px); align-items: center; }
.lema {
  font-family: var(--display); font-weight: 800;
  font-size: clamp(2.5rem, 10vw, 3.5rem); line-height: 1; letter-spacing: -.025em; text-wrap: balance;
}
.lema span { display: block; }
.lema__b { margin-top: .12em; color: var(--orange-text); }
.live { display: flex; align-items: center; gap: 12px; margin-top: 24px; font-weight: 600; font-size: clamp(1rem, 1.5vw, 1.14rem); font-variant-numeric: tabular-nums; }
.live__dot { position: relative; flex: none; width: 10px; height: 10px; border-radius: 50%; background: var(--ok); }
.live__dot::after { content: ""; position: absolute; inset: -5px; border-radius: 50%; border: 2px solid var(--ok); opacity: 0; animation: ping 2.4s ease-out infinite; }
@keyframes ping { 0% { transform: scale(.5); opacity: .7; } 100% { transform: scale(1.5); opacity: 0; } }
.live .colon { animation: blink 2s steps(1) infinite; }
@keyframes blink { 50% { opacity: .25; } }
.hero__cta { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 30px; }

/* El reloj: arriba el día, abajo la noche */
.dial { position: relative; width: min(100%, 470px); aspect-ratio: 1; margin-inline: auto; }
.dial__ring { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; }
.dial__photo {
  position: absolute; inset: 18%; width: 64%; height: 64%; object-fit: cover; border-radius: 50%;
  box-shadow: 0 0 0 6px color-mix(in srgb, var(--surface) 70%, transparent), var(--shadow);
}
.dial .tick { stroke: var(--orange); stroke-width: 3.5; }
.dial .tick--n { stroke: var(--purple-soft); }
.dial .tick--q { stroke-width: 6; }
.dial .num { fill: var(--ink); stroke: none; font: 700 15px var(--display); text-anchor: middle; dominant-baseline: central; }
.dial .sun circle { fill: var(--orange); stroke: none; }
.dial .sun .rays { stroke: var(--orange); stroke-width: 3; transform-box: fill-box; transform-origin: center; animation: spin 26s linear infinite; }
.dial .moon path { fill: var(--moon); stroke: none; }
.dial .halo { fill: none; stroke: var(--orange); stroke-width: 2; transform-box: fill-box; transform-origin: center; animation: ping 2.6s ease-out infinite; }
.dial .mark--moon .halo { stroke: var(--moon); }
@keyframes spin { to { transform: rotate(360deg); } }

/* Entrada: un solo momento orquestado */
.js .lema span, .js .live, .js .hero__cta, .js .dial__photo { opacity: 0; }
.ready .lema span { animation: rise .85s .08s cubic-bezier(.2, .7, .2, 1) forwards; }
.ready .lema .lema__b { animation-delay: .22s; }
.ready .live { animation: rise .8s .36s cubic-bezier(.2, .7, .2, 1) forwards; }
.ready .hero__cta { animation: rise .8s .46s cubic-bezier(.2, .7, .2, 1) forwards; }
.ready .dial__photo { animation: bloom 1s .15s cubic-bezier(.2, .7, .2, 1) forwards; }
.js .dial .tick, .js .dial .num, .js .dial .mark { opacity: 0; }
.ready .dial .tick { animation: fade .4s calc(.3s + var(--i) * 30ms) ease-out forwards; }
.ready .dial .num { animation: fade7 .6s .95s ease forwards; }
.ready .dial .mark { animation: fade .6s 1.2s ease forwards; }
@keyframes rise { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: none; } }
@keyframes bloom { from { opacity: 0; transform: scale(.9); } to { opacity: 1; transform: none; } }
@keyframes fade { to { opacity: 1; } }
@keyframes fade7 { to { opacity: .7; } }

/* ── Secciones: cada una sube sobre la anterior ── */
.sec { padding: var(--pad) 0 calc(var(--pad) + var(--lift)); background: var(--bg); transition: background-color .6s ease; }
.lift { position: relative; margin-top: calc(-1 * var(--lift)); border-radius: var(--lift) var(--lift) 0 0; }
.sec--tint { background: var(--tint); }
.sec__head h2, .cita__title {
  font: 700 clamp(1.9rem, 4.1vw, 2.9rem)/1.05 var(--display); letter-spacing: -.02em; text-wrap: balance;
}
.sec__head h2 { max-width: 17ch; }
.sec__head p { margin-top: 14px; color: var(--muted); max-width: 44ch; }
.sec__head--wide h2 { max-width: 22ch; }
.sec__grid { display: grid; gap: clamp(28px, 5vw, 64px); }

/* ── Propósito ── */
.purpose { background: var(--purple-field); color: #fff; }
.purpose__in { display: grid; gap: clamp(30px, 5vw, 72px); align-items: center; }
.purpose__photo { position: relative; width: min(68%, 340px); }
.purpose__photo::before {
  content: ""; position: absolute; width: 46%; aspect-ratio: 1; border-radius: 50%; background: var(--orange);
  right: -9%; top: -6%;
}
.purpose__photo img { position: relative; width: 100%; aspect-ratio: 5 / 6; object-fit: cover; border-radius: 999px 999px 32px 32px; }
.purpose h2 { font: 700 clamp(1.15rem, 1.8vw, 1.35rem)/1.2 var(--display); color: #FFE4A6; }
.purpose blockquote { margin-top: 16px; font: 600 clamp(1.45rem, 3vw, 2.25rem)/1.22 var(--display); letter-spacing: -.01em; max-width: 24ch; text-wrap: pretty; }
.purpose__by { margin-top: 28px; display: grid; gap: 2px; padding-left: 16px; border-left: 3px solid var(--orange); }
.purpose__by span { color: #CBE2F3; font-size: .95rem; }

/* ── Servicios ── */
.svc { border-top: 1px solid var(--line); }
.svc__item { border-bottom: 1px solid var(--line); }
.svc__btn {
  display: flex; align-items: center; justify-content: space-between; gap: 16px; width: 100%;
  padding: 20px 0; background: none; border: 0; text-align: left;
  font: 600 clamp(1.2rem, 2.2vw, 1.55rem)/1.2 var(--display); transition: color .2s ease;
}
.svc__btn:hover { color: var(--orange-text); }
.svc__btn i { position: relative; flex: none; width: 34px; height: 34px; border-radius: 50%; border: 1.5px solid var(--line-strong); color: var(--ink); transition: background-color .25s ease, border-color .25s ease; }
.svc__btn i::before, .svc__btn i::after { content: ""; position: absolute; left: 50%; top: 50%; width: 12px; height: 2px; margin: -1px 0 0 -6px; background: currentColor; transition: transform .3s ease; }
.svc__btn i::after { transform: rotate(90deg); }
.svc__item.is-open .svc__btn i { background: var(--orange); border-color: var(--orange); color: var(--plum); }
.svc__item.is-open .svc__btn i::after { transform: rotate(0); }
.svc__panel { display: grid; grid-template-rows: 0fr; transition: grid-template-rows .35s cubic-bezier(.2, .7, .2, 1); }
.svc__item.is-open .svc__panel { grid-template-rows: 1fr; }
.svc__panel > div { overflow: hidden; }
.svc__panel p { color: var(--muted); max-width: 52ch; }
.svc__panel .btn { margin: 16px 0 24px; min-height: 44px; padding: 0 20px; font-size: .95rem; box-shadow: none; }

/* ── Huellas: caminan cuando la sección entra en pantalla ── */
.trail { height: 84px; margin-top: clamp(36px, 6vw, 64px); }
.trail svg { width: 100%; height: 100%; stroke: none; fill: currentColor; }
.trail svg > g { opacity: 0; }
.trail[data-kind="dog"] { color: var(--orange); }
.trail[data-kind="cat"] { color: var(--purple-soft); }
.trail.is-in svg > g { animation: paso .4s calc(var(--i) * 120ms) ease-out forwards; }
@keyframes paso { to { opacity: .85; } }

/* ── Citas: campo naranja, igual en los dos temas ── */
.cita { background: var(--orange); color: var(--plum); }
.frase {
  margin-top: clamp(22px, 3.5vw, 40px); max-width: 23ch;
  font: 600 clamp(1.75rem, 5.4vw, 4rem)/1.4 var(--display); letter-spacing: -.015em;
}
.tok {
  display: inline-block; padding: .02em .42em .06em; margin: 0 .04em; border: 0; border-radius: .38em;
  background: #fff; color: var(--plum); font: inherit; letter-spacing: inherit; line-height: 1.2; white-space: nowrap;
  box-shadow: 0 .14em 0 rgba(20, 44, 61, .22);
  transition: transform .16s ease, box-shadow .16s ease, background-color .2s ease, color .2s ease;
}
.tok:hover { transform: translateY(-2px); box-shadow: 0 calc(.14em + 2px) 0 rgba(20, 44, 61, .22); }
.tok:active { transform: translateY(.1em); box-shadow: 0 .04em 0 rgba(20, 44, 61, .22); }
.tok[aria-expanded="true"] { background: var(--plum); color: #fff; }
.tok--vacio { background: transparent; box-shadow: inset 0 0 0 2.5px var(--plum); animation: llamar 2.2s ease-in-out infinite; }
.tok--vacio[aria-expanded="true"] { animation: none; }
@keyframes llamar { 50% { background: rgba(255, 255, 255, .42); } }
.tok.swap { animation: swap .32s ease; }
@keyframes swap { 50% { transform: rotateX(80deg); } }
.cita__hint { margin-top: 18px; font-size: .95rem; font-weight: 500; }

.tray {
  margin-top: 22px; padding: clamp(16px, 2.4vw, 24px); border-radius: 26px; background: #fff; max-width: 720px;
  box-shadow: 0 30px 60px -30px rgba(120, 80, 0, .55); animation: abrir .32s cubic-bezier(.2, .8, .2, 1);
}
@keyframes abrir { from { opacity: 0; transform: translateY(-10px); } }
.tray__label { font-weight: 700; font-size: .92rem; margin-bottom: 10px; }
.tray__days + .tray__label { margin-top: 18px; }
.opt {
  min-height: 46px; padding: 0 18px; border-radius: 14px; border: 1.5px solid #DBE8F1; background: #fff; color: var(--plum);
  font-weight: 600; font-variant-numeric: tabular-nums; transition: background-color .16s ease, border-color .16s ease, color .16s ease;
}
.opt:hover:not(:disabled) { border-color: var(--purple); }
.opt[aria-pressed="true"] { background: var(--purple); border-color: var(--purple); color: #fff; }
.opt:disabled { color: #8194A2; background: #EFF5FA; border-color: transparent; text-decoration: line-through; cursor: not-allowed; }
.tray__opts { display: flex; flex-wrap: wrap; gap: 8px; }
.tray__days { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 6px; }
.tray__days .opt { padding: 7px 0; min-height: 60px; line-height: 1.15; }
.tray__days small { display: block; font-size: .74rem; }
.tray__days b { display: block; font: 700 1.25rem var(--display); }
.tray__slots { display: grid; grid-template-columns: repeat(auto-fill, minmax(74px, 1fr)); gap: 6px; }
.tray__slots .opt { padding: 0; min-height: 44px; font-size: .94rem; }
.tray__empty { color: #586B79; }

.datos { display: grid; gap: 12px; margin-top: 26px; max-width: 720px; animation: abrir .35s cubic-bezier(.2, .8, .2, 1); }
.field span { display: block; font-size: .88rem; font-weight: 600; margin-bottom: 6px; }
.field input {
  width: 100%; min-height: 54px; padding: 0 18px; border-radius: 16px; border: 2px solid transparent;
  background: #fff; color: var(--plum); font-size: 1rem; transition: border-color .18s ease;
}
.field input::placeholder { color: #738795; }
.field input:focus { outline: none; border-color: var(--plum); }
.field input.is-bad { border-color: #B3160B; }
.datos .btn { margin-top: 6px; }
.cita__error { margin-top: 16px; font-weight: 700; color: #5E0B05; }

.cita__ok { display: flex; gap: 22px; align-items: flex-start; margin-top: clamp(22px, 3.5vw, 40px); outline: none; animation: abrir .4s ease; }
.cita__ok h3 { font: 700 clamp(1.8rem, 4vw, 2.6rem)/1.05 var(--display); }
.cita__ok #cita-resumen { margin-top: 10px; font: 600 clamp(1.15rem, 2vw, 1.4rem)/1.35 var(--display); max-width: 30ch; }
.cita__ok-note { margin: 10px 0 20px; max-width: 40ch; }
.tick { flex: none; width: 64px; height: 64px; stroke: var(--plum); stroke-width: 3; }
.tick circle { stroke-dasharray: 151; stroke-dashoffset: 151; animation: draw .6s ease forwards; }
.tick path { stroke-dasharray: 36; stroke-dashoffset: 36; animation: draw .35s .5s ease forwards; }
@keyframes draw { to { stroke-dashoffset: 0; } }

.cita__peek {
  display: inline-flex; align-items: center; gap: 10px; margin-top: 30px; padding: 6px 0; background: none; border: 0;
  font-weight: 600; font-size: .98rem; color: var(--plum); border-bottom: 2px solid rgba(20, 44, 61, .4); border-radius: 0;
}
.cita__peek:hover { border-bottom-color: var(--plum); }
.cita__peek::after { content: ""; width: 8px; height: 8px; border-right: 2px solid; border-bottom: 2px solid; transform: rotate(45deg) translateY(-3px); transition: transform .25s ease; }
.cita__peek[aria-expanded="true"]::after { transform: rotate(-135deg) translate(-2px, -1px); }

/* La agenda de la veterinaria: una hoja, no una ventana */
.agenda {
  margin-top: 22px; padding: clamp(18px, 3vw, 30px); border-radius: 26px; background: #FFFDF9; color: var(--plum);
  box-shadow: 0 30px 60px -30px rgba(120, 80, 0, .55); animation: abrir .4s cubic-bezier(.2, .8, .2, 1);
}
.agenda__head { display: flex; align-items: flex-end; justify-content: space-between; gap: 14px; padding-bottom: 16px; border-bottom: 2px solid var(--plum); }
.agenda__kicker { font-weight: 600; font-size: .9rem; color: #586B79; }
.agenda__date { font: 700 clamp(1.3rem, 2.6vw, 1.75rem)/1.1 var(--display); }
.agenda__date::first-letter { text-transform: uppercase; }
.agenda__count { font-weight: 600; font-size: .92rem; color: #586B79; white-space: nowrap; }
.agenda__list li {
  display: grid; grid-template-columns: 62px 1fr auto; align-items: baseline; gap: 10px;
  padding: 12px 10px 12px 12px; border-bottom: 1px solid #E6EFF5; break-inside: avoid; border-left: 4px solid transparent;
}
.agenda__list time { font: 700 1.05rem var(--display); font-variant-numeric: tabular-nums; }
.agenda__list b { font-weight: 600; }
.agenda__list small { display: block; color: #586B79; font-size: .86rem; }
.agenda__list em { font-style: normal; font-weight: 700; font-size: .8rem; color: #7E4A00; white-space: nowrap; }
.agenda__list li.is-new { background: #FFF3DA; border-left-color: var(--orange); border-bottom-color: transparent; border-radius: 0 12px 12px 0; animation: llegar .8s cubic-bezier(.2, .8, .2, 1); }
@keyframes llegar { 0% { opacity: 0; transform: translateX(-26px); } 60% { transform: translateX(4px); } }
.agenda__empty { padding: 22px 0; color: #586B79; }
.agenda__foot { margin-top: 16px; color: #586B79; font-size: .9rem; max-width: 62ch; }

/* ── Tienda: una fila que se desliza ── */
.shop__head { display: flex; align-items: flex-end; justify-content: space-between; gap: 20px; }
.shop__nav { display: none; gap: 8px; }
.shop {
  --gutter: max(clamp(20px, 4.5vw, 44px), calc((100vw - 1160px) / 2));
  display: flex; gap: clamp(14px, 2vw, 24px); margin-top: clamp(26px, 4vw, 44px);
  padding: 4px var(--gutter) 14px; scroll-padding-inline: var(--gutter);
  overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; -webkit-overflow-scrolling: touch;
}
.shop::-webkit-scrollbar { display: none; }
.prod { flex: none; width: clamp(214px, 62vw, 290px); scroll-snap-align: start; }
.prod__img { position: relative; border-radius: 26px; overflow: hidden; background: var(--tint); aspect-ratio: 1; }
.prod__img img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s cubic-bezier(.2, .7, .2, 1); }
.prod:hover .prod__img img { transform: scale(1.05); }
.prod__add {
  position: absolute; right: 12px; bottom: 12px; display: inline-flex; align-items: center; gap: 6px;
  min-height: 44px; padding: 0 18px; border-radius: 999px; border: 0;
  background: #fff; color: var(--plum); font-weight: 700; font-size: .92rem;
  box-shadow: 0 8px 20px -8px rgba(0, 0, 0, .4); transition: transform .18s ease, background-color .2s ease;
}
.prod__add:hover { background: var(--orange); }
.prod__add:active { transform: scale(.94); }
.prod__add.is-added { background: var(--orange); }
.prod h3 { margin-top: 14px; font: 600 1.05rem/1.3 var(--body); }
.prod__meta { color: var(--muted); font-size: .9rem; }
.prod__price { margin-top: 4px; font: 700 1.25rem var(--display); font-variant-numeric: tabular-nums; }

/* ── Carrito ── */
.cart {
  width: 100%; max-width: none; max-height: 88dvh; margin: auto 0 0; padding: 0; border: 0;
  border-radius: 28px 28px 0 0; background: var(--surface); color: var(--ink);
}
.cart::backdrop { background: rgba(10, 26, 37, .55); -webkit-backdrop-filter: blur(3px); backdrop-filter: blur(3px); }
.cart[open] { animation: sheet .35s cubic-bezier(.2, .8, .2, 1); }
@keyframes sheet { from { transform: translateY(40px); opacity: 0; } }
.cart__in { padding: 22px clamp(18px, 4vw, 28px) calc(24px + env(safe-area-inset-bottom)); }
.cart__head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 8px; }
.cart__head h2 { font: 700 1.5rem var(--display); }
.cart__empty { padding: 28px 0 12px; color: var(--muted); }
.cart__items li { display: grid; grid-template-columns: 56px 1fr auto; gap: 12px; align-items: center; padding: 12px 0; border-bottom: 1px solid var(--line); }
.cart__items img { width: 56px; height: 56px; border-radius: 14px; object-fit: cover; }
.cart__items b { display: block; font-weight: 600; font-size: .96rem; line-height: 1.25; }
.cart__items small { color: var(--muted); font-variant-numeric: tabular-nums; }
.qty { display: inline-flex; align-items: center; border: 1.5px solid var(--line-strong); border-radius: 999px; }
.qty button { width: 36px; height: 36px; border: 0; background: none; font-size: 1.15rem; line-height: 1; }
.qty span { min-width: 20px; text-align: center; font-weight: 700; font-variant-numeric: tabular-nums; }
.cart__opt { margin: 18px 0 0; padding: 0; border: 0; min-width: 0; }
.cart__opt legend { font-weight: 700; font-size: .95rem; margin-bottom: 8px; padding: 0; }
.cart__opt .opt { background: transparent; color: var(--ink); border-color: var(--line-strong); }
.cart__opt .opt[aria-pressed="true"] { background: var(--purple); border-color: var(--purple); color: #fff; }
.cart__total { display: flex; justify-content: space-between; align-items: baseline; margin: 22px 0 16px; font-weight: 600; }
.cart__total strong { font: 800 1.7rem var(--display); font-variant-numeric: tabular-nums; }
.cart .btn--primary { width: 100%; }
.cart__ok { text-align: center; padding: 26px 0 8px; }
.cart__ok .tick { margin-inline: auto; stroke: var(--ok); }
.cart__ok h3 { font: 700 1.5rem var(--display); margin-top: 14px; }
.cart__ok p { color: var(--muted); margin: 8px auto 20px; max-width: 32ch; }

/* ── Planes: la línea de una vida ── */
.vida { position: relative; display: grid; gap: 26px; margin: clamp(30px, 5vw, 56px) 0 clamp(30px, 4vw, 44px); }
.vida::before {
  content: ""; position: absolute; left: 44px; top: 20px; bottom: 20px; width: 4px; margin-left: -2px; border-radius: 4px;
  background: linear-gradient(180deg, #FFDA8E, var(--orange) 45%, var(--purple-soft));
}
.vida li { position: relative; display: grid; grid-template-columns: 88px 1fr; gap: 18px; align-items: center; }
.vida img { width: 88px; height: 88px; border-radius: 50%; object-fit: cover; box-shadow: 0 0 0 5px var(--tint); transition: box-shadow .6s ease; }
.vida__edad { font-weight: 700; font-size: .88rem; color: var(--orange-text); }
.vida h3 { font: 700 1.4rem/1.15 var(--display); margin-top: 2px; }
.vida p { color: var(--muted); font-size: .98rem; margin-top: 4px; max-width: 34ch; }

/* ── Ubicación ── */
.loc { display: grid; gap: clamp(28px, 5vw, 56px); align-items: stretch; }
.loc__go { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 26px; }
.loc__data { margin-top: 30px; border-top: 1px solid var(--line); }
.loc__data div { display: flex; justify-content: space-between; gap: 16px; padding: 14px 0; border-bottom: 1px solid var(--line); }
.loc__data dt { color: var(--muted); }
.loc__data dd { font-weight: 600; text-align: right; }
.loc__map {
  position: relative; min-height: 340px; border-radius: 28px; overflow: hidden; background: var(--tint);
  background-image: linear-gradient(var(--line) 1.5px, transparent 1.5px), linear-gradient(90deg, var(--line) 1.5px, transparent 1.5px);
  background-size: 56px 56px; display: grid; place-items: center;
}
.loc__map iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
[data-theme="night"] .loc__map iframe { filter: invert(.92) hue-rotate(180deg) saturate(.7) brightness(.95); }
.loc__map-btn { min-height: 48px; padding: 0 22px; border-radius: 999px; border: 0; background: var(--ink); color: var(--bg); font-weight: 600; }

/* Mapa dibujado (la clínica es ficticia) */
.loc__map--dibujo { background-image: none; }
.loc__map--dibujo svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.m-fondo { fill: var(--tint); }
.m-rio { fill: none; stroke: #9FD0EE; stroke-width: 26; stroke-linecap: round; opacity: .55; }
.m-parque { fill: #BFE3C6; }
.m-calle path { fill: none; stroke: var(--surface); stroke-width: 14; }
.m-calle--av path { stroke-width: 24; }
.m-txt { font: 600 13px var(--body); fill: var(--muted); }
.m-txt--av { font-weight: 700; fill: var(--ink); opacity: .6; letter-spacing: .04em; }
.m-pin > path:first-child { fill: #142C3D; }
.m-pin__star { fill: var(--orange); }
.m-pin { animation: rebote 2.4s cubic-bezier(.3, .7, .4, 1) infinite; }
@keyframes rebote { 0%, 60%, 100% { translate: 0 0; } 30% { translate: 0 -8px; } }
[data-theme="night"] .m-parque { fill: #1C4A3A; }
[data-theme="night"] .m-rio { stroke: #1F547A; }
[data-theme="night"] .m-pin > path:first-child { fill: #F6B13C; }
[data-theme="night"] .m-pin__star { fill: #142C3D; }

/* Aviso de la página de muestra */
.demo { margin: auto; width: min(460px, calc(100vw - 32px)); padding: 0; border: 0; border-radius: 26px; background: var(--surface); color: var(--ink); box-shadow: var(--shadow); }
.demo::backdrop { background: rgba(10, 26, 37, .6); -webkit-backdrop-filter: blur(3px); backdrop-filter: blur(3px); }
.demo[open] { animation: sheet .35s cubic-bezier(.2, .8, .2, 1); }
.demo__in { padding: clamp(22px, 5vw, 32px); }
.demo__kicker { display: inline-block; padding: 4px 10px; border-radius: 999px; background: var(--orange); color: #142C3D; font-weight: 700; font-size: .78rem; letter-spacing: .04em; text-transform: uppercase; }
.demo h2 { margin-top: 14px; font: 700 1.45rem/1.15 var(--display); }
.demo__txt { margin-top: 10px; color: var(--muted); }
.demo__who { margin-top: 16px; padding-top: 14px; border-top: 1px solid var(--line); font-size: .92rem; }
.demo__acts { margin-top: 20px; display: grid; gap: 10px; }
.demo__acts .btn { width: 100%; justify-content: center; }
@media (prefers-reduced-motion: reduce) { .m-pin { animation: none; } }

/* ── Pie ── */
.foot { background: var(--foot); color: #F2F8FD; padding: 56px 0 calc(116px + env(safe-area-inset-bottom)); transition: background-color .6s ease; }
.foot .brand { color: #F2F8FD; }
.foot .brand__mark { width: 56px; height: 56px; }
.foot .brand__name { font-size: 2rem; }
.foot .brand__name small { color: #ABC1D0; font-size: .74rem; }
.foot__demo a { color: #FFC14D; font-weight: 700; }
.foot__open { margin-top: 20px; font: 700 clamp(1.3rem, 2.4vw, 1.7rem)/1.15 var(--display); max-width: 24ch; }
.foot__demo { margin-top: 12px; max-width: 62ch; color: #ABC1D0; font-size: .9rem; }

/* ── Barra de acción en el teléfono ── */
.dock {
  position: fixed; left: 10px; right: 10px; bottom: calc(10px + env(safe-area-inset-bottom)); z-index: 45;
  display: grid; grid-template-columns: 1.15fr 1fr 1fr; gap: 6px; padding: 6px;
  border-radius: 22px; background: color-mix(in srgb, var(--surface) 92%, transparent);
  -webkit-backdrop-filter: blur(16px); backdrop-filter: blur(16px);
  border: 1px solid var(--line); box-shadow: 0 14px 40px -14px rgba(20, 44, 61, .5);
}
.dock a { display: flex; align-items: center; justify-content: center; gap: 7px; min-height: 48px; border-radius: 16px; text-decoration: none; font-weight: 700; font-size: .88rem; }
.dock svg { width: 19px; height: 19px; }
.dock__urgent { background: var(--orange); color: var(--plum); }

/* ── Desde tableta ── */
@media (min-width: 760px) {
  .lema { font-size: clamp(3.2rem, 6.4vw, 5.1rem); }
  .purpose__in { grid-template-columns: auto 1fr; }
  .datos { grid-template-columns: repeat(3, 1fr); align-items: end; }
  .datos .btn { grid-column: 1 / -1; justify-self: start; }
  .agenda__list { columns: 2; column-gap: 34px; }
  .shop__nav { display: flex; }
  .vida { grid-template-columns: repeat(3, 1fr); gap: 28px; }
  .vida::before { left: 60px; right: calc((100% - 56px) / 3 - 60px); top: 60px; bottom: auto; width: auto; height: 4px; margin: -2px 0 0; background: linear-gradient(90deg, #FFDA8E, var(--orange) 45%, var(--purple-soft)); }
  .vida li { grid-template-columns: 1fr; gap: 20px; align-items: start; }
  .vida img { width: 120px; height: 120px; box-shadow: 0 0 0 8px var(--tint); }
  .dock { display: none; }
  .foot { padding-bottom: 64px; }
  .top__call { display: inline-flex; }
  .cart { margin: 0 0 0 auto; width: 440px; height: 100dvh; max-height: none; border-radius: 28px 0 0 28px; }
  .cart[open] { animation-name: drawer; }
  @keyframes drawer { from { transform: translateX(40px); opacity: 0; } }
}

/* ── Escritorio ── */
@media (min-width: 1000px) {
  .nav { display: flex; }
  .top__actions { margin-left: 12px; }
  .hero__in { grid-template-columns: 1.15fr .85fr; }
  .sec__grid { grid-template-columns: .8fr 1.2fr; align-items: start; }
  .sec__grid .sec__head { position: sticky; top: calc(var(--top-h) + 40px); }
  .purpose__photo { width: 360px; }
  .loc { grid-template-columns: .9fr 1.1fr; }
  .loc__map { min-height: 460px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; animation-delay: 0s !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}

/* ═════════ Tienda (/tienda) ═════════ */
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.shop__more { margin-top: clamp(22px, 3vw, 34px); }
.nav a[aria-current="page"] { border-bottom-color: var(--orange); }

.hero--shop { padding-bottom: calc(var(--lift) + clamp(34px, 5vw, 60px)); }
.hero--shop .sky__glow { top: -34%; right: -8%; }
.volver { display: inline-flex; align-items: center; gap: 6px; font-weight: 600; font-size: .95rem; text-decoration: none; padding: 6px 0; }
.volver svg { width: 18px; height: 18px; }
.volver:hover { text-decoration: underline; }
.shop-hero h1 { margin-top: 10px; font: 800 clamp(3rem, 11vw, 5.6rem)/.98 var(--display); letter-spacing: -.03em; }
.shop-hero p { margin-top: 16px; max-width: 44ch; font-size: clamp(1.05rem, 1.6vw, 1.2rem); }
.buscar { position: relative; display: block; margin-top: 26px; max-width: 540px; }
.buscar svg { position: absolute; left: 20px; top: 50%; translate: 0 -50%; width: 21px; height: 21px; color: var(--muted); pointer-events: none; }
.buscar input {
  width: 100%; min-height: 60px; padding: 0 22px 0 54px; border-radius: 999px; border: 2px solid transparent;
  background: var(--surface); color: var(--ink); font-size: 1.04rem; box-shadow: var(--shadow); transition: border-color .2s ease;
}
.buscar input::placeholder { color: var(--muted); }
.buscar input:focus { outline: none; border-color: var(--orange); }

.catalogo { padding-top: clamp(30px, 4vw, 48px); }
.filtros { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 18px; }
.seg { display: inline-flex; padding: 4px; border-radius: 999px; background: var(--tint); transition: background-color .6s ease; }
.seg button { min-height: 44px; padding: 0 20px; border: 0; border-radius: 999px; background: transparent; font-weight: 600; transition: background-color .2s ease, color .2s ease; }
.seg button[aria-pressed="true"] { background: var(--orange); color: var(--plum); }
.cats { display: flex; gap: 8px; max-width: 100%; overflow-x: auto; scrollbar-width: none; padding: 2px; }
.cats::-webkit-scrollbar { display: none; }
.cat {
  flex: none; min-height: 44px; padding: 0 17px; border-radius: 999px; border: 1.5px solid var(--line-strong); background: transparent;
  font-weight: 600; font-size: .96rem; white-space: nowrap; transition: background-color .2s ease, border-color .2s ease, color .2s ease;
}
.cat:hover { border-color: var(--ink); }
.cat[aria-pressed="true"] { background: var(--ink); border-color: var(--ink); color: var(--bg); }
.cuenta { margin-left: auto; color: var(--muted); font-size: .95rem; font-variant-numeric: tabular-nums; }

.grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 30px 14px; margin-top: 28px; }
.grid .prod { width: auto; }
.prod__open { position: absolute; inset: 0; z-index: 1; border: 0; background: none; cursor: pointer; border-radius: inherit; }
.prod__add { z-index: 2; }
.prod__add:disabled { background: #EAF1F6; color: #586B79; cursor: not-allowed; box-shadow: none; }
.badge { position: absolute; left: 12px; top: 12px; z-index: 2; padding: 5px 12px; border-radius: 999px; background: var(--plum); color: #fff; font-weight: 700; font-size: .78rem; pointer-events: none; }
.badge--low { background: #fff; color: var(--plum); }
.prod.is-out .prod__img img { filter: grayscale(.85); opacity: .55; }
.vacio { grid-column: 1 / -1; padding: 36px 0; color: var(--muted); font-size: 1.05rem; max-width: 46ch; }

.asesor {
  display: grid; gap: 22px; align-items: center; margin-top: clamp(48px, 7vw, 84px); padding: clamp(26px, 4vw, 46px);
  border-radius: 34px; background: var(--purple-field); color: #fff; transition: background-color .6s ease;
}
.asesor h2 { font: 700 clamp(1.55rem, 3vw, 2.25rem)/1.08 var(--display); letter-spacing: -.015em; max-width: 20ch; }
.asesor p { margin-top: 10px; color: #CFE5F5; max-width: 46ch; }

/* Ficha del producto */
.pdlg {
  width: 100%; max-width: none; max-height: 92dvh; margin: auto 0 0; padding: 0; border: 0; overflow: auto;
  border-radius: 28px 28px 0 0; background: var(--surface); color: var(--ink);
}
.pdlg::backdrop { background: rgba(10, 26, 37, .6); -webkit-backdrop-filter: blur(3px); backdrop-filter: blur(3px); }
.pdlg[open] { animation: sheet .35s cubic-bezier(.2, .8, .2, 1); }
.pdlg__in { position: relative; display: grid; }
.pdlg__img { background: var(--tint); aspect-ratio: 4 / 3; overflow: hidden; }
.pdlg__img img { width: 100%; height: 100%; object-fit: cover; }
.pdlg__body { padding: 22px clamp(20px, 4vw, 36px) calc(26px + env(safe-area-inset-bottom)); }
.pdlg__close { position: absolute; right: 14px; top: 14px; background: var(--surface); border-color: transparent; box-shadow: 0 6px 16px -6px rgba(0, 0, 0, .4); }
.pdlg__meta { color: var(--muted); font-weight: 600; font-size: .92rem; }
.pdlg h2 { margin-top: 4px; font: 700 clamp(1.55rem, 3vw, 2.1rem)/1.08 var(--display); letter-spacing: -.015em; }
.pdlg__price { margin-top: 12px; font: 800 2.1rem/1 var(--display); font-variant-numeric: tabular-nums; }
.pdlg__desc { margin-top: 14px; color: var(--muted); max-width: 44ch; }
.stock { display: flex; align-items: center; gap: 9px; margin-top: 16px; font-weight: 600; font-size: .96rem; }
.stock::before { content: ""; width: 9px; height: 9px; border-radius: 50%; background: var(--ok); }
.stock--low::before { background: var(--orange); }
.stock--out { color: var(--muted); }
.stock--out::before { background: var(--line-strong); }
.pdlg__buy { display: flex; align-items: center; gap: 12px; margin-top: 22px; }
.pdlg__buy .qty button { width: 44px; height: 52px; }
.pdlg__buy .btn { flex: 1; }
.pdlg__buy .btn:disabled { background: var(--tint); color: var(--muted); box-shadow: none; cursor: not-allowed; }
.pdlg__nota { margin-top: 16px; color: var(--muted); font-size: .9rem; }

@media (min-width: 760px) {
  .grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 44px 24px; }
  .asesor { grid-template-columns: 1fr auto; }
  .pdlg { margin: auto; width: min(92vw, 900px); border-radius: 30px; }
  .pdlg[open] { animation-name: bloom; animation-duration: .3s; }
  .pdlg__in { grid-template-columns: 1fr 1fr; }
  .pdlg__img { aspect-ratio: auto; min-height: 460px; }
  .pdlg__body { align-self: center; padding-block: 40px; }
}
@media (min-width: 1000px) {
  .grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
