/* ==========================================================================
   Martí Systems — landing
   Estilo: mate, callado, old money. Negro dominante · Hueso texto ·
   Latón RESERVADO (CTA principal + detalles finos). Sin glass, sin glows.
   ========================================================================== */
:root {
  --negro:   #111113;
  --elev:    #1A1A1C;
  --linea:   #2A2A2E;
  --hueso:   #EDE7D9;
  --apagado: #9D9A94;
  --laton:   #B08A4F;
}

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

html { scroll-behavior: smooth; }

body {
  background-color: var(--negro);
  /* Grano sutil global (la hero lo tapa con su propio fondo) */
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.8' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix type='saturate' values='0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.05'/%3E%3C/svg%3E");
  color: var(--hueso);
  font-family: 'EB Garamond', serif;
  font-size: 18px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

h1, h2, h3, h4 {
  font-family: 'EB Garamond', serif;
  font-weight: 400;
  color: var(--hueso);
  line-height: 1.15;
}

p { color: var(--apagado); }

a { color: var(--hueso); text-decoration: none; }

:focus-visible { outline: 2px solid var(--laton); outline-offset: 3px; }

/* ============================ Layout ============================ */
.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 32px;
}
@media (min-width: 768px) { .container { padding: 0 40px; } }

.divider { width: 100%; height: 1px; background-color: var(--linea); }

.section-spacing { padding: 120px 0; }
@media (min-width: 768px) { .section-spacing { padding: 160px 0; } }

/* ============================ Animations ============================ */
.fade-in {
  opacity: 0;
  transform: translateY(15px);
  transition: opacity 1s cubic-bezier(0.2, 0, 0, 1), transform 1s cubic-bezier(0.2, 0, 0, 1);
}
.fade-in.visible { opacity: 1; transform: translateY(0); }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .fade-in { opacity: 1 !important; transform: none !important; }
}

/* ============================ Navigation ============================ */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  padding: 22px 0;
  z-index: 100;
  background-color: transparent;
  border-bottom: 1px solid transparent;
  transition: background-color 0.4s ease, border-color 0.4s ease;
}
/* Al hacer scroll: aparece el fondo y la separación */
.nav.is-scrolled {
  background-color: var(--negro);
  border-bottom-color: var(--linea);
}

.nav-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
  padding: 0 32px;
}
@media (min-width: 768px) {
  .nav-container {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    padding: 0 64px;
  }
}

.logo-link { display: inline-flex; align-items: center; }
.logo-svg { height: 15px; width: auto; display: block; }
@media (min-width: 768px) { .logo-svg { height: 18px; } }

.nav-links { display: none; }
@media (min-width: 768px) {
  .nav-links { display: flex; gap: 56px; justify-content: center; }
}

.nav-link {
  font-family: 'Geist', sans-serif;
  font-size: 12px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--apagado);
  position: relative;
  transition: color 0.3s ease;
}
.nav-link::after {
  content: '';
  position: absolute;
  width: 0; height: 1px;
  bottom: -4px; left: 0;
  background-color: var(--hueso);
  transition: width 0.3s ease;
}
.nav-link:hover { color: var(--hueso); }
.nav-link:hover::after { width: 100%; }

.nav-actions { display: none; }
@media (min-width: 768px) { .nav-actions { display: flex; justify-content: flex-end; } }

.btn-nav-outline {
  display: inline-flex;
  align-items: center;
  padding: 8px 20px;
  font-family: 'Geist', sans-serif;
  font-size: 11px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: #C5C0B6;
  border: 1px solid rgba(237, 231, 217, 0.22);
  background: transparent;
  transition: color 0.3s ease, border-color 0.3s ease;
}
.btn-nav-outline:hover { color: var(--hueso); border-color: rgba(237, 231, 217, 0.45); }

