/* ==========================================================================
   ZEA SEGURA — V25 · Sistema de marca unificado + UX premium + móvil
   --------------------------------------------------------------------------
   Se carga AL FINAL. Unifica toda la web con el sistema visual de FLOWNEWS
   (la página más pulida): fuentes Playfair Display + Epilogue y la paleta
   verde #1B5E37 / rosa #F9C8D0 / crema #F5F0E8. Además: pop-up de
   confirmación, botones de envío, refinamientos de UX y optimización móvil.
   ========================================================================== */

/* ---------- 1. TOKENS DE MARCA (fuente de verdad: FLOWNEWS) ------------- */
:root {
  /* Verdes */
  --green: #1B5E37;
  --green-dark: #1B5E37;
  --green-deep: #0F3B22;
  --green-soft: #1F6B3F;
  /* Rosas */
  --pink: #F9C8D0;
  --pink-strong: #F9C8D0;
  --pink-soft: #FBD9DF;
  /* Neutros / crema */
  --cream: #F5F0E8;
  --cream-2: #EDE8DE;
  --cream-warm: #F5F0E8;
  --paper: #FFFFFF;
  --ink: #111010;
  --mid: #5A5248;
  --line: rgba(27, 94, 55, .14);
  /* Estados */
  --ok: #1B5E37;
  --amber: #F59E0B;
  --danger: #EF4444;
  /* Tipografía de marca */
  --font-script: "Playfair Display", Georgia, serif;
  --font-display: "Playfair Display", Georgia, "Times New Roman", serif;
  --font-sans: "Epilogue", "Helvetica Neue", Arial, sans-serif;
  /* Sombra premium */
  --shadow: 0 24px 70px rgba(15, 59, 34, .14);
  --shadow-sm: 0 10px 28px rgba(15, 59, 34, .10);
  --ease: cubic-bezier(.22, .61, .36, 1);
}

/* Suavizado de fuentes para acabado premium */
body {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  background: var(--cream);
}

/* Foco visible coherente y elegante en todo el sitio (accesibilidad) */
a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible,
[tabindex]:focus-visible {
  outline: 3px solid var(--green-soft);
  outline-offset: 2px;
  border-radius: 6px;
}

/* ---------- 2. TIPOGRAFÍA COHERENTE ------------------------------------ */
/* Todos los títulos display en Playfair; toda la UI/cuerpo en Epilogue.
   Se sustituyen los "Georgia" hard-coded que habían quedado sueltos. */
.hero h1,
.lab-title-stage h1,
.lab-band,
.lab-intro,
.lab-visible-contact h2,
.meet-wireframe-card h1,
.meet-card h2,
.nuku-lead,
.values-track span,
.process-card h3,
.process-card span,
.legal-hero h1 {
  font-family: var(--font-display);
}
.main-nav a,
.button,
.nav-meet,
.footer h2,
.newsletter-form label,
.process-card p,
.lab-intro,
.reference-contact-form input,
.reference-contact-form textarea,
.lab-inline-fields input {
  font-family: var(--font-sans);
}
/* Los inputs de contacto usaban Georgia italic; pasan a Epilogue limpio. */
.reference-contact-form input,
.reference-contact-form textarea,
.lab-inline-fields input {
  font-style: normal !important;
  font-size: 15px;
  letter-spacing: .01em;
}

/* ---------- 3. HEADER / NAV -------------------------------------------- */
.site-header {
  background: var(--green-deep);
  backdrop-filter: saturate(120%);
}
.main-nav a {
  font-weight: 600;
  letter-spacing: .12em;
  position: relative;
}
/* Subrayado animado premium en el nav */
.main-nav a:not(.nav-meet)::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: 6px;
  height: 2px;
  background: var(--pink);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform .3s var(--ease);
}
.main-nav a:not(.nav-meet):hover::after,
.main-nav a:not(.nav-meet).is-active::after {
  transform: scaleX(1);
}
.main-nav a.nav-meet {
  border-color: var(--pink);
  transition: background .25s var(--ease), color .25s var(--ease);
}
.main-nav a.nav-meet:hover,
.main-nav a.nav-meet:focus-visible {
  background: var(--pink);
  color: var(--green-deep);
}

/* ---------- 4. BOTONES (sistema unificado) ----------------------------- */
.button,
.hero-button,
.contact-submit-front,
.lab-inline-submit,
.newsletter-submit,
.global-contact-cta,
.meet-contact {
  font-family: var(--font-sans);
  font-weight: 700;
  letter-spacing: .06em;
  transition: transform .2s var(--ease), background-color .2s var(--ease),
              color .2s var(--ease), box-shadow .2s var(--ease);
  will-change: transform;
}
.button:hover,
.hero-button:hover,
.contact-submit-front:hover,
.lab-inline-submit:hover,
.newsletter-submit:hover,
.meet-contact:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-sm);
}
.button:active,
.lab-inline-submit:active,
.newsletter-submit:active,
.contact-submit-front:active { transform: translateY(0); }

