*, *::before, *::after { box-sizing: border-box; }

html, body {
    background-color: #000000 !important;
    color: #f8fafc !important;
    margin: 0;
    padding: 0;
    font-family: 'Poppins', system-ui, -apple-system, sans-serif;
    text-rendering: optimizeLegibility;
    overflow-x: hidden;
}

header {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 10px;
    padding: 10px 14px;
    height: auto;
    min-height: 58px;
    background-color: #000000;
    border-bottom: 1px solid rgba(124, 58, 237, 0.2);
    position: sticky;
    top: 0;
    z-index: 500;
}

/* Contenedor derecho del header para alinear categorías, búsqueda y botones de login */
.header-right {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    justify-content: flex-end;
}

/* --- Botón de Categorías en Header (Cyberpunk Refinado) --- */
.header-categories-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, rgba(124, 58, 237, 0.25), rgba(0, 240, 255, 0.15));
    color: #60a5fa !important;
    border: 1px solid rgba(0, 240, 255, 0.5);
    padding: 6px 14px;
    border-radius: 8px;
    font-size: 0.75rem;
    font-weight: 600;
    text-decoration: none;
    letter-spacing: 0.3px;
    cursor: pointer;
    box-shadow: 0 0 10px rgba(0, 240, 255, 0.2), inset 0 0 6px rgba(124, 58, 237, 0.2);
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    white-space: nowrap;
}
.header-categories-btn:hover {
    background: linear-gradient(135deg, rgba(124, 58, 237, 0.4), rgba(0, 240, 255, 0.3));
    color: #ffffff !important;
    border-color: rgba(0, 240, 255, 0.8);
    box-shadow: 0 0 18px rgba(0, 240, 255, 0.45), 0 0 8px rgba(124, 58, 237, 0.5);
    transform: translateY(-1px);
}

.header-search {
    flex: 0 1 120px;
}

.header-search input {
    background: #090a14;
    border: 1px solid rgba(0, 240, 255, 0.35);
    box-shadow: 0 0 10px rgba(124, 58, 237, 0.2);
    color: #ffffff !important;
    padding: 6px 10px;
    border-radius: 6px;
    font-size: 0.8rem;
    outline: none;
    width: 100%;
    transition: all 0.3s ease;
}

.header-search input:focus {
    max-width: 160px;
}
.header-search input::placeholder {
    color: #94a3b8;
}

/* Espacio opcional para futuros botones de login/auth en el header */
.header-auth-buttons {
    display: flex;
    align-items: center;
    gap: 6px;
}

/* --- Full-bleed Blended Hero Banner --- */
.hero-banner {
    position: relative;
    overflow: hidden;
    margin: 0;
    width: 100%;
    min-height: 290px;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 20px;
    background: #000000;
    border: none;
    box-shadow: none;
}

.hero-banner > img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: 0;
    filter: brightness(0.65) contrast(1.1);
}

.hero-banner > div:nth-child(2) {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to top, #000000 8%, rgba(0,0,0,0.85) 50%, rgba(9,10,20,0.2) 100%),
                linear-gradient(to right, rgba(0,0,0,0.85) 0%, transparent 40%, transparent 60%, rgba(0,0,0,0.85) 100%);
    z-index: 1;
    pointer-events: none;
}

/* Logo en la esquina izquierda del banner */
.hero-logo-container {
    position: absolute;
    top: 15px;
    left: 16px;
    z-index: 3;
}
.hero-logo-container img {
    height: 28px;
    width: auto;
    max-width: 110px;
    display: block;
    filter: drop-shadow(0 2px 6px rgba(0,0,0,0.9));
}

#hero-contenido {
    z-index: 2;
    position: relative;
    padding-top: 45px;
}

.hero-tag {
    color: #a78bfa;
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    margin-bottom: 6px;
    text-shadow: 0 0 8px rgba(124, 58, 237, 0.9);
}

.hero-title {
    font-size: 1.35rem;
    margin: 0 0 8px 0;
    color: #ffffff !important;
    line-height: 1.15;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.9), 0 0 12px rgba(0, 240, 255, 0.5);
}

