/* Grupo Clarté · Sistema visual
 * 28 de agosto de 2026 · Dirección de diseño
 *
 * Los VALORES salen del manual de marca de Clarté:
 *   Verde 627C  #10312B  → --fondo-profundo
 *   Verde 3302C #004C45  → --acento-oscuro
 *   Teal 7475C  #44797B  → --acento
 *   Crema       #FFF8F0  → --fondo-base
 *   Gray 5      #B1B1B1  → --gray-mid
 *   Gray 8      #898A8D  → --gray-mid-oscuro
 *
 * Este archivo aplica el sistema encima de los estilos existentes de cada página.
 * Va incluido después del <style> interno para sobrescribir con especificidad. */

/* ─────────── TOKENS ─────────── */
:root{
  --fondo-profundo:#10312B;
  --fondo-base:#FFF8F0;
  --fondo-suave:#FAEFDC;
  --fondo-white:#FFFFFF;
  --acento:#44797B;
  --acento-oscuro:#004C45;
  --acento-secundario:#C86E3E;
  --ink-strong:#10312B;
  --ink:#2A3E3A;
  --ink-suave:#4E5F5B;
  --line:#E8DEC9;
  --line-soft:#F0E7D5;
  --cream-warm:#F5E5C6;

  --fs-h1: clamp(34px, 5.5vw, 56px);
  --fs-h2: clamp(24px, 3.2vw, 34px);
  --fs-h3: 19px;
  --fs-body: 17px;
  --fs-small: 15px;
  --fs-eyebrow: 11.5px;

  --sp-1:8px; --sp-2:12px; --sp-3:16px; --sp-4:24px; --sp-5:32px;
  --sp-6:48px; --sp-7:64px; --sp-8:96px; --sp-9:128px;

  --nav-h:76px;
}

/* ─────────── BASE ─────────── */
html{scroll-behavior:smooth;-webkit-text-size-adjust:100%}
body{
  background:var(--fondo-base) !important;
  color:var(--ink);
  font-family:'Inter',-apple-system,BlinkMacSystemFont,'Segoe UI',sans-serif;
  font-size:var(--fs-body);
  line-height:1.6;
  -webkit-font-smoothing:antialiased;
  -moz-osx-font-smoothing:grayscale;
  overflow-x:hidden;
}

img{max-width:100%;height:auto;display:block}

/* ─────────── TIPOGRAFÍA ─────────── */
h1,h2,h3,h4{
  font-family:'Sora',sans-serif;
  color:var(--fondo-profundo);
  text-wrap:balance;
  letter-spacing:-0.018em;
  font-weight:600;
}
h1{font-size:var(--fs-h1);line-height:1.05;letter-spacing:-0.028em}
h2{font-size:var(--fs-h2);line-height:1.15}
h3{font-size:var(--fs-h3);line-height:1.3}
p{font-size:var(--fs-body);line-height:1.65;color:var(--ink-suave);text-wrap:pretty}

/* Ancho de lectura confortable en textos largos */
article p, .por-que p, .narrative p, .privacy-lead, .hero-sub, .hero-legal-sub,
.hero-business-sub, .hero-paq p, .promesa-body p, .hero-diag .hero-sub, .hero-gle .hero-sub,
section.foot-cta p{
  max-width:68ch;
}

/* Enlaces cuidados */
a{transition:color 150ms ease,background 150ms ease,border-color 150ms ease}

/* Focus visible universal */
*:focus{outline:none}
*:focus-visible{
  outline:2px solid var(--acento);
  outline-offset:3px;
  border-radius:2px;
}

/* Respeto al usuario que necesita menos movimiento */
@media (prefers-reduced-motion: reduce){
  *,*::before,*::after{
    animation-duration:0.01ms !important;
    animation-iteration-count:1 !important;
    transition-duration:0.01ms !important;
    scroll-behavior:auto !important;
  }
}

