/*
Theme Name: Academia Atlas Tuxtla Premium
Theme URI: https://atlastuxtla.mx
Author: Academia Atlas Tuxtla
Author URI: https://atlastuxtla.mx
Description: Tema premium a la medida con integración nativa para WooCommerce.
Version: 1.0
Text Domain: atlas-tuxtla
*/

/* Variables de Color Premium */
:root {
    --rojo-atlas: #c8102e;
    --rojo-intenso: #ff1a3b;
    --negro-atlas: #000000;
    --blanco: #ffffff;
    --gris-claro: #f4f4f4;
    --negro-suave: #111111;
}

html { scroll-behavior: smooth; }
* { margin: 0; padding: 0; box-sizing: border-box; font-family: 'Montserrat', sans-serif; }
body { background-color: var(--negro-atlas); color: var(--blanco); overflow-x: hidden; }
h2, h3 { text-transform: uppercase; font-weight: 900; letter-spacing: 1px; }
a { text-decoration: none; color: inherit; transition: 0.3s; }
img { max-width: 100%; height: auto; }

/* --- Animaciones Fade-In --- */
.fade-in-section { opacity: 0; transform: translateY(40px) scale(0.98); visibility: hidden; transition: opacity 1s cubic-bezier(0.22, 1, 0.36, 1), transform 1s cubic-bezier(0.22, 1, 0.36, 1); will-change: opacity, transform; }
.is-visible { opacity: 1; transform: translateY(0) scale(1); visibility: visible; }

/* --- Navegación y Menú Móvil --- */
header { position: fixed; top: 0; width: 100%; padding: 15px 5%; display: flex; justify-content: space-between; align-items: center; background: rgba(5, 5, 5, 0.95); backdrop-filter: blur(10px); z-index: 1000; border-bottom: 1px solid rgba(255,255,255,0.05); }
.logo-container { display: flex; align-items: center; gap: 15px; z-index: 1001; }
.logo-img { width: 45px; height: 45px; object-fit: cover; }
.logo-text { color: var(--blanco); font-size: 1.1rem; font-weight: 900; text-transform: uppercase; line-height: 1.1; }
.menu-toggle { display: none; color: white; font-size: 1.5rem; cursor: pointer; z-index: 1001; }
nav ul { list-style: none; display: flex; gap: 30px; align-items: center; }
nav > ul > li { position: relative; padding: 10px 0; }
nav ul li a { color: var(--blanco); font-weight: 700; font-size: 0.85rem; text-transform: uppercase; letter-spacing: 1px;}
nav ul li a:hover { color: var(--rojo-atlas); }
.submenu { position: absolute; top: 100%; left: 0; background: rgba(15, 15, 15, 0.95); min-width: 250px; border-top: 3px solid var(--rojo-atlas); opacity: 0; visibility: hidden; transform: translateY(15px); transition: all 0.4s ease; flex-direction: column; padding: 10px 0; box-shadow: 0 15px 30px rgba(0,0,0,0.8); }
nav > ul > li:hover .submenu { opacity: 1; visibility: visible; transform: translateY(0); display: flex; }
.submenu li { width: 100%; }
.submenu li a { display: block; padding: 12px 25px; border-bottom: 1px solid rgba(255,255,255,0.03); }

/* --- Botones Globales --- */
.btn-primary { display: inline-block; background-color: var(--rojo-atlas); color: var(--blanco); padding: 15px 35px; text-transform: uppercase; font-weight: 700; border-radius: 50px; font-size: 0.9rem; letter-spacing: 1px; transition: all 0.3s ease; border: none; cursor: pointer; text-align: center; }
.btn-primary:hover { background-color: var(--rojo-intenso); transform: scale(1.05) translateY(-3px); box-shadow: 0 10px 25px rgba(200, 16, 46, 0.6); }