/* ============================ Agenda ============================ */
.agenda-modal {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  background-color: rgba(17, 17, 19, 0.72);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.22s ease, visibility 0.22s ease;
}
.agenda-modal.is-open {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}
.agenda-modal-card {
  position: relative;
  width: min(100%, 540px);
  max-height: calc(100vh - 40px);
  padding: 44px 12px 12px;
  overflow: auto;
  background-color: #FAF9F6;
  border-radius: 8px;
  transform: scale(0.98);
  transition: transform 0.22s ease;
}
.agenda-modal.is-open .agenda-modal-card { transform: scale(1); }
.agenda-modal-close {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 28px;
  height: 28px;
  border: 0;
  background: transparent;
  color: #4A4843;
  font-family: 'Geist', sans-serif;
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
  transition: color 0.2s ease;
}
.agenda-modal-close:hover { color: var(--negro); }
.agenda-frame { min-height: 640px; }
.agenda-frame iframe { display: block; }
@media (max-width: 767px) {
  .agenda-modal { padding: 10px; }
  .agenda-modal-card {
    width: 100%;
    max-height: calc(100vh - 20px);
    padding: 42px 8px 8px;
  }
}

/* ============================ Buttons ============================ */
.btn {
  font-family: 'Geist', sans-serif;
  font-size: 13px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  padding: 16px 38px;
  border-radius: 2px;
  cursor: pointer;
  transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

/* El ÚNICO sitio donde el latón manda: el CTA principal */
.btn-primary { background-color: var(--laton); color: var(--negro); border: 1px solid var(--laton); }
.btn-primary:hover { background-color: #cdac6c; border-color: #cdac6c; }
.btn:disabled,
.btn:disabled:hover {
  cursor: not-allowed;
  opacity: 0.48;
  background-color: var(--laton);
  border-color: var(--laton);
}

/* Enlace secundario del hero, con flecha que se desliza */
.hero-link {
  font-family: 'Geist', sans-serif;
  font-size: 14px;
  font-weight: 500;
  letter-spacing: 0.02em;
  color: #C5C0B6;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  transition: color 0.3s ease;
}
.hero-link .arrow { transition: transform 0.3s ease; }
.hero-link:hover { color: var(--hueso); }
.hero-link:hover .arrow { transform: translateX(5px); }

.w-100 { width: 100%; }
.mt-4 { margin-top: 16px; }

/* ============================ Shared bits ============================ */
.section-title { font-size: clamp(32px, 5vw, 44px); margin-bottom: 24px; max-width: 700px; }
.section-text { font-size: 20px; max-width: 650px; margin-bottom: 64px; }

/* ============================ Hero ============================ */
.hero {
  position: relative;
  min-height: 100vh;
  padding: 120px 0 90px;
  display: flex;
  align-items: center;
  background-image:
    linear-gradient(rgba(17,17,19,0.22), rgba(17,17,19,0.22)),
    radial-gradient(ellipse 115% 130% at 50% 42%, rgba(17,17,19,0) 52%, rgba(17,17,19,0.5) 100%),
    radial-gradient(ellipse 65% 70% at 100% 0%, rgba(17,17,19,0.55) 0%, rgba(17,17,19,0) 60%),
    linear-gradient(90deg, rgba(17,17,19,0.95) 0%, rgba(17,17,19,0.85) 40%, rgba(17,17,19,0.58) 74%, rgba(17,17,19,0.42) 100%),
    linear-gradient(180deg, rgba(17,17,19,0.35) 0%, rgba(17,17,19,0) 22%, rgba(17,17,19,0) 66%, var(--negro) 100%),
    url('img/hero.jpg');
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}
@media (min-width: 768px) { .hero { padding: 140px 0 100px; } }

.hero-container { display: block; max-width: none; padding: 0 32px; }
@media (min-width: 768px) { .hero-container { padding: 0 64px; } }

.hero-content { display: flex; flex-direction: column; gap: 30px; max-width: none; }

.hero-title {
  font-family: 'EB Garamond', serif;
  font-size: clamp(38px, 4.8vw, 84px);
  line-height: 1.04;
  color: var(--hueso);
}
.hero-title span { display: block; }
/* En escritorio, cada frase en una sola línea */
@media (min-width: 992px) { .hero-title span { white-space: nowrap; } }

/* Segundo tiempo del mensaje: Garamond, apagado (NO etiqueta dorada) */
.hero-subtitle {
  font-family: 'EB Garamond', serif;
  font-size: clamp(20px, 2.4vw, 25px);
  font-weight: 400;
  color: var(--apagado);
  max-width: 560px;
  margin: 0;
}

.hero-actions { display: flex; flex-direction: column; gap: 16px; margin-top: 14px; }
@media (min-width: 480px) { .hero-actions { flex-direction: row; align-items: center; gap: 20px; } }

/* (indicador de scroll retirado) */

/* ============================ Enfoque (editorial) ============================ */
.editorial-layout { display: grid; grid-template-columns: 1fr; gap: 64px; }
@media (min-width: 992px) {
  .editorial-layout { grid-template-columns: 1fr 1.1fr; gap: 96px; align-items: start; }
}

.editorial-left { max-width: 500px; }
@media (min-width: 992px) { .editorial-left { position: sticky; top: 140px; } }

.overlapping-cards { position: relative; display: flex; flex-direction: column; gap: 16px; padding-top: 16px; }
@media (min-width: 992px) { .overlapping-cards { gap: 0; } }

.overlap-card {
  background-color: var(--elev);
  border: 1px solid var(--linea);
  border-radius: 6px;
  padding: 32px;
  position: relative;
  opacity: 0;
  transform: translateY(22px);
  transition: opacity 0.7s cubic-bezier(0.2, 0, 0, 1), transform 0.7s cubic-bezier(0.2, 0, 0, 1), border-color 0.4s ease;
}
.overlap-card.revealed { opacity: 1; transform: translateY(0); }
@media (min-width: 992px) {
  .overlap-card { padding: 40px; margin-bottom: -40px; }
  .oc-1 { z-index: 3; width: 90%; align-self: flex-start; }
  .oc-2 { z-index: 2; width: 95%; align-self: flex-end; }
  .oc-3 { z-index: 1; width: 93%; align-self: flex-start; margin-bottom: 0; }
}
.overlap-card:hover { border-color: var(--laton); z-index: 10; }

.oc-title { font-size: 30px; color: var(--hueso); line-height: 1.2; margin-bottom: 12px; }
.oc-desc { font-size: 20px; color: var(--apagado); line-height: 1.5; max-width: 450px; }

/* ============================ Diferencia (resultados) ============================ */
.sistemas-header { margin-bottom: 56px; }

/* Resultados — filas editoriales (manifiesto), no tarjetas */
.outcomes { border-top: 1px solid var(--linea); }
.outcome {
  position: relative;
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px;
  padding: 26px 0;
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.8s cubic-bezier(0.2, 0, 0, 1), transform 0.8s cubic-bezier(0.2, 0, 0, 1);
}
@media (min-width: 768px) {
  .outcome { grid-template-columns: 0.9fr 1.1fr; gap: 48px; align-items: baseline; }
}
/* Línea inferior que se "dibuja" al entrar (ledger) */
.outcome::after {
  content: '';
  position: absolute;
  left: 0; bottom: 0;
  width: 100%; height: 1px;
  background-color: var(--linea);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.9s cubic-bezier(0.22, 1, 0.36, 1);
}
/* Marcador de latón al pasar el cursor */
.outcome::before {
  content: '';
  position: absolute;
  left: 0; top: 28px;
  width: 1px; height: 22px;
  background-color: var(--laton);
  opacity: 0;
  transform: scaleY(0.4);
  transform-origin: center;
  transition: opacity 0.3s ease, transform 0.35s ease;
}
.outcome.revealed { opacity: 1; transform: translateY(0); }
.outcome.revealed::after { transform: scaleX(1); }
.outcome:hover::before { opacity: 1; transform: scaleY(1); }

.outcome-title { font-family: 'EB Garamond', serif; font-weight: 400; font-size: clamp(19px, 2.2vw, 25px); color: var(--hueso); line-height: 1.15; transition: transform 0.4s cubic-bezier(0.22, 1, 0.36, 1); }
.outcome-desc { font-family: 'EB Garamond', serif; font-size: 17px; color: var(--apagado); line-height: 1.5; margin: 0; max-width: 440px; transition: color 0.3s ease; }
.outcome:hover .outcome-title { transform: translateX(12px); }
.outcome:hover .outcome-desc { color: var(--hueso); }

/* ============================ Método ============================ */
.sticky-scroll-layout { position: relative; }

.method-manifesto-title { font-size: clamp(32px, 5vw, 44px); line-height: 1.15; color: var(--hueso); margin-bottom: 40px; max-width: 900px; }
.method-manifesto-text { max-width: 500px; }
.method-manifesto-quote { padding-left: 24px; border-left: 2px solid var(--laton); margin-top: 60px; }
.method-manifesto-quote p { font-size: clamp(15px, 1.7vw, 17px); font-style: normal; color: var(--hueso); line-height: 1.5; }

@media (min-width: 992px) { .method-manifesto-quote { margin-top: 48px; } }

.scroll-steps { position: relative; display: flex; flex-direction: column; gap: 56px; }
.s-step { display: flex; flex-direction: row; gap: 24px; position: relative; }
.s-step-visual { width: 2px; background-color: transparent; position: relative; }

/* Línea continua: pista gris + relleno hueso que baja con el scroll */
.steps-track, .steps-progress { position: absolute; left: 5px; width: 1px; z-index: 1; }
.steps-track { background-color: var(--linea); }
.steps-progress { background-color: #CFC8BB; height: 0; }
.s-step-visual::before {
  content: '';
  position: absolute;
  top: 3px; left: 0;
  width: 9px; height: 9px;
  border-radius: 50%;
  background-color: var(--negro);
  border: 1px solid var(--laton);
  z-index: 2;
  transition: background-color 0.45s ease;
}
/* Punto completado: se rellena en latón cuando la línea lo alcanza */
.s-step.is-done .s-step-visual::before { background-color: var(--laton); }
.s-step-content { flex: 1; padding-bottom: 24px; }
.s-num { font-family: 'Geist', sans-serif; font-size: 12px; font-weight: 500; color: var(--apagado); letter-spacing: 0.12em; display: block; margin-bottom: 12px; transition: color 0.45s ease; }
.s-step.is-done .s-num { color: var(--hueso); }
.s-title { font-size: 28px; color: var(--hueso); margin-bottom: 12px; line-height: 1.2; }
.s-desc { font-size: 18px; color: var(--apagado); line-height: 1.5; }

/* ============================ CTA (contacto) ============================ */
/* Variación dark-on-dark: un punto más claro, alternando con las secciones base */
#metodo, .cta-section { background-color: rgba(237, 231, 217, 0.02); }
/* Entrada sutil escalonada: el texto y luego la tarjeta */
.cta-split-left.fade-in, .cta-split-right.fade-in { transition-duration: 1.1s; }
.cta-split-right.fade-in { transition-delay: 0.18s; }

.cta-split-layout { display: flex; flex-direction: column; gap: 64px; }
@media (min-width: 992px) {
  .cta-split-layout { flex-direction: row; gap: 80px; align-items: center; }
  .cta-split-left { flex: 1; max-width: 500px; }
  .cta-split-right { flex: 1; max-width: 450px; width: 100%; }
}

.cta-title { font-size: clamp(38px, 5.5vw, 60px); line-height: 1.08; color: var(--hueso); margin-bottom: 24px; }
.cta-split-left .section-text { margin-bottom: 0; }

/* Tarjeta de contacto: el ÚNICO momento en claro. Papel #FAF9F6 (no Hueso,
   que vira a sepia). Filete de latón + sombra suave = tarjeta sobre la mesa. */
.premium-form-card {
  background-color: #FAF9F6;
  border: 1px solid #E4DFD4;
  border-top: 2px solid var(--laton);
  border-radius: 8px;
  padding: 36px 32px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.35);
  overflow: hidden;
  transition: height 0.45s cubic-bezier(0.22, 1, 0.36, 1), opacity 0.22s ease;
}

#form-evaluacion {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.form-group { display: flex; flex-direction: column; gap: 8px; }
.form-label {
  font-family: 'Geist', sans-serif;
  font-size: 12px;
  font-weight: 500;
  color: #111113;
  text-transform: uppercase;
  letter-spacing: 0.1em;
}
.form-input {
  background-color: #FFFFFF;
  border: 1px solid #DDD6C8;
  color: #111113;
  font-family: 'Geist', sans-serif;
  font-size: 14px;
  padding: 12px 16px;
  border-radius: 4px;
  width: 100%;
  line-height: 1.5;
  transition: border-color 0.3s ease;
}
.form-input::placeholder { color: rgba(17, 17, 19, 0.35); }
.form-input:focus { outline: none; border-color: var(--laton); }
.form-textarea { min-height: 90px; resize: none; }

.hp {
  position: absolute;
  left: -10000px;
  top: auto;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.consent-check {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 6px;
  color: #5D594F;
  font-family: 'Geist', sans-serif;
  font-size: 11px;
  line-height: 1.45;
  cursor: pointer;
}
.consent-check a {
  color: #111113;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}
.consent-check input {
  width: 15px;
  height: 15px;
  flex: 0 0 15px;
  accent-color: var(--laton);
}
.form-status {
  min-height: 18px;
  color: #6F3D32;
  font-family: 'Geist', sans-serif;
  font-size: 12px;
  line-height: 1.4;
}
.premium-form-card.is-fading { opacity: 0; }
.premium-form-card.is-success {
  justify-content: center;
}
.form-success {
  color: #111113;
  font-family: 'EB Garamond', serif;
  font-size: 20px;
  line-height: 1.3;
}
.form-success strong { font-weight: 500; }

/* ============================ Footer ============================ */
.footer { padding: 56px 0 32px; background-color: var(--elev); border-top: 1px solid var(--linea); }
/* Footer a ancho completo, alineado con el nav (bookend) */
.footer .container { max-width: none; }
@media (min-width: 768px) { .footer .container { padding: 0 64px; } }

.footer-grid { display: grid; grid-template-columns: 1fr; gap: 40px; margin-bottom: 48px; }
@media (min-width: 768px) { .footer-grid { grid-template-columns: 2fr 1fr 1fr 1fr; gap: 32px; } }

.footer-col { display: flex; flex-direction: column; gap: 12px; }
.footer-logo { height: 48px; width: auto; align-self: flex-start; margin-bottom: 10px; }

.footer-heading { font-family: 'Geist', sans-serif; font-size: 12px; font-weight: 500; text-transform: uppercase; letter-spacing: 0.12em; color: var(--hueso); margin-bottom: 8px; }
.footer-link, .footer-text { font-family: 'Geist', sans-serif; font-size: 13px; color: var(--apagado); }
.footer-link { position: relative; display: inline-block; transition: color 0.3s ease; }
.footer-link::after { content: ''; position: absolute; width: 0; height: 1px; bottom: -2px; left: 0; background-color: var(--hueso); transition: width 0.3s ease; }
.footer-link:hover { color: var(--hueso); }
.footer-link:hover::after { width: 100%; }

.footer-bottom { padding-top: 32px; border-top: 1px solid var(--linea); }
.copyright { font-family: 'Geist', sans-serif; font-size: 12px; color: var(--apagado); }
