/* Paleta base: 60% blanco, 30% azul, 10% rojo */
:root {
  --blanco: #ffffff;
  --gris-suave: #f8fafc;
  --azul: #0f2b5c;       /* Azul marino */
  --azul-claro: #1d4ed8; /* Azul vivo */
  --rojo: #dc2626;       /* Rojo acento */
  --texto: #1e293b;
}

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

body {
  background-color: var(--blanco);
  color: var(--texto);
  font-family: system-ui, -apple-system, sans-serif;
  line-height: 1.5;
}

/* --- Intro Superpuesta --- */
#intro-overlay {
  position: fixed;
  inset: 0;
  background-color: var(--blanco);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  transition: opacity 0.6s ease, visibility 0.6s ease;
  padding: 5%;
}

#intro-overlay.fade-out {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.track-container {
  width: clamp(260px, 45vw, 650px);
  max-height: 45vh;
  aspect-ratio: 1000 / 560;
  display: flex;
  align-items: center;
  justify-content: center;
}

#olympic-track-svg {
  width: 100%;
  height: 100%;
  overflow: visible;
  filter: drop-shadow(0 6px 16px rgba(0, 0, 0, 0.06));
}

#finish-line {
  transition: opacity 0.4s ease;
  opacity: 0.95;
}

#finish-line.hidden {
  opacity: 0;
}

/* --- Transición Web Principal --- */
#main-content {
  opacity: 0;
  transform: translateY(12px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

#main-content.visible {
  opacity: 1;
  transform: translateY(0);
}











/* --- Barra de navegación --- */
.navbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.75rem 5%;
  background: var(--blanco);
  border-bottom: 1px solid #e2e8f0;
  gap: 1rem;
}

/* Bloque conjunto (Logo + Texto) */
.brand-container {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  text-decoration: none;
}

/* Imagen del escudo adaptada */
.logo-img {
  width: clamp(40px, 4vw, 50px);
  height: clamp(40px, 4vw, 50px);
  object-fit: contain;
  border-radius: 50%;
  flex-shrink: 0;
}

/* Tipografía del nombre */
.logo-text {
  font-weight: 800;
  font-size: clamp(1rem, 1.8vw, 1.25rem);
  color: var(--azul);
  letter-spacing: -0.5px;
  white-space: nowrap;
}

.logo-text span {
  color: var(--rojo);
  margin: 0 1px;
}

nav a {
  position: relative;
  margin: 0 1rem;
  padding: 0.3rem 0;
  text-decoration: none;
  color: var(--azul);
  font-weight: 500;
  transition: color 0.3s ease;
}

nav a::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 2px;
  background-color: var(--rojo);
  transform: scaleX(0);
  transform-origin: center;
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

nav a:hover::after {
  transform: scaleX(1);
}

nav a:hover {
  color: var(--azul-claro);
}

.btn-rojo {
  background: transparent;
  color: white;
  border-color: blue;
  border: 2px solid blue;
  padding: 0.55rem 1.35rem;
  font-size: 0.9rem;
  font-weight: 700;
  letter-spacing: 0.5px;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

.btn-rojo:hover {
  background: transparent;
  color: white;
  border-color: blue;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.25);
  transform: translateY(-1px);
}

.btn-rojo.btn-icono {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.55rem 0.85rem; 
}

.icono-shop {
  width: 22px;
  height: 22px;
  object-fit: contain;
  display: block;
}

/* Botón azul complementario */
.btn-azul {
  background-color: var(--azul);
  color: var(--blanco);
  border: none;
  cursor: pointer;
  text-decoration: none;
  transition: background-color 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
  box-shadow: 0 4px 12px rgba(15, 43, 92, 0.2);
}

.btn-azul:hover {
  background-color: var(--azul-claro);
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(29, 78, 216, 0.35);
}

