/* ============================================================
   HELIX · PORTFOLIO WEB · 2026
   styles.css — Versión separada y con responsividad mejorada
   ============================================================ */

/* ============================================================
   VARIABLES Y RESET
   ============================================================ */
:root {
  --bg-deep: #050614;
  --bg-mid: #0a0b24;
  --bg-soft: #131432;
  --ink: #ffffff;
  --ink-soft: rgba(255, 255, 255, 0.75);
  --ink-mute: rgba(255, 255, 255, 0.5);
  --ink-faint: rgba(255, 255, 255, 0.15);
  --cyan: #06d6ff;
  --cyan-soft: #67e8f9;
  --violet: #a78bfa;
  --violet-deep: #7c3aed;
  --amber: #fbbf24;
  --glass-bg: rgba(255, 255, 255, 0.04);
  --glass-border: rgba(255, 255, 255, 0.1);

  /* Padding horizontal responsivo unificado */
  --section-padding-x: clamp(20px, 5vw, 80px);
  --section-padding-y: clamp(64px, 9vw, 120px);
  --content-max-width: 1280px;
  --glass-max-width: 1180px;
  --qa-page-edge-safe: max(16px, env(safe-area-inset-left));
}


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

html {
  scroll-behavior: smooth;
  background: var(--bg-deep);
  width: 100%;
  max-width: 100%;
  overflow-x: clip;
  overflow-y: auto;
}

body {
  width: 100%;
  max-width: 100%;
  min-width: 0;
  overflow-x: clip;
  overflow-y: visible;
  background: transparent;
  color: var(--ink);
  font-family: 'Geist', sans-serif;
  font-weight: 400;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* ============================================================
   FONDO ANIMADO Y OVERLAYS
   ============================================================ */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  background:
    radial-gradient(circle at 20% 20%, rgba(6, 214, 255, 0.05), transparent 40%),
    radial-gradient(circle at 80% 80%, rgba(124, 58, 237, 0.05), transparent 40%);
  pointer-events: none;
  z-index: 0;
  animation: bgShift 20s ease-in-out infinite;
}

@keyframes bgShift {
  0%, 100% { transform: translate(0, 0); }
  50% { transform: translate(-30px, -30px); }
}

body::after {
  content: '';
  position: fixed;
  inset: 0;
  opacity: 0.025;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.65' numOctaves='3'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  pointer-events: none;
  z-index: 0;
}

.grid-bg {
  position: fixed;
  inset: 0;
  background-image:
    linear-gradient(rgba(255,255,255,0.02) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.02) 1px, transparent 1px);
  background-size: 60px 60px;
  pointer-events: none;
  z-index: -1;
}

/* ============================================================
   NAVIGATION
   ============================================================ */
nav {
  position: fixed;
  top: 24px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 100;
  background: rgba(5, 6, 20, 0.85);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid var(--glass-border);
  border-radius: 999px;
  padding: 10px 16px;
  display: flex;
  align-items: center;
  gap: 8px;
  box-shadow: 0 10px 40px rgba(0,0,0,0.5);
  animation: navFloat 6s ease-in-out infinite;
  max-width: calc(100vw - 24px);
}

@keyframes navFloat {
  0%, 100% { transform: translateX(-50%) translateY(0); }
  50% { transform: translateX(-50%) translateY(-4px); }
}

nav .brand {
  display: flex;
  align-items: center;
  padding: 0 14px 0 4px;
  gap: 6px;
  flex-shrink: 0;
}
nav .brand .brand-logo {
  height: 22px;
  width: auto;
  display: block;
  filter: drop-shadow(0 0 10px rgba(34, 211, 238, 0.28));
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 4px;
}

nav a {
  color: var(--ink-soft);
  text-decoration: none;
  font-size: 12px;
  font-family: 'Geist Mono', monospace;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 8px 14px;
  border-radius: 999px;
  transition: all 0.3s;
  white-space: nowrap;
}
nav a:hover {
  background: var(--glass-bg);
  color: var(--cyan);
}

/* Botón hamburguesa — oculto por defecto, visible en mobile */
.nav-toggle {
  display: none;
  width: 36px;
  height: 36px;
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 0;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
  flex-shrink: 0;
}
.nav-toggle span {
  display: block;
  width: 18px;
  height: 1.5px;
  background: var(--ink-soft);
  border-radius: 2px;
  transition: all 0.3s;
}
.nav-toggle[aria-expanded="true"] span:nth-child(1) {
  transform: translateY(6.5px) rotate(45deg);
}
.nav-toggle[aria-expanded="true"] span:nth-child(2) {
  opacity: 0;
}
.nav-toggle[aria-expanded="true"] span:nth-child(3) {
  transform: translateY(-6.5px) rotate(-45deg);
}

/* ============================================================
   COMMON SECTION STYLES
   ============================================================ */
section {
  position: relative;
  z-index: 10;
  min-height: 100vh;
  width: 100%;
  max-width: none;
  margin-left: 0;
  margin-right: 0;
  /* QA FINAL: el padding anterior sumaba centrado + padding y achicaba el contenido a ~1120px en desktop.
     La sección debe ocupar todo el viewport; el ancho máximo se aplica solo a sus hijos. */
  padding: var(--section-padding-y) var(--section-padding-x);
  display: flex;
  flex-direction: column;
  justify-content: center;
  overflow: visible;
}

/*
   Contenedor lógico sin tocar el HTML:
   la sección ahora ocupa todo el viewport para que el fondo/glow no se corte,
   pero el contenido conserva un ancho editorial máximo.
*/
section > :not(.glow):not(.scroll-hint) {
  width: 100%;
  max-width: var(--content-max-width);
  margin-left: auto;
  margin-right: auto;
  align-self: center;
}

.glow {
  position: absolute;
  border-radius: 50%;
  filter: blur(100px);
  pointer-events: none;
  z-index: 1;
  max-width: 80vw;
  max-height: 80vw;
}

.label {
  font-family: 'Geist Mono', monospace;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.3em;
  color: var(--ink-mute);
  font-weight: 500;
}

.display {
  font-family: 'Instrument Serif', serif;
  font-weight: 400;
  letter-spacing: -0.02em;
}

/* Scroll animations - reveal */
.reveal {
  opacity: 0;
  transform: translateY(40px);
  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);
}
.reveal-1 { transition-delay: 0.1s; }
.reveal-2 { transition-delay: 0.25s; }
.reveal-3 { transition-delay: 0.4s; }
.reveal-4 { transition-delay: 0.55s; }
.reveal-5 { transition-delay: 0.7s; }
.reveal-6 { transition-delay: 0.85s; }

