/* 1. VARIABLES Y CONFIGURACIÓN GLOBAL */
:root {
    --purple-main: #8b5cf6;
    --purple-dark: #7c3aed;
    --dark-bg: #09090b;
    --darker-bg: #060608;
    --card-bg: #141418;
    --border-soft: rgba(255, 255, 255, 0.1);
    --text-main: #ffffff;
    --text-dim: #a1a1aa;
    --transition: all 0.3s ease;
}

html, body {
    overflow-x: hidden;
    width: 100%;
}

body {
    font-family: 'Plus Jakarta Sans', sans-serif;
    background-color: var(--dark-bg);
    color: var(--text-main);
}

/* 2. UTILIDADES GENERALES */
.text-purple {
    background: linear-gradient(45deg, #8b5cf6, #d8b4fe);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    font-weight: 800;
}

.bg-darker { background-color: var(--darker-bg); }
.text-dim { color: var(--text-dim); }
.extra-small { font-size: 0.75rem; }
.fw-800 { font-weight: 800; }

img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* 3. NAVBAR PREMIUM */
.navbar {
    background-color: rgba(9, 9, 11, 0.85);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border-soft);
    z-index: 1050;
}

.nav-link { 
    color: var(--text-dim) !important; 
    font-size: 0.9rem; 
    transition: var(--transition);
}

.nav-link:hover { color: var(--text-main) !important; }

/* Buscador Estilizado */
.search-group, .newsletter-group {
    display: flex;
    background: #1a1a20;
    border: 1px solid var(--border-soft);
    border-radius: 8px;
    padding: 2px;
    transition: var(--transition);
}

.search-group:focus-within, .newsletter-group:focus-within {
    border-color: var(--purple-main);
    box-shadow: 0 0 10px rgba(139, 92, 246, 0.2);
}

.search-input, .newsletter-input {
    background: transparent !important;
    border: none !important;
    color: white !important;
    box-shadow: none !important;
    font-size: 0.9rem;
}

.search-input::placeholder, .newsletter-input::placeholder { color: #52525b; }

.search-btn {
    background: transparent;
    border: none;
    padding: 5px 15px;
    cursor: pointer;
    opacity: 0.7;
    transition: var(--transition);
}

.search-btn:hover { opacity: 1; transform: scale(1.1); }

/* 4. HERO SECTION */
.hero-section {
    position: relative;
    overflow: hidden;
    width: 100%;
    min-height: 60vh;
    display: flex;
    align-items: center;
}

/* Filtro oscuro para legibilidad */
.hero-section::before {
    content: "";
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background-color: rgba(0, 0, 0, 0.6); /* Ajustado a 0.6 para mejor lectura */
    z-index: 1;
}

.hero-section .container {
    position: relative;
    z-index: 2;
}

.hero-section h1 {
    letter-spacing: -2px;
    line-height: 1.1;
}

.glow-bg {
    position: absolute;
    top: -20%;
    right: -10%;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(139, 92, 246, 0.15) 0%, rgba(9, 9, 11, 0) 70%);
    z-index: 0;
    pointer-events: none;
}

/* 5. CARDS Y COMPONENTES */
.bg-card {
    background-color: var(--card-bg) !important;
    border: 1px solid var(--border-soft) !important;
    border-radius: 16px;
    transition: var(--transition);
}

.bg-card:hover {
    transform: translateY(-8px);
    border-color: var(--purple-main) !important;
}

/* Imagenes fijas para que no se rompa el diseño */
.card img, .comp-card img, .blog-card img {
    width: 100%;
    aspect-ratio: 16 / 9;
    object-fit: cover;
    border-radius: 12px;
}

/* Botón Corazón Favoritos */
.btn-heart {
    position: absolute; top: 12px; right: 12px;
    background: rgba(255, 255, 255, 0.05); border: none; border-radius: 50%;
    width: 36px; height: 36px; display: flex; align-items: center; justify-content: center;
    cursor: pointer; z-index: 5; fill: #52525b; transition: var(--transition);
}

