/* ============================================================
   SOMAG — Administración de Consorcios · CABA
   Sitio vitrina (producción). CSS plano, sin build.
   Aesthetic: editorial-luxury sobrio para público 40–70.
   Contraste WCAG AA verificado:
     - Oro sobre claro = --gold-ink #7d5a1e (5.56:1 bone / 4.96:1 cream)
     - Oro brillante (--gold-400) sólo sobre navy (7.89:1)
     - Foco: outline navy sobre claro, oro-400 sobre navy
   ============================================================ */

:root {
  /* Paleta SOMAG (del logo) */
  --navy-900: #16243f;
  --navy-800: #1e2e4e;
  --gold-500: #c8a24b;   /* oro brillante — sólo decorativo o sobre navy */
  --gold-400: #d6b568;   /* oro claro — texto/iconos sobre navy */
  --gold-ink: #7d5a1e;   /* oro tinta — texto/iconos sobre claro (AA) */
  --cream-300: #e7d7b8;
  --cream-100: #ede4d3;
  --bone: #f5f1e9;
  --paper: #fbf9f4;      /* tarjetas sobre bone */
  --ink: #1a1a1a;
  --ink-soft: #4a4a4a;   /* 7.86:1 sobre bone */

  --maxw: 1200px;
  --gutter: clamp(1.25rem, 4vw, 2rem);
  --section-y: clamp(4.5rem, 9vw, 8rem);

  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);

  --r-sm: 8px;
  --r-md: 12px;
  --r-lg: 18px;
  --r-pill: 999px;

  --font-display: "Fraunces", Georgia, "Times New Roman", serif;
  --font-body: "Mulish", system-ui, -apple-system, "Segoe UI", sans-serif;
}

/* ---------- Reset / base ---------- */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  font-family: var(--font-body);
  background: var(--bone);
  color: var(--ink);
  line-height: 1.65;
  font-size: 1.0625rem;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}
body.menu-locked { overflow: hidden; }
img { max-width: 100%; display: block; height: auto; }
a { color: inherit; }
:focus:not(:focus-visible) { outline: none; }
:focus-visible {
  outline: 2px solid var(--navy-900);
  outline-offset: 3px;
  border-radius: 2px;
}
.band-navy :focus-visible,
.contacto :focus-visible { outline-color: var(--gold-400); }

.skip-link {
  position: absolute; left: 1rem; top: -3rem; z-index: 200;
  background: var(--navy-900); color: var(--bone);
  padding: 0.7rem 1.1rem; border-radius: var(--r-sm);
  text-decoration: none; font-weight: 700;
  transition: top 0.2s var(--ease);
}
.skip-link:focus { top: 1rem; }

/* Sentinel para la sombra del nav (IntersectionObserver, sin scroll listener) */
#top-sentinel {
  position: absolute; top: 0; left: 0;
  width: 1px; height: 8px;
  pointer-events: none;
}

/* ---------- Tipografía ---------- */
h1, h2, h3 {
  font-family: var(--font-display);
  font-weight: 500;
  line-height: 1.08;
  letter-spacing: -0.012em;
  color: var(--navy-900);
}
h1 { font-size: clamp(2.45rem, 6.2vw, 4.1rem); }
h2 { font-size: clamp(1.85rem, 4.4vw, 3rem); }
h3 { font-size: 1.2rem; line-height: 1.25; }
.em-serif { font-style: italic; color: var(--gold-ink); }

.eyebrow {
  display: inline-block;
  font-family: var(--font-body);
  font-weight: 700; text-transform: uppercase;
  letter-spacing: 0.22em; font-size: 0.72rem;
  color: var(--gold-ink);
}

/* ---------- Layout ---------- */
.container { width: 100%; max-width: var(--maxw); margin-inline: auto; padding-inline: var(--gutter); }
.container-narrow { max-width: 760px; }
.section { padding-block: var(--section-y); }
.band-bone { background: var(--bone); }
.band-cream { background: var(--cream-100); }
.band-navy { background: var(--navy-900); color: var(--bone); }
.band-navy h1, .band-navy h2, .band-navy h3 { color: var(--bone); }
.band-navy .eyebrow { color: var(--gold-400); }
.lead { font-size: clamp(1.05rem, 1.6vw, 1.25rem); color: var(--ink-soft); }
.band-navy .lead { color: var(--cream-300); }

.section-head { max-width: 46rem; margin-bottom: clamp(2.5rem, 5vw, 4rem); }
.section-head .eyebrow { margin-bottom: 0.9rem; }
.section-head.center { margin-inline: auto; text-align: center; }

/* ---------- Reveal on scroll (sólo con JS) ---------- */
.js [data-reveal] {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.8s var(--ease-out), transform 0.8s var(--ease-out);
}
.js [data-reveal].is-in { opacity: 1; transform: none; }
.js [data-reveal][data-reveal-delay="1"] { transition-delay: 0.08s; }
.js [data-reveal][data-reveal-delay="2"] { transition-delay: 0.16s; }
.js [data-reveal][data-reveal-delay="3"] { transition-delay: 0.24s; }

