/* ===========================================================
   Sociedad Escala — Estilos globales
   Fondo único negro, estilo minimal/tech. Basado en brand.md.
   =========================================================== */

:root {
  --emerald: #00674E;
  --emerald-bright: #1E9C74;
  --emerald-deep: #013D2E;
  --black: #0A0A0A;
  --ink: #131313;
  --white: #FFFFFF;
  --bone: #E8E2D4;
  --bone-dim: #9A9587;
  --bone-line: #232323;

  --display: 'Archivo', sans-serif;
  --sans: 'Space Grotesk', sans-serif;
  --mono: 'JetBrains Mono', monospace;
  --script: 'Lora', serif;

  --pad: clamp(20px, 6vw, 120px);
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  font-family: var(--sans);
  background:
    radial-gradient(ellipse 900px 520px at 18% 0%, rgba(30, 156, 116, .20), transparent 55%),
    radial-gradient(ellipse 800px 600px at 88% 12%, rgba(0, 103, 78, .18), transparent 55%),
    radial-gradient(ellipse 1000px 700px at 50% 100%, rgba(1, 61, 46, .28), transparent 55%),
    var(--black);
  background-attachment: fixed;
  background-repeat: no-repeat;
  color: var(--bone-dim);
  -webkit-font-smoothing: antialiased;
  line-height: 1.55;
  overflow-x: hidden;
}

::selection { background: var(--emerald); color: var(--white); }

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }

section { padding: clamp(56px, 9vw, 110px) var(--pad); position: relative; }

h1, h2, h3 {
  font-family: var(--display);
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: -.02em;
  line-height: 1.02;
  color: var(--white);
}

h2 { font-size: clamp(26px, 4.2vw, 52px); text-align: center; margin-left: auto; margin-right: auto; }

.eyebrow {
  font-family: var(--mono);
  font-size: 11px; letter-spacing: .2em; text-transform: uppercase;
  display: flex; align-items: center; gap: 10px; margin-bottom: 22px;
  color: var(--bone-dim);
}
.eyebrow::before { content: "//"; color: var(--emerald-bright); }

.lede {
  font-size: clamp(15px, 1.3vw, 17px); max-width: 56ch; margin-top: 18px;
  font-weight: 300; color: var(--bone-dim);
}

/* ---------- logo ---------- */
.markB rect.blk { fill: var(--white); }
.markB rect.grn { fill: var(--emerald-bright); }

.wordmark {
  font-family: var(--sans); font-weight: 400; text-transform: uppercase;
  letter-spacing: .42em; line-height: 1.35; color: var(--white);
}

/* ---------- nav ---------- */
.site-nav {
  display: flex; align-items: center; justify-content: space-between;
  padding: 20px var(--pad);
  border-bottom: 1px solid var(--bone-line);
}
.site-nav .brand { display: flex; align-items: center; gap: 14px; }
.site-nav .links {
  display: flex; gap: 28px;
  font-family: var(--mono); font-size: 11px; letter-spacing: .08em; text-transform: uppercase;
  color: var(--bone-dim);
}
.site-nav .links a:hover { color: var(--bone); }
.site-nav .links a.active { color: var(--emerald-bright); }
.menu-toggle {
  display: none; position: absolute; right: var(--pad); top: 50%; transform: translateY(-50%);
  flex-direction: column; justify-content: center; gap: 5px;
  width: 32px; height: 32px; background: none; border: none; padding: 0; cursor: pointer;
}
.menu-toggle span {
  width: 22px; height: 2px; background: var(--bone); display: block;
  transition: transform .2s ease, opacity .2s ease;
}
.menu-toggle.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.menu-toggle.open span:nth-child(2) { opacity: 0; }
.menu-toggle.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