.btn-heart:hover { transform: scale(1.1); background: rgba(255,255,255,0.1); }
.btn-heart.active {
    fill: #ef4444 !important;
    background: rgba(239, 68, 68, 0.1) !important;
    filter: drop-shadow(0 0 5px rgba(239, 68, 68, 0.5));
}

/* Botones */
.btn-purple {
    background-color: var(--purple-main);
    color: white;
    border: none;
    font-weight: 600;
    transition: var(--transition);
}

.btn-purple:hover {
    background-color: var(--purple-dark);
    color: white;
    box-shadow: 0 5px 15px rgba(139, 92, 246, 0.3);
}

/* Categorías */
.cat-card {
    background-color: var(--card-bg);
    border: 1px solid var(--border-soft);
    border-radius: 12px;
    padding: 15px;
    text-align: center;
    color: var(--text-dim);
    transition: var(--transition);
    cursor: pointer;
}
.cat-card:hover { border-color: var(--purple-main); color: var(--text-main); }

/* 6. PUBLICIDAD Y OTROS */
.ad-box-horizontal { 
    height: 90px; 
    background-color: transparent;
    display: flex; align-items: center; justify-content: center;
}

.ad-banner-premium {
    background: linear-gradient(90deg, #141418 0%, #20133c 100%);
    border: 1px solid var(--purple-main);
    border-radius: 20px;
    min-height: 180px;
    position: relative;
    overflow: hidden;
}

.icon-circle {
    width: 50px; height: 50px;
    border: 2px solid var(--purple-main);
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    color: var(--text-main); font-weight: bold; font-size: 1.2rem;
}

/* Newsletter */
.newsletter-card {
    background: #0d0d0f;
    border: 1px solid var(--border-soft);
    border-radius: 24px;
    overflow: hidden;
}

.mail-icon {
    background: rgba(139, 92, 246, 0.1);
    width: 70px; height: 70px; border-radius: 16px;
    display: flex; align-items: center; justify-content: center;
}

/* 7. FOOTER */
.social-icon {
    font-size: 1.2rem;
    color: var(--text-dim);
    transition: var(--transition);
    text-decoration: none;
}

.social-icon:hover {
    color: var(--purple-main) !important;
    transform: translateY(-3px);
}

footer a {
    transition: var(--transition);
}

/* 8. MEDIA QUERIES */
@media (max-width: 991px) {
    .navbar-nav {
        padding-top: 1rem;
        border-top: 1px solid var(--border-soft);
        margin-top: 1rem;
    }
    .hero-section h1 { font-size: 2.5rem; }
}

.card-title-custom {
    display: -webkit-box;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    min-height: 2.5rem; /* Mantiene el hueco aunque el título sea corto */
}

/* EFECTO GLASSMORPHISM Y GLOW */
.bg-glass {
    background: rgba(20, 20, 24, 0.7) !important;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(139, 92, 246, 0.2) !important;
}

.bg-glass:hover {
    border-color: var(--purple-main) !important;
    box-shadow: 0 0 25px rgba(139, 92, 246, 0.2);
}

/* BADGES ESPECIALES */
.badge-price-leader {
    background-color: #06b6d4; /* Cian brillante */
    color: #000;
    font-weight: 700;
    font-size: 0.65rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.text-old-price {
    text-decoration: line-through;
    color: var(--text-dim);
    font-size: 0.85rem;
}

/* TARJETAS CLICKEABLES */
.card-clickable {
    transition: var(--transition);
    cursor: pointer;
}

.card-clickable:hover {
    transform: translateY(-5px);
    border-color: var(--purple-main) !important;
    box-shadow: 0 8px 20px rgba(139, 92, 246, 0.2);
}

.card-clickable:active {
    transform: translateY(-2px);
}

.bg-purple-dark {
    background-color: rgb(13, 3, 37) !important;
}

.bg-purple-dark:hover {
    background-color: rgb(20, 5, 50) !important;
    box-shadow: 0 0 15px rgba(139, 92, 246, 0.3);
}

.featured-card {
    background-color: rgb(13, 3, 37) !important;
    border: 1px solid rgba(139, 92, 246, 0.25);
    border-radius: 24px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.featured-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 30px 60px rgba(139, 92, 246, 0.18);
}

.featured-card .card-img-top {
    height: 280px;
    object-fit: cover;
}

.badge-featured {
    background: rgba(139, 92, 246, 0.95);
    color: white;
    border: 1px solid rgba(255, 255, 255, 0.15);
    padding: 0.6rem 0.85rem;
    font-size: 0.75rem;
}

.overlay-title {
    text-shadow: 0 0 20px rgba(0, 0, 0, 0.5);
}

.object-fit-cover {
    object-fit: cover !important;
}

@media (min-width: 992px) {
    .featured-article-card .img-fluid {
        min-height: 280px;
    }
}

/* PUBLICIDAD MODERNA */
.ad-placeholder-modern {
    width: 100%;
    height: 100%;
    background: repeating-linear-gradient(
        45deg,
        rgba(139, 92, 246, 0.03),
        rgba(139, 92, 246, 0.03) 10px,
        rgba(9, 9, 11, 0.05) 10px,
        rgba(9, 9, 11, 0.05) 20px
    );
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px dashed rgba(139, 92, 246, 0.3);
    border-radius: 12px;
}

.ad-label-modern {
    color: var(--purple-main);
    letter-spacing: 2px;
    font-weight: 600;
    opacity: 0.6;
}

/* Efecto para los Banners de Xyberoom */
.ad-banner-img {
    transition: transform 0.3s ease, filter 0.3s ease;
    cursor: pointer;
}

.ad-banner-img:hover {
    transform: scale(1.01); /* Crece apenas un poquito */
    filter: brightness(1.2) drop-shadow(0 0 15px var(--purple-main));
}

/* ANIMACIONES */
.pulse-animation {
    animation: pulse-red 2s infinite;
}

@keyframes pulse-red {
    0% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(239, 68, 68, 0.7); }
    70% { transform: scale(1); box-shadow: 0 0 0 10px rgba(239, 68, 68, 0); }
    100% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(239, 68, 68, 0); }
}