/* ---------- NAV ---------- */
.nav {
  position: sticky; top: 0; z-index: 50;
  background: rgba(245, 241, 233, 0.78);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid transparent;
  transition: background-color 0.4s var(--ease), border-color 0.4s var(--ease), box-shadow 0.4s var(--ease);
}
.nav.is-scrolled {
  background: rgba(245, 241, 233, 0.95);
  border-bottom-color: rgba(26, 26, 26, 0.08);
  box-shadow: 0 6px 24px rgba(26, 26, 26, 0.06);
}
.nav-inner {
  max-width: var(--maxw); margin-inline: auto;
  display: flex; align-items: center; justify-content: space-between;
  padding: 0.85rem var(--gutter);
}
.brand { display: flex; align-items: center; gap: 0.7rem; text-decoration: none; }
.brand-mark { width: auto; height: 32px; flex: 0 0 auto; }
.brand-name { font-family: var(--font-display); font-weight: 600; font-size: 1.55rem; color: var(--navy-900); line-height: 1; }

.nav-links { display: none; align-items: center; gap: 2rem; }
@media (min-width: 900px) { .nav-links { display: flex; } }
.nav-link { font-size: 0.88rem; text-decoration: none; color: var(--ink-soft); transition: color 0.25s var(--ease); }
.nav-link:hover { color: var(--navy-900); }

.menu-toggle {
  display: inline-grid; place-items: center;
  width: 44px; height: 44px; background: transparent; border: 0; cursor: pointer;
  color: var(--navy-900);
}
@media (min-width: 900px) { .menu-toggle { display: none; } }
.menu-toggle svg { width: 26px; height: 26px; }

/* Menú mobile */
.mobile-menu {
  position: fixed; inset: 0; z-index: 60;
  display: flex; flex-direction: column; justify-content: center; gap: 1.4rem;
  padding: 2rem; background: var(--bone);
  transform: translateY(-100%); transition: transform 0.45s var(--ease);
}
.mobile-menu.is-open { transform: none; }
.mobile-menu a { font-family: var(--font-display); font-size: 1.7rem; text-decoration: none; color: var(--navy-900); }
.mobile-menu .mm-cta { font-family: var(--font-body); font-size: 1rem; margin-top: 0.5rem; }
.mm-close {
  position: absolute; top: 1.1rem; right: 1.1rem;
  width: 44px; height: 44px; background: transparent; border: 0; cursor: pointer; color: var(--navy-900);
}
.mm-close svg { width: 26px; height: 26px; }

/* ---------- Botones ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 0.6rem;
  padding: 0.95rem 1.5rem; border-radius: var(--r-pill);
  text-decoration: none; font-weight: 700; font-size: 0.98rem; letter-spacing: 0.01em;
  border: 1px solid transparent; cursor: pointer;
  transition: transform 0.25s var(--ease), background-color 0.3s var(--ease), color 0.3s var(--ease), box-shadow 0.3s var(--ease), border-color 0.3s var(--ease);
}
.btn svg { width: 20px; height: 20px; flex: 0 0 auto; }
.btn:active { transform: scale(0.985); }

.btn-primary { background: var(--navy-900); color: var(--bone); }
.btn-primary:hover { background: var(--navy-800); box-shadow: 0 14px 30px rgba(22, 36, 63, 0.22); }
.btn-ghost { border-color: var(--gold-ink); color: var(--gold-ink); background: transparent; }
.btn-ghost:hover { background: var(--gold-ink); color: var(--bone); }

/* Oro brillante para CTA sobre navy */
.band-navy .btn-primary, .contacto .btn-primary { background: var(--gold-500); color: var(--navy-900); }
.band-navy .btn-primary:hover, .contacto .btn-primary:hover { background: var(--gold-400); box-shadow: 0 14px 30px rgba(200, 162, 75, 0.28); }

