* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Poppins', sans-serif;
    background: #ffffff;
    color: #333;
    overflow-x: hidden;
}

/* ================= PARTÍCULAS ================= */

.particles {
    position: fixed;
    width: 100%;
    height: 100%;
    background-image: radial-gradient(circle, #0077ff 2px, transparent 2px);
    background-size: 60px 60px;
    opacity: 0.08;
    animation: moveParticles 120s linear infinite;
    z-index: -1;
}

@keyframes moveParticles {
    from { background-position: 0 0; }
    to { background-position: 1000px 1000px; }
}

/* ================= HERO ================= */

/* ================= HERO ACTUALIZADO ================= */

.hero {
    min-height: 88vh; /* ya no ocupa 100vh rígido */
    padding:20px 8% 0 8%; /* menos espacio arriba */
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start; /* empieza más arriba */
    gap: 20px;
}

/* Logo más integrado */
.logo {
    width: 75px;
    margin-bottom: -100px;
    animation: floatLogo 4s ease-in-out infinite;
}

@keyframes floatLogo {
    0%,100% { transform: translateY(0); }
    50% { transform: translateY(-6px); }
}

/* Header centrado y más compacto */
.hero-header {
    text-align: center;
    margin-bottom: 10px;
}

.hero-header h1 {
    font-size: 3.2rem;
    font-weight: 700;
    color: #1db954;
    letter-spacing: 6px;
    margin-bottom: 10px;
}

.hero-header p {
    font-size: 1.15rem;
    color: #555;
    max-width: 600px;
    margin: 0 auto;
}

/* Contenido más pegado */
.hero-content {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 25px;
    margin-top: 10px;
}
/* ================= BANNER ================= */

.games-banner {
    width: 100%;
    height: 220px;
    border-radius: 18px;
    overflow: hidden;
    background: url("f1.jpg") center/cover no-repeat;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: 0.4s;
}

.games-banner:hover {
    transform: scale(1.02);
}

.games-banner::before {
    content: "";
    position: absolute;
    width: 100%;
    height: 100%;
    backdrop-filter: blur(6px);
    background: rgba(0,0,0,0.45);
}

.banner-overlay {
    position: relative;
    color: white;
    text-align: center;
}

.banner-overlay h2 {
    font-size: 1.8rem;
    margin-bottom: 15px;
}

/* BOTONES */

.btn-primary,
.btn-secondary {
    padding: 10px 22px;
    background: #1db954;
    color: white;
    text-decoration: none;
    border-radius: 25px;
    font-size: 1rem;
    transition: 0.3s;
}

.btn-primary:hover,
.btn-secondary:hover {
    background: #169c46;
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(29,185,84,0.4);
}

/* ================= CARDS ================= */

.cards-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.card {
    background: white;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 10px 25px rgba(0,0,0,0.08);
    transition: 0.4s;
}

.card:hover {
    transform: translateY(-8px);
    box-shadow: 0 18px 35px rgba(0,0,0,0.12);
}

.card-image {
    height: 130px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    position: relative;
}

.card-image::before {
    content: "";
    position: absolute;
    width: 100%;
    height: 100%;
    backdrop-filter: blur(4px);
    background: rgba(0,0,0,0.4);
}

.card-image h3 {
    position: relative;
    font-size: 1.9rem;
}

.vender { background: url("y6.jpg") center/cover no-repeat; }
.comprar { background: url("y5.jpg") center/cover no-repeat; }

.card-body {
    padding: 20px;
    text-align: center;
}

.card-body p {
    font-size: 1.1rem;
    margin-bottom: 15px;
}

/* ============================= */
/* SECCIÓN ECOLÓGICA */
/* ============================= */

.eco-section {
    width: 100%;
    height: 80vh;
    background: url("ma1.jpg") center/cover no-repeat;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-top: 60px;
}

/* Overlay oscuro elegante */
.eco-overlay {
    position: absolute;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        rgba(0, 0, 0, 0.55),
        rgba(0, 0, 0, 0.65)
    );
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 0 15%;
    text-align: center;
    color: white;
}

/* Título */
.eco-overlay h2 {
    font-size: 2.8rem;
    margin-bottom: 25px;
    font-weight: 700;
    letter-spacing: 2px;
    text-shadow: 0 0 20px rgba(0,0,0,0.6);
}

