/* =========================================================
   Planiodont · landing pública
   Sistema: azul rey del logo (#0047BA), tinta azul noche,
   fondo papel frío. Gambarino (títulos) + General Sans (texto).
   Espaciado en múltiplos de 8 px.
   ========================================================= */

:root {
  /* Color */
  --brand: #0047BA;          /* azul del logo: acción principal */
  --brand-press: #003A99;
  --bg: #F4F6FA;             /* papel frío */
  --surface: #E7ECF4;        /* un escalón más oscuro */
  --paper: #FFFFFF;
  --ink: #0A1A33;            /* azul noche: texto */
  --muted: #3F4B63;          /* texto secundario (7.6:1 sobre --bg) */
  --field: #0047BA;          /* campo de color completo */
  --on-field: #FFFFFF;
  --on-field-soft: #DCE6FA;
  --deep: #061F4D;           /* fondo del pie */
  --pend-bg: #FFF0B3;        /* marcador de dato pendiente */
  --pend-ink: #4A3A00;

  /* Tipo */
  --font-display: "Gambarino", "Iowan Old Style", Georgia, serif;
  --font-text: "General Sans", "Segoe UI", system-ui, -apple-system, sans-serif;
  --step-small: clamp(0.8125rem, 0.79rem + 0.1vw, 0.875rem);
  --step-body: clamp(1.0625rem, 1rem + 0.25vw, 1.1875rem);
  --step-lead: clamp(1.25rem, 1.1rem + 0.7vw, 1.625rem);
  --step-head: clamp(2.25rem, 1.3rem + 3.6vw, 4.25rem);
  --step-hero: clamp(3.5rem, 1.6rem + 6.4vw, 7rem);
  --step-sub: clamp(2rem, 1.4rem + 2vw, 3rem);
  --step-item: clamp(1.625rem, 1.2rem + 1.4vw, 2.5rem);

  /* Espacio (8 px) */
  --s1: 8px; --s2: 16px; --s3: 24px; --s4: 32px; --s5: 40px; --s6: 48px;
  --s8: 64px; --s10: 80px; --s12: 96px; --s15: 120px; --s20: 160px;
  --margin: clamp(16px, 4vw, 56px);
  --gap: clamp(16px, 2vw, 32px);
  --section: clamp(96px, 12vw, 184px);

  /* Forma */
  --radius-card: 8px;
  --pill: 999px;

  /* Movimiento */
  --ease-out: cubic-bezier(.16, 1, .3, 1);
  --ease-io: cubic-bezier(.65, 0, .35, 1);
}

/* ---------- Fuentes (servidas desde el propio sitio) ---------- */
@font-face { font-family: "Gambarino"; src: url("../fonts/gambarino-400.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: "General Sans"; src: url("../fonts/general-sans-400.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: "General Sans"; src: url("../fonts/general-sans-500.woff2") format("woff2"); font-weight: 500; font-style: normal; font-display: swap; }
@font-face { font-family: "General Sans"; src: url("../fonts/general-sans-600.woff2") format("woff2"); font-weight: 600; font-style: normal; font-display: swap; }

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html, body { overflow-x: clip; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 80px; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-text);
  font-size: var(--step-body);
  line-height: 1.55;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}