.mobile-menu {
  display: none; flex-direction: column;
  background: var(--ink); border-bottom: 1px solid var(--bone-line);
  padding: 4px var(--pad) 16px;
}
.mobile-menu.open { display: flex; }
.mobile-menu a {
  font-family: var(--mono); font-size: 13px; letter-spacing: .08em; text-transform: uppercase;
  color: var(--bone-dim); padding: 16px 0; border-top: 1px solid var(--bone-line);
}
.mobile-menu a:first-child { border-top: 0; }
.mobile-menu a.active { color: var(--emerald-bright); }

@media (max-width: 720px) {
  .site-nav .links { display: none; }
  .site-nav .btn.solid { display: none; }
  .site-nav { justify-content: center; position: relative; }
  .menu-toggle { display: flex; }
}
@media (min-width: 721px) {
  .mobile-menu { display: none !important; }
}

/* ---------- buttons ---------- */
.btn {
  display: inline-block;
  font-family: var(--mono); font-size: 11px; letter-spacing: .08em; text-transform: uppercase;
  padding: 14px 24px; border-radius: 4px;
  transition: opacity .15s ease, border-color .15s ease;
}
.btn:hover { opacity: .82; }
.btn.solid { background: var(--emerald-bright); color: var(--black); font-weight: 500; }
.btn.ghost { border: 1px solid var(--bone-line); color: var(--bone-dim); }
.btn.ghost:hover { border-color: var(--emerald-bright); color: var(--bone); }

/* ---------- hero ---------- */
.hero {
  min-height: 72vh; display: flex; flex-direction: column; justify-content: center; align-items: center;
  text-align: center;
  gap: 18px;
}
@media (max-width: 640px) {
  .hero { min-height: auto; padding-top: 32px; padding-bottom: 32px; }
}
.hero .kicker {
  font-family: var(--mono); font-size: 12px; letter-spacing: .14em; text-transform: uppercase;
  color: var(--emerald-bright);
}
.hero h1 { font-size: clamp(38px, 7.2vw, 92px); max-width: 20ch; color: var(--white); }
.hero h1 em { font-style: normal; color: var(--emerald-bright); }
.hero .tagline {
  font-family: var(--sans); font-weight: 300; font-style: normal;
  font-size: clamp(17px, 1.8vw, 21px); color: var(--emerald-bright);
  line-height: 1.3; margin-top: -4px;
}
.hero .sub { font-size: clamp(15px, 1.3vw, 17px); font-weight: 300; color: var(--bone-dim); max-width: 52ch; }
.hero .btns { display: flex; gap: 14px; flex-wrap: wrap; margin-top: 8px; justify-content: center; }

.hero-link {
  display: inline-block; margin-top: 2px;
  font-family: var(--mono); font-size: 11px; letter-spacing: .08em; text-transform: uppercase;
  color: var(--bone-dim);
}
.hero-link:hover { color: var(--bone); }

.hero-cta { display: flex; flex-direction: column; align-items: center; gap: 12px; margin-top: 4px; }
.hero-cta-note {
  font-family: var(--mono); font-size: 12px; letter-spacing: .04em;
  color: var(--bone-dim); max-width: 40ch;
}

/* ---------- social proof (números) ---------- */
.proof-grid {
  display: grid; grid-template-columns: repeat(3, 1fr);
  border: 1px solid rgba(30, 156, 116, .2); border-radius: 14px; overflow: hidden;
  margin-top: 40px;
}
.proof-row {
  display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center;
  padding: 36px 24px; gap: 10px;
  border-left: 1px solid rgba(30, 156, 116, .2);
}
.proof-row:first-child { border-left: 0; }
.proof-num {
  font-family: var(--display); font-weight: 900; font-size: clamp(34px, 5vw, 56px);
  color: var(--emerald-bright); line-height: 1; letter-spacing: -.01em;
}
.proof-label {
  font-family: var(--mono); font-size: 12px; letter-spacing: .08em; text-transform: uppercase;
  color: var(--bone-dim);
}
@media (max-width: 640px) {
  .proof-grid { grid-template-columns: 1fr; }
  .proof-row { border-left: 0; border-top: 1px solid rgba(30, 156, 116, .2); }
  .proof-row:first-child { border-top: 0; }
}