/* Botón WhatsApp */
.btn-wa { background: var(--navy-900); color: var(--bone); }
.btn-wa:hover { background: var(--navy-800); box-shadow: 0 14px 30px rgba(22, 36, 63, 0.22); }
.contacto .btn-wa { background: #fff; color: var(--navy-900); }
.contacto .btn-wa:hover { background: var(--cream-100); }
/* Icono "botón en botón" */
.btn .ic-pill {
  display: inline-grid; place-items: center;
  width: 28px; height: 28px; border-radius: 50%;
  background: rgba(255, 255, 255, 0.16); margin-right: -0.4rem;
  transition: transform 0.3s var(--ease);
}
.btn-ghost .ic-pill, .contacto .btn-wa .ic-pill { background: rgba(22, 36, 63, 0.1); }
.btn:hover .ic-pill { transform: translateX(3px); }
.btn .ic-pill svg { width: 15px; height: 15px; }

/* ---------- HERO ---------- */
.hero { padding-top: clamp(3.5rem, 7vw, 6rem); padding-bottom: clamp(3.5rem, 7vw, 6rem); }
.hero-grid { display: grid; gap: clamp(2.5rem, 5vw, 4rem); align-items: center; }
@media (min-width: 940px) { .hero-grid { grid-template-columns: 1.15fr 0.85fr; } }
.hero h1 { margin: 1.4rem 0; }
.hero .lead { max-width: 34rem; }
.hero-cta { display: flex; flex-wrap: wrap; gap: 1rem; margin-top: 2.2rem; }

/* Badge RPAC */
.rpac-badge {
  display: inline-flex; align-items: center; gap: 0.55rem;
  padding: 0.5rem 1rem; border-radius: var(--r-pill);
  font-size: 0.8rem; font-weight: 700; letter-spacing: 0.02em;
  background: #fff; color: var(--navy-900);
  border: 1px solid rgba(22, 36, 63, 0.14);
  box-shadow: 0 4px 14px rgba(26, 26, 26, 0.05);
}
.rpac-badge svg { width: 19px; height: 19px; color: var(--gold-ink); flex: 0 0 auto; }
.band-navy .rpac-badge { background: rgba(214, 181, 104, 0.12); color: var(--cream-300); border-color: rgba(214, 181, 104, 0.35); }
.band-navy .rpac-badge svg { color: var(--gold-400); }

/* Tarjeta de confianza (double-bezel) en el hero */
.trust-card-shell {
  background: rgba(22, 36, 63, 0.04);
  border: 1px solid rgba(22, 36, 63, 0.08);
  border-radius: var(--r-lg);
  padding: 0.5rem;
}
.trust-card {
  background: var(--navy-900); color: var(--bone);
  border-radius: calc(var(--r-lg) - 0.4rem);
  padding: clamp(1.6rem, 3vw, 2.2rem);
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.08), 0 24px 50px rgba(22, 36, 63, 0.18);
}
.trust-card .tc-label { font-size: 0.7rem; text-transform: uppercase; letter-spacing: 0.2em; color: var(--gold-400); font-weight: 700; }
.trust-card .tc-name { font-family: var(--font-display); font-size: 1.5rem; margin: 0.5rem 0 0.15rem; color: var(--bone); }
.trust-card .tc-role { font-size: 0.92rem; color: var(--cream-300); }
.trust-card .tc-list { list-style: none; padding: 0; margin: 1.4rem 0 0; display: grid; gap: 0.85rem; }
.trust-card .tc-list li { display: flex; align-items: flex-start; gap: 0.65rem; font-size: 0.95rem; color: var(--bone); }
.trust-card .tc-list svg { width: 19px; height: 19px; color: var(--gold-400); flex: 0 0 auto; margin-top: 0.15rem; }
.trust-card .tc-foot { margin-top: 1.5rem; padding-top: 1.3rem; border-top: 1px solid rgba(245, 241, 233, 0.14); display: grid; gap: 0.6rem; }
.tc-contact { display: inline-flex; align-items: center; gap: 0.55rem; color: var(--cream-300); text-decoration: none; font-size: 0.95rem; transition: color 0.25s var(--ease); }
.tc-contact:hover { color: var(--gold-400); }
.tc-contact svg { width: 17px; height: 17px; color: var(--gold-400); flex: 0 0 auto; }

/* ---------- Tira de confianza (strip) ---------- */
.trust-strip { border-block: 1px solid rgba(26, 26, 26, 0.08); background: var(--paper); }
.trust-strip-inner {
  max-width: var(--maxw); margin-inline: auto; padding: 1.1rem var(--gutter);
  display: flex; flex-wrap: wrap; gap: 0.75rem 2rem; align-items: center; justify-content: center;
}
.trust-item { display: inline-flex; align-items: center; gap: 0.5rem; font-size: 0.9rem; font-weight: 600; color: var(--navy-900); }
.trust-item svg { width: 18px; height: 18px; color: var(--gold-ink); flex: 0 0 auto; }
.trust-sep { width: 1px; height: 18px; background: rgba(26, 26, 26, 0.14); display: none; }
@media (min-width: 760px) { .trust-sep { display: block; } }

/* ---------- MANIFIESTO ---------- */
.manifiesto { text-align: center; }
.manifiesto .prose { display: grid; gap: 1.3rem; margin-top: 1.8rem; font-size: clamp(1.05rem, 1.7vw, 1.25rem); color: var(--ink-soft); }
.manifiesto .prose strong { color: var(--navy-900); font-weight: 700; }

/* Servicios y "Cómo trabajamos": estilos en los bloques version-c de más abajo
   (.svc-stack / .svc-card-c y .como-grid / .proceso). */