/* Base común para botones solo de icono en la barra de navegación */
.btn-icono {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  padding: 0;
  border-radius: 8px; /* O 50% si prefieres que ambos botones sean redondos */
}

/* Tamaño y comportamiento del icono SVG */
.icono-nav {
  width: 20px;
  height: 20px;
  display: block;
}













/* --- Hero Slider (Ocupa todo el ancho y 80% de alto de pantalla) --- */
.hero-slider {
  position: relative;
  width: 100%;
  height: 90vh;
  height: 90dvh; /* Soporte exacto para barras de navegación dinámicas móviles */
  margin: 0;
  border-radius: 0;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  box-shadow: none;
}

/* Tira horizontal: 9 imágenes = 900% de ancho */
.slider-track {
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
  width: 900%;
  display: flex;
  animation: deslizar9Fotos 32s cubic-bezier(0.45, 0, 0.25, 1) infinite;
}

/* Cada diapositiva mide exactamente 1/9 parte de la tira */
.slide {
  width: calc(100% / 9);
  height: 100%;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  flex-shrink: 0;
}

/* Capa degradada de izquierda a derecha */
.slider-overlay {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background: linear-gradient(
    to right,
    rgba(15, 23, 42, 0.85) 0%,
    rgba(15, 23, 42, 0.6) 25%,
    rgba(15, 23, 42, 0) 55%,
    rgba(15, 23, 42, 0) 100%
  );
}

/* Texto alineado a la izquierda */
.slider-content {
  position: relative;
  z-index: 2;
  color: #ffffff;
  text-align: left;
  padding: 0 5%;
  max-width: 650px;
}

.slider-content h2 {
  font-size: clamp(2rem, 4.5vw, 3.8rem);
  font-weight: 800;
  line-height: 1.15;
  margin-bottom: 0.75rem;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.4);
}

.slider-content p {
  font-size: clamp(1rem, 2vw, 1.35rem);
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.4);
}

/* Contenedor estándar para el contenido de abajo */
.container {
  max-width: 1100px;
  margin: 3rem auto;
  padding: 0 5%;
}

.container h1 {
  color: var(--azul);
  margin-bottom: 0.5rem;
}

/* --- Animación de los 9 fondos --- */
@keyframes deslizar9Fotos {
  0%, 9% { transform: translateX(0%); }
  12.5%, 21.5% { transform: translateX(-11.111%); }
  25%, 34% { transform: translateX(-22.222%); }
  37.5%, 46.5% { transform: translateX(-33.333%); }
  50%, 59% { transform: translateX(-44.444%); }
  62.5%, 71.5% { transform: translateX(-55.555%); }
  75%, 84% { transform: translateX(-66.666%); }
  87.5%, 96.5% { transform: translateX(-77.777%); }
  100% { transform: translateX(-88.888%); }
}

/* --- Ajustes Responsive Móvil --- */
@media (max-width: 768px) {
  .navbar {
    padding: 0.6rem 4%;
  }

  .brand-container {
    gap: 0.5rem;
  }

  .slider-content {
    padding: 0 1.5rem;
    max-width: 100%;
  }
}














/* --- Footer Celeste --- */
.site-footer {
  background-color: #72b3dc; /* Azul celeste exacto de la imagen */
  color: #ffffff;
  padding: 3rem 5% 1.5rem;
  width: 100%;
}

.footer-container {
  max-width: 1100px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 2.5rem;
}

.footer-col h3 {
  font-size: 1.15rem;
  font-weight: 800;
  letter-spacing: 0.5px;
  margin-bottom: 1.2rem;
  color: #ffffff;
}

.footer-col p {
  font-size: 0.95rem;
  line-height: 1.8;
  color: rgba(255, 255, 255, 0.95);
}

.footer-col a {
  color: #ffffff;
  text-decoration: none;
  transition: opacity 0.2s ease;
}

.footer-col a:hover {
  opacity: 0.8;
  text-decoration: underline;
}