/* ---------- logo strip (clientes) ---------- */
.logo-marquee {
  overflow: hidden;
  position: relative;
  -webkit-mask-image: linear-gradient(to right, transparent, black 10%, black 90%, transparent);
  mask-image: linear-gradient(to right, transparent, black 10%, black 90%, transparent);
}
.logo-track {
  display: flex; align-items: center; gap: 64px;
  width: max-content;
  animation: logo-scroll 30s linear infinite;
}
.logo-marquee:hover .logo-track { animation-play-state: paused; }
.logo-track img {
  height: 30px; width: auto; object-fit: contain; flex-shrink: 0;
  filter: grayscale(1) invert(1) brightness(1.7); opacity: .6;
  transition: opacity .2s ease;
}
.logo-track img:hover { opacity: 1; }
@keyframes logo-scroll {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}
@media (prefers-reduced-motion: reduce) {
  .logo-track { animation: none; }
}

/* ---------- cards / grids ---------- */
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-top: 40px; }
@media (max-width: 820px) { .grid-2 { grid-template-columns: 1fr; } }

.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; margin-top: 40px; }
@media (max-width: 980px) { .grid-4 { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .grid-4 { grid-template-columns: 1fr; } }

.card {
  position: relative;
  padding: 32px;
  background: var(--ink);
  border: 1px solid rgba(30, 156, 116, .22);
  border-radius: 14px;
  box-shadow: 0 24px 48px -32px rgba(30, 156, 116, .35);
  transition: border-color .2s ease, box-shadow .2s ease, transform .2s ease;
}
.card .badge-top {
  position: absolute; top: -12px; right: 20px;
  background: var(--emerald-bright); color: var(--black);
  font-family: var(--mono); font-size: 10px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase;
  padding: 6px 12px; border-radius: 20px;
  box-shadow: 0 8px 18px -6px rgba(30, 156, 116, .6);
}
.card:hover {
  border-color: rgba(30, 156, 116, .55);
  box-shadow: 0 24px 48px -20px rgba(30, 156, 116, .5);
  transform: translateY(-3px);
}
.card h4 {
  font-family: var(--mono); font-size: 11px; letter-spacing: .1em; text-transform: uppercase;
  color: var(--emerald-bright); margin-bottom: 12px;
}
.card p { font-size: 14px; font-weight: 300; color: var(--bone-dim); }

/* ---------- stats strip ---------- */
.stats-strip {
  display: grid; grid-template-columns: repeat(3, 1fr);
  border: 1px solid rgba(30, 156, 116, .2); border-radius: 14px; overflow: hidden;
}
@media (max-width: 640px) { .stats-strip { grid-template-columns: 1fr; } }
.stats-strip div { padding: 28px clamp(18px, 3vw, 36px); border-left: 1px solid rgba(30, 156, 116, .2); }
.stats-strip div:first-child { border-left: 0; }
.stats-strip .n { font-family: var(--display); font-weight: 900; font-size: clamp(30px, 4vw, 44px); color: var(--white); line-height: 1; }
.stats-strip .l { font-family: var(--mono); font-size: 10px; letter-spacing: .08em; text-transform: uppercase; color: var(--bone-dim); margin-top: 10px; }

/* ---------- footer ---------- */
.site-footer {
  padding: 40px var(--pad);
  display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 20px;
  border-top: 1px solid var(--bone-line);
}
.site-footer .foot-mono {
  font-family: var(--mono); font-size: 11px; letter-spacing: .08em; text-transform: uppercase; color: var(--bone-dim);
}

/* ---------- list w/ icon ---------- */
.icon-list { list-style: none; display: flex; flex-direction: column; gap: 14px; margin-top: 18px; }
.icon-list li { font-size: 14px; font-weight: 300; display: flex; gap: 12px; align-items: flex-start; line-height: 1.45; color: var(--bone-dim); }
.icon-list li svg { flex-shrink: 0; margin-top: 2px; }
.icon-list.yes li svg { color: var(--emerald-bright); }
.icon-list.no li svg { color: #E06B5C; }

/* ---------- numbered steps ---------- */
.steps { display: flex; flex-direction: column; margin-top: 36px; }
.step {
  display: grid; grid-template-columns: 60px 1fr; gap: 20px;
  padding: 26px 0; border-top: 1px solid var(--bone-line);
}
.step .num { font-family: var(--mono); font-size: 12px; color: var(--emerald-bright); }
.step h4 { font-family: var(--display); font-weight: 800; text-transform: uppercase; font-size: 17px; color: var(--white); margin-bottom: 6px; letter-spacing: -.01em; }
.step p { font-size: 14px; font-weight: 300; color: var(--bone-dim); max-width: 58ch; }

/* ---------- process (secuencia con iconos) ---------- */
.process-grid {
  display: grid; grid-template-columns: repeat(4, 1fr);
  margin-top: 40px; border: 1px solid rgba(30, 156, 116, .2); border-radius: 14px; overflow: hidden;
}
.process-col { padding: 26px 24px; border-left: 1px solid rgba(30, 156, 116, .2); position: relative; }
.process-col:first-child { border-left: 0; }
@media (max-width: 820px) {
  .process-grid { grid-template-columns: 1fr; }
  .process-col { border-left: 0; border-top: 1px solid rgba(30, 156, 116, .2); }
  .process-col:first-child { border-top: 0; }
}
.process-icon-badge {
  width: 48px; height: 48px; border-radius: 12px;
  background: rgba(30, 156, 116, .12); border: 1px solid rgba(30, 156, 116, .3);
  display: flex; align-items: center; justify-content: center;
  color: var(--emerald-bright); margin-bottom: 20px;
}
.process-title {
  font-family: var(--display); font-weight: 900; text-transform: uppercase;
  font-size: 16px; line-height: 1.2; color: var(--white); letter-spacing: -.01em;
  margin-bottom: 12px;
}
.process-col p { font-size: 13px; font-weight: 300; color: var(--bone-dim); line-height: 1.55; }

/* ---------- team ---------- */
.team-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 56px; margin-top: 48px;
}
.team-card { text-align: center; }
.team-photo {
  width: 148px; height: 148px; border-radius: 50%; overflow: hidden;
  margin: 0 auto 22px; border: 2px solid rgba(30, 156, 116, .3);
}
.team-photo img { width: 100%; height: 100%; object-fit: cover; filter: grayscale(.3); }
.team-role {
  font-family: var(--mono); font-size: 11px; letter-spacing: .1em; text-transform: uppercase;
  color: var(--emerald-bright); margin-bottom: 8px;
}
.team-name {
  font-family: var(--display); font-weight: 900; text-transform: uppercase;
  font-size: 24px; color: var(--white); letter-spacing: -.01em;
}
.team-tag {
  font-family: var(--mono); font-size: 11px; letter-spacing: .1em; text-transform: uppercase;
  color: var(--bone-dim); margin-top: 8px; opacity: .7;
}

/* team — full bios (página Quiénes somos) */
.team-card-lg .team-photo { width: 180px; height: 180px; }
.team-card-lg .bio {
  margin: 16px auto 0; font-size: 14px; font-weight: 300; color: var(--bone-dim);
  max-width: 34ch;
}

/* ---------- close / cta section ---------- */
.close-cta { text-align: center; }
.close-cta h2 { font-size: clamp(26px, 4.4vw, 48px); max-width: 20ch; margin: 0 auto; }
.close-cta .lede { margin-left: auto; margin-right: auto; text-align: center; }
.close-cta .btns { display: flex; justify-content: center; gap: 14px; margin-top: 30px; flex-wrap: wrap; }
.close-cta .eyebrow { justify-content: center; }

/* ---------- landing filtro (análisis gratuito) ---------- */
.filter-header { display: flex; justify-content: center; padding: 30px var(--pad) 0; }
.filter-header .wordmark { font-size: 14px; }

.filter-hero { padding-top: clamp(36px, 6vw, 64px); padding-bottom: 0; text-align: center; }
.filter-hero .eyebrow { justify-content: center; }
.filter-hero .kicker {
  display: block; font-family: var(--mono); font-size: 12px; letter-spacing: .14em; text-transform: uppercase;
  color: var(--emerald-bright); margin-bottom: 14px;
}
.filter-hero h1 { font-size: clamp(30px, 5vw, 56px); max-width: 26ch; margin: 0 auto; }
.filter-hero h1 em { font-style: normal; color: var(--emerald-bright); }
.filter-hero .lede { margin: 18px auto 0; text-align: center; max-width: 54ch; }

/* ---------- barra de progreso (página de gracias) ---------- */
.confirm-progress { text-align: center; padding-top: clamp(40px, 6vw, 64px); padding-bottom: 0; }
.progress-bar {
  max-width: 420px; height: 8px; margin: 0 auto;
  background: var(--bone-line); border-radius: 999px; overflow: hidden;
}
.progress-fill { height: 100%; background: var(--emerald-bright); border-radius: 999px; }
.progress-text {
  margin-top: 18px; font-family: var(--sans); font-weight: 300;
  font-size: clamp(16px, 2vw, 20px); color: var(--bone-dim);
}
.progress-text strong { color: var(--white); font-weight: 600; }

/* ---------- video placeholder ---------- */
.video-section { padding-top: clamp(32px, 5vw, 56px); padding-bottom: clamp(20px, 3vw, 32px); }

.video-frame {
  max-width: 780px; margin: 0 auto; aspect-ratio: 16 / 9;
  background: var(--ink); border: 1px solid rgba(30, 156, 116, .25); border-radius: 16px;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 16px; position: relative; overflow: hidden;
}
.video-frame .play-btn {
  width: 72px; height: 72px; border-radius: 50%; background: var(--emerald-bright);
  display: flex; align-items: center; justify-content: center; color: var(--black); flex-shrink: 0;
}
.video-frame .video-note {
  font-family: var(--mono); font-size: 11px; letter-spacing: .08em; text-transform: uppercase; color: var(--bone-dim);
}

/* ---------- trust bullets ---------- */
.trust-bullets {
  display: flex; flex-direction: column; align-items: center; list-style: none;
  gap: 10px; margin: 28px auto 0;
}
.trust-bullets li {
  display: flex; align-items: center; gap: 8px;
  font-family: var(--mono); font-size: 12px; letter-spacing: .04em; text-transform: uppercase;
  color: var(--bone-dim);
}
.trust-bullets svg { color: var(--emerald-bright); flex-shrink: 0; }

/* ---------- urgencia (cupos limitados) ---------- */
.urgency-banner {
  display: flex; align-items: center; justify-content: center; gap: 10px;
  max-width: 480px; margin: 24px auto 0;
  padding: 12px 22px; border: 1px solid rgba(30, 156, 116, .35); border-radius: 999px;
  background: rgba(30, 156, 116, .08);
  font-family: var(--mono); font-size: 12px; letter-spacing: .03em; color: var(--bone-dim);
  text-align: center;
}
.urgency-banner strong { color: var(--emerald-bright); font-weight: 700; }
.urgency-banner span:not(.urgency-dot) { flex: 1; min-width: 0; }
.urgency-dot {
  width: 8px; height: 8px; border-radius: 50%; background: var(--emerald-bright); flex-shrink: 0;
  animation: urgency-pulse 1.6s ease-in-out infinite;
}
@keyframes urgency-pulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(30, 156, 116, .5); }
  50% { box-shadow: 0 0 0 6px rgba(30, 156, 116, 0); }
}
@media (max-width: 520px) {
  .urgency-banner { max-width: calc(100% - 40px); font-size: 11px; padding: 12px 16px; }
}