/* ---------- 5. NEWSLETTER: pila robusta (label · input · botón) -------- */
/* Reconstrucción limpia sobre el footer. Anulamos el label flotante absoluto
   heredado y apilamos etiqueta, campo y botón con áreas táctiles cómodas. */
.footer-newsletter .newsletter-form {
  position: static !important;
  display: flex !important;
  flex-direction: column;
  align-items: stretch;
  gap: 10px;
  width: 100%;
}
.footer-newsletter .newsletter-form label {
  position: static !important;
  top: auto !important;
  left: auto !important;
  transform: none !important;
  order: -1;                       /* la etiqueta siempre arriba */
  pointer-events: auto;
  color: var(--pink) !important;
  font-family: var(--font-sans);
  font-size: 12px !important;
  font-weight: 700 !important;
  letter-spacing: .16em;
}
.footer-newsletter .newsletter-form input {
  width: 100%;
  height: 50px !important;
  padding: 4px 20px !important;    /* sin el padding-left de 91px del diseño viejo */
  border: 2px solid var(--pink) !important;
  border-radius: 999px;
  background: rgba(255, 255, 255, .06) !important;
  color: #fff;
  font-family: var(--font-sans);
  font-size: 15px;
}
.footer-newsletter .newsletter-form input::placeholder { color: rgba(255,255,255,.5); }
.footer-newsletter .newsletter-form input:focus {
  border-color: #fff !important;
  background: rgba(255, 255, 255, .12) !important;
  box-shadow: 0 0 0 4px rgba(249, 200, 208, .22) !important;
}
.footer-wireframe .footer-newsletter .newsletter-submit,
.newsletter-submit {
  align-self: start;
  min-height: 46px;
  padding: 12px 32px !important;
  border: 2px solid var(--pink) !important;
  border-radius: 999px;
  background: var(--pink) !important;
  color: var(--green-deep) !important;
  font-family: var(--font-sans);
  font-size: 13px !important;
  font-weight: 800;
  letter-spacing: .06em;
  text-transform: uppercase;
  cursor: pointer;
  width: auto;
}
.footer-wireframe .footer-newsletter .newsletter-submit:hover,
.footer-wireframe .footer-newsletter .newsletter-submit:focus-visible,
.newsletter-submit:hover,
.newsletter-submit:focus-visible {
  background: transparent !important;
  color: var(--pink) !important;
}
.footer-newsletter .newsletter-status {
  position: static !important;
  color: var(--pink-soft);
  font-size: 12px;
}
@media (max-width: 420px) {
  .newsletter-submit { align-self: stretch; width: 100%; text-align: center; }
}

/* ---------- 6. FORMULARIOS DE CONTACTO: refinamiento ------------------- */
.reference-contact-form input,
.reference-contact-form textarea {
  height: 46px;
  border: 2px solid var(--green-dark);
  border-radius: 999px;
  background: #fff;
  color: var(--green-deep);
  text-align: left;              /* antes iban a la derecha: menos legible */
  transition: border-color .2s var(--ease), box-shadow .2s var(--ease);
}
.reference-contact-form input::placeholder,
.reference-contact-form textarea::placeholder {
  color: #9aa39d;
}
.reference-contact-form input:focus,
.reference-contact-form textarea:focus {
  border-color: var(--green-soft);
  box-shadow: 0 0 0 4px rgba(27, 94, 55, .12);
  outline: none;
}
.reference-contact-form .form-status,
.lab-visible-contact .form-status {
  text-align: left;
  font-size: 12px;
}
.form-status.error { color: var(--danger); font-weight: 600; }

/* Botón ENVIAR del modal y de los inline: acabado premium */
.contact-submit-front,
.lab-inline-submit {
  min-height: 48px;
  padding: 12px 34px;
  border: 2px solid var(--green-dark);
  border-radius: 999px;
  background: var(--green-dark);
  color: #fff;
  font-size: 14px;
  font-weight: 800;
  text-transform: uppercase;
  cursor: pointer;
}
.contact-submit-front:hover,
.lab-inline-submit:hover,
.contact-submit-front:focus-visible,
.lab-inline-submit:focus-visible {
  background: var(--pink);
  color: var(--green-deep);
  border-color: var(--pink);
}
.contact-submit-front:disabled,
.lab-inline-submit:disabled,
.newsletter-submit:disabled {
  opacity: .6;
  cursor: wait;
  transform: none;
}

/* ---------- 7. ZEALAB: pulido premium ---------------------------------- */
.lab-selector-band { background: var(--green-deep); }
.lab-selector-band .lab-tabs button {
  font-family: var(--font-display);
  transition: transform .2s var(--ease);
}
.lab-selector-band .lab-tabs button:hover { transform: translateY(-2px); }
.seguros-band { background: var(--green-deep); }
.arl-band { background: var(--pink); color: var(--green-deep); }
.process-card {
  border: 1px solid var(--line);
  border-radius: 18px;
  transition: transform .25s var(--ease), box-shadow .25s var(--ease);
}
.process-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-sm);
}
.lab-visible-contact { background: var(--cream); }