/* Iconos de redes sociales circulares blancos */
.footer-socials {
  display: flex;
  gap: 0.75rem;
}

/* El enlace circular que actúa como contenedor */
.footer-socials a {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden; /* Clave: recorta la imagen cuadrada para que sea un círculo */
  background-color: #ffffff;
  transition: transform 0.2s ease;
}

.footer-socials a:hover {
  transform: translateY(-3px);
}

/* La imagen dentro del círculo */
.footer-socials a img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transform: scale(1.50); /* 1.25 equivale a un 25% de zoom */
}

/* Línea separadora y texto inferior */
.footer-bottom {
  max-width: 1100px;
  margin: 2.5rem auto 0;
  padding-top: 1.25rem;
  border-top: 1px solid rgba(255, 255, 255, 0.35);
  text-align: center;
}

.footer-bottom p {
  font-size: 0.78rem;
  letter-spacing: 0.8px;
  color: rgba(255, 255, 255, 0.9);
}

/* --- Adaptación para Móviles --- */
@media (max-width: 768px) {
  .site-footer {
    padding: 2.5rem 6% 1.5rem;
  }

  .footer-container {
    flex-direction: column;
    gap: 2rem;
  }

  .footer-col h3 {
    margin-bottom: 0.8rem;
  }
}

















/* --- Sección Deslizable de Ancho Completo --- */
.secciones-carrusel {
  width: 100%;
  padding: 4.5rem 0 3.5rem;
  background-color: var(--blanco);
  overflow: hidden;
}

.carrusel-header {
  text-align: center;
  padding: 0 5%;
  margin-bottom: 2.5rem;
}

.carrusel-header h2 {
  font-size: clamp(1.8rem, 3.5vw, 2.5rem);
  font-weight: 800;
  color: var(--azul);
  letter-spacing: -0.5px;
}

.carrusel-header h2 span {
  color: var(--rojo);
}

.carrusel-header p {
  color: #64748b;
  font-size: 1rem;
  margin-top: 0.4rem;
}

/* Pista horizontal: ocupa todo el ancho y centra las tarjetas en PC */
.carrusel-track {
  width: 100vw;
  max-width: 100%;
  display: flex;
  gap: 1.75rem;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  -webkit-overflow-scrolling: touch;
  padding: 1rem 5% 2.5rem;

  /* Difuminado suave: opaco al 100% en el centro, desvaneciéndose en los extremos */
  -webkit-mask-image: linear-gradient(
    to right,
    transparent 0%,
    black 4%,
    black 93%,
    transparent 100%
  );
  mask-image: linear-gradient(
    to right,
    transparent 0%,
    black 4%,
    black 93%,
    transparent 100%
  );
}

/* Estilo de la barra de scroll */
.carrusel-track::-webkit-scrollbar {
  height: 6px;
}

.carrusel-track::-webkit-scrollbar-track {
  background: var(--gris-suave);
  border-radius: 10px;
}

.carrusel-track::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: 10px;
}

/* Tarjeta individual */
.seccion-card {
  flex: 0 0 clamp(280px, 22vw, 340px);
  scroll-snap-align: center; /* Se imanta al centro de la pantalla al deslizar */
  background: var(--blanco);
  border: 1px solid #e2e8f0;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 8px 24px rgba(15, 43, 92, 0.06);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
  display: flex;
  flex-direction: column;
}

.seccion-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 16px 32px rgba(15, 43, 92, 0.12);
}

.card-img {
  position: relative; /* Necesario para contener el pseudo-elemento */
  width: 100%;
  height: 190px;
  background-size: cover;
  background-position: center;
  flex-shrink: 0;
  background-image: url('img/notFound.jpg');
}

/* Sombra degradada en el tercio inferior de la foto */
.card-img::after {
  content: '';
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(
    to bottom,
    transparent 65%,
    rgba(15, 43, 92, 0.28) 100%
  );
}