/* ---------- form (3 pasos) ---------- */
.form-section { max-width: 560px; margin: 0 auto; padding-top: clamp(16px, 3vw, 28px); }

.step-progress {
  display: flex; align-items: center; justify-content: center; gap: 8px; margin-bottom: 32px;
}
.step-progress .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--bone-line); transition: background .2s ease; }
.step-progress .dot.active { background: var(--emerald-bright); }
.step-progress .dot.done { background: var(--emerald); }
.step-progress .step-label {
  font-family: var(--mono); font-size: 11px; letter-spacing: .08em; text-transform: uppercase; color: var(--bone-dim);
  margin-left: 6px;
}

.form-card {
  background: var(--ink); border: 1px solid rgba(30, 156, 116, .22); border-radius: 16px;
  padding: clamp(24px, 4vw, 44px);
  box-shadow: 0 24px 48px -32px rgba(30, 156, 116, .35);
}

.form-step { display: none; flex-direction: column; gap: 18px; }
.form-step.active { display: flex; }

.form-step h3 {
  font-family: var(--display); font-weight: 900; text-transform: uppercase;
  font-size: clamp(18px, 2.6vw, 24px); color: var(--white); margin-bottom: 4px;
}
.form-step .step-sub { font-size: 13px; font-weight: 300; color: var(--bone-dim); margin-top: -12px; margin-bottom: 4px; }