/* ---------- PILARES ---------- */
.grid-pilares { display: grid; gap: clamp(1.8rem, 3vw, 2.5rem); grid-template-columns: 1fr; }
@media (min-width: 560px) { .grid-pilares { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 980px) { .grid-pilares { grid-template-columns: repeat(4, 1fr); } }
.pilar { text-align: center; }
.pilar-icon {
  display: inline-grid; place-items: center; width: 64px; height: 64px;
  border-radius: 50%; margin-bottom: 1rem;
  border: 1px solid var(--gold-ink); color: var(--gold-ink); background: transparent;
}
.pilar-icon svg { width: 30px; height: 30px; }
.pilar h3 { color: var(--navy-900); margin-bottom: 0.4rem; font-size: 1.08rem; }
.pilar p { font-size: 0.92rem; color: var(--ink-soft); }

/* ---------- FAQ ---------- */
.faq-list { max-width: 760px; }
.faq-item { border-bottom: 1px solid rgba(26, 26, 26, 0.12); }
.faq-q {
  width: 100%; display: flex; align-items: center; justify-content: space-between; gap: 1rem;
  padding: 1.35rem 0; background: transparent; border: 0; cursor: pointer;
  text-align: left; font-family: var(--font-body); font-size: 1.05rem; font-weight: 700; color: var(--navy-900);
}
.faq-chevron { width: 22px; height: 22px; flex: 0 0 auto; color: var(--gold-ink); transition: transform 0.35s var(--ease); }
.faq-q[aria-expanded="true"] .faq-chevron { transform: rotate(180deg); }
.faq-a { overflow: hidden; }
.js .faq-a { max-height: 0; transition: max-height 0.4s var(--ease); }
.faq-a-inner { padding: 0 0 1.4rem; }
.faq-a-inner p { font-size: 0.98rem; line-height: 1.65; color: var(--ink-soft); max-width: 64ch; }

/* ---------- CONTACTO ---------- */
.contacto { text-align: center; }
.contacto h2 { color: var(--bone); }
.contacto .lead { color: var(--cream-300); max-width: 38rem; margin-inline: auto; }

/* Pre-calificador (sólo con JS) */
.prequal { display: none; margin: 2.2rem auto 0; max-width: 34rem; }
.js .prequal { display: block; }
.prequal-label { font-size: 0.95rem; color: var(--cream-300); margin-bottom: 0.9rem; }
.prequal-opts { display: flex; flex-wrap: wrap; gap: 0.6rem; justify-content: center; }
.prequal-opt {
  font: inherit; font-size: 0.92rem; font-weight: 600;
  padding: 0.6rem 1.1rem; border-radius: var(--r-pill); cursor: pointer;
  background: rgba(245, 241, 233, 0.06); color: var(--bone);
  border: 1px solid rgba(214, 181, 104, 0.35);
  transition: background-color 0.25s var(--ease), color 0.25s var(--ease), border-color 0.25s var(--ease);
}
.prequal-opt:hover { border-color: var(--gold-400); }
.prequal-opt[aria-pressed="true"] { background: var(--gold-400); color: var(--navy-900); border-color: var(--gold-400); }

.contacto-cta { display: flex; justify-content: center; margin-top: 2rem; }
/* Si no hay JS, el bloque de pre-calificador no aparece y el CTA queda con buen margen */
.js .contacto-cta { margin-top: 1.6rem; }

.contact-methods { display: flex; flex-wrap: wrap; gap: 1rem 2rem; justify-content: center; align-items: center; margin-top: 2.5rem; }
.contact-method { display: inline-flex; align-items: center; gap: 0.55rem; color: var(--cream-300); text-decoration: none; font-size: 0.95rem; transition: color 0.25s var(--ease); }
.contact-method:hover { color: var(--gold-400); }
.contact-method svg { width: 18px; height: 18px; color: var(--gold-400); flex: 0 0 auto; }

/* ---------- FOOTER ---------- */
.footer { background: var(--navy-900); border-top: 1px solid rgba(245, 241, 233, 0.10); }
.footer-inner {
  max-width: var(--maxw); margin-inline: auto; padding: 3rem var(--gutter);
  display: flex; flex-direction: column; gap: 1.4rem; align-items: center; text-align: center;
}
@media (min-width: 760px) { .footer-inner { flex-direction: row; justify-content: space-between; text-align: left; } }
.footer-logo { width: auto; height: clamp(54px, 7vw, 72px); }
.footer .f-tag { font-size: 0.9rem; color: var(--cream-300); margin-top: 0.7rem; }
.footer .f-legal { font-size: 0.85rem; color: var(--cream-300); }

/* ---------- Motion reducido ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .js [data-reveal] { opacity: 1; transform: none; transition: none; }
  * { animation-duration: 0.001ms !important; transition-duration: 0.001ms !important; }
}

/* ============================================================
   VERSION C — capa de diseño sobre la base (Versión B).
   Solo agrega / sobreescribe. Aesthetic: editorial-luxury,
   hero navy cinemático, nav flotante, blur-in, sticky servicios.
   ============================================================ */

/* Compensación de scroll por nav flotante fijo */
:where(#inicio, section[id]) { scroll-margin-top: 6.5rem; }

/* ---------- NAV flotante (island) ---------- */
.nav {
  position: fixed;
  top: clamp(0.55rem, 1.6vw, 1.05rem);
  left: 50%;
  transform: translateX(-50%);
  width: min(100% - 1.4rem, var(--maxw));
  border-radius: var(--r-pill);
  border: 1px solid rgba(245, 241, 233, 0.14);
  background: rgba(22, 36, 63, 0.80);   /* subido de 0.55: el nav translúcido va sobre la foto del hero; con fondo casi sólido el dorado de los links pasa AA de forma confiable */
  backdrop-filter: blur(14px) saturate(1.25);
  -webkit-backdrop-filter: blur(14px) saturate(1.25);
  box-shadow: 0 10px 30px rgba(8, 15, 30, 0.18);
}
.nav.is-scrolled {
  background: rgba(22, 36, 63, 0.84);
  border-color: rgba(245, 241, 233, 0.10);
  box-shadow: 0 14px 36px rgba(8, 15, 30, 0.32);
}
.nav-inner { padding: 0.5rem 0.6rem 0.5rem 1.1rem; }
.nav .brand-mark { color: var(--gold-400); }
.nav .brand-name { color: var(--bone); }
.nav-link { color: var(--gold-400); transition: color 0.25s var(--ease); }
.nav-link:hover { color: var(--bone); }
.nav :focus-visible { outline-color: var(--gold-400); }   /* foco de teclado visible sobre el nav navy */
/* Correr los links un poco a la izquierda (separarlos del borde derecho del nav) */
@media (min-width: 900px) { .nav-links { margin-right: clamp(1rem, 2.5vw, 2.5rem); } }
.nav .menu-toggle { color: var(--bone); }
.nav .btn-primary { background: var(--gold-500); color: var(--navy-900); }
.nav .btn-primary:hover { background: var(--gold-400); box-shadow: 0 12px 26px rgba(200, 162, 75, 0.30); }

/* CTA WhatsApp sólo-icono en mobile (siempre visible → conversión sin JS) */
.nav-wa-mobile { display: inline-grid; place-items: center; width: 42px; height: 42px; padding: 0; }
.nav-wa-mobile svg { width: 20px; height: 20px; }
@media (min-width: 900px) { .nav-wa-mobile { display: none; } }

/* Sin JS: el hamburguesa no hace nada → lo ocultamos (el CTA de WhatsApp queda visible) */
.no-js .menu-toggle { display: none; }

/* Mobile: sin backdrop-blur (perf), navy casi sólido */
@media (max-width: 900px) {
  .nav { background: rgba(22, 36, 63, 0.92); backdrop-filter: none; -webkit-backdrop-filter: none; }
}

/* ---------- HERO cinemático (navy) ---------- */
.hero {
  position: sticky;           /* efecto overlap: el hero queda pinneado mientras el contenido sube y lo tapa */
  top: 0;
  z-index: 0;                 /* el contenido posterior (.after-hero) va con z-index mayor y se pinta encima */
  isolation: isolate;
  overflow: hidden;
  color: var(--bone);
  height: 100vh;              /* fallback navegadores sin svh */
  height: 100svh;             /* alto fijo del viewport, sin saltos por la barra del browser en mobile */
  display: grid;
  align-content: center;      /* centra verticalmente el bloque de texto en el hero a pantalla completa */
  padding-top: clamp(6.5rem, 12vw, 9rem);   /* aire bajo el nav flotante fijo */
  padding-bottom: clamp(3.5rem, 8vw, 6rem);
  background:
    radial-gradient(135% 115% at 84% -12%, rgba(214, 181, 104, 0.16), rgba(214, 181, 104, 0) 52%),
    radial-gradient(120% 120% at 50% 125%, rgba(30, 46, 78, 0.55), rgba(30, 46, 78, 0) 60%),
    linear-gradient(168deg, var(--navy-900) 0%, #14213b 55%, #111d34 100%);
}
.hero .container { position: relative; z-index: 1; }
/* La tarjeta de confianza se movió a "Por qué SOMAG": el hero queda a una sola columna, texto a la izquierda */
.hero-copy { max-width: 42rem; }
@media (min-width: 940px) { .hero-grid { grid-template-columns: 1fr; } }

/* ---------- Efecto overlap: el contenido posterior sube y tapa el hero pinneado ----------
   El hero es position:sticky (queda fijo arriba). Este contenedor envuelve TODO lo que viene
   después del hero y se pinta por encima (z-index mayor) con fondo OPACO, así lo cubre a
   medida que se scrollea (scroll nativo del usuario, sin JS). IMPORTANTE: no agregar overflow
   (distinto de visible), transform, filter, perspective ni will-change acá ni en main: cualquiera
   crearía un scroll-container/containing-block que rompe el sticky del hero Y el de Servicios. */
.after-hero { position: relative; z-index: 1; background: var(--paper); }
/* Foto de fondo (LCP). El gradiente de .hero queda como fallback si la imagen falla. */
.hero-bg {
  position: absolute; inset: 0; z-index: -3; pointer-events: none;
  width: 100%; height: 100%; object-fit: cover; object-position: center;
}
/* Duotono navy sobre la foto: pesado a la izquierda (legibilidad del copy),
   destello dorado arriba a la derecha, leve oscurecido inferior. */
.hero-overlay {
  position: absolute; inset: 0; z-index: -2; pointer-events: none;
  background:
    radial-gradient(120% 120% at 86% -12%, rgba(214, 181, 104, 0.16), rgba(214, 181, 104, 0) 48%),
    linear-gradient(102deg, rgba(11, 19, 35, 0.92) 0%, rgba(13, 22, 40, 0.80) 38%, rgba(15, 25, 46, 0.55) 78%, rgba(16, 27, 49, 0.48) 100%),
    linear-gradient(180deg, rgba(11, 19, 35, 0) 35%, rgba(11, 19, 35, 0.45) 100%);
}
.hero-grain {
  position: absolute; inset: 0; z-index: -1; pointer-events: none;
  opacity: 0.09; mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='120'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  background-size: 120px 120px;
}
/* En mobile el copy ocupa todo el ancho: overlay más parejo y oscuro para legibilidad. */
@media (max-width: 760px) {
  .hero-overlay {
    background:
      radial-gradient(140% 120% at 80% -10%, rgba(214, 181, 104, 0.14), rgba(214, 181, 104, 0) 50%),
      linear-gradient(180deg, rgba(12, 20, 37, 0.86) 0%, rgba(13, 22, 40, 0.90) 60%, rgba(11, 19, 35, 0.94) 100%);
  }
}

/* Botón fantasma sobre navy (gold-ink no contrasta en oscuro) */
.band-navy .btn-ghost { border-color: rgba(214, 181, 104, 0.5); color: var(--cream-300); background: transparent; }
.band-navy .btn-ghost:hover { background: rgba(214, 181, 104, 0.12); border-color: var(--gold-400); color: var(--bone); }

/* H1 blur-in por palabra (sólo hero + manifiesto) */
.js .blur-words .w {
  display: inline-block;
  opacity: 0;
  transform: translateY(0.5em);
  transition: opacity 0.65s var(--ease-out), transform 0.65s var(--ease-out), filter 0.65s var(--ease-out);
  transition-delay: calc(var(--i, 0) * 55ms);
}
@media (min-width: 641px) { .js .blur-words .w { filter: blur(12px); } }
.js .blur-words.is-in .w { opacity: 1; transform: none; filter: none; }
.blur-words .w.em { font-style: italic; color: var(--gold-400); }

/* Tarjeta de confianza (a cargo de Alejandro): variante clara, ahora en "Por qué SOMAG" sobre banda cream */
.intro-aside .trust-card-shell { background: rgba(22, 36, 63, 0.05); border-color: rgba(22, 36, 63, 0.10); }
.intro-aside .trust-card {
  background: var(--paper); color: var(--ink);
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.6), 0 22px 48px rgba(8, 15, 30, 0.13);
}
.intro-aside .trust-card .tc-label { color: var(--gold-ink); }
.intro-aside .trust-card .tc-name { color: var(--navy-900); }
.intro-aside .trust-card .tc-role { color: var(--ink-soft); }
.intro-aside .trust-card .tc-list li { color: var(--ink-soft); }
.intro-aside .trust-card .tc-list svg { color: var(--gold-ink); }
.intro-aside .trust-card .tc-foot { border-top-color: rgba(26, 26, 26, 0.12); }
.intro-aside .trust-card .tc-contact { color: var(--ink-soft); }
.intro-aside .trust-card .tc-contact:hover { color: var(--gold-ink); }
.intro-aside .trust-card .tc-contact svg { color: var(--gold-ink); }

/* ---------- "POR QUÉ SOMAG" (manifiesto + tarjeta de Alejandro) ---------- */
.manifiesto-title {
  font-size: clamp(1.95rem, 4.2vw, 2.9rem);
  line-height: 1.12;
  letter-spacing: -0.01em;
  max-width: 24ch;
  margin-inline: auto;
  text-wrap: balance;
}
/* En banda clara el énfasis va sólo en itálica (el dorado no contrasta sobre crema) */
.manifiesto .blur-words .w.em { color: inherit; }

/* Dos columnas: texto a la izquierda, tarjeta de Alejandro a la derecha */
.intro-grid { display: grid; grid-template-columns: 1fr; gap: clamp(2.5rem, 5vw, 3.25rem); align-items: center; }
@media (min-width: 861px) {
  .intro-grid { grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr); gap: clamp(2.5rem, 5vw, 4.5rem); }
}
.intro-copy.manifiesto { text-align: left; }
.intro-copy .manifiesto-title { margin-inline: 0; max-width: 20ch; }
.intro-copy .prose { margin-inline: 0; max-width: 46ch; }

/* ---------- SERVICIOS (tarjetas apiladas sticky · híbrido foto + ícono) ---------- */
/* position:sticky se rompe si un ancestro es scroll-container. overflow-x:clip NO lo crea
   (overflow-x:hidden sí). Por eso pisamos el hidden de la base por clip. */
body { overflow-x: clip; }

.svc-head {
  display: grid; grid-template-columns: 1fr;
  gap: clamp(1.25rem, 3vw, 2rem); align-items: end;
  margin-bottom: clamp(2.5rem, 5vw, 4rem);
}
.svc-head-main h2 { margin-top: 0.6rem; max-width: 18ch; }
/* El header de Servicios quedó a una sola columna (se eliminó el bloque "aside" del header). */

.svc-stack { display: grid; gap: clamp(1.25rem, 3vw, 2.25rem); --svc-top: clamp(4.5rem, 6vw, 6rem); --svc-stagger: 1.5rem; }

.svc-card-c {
  display: grid; grid-template-columns: 1fr;
  gap: clamp(1.25rem, 3vw, 2.5rem); align-items: stretch;
  background: var(--paper);
  border: 1px solid rgba(22, 36, 63, 0.08);
  border-radius: 1.6rem;
  padding: clamp(1.4rem, 3vw, 2.4rem);
  box-shadow: 0 1px 2px rgba(8, 15, 30, 0.04), 0 22px 48px rgba(8, 15, 30, 0.10);
}
/* Mobile: la figura va de banner arriba, después el texto */
.svc-card-c .svc-figure { order: -1; min-height: 168px; }

@media (min-width: 861px) {
  .svc-card-c {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.04fr);
    align-items: center;
    min-height: clamp(360px, 40vw, 460px);   /* un poco más alto: los textos nuevos de servicios son más largos */
    position: sticky;
    top: calc(var(--svc-top) + var(--n, 0) * var(--svc-stagger));
  }
  .svc-card-c .svc-figure { order: 0; min-height: 0; align-self: stretch; }
}

