/* ==========================================================================
   CARGA DE FUENTE PERSONALIZADA (Solo para Títulos)
   ========================================================================== */
@font-face {
    font-family: 'Amsi Pro';
    src: url('fonts/AmsiProCond-Ultra.otf') format('opentype');
    font-weight: bold;
    font-style: normal;
    font-display: swap;
}

:root {
    /* Paleta de Colores Principal */
    --bg-primary: #099837;
    --bg-dark: #006629;
    --accent-yellow: #FFCC00;
    --accent-red: #D80027;
    --text-white: #FFFFFF;
    --text-dark: #222222;

    /* FUENTES */
    --font-family-title: 'Amsi Pro', 'Arial Black', sans-serif;
    --font-family-body: 'Arial', 'Helvetica', sans-serif;
}

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

html {
    scroll-behavior: smooth;
}

body {
    background-color: var(--bg-primary);
    color: var(--text-white);
    font-family: var(--font-family-body);
    line-height: 1.5;
    overflow-x: hidden;
}

/* Elevamos todas las secciones principales por encima del fondo parallax */
.hero-section,
.mecanica-section,
.dinamica-section,
.premios-legales-section,
.main-footer {
    position: relative;
    z-index: 2;
}

.container {
    width: 90%;
    max-width: 1100px;
    margin: 0 auto;
    padding: 20px 0;
}

.text-center {
    text-align: center;
}

.img-placeholder {
    max-width: 100%;
    height: auto;
    display: block;
    object-fit: contain;
}


/* ==========================================================================
   ELEMENTOS DECORATIVOS PARALLAX (CSS BLUR DE PROFUNDIDAD)
   ========================================================================== */

.parallax-bg-wrapper {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100vh;
  pointer-events: none; 
  z-index: 1; /* Fondo pero sobre el body */
  overflow: hidden;
    pointer-events: none !important;
}

.floating-item {
  position: absolute;
  will-change: transform;
  user-select: none;
}

/* Aplica el desenfoque directo por CSS */
.blur-bg {
  filter: blur(6px);
  opacity: 0.7;
}

/* Posiciones iniciales Desktop */
.item-1 { top: 15%; right: 15%; width: 100px; } /* Lonchera */
.item-2 { top: 35%; left: 10%;   width: 65px;  } /* Colores */
.item-3 { top: 70%; left: 10%;   width: 150px; transform: rotate(-35deg); } /* Escuadra */
.item-4 { top: 10%; left: 10%;  width: 100px; } /* Mochila */
.item-5 { top: 52%; left: 7%;   width: 80px; } /* Crayolas */
.item-6 { top: 25%; right: 10%;  width: 60px; } /* Plumas */
.item-7 { top: 62%; right: 13%;   width: 150px; } /* Cuaderno */
.item-8 { top: 45%; right: 8%;  width: 120px; transform: rotate(-15deg); } /* Resistol */


/* ==========================================================================
   PRELOADER
   ========================================================================== */

#preloader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-color: var(--bg-dark);
    z-index: 9999;
    display: flex;
    justify-content: center;
    align-items: center;
}

.loader-content {
    text-align: center;
}

