/* ==========================================================================
   styles.css — Landing de marketing para médicos · The Social Box
   --------------------------------------------------------------------------
   §1–5 y §14–20 vienen de la landing de Diseño Gráfico (tokens, base,
   botones, header, lightbox, FAQ, contacto, CTA final, footer, cintas,
   reveal, barra móvil). Lo propio de esta landing ("signos vitales")
   está de §22 en adelante.
   ========================================================================== */

/* ============ 0. TIPOGRAFÍAS (alojadas en assets/fonts, solo latín) ============ */
@font-face {
  font-family: "Plus Jakarta Sans";
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url("../fonts/plus-jakarta-sans-latin-variable.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Archivo Black";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("../fonts/archivo-black-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "JetBrains Mono";
  font-style: normal;
  font-weight: 500 700;
  font-display: swap;
  src: url("../fonts/jetbrains-mono-latin-variable.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Cormorant Garamond";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("../fonts/cormorant-garamond-600-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Cormorant Garamond";
  font-style: italic;
  font-weight: 500;
  font-display: swap;
  src: url("../fonts/cormorant-garamond-italic-500-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Reenie Beanie";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("../fonts/reenie-beanie-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Homemade Apple";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("../fonts/homemade-apple-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* ============ 1. VARIABLES (TOKENS DE MARCA) ============ */
:root {
  /* --- Paleta — The Social Box (extraída de thesocialbox.marketing/css/variables.css) --- */
  --color-ink:        #040404;   /* negro de marca — fondos oscuros */
  --color-ink-rgb:     4, 4, 4;
  --color-ink-soft:    #1a1a1a;  /* superficie elevada (tarjetas sobre fondo oscuro) */
  --color-body:        #d1d1d1;  /* texto sobre fondo oscuro (hero, stats, cta, contacto) */
  --color-text-soft:   #4a4a4a;  /* texto de párrafo sobre fondo claro (cream) */
  --color-cream:       #f7f6f2;  /* fondo de la página — blanco roto, no puro, para que no deslumbre */
  --color-sand:        #f5f5f5;  /* franjas ligeramente diferenciadas sobre el blanco */
  --color-line:        #dddddd;
  --color-white:       #ffffff;

  --color-brand:       #ff0000;  /* rojo de marca — CTAs y acentos */
  --color-brand-rgb:    255, 0, 0;
  --color-brand-dark:  #c40000;  /* hover de CTAs */
  --color-brand-soft:  rgba(255, 0, 0, 0.14);
  --color-whatsapp:    #25d366;

  /* Color de fondo del header cuando se hace scroll (header
     transparente en desktop → color de marca al hacer scroll).
     Usamos el negro de marca en vez del rojo: una barra roja sólida de
     header resultaba demasiado intensa para navegación permanente. */
  --color-header-scroll:     var(--color-ink);
  --color-header-scroll-rgb: var(--color-ink-rgb);

  /* --- Tipografía — The Social Box --- */
  --font-display: "Plus Jakarta Sans", "Helvetica Neue", Arial, sans-serif;
  --font-body:    "Plus Jakarta Sans", "Helvetica Neue", Arial, sans-serif;
  --font-accent:  "Archivo Black", "Helvetica Neue", Arial, sans-serif; /* cifras destacadas (stats) */
  --font-hero:    "Plus Jakarta Sans", "Helvetica Neue", Arial, sans-serif; /* titular del hero, peso 700 */

  /* --- Espaciado --- */
  --space-section: 3rem;
  --container:     1200px;
  --container-narrow: 760px;
  --gutter:        1.5rem;

  /* --- Otros --- */
  --radius:     6px;
  --radius-lg:  6px;
  --radius-full: 999px;
  /* Recuadros con una esquina cortada en diagonal — el estilo de "banner"
     de esta marca en vez de tarjetas muy redondeadas. */
  --cut-corner:    polygon(0 0, calc(100% - 26px) 0, 100% 26px, 100% 100%, 0 100%);
  --cut-corner-sm: polygon(0 0, calc(100% - 16px) 0, 100% 16px, 100% 100%, 0 100%);
  --shadow-sm:  0 2px 10px rgba(4, 4, 4, 0.25);
  --shadow-md:  0 12px 40px rgba(4, 4, 4, 0.35);
  --shadow-lg:  0 24px 70px rgba(4, 4, 4, 0.45);
  --shadow-glow: 0 10px 40px rgba(var(--color-brand-rgb), 0.35); /* como en el sitio real */
  --ease:       cubic-bezier(0.22, 1, 0.36, 1);
  --header-h:   84px;
  --mobile-cta-h: 64px; /* alto de la barra CTA fija en móvil */
}

/* ============ 2. BASE Y TIPOGRAFÍA ============ */
body {
  font-family: var(--font-body);
  font-weight: 300;
  font-size: 1rem;
  color: var(--color-text-soft);
  background-color: var(--color-cream);
  overflow-x: hidden;
}

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 400;
  color: var(--color-ink);
  line-height: 1.15;
  letter-spacing: -0.01em;
}

h1 { font-size: clamp(2.6rem, 6vw, 4.6rem); }
h2 { font-size: clamp(1.75rem, 3.2vw, 2.5rem); }
h3 { font-size: 1.25rem; }
h4 { font-size: 1.05rem; }

p { margin-bottom: 1.1rem; }
p:last-child { margin-bottom: 0; }

::selection {
  background: var(--color-brand);
  color: var(--color-white);
}

/* ============ 3. UTILIDADES ============ */
.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.container--narrow { max-width: var(--container-narrow); }
.link { color: var(--color-brand); text-decoration: underline; text-underline-offset: 2px; }
.link:hover { color: var(--color-brand-dark); }

.section {
  position: relative;
  padding-block: var(--space-section);
}

.section > .container {
  position: relative;
  z-index: 1;
}

.section__bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

.section__head {
  max-width: 660px;
  margin-inline: auto;
  margin-bottom: 1.5rem;
  text-align: center;
}

.section__title {
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.01em;
  margin-bottom: 0.5rem;
}

.section__lead {
  font-size: 1.0625rem;
}

.eyebrow {
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--color-brand);
  margin-bottom: 0.9rem;
}

/* Encabezados de sección (eyebrow + título + lead) en cascada al entrar
   en pantalla — mismo patrón que Nosotros, aplicado a cualquier
   .section__head del sitio (requiere que el propio .section__head tenga
   la clase .reveal en el HTML). */
.section__head .eyebrow,
.section__head .section__title,
.section__head .section__lead {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.6s var(--ease), transform 0.6s var(--ease);
}

.section__head.is-visible .eyebrow { opacity: 1; transform: none; transition-delay: 0.05s; }
.section__head.is-visible .section__title { opacity: 1; transform: none; transition-delay: 0.15s; }
.section__head.is-visible .section__lead { opacity: 1; transform: none; transition-delay: 0.25s; }

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 999;
  background: var(--color-ink);
  color: var(--color-white);
  padding: 0.75rem 1.25rem;
}
.skip-link:focus {
  left: 1rem;
  top: 1rem;
}

/* ============ 4. BOTONES ============ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.95rem 2rem;
  border-radius: var(--radius-full, 999px);
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  cursor: pointer;
  position: relative;
  overflow: hidden;
  transition: background-color 0.3s var(--ease),
              color 0.3s var(--ease),
              border-color 0.3s var(--ease),
              box-shadow 0.3s var(--ease),
              transform 0.3s var(--ease);
}

.btn:hover { transform: translateY(-2px); }
.btn:active { transform: translateY(0); }

.btn--primary {
  background-color: var(--color-brand);
  color: var(--color-white);
  box-shadow: var(--shadow-glow);
}
.btn--primary:hover { background-color: var(--color-brand-dark); box-shadow: 0 14px 46px rgba(var(--color-brand-rgb), 0.45); }

.btn--ghost {
  border: 1px solid rgba(255, 255, 255, 0.55);
  color: var(--color-white);
}
.btn--ghost:hover {
  background-color: var(--color-white);
  color: var(--color-ink);
  border-color: var(--color-white);
}
.btn--block { width: 100%; }

.btn__ripple {
  position: absolute;
  border-radius: 50%;
  background-color: rgba(255, 255, 255, 0.55);
  transform: scale(0);
  opacity: 0.6;
  pointer-events: none;
  animation: rippleOut 0.6s var(--ease) forwards;
}
.btn--ghost .btn__ripple {
  background-color: rgba(26, 22, 20, 0.18);
}
@keyframes rippleOut {
  to { transform: scale(1); opacity: 0; }
}

/* ============ 5. HEADER / NAVEGACIÓN ============ */
/* Header:
   - Desktop: header transparente sobre el hero; al hacer scroll pasa a un
     fondo sólido con el color de marca (--color-header-scroll).
   - Móvil: SIN menú hamburguesa. El header solo muestra el logo y un único
     botón de llamada a la acción (.header__cta). La navegación por
     secciones en móvil se resuelve con scroll y con la barra CTA fija
     (ver sección 19) — no se reintroduce un panel de menú. */
.site-header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 100;
  height: var(--header-h);
  display: flex;
  align-items: center;
  background-color: transparent;
  transition: background-color 0.4s var(--ease),
              box-shadow 0.4s var(--ease),
              height 0.4s var(--ease);
}

.site-header.is-scrolled {
  height: 68px;
  background-color: rgba(var(--color-header-scroll-rgb), 0.92);
  backdrop-filter: blur(10px);
  box-shadow: var(--shadow-sm);
}

/* Variante clara: para secciones con fondo claro detrás del header
   (data-header-theme="light"), el estado "scrolled" usa un fondo crema
   en vez del color de marca, para que el texto oscuro siga legible. */
.site-header.is-scrolled.theme-light {
  background-color: rgba(245, 245, 245, 0.94);
}

.header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* Logo */
.logo {
  display: flex;
  align-items: center;
}

/* Logotipo completo (wordmark "The Social Box" + marca roja), tal cual lo
   entregó el cliente. Un <img> no puede invertir color con currentColor
   como sí podía el wordmark en texto real, así que van DOS versiones
   superpuestas (texto blanco / texto tinta) y el header alterna cuál se
   ve según su propio estado de scroll (mismo patrón que ya usa el resto
   del header para el tema claro/oscuro). */
.logo__mark {
  display: block;
  height: 50px;
  width: auto;
}

.logo__mark--light { display: none; }

.site-header.is-scrolled.theme-light .logo__mark--dark  { display: none; }
.site-header.is-scrolled.theme-light .logo__mark--light { display: block; }

/* Nav (solo visible en escritorio — ver responsive.css) */
.nav__list {
  display: flex;
  align-items: center;
  gap: 2rem;
}

.nav__link {
  position: relative;
  font-size: 0.8125rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.88);
  transition: color 0.3s var(--ease);
}

.site-header.is-scrolled.theme-light .nav__link { color: var(--color-ink-soft); }

.nav__link::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -6px;
  width: 0;
  height: 1px;
  background-color: var(--color-brand);
  transition: width 0.3s var(--ease);
}

.nav__link:hover::after,
.nav__link.is-active::after { width: 100%; }

.nav__link:hover,
.nav__link.is-active { color: var(--color-brand); }

.nav__link--cta,
.header__cta {
  padding: 0.6rem 1.3rem;
  border: 1px solid currentColor;
  border-radius: var(--radius);
}
.nav__link--cta::after { display: none; }
.nav__link--cta:hover,
.header__cta:hover {
  background-color: var(--color-brand);
  border-color: var(--color-brand);
  color: var(--color-white);
}

/* Botón CTA del header en móvil (visible solo <768px, ver responsive.css) */
.header__cta {
  display: none;
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  color: var(--color-white);
  white-space: nowrap;
}
.site-header.is-scrolled.theme-light .header__cta { color: var(--color-ink); }

/* "Cotizar" en el nav de escritorio: botón rojo sólido, la acción
   principal siempre a la vista. Las redes sociales ya no van en el nav
   (sacaban al visitante de la landing); viven en Contacto. */
.nav__link.nav__link--cta,
.site-header.is-scrolled.theme-light .nav__link--cta {
  font-weight: 600;
  background-color: var(--color-brand);
  border-color: var(--color-brand);
  color: var(--color-white);
  transition: background-color 0.3s var(--ease), border-color 0.3s var(--ease);
}
.nav__link.nav__link--cta:hover,
.site-header.is-scrolled.theme-light .nav__link--cta:hover {
  background-color: var(--color-brand-dark);
  border-color: var(--color-brand-dark);
}

body.lightbox-open { overflow: hidden; }

.lightbox {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1.5rem;
  padding: 4rem 1.5rem;
  background-color: rgba(var(--color-ink-rgb), 0.94);
  opacity: 0;
  transition: opacity 0.3s var(--ease);
}

.lightbox[hidden] { display: none; }
.lightbox.is-open { opacity: 1; }

.lightbox__figure {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  max-width: min(84vw, 1100px);
  margin: 0;
}

.lightbox__img {
  max-width: 100%;
  max-height: 78vh;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  object-fit: contain;
  opacity: 0;
  transform: scale(0.97);
  transition: opacity 0.3s var(--ease), transform 0.3s var(--ease);
}

.lightbox.is-open .lightbox__img { opacity: 1; transform: scale(1); }

.lightbox__figure figcaption {
  font-family: var(--font-display);
  font-size: 1.25rem;
  color: var(--color-white);
  text-align: center;
}

.lightbox__close,
.lightbox__nav {
  flex-shrink: 0;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background-color: rgba(255, 255, 255, 0.1);
  color: var(--color-white);
  transition: background-color 0.3s var(--ease), transform 0.2s var(--ease);
}

.lightbox__nav { width: 48px; height: 48px; font-size: 1.5rem; }

.lightbox__close {
  position: absolute;
  top: 1.5rem;
  right: 1.5rem;
  width: 44px;
  height: 44px;
  font-size: 1.5rem;
}

.lightbox__close:hover,
.lightbox__nav:hover { background-color: var(--color-brand); }

/* ============ 14. PREGUNTAS FRECUENTES (FAQ) ============ */
/* Sección FAQ como RECETA QUE SE LLENA. Izquierda:
   título, contador y las 7 preguntas como botones. Derecha: la receta,
   con la lista de "medicamentos" que se va llenando y, en "Indicaciones",
   la respuesta completa escrita a mano. Alto fijo: no mueve la página.
   main.js §28. */
.faq-section {
  min-height: calc(100svh - var(--header-h));
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding-block: clamp(0.75rem, 2.5svh, 1.75rem);
}
.faq-section .section__title { font-size: clamp(1.5rem, 2.4vw, 2.125rem); }
.faq-rx {
  display: grid;
  grid-template-columns: minmax(0, 0.62fr) minmax(0, 1.38fr);
  grid-template-rows: auto auto 1fr;
  column-gap: clamp(1.5rem, 4vw, 3.5rem);
  align-items: start;
}
.faq-rx__head { grid-column: 1; grid-row: 1; max-width: none; margin: 0; text-align: right; }
.faq-rx .chat-count { grid-column: 1; grid-row: 2; margin: 0.6rem 0 0; text-align: right; }
.chat-side--l { grid-column: 1; grid-row: 3; margin-top: clamp(0.75rem, 2.4svh, 1.5rem); }
.faq-rx .rx-pad { grid-column: 2; grid-row: 1 / 4; align-self: center; }
.chat-count {
  margin: clamp(0.35rem, 1.2svh, 0.75rem) 0 clamp(0.5rem, 1.6svh, 1rem);
  font: 600 0.75rem/1.2 var(--font-body);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-align: center;
  color: var(--color-brand);
}
.chat-side { display: flex; flex-direction: column; gap: clamp(0.25rem, 0.7svh, 0.5rem); }   /* 9 preguntas en esta versión: un poco más juntas para caber */
.chat-side--l { align-items: flex-end; }
.chat__pick {
  flex: 0 0 auto;
  padding: 0.7rem 1.1rem;
  border: 1px solid rgba(var(--color-brand-rgb), 0.35);
  border-radius: 18px;
  background-color: var(--color-white);
  color: var(--color-ink);
  font: 600 0.9375rem/1.3 var(--font-body);
  white-space: nowrap;
  cursor: pointer;
  box-shadow: 0 8px 22px rgba(4, 4, 4, 0.07);
  transition: background-color 0.3s var(--ease), color 0.3s var(--ease), border-color 0.3s var(--ease), opacity 0.3s var(--ease), transform 0.35s var(--ease);
}
.chat-side--l .chat__pick { border-bottom-right-radius: 4px; }   /* colita hacia la receta */
.chat-side--l .chat__pick:hover { transform: translateX(6px); }
.chat__pick:hover { background-color: var(--color-brand); border-color: var(--color-brand); color: var(--color-white); }
.chat__pick:focus-visible { outline: 2px solid var(--color-brand); outline-offset: 2px; }
/* Pregunta ya hecha (pedido 2026-10-19): palomita, fondo rosado y texto
   más suave, para ver de un vistazo cuáles faltan. */
.chat__pick.is-asked {
  border-color: transparent;
  background-color: #ffe3e0;
  color: rgba(var(--color-ink-rgb), 0.6);
}
.chat__pick.is-asked::after {
  content: " ✓";
  font-weight: 800;
  color: var(--color-brand);
}
.chat__pick.is-asked:hover { background-color: var(--color-brand); color: var(--color-white); }
.chat__pick.is-asked:hover::after { color: var(--color-white); }
.chat__pick:disabled { opacity: 0.5; cursor: wait; }
.chat__pick.is-current { border-color: var(--color-brand); box-shadow: 0 0 0 2px rgba(var(--color-brand-rgb), 0.25), 0 8px 22px rgba(4, 4, 4, 0.07); }   /* la que se está leyendo */
.rx-pad {
  --ink: #1f3a93;
  position: relative;
  display: flex;
  flex-direction: column;
  width: 100%;   /* ocupa el lugar donde iba el chat (2026-10-19) */
  height: clamp(480px, calc(100svh - var(--header-h) - 4rem), 720px);   /* alto fijo: no crece con lo escrito */
  padding: clamp(1.6rem, 4svh, 2.4rem) clamp(1.3rem, 2.6vw, 2.4rem) clamp(0.9rem, 2svh, 1.3rem);
  border-radius: 6px;
  background:
    radial-gradient(circle at 18% 12%, rgba(255, 255, 255, 0.9), transparent 55%),
    linear-gradient(180deg, #fffdf6, #fbf6e9);
  color: #3b3b3b;
  box-shadow: 0 1px 0 rgba(0, 0, 0, 0.04), 0 22px 50px rgba(4, 4, 4, 0.18), 0 4px 10px rgba(4, 4, 4, 0.08);
  transform: rotate(0.8deg);
}
.rx-pad::before {   /* borde de arriba perforado, como hoja arrancada del recetario */
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 8px;
  background: radial-gradient(circle at 5px 0, transparent 3.2px, #fffdf6 3.6px) 0 0 / 10px 8px repeat-x;
  transform: translateY(-4px);
}
.rx-pad__clip {   /* pinza metálica */
  position: absolute;
  top: -16px;
  left: 50%;
  width: 92px;
  height: 30px;
  border-radius: 8px 8px 12px 12px;
  background: linear-gradient(180deg, #d9dbe0, #9ea3ad 60%, #7d828c);
  box-shadow: 0 3px 6px rgba(0, 0, 0, 0.25), inset 0 1px 0 rgba(255, 255, 255, 0.7);
  transform: translateX(-50%) rotate(-1.6deg);
}
.rx-pad__clip::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 7px;
  width: 30px;
  height: 7px;
  border-radius: 4px;
  background-color: #5f646d;
  transform: translateX(-50%);
}
.rx-pad__head {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  padding-bottom: 0.6rem;
  border-bottom: 2px solid var(--color-brand);
}
.rx-pad__head img { width: 54px; height: auto; flex-shrink: 0; }
.rx-pad__head b { display: block; font: 800 0.95rem/1.15 var(--font-display); color: var(--color-ink); }
.rx-pad__head small { display: block; font-size: 0.625rem; line-height: 1.35; color: #777; }
.rx-pad__fields {
  display: flex;
  justify-content: space-between;
  gap: 0.6rem;
  margin-top: 0.5rem;
  font-size: 0.6875rem;
  color: #888;
}
.rx-pad__fields span { border-bottom: 1px dotted #c9c3b3; }
.rx-hand { font: 400 1.15rem/1 "Reenie Beanie", cursive; font-style: normal; color: var(--ink); }
.rx-pad__body {
  position: relative;
  margin-top: 0.4rem;
  padding-left: 2.3rem;
  background: repeating-linear-gradient(180deg, transparent 0 calc(2.15rem - 1px), rgba(31, 58, 147, 0.12) calc(2.15rem - 1px) 2.15rem);
}
.rx-pad__symbol {
  position: absolute;
  top: 0.1rem;
  left: 0;
  font: 600 2.2rem/1 "Cormorant Garamond", serif;
  color: var(--color-brand);
}
.rx-pad__lines { margin: 0; padding: 0; list-style: none; counter-reset: rx; }
.rx-pad__item {
  counter-increment: rx;
  display: block;
  padding: 0.15rem 0 0.2rem var(--nudge, 0);
  font: 400 clamp(1.1rem, 2.6svh, 1.35rem)/1 "Reenie Beanie", cursive;
  color: var(--ink);
  transform: rotate(var(--tilt, 0deg));
  transform-origin: left center;
  animation: rxWrite 0.6s steps(14, end) both;   /* "se escribe" de izquierda a derecha (más rápida 2026-10-22; los pasos limitan los repintados) */
}
.rx-pad__item::before { content: counter(rx) ") "; color: var(--color-brand); }
.rx-pad__item b { font-weight: 400; text-decoration: underline wavy rgba(31, 58, 147, 0.35) 1px; text-underline-offset: 3px; }
.rx-pad__item span { display: block; margin: -0.1rem 0 0 0.9rem; font-size: 0.78em; color: rgba(31, 58, 147, 0.85); }
.rx-pad__item.is-again b { animation: rxAgain 1s var(--ease); }
@keyframes rxWrite { from { clip-path: inset(0 100% 0 0); } to { clip-path: inset(0 0 0 0); } }
@keyframes rxAgain { 0%, 100% { background-color: transparent; } 30% { background-color: rgba(255, 230, 0, 0.55); } }
.rx-pad__empty { position: absolute; top: 0.5rem; left: 2.3rem; margin: 0; font-size: 1.35rem; opacity: 0.45; }

/* Firma y sello (mejorados 2026-10-19): la firma "The Social Box" va
   completa y centrada sobre la línea; se escribe de izquierda a derecha y
   cierra con un rasgo. Después cae el sello con la marca de TSB (SVG con
   filtro de tinta gastada), golpea la hoja y se asienta ladeado. */
.rx-pad__foot {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: flex-end;
  margin-top: 0.6rem;
  min-height: clamp(4.4rem, 11svh, 5.6rem);
}
.rx-pad__signbox {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: min(72%, 320px);
}
/* Firma sin trabarse (2026-10-22): antes se revelaba con clip-path, que
   se repinta en cada cuadro. Ahora es una ventana (.rx-pad__sign, con
   overflow oculto) que avanza mientras su texto (.rx-pad__sign-in)
   retrocede lo mismo: el texto queda quieto y solo se mueven capas
   (transform). Trazo continuo, sin pausas ni punta de pluma (pedido
   2026-10-22). El relleno va en el texto, no en la ventana, para que
   ventana y texto midan lo mismo y no se asome el inicio de la "T";
   además la firma está oculta (visibility) hasta que empieza a escribirse. */
.rx-pad__sign {
  position: relative;
  display: block;
  overflow: hidden;
  font: 400 clamp(1.05rem, 2.6svh, 1.4rem)/1.9 "Homemade Apple", cursive;   /* line-height alto: no se cortan rasgos */
  color: var(--ink);
  white-space: nowrap;
  visibility: hidden;
  transform: rotate(-4deg) translateX(-100%);
  will-change: transform;
}
.rx-pad__sign-in { display: block; padding: 0 0.7rem; transform: translateX(100%); will-change: transform; }
.rx-pad.is-done .rx-pad__sign { visibility: visible; animation: rxSignWin 1.9s cubic-bezier(0.37, 0.1, 0.4, 1) 0.4s both; }
.rx-pad.is-done .rx-pad__sign-in { animation: rxSignBody 1.9s cubic-bezier(0.37, 0.1, 0.4, 1) 0.4s both; }
@keyframes rxSignWin {
  from { transform: rotate(-4deg) translateX(-100%); }
  to   { transform: rotate(-4deg) translateX(0); }
}
@keyframes rxSignBody {
  from { transform: translateX(100%); }
  to   { transform: translateX(0); }
}
/* Antes de las 7 preguntas la zona de la firma va vacía (pedido
   2026-10-22): el rasgo se asomaba (con la línea estirada, el dasharray no
   coincide con el largo real) y la raya de firma ya se veía. Ahora el
   rasgo se descubre con un recorte y la raya se traza al empezar a firmar. */
.rx-pad__flourish { width: 78%; height: 16px; margin-top: -0.85rem; overflow: visible; clip-path: inset(-50% 100% -50% 0); }
.rx-pad__flourish path {
  fill: none;
  stroke: var(--ink);
  stroke-width: 1.6;
  stroke-linecap: round;
  vector-effect: non-scaling-stroke;
}
.rx-pad.is-done .rx-pad__flourish { animation: rxFlourish 0.7s cubic-bezier(0.4, 0, 0.2, 1) 2.25s both; }
@keyframes rxFlourish { to { clip-path: inset(-50% 0 -50% 0); } }
.rx-pad__line { position: relative; width: 100%; margin-top: 0.15rem; padding-top: 0.3rem; font-size: 0.625rem; text-align: center; color: #888; opacity: 0; }
.rx-pad__line::before {   /* raya de firma */
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background-color: #555;
  transform: scaleX(0);
}
.rx-pad.is-done .rx-pad__line { animation: rxFade 0.4s ease-out both; }
.rx-pad.is-done .rx-pad__line::before { animation: rxRule 0.45s cubic-bezier(0.4, 0, 0.2, 1) both; }
@keyframes rxFade { from { opacity: 0; } to { opacity: 1; } }
@keyframes rxRule { from { transform: scaleX(0); } to { transform: scaleX(1); } }

.rx-pad__stamp {
  position: absolute;
  right: clamp(-0.4rem, -1vw, 0rem);
  bottom: -0.3rem;
  width: clamp(84px, 13svh, 112px);
  height: auto;
  color: #d10f17;
  opacity: 0;
  pointer-events: none;
  will-change: transform, opacity;   /* capa propia desde el inicio: el filtro de tinta no se recalcula al caer */
}
.rx-pad.is-done .rx-pad__stamp { animation: rxStamp 0.6s cubic-bezier(0.2, 0.9, 0.3, 1.15) 3.05s both; }
.rx-pad.is-done .rx-pad__signbox { animation: rxThump 0.35s ease-out 3.38s; }   /* la firma "recibe" el sellazo (antes se movía toda la hoja) */
@keyframes rxStamp {
  0%   { opacity: 0; transform: translate(14px, -46px) rotate(-38deg) scale(2.3); }
  55%  { opacity: 0.95; transform: rotate(-11deg) scale(0.9); }
  78%  { transform: rotate(-15deg) scale(1.05); }
  100% { opacity: 0.88; transform: rotate(-14deg) scale(1); }
}
@keyframes rxThump { 35% { translate: 0 3px; } 100% { translate: 0 0; } }.rx-pad__stain {   /* mancha de café, detalle */
  position: absolute;
  right: -18px;
  top: 38%;
  width: 74px;
  height: 74px;
  border-radius: 50%;
  border: 5px solid rgba(150, 100, 40, 0.12);
  box-shadow: inset 0 0 0 2px rgba(150, 100, 40, 0.06);
  pointer-events: none;
}
@media (prefers-reduced-motion: reduce) {
  .rx-pad__item, .rx-pad__item.is-again b { animation: none; }
  .rx-pad.is-done .rx-pad__flourish { clip-path: none; }
  .rx-pad.is-done .rx-pad__line { opacity: 1; }
  .rx-pad.is-done .rx-pad__line::before { transform: none; }
  .rx-pad.is-done .rx-pad__flourish,
  .rx-pad.is-done .rx-pad__line,
  .rx-pad.is-done .rx-pad__line::before { animation: none; }
  .rx-pad.is-done .rx-pad__sign { transform: rotate(-4deg); }
  .rx-pad.is-done .rx-pad__sign-in { transform: none; }
  .rx-pad.is-done .rx-pad__sign,
  .rx-pad.is-done .rx-pad__sign-in,
  .rx-pad.is-done .rx-pad__signbox,
  .rx-pad.is-done .rx-pad__stamp { animation: none; }
  .rx-pad.is-done .rx-pad__stamp { opacity: 0.88; transform: rotate(-14deg); }
}
/* Dos partes: lista de medicamentos (izq.) e "Indicaciones" (der.) */
.rx-pad__main {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr);
  gap: clamp(1rem, 2.5vw, 2rem);
  flex: 1;
  min-height: 0;
  margin-top: 0.4rem;
}
.rx-pad__main .rx-pad__body { margin-top: 0; overflow: hidden; }
.rx-pad__note {
  position: relative;
  padding: 0.9rem 1rem 0.8rem 1.1rem;
  overflow: hidden;
  border-left: 2px solid rgba(var(--color-brand-rgb), 0.35);
  background: repeating-linear-gradient(180deg, transparent 0 calc(1.9rem - 1px), rgba(31, 58, 147, 0.1) calc(1.9rem - 1px) 1.9rem);
}
.rx-pad__note-label {
  margin: 0 0 0.35rem;
  font: 700 0.625rem/1.2 var(--font-mono);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--color-brand);
}
.rx-pad__q { margin: 0 0 0.3rem; font: 700 0.9375rem/1.3 var(--font-display); color: var(--color-ink); }
.rx-pad__a { margin: 0; font-size: clamp(1.25rem, 2.9svh, 1.6rem); line-height: 1.2; }
.rx-pad__a.is-writing { animation: rxWriteDown 0.75s steps(12, end) both; }   /* se escribe de arriba abajo (antes 1.6 s; 2026-10-22) */
/* El repintado de la escritura se queda dentro de la receta (no toca el
   resto de la página) */
.rx-pad__body,
.rx-pad__note { contain: paint; }
@keyframes rxWriteDown { from { clip-path: inset(0 0 100% 0); } to { clip-path: inset(0 0 0 0); } }
.rx-pad__note .rx-pad__a:not(.is-writing) { opacity: 0.55; }
@media (min-width: 769px) and (max-width: 1100px) {
  .chat__pick { white-space: normal; }   /* columna angosta en tableta: el botón baja a 2 renglones */
  .rx-pad__main { grid-template-columns: 1fr; }   /* lista arriba, indicaciones abajo */
  .rx-pad__main .rx-pad__body { max-height: 38%; }
}

/* Sin JS (o antes de arrancar) se ve la lista de preguntas tal cual. */
.chat__data { margin: 1rem 0 0; }
.chat__data dt { font-weight: 700; }
.chat__data dd { margin: 0 0 0.75rem; color: var(--color-text-soft); }
.rx-pad.is-ready .chat__data { display: none; }
.rx-pad:not(.is-ready) .rx-pad__main { display: none; }

/* ============ 16. CONTACTO ============
   Mapa real de Google Maps a la izquierda, el formulario al centro y a
   la derecha los 4 canales como renglones horizontales que se expanden
   con el cursor. Colapsados por defecto (ícono + nombre en horizontal,
   no vertical); al hover, el renglón crece, se pinta con una vista
   ilustrativa de a dónde manda (chat de WhatsApp, bandeja de
   correo, grilla de Instagram, tarjeta de Facebook) y los demás se
   comprimen. Cada uno es un <a> real que abre la app correspondiente.
   El mapa vive en su propia columna (no es otro renglón del acordeón)
   porque un <iframe> no puede ir dentro de un <a> — contenido
   interactivo anidado, inválido en HTML. */
/* Toda la sección cabe en una pantalla: al llegar con #contacto (que
   deja --header-h libre arriba por scroll-padding) se ven encabezado,
   mapa y canales completos sin tener que seguir bajando. La altura del
   bloque mapa + canales se deriva del alto de la ventana. */
.contact {
  --contact-head: 12rem; /* encabezado de sección + paddings (+ aire extra: bloque ~10% más chico, pedido 2026-09-25) */
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding-block: clamp(1.25rem, 3vh, 2.25rem);
}

/* Más ancho que el resto de secciones para que el mapa gane a los lados
   (no hacia arriba). */
.contact > .container { max-width: 1280px; }

.contact .section__head { margin-bottom: 0; }

.contact .section__title {
  font-size: clamp(1.5rem, 2.4vw, 2rem);
  margin-bottom: 0.35rem;
}

.contact .section__lead { font-size: 0.9375rem; }

.contact-layout {
  display: grid;
  grid-template-columns: 1.1fr 1fr 0.95fr;
  grid-template-areas: "map form panels";
  gap: 1.1rem;
  margin-top: 1.25rem;
  height: clamp(320px, calc(100svh - var(--header-h) - var(--contact-head)), 480px);
}

/* ===== Mapa (izquierda) ===== */
.contact-map {
  grid-area: map;
  display: flex;
  flex-direction: column;
  min-height: 0;
  overflow: hidden;
  border-radius: 22px;
  border: 1px solid var(--color-line);
  background-color: var(--color-white);
}

.contact-map__head {
  display: flex;
  align-items: center;
  gap: 1.1rem;
  padding: 1rem 1.5rem;
}

.contact-map__icon { flex-shrink: 0; width: 26px; height: 26px; color: var(--color-brand); }
.contact-map__icon svg { width: 100%; height: 100%; }

.contact-map__body { display: flex; flex-direction: column; gap: 0.2rem; min-width: 0; }
.contact-map__label { font-size: 0.75rem; font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase; color: var(--color-ink); }
.contact-map__value { font-size: 0.9375rem; color: var(--color-text-soft); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.contact-map__link {
  flex-shrink: 0;
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.8125rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--color-brand);
  white-space: nowrap;
  transition: color 0.3s var(--ease);
}
.contact-map__link svg { width: 15px; height: 15px; transition: transform 0.3s var(--ease); }
.contact-map__link:hover { color: var(--color-brand-dark); }
.contact-map__link:hover svg { transform: translateX(3px); }

/* Recorte de la tarjeta flotante de Google: el iframe mide
   --map-crop de más y se sube esa misma cantidad. El pin queda
   --map-crop/2 arriba del centro visible, que se ve natural. */
.contact-map__frame {
  --map-crop: 150px;
  position: relative;
  flex: 1;
  min-height: 0;
  overflow: hidden;
  border-top: 1px solid var(--color-line);
}

.contact-map__embed {
  position: absolute;
  top: calc(var(--map-crop) * -1);
  left: 0;
  display: block;
  width: 100%;
  height: calc(100% + var(--map-crop));
  border: 0;
  filter: grayscale(0.15);
}

/* ===== Formulario (centro) ===== */
.contact-form {
  grid-area: form;
  display: flex;
  flex-direction: column;
  min-height: 0;
  border-radius: 22px;
  border: 1px solid var(--color-line);
  background-color: var(--color-white);
  overflow: hidden;
}

/* Solo en móvil (responsive.css): pliega/despliega el formulario. */
.contact-form__toggle { display: none; }

.contact-form__body {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  min-height: 0;
  padding: 1.1rem 1.35rem 1rem;
}

.contact-form__head { display: flex; flex-direction: column; gap: 0.15rem; margin-bottom: 0.15rem; }
.contact-form__label {
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--color-brand);
}
.contact-form__title {
  font-size: 1.0625rem;
  font-weight: 800;
  line-height: 1.25;
  color: var(--color-ink);
}

.contact-form__row { display: grid; grid-template-columns: 1fr 1fr; gap: 0.6rem; }

/* Trampa para bots de Web3Forms: fuera de vista, sin afectar el layout. */
.contact-form__honeypot { position: absolute; left: -9999px; opacity: 0; pointer-events: none; }

.field { display: flex; flex-direction: column; gap: 0.3rem; min-width: 0; }
.field--grow { flex: 1; min-height: 0; }

/* Etiqueta y error en la misma línea: el error no empuja el layout. */
.field__top { display: flex; align-items: baseline; justify-content: space-between; gap: 0.5rem; }
.field label {
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--color-ink);
}
.field__error {
  font-size: 0.6875rem;
  font-weight: 600;
  color: var(--color-brand-dark);
  text-align: right;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.field input,
.field select,
.field textarea {
  width: 100%;
  height: 40px;
  padding: 0 0.9rem;
  border: 1px solid var(--color-line);
  border-radius: 12px;
  background-color: var(--color-cream);
  font: inherit;
  font-size: 0.875rem;
  color: var(--color-ink);
  transition: border-color 0.3s var(--ease), background-color 0.3s var(--ease), box-shadow 0.3s var(--ease);
}

.field select {
  appearance: none;
  -webkit-appearance: none;
  padding-right: 2.4rem;
  cursor: pointer;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23040404' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 0.85rem center;
  background-size: 16px;
}
.field select:invalid { color: #8a8a8a; } /* placeholder "Selecciona una opción" */

.field textarea {
  flex: 1;
  min-height: 64px;
  padding: 0.65rem 0.9rem;
  resize: none;
  line-height: 1.45;
}

.field input::placeholder,
.field textarea::placeholder { color: #8a8a8a; }

.field input:hover,
.field select:hover,
.field textarea:hover { border-color: #c4c4c4; }

.field input:focus,
.field select:focus,
.field textarea:focus {
  outline: none;
  border-color: var(--color-brand);
  background-color: var(--color-white);
  box-shadow: 0 0 0 4px var(--color-brand-soft);
}

.field.has-error input,
.field.has-error select,
.field.has-error textarea { border-color: var(--color-brand-dark); background-color: #fff7f7; }

.contact-form__submit { margin-top: 0.15rem; padding-block: 0.85rem; }
.contact-form__submit svg { width: 16px; height: 16px; transition: transform 0.35s var(--ease); }
.contact-form__submit:hover svg { transform: translate(3px, -3px); }
.contact-form__submit:disabled { opacity: 0.7; cursor: progress; }

/* Aviso legal bajo el botón: una línea pequeña y pegada al botón para
   no romper la regla de "Contacto cabe en una pantalla". */
.contact-form__legal {
  margin: -0.2rem 0 0;
  font-size: 0.6875rem;
  line-height: 1.3;
  text-align: center;
  color: var(--color-text-soft);
}
.contact-form__legal a { color: inherit; text-decoration: underline; text-underline-offset: 2px; }
.contact-form__legal a:hover { color: var(--color-brand-dark); }

.contact-form__status {
  min-height: 1.1em;
  margin: 0;
  font-size: 0.75rem;
  font-weight: 600;
  line-height: 1.35;
  text-align: center;
  color: var(--color-text-soft);
}
.contact-form__status.is-ok    { color: #0f8a43; }
.contact-form__status.is-error { color: var(--color-brand-dark); }
.contact-form__status:empty { display: none; }

/* Pantallas bajas (laptops de 720–800px de alto): el formulario se
   compacta para que la sección siga cabiendo sin cortar el mensaje. */
@media (max-height: 820px) {
  .contact-form__body { gap: 0.45rem; padding-block: 0.9rem 0.85rem; }
  .contact-form__title { display: none; }
  .contact-form__row { gap: 0.5rem; }
  .field { gap: 0.2rem; }
  .field input,
  .field select { height: 36px; }
  .field textarea { min-height: 48px; }
  .contact-form__submit { padding-block: 0.75rem; }
}

/* ===== Renglones de canales (derecha) ===== */
.contact-panels {
  grid-area: panels;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  min-height: 0;
}

/* Renglones claros (blanco sobre el crema de la página) para que el
   ícono de cada canal se distinga con su propio color. --ch es el color
   del canal (ícono y acentos), --ch-strong una versión más oscura que
   aguanta texto blanco encima (botón), --ch-soft el tinte de fondo. */
.contact-panel {
  --ch: var(--color-brand);
  --ch-strong: var(--color-brand-dark);
  --ch-soft: var(--color-brand-soft);
  position: relative;
  flex: 1;
  min-height: 0;
  display: block;
  border-radius: 16px;
  overflow: hidden;
  background-color: var(--color-white);
  border: 1px solid var(--color-line);
  text-decoration: none;
  transition: flex 0.65s cubic-bezier(0.22, 1, 0.36, 1), border-color 0.4s var(--ease), box-shadow 0.4s var(--ease);
}

.contact-panel--whatsapp  { --ch: #25d366; --ch-strong: #0f8a43; --ch-soft: rgba(37, 211, 102, 0.14); }
.contact-panel--instagram { --ch: #d62976; --ch-strong: #c1236a; --ch-soft: rgba(214, 41, 118, 0.12); }
.contact-panel--facebook  { --ch: #1877f2; --ch-strong: #1466d6; --ch-soft: rgba(24, 119, 242, 0.12); }

.contact-panel:is(:hover, .is-open) {
  flex: 3.6;
  border-color: var(--ch);
  box-shadow: 0 18px 40px -22px rgba(0, 0, 0, 0.35);
}
/* Solo con cursor real: en el teléfono el :hover se queda "pegado" tras
   tocar y esta regla (más específica) aplastaba a los demás canales hasta
   esconderlos (2026-10-22). En teléfono los tamaños los pone responsive.css. */
@media (hover: hover) {
  .contact-panels:hover .contact-panel:not(:hover) { flex: 0.62; }
}

/* Vista ilustrativa de a dónde manda cada canal (mockup SVG con la
   marca) — anclada abajo a la derecha, como un
   teléfono que asoma, y oculta hasta el hover. */
.contact-panel__art {
  position: absolute;
  right: 1.25rem;
  bottom: 0;
  z-index: 2;
  width: auto;
  height: 92%;
  max-width: 48%;
  object-fit: contain;
  object-position: right bottom;
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.5s var(--ease), transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
  pointer-events: none;
}
.contact-panel:is(:hover, .is-open) .contact-panel__art { opacity: 1; transform: translateY(0); transition-delay: 0.12s; }

/* Tinte suave del color del canal detrás del mockup. */
.contact-panel__scrim {
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 82% 110%, var(--ch-soft), transparent 62%);
  opacity: 0;
  transition: opacity 0.5s var(--ease);
  pointer-events: none;
}
.contact-panel:is(:hover, .is-open) .contact-panel__scrim { opacity: 1; }

/* Colapsado: ícono + nombre en horizontal, alineados a la izquierda. */
.contact-panel__collapsed {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: flex;
  align-items: center;
  gap: 0.9rem;
  padding: 0 1.25rem;
  opacity: 1;
  transition: opacity 0.35s var(--ease);
}
.contact-panel:is(:hover, .is-open) .contact-panel__collapsed { opacity: 0; }

.contact-panel__icon {
  flex-shrink: 0;
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  padding: 8px;
  border-radius: 50%;
  background-color: var(--ch-soft);
  color: var(--ch);
}
.contact-panel__icon svg { width: 100%; height: 100%; }

.contact-panel__name {
  font-size: 1.0625rem;
  font-weight: 700;
  letter-spacing: 0.01em;
  color: var(--color-ink);
  white-space: nowrap;
}

/* Expandido: ícono grande arriba, nombre/dato y botón debajo, todo en
   la mitad izquierda — la derecha la ocupa el mockup. */
.contact-panel__expanded {
  position: absolute;
  inset: 0;
  right: 50%;
  z-index: 3;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
  gap: 0.75rem;
  padding: 0 0 0 1.5rem;
  opacity: 0;
  transition: opacity 0.4s var(--ease) 0.1s;
  pointer-events: none;
}
.contact-panel:is(:hover, .is-open) .contact-panel__expanded {
  opacity: 1;
  pointer-events: auto;
}

.contact-panel__icon-lg {
  flex-shrink: 0;
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  padding: 9px;
  border-radius: 14px;
  background-color: var(--ch);
  color: var(--color-white);
  transform: scale(0.6);
  transition: transform 0.45s cubic-bezier(0.22, 1.6, 0.36, 1) 0.12s;
}
.contact-panel:is(:hover, .is-open) .contact-panel__icon-lg { transform: scale(1); }
.contact-panel__icon-lg svg { width: 100%; height: 100%; }

.contact-panel__text { display: flex; flex-direction: column; gap: 0.15rem; min-width: 0; max-width: 100%; }
.contact-panel__label { font-size: 1.25rem; font-weight: 800; color: var(--color-ink); white-space: nowrap; }
.contact-panel__value {
  font-size: 0.875rem;
  color: var(--color-text-soft);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.contact-panel__cta {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.5rem 1rem;
  border-radius: 999px;
  background-color: var(--ch-strong);
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--color-white);
}
.contact-panel__cta svg { width: 14px; height: 14px; transform: translateX(-4px); transition: transform 0.3s var(--ease); }
.contact-panel:is(:hover, .is-open) .contact-panel__cta svg { transform: translateX(0); }

/* ============ 17. FOOTER ============ */
/* ---- CTA final: visita thesocialbox.marketing ----
   Ventana de navegador del ancho del contenido (opción elegida por el
   usuario 2026-09-28): barra (.site-cta__bar) con los tres puntos y la
   dirección del sitio —mismo lenguaje que .project-card__bar de
   Proyectos— y abajo la "pantalla" (.site-cta__screen) con el video del
   equipo de fondo y velo del lado del texto. Lleva aire abajo para no
   pegarse al footer. --cta-radius es el radio de las esquinas de abajo
   de la pantalla, para que recorte y velo coincidan con el borde. */
.site-cta { padding-block: clamp(1.5rem, 4svh, 2.5rem) clamp(2.5rem, 7svh, 4.5rem); }

.site-cta__window {
  --cta-radius: 20px;
  max-width: 1160px;
  margin-inline: auto;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: calc(var(--cta-radius) + 2px);
  background-color: #2b2b2b;
  box-shadow: 0 30px 70px rgba(var(--color-ink-rgb), 0.35), 0 0 0 1px rgba(var(--color-ink-rgb), 0.06);
  transition: transform 0.5s var(--ease), box-shadow 0.5s var(--ease);
}

@media (hover: hover) {
  .site-cta__window:hover {
    transform: translateY(-4px);
    box-shadow: 0 40px 90px rgba(var(--color-ink-rgb), 0.4), 0 0 0 1px rgba(var(--color-ink-rgb), 0.06);
  }
}

.site-cta__bar {
  display: flex;
  align-items: center;
  gap: 7px;
  height: 40px;
  padding-inline: 16px;
}

.site-cta__bar i {
  flex-shrink: 0;
  width: 11px;
  height: 11px;
  border-radius: 50%;
  background-color: #4a4a4a;
}

.site-cta__bar i:first-child { background-color: var(--color-brand); }

.site-cta__url {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  min-width: 0;
  max-width: 360px;
  flex: 1;
  margin: 0 auto;
  padding: 4px 14px;
  border-radius: var(--radius-full);
  background-color: rgba(255, 255, 255, 0.08);
  color: rgba(255, 255, 255, 0.75);
  font-size: 0.75rem;
  letter-spacing: 0.02em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  transform: translateX(-24px); /* compensa los puntos: la dirección queda centrada en la ventana */
}

.site-cta__url svg { flex-shrink: 0; color: #4ade80; }

.site-cta__screen {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2.5rem;
  min-height: clamp(240px, 36svh, 340px);
  padding: clamp(2rem, 5vw, 3.5rem) clamp(1.75rem, 5vw, 4.5rem);
  border-radius: 0 0 var(--cta-radius) var(--cta-radius);
  isolation: isolate;
  background-color: var(--color-ink);
}

/* Capa del video. El video se pinta en una capa por hardware que en
   algunos navegadores (Safari/iOS, y Chrome durante animaciones) se
   salta el recorte de overflow + border-radius y se veía rectangular.
   clip-path y la máscara sí la recortan; translateZ la fija en su capa. */
.site-cta__media {
  position: absolute;
  inset: 0;
  z-index: -1;
  overflow: hidden;
  border-radius: inherit;
  clip-path: inset(0 round 0 0 var(--cta-radius) var(--cta-radius));
  -webkit-mask-image: -webkit-radial-gradient(white, black);
  transform: translateZ(0);
}

.site-cta__bg {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 50%;
  transition: transform 1.2s var(--ease);
}

.site-cta__window:hover .site-cta__bg { transform: scale(1.04); }

/* Velo: oscuro del lado del texto, más ligero a la derecha para que se
   vea el video. */
.site-cta__media::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1; /* encima del video, dentro de .site-cta__media */
  background: linear-gradient(90deg, rgba(var(--color-ink-rgb), 0.88) 0%, rgba(var(--color-ink-rgb), 0.62) 50%, rgba(var(--color-ink-rgb), 0.35) 100%);
}

.site-cta__eyebrow {
  margin-bottom: 0.4rem;
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--color-brand);
}

.site-cta__title {
  margin-bottom: 0.5rem;
  font-size: clamp(1.5rem, 3.4vw, 2.5rem);
  font-weight: 800;
  line-height: 1.1;
  color: var(--color-white);
}

.site-cta__lead {
  max-width: 44ch;
  margin: 0;
  font-size: 1.0625rem;
  color: rgba(255, 255, 255, 0.85);
}

.site-cta__btn { flex-shrink: 0; }
.site-cta__btn svg { transition: transform 0.3s var(--ease); }
.site-cta__btn:hover svg { transform: translate(2px, -2px); }

.site-footer {
  position: relative;
  background-color: var(--color-ink);
  color: rgba(255, 255, 255, 0.6);
  font-size: 0.9375rem;
  overflow: hidden;
}

.site-footer::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--color-brand), transparent);
  background-size: 200% 100%;
  animation: footerShimmer 7s linear infinite;
}

@keyframes footerShimmer {
  0%   { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

/* Cinta (negra desde 2026-09-28) entre Nosotros y Proyectos, con los servicios
   corriendo sin fin. main.js §18 escribe --tape-shift (ancho de una
   lista) y --tape-dur (velocidad constante en px/s). */
.brand-band { overflow: hidden; }

.tape {
  padding-block: clamp(0.85rem, 1.6vw, 1.2rem);
  overflow: hidden;
}

/* Negra (la que se usa desde 2026-09-28, pedido del usuario): texto
   blanco y, al pasar el cursor, cada servicio se enciende en rojo. */
.tape--black {
  background-color: var(--color-ink);
  color: var(--color-white);
}

.tape__track {
  display: flex;
  width: max-content;
  animation: tapeScroll var(--tape-dur, 30s) linear infinite;
}

.tape:hover .tape__track { animation-play-state: paused; }

@keyframes tapeScroll {
  to { transform: translateX(calc(-1 * var(--tape-shift, 50%))); }
}

.tape__list {
  display: flex;
  flex-shrink: 0;
  margin: 0;
  padding: 0;
  list-style: none;
}

/* Sin separadores (pedido del cliente): el aire entre servicios sale
   del padding de cada uno. */
.tape__list li {
  padding-right: clamp(2rem, 4vw, 3.5rem);
  font-family: var(--font-display);
  font-size: clamp(1rem, 2.1vw, 1.625rem);
  font-weight: 800;
  line-height: 1;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  white-space: nowrap;
  transition: color 0.25s var(--ease);
}
.tape--black .tape__list li:hover { color: var(--color-brand); }

/* Cinta blanca de logos de clientes (entre Portafolio y Cómo trabajamos).
   Mismo motor que la negra (main.js §18). Cada logo cabe en una caja
   máxima (los PNG vienen recortados a su dibujo), así un logo apaisado
   como Kronos no domina a uno casi cuadrado como Athletic. En gris y
   atenuados para que no compitan; a color al pasar el cursor. */

.tape--logos .tape__list { align-items: center; }

.tape--logos .tape__list li {
  display: flex;
  align-items: center;
  padding-right: clamp(2.5rem, 5vw, 4.5rem);
  font-size: 0;
  line-height: 0;
}

.tape--logos img {
  width: auto;
  height: auto;
  max-width: var(--logo-w, 140px);
  max-height: var(--logo-h, 52px);
  filter: grayscale(1);
  opacity: 0.6;
  transition: filter 0.3s var(--ease), opacity 0.3s var(--ease);
}

.tape--logos li:hover img { filter: none; opacity: 1; }

@media (prefers-reduced-motion: reduce) {
  .tape__track { animation: none; }
}

/* ---- Footer real: marca · Explora · Contacto · Síguenos ----
   Compacto a propósito (una franja). main.js §17 escribe --fx/--fy para
   el brillo rojo que sigue al cursor y maneja el botón de copiar correo. */
.site-footer--full { --fx: 50%; --fy: 0%; }

.footer__glow {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: radial-gradient(420px circle at var(--fx) var(--fy), rgba(var(--color-brand-rgb), 0.16), transparent 70%);
  opacity: 0;
  transition: opacity 0.5s var(--ease);
}

.site-footer--full:hover .footer__glow { opacity: 1; }

.footer__grid {
  position: relative;
  display: grid;
  grid-template-columns: 1.4fr 0.8fr 1.3fr 0.9fr;
  gap: clamp(1.5rem, 3vw, 3rem);
  padding-block: clamp(2rem, 4vw, 2.75rem) clamp(1.5rem, 3vw, 2rem);
}

.footer__logo { display: inline-block; transition: transform 0.4s var(--ease); }
.footer__logo:hover { transform: scale(1.05) rotate(-2deg); }
.footer__logo img { width: auto; height: 56px; }

.footer__tagline {
  max-width: 28ch;
  margin: 0.85rem 0 0;
  line-height: 1.55;
  color: rgba(255, 255, 255, 0.55);
}

.footer__heading {
  margin: 0 0 0.85rem;
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--color-brand);
}

.footer__links,
.footer__contact,
.footer__social { list-style: none; margin: 0; padding: 0; }

.footer__links { display: grid; gap: 0.55rem; }

/* Enlaces: una flecha roja entra desde la izquierda y empuja el texto. */
.footer__links a {
  display: inline-flex;
  align-items: center;
  color: rgba(255, 255, 255, 0.75);
  transition: color 0.3s var(--ease);
}

.footer__links a::before {
  content: "→";
  display: inline-block;
  width: 0;
  overflow: hidden;
  color: var(--color-brand);
  opacity: 0;
  transition: width 0.3s var(--ease), opacity 0.3s var(--ease), margin 0.3s var(--ease);
}

.footer__links a:hover,
.footer__links a:focus-visible { color: var(--color-white); }
.footer__links a:hover::before,
.footer__links a:focus-visible::before { width: 1em; margin-right: 0.35rem; opacity: 1; }

.footer__contact { display: grid; gap: 0.6rem; }

.footer__contact li { display: flex; align-items: center; gap: 0.35rem; }

.footer__contact a {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  color: rgba(255, 255, 255, 0.75);
  transition: color 0.3s var(--ease);
}

.footer__contact a svg {
  flex-shrink: 0;
  width: 16px;
  height: 16px;
  color: var(--color-brand);
  transition: transform 0.35s var(--ease);
}

.footer__contact a:hover { color: var(--color-white); }
.footer__contact a:hover svg { transform: scale(1.2) rotate(-8deg); }

/* Copiar correo: aparece junto al correo; al copiar muestra "¡Copiado!". */
.footer__copy-btn {
  position: relative;
  display: grid;
  place-items: center;
  width: 26px;
  height: 26px;
  padding: 0;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: rgba(255, 255, 255, 0.45);
  cursor: pointer;
  transition: color 0.3s var(--ease), background-color 0.3s var(--ease);
}

.footer__copy-btn svg { width: 14px; height: 14px; }
.footer__copy-btn:hover,
.footer__copy-btn:focus-visible { color: var(--color-white); background-color: rgba(255, 255, 255, 0.08); }

.footer__copy-tip {
  position: absolute;
  bottom: calc(100% + 6px);
  left: 50%;
  padding: 0.25rem 0.5rem;
  border-radius: 6px;
  background-color: var(--color-brand);
  color: var(--color-white);
  font-size: 0.75rem;
  font-weight: 700;
  white-space: nowrap;
  opacity: 0;
  transform: translate(-50%, 4px);
  pointer-events: none;
  transition: opacity 0.25s var(--ease), transform 0.25s var(--ease);
}

.footer__copy-btn.is-copied .footer__copy-tip { opacity: 1; transform: translate(-50%, 0); }

/* Redes: círculos con contorno que se rellenan de rojo desde abajo,
   suben un poco y muestran su nombre en una etiqueta. */
.footer__social { display: flex; gap: 0.6rem; }

.footer__social a {
  position: relative;
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 50%;
  color: var(--color-white);
  isolation: isolate;
  transition: transform 0.35s var(--ease), border-color 0.35s var(--ease);
}

.footer__social a::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  border-radius: inherit;
  background-color: var(--color-brand);
  /* Se llena de abajo hacia arriba recortando (no escalando): una elipse
     escalada se salía del círculo por abajo a medio camino. */
  clip-path: inset(100% 0 0 0);
  transition: clip-path 0.35s var(--ease);
}

.footer__social a::after {
  content: attr(data-label);
  position: absolute;
  bottom: calc(100% + 8px);
  left: 50%;
  padding: 0.2rem 0.5rem;
  border-radius: 6px;
  background-color: var(--color-white);
  color: var(--color-ink);
  font-size: 0.75rem;
  font-weight: 700;
  white-space: nowrap;
  opacity: 0;
  transform: translate(-50%, 4px);
  pointer-events: none;
  transition: opacity 0.25s var(--ease), transform 0.25s var(--ease);
}

.footer__social svg { width: 18px; height: 18px; }

.footer__social a:hover,
.footer__social a:focus-visible { transform: translateY(-3px); border-color: var(--color-brand); }
.footer__social a:hover::before,
.footer__social a:focus-visible::before { clip-path: inset(0 0 0 0); }
.footer__social a:hover::after,
.footer__social a:focus-visible::after { opacity: 1; transform: translate(-50%, 0); }

/* ---- Franja inferior: © + legales ---- */
.footer__bottom {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding-block: 0.9rem;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  font-size: 0.875rem;
  color: rgba(255, 255, 255, 0.45);
}

.footer__copy { margin: 0; }

.footer__legal { display: flex; gap: 1.25rem; margin: 0; padding: 0; list-style: none; }

.footer__legal a { position: relative; white-space: nowrap; transition: color 0.3s var(--ease); }

.footer__legal a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -2px;
  width: 100%;
  height: 1px;
  background-color: var(--color-brand);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.35s var(--ease);
}

.footer__legal a:hover { color: var(--color-brand); }
.footer__legal a:hover::after { transform: scaleX(1); }

/* ============ 18. ANIMACIONES (REVEAL) ============ */
/* Patrón usado en TODA la landing: cualquier elemento con la clase
   .reveal o .reveal-repeat (mismo comportamiento, dos nombres por
   compatibilidad con el HTML existente) aparece con fade + desplazamiento
   al entrar en pantalla y VUELVE A OCULTARSE al salir, para reaparecer
   cada vez que se vuelve a scrollear hasta ahí (efecto "permanente" en
   toda la página, no solo la primera vez — ver main.js §3). No se anima
   si el usuario tiene activado "reducir movimiento". */
.reveal,
.reveal-repeat {
  opacity: 0;
  transform: translateY(26px);
  transition: opacity 0.8s var(--ease), transform 0.8s var(--ease);
}

.reveal.is-visible,
.reveal-repeat.is-visible { opacity: 1; transform: none; }

/* ============ 17.2 PÁGINAS SECUNDARIAS (GRACIAS, 404, AVISO) ============ */
.status-page {
  min-height: 100svh;
  display: grid;
  place-items: center;
  padding: 3rem var(--gutter);
  background-color: var(--color-ink);
  text-align: center;
}

.status-page__container { max-width: 560px; }

.status-page__code {
  margin-bottom: 0.5rem;
  font-family: var(--font-accent);
  font-size: clamp(4rem, 12vw, 7rem);
  line-height: 1;
  color: var(--color-brand);
}

.status-page__title {
  margin-bottom: 1rem;
  font-weight: 700;
  font-size: clamp(2rem, 5vw, 3rem);
  color: var(--color-white);
}

.status-page__text { color: var(--color-body); }

.status-page__actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.75rem;
  margin-top: 2rem;
}

.legal-page__header {
  padding-block: 1.25rem;
  border-bottom: 1px solid var(--color-line);
  background-color: var(--color-ink);
}

.legal-page__logo img { width: 72px; height: auto; }

.legal-page__body {
  padding-block: 3rem 4rem;
}

.legal-page__body h1 {
  margin-bottom: 0.5rem;
  font-weight: 700;
  font-size: clamp(2rem, 5vw, 3rem);
}

.legal-page__body h2 {
  margin-top: 2rem;
  margin-bottom: 0.75rem;
  font-weight: 700;
  font-size: 1.25rem;
}

.legal-page__body a { color: var(--color-brand); text-decoration: underline; }

.legal-page__footer {
  padding-block: 1.5rem;
  border-top: 1px solid var(--color-line);
  background-color: var(--color-ink);
  font-size: 0.875rem;
  color: var(--color-body);
}

/* ============ 19. BARRA CTA FIJA EN MÓVIL ============ */
/* Sustituye a cualquier menú de navegación en móvil (nada de
   hamburguesa). Es el patrón de mayor impacto de conversión en
   móvil según la evidencia de la industria: 1–2 acciones siempre visibles
   al pie de la pantalla. Se oculta automáticamente en escritorio. */
.mobile-cta-bar {
  display: none;
}

/* ============ 20. INTERACCIONES: BOTONES, RIPPLE, MAGNETISMO, PARALLAX ============ */

/* ==========================================================================
   §22–30 · LO PROPIO DE ESTA LANDING: "SIGNOS VITALES DEL CONSULTORIO"
   Hilo visual: una línea de pulso (ECG) roja que aparece en el hero, las
   cifras, el chequeo, el proceso, la comparativa y el footer. Lecturas
   tipo monitor en JetBrains Mono (--font-mono).
   ========================================================================== */
:root {
  --font-mono: "JetBrains Mono", ui-monospace, "Cascadia Mono", Consolas, monospace;
  --pulse-glow: 0 0 18px rgba(var(--color-brand-rgb), 0.55);
}

/* El primer bloque de la sección 18 (reveal) ya viene de la base; aquí solo
   lo que cambia. */
.btn svg { width: 18px; height: 18px; flex-shrink: 0; }

/* ============ 22. HERO — MONITOR DE SIGNOS VITALES ============
   Fondo negro con cuadrícula de monitor, línea de pulso en canvas a todo
   lo ancho (main.js §21) y la foto en un marco con esquinas de visor. Las
   notificaciones entran una por latido. */
.hero--vitals {
  position: relative;
  min-height: 100svh;
  display: flex;
  align-items: center;
  padding: calc(var(--header-h) + 1.5rem) 0 clamp(3rem, 8svh, 5rem);
  background:
    radial-gradient(60% 70% at 78% 40%, rgba(var(--color-brand-rgb), 0.16), transparent 70%),
    radial-gradient(50% 60% at 10% 90%, rgba(255, 255, 255, 0.05), transparent 70%),
    var(--color-ink);
  color: var(--color-body);
  overflow: hidden;
  isolation: isolate;
}

.hero__grid {
  position: absolute;
  inset: 0;
  z-index: -1;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.045) 1px, transparent 1px);
  background-size: 44px 44px;
  -webkit-mask-image: radial-gradient(ellipse 80% 70% at 50% 50%, #000 30%, transparent 100%);
          mask-image: radial-gradient(ellipse 80% 70% at 50% 50%, #000 30%, transparent 100%);
}

.hero__ecg {
  position: absolute;
  inset: 0;
  z-index: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  /* Tenue detrás del texto, plena junto a la foto */
  -webkit-mask-image: linear-gradient(90deg, rgba(0, 0, 0, 0.28) 0%, rgba(0, 0, 0, 0.28) 42%, #000 62%);
          mask-image: linear-gradient(90deg, rgba(0, 0, 0, 0.28) 0%, rgba(0, 0, 0, 0.28) 42%, #000 62%);
}

.hero__layout {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
  gap: clamp(2rem, 5vw, 5rem);
  align-items: center;
}

.hero__eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  margin-bottom: 1.1rem;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.72);
}

.hero__live {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background-color: var(--color-brand);
  box-shadow: 0 0 0 0 rgba(var(--color-brand-rgb), 0.6);
  animation: clockPulse 1.1s var(--ease) infinite;
}

.hero__title {
  margin-bottom: 1.25rem;
  font-family: var(--font-hero);
  font-size: clamp(2.2rem, 4vw, 3.6rem);
  font-weight: 800;
  line-height: 1.02;
  letter-spacing: -0.025em;
  color: var(--color-white);
}

.hero__title-line { display: block; }
.hero__title-accent { color: var(--color-brand); text-shadow: var(--pulse-glow); }

.hero__text {
  max-width: 46ch;
  margin-bottom: 1.75rem;
  font-size: clamp(1rem, 1.25vw, 1.125rem);
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.78);
}

/* Entrada escalonada al cargar */
.hero__copy > * {
  opacity: 0;
  transform: translateY(22px);
  animation: heroIn 0.9s var(--ease) forwards;
}
.hero__copy > :nth-child(2) { animation-delay: 0.12s; }
.hero__copy > :nth-child(3) { animation-delay: 0.24s; }
.hero__copy > :nth-child(4) { animation-delay: 0.36s; }

@keyframes heroIn { to { opacity: 1; transform: none; } }

/* Foto en marco de visor */
.hero__media {
  position: relative;
  justify-self: end;
  width: min(100%, 440px);
  height: clamp(340px, 66svh, 640px);
  opacity: 0;
  animation: heroIn 1.1s var(--ease) 0.3s forwards;
  transform: translateY(22px);
}

.hero__frame {
  position: absolute;
  inset: 0;
  overflow: hidden;
  border-radius: 30px;
  box-shadow: 0 40px 90px rgba(0, 0, 0, 0.55), 0 0 0 1px rgba(255, 255, 255, 0.08);
}

.hero__slides {
  position: absolute;
  inset: 0;
}

.hero__frame img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 30%;
  opacity: 0;
  transition: opacity 0.9s ease;
}

/* La foto nueva aparece encima de la anterior, que sigue visible debajo:
   así el cruce nunca deja ver el fondo. */
/* Fotos con poco aire arriba: el recorte se pega al borde para no cortar la cabeza. */
.hero__frame img.is-top { object-position: 50% 0; }
.hero__frame img.is-on { z-index: 2; opacity: 1; }
.hero__frame img.is-prev { z-index: 1; opacity: 1; transition: none; }

/* Línea de escáner que baja por la foto */
.hero__scan {
  position: absolute;
  left: 0;
  right: 0;
  top: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.9), transparent);
  box-shadow: 0 0 22px 6px rgba(255, 255, 255, 0.25);
  animation: heroScan 5.5s linear infinite;
}

@keyframes heroScan {
  0%   { transform: translateY(-10px); opacity: 0; }
  8%   { opacity: 1; }
  92%  { opacity: 1; }
  100% { transform: translateY(var(--scan-h, 640px)); opacity: 0; }
}

.hero__corner {
  position: absolute;
  width: 34px;
  height: 34px;
  border: 2px solid var(--color-brand);
  pointer-events: none;
}
.hero__corner--tl { top: -14px; left: -14px; border-right: 0; border-bottom: 0; border-top-left-radius: 12px; }
.hero__corner--br { right: -14px; bottom: -14px; border-left: 0; border-top: 0; border-bottom-right-radius: 12px; }

/* Notificaciones abajo a la izquierda (sobre la bata, lejos de la cara);
   la nueva entra abajo y las anteriores suben. */
.pings {
  position: absolute;
  left: -16%;
  bottom: 7%;
  width: 280px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.ping {
  --slot: 0;
  position: absolute;
  bottom: 0;
  left: 0;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  width: 100%;
  padding: 0.7rem 0.9rem;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 16px;
  background-color: rgba(18, 18, 18, 0.74);
  backdrop-filter: blur(14px) saturate(1.2);
  -webkit-backdrop-filter: blur(14px) saturate(1.2);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.45);
  opacity: 0;
  transform: translate(-24px, 12px) scale(0.94);
  filter: blur(4px);
  transition: transform 0.7s var(--ease), opacity 0.5s var(--ease), filter 0.5s var(--ease);
}

.ping.is-in {
  opacity: calc(1 - var(--slot) * 0.3);
  transform: translate(calc(var(--slot) * -10px), calc(var(--slot) * -70px)) scale(calc(1 - var(--slot) * 0.06));
  filter: none;
}

.ping.is-out {
  opacity: 0;
  transform: translate(-30px, -150px) scale(0.85);
}

.ping__icon {
  flex-shrink: 0;
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  padding: 8px;
  border-radius: 11px;
  color: var(--color-white);
  background-color: var(--color-brand);
}
.ping__icon svg { width: 100%; height: 100%; }
.ping--wa   .ping__icon { background-color: #25d366; }
.ping--star .ping__icon { background-color: #fbbc04; color: #3b2a00; }
.ping--cal  .ping__icon { background-color: var(--color-brand); }
.ping--ig   .ping__icon { background: linear-gradient(135deg, #feda75, #d62976 55%, #4f5bd5); }
.ping--map  .ping__icon { background-color: #1a73e8; }

.ping__body {
  min-width: 0;
  font-size: 0.78rem;
  line-height: 1.35;
  color: rgba(255, 255, 255, 0.72);
}
.ping__body b {
  display: block;
  font-size: 0.8125rem;
  font-weight: 700;
  color: var(--color-white);
}

/* Escritura del acento del título: un recorte revela la línea de
   izquierda a derecha con una punta brillante al frente. */
.hero__write {
  position: relative;
  display: inline-block;
  clip-path: inset(-20% 100% -40% 0);
  animation: heroWrite 1.7s cubic-bezier(0.45, 0, 0.25, 1) 0.75s forwards;
}
@keyframes heroWrite { to { clip-path: inset(-20% -2% -40% 0); } }
.hero__write-head {
  position: absolute;
  inset: 0;
  pointer-events: none;
  transform: translateX(-100%);
  animation: heroHead 1.7s cubic-bezier(0.45, 0, 0.25, 1) 0.75s forwards;
}
.hero__write-head::after {
  content: "";
  position: absolute;
  top: 10%;
  bottom: -10%;
  right: -2px;
  width: 3px;
  border-radius: 3px;
  background-color: #fff;
  box-shadow: 0 0 14px 4px rgba(var(--color-brand-rgb), 0.9);
}
@keyframes heroHead {
  0%   { transform: translateX(-100%); opacity: 1; }
  92%  { opacity: 1; }
  100% { transform: translateX(0); opacity: 0; }
}

/* Pulso que baja del hero al chequeo (main.js §21.1) */
.pulse-trip {
  position: absolute;
  left: 0;
  z-index: 90;
  width: 100%;
  overflow: visible;
  pointer-events: none;
  transition: opacity 0.6s ease;
}
.pulse-trip.is-done { opacity: 0; }
.pulse-trip svg { position: absolute; top: 0; left: 0; overflow: visible; }
.pulse-trip path {
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-dasharray: 1;
  stroke-dashoffset: 1;
}
.pulse-trip__glow { stroke: rgba(var(--color-brand-rgb), 0.35); stroke-width: 10; }
.pulse-trip__line { stroke: var(--color-brand); stroke-width: 3; }
.pulse-trip__dot {
  position: absolute;
  top: -9px;
  left: -9px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: radial-gradient(circle, #fff 0 25%, rgba(var(--color-brand-rgb), 0.85) 45%, rgba(var(--color-brand-rgb), 0) 72%);
  box-shadow: 0 0 22px 8px rgba(var(--color-brand-rgb), 0.55);
}

.monitor.is-zap { animation: monitorZap 0.9s var(--ease); }
@keyframes monitorZap {
  0%   { box-shadow: 0 0 0 0 rgba(var(--color-brand-rgb), 0.9); }
  100% { box-shadow: 0 0 0 26px rgba(var(--color-brand-rgb), 0); }
}

.hero__scroll {
  position: absolute;
  left: 50%;
  bottom: 1.4rem;
  z-index: 2;
  width: 26px;
  height: 42px;
  margin-left: -13px;
  border: 1.5px solid rgba(255, 255, 255, 0.4);
  border-radius: 14px;
}
.hero__scroll span {
  position: absolute;
  top: 8px;
  left: 50%;
  width: 4px;
  height: 8px;
  margin-left: -2px;
  border-radius: 2px;
  background-color: var(--color-brand);
  animation: heroWheel 1.8s var(--ease) infinite;
}
@keyframes heroWheel {
  0%   { transform: translateY(0); opacity: 1; }
  70%  { transform: translateY(14px); opacity: 0; }
  100% { transform: translateY(0); opacity: 0; }
}

/* ============ 23. SIGNOS VITALES (CIFRAS) ============ */
.vitals {
  position: relative;
  padding-block: 0 clamp(2rem, 6svh, 3.5rem);
  background-color: var(--color-ink);
}

.vitals__strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  border-block: 1px solid rgba(255, 255, 255, 0.1);
}

.vital {
  position: relative;
  padding: 1.4rem 1.5rem 1.2rem;
}
.vital + .vital { border-left: 1px solid rgba(255, 255, 255, 0.1); }

.vital__label {
  margin-bottom: 0.4rem;
  font-family: var(--font-mono);
  font-size: 0.6875rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.55);
}

.vital__value {
  margin: 0;
  font-family: var(--font-accent);
  font-size: clamp(2rem, 3.4vw, 2.9rem);
  line-height: 1;
  color: var(--color-white);
}
.vital__value small { margin-left: 0.1em; font-size: 0.6em; color: var(--color-brand); }

[data-count] { display: inline-block; transition: transform 0.6s var(--ease), opacity 0.6s var(--ease); }
.vitals__strip:not(.is-visible) [data-count] { opacity: 0; transform: translateY(12px); }

/* "Ausculta nuestra trayectoria" (main.js §21.2): estetoscopio sobre 7
   latidos 2020–2026; el que escucha se enciende y los anteriores quedan
   tenues. El trazo y las piezas los arma el JS. */
.vital--steth { cursor: ew-resize; touch-action: pan-y; }
.steth__num { display: inline-block; min-width: 0.65em; }
.vital__value small.is-off { visibility: hidden; }
.steth {
  position: absolute;
  right: 1.25rem;
  bottom: 0.85rem;
  width: 50%;
  height: 50px;
}
.steth__trace { position: absolute; top: 0; left: 0; width: 100%; height: 34px; overflow: visible; }
.steth__trace path {
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
  vector-effect: non-scaling-stroke;
}
.steth__base { stroke: rgba(255, 255, 255, 0.18); stroke-width: 1.4; }
.steth__beat {
  stroke: rgba(var(--color-brand-rgb), 0.28);
  stroke-width: 1.6;
  transition: stroke 0.3s ease, filter 0.3s ease;
}
.steth__beat.is-past { stroke: rgba(var(--color-brand-rgb), 0.6); }
.steth__beat.is-on {
  stroke: var(--color-brand);
  stroke-width: 2.2;
  filter: drop-shadow(0 0 5px rgba(var(--color-brand-rgb), 0.9));
  animation: stethThump 0.5s var(--ease);
}
@keyframes stethThump {
  0%   { stroke: #fff; }
  100% { stroke: var(--color-brand); }
}
.steth__years {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 12px;
  margin: 0;
  padding: 0;
  list-style: none;
  font-family: var(--font-mono);
  font-size: 0.5625rem;
  color: rgba(255, 255, 255, 0.35);
}
.steth__years li {
  position: absolute;
  transform: translateX(-50%);
  transition: color 0.25s ease;
}
.steth__years li.is-on { color: var(--color-white); font-weight: 700; }

/* Campana del estetoscopio: el diafragma se apoya en la línea base */
.steth__piece {
  position: absolute;
  top: -17px;
  left: 0;
  width: 31px;
  height: 52px;
  margin-left: -15.5px;
  pointer-events: none;
  transition: left 0.32s var(--ease);
  filter: drop-shadow(0 4px 6px rgba(0, 0, 0, 0.6));
}
.steth__piece.is-follow { transition: left 0.12s linear; }
.steth__piece svg { display: block; width: 100%; height: 100%; overflow: visible; }
.steth__piece .tube { fill: none; stroke: #8d8d8d; stroke-width: 3; stroke-linecap: round; }
.steth__piece .bell { fill: #d9d9d9; stroke: #f5f5f5; stroke-width: 1.2; }
.steth__piece .disc { fill: #5c5c5c; }
.steth__piece .ring { fill: none; stroke: var(--color-brand); stroke-width: 1.4; opacity: 0; }
.steth__piece.is-listen .ring { animation: stethRing 0.6s ease-out; }
@keyframes stethRing {
  0%   { opacity: 0.9; transform: scale(0.6); }
  100% { opacity: 0; transform: scale(1.8); }
}
.steth__piece .ring { transform-box: fill-box; transform-origin: center; }

/* ---- Jeringa (clientes) ---- */
.vital--syringe { cursor: ew-resize; touch-action: pan-y; }
.syringe {
  position: absolute;
  right: 1.25rem;
  bottom: 0.85rem;
  width: 38%;
  height: 50px;
}
.syringe svg { display: block; width: 100%; height: 36px; overflow: visible; }
.syringe__barrel { fill: rgba(255, 255, 255, 0.05); stroke: rgba(255, 255, 255, 0.55); stroke-width: 1.2; }
.syringe__liquid { fill: var(--color-brand); opacity: 0.85; filter: drop-shadow(0 0 4px rgba(var(--color-brand-rgb), 0.7)); }
.syringe__ticks { stroke: rgba(255, 255, 255, 0.55); stroke-width: 1; }
.syringe__needle { fill: rgba(255, 255, 255, 0.55); stroke: rgba(255, 255, 255, 0.7); stroke-width: 1; }
.syringe__plunger rect { fill: #cfcfcf; }
.syringe__plunger path { fill: none; stroke: #cfcfcf; stroke-width: 2; stroke-linecap: round; }
.syringe__scale {
  display: flex;
  justify-content: space-between;
  padding: 0 13% 0 15%;
  font-family: var(--font-mono);
  font-size: 0.5625rem;
  color: rgba(255, 255, 255, 0.35);
}
.syringe__scale i { font-style: normal; }

/* ---- Blíster de 4 cápsulas (áreas) ---- */
.blister {
  position: absolute;
  right: 1.25rem;
  bottom: 0.7rem;
  width: 46%;
}
.blister__pack {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 5px;
  padding: 5px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 8px;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.12), rgba(255, 255, 255, 0.03));
}
.blister__cell {
  position: relative;
  display: grid;
  place-items: center;
  height: 30px;
  border-radius: 50% / 40%;
  background: radial-gradient(circle at 35% 30%, rgba(255, 255, 255, 0.18), rgba(255, 255, 255, 0.04) 70%);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.12);
  cursor: pointer;
}
.pill {
  display: block;
  width: 11px;
  height: 24px;
  border-radius: 6px;
  background: linear-gradient(var(--color-brand) 50%, #f2f2f2 50%);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.5), inset -2px 0 3px rgba(0, 0, 0, 0.18);
  opacity: 0;
  transform: translateY(-34px) rotate(-30deg);
  transition: transform 0.45s cubic-bezier(0.34, 1.56, 0.64, 1), opacity 0.25s ease;
}
.pill.is-in { opacity: 1; transform: rotate(18deg); }
.blister__cell:hover .pill.is-in,
.pill.is-in.is-out { transform: translateY(-12px) rotate(-12deg) scale(1.12); }
.blister__cap {
  display: block;
  margin-top: 4px;
  font-family: var(--font-mono);
  font-size: 0.5625rem;
  letter-spacing: 0.06em;
  text-align: center;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.5);
  transition: color 0.2s ease;
}
.blister__cap.is-on { color: var(--color-white); }

/* ---- Receta bilingüe (idiomas) ---- */
.vital--rxlang { cursor: pointer; }
.rxlang {
  position: absolute;
  right: 1.25rem;
  bottom: 0.85rem;
  width: 50%;
  height: 46px;
  perspective: 500px;
}
.rxlang__card {
  position: relative;
  width: 100%;
  height: 100%;
  transform-style: preserve-3d;
  transition: transform 0.7s var(--ease);
}
.rxlang__card.is-en { transform: rotateY(180deg); }
.rxlang__face {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0 0.6rem;
  border-radius: 6px;
  border-top: 3px solid var(--color-brand);
  background-color: #fffefb;
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.45);
  color: var(--color-ink);
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
}
.rxlang__face--en { transform: rotateY(180deg); }
.rxlang__face b { font-family: Georgia, serif; font-size: 1.15rem; color: var(--color-brand); }
.rxlang__face span { flex: 1; font-family: "Segoe Script", "Brush Script MT", cursive; font-size: 0.75rem; line-height: 1.1; color: #1f3a8a; }
.rxlang__face em {
  padding: 0.15rem 0.35rem;
  border-radius: 4px;
  background-color: var(--color-ink);
  font-family: var(--font-mono);
  font-size: 0.5625rem;
  font-style: normal;
  color: #fff;
}

/* ============ 24. CHEQUEO DEL CONSULTORIO ============
   Preguntas a la izquierda (una a la vez) y monitor a la derecha. Cabe en
   una pantalla: las alturas del monitor salen de svh. */
.checkup {
  min-height: calc(100svh - var(--header-h));
  display: flex;
  align-items: center;
  padding-block: clamp(1.5rem, 4svh, 3rem);
  background:
    radial-gradient(55% 60% at 85% 50%, rgba(var(--color-brand-rgb), 0.12), transparent 70%),
    #0a0a0a;
  color: var(--color-body);
}

.checkup__grid {
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.05fr);
  gap: clamp(1.75rem, 4vw, 3.75rem);
  align-items: center;
}

.checkup__head { max-width: none; margin: 0 0 1.25rem; text-align: left; }
.checkup .section__title { font-size: clamp(1.6rem, 2.7vw, 2.4rem); color: var(--color-white); text-transform: none; letter-spacing: -0.015em; }
.checkup .section__lead { color: rgba(255, 255, 255, 0.7); }

.quiz {
  padding: clamp(1.1rem, 2.4svh, 1.6rem) clamp(1.1rem, 2vw, 1.6rem);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 22px;
  background-color: rgba(255, 255, 255, 0.035);
}

.quiz__progress {
  display: flex;
  gap: 6px;
  margin-bottom: 1.1rem;
}
.quiz__progress span {
  flex: 1;
  height: 4px;
  border-radius: 4px;
  background-color: rgba(255, 255, 255, 0.14);
  transition: background-color 0.4s var(--ease), box-shadow 0.4s var(--ease);
}
.quiz__progress span.is-yes { background-color: var(--color-brand); box-shadow: 0 0 10px rgba(var(--color-brand-rgb), 0.6); }
.quiz__progress span.is-no  { background-color: rgba(255, 255, 255, 0.45); }
.quiz__progress span.is-current { background-color: rgba(255, 255, 255, 0.85); }

.quiz__stage {
  display: grid;
  min-height: clamp(7.5rem, 17svh, 9rem);
}

.quiz__q,
.quiz__result {
  grid-area: 1 / 1;
  min-width: 0;
  margin: 0;
  padding: 0;
  border: 0;
  opacity: 0;
  visibility: hidden;
  transform: translateX(28px);
  transition: opacity 0.45s var(--ease), transform 0.55s var(--ease), visibility 0s linear 0.55s;
}

.quiz__q.is-current,
.quiz.is-done .quiz__result {
  opacity: 1;
  visibility: visible;
  transform: none;
  transition: opacity 0.45s var(--ease) 0.1s, transform 0.55s var(--ease) 0.1s, visibility 0s;
}
.quiz__q.is-past { transform: translateX(-28px); }

.quiz__q legend {
  float: left;
  width: 100%;
  padding: 0;
  font-size: clamp(1.15rem, 1.7vw, 1.5rem);
  font-weight: 700;
  line-height: 1.3;
  color: var(--color-white);
}

.quiz__n {
  display: block;
  margin-bottom: 0.6rem;
  font-family: var(--font-mono);
  font-size: 0.6875rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--color-brand);
}

.quiz__answers {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  margin-top: 1.1rem;
}

.quiz__btn {
  flex: 1;
  max-width: 170px;
  padding: 0.85rem 1rem;
  border: 1px solid rgba(255, 255, 255, 0.25);
  border-radius: 999px;
  background: transparent;
  font: inherit;
  font-size: 0.9375rem;
  font-weight: 700;
  color: var(--color-white);
  cursor: pointer;
  transition: background-color 0.25s var(--ease), border-color 0.25s var(--ease), transform 0.25s var(--ease);
}
.quiz__btn:hover { transform: translateY(-2px); }
.quiz__btn--yes { border-color: var(--color-brand); background-color: var(--color-brand); box-shadow: var(--shadow-glow); }
.quiz__btn--yes:hover { background-color: var(--color-brand-dark); }
.quiz__btn--no:hover { border-color: var(--color-white); background-color: rgba(255, 255, 255, 0.08); }

.quiz__back {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  margin-left: auto;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 50%;
  background: transparent;
  color: var(--color-white);
  cursor: pointer;
}
.quiz__back svg { width: 18px; height: 18px; }
.quiz__back:disabled { opacity: 0.25; cursor: default; }

.quiz.is-done .quiz__answers { display: none; }

.quiz__verdict {
  margin-bottom: 0.7rem;
  font-size: clamp(1rem, 1.35vw, 1.15rem);
  font-weight: 700;
  line-height: 1.35;
  color: var(--color-white);
}

.quiz__rx-title {
  margin-bottom: 0.45rem;
  font-family: var(--font-mono);
  font-size: 0.6875rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--color-brand);
}
.quiz__rx-title span { font-size: 1rem; }

.quiz__rx {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin: 0 0 1rem;
  padding: 0;
  list-style: none;
}
.quiz__rx li {
  padding: 0.35rem 0.75rem;
  border: 1px solid rgba(var(--color-brand-rgb), 0.55);
  border-radius: 999px;
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--color-white);
  background-color: rgba(var(--color-brand-rgb), 0.1);
}

.quiz__actions { display: flex; flex-wrap: wrap; align-items: center; gap: 0.9rem 1.2rem; }
.quiz__send { padding: 0.85rem 1.4rem; }
.quiz__restart {
  padding: 0;
  border: 0;
  background: none;
  font: inherit;
  font-size: 0.8125rem;
  color: rgba(255, 255, 255, 0.65);
  text-decoration: underline;
  text-underline-offset: 3px;
  cursor: pointer;
}
.quiz__restart:hover { color: var(--color-white); }

/* Monitor */
.monitor {
  padding: 1rem 1.15rem 1.15rem;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 24px;
  background: linear-gradient(180deg, #121212, #070707);
  box-shadow: 0 40px 80px rgba(0, 0, 0, 0.5), inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

.monitor__top {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 0.75rem;
  font-family: var(--font-mono);
  font-size: 0.6875rem;
  letter-spacing: 0.12em;
  color: rgba(255, 255, 255, 0.5);
}
.monitor__rec { display: inline-flex; align-items: center; gap: 0.45rem; color: var(--color-brand); }
.monitor__rec i { width: 7px; height: 7px; border-radius: 50%; background-color: currentColor; animation: recBlink 1.2s steps(2, jump-none) infinite; }
@keyframes recBlink { 50% { opacity: 0.2; } }

.monitor__wave {
  position: relative;
  height: clamp(130px, 26svh, 250px);
  overflow: hidden;
  border-radius: 14px;
  background-color: #050505;
  background-image:
    linear-gradient(rgba(var(--color-brand-rgb), 0.07) 1px, transparent 1px),
    linear-gradient(90deg, rgba(var(--color-brand-rgb), 0.07) 1px, transparent 1px);
  background-size: 22px 22px;
}
.monitor__wave canvas { position: absolute; inset: 0; width: 100%; height: 100%; }

.monitor__label {
  position: absolute;
  top: 0.7rem;
  left: 0.85rem;
  font-family: var(--font-mono);
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  color: var(--color-white);
  text-shadow: 0 0 10px rgba(0, 0, 0, 0.8);
}

.monitor__read {
  display: grid;
  grid-template-columns: minmax(0, 0.75fr) minmax(0, 1.25fr);
  gap: 1.25rem;
  align-items: center;
  margin-top: 1rem;
}

.monitor__caption {
  display: block;
  font-family: var(--font-mono);
  font-size: 0.6875rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.5);
}
.monitor__big b {
  font-family: var(--font-accent);
  font-size: clamp(2.6rem, 4.6vw, 3.8rem);
  font-weight: 400;
  line-height: 1;
  color: var(--color-white);
  font-variant-numeric: tabular-nums;
}
.monitor__big small { font-size: 0.5em; color: var(--color-brand); }

.monitor__bars {
  display: grid;
  gap: 0.55rem;
  margin: 0;
  padding: 0;
  list-style: none;
}
.monitor__bars li {
  display: grid;
  grid-template-columns: 6.8rem minmax(0, 1fr);
  align-items: center;
  gap: 0.6rem;
  font-family: var(--font-mono);
  font-size: 0.6875rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.62);
}
.monitor__bars i {
  display: block;
  height: 6px;
  overflow: hidden;
  border-radius: 6px;
  background-color: rgba(255, 255, 255, 0.1);
}
.monitor__bars em {
  display: block;
  width: 100%;
  height: 100%;
  border-radius: inherit;
  background-color: var(--color-brand);
  box-shadow: 0 0 10px rgba(var(--color-brand-rgb), 0.7);
  transform: scaleX(var(--v, 0));
  transform-origin: left;
  transition: transform 0.9s var(--ease);
}

/* ============ 25. SERVICIOS — RECETAS + PANTALLA ============
   La pantalla es un contenedor (container-type: size): todo lo de adentro
   se mide en cqh/em para escalar con su alto, igual en escritorio y en
   teléfono. */
.rx {
  min-height: calc(100svh - var(--header-h));
  display: flex;
  align-items: center;
  padding-block: clamp(1.5rem, 4svh, 3rem);
}

.rx__grid {
  display: grid;
  grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr);
  gap: clamp(1.75rem, 4vw, 3.5rem);
  align-items: center;
}

.rx__head { max-width: none; margin: 0 0 1.25rem; text-align: left; }
.rx .section__title { font-size: clamp(1.4rem, 2.2vw, 1.95rem); }

.rx__list {
  display: grid;
  gap: 0.55rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.rx__item {
  position: relative;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  column-gap: 1rem;
  width: 100%;
  padding: 0.95rem 1.15rem;
  overflow: hidden;
  border: 1px solid var(--color-line);
  border-radius: 16px;
  background-color: rgba(255, 255, 255, 0.6);
  font: inherit;
  text-align: left;
  color: var(--color-ink);
  cursor: pointer;
  transition: border-color 0.35s var(--ease), background-color 0.35s var(--ease), box-shadow 0.35s var(--ease), transform 0.35s var(--ease);
}
.rx__item:hover { border-color: rgba(var(--color-brand-rgb), 0.4); transform: translateX(4px); }
.rx__item.is-active {
  border-color: rgba(var(--color-brand-rgb), 0.55);
  background-color: var(--color-white);
  box-shadow: 0 18px 40px -20px rgba(4, 4, 4, 0.35);
  transform: none;
}

.rx__num {
  grid-row: 1 / span 3;
  padding-top: 0.2rem;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--color-brand);
}
.rx__name { font-size: 1.0625rem; font-weight: 800; line-height: 1.3; }

.rx__text,
.rx__tags {
  display: block;
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  transition: max-height 0.5s var(--ease), opacity 0.4s var(--ease), margin 0.4s var(--ease);
}
.rx__text { font-size: 0.9rem; line-height: 1.5; color: var(--color-text-soft); }
.rx__item.is-active .rx__text { max-height: 6rem; margin-top: 0.35rem; opacity: 1; }
.rx__item.is-active .rx__tags { display: flex; flex-wrap: wrap; gap: 0.3rem; max-height: 4rem; margin-top: 0.6rem; opacity: 1; }
.rx__tags i {
  padding: 0.2rem 0.6rem;
  border-radius: 999px;
  background-color: var(--color-brand-soft);
  font-style: normal;
  font-size: 0.6875rem;
  font-weight: 600;
  color: var(--color-brand-dark);
}

/* Barra de tiempo del avance automático */
.rx__timer {
  position: absolute;
  left: 0;
  bottom: 0;
  height: 3px;
  width: 100%;
  background-color: var(--color-brand);
  transform: scaleX(0);
  transform-origin: left;
}
.rx__item.is-active.is-running .rx__timer { animation: rxTimer var(--rx-ms, 6000ms) linear forwards; }
@keyframes rxTimer { to { transform: scaleX(1); } }

.rx__caption { display: none; }

.rx__screen {
  position: relative;
  container-type: size;
  height: clamp(380px, calc(100svh - var(--header-h) - 6rem), 640px);
  overflow: hidden;
  border-radius: 28px;
  background-color: var(--color-ink);
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.04) 1px, transparent 1px);
  background-size: 34px 34px;
  box-shadow: 0 40px 80px -30px rgba(4, 4, 4, 0.6);
  font-size: clamp(9px, 2.3cqh, 15px);
}

/* Barrido solo con transform (lo mueve la GPU, sin repintar): cada vista
   es una ventana con overflow:hidden que se desplaza mientras su
   contenido (.rx-view__in, lo crea main.js §23) se desplaza al revés, así
   el contenido queda quieto y solo cambia qué parte se ve. La nueva entra
   por la izquierda y la vieja sale por la derecha, sin encimarse. */
.rx-view {
  position: absolute;
  inset: 0;
  overflow: hidden;
  visibility: hidden;
}
.rx-view__in { position: absolute; inset: 0; }
.rx-view.is-on,
.rx-view.is-old { visibility: visible; }
.rx-view.is-old { z-index: 1; }
.rx-view.is-on { z-index: 2; }
.rx-view.is-on.is-enter,
.rx-view.is-old,
.rx-view.is-on.is-enter > .rx-view__in,
.rx-view.is-old > .rx-view__in { will-change: transform; }
.rx-view.is-on.is-enter { animation: rxInWin 0.95s var(--ease) both; }
.rx-view.is-on.is-enter > .rx-view__in { animation: rxInBody 0.95s var(--ease) both; }
.rx-view.is-old { animation: rxOutWin 0.95s var(--ease) both; }
.rx-view.is-old > .rx-view__in { animation: rxOutBody 0.95s var(--ease) both; }
@keyframes rxInWin   { from { transform: translateX(-100cqw); } to { transform: none; } }
@keyframes rxInBody  { from { transform: translateX(100cqw); }  to { transform: none; } }
@keyframes rxOutWin  { from { transform: none; } to { transform: translateX(100cqw); } }
@keyframes rxOutBody { from { transform: none; } to { transform: translateX(-100cqw); } }

/* Línea que barre la pantalla al cambiar */
.rx__sweep {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  z-index: 5;
  width: 3px;
  background-color: var(--color-brand);
  box-shadow: 0 0 24px 6px rgba(var(--color-brand-rgb), 0.55);
  opacity: 0;
  pointer-events: none;
}
.rx__screen.is-sweeping .rx__sweep { will-change: transform; animation: rxSweep 0.95s var(--ease) both; }
@keyframes rxSweep {
  0%   { transform: translateX(0); opacity: 1; }
  90%  { opacity: 1; }
  100% { transform: translateX(100cqw); opacity: 0; }
}

.rx__note {
  position: absolute;
  left: 50%;
  bottom: 0.8em;
  z-index: 6;
  margin: 0;
  padding: 0.35em 0.9em;
  border-radius: 999px;
  background-color: rgba(4, 4, 4, 0.6);
  backdrop-filter: blur(6px);
  font-family: var(--font-mono);
  font-size: 0.72em;
  letter-spacing: 0.06em;
  white-space: nowrap;
  color: rgba(255, 255, 255, 0.7);
  transform: translateX(-50%);
}

/* --- Piezas comunes de las vistas --- */
.mk-ig__avatar {
  flex-shrink: 0;
  display: grid;
  place-items: center;
  width: 3.2em;
  height: 3.2em;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--color-brand), #7a0000);
  box-shadow: 0 0 0 2px #fff, 0 0 0 4px #d62976;
  font-size: 0.75em;
  font-weight: 800;
  color: var(--color-white);
}