/* --- Carrito Premium Avanzado --- */
.cart-floating-btn { position: fixed; bottom: 30px; right: 30px; width: 60px; height: 60px; background: var(--rojo-atlas); color: white; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 1.5rem; box-shadow: 0 10px 25px rgba(0,0,0,0.5); cursor: pointer; z-index: 999; transition: 0.3s; }
.cart-floating-btn:hover { transform: scale(1.1); background: var(--rojo-intenso); }
.cart-badge { position: absolute; top: -5px; right: -5px; background: white; color: var(--rojo-atlas); font-size: 0.8rem; font-weight: 900; width: 22px; height: 22px; border-radius: 50%; display: flex; align-items: center; justify-content: center; }
.cart-sidebar { position: fixed; top: 0; right: -450px; width: 450px; max-width: 100vw; height: 100vh; background: var(--blanco); color: var(--negro-atlas); z-index: 2000; box-shadow: -10px 0 30px rgba(0,0,0,0.5); transition: right 0.4s cubic-bezier(0.22, 1, 0.36, 1); display: flex; flex-direction: column; }
.cart-sidebar.open { right: 0; }
.cart-header { padding: 25px; background: var(--gris-claro); display: flex; justify-content: space-between; align-items: center; border-bottom: 1px solid #ddd; }
.close-cart { font-size: 1.5rem; cursor: pointer; color: var(--negro-atlas); transition: 0.3s; }
.close-cart:hover { color: var(--rojo-atlas); transform: rotate(90deg); }
.cart-items { padding: 25px; flex-grow: 1; overflow-y: auto; }
.cart-item-mock { display: flex; gap: 15px; margin-bottom: 25px; border-bottom: 1px solid #eee; padding-bottom: 20px; position: relative;}
.cart-item-img { width: 85px; height: 85px; background: #ddd; border-radius: 8px; flex-shrink: 0; background-size: cover; background-position: center;}
.cart-item-details { flex-grow: 1; display: flex; flex-direction: column; justify-content: center; }
.qty-control { display: inline-flex; align-items: center; border: 1px solid #ccc; border-radius: 6px; overflow: hidden; margin-top: 10px; width: fit-content;}
.qty-btn { background: #f9f9f9; border: none; padding: 5px 12px; font-weight: bold; cursor: pointer; transition: 0.3s; font-size: 1.1rem; color: #555;}
.qty-btn:hover { background: #e0e0e0; }
.qty-input { width: 35px; text-align: center; border: none; font-weight: bold; font-size: 1rem; color: var(--negro-atlas); outline: none; -moz-appearance: textfield;}
.remove-item { position: absolute; right: 0; top: 0; color: #aaa; cursor: pointer; font-size: 1.1rem; transition: 0.3s; }
.remove-item:hover { color: var(--rojo-atlas); }
.cart-footer { padding: 25px; border-top: 1px solid #ddd; background: #fafafa; }
.cart-total { display: flex; justify-content: space-between; font-size: 1.3rem; font-weight: 900; margin-bottom: 20px; }
.overlay { position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0,0,0,0.7); z-index: 1999; display: none; opacity: 0; transition: 0.3s; }
.overlay.show { display: block; opacity: 1; }

/* ==========================================================================
   Eliminación TOTAL del hueco negro entre Hero y Noticias
   ========================================================================== */
.hero { 
    position: relative; 
    height: 100vh; 
    display: flex; 
    align-items: center; 
    justify-content: center; 
    overflow: hidden; 
    background-color: var(--negro-atlas); 
    margin-bottom: 0 !important; 
    border-bottom: none !important;
}
.video-background { position: absolute; top: 50%; left: 50%; min-width: 100%; min-height: 100%; width: auto; height: auto; transform: translate(-50%, -50%); opacity: 0.6; pointer-events: none;}
.tv-effect { position: absolute; top: 0; left: 0; width: 100%; height: 100%; background: linear-gradient(rgba(0,0,0,0) 50%, rgba(0,0,0,0.25) 50%); background-size: 100% 4px; box-shadow: inset 0 0 150px #000; pointer-events: none;}
.hero-content { position: relative; z-index: 3; text-align: center; max-width: 800px; padding: 0 20px; }
.hero-content h1 { font-size: clamp(3rem, 6vw, 4.5rem); font-weight: 900; text-transform: uppercase; margin-bottom: 20px; text-shadow: 0 4px 15px rgba(0,0,0,0.8);}
.hero-content p { font-size: 1.1rem; margin-bottom: 35px; opacity: 0.9;}

section { padding: 90px 5%; }
.section-title { font-size: 2.2rem; text-align: center; margin-bottom: 50px; color: var(--blanco); }
.container { max-width: 1100px; margin: 0 auto; }

/* ==========================================================================
   CORRECCIÓN DEFINITIVA SECCIÓN NOTICIAS (Home)
   ========================================================================== */
.noticias-wrapper { 
    position: relative; 
    background-color: var(--negro-atlas); 
    overflow: hidden; 
    /* Margen negativo para asegurar que se fusione con el Hero sin huecos */
    margin-top: 0px !important; 
    padding-top: 0;
    z-index: 10;
}

.noticias-wrapper::before {
    content: '';
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background-image: url('https://academiaatlastuxtla.com/wp-content/uploads/2026/03/MG_3503-scaled.jpg');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    z-index: 1;
    pointer-events: none;
}

.noticias-wrapper::after {
    content: '';
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background: linear-gradient(to bottom, rgba(0,0,0,0.9), rgba(0,0,0,0.6));
    z-index: 2;
    pointer-events: none;
}

.noticias-wrapper .container { position: relative; z-index: 3; }
.noticia-card { background: rgba(20,20,20,0.9); border-radius: 12px; overflow: hidden; display: flex; flex-direction: column; transition: 0.4s; border: 1px solid rgba(255,255,255,0.05); backdrop-filter: blur(5px); position: relative; z-index: 3;}
.noticia-card:hover { transform: translateY(-10px); border-color: rgba(200,16,46,0.5); box-shadow: 0 15px 35px rgba(200,16,46,0.4); }
.noticia-img { width: 100%; height: 200px; background-size: cover; background-position: center; }
.noticia-body { padding: 25px; display: flex; flex-direction: column; flex-grow: 1; }
.noticia-tag { color: var(--rojo-intenso); font-weight: 900; text-transform: uppercase; font-size: 0.75rem; margin-bottom: 10px; display: block;}
.noticia-card h3 { font-size: 1.1rem; margin-bottom: 20px; line-height: 1.4; color: var(--blanco); }
.btn-leer-mas { margin-top: auto; align-self: flex-start; background: var(--rojo-atlas); color: white; padding: 8px 20px; border-radius: 4px; font-size: 0.8rem; font-weight: 700; text-transform: uppercase; transition: 0.3s;}
.btn-leer-mas:hover { background: var(--rojo-intenso); }

.noticias-grid-home { 
    display: grid; 
    grid-template-columns: 1fr;
    gap: 20px;
    margin: 0 auto;
    position: relative;
    z-index: 3;
}

@media (min-width: 600px) {
    .noticias-grid-home { 
        grid-template-columns: repeat(2, 1fr); 
        gap: 30px;
        max-width: 900px;
    }
    .noticias-grid-home .noticia-body { padding: 20px; }
    .noticias-grid-home .noticia-card h3 { font-size: 1rem; margin-bottom: 15px; }
}

/* --- Resto de las Secciones --- */
.partidos { background: radial-gradient(circle at center, #6e0a15 0%, var(--negro-atlas) 60%); }
.partido-widget { background: rgba(255,255,255,0.98); color: var(--negro-atlas); border-radius: 15px; padding: 40px; text-align: center; max-width: 700px; margin: 0 auto; box-shadow: 0 20px 40px rgba(0,0,0,0.6); position: relative; overflow: hidden; }
.linea-trace { position: absolute; background: var(--rojo-intenso); z-index: 10; }
.linea-top { top: 0; left: -100%; width: 100%; height: 7px; }
.linea-right { top: -100%; right: 0; width: 7px; height: 100%; }
.linea-bottom { bottom: 0; right: -100%; width: 100%; height: 7px; }
.linea-left { bottom: -100%; left: 0; width: 7px; height: 100%; }
.is-visible .linea-top { animation: traceTop 0.8s ease-in-out forwards; }
.is-visible .linea-right { animation: traceRight 0.8s ease-in-out 0.8s forwards; }
.is-visible .linea-bottom { animation: traceBottom 0.8s ease-in-out 1.6s forwards; }
.is-visible .linea-left { animation: traceLeft 0.8s ease-in-out 2.4s forwards; }
@keyframes traceTop { 0% { left: -100%; } 50% { left: 0; opacity: 1; } 100% { left: 100%; opacity: 0; } }
@keyframes traceRight { 0% { top: -100%; } 50% { top: 0; opacity: 1; } 100% { top: 100%; opacity: 0; } }
@keyframes traceBottom { 0% { right: -100%; } 50% { right: 0; opacity: 1; } 100% { right: 100%; opacity: 0; } }
@keyframes traceLeft { 0% { bottom: -100%; } 50% { bottom: 0; opacity: 1; } 100% { bottom: 100%; opacity: 0; } }
.partido-header { font-weight: 700; text-transform: uppercase; color: #777; margin-bottom: 20px; font-size: 0.9rem; position: relative; z-index: 2;}
.equipos { display: flex; justify-content: center; align-items: center; gap: 40px; margin-bottom: 30px; position: relative; z-index: 2;}
.equipo { display: flex; flex-direction: column; align-items: center; gap: 10px; font-weight: 900; text-transform: uppercase; font-size: 0.9rem;}
.equipo-logo { width: 70px; height: 70px; background-color: #eee; border-radius: 50%; }
.vs { font-size: 2rem; font-weight: 900; color: var(--rojo-atlas); }

.tienda { background-color: var(--gris-claro); color: var(--negro-atlas); }
.tienda .section-title { color: var(--negro-atlas); }
.productos-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 30px; }
.producto-card { background: var(--blanco); padding: 25px; border-radius: 15px; text-align: center; box-shadow: 0 5px 15px rgba(0,0,0,0.05); transition: 0.4s;}
.producto-card:hover { transform: translateY(-10px); box-shadow: 0 15px 30px rgba(0,0,0,0.1); }
.producto-img { width: 100%; height: 220px; background-color: #eee; background-size: cover; background-position: center; margin-bottom: 20px; border-radius: 8px; }
.producto-precio { color: var(--rojo-atlas); font-weight: 900; font-size: 1.2rem; display: block; margin-bottom: 15px;}

.jugador-mes { background-color: var(--negro-suave); overflow: hidden; padding: 60px 5%;}
.jugador-banner { position: relative; max-width: 1100px; margin: 0 auto; background: linear-gradient(135deg, #a02025 0%, #4a0d11 100%); border-radius: 20px; display: flex; align-items: center; overflow: hidden; box-shadow: 0 20px 50px rgba(0,0,0,0.6); min-height: 420px; }
.jugador-bg-text { position: absolute; font-size: clamp(6rem, 15vw, 12rem); font-weight: 900; color: rgba(255,255,255,0.04); top: 50%; left: 50%; transform: translate(-50%, -50%); white-space: nowrap; pointer-events: none; z-index: 1;}
.jugador-info { position: relative; z-index: 2; width: 55%; padding: 50px; }
.jugador-info h4 { font-size: 1.2rem; font-weight: 900; margin-bottom: 10px; color: rgba(255,255,255,0.8); text-transform: uppercase; letter-spacing: 2px;}
.jugador-info h2 { font-size: clamp(2.5rem, 5vw, 4rem); line-height: 1; margin-bottom: 40px; text-transform: none; }
.jugador-stats { display: flex; gap: 30px; flex-wrap: wrap; border-top: 1px solid rgba(255,255,255,0.2); padding-top: 20px; }
.stat-item h5 { font-size: 1.1rem; font-weight: 900; margin-bottom: 5px; color: var(--blanco); }
.stat-item p { font-size: 0.95rem; opacity: 0.9; color: #ddd; }
.jugador-img-container { position: absolute; z-index: 2; right: 0; bottom: 0; width: 50%; height: 100%; display: flex; justify-content: flex-end; align-items: flex-end; pointer-events: none;}
.jugador-img { height: 115%; width: auto; object-fit: contain; filter: drop-shadow(-15px 0px 25px rgba(0,0,0,0.6)); margin-right: 20px;}

.categorias { background-color: var(--negro-suave); }
.categorias-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 20px; }
.categoria-item { position: relative; height: 250px; background-color: #222; border-radius: 12px; overflow: hidden; display: flex; align-items: flex-end; padding: 20px; transition: 0.4s; cursor: pointer; }
.categoria-item:hover { transform: scale(1.03); box-shadow: 0 10px 30px rgba(200,16,46,0.3); }
.categoria-item::after { content: ''; position: absolute; bottom: 0; left: 0; width: 100%; height: 60%; background: linear-gradient(to top, rgba(0,0,0,0.9), transparent); z-index: 1; }
.categoria-item h3 { position: relative; z-index: 2; color: var(--blanco); font-size: 1.3rem; }

/* ==========================================================================
   --- 6. Patrocinadores Premium (Aumentados y con pausa on Hover) ---
   ========================================================================== */
.patrocinadores-section { padding: 50px 0; background-color: var(--negro-atlas); overflow: hidden; border-top: 1px solid #1a1a1a; border-bottom: 1px solid #1a1a1a;}
.marquee-wrapper { display: flex; width: 200vw; margin-bottom: 30px; }
.marquee-wrapper:last-child { margin-bottom: 0; }
.marquee-track { display: flex; width: 50%; justify-content: space-around; align-items: center; animation: scroll-left 25s linear infinite; }
.marquee-track.reverse { animation: scroll-right 25s linear infinite; }

/* PAUSAR ANIMACIÓN AL PASAR EL MOUSE */
.marquee-wrapper:hover .marquee-track {
    animation-play-state: paused;
}

.sponsor-link { display: inline-block; padding: 0 20px; }

/* LOGOS: Mucho más grandes y con opacidad por defecto (sin alterar el color base) */
.sponsor-logo { 
    height: 80px;  /* Aumentado de 50px a 80px */
    max-width: 250px; /* Aumentado de 180px a 250px */
    object-fit: contain; 
    opacity: 0.5; /* Mantenemos una opacidad suave para que se vean unificados */
    filter: grayscale(100%); /* Ayuda a que logos a color se vean neutros por defecto */
    transition: all 0.4s cubic-bezier(0.22, 1, 0.36, 1); 
}

/* Al pasar el mouse recuperan vida y color original */
.sponsor-link:hover .sponsor-logo { 
    opacity: 1; 
    filter: none; 
    transform: scale(1.15); 
}

@keyframes scroll-left { 0% { transform: translateX(0); } 100% { transform: translateX(-100%); } }
@keyframes scroll-right { 0% { transform: translateX(-100%); } 100% { transform: translateX(0); } }

/* --- 7. Footer Increíble --- */
footer { background-color: #050505; padding: 80px 50px 30px; border-top: 4px solid var(--rojo-atlas); }
.footer-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 40px; max-width: 1100px; margin: 0 auto 50px; }
.footer-col h3 { color: var(--blanco); font-size: 1.2rem; margin-bottom: 20px; }
.footer-col p, .footer-col ul li a { color: #888; font-size: 0.9rem; line-height: 1.8; transition: 0.3s; }
.footer-col ul { list-style: none; }
.footer-col ul li a:hover { color: var(--rojo-atlas); padding-left: 5px; }
.social-icons { display: flex; gap: 15px; margin-top: 20px; }
.social-icons a { display: flex; align-items: center; justify-content: center; width: 40px; height: 40px; background: #111; border-radius: 50%; color: var(--blanco); transition: 0.3s; }
.social-icons a:hover { background: var(--rojo-atlas); transform: translateY(-5px); }
.footer-bottom { text-align: center; padding-top: 30px; border-top: 2px solid #9fa3a9; color: #9fa3a9; font-size: 0.9rem; }

/* ==========================================================================
   ESTILOS DE TIPOGRAFÍA PROFESIONAL PARA CONTENIDO DE NOTICIAS 
   ========================================================================== */
.contenido-post p {
    font-size: 1.1rem;
    line-height: 1.8;
    margin-bottom: 20px;
    color: #ddd;
}
.contenido-post ul {
    margin-bottom: 20px;
    padding-left: 20px;
    color: #ddd;
}
.contenido-post li {
    margin-bottom: 10px;
}
.contenido-post h2, .contenido-post h3, .contenido-post h4 {
    margin-top: 40px;
    margin-bottom: 20px;
    color: var(--blanco);
    font-weight: 900;
}
.contenido-post blockquote {
    border-left: 4px solid var(--rojo-atlas);
    padding: 20px;
    font-style: italic;
    color: #bbb;
    background: rgba(255,255,255,0.02);
    margin-bottom: 25px;
    border-radius: 0 8px 8px 0;
}
.contenido-post img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    margin-bottom: 25px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.5);
}

@media (max-width: 768px) {
    .menu-toggle { display: block; }
    nav { position: fixed; top: 75px; left: -100%; width: 100%; height: calc(100vh - 75px); background: rgba(10,10,10,0.98); flex-direction: column; padding: 40px 20px; transition: 0.3s; overflow-y: auto; }
    nav.active { left: 0; }
    nav ul { flex-direction: column; width: 100%; gap: 15px; }
    nav ul li { width: 100%; text-align: center; }
    .submenu { position: relative; top: 0; box-shadow: none; background: transparent; display: none; }
    nav > ul > li:hover .submenu { display: block; }
    .jugador-banner { flex-direction: column; text-align: center; }
    .jugador-info { width: 100%; padding: 30px 20px; }
    .jugador-stats { justify-content: center; }
    .jugador-img-container { position: relative; width: 100%; height: 350px; }
    .jugador-img { height: 350px; }
    .cart-sidebar { width: 100%; right: -100%; }
}
/* ==========================================================================
   CORRECCIONES DE ÚLTIMA HORA (LOGO Y SEPARACIÓN)
   ========================================================================== */

/* 1. Solución Definitiva al Logo Cortado */
.logo-img {
    width: auto !important;
    max-width: 250px !important;
    height: 55px !important; /* Le da más altura para que luzca */
    object-fit: contain !important; /* Evita cualquier recorte */
}

/* 2. Solución al Hueco de Separación */
/* Esto elimina los párrafos o saltos de línea invisibles que inyecta WordPress */
.hero + p, 
.hero + br, 
.noticias-wrapper > p:empty, 
.noticias-wrapper > br {
    display: none !important;
    margin: 0 !important;
    padding: 0 !important;
    height: 0 !important;
}

/* Forzamos la unión de las capas */
.noticias-wrapper {
    margin-top: -5px !important; /* Muerde ligeramente el borde superior */
    position: relative !important;
    z-index: 50 !important; /* Se asegura de montarse sobre el video */
}

.hero {
    margin-bottom: 0 !important;
    padding-bottom: 0 !important;
}