/* ============================================
   walternahuel.com — Design System
   Validado por investigación UX/UI Perplexity
   ============================================ */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap');

/* ============================================
   TOKENS — Heredados del dashboard
   ============================================ */
:root {
  /* Colores base */
  --color-bg-warm:       #F8F7F4;
  --color-bg-white:      #FFFFFF;
  --color-bg-secondary:  #F0EEE8;
  --color-bg-dark:       #1C1C1A;
  --color-border:        #E4E2DC;

  /* Acento principal */
  --color-accent:        #2563EB;
  --color-accent-hover:  #1D4ED8;
  --color-accent-soft:   #EFF6FF;
  --color-accent-border: #BFDBFE;

  /* Acento secundario — ámbar (CTAs sobre fondo oscuro) */
  --color-amber:         #F59E0B;
  --color-amber-hover:   #D97706;

  /* Texto */
  --color-text-primary:   #1C1C1A;
  --color-text-secondary: #6B7060;
  --color-text-inverse:   #F8F7F4;
  --color-text-muted:     #9CA3AF;

  /* Semánticos — solo para estados */
  --color-ok:       #16A34A;
  --color-warning:  #D97706;
  --color-critical: #DC2626;

  /* Tipografía */
  --font: 'Inter', system-ui, -apple-system, sans-serif;

  /* Escala tipográfica editorial */
  --text-hero:       clamp(40px, 6vw, 64px);
  --text-display:    clamp(28px, 4vw, 48px);
  --text-heading:    24px;
  --text-subheading: 18px;
  --text-body-lg:    17px;
  --text-body:       15px;
  --text-caption:    13px;
  --text-label:      11px;

  /* Letter spacing editorial */
  --tracking-hero:    -0.03em;
  --tracking-display: -0.02em;
  --tracking-heading: -0.01em;
  --tracking-label:    0.08em;

  /* Line height */
  --leading-hero:    1.05;
  --leading-heading: 1.2;
  --leading-body:    1.65;

  /* Espaciado de secciones */
  --section-y: clamp(72px, 10vw, 128px);
  --section-x: clamp(24px, 5vw, 64px);

  /* Layout */
  --content-max:  1120px;
  --text-max:     640px;

  /* Border radius */
  --radius-sm:  6px;
  --radius-md:  10px;
  --radius-lg:  14px;
  --radius-xl:  20px;

  /* Sombras */
  --shadow-card:       0 1px 3px rgba(28,28,26,0.06), 0 4px 16px rgba(28,28,26,0.08);
  --shadow-card-hover: 0 4px 12px rgba(28,28,26,0.10), 0 16px 40px rgba(28,28,26,0.12);

  /* Transiciones */
  --transition-base:  150ms ease;
  --transition-hover: 250ms ease;
}

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

html {
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  scroll-behavior: smooth;
}

body {
  font-family: var(--font);
  font-size: var(--text-body);
  color: var(--color-text-primary);
  background: var(--color-bg-warm);
  line-height: var(--leading-body);
}