.spinner {
    width: 60px;
    height: 60px;
    border: 6px solid rgba(255, 255, 255, 0.2);
    border-top-color: var(--accent-yellow);
    border-radius: 50%;
    animation: spin 1s infinite linear;
    margin: 0 auto 20px auto;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.loader-text {
    font-family: var(--font-family-title);
    color: var(--accent-yellow);
    font-size: 1.1rem;
    letter-spacing: 2px;
}


/* ==========================================================================
   HEADER / NAVEGACIÓN
   ========================================================================== */

.main-header {
    position: relative;
    width: 100%;
    z-index: 1000;
}

.header-container {
    display: flex;
    align-items: center;
    justify-content: space-between; /* Logos a la izq, nav/hamburguesa a la der */
    width: 100%;
    padding: 10px 20px;
}

.brand-logos {
    display: flex;
    align-items: center;
    gap: 12px;
}

.logo-img {
    max-height: 60px;
    width: auto;
}

.main-nav ul {
    display: flex;
    list-style: none;
    gap: 20px;
}

.main-nav a {
    color: var(--text-white);
    text-decoration: none;
    font-family: var(--font-family-title);
    font-size: 1.3rem;
    letter-spacing: 0.5px;
    transition: color 0.3s ease;
}

.main-nav a:hover {
    color: var(--accent-yellow);
    z-index: 99990 !important;
}


/* Botón Hamburguesa (oculto en desktop) */
.hamburger-btn {
    position: relative;
    z-index: 99999 !important;
    pointer-events: auto !important;
    display: none;
    flex-direction: column;
    justify-content: space-between;
    width: 30px;
    height: 22px;
    background: transparent;
    border: none;
    cursor: pointer;
    z-index: 1002 !important; /* Arriba del menú desplegado */
    padding: 0;
}

.hamburger-btn .bar {
    width: 100%;
    height: 3px;
    background-color: var(--text-white);
    border-radius: 3px;
    transition: transform 0.3s ease, opacity 0.3s ease, background-color 0.3s ease;
}

/* Animación a "X" */
.hamburger-btn.active .bar:nth-child(1) {
    transform: translateY(9.5px) rotate(45deg);
    background-color: var(--accent-yellow);
}

.hamburger-btn.active .bar:nth-child(2) {
    opacity: 0;
}

.hamburger-btn.active .bar:nth-child(3) {
    transform: translateY(-9.5px) rotate(-45deg);
    background-color: var(--accent-yellow);
}


/* ==========================================================================
   HERO SECTION
   ========================================================================== */

.hero-section {
    padding: 40px 0 20px 0;
}

.hero-main-title {
    display: flex;
    justify-content: center;
    margin-bottom: 20px;
}

.hero-badge-img {
    max-width: 420px;
}

.hero-subtitle {
    font-family: var(--font-family-title);
    font-size: 2.5rem;
    text-transform: uppercase;
    color: var(--accent-yellow);
    line-height: 1;
    margin-bottom: 15px;
}

.highlight-text {
    font-size: 4rem;
    color: var(--text-white);
}

.hero-tagline {
    font-family: var(--font-family-title);
    font-size: 1.7rem;
    color: var(--text-white);
}


/* ==========================================================================
   MECÁNICA
   ========================================================================== */

.mecanica-section {
    padding: 30px 0;
}

.section-title {
    font-family: var(--font-family-title);
    font-size: 3.5rem;
    color: var(--accent-yellow);
    margin-bottom: 15px;
    text-transform: uppercase;
}

.mecanica-box {
    max-width: 850px;
    margin: 0 auto;
    font-size: 0.95rem;
    line-height: 1.6;
}

.mecanica-box span {
    font-weight: bold;
}

.mecanica-note {
    margin-top: 15px;
    margin-bottom: 1%;
    font-weight: bold;
    font-style: italic;
    font-size: 1.5rem;
}


/* ==========================================================================
   DINÁMICAS (1 Y 2)
   ========================================================================== */

.dinamica-section {
    padding: 40px 0;
}

.dinamica-title {
    font-family: var(--font-family-title);
    font-size: 2.5rem;
    color: var(--accent-yellow);
    text-transform: uppercase;
}

.dinamica-dates {
    font-family: var(--font-family-title);
    font-size: 1.8rem;
    color: var(--text-white);
    margin-bottom: 5px;
}

.dinamica-desc {
    font-size: 0.9rem;
    opacity: 0.9;
    margin-bottom: 30px;
}

.dinamica-content {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 30px;
    flex-wrap: wrap;
    margin-bottom: 30px;
}

.dinamica-media {
    display: flex;
    align-items: flex-end;
    gap: 15px;
}

.character-img {
    max-height: 420px;
}

.list-img {
    max-height: 320px;
}

.dinamica-badge {
    display: flex;
    justify-content: center;
}

.badge-img {
    max-width: 320px;
}


/* ==========================================================================
   CONTADOR SIMPLE (TEXTO)
   ========================================================================== */

.countdown-simple-container {
    margin: 15px auto 25px auto;
    background-color: rgba(0, 0, 0, 0.25);
    padding: 10px 20px;
    border-radius: 50px;
    display: inline-block;
    border: 2px solid var(--accent-yellow);
}

.countdown-simple-text {
    font-family: var(--font-family-title);
    font-size: 1.2rem;
    color: var(--text-white);
    letter-spacing: 0.5px;
}

.countdown-simple-text span {
    color: var(--accent-yellow);
    font-size: 1.4rem;
}


/* ==========================================================================
   BOTONES Y CTA
   ========================================================================== */

.cta-wrapper {
    margin-top: 20px;
}

.btn-cta {
    display: inline-block;
    z-index: 1;
    background-color: #70d38a;
    color: #fff;
    font-family: var(--font-family-body);
    font-size: 1.7rem;
    padding: 20px 30px;
    border-radius: 50px;
    text-decoration: none;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    transition: transform 0.3s ease, background-color 0.3s ease;
}

.btn-cta:hover {
    background-color: var(--accent-yellow);
    color: #000;
    transform: scale(1.05);
}



/* ==========================================================================
   SECCIÓN PREMIOS Y TÉRMINOS Y CONDICIONES
   ========================================================================== */

.premios-legales-section {
    padding: 60px 20px;
}

.premios-title {
    font-family: var(--font-family-title);
    color: var(--accent-yellow);
    font-size: 4rem;
    text-align: center;
    margin-bottom: 0;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.premios-grid {
    display: grid;
    grid-template-columns: repeat(3, 2fr);
    gap: 30px;
    align-items: end;
    text-align: center;
    margin-bottom: 70px;
}

.premio-item {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.premio-img {
    max-width: 100%;
    height: auto;
    max-height: 220px;
    object-fit: contain;
    margin-bottom: 15px;
    filter: drop-shadow(0 8px 12px rgba(0, 0, 0, 0.25));
    transition: transform 0.3s ease;
}

.premio-item:hover .premio-img {
    transform: translateY(-5px);
}

.premio-title {
    font-family: var(--font-family-title);
    color: var(--text-white);
    font-size: 1.5rem;
    letter-spacing: 0.5px;
    margin: 0;
    text-transform: uppercase;
}

/* Términos y Condiciones */
.tyc-container {
    max-width: 900px;
    margin: 0 auto;
    color: var(--text-white);
}

.tyc-title {
    font-family: var(--font-family-title);
    color: var(--accent-yellow);
    font-size: 3rem;
    text-align: center;
    margin-bottom: 30px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.tyc-list {
    list-style: none;
    padding: 0;
    margin: 0;
    margin-bottom: 10%;
}

.tyc-list li {
    font-family: var(--font-family-body);
    font-size: 0.95rem;
    line-height: 1.6;
    margin-bottom: 14px;
    position: relative;
    padding-left: 18px;
}

.tyc-list li span {
    font-weight: bold;
}
}

.tyc-list li::before {
    content: "•";
    color: var(--text-white);
    font-size: 1.2rem;
    position: absolute;
    left: 0;
    top: -2px;
}


/* ==========================================================================
   FOOTER
   ========================================================================== */

.main-footer {
    background-color: var(--bg-dark);
    padding: 20px 0;
    font-size: 0.85rem;
    opacity: 0.8;
}


/* ==========================================================================
   RESPONSIVO ÚNICO (MÓVIL <= 768px)
   ========================================================================== */

@media (max-width: 768px) {

    /* Parallax Móvil */
    .parallax-bg-wrapper {
        z-index: 1;
        opacity: 0.5;
    }

    .floating-item {
        scale: 0.5;
    }

    .floating-item:not(.blur-bg) {
        filter: blur(2px);
    }

    .item-1 { top: 10%; right: 5px; width: 100px; }
    .item-2 { top: 35%; left: -5px; width: 120px; }
    .item-3 { top: 65%; left: 2px; width: 80px; }
    .item-4 { top: 15%; left: 25px; width: 100px; }
    .item-5 { top: 50%; left: 1px; width: 80px; }
    .item-6 { top: 20%; right: 1px; width: 60px; }
    .item-7 { top: 80%; left: 1px; width: 100px; }
    .item-8 { top: 60%; right: 40px; width: 80px; }

    /* Header y Navegación Móvil */
    .header-container {
        display: flex;
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
        width: 100%;
        padding: 12px 20px;
    }

    .brand-logos {
        margin: 0; /* Limpiamos márgenes que rompían la línea */
    }

    .logo-img {
        max-height: 40px;
        width: auto;
    }

    .hamburger-btn {
        display: flex;
        margin-left: auto;
    }

    /* Menú Fullscreen */
    .main-nav {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100vh;
        background-color: var(--bg-dark);
        display: flex;
        justify-content: center;
        align-items: center;
        opacity: 0;
        visibility: hidden;
        transition: opacity 0.3s ease, visibility 0.3s ease;
        z-index: 1001 !important;
    }

    .main-nav.active {
        opacity: 1;
        visibility: visible;
    }

    .main-nav ul {
        flex-direction: column;
        align-items: center;
        gap: 30px;
        padding: 0;
    }

    .main-nav a {
        font-size: 1.8rem;
    }

    /* Hero Section */
    .hero-badge-img {
        max-width: 320px;
    }

    .hero-subtitle {
        font-size: 1.6rem;
    }

    .highlight-text {
        font-size: 2.5rem;
    }

    .hero-tagline {
        font-size: 1rem;
    }

    /* Dinámicas */
    .dinamica-content {
        flex-direction: column;
    }

    .dinamica-media {
        flex-direction: column;
        align-items: center;
    }

    /* Premios y TYC */
    .premios-grid {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .premio-title {
        font-size: 1.6rem;
    }

    .tyc-container {
        max-width: 350px;
        margin: 0 auto;
    }

    .tyc-title {
        font-size: 1.8rem;
    }

    .tyc-list li {
        font-size: 0.9rem;
    }
}