.field label {
  display: block; font-family: var(--mono); font-size: 11px; letter-spacing: .06em; text-transform: uppercase;
  color: var(--bone-dim); margin-bottom: 8px;
}
.field input, .field select {
  width: 100%; background: var(--black); border: 1px solid var(--bone-line); border-radius: 8px;
  padding: 14px 16px; color: var(--white); font-family: var(--sans); font-size: 15px;
  transition: border-color .15s ease; appearance: none;
}
.field select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='none' stroke='%239A9587' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 16px center; padding-right: 40px; cursor: pointer;
}
.field input:focus, .field select:focus { outline: none; border-color: var(--emerald-bright); }
.field.error input, .field.error select { border-color: #E06B5C; }
.field-error-msg { font-family: var(--mono); font-size: 11px; color: #E06B5C; margin-top: 6px; display: none; }
.field.error .field-error-msg { display: block; }
.field-hint { font-family: var(--mono); font-size: 11px; color: var(--bone-dim); margin-top: 8px; line-height: 1.4; }

.field .phone-row { display: flex; gap: 8px; }
.field .phone-row select {
  width: 132px; flex: 0 0 132px;
  padding: 14px 24px 14px 10px; font-size: 13px;
  background-position: right 8px center;
}
.field .phone-row input { width: auto; flex: 1; min-width: 0; }

.form-nav { display: flex; justify-content: space-between; align-items: center; margin-top: 6px; gap: 14px; }
.btn-back {
  font-family: var(--mono); font-size: 11px; letter-spacing: .06em; text-transform: uppercase;
  color: var(--bone-dim); background: none; border: none; cursor: pointer; padding: 8px 0;
}
.btn-back:hover { color: var(--bone); }

button.btn.solid { border: none; cursor: pointer; font-family: var(--mono); }
.btn.solid:disabled { opacity: .5; cursor: not-allowed; }
.btn.full { width: 100%; text-align: center; padding: 16px 24px; }

.form-privacy-note {
  font-family: var(--mono); font-size: 11px; color: var(--bone-dim); text-align: center; margin-top: 14px;
}

.calendly-wrap { min-height: 680px; }
.calendly-loading {
  display: flex; align-items: center; justify-content: center; min-height: 300px;
  font-family: var(--mono); font-size: 12px; letter-spacing: .06em; text-transform: uppercase; color: var(--bone-dim);
}

/* Calendly necesita ~320px de ancho para renderizar el calendario completo —
   en móvil, el padding acumulado de .form-card + la sección lo deja por debajo
   de eso (solo se ve el encabezado). Lo sacamos del padding para que use
   todo el ancho de la pantalla. */
@media (max-width: 640px) {
  .calendly-wrap {
    width: 100vw;
    position: relative;
    left: 50%;
    margin-left: -50vw;
  }
}
