/* =============================================================================
   RAFAEL SOLUCIONES ELECTRÓNICA — Design System 2026
   Dark-first · Glassmorphism · Micro-interacciones · Sin frameworks
   ============================================================================= */

/* ---------------------------------------------------------------- 1. TOKENS */
:root {
  /* Superficies */
  --bg:            #05070d;
  --bg-alt:        #080b14;
  --surface:       rgba(255, 255, 255, .035);
  --surface-2:     rgba(255, 255, 255, .06);
  --stroke:        rgba(255, 255, 255, .09);
  --stroke-strong: rgba(255, 255, 255, .16);

  /* Marca */
  --brand:      #22d3ee;
  --brand-2:    #6366f1;
  --brand-soft: rgba(34, 211, 238, .12);
  --grad:       linear-gradient(120deg, #22d3ee 0%, #38bdf8 40%, #818cf8 100%);
  --grad-soft:  linear-gradient(135deg, rgba(34,211,238,.18), rgba(99,102,241,.14));

  /* Semánticos */
  --ok:    #34d399;
  --warn:  #fbbf24;
  --danger:#fb7185;
  --info:  #38bdf8;

  /* Texto */
  --text:   #eef2f8;
  --muted:  #9aa6bd;
  --faint:  #66738c;

  /* Formas */
  --r-sm: 10px;
  --r:    16px;
  --r-lg: 22px;
  --r-xl: 30px;

  /* Sombras */
  --sh-sm: 0 4px 14px rgba(0, 0, 0, .3);
  --sh:    0 18px 40px rgba(0, 0, 0, .45);
  --sh-lg: 0 34px 80px rgba(0, 0, 0, .6);
  --glow:  0 0 0 1px rgba(34, 211, 238, .28), 0 18px 50px rgba(34, 211, 238, .18);

  /* Tipografía */
  --font:  'Inter', system-ui, -apple-system, sans-serif;
  --head:  'Space Grotesk', var(--font);
  --mono:  'JetBrains Mono', ui-monospace, monospace;

  /* Layout */
  --shell: 1240px;
  --pad:   clamp(1.1rem, 4vw, 2rem);
  --sec-y: clamp(4.5rem, 9vw, 8rem);

  /* Motion */
  --ease:  cubic-bezier(.22, 1, .36, 1);
  --ease-2:cubic-bezier(.4, 0, .2, 1);
}

/* ------------------------------------------------------------- 2. BASE */
*, *::before, *::after { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  scroll-padding-top: 92px;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.65;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

body.is-locked { overflow: hidden; }

[hidden] { display: none !important; }

/* height:auto es obligatorio desde que las <img> llevan width/height en el HTML.
   Esos atributos fijan una altura real; sin esta línea la imagen se pinta a su
   altura nativa y se ignora el aspect-ratio del CSS (la tarjeta del carrusel
   salía de 1062px de alto). Las reglas que sí definen altura propia, como
   .svc-media img { height:100% }, tienen más peso y siguen mandando. */
img { max-width: 100%; height: auto; display: block; }
a   { color: inherit; text-decoration: none; }
ul, ol { margin: 0; padding: 0; }
button, input, select, textarea { font: inherit; color: inherit; }
button { background: none; border: 0; cursor: pointer; }

h1, h2, h3, h4, h5 {
  font-family: var(--head);
  font-weight: 600;
  line-height: 1.15;
  letter-spacing: -.02em;
  margin: 0;
}

::selection { background: rgba(34, 211, 238, .3); color: #fff; }

:focus-visible {
  outline: 2px solid var(--brand);
  outline-offset: 3px;
  border-radius: 6px;
}

/* Scrollbar */
::-webkit-scrollbar { width: 11px; height: 11px; }
::-webkit-scrollbar-track { background: #04060b; }
::-webkit-scrollbar-thumb {
  background: linear-gradient(#1a4d63, #2a3560);
  border-radius: 99px;
  border: 3px solid #04060b;
}
::-webkit-scrollbar-thumb:hover { background: linear-gradient(#22d3ee, #6366f1); }

/* ---------------------------------------------------------- 3. UTILIDADES */
.shell {
  width: min(100% - (var(--pad) * 2), var(--shell));
  margin-inline: auto;
}

.grad-text {
  background: var(--grad);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.glass {
  background: linear-gradient(160deg, rgba(255,255,255,.07), rgba(255,255,255,.025));
  border: 1px solid var(--stroke);
  border-radius: var(--r-lg);
  -webkit-backdrop-filter: blur(22px) saturate(150%);
  backdrop-filter: blur(22px) saturate(150%);
  -webkit-backdrop-filter: blur(22px) saturate(150%);
}

.c-ok    { color: var(--ok); }
.c-brand { color: var(--brand); }
.c-info  { color: var(--info); }
.c-warn  { color: var(--warn); }

/* Reveal on scroll */
.reveal {
  opacity: 0;
  transform: translateY(26px);
  transition: opacity .8s var(--ease), transform .8s var(--ease);
  transition-delay: var(--rd, 0ms);
}
.reveal.in { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  * { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; }
  .reveal { opacity: 1; transform: none; }
  html { scroll-behavior: auto; }
}

/* -------------------------------------------------------------- 4. BOTONES */
.btn {
  --btn-bg: transparent;
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .55rem;
  padding: .78rem 1.5rem;
  border-radius: 999px;
  font-weight: 600;
  font-size: .93rem;
  letter-spacing: .01em;
  white-space: nowrap;
  cursor: pointer;
  overflow: hidden;
  transition: transform .35s var(--ease), box-shadow .35s var(--ease), background .3s, border-color .3s;
}
.btn i { font-size: 1.05em; }
.btn:active { transform: scale(.97); }

.btn-lg { padding: .95rem 1.85rem; font-size: 1rem; }
.btn-sm { padding: .55rem 1.1rem; font-size: .85rem; }

.btn-primary {
  background: var(--grad);
  color: #04121a;
  box-shadow: 0 12px 34px rgba(34, 211, 238, .28);
}
.btn-primary::after {
  content: '';
  position: absolute; inset: 0;
  background: linear-gradient(120deg, transparent 20%, rgba(255,255,255,.6) 50%, transparent 80%);
  transform: translateX(-130%);
  transition: transform .8s var(--ease);
}
.btn-primary:hover { transform: translateY(-3px); box-shadow: 0 18px 46px rgba(34, 211, 238, .42); }
.btn-primary:hover::after { transform: translateX(130%); }

.btn-ghost {
  background: var(--surface);
  border: 1px solid var(--stroke-strong);
  color: var(--text);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
}
.btn-ghost:hover {
  transform: translateY(-3px);
  border-color: var(--brand);
  background: var(--brand-soft);
  color: #fff;
}

.btn-wa {
  background: linear-gradient(135deg, #25d366, #12a150);
  color: #04140a;
  box-shadow: 0 12px 30px rgba(37, 211, 102, .3);
}
.btn-wa:hover { transform: translateY(-3px); box-shadow: 0 18px 42px rgba(37, 211, 102, .45); }

.link-btn {
  display: inline-flex; align-items: center; gap: .4rem;
  color: var(--brand);
  font-weight: 600; font-size: .9rem;
  transition: gap .3s var(--ease), color .3s;
}
.link-btn:hover { gap: .75rem; color: #7de8fb; }

/* Spinner */
.spinner {
  width: 15px; height: 15px;
  border: 2px solid rgba(0,0,0,.25);
  border-top-color: #04121a;
  border-radius: 50%;
  display: inline-block;
  animation: spin .7s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ----------------------------------------------------------- 5. PRELOADER */
.preloader {
  position: fixed; inset: 0; z-index: 9999;
  display: grid; place-items: center;
  background: radial-gradient(circle at 50% 40%, #0b1220, #04060b 70%);
  transition: opacity .7s var(--ease), visibility .7s;
}
.preloader.done { opacity: 0; visibility: hidden; }

.preloader-inner { text-align: center; }

.preloader-chip {
  position: relative;
  width: 96px; height: 96px;
  margin: 0 auto 1.6rem;
  display: grid; place-items: center;
}
.chip-core {
  width: 54px; height: 54px;
  display: grid; place-items: center;
  border-radius: 15px;
  background: var(--grad);
  color: #041018;
  font-size: 1.6rem;
  box-shadow: 0 0 34px rgba(34, 211, 238, .55);
  animation: chipPulse 1.7s var(--ease-2) infinite;
}
@keyframes chipPulse { 0%,100% { transform: scale(1); } 50% { transform: scale(.9); } }

.chip-ring {
  position: absolute; inset: 0;
  border: 2px solid transparent;
  border-top-color: var(--brand);
  border-right-color: var(--brand-2);
  border-radius: 50%;
  animation: spin 1.1s linear infinite;
}
.chip-pin {
  position: absolute;
  width: 6px; height: 6px;
  background: var(--brand);
  border-radius: 2px;
  animation: pinBlink 1.4s infinite;
}
.chip-pin.p1 { top: -3px;  left: 50%; margin-left: -3px; }
.chip-pin.p2 { bottom: -3px; left: 50%; margin-left: -3px; animation-delay: .35s; }
.chip-pin.p3 { left: -3px;  top: 50%; margin-top: -3px;  animation-delay: .7s; }
.chip-pin.p4 { right: -3px; top: 50%; margin-top: -3px;  animation-delay: 1.05s; }
@keyframes pinBlink { 0%,100% { opacity: .2; } 50% { opacity: 1; box-shadow: 0 0 10px var(--brand); } }

.preloader-brand {
  font-family: var(--head);
  font-size: 1.15rem;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--muted);
}
.preloader-brand span { color: var(--brand); }

.preloader-bar {
  width: 190px; height: 3px;
  margin: 1.1rem auto 0;
  background: rgba(255,255,255,.08);
  border-radius: 99px;
  overflow: hidden;
}
.preloader-bar i {
  display: block; height: 100%; width: 40%;
  background: var(--grad);
  border-radius: 99px;
  animation: loadSlide 1.2s var(--ease-2) infinite;
}
@keyframes loadSlide {
  0%   { transform: translateX(-100%); }
  100% { transform: translateX(350%); }
}

/* --------------------------------------------- 6. CURSOR GLOW / PROGRESO */
.cursor-glow {
  position: fixed;
  width: 460px; height: 460px;
  border-radius: 50%;
  pointer-events: none;
  z-index: 1;
  background: radial-gradient(circle, rgba(34,211,238,.09), transparent 62%);
  transform: translate(-50%, -50%);
  opacity: 0;
  transition: opacity .5s;
  mix-blend-mode: screen;
}
@media (hover: hover) and (min-width: 992px) { .cursor-glow.on { opacity: 1; } }

.scroll-progress {
  position: fixed; top: 0; left: 0;
  height: 3px; width: 0;
  background: var(--grad);
  z-index: 900;
  box-shadow: 0 0 14px rgba(34, 211, 238, .8);
  transition: width .1s linear;
}

/* -------------------------------------------------------------- 7. NAVBAR */
.nav {
  position: fixed; top: 0; left: 0; right: 0;
  z-index: 800;
  padding: 1rem 0;
  transition: padding .4s var(--ease);
}
/* IMPORTANTE: el fondo y el desenfoque viven en un pseudo-elemento, nunca en
   .nav. Un backdrop-filter (o filter/transform) sobre .nav crearía un bloque
   contenedor y encerraría al panel lateral —position: fixed— dentro de la
   barra, dejándolo de ~128px de alto en cuanto se hace scroll. */
.nav::before {
  content: '';
  position: absolute; inset: 0;
  z-index: -1;
  background: rgba(5, 7, 13, .82);
  -webkit-backdrop-filter: blur(20px) saturate(160%);
  backdrop-filter: blur(20px) saturate(160%);
  border-bottom: 1px solid var(--stroke);
  opacity: 0;
  transition: opacity .4s var(--ease);
}
.nav.stuck { padding: .55rem 0; }
.nav.stuck::before { opacity: 1; }

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

/* Marca */
.brand { display: inline-flex; align-items: center; gap: .7rem; }
.brand-mark {
  width: 44px; height: 44px;
  display: grid; place-items: center;
  border-radius: 14px;
  background: #fff;
  box-shadow: 0 0 0 1px var(--stroke), 0 8px 22px rgba(0,0,0,.4);
  transition: transform .4s var(--ease), box-shadow .4s;
}
.brand-mark img { width: 30px; height: 30px; object-fit: contain; }
.brand:hover .brand-mark { transform: rotate(-6deg) scale(1.06); box-shadow: var(--glow); }

.brand-copy { display: flex; flex-direction: column; line-height: 1.1; }
.brand-copy strong {
  font-family: var(--head);
  font-size: 1.25rem;
  letter-spacing: .05em;
  color: #fff;
}
.brand-copy small { font-size: .68rem; color: var(--muted); letter-spacing: .1em; text-transform: uppercase; }

/* Links */
.nav-links { display: flex; align-items: center; gap: .25rem; }

.nav-link {
  position: relative;
  display: inline-flex; align-items: center; gap: .35rem;
  padding: .55rem .85rem;
  border-radius: 999px;
  font-size: .9rem; font-weight: 500;
  color: var(--muted);
  transition: color .3s, background .3s;
}
.nav-link:hover, .nav-link.is-active { color: #fff; background: var(--surface); }
.nav-link i { font-size: .75rem; transition: transform .3s var(--ease); }

/* Sin :hover propio: .nav-cta es un .btn-primary y su regla de hover ya define
   el degradado, el brillo y la elevación. Anularlo aquí borraba el fondo. */
.nav-cta { margin-left: .5rem; }

/* Tienda: es el único enlace del nav que lleva a otra página, no a una sección.
   El borde tenue lo separa de las anclas sin llegar a competir con .nav-cta,
   que debe seguir siendo el único botón sólido de la barra. */
.nav-shop {
  margin-left: .35rem;
  border: 1px solid var(--stroke);
  color: var(--text);
  /* .nav-link solo transiciona color y background; sin esto el borde saltaría
     de golpe al pasar el ratón mientras el resto se funde. */
  transition: color .3s, background .3s, border-color .3s;
}
.nav-shop:hover {
  color: #fff;
  border-color: var(--brand);
  background: var(--brand-soft);
}
/* La regla general .nav-link i está pensada para la flecha del desplegable
   (.75rem); a ese tamaño el icono de bolsa se ve raquítico. */
.nav-shop i { font-size: .95rem; }

/* Dropdown */
.nav-drop { position: relative; }
.nav-drop-menu {
  position: absolute; top: calc(100% + 12px); left: 50%;
  transform: translateX(-50%) translateY(10px);
  min-width: 290px;
  padding: .5rem;
  background: rgba(10, 14, 24, .96);
  border: 1px solid var(--stroke);
  border-radius: var(--r);
  box-shadow: var(--sh);
  -webkit-backdrop-filter: blur(24px);
  backdrop-filter: blur(24px);
  opacity: 0; visibility: hidden;
  transition: all .32s var(--ease);
}
.nav-drop.open .nav-drop-menu { opacity: 1; visibility: visible; transform: translateX(-50%) translateY(0); }
.nav-drop.open .nav-drop-btn i { transform: rotate(180deg); }

.nav-drop-menu a {
  display: flex; align-items: center; gap: .8rem;
  padding: .65rem .8rem;
  border-radius: var(--r-sm);
  color: var(--muted);
  transition: background .25s, color .25s, transform .25s var(--ease);
}
.nav-drop-menu a:hover { background: var(--surface-2); color: #fff; transform: translateX(4px); }
.nav-drop-menu a > i {
  flex: none;
  width: 34px; height: 34px;
  display: grid; place-items: center;
  border-radius: 10px;
  background: var(--grad-soft);
  color: var(--brand);
  font-size: .95rem;
}
.nav-drop-menu span { display: flex; flex-direction: column; font-size: .9rem; font-weight: 500; }
.nav-drop-menu small { font-size: .74rem; color: var(--faint); font-weight: 400; }

/* Lado derecho */
.nav-side { display: flex; align-items: center; gap: .7rem; }

.status-chip {
  display: inline-flex; align-items: center; gap: .45rem;
  padding: .38rem .8rem;
  border-radius: 999px;
  background: rgba(52, 211, 153, .1);
  border: 1px solid rgba(52, 211, 153, .28);
  font-size: .74rem; font-weight: 600;
  color: var(--ok);
  white-space: nowrap;
}
.status-chip .dot {
  width: 7px; height: 7px; border-radius: 50%;
  background: var(--ok);
  box-shadow: 0 0 0 0 rgba(52, 211, 153, .6);
  animation: ring 2s infinite;
}
.status-chip.closed { background: rgba(251, 113, 133, .1); border-color: rgba(251, 113, 133, .3); color: var(--danger); }
.status-chip.closed .dot { background: var(--danger); animation: none; }
@keyframes ring {
  0%   { box-shadow: 0 0 0 0 rgba(52, 211, 153, .55); }
  70%  { box-shadow: 0 0 0 9px rgba(52, 211, 153, 0); }
  100% { box-shadow: 0 0 0 0 rgba(52, 211, 153, 0); }
}

/* Burger */
.nav-burger {
  display: none;
  width: 44px; height: 44px;
  border-radius: 13px;
  background: var(--surface);
  border: 1px solid var(--stroke);
  padding: 0;
  position: relative;
}
.nav-burger span {
  position: absolute; left: 13px;
  width: 18px; height: 2px;
  background: var(--text);
  border-radius: 2px;
  transition: all .35s var(--ease);
}
.nav-burger span:nth-child(1) { top: 15px; }
.nav-burger span:nth-child(2) { top: 21px; }
.nav-burger span:nth-child(3) { top: 27px; }
.nav-burger.on span:nth-child(1) { top: 21px; transform: rotate(45deg); }
.nav-burger.on span:nth-child(2) { opacity: 0; transform: scaleX(0); }
.nav-burger.on span:nth-child(3) { top: 21px; transform: rotate(-45deg); }

.nav-scrim {
  position: fixed; inset: 0; z-index: 700;
  background: rgba(3, 5, 10, .72);
  -webkit-backdrop-filter: blur(4px);
  backdrop-filter: blur(4px);
  opacity: 0;
  transition: opacity .4s;
}
.nav-scrim.on { opacity: 1; }

/* ---------------------------------------------------------------- 8. HERO */
.hero {
  position: relative;
  min-height: 100svh;
  display: flex;
  align-items: center;
  padding: clamp(7rem, 14vh, 9rem) 0 4rem;
  overflow: hidden;
  isolation: isolate;
}

.hero-bg { position: absolute; inset: 0; z-index: -1; }

.mesh {
  position: absolute;
  border-radius: 50%;
  filter: blur(90px);
  opacity: .5;
}
.mesh-a { width: 620px; height: 620px; top: -14%; right: -8%;  background: radial-gradient(circle, #0e7490, transparent 68%); animation: drift 22s ease-in-out infinite; }
.mesh-b { width: 540px; height: 540px; bottom: -18%; left: -10%; background: radial-gradient(circle, #4338ca, transparent 68%); animation: drift 27s ease-in-out infinite reverse; }
.mesh-c { width: 420px; height: 420px; top: 34%; left: 40%;     background: radial-gradient(circle, #0891b2, transparent 70%); opacity: .3; animation: drift 19s ease-in-out infinite; }
@keyframes drift {
  0%,100% { transform: translate(0,0) scale(1); }
  33%     { transform: translate(50px,-40px) scale(1.1); }
  66%     { transform: translate(-40px,35px) scale(.94); }
}

.grid-overlay {
  position: absolute; inset: 0;
  background-image:
    linear-gradient(rgba(255,255,255,.032) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.032) 1px, transparent 1px);
  background-size: 62px 62px;
  mask-image: radial-gradient(ellipse 78% 62% at 50% 42%, #000 30%, transparent 100%);
  -webkit-mask-image: radial-gradient(ellipse 78% 62% at 50% 42%, #000 30%, transparent 100%);
}

.hero-noise {
  position: absolute; inset: 0;
  opacity: .035;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr);
  gap: clamp(2rem, 5vw, 4rem);
  align-items: center;
}

.eyebrow {
  display: inline-flex; align-items: center; gap: .6rem;
  margin: 0 0 1.4rem;
  padding: .45rem 1rem .45rem .7rem;
  border-radius: 999px;
  background: var(--surface);
  border: 1px solid var(--stroke-strong);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  font-size: .8rem; font-weight: 600;
  letter-spacing: .04em;
  color: #cfe4ee;
}
.pulse-dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--brand);
  animation: ring 2s infinite;
  box-shadow: 0 0 0 0 rgba(34, 211, 238, .6);
}

.hero-title {
  font-size: clamp(2.6rem, 7.2vw, 5rem);
  font-weight: 700;
  line-height: 1.02;
  margin-bottom: .9rem;
}
.hero-title .grad-text { display: block; }

.hero-type {
  font-family: var(--mono);
  font-size: clamp(.95rem, 2vw, 1.15rem);
  color: var(--brand);
  min-height: 1.8em;
  margin: 0 0 1.2rem;
  letter-spacing: .01em;
}
.caret { animation: blink 1s steps(2) infinite; color: var(--brand); }
@keyframes blink { 50% { opacity: 0; } }

.hero-lead {
  max-width: 56ch;
  font-size: clamp(1rem, 1.6vw, 1.1rem);
  color: var(--muted);
  margin: 0 0 2.2rem;
}

.hero-actions { display: flex; flex-wrap: wrap; gap: .9rem; margin-bottom: 2.8rem; }

.hero-stats { display: flex; align-items: center; flex-wrap: wrap; gap: clamp(1rem, 3vw, 2.2rem); }
.hstat { display: flex; flex-direction: column; }
.hstat b {
  font-family: var(--head);
  font-size: clamp(1.6rem, 3.2vw, 2.2rem);
  font-weight: 700;
  background: var(--grad);
  -webkit-background-clip: text; background-clip: text; color: transparent;
  line-height: 1;
}
.hstat span { font-size: .78rem; color: var(--faint); text-transform: uppercase; letter-spacing: .09em; margin-top: .3rem; }
.hstat-sep { width: 1px; height: 34px; background: var(--stroke-strong); }

/* Visual orbital */
.hero-visual {
  position: relative;
  display: grid;
  place-items: center;
  min-height: 380px;
}

.orbiter {
  position: relative;
  width: min(340px, 78vw);
  aspect-ratio: 1;
  display: grid; place-items: center;
  transition: transform .5s var(--ease-2);
  transform-style: preserve-3d;
}

.ring {
  position: absolute;
  border-radius: 50%;
  border: 1px solid var(--stroke-strong);
}
.ring-1 { inset: 0;   border-style: dashed; border-color: rgba(34,211,238,.28); animation: spin 34s linear infinite; }
.ring-2 { inset: 14%; border-color: rgba(129,140,248,.26); animation: spin 24s linear infinite reverse; }
.ring-3 { inset: 28%; border-color: rgba(255,255,255,.1); }

.core {
  width: 34%; aspect-ratio: 1;
  display: grid; place-items: center;
  border-radius: 28%;
  background: linear-gradient(145deg, rgba(34,211,238,.22), rgba(99,102,241,.16));
  border: 1px solid rgba(34,211,238,.4);
  color: var(--brand);
  font-size: clamp(2rem, 5vw, 2.8rem);
  box-shadow: 0 0 50px rgba(34, 211, 238, .32), inset 0 0 30px rgba(34,211,238,.1);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  animation: coreFloat 5s ease-in-out infinite;
}
@keyframes coreFloat { 0%,100% { transform: translateY(-5px); } 50% { transform: translateY(5px); } }

/* Satélites del orbe. Nombre propio (.orb) para no chocar con las cajas
   de estadísticas de testimonios, que también son ".sat" por historia. */
.orb {
  position: absolute;
  width: 50px; height: 50px;
  display: grid; place-items: center;
  border-radius: 15px;
  background: rgba(12, 17, 28, .9);
  border: 1px solid var(--stroke-strong);
  color: var(--brand);
  font-size: 1.2rem;
  box-shadow: var(--sh-sm);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  animation: satFloat 6s ease-in-out infinite;
}
.orb.o1 { top: -6%;  left: 50%; margin-left: -25px; }
.orb.o2 { right: -6%; top: 50%; margin-top: -25px;  animation-delay: 1.5s; color: var(--info); }
.orb.o3 { bottom: -6%; left: 50%; margin-left: -25px; animation-delay: 3s;  color: var(--warn); }
.orb.o4 { left: -6%; top: 50%; margin-top: -25px;   animation-delay: 4.5s; color: #a5b4fc; }
@keyframes satFloat { 0%,100% { transform: translateY(-7px); } 50% { transform: translateY(7px); } }

.float-card {
  position: absolute;
  display: flex; align-items: center; gap: .65rem;
  padding: .7rem 1rem;
  border-radius: var(--r);
  background: rgba(11, 16, 26, .88);
  border: 1px solid var(--stroke-strong);
  box-shadow: var(--sh);
  -webkit-backdrop-filter: blur(16px);
  backdrop-filter: blur(16px);
  animation: satFloat 7s ease-in-out infinite;
}
.float-card i { color: var(--brand); font-size: 1.2rem; }
.float-card strong { display: block; font-size: .85rem; }
.float-card small { display: block; font-size: .72rem; color: var(--faint); }
.fc-1 { top: 6%; left: -6%; }
.fc-2 { bottom: 8%; right: -4%; animation-delay: 2.4s; }

/* Scroll cue */
.scroll-cue {
  position: absolute; bottom: 1.9rem; left: 50%;
  transform: translateX(-50%);
  display: flex; flex-direction: column; align-items: center; gap: .5rem;
  font-size: .7rem; letter-spacing: .28em; text-transform: uppercase;
  color: var(--faint);
  transition: color .3s;
}
.scroll-cue:hover { color: var(--brand); }
.scroll-cue i {
  width: 1px; height: 42px;
  background: linear-gradient(var(--brand), transparent);
  position: relative; overflow: hidden;
}
.scroll-cue i::after {
  content: '';
  position: absolute; top: 0; left: 0;
  width: 100%; height: 12px;
  background: var(--brand);
  animation: cue 2s var(--ease-2) infinite;
}
@keyframes cue { 0% { transform: translateY(-14px); opacity: 0; } 40% { opacity: 1; } 100% { transform: translateY(42px); opacity: 0; } }

/* ------------------------------------------------------------- 9. MARQUEE */
.marquee-band {
  border-block: 1px solid var(--stroke);
  background: linear-gradient(90deg, rgba(34,211,238,.05), rgba(99,102,241,.05));
  padding: 1.15rem 0;
  overflow: hidden;
}
.marquee {
  mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent);
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent);
}
.marquee-track {
  display: flex; align-items: center; gap: 2.4rem;
  width: max-content;
  animation: slide 42s linear infinite;
}
.marquee-band:hover .marquee-track { animation-play-state: paused; }
.marquee-track span {
  font-family: var(--head);
  font-size: 1.15rem; font-weight: 600;
  color: var(--faint);
  letter-spacing: .04em;
  transition: color .3s;
}
.marquee-track span:hover { color: var(--brand); }
.marquee-track i { color: rgba(34,211,238,.35); font-size: .55rem; font-style: normal; }
@keyframes slide { to { transform: translateX(-50%); } }

/* ------------------------------------------------------------ 10. SECCIÓN */
.section { position: relative; padding: var(--sec-y) 0; }
.section-alt { background: var(--bg-alt); }
.section-alt::before {
  content: '';
  position: absolute; inset: 0;
  background: radial-gradient(ellipse 60% 45% at 50% 0%, rgba(34,211,238,.05), transparent 70%);
  pointer-events: none;
}
.section > .shell { position: relative; z-index: 1; }

.sec-head {
  max-width: 700px;
  margin: 0 auto clamp(2.5rem, 5vw, 3.8rem);
  text-align: center;
}
.sec-kicker {
  display: inline-flex; align-items: center; gap: .45rem;
  padding: .35rem .9rem;
  border-radius: 999px;
  background: var(--brand-soft);
  border: 1px solid rgba(34,211,238,.25);
  color: var(--brand);
  font-size: .74rem; font-weight: 700;
  letter-spacing: .12em; text-transform: uppercase;
  margin-bottom: 1.1rem;
}
.sec-title {
  font-size: clamp(1.9rem, 4.4vw, 3.1rem);
  font-weight: 700;
  margin-bottom: 1rem;
}
.sec-sub { color: var(--muted); font-size: clamp(.96rem, 1.5vw, 1.06rem); margin: 0; }

/* KPIs */
.kpi-row {
  display: flex; flex-wrap: wrap; justify-content: center;
  gap: clamp(1rem, 3vw, 2.5rem);
  margin-bottom: 2.6rem;
}
.kpi {
  text-align: center;
  padding: 1rem 1.8rem;
  border-radius: var(--r);
  background: var(--surface);
  border: 1px solid var(--stroke);
  min-width: 150px;
  transition: transform .4s var(--ease), border-color .4s, box-shadow .4s;
}
.kpi:hover { transform: translateY(-5px); border-color: rgba(34,211,238,.4); box-shadow: var(--glow); }
.kpi b {
  display: block;
  font-family: var(--head);
  font-size: clamp(1.6rem, 3vw, 2.1rem);
  background: var(--grad);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.kpi span { font-size: .78rem; color: var(--faint); text-transform: uppercase; letter-spacing: .07em; }

/* Filtros pill */
.filter-bar {
  display: flex; flex-wrap: wrap; justify-content: center; gap: .55rem;
  margin-bottom: 2.6rem;
}
.pill {
  display: inline-flex; align-items: center; gap: .45rem;
  padding: .58rem 1.15rem;
  border-radius: 999px;
  background: var(--surface);
  border: 1px solid var(--stroke);
  color: var(--muted);
  font-size: .87rem; font-weight: 500;
  transition: all .3s var(--ease);
}
.pill:hover { color: #fff; border-color: var(--stroke-strong); transform: translateY(-2px); }

/* Recuento que initServiceFilter() inyecta en cada filtro */
.pill-n {
  font-style: normal;
  font-family: var(--mono);
  font-size: .72rem;
  color: var(--faint);
  margin-left: .1rem;
}
.pill:hover .pill-n { color: var(--muted); }
.pill.is-active .pill-n { color: rgba(4,18,26,.65); }
.pill.is-active {
  background: var(--grad);
  color: #04121a;
  border-color: transparent;
  font-weight: 600;
  box-shadow: 0 8px 24px rgba(34,211,238,.28);
}

/* -------------------------------------------------- Cabecera partida
   Título y descripción a la izquierda, herramientas (filtros, buscador)
   a la derecha. En secciones con filtros ahorra una banda entera de alto
   frente a apilar cabecera centrada + controles.
   Se alinean por abajo para que los pills queden a ras de la última línea
   de la izquierda. */
.sec-split {
  display: grid;
  /* El mínimo de 320px en la izquierda obliga a que sea la columna de
     herramientas la que ceda: los pills se reparten en dos líneas antes de
     que el título se estruje. */
  grid-template-columns: minmax(min(100%, 320px), 1fr) auto;
  align-items: end;
  gap: clamp(1.2rem, 3vw, 3rem);
  margin-bottom: clamp(2rem, 4vw, 3rem);
  padding-bottom: clamp(1.2rem, 2.5vw, 1.8rem);
  border-bottom: 1px solid var(--stroke);
}
.sec-split > * { min-width: 0; }

.sec-split .sec-head {
  max-width: 62ch;
  margin: 0;
  text-align: left;
}
.sec-split .sec-kicker { margin-bottom: .8rem; }
.sec-split .sec-title  { margin-bottom: .7rem; }

/* Columna de herramientas: se apilan de arriba abajo y se pegan a la derecha */
.sec-tools {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: .75rem;
  /* Tope para que una tira larga de pills se reparta en dos líneas en vez de
     comerse media sección. */
  max-width: 480px;
}
.sec-tools .filter-bar { justify-content: flex-end; margin-bottom: 0; }
/* Ancho en unidades absolutas: un porcentaje aquí sería circular, porque la
   columna se dimensiona según su contenido. */
.sec-tools .err-search { width: clamp(260px, 30vw, 400px); }
.sec-tools .err-conteo { text-align: right; }

/* KPIs en línea: mismos datos que las tarjetas, sin las cajas, para que
   quepan bajo el texto sin añadir otra banda. */
.kpi-inline {
  justify-content: flex-start;
  align-items: center;
  gap: clamp(1rem, 2.4vw, 1.9rem);
  margin: 1.5rem 0 0;
}
.kpi-inline .kpi {
  min-width: 0;
  /* Anula el `flex: 1 1 140px` que las tarjetas reciben en móvil: aquí no son
     cajas y no deben estirarse. */
  flex: 0 1 auto;
  padding: 0 0 0 clamp(1rem, 2.4vw, 1.9rem);
  text-align: left;
  background: none;
  border: 0;
  border-left: 1px solid var(--stroke);
  border-radius: 0;
}
.kpi-inline .kpi:first-child { padding-left: 0; border-left: 0; }
.kpi-inline .kpi:hover { transform: none; box-shadow: none; }
.kpi-inline .kpi b { font-size: clamp(1.35rem, 2.4vw, 1.75rem); line-height: 1.1; }
.kpi-inline .kpi span { font-size: .72rem; }

/* Por debajo de ~900px la columna derecha ya no tiene aire suficiente:
   vuelve todo a una sola columna, alineado a la izquierda. */
@media (max-width: 900px) {
  .sec-split {
    grid-template-columns: 1fr;
    gap: 1.4rem;
  }
  .sec-tools { align-items: stretch; max-width: none; }
  .sec-tools .filter-bar { justify-content: flex-start; }
  .sec-tools .err-search { width: 100%; }
  .sec-tools .err-conteo { text-align: left; }
}

@media (max-width: 520px) {
  .kpi-inline { gap: .85rem; }
  .kpi-inline .kpi { padding-left: .85rem; }
}

/* ----------------------------------------------------------- 11. SERVICIOS */
/* La sección va en dos niveles: 3 tarjetas destacadas con foto y 5 compactas.
   Cada nivel tiene su propia rejilla en vez de compartir una sola: si
   compartieran, al filtrar podría quedar una compacta (~120px) en la misma
   fila que una destacada (~490px) y la fila se llenaría de hueco. */
.svc-layout { display: grid; gap: 1.5rem; }

/* auto-fit (no auto-fill) para que las 3 destacadas ocupen 3 columnas justas
   y no quede una pista vacía a la derecha. */
.svc-tier-hero {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(300px, 100%), 1fr));
  gap: 1.5rem;
}

/* Número de columnas fijo: son 6 fichas (5 servicios + la de contacto) y se
   quieren en 3+3, no en el 4+2 que daría un auto-fit a este ancho. */
.svc-tier-mini {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
}

/* Si un filtro deja el nivel destacado sin tarjetas, se colapsa entero; si no,
   seguiría aportando el gap de .svc-layout y dejaría un salto en blanco. */
.svc-tier-hero:not(:has(.svc:not(.is-hidden))) { display: none; }

.svc {
  position: relative;
  display: flex; flex-direction: column;
  border-radius: var(--r-lg);
  background: linear-gradient(165deg, rgba(255,255,255,.055), rgba(255,255,255,.02));
  border: 1px solid var(--stroke);
  overflow: hidden;
  transition: transform .45s var(--ease), border-color .45s, box-shadow .45s;
  transform-style: preserve-3d;
}
.svc::after {
  content: '';
  position: absolute; inset: 0;
  border-radius: inherit;
  padding: 1px;
  background: var(--grad);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor; mask-composite: exclude;
  opacity: 0;
  transition: opacity .45s;
  pointer-events: none;
}
.svc:hover { transform: translateY(-8px); box-shadow: var(--sh-lg); }
.svc:hover::after { opacity: 1; }
.svc.is-hidden { display: none; }

/* 16/9 en vez de 16/10: recorta ~25px de alto por destacada sin que la foto
   pierda lectura. Solo lo usan las destacadas; las compactas van con .svc-thumb. */
.svc-media { position: relative; aspect-ratio: 16 / 9; overflow: hidden; }
.svc-media img {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform .8s var(--ease), filter .5s;
  filter: saturate(.85) brightness(.85);
}
.svc:hover .svc-media img { transform: scale(1.09); filter: saturate(1.05) brightness(1); }
.svc-media::after {
  content: '';
  position: absolute; inset: 0;
  background: linear-gradient(to top, rgba(5,7,13,.95) 4%, transparent 55%);
}

.tag {
  position: absolute; top: .85rem; left: .85rem; z-index: 2;
  padding: .3rem .75rem;
  border-radius: 999px;
  font-size: .7rem; font-weight: 700;
  letter-spacing: .06em; text-transform: uppercase;
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
}
/* Base oscura para que el texto se lea también sobre fotos claras */
.tag-repair  { background: linear-gradient(rgba(5,8,15,.72), rgba(5,8,15,.72)), rgba(34,211,238,.3);  border: 1px solid rgba(34,211,238,.5);  color: #7de8fb; }
.tag-install { background: linear-gradient(rgba(5,8,15,.72), rgba(5,8,15,.72)), rgba(129,140,248,.3); border: 1px solid rgba(129,140,248,.5); color: #bcc4ff; }
.tag-consult { background: linear-gradient(rgba(5,8,15,.72), rgba(5,8,15,.72)), rgba(52,211,153,.3);  border: 1px solid rgba(52,211,153,.5);  color: #7ce7c0; }
.tag-urgent  { background: linear-gradient(rgba(5,8,15,.72), rgba(5,8,15,.72)), rgba(251,113,133,.3); border: 1px solid rgba(251,113,133,.5); color: #ffa8b6; }

.price {
  position: absolute; bottom: .85rem; right: .85rem; z-index: 2;
  padding: .32rem .8rem;
  border-radius: 999px;
  background: rgba(5,8,15,.75);
  border: 1px solid var(--stroke-strong);
  font-family: var(--mono);
  font-size: .76rem; font-weight: 500;
  color: var(--brand);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
}
.price-urgent { color: #ffa8b6; border-color: rgba(251,113,133,.4); }

.svc-body { padding: 1.3rem 1.35rem 1.4rem; display: flex; flex-direction: column; flex: 1; }

.svc-icon {
  width: 44px; height: 44px;
  display: grid; place-items: center;
  border-radius: 13px;
  background: var(--grad-soft);
  border: 1px solid rgba(34,211,238,.24);
  color: var(--brand);
  font-size: 1.15rem;
  margin-bottom: .85rem;
  transition: transform .45s var(--ease);
}
.svc:hover .svc-icon { transform: rotate(-8deg) scale(1.08); }
.icon-urgent { background: rgba(251,113,133,.14); border-color: rgba(251,113,133,.3); color: #ffa8b6; }

.svc-body h3 { font-size: 1.14rem; margin-bottom: .5rem; }
.svc-body > p { color: var(--muted); font-size: .9rem; margin: 0 0 1rem; }

.svc-feats { list-style: none; display: grid; gap: .4rem; margin-bottom: 1.1rem; }
.svc-feats li { display: flex; align-items: center; gap: .5rem; font-size: .84rem; color: #c3cede; }
.svc-feats i { color: var(--ok); font-size: .9rem; }

.svc-foot {
  display: flex; align-items: center; justify-content: space-between;
  gap: .6rem;
  margin-top: auto;
  padding-top: .9rem;
  border-top: 1px solid var(--stroke);
}
.stars { display: inline-flex; align-items: center; gap: .1rem; color: var(--warn); font-size: .8rem; }
.stars em { font-style: normal; color: var(--faint); font-size: .78rem; margin-left: .35rem; }

/* La ficha entera abre el modal: el pseudoelemento del enlace se estira
   sobre ella. El foco y el lector de pantalla siguen apuntando al botón, así
   que no se añade nada que recorrer con el teclado. Requiere que el
   contenedor sea position:relative — lo son .svc y .guia. */
.svc .link-btn::after,
.guia .link-btn::after {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 3;
}

/* ---------------------------------------------------- Tarjeta compacta */
/* Objeto multimedia horizontal: miniatura + texto. Conserva la fotografía
   a una décima parte del alto que costaba el banner de 16/9. */
.svc-mini {
  flex-direction: row;
  align-items: center;
  gap: .9rem;
  padding: .85rem;
  border-radius: var(--r);
}
.svc-mini:hover { transform: translateY(-4px); }

.svc-thumb {
  flex: none;
  position: relative;
  width: 76px; height: 76px;
  border-radius: 12px;
  overflow: hidden;
}
.svc-thumb img {
  width: 100%; height: 100%; object-fit: cover;
  filter: saturate(.85) brightness(.85);
  transition: transform .6s var(--ease), filter .4s;
}
.svc-mini:hover .svc-thumb img { transform: scale(1.09); filter: saturate(1.05) brightness(1); }

.svc-mini .svc-body { padding: 0; gap: .25rem; justify-content: center; min-width: 0; }
.svc-mini .svc-body h3 { font-size: .97rem; margin: 0; line-height: 1.3; }
.svc-mini > .svc-body > p {
  margin: 0;
  font-size: .8rem;
  color: var(--muted);
  /* Dos líneas como techo: los textos están recortados a mano, pero un
     título de marca largo no debe poder descuadrar la altura de la fila. */
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  overflow: hidden;
}

.svc-mini-foot {
  display: flex; align-items: center; justify-content: space-between;
  gap: .5rem;
  margin-top: .4rem;
}
.svc-mini-foot .link-btn { font-size: .82rem; }

/* Variante del precio fuera de la imagen: mismo lenguaje que .price pero en
   flujo normal, sin posicionamiento absoluto. */
.price-flat {
  padding: .24rem .6rem;
  border-radius: 999px;
  background: var(--surface);
  border: 1px solid var(--stroke-strong);
  font-family: var(--mono);
  font-size: .72rem;
  color: var(--brand);
  white-space: nowrap;
}
.price-flat.price-urgent { color: #ffa8b6; border-color: rgba(251,113,133,.4); }

/* Ficha de contacto que cierra la rejilla de compactas: rellena la sexta
   celda y convierte un hueco muerto en una vía de contacto. */
.svc-cta { background: var(--grad-soft); border-color: rgba(34,211,238,.24); }
.svc-cta-icon {
  flex: none;
  width: 76px; height: 76px;
  display: grid; place-items: center;
  border-radius: 12px;
  background: rgba(34,211,238,.1);
  border: 1px solid rgba(34,211,238,.2);
  color: var(--brand);
  font-size: 1.5rem;
}

@media (max-width: 1000px) {
  .svc-tier-mini { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 620px) {
  .svc-tier-mini { grid-template-columns: 1fr; }
}

/* ------------------------------------------------------------ 12. TIMELINE */
.timeline { position: relative; display: grid; gap: 2rem; }

.tl-rail {
  position: absolute;
  left: 26px; top: 8px; bottom: 8px;
  width: 2px;
  background: var(--stroke);
  border-radius: 2px;
  overflow: hidden;
}
.tl-rail i {
  display: block; width: 100%; height: 0;
  background: var(--grad);
  box-shadow: 0 0 14px rgba(34,211,238,.65);
  transition: height .2s linear;
}

.tl-item { display: grid; grid-template-columns: 54px 1fr; gap: 1.3rem; align-items: start; }

.tl-node {
  position: relative; z-index: 2;
  width: 54px; height: 54px;
  display: grid; place-items: center;
  border-radius: 17px;
  background: #0b1120;
  border: 1px solid var(--stroke-strong);
  color: var(--brand);
  font-size: 1.2rem;
  transition: all .5s var(--ease);
}
.tl-item.in .tl-node {
  border-color: rgba(34,211,238,.5);
  box-shadow: 0 0 0 5px rgba(34,211,238,.07), 0 0 26px rgba(34,211,238,.25);
}

.tl-card {
  padding: 1.4rem 1.5rem;
  border-radius: var(--r-lg);
  background: linear-gradient(160deg, rgba(255,255,255,.055), rgba(255,255,255,.02));
  border: 1px solid var(--stroke);
  transition: transform .45s var(--ease), border-color .45s, box-shadow .45s;
}
.tl-card:hover { transform: translateX(6px); border-color: rgba(34,211,238,.32); box-shadow: var(--sh); }

.tl-step {
  display: inline-block;
  font-family: var(--mono);
  font-size: .72rem;
  color: var(--brand);
  letter-spacing: .08em;
  margin-bottom: .5rem;
}
.tl-card h3 { font-size: 1.22rem; margin-bottom: .5rem; }
.tl-card > p { color: var(--muted); font-size: .92rem; margin: 0 0 1rem; }

.tl-meta { display: flex; flex-wrap: wrap; gap: .5rem; }
.chip {
  display: inline-flex; align-items: center; gap: .4rem;
  padding: .35rem .85rem;
  border-radius: 999px;
  font-size: .78rem; font-weight: 500;
  border: 1px solid transparent;
}
.chip-info  { background: rgba(56,189,248,.1);  border-color: rgba(56,189,248,.28);  color: #7dd3fc; }
.chip-ok    { background: rgba(52,211,153,.1);  border-color: rgba(52,211,153,.28);  color: #6ee7b7; }
.chip-brand { background: rgba(129,140,248,.1); border-color: rgba(129,140,248,.28); color: #a5b4fc; }
.chip-warn  { background: rgba(251,191,36,.1);  border-color: rgba(251,191,36,.28);  color: #fcd34d; }

.tl-note {
  margin-top: 1.1rem;
  padding: .95rem 1.1rem;
  border-radius: var(--r);
  background: rgba(99,102,241,.07);
  border-left: 3px solid var(--brand-2);
}
.tl-note strong { display: flex; align-items: center; gap: .45rem; font-size: .84rem; color: #a5b4fc; margin-bottom: .5rem; }
.tl-note ul { list-style: none; display: grid; gap: .3rem; }
.tl-note li { position: relative; padding-left: 1.1rem; font-size: .84rem; color: var(--muted); }
.tl-note li::before { content: '▹'; position: absolute; left: 0; color: var(--brand); }

/* ------------------------------------------- 13. BUSCADOR DE CÓDIGOS DE ERROR */
/* Sustituye al antiguo carrusel: las familias se ven todas a la vez y el
   usuario filtra en lugar de esperar a que pase la diapositiva. */

/* El buscador y los filtros viven en la columna derecha de .sec-split;
   la separación entre ellos la pone el gap de .sec-tools. */
.err-search {
  position: relative;
  display: flex; align-items: center;
}
.err-search > i {
  position: absolute; left: 1.1rem;
  color: var(--brand);
  font-size: 1.05rem;
  pointer-events: none;
}
.err-search input {
  width: 100%;
  padding: 1rem 3rem;
  border-radius: 999px;
  background: var(--surface);
  border: 1px solid var(--stroke-strong);
  color: var(--text);
  font-size: .97rem;
  outline: none;
  transition: border-color .3s, background .3s, box-shadow .3s;
}
.err-search input::placeholder { color: var(--faint); }
.err-search input:focus {
  border-color: var(--brand);
  background: rgba(34, 211, 238, .05);
  box-shadow: 0 0 0 4px rgba(34, 211, 238, .12);
}
/* El navegador pinta su propia "x" en los input[type=search]; sobra */
.err-search input::-webkit-search-cancel-button { -webkit-appearance: none; appearance: none; }

.err-clear {
  position: absolute; right: .8rem;
  width: 32px; height: 32px;
  display: grid; place-items: center;
  border-radius: 50%;
  background: var(--surface-2);
  border: 1px solid var(--stroke);
  color: var(--muted);
  font-size: .75rem;
  transition: all .3s var(--ease);
}
.err-clear:hover { color: #fff; background: var(--danger); border-color: transparent; }

.err-conteo {
  margin: 0;
  text-align: center;
  font-family: var(--mono);
  font-size: .76rem;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--faint);
}
.err-conteo b { color: var(--brand); font-weight: 500; }

/* --- Rejilla de familias --- */
/* Dos columnas anchas: con 4 familias sale una retícula 2×2 equilibrada, y el
   ancho permite que la descripción quepa junto al código sin partirse tanto. */
.err-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(420px, 100%), 1fr));
  gap: 1.5rem;
  align-items: start;
}

.err-card {
  display: flex; flex-direction: column;
  border-radius: var(--r-lg);
  background: linear-gradient(165deg, rgba(255,255,255,.05), rgba(255,255,255,.018));
  border: 1px solid var(--stroke);
  overflow: hidden;
  transition: border-color .45s var(--ease), box-shadow .45s var(--ease);
}
.err-card:hover { border-color: rgba(34,211,238,.3); box-shadow: var(--sh); }
.err-card.is-hidden { display: none; }

.err-media { position: relative; aspect-ratio: 21 / 9; overflow: hidden; background: #0b1120; }
.err-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .8s var(--ease); }
.err-card:hover .err-media img { transform: scale(1.05); }
.err-media::after {
  content: '';
  position: absolute; inset: 0;
  background: linear-gradient(to top, rgba(5,7,13,.9) 3%, transparent 60%);
}

/* En móvil y tablet la cabecera es la foto ancha con el título debajo. */
.err-titulo { padding: 1.25rem 1.35rem 0; }

.err-body { padding: 1.1rem 1.35rem 1.4rem; display: flex; flex-direction: column; flex: 1; }
.err-titulo h3 { font-size: 1.1rem; margin-bottom: .4rem; }

.err-marcas {
  display: flex; align-items: center; gap: .4rem;
  margin: 0;
  font-size: .8rem;
  color: var(--faint);
}
.err-marcas i { color: var(--brand); }

.err-list { list-style: none; display: grid; gap: .4rem; margin: 0 0 1rem; }

.err-item {
  display: flex; align-items: flex-start; gap: .7rem;
  padding: .6rem .7rem;
  border-radius: var(--r-sm);
  background: var(--surface);
  border: 1px solid var(--stroke);
  transition: background .3s, border-color .3s, transform .3s var(--ease);
}
.err-item:hover { background: var(--surface-2); border-color: rgba(34,211,238,.25); transform: translateX(3px); }
.err-item.is-hidden { display: none; }

/* Resaltado del término buscado */
.err-item.is-hit { border-color: rgba(34,211,238,.5); background: rgba(34,211,238,.07); }

.err-code {
  flex: none;
  min-width: 52px;
  padding: .22rem .5rem;
  text-align: center;
  border-radius: 7px;
  background: rgba(251,113,133,.1);
  border: 1px solid rgba(251,113,133,.28);
  font-family: var(--mono);
  font-size: .82rem; font-weight: 500;
  color: #ffa8b6;
}
.err-desc { font-size: .84rem; line-height: 1.5; color: #c3cede; }

.err-more {
  width: 100%;
  padding: .65rem 1rem;
  margin-bottom: 1rem;
  border-radius: var(--r-sm);
  background: var(--surface);
  border: 1px dashed var(--stroke-strong);
  font-size: .82rem; font-weight: 500;
  color: var(--brand);
  transition: all .3s var(--ease);
}
.err-more:hover { background: var(--brand-soft); border-color: var(--brand); border-style: solid; }

.err-note {
  display: flex; align-items: flex-start; gap: .5rem;
  margin: auto 0 0;
  padding: .75rem .9rem;
  border-radius: var(--r-sm);
  background: rgba(34,211,238,.05);
  border: 1px solid rgba(34,211,238,.18);
  font-size: .82rem;
  color: var(--muted);
}
.err-note i { color: var(--brand); margin-top: .15rem; flex: none; }

.err-pdf {
  display: inline-flex; align-items: center; gap: .45rem;
  margin-top: .9rem;
  font-size: .82rem; font-weight: 500;
  color: var(--brand);
  transition: gap .3s var(--ease);
}
.err-pdf:hover { gap: .75rem; }

/* --- Sin resultados --- */
.err-vacio {
  display: flex; flex-direction: column; align-items: center; gap: .9rem;
  padding: clamp(2.2rem, 5vw, 3.4rem) 1.4rem;
  border-radius: var(--r-lg);
  background: var(--surface);
  border: 1px dashed var(--stroke-strong);
  text-align: center;
  animation: faqIn .4s var(--ease);
}
.err-vacio > i { font-size: 1.9rem; color: var(--faint); }
.err-vacio p { margin: 0; color: var(--muted); font-size: .95rem; max-width: 42ch; }

/* --- Compactación en escritorio ---------------------------------------------
   En móvil y tablet la tarjeta va bien: foto ancha arriba y lista debajo.
   A partir de 1024px la retícula pasa a dos columnas de ~600px y esa foto de
   21:9 se come 260px por tarjeta sin aportar nada. Ahí la foto se convierte en
   miniatura junto al título y la lista se aprieta. No se quita información:
   la imagen sigue estando y todos los códigos siguen ahí. */
@media (min-width: 1024px) {
  .err-head {
    display: flex; align-items: center; gap: 1rem;
    padding: 1.1rem 1.25rem;
    border-bottom: 1px solid var(--stroke);
  }
  .err-media {
    flex: none;
    width: 78px; height: 78px;
    aspect-ratio: auto;
    border-radius: var(--r-sm);
    border: 1px solid var(--stroke);
  }
  .err-media::after { display: none; }
  .err-titulo { padding: 0; min-width: 0; }
  .err-titulo h3 { font-size: 1.05rem; margin-bottom: .25rem; }

  .err-body { padding: 1rem 1.25rem 1.2rem; }
  .err-list { gap: .3rem; margin-bottom: .8rem; }
  .err-item { padding: .45rem .6rem; gap: .6rem; align-items: center; }
  .err-code { min-width: 46px; padding: .18rem .45rem; font-size: .78rem; }
  .err-desc { font-size: .82rem; line-height: 1.4; }
  .err-more { padding: .5rem 1rem; margin-bottom: .8rem; }
  .err-note { padding: .6rem .8rem; font-size: .8rem; }
  .err-pdf { margin-top: .7rem; }
}

/* --- Aviso legal/técnico --- */
.err-aviso {
  display: flex; align-items: flex-start; gap: .6rem;
  max-width: 760px;
  margin: 2.2rem auto 0;
  padding: .9rem 1.1rem;
  border-radius: var(--r);
  background: rgba(251,191,36,.06);
  border: 1px solid rgba(251,191,36,.22);
  font-size: .85rem;
  color: #fde68a;
}
.err-aviso i { margin-top: .15rem; flex: none; }

.slider-nav { display: flex; align-items: center; justify-content: center; gap: 1.1rem; margin-top: 1.8rem; }

.round-btn {
  width: 46px; height: 46px;
  display: grid; place-items: center;
  border-radius: 50%;
  background: var(--surface);
  border: 1px solid var(--stroke-strong);
  color: var(--text);
  font-size: 1.05rem;
  transition: all .35s var(--ease);
}
.round-btn:hover { background: var(--grad); color: #04121a; border-color: transparent; transform: scale(1.09); box-shadow: 0 10px 26px rgba(34,211,238,.3); }

.dots { display: flex; gap: .45rem; }
.dots button {
  width: 9px; height: 9px;
  border-radius: 99px;
  background: var(--stroke-strong);
  padding: 0;
  transition: all .4s var(--ease);
}
.dots button.on { width: 28px; background: var(--grad); }

/* ------------------------------------------------------------ 14. NOSOTROS */
/* Registro visual sobrio: retícula editorial, filetes finos y acento contenido. */

.about-section { --hair: rgba(255, 255, 255, .1); }

/* Encabezado alineado a la izquierda */
.sec-head-left {
  max-width: none;
  margin-inline: 0;
  text-align: left;
  margin-bottom: clamp(2.2rem, 4vw, 3.2rem);
}
.sec-head-left .sec-title { margin-bottom: 1.4rem; }

.overline {
  display: inline-flex; align-items: center; gap: .7rem;
  font-family: var(--mono);
  font-size: .74rem;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--brand);
  margin-bottom: 1.1rem;
}
.overline i { font-style: normal; color: var(--faint); letter-spacing: 0; }

.rule {
  display: block;
  width: 72px; height: 2px;
  background: var(--brand);
}

/* --- Bloque superior: imagen + texto --- */
.about-top {
  display: grid;
  grid-template-columns: minmax(0, 47fr) minmax(0, 53fr);
  gap: clamp(2rem, 5vw, 4.5rem);
  align-items: center;
  padding-bottom: clamp(2.5rem, 5vw, 4rem);
}

.about-frame { position: relative; margin: 0; }
.about-frame::before {
  /* Marco desplazado: da profundidad sin sombras ni brillos */
  content: '';
  position: absolute;
  inset: 18px -18px -18px 18px;
  border: 1px solid var(--hair);
  pointer-events: none;
}
.about-frame-img {
  position: relative;
  overflow: hidden;
  height: clamp(300px, 40vw, 460px);
  border: 1px solid var(--hair);
}
.about-frame-img img {
  width: 100%; height: 118%;
  object-fit: cover;
  filter: grayscale(.35) contrast(1.05) brightness(.72);
  transition: filter .8s var(--ease), transform 1.2s var(--ease);
}
.about-frame:hover .about-frame-img img { filter: grayscale(0) contrast(1) brightness(.85); }
.about-frame-img::after {
  content: '';
  position: absolute; inset: 0;
  background: linear-gradient(to top, rgba(5, 7, 13, .85), rgba(5, 7, 13, .05) 55%);
}

.about-frame figcaption {
  position: relative;
  display: flex; flex-direction: column; gap: .2rem;
  margin-top: -1px;
  padding: .95rem 1.1rem;
  background: rgba(10, 14, 24, .96);
  border: 1px solid var(--hair);
  border-left: 2px solid var(--brand);
}
.about-plate-label {
  font-family: var(--mono);
  font-size: .68rem; letter-spacing: .18em; text-transform: uppercase;
  color: var(--brand);
}
.about-plate-value { font-size: .84rem; color: var(--muted); }

/* Texto */
.about-statement {
  font-family: var(--head);
  font-size: clamp(1.4rem, 2.6vw, 1.9rem);
  font-weight: 500;
  line-height: 1.3;
  letter-spacing: -.015em;
  color: #fff;
  margin: 0 0 1.3rem;
}
.about-lead {
  font-size: 1.02rem;
  line-height: 1.8;
  color: var(--muted);
  margin: 0 0 2rem;
  max-width: 56ch;
}

.about-sign {
  display: flex; align-items: center; gap: .9rem;
  padding: 1.2rem 0;
  border-top: 1px solid var(--hair);
  border-bottom: 1px solid var(--hair);
  margin-bottom: 1.8rem;
}
.about-sign img {
  width: 52px; height: 52px;
  border-radius: 50%;
  object-fit: cover;
  filter: grayscale(.3);
}
.about-sign b { display: block; font-family: var(--head); font-size: 1rem; font-weight: 600; }
.about-sign span { font-size: .82rem; color: var(--faint); }

.about-actions { display: flex; flex-wrap: wrap; gap: .7rem; }

/* --- Franja de cifras --- */
.about-figures {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  border-top: 1px solid var(--hair);
  border-bottom: 1px solid var(--hair);
}
.about-figures > div {
  padding: clamp(1.4rem, 3vw, 2.2rem) 1.2rem;
  text-align: center;
  border-left: 1px solid var(--hair);
}
.about-figures > div:first-child { border-left: 0; }
.about-figures b {
  display: block;
  font-family: var(--head);
  font-size: clamp(1.9rem, 4vw, 2.9rem);
  font-weight: 500;
  letter-spacing: -.03em;
  color: #fff;
  line-height: 1;
  margin-bottom: .55rem;
}
.about-figures span {
  font-family: var(--mono);
  font-size: .7rem;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--faint);
}

/* --- Pilares numerados --- */
.about-pillars {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
}
.pillar {
  position: relative;
  padding: clamp(1.6rem, 3vw, 2.2rem) clamp(1.1rem, 2vw, 1.8rem);
  border-left: 1px solid var(--hair);
  border-bottom: 1px solid var(--hair);
  transition: background .45s var(--ease);
}
.pillar:first-child { border-left: 0; }
.pillar::before {
  /* Filete de acento que crece al pasar el cursor */
  content: '';
  position: absolute; top: -1px; left: -1px;
  width: 0; height: 2px;
  background: var(--brand);
  transition: width .55s var(--ease);
}
.pillar:hover { background: rgba(255, 255, 255, .022); }
.pillar:hover::before { width: calc(100% + 1px); }

.pillar-num {
  display: block;
  font-family: var(--mono);
  font-size: .74rem;
  letter-spacing: .12em;
  color: var(--brand);
  margin-bottom: 1rem;
}
.pillar h3 {
  font-size: 1.02rem;
  font-weight: 600;
  margin-bottom: .5rem;
}
.pillar p { margin: 0; font-size: .87rem; line-height: 1.65; color: var(--muted); }

/* ------------------------------------------------------------- 15. VALORES */
.bento {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(290px, 100%), 1fr));
  gap: 1.5rem;
}

.bento-card {
  position: relative;
  padding: 1.8rem;
  border-radius: var(--r-xl);
  background: linear-gradient(165deg, rgba(255,255,255,.055), rgba(255,255,255,.018));
  border: 1px solid var(--stroke);
  overflow: hidden;
  transition: transform .5s var(--ease), border-color .5s, box-shadow .5s;
}
.bento-card::before {
  content: '';
  position: absolute; top: -60%; right: -30%;
  width: 320px; height: 320px;
  border-radius: 50%;
  filter: blur(70px);
  opacity: .16;
  transition: opacity .5s;
}
.b-mission::before { background: #22d3ee; }
.b-vision::before  { background: #818cf8; }
.b-values::before  { background: #34d399; }
.bento-card:hover { transform: translateY(-7px); border-color: var(--stroke-strong); box-shadow: var(--sh-lg); }
.bento-card:hover::before { opacity: .3; }

.bento-icon {
  width: 52px; height: 52px;
  display: grid; place-items: center;
  border-radius: 16px;
  background: var(--grad-soft);
  border: 1px solid rgba(34,211,238,.22);
  color: var(--brand);
  font-size: 1.35rem;
  margin-bottom: 1.1rem;
}
.b-vision .bento-icon { color: #a5b4fc; border-color: rgba(129,140,248,.25); background: linear-gradient(135deg, rgba(129,140,248,.2), rgba(99,102,241,.1)); }
.b-values .bento-icon { color: #6ee7b7; border-color: rgba(52,211,153,.25);  background: linear-gradient(135deg, rgba(52,211,153,.18), rgba(16,185,129,.1)); }

.bento-card h3 { font-size: 1.4rem; margin-bottom: .8rem; }
.bento-card > p { color: var(--muted); font-size: .94rem; margin: 0 0 1.2rem; }
.bento-card p strong { color: #fff; }
.bento-card p em { font-style: normal; color: var(--brand); }
.b-vision p em { color: #a5b4fc; }

.bento-tags { display: flex; flex-wrap: wrap; gap: .5rem; }
.bento-tags span {
  padding: .35rem .85rem;
  border-radius: 999px;
  background: var(--brand-soft);
  border: 1px solid rgba(34,211,238,.24);
  font-size: .77rem; font-weight: 600;
  color: var(--brand);
}

.bento-goals { display: grid; gap: .6rem; }
.bento-goals span { display: flex; align-items: center; gap: .6rem; font-size: .88rem; color: #c3cede; }
.bento-goals i { color: #a5b4fc; }

.values-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(130px, 100%), 1fr)); gap: .8rem; }
.vitem {
  display: flex; align-items: center; gap: .7rem;
  padding: .8rem;
  border-radius: var(--r-sm);
  background: var(--surface);
  border: 1px solid var(--stroke);
  transition: all .35s var(--ease);
}
.vitem:hover { background: var(--surface-2); transform: translateY(-3px); border-color: rgba(52,211,153,.3); }
.vitem i { color: var(--ok); font-size: 1.15rem; }
.vitem b { display: block; font-size: .88rem; }
.vitem small { font-size: .74rem; color: var(--faint); }

/* --------------------------------------------------------------- 16. BLOG */
/* SIN USO TRAS EL REDISEÑO — la tarjeta .post se sustituyó por las guías
   agrupadas (.guias-grid, más abajo). Se conserva, como el bloque .news de
   #noticias, por si hiciera falta recuperar el formato de tarjeta con foto
   grande para un blog de verdad. Ojo: .c-cyan / .c-teal / .c-red SÍ siguen
   en uso, ahora en .guia-cat. */
.post-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(310px, 100%), 1fr)); gap: 1.5rem; }

.post {
  display: flex; flex-direction: column;
  border-radius: var(--r-lg);
  background: linear-gradient(165deg, rgba(255,255,255,.05), rgba(255,255,255,.018));
  border: 1px solid var(--stroke);
  overflow: hidden;
  transition: transform .45s var(--ease), border-color .45s, box-shadow .45s;
}
.post:hover { transform: translateY(-8px); border-color: var(--stroke-strong); box-shadow: var(--sh-lg); }

.post-media { position: relative; aspect-ratio: 16 / 9; overflow: hidden; }
.post-media img { width: 100%; height: 100%; object-fit: cover; filter: brightness(.8); transition: transform .8s var(--ease), filter .5s; }
.post:hover .post-media img { transform: scale(1.08); filter: brightness(1); }
.post-media::after { content: ''; position: absolute; inset: 0; background: linear-gradient(to top, rgba(5,7,13,.9), transparent 60%); }

.post-cat {
  position: absolute; top: .85rem; left: .85rem; z-index: 2;
  padding: .3rem .8rem;
  border-radius: 999px;
  font-size: .7rem; font-weight: 700;
  letter-spacing: .05em; text-transform: uppercase;
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
}
/* Base oscura: estas insignias se apoyan sobre fotos que pueden ser claras */
.c-cyan { background: linear-gradient(rgba(5,8,15,.75), rgba(5,8,15,.75)), rgba(34,211,238,.3);  border: 1px solid rgba(34,211,238,.5); color: #7de8fb; }
.c-teal { background: linear-gradient(rgba(5,8,15,.75), rgba(5,8,15,.75)), rgba(52,211,153,.3);  border: 1px solid rgba(52,211,153,.5); color: #7ce7c0; }
.c-red  { background: linear-gradient(rgba(5,8,15,.75), rgba(5,8,15,.75)), rgba(251,113,133,.3); border: 1px solid rgba(251,113,133,.5); color: #ffa8b6; }

.post-body { padding: 1.3rem 1.35rem 1.4rem; display: flex; flex-direction: column; flex: 1; }
.post-body h3 { font-size: 1.12rem; margin-bottom: .5rem; }
.post-sub { display: flex; align-items: center; gap: .4rem; font-size: .82rem; color: var(--brand); margin-bottom: .7rem; }
.post-body > p { color: var(--muted); font-size: .9rem; margin: 0 0 1.1rem; }

.post-foot {
  display: flex; align-items: center; justify-content: space-between; gap: .6rem;
  margin-top: auto; padding-top: .9rem;
  border-top: 1px solid var(--stroke);
}
.post-time { display: inline-flex; align-items: center; gap: .35rem; font-size: .76rem; color: var(--faint); }

/* ------------------------------------------------------- Guías agrupadas */
/* Una columna por tema. Las seis guías son pares exactos (2+2+2), así que la
   agrupación sustituye al filtro en vez de sumarse a él. */
/* Sin align-items: las tres columnas se estiran a la misma altura, que si no
   quedan escalonadas según cuántas líneas ocupe cada título. */
.guias-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.2rem;
}

.guia-col {
  padding: 1.1rem;
  border-radius: var(--r-lg);
  background: linear-gradient(165deg, rgba(255,255,255,.05), rgba(255,255,255,.018));
  border: 1px solid var(--stroke);
}

/* Reutiliza los colores de categoría .c-cyan / .c-teal / .c-red, que hasta
   ahora sólo se usaban en la insignia sobre la foto. */
.guia-cat {
  display: inline-flex; align-items: center; gap: .45rem;
  padding: .32rem .85rem;
  border-radius: 999px;
  font-size: .72rem; font-weight: 700;
  letter-spacing: .07em; text-transform: uppercase;
  margin-bottom: .9rem;
}

.guia {
  position: relative;
  display: flex; align-items: flex-start; gap: .8rem;
  padding: .8rem .3rem;
  transition: background .3s var(--ease);
}
.guia + .guia { border-top: 1px solid var(--stroke); }
.guia:hover { background: rgba(255,255,255,.035); }

.guia-thumb {
  flex: none;
  width: 64px; height: 64px;
  border-radius: 12px;
  overflow: hidden;
}
.guia-thumb img {
  width: 100%; height: 100%; object-fit: cover;
  filter: brightness(.8);
  transition: transform .6s var(--ease), filter .4s;
}
.guia:hover .guia-thumb img { transform: scale(1.09); filter: brightness(1); }

.guia-txt { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: .22rem; }
.guia-txt h4 { font-size: .95rem; line-height: 1.3; margin: 0; }
.guia-txt p {
  margin: 0;
  font-size: .8rem; color: var(--muted); line-height: 1.45;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  overflow: hidden;
}

.guia-fecha {
  font-family: var(--mono);
  font-size: .7rem;
  color: var(--faint);
  letter-spacing: .04em;
  margin-top: .1rem;
}

/* Sólo la flecha: el rótulo lo lleva el aria-label, porque el título de la
   guía que hay al lado ya dice a dónde va. */
.guia-go {
  margin-left: auto;
  align-self: center;
  flex: none;
  font-size: 1rem;
}
.guia:hover .guia-go { color: #7de8fb; }

/* A dos columnas antes que a una: en tablet, una sola columna dejaría filas
   de 800px de ancho con dos líneas de texto y mucho aire muerto. */
@media (max-width: 1040px) {
  .guias-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 680px) {
  .guias-grid { grid-template-columns: 1fr; }
}

/* ------------------------------------------------------------ 17. NOTICIAS */
.news-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(300px, 100%), 1fr)); gap: 1.5rem; }

.news {
  display: flex; flex-direction: column;
  border-radius: var(--r-lg);
  background: var(--surface);
  border: 1px solid var(--stroke);
  overflow: hidden;
  transition: transform .45s var(--ease), border-color .45s, box-shadow .45s;
}
.news:hover { transform: translateY(-6px); border-color: rgba(34,211,238,.3); box-shadow: var(--sh); }

.news-media { position: relative; aspect-ratio: 16 / 9; overflow: hidden; }
.news-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .8s var(--ease); }
.news:hover .news-media img { transform: scale(1.07); }

.news-badge {
  position: absolute; bottom: .8rem; left: .8rem;
  display: inline-flex; align-items: center; gap: .35rem;
  padding: .3rem .8rem;
  border-radius: 999px;
  background: rgba(5,8,15,.8);
  border: 1px solid var(--stroke-strong);
  font-size: .73rem; font-weight: 600;
  color: var(--brand);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
}

.news-body { padding: 1.25rem 1.3rem 1.35rem; display: flex; flex-direction: column; flex: 1; }
.news-body h3 { font-size: 1.08rem; margin-bottom: .6rem; }
.news-body > p { color: var(--muted); font-size: .88rem; margin: 0 0 1.1rem; }
.news-foot {
  display: flex; align-items: center; justify-content: space-between; gap: .6rem;
  margin-top: auto; padding-top: .9rem;
  border-top: 1px solid var(--stroke);
}
.news-foot time { display: inline-flex; align-items: center; gap: .35rem; font-size: .76rem; color: var(--faint); }

/* ---------------------------------------------------------------- 18. FAQ */
.faq-list { display: grid; gap: .85rem; max-width: 900px; margin-inline: auto; }

.faq {
  border-radius: var(--r-lg);
  background: var(--surface);
  border: 1px solid var(--stroke);
  overflow: hidden;
  transition: border-color .35s, background .35s, box-shadow .35s;
}
.faq[open] { border-color: rgba(34,211,238,.35); background: var(--surface-2); box-shadow: var(--sh); }
.faq.is-hidden { display: none; }

.faq summary {
  display: flex; align-items: center; gap: 1rem;
  padding: 1.1rem 1.3rem;
  cursor: pointer;
  list-style: none;
}
.faq summary::-webkit-details-marker { display: none; }

.faq-ico {
  flex: none;
  width: 42px; height: 42px;
  display: grid; place-items: center;
  border-radius: 13px;
  background: var(--grad-soft);
  border: 1px solid rgba(34,211,238,.2);
  color: var(--brand);
  font-size: 1.1rem;
  transition: transform .4s var(--ease);
}
.faq[open] .faq-ico { transform: rotate(-8deg) scale(1.05); }

.faq-q { flex: 1; display: flex; flex-direction: column; font-family: var(--head); font-weight: 600; font-size: 1rem; }
.faq-q small { font-family: var(--font); font-weight: 400; font-size: .78rem; color: var(--faint); margin-top: .2rem; }

.faq-toggle {
  flex: none;
  width: 32px; height: 32px;
  display: grid; place-items: center;
  border-radius: 50%;
  background: var(--surface-2);
  border: 1px solid var(--stroke);
  color: var(--brand);
  font-size: .8rem;
  transition: transform .4s var(--ease), background .3s;
}
.faq[open] .faq-toggle { transform: rotate(135deg); background: var(--brand); color: #04121a; }

.faq-a { padding: 0 1.3rem 1.4rem; animation: faqIn .45s var(--ease); }
@keyframes faqIn { from { opacity: 0; transform: translateY(-8px); } to { opacity: 1; transform: none; } }

.faq-a h4 { display: flex; align-items: center; gap: .5rem; font-size: .95rem; color: var(--brand); margin: 1.2rem 0 .8rem; }
.faq-a h4:first-child { margin-top: 0; }

.split { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(230px, 100%), 1fr)); gap: 1.1rem; }

.arrow-list { list-style: none; display: grid; gap: .45rem; }
.arrow-list li { position: relative; padding-left: 1.3rem; font-size: .9rem; color: var(--muted); }
.arrow-list li::before { content: '→'; position: absolute; left: 0; color: var(--ok); }

.stat-card {
  display: grid; place-content: center; text-align: center;
  padding: 1.4rem;
  border-radius: var(--r);
  background: var(--grad-soft);
  border: 1px solid rgba(34,211,238,.2);
}
.stat-card b { font-family: var(--head); font-size: 2.6rem; background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; line-height: 1; }
.stat-card span { display: block; font-size: .88rem; color: #cbd5e5; margin: .3rem 0 .4rem; }
.stat-card small { font-size: .78rem; color: var(--faint); }

.temp-hero {
  text-align: center;
  padding: 1.3rem;
  border-radius: var(--r);
  background: var(--grad-soft);
  border: 1px solid rgba(34,211,238,.2);
  margin-bottom: 1.1rem;
}
.temp-hero b { display: block; font-family: var(--head); font-size: clamp(1.9rem, 5vw, 2.7rem); background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.temp-hero span { font-size: .82rem; color: var(--faint); text-transform: uppercase; letter-spacing: .1em; }

.mini-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(180px, 100%), 1fr)); gap: .85rem; }
.mini-cards.mini-3 { grid-template-columns: repeat(auto-fit, minmax(min(160px, 100%), 1fr)); }
.mini-cards > div {
  padding: 1.05rem;
  border-radius: var(--r);
  background: var(--surface);
  border: 1px solid var(--stroke);
  transition: transform .35s var(--ease), border-color .35s;
}
.mini-cards > div:hover { transform: translateY(-4px); border-color: rgba(34,211,238,.3); }
.mini-cards i { color: var(--brand); font-size: 1.25rem; display: block; margin-bottom: .5rem; }
.mini-cards b { display: block; font-size: .92rem; margin-bottom: .25rem; }
.mini-cards b.big { font-family: var(--head); font-size: 1.9rem; background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.mini-cards span { font-size: .8rem; color: var(--faint); }
.mini-cards p { margin: .3rem 0 0; font-size: .84rem; color: var(--muted); }
.mini-cards .arrow-list { margin-top: .6rem; }

.freq {
  display: inline-block;
  padding: .28rem .8rem;
  border-radius: 999px;
  background: var(--brand-soft);
  border: 1px solid rgba(34,211,238,.24);
  font-size: .76rem; font-weight: 700;
  color: var(--brand);
  margin-bottom: .7rem;
}

.strategy { padding: 1.2rem; border-radius: var(--r); border: 1px solid var(--stroke); }
.strategy h4 { margin-top: 0 !important; }
.strategy p { font-size: .86rem; color: var(--muted); margin: 0 0 .5rem; }
.s-on  { background: rgba(52,211,153,.06);  border-color: rgba(52,211,153,.22); }
.s-on h4  { color: var(--ok) !important; }
.s-off { background: rgba(251,113,133,.06); border-color: rgba(251,113,133,.22); }
.s-off h4 { color: var(--danger) !important; }
.badge-save {
  display: inline-block; margin-top: .8rem;
  padding: .3rem .85rem;
  border-radius: 999px;
  background: var(--surface-2);
  font-family: var(--mono); font-size: .8rem;
  color: var(--text);
}

.brand-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(130px, 100%), 1fr)); gap: .8rem; }
.brand-cards > div {
  text-align: center;
  padding: .95rem .7rem;
  border-radius: var(--r);
  background: var(--surface);
  border: 1px solid var(--stroke);
  transition: transform .35s var(--ease);
}
.brand-cards > div:hover { transform: translateY(-4px); }
.brand-cards b { display: block; font-size: .95rem; margin: .45rem 0 .2rem; }
.brand-cards em { font-style: normal; color: var(--warn); font-size: .85rem; letter-spacing: .05em; }
.lvl { display: inline-block; padding: .2rem .65rem; border-radius: 999px; font-size: .68rem; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; }
.lvl.premium { background: rgba(251,191,36,.14); border: 1px solid rgba(251,191,36,.3); color: #fcd34d; }
.lvl.good    { background: rgba(56,189,248,.12); border: 1px solid rgba(56,189,248,.28); color: #7dd3fc; }

.cause-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(215px, 100%), 1fr)); gap: .85rem; }
.cause-grid > div {
  padding: 1.05rem;
  border-radius: var(--r);
  background: var(--surface);
  border: 1px solid var(--stroke);
  transition: transform .35s var(--ease), border-color .35s;
}
.cause-grid > div:hover { transform: translateY(-4px); border-color: rgba(251,113,133,.3); }
.cause-grid i { color: var(--danger); font-size: 1.25rem; }
.cause-grid b { display: block; margin: .45rem 0 .3rem; font-size: .93rem; }
.cause-grid p { margin: 0 0 .6rem; font-size: .84rem; color: var(--muted); }
.impact { display: inline-block; padding: .2rem .7rem; border-radius: 999px; font-size: .72rem; font-weight: 600; }
.impact.high { background: rgba(251,113,133,.14); color: #ffa8b6; }
.impact.mid  { background: rgba(251,191,36,.14);  color: #fcd34d; }
.impact.low  { background: rgba(52,211,153,.14);  color: #6ee7b7; }

.callout {
  display: flex; align-items: flex-start; gap: .65rem;
  padding: .9rem 1.1rem;
  border-radius: var(--r);
  font-size: .88rem;
  margin-bottom: 1.1rem;
  border: 1px solid;
}
.callout i { margin-top: .15rem; font-size: 1.05rem; }
.callout b { margin-right: .3rem; }
.callout.warn   { background: rgba(251,191,36,.08);  border-color: rgba(251,191,36,.25);  color: #fde68a; }
.callout.brand  { background: rgba(34,211,238,.07);  border-color: rgba(34,211,238,.25);  color: #a5edfb; }
.callout.ok     { background: rgba(52,211,153,.07);  border-color: rgba(52,211,153,.25);  color: #a7f3d0; }
.callout.danger { background: rgba(251,113,133,.08); border-color: rgba(251,113,133,.25); color: #fecdd3; }

/* --------------------------------------------------------- 19. TESTIMONIOS */
.tsm { position: relative; }
.tsm-viewport { overflow: hidden; padding: .5rem; }
.tsm-track { display: flex; gap: 1.5rem; transition: transform .7s var(--ease); }

.tsm-card {
  position: relative;
  flex: 0 0 calc((100% - 3rem) / 3);
  display: flex; flex-direction: column;
  padding: 1.7rem;
  border-radius: var(--r-lg);
  background: linear-gradient(165deg, rgba(255,255,255,.055), rgba(255,255,255,.018));
  border: 1px solid var(--stroke);
  transition: transform .45s var(--ease), border-color .45s, box-shadow .45s;
}
.tsm-card:hover { transform: translateY(-6px); border-color: rgba(34,211,238,.3); box-shadow: var(--sh); }
.tsm-card.is-featured { border-color: rgba(251,191,36,.3); background: linear-gradient(165deg, rgba(251,191,36,.07), rgba(255,255,255,.02)); }

.tsm-badge {
  position: absolute; top: -11px; right: 1.2rem;
  display: inline-flex; align-items: center; gap: .35rem;
  padding: .28rem .8rem;
  border-radius: 999px;
  background: linear-gradient(135deg, #fbbf24, #f59e0b);
  color: #3b2705;
  font-size: .7rem; font-weight: 700;
  letter-spacing: .04em; text-transform: uppercase;
}

.tsm-mark { position: absolute; top: 1.1rem; right: 1.3rem; font-size: 2.4rem; color: rgba(34,211,238,.12); }
.tsm-stars { color: var(--warn); font-size: .85rem; margin-bottom: .9rem; }
.tsm-card > p { flex: 1; color: #c8d3e3; font-size: .92rem; font-style: italic; margin: 0 0 1.3rem; }

.tsm-card footer { display: flex; align-items: center; gap: .8rem; padding-top: 1rem; border-top: 1px solid var(--stroke); }
/* Monograma en vez del mismo icono de persona repetido cinco veces: no
   pretende ser una foto, pero cada cliente se lee como una persona distinta
   en lugar de como una plantilla sin rellenar. Las iniciales van
   aria-hidden porque el nombre completo está justo al lado. */
.av {
  flex: none;
  width: 44px; height: 44px;
  display: grid; place-items: center;
  border-radius: 50%;
  background: var(--grad-soft);
  border: 1px solid rgba(34,211,238,.24);
  color: var(--brand);
  font-family: var(--head);
  font-size: .92rem; font-weight: 600;
  letter-spacing: .02em;
}

.av-1 { background: rgba(34,211,238,.14);  border-color: rgba(34,211,238,.3);  color: #7de8fb; }
.av-2 { background: rgba(251,191,36,.14);  border-color: rgba(251,191,36,.32); color: #fcd34d; }
.av-3 { background: rgba(129,140,248,.14); border-color: rgba(129,140,248,.32); color: #bcc4ff; }
.av-4 { background: rgba(52,211,153,.14);  border-color: rgba(52,211,153,.32); color: #7ce7c0; }
.av-5 { background: rgba(251,113,133,.14); border-color: rgba(251,113,133,.32); color: #ffa8b6; }
.tsm-card footer b { display: block; font-size: .93rem; }
.tsm-card footer small { display: block; font-size: .78rem; color: var(--muted); }
.tsm-card footer em { display: flex; align-items: center; gap: .3rem; font-style: normal; font-size: .74rem; color: var(--faint); margin-top: .15rem; }

/* ------------------------------------------------ Reseñas de Google */
.gr {
  margin-top: 2.2rem;
  padding: 1.3rem 1.4rem;
  border-radius: var(--r-lg);
  background: var(--surface);
  border: 1px solid var(--stroke);
}

.gr-head {
  display: flex; align-items: center; justify-content: space-between;
  flex-wrap: wrap; gap: .8rem;
  padding-bottom: 1rem;
  margin-bottom: .3rem;
  border-bottom: 1px solid var(--stroke);
}
.gr-score { display: flex; align-items: baseline; flex-wrap: wrap; gap: .5rem; }
.gr-stars { color: var(--warn); font-size: .9rem; letter-spacing: .06em; }
.gr-score b {
  font-family: var(--head); font-size: 1.5rem;
  background: var(--grad);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.gr-score > span:last-child { font-size: .84rem; color: var(--muted); }

.gr-list {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.1rem;
}

.gr-item { margin: 0; padding-top: 1rem; }
.gr-item blockquote { margin: 0; }
.gr-item blockquote p {
  margin: 0 0 .6rem;
  font-size: .88rem; font-style: italic; color: #c8d3e3; line-height: 1.5;
}
.gr-item figcaption {
  display: flex; align-items: center; flex-wrap: wrap; gap: .4rem;
  font-size: .76rem; color: var(--faint);
}
.gr-item figcaption b { color: var(--text); font-weight: 600; font-size: .8rem; }
.gr-item figcaption time { font-family: var(--mono); }

/* Distintivo real de Google: un Local Guide con historial pesa más que una
   cuenta sin actividad, y merece decirlo. */
.gr-guide {
  padding: .1rem .45rem;
  border-radius: 999px;
  background: rgba(129,140,248,.14);
  border: 1px solid rgba(129,140,248,.28);
  color: #bcc4ff;
  font-size: .66rem; font-weight: 600;
  letter-spacing: .04em;
}

@media (max-width: 860px) {
  .gr-list { grid-template-columns: 1fr; }
  .gr-item + .gr-item { border-top: 1px solid var(--stroke); }
}

.sat-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(min(160px, 100%), 1fr));
  gap: 1.1rem;
  margin-top: 1.6rem;
}
.sat {
  text-align: center;
  padding: 1.4rem 1rem;
  border-radius: var(--r-lg);
  background: var(--surface);
  border: 1px solid var(--stroke);
  transition: transform .4s var(--ease), border-color .4s, box-shadow .4s;
}
.sat:hover { transform: translateY(-6px); border-color: rgba(34,211,238,.35); box-shadow: var(--glow); }
.sat > i {
  display: grid; place-items: center;
  width: 46px; height: 46px;
  margin: 0 auto .8rem;
  border-radius: 14px;
  background: var(--grad-soft);
  color: var(--brand);
  font-size: 1.2rem;
}
.sat b { display: block; font-family: var(--head); font-size: 1.8rem; background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.sat span { font-size: .8rem; color: var(--faint); }

/* ----------------------------------------------------------- 20. CONTACTO */
/* Mismo registro sobrio que Nosotros: retícula editorial, filetes finos y un
   solo acento. Antes cada fila era una tarjeta con su propio color —cinco
   colores distintos en una misma columna— y eso era lo que le quitaba
   prestancia: el ojo no sabía dónde mirar porque todo gritaba igual. */
.contacto-section { --hair: rgba(255, 255, 255, .1); }

.contact {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  gap: clamp(1.4rem, 3vw, 2.4rem);
  align-items: start;
}

/* Sin .glass: el desenfoque y el degradado pesaban demasiado para un bloque
   que es sobre todo texto. Un filete y una superficie casi plana dejan que
   mande la tipografía. */
.contact-info,
.contact-form {
  padding: clamp(1.4rem, 3vw, 2.1rem);
  border: 1px solid var(--hair);
  border-radius: var(--r-lg);
  background: rgba(255, 255, 255, .022);
}

.ci-head { margin-bottom: 1.5rem; }
.ci-head h3 { font-size: 1.3rem; margin-bottom: 1rem; }
.ci-head .rule { width: 56px; }

/* Filas separadas por filetes en lugar de cajas sueltas */
.ci-list { display: grid; }
.ci-item {
  display: flex; align-items: center; gap: 1rem;
  padding: .95rem .15rem;
  border-top: 1px solid var(--hair);
}
.ci-item:first-child { border-top: 0; padding-top: 0; }

.ci-ico {
  flex: none;
  width: 38px; height: 38px;
  display: grid; place-items: center;
  border-radius: 50%;
  border: 1px solid var(--hair);
  color: var(--muted);
  font-size: .95rem;
  transition: color .35s var(--ease), border-color .35s, background .35s;
}
a.ci-item:hover .ci-ico {
  color: var(--brand);
  border-color: rgba(34,211,238,.45);
  background: rgba(34,211,238,.07);
}

.ci-text { flex: 1; display: flex; flex-direction: column; gap: .15rem; min-width: 0; }
.ci-text small {
  font-family: var(--mono);
  font-size: .68rem; color: var(--faint);
  text-transform: uppercase; letter-spacing: .14em;
}
.ci-text b { font-size: .9rem; font-weight: 500; }
.ci-text address { font-style: normal; font-size: .88rem; line-height: 1.45; }

.ci-arrow { color: var(--faint); font-size: .8rem; transition: transform .3s var(--ease), color .3s; }
a.ci-item:hover .ci-arrow { color: var(--brand); transform: translateX(4px); }

/* Alineado a la izquierda como el resto de la columna: el centrado anterior
   partía la lectura en dos ejes distintos dentro de la misma tarjeta. */
.ci-social { padding-top: 1.4rem; margin-top: 1.2rem; border-top: 1px solid var(--hair); }
.ci-social > span {
  display: block;
  font-family: var(--mono);
  font-size: .68rem; color: var(--faint);
  text-transform: uppercase; letter-spacing: .18em;
  margin-bottom: .9rem;
}
/* Clase propia en lugar de ".ci-social > div": el QR también es un div hijo
   de .ci-social, y un selector de dos clases le ganaba por especificidad al
   .ci-qr de una sola, dejándolo visible en móvil y con el gap equivocado. */
.ci-redes { display: flex; gap: .6rem; }
.soc {
  width: 42px; height: 42px;
  display: grid; place-items: center;
  border-radius: 50%;
  background: transparent;
  border: 1px solid var(--hair);
  font-size: 1.05rem;
  color: var(--muted);
  transition: all .35s var(--ease);
}
.soc:hover { transform: translateY(-4px) scale(1.05); color: #fff; }
.soc.wa:hover { background: #25d366; border-color: #25d366; box-shadow: 0 10px 26px rgba(37,211,102,.35); }
.soc.ig:hover { background: linear-gradient(45deg, #f09433, #dc2743, #bc1888); border-color: transparent; box-shadow: 0 10px 26px rgba(220,39,67,.35); }
.soc.em:hover { background: var(--grad); border-color: transparent; color: #04121a; box-shadow: 0 10px 26px rgba(34,211,238,.3); }

.ci-qr {
  display: flex; align-items: center; gap: .9rem;
  margin-top: 1.3rem;
  padding-top: 1.3rem;
  border-top: 1px solid var(--hair);
}
/* El QR necesita fondo claro para leerse; se le da como acolchado en vez de
   como marco blanco de 2px, que era el elemento más estridente del bloque. */
.ci-qr img { border-radius: 8px; padding: 5px; background: #fff; }
.ci-qr b { display: block; font-size: .86rem; font-weight: 500; }
.ci-qr small { font-size: .75rem; color: var(--faint); }

/* Un QR sólo sirve para escanearlo desde otro dispositivo: en el móvil que
   lo está mostrando no tiene ninguna utilidad, y ahí ya está la fila de
   WhatsApp con el número tocable. */
@media (max-width: 992px) {
  .ci-qr { display: none; }
}

/* Formulario */
.contact-form { position: relative; overflow: hidden; }
/* El panel de éxito recibe el foco por JS para que se anuncie; el contorno
   sobra porque no es un control con el que se interactúe. */
.cf-overlay:focus { outline: none; }
.cf-head { display: flex; align-items: center; gap: .7rem; padding-bottom: 1.2rem; margin-bottom: 1.4rem; border-bottom: 1px solid var(--hair); }
.cf-head i { color: var(--brand); font-size: 1.15rem; }
.cf-head h3 { font-size: 1.2rem; }

/* Aviso de si hay alguien en el taller. Lo escribe initAvisoHorario() desde
   HORARIO, así que no puede quedarse desfasado como la antigua promesa de
   "menos de 12 horas". */
.cf-horario {
  display: flex; align-items: flex-start; gap: .6rem;
  margin: 0 0 1.5rem;
  padding: .8rem 1rem;
  border: 1px solid var(--hair);
  border-radius: var(--r-sm);
  font-size: .84rem; line-height: 1.5;
  color: var(--muted);
}
.cf-horario i { flex: none; margin-top: .15rem; font-size: .95rem; }
.cf-horario.abierto { border-color: rgba(52,211,153,.3);  background: rgba(52,211,153,.06); }
.cf-horario.abierto i { color: var(--ok); }
.cf-horario.cerrado { border-color: rgba(251,191,36,.28); background: rgba(251,191,36,.05); }
.cf-horario.cerrado i { color: var(--warn); }

/* Marca de campo obligatorio. Va aria-hidden en el HTML: el atributo required
   ya se lo dice al lector de pantalla, y un "asterisco" leído en voz alta
   delante de cada etiqueta solo estorba. */
.req { color: var(--brand); font-weight: 400; }

.cf-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(220px, 100%), 1fr)); gap: 1.4rem 1.1rem; }
.field { position: relative; }
.field-full { grid-column: 1 / -1; }

.field input, .field select, .field textarea {
  width: 100%;
  padding: 1.15rem .95rem .55rem;
  border-radius: var(--r-sm);
  background: rgba(255,255,255,.03);
  border: 1px solid var(--stroke);
  color: var(--text);
  font-size: .93rem;
  transition: border-color .3s, background .3s, box-shadow .3s;
  outline: none;
}
.field textarea { resize: vertical; min-height: 120px; }
.field select { appearance: none; cursor: pointer; padding-right: 2.4rem; }
.field select option { background: #0b1120; color: var(--text); }
.field:has(select)::after {
  content: '\F282';
  font-family: 'bootstrap-icons';
  position: absolute; right: 1rem; top: 1.05rem;
  color: var(--faint); font-size: .85rem;
  pointer-events: none;
}

.field label {
  position: absolute; left: .95rem; top: .95rem;
  display: flex; align-items: center; gap: .35rem;
  font-size: .93rem;
  color: var(--faint);
  pointer-events: none;
  transition: all .28s var(--ease);
}
.field select ~ label { pointer-events: none; }

.field input:focus, .field select:focus, .field textarea:focus {
  border-color: var(--brand);
  background: rgba(34,211,238,.04);
  box-shadow: 0 0 0 3px rgba(34,211,238,.1);
}
.field input:focus ~ label,
.field input:not(:placeholder-shown) ~ label,
.field textarea:focus ~ label,
.field textarea:not(:placeholder-shown) ~ label,
.field select:focus ~ label,
.field select.filled ~ label {
  top: .3rem;
  font-size: .7rem;
  letter-spacing: .04em;
  color: var(--brand);
}
.field.invalid input, .field.invalid select, .field.invalid textarea { border-color: var(--danger); }

/* Motivo del error bajo cada campo. Ocupa sitio solo cuando hay texto, para
   que la rejilla no se descuadre con el formulario vacío. */
.field-msg { display: none; margin-top: .35rem; font-size: .78rem; color: var(--danger); }
.field.invalid .field-msg:not(:empty) { display: block; }

/* Campo trampa antispam: fuera de la pantalla en vez de display:none, que
   algunos bots detectan y saltan. */
.hp {
  position: absolute; left: -9999px;
  width: 1px; height: 1px; overflow: hidden;
}

/* Aviso general del servidor. */
.cf-alert {
  display: flex; align-items: center; gap: .55rem;
  margin: 1.2rem 0 0; padding: .8rem 1rem;
  border: 1px solid rgba(251, 113, 133, .35);
  border-radius: 12px;
  background: rgba(251, 113, 133, .1);
  color: var(--text); font-size: .85rem;
}
.cf-alert i { flex: none; color: var(--danger); font-size: 1rem; }

.cf-actions { display: flex; flex-wrap: wrap; gap: .8rem; margin-top: 1.6rem; }
.btn-spin { display: inline-flex; align-items: center; gap: .5rem; }
.cf-note { display: flex; align-items: center; gap: .45rem; margin: 1.1rem 0 0; font-size: .8rem; color: var(--faint); }
.cf-note i { color: var(--ok); }

.cf-overlay {
  position: absolute; inset: 0; z-index: 5;
  display: grid; place-items: center;
  padding: 1.5rem;
  background: rgba(8, 12, 20, .95);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  animation: faqIn .4s var(--ease);
}
.cf-ok { text-align: center; max-width: 380px; }
.cf-ok-ico {
  display: grid; place-items: center;
  width: 72px; height: 72px;
  margin: 0 auto 1.1rem;
  border-radius: 50%;
  background: linear-gradient(135deg, #34d399, #10b981);
  color: #04140a;
  font-size: 2rem;
  animation: popIn .55s var(--ease) backwards;
}
@keyframes popIn { from { transform: scale(0) rotate(-90deg); } to { transform: none; } }
.cf-ok h3 { font-size: 1.35rem; margin-bottom: .6rem; }
.cf-ok p { color: var(--muted); font-size: .9rem; margin: 0 0 1.4rem; }
.cf-ok .btn { margin: .3rem; }

/* --------------------------------------------------------- Ubicación */
/* La portada es la fachada real del taller. El iframe de Google se monta sólo
   al pulsar: hasta entonces la página no hace ni una petición a Google. */
.mapa {
  margin: clamp(1.4rem, 3vw, 2.4rem) 0 0;
  border: 1px solid var(--hair);
  border-radius: var(--r-lg);
  overflow: hidden;
}

.mapa-lienzo { position: relative; aspect-ratio: 21 / 9; background: #080c15; }
/* La foto de la fachada es vertical (765x1020) y este marco es 21:9, así que
   sólo cabe una franja del 32% de su alto. Centrada por defecto cortaría el
   rótulo por la mitad; subiéndola al 34% entra entero. */
.mapa-lienzo img {
  width: 100%; height: 100%;
  object-fit: cover;
  object-position: center 34%;
  filter: grayscale(.45) brightness(.5);
}
.mapa-lienzo iframe { display: block; width: 100%; height: 100%; border: 0; }

.mapa-abrir {
  position: absolute; inset: 0; margin: auto;
  width: max-content; height: max-content;
  display: flex; align-items: center; gap: .85rem;
  padding: .8rem 1.4rem .8rem .8rem;
  border-radius: 999px;
  background: rgba(8, 12, 20, .8);
  border: 1px solid var(--stroke-strong);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  color: var(--text);
  transition: all .35s var(--ease);
}
.mapa-abrir:hover { border-color: var(--brand); background: rgba(34,211,238,.16); transform: scale(1.03); }
.mapa-abrir-ico {
  flex: none;
  width: 36px; height: 36px;
  display: grid; place-items: center;
  border-radius: 50%;
  background: var(--grad);
  color: #04121a;
  font-size: 1rem;
}
.mapa-abrir > span:last-child {
  display: flex; flex-direction: column; align-items: flex-start;
  font-size: .92rem; font-weight: 600; line-height: 1.25;
}
.mapa-abrir small { font-weight: 400; font-size: .72rem; color: var(--faint); }

.mapa figcaption {
  display: flex; align-items: center; justify-content: space-between;
  flex-wrap: wrap; gap: 1rem;
  padding: 1rem 1.3rem;
  border-top: 1px solid var(--hair);
}
.mapa-datos b { display: block; font-size: .95rem; font-weight: 500; }
.mapa-datos small { font-size: .8rem; color: var(--faint); }

@media (max-width: 700px) {
  .mapa-lienzo { aspect-ratio: 16 / 10; }
  .mapa figcaption { flex-direction: column; align-items: stretch; }
}

/* -------------------------------------------------------------- 21. FOOTER */
/* Pie corporativo: banda de contacto, mapa del sitio y línea legal. */

.footer {
  --hair: rgba(255, 255, 255, .1);
  position: relative;
  background: #03050a;
  border-top: 1px solid var(--stroke);
}

/* --- Banda superior de contacto --- */
.f-cta {
  border-bottom: 1px solid var(--hair);
  background:
    radial-gradient(ellipse 70% 140% at 78% 50%, rgba(34, 211, 238, .07), transparent 70%),
    linear-gradient(180deg, rgba(255, 255, 255, .022), transparent);
}
.f-cta-in {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between;
  gap: clamp(1.5rem, 4vw, 3rem);
  padding: clamp(2.4rem, 5vw, 3.6rem) 0;
}
.f-cta-copy { max-width: 46ch; }
.f-cta-copy .overline { margin-bottom: .9rem; }
.f-cta-copy h3 {
  font-size: clamp(1.4rem, 3vw, 2rem);
  font-weight: 600;
  margin-bottom: .5rem;
}
.f-cta-copy p { margin: 0; color: var(--muted); font-size: .95rem; }
.f-cta-actions { display: flex; flex-wrap: wrap; gap: .7rem; }

/* --- Cuerpo --- */
.f-main {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 1.6fr);
  gap: clamp(2rem, 5vw, 4.5rem);
  padding: clamp(2.8rem, 6vw, 4.2rem) 0;
}

.f-identity .brand { margin-bottom: 1.4rem; }

.f-mission {
  max-width: 42ch;
  margin: 0 0 1.9rem;
  font-size: .92rem;
  line-height: 1.75;
  color: var(--muted);
}

/* Bloque de datos tipo membrete */
.f-address { margin: 0 0 1.6rem; display: grid; gap: 1.05rem; }
.f-address dt {
  font-family: var(--mono);
  font-size: .67rem;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--faint);
  margin-bottom: .3rem;
}
.f-address dd {
  margin: 0;
  font-size: .89rem;
  line-height: 1.6;
  color: #c3cede;
}
.f-address a { transition: color .3s; border-bottom: 1px solid transparent; }
.f-address a:hover { color: var(--brand); border-bottom-color: rgba(34, 211, 238, .45); }

/* Mapa del sitio */
.f-links {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(1.5rem, 3vw, 2.5rem);
}
.f-col h4 {
  font-family: var(--mono);
  font-size: .7rem;
  font-weight: 500;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: var(--brand);
  padding-bottom: .9rem;
  margin-bottom: 1.1rem;
  border-bottom: 1px solid var(--hair);
}
.f-col ul { list-style: none; display: grid; gap: .78rem; }
.f-col li { line-height: 1.4; }
.f-col a,
.f-col button {
  display: inline-flex; align-items: center; gap: .45rem;
  padding: 0;
  font-size: .88rem;
  text-align: left;
  color: var(--muted);
  transition: color .3s, transform .3s var(--ease);
}
.f-col a:hover, .f-col button:hover { color: #fff; transform: translateX(3px); }
.f-col i { font-size: .78rem; color: var(--faint); }

.f-identity .status-chip { display: inline-flex; }

/* --- Línea legal --- */
.f-legal {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between;
  gap: 1rem 1.5rem;
  padding: 1.5rem 0 5.5rem;
  border-top: 1px solid var(--hair);
  font-size: .82rem;
  color: var(--faint);
}
.f-legal-links { display: flex; align-items: center; gap: .7rem; }
.f-legal-links a { transition: color .3s; }
.f-legal-links a:hover { color: var(--brand); }

.f-social { display: flex; gap: .5rem; }
.f-social a {
  width: 36px; height: 36px;
  display: grid; place-items: center;
  border: 1px solid var(--hair);
  border-radius: 50%;
  font-size: .95rem;
  color: var(--muted);
  transition: all .35s var(--ease);
}
.f-social a:hover { color: #fff; border-color: var(--brand); background: rgba(34, 211, 238, .08); }

/* --------------------------------------------------------- 22. FAB / TOP */
.fab-wa {
  position: fixed; bottom: 1.6rem; right: 1.6rem; z-index: 600;
  width: 58px; height: 58px;
  display: grid; place-items: center;
  border-radius: 50%;
  background: linear-gradient(135deg, #25d366, #12a150);
  color: #fff;
  font-size: 1.6rem;
  box-shadow: 0 14px 34px rgba(37,211,102,.4);
  transition: transform .4s var(--ease), box-shadow .4s;
}
.fab-wa:hover { transform: scale(1.1) rotate(6deg); box-shadow: 0 18px 44px rgba(37,211,102,.55); }
.fab-ping {
  position: absolute; inset: 0;
  border-radius: 50%;
  border: 2px solid rgba(37,211,102,.55);
  animation: ping 2.2s var(--ease-2) infinite;
}
@keyframes ping { 0% { transform: scale(1); opacity: .8; } 100% { transform: scale(1.7); opacity: 0; } }

.to-top {
  position: fixed; bottom: 1.6rem; right: 6.3rem; z-index: 600;
  width: 46px; height: 46px;
  display: grid; place-items: center;
  border-radius: 50%;
  background: rgba(11,17,28,.9);
  border: 1px solid var(--stroke-strong);
  color: var(--text);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  opacity: 0; visibility: hidden; transform: translateY(14px);
  transition: all .45s var(--ease);
}
.to-top.on { opacity: 1; visibility: visible; transform: none; }
.to-top:hover { background: var(--grad); color: #04121a; border-color: transparent; }

/* -------------------------------------------------------------- 23. MODAL */
.modal-sources { display: none; }

.modal-root { position: fixed; inset: 0; z-index: 1000; display: grid; place-items: center; padding: 1.2rem; }
.modal-scrim {
  position: absolute; inset: 0;
  background: rgba(3, 5, 10, .8);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  opacity: 0;
  transition: opacity .4s;
}
.modal-root.on .modal-scrim { opacity: 1; }

.modal-shell {
  position: relative;
  width: min(100%, 780px);
  max-height: min(88vh, 900px);
  display: flex; flex-direction: column;
  border-radius: var(--r-xl);
  background: #0a0e18;
  border: 1px solid var(--stroke-strong);
  box-shadow: var(--sh-lg);
  overflow: hidden;
  opacity: 0;
  transform: translateY(28px) scale(.97);
  transition: all .45s var(--ease);
}
.modal-root.on .modal-shell { opacity: 1; transform: none; }

.modal-x {
  position: absolute; top: 1rem; right: 1rem; z-index: 4;
  width: 40px; height: 40px;
  display: grid; place-items: center;
  border-radius: 50%;
  background: rgba(5,8,15,.7);
  border: 1px solid var(--stroke-strong);
  color: #fff;
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  transition: all .35s var(--ease);
}
.modal-x:hover { background: var(--danger); border-color: transparent; transform: rotate(90deg); }

.modal-content { display: flex; flex-direction: column; overflow: hidden; }

/* Modal — hero */
.m-hero { position: relative; height: clamp(170px, 26vw, 230px); flex: none; }
.m-hero img { width: 100%; height: 100%; object-fit: cover; }
.m-hero::after { content: ''; position: absolute; inset: 0; background: linear-gradient(to top, #0a0e18 4%, rgba(10,14,24,.35) 60%, rgba(10,14,24,.55)); }
.m-hero-in { position: absolute; bottom: 1.2rem; left: clamp(1.2rem, 3vw, 1.8rem); right: 1.2rem; z-index: 2; }
.m-hero-in .tag { position: static; display: inline-flex; margin-bottom: .55rem; }
.m-hero-in h2 { font-size: clamp(1.4rem, 3.4vw, 1.9rem); }
.m-price {
  position: absolute; top: 1rem; left: clamp(1.2rem, 3vw, 1.8rem); z-index: 2;
  padding: .38rem .9rem;
  border-radius: 999px;
  background: rgba(5,8,15,.75);
  border: 1px solid rgba(34,211,238,.4);
  font-family: var(--mono); font-size: .8rem;
  color: var(--brand);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
}
.m-price-urgent { color: #ffa8b6; border-color: rgba(251,113,133,.45); }

/* Modal — perfil */
.m-profile {
  display: flex; align-items: center; gap: 1.2rem;
  padding: clamp(1.6rem, 4vw, 2.2rem) clamp(1.2rem, 3vw, 1.8rem);
  background: linear-gradient(135deg, rgba(34,211,238,.13), rgba(99,102,241,.1));
  border-bottom: 1px solid var(--stroke);
  flex: none;
}
.m-avatar { position: relative; flex: none; }
.m-avatar img {
  width: 92px; height: 92px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid rgba(34,211,238,.5);
  box-shadow: 0 0 26px rgba(34,211,238,.3);
}
.m-verified {
  position: absolute; bottom: 2px; right: 2px;
  width: 26px; height: 26px;
  display: grid; place-items: center;
  border-radius: 50%;
  background: var(--ok);
  color: #04140a;
  font-size: .8rem;
  border: 2px solid #0a0e18;
}
.m-profile h2 { font-size: clamp(1.3rem, 3vw, 1.7rem); margin-bottom: .3rem; }
.m-role { margin: 0 0 .6rem; font-size: .88rem; color: var(--brand); }
.m-badges { display: flex; flex-wrap: wrap; gap: .45rem; }
.m-badges span {
  display: inline-flex; align-items: center; gap: .35rem;
  padding: .28rem .75rem;
  border-radius: 999px;
  background: var(--surface-2);
  border: 1px solid var(--stroke);
  font-size: .74rem; font-weight: 600;
  color: #cbd5e5;
}

/* Modal — body */
.m-body { padding: clamp(1.3rem, 3vw, 1.8rem); overflow-y: auto; flex: 1; }
.m-body::-webkit-scrollbar { width: 7px; }
.m-body::-webkit-scrollbar-thumb { background: rgba(34,211,238,.3); border-radius: 99px; }

.m-lead { font-size: .97rem; color: #cbd5e5; margin: 0 0 1.4rem; }
.m-h4 { display: flex; align-items: center; gap: .5rem; font-size: 1rem; color: var(--brand); margin: 1.6rem 0 .9rem; }
.m-h4:first-child { margin-top: 0; }

.m-feats { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(200px, 100%), 1fr)); gap: .8rem; }
.m-feats-3 { grid-template-columns: repeat(auto-fit, minmax(min(160px, 100%), 1fr)); }
.m-feats > div {
  padding: 1rem;
  border-radius: var(--r);
  background: var(--surface);
  border: 1px solid var(--stroke);
  transition: transform .35s var(--ease), border-color .35s;
}
.m-feats > div:hover { transform: translateY(-3px); border-color: rgba(34,211,238,.3); }
.m-feats i { color: var(--brand); font-size: 1.2rem; }
.m-feats b { display: block; margin: .5rem 0 .2rem; font-size: .9rem; }
.m-feats small { font-size: .8rem; color: var(--faint); line-height: 1.5; display: block; }

.m-steps { list-style: none; counter-reset: s; display: grid; gap: .6rem; }
.m-steps li {
  counter-increment: s;
  display: flex; align-items: center; gap: .8rem;
  padding: .75rem .95rem;
  border-radius: var(--r-sm);
  background: var(--surface);
  border: 1px solid var(--stroke);
  font-size: .88rem;
  color: #c3cede;
  transition: all .35s var(--ease);
}
.m-steps li::before {
  content: counter(s, decimal-leading-zero);
  flex: none;
  width: 32px; height: 32px;
  display: grid; place-items: center;
  border-radius: 10px;
  background: var(--grad-soft);
  border: 1px solid rgba(34,211,238,.24);
  font-family: var(--mono);
  font-size: .78rem;
  color: var(--brand);
}
.m-steps li:hover { transform: translateX(4px); border-color: rgba(34,211,238,.3); }

.m-modes { list-style: none; display: grid; gap: .6rem; }
.m-modes li {
  display: flex; align-items: center; gap: .8rem;
  padding: .75rem .95rem;
  border-radius: var(--r-sm);
  background: var(--surface);
  border: 1px solid var(--stroke);
  font-size: .88rem; color: #c3cede;
}
.m-modes i { color: var(--brand); font-size: 1.05rem; }

.m-brands { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; margin-top: 1.5rem; }
.m-brands small { width: 100%; font-size: .78rem; color: var(--faint); text-transform: uppercase; letter-spacing: .08em; }
.m-brands span, .m-brands .dl {
  display: inline-flex; align-items: center; gap: .4rem;
  padding: .4rem .85rem;
  border-radius: 999px;
  background: var(--surface);
  border: 1px solid var(--stroke);
  font-size: .8rem;
  color: var(--muted);
  transition: all .3s var(--ease);
}
.m-brands span:hover, .m-brands .dl:hover { color: var(--brand); border-color: rgba(34,211,238,.35); transform: translateY(-2px); }

.m-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: .8rem; margin: 1.4rem 0; text-align: center; }
.m-stats > div { padding: .95rem .5rem; border-radius: var(--r); background: var(--grad-soft); border: 1px solid rgba(34,211,238,.18); }
.m-stats b { display: block; font-family: var(--head); font-size: clamp(1.2rem, 3vw, 1.6rem); background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.m-stats span { font-size: .74rem; color: var(--faint); }

.m-certs { display: grid; gap: .7rem; }
.m-certs > div {
  display: flex; align-items: center; gap: .9rem;
  padding: .9rem 1rem;
  border-radius: var(--r);
  background: var(--surface);
  border: 1px solid var(--stroke);
  transition: all .35s var(--ease);
}
.m-certs > div:hover { transform: translateX(4px); border-color: rgba(34,211,238,.3); }
.m-certs > div > i {
  flex: none;
  width: 42px; height: 42px;
  display: grid; place-items: center;
  border-radius: 13px;
  background: var(--grad-soft);
  color: var(--brand);
  font-size: 1.1rem;
}
.m-certs b { display: block; font-size: .9rem; }
.m-certs small { font-size: .8rem; color: var(--faint); }

/* Modal — artículo */
.m-meta {
  display: flex; flex-wrap: wrap; align-items: center; gap: .45rem;
  padding-bottom: 1rem;
  margin-bottom: 1.3rem !important;
  border-bottom: 1px solid var(--stroke);
  font-family: var(--mono);
  font-size: .76rem !important;
  letter-spacing: .05em;
  color: var(--faint) !important;
}
.m-meta i { color: var(--brand); }
.m-meta span { color: var(--stroke-strong); }

.m-article p { color: var(--muted); font-size: .93rem; margin: 0 0 1rem; }
.m-article .m-lead { font-size: 1rem; color: #cbd5e5; line-height: 1.75; }
.m-article ul, .m-article ol { padding-left: 1.3rem; margin: 0 0 1.2rem; display: grid; gap: .45rem; }
.m-article li { font-size: .91rem; color: var(--muted); }
.m-article li::marker { color: var(--brand); }
.m-article strong { color: #dbeafe; }

/* Modal — footer */
.m-foot {
  display: flex; flex-wrap: wrap; gap: .7rem;
  padding: 1.1rem clamp(1.2rem, 3vw, 1.8rem);
  border-top: 1px solid var(--stroke);
  background: rgba(255,255,255,.02);
  flex: none;
}
.m-foot .btn { flex: 1; min-width: 165px; }
.m-foot-3 .btn { min-width: 145px; font-size: .85rem; }

/* ---------------------------------------------------------- 24. RESPONSIVE */
@media (max-width: 1100px) {
  .tsm-card { flex: 0 0 calc((100% - 1.5rem) / 2); }
  .f-main { grid-template-columns: 1fr; }
  .about-pillars { grid-template-columns: repeat(2, 1fr); }
  .pillar:nth-child(3) { border-left: 0; }
}

/* Navegación móvil. Punto de corte propio a 1150px: el menú de escritorio
   necesita ~1036px y no cabe hasta bien pasados los 1100px, así que se cambia
   a hamburguesa antes de que la barra se desborde. Si se cambia este valor,
   actualizar también el matchMedia de initNav() en script.js. */
@media (max-width: 1150px) {
  .nav-burger { display: block; }
  .status-chip { display: none; }

  /* Altura constante: en pantallas pequeñas el encogido al hacer scroll se
     percibe como si la barra se recortara. */
  .nav, .nav.stuck { padding: .7rem 0; }

  .nav-links {
    position: fixed; top: 0; right: 0; bottom: 0;
    width: min(340px, 86vw);
    z-index: 750;
    flex-direction: column;
    align-items: stretch;
    gap: .25rem;
    padding: 6rem 1.2rem 2rem;
    background: #080c15;
    border-left: 1px solid var(--stroke);
    box-shadow: -20px 0 60px rgba(0,0,0,.55);
    overflow-y: auto;
    transform: translateX(100%);
    transition: transform .45s var(--ease);
  }
  .nav-links.on { transform: none; }
  /* La marca y el botón hamburguesa quedan por encima del panel deslizante */
  .brand, .nav-burger { position: relative; z-index: 760; }
  .nav-link { padding: .8rem 1rem; font-size: .98rem; border-radius: var(--r-sm); }
  .nav-drop-btn { width: 100%; justify-content: space-between; }
  .nav-drop-menu,
  .nav-drop.open .nav-drop-menu {
    position: static;
    /* Debe anular el translateX(-50%) del menú flotante de escritorio: si no,
       el submenú se desplaza media anchura a la izquierda y se recorta fuera
       del cajón. Necesita el mismo peso que .nav-drop.open .nav-drop-menu. */
    transform: none;
    min-width: 0;
    max-width: 100%;
    opacity: 1; visibility: visible;
    background: transparent;
    border: 0; box-shadow: none;
    padding: .2rem 0 .4rem .6rem;
    border-left: 1px solid var(--stroke);
    margin-left: 1rem;
  }
  .nav-drop-menu { display: none; }
  .nav-drop.open .nav-drop-menu { display: block; }
  .nav-drop-menu a { padding: .6rem .7rem; }
  .nav-drop-menu span { min-width: 0; }
  .nav-drop-menu small { white-space: normal; }
  /* En el cajón los enlaces van a ancho completo: el margen lateral que en
     escritorio lo separa de "Contacto" aquí lo dejaría desalineado. */
  .nav-shop { margin: .5rem 0 0; }
  .nav-cta { margin: 1rem 0 0; justify-content: center; }
  .f-identity .status-chip { display: inline-flex; }
}

@media (max-width: 992px) {
  html { scroll-padding-top: 80px; }

  /* Hero */
  .hero-grid { grid-template-columns: 1fr; text-align: center; }
  .hero-copy { display: flex; flex-direction: column; align-items: center; }
  .hero-lead { margin-inline: auto; }
  .hero-actions, .hero-stats { justify-content: center; }
  .hero { min-height: 0; padding: 7rem 0 4rem; }
  .hero-visual { order: -1; min-height: 0; margin-bottom: .5rem; }
  .orbiter { width: min(240px, 58vw); }
  .orb { width: 42px; height: 42px; font-size: 1rem; border-radius: 13px; }
  .orb.o1, .orb.o3 { margin-left: -21px; }
  .orb.o2, .orb.o4 { margin-top: -21px; }
  .float-card { display: none; }
  .scroll-cue { display: none; }

  /* Contacto */
  .contact { grid-template-columns: 1fr; }

  /* Nosotros */
  .about-top { grid-template-columns: 1fr; gap: 2.4rem; }
  .about-frame::before { inset: 14px -14px -14px 14px; }
  .about-figures { grid-template-columns: repeat(2, 1fr); }
  .about-figures > div:nth-child(3) { border-left: 0; }
  .about-figures > div:nth-child(-n+2) { border-bottom: 1px solid var(--hair); }

  /* Footer */
  .f-cta-in { flex-direction: column; align-items: flex-start; }
  .f-identity .status-chip { display: inline-flex; }
}

@media (max-width: 768px) {
  .board { grid-template-columns: 1fr; }
  .tsm-card { flex: 0 0 100%; }
  .about-frame-img { height: 250px; }
  .f-links { grid-template-columns: 1fr; gap: 1.8rem; }
  /* Los rótulos de los botones no se parten: en móvil se apilan a ancho completo */
  .f-cta-actions { width: 100%; flex-direction: column; align-items: stretch; }
  .f-legal { flex-direction: column; align-items: flex-start; }
  .m-stats { grid-template-columns: 1fr; }
  .m-foot { flex-direction: column; }
  .m-foot .btn { width: 100%; }
  .to-top { right: 1.6rem; bottom: 6.2rem; }
  .tl-item { grid-template-columns: 44px 1fr; gap: .9rem; }
  .tl-node { width: 44px; height: 44px; font-size: 1rem; border-radius: 14px; }
  .tl-rail { left: 21px; }
  .kpi { min-width: 0; flex: 1 1 140px; padding: .9rem 1rem; }
}

@media (max-width: 520px) {
  /* Solo la marca de la barra superior pierde el descriptor; el pie lo conserva */
  .nav .brand-copy small { display: none; }
  .hero-stats { gap: 1.1rem; }
  .hstat-sep { display: none; }
  .filter-bar { gap: .4rem; }
  .pill { padding: .5rem .9rem; font-size: .8rem; }
  .faq summary { padding: .9rem 1rem; gap: .7rem; }
  .faq-a { padding: 0 1rem 1.2rem; }
  .m-profile { flex-direction: column; text-align: center; }
  .m-badges { justify-content: center; }

  /* Nosotros / footer en pantallas estrechas: una sola columna, sin filetes verticales */
  .about-pillars { grid-template-columns: 1fr; }
  .pillar { border-left: 0; }
  .about-figures { grid-template-columns: 1fr; }
  .about-figures > div { border-left: 0; border-bottom: 1px solid var(--hair); text-align: left; }
  .about-figures > div:last-child { border-bottom: 0; }
  .about-frame::before { display: none; }
}

/* ------------------------------------------ 25. ROBUSTEZ EN PANTALLA ESTRECHA */
/* Los hijos de grid y flex tienen min-width:auto por defecto, así que no bajan
   de su ancho mínimo de contenido y empujan la página hacia el scroll lateral.
   Estas reglas les permiten encogerse y parten las cadenas largas. */
.hero-grid > *,
.about-top > *,
.contact > *,
.f-main > *,
.f-cta-in > *,
.svc, .post, .news, .bento-card, .tsm-card,
.ci-item, .ci-text, .m-feats > *, .tl-item, .tl-card {
  min-width: 0;
}

/* Correos, URLs y códigos no tienen puntos de corte naturales */
.ci-text b,
.f-address dd,
.m-brands span,
.code {
  overflow-wrap: anywhere;
}

.footer, .f-main, .f-legal, .contact, .about-top { max-width: 100%; }

/* Objetivos táctiles: en pantallas de dedo, mínimo ~40px de alto real */
@media (max-width: 900px) {
  .link-btn { padding: .55rem 0; }

  .post-foot, .news-foot, .svc-foot { flex-wrap: wrap; row-gap: .3rem; }

  /* Los puntos siguen siendo pequeños; se amplía sólo su zona sensible.
     El ensanche lateral se queda por debajo del hueco entre puntos (7.2px)
     para que las zonas de dos puntos vecinos no se solapen. */
  .dots button { position: relative; }
  .dots button::after {
    content: '';
    position: absolute;
    inset: -16px -3px;
  }

  .f-col ul { gap: .1rem; }
  .f-col a, .f-col button { padding: .7rem 0; }
  .f-legal-links a { padding: .7rem 0; }
  .f-address a { display: inline-block; padding: .7rem 0; }
  .f-social a { width: 44px; height: 44px; }
  .m-brands span, .m-brands .dl { padding: .55rem .9rem; }
  .pill { padding: .7rem 1.05rem; }
}

/* ---------------------------------------------------------- 26. IMPRESIÓN */
@media print {
  .nav, .fab-wa, .to-top, .preloader, .cursor-glow, .scroll-progress,
  .marquee-band, .modal-root, .scroll-cue { display: none !important; }
  body { background: #fff; color: #000; }
  .section { padding: 1.5rem 0; }
}
