/* RESET & VARIABLES */
:root {
    --primary: #ff6600;
    --bg: #0a0a0a;
    --card: #141414;
    --text: #ffffff;
    --accent: #222;
}

* { margin: 0; padding: 0; box-sizing: border-box; scroll-behavior: smooth; }

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg);
    color: var(--text);
    overflow-x: hidden;
}

/* NAVBAR */
.navbar {
    height: 80px; background: rgba(0,0,0,0.9);
    backdrop-filter: blur(15px); position: fixed; top: 0; width: 100%;
    z-index: 1000; border-bottom: 1px solid var(--accent);
    display: flex; align-items: center;
}

.nav-container {
    width: 90%; max-width: 1200px; margin: auto;
    display: flex; justify-content: space-between; align-items: center;
}

.logo { font-family: 'Orbitron'; font-weight: 800; color: #fff; text-decoration: none; font-size: 1.5rem; letter-spacing: -1px; }
.logo span { color: var(--primary); }

.cart-trigger { 
    background: var(--primary); padding: 8px 20px; border-radius: 4px; 
    cursor: pointer; display: flex; align-items: center; gap: 10px; font-weight: 600;
    transition: 0.3s;
}

.cart-trigger:hover { transform: scale(1.05); box-shadow: 0 0 20px rgba(255, 102, 0, 0.4); }

/* HERO */
.hero {
    height: 80vh; display: flex; align-items: center; justify-content: center;
    text-align: center; background: radial-gradient(circle at center, #1a1a1a 0%, #0a0a0a 100%);
}

.hero h1 { font-family: 'Orbitron'; font-size: clamp(2.5rem, 8vw, 5rem); line-height: 1; margin: 20px 0; }
.hero-tag { color: var(--primary); letter-spacing: 5px; font-size: 0.9rem; font-weight: 600; }
.btn-scroll { color: var(--text); text-decoration: none; opacity: 0.6; transition: 0.3s; }
.btn-scroll:hover { opacity: 1; color: var(--primary); }

/* PRODUCTOS */
.container { max-width: 1200px; margin: 80px auto; padding: 0 20px; }
.product-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 30px; }

.card { 
    background: var(--card); border: 1px solid var(--accent); border-radius: 12px;
    padding: 20px; transition: 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.card:hover { border-color: var(--primary); transform: translateY(-10px); }

/* Fallback de imagen */
.img-placeholder { font-family: 'Orbitron'; color: #222; font-weight: 800; font-size: 1.2rem; }

/* Modifica el contenedor para asegurar que la imagen no se salga al crecer */
.img-container {
    width: 100%; 
    height: 250px; 
    border-radius: 8px; 
    margin-bottom: 20px;
    background: #080808; 
    display: flex; 
    align-items: center; 
    justify-content: center;
    overflow: hidden; /* Esto es vital para que la imagen no desborde */
    border: 1px solid #1a1a1a;
}

/* Añade una transición suave a la imagen */
.img-container img { 
    width: 100%; 
    height: 100%; 
    object-fit: cover; 
    transition: transform 0.5s ease; /* Controla la velocidad del zoom */
}

/* Cuando el usuario pase el ratón por la CARD, la imagen dentro crecerá */
.card:hover .img-container img {
    transform: scale(1.1); /* Crece un 10% */
}


.card h3 { font-family: 'Orbitron'; margin-bottom: 10px; font-size: 1.1rem; }
.price { color: var(--primary); font-size: 1.5rem; font-weight: 700; margin-bottom: 20px; }

.btn-add {
    width: 100%; padding: 12px; background: transparent; color: #fff;
    border: 1px solid #fff; border-radius: 6px; cursor: pointer; transition: 0.3s;
}

.btn-add:hover { background: #fff; color: #000; }

/* SIDEBAR CESTA */
.sidebar {
    position: fixed; right: -400px; top: 0; width: 380px; height: 100%;
    background: #0d0d0d; z-index: 2000; transition: 0.5s; padding: 40px;
    display: flex; flex-direction: column; border-left: 1px solid var(--accent);
}
.sidebar.active { right: 0; }
.sidebar-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 30px; }
.close-btn { background: none; border: none; color: #fff; font-size: 2.5rem; cursor: pointer; }

.cart-item {
    display: flex; justify-content: space-between; align-items: center;
    padding: 15px 0; border-bottom: 1px solid #1a1a1a;
}

.btn-remove { background: none; border: none; color: #ff4444; cursor: pointer; font-size: 0.8rem; }

/* FORMULARIO MODAL */
.modal-overlay {
    display: none; position: fixed; inset: 0; background: rgba(0,0,0,0.9);
    z-index: 3000; backdrop-filter: blur(10px); align-items: center; justify-content: center;
}
.modal-card {
    background: var(--card); padding: 40px; border-radius: 20px; width: 90%; max-width: 500px;
    border: 1px solid var(--primary);
}
.input-group input, .input-group textarea {
    width: 100%; padding: 15px; margin-bottom: 15px; background: #000;
    border: 1px solid var(--accent); color: #fff; border-radius: 8px;
}
.btn-send { background: var(--primary); color: #fff; border: none; padding: 15px 30px; border-radius: 8px; cursor: pointer; font-weight: bold; width: 100%; margin-bottom: 10px; }
.btn-cancel { background: none; border: none; color: #666; cursor: pointer; width: 100%; }

/* Botón de Pago Premium */
.btn-checkout {
    width: 100%;
    padding: 18px;
    background: linear-gradient(135deg, #ff6600 0%, #ff9900 100%);
    color: white;
    border: none;
    border-radius: 8px;
    font-family: 'Orbitron', sans-serif;
    font-weight: 800;
    font-size: 1rem;
    letter-spacing: 1px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(255, 102, 0, 0.3);
    position: relative;
    overflow: hidden;
}

.btn-checkout:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(255, 102, 0, 0.5);
    filter: brightness(1.1);
}

.btn-checkout:active {
    transform: translateY(1px);
}

/* Efecto de brillo que pasa por el botón */
.btn-checkout::after {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: rgba(255, 255, 255, 0.1);
    transform: rotate(45deg);
    transition: 0.5s;
    pointer-events: none;
}

.btn-checkout:hover::after {
    left: 120%;
}

.btn-correo {
    width: 100%;
    padding: 18px;
    background: linear-gradient(135deg, #033670 0%, #00ffea 100%);
    color: white;
    border: none;
    border-radius: 8px;
    font-family: 'Orbitron', sans-serif;
    font-weight: 800;
    font-size: 1rem;
    letter-spacing: 1px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(0, 255, 238, 0.3);
    position: relative;
    overflow: hidden;
}

.btn-correo:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 255, 255, 0.5);
    filter: brightness(1.1);
}

.btn-correo:active {
    transform: translateY(1px);
}

/* Efecto de brillo que pasa por el botón */
.btn-correo::after {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: rgba(255, 255, 255, 0.1);
    transform: rotate(45deg);
    transition: 0.5s;
    pointer-events: none;
}

.btn-correo:hover::after {
    left: 120%;
}

.footer-copyright {
    text-align: center;
    font-size: 0.8em;
    color: #555;
    padding: 20px;
    border-top: 1px solid #eee;
}

/* Ajuste para que el modal personalizado use el mismo estilo que el de pago */
#modal-personalizado .modal-card {
    background: var(--card);
    padding: 40px;
    border-radius: 20px;
    width: 90%;
    max-width: 500px;
    border: 1px solid var(--primary);
    text-align: center;
}

/* Reutilizamos tus inputs oscuros */
#modal-personalizado input, 
#modal-personalizado textarea {
    width: 100%;
    padding: 15px;
    margin-bottom: 15px;
    background: #000;
    border: 1px solid var(--accent);
    color: #fff;
    border-radius: 8px;
    font-family: 'Inter', sans-serif;
}

#modal-personalizado textarea {
    height: 120px;
    resize: none;
}

        .recursos-container { max-width: 800px; margin: 120px auto; padding: 20px; text-align: center; }
        .app-card {
            background: var(--card);
            border: 1px solid var(--accent);
            border-radius: 15px;
            padding: 30px;
            margin-bottom: 30px;
            transition: 0.3s;
            display: flex;
            align-items: center;
            gap: 20px;
            text-align: left;
        }
        .app-card:hover { border-color: var(--primary); transform: translateY(-5px); }
        .app-info h3 { font-family: 'Orbitron'; color: var(--primary); margin-bottom: 5px; }
        .app-info p { color: #888; font-size: 0.9rem; margin-bottom: 15px; }
        .btn-download {
            transition: 0.3s;
            display: inline-block;
            background: var(--primary);
            color: white;
            padding: 10px 20px;
            border-radius: 6px;
            text-decoration: none;
            font-weight: bold;
            font-size: 0.8rem;
            text-transform: uppercase;
        }
        .btn-download:hover{
            transform: translateY(-2px);
            box-shadow: 0 8px 25px rgba(255, 102, 0, 0.5);
            filter: brightness(1.1);
        }

        /* Ajuste para el contenedor del logo de la app */
.app-icon {
    width: 80px;      /* Tamaño fijo para que todos los iconos sean iguales */
    height: 80px;
    background: #000;
    border-radius: 12px;
    border: 1px solid #333;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden; /* Corta lo que sobresalga */
    flex-shrink: 0;   /* Evita que se aplaste si el texto es muy largo */
}

/* Ajuste para la imagen dentro del logo */
.app-icon img {
    transition: 0.3s;
    width: 100%;
    height: 100%;
    object-fit: contain; /* Esto evita que se ralle/estire, la ajusta al hueco */
    padding: 10px;       /* Un poco de aire para que el logo no toque los bordes */
}

.app-icon img:hover{
    width: 105%;
    height: 105%;
    padding: 5px;
    border-radius: 20%;
    transition: 0.3s;
}

.btn-rec{
    text-decoration: none; 
    color: #fff; 
    font-family: 'Orbitron'; 
    font-size: 0.8rem; 
    letter-spacing: 1px; 
    border: 1px solid #333; 
    padding: 8px 15px; 
    border-radius: 4px; 
    transition: 0.3s;
}

.btn-rec:hover{
    padding: 10px 20px;
    font-size: 0.9rem;
    filter: brightness(1.1);
    box-shadow: 0 8px 25px rgba(255, 102, 0, 0.5);
}

/* --- ESTILOS PÁGINA 404 --- */
.body-404 {
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    background: radial-gradient(circle at center, #1a1a1a 0%, #0a0a0a 100%);
}

.error-container {
    text-align: center;
    position: relative;
    z-index: 10;
}

.error-code {
    font-family: 'Orbitron';
    font-size: clamp(8rem, 20vw, 12rem);
    font-weight: 800;
    color: var(--primary);
    position: relative;
    line-height: 1;
    text-shadow: 0 0 30px rgba(255, 102, 0, 0.3);
}

/* Efecto Glitch para el 404 */
.error-code::before, .error-code::after {
    content: "404";
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    opacity: 0.8;
}

.error-code::before {
    color: #ff00c1;
    z-index: -1;
    animation: glitch-anim 0.3s infinite;
}

.error-code::after {
    color: #00fff9;
    z-index: -2;
    animation: glitch-anim 0.3s infinite reverse;
}

@keyframes glitch-anim {
    0% { transform: translate(0); }
    20% { transform: translate(-3px, 3px); }
    40% { transform: translate(-3px, -3px); }
    60% { transform: translate(3px, 3px); }
    80% { transform: translate(3px, -3px); }
    100% { transform: translate(0); }
}

.error-msg {
    font-family: 'Orbitron';
    letter-spacing: 4px;
    margin-top: -20px;
    text-transform: uppercase;
}

.error-desc {
    color: #666;
    margin: 20px 0 40px;
    font-size: 0.9rem;
}

/* Fondo de rejilla 3D */
.grid-overlay {
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    background-image: 
        linear-gradient(rgba(255, 102, 0, 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 102, 0, 0.03) 1px, transparent 1px);
    background-size: 40px 40px;
    z-index: 0;
    pointer-events: none;
}

/* --- ESTILOS LOGIN --- */
.body-login {
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: radial-gradient(circle at center, #1a1a1a 0%, #050505 100%);
    position: relative;
}

.login-overlay {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background: linear-gradient(rgba(18, 16, 16, 0) 50%, rgba(0, 0, 0, 0.25) 50%), 
                linear-gradient(90deg, rgba(255, 0, 0, 0.02), rgba(0, 255, 0, 0.01), rgba(0, 0, 255, 0.02));
    background-size: 100% 4px, 3px 100%;
    pointer-events: none;
    z-index: 2;
}

.login-card {
    background: rgba(20, 20, 20, 0.9);
    padding: 50px 40px;
    border-radius: 20px;
    border: 1px solid var(--accent);
    width: 90%;
    max-width: 420px;
    position: relative;
    z-index: 10;
    backdrop-filter: blur(10px);
    box-shadow: 0 0 40px rgba(0,0,0,0.5);
}

.login-card:hover {
    border-color: var(--primary);
}

.login-header {
    text-align: center;
    margin-bottom: 40px;
}

.login-header p {
    font-family: 'Orbitron';
    font-size: 0.7rem;
    letter-spacing: 3px;
    color: #555;
    margin-top: 10px;
}

.input-group-login {
    margin-bottom: 25px;
    text-align: left;
}

.input-group-login label {
    display: block;
    font-family: 'Orbitron';
    font-size: 0.65rem;
    color: var(--primary);
    margin-bottom: 8px;
    letter-spacing: 1px;
}

.input-group-login input {
    width: 100%;
    background: #000;
    border: 1px solid #222;
    padding: 15px;
    border-radius: 8px;
    color: white;
    font-family: 'Inter', sans-serif;
    outline: none;
    transition: 0.3s;
}

.input-group-login input:focus {
    border-color: var(--primary);
    box-shadow: 0 0 15px rgba(255, 102, 0, 0.1);
}

.login-footer {
    margin-top: 30px;
    text-align: center;
    font-size: 0.8rem;
}

.login-footer a {
    color: #444;
    text-decoration: none;
    transition: 0.3s;
}

.login-footer a:hover {
    color: var(--primary);
}

.login-footer span {
    color: #222;
    margin: 0 10px;
}

/* Contenedor del Cupón/Descuento */
.descuento {
    display: none; /* Se activa por JS */
    align-items: center;
    justify-content: space-between;
    padding: 10px 20px;
    margin: 20px 0;
    border-radius: 12px;
    background: rgba(26, 26, 26, 0.8);
    border: 1px solid #333;
    box-shadow: inset 0 0 10px rgba(0, 0, 0, 0.5);
    transition: 0.3s;
}

/* Si el usuario está logueado y quieres resaltar el área */
.descuento:hover {
    border-color: var(--primary);
    box-shadow: 0 0 15px rgba(255, 102, 0, 0.1);
}

/* El input de texto */
.descuento input {
    background: #000;
    border: 1px solid #444;
    color: var(--primary);
    padding: 8px 15px;
    border-radius: 8px;
    font-family: 'Inter', sans-serif;
    outline: none;
    width: 60%;
    transition: 0.3s;
}

.descuento input:focus {
    border-color: var(--primary);
    background: #0a0a0a;
    box-shadow: 0 0 10px rgba(255, 102, 0, 0.2);
}

/* Placeholder (el texto de ejemplo dentro) */
.descuento input::placeholder {
    color: #555;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Si quieres añadir un pequeño texto al lado */
.descuento::before {
    content: "CUPÓN:";
    font-family: 'Orbitron';
    font-size: 0.7rem;
    color: #888;
    letter-spacing: 2px;
}

.btn-verificar {
    background: var(--primary);
    color: black;
    border: none;
    padding: 8px 15px;
    border-radius: 6px;
    font-family: 'Orbitron';
    font-size: 0.7rem;
    font-weight: 800;
    cursor: pointer;
    transition: 0.3s;
}

.btn-verificar:hover {
    filter: brightness(1.2);
    box-shadow: 0 0 10px rgba(255, 102, 0, 0.4);
}

.btn-login-main{
    text-decoration: none; 
    color: #fff; 
    font-family: 'Orbitron'; 
    font-size: 0.8rem; 
    letter-spacing: 1px; 
    border: 1px solid #333; 
    padding: 8px 15px; 
    border-radius: 4px; 
    transition: 0.3s;
}

.btn-login-main:hover{
    padding: 10px 18px;
    font-size: 0.8rem;
    filter: brightness(1.1);
    box-shadow: 0 8px 25px rgba(0, 255, 38, 0.5);
}