/* Texto principal */
.eco-overlay p {
    max-width: 800px;
    font-size: 1.2rem;
    line-height: 1.7;
    margin-bottom: 40px;
    opacity: 0.95;
}

/* Frases */
.eco-quotes {
    display: flex;
    flex-direction: column;
    gap: 15px;
    font-weight: 500;
    font-size: 1.1rem;
    letter-spacing: 1px;
}

.eco-quotes span {
    opacity: 0.9;
    transition: transform 0.3s ease;
}

.eco-quotes span:hover {
    transform: scale(1.05);
    }
/* ================= WHY RESTAURADA ================= */

.why {
    padding: 120px 10%;
    background: #f8fff9;
    display: flex;
    justify-content: center;
}

.why-content {
    max-width: 900px;
    text-align: center;
}

.why-content h2 {
    font-size: 2.8rem;
    color: #1db954;
    margin-bottom: 50px;
}

.why-content ul {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 25px;
}

.why-content li {
    background: white;
    padding: 20px 25px;
    border-radius: 14px;
    font-size: 1.2rem;
    box-shadow: 0 10px 25px rgba(0,0,0,0.05);
    transition: 0.3s;
}

.why-content li:hover {
    transform: translateX(8px);
    box-shadow: 0 15px 30px rgba(0,0,0,0.08);
}

.why-content li span {
    color: #1db954;
    font-weight: bold;
    margin-right: 10px;
}

/* ================= FOOTER ================= */

footer {
    background: #0a0a0a;
    padding: 90px 10%;
    text-align: center;
    color: #aaa;
}

footer h2 {
    font-size: 2.8rem;
    color: #1db954;
    margin-bottom: 20px;
}

.legal-links {
    margin: 35px 0;
    display: flex;
    justify-content: center;
    gap: 25px;
    flex-wrap: wrap;
}

.legal-links a {
    padding: 12px 24px;
    border: 1px solid rgba(29,185,84,0.4);
    border-radius: 8px;
    color: #ccc;
    text-decoration: none;
    font-size: 0.95rem;
    transition: all 0.3s ease;
}

.legal-links a:hover {
    background: #1db954;
    color: #000;
    box-shadow: 0 0 20px rgba(29,185,84,0.4);
}

.dev a {
    color: #aaa;
}

.dev a:hover {
    color: #1db954;
}
/* ========================================= */
/* ANIMACIONES AVANZADAS SIN TOCAR ESTRUCTURA */
/* ========================================= */

/* ===== Fade inicial suave ===== */

body {
    animation: fadeInBody 1.2s ease-out;
}