/* --- 01 Redes --- */
.rx-view--redes > .rx-view__in { background: radial-gradient(60% 70% at 30% 50%, rgba(214, 41, 118, 0.18), transparent 70%); }

/* Celular realista: marco metálico delgado, esquinas proporcionales (no
   cápsula), bisel negro, botones laterales, isla dinámica, barra de
   estado, barras de Instagram e indicador de inicio. */
.mk-phone {
  position: absolute;
  left: 9%;
  top: 6%;
  height: 86%;
  aspect-ratio: 9 / 19.5;
  min-width: 0;          /* que el contenido no lo ensanche: siempre forma de celular */
  padding: 0.28em;
  border-radius: 14% / 6.6%;
  background: linear-gradient(135deg, #5b5b60 0%, #c9c9ce 18%, #3a3a3e 40%, #8e8e93 62%, #2c2c2e 82%, #a5a5aa 100%);
  box-shadow:
    0 30px 60px rgba(0, 0, 0, 0.55),
    inset 0 0 0 1px rgba(255, 255, 255, 0.18);
}
.mk-phone__btn {
  position: absolute;
  width: 0.22em;
  border-radius: 0.2em;
  background: linear-gradient(90deg, #2a2a2d, #8e8e93);
}
.mk-phone__btn--a { left: -0.16em; top: 17%; height: 4%; }
.mk-phone__btn--b { left: -0.16em; top: 24%; height: 8%; }
.mk-phone__btn--c { right: -0.16em; top: 22%; height: 11%; background: linear-gradient(90deg, #8e8e93, #2a2a2d); }
.mk-phone__screen {
  position: relative;
  display: flex;
  flex-direction: column;
  height: 100%;
  overflow: hidden;
  border: 0.3em solid #050505;
  border-radius: 12.5% / 5.9%;
  background-color: var(--color-white);
}
.mk-phone__notch {
  position: absolute;
  z-index: 2;
  top: 0.38em;
  left: 50%;
  width: 32%;
  height: 1.05em;
  border-radius: 1em;
  background-color: #050505;
  transform: translateX(-50%);
}
.mk-phone__status {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 1.85em;
  padding: 0.25em 1.25em 0;
  font-size: 0.5em;
  color: var(--color-ink);
}
.mk-phone__status b { font-size: 1.15em; }
.mk-phone__status span { display: flex; align-items: center; gap: 0.35em; }
.mk-phone__status svg { height: 0.95em; width: auto; fill: currentColor; color: var(--color-ink); }
.mk-phone__app {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.25em 0.6em 0.4em;
  font-size: 0.62em;
  color: var(--color-ink);
}
.mk-phone__app svg { width: 1.2em; height: 1.2em; }
.mk-phone .mk-ig { flex: 1; min-height: 0; min-width: 0; overflow: hidden; padding: 0 0.55em; font-size: 0.86em; }
.mk-phone .mk-ig__head { gap: 0.5em; }
.mk-phone .mk-ig__avatar { flex-shrink: 0; }
.mk-phone .mk-ig__stats { min-width: 0; overflow: hidden; }
.mk-phone__nav {
  display: flex;
  align-items: center;
  justify-content: space-around;
  padding: 0.4em 0.5em 0.15em;
  border-top: 1px solid #ececec;
  background-color: var(--color-white);
  font-size: 0.68em;
  color: var(--color-ink);
}
.mk-phone__nav svg { width: 1.15em; height: 1.15em; }
.mk-phone__me {
  display: grid;
  place-items: center;
  width: 1.3em;
  height: 1.3em;
  border-radius: 50%;
  background: linear-gradient(45deg, #f9ce34, #ee2a7b, #6228d7);
  font-size: 0.62em;
  font-weight: 800;
  color: #fff;
}
.mk-phone .mk-ig__stats b { white-space: nowrap; }
/* Recuadro bajito (celular): menos barras para que se vean las publicaciones */
@container (max-height: 380px) {
  .mk-phone__app,
  .mk-phone .mk-ig__bio { display: none; }
  .mk-phone .mk-ig__head { margin-bottom: 0.35em; }
  .mk-phone .mk-ig__btn { margin-bottom: 0.45em; padding: 0.3em 0; }
  /* cifras sin las palabras largas, que no caben: "128 posts / 3.4 mil seg." */
  .mk-phone .mk-ig__stats { display: grid; grid-template-columns: 1fr; font-size: 0; }
  .mk-phone .mk-ig__stats b { font-size: 0.6rem; line-height: 1.35; }
  .mk-phone .mk-ig__stats b:first-of-type::after { content: " posts"; font-weight: 500; color: #666; }
  .mk-phone .mk-ig__stats b:last-of-type::after { content: " seg."; font-weight: 500; color: #666; }
}
.mk-phone__home {
  display: block;
  flex-shrink: 0;
  width: 36%;
  height: 0.2em;
  margin: 0.3em auto 0.32em;
  border-radius: 1em;
  background-color: #111;
}

.mk-ig__head { display: flex; align-items: center; gap: 0.8em; margin-bottom: 0.6em; }
.mk-ig__stats { display: grid; grid-template-columns: auto auto; column-gap: 0.4em; font-size: 0.62em; color: #555; }
.mk-ig__stats b { color: var(--color-ink); font-size: 1.15em; }
.mk-ig__name { margin: 0; font-size: 0.72em; font-weight: 800; color: var(--color-ink); }
.mk-ig__bio { margin: 0.1em 0 0.5em; font-size: 0.62em; color: #666; }
.mk-ig__btn {
  display: block;
  margin-bottom: 0.7em;
  padding: 0.45em 0;
  border-radius: 0.6em;
  background-color: #1a73e8;
  font-size: 0.62em;
  font-weight: 700;
  text-align: center;
  color: #fff;
}
.mk-ig__grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2px; }
.mk-ig__grid img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; }
/* Redes: tres columnas alineadas al centro (perfil · reel · publicación),
   misma altura y separación pareja, sin encimarse ni girarse. En
   pantallas angostas la publicación se oculta y quedan perfil + reel. */
.rx-view--redes > .rx-view__in {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4cqw;
  padding: 0 4cqw 4%;
}
.rx-view--redes .mk-phone { position: relative; left: auto; top: auto; flex-shrink: 0; height: 84%; width: auto; }
@container (max-aspect-ratio: 3 / 2) {
  .rx-view--redes .mk-igposts { display: none; }
}

.mk-reel {
  position: relative;
  flex-shrink: 0;
  height: 80%;
  aspect-ratio: 9 / 16;
  overflow: hidden;
  border-radius: 1.2em;
  background-color: #000;
  box-shadow: 0 30px 60px rgba(0, 0, 0, 0.6), 0 0 0 1px rgba(255, 255, 255, 0.08);
  color: #fff;
}
.mk-reel video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity 0.4s ease;
}
.mk-reel video.is-on { opacity: 1; }
.mk-reel::after {
  content: "";
  position: absolute;
  inset: 55% 0 0;
  background: linear-gradient(transparent, rgba(0, 0, 0, 0.7));
  pointer-events: none;
}
.mk-reel__tag {
  position: absolute;
  top: 0.8em;
  left: 0.8em;
  z-index: 1;
  display: inline-flex;
  align-items: center;
  gap: 0.3em;
  font-size: 0.7em;
  font-weight: 800;
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.6);
}
.mk-reel__tag svg { width: 1.3em; height: 1.3em; }
.mk-reel__side {
  position: absolute;
  right: 0.55em;
  bottom: 2.6em;
  z-index: 1;
  display: grid;
  gap: 0.7em;
  justify-items: center;
  font-size: 0.9em;
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.6);
}
.mk-reel__side i { display: grid; justify-items: center; font-style: normal; line-height: 1; }
.mk-reel__side small { margin-top: 0.2em; font-size: 0.55em; font-weight: 700; }
.mk-reel__foot {
  position: absolute;
  left: 0.8em;
  right: 2.8em;
  bottom: 1.1em;
  z-index: 1;
  display: grid;
  font-size: 0.62em;
  line-height: 1.3;
}
.mk-reel__foot small { opacity: 0.85; }
.mk-reel__bar {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 1;
  height: 3px;
  background-color: rgba(255, 255, 255, 0.25);
}
.mk-reel__bar i {
  display: block;
  height: 100%;
  background-color: #fff;
  transform: scaleX(0);
  transform-origin: left;
}

.mk-igposts { flex-shrink: 0; width: min(28cqw, 42cqh); }
.mk-igpost {
  position: relative;
  margin: 0;
  overflow: hidden;
  border-radius: 0.8em;
  background-color: var(--color-white);
  box-shadow: 0 24px 50px rgba(0, 0, 0, 0.55);
  color: var(--color-ink);
}
.mk-igpost__comment { margin: 0; padding: 0 0.7em 0.7em; font-size: 0.55em; line-height: 1.35; color: #333; }
.mk-igpost__comment b { margin-right: 0.3em; color: var(--color-ink); }
.mk-igpost__head { display: flex; align-items: center; gap: 0.45em; padding: 0.5em 0.6em; font-size: 0.6em; }
.mk-igpost__av {
  display: grid;
  place-items: center;
  width: 2.2em;
  height: 2.2em;
  border-radius: 50%;
  background: linear-gradient(45deg, #f9ce34, #ee2a7b, #6228d7);
  font-size: 0.8em;
  font-weight: 800;
  color: #fff;
}
.mk-igpost img { display: block; width: 100%; aspect-ratio: 4 / 5; object-fit: cover; }
.mk-igpost__acts { display: flex; gap: 0.6em; margin: 0; padding: 0.45em 0.6em 0.15em; font-size: 0.7em; }
.mk-igpost__acts span { margin-left: auto; }
.mk-igpost__likes { margin: 0; padding: 0 0.6em 0.6em; font-size: 0.55em; font-weight: 700; }
@keyframes mkFloat { 50% { transform: translateY(-0.5em); } }

/* --- 02 Imagen: cada marca toma el panel ---
   Tres franjas con el color de su manual. La abierta gira su logo y deja
   caer sus piezas encimadas; las otras se quedan con el logo en vertical.
   Todo se mide con la pantalla (cqw/cqh) para servir igual en celular. */
.brands {
  --strip: 13cqw;
  --gap: 0.45em;
  position: absolute;
  inset: 3.5cqh 3.5cqw 11cqh;
  display: flex;
  gap: var(--gap);
}
.brand {
  position: relative;
  flex: 0 0 var(--strip);
  min-width: 0;
  overflow: hidden;
  border-radius: 1em;
  background-color: var(--brand);
  transition: flex-basis 0.75s var(--ease);
}
.brand.is-open { flex-basis: calc(93cqw - 2 * var(--strip) - 2 * var(--gap)); }
.brand--claren { --logo-closed: 23cqh; --logo-open: 25cqw; --brand: #113355; background-image: radial-gradient(90% 60% at 100% 100%, #78baec 0 58%, transparent 58.4%); }
.brand--sinacne { --brand: #00a9c6; background-image: repeating-radial-gradient(circle at 100% 100%, rgba(255, 255, 255, 0.13) 0 7%, transparent 7% 14%); }
.brand--rosa { --brand: #e0617a; background-image: radial-gradient(90% 55% at 0 100%, #4c4d4a 0 58%, transparent 58.4%); }

.brand__tab {
  position: absolute;
  inset: 0;
  z-index: 3;
  width: 100%;
  padding: 0;
  border: 0;
  border-radius: inherit;
  background: none;
  cursor: pointer;
}
.brand__tab:focus-visible { outline: 2px solid #fff; outline-offset: -4px; }
.brand.is-open .brand__tab { cursor: default; pointer-events: none; }
.brand__logo {
  position: absolute;
  top: 50%;
  left: 50%;
  width: var(--logo-closed, 31cqh);
  max-width: none;
  height: auto;
  transform: translate(-50%, -50%) rotate(-90deg);
  transition: top 0.75s var(--ease), left 0.75s var(--ease), width 0.75s var(--ease), transform 0.75s var(--ease);
}
.brand.is-open .brand__logo {
  top: 2.6cqh;
  left: 3cqw;
  width: var(--logo-open, 31cqw);
  transform: none;
}
/* El logo de la Dra. Rosa es cuadrado: se queda derecho */
.brand--rosa { --logo-closed: 10cqw; --logo-open: 13.5cqh; }
.brand--rosa .brand__logo { transform: translate(-50%, -50%); }

.brand__stage {
  position: absolute;
  width: calc(93cqw - 2 * var(--strip) - 2 * var(--gap));
  opacity: 0;
  transition: opacity 0.3s ease;
}
.brand.is-open .brand__stage { opacity: 1; transition-delay: 0.25s; }
.brand__stage { top: 17cqh; bottom: 0; left: 0; }

.brand__piece {
  position: absolute;
  display: block;
  object-fit: cover;
  border-radius: 0.5em;
  box-shadow: 0 1.1em 2em rgba(0, 0, 0, 0.42), 0 0.15em 0.4em rgba(0, 0, 0, 0.3);
  opacity: 0;
  transform: translateY(2.4em) rotate(calc(var(--r) * 3)) scale(0.9);
  transition: opacity 0.2s ease, transform 0.2s ease;
}
.brand.is-open .brand__piece {
  opacity: 1;
  transform: rotate(var(--r));
  transition: opacity 0.5s ease var(--d), transform 0.85s cubic-bezier(0.2, 1.25, 0.35, 1) var(--d);
}
.brand__piece--a { --r: -2deg; --d: 0.3s; left: 4%; top: 0; width: 66%; height: 50%; z-index: 1; }
.brand__piece--b { --r: 3deg; --d: 0.45s; left: 60%; top: 8%; width: 36%; height: 46%; z-index: 2; }
.brand__piece--c { --r: 2.5deg; --d: 0.6s; left: 5%; top: 51%; width: 44%; height: 42%; z-index: 3; }
.brand__piece--d { --r: -2deg; --d: 0.75s; left: 46%; top: 57%; width: 50%; height: 38%; z-index: 4; }
/* Marcas con tres piezas: la principal manda y las otras dos la pisan abajo */
.brand--sinacne .brand__piece--a,
.brand--rosa .brand__piece--a { left: 4%; width: 92%; height: 58%; }
.brand--sinacne .brand__piece--b,
.brand--rosa .brand__piece--b { left: 5%; top: 50%; width: 47%; height: 44%; --r: -3deg; }
.brand--sinacne .brand__piece--c,
.brand--rosa .brand__piece--c { left: 50%; top: 53%; width: 45%; height: 42%; --r: 2.5deg; }
.brand--sinacne .brand__piece--a { object-position: 50% 0; }
.brand--claren .brand__piece--c { object-position: 25% 50%; }

/* --- 03 Web + Google --- */
.rx-view--web > .rx-view__in { background: radial-gradient(60% 70% at 40% 40%, rgba(26, 115, 232, 0.2), transparent 70%); }

.mk-browser {
  position: absolute;
  left: 6%;
  top: 8%;
  width: 74%;
  height: 68%;
  overflow: hidden;
  border-radius: 1em;
  background-color: #fff;
  box-shadow: 0 30px 60px rgba(0, 0, 0, 0.55);
}
.mk-browser__bar {
  display: flex;
  align-items: center;
  gap: 0.4em;
  height: 2.1em;
  padding-inline: 0.8em;
  background-color: #ececec;
}
.mk-browser__bar i { width: 0.6em; height: 0.6em; border-radius: 50%; background-color: #c9c9c9; }
.mk-browser__bar i:first-child { background-color: var(--color-brand); }
.mk-browser__bar span {
  margin: 0 auto;
  padding: 0.2em 1.4em;
  border-radius: 1em;
  background-color: #fff;
  font-size: 0.62em;
  color: #666;
}

.mk-site { position: relative; height: calc(100% - 2.1em); }
.mk-site img { width: 100%; height: 100%; object-fit: cover; object-position: 60% 30%; }
.mk-site::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(4, 4, 4, 0.85) 0%, rgba(4, 4, 4, 0.35) 60%, transparent);
}
.mk-site--shot img { object-position: 0 0; }
.mk-site--shot::after { content: none; }

.mk-gmb {
  position: absolute;
  right: 5%;
  bottom: 8%;
  width: 40%;
  overflow: hidden;
  border-radius: 1em;
  background-color: #fff;
  box-shadow: 0 30px 60px rgba(0, 0, 0, 0.55);
}

/* Mapa estilo Google (SVG en index.html; animación en main.js §23.1) */
.mk-gmb__map { position: relative; aspect-ratio: 360 / 160; overflow: hidden; background-color: #efece6; }
.mk-gmb__map svg { display: block; width: 100%; height: 100%; }
.mk-gmap__labels text { font-family: Roboto, Arial, sans-serif; font-size: 7px; font-weight: 500; fill: #6b6b6b; paint-order: stroke; stroke: rgba(255, 255, 255, 0.85); stroke-width: 2px; }
.mk-gmap__labels .is-park { fill: #3f8a3f; font-size: 6.5px; }
.mk-gmap__route-edge,
.mk-gmap__route {
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-dasharray: 1;
  stroke-dashoffset: var(--route, 0);
}
.mk-gmap__route-edge { stroke: #1967d2; stroke-width: 8; }
.mk-gmap__route { stroke: #4285f4; stroke-width: 5.5; }
.mk-gmap__car { transition: opacity 0.3s ease; }
.mk-gmap__pin-body { transform-box: fill-box; transform-origin: 50% 100%; }
.mk-gmb__map.is-drop .mk-gmap__pin-body { animation: gmapDrop 0.6s cubic-bezier(0.3, 0, 0.4, 1) both; }
.mk-gmb__map.is-arrived .mk-gmap__pin-body { animation: gmapBounce 0.6s cubic-bezier(0.3, 0, 0.4, 1); }
@keyframes gmapDrop {
  0%   { transform: translateY(-40px); opacity: 0; }
  60%  { transform: translateY(0); opacity: 1; }
  75%  { transform: translateY(-5px) scaleY(1.05); }
  100% { transform: none; }
}
@keyframes gmapBounce {
  0%, 100% { transform: none; }
  40% { transform: translateY(-7px) scale(1.12); }
  70% { transform: translateY(0) scaleY(0.9); }
}

/* Chip de tiempo estimado (y "Has llegado") */
.mk-gmap__eta {
  position: absolute;
  left: 0.5em;
  top: 0.5em;
  display: inline-flex;
  align-items: baseline;
  gap: 0.35em;
  padding: 0.3em 0.65em;
  border-radius: 2em;
  background-color: #fff;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.22);
  font-family: Roboto, Arial, sans-serif;
  font-size: 0.62em;
  color: #3c4043;
  opacity: 0;
  transform: translateY(-0.4em);
  transition: opacity 0.3s ease, transform 0.3s ease, background-color 0.3s ease, color 0.3s ease;
}
.mk-gmap__eta b { color: #188038; }
.mk-gmb__map.is-routing .mk-gmap__eta { opacity: 1; transform: none; }
.mk-gmb__map.is-arrived .mk-gmap__eta { background-color: #188038; color: #fff; }
.mk-gmb__map.is-arrived .mk-gmap__eta b { color: #fff; }

.mk-gmb__toast {
  position: absolute;
  bottom: 0.5em;
  right: 0.5em;
  padding: 0.3em 0.65em;
  border-radius: 2em;
  background-color: #fff;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.22);
  font-size: 0.62em;
  font-weight: 700;
  color: #333;
  white-space: nowrap;
  opacity: 0;
  transform: translateY(0.5em);
  transition: opacity 0.35s ease, transform 0.35s var(--ease);
}
.mk-gmb__map.is-review .mk-gmb__toast { opacity: 1; transform: none; }
@container (max-aspect-ratio: 3 / 2) {
  .mk-gmb__map { aspect-ratio: 360 / 190; }
  .mk-gmap__eta,
  .mk-gmb__toast { font-size: 0.5em; }
  .mk-gmap__eta { left: 0.35em; top: 0.35em; }
  .mk-gmb__toast { right: 0.35em; bottom: 0.35em; }
}

.mk-gmb__body { padding: 0.8em 1em 1em; font-size: 0.8em; color: #333; }
.mk-gmb__body > b { display: block; font-size: 1.1em; color: var(--color-ink); }
.mk-gmb__rate { margin: 0.2em 0; color: #fbbc04; }
.mk-gmb__rate span { font-weight: 700; color: #333; }
.mk-gmb__rate small { color: #777; }
.mk-gmb__meta { margin: 0 0 0.6em; font-size: 0.85em; color: #666; }
.mk-gmb__meta em { font-style: normal; font-weight: 600; color: #188038; }
.mk-gmb__btns { display: flex; flex-wrap: wrap; gap: 0.35em; }
.mk-gmb__btns span { padding: 0.35em 0.8em; border: 1px solid #dadce0; border-radius: 2em; font-size: 0.82em; font-weight: 600; color: #1a73e8; transition: background-color 0.25s ease, color 0.25s ease, transform 0.15s ease; }
.mk-gmb__btns .mk-gmb__go.is-press { border-color: #1a73e8; background-color: #1a73e8; color: #fff; transform: scale(0.94); }
.mk-gmb__btns .mk-gmb__go.is-on { border-color: #1a73e8; background-color: #1a73e8; color: #fff; }

.mk-gmb__count { display: inline-block; height: 1.25em; overflow: hidden; vertical-align: bottom; }
.mk-gmb__count i { display: block; height: 1.25em; font-style: normal; line-height: 1.25em; transition: transform 0.45s var(--ease); }
.mk-gmb__count.is-new i { transform: translateY(-100%); }
/* --- 04 Publicidad --- */
.rx-view--ads > .rx-view__in { background: radial-gradient(60% 70% at 70% 40%, rgba(var(--color-brand-rgb), 0.18), transparent 70%); }

.mk-ad {
  position: absolute;
  left: 8%;
  top: 6%;
  display: flex;
  flex-direction: column;
  height: 86%;
  aspect-ratio: 0.66;
  overflow: hidden;
  border-radius: 1em;
  background-color: #fff;
  box-shadow: 0 30px 60px rgba(0, 0, 0, 0.55);
}
.mk-ad__head { display: flex; align-items: center; gap: 0.7em; padding: 0.7em 0.9em; font-size: 0.7em; color: #777; }
.mk-ad__head b { display: block; font-size: 1.15em; color: var(--color-ink); }
.mk-ad__head .mk-ig__avatar { box-shadow: none; font-size: 0.85em; }
.mk-ad img { flex: 1; min-height: 0; width: 100%; object-fit: cover; }
.mk-ad__cta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.6em;
  padding: 0.7em 0.9em;
  background-color: #f2f2f2;
  font-size: 0.7em;
  color: #333;
}
.mk-ad__cta b { padding: 0.45em 0.9em; border-radius: 0.5em; background-color: #e4e6eb; color: var(--color-ink); }

.mk-chart {
  position: absolute;
  right: 6%;
  top: 14%;
  width: 42%;
  padding: 1.2em 1.3em;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 1.2em;
  background-color: rgba(255, 255, 255, 0.06);
  backdrop-filter: blur(8px);
  color: #fff;
}
.mk-chart__title { margin: 0; font-size: 1.05em; font-weight: 800; }
.mk-chart__sub { margin: 0.1em 0 1em; font-family: var(--font-mono); font-size: 0.62em; letter-spacing: 0.08em; text-transform: uppercase; color: rgba(255, 255, 255, 0.5); }
.mk-chart__bars {
  display: flex;
  align-items: flex-end;
  gap: 0.5em;
  height: 9em;
  padding-bottom: 0.4em;
  border-bottom: 1px solid rgba(255, 255, 255, 0.15);
}
.mk-chart__bars i {
  flex: 1;
  height: calc(var(--h) * 100%);
  border-radius: 0.35em 0.35em 0 0;
  background: linear-gradient(180deg, var(--color-brand), rgba(var(--color-brand-rgb), 0.35));
  transform: scaleY(0);
  transform-origin: bottom;
  transition: transform 0.8s var(--ease);
}
.rx-view--ads.is-on .mk-chart__bars i { transform: scaleY(1); }
.rx-view--ads.is-on .mk-chart__bars i:nth-child(2) { transition-delay: 0.08s; }
.rx-view--ads.is-on .mk-chart__bars i:nth-child(3) { transition-delay: 0.16s; }
.rx-view--ads.is-on .mk-chart__bars i:nth-child(4) { transition-delay: 0.24s; }
.rx-view--ads.is-on .mk-chart__bars i:nth-child(5) { transition-delay: 0.32s; }
.rx-view--ads.is-on .mk-chart__bars i:nth-child(6) { transition-delay: 0.4s; }
.rx-view--ads.is-on .mk-chart__bars i:nth-child(7) { transition-delay: 0.48s; }
.mk-chart__kpis { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0.5em; margin-top: 0.9em; font-size: 0.62em; color: rgba(255, 255, 255, 0.6); }
.mk-chart__kpis b { display: block; font-size: 1.1em; color: #fff; }

/* Pantalla casi cuadrada (celular): anuncio y gráfica lado a lado, sin
   encimarse. El anuncio se angosta y encuadra al doctor; la gráfica ocupa
   la otra mitad con sus barras más bajas. */
@container (max-aspect-ratio: 3 / 2) {
  .mk-ad { left: 4%; top: 5%; width: 50%; height: 80%; aspect-ratio: auto; border-radius: 0.8em; }
  .mk-ad__head { padding: 0.55em 0.7em; font-size: 0.62em; }
  .mk-ad__head > span:last-child { min-width: 0; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
  .mk-ad img { object-position: 62% 18%; }
  .mk-ad__cta { justify-content: center; padding: 0.55em 0.7em; font-size: 0.62em; }
  .mk-ad__cta span { display: none; }
  .mk-chart { right: 4%; top: 5%; width: 38%; height: 80%; display: flex; flex-direction: column; padding: 0.9em 0.9em; }
  .mk-chart__title { font-size: 0.85em; line-height: 1.2; }
  .mk-chart__sub { margin-bottom: 0.6em; font-size: 0.5em; }
  .mk-chart__bars { flex: 1; height: auto; min-height: 0; gap: 0.3em; }
  .mk-chart__kpis { grid-template-columns: 1fr; gap: 0.25em; margin-top: 0.6em; font-size: 0.55em; }
  .mk-chart__kpis span { display: flex; justify-content: space-between; gap: 0.4em; }
  .mk-chart__kpis b { display: inline; }
}

/* ============ 26. PROCESO — DEL DIAGNÓSTICO AL ALTA ============
   Picos R del trazo en x = 12/32/52/72/92 % y y = 18.75 % del alto (ver
   el path en index.html): ahí van los latidos. */
.care {
  min-height: calc(100svh - var(--header-h));
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding-block: clamp(1.5rem, 4svh, 3rem);
}
.care .section__head { max-width: 920px; margin-bottom: 0.5rem; }

.care__track {
  position: relative;
  height: clamp(84px, 12svh, 130px);   /* más baja para darle alto a las fotos (2026-10-19) */
}

.care__line {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  overflow: visible;
  fill: none;
  stroke-linejoin: round;
  stroke-linecap: round;
}
.care__base { stroke: var(--color-line); stroke-width: 2; }
.care__draw {
  stroke: var(--color-brand);
  stroke-width: 3;
  stroke-dasharray: 1;
  stroke-dashoffset: var(--off, 1);
  filter: drop-shadow(0 0 6px rgba(var(--color-brand-rgb), 0.5));
}

.care__steps { position: absolute; inset: 0; margin: 0; padding: 0; list-style: none; }
.care__steps li { position: absolute; top: 0; bottom: 0; width: 140px; margin-left: -70px; }
.care__steps li:nth-child(1) { left: 12%; }
.care__steps li:nth-child(2) { left: 32%; }
.care__steps li:nth-child(3) { left: 52%; }
.care__steps li:nth-child(4) { left: 72%; }
.care__steps li:nth-child(5) { left: 92%; }

.care__beat {
  position: relative;
  width: 100%;
  height: 100%;
  padding: 0;
  border: 0;
  background: none;
  font: inherit;
  cursor: pointer;
}

.care__dot {
  position: absolute;
  top: calc(18.75% - 22px);
  left: 50%;
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border: 2px solid var(--color-line);
  border-radius: 50%;
  background-color: var(--color-white);
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--color-ink);
  transform: translateX(-50%);
  transition: border-color 0.35s var(--ease), background-color 0.35s var(--ease), color 0.35s var(--ease), transform 0.35s var(--ease);
}
.care__beat.is-reached .care__dot { border-color: var(--color-brand); }
.care__beat:hover .care__dot { transform: translateX(-50%) scale(1.1); }
.care__beat.is-selected .care__dot {
  border-color: var(--color-brand);
  background-color: var(--color-brand);
  color: var(--color-white);
  box-shadow: var(--shadow-glow);
}
.care__beat.is-selected .care__dot::after {
  content: "";
  position: absolute;
  inset: -8px;
  border: 2px solid rgba(var(--color-brand-rgb), 0.5);
  border-radius: 50%;
  animation: careRing 1.6s var(--ease) infinite;
}
@keyframes careRing {
  from { transform: scale(0.8); opacity: 1; }
  to   { transform: scale(1.4); opacity: 0; }
}

.care__name {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  font-size: 0.875rem;
  font-weight: 700;
  color: var(--color-text-soft);
  transition: color 0.3s var(--ease);
}
.care__beat.is-selected .care__name { color: var(--color-ink); }

.care__chart {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
  height: clamp(230px, calc(100svh - var(--header-h) - 17rem), 520px);   /* fotos más altas (pedido 2026-10-19) */
  margin-top: 1rem;
  overflow: hidden;
  border: 1px solid var(--color-line);
  border-radius: 24px;
  background-color: var(--color-white);
  box-shadow: 0 24px 50px -30px rgba(4, 4, 4, 0.35);
}

.care__photos { position: relative; overflow: hidden; }
.care__photos img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transform: scale(1.06);
  transition: opacity 0.7s var(--ease), transform 1.4s var(--ease);
}
.care__photos img.is-on { opacity: 1; transform: none; }
.care__note {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: clamp(1.25rem, 3svh, 2rem) clamp(1.25rem, 3vw, 2.5rem);
  transition: opacity 0.25s var(--ease), transform 0.25s var(--ease);
}
.care__note.is-swapping { opacity: 0; transform: translateY(8px); }
.care__meta { margin-bottom: 0.4rem; font-family: var(--font-mono); font-size: 0.75rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--color-brand); }
.care__title { margin-bottom: 0.5rem; font-size: clamp(1.4rem, 2.2vw, 1.9rem); font-weight: 800; }
.care__text { margin: 0; font-size: 1rem; line-height: 1.6; }

/* ============ 27. PORTAFOLIO — CARRUSEL 3D ============
   main.js §25 escribe --cw/--ch (tamaño de pieza), --r (radio) y --a
   (giro). Cada pieza recibe --f (0 de espaldas … 1 de frente). */
.ring-sec {
  min-height: calc(100svh - var(--header-h));
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding-block: clamp(1rem, 3svh, 2.25rem);   /* menos aire: el carrusel es más grande (2026-10-19) */
  overflow: hidden;
}
.ring-sec .section__head { max-width: 980px; margin-bottom: 0.5rem; }
.ring-sec .section__title,
.care .section__title { font-size: clamp(1.5rem, 2.5vw, 2.2rem); }

.ring-filters { display: flex; flex-wrap: wrap; justify-content: center; gap: 0.4rem; }
.ring-filter {
  padding: 0.45rem 1rem;
  border: 1px solid var(--color-line);
  border-radius: 999px;
  background-color: var(--color-white);
  font: inherit;
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--color-text-soft);
  cursor: pointer;
  transition: background-color 0.25s var(--ease), border-color 0.25s var(--ease), color 0.25s var(--ease);
}
.ring-filter:hover { border-color: var(--color-brand); color: var(--color-ink); }
.ring-filter.is-active { border-color: var(--color-brand); background-color: var(--color-brand); color: var(--color-white); }

.ring {
  --cw: 220px;
  --ch: 275px;
  --r: 420px;
  position: relative;
  height: clamp(260px, calc(100svh - var(--header-h) - 14rem), 580px);   /* ligeramente más grande (2026-10-19); sigue cabiendo en una pantalla */
  margin-top: 0.5rem;
  perspective: 1500px;
  perspective-origin: 50% 40%;
  touch-action: pan-y;
  cursor: grab;
  user-select: none;
  -webkit-user-select: none;
}
.ring:focus-visible { outline: 2px solid var(--color-brand); outline-offset: 6px; border-radius: 12px; }
.ring.is-dragging { cursor: grabbing; }

.ring__spin {
  position: absolute;
  left: 50%;
  top: 46%;
  transform-style: preserve-3d;
  transform: translateZ(calc(var(--r) * -1));
}

.ring__card {
  --f: 1;
  position: absolute;
  left: calc(var(--cw) / -2);
  top: calc(var(--ch) / -2);
  width: var(--cw);
  height: var(--ch);
  margin: 0;
  overflow: hidden;
  border-radius: 14px;
  background-color: #1a1a1a;   /* mientras carga la pieza (fondo negro desde 2026-10-22) */
  box-shadow: 0 24px 40px -18px rgba(4, 4, 4, 0.55);
  --ang: 0deg;   /* main.js §25: ángulo según la distancia a la pieza del frente */
  transform: rotateY(var(--ang)) translateZ(var(--r));
  opacity: calc(0.25 + var(--f) * 0.75);
  filter: brightness(calc(0.55 + var(--f) * 0.45));
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
  transition: opacity 0.3s, filter 0.3s;
}
.ring__card.is-away { visibility: hidden; }   /* espera atrás cuando hay más piezas que lugares */
.ring__card img { width: 100%; height: 100%; object-fit: cover; pointer-events: none; }
.ring__card.is-front { box-shadow: 0 30px 60px -20px rgba(4, 4, 4, 0.6), 0 0 0 3px var(--color-brand); cursor: zoom-in; }
.ring__card.is-dim { opacity: calc((0.25 + var(--f) * 0.75) * 0.3); filter: grayscale(1) brightness(0.8); }

.ring__floor {
  position: absolute;
  left: 15%;
  right: 15%;
  bottom: 0;
  height: 18%;
  background: radial-gradient(50% 50% at 50% 50%, rgba(4, 4, 4, 0.22), transparent 70%);
  pointer-events: none;
}

.ring-ctrl {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.9rem;
  margin-top: 0.75rem;
}
.ring-ctrl__arrow {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  flex-shrink: 0;
  border: 1px solid var(--color-line);
  border-radius: 50%;
  background-color: var(--color-white);
  color: var(--color-ink);
  cursor: pointer;
  transition: background-color 0.25s var(--ease), color 0.25s var(--ease), border-color 0.25s var(--ease);
}
.ring-ctrl__arrow svg { width: 18px; height: 18px; }
.ring-ctrl__arrow:hover { border-color: var(--color-brand); background-color: var(--color-brand); color: var(--color-white); }

.ring-ctrl__caption {
  display: flex;
  flex-direction: column;
  min-width: 0;
  max-width: 34ch;
  margin: 0;
  text-align: center;
}
.ring-ctrl__caption span { font-family: var(--font-mono); font-size: 0.6875rem; letter-spacing: 0.1em; color: var(--color-brand); }
.ring-ctrl__caption b { overflow: hidden; font-size: 0.875rem; font-weight: 600; white-space: nowrap; text-overflow: ellipsis; color: var(--color-ink); }

.ring-ctrl__zoom {
  flex-shrink: 0;
  padding: 0.55rem 1rem;
  border: 1px solid var(--color-ink);
  border-radius: 999px;
  background: transparent;
  font: inherit;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--color-ink);
  cursor: pointer;
  transition: background-color 0.25s var(--ease), color 0.25s var(--ease);
}
.ring-ctrl__zoom:hover { background-color: var(--color-ink); color: var(--color-white); }

/* ============ 29. FOOTER — PULSO EN EL BORDE ============ */
/* Monitor en el borde (2026-10-22, antes un trazo SVG que solo corría):
   main.js §17.1 escribe el ECG con el motor Sweep; en cada latido sale un
   destello rojo desde la punta (--bx) hacia el footer y late el corazón
   de la lectura de lpm. Mover el mouse sobre el footer acelera el pulso. */
.site-footer::before { display: none; }
.footer__monitor {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 72px;
  pointer-events: none;
  background:
    linear-gradient(90deg, transparent, rgba(var(--color-brand-rgb), 0.18) 15%, rgba(var(--color-brand-rgb), 0.18) 85%, transparent) 0 55% / 100% 1px no-repeat;
}
.footer__ecg { display: block; width: 100%; height: 100%; }
.footer__flash {
  --bx: 50%;
  position: absolute;
  top: 0;
  left: var(--bx);
  width: 520px;
  height: 260px;
  margin-left: -260px;
  background: radial-gradient(50% 40% at 50% 22%, rgba(var(--color-brand-rgb), 0.32), rgba(var(--color-brand-rgb), 0.08) 55%, transparent 75%);
  opacity: 0;
}
.footer__flash.is-on { animation: footerFlash 0.9s ease-out; }
@keyframes footerFlash {
  0%   { opacity: 0; transform: scale(0.7); }
  15%  { opacity: 1; transform: scale(1); }
  100% { opacity: 0; transform: scale(1.25); }
}
.footer__bpm {
  position: absolute;
  top: 10px;
  right: var(--gutter);
  display: flex;
  align-items: baseline;
  gap: 0.35rem;
  font-family: var(--font-mono);
  font-size: 0.6875rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.45);
}
.footer__bpm i { font-style: normal; color: var(--color-brand); display: inline-block; }
.footer__bpm b { font-size: 1.05rem; font-weight: 700; color: var(--color-white); font-variant-numeric: tabular-nums; }
.footer__bpm.is-beat i { animation: footerHeart 0.45s ease-out; }
@keyframes footerHeart {
  0%   { transform: scale(1); }
  25%  { transform: scale(1.45); text-shadow: 0 0 10px rgba(var(--color-brand-rgb), 0.9); }
  100% { transform: scale(1); }
}
.footer__grid { padding-top: clamp(4rem, 7vw, 5rem); }

/* Secciones con ancla: el header fijo no tapa el inicio */
html { scroll-behavior: smooth; scroll-padding-top: var(--header-h); }

/* ============ 29.1 ENTRADA DE SECCIONES ============
   Pedido 2026-10-19: al ir bajando, cada sección aparece con animación.
   main.js §29 marca los bloques de cada sección (.scene__part) y les pone
   .is-in cuando entran a la vista. El fondo de la sección no se mueve
   (no deja huecos de color); lo que sube y se desvanece es su contenido.
   Se repite cada vez que se vuelve a llegar, como el resto de los reveal
   de la página. (Se probó un trazo de pulso rojo en el borde y se
   descartó: no volver a ponerlo.) */
.scene__part {
  opacity: 0;
  transform: translateY(56px);
  /* Se probó entrar con desenfoque (filter: blur) y se descartó: no
     volver a ponerlo. */
  transition: opacity 1.6s var(--ease), transform 1.8s var(--ease);
}
.scene__part.is-in { opacity: 1; transform: none; }

/* ============ 29.2 CLIENTES EN SALTILLO ============
   Expediente de un cliente local: fotos de su identidad a la izquierda y,
   a la derecha, su ficha con las cifras como lectura de monitor (main.js
   §30 las sube al aparecer y dibuja el trazo). Cabe en una pantalla:
   las alturas salen de svh. */
.local-case { padding-block: clamp(2rem, 6svh, 3.5rem); }
.local-case .section__head { margin-bottom: clamp(1rem, 3svh, 1.75rem); }
.local-case .section__title { color: var(--color-white); }
.local-case .section__lead { color: var(--color-body); }

.local-case__grid {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: clamp(1.25rem, 3vw, 2.5rem);
  align-items: center;
}

.local-case__photos {
  position: relative;
  height: clamp(220px, 46svh, 420px);
  margin: 0;
}
.local-case__photo {
  position: absolute;
  object-fit: cover;
  border-radius: 18px;
  box-shadow: var(--shadow-lg);
  transition: opacity 0.9s var(--ease), transform 1.1s var(--ease);
}
.local-case__photo--main { top: 0; left: 0; width: 84%; height: 76%; }
.local-case__photo--door {
  right: 0;
  bottom: 0;
  width: 48%;
  height: 46%;
  border: 3px solid var(--color-ink);
  transform: rotate(2deg);
}
.local-case__grid:not(.is-visible) .local-case__photo--main { opacity: 0; transform: translateX(-24px); }
.local-case__grid:not(.is-visible) .local-case__photo--door { opacity: 0; transform: translateY(24px) rotate(6deg); }
.local-case__grid.is-visible .local-case__photo--door { transition-delay: 0.25s; }

.local-case__chart {
  padding: clamp(1.1rem, 2.6svh, 1.75rem) clamp(1.1rem, 2vw, 1.75rem);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 18px;
  background-color: var(--color-ink-soft);
}
.local-case__kicker {
  margin: 0;
  font-family: var(--font-mono);
  font-size: 0.6875rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--color-brand);
}
.local-case__kicker span { margin-left: 0.8em; color: rgba(255, 255, 255, 0.5); }
.local-case__name {
  margin: 0.45rem 0 0.3rem;
  font-family: var(--font-display);
  font-size: clamp(1.2rem, 2.1vw, 1.55rem);
  font-weight: 800;
  line-height: 1.15;
  color: var(--color-white);
}
.local-case__services { margin: 0; font-size: 0.9375rem; color: var(--color-body); }
.local-case__link {
  color: var(--color-white);
  text-decoration: underline;
  text-decoration-color: var(--color-brand);
  text-underline-offset: 3px;
}
.local-case__link:hover { color: var(--color-brand); }

/* Monitor: rejilla tenue roja, como la del hero */
.local-case__monitor {
  margin-top: clamp(0.8rem, 2.2svh, 1.25rem);
  padding: clamp(0.8rem, 2svh, 1.1rem) clamp(0.8rem, 1.6vw, 1.1rem) 0.4rem;
  border: 1px solid rgba(var(--color-brand-rgb), 0.28);
  border-radius: 12px;
  background-color: #070707;
  background-image:
    linear-gradient(rgba(var(--color-brand-rgb), 0.06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(var(--color-brand-rgb), 0.06) 1px, transparent 1px);
  background-size: 22px 22px;
}
.local-case__vitals {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.75rem;
  margin: 0;
}
.local-case__vital { display: flex; flex-direction: column; }
.local-case__label {
  flex: 1;
  min-height: 2.4em;
  font-family: var(--font-mono);
  font-size: 0.625rem;
  line-height: 1.2;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.55);
}
.local-case__value {
  margin: 0.3rem 0 0;
  font-family: var(--font-accent);
  font-size: clamp(1.6rem, 3vw, 2.4rem);
  line-height: 1;
  color: var(--color-white);
  font-variant-numeric: tabular-nums;
}
.local-case__value small { margin-left: 0.08em; font-size: 0.6em; color: var(--color-brand); }
.local-case__trace {
  display: block;
  width: 100%;
  height: clamp(26px, 5svh, 40px);
  margin-top: 0.3rem;
  overflow: visible;
}
.local-case__trace path {
  fill: none;
  stroke: var(--color-brand);
  stroke-width: 2;
  stroke-linejoin: round;
  vector-effect: non-scaling-stroke;
  filter: drop-shadow(0 0 6px rgba(var(--color-brand-rgb), 0.6));
  stroke-dasharray: 1;
  stroke-dashoffset: 1;
}
.local-case__monitor.is-live .local-case__trace path {
  stroke-dashoffset: 0;
  transition: stroke-dashoffset 1.8s cubic-bezier(0.45, 0, 0.25, 1);
}
.local-case__note {
  margin: 0.75rem 0 0;
  font-size: 0.75rem;
  line-height: 1.45;
  color: rgba(255, 255, 255, 0.5);
}

.local-case__also {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 0.6rem 1rem;
  margin-top: clamp(1rem, 3svh, 1.75rem);
}
.local-case__also-title {
  margin: 0;
  font-family: var(--font-mono);
  font-size: 0.6875rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--color-brand);
}
.local-case__clients {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin: 0;
  padding: 0;
  list-style: none;
}
.local-case__client {
  display: flex;
  align-items: baseline;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--radius-full);
  background-color: var(--color-ink-soft);
  font-size: 0.875rem;
  color: var(--color-body);
}
.local-case__client b { color: var(--color-white); }

@media (prefers-reduced-motion: reduce) {
  .local-case__photo,
  .local-case__monitor.is-live .local-case__trace path { transition: none; }
  .local-case__trace path { stroke-dashoffset: 0; }
  .local-case__grid:not(.is-visible) .local-case__photo--main,
  .local-case__grid:not(.is-visible) .local-case__photo--door { opacity: 1; transform: none; }
  .local-case__photo--door { transform: rotate(2deg); }
}

/* ============ 30.1 FONDOS NEGROS ============
   Pedido 2026-10-22: todo lo que tenía fondo blanco/crema pasa a negro.
   En las secciones que eran claras se invierten los tokens de texto
   (--color-ink pasa a blanco) y las tarjetas, botones y campos van en
   gris casi negro. Se quedan claros a propósito los objetos que imitan
   algo real: la receta de papel del FAQ, las vistas de la pantalla de
   Servicios (Instagram, Google, anuncio…) y el mapa. */
body { background-color: var(--color-ink); }

.rx, .care, .ring-sec, .faq-section, .contact {
  --color-ink: #ffffff;
  --color-text-soft: #b3b3b3;
  --color-line: rgba(255, 255, 255, 0.14);
  --color-cream: #161616;
  --card-dark: #111111;
  color: var(--color-text-soft);
}

/* Objetos que conservan sus colores originales */
.rx__screen,
.rx-pad {
  --color-ink: #040404;
  --color-text-soft: #4a4a4a;
  --color-line: #dddddd;
}
.rx__screen { box-shadow: 0 40px 80px -30px rgba(0, 0, 0, 0.8), 0 0 0 1px rgba(255, 255, 255, 0.1); }

/* Servicios */
.rx__item { background-color: rgba(255, 255, 255, 0.04); }
.rx__item.is-active { background-color: var(--card-dark); }
.rx__tags i { color: #ff6b6b; }

/* Proceso */
.care__dot,
.care__chart { background-color: var(--card-dark); }

/* Portafolio */
.ring-filter,
.ring-ctrl__arrow { background-color: var(--card-dark); }
.ring-ctrl__zoom:hover { background-color: #fff; color: #040404; }
.ring__floor { background: radial-gradient(50% 50% at 50% 50%, rgba(var(--color-brand-rgb), 0.12), transparent 70%); }

/* FAQ */
.chat__pick { background-color: var(--card-dark); box-shadow: none; }
.chat__pick.is-asked { background-color: rgba(var(--color-brand-rgb), 0.16); color: rgba(255, 255, 255, 0.6); }

/* Contacto */
.contact-map,
.contact-form,
.contact-panel { background-color: var(--card-dark); }
.contact .field select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23ffffff' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
}
.contact .field select option { background-color: #161616; color: #fff; }
.contact .field input:hover,
.contact .field select:hover,
.contact .field textarea:hover { border-color: rgba(255, 255, 255, 0.3); }
.contact .field input:focus,
.contact .field select:focus,
.contact .field textarea:focus { background-color: #1c1c1c; }
.contact .field.has-error input,
.contact .field.has-error select,
.contact .field.has-error textarea { background-color: rgba(var(--color-brand-rgb), 0.08); }
.contact .field__error,
.contact-form__status.is-error { color: #ff4d4d; }
.contact-form__status.is-ok { color: #4ade80; }

/* ============ 30. MENOS MOVIMIENTO ============ */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .hero__write { clip-path: none; animation: none; }
  .hero__write-head { display: none; }
  .hero__copy > *,
  .hero__media { opacity: 1; transform: none; animation: none; }
  .hero__scan,
  .hero__live,
  .hero__scroll span,
  .monitor__rec i,
  .footer__flash.is-on,
  .footer__bpm.is-beat i,
  .care__beat.is-selected .care__dot::after { animation: none; }
  .ping { transition: none; }
  .rx-view.is-on.is-enter,
  .rx-view.is-old,
  .rx-view > .rx-view__in,
  .rx__screen.is-sweeping .rx__sweep { animation: none; }
  .rx__item.is-active.is-running .rx__timer { animation: none; }
  .brand, .brand__logo, .brand__piece, .brand__stage { transition: none !important; }
  .quiz__q,
  .quiz__result { transition: none; }
}