img, video { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { cursor: pointer; font-family: var(--font); }

/* ============================================
   LAYOUT
   ============================================ */
.container {
  width: 100%;
  max-width: var(--content-max);
  margin: 0 auto;
  padding: 0 var(--section-x);
}

.section {
  padding: var(--section-y) var(--section-x);
  max-width: calc(var(--content-max) + (var(--section-x) * 2));
  margin: 0 auto;
}

/* ============================================
   NAVEGACIÓN
   ============================================ */
.nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(248, 247, 244, 0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 0.5px solid var(--color-border);
  padding: 0 var(--section-x);
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-logo {
  font-size: 15px;
  font-weight: 600;
  color: var(--color-text-primary);
  letter-spacing: -0.3px;
}

.nav-logo span { color: var(--color-accent); }

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

.nav-link {
  font-size: var(--text-caption);
  color: var(--color-text-secondary);
  transition: color var(--transition-base);
}

.nav-link:hover { color: var(--color-text-primary); }

.nav-cta {
  font-size: var(--text-caption);
  font-weight: 500;
  color: var(--color-accent);
  background: var(--color-accent-soft);
  border: 0.5px solid var(--color-accent-border);
  padding: 7px 16px;
  border-radius: var(--radius-sm);
  transition: background var(--transition-base), border-color var(--transition-base);
}

.nav-cta:hover {
  background: #DBEAFE;
  border-color: #93C5FD;
}

/* ============================================
   HERO — FONDO OSCURO (diferenciador deliberado)
   ============================================ */
.hero {
  background: var(--color-bg-dark);
  padding: clamp(72px, 10vw, 120px) var(--section-x) clamp(80px, 11vw, 128px);
  position: relative;
  overflow: hidden;
}

.hero-inner {
  max-width: var(--content-max);
  margin: 0 auto;
  position: relative;
  z-index: 1;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(37, 99, 235, 0.12);
  border: 0.5px solid rgba(37, 99, 235, 0.25);
  color: #93C5FD;
  font-size: var(--text-label);
  font-weight: 500;
  letter-spacing: var(--tracking-label);
  text-transform: uppercase;
  padding: 5px 14px;
  border-radius: 20px;
  margin-bottom: 28px;
}

.hero-badge-dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--color-accent);
  flex-shrink: 0;
}

.hero h1 {
  font-size: var(--text-hero);
  font-weight: 700;
  color: var(--color-text-inverse);
  line-height: var(--leading-hero);
  letter-spacing: var(--tracking-hero);
  max-width: 680px;
  margin-bottom: 20px;
}

.hero h1 span { color: var(--color-accent); }

.hero-sub {
  font-size: var(--text-body-lg);
  color: var(--color-text-muted);
  line-height: var(--leading-body);
  max-width: 520px;
  margin-bottom: 36px;
}

.hero-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  align-items: center;
  margin-bottom: 56px;
}

.hero-stats {
  display: flex;
  gap: 36px;
  flex-wrap: wrap;
  padding-top: 36px;
  border-top: 0.5px solid rgba(255, 255, 255, 0.08);
}

.hero-stat-val {
  font-size: 22px;
  font-weight: 600;
  color: var(--color-text-inverse);
  letter-spacing: -0.02em;
  line-height: 1;
  margin-bottom: 4px;
}

.hero-stat-label {
  font-size: var(--text-label);
  color: #6B7280;
  letter-spacing: 0.02em;
}

/* ============================================
   BOTONES
   ============================================ */
.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 14px;
  font-weight: 500;
  color: #FFFFFF;
  background: var(--color-accent);
  padding: 10px 22px;
  border-radius: var(--radius-sm);
  border: none;
  transition: background var(--transition-hover);
}

.btn-primary:hover { background: var(--color-accent-hover); }

.btn-secondary {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 14px;
  font-weight: 400;
  color: var(--color-text-muted);
  padding: 10px 22px;
  border-radius: var(--radius-sm);
  border: 0.5px solid rgba(255, 255, 255, 0.1);
  background: transparent;
  transition: border-color var(--transition-hover), color var(--transition-hover);
}

.btn-secondary:hover {
  border-color: rgba(255, 255, 255, 0.2);
  color: var(--color-text-inverse);
}

.btn-amber {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 14px;
  font-weight: 500;
  color: var(--color-bg-dark);
  background: var(--color-amber);
  padding: 10px 24px;
  border-radius: var(--radius-sm);
  border: none;
  transition: background var(--transition-hover);
}