.svc-body { align-self: center; }
.svc-num {
  display: inline-grid; place-items: center;
  width: 44px; height: 44px; border-radius: var(--r-pill);
  background: rgba(22, 36, 63, 0.06); color: var(--navy-900);
  font-family: var(--font-display); font-size: 1rem; font-weight: 600;
  margin-bottom: 1.1rem;
}
.svc-card-c h3 { font-size: clamp(1.45rem, 2.4vw, 1.95rem); line-height: 1.12; letter-spacing: -0.01em; margin-bottom: 0.7rem; }
.svc-body p { color: var(--ink-soft); max-width: 44ch; }
.svc-tags { list-style: none; margin: 1.4rem 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 0.55rem; }
.svc-tags li {
  display: inline-flex; align-items: center; gap: 0.45rem;
  padding: 0.4rem 0.85rem 0.4rem 0.65rem; border-radius: var(--r-pill);
  background: var(--bone); border: 1px solid rgba(22, 36, 63, 0.08);
  font-size: 0.84rem; font-weight: 600; color: var(--navy-900);
}
.svc-tags svg { width: 15px; height: 15px; color: var(--gold-ink); flex: none; }

.svc-figure {
  position: relative; isolation: isolate;
  border-radius: 1.15rem; overflow: hidden;
  display: grid; place-items: center;
  background: linear-gradient(150deg, var(--navy-900), #14213b 60%, #111d34);
}
.svc-figure-bg { position: absolute; inset: 0; z-index: -2; width: 100%; height: 100%; object-fit: cover; }
.svc-figure-veil {
  position: absolute; inset: 0; z-index: -1; pointer-events: none;
  transition: opacity 0.5s var(--ease-out);
  background:
    radial-gradient(90% 90% at 50% 35%, rgba(214, 181, 104, 0.20), rgba(214, 181, 104, 0) 60%),
    linear-gradient(155deg, rgba(13, 22, 40, 0.62) 0%, rgba(15, 25, 46, 0.70) 55%, rgba(11, 19, 35, 0.80) 100%);
}
.svc-glyph {
  width: clamp(54px, 7vw, 88px); height: auto; color: var(--gold-400);
  filter: drop-shadow(0 8px 22px rgba(8, 15, 30, 0.45));
  transition: transform 0.5s var(--ease-out);
}
.svc-card-c:hover .svc-glyph { transform: scale(1.06); }
.svc-card-c:hover .svc-figure-veil { opacity: 0.82; }

/* ---------- Cómo trabajamos: timeline editorial (version-c) ---------- */
.como-grid { display: grid; grid-template-columns: 1fr; gap: clamp(2.5rem, 5vw, 4rem); }
@media (min-width: 861px) {
  .como-grid { grid-template-columns: minmax(0, 0.82fr) minmax(0, 1.18fr); gap: clamp(3rem, 6vw, 6rem); align-items: start; }
  .como-head { position: sticky; top: clamp(5.5rem, 9vw, 7.5rem); }
}
.como-head h2 { max-width: 15ch; margin-top: 0.6rem; }
.como-lead { margin-top: 1.15rem; color: var(--ink-soft); font-size: clamp(1rem, 1.35vw, 1.1rem); line-height: 1.6; max-width: 34ch; }

.proceso { --nodo: clamp(48px, 5vw, 58px); --proceso-gap: clamp(2rem, 4vw, 3rem); display: grid; gap: var(--proceso-gap); }
.proceso-step { display: grid; grid-template-columns: var(--nodo) 1fr; gap: clamp(1.1rem, 2.5vw, 1.75rem); align-items: stretch; }
.proceso-marker { position: relative; display: flex; justify-content: center; }
.proceso-num {
  position: relative; z-index: 1; flex: none;
  width: var(--nodo); height: var(--nodo);
  display: grid; place-items: center;
  border-radius: var(--r-pill);
  background: var(--paper);
  border: 1px solid rgba(125, 90, 30, 0.32);
  box-shadow: 0 2px 12px rgba(8, 15, 30, 0.07), inset 0 1px 1px rgba(255, 255, 255, 0.65);
  font-family: var(--font-display); font-style: italic; font-weight: 500;
  font-size: clamp(1.15rem, 1.8vw, 1.5rem); color: var(--gold-ink);
  transition: transform 0.5s var(--ease-out), border-color 0.5s var(--ease-out);
}
.proceso-step:not(:last-child) .proceso-marker::after {
  content: ""; position: absolute; left: 50%; transform: translateX(-50%);
  top: var(--nodo); bottom: calc(-1 * var(--proceso-gap));
  width: 2px; border-radius: 2px;
  background: linear-gradient(180deg, rgba(125, 90, 30, 0.42), rgba(125, 90, 30, 0.08));
}
.proceso-content { padding-top: 0.35rem; }
.proceso-content h3 { color: var(--navy-900); font-size: clamp(1.2rem, 2vw, 1.55rem); line-height: 1.18; letter-spacing: -0.01em; margin-bottom: 0.5rem; }
.proceso-content p { color: var(--ink-soft); line-height: 1.6; max-width: 42ch; }
.proceso-step:hover .proceso-num { transform: translateY(-2px); border-color: rgba(125, 90, 30, 0.58); }

/* ---------- Por qué elegirnos: pilares en tarjeta (version-c) ---------- */
.pilar {
  background: var(--paper);
  border: 1px solid rgba(22, 36, 63, 0.08);
  border-radius: 1.4rem;
  padding: clamp(1.7rem, 3vw, 2.3rem) clamp(1.2rem, 2.5vw, 1.6rem);
  box-shadow: 0 1px 2px rgba(8, 15, 30, 0.04), 0 18px 40px rgba(8, 15, 30, 0.07);
  transition: transform 0.5s var(--ease-out), box-shadow 0.5s var(--ease-out), border-color 0.5s var(--ease-out);
}
.pilar:hover {
  transform: translateY(-4px);
  box-shadow: 0 1px 2px rgba(8, 15, 30, 0.05), 0 28px 56px rgba(8, 15, 30, 0.12);
  border-color: rgba(125, 90, 30, 0.22);
}
.pilar .pilar-icon {
  border-radius: 1.05rem;
  background: rgba(125, 90, 30, 0.07);
  border-color: rgba(125, 90, 30, 0.30);
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.55);
}