/* ─────────── CABECERA · fondo profundo con logo crema ─────────── */
header{
  position:sticky;
  top:0;
  background:var(--fondo-profundo) !important;
  backdrop-filter:none !important;
  -webkit-backdrop-filter:none !important;
  border-bottom:1px solid rgba(255,248,240,0.08) !important;
  z-index:100;
  transition:box-shadow 200ms ease;
}
body.scrolled header,
header.scrolled{
  box-shadow:0 10px 30px -18px rgba(0,0,0,0.4);
}
header .nav{
  min-height:var(--nav-h);
  padding:0 32px !important;
}
header .brand-link{height:auto !important;padding:14px 0}
header .logo-header{
  height:44px !important;
  width:auto !important;
  margin-left:0 !important;
  filter:brightness(0) invert(1);
  opacity:0.98;
}
header .header-isotipo{
  height:34px !important;
  width:auto !important;
  filter:brightness(0) invert(1);
  opacity:0.9;
}
header nav ul{gap:28px !important}
header nav ul a{
  color:var(--fondo-base) !important;
  font-size:0.92rem !important;
  font-weight:500 !important;
  padding:8px 0;
  position:relative;
}
header nav ul a::after{
  content:"";
  position:absolute;
  left:0;right:0;
  bottom:-2px;
  height:2px;
  background:var(--acento);
  transform:scaleX(0);
  transform-origin:left;
  transition:transform 180ms ease;
}
header nav ul a:hover::after,
header nav ul a.active::after{transform:scaleX(1)}
header nav ul a:hover,
header nav ul a.active{color:#fff !important}

header .btn-nav{
  background:var(--acento) !important;
  color:var(--fondo-base) !important;
  padding:12px 22px !important;
  border-radius:6px;
  letter-spacing:0.04em !important;
  transition:background 160ms ease,transform 160ms ease !important;
}
header .btn-nav::after{display:none !important}
header .btn-nav:hover{
  background:#5a8f92 !important;
  transform:translateY(-1px);
}

/* Lang toggle */
header .lang-toggle{
  border-left:1px solid rgba(255,248,240,0.15) !important;
  padding-left:20px !important;
}
header .lang-toggle a.lang-link{
  color:rgba(255,248,240,0.55) !important;
}
header .lang-toggle a.lang-link.active{color:var(--fondo-base) !important}
header .lang-toggle a.lang-link:hover{color:var(--acento) !important}
header .lang-toggle .lang-sep{color:rgba(255,248,240,0.25) !important}

/* Hamburguesa en color crema */
.menu-toggle{color:var(--fondo-base) !important}

/* ─────────── RITMO DE FONDOS · roles de sección ─────────── */
/* Aplica automáticamente sobre las clases que ya usa el sitio */
section.section, section.foot-cta{background:var(--fondo-base)}

/* Fondos suaves (crema por encima del base) */
.paquetes, .practicas, .por-proyecto, .recursos-hub,
.audiencia, .principios, .frentes-grid, .promesa-legal,
.faq, section.section-cream, section.section-cream-soft{
  background:var(--fondo-suave) !important;
}

/* Fondos profundos · énfasis */
.hero, .hero-legal, .hero-business, .hero-paq, .hero-diag, .hero-gle,
.privacy-hero,
.costo, .metricas, .cta-final, .cta-empezar, .cta-form,
footer{
  background:var(--fondo-profundo) !important;
  color:var(--fondo-base);
}
.hero h1, .hero-legal h1, .hero-business h1, .hero-paq h1, .hero-diag h1, .hero-gle h1,
.privacy-hero h1,
.costo h2, .metricas h2, .cta-final h2, .cta-empezar h2, .cta-form h2,
.hero h2, .hero-legal h2, .hero-business h2, .hero-paq h2, .hero-diag h2, .hero-gle h2{
  color:var(--fondo-base) !important;
}
.hero p, .hero-legal p, .hero-business p, .hero-paq p, .hero-diag p, .hero-gle p,
.hero-sub, .hero-legal-sub, .hero-business-sub, .privacy-lead,
.costo p, .metricas p, .cta-final p, .cta-empezar p, .cta-form p,
.hero-diag .hero-sub, .hero-gle .hero-sub, .cta-form-lead{
  color:rgba(255,248,240,0.85) !important;
}
.hero em, .hero-legal em, .hero-business em, .hero-paq em, .hero-diag em, .hero-gle em,
.privacy-hero em{
  color:var(--acento) !important;
  font-style:italic;
  font-family:'Lora',serif;
  font-weight:500;
}

/* Eyebrow sobre fondo profundo */
.hero .eyebrow, .hero-legal .eyebrow, .hero-business .eyebrow, .hero-paq .eyebrow,
.hero-diag .eyebrow, .hero-gle .eyebrow, .privacy-hero .eyebrow,
.costo .eyebrow, .metricas .eyebrow, .cta-final .eyebrow, .cta-empezar .eyebrow, .cta-form .eyebrow{
  color:var(--acento) !important;
  font-size:var(--fs-eyebrow);
  letter-spacing:0.14em;
  font-weight:500;
  text-transform:uppercase;
}

/* ─────────── SECCIONES · ritmo vertical ─────────── */
section.section, section.foot-cta, section.hero, section.hero-legal,
section.hero-business, section.hero-paq, section.hero-diag, section.hero-gle,
section.privacy-hero,
section.costo, section.metricas, section.cta-final, section.cta-empezar, section.cta-form,
section.paquetes, section.practicas, section.por-proyecto, section.recursos-hub,
section.audiencia, section.principios, section.faq, section.promesa-legal,
section.testimonios, section.clientes, section.equipo-preview, section.proceso,
section.areas{
  padding:96px 0;
}

@media (max-width:900px){
  section.section, section.foot-cta, section.hero, section.hero-legal,
  section.hero-business, section.hero-paq, section.hero-diag, section.hero-gle,
  section.privacy-hero,
  section.costo, section.metricas, section.cta-final, section.cta-empezar, section.cta-form,
  section.paquetes, section.practicas, section.por-proyecto, section.recursos-hub,
  section.audiencia, section.principios, section.faq, section.promesa-legal,
  section.testimonios, section.clientes, section.equipo-preview, section.proceso,
  section.areas{
    padding:56px 0 !important;
  }
}

/* ─────────── BOTONES ─────────── */
.btn-primary, .cta-primary, .form-submit, .paquete-cta{
  background:var(--acento) !important;
  color:var(--fondo-base) !important;
  padding:16px 28px !important;
  border-radius:6px;
  font-family:'Sora',sans-serif !important;
  font-weight:500 !important;
  letter-spacing:0.04em !important;
  border:0;
  cursor:pointer;
  transition:background 160ms ease,transform 160ms ease,box-shadow 160ms ease !important;
  min-height:48px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
}
.btn-primary:hover, .cta-primary:hover, .form-submit:hover, .paquete-cta:hover{
  background:#5a8f92 !important;
  transform:translateY(-1px);
  box-shadow:0 12px 24px -14px rgba(16,49,43,0.35);
}
.btn-secondary, .cta-secondary{
  background:transparent !important;
  color:var(--fondo-base) !important;
  padding:16px 28px !important;
  border:1px solid rgba(255,248,240,0.6) !important;
  border-radius:6px;
  font-family:'Sora',sans-serif !important;
  font-weight:500 !important;
  letter-spacing:0.04em !important;
  min-height:48px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  transition:background 160ms ease,border-color 160ms ease !important;
}
.btn-secondary:hover, .cta-secondary:hover{
  background:rgba(255,248,240,0.08) !important;
  border-color:var(--fondo-base) !important;
}

/* En hero profundo, el primario invierte para respirar */
.hero-diag .cta-primary, .hero-gle .cta-primary, .hero-legal .btn-primary, .hero-business .btn-primary,
.hero-paq .cta-primary, .hero .btn-primary{
  background:var(--fondo-base) !important;
  color:var(--fondo-profundo) !important;
}
.hero-diag .cta-primary:hover, .hero-gle .cta-primary:hover, .hero-legal .btn-primary:hover,
.hero-business .btn-primary:hover, .hero-paq .cta-primary:hover, .hero .btn-primary:hover{
  background:var(--acento) !important;
  color:var(--fondo-base) !important;
}

/* ─────────── PIE ─────────── */
footer{
  background:var(--fondo-profundo) !important;
  color:rgba(255,248,240,0.7);
  padding:64px 0 24px !important;
  border-top:1px solid rgba(255,248,240,0.08);
}
footer .footer-logo{filter:none;height:52px !important}
footer .footer-isotipo{height:34px !important;filter:none}
footer h4{color:var(--fondo-base) !important;font-size:var(--fs-eyebrow);letter-spacing:0.14em;text-transform:uppercase}
footer a{color:rgba(255,248,240,0.7) !important;transition:color 150ms ease}
footer a:hover{color:var(--fondo-base) !important}
footer .social a{
  display:inline-flex;align-items:center;justify-content:center;
  width:36px;height:36px;
  border:1px solid rgba(255,248,240,0.2);
  border-radius:50%;
  font-size:0.72rem;font-weight:600;
  transition:background 160ms ease,color 160ms ease,border-color 160ms ease;
}
footer .social a:hover{
  background:var(--acento);
  color:var(--fondo-base) !important;
  border-color:var(--acento);
}
footer .footer-bottom{
  border-top:1px solid rgba(255,248,240,0.08) !important;
  padding-top:20px;
  color:rgba(255,248,240,0.45);
}
footer .footer-bottom a, footer .footer-bottom button{
  color:rgba(255,248,240,0.55) !important;
}

/* ─────────── FORMULARIOS · legibilidad y móvil ─────────── */
input[type="text"], input[type="email"], input[type="tel"], select, textarea{
  font-size:16px !important;
  min-height:48px;
  padding:14px 16px !important;
  border:1px solid var(--line) !important;
  background:var(--fondo-white) !important;
  border-radius:6px;
  transition:border-color 150ms ease,box-shadow 150ms ease;
  font-family:'Inter',sans-serif;
}
input:focus, select:focus, textarea:focus{
  border-color:var(--acento) !important;
  box-shadow:0 0 0 3px rgba(68,121,123,0.15);
}
label{font-family:'Sora',sans-serif;font-weight:500;color:var(--fondo-profundo);font-size:var(--fs-small);letter-spacing:0.02em}

/* ─────────── TARJETAS ─────────── */
.paquete, .practica-card, .paso, .paso-card, .frente, .audiencia-item,
.principio, .miembro, .caso, .recurso-item, .testimonio{
  background:var(--fondo-white);
  border:1px solid var(--line);
  border-radius:8px;
  transition:transform 200ms ease, box-shadow 200ms ease, border-color 200ms ease;
}
.paquete:hover, .practica-card:hover, .paso:hover, .paso-card:hover,
.principio:hover, .caso:hover, .recurso-item:hover, .testimonio:hover{
  transform:translateY(-3px);
  box-shadow:0 20px 40px -25px rgba(16,49,43,0.18);
  border-color:var(--acento);
}

/* ─────────── DETALLES tipográficos por área ─────────── */
.eyebrow{
  font-family:'Sora',sans-serif;
  font-size:var(--fs-eyebrow);
  letter-spacing:0.14em;
  text-transform:uppercase;
  color:var(--acento);
  font-weight:500;
}
strong{color:var(--fondo-profundo);font-weight:600}
em, .italic-editorial{font-family:'Lora',serif;font-style:italic;color:var(--acento)}

/* ─────────── CONTAINERS ─────────── */
.container{max-width:1200px;margin:0 auto;padding:0 24px}
.container-narrow{max-width:860px;margin:0 auto;padding:0 24px}
@media(min-width:900px){
  .container{padding:0 40px}
  .container-narrow{padding:0 40px}
}

/* ─────────── MÓVIL · barra de acción inferior (páginas comerciales) ─────────── */
body.pagina-comercial .mobile-cta-bar{
  display:none;
  position:fixed;
  left:12px;right:12px;bottom:12px;
  padding:14px 18px;
  background:var(--fondo-profundo);
  color:var(--fondo-base);
  border-radius:10px;
  z-index:90;
  box-shadow:0 20px 50px -20px rgba(0,0,0,0.4);
  text-align:center;
  font-family:'Sora',sans-serif;
  font-weight:500;
  font-size:0.92rem;
  letter-spacing:0.03em;
  text-decoration:none;
}
@media(max-width:900px){
  body.pagina-comercial .mobile-cta-bar{display:block}
  body.pagina-comercial{padding-bottom:80px}
}

/* ─────────── HERO · respiración ─────────── */
.hero, .hero-legal, .hero-business, .hero-paq, .hero-diag, .hero-gle, .privacy-hero{
  padding:120px 0 100px !important;
  position:relative;
  overflow:hidden;
}
.hero::after, .hero-legal::after, .hero-business::after, .hero-paq::after,
.hero-diag::after, .hero-gle::after{
  content:"";position:absolute;
  top:-120px;right:-140px;
  width:520px;height:520px;
  border-radius:50%;
  background:radial-gradient(circle,rgba(68,121,123,0.22),transparent 66%);
  pointer-events:none;
}
@media(max-width:900px){
  .hero, .hero-legal, .hero-business, .hero-paq, .hero-diag, .hero-gle, .privacy-hero{
    padding:72px 0 56px !important;
  }
}

/* ─────────── ENLACES EN CONTENIDO ─────────── */
article a, .narrative a, p a{
  color:var(--acento);
  border-bottom:1px solid rgba(68,121,123,0.35);
  padding-bottom:1px;
  text-decoration:none;
  transition:color 150ms ease, border-color 150ms ease;
}
article a:hover, .narrative a:hover, p a:hover{
  color:var(--acento-oscuro);
  border-color:var(--acento);
}

/* ─────────── OVERRIDES DE CONTRASTE ─────────── */
/* Texto atenuado sobre fondo profundo mantiene contraste 4.5:1 */
.hero .hero-trust, .hero-legal-trust, .hero-business-trust{
  color:rgba(255,248,240,0.72) !important;
}

/* WhatsApp float queda igual pero con ring de focus */
.wa-float-btn:focus-visible{outline:3px solid var(--fondo-base);outline-offset:4px}

/* ─────────── MENU MÓVIL profundo ─────────── */
@media(max-width:980px){
  header nav ul{
    background:var(--fondo-profundo) !important;
    border-top:1px solid rgba(255,248,240,0.1) !important;
    border-bottom:none !important;
    padding:8px 24px 32px !important;
    box-shadow:0 30px 60px -20px rgba(0,0,0,0.5) !important;
  }
  header nav ul li{
    border-bottom:1px solid rgba(255,248,240,0.08) !important;
  }
  header nav ul a{
    color:var(--fondo-base) !important;
    padding:20px 0 !important;
    min-height:48px;
  }
  header nav ul a.btn-nav{
    background:var(--acento) !important;
    margin-top:16px !important;
    border-radius:6px !important;
  }
  header nav ul .lang-toggle{
    border-top:1px solid rgba(255,248,240,0.1) !important;
    border-left:none !important;
    padding:16px 0 0 !important;
    justify-content:flex-start !important;
  }
}
