/* ==========================================================================
   Karen Morales Insurance — hoja de estilos
   Rangos de pantalla usados:
     escritorio        ≥ 1181px (con ajustes en 1181–1299, 1500–1649 y 1650–1799)
     tablet            992–1180px
     tablet chica      768–991px
     móvil             ≤ 767px
   La fuente raíz escala (10px, 9px ≤1200, 8px ≤900, 4.8px ≤640, 12px ≥1800):
   los espaciados en rem siguen esa escala.
   ========================================================================== */

:root {
  --navy: #1f3a56;
  --dorado: #d4af37;
  --crema: #f5f2eb;
  --beige: #e6e2da;
  --blanco: #fff;
  --curva: cubic-bezier(0.86, 0, 0.09, 1);
}

/* Base -------------------------------------------------------------------- */

/* scroll-padding-top: los enlaces a anclas (#preguntas…) se detienen debajo de la barra fija
   (114px de alto con top: -20px, así que tapa 94px en todos los tamaños) */
html { font-size: 10px; scroll-behavior: smooth; scroll-padding-top: 94px; }
@media (max-width: 1200px) { html { font-size: 9px; } }
@media (max-width: 900px)  { html { font-size: 8px; } }
@media (max-width: 640px)  { html { font-size: 4.8px; } }
@media (min-width: 1800px) { html { font-size: 12px; } }

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