/* ============================================================
   HERO SECTION
   ============================================================ */
.hero {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  position: relative;
  padding-top: clamp(96px, 14vw, 120px);
}

.hero .glow.cyan {
  width: clamp(300px, 50vw, 600px);
  height: clamp(300px, 50vw, 600px);
  top: -200px;
  right: -200px;
  background: radial-gradient(circle, rgba(6, 214, 255, 0.5), transparent 70%);
  animation: float1 12s ease-in-out infinite;
}

.hero .glow.violet {
  width: clamp(280px, 42vw, 500px);
  height: clamp(280px, 42vw, 500px);
  bottom: -150px;
  left: -100px;
  background: radial-gradient(circle, rgba(124, 58, 237, 0.4), transparent 70%);
  animation: float2 15s ease-in-out infinite;
}

@keyframes float1 {
  0%, 100% { transform: translate(0, 0) scale(1); }
  50% { transform: translate(-50px, 50px) scale(1.1); }
}
@keyframes float2 {
  0%, 100% { transform: translate(0, 0) scale(1); }
  50% { transform: translate(50px, -50px) scale(1.05); }
}

.hero-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  margin-bottom: auto;
  padding: 40px 0 28px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  position: relative;
  z-index: 5;
  gap: 24px;
  flex-wrap: wrap;
}

.hero-brand {
  display: flex;
  align-items: center;
  gap: 18px;
  position: relative;
}
.hero-brand-mark {
  height: clamp(48px, 7vw, 76px);
  width: auto;
  display: block;
  filter: drop-shadow(0 0 24px rgba(34, 211, 238, 0.22));
}
.hero-brand-rule {
  width: 1px;
  height: 56px;
  background: linear-gradient(to bottom, transparent, rgba(34, 211, 238, 0.45), transparent);
}
.hero-brand-text {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.hero-brand-name {
  font-family: 'Geist Mono', monospace;
  font-size: 11px;
  letter-spacing: 0.35em;
  text-transform: uppercase;
  color: var(--ink);
  font-weight: 600;
}
.hero-brand-tag {
  font-family: 'Geist Mono', monospace;
  font-size: 10px;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--ink-mute);
  line-height: 1.5;
}
.hero-brand-tag span {
  color: var(--cyan-soft);
}

.hero-meta {
  text-align: right;
  font-size: 10px;
  color: var(--ink-mute);
  font-family: 'Geist Mono', monospace;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  line-height: 1.8;
}

.hero-content {
  margin-top: 8vh;
  max-width: 1100px;
  position: relative;
  z-index: 5;
}

.hero-eyebrow {
  font-family: 'Geist Mono', monospace;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.4em;
  color: var(--cyan);
  margin-bottom: 40px;
  display: flex;
  align-items: center;
  gap: 14px;
}
.hero-eyebrow::before {
  content: '';
  width: 40px;
  height: 1px;
  background: var(--cyan);
  display: inline-block;
}

.hero-title {
  display: inline-block;
  margin-bottom: 50px;
  position: relative;
  height: clamp(60px, 13vw, 180px);
  max-width: 100%;
}
.hero-title-logo {
  height: 100%;
  width: auto;
  max-width: 100%;
  display: block;
  filter: drop-shadow(0 0 36px rgba(34, 211, 238, 0.32)) drop-shadow(0 0 12px rgba(124, 58, 237, 0.22));
}
.hero-title::after {
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  bottom: -14px;
  height: 2px;
  background: linear-gradient(90deg, var(--cyan), var(--violet), transparent 80%);
  transform: scaleX(0);
  transform-origin: left;
  opacity: 0;
  transition: transform 1.2s cubic-bezier(0.16, 1, 0.3, 1) 0.6s, opacity 0.6s 0.6s;
}
.hero-title.visible::after {
  opacity: 0.7;
  transform: scaleX(1);
}

/* legacy em styles — unused después del swap a logo, mantenidos por seguridad */
.hero-title em {
  font-style: italic;
  font-weight: 400;
  color: var(--cyan-soft);
  display: inline-block;
  position: relative;
}

.hero-subtitle {
  font-size: clamp(16px, 2vw, 28px);
  color: var(--ink-soft);
  line-height: 1.4;
  max-width: 900px;
  font-weight: 300;
  margin-bottom: 60px;
}
.hero-subtitle strong {
  color: var(--cyan-soft);
  font-weight: 500;
}

.hero-stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: clamp(14px, 2vw, 24px);
  margin-top: auto;
  padding-top: 40px;
  border-top: 1px solid var(--ink-faint);
}

.hero-stat .number {
  font-family: 'Instrument Serif', serif;
  font-size: clamp(28px, 4vw, 56px);
  color: var(--cyan);
  line-height: 1;
  margin-bottom: 8px;
  font-style: italic;
}
.hero-stat .number-unit {
  font-size: 0.6em;
  color: var(--ink-mute);
}
.hero-stat .stat-label {
  font-family: 'Geist Mono', monospace;
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: var(--ink-mute);
}

.scroll-hint {
  position: absolute;
  bottom: 30px;
  left: 50%;
  transform: translateX(-50%);
  font-family: 'Geist Mono', monospace;
  font-size: 10px;
  letter-spacing: 0.3em;
  color: var(--ink-mute);
  text-transform: uppercase;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  animation: bounce 2s ease-in-out infinite;
}
.scroll-hint::after {
  content: '';
  width: 1px;
  height: 30px;
  background: linear-gradient(180deg, var(--cyan), transparent);
}

@keyframes bounce {
  0%, 100% { transform: translateX(-50%) translateY(0); }
  50% { transform: translateX(-50%) translateY(10px); }
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.4; }
}

/* ============================================================
   QUIÉNES SOMOS
   ============================================================ */
.who-section .glow.cyan {
  width: clamp(240px, 30vw, 400px);
  height: clamp(240px, 30vw, 400px);
  top: 20%; right: -100px;
  background: radial-gradient(circle, rgba(6, 214, 255, 0.3), transparent 70%);
}
.who-section .glow.violet {
  width: clamp(220px, 28vw, 350px);
  height: clamp(220px, 28vw, 350px);
  bottom: 10%; left: -100px;
  background: radial-gradient(circle, rgba(124, 58, 237, 0.3), transparent 70%);
}

