/* =========================================================
   ELEVA MARKETING — CSS OPTIMIZADO Y CORREGIDO
   ========================================================= */

/* ------------------------------
   1) VARIABLES
   ------------------------------ */
:root{
  --c1:#206184; --c2:#5BA1B8; --c3:#5BB8B8; --c4:#3E9699;
  --bg:#0b1220; --text:#e5eef7; --muted:#9fb3c8;

  --float-speed:4.5s; --drift-speed:9s; --grid-speed:40s;
  --orb-float-1:14s; --orb-float-2:12s; --orb-float-3:16s;

  --grad-hero:
    radial-gradient(1200px 600px at 10% 10%, #5BB8B822, transparent 60%),
    radial-gradient(1000px 500px at 90% 20%, #3E969922, transparent 60%),
    linear-gradient(140deg, #0d1b2a, #0a1830 40%, #0b132b 75%);
  --grad-main: linear-gradient(135deg, var(--c1), var(--c2), var(--c3));

  /* Altura dinámica del nav */
  --nav-h: 72px;
}

/* ------------------------------
   2) RESET + TIPOGRAFÍA
   ------------------------------ */
*{box-sizing:border-box}
html{scroll-behavior:smooth; max-width:100%; overflow-x:hidden; scroll-padding-top: var(--nav-h);}
body{
  margin:0;color:var(--text);background:var(--bg);
  font-family:Montserrat,system-ui,-apple-system,Segoe UI,Roboto,sans-serif;
  max-width:100%; overflow-x:hidden;
}
body.has-fixed-nav{ padding-top: var(--nav-h); }
body.nav-open{overflow:hidden}

h1,h2,h3,h4,h5{color:#eaf6ff;font-family:"Archivo Black",Montserrat,sans-serif}
a{color:var(--c3);text-decoration:none}

/* Utilidad oculta accesible */
.sr-only {
  position:absolute; width:1px; height:1px; padding:0; margin:-1px;
  overflow:hidden; clip:rect(0,0,0,0); white-space:nowrap; border:0;
}

/* ------------------------------
   3) LAYOUT
   ------------------------------ */
.container{max-width:1200px;margin:0 auto;padding:0 5vw}
.section{padding:56px 0}
.section--muted{background:#0c1426}
.section__head{text-align:center;margin-bottom:28px}
.section__sub{color:var(--muted)}

/* =========================================================
   NAVEGACIÓN OPTIMIZADA Y ESTABLE
   ========================================================= */
.cabecera{
  position:fixed;top:0;left:0;right:0;z-index:1000;width:100%;
  background:#0b1220cc; backdrop-filter:blur(10px);
  border-bottom:1px solid #1f2b45;
}

.navegacion .nav__inner{
  height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 max(16px, env(safe-area-inset-left)) 0 max(16px, env(safe-area-inset-right));
  width: 100%;
  gap: 16px;
}

/* BRAND - Logo principal */
.brand{
  display: flex;
  align-items: center;
  gap: 10px;
  color: #eaf6ff;
  flex: 0 0 auto;
  min-width: 0;
}

.brand__img {
  height: 44px;
  width: auto;
  max-width: 180px;
  object-fit: contain;
}

.brand__icon{
  width: 44px;
  height: 44px;
  border-radius: 10px;
  border: 1px solid #1f2b45;
  background: #0b1220;
  object-fit: contain;
  flex: 0 0 44px;
}

.logo{
  font-weight: 900;
  font-size: 22px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 200px;
}

.logo span{
  background: var(--grad-main);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* MENÚ DESKTOP */
.menu{
  display: flex;
  gap: 24px;
  list-style: none;
  margin: 0;
  padding: 0;
  flex: 0 0 auto;
}

.menu a{
  position: relative;
  padding: 10px 12px;
  border-radius: 10px;
  color: #cfe4ff;
  transition: all 0.3s ease;
}

.menu a::after {
  content: '';
  position: absolute;
  bottom: 4px;
  left: 50%;
  width: 0;
  height: 2px;
  background: linear-gradient(135deg, var(--c2), var(--c3));
  transform: translateX(-50%);
  transition: width 0.3s ease;
}

.menu a:hover{
  background: #0e1a2e;
  color: #eaf6ff;
}

.menu a:hover::after {
  width: calc(100% - 24px);
}

/* CONTROLES - Switch idioma */
.switches{
  display: flex;
  align-items: center;
  gap: 12px;
  flex: 0 0 auto;
}

.lang{
  height: 28px;
  position: relative;
  display: inline-flex;
  align-items: center;
}

.lang input{
  appearance: none;
  width: 0;
  height: 0;
  position: absolute;
}

.lang__slider{
  position: relative;
  width: 92px;
  height: 28px;
  border-radius: 999px;
  border: 1px solid #21304a;
  background: #0f1a2b;
  display: block;
  overflow: hidden;
  cursor: pointer;
  user-select: none;
  box-shadow: inset 0 0 0 1px #122139;
}

.lang__es,.lang__en{
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 50%;
  text-align: center;
  pointer-events: none;
  font-weight: 800;
  font-size: 11px;
  letter-spacing: .3px;
  color: #8fa6c4;
}

.lang__es{left: 0}
.lang__en{right: 0}

.lang__slider::after{
  content: "";
  position: absolute;
  top: 50%;
  left: 2px;
  width: 46px;
  height: 24px;
  transform: translateY(-50%);
  border-radius: 999px;
  background: #dfeaf7;
  box-shadow: 0 2px 8px rgba(0,0,0,.25);
  transition: transform .2s ease;
}

#langToggle:checked + .lang__slider::after{
  transform: translate(46px,-50%);
}

#langToggle:not(:checked) + .lang__slider .lang__es{
  color: #e6f1ff;
  opacity: 1;
}

#langToggle:not(:checked) + .lang__slider .lang__en{
  opacity: .35;
}

#langToggle:checked + .lang__slider .lang__en{
  color: #e6f1ff;
  opacity: 1;
}

#langToggle:checked + .lang__slider .lang__es{
  opacity: .35;
}
/* --- Mejora de contraste del switch ES/EN --- */

/* 1) Asegura que las etiquetas queden por ENCIMA del knob */
.lang__es,
.lang__en { 
  z-index: 2;              /* texto sobre el knob */
  font-weight: 900; 
}

.lang__slider::after { 
  z-index: 1;              /* knob por debajo del texto */
}

/* 2) Resalta el idioma ACTIVO con texto oscuro (contraste sobre knob claro) */
#langToggle:not(:checked) + .lang__slider .lang__es,
#langToggle:checked       + .lang__slider .lang__en {
  color: #0c2340;          /* oscuro, legible sobre el knob blanco */
  opacity: 1;
  text-shadow: 0 0 1px rgba(0,0,0,.18); /* sutil mejora de legibilidad */
}

