/* =========================================================
   RIMALIP — Hoja de estilos
   Colores y tipografías según el Manual de Marca
   ========================================================= */
:root {
  /* Primarios */
  --olive: #6B705C;
  --olive-dark: #575B4A;
  --olive-deep: #3E4135;
  --pearl: #F8F9F5;
  --jet: #151616;
  /* Secundarios */
  --platinum: #B4B7BA;
  --sky: #E0F4F7;

  --text: #2A2C27;
  --muted: #6E716B;
  --line: rgba(107, 112, 92, .18);
  --card: #FFFFFF;

  --font-title: "Cormorant Garamond", Georgia, "Times New Roman", serif;
  --font-body: "Lato", "Nunito", system-ui, -apple-system, "Segoe UI", sans-serif;

  --radius: 22px;
  --radius-sm: 14px;
  --shadow: 0 18px 40px -22px rgba(21, 22, 22, .25);
  --ease: cubic-bezier(.22, 1, .36, 1);
  --container: 1200px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 90px; }
body {
  margin: 0;
  font-family: var(--font-body);
  font-weight: 400;
  color: var(--text);
  background: var(--pearl);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
h1, h2, h3, h4 { font-family: var(--font-title); font-weight: 500; line-height: 1.12; margin: 0; }
p { margin: 0; }
svg { fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }

.container { width: min(100% - 32px, var(--container)); margin-inline: auto; }
.section { padding: clamp(72px, 10vw, 120px) 0; }

/* ---------- Botones ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 14px 26px; border-radius: 999px;
  font: 700 .9rem/1 var(--font-body); letter-spacing: .02em;
  border: 1px solid transparent; cursor: pointer;
  transition: background .3s var(--ease), color .3s var(--ease), transform .3s var(--ease), box-shadow .3s var(--ease);
}
.btn svg { width: 16px; height: 16px; stroke-width: 2.2; transition: transform .3s var(--ease); }
.btn:hover svg { transform: translateX(3px); }
.btn:active { transform: scale(.97); }
.btn--primary { background: var(--olive); color: var(--pearl); }
.btn--primary:hover { background: var(--olive-dark); box-shadow: 0 10px 24px -12px rgba(107,112,92,.8); }
.btn--light { background: var(--pearl); color: var(--olive-deep); }
.btn--light:hover { background: #fff; }

/* ---------- Pills / etiquetas ---------- */
.pill {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 7px 16px; border-radius: 999px;
  border: 1px solid var(--olive); color: var(--olive);
  font-size: .78rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase;
  margin-bottom: 22px;
}
.pill .line { width: 16px; height: 1px; background: currentColor; position: relative; }
.pill .line::after { content: ""; position: absolute; right: -2px; top: -2px; width: 5px; height: 5px; border-radius: 50%; background: currentColor; }
.pill .line:first-child::after { right: auto; left: -2px; }
.pill--glass { border-color: rgba(248,249,245,.35); color: var(--pearl); background: rgba(248,249,245,.08); backdrop-filter: blur(6px); }
.pill--dark { border-color: rgba(224,244,247,.4); color: var(--sky); }
.dot { width: 7px; height: 7px; border-radius: 50%; background: var(--sky); box-shadow: 0 0 0 4px rgba(224,244,247,.18); }

.title { font-size: clamp(2.1rem, 4.2vw, 3.2rem); color: var(--jet); font-weight: 500; }
.title strong { font-weight: 700; color: var(--olive); }
.title--light { color: var(--pearl); }
.title--light strong { color: var(--sky); }
.lead { color: var(--muted); font-size: 1.05rem; font-weight: 300; margin-top: 18px; max-width: 60ch; }
.lead--light { color: rgba(248,249,245,.78); }

.section__head { text-align: center; display: flex; flex-direction: column; align-items: center; margin-bottom: 52px; }
.section__head .lead { margin-inline: auto; }

/* ---------- Cabecera ---------- */
.header {
  position: fixed; inset: 0 0 auto 0; z-index: 50;
  padding: 18px 0;
  transition: background .4s var(--ease), padding .4s var(--ease), box-shadow .4s var(--ease);
}
.header__inner { display: flex; align-items: center; gap: 32px; }
.header__logo { position: relative; display: block; width: 150px; height: 56px; flex-shrink: 0; }
.logo { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; object-position: left center; transition: opacity .4s var(--ease); }
.logo--dark { opacity: 0; }
.nav { display: flex; gap: 30px; margin-left: auto; }
.nav__link { color: rgba(248,249,245,.82); font-size: .93rem; position: relative; padding: 6px 0; transition: color .3s; }
.nav__link::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 2px; border-radius: 2px; background: currentColor; transform: scaleX(0); transition: transform .35s var(--ease); }
.nav__link:hover, .nav__link.is-active { color: var(--pearl); }
.nav__link.is-active::after { transform: scaleX(1); }
.nav__cta-mobile { display: none; }
.header__cta { padding: 12px 22px; }

.header.is-scrolled { background: rgba(248,249,245,.92); backdrop-filter: blur(14px); padding: 10px 0; box-shadow: 0 1px 0 var(--line); }
.header.is-scrolled .logo--light { opacity: 0; }
.header.is-scrolled .logo--dark { opacity: 1; }
.header.is-scrolled .nav__link { color: var(--muted); }
.header.is-scrolled .nav__link:hover, .header.is-scrolled .nav__link.is-active { color: var(--olive); }