.hero-meta {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.8rem;
    color: #f1f5f9;
    margin-bottom: 14px;
    flex-wrap: wrap;
    text-shadow: 0 1px 4px rgba(0,0,0,0.9);
}

.hero-badge-airing {
    background: rgba(124, 58, 237, 0.35);
    border: 1px solid rgba(167, 139, 250, 0.8);
    color: #ffffff;
    padding: 3px 10px;
    border-radius: 999px;
    font-size: 0.75rem;
    box-shadow: 0 0 10px rgba(124, 58, 237, 0.4);
}

.hero-actions {
    display: flex;
    gap: 10px;
    z-index: 3;
    flex-wrap: wrap;
}

.btn-hero-primary {
    background: linear-gradient(135deg, #2563eb, #7c3aed);
    color: #ffffff !important;
    border: none;
    padding: 9px 18px;
    border-radius: 999px;
    font-weight: 600;
    font-size: 0.8rem;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    box-shadow: 0 0 15px rgba(37, 99, 235, 0.5);
    text-decoration: none;
}

.btn-hero-secondary {
    background: rgba(9, 10, 20, 0.9);
    color: #60a5fa !important;
    border: 1px solid rgba(0, 240, 255, 0.5);
    padding: 9px 18px;
    border-radius: 999px;
    font-weight: 600;
    font-size: 0.8rem;
    display: inline-flex;
    align-items: center;
    cursor: pointer;
    box-shadow: inset 0 0 10px rgba(0, 240, 255, 0.15);
    text-decoration: none;
}

#hero-dots {
    position: absolute;
    bottom: 14px;
    right: 20px;
    display: flex;
    gap: 6px;
    z-index: 3;
}
.hero-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: rgba(255,255,255,0.3);
    cursor: pointer;
}
.hero-dot.active {
    width: 20px;
    border-radius: 4px;
    background: #60a5fa;
    box-shadow: 0 0 8px #60a5fa;
}

/* --- Cyberpunk Grid Sections (Móvil base) --- */
.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 16px;
    margin: 22px 0 10px 0;
}
.section-title {
    font-size: 1rem;
    font-weight: 700;
    color: #60a5fa;
    text-shadow: 0 0 8px rgba(96, 165, 250, 0.4);
    margin: 0;
}
.btn-ver-todo {
    background: rgba(9, 10, 20, 0.8);
    border: 1px solid rgba(0, 240, 255, 0.4);
    color: #60a5fa;
    font-size: 0.7rem;
    font-weight: 600;
    padding: 5px 12px;
    border-radius: 6px;
    cursor: pointer;
}
.cyber-horizontal-scroll {
    display: flex;
    gap: 12px;
    overflow-x: auto;
    padding: 5px 16px 15px 16px;
    scroll-snap-type: x mandatory;
    min-height: 200px;
}
.cyber-horizontal-scroll::-webkit-scrollbar { display: none; }

.cyber-card {
    flex: 0 0 125px;
    scroll-snap-align: start;
    display: flex;
    flex-direction: column;
    background: #090a14;
    border-radius: 10px;
    border: 1px solid rgba(124, 58, 237, 0.35);
    box-shadow: 0 0 12px rgba(124, 58, 237, 0.15);
    overflow: hidden;
    text-decoration: none;
    color: inherit;
}
.cyber-card-poster {
    position: relative;
    aspect-ratio: 2 / 3;
    width: 100%;
    background: #000000;
    overflow: hidden;
}
.cyber-card-poster img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* --- Etiquetas y Badges de Cards --- */
.cyber-tag-new {
    position: absolute;
    top: 5px;
    left: 5px;
    background: rgba(9, 10, 20, 0.85);
    color: #a78bfa;
    border: 1px solid rgba(167, 139, 250, 0.6);
    font-size: 0.6rem;
    font-weight: 700;
    padding: 2px 6px;
    border-radius: 4px;
    z-index: 2;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    backdrop-filter: blur(4px);
    box-shadow: 0 2px 6px rgba(0,0,0,0.8);
}