.section-header {
  display: flex;
  align-items: baseline;
  gap: 40px;
  margin-bottom: 80px;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--ink-faint);
  flex-wrap: wrap;
}

.section-num {
  font-family: 'Geist Mono', monospace;
  font-size: 12px;
  color: var(--cyan);
  letter-spacing: 0.2em;
}

.section-title {
  font-family: 'Instrument Serif', serif;
  font-size: clamp(36px, 5vw, 64px);
  letter-spacing: -0.02em;
  color: var(--ink);
}

.section-spacer { flex: 1; }

.section-meta {
  font-family: 'Geist Mono', monospace;
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.25em;
  color: var(--ink-mute);
}

.who-statement {
  font-family: 'Instrument Serif', serif;
  font-size: clamp(28px, 5vw, 72px);
  line-height: 1.15;
  letter-spacing: -0.02em;
  color: var(--ink);
  margin-bottom: 60px;
  max-width: 1200px;
}
.who-statement em {
  font-style: italic;
  color: var(--cyan-soft);
}

.who-paragraph {
  font-size: clamp(15px, 1.6vw, 18px);
  line-height: 1.7;
  color: var(--ink-soft);
  max-width: 900px;
  margin-bottom: 80px;
  font-weight: 300;
}

.pillars {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: clamp(14px, 2vw, 24px);
}

.pillar {
  background: rgba(10, 11, 36, 0.7);
  backdrop-filter: blur(20px) saturate(130%);
  -webkit-backdrop-filter: blur(20px) saturate(130%);
  border: 1px solid var(--glass-border);
  border-radius: 24px;
  padding: clamp(20px, 3vw, 36px) clamp(18px, 2.5vw, 32px);
  position: relative;
  overflow: hidden;
  transition: all 0.5s cubic-bezier(0.16, 1, 0.3, 1);
  cursor: pointer;
  transform-style: preserve-3d;
}
.pillar::before {
  content: '';
  position: absolute;
  top: 0; left: 0;
  width: 60%;
  height: 2px;
  background: linear-gradient(90deg, var(--cyan), transparent);
  transition: width 0.5s;
}
.pillar:hover {
  transform: translateY(-8px) rotateX(2deg);
  border-color: rgba(6, 214, 255, 0.3);
  box-shadow:
    0 20px 60px rgba(6, 214, 255, 0.1),
    0 0 40px rgba(6, 214, 255, 0.05);
}
.pillar:hover::before {
  width: 100%;
}

.pillar-num {
  font-family: 'Geist Mono', monospace;
  font-size: 10px;
  color: var(--cyan);
  letter-spacing: 0.25em;
  margin-bottom: 16px;
}
.pillar-title {
  font-family: 'Instrument Serif', serif;
  font-size: clamp(22px, 2.4vw, 28px);
  line-height: 1.15;
  color: var(--ink);
  margin-bottom: 14px;
  letter-spacing: -0.01em;
}
.pillar-desc {
  font-size: 14px;
  line-height: 1.6;
  color: var(--ink-mute);
  font-weight: 300;
}

/* ============================================================
   CASO ZYPHOR
   ============================================================ */
.zyphor-section {
  padding-top: clamp(80px, 12vw, 120px);
  padding-bottom: clamp(80px, 12vw, 120px);
}

.zyphor-section .glow.cyan {
  width: clamp(400px, 50vw, 700px);
  height: clamp(400px, 50vw, 700px);
  top: -200px; left: -200px;
  background: radial-gradient(circle, rgba(6, 214, 255, 0.4), transparent 70%);
  animation: float1 18s ease-in-out infinite;
}
.zyphor-section .glow.violet {
  width: clamp(300px, 40vw, 500px);
  height: clamp(300px, 40vw, 500px);
  bottom: 0; right: -100px;
  background: radial-gradient(circle, rgba(124, 58, 237, 0.35), transparent 70%);
  animation: float2 22s ease-in-out infinite;
}

.case-header {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 40px;
  align-items: end;
  margin-bottom: 32px;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--ink-faint);
}

.case-num {
  font-family: 'Geist Mono', monospace;
  font-size: 12px;
  color: var(--cyan);
  letter-spacing: 0.2em;
}

.case-name {
  font-family: 'Instrument Serif', serif;
  font-size: clamp(48px, 8vw, 120px);
  letter-spacing: -0.03em;
  color: var(--ink);
  line-height: 1;
}
.case-name .accent {
  color: var(--cyan);
}

.case-logo-lockup {
  display: flex;
  align-items: center;
  gap: 22px;
  flex-wrap: wrap;
  padding: 6px 0;
}
.case-logo-img {
  height: clamp(40px, 6vw, 84px);
  width: auto;
  max-width: 100%;
  display: block;
  filter:
    drop-shadow(0 0 8px rgba(34, 211, 238, 0.65))
    drop-shadow(0 0 28px rgba(34, 211, 238, 0.45))
    drop-shadow(0 0 60px rgba(34, 211, 238, 0.25));
  image-rendering: auto;
  -webkit-backface-visibility: hidden;
  animation: zyphorPulse 4s ease-in-out infinite;
}
@keyframes zyphorPulse {
  0%, 100% {
    filter:
      drop-shadow(0 0 8px rgba(34, 211, 238, 0.65))
      drop-shadow(0 0 28px rgba(34, 211, 238, 0.45))
      drop-shadow(0 0 60px rgba(34, 211, 238, 0.25));
  }
  50% {
    filter:
      drop-shadow(0 0 12px rgba(34, 211, 238, 0.85))
      drop-shadow(0 0 40px rgba(34, 211, 238, 0.55))
      drop-shadow(0 0 80px rgba(34, 211, 238, 0.32));
  }
}
.case-logo-by {
  font-family: 'Geist Mono', monospace;
  font-size: 11px;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--ink-mute);
  padding-left: 22px;
  border-left: 1px solid rgba(34, 211, 238, 0.35);
  line-height: 1.6;
  display: flex;
  flex-direction: column;
}
.case-logo-by::before {
  content: 'PRODUCTO';
  display: block;
  color: var(--cyan-soft);
  font-size: 9px;
  letter-spacing: 0.35em;
  margin-bottom: 4px;
}
.case-logo-by strong {
  color: var(--ink);
  font-weight: 600;
  font-size: 13px;
  letter-spacing: 0.2em;
}