/* ---------- FAQ en tarjetas (version-c) ---------- */
.faq-list { max-width: 820px; display: grid; gap: 0.75rem; }
.faq-item {
  border-bottom: 0;
  background: var(--paper);
  border: 1px solid rgba(22, 36, 63, 0.08);
  border-radius: 1rem;
  padding: 0 clamp(1.1rem, 2.5vw, 1.6rem);
  transition: border-color 0.4s var(--ease-out), box-shadow 0.4s var(--ease-out);
}
.faq-item:hover { border-color: rgba(125, 90, 30, 0.28); box-shadow: 0 12px 30px rgba(8, 15, 30, 0.06); }
.faq-q { padding: 1.2rem 0; }
/* Sin JS, el botón del acordeón no actúa: ocultamos el chevron para no sugerir un estado plegable que no existe. */
.no-js .faq-chevron { display: none; }
.no-js .faq-q { cursor: default; }

/* ---------- Contacto: glow dorado de cierre (version-c) ---------- */
.contacto { position: relative; isolation: isolate; overflow: hidden; }
.contacto-glow {
  position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background:
    radial-gradient(55% 45% at 50% 0%, rgba(214, 181, 104, 0.18), transparent 70%),
    radial-gradient(40% 60% at 85% 110%, rgba(214, 181, 104, 0.08), transparent 70%);
}