body {
  font-family: Outfit, sans-serif;
  font-size: 16px;
  line-height: 1.5;
  color: var(--navy);
  background: var(--blanco);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1, h2, h3, h4, h5, h6 { font-weight: 500; line-height: 1.2; }
ul { list-style: none; }
img { max-width: 100%; vertical-align: middle; border: 0; }
a { color: inherit; text-decoration: none; transition: color .35s ease-in-out; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
address { font-style: normal; }
::selection { background: var(--navy); color: var(--blanco); }

.sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
.ico {
  width: 1em;
  height: 1em;
  fill: none;
  stroke: currentColor;
  stroke-width: var(--trazo, 1);
  stroke-linecap: round;
  stroke-linejoin: round;
  transform: scale(var(--escala, 1));
  transform-origin: var(--origen, 50% 50%);
}
/* Los íconos de Tabler traen margen interno: se agrandan sin alterar el layout */
.rombo, .servicio__info, .circulo__centro, .panel__icono, .boton-cotiza__icono { --escala: 1.22; --trazo: .82; }
.rasgo__icono, .dato__icono { --escala: 1.25; --trazo: .8; --origen: 0 50%; }
.pie__social { --escala: 1.3; --trazo: .8; }
.compromiso__icono { --escala: 1.3; --trazo: .8; }
.video__boton { --escala: 1.5; --trazo: .7; }

/* Rejilla ------------------------------------------------------------------ */

.contenedor { width: 100%; margin: 0 auto; padding: 0 15px; }
@media (min-width: 576px)  { .contenedor { max-width: 540px; } }
@media (min-width: 768px)  { .contenedor { max-width: 720px; } }
@media (min-width: 992px)  { .contenedor { max-width: 960px; } }
@media (min-width: 1200px) { .contenedor { max-width: 1450px; } }

.fila { display: flex; flex-wrap: wrap; margin: 0 -15px; }
.fila--centro { justify-content: center; }
@media (max-width: 1199px) { .fila { justify-content: center; } }

.col-5c, .col-4c, .col-3c, .col-2c { position: relative; width: 100%; padding: 15px 15px 0; }
@media (min-width: 992px) {
  .col-5c { flex: 0 0 20%; max-width: 20%; }
  .col-4c { flex: 0 0 25%; max-width: 25%; }
  .col-3c { flex: 0 0 33.333%; max-width: 33.333%; }
  .col-2c { flex: 0 0 50%; max-width: 50%; }
}

/* Botones ------------------------------------------------------------------ */

.boton {
  position: relative;
  display: inline-block;
  overflow: hidden;
  max-width: 250px;
  height: 70px;
  margin: 1rem auto;
  padding: 0 50px;
  border-radius: 5px;
  background: var(--navy);
  color: var(--blanco);
  font-size: 16px;
  font-weight: 600;
  line-height: 70px;
  text-transform: capitalize;
  vertical-align: baseline;
  transition: background-color .35s ease-in-out, color .35s ease-in-out;
}
.boton span { position: relative; z-index: 2; display: flex; text-align: left; }
/* Cuadros que cruzan el botón al pasar el cursor */
.boton::before, .boton::after {
  content: "";
  position: absolute;
  top: 50%;
  width: 20px;
  height: 20px;
  border-radius: 5%;
  background: var(--navy);
}
.boton::before { left: -20px; transform: translate(-50%, -50%); }
.boton::after { right: -20px; transform: translate(50%, -50%); }
.boton:hover { background: var(--dorado); color: var(--navy); }
.boton:hover::before { animation: cruce-izq .9s ease both; }
.boton:hover::after { animation: cruce-der .5s ease both; }

@keyframes cruce-izq {
  0% { left: -10px; }
  50% { left: 35%; width: 50px; height: 50px; }
  70% { left: 20%; }
  100% { left: 110%; width: 375px; height: 375px; }
}
@keyframes cruce-der {
  0% { right: -20px; }
  30% { right: 30%; width: 20px; height: 20px; }
  40% { right: 20%; }
  100% { right: 80%; width: 125px; height: 125px; }
}

.boton--borde { padding: 0 48px; border: 2px solid var(--blanco); }

/* Cargador ------------------------------------------------------------------ */

.cargador {
  position: fixed;
  top: 0;
  right: 0;
  z-index: 99999;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  background: var(--blanco);
  transition: top 1s var(--curva);
}
.cargado .cargador { top: 100%; }
.cargador figure {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 140px;
  height: 140px;
  margin-bottom: 1rem;
  border: 1px solid var(--beige);
  border-radius: 50%;
  animation: subir .3s ease;
}
.cargador figure::after {
  content: "";
  position: absolute;
  inset: 0;
  border: 1px solid transparent;
  border-top: 3px solid var(--navy);
  border-radius: 50%;
  animation: girar .6s ease infinite;
}
.cargador img { height: 130px; }

@keyframes subir { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: none; } }
@keyframes girar { to { transform: rotate(360deg); } }

/* Cursor personalizado (solo con mouse) */
.puntero, .puntero-anillo { position: fixed; top: 0; left: 0; z-index: 9999; pointer-events: none; }
.puntero { width: 0; height: 0; margin: -5px 0 0 -3px; border: 2px solid #ababab; border-radius: 4px; }
.puntero-anillo { width: 0; height: 0; padding: 25px; border: 2px solid #f1f1f1; border-radius: 100px; }

/* Panel lateral -------------------------------------------------------------- */

.panel {
  position: fixed;
  top: 0;
  left: -100%;
  z-index: 9;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  width: 400px;
  max-width: 100%;
  height: 100vh;
  padding: 20px 30px;
  background: var(--blanco);
  box-shadow: 0 0 60px rgba(0, 0, 0, .4);
  color: #000;
  transition: left 1s var(--curva);
}
.panel.abierto { left: 0; z-index: 11; }
@media (max-width: 767px) { .panel { max-width: 80vw; } }

.panel__interior { display: flex; flex-wrap: wrap; align-items: center; height: 100%; overflow-y: auto; }
.panel__logo { width: 100%; margin-bottom: 40px; text-align: center; }
.panel__logo a { display: inline; }

.panel__contacto { width: 100%; }
.panel__titulo {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  margin-bottom: .5rem;
  color: var(--navy);
  font-size: 32px;
  font-weight: 900;
  line-height: 1.2;
  text-align: center;
}
.panel__datos { display: block; margin-bottom: 20px; color: var(--navy); font-size: 20px; line-height: 30px; text-align: center; }
/* Cada dato es un enlace: llamar, escribir un correo o abrir WhatsApp */
.panel__dato { display: block; }
.panel__dato:hover { color: var(--dorado); }
.panel__dato:hover .panel__icono { background: var(--dorado); color: var(--navy); }
.panel__icono {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 90px;
  height: 91px;
  margin: 2rem auto 15px;
  border-radius: 5px;
  background: var(--navy);
  color: var(--blanco);
  font-size: 40px;
  transition: background-color .35s ease-in-out, color .35s ease-in-out;
}

.panel__menu { display: none; width: 100%; padding: 20px 0; }
.panel__menu ul { display: block; width: 100%; }
.panel__menu li { position: relative; float: left; width: 100%; margin: 3px 0; padding: 5px; }
.panel__menu > ul > li > a { display: block; padding: .5rem 0; color: var(--navy); font-size: 18px; font-weight: 600; line-height: 27px; }
.panel__menu a:hover { color: var(--dorado); }
.panel__menu .con-sub > a { white-space: nowrap; }
.panel__menu .con-sub > a::after {
  content: "";
  display: inline-block;
  margin-left: .255em;
  vertical-align: .255em;
  border-top: .3em solid;
  border-right: .3em solid transparent;
  border-left: .3em solid transparent;
}
.panel__sub {
  position: absolute;
  top: calc(1rem + 19px);
  left: -19px;
  z-index: 1;
  width: 100%;
  min-width: 160px;
  max-height: 135px;
  overflow-y: scroll;
  padding-left: 20px;
  border-radius: 5px;
  background: var(--blanco);
  visibility: hidden;
  opacity: 0;
  transition: opacity .5s, visibility .5s;
}
.panel__menu li:hover > .panel__sub { visibility: visible; opacity: 1; }
.panel__sub li { clear: both; }
.panel__sub a { padding: .25rem 1.5rem; color: var(--navy); font-size: 18px; font-weight: 600; line-height: 27px; white-space: nowrap; }
@media (min-width: 768px) and (max-width: 991px) { .panel__sub { left: -31px; } }
@media (max-width: 767px) { .panel__sub { left: -26px; } }


@media (max-width: 1180px) {
  .panel__contacto { display: none; }
  .panel__menu { display: flex; }
}

/* Barra superior -------------------------------------------------------------- */

.barra {
  position: fixed;
  top: -20px;
  left: 0;
  z-index: 8;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  width: 100%;
  height: 114px;
  padding: .5rem 1rem;
  background: var(--blanco);
}
.barra__fila { display: flex; align-items: center; justify-content: space-between; }
@media (max-width: 767px) { .barra__fila { padding: 0; } }

.barra__logo { display: block; margin-right: auto; padding: 20px 0; }
.barra__logo img { display: block; height: 76px; width: auto; max-width: none; }

.menu { margin: 5px auto 0; }
.menu__lista { display: flex; flex-wrap: wrap; }
.menu__lista li { position: relative; display: flex; padding: 0 14px; }
.menu__enlace {
  position: relative;
  z-index: 1;
  display: block;
  padding: 11px;
  color: var(--navy);
  font-size: 18px;
  font-weight: 600;
  line-height: 27px;
  white-space: nowrap;
  transition: color .5s;
}
.menu__enlace::before {
  content: "";
  position: absolute;
  bottom: 5px;
  left: 11px;
  z-index: -1;
  width: 0;
  height: 3px;
  border-radius: 5px;
  background: var(--navy);
  transition: width .35s, background-color .35s;
}
.menu__enlace:hover { color: var(--dorado); }
.menu__enlace:hover::before { width: 59px; background: var(--dorado); }

.menu__sub {
  position: absolute;
  top: 110%;
  left: 3px;
  z-index: 1;
  min-width: 160px;
  padding: 5px 0;
  border-radius: 5px;
  background: var(--blanco);
  box-shadow: 0 0 5px rgba(0, 0, 0, .15);
  /* Se cierra con 0.3s de retraso: si el mouse se sale un momento al bajar, no desaparece */
  visibility: hidden;
  opacity: 0;
  transition: opacity .2s .3s, visibility 0s .5s;
}
/* Puente invisible sobre el hueco entre el enlace y el submenú (top: 110%), para no perder el hover al bajar */
.menu__sub::before { content: ""; position: absolute; bottom: 100%; left: 0; right: 0; height: 16px; }
.menu__lista li:hover > .menu__sub,
.menu__lista li:focus-within > .menu__sub { visibility: visible; opacity: 1; transition: opacity .2s, visibility 0s; }
.menu__sub li { width: 100%; }

@media (min-width: 1181px) and (max-width: 1299px) {
  .menu__lista li { padding: 0 2px; }
  .menu__lista > li > .menu__enlace { padding: 14px 8px; font-size: 14px; font-weight: 700; line-height: 21px; }
  .menu__sub .menu__enlace { font-size: 14px; font-weight: 700; line-height: 21px; }
}
/* Entre 1181 y 1199px el contenedor mide 960px y el menú no cabía: la barra usa todo el ancho */
@media (min-width: 1181px) and (max-width: 1199px) { .barra__fila { max-width: none; } }
/* Seis enlaces ("Acompañamiento" es largo): menos espacio entre ellos para que no bajen a otra línea */
@media (min-width: 1300px) and (max-width: 1439px) { .menu__lista li { padding: 0 4px; } }
@media (max-width: 1180px) { .menu { display: none; } }
@media (max-width: 900px) { .menu { margin-top: 0; } }

.hamburguesa { position: relative; width: 30px; height: 20px; margin-left: auto; padding: 0; transition: transform .5s cubic-bezier(0.86, 0, 0.07, 1); }
.hamburguesa span {
  position: absolute;
  left: 0;
  display: block;
  width: 100%;
  height: 2px;
  background: var(--navy);
  transition: .25s ease-in-out;
}
.hamburguesa span:nth-child(1) { top: 0; }
.hamburguesa span:nth-child(2) { top: 9px; width: 22px; }
.hamburguesa span:nth-child(3) { top: 18px; }
.hamburguesa:hover span { width: 100%; }
.hamburguesa.abierta span { width: 20px; }
.hamburguesa.abierta span:nth-child(1) { top: 9px; width: 28px; transform: rotate(135deg); }
.hamburguesa.abierta span:nth-child(2) { left: -20px; opacity: 0; }
.hamburguesa.abierta span:nth-child(3) { top: 9px; width: 28px; transform: rotate(-135deg); }
/* En escritorio el panel lo abre el botón "Cotiza tu seguro"; la hamburguesa queda para tablet y móvil */
@media (min-width: 1181px) { .hamburguesa { display: none; } }

.barra__accion { height: 110px; margin-top: 4px; margin-left: 30px; }
@media (max-width: 767px) { .barra__accion { display: none; } }

.boton-cotiza {
  position: relative;
  display: inline-flex;
  align-items: flex-start;
  overflow: hidden;
  max-width: 250px;
  height: 75px;
  margin: 19px 0 1rem;
  padding: 0 17px 0 8px;
  border-radius: 5px;
  background: var(--navy);
  color: var(--blanco);
  font-size: 18px;
  font-weight: 600;
  line-height: 70px;
}
.boton-cotiza:hover { color: var(--blanco); }
.boton-cotiza__icono { display: flex; align-items: center; justify-content: center; width: 63px; height: 59px; margin-top: 5px; font-size: 48px; }
.boton-cotiza__texto { display: block; white-space: nowrap; }

/* Portada ---------------------------------------------------------------------- */

/* La portada no ocupa toda la pantalla: así se asoma la sección siguiente y se nota que hay más contenido */
.portada { position: relative; width: 100%; }
.portada, .portada__slider { height: 78vh; min-height: 560px; max-height: 860px; }
.portada__slider { width: 100%; overflow: hidden; }
.portada__slide {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  padding: 0 15%;
  background: var(--blanco);
}
@media (max-width: 767px) { .portada__slide { padding: 100px 0 0; } }

.portada__fondo { position: absolute; inset: 0; background-position: center; background-size: cover; }
.portada__contenido { position: relative; z-index: 1; }

.portada__titulo {
  width: 100%;
  margin: -105px 0 10px -5rem;
  color: var(--navy);
  font-size: 60px;
  font-weight: 600;
  line-height: 1.2;
}
.portada__texto { width: 100%; margin: 17px 0 65px -4.8rem; color: var(--navy); font-size: 18px; line-height: 1.5; }
.portada__acciones { position: relative; display: flex; margin-top: calc(29px - 6rem); }

/* Botón circular con texto giratorio */
/* Botón circular "Hablar con Karen" (WhatsApp): único botón de la portada */
.circulo { position: relative; display: block; flex: none; width: 200px; height: 200px; font-weight: 600; }
/* Gira el SVG completo y no cada <text>: Safari (iOS) toma el 50% del transform-origin de un <text>
   respecto a su propia caja y el texto giraba fuera del eje */
.circulo__texto { position: absolute; inset: 0; width: 200px; height: 200px; overflow: visible; transform-origin: 50% 50%; animation: girar 15s linear infinite; }
.circulo__texto text { fill: var(--navy); font-size: 8px; }
.circulo__centro {
  position: absolute;
  top: 40px;
  left: 40px;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 120px;
  height: 120px;
  border-radius: 50%;
  background: var(--navy);
  color: var(--blanco);
  font-size: 55px;
  transition: background-color .35s ease-in-out;
}
.circulo:hover .circulo__centro { background: var(--dorado); }

.portada__flecha {
  position: absolute;
  top: 39%;
  z-index: 3;
  width: 60px;
  height: 60px;
  border: 1px solid transparent;
  border-radius: 5px;
  background: var(--navy);
  color: var(--blanco);
  font-size: 23px;
  line-height: 60px;
  text-align: center;
  transform: rotate(90deg);
  transition: .35s ease-in-out;
}
.portada__flecha span { display: block; width: 60px; height: 60px; margin: -1px; line-height: 60px; transform: rotate(272deg); }
.portada__flecha:hover { background: var(--dorado); color: var(--navy); }
.portada__flecha--prev { left: 50px; }
.portada__flecha--next { right: 50px; }

/* El contenido de la portada va en la mitad derecha: las imágenes dejan el sujeto a la izquierda */
@media (min-width: 992px) {
  .portada__contenido { width: 50%; max-width: none; margin-right: 0; margin-left: 50%; }
  .portada__titulo, .portada__texto { margin-left: 0; }
  .portada__titulo, .portada__texto { text-align: right; }
  .portada__acciones { justify-content: flex-end; }
}
/* En pantallas angostas la foto queda detrás del texto: panel claro para que se lea */
@media (max-width: 991px) {
  .portada__contenido {
    width: calc(100% - 24px);
    padding-top: 20px;
    padding-bottom: 20px;
    border-radius: 10px;
    background: rgba(255, 255, 255, .78);
    -webkit-backdrop-filter: blur(2px);
    backdrop-filter: blur(2px);
  }
}
@media (min-width: 1181px) and (max-width: 1299px) {
  .portada__titulo { margin-top: -42px; font-size: 43px; }
}
@media (min-width: 1500px) and (max-width: 1799px) {
  .portada__titulo { font-size: 50px; }
}
@media (max-width: 1180px) {
  .portada__titulo { margin-top: 76px; font-size: 30px; }
  .portada__titulo br { display: none; }
  .portada__flecha { display: none; }
}
@media (max-width: 900px) {
  .portada__titulo { margin-left: 0; }
  .portada__texto { margin: 0 0 56px; }
}
@media (max-width: 991px) {
  .portada__acciones { margin-top: -5rem; }
}
@media (max-width: 767px) {
  .portada__titulo { margin-top: 6px; font-size: 35px; }
}
/* Desde 992px el contenido se centra en la franja visible: debajo del menú fijo (94px) y
   por encima de las nubes que cubren el borde inferior */
@media (min-width: 992px) {
  .portada__slide { padding-top: 94px; padding-bottom: 8vw; }
  .portada__titulo { margin-top: 0; }
  /* La foto entra completa en esa franja (sin recortar a las personas) y queda a la izquierda;
     el fondo casi blanco de la imagen se difumina en los bordes para fundirse con el blanco del slide */
  .portada__fondo {
    top: 94px;
    bottom: 5vw;
    background-position: left bottom;
    background-repeat: no-repeat;
    background-size: contain;
    -webkit-mask-image: linear-gradient(to right, transparent, #000 3%, #000 55%, transparent 75%), linear-gradient(transparent, #000 8%);
    -webkit-mask-composite: source-in;
    mask-image: linear-gradient(to right, transparent, #000 3%, #000 55%, transparent 75%), linear-gradient(transparent, #000 8%);
    mask-composite: intersect;
  }
}
/* Con flechas visibles, la foto empieza a su derecha para que no tapen a las personas.
   Las nubes terminan casi al ras de la portada (ver .nubes), así que foto y contenido suben un poco */
@media (min-width: 1181px) {
  .portada, .portada__slider { height: 74vh; }
  .portada__slide { padding-bottom: 12vw; }
  .portada__fondo { left: 110px; bottom: 9vw; }
}
/* Pantallas bajas: contenido más compacto para que quepa en la portada */
@media (min-width: 992px) and (max-height: 940px) {
  .portada__titulo { font-size: 44px; }
  .portada__texto { margin: 10px 0 50px; }
  .circulo { zoom: .75; }
}
@media (min-width: 992px) and (max-height: 760px) {
  .portada__titulo { font-size: 36px; }
  .portada__texto { margin-bottom: 45px; }
  .circulo { zoom: .65; }
}

/* Nubes */
/* Las nubes se superponen a la portada: no deben capturar el mouse */
.nubes { position: relative; z-index: 2; margin: -168px 0 -22px; pointer-events: none; }
.nubes img { display: block; width: 100%; }
/* En escritorio cubren casi todo su alto (la imagen mide 24.4vw): así no queda una franja vacía
   bajo la portada y las tarjetas de beneficios se asoman completas en la primera pantalla */
@media (min-width: 1181px) { .nubes { margin-top: -22vw; } }
@media (max-width: 900px) { .nubes { margin-top: -139px; padding: 2rem 0; } }
@media (min-width: 801px) and (max-width: 843px) { .nubes { margin-top: -135px; } }
@media (min-width: 844px) and (max-width: 900px) { .nubes { margin-top: -167px; } }
@media (max-width: 767px) { .nubes { margin-top: -61px; } }

/* Tarjetas (beneficios y ventajas) ------------------------------------------------ */

.destacados { position: relative; z-index: 2; margin-bottom: -34px; padding: 2rem 0 0; }
@media (max-width: 900px) { .destacados { margin-bottom: 0; padding: 4rem 0 1rem; } }

.tarjeta { z-index: 2; text-align: center; cursor: default; }
.tarjeta__caja {
  position: relative;
  margin-bottom: 16px;
  padding: 22px;
  border-radius: 5px;
  box-shadow: 0 0 5px rgba(181, 181, 181, .38);
}
.tarjeta__caja::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  z-index: -1;
  width: 100%;
  height: 0;
  border-radius: 5px;
  background: var(--navy);
  transition: height .6s;
}
.tarjeta__caja:hover::before { height: 100%; }
.tarjeta__cuerpo { display: inline-block; text-align: center; }

.rombo {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 80px;
  height: 80px;
  margin: 0 auto 1rem;
  border-radius: 5px;
  background: var(--navy);
  color: var(--blanco);
  font-size: 62px;
  transform: translate(-1px, 2px);
  transition: background-color .2s ease-in-out;
}
.rombo:hover { background: var(--dorado); }

.tarjeta__titulo { margin-bottom: .5rem; color: var(--navy); font-size: 22px; font-weight: 600; }
.tarjeta__texto { margin-bottom: .5rem; color: var(--navy); font-size: 16px; line-height: 1.2; }
.tarjeta__caja:hover .tarjeta__titulo,
.tarjeta__caja:hover .tarjeta__texto { color: var(--blanco); }

/* Sobre Karen ---------------------------------------------------------------------- */

/* Los rayos giratorios (.sobre__rayos) pasan del borde en algunos anchos: sin scroll horizontal */
.sobre { padding: 2rem 0; background: var(--blanco); overflow-x: clip; }
.sobre > .contenedor { margin-top: 4rem; }
@media (max-width: 900px) { .sobre > .contenedor { margin-top: 3rem; } }

/* En escritorio el texto va a la izquierda y la foto a la derecha */
@media (min-width: 992px) { .sobre__media { order: 2; } }
/* Rayos giratorios detrás de la foto (CSS propio) */
.sobre__rayos {
  position: absolute;
  bottom: -7%;
  left: 3%;
  z-index: 0;
  width: 670px;
  max-width: 100%;
  aspect-ratio: 1;
  border-radius: 50%;
  background: repeating-conic-gradient(rgba(12, 21, 64, .045) 0deg 7deg, transparent 7deg 18deg);
  -webkit-mask-image: radial-gradient(circle, transparent 0 3%, #000 8%, #000 52%, transparent 70%);
  mask-image: radial-gradient(circle, transparent 0 3%, #000 8%, #000 52%, transparent 70%);
  animation: girar 30s linear infinite;
}
.sobre__foto { position: relative; z-index: 0; display: block; width: 100%; border-radius: 5px; }
@media (min-width: 1181px) and (max-width: 1299px) { .sobre__rayos { bottom: -20%; width: 428px; } }
@media (min-width: 1500px) and (max-width: 1649px) { .sobre__rayos { bottom: -30%; width: 538px; } }
@media (max-width: 900px) { .sobre__rayos { display: none; } }

.sobre__titulo { margin-bottom: .5rem; font-size: 32px; font-weight: 900; }
@media (max-width: 900px) { .sobre__titulo { margin-top: 11rem; } }
.sobre__parrafo { margin: 1.4rem 0 1rem; font-size: 16px; line-height: 1.5; }

.rasgos { margin-top: calc(1.2rem - 1rem - 8px); }
@media (max-width: 900px) { .rasgos { margin-top: 1.2rem; } }
.rasgos > .rasgo { display: flex; flex-wrap: wrap; align-content: flex-start; padding: 15px 0 0; cursor: pointer; }
.rasgo__icono {
  flex: 0 0 25%;
  max-width: 25%;
  padding: 7px 15px 0;
  color: var(--navy);
  font-size: 70px;
  line-height: 105px;
  transition: color .5s;
}
.rasgo__icono .ico { position: relative; left: -.15em; display: block; height: 105px; width: 70px; }
.rasgo__icono:hover { color: var(--dorado); }
.rasgo__cuerpo { flex: 0 0 75%; max-width: 75%; padding: 7px 15px 0; }
.rasgo__titulo { display: block; margin-bottom: .5rem; font-size: 21px; font-weight: 900; line-height: 1.2; }
.rasgo__texto { display: block; margin-bottom: .5rem; font-size: 16px; line-height: 1.2; }

@media (min-width: 992px) and (max-width: 1180px) {
  .rasgo__icono { font-size: 54px; line-height: 81px; }
  .rasgo__icono .ico { width: 54px; height: 81px; }
}
@media (max-width: 1000px) { .rasgo__titulo, .rasgo__texto { text-align: center; } }
@media (max-width: 991px) {
  .rasgo__icono, .rasgo__cuerpo { flex: 0 0 100%; max-width: 100%; padding: 15px 15px 0; }
  .rasgo__icono .ico { left: 0; margin: 0 auto; }
}

.sobre__texto > .boton { margin-top: .4rem; }

/* Franja de seguros ------------------------------------------------------------------ */

.franja { position: relative; margin-top: -43px; padding: 2rem 0 6rem; background: var(--navy); }
@media (max-width: 1180px) { .franja { margin-top: -20px; } }
@media (max-width: 900px) { .franja { margin-top: 0; padding: 1rem 0 3rem; } }
.franja__texto, .franja__accion { width: 100%; padding: 15px 15px 0; }
@media (min-width: 992px) {
  .franja__texto { flex: 0 0 83.3333%; max-width: 83.3333%; }
  .franja__accion { flex: 0 0 16.6667%; max-width: 16.6667%; }
}
.franja__titulo { margin-bottom: .5rem; color: var(--blanco); font-size: 32px; font-weight: 900; }
.franja__lema { color: var(--blanco); }

/* Carrusel de servicios ------------------------------------------------------------------ */

.servicios { position: relative; margin-top: -103px; padding: 2rem 0; }
@media (max-width: 1180px) { .servicios { margin-top: -60px; padding-bottom: 0; } }
@media (max-width: 900px) { .servicios { margin-top: 0; padding: 1rem 0 3rem; } }

.carrusel { position: relative; overflow: hidden; margin-top: 15px; padding-bottom: 73px; }
@media (min-width: 1181px) and (max-width: 1299px) { .carrusel { padding-bottom: 112px; } }
.carrusel.carrusel--fijo { padding-bottom: 0; }

.carrusel .swiper-pagination { bottom: -2px; margin-bottom: 9px; line-height: 24px; }
@media (max-width: 900px) { .carrusel .swiper-pagination { margin-bottom: 0; } }
.carrusel .swiper-pagination-bullet {
  width: 20px;
  height: 20px;
  margin: 0 4px 0 5px;
  border-radius: 5px;
  background: var(--navy);
  opacity: .8;
  transition: .35s ease-in-out;
}
.carrusel .swiper-pagination-bullet-active { width: 25px; height: 25px; margin-bottom: -3px; background: var(--dorado); opacity: 1; }
@media (max-width: 900px) { .carrusel .swiper-pagination-bullet-active { margin-bottom: 0; } }

.servicio { position: relative; z-index: 2; margin-bottom: 1rem; }
.servicio__foto { display: block; width: 100%; border-radius: 5px; }
.servicio__info { position: absolute; right: 0; bottom: 0; left: 0; z-index: 1; padding-top: .2rem; color: var(--blanco); text-align: center; }
.servicio__info::before, .servicio__info::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  z-index: -1;
  width: 100%;
  border-radius: 5px;
  transition: .6s ease-in-out;
}
.servicio__info::before { height: 105%; background: var(--navy); }
.servicio__info::after { height: 115%; background: rgba(31, 58, 86, .424); }
.servicio__info > .ico { display: block; width: 60px; height: 90px; margin: 0 auto; }
.servicio__titulo { margin: calc(1rem - 20px) 0 1rem; font-size: 22px; font-weight: 600; }
.servicio__texto { padding: 0 15px; font-size: 16px; line-height: 1.5; }
.servicio__accion { margin-bottom: -80px; visibility: hidden; opacity: 0; transition: .3s ease-in-out; }
.servicio__accion .boton span { padding: 0 15px; }
.servicio:hover .servicio__accion { margin-bottom: -2px; visibility: visible; opacity: 1; }

/* Acompañamiento ------------------------------------------------------------------ */

/* Los círculos de puntos (.forma) se salen del borde a propósito: se recortan aquí para no generar scroll horizontal */
.acompanamiento { position: relative; z-index: 2; padding: 2rem 0 1rem; overflow-x: clip; }
/* Círculos de puntos decorativos (CSS propio) */
.forma {
  position: absolute;
  display: block;
  width: 205px;
  height: 197px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(0, 0, 0, .3) 1.8px, transparent 2.3px) center / 13px 13px;
}
.forma--1 { top: calc(2rem + 149px); left: calc(10% + 1271px); animation: flotar-y 1.5s ease infinite; }
.forma--2 { top: calc(2rem + 287px); left: calc(10% + 62px); animation: flotar-x 5s linear infinite alternate; }
@media (min-width: 1181px) and (max-width: 1299px) { .forma--1 { left: calc(10% + 894px); } .forma--2 { left: calc(10% - 93px); } }
@media (min-width: 1500px) and (max-width: 1649px) { .forma--1 { left: calc(10% + 1113px); } .forma--2 { left: calc(10% - 102px); } }
@media (min-width: 1650px) and (max-width: 1799px) { .forma--1 { left: calc(10% + 1203px); } .forma--2 { left: calc(10% - 22px); } }
@media (max-width: 1180px) { .forma { display: none; } }

@keyframes flotar-y { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(5px); } }
@keyframes flotar-x { 0%, 100% { transform: translate(0, 0); } 50% { transform: translate(10px, 0); } 80% { transform: translate(-10px, 0); } }

/* Encabezados de sección */
.cabecera { padding-top: 15px; text-align: center; }
.cabecera__titulo { display: flex; flex-wrap: wrap; justify-content: center; margin-bottom: .5rem; font-size: 32px; font-weight: 900; }
.cabecera__texto { font-size: 16px; text-align: center; }
.cabecera--clara .cabecera__titulo, .cabecera--clara .cabecera__texto { color: var(--blanco); }
@media (max-width: 900px) {
  .cabecera { padding-top: calc(15px + 3rem); }
  .cabecera__titulo { margin: 6rem 3rem calc(.5rem + 3rem); }
  .cabecera__texto { padding: 3rem; }
  .cabecera--clara .cabecera__titulo { margin-top: 0; }
  .cabecera--clara .cabecera__texto { padding: 0; }
}

/* El botón de play se centra sobre la imagen, sea cual sea su tamaño */
.video { position: relative; padding-top: 15px; text-align: center; }
.video__foto { display: block; margin: 0 auto; border-radius: 5px; }
.video__centro { position: absolute; top: 15px; right: 0; bottom: 0; left: 0; display: flex; align-items: center; justify-content: center; pointer-events: none; }
.video__centro .video__boton { pointer-events: auto; }
.video__boton {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 140px;
  height: 140px;
  border-radius: 50%;
  background: var(--navy);
  color: var(--blanco);
  font-size: 42px;
  animation: pulso 1s linear infinite;
  transition: background-color .4s, color .4s;
}
.video__boton .ico { margin-left: 10px; }
.video__boton:hover { background: var(--dorado); color: var(--navy); }
@keyframes pulso {
  0% { box-shadow: 0 0 0 0 rgba(31, 58, 86, 1); }
  70% { box-shadow: 0 0 0 40px rgba(31, 58, 86, 0); }
  100% { box-shadow: 0 0 0 0 rgba(31, 58, 86, 0); }
}

/* Por qué ------------------------------------------------------------------ */

.ventajas { position: relative; z-index: 1; padding: 3rem 0; background: var(--blanco); }
.ventajas__rejilla { margin-top: 1rem; }
@media (max-width: 900px) { .ventajas { padding: 0 0 3rem; } }

/* Cómo funciona ------------------------------------------------------------------ */

.pasos { padding: 2rem 0 3rem; background: var(--navy); }
.pasos__rejilla { margin-top: 1rem; }
.paso { display: block; color: var(--blanco); text-align: center; cursor: pointer; }
.paso__foto {
  position: relative;
  z-index: 1;
  display: inline-block;
  width: 100%;
  max-width: 260px;
  aspect-ratio: 1;
  margin-bottom: 20px;
  overflow: hidden;
  border-radius: 50%;
  background-position: top center;
  background-size: cover;
  vertical-align: baseline;
}
.paso__foto::before, .paso__foto::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 50%;
  box-shadow: inset 100px 0 0 rgba(255, 255, 255, .01), inset 0 100px 0 rgba(255, 255, 255, .01), inset -100px 0 0 rgba(255, 255, 255, .01), inset 0 -100px 0 rgba(255, 255, 255, .01);
  transition: box-shadow .3s linear;
}
.paso__foto::after { transform: rotate(45deg); }
.paso:hover .paso__foto::after { box-shadow: inset 5px 0 0 rgba(255, 255, 255, .5), inset 0 5px 0 rgba(255, 255, 255, .5), inset -5px 0 0 rgba(255, 255, 255, .5), inset 0 -5px 0 rgba(255, 255, 255, .5); }
.paso__titulo { display: block; margin-bottom: .5rem; font-size: 25px; font-weight: 600; line-height: 1.2; }
.paso__numero { display: block; font-size: 17px; line-height: 1.5; }
@media (min-width: 992px) and (max-width: 1299px) { .paso__titulo { font-size: 20px; } }
@media (max-width: 991px) { .paso__foto { max-width: 300px; } }
@media (max-width: 767px) { .paso { margin-bottom: 30px; } }

/* Experiencia ------------------------------------------------------------------ */

.experiencia { padding: 2rem 0 3rem; }
.experiencia__lista { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px 30px; margin-top: 2rem; list-style: none; }
@media (max-width: 991px) { .experiencia__lista { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 640px) { .experiencia__lista { grid-template-columns: 1fr; } }
.apoyo { display: flex; align-items: flex-start; gap: 14px; padding: 18px 20px; border: 2px solid var(--beige); border-radius: 5px; font-size: 16px; line-height: 1.45; transition: border-color .3s; }
.apoyo:hover { border-color: var(--dorado); }
.apoyo .ico { flex: none; width: 26px; height: 26px; margin-top: -1px; color: var(--dorado); --trazo: 1.4; }

/* Comunidad gratuita ----------------------------------------------------------- */

.comunidad { padding: 0 0 5rem; }
.comunidad__caja { display: flex; align-items: center; gap: 30px; padding: 40px 50px; border-radius: 5px; background: var(--navy); color: var(--blanco); }
.comunidad__icono { display: flex; flex: none; align-items: center; justify-content: center; width: 90px; height: 90px; border: 2px solid var(--dorado); border-radius: 50%; color: var(--dorado); font-size: 44px; --escala: 1.2; --trazo: .9; }
.comunidad__texto { flex: 1; }
.comunidad__titulo { margin-bottom: .5rem; font-size: 28px; font-weight: 900; }
.comunidad__lema { font-size: 16px; line-height: 1.5; }
.comunidad__boton { flex: none; max-width: none; margin: 0; }
@media (max-width: 991px) {
  .comunidad__caja { flex-direction: column; padding: 35px 25px; text-align: center; }
}

/* Qué incluye cada seguro ---------------------------------------------------------- */

.coberturas { padding: 0 0 3rem; }
.cobertura { padding-top: 30px; }
.cobertura__titulo { display: flex; align-items: center; gap: 12px; margin-bottom: 12px; font-size: 24px; font-weight: 600; }
.cobertura__titulo .ico { flex: none; width: 34px; height: 34px; color: var(--dorado); --trazo: 1.2; }
.cobertura__intro { margin-bottom: 12px; font-size: 16px; line-height: 1.5; }
.cobertura__lista { list-style: none; }
.cobertura__lista li { position: relative; padding: 4px 0 4px 22px; font-size: 16px; line-height: 1.45; }
.cobertura__lista li::before { content: ""; position: absolute; top: 12px; left: 2px; width: 8px; height: 8px; border-radius: 50%; background: var(--dorado); }
.cobertura:target .cobertura__titulo { color: var(--dorado); }

/* Aseguradoras ------------------------------------------------------------------ */

.aseguradoras { padding: 5rem 0 6rem; text-align: center; }
.aseguradoras__titulo { margin-bottom: 25px; color: var(--navy); font-size: 16px; font-weight: 600; letter-spacing: .15em; text-transform: uppercase; }
/* Cada aseguradora es un logo (<img>) o, mientras no haya logo autorizado, su nombre (<span>).
   Ambos se ven en gris y recuperan su color al pasar el mouse. */
.aseguradoras__lista { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 30px 70px; list-style: none; }
.aseguradoras__lista li { display: flex; align-items: center; height: 50px; }
.aseguradoras__lista img { display: block; width: auto; max-width: 200px; height: 42px; object-fit: contain; filter: grayscale(1); opacity: .55; transition: filter .3s, opacity .3s; }
.aseguradoras__lista span { color: #8a8f96; font-size: 30px; font-weight: 600; letter-spacing: -.01em; transition: color .3s; }
.aseguradoras__lista li:hover img { filter: none; opacity: 1; }
.aseguradoras__lista li:hover span { color: var(--navy); }
.aseguradoras__nota { margin-top: 22px; color: var(--navy); font-size: 14px; opacity: .75; }
@media (max-width: 767px) {
  .aseguradoras__lista { gap: 20px 40px; }
  .aseguradoras__lista img { height: 34px; }
  .aseguradoras__lista span { font-size: 24px; }
}

/* Preguntas frecuentes (acordeón con <details>, sin JS) -------------------------------- */

.preguntas { padding: 3rem 0 4rem; }
.preguntas__lista { max-width: 900px; margin: 2rem auto 0; }
.pregunta { border-bottom: 1px solid var(--beige); }
.pregunta:first-child { border-top: 1px solid var(--beige); }
.pregunta__titulo { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 20px 4px; font-size: 19px; font-weight: 600; line-height: 1.35; list-style: none; cursor: pointer; transition: color .3s; }
.pregunta__titulo::-webkit-details-marker { display: none; }
.pregunta__titulo:hover, .pregunta[open] .pregunta__titulo { color: var(--dorado); }
.pregunta__titulo .ico { flex: none; width: 26px; height: 26px; --trazo: 1.4; transition: transform .3s; }
.pregunta[open] .pregunta__titulo .ico { transform: rotate(45deg); }
.pregunta__respuesta { padding: 0 44px 22px 4px; font-size: 16px; line-height: 1.6; }
.preguntas__accion { margin-top: 1.5rem; text-align: center; }
@media (max-width: 767px) { .pregunta__titulo { font-size: 17px; } .pregunta__respuesta { padding-right: 4px; } }

/* Compromiso ------------------------------------------------------------------ */

.compromiso { position: relative; padding: 1rem 0 6rem; background: var(--crema); }
.persona { position: absolute; z-index: 2; display: block; }
/* Se ubican desde el centro, para no chocar con el título en ningún ancho: las de arriba a los
   lados del título y las de abajo en el margen inferior, bajo las frases */
.persona--1 { top: calc(1rem + 100px); left: calc(50% + 330px); animation: flotar-y 2s ease infinite; }
.persona--2 { top: calc(1rem + 100px); right: calc(50% + 330px); animation: flotar-y 2s ease infinite; }
.persona--3 { bottom: 22px; left: calc(50% + 200px); animation: flotar-x 5s linear infinite alternate; }
.persona--4 { bottom: 22px; right: calc(50% + 200px); animation: flotar-x 5s linear infinite alternate; }
@media (min-width: 1181px) { .compromiso { padding-bottom: 140px; } }
@media (max-width: 1180px) { .persona { display: none; } }

.compromiso__icono {
  width: 128px;
  height: 90px;
  margin: 0 auto 15px;
  padding: 5px;
  color: var(--navy);
  font-size: 75px;
  line-height: 87px;
  transition: color .5s;
}
.compromiso__icono .ico { vertical-align: middle; }
.compromiso__icono:hover { color: var(--dorado); }
.compromiso__cabecera .cabecera__titulo { display: block; }
.compromiso__pilares { margin-bottom: 0; }
@media (min-width: 992px) and (max-width: 1180px) { .compromiso__icono { width: 67px; } }
@media (max-width: 850px) {
  .compromiso__icono { display: flex; align-items: center; justify-content: center; margin-bottom: 0; line-height: 100px; }
}
@media (max-width: 900px) { .compromiso__pilares { margin-bottom: -2rem; } }

.frase {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-height: 169px;
  border: 2px solid var(--beige);
  border-radius: 5px;
  text-align: center;
}
.frase__texto {
  position: relative;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  margin-bottom: -102px;
  padding: 2.2em;
  font-size: 16px;
  line-height: 1.7em;
}
.frase__comillas { display: block; width: 100%; height: 96px; fill: currentColor; stroke: none; opacity: .1; transform: translate(3px, -87px) scale(1.3); }
.frase__firma { margin-bottom: .5rem; font-size: 19px; font-weight: 700; line-height: 1.2; text-align: center; }

/* Pie de página ------------------------------------------------------------------ */

.pie { position: relative; margin-top: 4px; padding: 3px 0; background: var(--navy); color: var(--navy); font-size: 1.4rem; line-height: 1.5; }
@media (max-width: 1180px) { .pie { display: inline-flex; width: 100%; } }
@media (max-width: 900px) { .pie { margin-top: 0; text-align: center; } }

.pie__marca, .pie__cta, .pie__datos, .pie__base { width: 100%; padding: 15px 15px 0; }
@media (min-width: 1200px) {
  .pie__marca { flex: 0 0 16.6667%; max-width: 16.6667%; }
  .pie__cta { flex: 0 0 58.3333%; max-width: 58.3333%; }
  .pie__datos { flex: 0 0 25%; max-width: 25%; }
}

.pie__logo { width: 100%; margin-bottom: 16px; text-align: center; }
.pie__logo img { max-height: 74px; margin: 1px 0 -8px; }
@media (max-width: 1180px) { .pie__logo { display: inline-block; } }
@media (max-width: 991px) { .pie__logo { width: 70%; } }
.pie__eslogan { color: var(--blanco); font-size: 16px; line-height: 1.5; text-align: center; }
.pie__social { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; margin: 1rem 0 1rem; font-size: 2rem; line-height: 1.5; }
.pie__social li { margin-right: 10px; }
.pie__social a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 53px;
  height: 49px;
  border-radius: 5px;
  background: var(--navy);
  color: var(--blanco);
  font-size: 40px;
  vertical-align: top;
}
.pie__social a:hover { background: var(--dorado); color: var(--navy); }
@media (min-width: 1181px) and (max-width: 1299px) { .pie__social li { margin-right: 5px; } }
@media (min-width: 1181px) { .pie__social li { height: 50px; } }
@media (max-width: 850px) { .pie__social { margin-bottom: 0; } }

.pie__titulo { margin: 10px 0 15px; color: var(--blanco); font-size: 26px; font-weight: 900; text-align: center; }
@media (max-width: 1180px) { .pie__titulo { margin-top: 50px; } }
.pie__texto { margin-bottom: 0; color: var(--blanco); font-size: 16px; line-height: 1.5; text-align: center; }
.pie__boton { text-align: center; }

.pie__datos { padding-top: 10px; }
.dato { display: flex; flex-wrap: wrap; margin-top: -5px; padding: 15px 0 0; cursor: default; }
a.dato { cursor: pointer; }
.pie__datos > .dato:first-child { margin-top: 0; }
.dato__icono { flex: 0 0 25%; max-width: 25%; padding: 7px 15px 0; color: var(--blanco); font-size: 60px; line-height: 0; }
.dato__icono .ico { position: relative; left: -.15em; display: block; }
.dato__cuerpo { flex: 0 0 75%; max-width: 75%; padding: 7px 15px 0; }
.dato__etiqueta { display: block; margin-bottom: .5rem; color: var(--blanco); font-size: 16px; line-height: 1.2; }
.dato__valor { display: block; margin-bottom: .5rem; color: var(--blanco); font-size: 21px; font-weight: 900; line-height: 1.2; }
@media (max-width: 1180px) { .dato { justify-content: center; text-align: center; } }
@media (min-width: 992px) and (max-width: 1180px) {
  .dato { width: max-content; max-width: 100%; margin-left: auto; margin-right: auto; }
  .dato__icono { font-size: 70px; }
  .dato__icono .ico { margin-right: -14px; }
}
@media (max-width: 991px) {
  .dato__icono, .dato__cuerpo { flex: 0 0 100%; max-width: 100%; padding: 15px 15px 0; }
  .dato__icono .ico { left: 0; margin: 0 auto; }
}
@media (max-width: 900px) { .dato__etiqueta { text-align: center; } }

.pie__copy {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  width: 100%;
  padding: 10px;
  color: var(--blanco);
  font-size: 16px;
  line-height: 1.5;
  text-align: center;
}
.pie__legal { display: flex; flex-wrap: wrap; justify-content: center; gap: 4px 22px; padding: 0 10px 18px; color: var(--blanco); font-size: 13px; line-height: 1.5; list-style: none; opacity: .8; }
.pie__copy::before, .pie__copy::after { content: ""; flex: 1 1 0%; height: 1px; background: var(--blanco); }
@media (max-width: 1180px) { .pie__copy { margin-top: 40px; } }

/* Encima del botón de Emma y centrado con él */
.arriba {
  position: fixed;
  right: 27px;
  bottom: 96px;
  z-index: 5;
  display: none;
  align-items: center;
  justify-content: center;
  width: 50px;
  height: 58px;
  padding: 10px;
  border-radius: 5px;
  background: var(--navy);
  color: var(--blanco);
  font-size: 30px;
}
.arriba.visible { display: flex; }
.arriba:hover { background: var(--dorado); color: var(--navy); }
.arriba { --escala: 1.9; --trazo: 1.4; }
.arriba .ico { margin-top: -6px; }
@media (max-width: 767px) { .arriba { right: 15px; bottom: 80px; } }

/* Emma, asistente virtual ------------------------------------------------------------------- */
/* Medidas en px: la fuente raíz baja hasta 4.8px en móvil y el chat debe leerse igual en todos
   los tamaños. Queda sobre el panel lateral (11) y debajo del cursor (9999) y el cargador. */

.emma { position: fixed; right: 20px; bottom: 20px; z-index: 20; font-size: 15px; line-height: 1.45; }
.emma__oculto { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.emma__saludo[hidden], .emma__ventana[hidden] { display: none; }

.emma__lanzador {
  display: block;
  width: 64px;
  height: 64px;
  border-radius: 50%;
  box-shadow: 0 6px 22px rgba(31, 58, 86, .35);
  transition: transform .3s ease;
}
.emma__lanzador:hover { transform: scale(1.06); }
.emma__lanzador img { display: block; width: 100%; height: 100%; }

/* Burbuja del saludo, a la izquierda del botón */
.emma__saludo {
  position: absolute;
  right: 80px;
  bottom: 6px;
  width: 260px;
  border-radius: 14px 14px 4px 14px;
  background: var(--blanco);
  box-shadow: 0 8px 30px rgba(31, 58, 86, .22);
  animation: subir .4s ease;
}
.emma__saludo-texto { display: block; width: 100%; padding: 14px 36px 14px 16px; color: var(--navy); text-align: left; }
.emma__saludo-cerrar {
  position: absolute;
  top: 6px;
  right: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  color: var(--navy);
  font-size: 16px;
  --trazo: 1.6;
}
.emma__saludo-cerrar:hover { background: var(--beige); }

.emma__ventana {
  position: absolute;
  right: 0;
  bottom: 80px;
  display: flex;
  flex-direction: column;
  width: 380px;
  height: min(600px, calc(100vh - 120px));
  border-radius: 16px;
  background: var(--blanco);
  box-shadow: 0 12px 50px rgba(31, 58, 86, .3);
  overflow: hidden;
  animation: subir .3s ease;
}

.emma__cabecera { display: flex; align-items: center; gap: 12px; padding: 14px 12px 14px 16px; background: var(--navy); color: var(--blanco); }
.emma__avatar { width: 44px; height: 44px; flex: none; }
.emma__identidad { flex: 1; min-width: 0; }
.emma__nombre { font-size: 18px; font-weight: 600; line-height: 1.2; }
.emma__rol { font-size: 13px; opacity: .8; }
.emma__karen, .emma__cerrar {
  display: flex;
  flex: none;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  color: var(--blanco);
  font-size: 22px;
  transition: background .3s, color .3s;
  --trazo: 1.4;
}
.emma__karen:hover, .emma__cerrar:hover { background: var(--dorado); color: var(--navy); }

.emma__mensajes { display: flex; flex: 1; flex-direction: column; gap: 10px; padding: 16px; background: var(--crema); overflow-y: auto; overscroll-behavior: contain; }
.emma__mensaje { max-width: 86%; padding: 10px 14px; border-radius: 16px; overflow-wrap: anywhere; }
.emma__mensaje p + p, .emma__mensaje p + ul, .emma__mensaje ul + p { margin-top: 6px; }
.emma__mensaje ul { padding-left: 18px; list-style: disc; }
.emma__mensaje li + li { margin-top: 3px; }
.emma__mensaje--emma { align-self: flex-start; border-bottom-left-radius: 4px; background: var(--blanco); color: var(--navy); }
.emma__mensaje--usuario { align-self: flex-end; border-bottom-right-radius: 4px; background: var(--navy); color: var(--blanco); white-space: pre-wrap; }
.emma__whatsapp { display: inline-block; margin-top: 8px; padding: 6px 14px; border-radius: 20px; background: var(--navy); color: var(--blanco); font-size: 14px; }
.emma__whatsapp:hover { background: var(--dorado); color: var(--navy); }

.emma__sugerencias { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 2px; }
.emma__sugerencias button, .emma__sugerencias a {
  padding: 7px 13px;
  border: 1px solid var(--navy);
  border-radius: 20px;
  background: var(--blanco);
  color: var(--navy);
  font-size: 14px;
  line-height: 1.3;
  transition: background .3s, border-color .3s;
}
.emma__sugerencias button:hover, .emma__sugerencias a:hover { border-color: var(--dorado); background: var(--dorado); }

/* Tres puntos mientras Emma responde */
.emma__escribiendo { display: flex; gap: 5px; padding: 14px 16px; }
.emma__escribiendo span { width: 7px; height: 7px; border-radius: 50%; background: var(--navy); opacity: .3; animation: emma-punto 1.2s infinite; }
.emma__escribiendo span:nth-child(2) { animation-delay: .2s; }
.emma__escribiendo span:nth-child(3) { animation-delay: .4s; }
@keyframes emma-punto { 30% { opacity: 1; transform: translateY(-3px); } 60% { opacity: .3; transform: none; } }

.emma__formulario { display: flex; align-items: flex-end; gap: 8px; padding: 10px 12px 8px; border-top: 1px solid var(--beige); }
/* 16px: con menos, iOS hace zoom al escribir */
.emma__texto {
  flex: 1;
  min-width: 0;
  max-height: 110px;
  padding: 9px 14px;
  border: 1px solid var(--beige);
  border-radius: 20px;
  color: var(--navy);
  font: inherit;
  font-size: 16px;
  line-height: 1.4;
  resize: none;
}
.emma__texto:focus { border-color: var(--dorado); outline: none; }
.emma__enviar {
  display: flex;
  flex: none;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: var(--navy);
  color: var(--blanco);
  font-size: 20px;
  transition: background .3s, color .3s, opacity .3s;
  --trazo: 1.5;
}
.emma__enviar:hover { background: var(--dorado); color: var(--navy); }
.emma__formulario--esperando .emma__enviar { opacity: .4; pointer-events: none; }

.emma__aviso { padding: 0 16px 10px; color: #5d6d7e; font-size: 12px; line-height: 1.4; }
.emma__aviso a { text-decoration: underline; }

/* Móvil: el chat ocupa toda la pantalla y el botón se esconde mientras está abierto */
@media (max-width: 767px) {
  .emma { right: 12px; bottom: 12px; }
  .emma__lanzador { width: 56px; height: 56px; }
  .emma__saludo { right: 68px; bottom: 2px; width: min(260px, calc(100vw - 96px)); }
  /* top y height los ajusta asistente.js al área visible sobre el teclado (visualViewport) */
  .emma__ventana { position: fixed; top: 0; left: 0; width: 100%; height: 100%; height: 100dvh; border-radius: 0; }
  .emma--abierta .emma__lanzador { display: none; }
  /* La página de fondo no se desplaza mientras el chat está abierto */
  .emma-abierta, .emma-abierta body { overflow: hidden; }
}

/* Animaciones de aparición ------------------------------------------------------------------ */

.js .aparecer { visibility: hidden; }
.js .aparecer.visto { visibility: visible; animation-duration: 1s; animation-fill-mode: both; }
.visto[data-anim="fade"] { animation-name: aparecer-fade; }
.visto[data-anim="fade-up"] { animation-name: aparecer-arriba; }
.visto[data-anim="fade-left"] { animation-name: aparecer-izq; }
.visto[data-anim="fade-right"] { animation-name: aparecer-der; }
.visto[data-anim="zoom"] { animation-name: aparecer-zoom; }
.visto[data-anim="flip-x"] { animation-name: aparecer-giro-x; backface-visibility: visible; }
.visto[data-anim="flip-y"] { animation-name: aparecer-giro-y; backface-visibility: visible; }

@keyframes aparecer-fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes aparecer-arriba { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: none; } }
@keyframes aparecer-izq { from { opacity: 0; transform: translateX(-20px); } to { opacity: 1; transform: none; } }
@keyframes aparecer-der { from { opacity: 0; transform: translateX(20px); } to { opacity: 1; transform: none; } }
@keyframes aparecer-zoom { from { opacity: 0; transform: scale(.3); } 50% { opacity: 1; } }
@keyframes aparecer-giro-x {
  from { opacity: 0; transform: perspective(400px) rotateX(90deg); animation-timing-function: ease-in; }
  40% { transform: perspective(400px) rotateX(-20deg); animation-timing-function: ease-in; }
  60% { opacity: 1; transform: perspective(400px) rotateX(10deg); }
  80% { transform: perspective(400px) rotateX(-5deg); }
  to { transform: perspective(400px); }
}
@keyframes aparecer-giro-y {
  from { opacity: 0; transform: perspective(400px) rotateY(90deg); animation-timing-function: ease-in; }
  40% { transform: perspective(400px) rotateY(-20deg); animation-timing-function: ease-in; }
  60% { opacity: 1; transform: perspective(400px) rotateY(10deg); }
  80% { transform: perspective(400px) rotateY(-5deg); }
  to { transform: perspective(400px); }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .js .aparecer { visibility: visible; }
  .visto { animation: none !important; }
  .emma__saludo, .emma__ventana, .emma__escribiendo span { animation: none; }
}