@keyframes fadeInBody {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* ===== Entrada hero elegante ===== */

.hero-header h1 {
    animation: slideDown 1s ease-out;
}

.hero-header p {
    animation: fadeUp 1.4s ease-out;
}

@keyframes slideDown {
    from { transform: translateY(-40px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

@keyframes fadeUp {
    from { transform: translateY(40px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

/* ===== Brillo animado en el título ===== */

.hero-header h1 {
    position: relative;
    overflow: hidden;
}

.hero-header h1::after {
    content: "";
    position: absolute;
    top: 0;
    left: -150%;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        120deg,
        transparent,
        rgba(255,255,255,0.5),
        transparent
    );
    animation: shine 4s infinite;
}

@keyframes shine {
    0% { left: -150%; }
    50% { left: 150%; }
    100% { left: 150%; }
}

/* ===== Glow suave en cards ===== */

.card {
    position: relative;
}

.card::after {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: 16px;
    background: linear-gradient(45deg, transparent, rgba(29,185,84,0.15), transparent);
    opacity: 0;
    transition: opacity 0.4s ease;
    pointer-events: none;
}

.card:hover::after {
    opacity: 1;
}

/* ===== Efecto flotación suave banner ===== */

.games-banner {
    animation: floatBanner 6s ease-in-out infinite;
}

@keyframes floatBanner {
    0%,100% { transform: translateY(0); }
    50% { transform: translateY(-6px); }
}

/* ===== Animación eco section (zoom lento fondo) ===== */

.eco-section {
    animation: zoomEco 20s ease-in-out infinite alternate;
}

@keyframes zoomEco {
    from { background-size: 100%; }
    to { background-size: 110%; }
}

/* ===== Animación progresiva WHY items ===== */

.why-content li {
    opacity: 0;
    transform: translateY(40px);
    animation: revealWhy 0.8s forwards;
}

.why-content li:nth-child(1) { animation-delay: 0.2s; }
.why-content li:nth-child(2) { animation-delay: 0.4s; }
.why-content li:nth-child(3) { animation-delay: 0.6s; }
.why-content li:nth-child(4) { animation-delay: 0.8s; }

@keyframes revealWhy {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ===== Botones con efecto pulso suave ===== */

.btn-primary {
    animation: pulse 3s infinite;
}

@keyframes pulse {
    0% { box-shadow: 0 0 0 0 rgba(29,185,84,0.6); }
    70% { box-shadow: 0 0 0 15px rgba(29,185,84,0); }
    100% { box-shadow: 0 0 0 0 rgba(29,185,84,0); }
}

/* ===== Footer aparición suave ===== */

footer {
    animation: fadeUpFooter 1.2s ease-out;
}

@keyframes fadeUpFooter {
    from { opacity: 0; transform: translateY(60px); }
    to { opacity: 1; transform: translateY(0); }
}
/* ========================================= */
/* EFECTOS PROFESIONALES PREMIUM */
/* ========================================= */

/* ===== Scroll Reveal profesional ===== */

section:not(.hero) {
    opacity: 0;
    transform: translateY(60px);
    transition: all 1s cubic-bezier(.2,.8,.2,1);
}
.hero {
    opacity: 1 !important;
    transform: none !important;
}

section.visible {
    opacity: 1;
    transform: translateY(0);
}

/* ===== Hero efecto gradiente animado ===== */

.hero {
    background: linear-gradient(-45deg, #ffffff, #f4fff6, #ffffff);
    background-size: 400% 400%;
    animation: gradientMove 12s ease infinite;
}

@keyframes gradientMove {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

/* ===== Cards efecto 3D profesional ===== */

.card {
    cursor: pointer;
    transition: transform 0.4s cubic-bezier(.2,.8,.2,1), 
                box-shadow 0.4s ease;
}

.card:hover {
    transform: translateY(-12px) scale(1.02);
    box-shadow: 0 30px 60px rgba(0,0,0,0.15);
}

/* Brillo dinámico */

.card::before {
    content: "";
    position: absolute;
    top: 0;
    left: -120%;
    width: 60%;
    height: 100%;
    background: linear-gradient(
        120deg,
        transparent,
        rgba(255,255,255,0.4),
        transparent
    );
    transform: skewX(-25deg);
    transition: 0.8s;
    pointer-events: none;
}

.card:hover::before {
    left: 150%;
}

/* ===== Banner efecto profundidad ===== */

.games-banner {
    transform-style: preserve-3d;
    transition: transform 0.6s ease;
}

.games-banner:hover {
    transform: scale(1.03) rotateX(3deg);
}

/* ===== Eco Section efecto cinematográfico ===== */

.eco-overlay h2 {
    animation: fadeTitle 1.2s ease forwards;
}

@keyframes fadeTitle {
    from { opacity: 0; letter-spacing: 10px; }
    to { opacity: 1; letter-spacing: 2px; }
}

/* ===== WHY efecto elegante ===== */

.why-content li {
    transition: all 0.4s ease;
}

.why-content li:hover {
    background: #1db954;
    color: white;
    transform: translateX(12px);
}

.why-content li:hover span {
    color: white;
}

/* ===== Botones efecto magnético premium ===== */

.btn-primary,
.btn-secondary {
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
}

.btn-primary::after,
.btn-secondary::after {
    content: "";
    position: absolute;
    width: 0%;
    height: 100%;
    left: 50%;
    top: 0;
    background: rgba(255,255,255,0.2);
    transform: translateX(-50%);
    transition: width 0.4s ease;
}

.btn-primary:hover::after,
.btn-secondary:hover::after {
    width: 140%;
}

/* ===== Footer animación elegante ===== */

footer {
    background: linear-gradient(180deg,#0a0a0a,#111);
}

footer h2 {
    animation: glowTitle 3s infinite alternate;
}

@keyframes glowTitle {
    from { text-shadow: 0 0 10px rgba(29,185,84,0.3); }
    to { text-shadow: 0 0 25px rgba(29,185,84,0.7); }
}
/* ========================= */
/* TOP BAR PROFESIONAL */
/* ========================= */

.topbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background: linear-gradient(90deg, #1db954, #17a74a);
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 40px;
    padding: 12px 20px;
    z-index: 9999;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    animation: slideDownBar 0.8s ease-out;
}

@keyframes slideDownBar {
    from { transform: translateY(-100%); }
    to { transform: translateY(0); }
}

.topbar a {
    color: white;
    text-decoration: none;
    font-weight: 500;
    font-size: 0.95rem;
    position: relative;
    transition: all 0.3s ease;
}

/* Subrayado animado profesional */
.topbar a::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: -4px;
    width: 0%;
    height: 2px;
    background: white;
    transition: width 0.3s ease;
}

.topbar a:hover::after {
    width: 100%;
}

.topbar a:hover {
    transform: translateY(-2px);
    opacity: 0.9;
}

/* Ajustamos el hero para que no quede tapado */
.hero {
    margin-top: 60px;
}

/* Responsive */
@media (max-width: 900px) {
    .topbar {
        flex-direction: column;
        gap: 10px;
        padding: 15px;
        text-align: center;
    }

    .hero {
        margin-top: 100px;
    }
}
/* =============================== */
/* BOTÓN CATEGORÍAS */
/* =============================== */

.menu-toggle {
    position: fixed;
    top: 15px;
    right: 20px;
    background: white;
    padding: 10px 18px;
    border-radius: 30px;
    font-weight: 600;
    cursor: pointer;
    box-shadow: 0 5px 20px rgba(0,0,0,0.1);
    z-index: 10000;
    transition: all 0.3s ease;
}

.menu-toggle:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(0,0,0,0.15);
}

.menu-toggle span {
    margin-left: 8px;
}

/* =============================== */
/* OVERLAY */
/* =============================== */

.menu-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.4);
    backdrop-filter: blur(4px);
    opacity: 0;
    visibility: hidden;
    transition: 0.4s ease;
    z-index: 9998;
}

.menu-overlay.active {
    opacity: 1;
    visibility: visible;
}

/* =============================== */
/* BOTÓN CATEGORÍAS IZQUIERDA */
/* =============================== */

.menu-toggle {
    position: fixed;
    top: 15px;
    left: 20px;
    display: inline-flex; /* clave */
    align-items: center;
    gap: 8px;
    background: white;
    padding: 8px 16px; /* más pequeño */
    border-radius: 30px;
    font-weight: 600;
    font-size: 0.95rem;
    cursor: pointer;
    box-shadow: 0 5px 20px rgba(0,0,0,0.1);
    z-index: 10000;
    transition: all 0.3s ease;
    width: auto; /* IMPORTANTE */
    max-width: fit-content; /* evita que se estire */
}

.menu-toggle.hide {
    opacity: 0;
    pointer-events: none;
}

.menu-toggle:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(0,0,0,0.15);
}

.menu-toggle span {
    margin-left: 8px;
}

/* =============================== */
/* OVERLAY */
/* =============================== */

.menu-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.4);
    backdrop-filter: blur(4px);
    opacity: 0;
    visibility: hidden;
    transition: 0.4s ease;
    z-index: 9998;
}

.menu-overlay.active {
    opacity: 1;
    visibility: visible;
}

/* =============================== */
/* PANEL LATERAL IZQUIERDA */
/* =============================== */

.side-menu {
    position: fixed;
    top: 0;
    left: -400px; /* ahora entra desde la izquierda */
    width: 350px;
    height: 100%;
    background: #f9f9f9;
    box-shadow: 10px 0 40px rgba(0,0,0,0.15);
    transition: left 0.4s cubic-bezier(.2,.8,.2,1);
    z-index: 9999;
    padding: 30px 25px;
    display: flex;
    flex-direction: column;
}

.side-menu.active {
    left: 0;
}

/* Header */
.menu-header {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-bottom: 30px;
}

.menu-header h2 {
    font-size: 1.2rem;
    color: #1db954;
    letter-spacing: 1px;
}

#closeMenu {
    font-size: 1.6rem;
    cursor: pointer;
    transition: 0.3s;
}

#closeMenu:hover {
    transform: rotate(90deg);
}

/* Links */
.menu-links {
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.menu-links a {
    text-decoration: none;
    font-weight: 600;
    color: #222;
    font-size: 1rem;
    transition: all 0.3s ease;
}

.menu-links a:hover {
    color: #1db954;
    transform: translateX(8px);
}

/* Responsive */
@media(max-width:500px){
    .side-menu{
        width: 100%;
    }
}