/* ---------- Botón flotante de WhatsApp (FAB) ---------- */
.wa-fab {
  position: fixed;
  right: clamp(1rem, 2.5vw, 1.5rem);
  bottom: calc(clamp(1rem, 2.5vw, 1.5rem) + env(safe-area-inset-bottom, 0px)); /* iOS: no quedar bajo la barra de gestos */
  z-index: 55;                /* sobre el nav (50) y el contenido; debajo del menú mobile (60) para que el menú lo tape al abrir */
  display: inline-grid;
  place-items: center;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: #25d366;        /* verde WhatsApp */
  color: #fff;                /* ícono blanco */
  box-shadow: 0 6px 18px rgba(8, 15, 30, 0.28), 0 2px 6px rgba(8, 15, 30, 0.18);
  transition: transform 0.25s var(--ease-out), box-shadow 0.25s var(--ease-out);
  -webkit-tap-highlight-color: transparent;
}
.wa-fab svg { width: 30px; height: 30px; display: block; }
.wa-fab:hover { transform: translateY(-2px) scale(1.05); box-shadow: 0 12px 26px rgba(8, 15, 30, 0.34), 0 3px 9px rgba(8, 15, 30, 0.22); }
.wa-fab:active { transform: translateY(0) scale(0.98); }
/* Foco de teclado visible sobre cualquier banda (blanco + halo navy) */
.wa-fab:focus-visible { outline: 3px solid #fff; outline-offset: 2px; box-shadow: 0 0 0 5px rgba(22, 36, 63, 0.65), 0 6px 18px rgba(8, 15, 30, 0.28); }

/* ---------- Motion reducido (version-c) ---------- */
@media (prefers-reduced-motion: reduce) {
  .js .blur-words .w { opacity: 1; transform: none; filter: none; transition: none; }
  .svc-card-c { position: static; }
  .svc-glyph, .svc-figure-veil { transition: none; }
  .svc-card-c:hover .svc-glyph { transform: none; }
  .como-head { position: static; }
  .proceso-num { transition: none; }
  .proceso-step:hover .proceso-num { transform: none; }
  .pilar { transition: none; }
  .pilar:hover { transform: none; }
  .faq-item { transition: none; }
  .wa-fab:hover { transform: none; }
}
