/* ══════════════════════════════════════════════════════
   PLENIQ · CSS compartido — tokens, navbar, footer,
   animaciones de reveal y modal de auditoría.
   Incluir en TODAS las páginas del sitio.
══════════════════════════════════════════════════════ */

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

/* ── DESIGN TOKENS ── */
:root {
  --dark:    #0D1A3A;
  --indigo:  #1B2C6B;
  --blue:    #3D5BE0;
  --blue-h:  #2D4BCF;
  --white:   #FFFFFF;
  --text:    #1A1A2E;
  --surface: #F4F6FC;
  --muted:   #5A6070;
  --border:  #E8ECF4;

  --nav-h:  68px;
  --max-w:  1280px;
  --r-card: 12px;
  --r-btn:  8px;
  --r-pill: 999px;

  --xs: 4px;  --sm: 8px;  --md: 16px;  --lg: 24px;
  --xl: 32px; --2xl:48px; --3xl:64px;  --4xl:96px; --5xl:128px;
}

html {
  scroll-behavior: smooth;
  overflow-x: clip;
}
body {
  font-family: 'Geist', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  background: var(--white);
  color: var(--text);
  overflow-x: clip;
  max-width: 100%;
}

/* ════════════════════════════════════════
   NAVBAR
════════════════════════════════════════ */
nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 200;
  height: var(--nav-h);
  background: transparent;
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 48px;
  transition: background .3s, backdrop-filter .3s, border-color .3s, box-shadow .3s;
  border-bottom: 1px solid transparent;
}
nav.scrolled {
  background: rgba(255,255,255,0.88);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(0,0,0,0.07);
  box-shadow: 0 1px 0 rgba(0,0,0,0.04);
}
nav.scrolled .logo-word { color: var(--indigo); }
nav.scrolled .logo-mark svg path { stroke: var(--indigo); }
nav.scrolled .nav-links a { color: var(--muted); }
nav.scrolled .nav-links a:hover { color: var(--text); }
nav.scrolled .btn-nav {
  background: var(--blue);
  border-color: var(--blue);
  color: #fff;
}
nav.scrolled .btn-nav:hover { background: var(--blue-h); }

