/* style.css — Estilo inspirado en Frankfurt, corregido para desborde en stats-section y centrado en hero-content */

/* Cambios: Agrego focus styles, más padding mobile, max-width imgs, ajusto stats, centro hero-content */

:root {
  --primary: #6D2463;
  --primary-2: #A84FA3;
  --text: #222222;
  --muted: #666666;
  --bg: #FFFFFF;
  --soft: #F5F5F7;
  --glass: rgba(255,255,255,0.06);
  --shadow: 0 10px 30px rgba(0,0,0,0.08);
  --maxWidth: 1200px;
  --space: 24px;
  --font: "Inter", "Helvetica Neue", Arial, sans-serif;
}

* {
  box-sizing: border-box;
}

html, body {
  height: 100%;
  margin: 0;
  overflow-x: hidden; /* Previene desborde horizontal global */
}

body {
  font-family: var(--font);
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Layout helpers */
.wrap {
  max-width: var(--maxWidth);
  margin: 0 auto;
  padding: 0 20px;
  width: 100%;
  overflow-x: hidden;
}

.section {
  padding: 80px 0;
  overflow-x: hidden;
}

.section.alt {
  background: var(--primary);
  color: var(--soft);
}

.center {
  text-align: center;
}

.lead {
  color: var(--soft);
  font-size: clamp(1rem, 2.5vw, 1.05rem);
  max-width: 780px;
  margin: 0 auto 1.2rem;
  overflow-wrap: break-word;
}

/* Header */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  background: rgba(255,255,255,0.96);
  backdrop-filter: blur(6px);
  border-bottom: 1px solid #eee;
  z-index: 1200;
}

.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 20px;
}

.brand, .brand-logo {
  display: flex;
  align-items: center;
  gap: 10px;
}

.brand-logo img {
  height: 50px;
  max-width: 100%;
}

.main-nav ul {
  display: flex;
  gap: 18px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.main-nav a {
  text-decoration: none;
  color: var(--muted);
  font-weight: 600;
  font-size: 0.95rem;
  padding: 6px 4px;
  border-bottom: 2px solid transparent;
  transition: color 0.18s ease, border-color 0.18s ease;
}

.main-nav a:hover {
  color: var(--primary);
  border-color: var(--primary);
}

.menu-toggle {
  display: none;
  background: none;
  border: 0;
  font-size: 1.2rem;
  cursor: pointer;
  color: var(--muted);
}

.nav-overlay {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0,0,0,0.5);
  z-index: 1199;
}

/* Hero */
.hero {
  position: relative;
  min-height: 88vh;
  display: flex;
  align-items: center;
  color: #fff;
  padding-top: 80px;
  overflow-x: hidden;
}

.hero-media {
  position: absolute;
  inset: 0;
  overflow: hidden;
}

.hero-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.hero-gradient {
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, var(--primary), var(--primary-2));
  opacity: 0.95;
}

.hero-content {
  position: relative;
  display: flex;
  justify-content: center; /* Centra horizontalmente */
  align-items: center; /* Centra verticalmente */
  gap: 32px;
  padding: 48px 10px;
  max-width: var(--maxWidth); /* Respeta el ancho máximo */
  width: 100%; /* Asegura que no desborde */
  margin: 0 auto; /* Centra el contenedor */
}

.hero-left {
  flex: 1;
  max-width: 720px;
}

.hero-title {
  font-size: clamp(2rem, 5vw, 3rem);
  line-height: 1.02;
  margin: 0 0 10px;
  font-weight: 800;
  overflow-wrap: break-word;
}

.hero-sub {
  font-size: clamp(0.95rem, 2vw, 1.05rem);
  color: rgba(255,255,255,0.95);
  margin-bottom: 10px;
}

.countdown {
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 18px 0;
  flex-wrap: wrap;
}

.big-count {
  font-weight: 800;
  font-size: clamp(1.2rem, 3vw, 1.3rem);
}

.count-sub {
  font-size: clamp(0.9rem, 2vw, 0.95rem);
  opacity: 0.95;
}

.hero-actions {
  margin-top: 18px;
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.btn {
  display: inline-block;
  padding: 12px 20px;
  border-radius: 6px;
  text-decoration: none;
  font-weight: 700;
  min-width: 120px;
  text-align: center;
}

.btn.primary {
  background: var(--primary);
  color: #fff;
  border: 2px solid var(--primary);
}

.btn.primary:hover {
  background: #5b1e53;
}

.btn.ghost {
  background: transparent;
  color: #fff;
  border: 2px solid rgba(255,255,255,0.2);
}

.btn.secondary {
  background: transparent;
  border: 2px solid #fff;
  color: #fff;
}

.hero-right {
  width: 360px;
}

.hero-panel {
  background: var(--glass);
  padding: 20px;
  border-radius: 8px;
  border: 1px solid rgba(255,255,255,0.06);
}

.panel-title {
  color: #fff;
  margin: 0 0 8px;
}

.hero-metrics {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 14px;
}

.hero-metrics li {
  list-style: none;
  color: #fff;
  font-weight: 800;
  padding: 8px 10px;
  background: rgba(255,255,255,0.06);
  border-radius: 6px;
  flex: 0 0 45%;
}

/* Two Column About */
.two-col {
  display: grid;
  grid-template-columns: 1fr 420px;
  gap: 32px;
  align-items: start;
}

.spotlight {
  background: linear-gradient(180deg, rgba(109,36,99,0.06), rgba(168,79,163,0.04));
  padding: 16px;
  border-radius: 8px;
  border: 1px solid rgba(0,0,0,0.04);
}

.card-img {
  width: 100%;
  height: 220px;
  object-fit: cover;
  border-radius: 8px;
  margin-top: 18px;
}

/* Guest Section */
.guest-section .two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 28px;
  align-items: center;
}