.card-info {
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.card-info h3 {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--azul);
  margin-bottom: 0.6rem;
}

.card-info p {
  color: #64748b;
  font-size: 0.92rem;
  line-height: 1.5;
  margin-bottom: 1.5rem;
  flex-grow: 1;
}

.card-btn {
  display: inline-block;
  align-self: flex-start;
  text-decoration: none;
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--azul-claro);
  border: 1.5px solid var(--azul-claro);
  padding: 0.55rem 1.2rem;
  border-radius: 8px;
  transition: all 0.2s ease;
}

.card-btn:hover {
  background-color: var(--azul-claro);
  color: var(--blanco);
}

/* --- Adaptación a Móvil --- */
@media (max-width: 768px) {
  .secciones-carrusel {
    padding: 3rem 0 2rem;
  }

  .carrusel-header {
    text-align: left;
    padding: 0 6%;
    margin-bottom: 1.5rem;
  }

  .carrusel-track {
    justify-content: flex-start; /* Evita recortar la primera tarjeta al deslizar */
    padding: 1rem 6% 2rem;
    gap: 1.25rem;
  }

  .seccion-card {
    flex: 0 0 78vw; /* Permite asomar la siguiente tarjeta por la derecha */
    scroll-snap-align: start;
  }
}














/* --- SECCIÓN RECUERDOS / COMUNIDAD --- */
.seccion-recuerdos {
  background-color: var(--blanco);
  border-top: 1px solid var(--gris-lineas, #e2e8f0);
  border-bottom: 1px solid var(--gris-lineas, #e2e8f0);
  padding: 5rem 5%;
}

.recuerdos-container {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  gap: 3.5rem;
}

.recuerdos-badge {
  display: inline-block;
  background-color: #fee2e2;
  color: var(--rojo);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 1px;
  padding: 0.35rem 0.85rem;
  border-radius: 50px;
  text-transform: uppercase;
  margin-bottom: 1rem;
}

.recuerdos-content h2 {
  color: var(--azul);
  font-size: clamp(1.8rem, 3.5vw, 2.4rem);
  font-weight: 800;
  line-height: 1.2;
  margin-bottom: 1.2rem;
}

.recuerdos-content p {
  color: #64748b;
  font-size: 1rem;
  line-height: 1.6;
  margin-bottom: 2rem;
}

.btn-recuerdos {
  display: inline-block;
  background-color: var(--azul);
  color: var(--blanco);
  text-decoration: none;
  font-weight: 700;
  font-size: 0.95rem;
  padding: 0.85rem 1.8rem;
  border-radius: 8px;
  transition: background-color 0.2s ease, transform 0.2s ease;
}

.btn-recuerdos:hover {
  background-color: var(--rojo);
  transform: translateY(-2px);
}

/* Mosaico interactivo de fotos */
.recuerdos-grid-preview {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1rem;
  position: relative;
}

.preview-card {
  height: 170px;
  background-size: cover;
  background-position: center;
  border-radius: 12px;
  box-shadow: 0 8px 20px rgba(15, 43, 92, 0.08);
  transition: transform 0.3s ease;
}

.preview-card:hover {
  transform: scale(1.03);
}

.foto-1 {
  grid-column: 1 / 2;
  grid-row: 1 / 3;
  height: 350px; /* Foto vertical destacada */
}

.foto-2 {
  grid-column: 2 / 3;
  grid-row: 1 / 2;
}

.foto-3 {
  grid-column: 2 / 3;
  grid-row: 2 / 3;
}

/* Responsivo para tablets y móviles */
@media (max-width: 860px) {
  .recuerdos-container {
    grid-template-columns: 1fr;
    gap: 2.5rem;
  }

  .seccion-recuerdos {
    padding: 3.5rem 5%;
  }

  .foto-1 {
    height: 240px;
  }
  
  .preview-card {
    height: 115px;
  }
}