img, video, svg { display: block; max-width: 100%; }
img { height: auto; }
figure { margin: 0; }
h1, h2, h3, p, ul, ol, dl, dd { margin: 0; }
ul[role="list"], ol[role="list"] { list-style: none; padding: 0; }
a { color: inherit; }
button, input { font: inherit; color: inherit; }
::selection { background: var(--brand); color: #fff; }
:focus-visible { outline: 3px solid var(--brand); outline-offset: 3px; border-radius: 4px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

.skip {
  position: absolute; left: var(--margin); top: -80px; z-index: 100;
  background: var(--ink); color: #fff; padding: 12px 20px; border-radius: var(--pill); text-decoration: none;
}
.skip:focus { top: 12px; }

/* Datos pendientes: visibles a propósito hasta que la clínica los confirme */
mark.pendiente {
  background: var(--pend-bg); color: var(--pend-ink);
  padding: 0.05em 0.35em; border-radius: 4px; font-weight: 500;
  box-decoration-break: clone; -webkit-box-decoration-break: clone;
}

/* ---------- Tipo ---------- */
.t-head {
  font-family: var(--font-display); font-weight: 400;
  font-size: var(--step-head); line-height: 0.98; letter-spacing: -0.02em;
  text-wrap: balance;
}
.t-item {
  font-family: var(--font-display); font-weight: 400;
  font-size: var(--step-item); line-height: 1; letter-spacing: -0.015em;
}
.t-lead { font-size: var(--step-lead); line-height: 1.4; max-width: 34ch; text-wrap: pretty; }
.t-statement {
  font-family: var(--font-display); font-size: clamp(1.375rem, 1rem + 1.1vw, 2.125rem);
  line-height: 1.15; letter-spacing: -0.01em; max-width: 24ch; text-wrap: balance;
}

/* ---------- Botones ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 48px; padding: 0 26px; border-radius: var(--pill); border: 0;
  font-weight: 500; font-size: var(--step-body); text-decoration: none; cursor: pointer;
  transition: transform .25s var(--ease-out), background-color .2s ease, color .2s ease;
}
.btn:active { transform: scale(.97); }
.btn--lg { min-height: 56px; padding: 0 32px; font-size: var(--step-body); }
.btn--block { width: 100%; }
.btn--accent { background: var(--brand); color: #fff; }
.btn--accent:hover { background: var(--brand-press); }
.btn--paper { background: var(--paper); color: var(--brand); }
.btn--paper:hover { background: var(--surface); }
.link {
  font-weight: 500; text-decoration: underline; text-decoration-thickness: 2px;
  text-underline-offset: 5px; text-decoration-color: color-mix(in srgb, currentColor 35%, transparent);
  transition: text-decoration-color .2s ease;
  display: inline-flex; align-items: center; min-height: 44px;
}
.link:hover { text-decoration-color: currentColor; }

/* ---------- Barra ---------- */
.bar {
  position: fixed; inset: 0 0 auto 0; z-index: 50;
  display: flex; align-items: center; gap: var(--s4);
  padding: 14px var(--margin);
  color: var(--ink);
  transition: background-color .35s ease, transform .35s var(--ease-out);
}
.bar.is-solid { background: var(--bg); }
.bar.is-hidden { transform: translateY(-100%); }
.bar__brand { display: inline-flex; align-items: center; min-height: 44px; margin-right: auto; }
.bar__logo { height: 34px; width: auto; }
.bar__nav { display: flex; gap: var(--s4); }
.bar__nav a {
  text-decoration: none; font-weight: 500; font-size: var(--step-small);
  display: inline-flex; align-items: center; min-height: 44px; position: relative;
}
.bar__nav a::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 8px; height: 2px; background: currentColor;
  transform: scaleX(0); transform-origin: left; transition: transform .3s var(--ease-out);
}
.bar__nav a:hover::after { transform: scaleX(1); }
.bar__cta { min-height: 44px; padding: 0 22px; background: var(--brand); color: #fff; }
.bar__cta:hover { background: var(--brand-press); color: #fff; }
.bar__menu {
  display: none; min-height: 44px; min-width: 64px; padding: 0 16px; border: 0; border-radius: var(--pill);
  background: var(--ink); color: #fff; font-weight: 500; cursor: pointer;
}

.menu-movil {
  position: fixed; inset: 0; z-index: 45; background: var(--bg);
  padding: 96px var(--margin) var(--s4); display: flex; flex-direction: column; justify-content: space-between;
}
.menu-movil[hidden] { display: none; }
.menu-movil nav { display: flex; flex-direction: column; }
.menu-movil nav a {
  font-family: var(--font-display); font-size: var(--step-sub); line-height: 1.25;
  text-decoration: none; padding: 6px 0;
}

/* ---------- 1. Hero ---------- */
.hero { position: relative; height: 100svh; min-height: 560px; overflow: hidden; background: #e9e9e6; }
.hero__media { position: absolute; inset: 0; }
.hero__still img, .hero__video {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: center 70%;
}
.hero__video { opacity: 0; transition: opacity 1s ease; }
.hero__video.is-playing { opacity: 1; }
.hero__copy {
  position: absolute; left: var(--margin); right: var(--margin); top: clamp(104px, 15vh, 160px);
  text-align: center; color: var(--ink);
}
.hero__title {
  font-family: var(--font-display); font-weight: 400; font-size: var(--step-hero);
  line-height: 0.92; letter-spacing: -0.025em;
}
.hero__line { display: block; }
.hero__sub {
  margin-top: var(--s4); font-size: var(--step-lead); line-height: 1.35; font-weight: 500;
  display: flex; flex-direction: column; align-items: center;
}
.hero__dock {
  position: absolute; left: 0; right: 0; bottom: 0;
  padding: var(--s3) var(--margin) var(--s4);
  display: flex; align-items: center; justify-content: space-between; gap: var(--s2);
}
.hero__pause {
  min-height: 44px; padding: 0 18px; border: 0; border-radius: var(--pill);
  background: rgba(10, 26, 51, .72); color: #fff; font-size: var(--step-small); font-weight: 500; cursor: pointer;
}
.hero__pause:hover { background: rgba(10, 26, 51, .9); }

/* ---------- 2. Servicios ---------- */
.servicios { padding: var(--section) var(--margin); }
.servicios__intro {
  margin-left: 35%; min-height: 40svh; display: flex; flex-direction: column; justify-content: center; gap: var(--s3);
}
.servicios__intro .t-head { max-width: 12ch; }
.servicios__rows { display: flex; flex-direction: column; gap: var(--s12); margin-top: var(--s8); }
.fila { display: grid; grid-template-columns: 35% minmax(0, 1fr) auto; align-items: start; }
.fila__text { grid-column: 2; max-width: 40ch; display: flex; flex-direction: column; gap: var(--s2); padding-right: var(--s4); }
.fila__text p { max-width: 36ch; }
.fila__pic { grid-column: 3; overflow: hidden; background: var(--surface); }
.fila__pic img { width: 100%; height: 100%; object-fit: cover; transition: transform .9s var(--ease-out); }
.fila:hover .fila__pic img { transform: scale(1.04); }
.fila__pic--a { width: clamp(260px, 30vw, 460px); aspect-ratio: 3 / 2; }
.fila__pic--b { width: clamp(220px, 24vw, 360px); aspect-ratio: 4 / 5; }
.fila__pic--c { width: clamp(200px, 20vw, 300px); aspect-ratio: 1; }
.fila__pic--d { width: clamp(240px, 27vw, 400px); aspect-ratio: 4 / 5; }

/* ---------- 3. El plan (diagonal) ---------- */
.plan {
  padding: var(--section) var(--margin);
  display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gap);
}
.plan { row-gap: var(--s4); }
.plan__title { grid-column: 7 / 13; grid-row: 1; align-self: end; max-width: 11ch; }
.plan__stage { display: contents; }
.plan__stage--1 .plan__pic { grid-column: 1 / 6; grid-row: 1 / span 2; aspect-ratio: 3 / 4; }
.plan__stage--1 .plan__text { grid-column: 7 / 11; grid-row: 2; align-self: start; }
.plan__stage--2 .plan__pic { grid-column: 5 / 9; grid-row: 3; aspect-ratio: 1; margin-top: var(--s8); }
.plan__stage--2 .plan__text { grid-column: 9 / 13; grid-row: 3; align-self: center; padding-left: var(--s2); }
.plan__stage--3 .plan__pic { grid-column: 7 / 13; grid-row: 4; aspect-ratio: 16 / 10; margin-top: var(--s8); }
.plan__stage--3 .plan__text { grid-column: 2 / 6; grid-row: 4; align-self: center; }
.plan__pic { overflow: hidden; background: var(--surface); }
.plan__pic img { width: 100%; height: 100%; object-fit: cover; }
.plan__text { max-width: 36ch; }
.plan__text strong { font-weight: 600; color: var(--brand); }

/* ---------- 4. Arma tu cita (campo azul) ---------- */
.armar {
  background: var(--field); color: var(--on-field);
  padding: var(--section) var(--margin);
  display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: var(--s8) var(--gap);
}
.armar__head { display: flex; flex-direction: column; gap: var(--s3); align-self: start; position: sticky; top: 120px; }
.armar__head .t-head { max-width: 10ch; }
.armar__head .t-lead { color: var(--on-field-soft); }
.armar__form { display: flex; flex-direction: column; gap: var(--s5); }
.opciones { border: 0; margin: 0; padding: 0; }
.opciones legend { font-size: var(--step-lead); font-weight: 500; margin-bottom: var(--s2); padding: 0; }
.opciones__set { display: flex; flex-wrap: wrap; gap: 10px; }
.opciones label { position: relative; cursor: pointer; }
.opciones input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.opciones span {
  display: inline-flex; align-items: center; min-height: 48px; padding: 0 20px; border-radius: var(--pill);
  background: rgba(255, 255, 255, .14); color: #fff; font-weight: 500;
  transition: background-color .2s ease, color .2s ease, transform .25s var(--ease-out);
}
.opciones label:hover span { background: rgba(255, 255, 255, .24); }
.opciones input:checked + span { background: #fff; color: var(--brand); }
.opciones input:focus-visible + span { outline: 3px solid #fff; outline-offset: 3px; }
.opciones label:active span { transform: scale(.96); }
.campo { display: flex; flex-direction: column; gap: var(--s1); max-width: 420px; }
.campo label { font-size: var(--step-lead); font-weight: 500; }
.campo__opt { font-weight: 400; color: var(--on-field-soft); font-size: var(--step-body); }
.campo input {
  min-height: 52px; padding: 0 18px; border-radius: var(--radius-card); border: 0;
  background: rgba(255, 255, 255, .14); color: #fff;
}
.campo input::placeholder { color: var(--on-field-soft); }
.campo input:focus-visible { outline: 3px solid #fff; outline-offset: 2px; background: rgba(255, 255, 255, .22); }
.armar__out { background: var(--deep); padding: var(--s4); border-radius: var(--radius-card); display: flex; flex-direction: column; gap: var(--s2); }
.armar__label { color: var(--on-field-soft); font-size: var(--step-small); font-weight: 500; }
.armar__msg { font-size: var(--step-lead); line-height: 1.4; min-height: 3.6em; }
.armar__note { color: var(--on-field-soft); font-size: var(--step-small); }

/* ---------- 5. La clínica ---------- */
.clinica { padding: var(--section) var(--margin); }
.clinica__head { display: flex; flex-direction: column; gap: var(--s3); max-width: 60%; }
.clinica__head .t-head { max-width: 13ch; }
.clinica__tiles {
  margin-top: var(--s10);
  display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: var(--s2);
}
.clinica__photo { grid-column: 1 / 9; position: relative; aspect-ratio: 16 / 10; overflow: hidden; }
.clinica__photo img { width: 100%; height: 100%; object-fit: cover; }
.clinica__note {
  position: absolute; top: 0; right: 0; width: min(340px, 44%);
  background: var(--bg); padding: var(--s3); font-size: var(--step-body); line-height: 1.5;
}
.clinica__side { grid-column: 9 / 13; display: flex; flex-direction: column; gap: var(--s4); }
.clinica__map {
  background: var(--field); color: #fff; aspect-ratio: 4 / 3.2; display: flex; flex-direction: column;
  justify-content: space-between; padding: var(--s3);
}
.clinica__map svg { width: 100%; height: auto; }
.clinica__map-label { font-family: var(--font-display); font-size: var(--step-item); line-height: 1; }
.datos { display: grid; grid-template-columns: 1fr 1fr; gap: var(--s3) var(--s2); }
.datos dt { color: var(--muted); font-size: var(--step-small); font-weight: 500; }
.datos dd { font-size: var(--step-body); font-weight: 500; }

/* ---------- 6. Antes y después ---------- */
.casos { padding: var(--section) var(--margin); background: var(--surface); }
.casos__title { max-width: 12ch; }
.casos__grid {
  margin-top: var(--s8);
  display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gap); align-items: start;
}
.casos__a { grid-column: 1 / 5; }
.casos__b { grid-column: 6 / 12; display: flex; flex-direction: column; gap: var(--s3); margin-top: var(--s10); }
.casos__c { grid-column: 8 / 13; margin-top: var(--s10); }
.casos__a img, .casos__c img { width: 100%; aspect-ratio: 3 / 4; object-fit: cover; }
.casos__c img { aspect-ratio: 5 / 4; }
.casos figcaption { margin-top: 10px; font-size: var(--step-small); color: var(--muted); }
.casos__pend { font-size: var(--step-body); }

/* ---------- 7. Equipo ---------- */
.equipo {
  padding: var(--section) var(--margin) var(--s12);
  display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gap);
}
.equipo__pin { grid-column: 1 / 6; }
.equipo__frame { position: sticky; top: 12vh; aspect-ratio: 4 / 5; overflow: hidden; background: var(--surface); }
.equipo__frame img {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover;
  opacity: 0; transition: opacity .4s ease;
}
.equipo__frame img.is-on { opacity: 1; }
.equipo__list { grid-column: 7 / 12; padding-top: var(--s8); padding-bottom: var(--s8); }
.equipo__list .t-head { margin-bottom: var(--s6); max-width: 10ch; }
.activa__row button {
  width: 100%; min-height: 64px; padding: 12px 0; border: 0; background: none; cursor: pointer; text-align: left;
  display: flex; align-items: baseline; justify-content: space-between; gap: var(--s2);
}
.activa__name {
  font-family: var(--font-display); font-size: var(--step-item); line-height: 1.1;
  color: var(--muted); transition: color .3s ease;
}
.activa__row.is-active .activa__name { color: var(--brand); }
.activa__row button:hover .activa__name { color: var(--ink); }
.activa__meta { font-size: var(--step-small); color: var(--muted); text-align: right; flex-shrink: 0; }
.activa__desc { max-width: 36ch; padding: 0 0 var(--s3); color: var(--ink); }

/* ---------- 8. Seguros ---------- */
.seguros {
  padding: var(--s15) var(--margin);
  background: var(--surface);
  display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gap);
}
.seguros__title { grid-column: 1 / 5; font-size: var(--step-sub); max-width: 9ch; }
.seguros__body { grid-column: 5 / 13; display: flex; flex-direction: column; gap: var(--s5); }
.seguros__lead { font-size: var(--step-lead); line-height: 1.4; max-width: 44ch; }
.ars { columns: 3; column-gap: var(--s4); }
.ars li {
  break-inside: avoid; font-size: var(--step-body); font-weight: 500; line-height: 1.35;
  padding: 10px 0; display: flex; align-items: center; gap: 12px; min-height: 48px;
}
.ars li::before {
  content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--brand); flex-shrink: 0;
}
.ars img { height: 32px; width: auto; max-width: 120px; object-fit: contain; }
.pagos { background: var(--paper); border-radius: var(--radius-card); padding: var(--s3) var(--s4); display: flex; flex-wrap: wrap; align-items: center; gap: var(--s2) var(--s4); }
.pagos__title { font-weight: 600; }
.pagos__list { display: flex; flex-wrap: wrap; gap: var(--s1) var(--s3); }
.pagos__list li { font-size: var(--step-body); }
.pagos__list li + li::before { content: "·"; margin-right: var(--s3); color: var(--muted); }
/* ---------- 9. Preguntas ---------- */
.faq {
  background: var(--deep); color: #fff;
  padding: 0 var(--margin);
  display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gap);
}
.faq__col { grid-column: 1 / 6; padding: var(--section) 0; display: flex; flex-direction: column; gap: var(--s5); }
.faq__col .t-head { font-size: var(--step-sub); max-width: 10ch; }
.faq__facts li { font-size: var(--step-body); margin-bottom: 6px; color: #E4EBF8; }
.faq__facts strong { color: #fff; font-weight: 600; }
.faq__list { display: flex; flex-direction: column; gap: var(--s1); }
.faq details { padding: 6px 0; }
.faq summary {
  list-style: none; cursor: pointer; min-height: 48px; display: flex; align-items: center; justify-content: space-between;
  gap: var(--s2); font-size: var(--step-lead); font-weight: 500;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: ""; width: 12px; height: 12px; flex-shrink: 0; margin-right: 4px;
  border-right: 2px solid currentColor; border-bottom: 2px solid currentColor;
  transform: rotate(45deg) translateY(-3px); transition: transform .3s var(--ease-out);
}
.faq details[open] summary::after { transform: rotate(-135deg) translateY(-3px); }
.faq summary:hover { color: #C9D8F7; }
.faq details p { color: #D4DEF2; padding: 4px 0 var(--s2); max-width: 46ch; }
.faq__actions { display: flex; flex-wrap: wrap; align-items: center; gap: var(--s3); }
.faq__actions .btn--accent { background: #fff; color: var(--brand); }
.faq__actions .btn--accent:hover { background: var(--surface); }
.faq__pics { grid-column: 7 / 13; position: relative; padding-bottom: var(--s10); }
.faq__tall { width: 100%; aspect-ratio: 3 / 4; object-fit: cover; }
.faq__sq {
  position: absolute; width: 34%; aspect-ratio: 1; object-fit: cover; left: -40px; bottom: 40px;
  border: 8px solid var(--deep);
}

/* ---------- 10. Visítanos ---------- */
.visita { position: relative; min-height: 100svh; }
.visita__photo { position: absolute; inset: 0; overflow: hidden; }
.visita__photo img, .visita__video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.visita__video { opacity: 0; transition: opacity 1s ease; }
.visita__video.is-playing { opacity: 1; }
.visita__card {
  position: absolute; top: 72px; right: var(--margin); width: 400px;
  background: var(--paper); border-radius: var(--radius-card); padding: var(--s4);
  display: flex; flex-direction: column; gap: var(--s3);
}
.visita__title { font-family: var(--font-display); font-weight: 400; font-size: var(--step-sub); line-height: 1; }
.visita__card address { font-style: normal; line-height: 1.55; }
.horario { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; }
.horario th { text-align: left; font-weight: 500; padding: 6px 0; }
.horario td { text-align: right; padding: 6px 0; }

/* ---------- Pie ---------- */
.pie { background: var(--deep); padding: var(--s15) var(--margin) var(--s8); }
.pie__card {
  --scallop: 50px;
  position: relative; max-width: 1180px; margin: 0 auto; background: var(--paper); color: var(--ink);
  padding: calc(var(--s10) + 10px) clamp(24px, 4vw, 64px) var(--s4);
  display: grid; grid-template-columns: 1fr 1fr; gap: var(--s6);
  /* Borde superior festoneado, como el de una postal */
  -webkit-mask: radial-gradient(circle calc(var(--scallop) / 2) at 50% 0, #0000 98%, #000 100%) 50% 0 / var(--scallop) 100% repeat-x; /* taste-skill-ignore: máscara de forma, no un relleno visible */
          mask: radial-gradient(circle calc(var(--scallop) / 2) at 50% 0, #0000 98%, #000 100%) 50% 0 / var(--scallop) 100% repeat-x; /* taste-skill-ignore: máscara de forma */
}
.pie__msg { display: flex; flex-direction: column; gap: var(--s3); }
.pie__title { font-family: var(--font-display); font-weight: 400; font-size: var(--step-sub); line-height: 1; }
.pie__msg p { max-width: 40ch; }
.pie__logo { width: 150px; margin-top: var(--s2); }
.pie__addr { position: relative; padding-top: var(--s2); }
.pie__addr ul { display: flex; flex-direction: column; gap: var(--s1); }
.pie__addr a { text-decoration: none; display: inline-flex; align-items: center; min-height: 44px; font-size: var(--step-body); }
.pie__addr a:hover { color: var(--brand); }
.pie__stamp {
  position: absolute; top: 0; right: 0; width: 96px; aspect-ratio: 3 / 4; object-fit: cover;
  outline: 6px solid var(--paper); outline-offset: -6px; transform: rotate(4deg);
}
.pie__imprint { grid-column: 1 / -1; text-align: center; font-size: var(--step-small); color: var(--muted); }

/* ---------- Movimiento ---------- */
/* Sin JS todo se ve; con JS las piezas entran escalonadas una vez. */
.js .reveal > *, .js .reveal.fila > * { opacity: 0; transform: translateY(24px); }
.js .reveal.is-in > * {
  opacity: 1; transform: none;
  transition: opacity .8s var(--ease-out), transform .9s var(--ease-out);
}
.js .reveal.is-in > *:nth-child(2) { transition-delay: .08s; }
.js .reveal.is-in > *:nth-child(3) { transition-delay: .16s; }
.js .reveal.is-in > *:nth-child(4) { transition-delay: .24s; }
.js .reveal.is-in > *:nth-child(5) { transition-delay: .32s; }
.js .reveal.is-in > *:nth-child(6) { transition-delay: .40s; }
/* Títulos y piezas sueltas con clase reveal en sí mismas */
.js h2.reveal, .js .faq__facts.reveal { opacity: 0; transform: translateY(24px); }
.js h2.reveal.is-in, .js .faq__facts.reveal.is-in { opacity: 1; transform: none; transition: opacity .8s var(--ease-out), transform .9s var(--ease-out); }
.js h2.reveal > *, .js .faq__facts.reveal > * { opacity: 1; transform: none; }
/* Piezas sueltas (en «Tu plan»): cada foto y cada texto entra por su cuenta */
.js .rise { opacity: 0; transform: translateY(28px); }
.js .rise.is-in { opacity: 1; transform: none; transition: opacity .8s var(--ease-out), transform 1s var(--ease-out); }
.js .plan__text.rise.is-in { transition-delay: .1s; }

/* Firma: el hero se abre como un obturador */
.js .hero__media { clip-path: inset(0 0 100% 0); }
.js .hero__media img { transform: scale(1.12); }
.js .hero.is-open .hero__media { clip-path: inset(0 0 0 0); transition: clip-path 1.15s var(--ease-io); }
.js .hero.is-open .hero__media img { transform: scale(1); transition: transform 1.6s var(--ease-out); }
.js .hero__line, .js .hero__sub, .js .hero__dock { opacity: 0; transform: translateY(28px); }
.js .hero.is-open .hero__line, .js .hero.is-open .hero__sub, .js .hero.is-open .hero__dock {
  opacity: 1; transform: none; transition: opacity .9s var(--ease-out), transform 1s var(--ease-out);
}
.js .hero.is-open .hero__line { transition-duration: .7s, .8s; }
.js .hero.is-open .hero__line:nth-child(2) { transition-delay: .15s; }
.js .hero.is-open .hero__line:nth-child(3) { transition-delay: .25s; }
.js .hero.is-open .hero__sub { transition-delay: .35s; }
.js .hero.is-open .hero__dock { transition-delay: .45s; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: .01ms !important; animation-duration: .01ms !important; }
  .js .reveal > *, .js h2.reveal, .js .faq__facts.reveal, .js .rise,
  .js .hero__line, .js .hero__sub, .js .hero__dock { opacity: 1; transform: none; }
  .js .hero__media { clip-path: none; }
  .js .hero__media img { transform: none; }
  .hero__video, .visita__video { display: none; }
}

/* =========================================================
   Tableta (≤ 1080)
   ========================================================= */
@media (max-width: 1080px) {
  .bar__nav { display: none; }
  .servicios__intro { margin-left: 20%; }
  .fila { grid-template-columns: 20% minmax(0, 1fr) auto; }
  .plan__stage--1 .plan__text { grid-column: 7 / 13; }
  .plan__stage--2 .plan__pic { grid-column: 3 / 8; }
  .plan__stage--2 .plan__text { grid-column: 8 / 13; }
  .plan__stage--3 .plan__pic { grid-column: 6 / 13; }
  .plan__stage--3 .plan__text { grid-column: 1 / 6; }
  .armar { grid-template-columns: 1fr; }
  .armar__head { position: static; }
  .armar__head .t-head { max-width: 14ch; }
  .clinica__head { max-width: 80%; }
  .clinica__photo { grid-column: 1 / -1; }
  .clinica__side { grid-column: 1 / -1; display: grid; grid-template-columns: 1fr 1fr; gap: var(--s3); align-items: start; }
  .seguros__title { grid-column: 1 / -1; margin-bottom: var(--s5); max-width: none; }
  .seguros__body { grid-column: 1 / -1; }
  .faq__col { grid-column: 1 / 8; }
  .faq__pics { grid-column: 8 / 13; }
  .faq__sq { left: -24px; }
}

/* =========================================================
   Celular (≤ 767)
   ========================================================= */
@media (max-width: 767px) {
  :root { --section: 96px; }
  .bar { padding: 10px var(--margin); }
  .bar__logo { height: 28px; }
  .bar__cta { display: none; }
  .bar__menu { display: inline-flex; align-items: center; justify-content: center; }

  .hero { min-height: 600px; }
  .hero__still img, .hero__video { object-position: center 80%; }
  .hero__copy { top: 96px; }
  .hero__title { font-size: clamp(2.75rem, 13vw, 4rem); }
  .hero__sub { margin-top: var(--s3); font-size: var(--step-body); }
  .hero__still img, .hero__video { object-position: 28% center; }
  .hero__dock {
    flex-direction: column; align-items: stretch; gap: var(--s1); padding-bottom: calc(var(--s3) + env(safe-area-inset-bottom));
  }
  .hero__dock .btn { width: 100%; }
  .hero__pause { align-self: center; }

  .servicios__intro { margin-left: 0; min-height: 0; padding-bottom: var(--s4); }
  .servicios__rows { gap: var(--s8); margin-top: var(--s4); }
  .fila { display: flex; flex-direction: column; gap: var(--s3); }
  .fila__text { padding-right: 0; }
  .fila__pic--a { width: 100%; }
  .fila__pic--b { width: 70%; align-self: flex-end; }
  .fila__pic--c { width: 55%; }
  .fila__pic--d { width: 84%; align-self: flex-end; }

  .plan { display: flex; flex-direction: column; gap: var(--s8); }
  .plan__title { max-width: none; }
  .plan { gap: var(--s3); }
  .plan__stage .plan__pic { margin-top: var(--s4); }
  .plan__stage .plan__text { padding: 0; }
  .plan__stage--1 .plan__pic { width: 100%; margin-top: 0; }
  .plan__stage--2 .plan__pic { width: 62%; align-self: flex-end; }
  .plan__stage--2 .plan__text { align-self: flex-end; max-width: 62%; }
  .plan__stage--3 .plan__pic { width: 78%; }

  .armar { gap: var(--s5); }
  .armar__out { padding: var(--s3); }

  .clinica__head { max-width: none; }
  .clinica__tiles { margin-top: var(--s5); display: flex; flex-direction: column; gap: var(--s3); }
  .clinica__photo { aspect-ratio: auto; overflow: visible; }
  .clinica__photo img { aspect-ratio: 4 / 3; }
  .clinica__note { position: static; width: auto; padding: var(--s2) 0 0; background: none; }
  .clinica__side { display: flex; flex-direction: column; }
  .clinica__map { aspect-ratio: 3 / 2; }

  .casos__grid { display: flex; flex-direction: column; gap: var(--s5); margin-top: var(--s5); }
  .casos__a { width: 84%; }
  .casos__b, .casos__c { margin-top: 0; }
  .casos__b { order: -1; }
  .casos__c { width: 70%; align-self: flex-end; }

  .equipo { display: flex; flex-direction: column-reverse; }
  .equipo__pin { margin-top: var(--s3); }
  .equipo__frame { position: relative; top: 0; aspect-ratio: 4 / 3; }
  .equipo__list { padding-top: var(--s5); padding-bottom: var(--s4); }
  .activa__row button { flex-direction: column; align-items: flex-start; gap: 4px; min-height: 56px; }
  .activa__meta { text-align: left; }

  .ars { columns: 2; }
  .pagos { flex-direction: column; align-items: flex-start; }

  .faq { display: flex; flex-direction: column-reverse; padding-top: var(--s8); }
  .faq__col { padding: var(--s6) 0 var(--section); }
  .faq__pics { padding-bottom: var(--s6); }
  .faq__tall { aspect-ratio: 4 / 5; }
  .faq__sq { width: 38%; left: auto; right: 0; bottom: 16px; }
  .faq__actions .btn { width: 100%; }

  .visita { min-height: 0; display: flex; flex-direction: column; }
  .visita__photo { position: relative; height: 70svh; }
  .visita__card {
    position: relative; top: auto; right: auto; width: auto; margin: -80px var(--margin) 0; z-index: 2;
  }

  .pie { padding-top: var(--s10); }
  .pie__card { --scallop: 40px; grid-template-columns: 1fr; padding-top: var(--s8); }
  .pie__stamp { width: 68px; top: -8px; }
}