/* ---------- 8. POP-UP DE CONFIRMACIÓN (toast modal) -------------------- */
.zea-toast {
  position: fixed;
  inset: 0;
  z-index: 400;
  display: grid;
  place-items: center;
  padding: 20px;
}
.zea-toast[hidden] { display: none; }
.zea-toast-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(15, 59, 34, .55);
  backdrop-filter: blur(3px);
  opacity: 0;
  transition: opacity .2s var(--ease);
}
.zea-toast.is-visible .zea-toast-backdrop { opacity: 1; }
.zea-toast-card {
  position: relative;
  width: min(430px, 100%);
  background: #fff;
  border-radius: 24px;
  padding: 40px 32px 32px;
  text-align: center;
  box-shadow: var(--shadow);
  transform: translateY(14px) scale(.96);
  opacity: 0;
  transition: transform .28s var(--ease), opacity .28s var(--ease);
}
.zea-toast.is-visible .zea-toast-card {
  transform: translateY(0) scale(1);
  opacity: 1;
}
.zea-toast-icon {
  width: 68px;
  height: 68px;
  margin: 0 auto 18px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  color: #fff;
}
.zea-toast-icon.is-ok { background: var(--green-dark); }
.zea-toast-icon.is-error { background: var(--danger); }
.zea-toast-card h3 {
  margin: 0 0 10px;
  font-family: var(--font-display);
  font-size: clamp(24px, 4vw, 30px);
  color: var(--green-deep);
  line-height: 1.1;
}
.zea-toast-card p {
  margin: 0 0 26px;
  font-family: var(--font-sans);
  font-size: 15px;
  line-height: 1.55;
  color: var(--mid);
}
.zea-toast-card p a { color: var(--green-dark); font-weight: 700; text-decoration: underline; }
.zea-toast-ok {
  min-height: 48px;
  padding: 13px 40px;
  border: 0;
  border-radius: 999px;
  background: var(--green-dark);
  color: #fff;
  font-family: var(--font-sans);
  font-size: 14px;
  font-weight: 800;
  letter-spacing: .05em;
  text-transform: uppercase;
  cursor: pointer;
  transition: background .2s var(--ease), transform .2s var(--ease);
}
.zea-toast-ok:hover { background: var(--green-deep); transform: translateY(-2px); }
.zea-toast-x {
  position: absolute;
  top: 14px; right: 16px;
  width: 36px; height: 36px;
  border: 0;
  background: transparent;
  color: var(--mid);
  font-size: 26px;
  line-height: 1;
  cursor: pointer;
  border-radius: 999px;
}
.zea-toast-x:hover { background: var(--cream-2); }

/* ---------- 9. MEET ZEA: título con contraste de marca ---------------- */
.meet-wireframe-card h1 {
  color: var(--green-deep);      /* antes gris #8f9496 (bajo contraste) */
  font-family: var(--font-display);
}
.meet-wireframe .meet-pill,
.meet-wireframe .meet-contact {
  transition: transform .2s var(--ease), background .2s var(--ease), color .2s var(--ease);
}
.meet-wireframe .meet-pill:hover,
.meet-wireframe .meet-contact:hover {
  transform: translateY(-2px);
  background: var(--green-dark);
  color: #fff;
}

/* ========================================================================
   10. OPTIMIZACIÓN MÓVIL (clase mundial)
   ======================================================================== */
@media (max-width: 640px) {
  /* Áreas táctiles cómodas en todo lo interactivo */
  .main-nav a,
  .button,
  .lab-tabs button,
  .contact-submit-front,
  .lab-inline-submit,
  .newsletter-submit,
  .meet-pill,
  .meet-contact,
  .footer-social-links a {
    min-height: 48px;
  }

  /* Newsletter a ancho completo y cómodo */
  .newsletter-submit { justify-self: stretch; width: 100%; text-align: center; }

  /* Formularios de contacto: campos y botón full-width, sin apretujar */
  .reference-contact-form {
    padding-left: 16px;
    padding-right: 16px;
  }
  .reference-contact-decoration { display: none; } /* la marca de agua estorba en móvil */
  .reference-contact-row { grid-template-columns: 1fr; } /* teléfono y NIT en dos filas */
  .lab-inline-submit,
  .contact-submit-front { width: 100%; justify-self: stretch; }

  /* Pop-up ocupa mejor la pantalla */
  .zea-toast-card { padding: 34px 22px 26px; border-radius: 20px; }

  /* Títulos grandes que no desborden */
  .hero h1 { font-size: clamp(26px, 8.5vw, 40px); }
  .lab-title-stage h1 { font-size: clamp(56px, 20vw, 96px); }
  .meet-wireframe-card h1 { font-size: clamp(38px, 11vw, 56px); }

  /* Marquesinas de valores un poco más contenidas */
  .values-track span { font-size: clamp(18px, 6vw, 26px); }
}

/* Pantallas muy pequeñas */
@media (max-width: 380px) {
  .header-inner { gap: 10px; }
  .zea-toast { padding: 12px; }
  .zea-toast-card { padding: 30px 18px 22px; }
}

/* Respeta usuarios que prefieren menos animación */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .001ms !important;
    transition-duration: .001ms !important;
  }
}