.nav-logo { display: flex; align-items: center; gap: 10px; text-decoration: none; }
.logo-mark { display: flex; align-items: center; }
.logo-mark svg { width: 28px; height: 28px; }
.logo-word { font-size: 17px; font-weight: 800; letter-spacing: 0.06em; color: #FFFFFF; }

.nav-links { display: flex; gap: 40px; list-style: none; }
.nav-links a {
  font-size: 14px; font-weight: 500; color: rgba(255,255,255,0.85);
  text-decoration: none; transition: color .15s;
}
.nav-links a:hover { color: #FFFFFF; }

.btn-nav {
  background: rgba(255,255,255,0.12);
  color: #FFFFFF;
  padding: 11px 22px; border-radius: var(--r-btn);
  font-size: 14px; font-weight: 600; font-family: inherit;
  border: 1.5px solid rgba(255,255,255,0.5);
  cursor: pointer; text-decoration: none;
  transition: background .15s;
}
.btn-nav:hover { background: rgba(255,255,255,0.22); }

/* ════════════════════════════════════════
   UTILIDADES GLOBALES
════════════════════════════════════════ */
.eyebrow {
  display: inline-block;
  font-size: 12px; font-weight: 600; letter-spacing: 0.07em;
  text-transform: uppercase; color: var(--muted);
  margin-bottom: var(--md);
}

.blue { color: var(--blue); }

.btn-primary {
  background: var(--blue); color: #FFFFFF;
  padding: 16px 32px; border-radius: var(--r-btn);
  font-size: 16px; font-weight: 700; font-family: inherit;
  text-decoration: none; border: none;
  display: inline-flex; align-items: center; gap: 8px;
  transition: background .15s, transform .15s;
}
.btn-primary:hover { background: var(--blue-h); transform: translateY(-1px); }

.btn-secondary {
  background: rgba(255,255,255,0.1);
  color: #FFFFFF;
  padding: 16px 32px; border-radius: var(--r-btn);
  font-size: 16px; font-weight: 600; font-family: inherit;
  text-decoration: none;
  border: 1.5px solid rgba(255,255,255,0.35);
  transition: background .15s;
}
.btn-secondary:hover { background: rgba(255,255,255,0.18); }

/* ════════════════════════════════════════
   FOOTER
════════════════════════════════════════ */
footer { background: #05091C; padding: var(--4xl) var(--2xl) var(--xl); }
.footer-grid {
  display: grid; grid-template-columns: 1.3fr 1fr 0.8fr;
  gap: var(--4xl); max-width: var(--max-w); margin: 0 auto;
  padding-bottom: var(--3xl);
  border-bottom: 1px solid rgba(255,255,255,0.1);
}
.footer-logo-word { font-size: 16px; font-weight: 800; letter-spacing: 0.06em; color: var(--white); }
.footer-logo-row { display: flex; align-items: center; gap: var(--sm); margin-bottom: var(--md); }
.footer-tag { font-size: 14px; color: rgba(255,255,255,0.5); line-height: 1.7; max-width: 280px; }
.footer-col-title {
  font-size: 12px; font-weight: 600; letter-spacing: 0.07em;
  text-transform: uppercase; color: rgba(255,255,255,0.35);
  margin-bottom: var(--lg);
}
.footer-links { list-style: none; display: flex; flex-direction: column; gap: 12px; }
.footer-links a {
  font-size: 14px; color: rgba(255,255,255,0.6);
  text-decoration: none; transition: color .15s;
}
.footer-links a:hover { color: var(--white); }
.footer-contact { display: flex; flex-direction: column; gap: 14px; }
.footer-contact a {
  display: flex; align-items: center; gap: 10px;
  font-size: 14px; color: rgba(255,255,255,0.6);
  text-decoration: none; transition: color .15s;
}
.footer-contact a:hover { color: var(--white); }
.footer-contact svg { opacity: .5; }
.footer-bottom {
  display: flex; justify-content: space-between; align-items: center;
  max-width: var(--max-w); margin: var(--xl) auto 0;
}
.footer-copy, .footer-region { font-size: 12px; color: rgba(255,255,255,0.28); }

/* ════════════════════════════════════════
   SCROLL REVEAL — slide up + spring + cascade
════════════════════════════════════════ */
.reveal {
  opacity: 0;
  transform: translateY(48px) scale(0.96);
  transition: opacity 1s cubic-bezier(0.16, 1, 0.3, 1),
              transform 1s cubic-bezier(0.16, 1, 0.3, 1);
}
.reveal.visible { opacity: 1; transform: translateY(0) scale(1); }
.reveal-delay-1 { transition-delay: 0.12s; }
.reveal-delay-2 { transition-delay: 0.26s; }
.reveal-delay-3 { transition-delay: 0.40s; }
.reveal-delay-4 { transition-delay: 0.54s; }

@keyframes springIn {
  0%   { opacity: 0; transform: translateY(44px) scale(0.91); }
  55%  { opacity: 1; transform: translateY(-8px) scale(1.03); }
  75%  { transform: translateY(4px) scale(0.98); }
  90%  { transform: translateY(-2px) scale(1.01); }
  100% { opacity: 1; transform: translateY(0) scale(1); }
}
.spring { opacity: 0; }
.spring.visible { animation: springIn 0.75s cubic-bezier(0.34, 1.56, 0.64, 1) forwards; }
.spring.visible.reveal-delay-1 { animation-delay: 0.14s; }
.spring.visible.reveal-delay-2 { animation-delay: 0.28s; }
.spring.visible.reveal-delay-3 { animation-delay: 0.42s; }
.spring.visible.reveal-delay-4 { animation-delay: 0.56s; }

.cascade-grid > * {
  opacity: 0;
  transform: translateY(40px) scale(0.96);
  transition: opacity 0.85s cubic-bezier(0.16, 1, 0.3, 1),
              transform 0.85s cubic-bezier(0.16, 1, 0.3, 1);
}
.cascade-grid > *:nth-child(1) { transition-delay: 0.06s; }
.cascade-grid > *:nth-child(2) { transition-delay: 0.22s; }
.cascade-grid > *:nth-child(3) { transition-delay: 0.38s; }
.cascade-grid > *:nth-child(4) { transition-delay: 0.54s; }
.cascade-grid.visible > * { opacity: 1; transform: translateY(0) scale(1); }

/* ════════════════════════════════════════
   MODAL AUDITORÍA
════════════════════════════════════════ */
#audit-overlay.visible { opacity: 1; }

.modal-section-header { margin-bottom: 28px; }
.modal-section-badge {
  display: inline-block; font-size: 10px; font-weight: 700;
  letter-spacing: 0.2em; text-transform: uppercase;
  color: rgba(255,255,255,0.4); margin-bottom: 10px;
}
.modal-section-title {
  font-size: clamp(20px,2.4vw,26px); font-weight: 700;
  letter-spacing: -0.02em; color: #fff; margin: 0 0 8px;
}
.modal-section-desc { font-size: 14px; color: rgba(255,255,255,0.55); margin: 0; line-height: 1.6; }

.modal-q { margin-bottom: 24px; }
.modal-q-text { font-size: 15px; color: rgba(255,255,255,0.85); margin: 0 0 12px; line-height: 1.5; }
.modal-q-inputs { display: flex; flex-direction: column; gap: 8px; }

.modal-option {
  display: flex; align-items: center; gap: 12px;
  padding: 12px 16px; border-radius: 10px;
  border: 1px solid rgba(255,255,255,0.1);
  color: rgba(255,255,255,0.75); font-size: 14px; cursor: pointer;
  transition: border-color .15s, background .15s;
}
.modal-option input { display: none; }
.modal-option:hover { border-color: rgba(61,91,224,0.6); background: rgba(61,91,224,0.06); }
.modal-option.selected { border-color: var(--blue); background: rgba(61,91,224,0.12); color: #fff; }

.modal-input, .modal-textarea {
  width: 100%; padding: 12px 16px; border-radius: 10px;
  border: 1px solid rgba(255,255,255,0.12); background: rgba(255,255,255,0.04);
  color: #fff; font-size: 14px; font-family: inherit; outline: none;
  transition: border-color .15s; box-sizing: border-box;
}
.modal-input:focus, .modal-textarea:focus { border-color: var(--blue); }
.modal-textarea { resize: vertical; min-height: 80px; }

.modal-nav {
  display: flex; justify-content: space-between; align-items: center;
  margin-top: 32px; padding-top: 24px;
  border-top: 1px solid rgba(255,255,255,0.07);
}
.btn-modal-next {
  background: var(--blue); color: #fff; border: none; border-radius: 10px;
  padding: 13px 28px; font-size: 14px; font-weight: 700; font-family: inherit;
  cursor: pointer; transition: background .15s;
}
.btn-modal-next:hover:not(:disabled) { background: #2f4ccc; }
.btn-modal-next:disabled { opacity: 0.45; cursor: not-allowed; }
.btn-modal-back {
  background: transparent; color: rgba(255,255,255,0.5); border: none;
  font-size: 14px; font-family: inherit; cursor: pointer;
  transition: color .15s;
}
.btn-modal-back:hover { color: rgba(255,255,255,0.85); }

/* ════════════════════════════════════════
   RESPONSIVE GLOBAL
════════════════════════════════════════ */
@media (max-width: 1024px) {
  nav { padding: 0 var(--lg); }
  .nav-links { display: none; }
  footer { padding-left: var(--lg); padding-right: var(--lg); }
  .footer-grid { grid-template-columns: 1fr; gap: var(--2xl); }
  .footer-bottom { flex-direction: column; gap: 8px; text-align: center; }
}