/* 3) Atenúa el idioma INACTIVO */
#langToggle:not(:checked) + .lang__slider .lang__en,
#langToggle:checked       + .lang__slider .lang__es {
  color: #8fa6c4;
  opacity: .45;
}


/* BOTÓN HAMBURGUESA */
.nav__toggle{
  display: none;
  background: none;
  border: none;
  font-size: 24px;
  color: #eaf6ff;
  width: 48px;
  height: 48px;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  flex: 0 0 auto;
}

.nav__backdrop{display: none !important}

/* =========================================================
   HERO
   ========================================================= */
.hero{
  min-height: 92vh;
  display: grid;
  place-items: center;
  position: relative;
  overflow: hidden;
  padding: 110px 0 72px;
  background: var(--grad-hero);
}

.hero__bg .orb{
  position: absolute;
  filter: blur(6px);
  opacity: .7;
  mix-blend-mode: screen;
}

.orb--1{
  width: 480px;
  height: 480px;
  border-radius: 50%;
  background: radial-gradient(circle at 30% 30%, #5BB8B8, #206184 60%, transparent);
  top: -120px;
  left: -120px;
  animation: float var(--orb-float-1) ease-in-out infinite;
}

.orb--2{
  width: 360px;
  height: 360px;
  border-radius: 50%;
  background: radial-gradient(circle at 60% 40%, #3E9699, #5BA1B8 60%, transparent);
  top: 10%;
  right: -120px;
  animation: float var(--orb-float-2) ease-in-out infinite reverse;
}

.orb--3{
  width: 260px;
  height: 260px;
  border-radius: 50%;
  background: radial-gradient(circle at 40% 60%, #5BA1B8, #5BB8B8 60%, transparent);
  bottom: -80px;
  left: 55%;
  animation: float var(--orb-float-3) ease-in-out infinite;
}

.gridlines{
  position: absolute;
  inset: -10% -10%;
  background-image: 
    linear-gradient(#ffffff10 1px, transparent 1px),
    linear-gradient(90deg,#ffffff10 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: radial-gradient(80% 60% at 50% 20%, #000 60%, transparent 100%);
  animation: gridMove var(--grid-speed) linear infinite;
}

.hero__inner{
  max-width: 820px;
  text-align: center;
  padding: 0 4vw;
}

.hero__title{
  font-size: clamp(36px,6vw,64px);
  line-height: 1.06;
  margin: 0 0 16px;
}

.text-gradient{
  background: linear-gradient(45deg,#e6f7ff,#bfeaf5);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero__desc{
  font-size: 18px;
  color: #cfe4ff;
  margin: 0 0 28px;
}

/* Botones */
.btn{
  display: inline-flex;
  align-items: center;
  gap: 10px;
  justify-content: center;
  padding: 14px 22px;
  border-radius: 16px;
  font-weight: 800;
  transition: transform .2s, box-shadow .2s;
}

.btn--primary{
  background: linear-gradient(135deg,#eaf6ff,#cfe4ff);
  color: #0c2340;
  box-shadow: 0 10px 30px #1b2a4122;
}

.btn--primary:hover{
  transform: translateY(-3px);
  box-shadow: 0 14px 36px #1b2a4140;
}

.btn--full{width: 100%}

.magnet{
  position: relative;
  isolation: isolate;
}

.magnet::after{
  content: "";
  position: absolute;
  inset: -2px;
  border-radius: 18px;
  background: radial-gradient(120px 40px at var(--mx,50%) 120%, #ffffff55, transparent 60%);
  opacity: .0;
  transition: opacity .2s;
  z-index: -1;
}

.magnet:hover::after{opacity: .6}

/* =========================================================
   CARDS SERVICIOS
   ========================================================= */
.grid{display: grid;gap: 24px}
.cards{grid-template-columns: repeat(auto-fit,minmax(280px,1fr))}

.card{
  position: relative;
  background: #0c1426;
  border: 1px solid #1f2b45;
  border-radius: 16px;
  padding: 28px;
  box-shadow: 0 10px 30px #00000020;
  transform-style: preserve-3d;
  transition: transform .25s, box-shadow .25s, border-color .25s, background .25s;
  overflow: hidden;
}

.card .card__icon{
  width: 78px;
  height: 78px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  background: var(--grad-main);
  color: #fff;
  font-size: 30px;
  margin-bottom: 12px;
  box-shadow: 0 8px 24px #0ea5b530;
  transition: transform .3s;
}

.aurora::before{
  content: "";
  position: absolute;
  inset: -1px;
  border-radius: inherit;
  padding: 1px;
  background: conic-gradient(from 0deg, #5BA1B8, #5BB8B8, #3E9699, #206184, #5BA1B8);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  animation: spin 6s linear infinite;
}

.card__shine{
  position: absolute;
  inset: -1px;
  border-radius: inherit;
  background: linear-gradient(120deg, transparent 40%, #ffffff20 50%, transparent 60%);
  transform: translateX(-120%);
  transition: transform .7s ease;
}

.spark, .spark::after{
  position: absolute;
  display: block;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: radial-gradient(circle, #fff 0 30%, transparent 60%);
  opacity: .0;
  filter: blur(.5px);
}

.spark{top: 12%; left: 10%}
.spark--b{bottom: 12%; right: 10%}

.card:hover .spark{animation: spark 1.1s ease both}
.card:hover .spark--b{animation: spark 1.1s .15s ease both}

.card:hover{
  transform: translateY(-10px) rotateX(6deg) rotateY(-4deg);
  box-shadow: 0 22px 48px #00000045;
  border-color: #2a395d;
  background: #0c1628;
}

.card:hover .card__icon{
  transform: translateZ(30px) scale(1.06) rotate(-3deg);
}

.card:hover .card__shine{
  transform: translateX(120%);
}

/* =========================================================
   ACERCA
   ========================================================= */
.about .about__wrap{
  display: grid;
  grid-template-columns: 1fr;
  justify-items: center;
  gap: 48px;
  align-items: center;
}
/* La caja de texto queda centrada, sin cambiar tipografías/colores */
.about .about__text{
  width: min(900px, 100%);
  margin-inline: auto;          /* centra horizontalmente la caja */
}

/* El título y su subrayado quedan centrados */
.about .about__text h2{
  display: block;                /* sobrescribe el inline-block global */
  text-align: center;
  width: fit-content;            /* el subrayado se ajusta al texto */
  margin-inline: auto;
}

.about__desc{color: var(--muted)}

.benefits{
  list-style: none;
  padding: 0;
  margin: 20px 0 0;
  display: grid;
  gap: 10px;
}

.benefits li{
  display: flex;
  align-items: center;
  gap: 10px;
}

/* ===================== VIDEO SECTION ===================== */
.video-section {
  background: #0c1426;
  padding: 60px 0;
  text-align: center;
}

.video-wrapper {
  position: relative;
  max-width: 900px;
  margin: 0 auto;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.4);
}

.promo-video {
  width: 100%;
  height: auto;
  display: block;
  border: none;
}


/* =========================================================
   CONTACTO
   ========================================================= */
.contact{
  grid-template-columns: 1fr .9fr;
  align-items: start;
  gap: 40px;
}

.form{
  display: grid;
  gap: 14px;
  max-width: 700px;
}

.group{display: grid;gap: 8px}

.input{
  padding: 12px 14px;
  border: 2px solid #1f2b45;
  background: #0c1426;
  color: #eaf6ff;
  border-radius: 12px;
  font: inherit;
  width: 100%;
}

.input:focus{
  outline: none;
  border-color: #5BA1B8;
  box-shadow: 0 0 0 3px #5BA1B830;
}

.form__msg{margin-top: 6px;font-weight: 700}

.contact__info{
  background: #0c1426;
  border: 1px solid #1f2b45;
  border-radius: 16px;
  padding: 24px;
}

.contact__title{
  font-size: clamp(24px,3.2vw,32px);
  margin: 0 0 6px;
}

.contact__text{
  color: #b8c9da;
  margin: 0 0 16px;
}

.contact__follow{margin: 6px 0 8px}

.social{
  list-style: none;
  display: flex;
  gap: 14px;
  padding: 0;
  margin: 10px 0 0;
}

.social__btn{
  display: inline-flex;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  align-items: center;
  justify-content: center;
  background: #17223a;
  border: 1px solid #1f2b45;
  color: #cfe4ff;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.social__btn--lg{
  width: 58px;
  height: 58px;
  font-size: 22px;
}

.social__btn:hover{
  transform: translateY(-3px);
  box-shadow: 0 12px 28px #00000035;
}

/* Hover específico para redes sociales */
.social__btn[href*="instagram"]:hover {
  background: linear-gradient(45deg, #f09433 0%, #e6683c 25%, #dc2743 50%, #cc2366 75%, #bc1888 100%);
  color: #fff;
  transform: translateY(-3px) scale(1.05);
  box-shadow: 0 15px 35px rgba(240, 148, 51, 0.4);
  border-color: #f09433;
}

.social__btn[href*="facebook"]:hover {
  background: #1877f2;
  color: #fff;
  transform: translateY(-3px) scale(1.05);
  box-shadow: 0 15px 35px rgba(24, 119, 242, 0.4);
  border-color: #1877f2;
}

.social__btn::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: linear-gradient(45deg, transparent, rgba(255,255,255,0.1), transparent);
  transform: rotate(45deg);
  transition: all 0.6s ease;
  opacity: 0;
}

.social__btn:hover::before {
  opacity: 0.6;
  transform: translateX(100%) translateY(100%) rotate(45deg);
}

/* =========================================================
   RESULTADOS (Nuestro trabajo)
   ========================================================= */
.results__grid{
  display: grid;
  grid-template-columns: repeat(4,minmax(0,1fr));
  gap: 22px;
}

.stat{
  position: relative;
  border: 1px solid #1f2b45;
  background: #0c1426;
  border-radius: 16px;
  padding: 22px;
  overflow: hidden;
  transition: transform .25s, box-shadow .25s, border-color .25s;
  box-shadow: 0 10px 30px #00000020;
}

.stat:hover{
  transform: translateY(-6px);
  box-shadow: 0 16px 36px #00000035;
  border-color: #2a395d;
}

.stat__icon{
  width: 56px;
  height: 56px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  background: var(--grad-main);
  color: #fff;
  font-size: 22px;
  margin-bottom: 10px;
  box-shadow: 0 8px 22px #0ea5b530;
}

.stat__label{
  margin: 0 0 6px;
  font-size: 16px;
  color: #d7e7f8;
}

.stat__num{
  font-size: 40px;
  font-weight: 900;
  line-height: 1;
}

/* =========================================================
   REVEAL
   ========================================================= */
.reveal{
  opacity: 0;
  transform: translateY(16px) scale(.98);
  filter: blur(3px);
  transition: opacity .6s ease, transform .6s ease, filter .6s ease;
}

.reveal.show{
  opacity: 1;
  transform: translateY(0) scale(1);
  filter: blur(0);
}

/* =========================================================
   ICONOS FLOTANTES
   ========================================================= */
.float{
  position: absolute;
  color: #ffffff25;
  font-size: 40px;
  animation: float var(--float-speed) ease-in-out infinite, drift var(--drift-speed) ease-in-out infinite;
  pointer-events: none;
  z-index: 1;
  will-change: transform;
  transform: translateZ(0);
}

.float--1{top: 18%;left: 8%}
.float--2{bottom: 22%;right: 16%;animation-delay: 1.2s}
.float--3{top: 60%;left: 75%;animation-delay: 2.4s}
.float--4{top: 28%;right: 24%;font-size: 44px;animation-delay: .8s}
.float--5{bottom: 18%;left: 22%;font-size: 36px;animation-delay: 1.8s}
.float--6{top: 42%;left: 14%;font-size: 38px;animation-delay: 2.6s}
.float--7{top: 70%;right: 28%;font-size: 42px;animation-delay: 3.2s}
.float--8{top: 20%;left: 48%;font-size: 40px;animation-delay: 1.4s}
.float--9{bottom: 30%;right: 38%;font-size: 40px;animation-delay: 2.0s}

/* Capas correctas para hero */
.hero { position: relative; }
.hero__bg { position: absolute; inset: 0; z-index: 0; }
.hero__inner { position: relative; z-index: 2; }

/* =========================================================
   FOOTER
   ========================================================= */
.footer{
  position: relative;
  background: #0a1020;
  color: #cfe4ff;
  border-top: 1px solid #1f2b45;
  margin-top: 40px;
  font-size: 15px;
}

.footer__grid{
  display: grid;
  grid-template-columns: 1.1fr .6fr .6fr;
  gap: 28px;
  padding: 48px 5vw;
}

.footer__brand h4{
  margin: 0 0 8px;
  font-size: 24px;
  font-weight: 800;
}

.footer__brand h4 span{
  background: var(--grad-main);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.footer__brand p{
  color: #a9bed6;
  max-width: 420px;
  line-height: 1.4;
}

.footer__links h5,.footer__social h5{
  margin: 0 0 12px;
  font-size: 16px;
  font-weight: 700;
}

.footer__links ul{
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 8px;
}

.footer__links a{
  color: #cfe4ff;
  transition: color .2s;
}

.footer__links a:hover{color: #fff}

.footer__social .icons{
  display: flex;
  gap: 12px;
}

.footer__copy{
  border-top: 1px solid #16203a;
  background: #0a0f1e;
  text-align: center;
  padding: 14px 5vw;
  font-size: 14px;
  color: #9fb3c8;
  position: relative;
}

.footer__toTop{
  position: absolute;
  right: 100px;
  bottom: 20px;
  width: 42px;
  height: 42px;
  border-radius: 10px;
  background: #17223a;
  border: 1px solid #1f2b45;
  display: grid;
  place-items: center;
  color: #cfe4ff;
  font-size: 16px;
  transition: background .2s, transform .2s;
}

.footer__toTop:hover{
  background: var(--c1);
  transform: translateY(-3px);
  color: #fff;
}

/* =========================================================
   WHATSAPP FAB
   ========================================================= */
.whatsapp-fab{
  position: fixed;
  right: max(16px, env(safe-area-inset-right));
  bottom: max(16px, env(safe-area-inset-bottom));
  width: 62px;
  height: 62px;
  border-radius: 999px;
  color: #fff;
  background: radial-gradient(120% 120% at 30% 20%, #35ea7c 0%, #25D366 60%, #1ebe57 100%);
  box-shadow: 0 12px 28px rgba(0,0,0,.28), inset 0 -4px 10px rgba(0,0,0,.15);
  display: grid;
  place-items: center;
  z-index: 1200;
  text-decoration: none;
  isolation: isolate;
  transition: transform .18s ease, box-shadow .18s ease, filter .18s ease;
  animation: wa-bob 3.6s ease-in-out infinite;
}

.whatsapp-fab:hover{
  transform: translateY(-3px);
  filter: saturate(1.1);
}

.whatsapp-fab:active{transform: translateY(0)}

.wa-ico{width: 28px; height: 28px}

.whatsapp-fab::before,
.whatsapp-fab::after{
  content: "";
  position: absolute;
  inset: -6px;
  border-radius: inherit;
  border: 2px solid currentColor;
  opacity: 0;
  transform: scale(0.7);
  animation: wa-pulse 2.4s ease-out infinite;
}

.whatsapp-fab::before{
  color: var(--c2);
  animation-delay: 0s;
}

.whatsapp-fab::after{
  color: var(--c3);
  animation-delay: 1.2s;
}

.wa-tooltip{
  position: absolute;
  right: 74px;
  bottom: 50%;
  transform: translateY(50%) scale(.92);
  transform-origin: right center;
  background: #0b1220;
  color: #eaf6ff;
  border: 1px solid #1f2b45;
  padding: 10px 12px;
  border-radius: 12px;
  font-size: 13px;
  white-space: nowrap;
  box-shadow: 0 8px 24px rgba(0,0,0,.28);
  opacity: 0;
  pointer-events: none;
  transition: opacity .25s ease, transform .25s ease;
}

.wa-tooltip::after{
  content: "";
  position: absolute;
  right: -6px;
  top: 50%;
  transform: translateY(-50%) rotate(45deg);
  width: 12px;
  height: 12px;
  background: #0b1220;
  border-right: 1px solid #1f2b45;
  border-bottom: 1px solid #1f2b45;
  border-radius: 2px;
}

.whatsapp-fab:hover .wa-tooltip,
.whatsapp-fab:focus-visible .wa-tooltip,
.whatsapp-fab.show-tip .wa-tooltip{
  opacity: 1;
  transform: translateY(50%) scale(1);
}

/* =========================================================
   LÍNEAS DECORATIVAS BAJO TÍTULOS H2
   ========================================================= */
.section__head h2,
.about h2,
.results h2,
h2 {
  position: relative;
  display: inline-block;
  padding-bottom: 12px;
}

.section__head h2::after,
.about h2::after,
.results h2::after,
h2::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(135deg, var(--c2), var(--c3));
  border-radius: 2px;
  box-shadow: 0 2px 8px rgba(91, 161, 184, 0.3);
  display: block;
}

.section__head {text-align: center}
.section__head h2 {text-align: center}
.about h2 {text-align: left}
h2.no-underline::after {display: none !important}

/* =========================================================
   FORMULARIO - VALIDACIÓN Y ERRORES
   ========================================================= */
.field-error {
  border-color: #ef4444 !important;
  box-shadow: 0 0 0 3px rgba(239, 68, 68, .15) !important;
}

.field-tip {
  margin-top: 6px;
  font-size: 0.9rem;
  line-height: 1.25;
  color: #ef4444;
  display: none;
}

.field-tip.is-visible { display: block; }

.btn[disabled], button[disabled] {
  opacity: .6;
  cursor: not-allowed;
}

/* =========================================================
   KEYFRAMES
   ========================================================= */
@keyframes float{
  0%,100% { transform: translateY(0) }
  50%     { transform: translateY(-32px) }
}

@keyframes drift{
  0%   { transform: translate(0,0) rotate(0deg) }
  50%  { transform: translate(20px,-20px) rotate(-14deg) }
  100% { transform: translate(0,0) rotate(0deg) }
}

@keyframes rocketFloat {
  0%, 100% { transform: translateY(0) rotate(0deg) }
  50% { transform: translateY(-15px) rotate(2deg) }
}

@keyframes rocketDrift {
  0% { transform: translate(0, 0) rotate(0deg) }
  25% { transform: translate(8px, -5px) rotate(-1deg) }
  50% { transform: translate(-6px, -8px) rotate(1deg) }
  75% { transform: translate(5px, -3px) rotate(-0.5deg) }
  100% { transform: translate(0, 0) rotate(0deg) }
}

@keyframes gridMove{
  0%{transform: translateY(0)}
  100%{transform: translateY(48px)}
}

@keyframes spin{to{transform: rotate(1turn)}}

@keyframes spark{
  0%{opacity: 0;transform: translate(0,0) scale(.5)}
  20%{opacity: .9}
  100%{opacity: 0;transform: translate(140px,-80px) scale(1.1)}
}

@keyframes wa-pulse{
  0%   { opacity: 0; transform: scale(.7) }
  20%  { opacity: .45 }
  70%  { opacity: .15 }
  100% { opacity: 0; transform: scale(1.22) }
}

@keyframes wa-bob{
  0%,100% { transform: translateY(0) }
  50%     { transform: translateY(-4px) }
}

/* =========================================================
   MEDIA QUERIES RESPONSIVE
   ========================================================= */

/* Tablets grandes */
@media (max-width: 1024px) {
  .section{padding: 48px 0}
  .section__head{margin-bottom: 22px}
  .results__grid{grid-template-columns: repeat(2,minmax(0,1fr))}
}

/* Tablets y móviles grandes */
@media (max-width: 960px) {
  /* Navegación móvil */
  .nav__toggle {display: flex}
  
  .menu {
    display: none;
    position: fixed;
    z-index: 60;
    left: max(16px, env(safe-area-inset-left));
    right: max(16px, env(safe-area-inset-right));
    top: var(--nav-h);
    background: #0a1020;
    flex-direction: column;
    gap: 8px;
    padding: 12px;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0,0,0,.18);
    width: auto;
    max-width: 100%;
    box-sizing: border-box;
  }
  
  .menu.open {display: flex}
  .menu a {display: block; padding: 12px 14px}
  
  /* Layout responsive */
  .cards{grid-template-columns: 1fr}
  .about .about__wrap{grid-template-columns: 1fr; gap: 24px}
  .contact{grid-template-columns: 1fr}
  .footer__grid{grid-template-columns: 1fr; text-align: center}
  .footer__social .icons{justify-content: center}
  .footer__toTop{
    right: 50%;
    transform: translateX(50%);
    bottom: 14px;
  }
}

/* Móviles */
@media (max-width: 640px) {
  :root {--nav-h: 60px}
  
  .navegacion .nav__inner {
    height: 60px;
    padding: 0 max(12px, env(safe-area-inset-left)) 0 max(12px, env(safe-area-inset-right));
    gap: 12px;
  }
  
  .brand__img {height: 38px; max-width: 140px}
  .brand__icon {width: 38px; height: 38px}
  .logo {font-size: 18px; max-width: 160px}
  
  .lang {height: 26px}
  .lang__slider {width: 80px; height: 26px}
  .lang__slider::after {width: 40px; height: 22px}
  #langToggle:checked + .lang__slider::after {transform: translate(40px,-50%)}
  
  .nav__toggle {width: 42px; height: 42px; font-size: 20px}
  
  .section{padding: 32px 0}
  .section__head{margin-bottom: 18px}
  
  .hero{
    display: block;
    min-height: auto;
    padding: 84px 0 40px;
    background-position: center top;
  }
  
  .hero__inner{
    max-width: 760px;
    margin: 0 auto;
    padding: 0 5vw;
  }
  
  .hero__title{
    font-size: clamp(28px,8vw,40px);
    line-height: 1.08;
    margin-top: 0;
  }
  
  .hero__desc{font-size: 16px}
  
  .results__grid{grid-template-columns: 1fr}
  .stat__num{font-size: 36px}
  
  .section__head h2::after,
  .about h2::after,
  .results h2::after,
  h2::after {height: 2px}
}

/* Móviles pequeños */
@media (max-width: 480px) {
  :root {--nav-h: 56px}
  
  .navegacion .nav__inner {
    height: 56px;
    padding: 0 10px;
    gap: 8px;
  }
  
  .brand__img {height: 34px; max-width: 120px}
  .brand__icon {width: 34px; height: 34px}
  .logo {font-size: 16px; max-width: 140px}
  
  .lang {height: 24px}
  .lang__slider {width: 72px; height: 24px}
  .lang__slider::after {width: 36px; height: 20px}
  #langToggle:checked + .lang__slider::after {transform: translate(36px,-50%)}
  
  .nav__toggle {width: 38px; height: 38px; font-size: 18px}
  
  .hero {padding-top: 72px}
  
  .whatsapp-fab {width: 54px; height: 54px}
  .wa-ico {width: 24px; height: 24px}
  .wa-tooltip {display: none}
}

/* Móviles muy pequeños */
@media (max-width: 380px) {
  :root {--nav-h: 52px}
  
  .navegacion .nav__inner {
    height: 52px;
    padding: 0 8px;
    gap: 6px;
  }
  
  .brand__img {height: 32px; max-width: 100px}
  .brand__icon {width: 32px; height: 32px}
  .logo {font-size: 15px; max-width: 120px}
  
  .nav__toggle {width: 36px; height: 36px; font-size: 16px}
}

/* Landscape móviles */
@media (max-width: 960px) and (orientation: landscape) and (max-height: 500px) {
  :root {--nav-h: 52px}
  
  .navegacion .nav__inner {
    height: 52px;
    padding: 0 max(12px, env(safe-area-inset-left)) 0 max(12px, env(safe-area-inset-right));
  }
  
  .brand__img {height: 32px; max-width: 120px}
}

/* =========================================================
   ACCESIBILIDAD Y OPTIMIZACIÓN
   ========================================================= */
@media (prefers-reduced-motion: reduce) {
  .whatsapp-fab,
  .whatsapp-fab::before,
  .whatsapp-fab::after,
  .about__art .art i,
  .float {
    animation: none !important;
  }
}

@media (prefers-contrast: high) {
  .lang__slider {border-width: 2px}
  .nav__toggle {border: 1px solid currentColor; border-radius: 4px}
}