.btn-amber:hover { background: var(--color-amber-hover); color: #FFFFFF; }

.btn-ghost {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 14px;
  font-weight: 400;
  color: var(--color-text-muted);
  padding: 10px 24px;
  border-radius: var(--radius-sm);
  border: 0.5px solid rgba(255, 255, 255, 0.1);
  background: transparent;
  transition: border-color var(--transition-hover), color var(--transition-hover);
}

.btn-ghost:hover {
  border-color: rgba(255, 255, 255, 0.2);
  color: var(--color-text-inverse);
}

.btn-outline {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  font-weight: 500;
  color: var(--color-accent);
  background: var(--color-accent-soft);
  border: 0.5px solid var(--color-accent-border);
  padding: 9px 18px;
  border-radius: var(--radius-sm);
  transition: background var(--transition-hover);
}

.btn-outline:hover { background: #DBEAFE; }

.btn-outline-dark {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  font-weight: 500;
  color: #FFFFFF;
  background: var(--color-accent);
  border: 0.5px solid var(--color-accent);
  padding: 9px 18px;
  border-radius: var(--radius-sm);
  transition: background var(--transition-hover);
}

.btn-outline-dark:hover { background: var(--color-accent-hover); }

/* ============================================
   SECTION LABELS
   ============================================ */
.section-label {
  font-size: var(--text-label);
  font-weight: 500;
  letter-spacing: var(--tracking-label);
  text-transform: uppercase;
  color: var(--color-text-secondary);
  margin-bottom: 12px;
}

/* ============================================
   SECCIÓN PROBLEMA — fondo cálido
   ============================================ */
.pain {
  background: var(--color-bg-warm);
  border-top: 0.5px solid var(--color-border);
}

.pain h2, .products h2, .why h2 {
  font-size: var(--text-display);
  font-weight: 700;
  color: var(--color-text-primary);
  letter-spacing: var(--tracking-display);
  line-height: var(--leading-heading);
  max-width: 560px;
  margin-bottom: 14px;
}

.pain h2 span, .products h2 span { color: var(--color-accent); }

.section-sub {
  font-size: var(--text-body);
  color: var(--color-text-secondary);
  line-height: var(--leading-body);
  max-width: 480px;
  margin-bottom: 48px;
}

.pain-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

.pain-card {
  background: var(--color-bg-white);
  border: 0.5px solid var(--color-border);
  border-radius: var(--radius-md);
  padding: 22px;
  transition: box-shadow var(--transition-hover);
}

.pain-card:hover { box-shadow: var(--shadow-card); }

.pain-icon {
  width: 34px;
  height: 34px;
  border-radius: var(--radius-sm);
  background: var(--color-bg-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 14px;
  font-size: 16px;
}

.pain-title {
  font-size: 14px;
  font-weight: 500;
  color: var(--color-text-primary);
  margin-bottom: 6px;
}

.pain-desc {
  font-size: var(--text-caption);
  color: var(--color-text-secondary);
  line-height: var(--leading-body);
}

/* ============================================
   SECCIÓN PRODUCTOS — fondo blanco
   ============================================ */
.products {
  background: var(--color-bg-white);
  border-top: 0.5px solid var(--color-border);
}

.products-header {
  margin-bottom: 40px;
}

.products-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

.product-card {
  background: var(--color-bg-warm);
  border: 0.5px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 24px;
  position: relative;
  transition: box-shadow var(--transition-hover);
}

.product-card:hover { box-shadow: var(--shadow-card-hover); }

.product-card.featured {
  background: var(--color-bg-white);
  border: 1.5px solid var(--color-accent);
}

.featured-badge {
  position: absolute;
  top: -1px;
  right: 20px;
  font-size: 11px;
  font-weight: 500;
  color: #FFFFFF;
  background: var(--color-accent);
  padding: 4px 10px;
  border-radius: 0 0 var(--radius-sm) var(--radius-sm);
}

.product-num {
  font-size: var(--text-label);
  font-weight: 600;
  letter-spacing: var(--tracking-label);
  text-transform: uppercase;
  color: var(--color-text-secondary);
  margin-bottom: 14px;
}

.product-name {
  font-size: 16px;
  font-weight: 600;
  color: var(--color-text-primary);
  letter-spacing: -0.2px;
  margin-bottom: 8px;
}

.product-desc {
  font-size: var(--text-caption);
  color: var(--color-text-secondary);
  line-height: var(--leading-body);
  margin-bottom: 20px;
}

.product-price {
  font-size: 22px;
  font-weight: 600;
  color: var(--color-text-primary);
  letter-spacing: -0.02em;
  line-height: 1;
}

.product-price-sub {
  font-size: 12px;
  color: var(--color-text-secondary);
  font-weight: 400;
}

.product-monthly {
  font-size: var(--text-caption);
  color: var(--color-text-secondary);
  margin-top: 4px;
  margin-bottom: 20px;
}

/* ============================================
   SECCIÓN POR QUÉ YO — fondo secundario
   ============================================ */
.why {
  background: var(--color-bg-secondary);
  border-top: 0.5px solid var(--color-border);
}

.why-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: center;
}

.why-creds {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 28px;
}

.cred-row {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  background: var(--color-bg-white);
  border: 0.5px solid var(--color-border);
  border-radius: var(--radius-md);
  padding: 12px 16px;
}

.cred-icon {
  width: 30px;
  height: 30px;
  border-radius: var(--radius-sm);
  background: var(--color-accent-soft);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  flex-shrink: 0;
  margin-top: 1px;
}

.cred-text {
  font-size: 13px;
  font-weight: 500;
  color: var(--color-text-primary);
  line-height: 1.4;
}

.cred-sub {
  font-size: 12px;
  color: var(--color-text-secondary);
  margin-top: 2px;
}

/* Dashboard preview mockup */
.dashboard-preview {
  background: var(--color-bg-dark);
  border-radius: var(--radius-lg);
  padding: 18px;
  border: 0.5px solid #2A2A28;
}

.db-topbar {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 16px;
}

.db-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
}

.db-label {
  font-size: 11px;
  color: #6B7060;
  margin-left: 8px;
}

.db-metrics {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin-bottom: 12px;
}

.db-metric {
  background: #252523;
  border-radius: var(--radius-sm);
  padding: 10px 12px;
}

.db-metric-label {
  font-size: 10px;
  color: #6B7060;
  margin-bottom: 4px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.db-metric-val {
  font-size: 20px;
  font-weight: 600;
  color: var(--color-text-inverse);
  letter-spacing: -0.02em;
  font-variant-numeric: tabular-nums;
}

.db-metric-val.green { color: #4ADE80; }
.db-metric-val.blue  { color: #60A5FA; }

.db-chart {
  background: #252523;
  border-radius: var(--radius-sm);
  padding: 12px;
}

.db-chart-label {
  font-size: 10px;
  color: #6B7060;
  margin-bottom: 10px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.db-bars {
  display: flex;
  align-items: flex-end;
  gap: 5px;
  height: 52px;
}

.db-bar-item {
  flex: 1;
  border-radius: 3px 3px 0 0;
  background: var(--color-accent);
}

/* ============================================
   SECCIÓN CTA FINAL — fondo oscuro
   ============================================ */
.cta-section {
  background: var(--color-bg-dark);
  border-top: 0.5px solid #2A2A28;
  text-align: center;
}

.cta-section h2 {
  font-size: var(--text-display);
  font-weight: 700;
  color: var(--color-text-inverse);
  letter-spacing: var(--tracking-hero);
  line-height: var(--leading-heading);
  margin-bottom: 14px;
}

.cta-section h2 span { color: var(--color-accent); }

.cta-sub {
  font-size: var(--text-body);
  color: var(--color-text-muted);
  line-height: var(--leading-body);
  max-width: 460px;
  margin: 0 auto 36px;
}

.cta-actions {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
}

/* ============================================
   FOOTER
   ============================================ */
.footer {
  background: var(--color-bg-warm);
  border-top: 0.5px solid var(--color-border);
  padding: 24px var(--section-x);
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
}

.footer-copy {
  font-size: 12px;
  color: var(--color-text-secondary);
}

.footer-links {
  display: flex;
  gap: 20px;
}

.footer-link {
  font-size: 12px;
  color: var(--color-text-secondary);
  transition: color var(--transition-base);
}

.footer-link:hover { color: var(--color-text-primary); }

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 768px) {
  .nav-links { display: none; }

  .pain-grid,
  .products-grid {
    grid-template-columns: 1fr;
  }

  .why-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .hero-stats {
    gap: 24px;
  }
}
