:root {
  --bg: #f7f8fa;
  --surface: #ffffff;
  --text: #1a1d24;
  --muted: #5b6472;
  --border: #e6e9ef;
  --brand: #2563eb;
  --brand-dark: #1d4ed8;
  --radius: 12px;
  --shadow: 0 1px 2px rgba(16, 24, 40, 0.04), 0 8px 24px rgba(16, 24, 40, 0.06);
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; }

html, body { height: 100%; }

html { scroll-behavior: smooth; }

/* Compensa el header sticky al saltar a una sección */
section[id] { scroll-margin-top: 84px; }

body {
  margin: 0;
  font-family: var(--font);
  color: var(--text);
  background: var(--bg);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

.container {
  width: 100%;
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 24px;
}

/* Header */
.site-header {
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 10;
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 68px;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--text);
}
.brand-mark {
  width: 22px;
  height: 22px;
  border-radius: 6px;
  background: linear-gradient(135deg, var(--brand), #60a5fa);
}
.brand-name {
  font-size: 1.15rem;
  font-weight: 500;
  letter-spacing: -0.01em;
}
.brand-name strong { font-weight: 700; color: var(--brand); }
.brand-name.small { font-size: 1rem; }

.nav {
  display: flex;
  align-items: center;
  gap: 28px;
}
.nav a {
  text-decoration: none;
  color: var(--muted);
  font-size: 0.95rem;
  transition: color 0.15s ease;
}
.nav a:hover { color: var(--text); }

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 20px;
  border-radius: var(--radius);
  font-size: 0.95rem;
  font-weight: 500;
  text-decoration: none;
  cursor: pointer;
  transition: all 0.15s ease;
  border: 1px solid transparent;
}
.btn-primary { background: var(--brand); color: #fff; }
.btn-primary:hover { background: var(--brand-dark); }
.btn-outline { background: transparent; color: var(--brand); border-color: var(--brand); }
.btn-outline:hover { background: rgba(37, 99, 235, 0.06); }
.btn-ghost { color: var(--text); padding: 8px 16px; }
.btn-ghost:hover { background: var(--bg); }

/* Hero */
.hero {
  display: flex;
  align-items: center;
  text-align: center;
  min-height: min(72vh, 620px);
}
.hero-inner {
  padding: 80px 24px;
  max-width: 720px;
}
.eyebrow {
  color: var(--brand);
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  margin: 0 0 16px;
}
.hero h1 {
  font-size: clamp(2rem, 5vw, 3.1rem);
  line-height: 1.15;
  letter-spacing: -0.02em;
  margin: 0 0 20px;
  font-weight: 700;
}
.lead {
  font-size: 1.15rem;
  color: var(--muted);
  margin: 0 auto 36px;
  max-width: 560px;
}

.hero-actions {
  display: flex;
  gap: 14px;
  justify-content: center;
  flex-wrap: wrap;
}

/* Secciones de contenido */
.section {
  padding: 72px 0;
  border-top: 1px solid var(--border);
}
.section-alt { background: var(--surface); }
.section h2 {
  font-size: clamp(1.6rem, 3.5vw, 2.1rem);
  letter-spacing: -0.02em;
  margin: 0 0 12px;
  font-weight: 700;
}
.section-lead {
  color: var(--muted);
  font-size: 1.05rem;
  margin: 0 0 36px;
  max-width: 560px;
}

/* Grid de tarjetas */
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 20px;
}
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.section-alt .card { background: var(--bg); }
.card:hover { transform: translateY(-2px); box-shadow: var(--shadow); }
.card h3 { margin: 0 0 8px; font-size: 1.1rem; font-weight: 600; }
.card p { margin: 0; color: var(--muted); font-size: 0.95rem; }
.tag {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--brand);
  background: rgba(37, 99, 235, 0.08);
  padding: 3px 10px;
  border-radius: 999px;
  margin-bottom: 12px;
}

/* Footer */
.site-footer {
  background: var(--surface);
  border-top: 1px solid var(--border);
}
.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  height: 72px;
  flex-wrap: wrap;
}
.copyright { color: var(--muted); font-size: 0.85rem; margin: 0; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .card { transition: none; }
}

/* Responsive */
@media (max-width: 640px) {
  .nav { gap: 18px; }
  .nav a { font-size: 0.9rem; }
  .hero-inner { padding: 56px 20px; }
  .section { padding: 56px 0; }
  .footer-inner { justify-content: center; text-align: center; }
}