.case-status {
  font-family: 'Geist Mono', monospace;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.25em;
  background: rgba(6, 214, 255, 0.1);
  color: var(--cyan);
  padding: 12px 20px;
  border-radius: 99px;
  border: 1px solid rgba(6, 214, 255, 0.3);
  display: inline-flex;
  align-items: center;
  gap: 8px;
  white-space: nowrap;
}
.case-status::before {
  content: '';
  width: 8px;
  height: 8px;
  background: var(--cyan);
  border-radius: 50%;
  box-shadow: 0 0 10px var(--cyan);
  animation: pulse 2s ease-in-out infinite;
  flex-shrink: 0;
}

.case-meta-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-bottom: 48px;
}

.meta-cell {
  background: rgba(10, 11, 36, 0.7);
  backdrop-filter: blur(20px) saturate(130%);
  -webkit-backdrop-filter: blur(20px) saturate(130%);
  border: 1px solid var(--glass-border);
  border-radius: 16px;
  padding: clamp(16px, 2vw, 20px) clamp(16px, 2vw, 24px);
  transition: all 0.4s;
}
.meta-cell:hover {
  border-color: rgba(6, 214, 255, 0.3);
  transform: translateY(-4px);
}
.meta-cell .meta-label {
  font-family: 'Geist Mono', monospace;
  font-size: 9px;
  text-transform: uppercase;
  letter-spacing: 0.25em;
  color: var(--ink-mute);
  margin-bottom: 10px;
}
.meta-cell .meta-value {
  font-family: 'Geist Mono', monospace;
  font-size: clamp(13px, 1.4vw, 16px);
  color: var(--ink);
  font-weight: 500;
}

/* Mockup con tilt 3D */
.case-mockup {
  background: rgba(10, 11, 36, 0.55);
  backdrop-filter: blur(24px) saturate(130%);
  -webkit-backdrop-filter: blur(24px) saturate(130%);
  border: 1px solid var(--glass-border);
  border-radius: 24px;
  padding: clamp(20px, 3vw, 40px);
  margin-bottom: 48px;
  position: relative;
  overflow: hidden;
  perspective: 1500px;
}
.case-mockup-frame {
  transform-style: preserve-3d;
  transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
  transform: rotateX(0deg) rotateY(0deg);
}
.case-mockup-image {
  width: 100%;
  display: block;
  border-radius: 12px;
  box-shadow:
    0 60px 120px rgba(0,0,0,0.6),
    0 30px 60px rgba(6, 214, 255, 0.1),
    0 0 0 1px var(--ink-faint);
}

.case-body {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  margin-bottom: 80px;
}

.case-block-title {
  font-family: 'Geist Mono', monospace;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.25em;
  color: var(--cyan);
  margin-bottom: 16px;
}

.case-text {
  font-size: clamp(14.5px, 1.4vw, 16px);
  line-height: 1.7;
  color: var(--ink-soft);
  font-weight: 300;
}
.case-text strong {
  color: var(--ink);
  font-weight: 500;
}

/* Capabilities */
.zyphor-capabilities {
  margin-top: 60px;
}

.subsection-title {
  font-family: 'Instrument Serif', serif;
  font-size: clamp(28px, 4vw, 48px);
  letter-spacing: -0.02em;
  color: var(--ink);
  margin-bottom: 16px;
}
.subsection-title em {
  font-style: italic;
  color: var(--cyan-soft);
}

.subsection-desc {
  font-size: clamp(14px, 1.5vw, 16px);
  color: var(--ink-soft);
  margin-bottom: 40px;
  max-width: 800px;
  line-height: 1.6;
}

.agents-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: clamp(10px, 1.5vw, 16px);
  margin-bottom: 80px;
}

.agent-tile {
  background: rgba(10, 11, 36, 0.7);
  backdrop-filter: blur(20px) saturate(130%);
  -webkit-backdrop-filter: blur(20px) saturate(130%);
  border: 1px solid var(--glass-border);
  border-radius: 16px;
  padding: clamp(14px, 2vw, 20px);
  position: relative;
  transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}
.agent-tile:hover {
  background: rgba(6, 214, 255, 0.06);
  border-color: rgba(6, 214, 255, 0.3);
  transform: translateY(-4px);
}
.agent-tile-icon {
  width: 36px;
  height: 36px;
  background: rgba(6, 214, 255, 0.1);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 12px;
  color: var(--cyan);
  font-size: 16px;
}
.agent-tile-name {
  font-size: 13px;
  font-weight: 700;
  color: var(--ink);
  letter-spacing: -0.01em;
  margin-bottom: 4px;
}
.agent-tile-desc {
  font-size: 11px;
  color: var(--ink-mute);
  line-height: 1.5;
}

/* PRO agents */
.pro-section {
  background: rgba(10, 11, 36, 0.55);
  backdrop-filter: blur(24px) saturate(130%);
  -webkit-backdrop-filter: blur(24px) saturate(130%);
  border: 1px solid var(--glass-border);
  border-radius: 32px;
  padding: clamp(24px, 4vw, 48px);
  margin-bottom: 60px;
  position: relative;
  overflow: hidden;
}
.pro-section::before {
  content: 'PRO';
  position: absolute;
  top: 20px;
  right: 30px;
  font-family: 'Instrument Serif', serif;
  font-style: italic;
  font-size: clamp(50px, 8vw, 80px);
  color: rgba(167, 139, 250, 0.08);
  letter-spacing: -0.02em;
}

.pro-header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 32px;
  flex-wrap: wrap;
  gap: 16px;
}

.pro-title {
  font-family: 'Instrument Serif', serif;
  font-size: clamp(28px, 3.4vw, 36px);
  color: var(--ink);
}
.pro-title em {
  font-style: italic;
  color: var(--violet);
}

.pro-subtitle {
  color: var(--ink-mute);
  font-size: clamp(13px, 1.3vw, 14px);
  margin-top: 4px;
}

.pro-price {
  font-family: 'Geist Mono', monospace;
  font-size: clamp(12px, 1.3vw, 14px);
  color: var(--violet);
  background: rgba(167, 139, 250, 0.1);
  padding: 8px 16px;
  border-radius: 99px;
  border: 1px solid rgba(167, 139, 250, 0.3);
  white-space: nowrap;
}

.pro-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(12px, 1.5vw, 16px);
}