.burger { display: none; margin-left: auto; width: 44px; height: 44px; border-radius: 12px; border: 1px solid rgba(248,249,245,.3); background: transparent; cursor: pointer; flex-direction: column; justify-content: center; align-items: center; gap: 5px; }
.burger span { width: 20px; height: 2px; background: var(--pearl); border-radius: 2px; transition: transform .3s var(--ease), opacity .3s; }
.header.is-scrolled .burger { border-color: var(--line); }
.header.is-scrolled .burger span { background: var(--olive); }
.burger[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.burger[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.burger[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ---------- Hero ---------- */
.hero {
  position: relative; overflow: hidden;
  background: var(--jet);
  color: var(--pearl);
  padding: 120px 0 0;
  isolation: isolate;
}
.hero__bg {
  position: absolute; inset: -20px; z-index: -1;
  background:
    radial-gradient(60% 70% at 72% 40%, rgba(107,112,92,.55), transparent 70%),
    linear-gradient(100deg, rgba(21,22,22,.96) 25%, rgba(21,22,22,.72) 60%, rgba(62,65,53,.85)),
    url("../assets/img/equipo-quirurgico.jpg") center 30% / cover no-repeat;
  filter: saturate(.7);
}
.hero__bg::after { content: ""; position: absolute; inset: 0; backdrop-filter: blur(6px); }
.hero__grid { display: grid; grid-template-columns: 1.05fr .95fr; align-items: center; gap: 40px; min-height: calc(100vh - 120px); min-height: calc(100svh - 120px); max-height: 820px; }
.hero__title { font-size: clamp(2.8rem, 6vw, 5.2rem); font-weight: 400; letter-spacing: -.01em; }
.hero__title strong { font-weight: 700; }
.hero__title em { font-style: italic; color: var(--sky); font-weight: 500; }
.hero__text { margin-top: 24px; max-width: 48ch; color: rgba(248,249,245,.75); font-size: 1.08rem; font-weight: 300; }
.hero__actions { display: flex; align-items: center; gap: 26px; margin-top: 38px; flex-wrap: wrap; }
.social { display: flex; align-items: center; gap: 12px; margin-top: 56px; }
.social__label { font-size: .74rem; letter-spacing: .22em; text-transform: uppercase; color: rgba(248,249,245,.55); margin-right: 8px; display: flex; align-items: center; gap: 12px; }
.social__label::after { content: ""; width: 28px; height: 1px; background: rgba(248,249,245,.35); }
.social__link { width: 42px; height: 42px; border-radius: 50%; display: grid; place-items: center; border: 1px solid rgba(248,249,245,.25); color: var(--pearl); transition: background .3s var(--ease), color .3s var(--ease), border-color .3s var(--ease), transform .3s var(--ease); }
.social__link svg { width: 18px; height: 18px; stroke-width: 1.6; }
.social__link:hover { background: var(--pearl); color: var(--olive-deep); border-color: var(--pearl); transform: translateY(-2px); }
.hero__link { display: flex; align-items: center; gap: 12px; line-height: 1.2; font-weight: 700; }
.hero__link small { display: block; font-weight: 300; font-size: .78rem; color: rgba(248,249,245,.6); }
.hero__link-icon { width: 46px; height: 46px; border-radius: 50%; border: 1px solid rgba(248,249,245,.35); display: grid; place-items: center; transition: background .3s, border-color .3s; }
.hero__link-icon svg { width: 18px; height: 18px; }
.hero__link:hover .hero__link-icon { background: rgba(248,249,245,.1); border-color: var(--pearl); }

.hero__visual { position: relative; align-self: end; height: 100%; min-height: 520px; display: flex; justify-content: center; align-items: flex-end; }
.hero__halo {
  position: absolute; bottom: 0; left: 50%; translate: -50% 0;
  width: min(440px, 90%); aspect-ratio: 1; border-radius: 50%;
  background: radial-gradient(circle at 50% 45%, rgba(224,244,247,.22), rgba(107,112,92,.25) 55%, transparent 70%);
  border: 1px solid rgba(224,244,247,.14);
}
.hero__figure {
  position: relative; z-index: 1;
  height: 560px; width: auto; max-width: 100%; object-fit: contain; object-position: bottom;
  margin-bottom: 0;
  filter: drop-shadow(0 30px 40px rgba(0,0,0,.35));
}
.hero__figure.is-illustration { height: min(640px, 78vh); }
@keyframes float { 50% { transform: translateY(-10px); } }

/* Tarjeta de reserva */

/* ---------- Nosotros ---------- */

/* ---------- Diferenciales (sencillo) ---------- */

/* ---------- Cirugías ---------- */
.surgeries { background: linear-gradient(180deg, #EEF7F7 0%, var(--pearl) 100%); }
.slider { position: relative; display: flex; align-items: center; gap: 14px; }
.slider__track {
  display: grid; grid-auto-flow: column; grid-auto-columns: calc((100% - 3 * 22px) / 4);
  gap: 22px; overflow-x: auto; scroll-snap-type: x mandatory; scroll-behavior: smooth;
  padding: 10px 4px 24px; flex: 1;
  scrollbar-width: none;
}
.slider__track::-webkit-scrollbar { display: none; }
.slider__arrow { flex-shrink: 0; width: 46px; height: 46px; border-radius: 50%; border: 1px solid var(--line); background: var(--card); color: var(--olive); cursor: pointer; display: grid; place-items: center; transition: background .3s, color .3s, transform .2s; }
.slider__arrow svg { width: 18px; height: 18px; }
.slider__arrow:hover { background: var(--olive); color: var(--pearl); }
.slider__arrow:active { transform: scale(.94); }

.card {
  scroll-snap-align: start;
  display: flex; flex-direction: column;
  padding: 28px 24px 22px; border-radius: var(--radius);
  background: var(--card); border: 1px solid rgba(107,112,92,.1);
  box-shadow: 0 10px 30px -24px rgba(21,22,22,.35);
  transition: transform .45s var(--ease), box-shadow .45s var(--ease), background .45s var(--ease), color .45s var(--ease);
}
.card__icon { width: 58px; height: 58px; color: var(--olive); margin-bottom: 18px; }
.card__icon svg { width: 100%; height: 100%; stroke-width: 1.6; }
.card h3 { font-size: 1.55rem; font-weight: 700; color: var(--olive-deep); margin-bottom: 10px; }
.card p { font-size: .9rem; color: var(--muted); flex: 1; }
.card__foot { display: flex; align-items: center; justify-content: space-between; margin-top: 24px; padding-top: 16px; border-top: 1px dashed var(--line); font-size: .82rem; font-weight: 700; color: var(--olive-deep); }
.card__foot span::before { content: ""; display: inline-block; width: 6px; height: 6px; border-radius: 50%; background: currentColor; margin-right: 8px; vertical-align: middle; }
.card__go { width: 38px; height: 38px; border-radius: 50%; background: var(--olive); color: var(--pearl); display: grid; place-items: center; transition: transform .35s var(--ease); }
.card__go svg { width: 16px; height: 16px; stroke-width: 2.2; }
.card:hover, .card.is-featured { background: var(--olive); color: var(--pearl); transform: translateY(-6px); box-shadow: 0 26px 40px -24px rgba(62,65,53,.7); }
.card:hover h3, .card.is-featured h3, .card:hover .card__icon, .card.is-featured .card__icon, .card:hover .card__foot, .card.is-featured .card__foot { color: var(--pearl); }
.card:hover p, .card.is-featured p { color: rgba(248,249,245,.8); }
.card:hover .card__foot, .card.is-featured .card__foot { border-color: rgba(248,249,245,.25); }
.card:hover .card__go, .card.is-featured .card__go { background: var(--pearl); color: var(--olive); transform: rotate(45deg); }
.slider__track:hover .card.is-featured:not(:hover) { background: var(--card); transform: none; box-shadow: 0 10px 30px -24px rgba(21,22,22,.35); }
.slider__track:hover .card.is-featured:not(:hover) h3, .slider__track:hover .card.is-featured:not(:hover) .card__foot { color: var(--olive-deep); }
.slider__track:hover .card.is-featured:not(:hover) .card__icon { color: var(--olive); }
.slider__track:hover .card.is-featured:not(:hover) p { color: var(--muted); }
.slider__track:hover .card.is-featured:not(:hover) .card__foot { border-color: var(--line); }
.slider__track:hover .card.is-featured:not(:hover) .card__go { background: var(--olive); color: var(--pearl); transform: none; }
.note { text-align: center; color: var(--muted); font-size: .85rem; margin-top: 18px; }

/* ---------- Proceso ---------- */

/* ---------- Así respondemos ---------- */

/* ---------- FAQ ---------- */
.faq { background: linear-gradient(180deg, var(--pearl), #EEF7F7); }
.faq__wrap { max-width: 860px; }
.faq__list { display: flex; flex-direction: column; gap: 12px; }
.faq__item { background: #fff; border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 0 24px; transition: box-shadow .3s; }
.faq__item[open] { box-shadow: var(--shadow); }
.faq__item summary { list-style: none; cursor: pointer; padding: 22px 36px 22px 0; position: relative; font: 600 1.3rem/1.3 var(--font-title); color: var(--jet); }
.faq__item summary::-webkit-details-marker { display: none; }
.faq__item summary::after { content: "+"; position: absolute; right: 0; top: 50%; translate: 0 -50%; width: 30px; height: 30px; border-radius: 50%; background: var(--sky); color: var(--olive-deep); display: grid; place-items: center; font: 400 1.2rem/1 var(--font-body); transition: transform .3s var(--ease); }
.faq__item[open] summary::after { transform: rotate(45deg); }
.faq__item p { padding-bottom: 22px; color: var(--muted); }

/* ---------- CTA ---------- */
.cta { position: relative; padding: 90px 0; background: var(--olive) url("../assets/img/hojas.jpg") right center / cover no-repeat; background-blend-mode: multiply; }
.cta__inner { display: flex; flex-direction: column; gap: 40px; }
.cta .title { max-width: 22ch; }
.cta .booking { background: rgba(21,22,22,.28); }
.cta .booking__btn { color: var(--olive-deep); }

/* ---------- Pie ---------- */
.footer { background: var(--jet); color: rgba(248,249,245,.7); padding: 70px 0 28px; font-size: .92rem; }
.footer__grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1.1fr 1fr; gap: 36px; }
.footer__brand img { width: 170px; margin-bottom: 18px; }
.footer__brand p { max-width: 34ch; }
.footer h4 { color: var(--pearl); font-size: 1.25rem; font-weight: 600; margin-bottom: 16px; }
.footer ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.footer a:hover { color: var(--sky); }
.footer__bottom { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-top: 54px; padding-top: 24px; border-top: 1px solid rgba(248,249,245,.1); font-size: .8rem; color: rgba(248,249,245,.5); }

/* ---------- Animación de entrada ---------- */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity .9s var(--ease), transform .9s var(--ease); }
.reveal--delay { transition-delay: .15s; }
.reveal.is-visible { opacity: 1; transform: none; }
.no-js .reveal { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
}

/* ---------- Responsive ---------- */
@media (max-width: 1080px) {
  .slider__track { grid-auto-columns: calc((100% - 2 * 22px) / 3); }
  .nav { gap: 22px; }
}
@media (max-width: 920px) {
  .header__cta { display: none; }
  .burger { display: flex; }
  .nav {
    position: fixed; inset: 0 0 0 auto; width: min(320px, 85vw);
    flex-direction: column; gap: 6px; padding: 100px 28px 28px;
    background: var(--pearl); box-shadow: -20px 0 40px -20px rgba(0,0,0,.3);
    transform: translateX(100%); transition: transform .45s var(--ease);
  }
  .nav.is-open { transform: none; }
  .nav .nav__link { color: var(--text); font-size: 1.05rem; padding: 12px 0; border-bottom: 1px solid var(--line); }
  .nav .nav__link::after { display: none; }
  .nav .nav__link.is-active { color: var(--olive); }
  .nav__cta-mobile { display: inline-flex; justify-content: center; margin-top: 18px; }
  .burger { position: relative; z-index: 2; }
  .header:has(.nav.is-open) .burger span { background: var(--olive); }

  .hero__grid { text-align: center; }
  .hero__content { display: flex; flex-direction: column; align-items: center; }
  .hero__actions { justify-content: center; }
  /* Móvil y tablet: la figura pasa a ser fondo detrás del texto */
  .hero { padding: 0; }
  .hero__grid { position: relative; display: flex; flex-direction: column; justify-content: center; min-height: 100vh; min-height: 100svh; max-height: none; padding: 110px 0 60px; }
  .hero__content { position: relative; z-index: 2; }
  .hero__visual { position: absolute; inset: 0; min-height: 0; height: auto; z-index: 0; pointer-events: none; align-items: flex-end; }
  .hero__visual.reveal, .hero__visual.reveal.is-visible { opacity: .3; }
  .hero__content { max-width: 600px; margin-inline: auto; }
  .hero__halo { width: min(520px, 110%); bottom: 4%; }
  .hero__figure, .hero__figure.is-illustration { height: 88%; max-height: 760px; filter: none; }
  .hero__title, .hero__text { text-shadow: 0 2px 18px rgba(21,22,22,.55); }
  .social { justify-content: center; margin-top: 36px; }
  .footer__grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 640px) {
  .slider__track { grid-auto-columns: 82%; }
  .slider__arrow { display: none; }
  .social { justify-content: center; }
  .footer__grid { grid-template-columns: 1fr; }
}
@media (max-width: 420px) { .social__label { display: none; } }

/* =========================================================
   RESULTADOS — galería difuminada con aviso +18
   ========================================================= */
.results { background: #fff; }
.btn--ghost { background: transparent; color: var(--olive-deep); border-color: var(--line); }
.btn--ghost:hover { border-color: var(--olive); }

.filters { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin-bottom: 32px; }
.filter {
  padding: 10px 20px; border-radius: 999px; border: 1px solid var(--line);
  background: var(--pearl); color: var(--olive-deep); cursor: pointer;
  font: 700 .82rem/1 var(--font-body); letter-spacing: .04em;
  transition: background .3s var(--ease), color .3s var(--ease), border-color .3s var(--ease);
}
.filter:hover { border-color: var(--olive); }
.filter.is-active { background: var(--olive); border-color: var(--olive); color: var(--pearl); }

.gallery-wrap { position: relative; border-radius: var(--radius); }
.gallery { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.gallery__item { margin: 0; position: relative; border-radius: var(--radius-sm); overflow: hidden; background: var(--jet); aspect-ratio: 3 / 4; }
.gallery__item[hidden] { display: none; }
.gallery__open { all: unset; display: block; width: 100%; height: 100%; cursor: zoom-in; }
.gallery__open:focus-visible { outline: 3px solid var(--olive); outline-offset: -3px; }
.gallery__item img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s var(--ease), filter .6s var(--ease); }
.gallery__item:hover img { transform: scale(1.04); }
.gallery__item figcaption {
  position: absolute; left: 0; right: 0; bottom: 0; padding: 28px 14px 12px;
  color: var(--pearl); font-size: .78rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase;
  background: linear-gradient(transparent, rgba(21,22,22,.75)); pointer-events: none;
}

/* Estado bloqueado: fotos tapadas */
.gallery-wrap.is-locked .gallery { pointer-events: none; user-select: none; }
.gallery-wrap.is-locked .gallery__item img { filter: blur(26px) saturate(.6) brightness(.85); transform: scale(1.15); }
.gallery-wrap.is-locked .gallery__item figcaption { opacity: 0; }
.gallery-wrap.is-locked .gallery { max-height: 640px; overflow: hidden; }

.age-gate {
  position: absolute; inset: 0; display: grid; place-items: center; padding: 16px;
  background: rgba(21,22,22,.35); border-radius: var(--radius); z-index: 2;
  transition: opacity .4s var(--ease), visibility .4s;
}
.gallery-wrap:not(.is-locked) .age-gate { opacity: 0; visibility: hidden; }
.age-gate__card {
  max-width: 460px; text-align: center; background: var(--pearl); color: var(--text);
  padding: 34px 28px; border-radius: var(--radius); box-shadow: 0 30px 60px -20px rgba(0,0,0,.5);
}
.age-gate__badge {
  display: inline-grid; place-items: center; width: 58px; height: 58px; border-radius: 50%;
  border: 2px solid var(--olive); color: var(--olive); font: 700 1.1rem/1 var(--font-body); margin-bottom: 14px;
}
.age-gate__card h3 { font-size: 1.9rem; margin-bottom: 10px; }
.age-gate__card p { color: var(--muted); margin-bottom: 22px; }
.age-gate__actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin-bottom: 16px; }
.age-gate__card small { display: block; color: var(--muted); font-size: .76rem; }

/* Visor */
.lightbox {
  position: fixed; inset: 0; z-index: 9999; display: grid; grid-template-columns: auto 1fr auto;
  align-items: center; gap: 8px; padding: 20px; background: rgba(21,22,22,.94);
}
.lightbox[hidden] { display: none; }
.lightbox__figure { margin: 0; display: flex; flex-direction: column; align-items: center; gap: 12px; min-width: 0; }
.lightbox__figure img { max-height: 84vh; max-width: 100%; border-radius: var(--radius-sm); object-fit: contain; }
.lightbox__figure figcaption { color: var(--pearl); font-size: .85rem; letter-spacing: .06em; text-transform: uppercase; }
.lightbox__nav, .lightbox__close {
  width: 48px; height: 48px; border-radius: 50%; border: 1px solid rgba(248,249,245,.3);
  background: rgba(248,249,245,.08); color: var(--pearl); cursor: pointer; display: grid; place-items: center;
}
.lightbox__nav:hover, .lightbox__close:hover { background: rgba(248,249,245,.2); }
.lightbox__nav svg, .lightbox__close svg { width: 22px; height: 22px; }
.lightbox__close { position: absolute; top: 16px; right: 16px; z-index: 1; }

@media (max-width: 900px) { .gallery { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 600px) {
  .gallery { grid-template-columns: repeat(2, 1fr); gap: 10px; }
  .gallery-wrap.is-locked .gallery { max-height: 560px; }
  .age-gate__card { padding: 26px 20px; }
  .lightbox { grid-template-columns: 1fr; padding: 70px 12px 12px; }
  .lightbox__nav { position: absolute; bottom: 20px; }
  .lightbox__nav--prev { left: calc(50% - 60px); }
  .lightbox__nav--next { right: calc(50% - 60px); }
  .lightbox__figure img { max-height: 72vh; }
}
@media (prefers-reduced-motion: reduce) {
  .gallery__item img, .age-gate { transition: none; }
}

/* ---------- Tarjetas de servicios: número y enlace a resultados ---------- */
.card { position: relative; }
.card__num { position: absolute; top: 24px; right: 24px; font: 600 1.1rem/1 var(--font-title); color: var(--platinum); }
.card__link { margin-top: 16px; font-size: .84rem; font-weight: 700; color: var(--olive); align-self: flex-start; border-bottom: 1px solid transparent; transition: border-color .3s; }
.card__link:hover { border-color: currentColor; }
.card:hover .card__link, .card.is-featured .card__link, .card:hover .card__num, .card.is-featured .card__num { color: var(--sky); }
.slider__track:hover .card.is-featured:not(:hover) .card__link { color: var(--olive); }
.slider__track:hover .card.is-featured:not(:hover) .card__num { color: var(--platinum); }

/* ---------- Etiqueta +18 ---------- */
.age-tag { display: inline-grid; place-items: center; min-width: 34px; height: 22px; padding: 0 6px; border-radius: 999px; background: #8C2F2F; color: #fff; font: 700 .7rem/1 var(--font-body); letter-spacing: .02em; vertical-align: middle; }
.age-tag--lg { min-width: 60px; height: 60px; border-radius: 50%; font-size: 1.1rem; margin-bottom: 10px; }

/* ---------- Adelanto de resultados (portada) ---------- */
.results__grid { display: grid; grid-template-columns: 1fr 1.1fr; gap: clamp(32px, 6vw, 72px); align-items: center; }
.results__text .lead { margin-bottom: 18px; }
.results__mosaic { position: relative; display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; border-radius: var(--radius); overflow: hidden; }
.results__mosaic img { width: 100%; aspect-ratio: 3 / 4; object-fit: cover; border-radius: var(--radius-sm); filter: blur(22px) saturate(.6) brightness(.8); transform: scale(1.1); }
.results__lock { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; color: var(--pearl); font: 500 1.9rem/1.1 var(--font-title); background: rgba(21,22,22,.25); transition: background .3s; }
.results__lock small { font: 400 .85rem/1.4 var(--font-body); margin-top: 8px; opacity: .85; }
.results__mosaic:hover .results__lock { background: rgba(21,22,22,.4); }

/* ---------- WhatsApp flotante ---------- */
.wa-float { position: fixed; right: 18px; bottom: 18px; z-index: 60; width: 56px; height: 56px; border-radius: 50%; background: #25D366; color: #fff; display: grid; place-items: center; box-shadow: 0 12px 28px -10px rgba(0,0,0,.45); transition: transform .3s var(--ease); }
.wa-float:hover { transform: scale(1.06); }
.wa-float svg { width: 28px; height: 28px; stroke-width: 1.8; }
.footer__legal a { text-decoration: underline; text-underline-offset: 3px; }

@media (max-width: 900px) { .results__grid { grid-template-columns: 1fr; } }

/* =========================================================
   CHAT GUIADO DE WHATSAPP + NOTIFICACIÓN
   ========================================================= */
.wa-chat { position: fixed; right: 22px; bottom: 22px; z-index: 60; margin-bottom: env(safe-area-inset-bottom); display: flex; flex-direction: column; align-items: flex-end; gap: 12px; }
.wa-chat__boton {
  position: relative; width: 62px; height: 62px; border-radius: 50%; border: 0; cursor: pointer;
  background: #25D366; color: #fff; display: grid; place-items: center;
  box-shadow: 0 14px 30px -10px rgba(0,0,0,.45); transition: transform .3s var(--ease), background .3s;
}
.wa-chat__boton svg { width: 32px; height: 32px; stroke-width: 1.6; }
.wa-chat__boton:active { transform: scale(.94); }
.wa-chat.is-open .wa-chat__boton { background: #1DA851; }
@media (hover: hover) { .wa-chat__boton:hover { transform: translateY(-3px); } }
.wa-chat__boton:focus-visible, .wa-chat__icono:focus-visible { outline: 2px solid var(--olive); outline-offset: 3px; }
.wa-chat__globo {
  position: absolute; top: -2px; right: -2px; min-width: 22px; height: 22px; padding: 0 6px; border-radius: 999px;
  background: #E53935; color: #fff; font: 700 .75rem/22px var(--font-body); border: 2px solid #fff;
  animation: wa-latido 1.6s ease-in-out 3;
}
.wa-chat__globo[hidden] { display: none; }
@keyframes wa-latido { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.18); } }

/* notificación */
.wa-aviso {
  position: relative; width: min(330px, calc(100vw - 32px)); display: flex; align-items: flex-start;
  background: #fff; border-radius: 18px; box-shadow: 0 20px 44px -16px rgba(21,22,22,.45); border: 1px solid var(--line);
  opacity: 0; transform: translateY(10px) scale(.97); transform-origin: bottom right;
  transition: opacity .25s var(--ease), transform .3s var(--ease);
}
.wa-aviso.is-visible { opacity: 1; transform: none; }
.wa-aviso[hidden] { display: none; }
.wa-aviso::after { content: ""; position: absolute; right: 24px; bottom: -7px; width: 14px; height: 14px; background: #fff; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); transform: rotate(45deg); }
.wa-aviso__abrir { all: unset; cursor: pointer; display: flex; gap: 12px; padding: 14px 8px 14px 14px; flex: 1; font-size: .88rem; line-height: 1.4; color: var(--text); }
.wa-aviso__abrir img { width: 40px; height: 40px; border-radius: 50%; flex: none; background: var(--pearl); }
.wa-aviso__texto { display: flex; flex-direction: column; gap: 2px; }
.wa-aviso__de { display: flex; align-items: baseline; gap: 8px; }
.wa-aviso__de strong { color: var(--olive-deep); }
.wa-aviso__de small { color: var(--muted); font-size: .72rem; }
.wa-aviso__x { flex: none; width: 32px; height: 32px; margin: 6px 6px 0 0; border: 0; border-radius: 50%; background: transparent; color: var(--muted); cursor: pointer; display: grid; place-items: center; }
.wa-aviso__x:hover { background: var(--pearl); color: var(--text); }
.wa-aviso__x svg { width: 16px; height: 16px; }

/* panel del chat */
.wa-chat__panel {
  position: absolute; right: 0; bottom: 76px; width: 360px; max-height: min(560px, calc(100vh - 120px));
  display: flex; flex-direction: column; overflow: hidden; border-radius: 20px; background: #EFEDE6;
  box-shadow: 0 30px 60px -20px rgba(21,22,22,.5); opacity: 0; transform: translateY(12px) scale(.98); transform-origin: bottom right;
  transition: opacity .22s var(--ease), transform .26s var(--ease);
}
.wa-chat__panel[hidden] { display: none; }
.wa-chat.is-open .wa-chat__panel { opacity: 1; transform: none; }
.wa-chat__cabecera { display: flex; align-items: center; gap: 12px; padding: 14px 12px 14px 16px; background: var(--olive-deep); color: var(--pearl); }
.wa-chat__cabecera img { width: 36px; height: 36px; border-radius: 50%; background: var(--pearl); flex: none; }
.wa-chat__titulo { flex: 1; min-width: 0; }
.wa-chat__titulo strong { display: block; font: 500 1.15rem/1.2 var(--font-title); }
.wa-chat__titulo small { display: inline-flex; align-items: center; gap: 6px; font-size: .76rem; color: rgba(248,249,245,.75); }
.wa-chat__enlinea { width: 8px; height: 8px; border-radius: 50%; background: #4CC77A; box-shadow: 0 0 0 3px rgba(76,199,122,.25); }
.wa-chat__icono { flex: none; width: 34px; height: 34px; border-radius: 50%; border: 0; background: transparent; color: rgba(248,249,245,.8); display: grid; place-items: center; cursor: pointer; }
.wa-chat__icono:hover { background: rgba(248,249,245,.12); color: var(--pearl); }
.wa-chat__icono svg { width: 18px; height: 18px; }
.wa-chat__mensajes { flex: 1; min-height: 180px; overflow-y: auto; padding: 16px; display: flex; flex-direction: column; gap: 8px; }
.wa-chat__msg { max-width: 85%; padding: 10px 14px; border-radius: 16px; font-size: .9rem; line-height: 1.45; animation: wa-entra .24s var(--ease) both; }
.wa-chat__msg--asesora { align-self: flex-start; background: #fff; color: var(--text); border-bottom-left-radius: 5px; }
.wa-chat__msg--yo { align-self: flex-end; background: var(--olive); color: var(--pearl); border-bottom-right-radius: 5px; }
.wa-chat__escribiendo { display: inline-flex; gap: 4px; padding: 13px 14px; }
.wa-chat__escribiendo span { width: 6px; height: 6px; border-radius: 50%; background: var(--olive); opacity: .35; animation: wa-punto .9s infinite ease-in-out; }
.wa-chat__escribiendo span:nth-child(2) { animation-delay: .15s; }
.wa-chat__escribiendo span:nth-child(3) { animation-delay: .3s; }
@keyframes wa-entra { from { opacity: 0; transform: translateY(6px); } }
@keyframes wa-punto { 0%, 60%, 100% { opacity: .35; transform: none; } 30% { opacity: 1; transform: translateY(-3px); } }
.wa-chat__respuestas { display: flex; flex-wrap: wrap; gap: 7px; padding: 12px 16px; border-top: 1px solid var(--line); background: var(--pearl); }
.wa-chat__respuestas:empty { display: none; }
.wa-chat__respuestas button { padding: 8px 14px; border-radius: 999px; border: 1px solid var(--olive); background: #fff; color: var(--olive-deep); font: 700 .82rem/1.2 var(--font-body); cursor: pointer; transition: background .2s, color .2s; }
.wa-chat__respuestas button:hover { background: var(--olive); color: var(--pearl); }
.wa-chat__respuestas .wa-chat__ir { width: 100%; display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 13px; background: #25D366; border-color: #25D366; color: #fff; font-size: .92rem; }
.wa-chat__ir svg { width: 18px; height: 18px; }
.wa-chat__entrada { display: flex; gap: 8px; padding: 12px 16px; border-top: 1px solid var(--line); background: var(--pearl); }
.wa-chat__entrada[hidden] { display: none; }
.wa-chat__entrada input { flex: 1; min-width: 0; height: 44px; padding: 0 16px; border-radius: 999px; border: 1px solid var(--line); background: #fff; font: 400 16px var(--font-body); color: var(--text); }
.wa-chat__entrada input:focus { outline: none; border-color: var(--olive); }
.wa-chat__entrada button { flex: none; width: 44px; height: 44px; border-radius: 50%; border: 0; background: var(--olive); color: var(--pearl); display: grid; place-items: center; cursor: pointer; }
.wa-chat__entrada button svg { width: 18px; height: 18px; }
.wa-chat__legal { margin: 0; padding: 8px 16px 12px; font-size: .72rem; line-height: 1.45; color: var(--muted); background: var(--pearl); }
.wa-chat__legal a { color: var(--olive-deep); font-weight: 700; text-decoration: underline; }
@media (max-width: 600px) {
  .wa-chat { right: 16px; bottom: 16px; }
  .wa-chat__panel { position: fixed; left: 12px; right: 12px; bottom: 92px; width: auto; max-height: calc(100svh - 110px); }
}
@media (prefers-reduced-motion: reduce) {
  .wa-chat__msg, .wa-chat__globo { animation: none; }
  .wa-chat__escribiendo span { animation-duration: 1.6s; }
}

/* =========================================================
   SEDES
   ========================================================= */
.sedes { background: #fff; }
.sedes__grid { display: grid; grid-template-columns: 360px 1fr; gap: 28px; align-items: stretch; }
.sedes__lista { display: flex; flex-direction: column; gap: 12px; }
.sede { all: unset; box-sizing: border-box; cursor: pointer; display: block; padding: 20px 22px; border-radius: var(--radius-sm); border: 1px solid var(--line); background: var(--pearl); transition: background .3s, border-color .3s, color .3s; }
.sede:hover { border-color: var(--olive); }
.sede:focus-visible { outline: 2px solid var(--olive); outline-offset: 2px; }
.sede h3 { font-size: 1.6rem; color: var(--olive-deep); margin-bottom: 4px; }
.sede p { font-size: .88rem; color: var(--muted); }
.sede__piso { display: inline-block; margin-top: 8px; padding: 3px 10px; border-radius: 999px; background: rgba(107,112,92,.12); color: var(--olive-deep); font-size: .74rem; font-weight: 700; letter-spacing: .04em; }
.sede.is-active { background: var(--olive); border-color: var(--olive); }
.sede.is-active h3 { color: var(--pearl); }
.sede.is-active p { color: rgba(248,249,245,.8); }
.sede.is-active .sede__piso { background: rgba(248,249,245,.18); color: var(--pearl); }
.sedes__mapa { position: relative; min-height: 420px; border-radius: var(--radius); overflow: hidden; background: var(--pearl); border: 1px solid var(--line); }
.sedes__mapa iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.sedes__ir { position: absolute; left: 16px; bottom: 16px; z-index: 1; }
@media (max-width: 900px) {
  .sedes__grid { grid-template-columns: 1fr; }
  .sedes__lista { display: grid; grid-template-columns: repeat(2, 1fr); }
  .sedes__mapa { min-height: 340px; }
}
@media (max-width: 600px) { .sedes__lista { grid-template-columns: 1fr; } }

/* ---------- Aviso de cookies ---------- */
.cookies {
  position: fixed; left: 22px; bottom: 22px; z-index: 70; width: min(420px, calc(100% - 44px));
  padding: 22px 22px 18px; border-radius: var(--radius); background: #fff; color: var(--text);
  box-shadow: 0 24px 60px -20px rgba(21,22,22,.45); border: 1px solid var(--line);
  opacity: 0; transform: translateY(16px); pointer-events: none;
  transition: opacity .35s var(--ease), transform .35s var(--ease);
}
.cookies.is-visible { opacity: 1; transform: none; pointer-events: auto; }
.cookies__titulo { display: block; font: 500 1.35rem/1.2 var(--font-title); color: var(--olive-deep); margin-bottom: 6px; }
.cookies p { font-size: .86rem; line-height: 1.55; margin-bottom: 16px; color: var(--muted); }
.cookies p a { color: var(--olive-deep); font-weight: 700; text-decoration: underline; text-underline-offset: 3px; }
.cookies__botones { display: flex; flex-wrap: wrap; gap: 8px; }
.cookies__btn {
  flex: 1 1 auto; padding: 11px 16px; border-radius: 999px; border: 1.5px solid var(--line); background: transparent;
  font: 700 .84rem/1 var(--font-body); color: var(--olive-deep); cursor: pointer;
  transition: background .25s var(--ease), color .25s var(--ease), border-color .25s var(--ease), transform .2s var(--ease);
}
.cookies__btn:active { transform: scale(.97); }
.cookies__btn:hover { border-color: var(--olive); }
.cookies__btn--principal { background: var(--olive); border-color: var(--olive); color: var(--pearl); }
.cookies__btn--principal:hover { background: var(--olive-dark); }
.cookies__btn:focus-visible { outline: 2px solid var(--olive); outline-offset: 2px; }
@media (max-width: 600px) {
  .cookies { left: 12px; right: 12px; bottom: 12px; width: auto; padding: 18px 16px 16px; }
  body.cookies-abierto .wa-chat { opacity: 0; pointer-events: none; }
}

/* redes por sede (pie) */
.footer__redes li { display: flex; flex-direction: column; }
.footer__redes small { opacity: .6; font-size: .72rem; }

/* ---------- Contacto: solo WhatsApp ---------- */
.wa-cta {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-start; gap: 28px;
  padding: 28px 32px; border-radius: var(--radius); background: rgba(21,22,22,.28);
  border: 1px solid rgba(248,249,245,.18); backdrop-filter: blur(18px);
}
.wa-cta__acciones { display: flex; flex-direction: column; align-items: flex-start; gap: 10px; }
.wa-cta__btn { background: #25D366; color: #fff; padding: 16px 28px; font-size: 1rem; }
.wa-cta__btn:hover { background: #1DA851; color: #fff; }
.wa-cta__btn svg { width: 22px; height: 22px; stroke-width: 1.8; }
.wa-cta__btn:hover svg { transform: none; }
.wa-cta__nums { font-size: .85rem; color: rgba(248,249,245,.75); }
.wa-cta__nums a { color: var(--pearl); text-decoration: underline; text-underline-offset: 3px; }
@media (max-width: 600px) { .wa-cta { padding: 22px 18px; } .wa-cta__btn { width: 100%; justify-content: center; } }

/* =========================================================
   NOSOTROS (rediseño): intro + mosaico de fotos + pilares
   ========================================================= */
.nos { background: var(--pearl); }
.nos__top { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr); gap: clamp(40px, 6vw, 84px); align-items: center; }
.nos__intro .title { font-size: clamp(2.4rem, 4.4vw, 3.6rem); }
.nos__quote { margin: 30px 0 0; padding: 4px 0 4px 22px; border-left: 2px solid var(--olive); }
.nos__quote p { font: 500 clamp(1.35rem, 2vw, 1.65rem)/1.3 var(--font-title); color: var(--olive-deep); }
.nos__quote cite { display: block; margin-top: 8px; font-style: normal; font-size: .85rem; color: var(--muted); }

.nos__mosaic { position: relative; display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); grid-template-rows: 150px 150px 150px 150px; gap: 14px; }
.nos__ph { margin: 0; border-radius: var(--radius); overflow: hidden; background: var(--jet); }
.nos__ph img { width: 100%; height: 100%; object-fit: cover; transition: transform .8s var(--ease); }
.nos__ph:hover img { transform: scale(1.04); }
.nos__ph--a { grid-column: 1 / 5; grid-row: 1 / 4; }
.nos__ph--b { grid-column: 5 / 7; grid-row: 2 / 5; }
.nos__ph--c { grid-column: 2 / 5; grid-row: 4 / 5; }
.nos__sello {
  grid-column: 5 / 7; grid-row: 1 / 2; align-self: stretch;
  display: flex; align-items: center; justify-content: center; padding: 18px;
  border-radius: var(--radius); background: var(--olive); color: var(--pearl);
}
.nos__sello img { width: 120px; }

/* Misión y visión */

@media (max-width: 900px) {
  .nos__top { grid-template-columns: minmax(0, 1fr); }
  .nos__mosaic { grid-template-rows: 120px 120px 120px 120px; }
}
@media (max-width: 600px) {
  .nos__mosaic { grid-template-rows: 90px 90px 90px 90px; gap: 10px; }
  .nos__sello { padding: 12px; }
  .nos__sello img { width: 80px; }
}
@media (prefers-reduced-motion: reduce) { .nos__ph img { transition: none; } }


/* =========================================================
   PROCESO: 5 pasos agrupados en antes / durante / después
   ========================================================= */
.process { background: var(--pearl); }
.process .section__head { margin-bottom: 44px; }
.fases { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 0 28px; margin-bottom: 26px; }
.fase { position: relative; padding-bottom: 14px; font: 500 1.5rem/1 var(--font-title); color: var(--olive-deep); }
.fase::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 3px; border-radius: 3px; background: var(--sky); }
.fase--antes { grid-column: 1 / 4; }
.fase--antes::after { background: rgba(107,112,92,.35); }
.fase--durante { grid-column: 4 / 5; }
.fase--durante::after { background: var(--olive); }
.fase--despues { grid-column: 5 / 6; }
.fase--despues::after { background: var(--olive-deep); }
.pasos { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 28px; }
.paso { display: flex; flex-direction: column; gap: 10px; }
.paso__fase { display: none; }
.paso__num { font: 500 clamp(3rem, 5vw, 4.4rem)/.9 var(--font-title); color: var(--olive); margin-bottom: 6px; }
.paso h3 { font-size: 1.5rem; color: var(--olive-deep); overflow-wrap: break-word; min-width: 0; }
.paso p { font-size: .92rem; color: var(--muted); }
@media (max-width: 900px) {
  .fases { display: none; }
  .pasos { grid-template-columns: minmax(0, 1fr); gap: 0; }
  .paso { display: grid; grid-template-columns: 72px minmax(0, 1fr); gap: 4px 16px; padding: 22px 0; border-top: 1px solid var(--line); }
  .paso:first-child { border-top: 0; }
  .paso__num { grid-row: 1 / 4; font-size: 3rem; }
  .paso__fase { display: inline-block; justify-self: start; padding: 3px 10px; border-radius: 999px; background: var(--sky); color: var(--olive-deep); font-size: .75rem; font-weight: 700; }
}

/* Misión y visión */
.mvv { background: var(--olive-deep) url("../assets/img/hojas.jpg") right center / cover no-repeat; background-blend-mode: multiply; color: var(--pearl); padding: clamp(64px, 8vw, 100px) 0; }
.mvv__grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(32px, 5vw, 72px); align-items: start; }
.mvv__label { font: 700 .9rem/1 var(--font-body); color: var(--sky); margin-bottom: 16px; }
.mvv__item p { font: 400 clamp(1.4rem, 2.2vw, 1.9rem)/1.35 var(--font-title); }
@media (max-width: 900px) { .mvv__grid { grid-template-columns: minmax(0, 1fr); } }