.cyber-badge-score {
    position: absolute;
    bottom: 5px;
    right: 5px;
    background: rgba(9, 10, 20, 0.85);
    color: #facc15;
    border: 1px solid rgba(250, 204, 21, 0.5);
    font-size: 0.65rem;
    font-weight: 700;
    padding: 2px 5px;
    border-radius: 4px;
    z-index: 2;
    backdrop-filter: blur(4px);
    box-shadow: 0 2px 6px rgba(0,0,0,0.8);
}

.cyber-card-body {
    padding: 6px;
    display: flex;
    flex-direction: column;
    gap: 3px;
}
.cyber-card-title {
    font-size: 0.75rem;
    font-weight: 600;
    color: #f8fafc;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.cyber-card-sub {
    font-size: 0.65rem;
    color: #94a3b8;
}

/* --- Footer & Social --- */
footer {
    text-align: center;
    padding: 25px 16px;
    color: #94a3b8;
    font-size: 0.75rem;
    border-top: 1px solid rgba(124, 58, 237, 0.25);
    margin-top: 30px;
    background-color: #000000;
}
.footer-social-buttons {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-bottom: 12px;
    flex-wrap: wrap;
}
.btn-social-footer {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 6px 14px;
    font-size: 0.75rem;
    font-weight: 500;
    text-decoration: none;
    border-radius: 5px;
    color: white !important;
}
.btn-telegram-footer { background-color: #229ed9; }
.btn-tiktok-footer { background-color: #090a14; border: 1px solid #334155; }

/* ==========================================================
   VERSION ESCRITORIO (PC / Desktop >= 768px y >= 1024px)
   ================================================---------- */
@media (min-width: 768px) {
    header {
        padding: 12px 36px;
        height: 65px;
    }
    .hero-logo-container {
        top: 20px;
        left: 24px;
    }
    .hero-logo-container img {
        height: 35px;
        max-width: 130px;
    }
    .header-right {
        gap: 14px;
    }
    .header-categories-btn {
        font-size: 0.85rem;
        padding: 8px 20px;
    }
    .header-search {
        flex: 0 1 160px;
    }
    .header-search input {
        font-size: 0.9rem;
        padding: 9px 14px;
    }
    .header-search input:focus {
        max-width: 210px;
    }
    .hero-banner {
        min-height: 420px;
        padding: 40px 48px;
    }
    .hero-title {
        font-size: 2.2rem;
    }
    .hero-meta {
        font-size: 0.95rem;
        gap: 16px;
    }
    .btn-hero-primary, .btn-hero-secondary {
        font-size: 0.9rem;
        padding: 11px 24px;
    }
    .section-header {
        padding: 0 36px;
        margin: 32px 0 16px 0;
    }
    .section-title {
        font-size: 1.35rem;
    }
    .cyber-horizontal-scroll {
        padding: 5px 36px 20px 36px;
        gap: 18px;
        min-height: 250px;
    }
    .cyber-card {
        flex: 0 0 160px;
        border-radius: 12px;
    }
    .cyber-card-body {
        padding: 10px;
    }
    .cyber-card-title {
        font-size: 0.85rem;
    }
}

@media (min-width: 1024px) {
    main {
        max-width: 1400px;
        margin: 0 auto;
    }
    .hero-banner {
        min-height: 480px;
        border-radius: 0 0 16px 16px;
    }
    .cyber-card {
        flex: 0 0 175px;
        transition: transform 0.25s cubic-bezier(0.4, 0, 0.2, 1), box-shadow 0.25s ease;
    }
    .cyber-card:hover {
        transform: translateY(-5px);
        box-shadow: 0 8px 24px rgba(124, 58, 237, 0.35);
        border-color: rgba(0, 240, 255, 0.7);
    }
}


/* Ajustes para contenedor de carrusel horizontal limpio */
.cyber-horizontal-scroll {
    display: flex !important;
    flex-direction: row !important;
    gap: 12px !important;
    overflow-x: auto !important;
    padding: 8px 12px !important;
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch;
}

.cyber-horizontal-scroll::-webkit-scrollbar {
    display: none;
}