.pro-tile {
  background: rgba(10, 11, 36, 0.7);
  backdrop-filter: blur(20px) saturate(130%);
  -webkit-backdrop-filter: blur(20px) saturate(130%);
  border: 1px solid var(--glass-border);
  border-radius: 16px;
  padding: clamp(18px, 2.5vw, 24px);
}
.pro-tile-name {
  font-family: 'Instrument Serif', serif;
  font-size: clamp(18px, 2vw, 22px);
  color: var(--ink);
  margin-bottom: 10px;
  letter-spacing: -0.01em;
}
.pro-tile-desc {
  font-size: 12px;
  color: var(--ink-mute);
  line-height: 1.6;
}

/* Pricing Tiers */
.tiers-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(14px, 2vw, 24px);
  margin-top: 32px;
}

.tier-card {
  background: rgba(10, 11, 36, 0.7);
  backdrop-filter: blur(20px) saturate(130%);
  -webkit-backdrop-filter: blur(20px) saturate(130%);
  border: 1px solid var(--glass-border);
  border-radius: 24px;
  padding: clamp(24px, 3vw, 36px) clamp(20px, 2.5vw, 32px);
  position: relative;
  transition: all 0.4s;
}
.tier-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 20px 60px rgba(0,0,0,0.3);
}
.tier-card.featured {
  background: linear-gradient(135deg, rgba(6, 214, 255, 0.08), rgba(124, 58, 237, 0.04));
  border-color: rgba(6, 214, 255, 0.3);
}
.tier-card.featured::before {
  content: 'Más elegido';
  position: absolute;
  top: -12px;
  left: 50%;
  transform: translateX(-50%);
  font-family: 'Geist Mono', monospace;
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  background: var(--cyan);
  color: var(--bg-deep);
  padding: 4px 14px;
  border-radius: 99px;
  font-weight: 700;
}
.tier-label {
  font-family: 'Geist Mono', monospace;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: var(--cyan);
  margin-bottom: 8px;
}
.tier-price {
  font-family: 'Instrument Serif', serif;
  font-size: clamp(38px, 4.5vw, 48px);
  color: var(--ink);
  margin-bottom: 8px;
  letter-spacing: -0.02em;
}
.tier-price-unit {
  font-size: 14px;
  color: var(--ink-mute);
  font-family: 'Geist', sans-serif;
}
.tier-scope {
  font-size: 14px;
  color: var(--ink-soft);
  line-height: 1.6;
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid var(--ink-faint);
}

/* Support */
.support-section {
  margin-top: 60px;
  background: rgba(10, 11, 36, 0.55);
  backdrop-filter: blur(24px) saturate(130%);
  -webkit-backdrop-filter: blur(24px) saturate(130%);
  border: 1px solid var(--glass-border);
  border-radius: 32px;
  padding: clamp(24px, 4vw, 48px);
  position: relative;
  overflow: hidden;
}

.support-header {
  margin-bottom: 32px;
}
.support-title {
  margin-bottom: 8px;
}
.support-subtitle {
  color: var(--ink-mute);
  font-size: clamp(14px, 1.4vw, 15px);
}

.support-formula {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(14px, 2vw, 24px);
  margin-bottom: 32px;
}

.formula-cell {
  background: rgba(10, 11, 36, 0.7);
  backdrop-filter: blur(20px) saturate(130%);
  -webkit-backdrop-filter: blur(20px) saturate(130%);
  border: 1px solid var(--glass-border);
  border-radius: 16px;
  padding: clamp(18px, 2.5vw, 24px);
  text-align: center;
}
.formula-cell .formula-label {
  font-family: 'Geist Mono', monospace;
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: var(--ink-mute);
  margin-bottom: 12px;
}
.formula-cell .formula-value {
  font-family: 'Instrument Serif', serif;
  font-size: clamp(28px, 3.4vw, 36px);
  color: var(--ink);
  letter-spacing: -0.02em;
}
.formula-cell .formula-value em { color: var(--cyan); font-style: italic; }

.scenarios {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: clamp(12px, 1.5vw, 16px);
}

.scenario {
  background: rgba(10, 11, 36, 0.7);
  backdrop-filter: blur(20px) saturate(130%);
  -webkit-backdrop-filter: blur(20px) saturate(130%);
  border: 1px solid var(--glass-border);
  border-radius: 16px;
  padding: clamp(18px, 2.5vw, 24px);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
}
.scenario-name {
  font-size: 13px;
  color: var(--ink-soft);
  line-height: 1.5;
  min-width: 0;
}
.scenario-name strong {
  display: block;
  color: var(--ink);
  font-weight: 700;
  margin-bottom: 4px;
}
.scenario-price {
  font-family: 'Instrument Serif', serif;
  font-style: italic;
  font-size: clamp(22px, 2.5vw, 28px);
  color: var(--cyan);
  white-space: nowrap;
  flex-shrink: 0;
}

/* Tags */
.stack-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 20px;
}

.tag {
  font-family: 'Geist Mono', monospace;
  font-size: 11px;
  padding: 6px 12px;
  background: rgba(255,255,255,0.04);
  border: 1px solid var(--glass-border);
  border-radius: 99px;
  color: var(--ink-soft);
  letter-spacing: 0.02em;
  transition: all 0.3s;
}
.tag:hover {
  background: rgba(6, 214, 255, 0.1);
  border-color: rgba(6, 214, 255, 0.3);
  color: var(--cyan);
}

/* ============================================================
   OTROS CASOS
   ============================================================ */
.cases-section .glow.violet {
  width: clamp(300px, 40vw, 500px);
  height: clamp(300px, 40vw, 500px);
  top: 20%; right: -100px;
  background: radial-gradient(circle, rgba(124, 58, 237, 0.3), transparent 70%);
}
.cases-section .glow.cyan {
  width: clamp(240px, 32vw, 400px);
  height: clamp(240px, 32vw, 400px);
  bottom: 20%; left: -100px;
  background: radial-gradient(circle, rgba(6, 214, 255, 0.3), transparent 70%);
}

.twin-cases {
  display: flex;
  flex-direction: column;
  gap: 40px;
}