.guest-img {
  width: 100%;
  height: 380px;
  object-fit: cover;
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.guest-copy h2 {
  margin-top: 0;
}

/* Stats Grid (Big Numbers) */
.stats-section {
  overflow-x: hidden;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 16px;
  text-align: center;
  max-width: 100%;
  overflow: hidden; /* Extra prevención */
}

.stat {
  background: var(--bg);
  padding: 16px;
  border-radius: 8px;
  box-shadow: var(--shadow);
  max-width: 100%;
}

.stat-number {
  font-size: clamp(1.4rem, 3.5vw, 1.8rem);
  font-weight: 800;
  color: var(--primary);
}

.stat-label {
  color: var(--muted);
  margin-top: 6px;
  font-size: 0.9rem;
  overflow-wrap: break-word;
  word-break: break-word; /* Mejora centrado/wrap */
}

/* Program Cards */
.program-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 18px;
  margin-top: 18px;
}

.prog-card {
  background: var(--primary-2);
  padding: 18px;
  border-radius: 8px;
  box-shadow: var(--shadow);
}

/* People Grid */
.people-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 18px;
  margin-top: 18px;
}

.person-card {
  background: var(--bg);
  padding: 12px;
  border-radius: 8px;
  text-align: center;
  box-shadow: var(--shadow);
}

.person-card img {
  width: 100%;
  height: 180px;
  object-fit: cover;
  border-radius: 6px;
  margin-bottom: 10px;
}

/* Homenajes */
.homenajes-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 18px;
  margin-top: 18px;
}

.h-card {
  background: var(--bg);
  padding: 18px;
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.h-card img {
  width: 100%;
  height: 180px;
  object-fit: cover;
  border-radius: 6px;
  margin-bottom: 10px;
}

/* Sponsors */
.sponsors-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 18px;
  margin-top: 18px;
}

.s-cat {
  background: var(--bg);
  padding: 14px;
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.sponsor-logos {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  margin-top: 18px;
}

.sponsor-logos img {
  height: 56px;
  max-width: 100%;
  filter: grayscale(100%);
  transition: filter 0.2s;
}

.sponsor-logos img:hover {
  filter: none;
}

/* Footer */
.site-footer {
  background: var(--primary);
  color: #fff;
  padding: 28px 0;
}

.footer-grid {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  align-items: center;
}

/* Animations */
.fade-up {
  opacity: 0;
  transform: translateY(14px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.fade-up.visible {
  opacity: 1;
  transform: none;
}

/* Agrego a imgs generales */
img {
  max-width: 100%;
  height: auto;
}

/* Focus para accesibilidad */
a:focus, button:focus {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
}

/* Back-to-top */
#back-to-top {
  position: fixed;
  bottom: 20px;
  right: 20px;
  background: var(--primary);
  color: #fff;
  border: none;
  border-radius: 50%;
  width: 40px;
  height: 40px;
  cursor: pointer;
  display: none;
  z-index: 1000;
  font-size: 1rem;
}

#back-to-top.visible {
  display: block;
}

/* Responsive */
@media (max-width: 900px) {
  .main-nav {
    display: none;
    position: fixed;
    top: 70px;
    right: 0;
    width: 100%;
    max-width: 300px;
    background: var(--bg);
    box-shadow: var(--shadow);
    padding: 12px;
    z-index: 1200;
    transform: translateX(100%);
    transition: transform 0.3s ease;
  }

  .main-nav.active {
    display: block;
    transform: translateX(0);
  }

  .main-nav ul {
    flex-direction: column;
    gap: 12px;
  }

  .main-nav a {
    display: block;
    padding: 10px;
    font-size: 1rem;
  }

  .menu-toggle {
    display: block;
  }

  .nav-overlay.active {
    display: block;
  }

  .hero-content {
    flex-direction: column;
    padding: 32px 8px;
    justify-content: center; /* Mantiene centrado en mobile */
  }

  .hero-left, .hero-right {
    width: 100%;
    max-width: none;
  }

  .hero-right {
    margin-top: 24px;
  }

  .hero-metrics li {
    flex: 0 0 48%;
  }

  .two-col {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  .guest-img {
    height: 300px;
  }

  .stats-grid {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .program-grid {
    grid-template-columns: 1fr;
  }

  .wrap { padding: 0 12px; } /* Mejor centrado mobile */
}

@media (max-width: 700px) {
  .footer-grid {
    flex-direction: column;
    gap: 8px;
  }
}

@media (max-width: 480px) {
  .wrap {
    padding: 0 8px;
  }

  .hero-title {
    font-size: clamp(1.6rem, 4vw, 2rem);
  }

  .hero-sub {
    font-size: 0.9rem;
  }

  .countdown {
    flex-direction: column;
    align-items: flex-start;
  }

  .big-count {
    font-size: 1.2rem;
  }

  .btn {
    padding: 10px 16px;
    font-size: 0.9rem;
  }

  .hero-panel {
    padding: 16px;
  }

  .card-img {
    height: 180px;
  }

  .guest-img {
    height: 240px;
  }

  .people-grid {
    grid-template-columns: 1fr;
  }

  .homenajes-grid {
    grid-template-columns: 1fr;
  }

  .sponsors-grid {
    grid-template-columns: 1fr;
  }

  .sponsor-logos img {
    height: 48px;
  }

  .section { padding: 60px 0; } /* Más aire en mobile */
}