/* CHIPS DE FILTRO */
.btn-outline-purple {
    border-color: var(--purple-main);
    color: var(--purple-main);
}
.btn-outline-purple:hover {
    background-color: var(--purple-main);
    color: white;
}

.text-gradient-purple {
    background: linear-gradient(90deg, #a855f7, #6366f1);
    background-clip: text;
    text-emphasis-color: transparent;
}

.shadow-purple {
    box-shadow: 0 10px 30px -10px rgba(168, 85, 247, 0.5);
}

.floating-animation {
    animation: floating 3s ease-in-out infinite;
}

@keyframes floating {
    0% { transform: translateY(0px); }
    50% { transform: translateY(-20px); }
    100% { transform: translateY(0px); }
}


/*PAGES CATEGORIAS*/

/* VARIABLES Y COLORES */
    :root {
        --neon-violet: #8a2be2; /* Violeta Neón Principal */
        --neon-violet-dim: rgba(138, 43, 226, 0.15);
        --bg-black: #0a0a0a; /* Negro Profundo */
        --border-color: rgba(255, 255, 255, 0.1);
    }

    .fs-huge { font-size: 5rem; }
    .uppercase { text-transform: uppercase; }
    .tracking-widest { letter-spacing: 0.2em; }
    .text-shadow-violet { text-shadow: 0 0 15px var(--neon-violet); }
    .opacity-05 { opacity: 0.05; }

    /* TEXTURA DE FONDO (Opcional, líneas tipo terminal) */
    .cyber-lines {
        background-image: linear-gradient(var(--border-color) 1px, transparent 1px), 
                          linear-gradient(90deg, var(--border-color) 1px, transparent 1px);
        background-size: 50px 50px;
    }

    /* CONTENEDOR IZQUIERDO */
    .cyber-brain-container {
        background: linear-gradient(145deg, #111, #080808);
        box-shadow: 10px 10px 20px #050505, -10px -10px 20px #151515;
    }
    .border-neon-violet {
        border: 2px solid var(--neon-violet) !important;
        box-shadow: 0 0 20px var(--neon-violet-dim);
    }

    /* EFECTO GLITCH PARA EL ÍCONO */
    .glitch-wrapper {
        position: relative;
    }
    .glitch {
        position: relative;
        animation: glitch-anim 2.5s infinite linear alternate-reverse;
    }
    .glitch::before, .glitch::after {
        content: attr(data-text);
        position: absolute;
        top: 0; left: 0; width: 100%; height: 100%;
        opacity: 0.8;
    }
    .glitch::before {
        color: #ff00ff; /* Magenta glitch */
        animation: glitch-anim-2 3s infinite linear alternate-reverse;
        left: 2px;
    }
    .glitch::after {
        color: #00ffff; /* Cyan glitch */
        animation: glitch-anim 2s infinite linear alternate-reverse;
        left: -2px;
    }
    @keyframes glitch-anim {
        0% { clip-path: inset(80% 0 5% 0); }
        20% { clip-path: inset(20% 0 15% 0); }
        40% { clip-path: inset(50% 0 30% 0); }
        60% { clip-path: inset(10% 0 70% 0); }
        80% { clip-path: inset(90% 0 2% 0); }
        100% { clip-path: inset(5% 0 85% 0); }
    }
    @keyframes glitch-anim-2 {
        0% { clip-path: inset(10% 0 70% 0); }
        100% { clip-path: inset(90% 0 2% 0); }
    }

    /* PANEL DE CONTROL DERECHO */
    .cyber-panel-card {
        background: rgba(15, 15, 15, 0.8) !important;
        border: 1px solid var(--border-color) !important;
        border-radius: 15px;
        backdrop-filter: blur(10px);
        position: relative;
        box-shadow: 0 10px 30px rgba(0,0,0,0.8);
    }
    
    /* ESQUINAS SCI-FI */
    .cyber-corner {
        position: absolute;
        width: 30px; height: 30px;
        border: 3px solid var(--neon-violet);
        opacity: 0.7;
    }
    .cyber-corner.top-left { top: -5px; left: -5px; border-right: none; border-bottom: none; border-top-left-radius: 10px; }
    .cyber-corner.bottom-right { bottom: -5px; right: -5px; border-left: none; border-top: none; border-bottom-right-radius: 10px; }

    /* INPUTS CYBERPUNK */
    .cyber-input-group {
        position: relative;
    }
    .form-control-cyber {
        background-color: transparent !important;
        border: none !important;
        border-bottom: 2px solid var(--border-color) !important;
        color: white !important;
        border-radius: 0 !important;
        padding-left: 0 !important;
        transition: 0.3s;
    }
    .form-control-cyber:focus {
        box-shadow: none !important;
        border-bottom-color: var(--neon-violet) !important;
    }
    .form-floating > .form-control-cyber:focus ~ label,
    .form-floating > .form-control-cyber:not(:placeholder-shown) ~ label {
        color: var(--neon-violet) !important;
        transform: scale(0.85) translateY(-1rem) translateX(-0.5rem) !important;
    }
    /* Línea animada inferior al hacer focus */
    .input-line {
        position: absolute;
        bottom: 0; left: 50%;
        width: 0; height: 2px;
        background-color: var(--neon-violet);
        transition: 0.4s ease;
        box-shadow: 0 0 10px var(--neon-violet);
    }
    .form-control-cyber:focus ~ .input-line {
        width: 100%;
        left: 0;
    }

    /* BOTÓN EJECUTAR */
    .btn-cyber-violet {
        background-color: transparent;
        border: 2px solid var(--neon-violet);
        color: var(--neon-violet);
        border-radius: 50px;
        transition: 0.3s;
        box-shadow: 0 0 15px var(--neon-violet-dim);
    }
    .btn-cyber-violet:hover {
        background-color: var(--neon-violet);
        color: black;
        box-shadow: 0 0 30px var(--neon-violet);
    }
    /* Efecto glitch de fondo en hover */
    .btn-bg-glitch {
        position: absolute;
        top: 0; left: -100%; width: 100%; height: 100%;
        background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
        transition: 0.5s;
    }
    .btn-cyber-violet:hover .btn-bg-glitch {
        left: 100%;
    }

    /*ESTADO DE SOPORTE HUMANO */

    .status-dot {
    width: 10px;
    height: 10px;
    background-color: #7700ff;
    border-radius: 50%;
    box-shadow: 0 0 10px #ce51ff;
    animation: pulse-green 2s infinite;
}
@keyframes pulse-green {
    0% { transform: scale(0.95); box-shadow: 0 0 0 0 rgb(153, 0, 255); }
    70% { transform: scale(1); box-shadow: 0 0 0 10px rgba(0, 255, 136, 0); }
    100% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(0, 255, 136, 0); }
}

.custom-nav-link {
    color: #8a2be2 !important; /* Violeta Neón */
    font-weight: bold;
    letter-spacing: 1px;
    transition: 0.3s;
    border: 1px solid transparent;
    border-radius: 20px;
    padding: 5px 15px !important;
}

.custom-nav-link:hover {
    color: #fff !important;
    background: rgba(138, 43, 226, 0.2);
    border-color: #8a2be2;
    text-shadow: 0 0 8px #8a2be2;
    box-shadow: 0 0 10px rgba(138, 43, 226, 0.3);
}

/* Animación de pulso para el ícono del radar */
.neon-pulse {
    animation: pulse-violet 2s infinite;
}

@keyframes pulse-violet {
    0% { opacity: 1; }
    50% { opacity: 0.5; }
    100% { opacity: 1; }
}

/*MEGA CARDS*/

.precioMasBajo {
    display: flex;
    gap: 20px;
    width: 100%;
    max-width: 1200px;
    margin: 20px auto 40px auto;
    padding: 10px;
}

/* Mega Card Estilo Pro */
.mega-card {
    flex: 1;
    background: linear-gradient(145deg, #0f0f0f, #1a1a1a);
    border: 2px solid #a855f7; /* Violeta Neón */
    border-radius: 12px;
    position: relative;
    overflow: hidden;
    box-shadow: 0 0 15px rgba(168, 85, 247, 0.3);
    transition: 0.4s ease;
}

.mega-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 0 25px rgba(168, 85, 247, 0.6);
    border-color: #bc77ff;
}

.mega-card-body {
    display: flex;
    align-items: center;
    padding: 25px;
    gap: 20px;
}

.mega-img img {
    width: 140px;
    height: 140px;
    object-fit: contain;
    filter: drop-shadow(0 0 8px rgba(168, 85, 247, 0.4));
}

.mega-info h3 {
    color: #fff;
    font-size: 1.4rem;
    margin: 5px 0;
}

.label-top {
    color: #a855f7;
    font-size: 0.7rem;
    font-weight: bold;
    letter-spacing: 2px;
}

.precios-bloque {
    display: flex;
    flex-direction: column;
    margin: 10px 0;
}

.old-price {
    color: #666666;
    text-decoration: line-through;
    font-size: 0.9rem;
}

.current-price {
    color: #62cfab; /* Cian Neón */
    font-size: 2.2rem;
    font-weight: 900;
}

.tag-oferta {
    position: absolute;
    top: 30px;
    right: -40px;
    background: #ff0000;
    color: rgb(255, 255, 255);
    padding: 5px 40px;
    font-size: 0.7rem;
    font-weight: bold;
    transform: rotate(45deg);
    box-shadow: 0 0 10px rgba(255, 0, 85, 0.5);
    text-align: center;
}

.tag-mas-bajo {
    position: absolute;
    top: 30px;
    right: -40px;
    background: rgba(98, 207, 171, 0.12);
    color: #62cfab;
    border: 1px solid rgba(98, 207, 171, 0.35);
    padding: 5px 40px;
    font-size: 0.7rem;
    font-weight: bold;
    transform: rotate(45deg);
    box-shadow: 0 0 10px rgba(98, 207, 171, 0.15);
    text-align: center;
}

.btn-xyber {
    display: inline-block;
    margin-top: 10px;
    padding: 10px 20px;
    background: transparent;
    border: 1px solid #a855f7;
    color: #a855f7;
    text-decoration: none;
    font-weight: bold;
    border-radius: 5px;
    transition: 0.3s;
}

.btn-xyber:hover {
    background: #a855f7;
    color: #fff;
}

/* Responsivo para el anuncio de TikTok (Mobile) */
@media (max-width: 768px) {
    .precioMasBajo {
        flex-direction: column;
    }
    .mega-card-body {
        flex-direction: column;
        text-align: center;
    }
}

/* GRID DE DECORACIÓN */

/* Contenedor del Mosaico */
.xyber-mosaic {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    grid-auto-rows: 200px; /* Altura de cada celda base */
    grid-auto-flow: dense; /* Rellena huecos automáticamente */
    gap: 15px;
}

/* Estilo de cada Celda */
.mosaic-item {
    position: relative;
    overflow: hidden;
    border-radius: 12px;
    border: 1px solid #7a00ff; /* Púrpura Xyberoom */
    box-shadow: 0 4px 15px rgba(122, 0, 255, 0.2);
}

.mosaic-item img {
    width: 100%;
    height: 100%;
    object-fit: cover; /* Recorta la imagen para llenar el espacio sin estirarse */
    transition: transform 0.5s ease, filter 0.3s ease;
    display: block;
}

.mosaic-item:hover img {
    transform: scale(1.1);
    filter: brightness(1.1);
}

/* Variaciones de tamaño para el efecto irregular */
.mosaic-item.big {
    grid-column: span 2;
    grid-row: span 2;
}

.mosaic-item.wide {
    grid-column: span 2;
}

.mosaic-item.tall {
    grid-row: span 2;
}

/* Ajuste para móviles */
@media (max-width: 768px) {
    .xyber-mosaic {
        grid-template-columns: repeat(2, 1fr);
        grid-auto-rows: 150px;
    }
    .mosaic-item.big {
        grid-column: span 2;
        grid-row: span 2;
    }
}

/*Top 3 celulares*/

.table-purple {
    background-color: #7a00ff;
    color: white;
}

.table-dark {
    background-color: #0d0d0d !important;
    border-color: #333;
}

/* Efecto para resaltar la columna al pasar el mouse */
.table-hover tbody tr:hover {
    background-color: rgba(122, 0, 255, 0.1) !important;
    color: #000000;
}

.text-warning {
    color: #ffcc00 !important; /* Estrellas doradas */
}

.card-img-top {
    width: 100%;
    height: 200px;
    object-fit: cover;
    border-radius: 20px !important;
}

/*ARTICULOS DE BLOG*/

.rtx-4060 {
    border: #670081 solid 1px;
    border-radius: 20px;
    display: flex;
    place-items: center;
    gap: 20px;
    width: 100%;
    max-width: 1200px;
    margin: 20px auto 20px auto;
    padding: 10px;
}