.twin-case {
  background: rgba(10, 11, 36, 0.55);
  backdrop-filter: blur(24px) saturate(130%);
  -webkit-backdrop-filter: blur(24px) saturate(130%);
  border: 1px solid var(--glass-border);
  border-radius: 32px;
  padding: clamp(24px, 4vw, 48px);
  position: relative;
  overflow: hidden;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(24px, 3.5vw, 48px);
  align-items: stretch;
  transition: all 0.5s;
}
.twin-case::before {
  content: '';
  position: absolute;
  top: 0; left: 0;
  height: 2px;
  width: 30%;
  background: linear-gradient(90deg, var(--cyan), transparent);
  transition: width 0.6s;
}
.twin-case:hover::before {
  width: 80%;
}
.twin-case:hover {
  border-color: rgba(6, 214, 255, 0.25);
}

.twin-info {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.twin-num {
  font-family: 'Geist Mono', monospace;
  font-size: 11px;
  color: var(--cyan);
  letter-spacing: 0.25em;
  margin-bottom: 16px;
}

.twin-name {
  font-family: 'Instrument Serif', serif;
  font-size: clamp(34px, 5vw, 64px);
  line-height: 1;
  letter-spacing: -0.02em;
  color: var(--ink);
  margin-bottom: 16px;
}

.twin-tagline {
  font-size: 13px;
  color: var(--cyan-soft);
  font-family: 'Geist Mono', monospace;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  margin-bottom: 24px;
}

.twin-desc {
  font-size: clamp(14px, 1.4vw, 15px);
  line-height: 1.65;
  color: var(--ink-soft);
  font-weight: 300;
  margin-bottom: auto;
}
.twin-desc strong { color: var(--ink); font-weight: 500; }

.twin-stack {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 24px;
}

.twin-visual {
  background: rgba(0,0,0,0.3);
  border-radius: 20px;
  overflow: hidden;
  position: relative;
  border: 1px solid var(--glass-border);
  min-height: 280px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.twin-visual img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top left;
  transition: transform 0.6s;
}
.twin-case:hover .twin-visual img {
  transform: scale(1.03);
}

.anon-mockup {
  width: 100%;
  height: 100%;
  background:
    radial-gradient(circle at 30% 30%, rgba(6, 214, 255, 0.15), transparent 50%),
    radial-gradient(circle at 70% 70%, rgba(124, 58, 237, 0.15), transparent 50%),
    rgba(0,0,0,0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  padding: 24px;
}
.anon-mockup::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255,255,255,0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.05) 1px, transparent 1px);
  background-size: 40px 40px;
}
.anon-content {
  position: relative;
  text-align: center;
  z-index: 2;
}
.anon-content .anon-icon {
  font-family: 'Instrument Serif', serif;
  font-size: clamp(56px, 7vw, 80px);
  margin-bottom: 24px;
  color: var(--cyan);
  font-style: italic;
}
.anon-content .anon-label {
  font-family: 'Geist Mono', monospace;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.3em;
  color: var(--ink-mute);
  line-height: 1.8;
}
.anon-content .anon-label strong {
  color: var(--cyan-soft);
  display: block;
  margin-bottom: 8px;
  font-weight: 600;
}

/* ============================================================
   CIERRE / CONTACTO
   ============================================================ */
.close-section {
  min-height: 100vh;
  padding-top: clamp(80px, 12vw, 100px);
  padding-bottom: 80px;
  display: flex;
  flex-direction: column;
}

.close-section .glow.cyan {
  width: clamp(400px, 55vw, 800px);
  height: clamp(400px, 55vw, 800px);
  top: 10%; right: -200px;
  background: radial-gradient(circle, rgba(6, 214, 255, 0.4), transparent 70%);
  animation: float1 16s ease-in-out infinite;
}
.close-section .glow.violet {
  width: clamp(320px, 45vw, 600px);
  height: clamp(320px, 45vw, 600px);
  bottom: -150px; left: -200px;
  background: radial-gradient(circle, rgba(124, 58, 237, 0.4), transparent 70%);
  animation: float2 20s ease-in-out infinite;
}

.close-hero {
  margin-top: auto;
  margin-bottom: 60px;
  max-width: 1200px;
}

.close-pre {
  font-family: 'Geist Mono', monospace;
  font-size: clamp(11px, 1.2vw, 12px);
  color: var(--cyan);
  text-transform: uppercase;
  letter-spacing: 0.4em;
  margin-bottom: 40px;
}

.close-title {
  font-family: 'Instrument Serif', serif;
  font-size: clamp(54px, 11vw, 180px);
  line-height: 0.9;
  letter-spacing: -0.04em;
  color: var(--ink);
  margin-bottom: 40px;
}
.close-title em {
  font-style: italic;
  color: var(--cyan-soft);
}

.close-sub {
  font-size: clamp(16px, 1.8vw, 24px);
  line-height: 1.5;
  color: var(--ink-soft);
  max-width: 800px;
  font-weight: 300;
}

.contact-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(12px, 1.6vw, 20px);
  margin-bottom: 60px;
}

.contact-card {
  background: rgba(10, 11, 36, 0.7);
  backdrop-filter: blur(20px) saturate(130%);
  -webkit-backdrop-filter: blur(20px) saturate(130%);
  border: 1px solid var(--glass-border);
  border-radius: 24px;
  padding: clamp(20px, 3vw, 32px);
  transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  cursor: pointer;
  position: relative;
  overflow: hidden;
}
.contact-card::before {
  content: '';
  position: absolute;
  top: 0; left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(6, 214, 255, 0.05), transparent);
  transition: left 0.6s;
}
.contact-card:hover {
  transform: translateY(-8px);
  border-color: rgba(6, 214, 255, 0.3);
  box-shadow: 0 20px 60px rgba(6, 214, 255, 0.1);
}
.contact-card:hover::before {
  left: 100%;
}

.contact-label {
  font-family: 'Geist Mono', monospace;
  font-size: 10px;
  color: var(--ink-mute);
  text-transform: uppercase;
  letter-spacing: 0.3em;
  margin-bottom: 12px;
}

.contact-value {
  font-family: 'Geist Mono', monospace;
  font-size: clamp(15px, 1.6vw, 18px);
  color: var(--ink);
  font-weight: 500;
  word-break: break-word;
}

