:root {
    --bg-color: #f0f8ff;
    --text-main: #2d3436;
    --text-muted: #636e72;
    --glass-bg: rgba(255, 255, 255, 0.7);
    --glass-border: rgba(255, 255, 255, 0.5);
    --shadow-soft: 0 8px 32px 0 rgba(31, 38, 135, 0.15);
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Nunito', sans-serif;
    background-color: var(--bg-color);
    color: var(--text-main);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    overflow-x: hidden;
    position: relative;
}

/* Fondo animado */
.background-bubbles {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    z-index: -1;
    overflow: hidden;
    background: linear-gradient(135deg, #a8edea 0%, #fed6e3 100%);
}

.bubble {
    position: absolute;
    bottom: -100px;
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    animation: float 10s infinite ease-in;
}

.bubble:nth-child(1) { left: 10%; animation-duration: 8s; width: 60px; height: 60px; }
.bubble:nth-child(2) { left: 20%; animation-duration: 5s; animation-delay: 1s; }
.bubble:nth-child(3) { left: 50%; animation-duration: 12s; width: 80px; height: 80px; animation-delay: 2s; }
.bubble:nth-child(4) { left: 70%; animation-duration: 7s; animation-delay: 0.5s; }
.bubble:nth-child(5) { left: 90%; animation-duration: 9s; width: 50px; height: 50px; }

@keyframes float {
    0% { transform: translateY(0) rotate(0deg); opacity: 1; border-radius: 50%; }
    100% { transform: translateY(-1000px) rotate(720deg); opacity: 0; border-radius: 30%; }
}

/* Componente Glassmorphism reutilizable */
.glass-panel {
    background: var(--glass-bg);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid var(--glass-border);
    border-radius: 24px;
    box-shadow: var(--shadow-soft);
}

/* Header / Hero */
.hero {
    /* Aquí cargaremos la imagen generada dinámicamente si es necesario, o un gradiente */
    background: url('assets/hero.png') center/cover no-repeat;
    background-color: #6c5ce7;
    background-blend-mode: overlay;
    padding: 80px 20px;
    text-align: center;
    display: flex;
    justify-content: center;
    align-items: center;
}

.hero-content {
    padding: 40px;
    max-width: 600px;
}

.hero-content h1 {
    font-family: 'Quicksand', sans-serif;
    font-size: 3rem;
    font-weight: 700;
    color: #2d3436;
    margin-bottom: 15px;
    text-shadow: 2px 2px 4px rgba(255,255,255,0.8);
}

.hero-content p {
    font-size: 1.2rem;
    color: #444;
    font-weight: 700;
}

/* Contenedor Principal */
.container {
    max-width: 1200px;
    margin: -40px auto 40px;
    padding: 0 20px;
    flex: 1;
    z-index: 10;
}

/* Buscador y Filtros */
.filters {
    background: var(--glass-bg);
    backdrop-filter: blur(10px);
    border-radius: 20px;
    padding: 30px;
    text-align: center;
    margin-bottom: 40px;
    box-shadow: var(--shadow-soft);
}

.filters h2 {
    font-family: 'Quicksand', sans-serif;
    margin-bottom: 20px;
    color: #2d3436;
}

.search-box {
    position: relative;
    max-width: 400px;
    margin: 0 auto;
}

.search-box input {
    width: 100%;
    padding: 15px 20px 15px 50px;
    border-radius: 30px;
    border: 2px solid #dfe6e9;
    font-size: 1rem;
    font-family: 'Nunito', sans-serif;
    outline: none;
    transition: all 0.3s ease;
}

.search-box input:focus {
    border-color: #0984e3;
    box-shadow: 0 0 15px rgba(9, 132, 227, 0.2);
}

.search-box i {
    position: absolute;
    left: 20px;
    top: 50%;
    transform: translateY(-50%);
    color: #b2bec3;
    font-size: 1.2rem;
}

/* Grilla de Juegos */
.games-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 30px;
}

/* Tarjeta de Juego */
.game-card {
    background: var(--glass-bg);
    border-radius: 20px;
    overflow: hidden;
    text-decoration: none;
    color: var(--text-main);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    box-shadow: 0 10px 20px rgba(0,0,0,0.05);
    border: 2px solid transparent;
    display: flex;
    flex-direction: column;
}

.game-card:hover {
    transform: translateY(-10px) scale(1.02);
    box-shadow: 0 20px 40px rgba(0,0,0,0.1);
    border-color: rgba(255,255,255,0.8);
}

.game-icon {
    height: 150px;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 4rem;
    color: white;
}

.game-info {
    padding: 25px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.game-info h3 {
    font-family: 'Quicksand', sans-serif;
    font-size: 1.5rem;
    margin-bottom: 10px;
}

.game-info p {
    color: var(--text-muted);
    line-height: 1.5;
    margin-bottom: 20px;
    flex: 1;
}

.play-btn {
    align-self: flex-start;
    padding: 10px 25px;
    background: rgba(0,0,0,0.1);
    border-radius: 30px;
    font-weight: 700;
    transition: all 0.3s;
}

.game-card:hover .play-btn {
    background: white;
    color: inherit;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

/* Footer */
footer {
    text-align: center;
    padding: 30px;
    color: #636e72;
    font-weight: 700;
    margin-top: auto;
}