.close-footer {
  padding-top: 24px;
  border-top: 1px solid var(--ink-faint);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

.close-footer-left {
  font-family: 'Geist Mono', monospace;
  font-size: 11px;
  color: var(--ink-mute);
  letter-spacing: 0.2em;
  text-transform: uppercase;
}

.close-footer-right {
  font-family: 'Instrument Serif', serif;
  font-style: italic;
  font-size: 16px;
  color: var(--ink-soft);
}


/* ============================================================
   QA RESPONSIVE PATCH · GLASS / TRANSPARENCY WIDTH
   ============================================================
   Evita que las superficies transparentes se estiren sin control,
   pero sin recortar el glow ni el fondo 3D del hero.
   ============================================================ */
.pillars,
.case-card,
.twin-case,
.pro-section,
.support-section,
.contact-grid,
.close-hero,
.hero-stats,
.case-meta-row,
.agents-grid,
.pro-grid,
.tiers-grid,
.support-formula,
.scenarios {
  width: 100%;
  max-width: min(var(--glass-max-width), 100%);
  margin-left: auto;
  margin-right: auto;
}

.hero-content,
.who-statement,
.who-paragraph,
.section-header,
.case-header,
.subsection-title,
.subsection-desc,
.close-footer {
  width: 100%;
  max-width: var(--content-max-width);
  margin-left: auto;
  margin-right: auto;
}

.hero-content {
  align-self: stretch;
}

/* Forzar wrap real en textos que antes podían empujar el viewport en mobile. */
.hero-brand-tag,
.hero-meta,
.hero-eyebrow,
.section-meta,
.case-status,
.contact-value,
.tag,
nav a {
  overflow-wrap: anywhere;
}

@media (min-width: 1281px) {
  .hero .glow.cyan { right: -200px; }
  .hero .glow.violet { left: -160px; }
}

/* ============================================================
   DNA 3D BACKGROUND
   ============================================================ */
#dna-canvas {
  position: fixed;
  inset: 0;
  display: block;
  width: 100% !important;
  height: 100% !important;
  min-width: 0;
  min-height: 0;
  max-width: 100% !important;
  pointer-events: none;
  z-index: 1;
  opacity: 0.5;
}

@media (prefers-reduced-motion: reduce) {
  #dna-canvas { opacity: 0.4; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* Garantizar que imágenes nunca rompan el layout */
img {
  max-width: 100%;
  height: auto;
}

/* ============================================================
   ============================================================
   RESPONSIVE BREAKPOINTS
   ============================================================
   Estrategia: mobile first NO, pero con breakpoints granulares
   que cubren cada tamaño de pantalla típico.
   ============================================================
   ============================================================ */

/* ============================================================
   DESKTOP MEDIANO · 1200px y abajo
   Ajustes finos antes de bajar a tablet
   ============================================================ */
@media (max-width: 1200px) {
  .case-header {
    gap: 24px;
  }
}

/* ============================================================
   TABLET HORIZONTAL · 1024px y abajo
   ============================================================ */
@media (max-width: 1024px) {
  .pillars { grid-template-columns: repeat(2, 1fr); }
  .case-meta-row { grid-template-columns: repeat(2, 1fr); }
  .case-body { grid-template-columns: 1fr; gap: 32px; }
  .agents-grid { grid-template-columns: repeat(3, 1fr); }
  .pro-grid { grid-template-columns: repeat(2, 1fr); }
  .twin-case { grid-template-columns: 1fr; }
  .tiers-grid { grid-template-columns: 1fr; gap: 16px; }
  .support-formula { grid-template-columns: 1fr; gap: 16px; }
  .scenarios { grid-template-columns: 1fr; }

  .case-header {
    grid-template-columns: 1fr;
    gap: 16px;
    align-items: start;
  }

  /* En tablet/mobile NO mostramos hover-only effects pesados */
  .pillar:hover,
  .meta-cell:hover,
  .tier-card:hover,
  .contact-card:hover {
    transform: none;
  }

  /* Nav: activar menú hamburguesa */
  nav {
    top: 12px;
    padding: 8px 12px;
    border-radius: 999px;
    animation: none;
    transform: translateX(-50%);
    background: rgba(5, 6, 20, 0.92);
  }
  .nav-toggle {
    display: flex;
  }
  .nav-links {
    position: absolute;
    top: calc(100% + 8px);
    left: 0;
    right: 0;
    flex-direction: column;
    gap: 4px;
    background: rgba(5, 6, 20, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    border-radius: 16px;
    padding: 12px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px);
    transition: opacity 0.25s, transform 0.25s, visibility 0s 0.25s;
  }
  .nav-links.open {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    transition: opacity 0.25s, transform 0.25s;
  }
  nav a {
    padding: 12px 16px;
    text-align: center;
    font-size: 13px;
    width: 100%;
  }

  /* Mockup tilt: desactivar perspective en touch */
  .case-mockup { perspective: none; }
  .case-mockup-frame { transform: none !important; transition: none; }
}

/* ============================================================
   TABLET VERTICAL · 900px y abajo
   Ajustes intermedios para iPad portrait y similares
   ============================================================ */
@media (max-width: 900px) {
  .pro-grid { grid-template-columns: repeat(2, 1fr); }
  .agents-grid { grid-template-columns: repeat(3, 1fr); }
  .contact-grid { grid-template-columns: repeat(3, 1fr); }
  .hero-stats { grid-template-columns: repeat(4, 1fr); }

  /* En tablets verticales el scroll-hint puede tocar los stats */
  .scroll-hint { display: none; }
}

/* ============================================================
   MOBILE GRANDE · 720px y abajo
   ============================================================ */
@media (max-width: 720px) {
  html { font-size: 15px; }
  :root { --glass-max-width: 100%; }

  section { min-height: auto; }
  .hero { padding-top: clamp(96px, 18vw, 120px); min-height: 100vh; }

  .hero-top {
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
  }
  .hero-meta { text-align: left; }

  .hero-stats {
    grid-template-columns: repeat(2, 1fr);
    gap: 18px;
  }

  /* Section headers */
  .section-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
  }
  .section-spacer { display: none; }

  /* Case */
  .case-meta-row { grid-template-columns: repeat(2, 1fr); gap: 12px; }
  .agents-grid { grid-template-columns: repeat(2, 1fr); gap: 12px; }
  .pro-grid { grid-template-columns: 1fr; gap: 12px; }
  .scenarios { grid-template-columns: 1fr; gap: 12px; }

  /* Scenario: que el precio no se vea apretado */
  .scenario {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
  }

  .pro-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
  }

  /* Contact */
  .contact-grid { grid-template-columns: 1fr; gap: 12px; }

  /* Footer */
  .close-footer {
    flex-direction: column;
    gap: 8px;
    align-items: flex-start;
  }

  /* Twin cases — los visuales se ven mejor con altura adaptada */
  .twin-visual { min-height: 220px; }

  /* DNA canvas más sutil */
  #dna-canvas { opacity: 0.35; }

  /* Desactivar animaciones costosas en móvil */
  .glow { animation: none; }

  /* Ocultar scroll hint en mobile — se solapa con los stats */
  .scroll-hint { display: none; }

  /* Hero brand layout */
  .hero-brand {
    flex-wrap: wrap;
    gap: 12px;
  }
  .hero-brand-rule { display: none; }
}

/* ============================================================
   MOBILE PEQUEÑO · 480px y abajo
   ============================================================ */
@media (max-width: 480px) {
  .hero-eyebrow {
    font-size: 11px;
    margin-bottom: 28px;
  }
  .hero-eyebrow::before { width: 24px; }

  .hero-stats { gap: 14px; }
  .hero-content { margin-top: 5vh; }
  .hero-title { height: clamp(54px, 21vw, 96px); margin-bottom: 36px; }
  .hero-stat .stat-label { font-size: 9px; }

  .pillars { grid-template-columns: 1fr; gap: 14px; }

  /* Nav: aún más compacto */
  nav {
    width: calc(100vw - 16px);
    padding: 6px 10px;
  }
  nav .brand .brand-logo { height: 18px; }

  /* Case status: que no rompa */
  .case-status {
    font-size: 10px;
    padding: 10px 14px;
    letter-spacing: 0.2em;
  }

  /* Pricing tiers: padding más justo */
  .tier-card { padding: 22px 18px; }

  /* Cards y secciones más respiro */
  .pro-section,
  .support-section { border-radius: 24px; }
  .twin-case { border-radius: 24px; }

  /* Tags: leve reducción */
  .tag { font-size: 10px; padding: 5px 10px; }
}

/* ============================================================
   MOBILE MUY PEQUEÑO · 380px y abajo
   ============================================================ */
@media (max-width: 380px) {
  :root {
    --section-padding-x: 16px;
  }

  .hero-stats { grid-template-columns: 1fr 1fr; gap: 12px; }
  .agents-grid { grid-template-columns: 1fr 1fr; gap: 10px; }

  .case-meta-row { grid-template-columns: 1fr; gap: 10px; }

  .pro-section::before { font-size: 44px; right: 18px; }
}

/* ============================================================
   LANDSCAPE MÓVIL (orientación horizontal en teléfonos)
   El min-height: 100vh en hero rompe en landscape — corregimos
   ============================================================ */
@media (max-height: 500px) and (orientation: landscape) {
  .hero,
  .close-section {
    min-height: auto;
    padding-top: 80px;
    padding-bottom: 60px;
  }
  section {
    min-height: auto;
  }
  .scroll-hint { display: none; }
}

/* ============================================================
   PRINT — por si alguien quiere imprimir
   ============================================================ */
@media print {
  nav, .scroll-hint, #dna-canvas, .grid-bg, .glow,
  body::before, body::after { display: none !important; }
  body {
    background: white !important;
    color: black !important;
  }
  section { page-break-inside: avoid; min-height: auto; }
}

/* QA-FINAL-2026-05-23: sección full-width, contenido max-width, canvas sin corte lateral. */


/* ============================================================
   QA PATCH REAL · 2026-05-23 · SINGLE SCROLLBAR FIX
   ============================================================
   Este bloque corrige el último archivo enviado, no el ZIP original.
   Causa corregida: el canvas usaba 100dvw/100dvh + min-width:100vw,
   lo que puede empujar el viewport cuando aparece la barra nativa del navegador.
   Además dejamos solo al documento como scroller vertical real.
   ============================================================ */
html {
  width: 100%;
  max-width: 100%;
  overflow-x: clip !important;
  overflow-y: auto !important;
}

body {
  width: 100%;
  max-width: 100%;
  min-width: 0;
  overflow-x: clip !important;
  overflow-y: visible !important;
}

#dna-canvas {
  width: 100% !important;
  height: 100% !important;
  min-width: 0 !important;
  min-height: 0 !important;
  max-width: 100% !important;
  max-height: 100% !important;
}

section {
  max-width: none !important;
  overflow: visible !important;
}

/* ============================================================
   QA CONTACT PATCH · SOLO WHATSAPP CENTRADO + ÍCONO FONT AWESOME
   ============================================================ */
.contact-grid {
  grid-template-columns: minmax(280px, 520px) !important;
  justify-content: center;
  justify-items: stretch;
  max-width: 620px !important;
  margin-left: auto;
  margin-right: auto;
}

.contact-grid .contact-card:not(:first-child) {
  display: none !important;
}

.contact-grid .contact-card:first-child {
  display: grid;
  grid-template-columns: auto 1fr;
  grid-template-rows: auto auto;
  column-gap: 22px;
  row-gap: 6px;
  align-items: center;
  min-height: 132px;
  cursor: default;
}

.contact-grid .contact-card:first-child::after {
  content: "\f232";
  font-family: "Font Awesome 6 Brands";
  font-weight: 400;
  grid-column: 1;
  grid-row: 1 / 3;
  color: var(--cyan);
  font-size: clamp(34px, 4vw, 52px);
  line-height: 1;
  filter: drop-shadow(0 0 18px rgba(6, 214, 255, 0.35));
  justify-self: center;
}

.contact-grid .contact-card:first-child .contact-label,
.contact-grid .contact-card:first-child .contact-value {
  grid-column: 2;
  position: relative;
  z-index: 2;
}

.contact-grid .contact-card:first-child .contact-label {
  margin-bottom: 0;
}

.contact-grid .contact-card:first-child .contact-value {
  font-size: clamp(17px, 1.8vw, 22px);
}

@media (max-width: 720px) {
  .contact-grid {
    grid-template-columns: minmax(0, 1fr) !important;
    max-width: 100% !important;
  }

  .contact-grid .contact-card:first-child {
    min-height: 116px;
    column-gap: 16px;
  }
}

@media (max-width: 420px) {
  .contact-grid .contact-card:first-child {
    grid-template-columns: 1fr;
    text-align: center;
    justify-items: center;
    row-gap: 10px;
  }

  .contact-grid .contact-card:first-child::after {
    grid-column: 1;
    grid-row: 1;
  }

  .contact-grid .contact-card:first-child .contact-label,
  .contact-grid .contact-card:first-child .contact-value {
    grid-column: 1;
  }
}

/* QA-CONTACT-FINAL-2026-05-23: contacto reducido a WhatsApp centrado con ícono Font Awesome. */
