@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;600;700;800&display=swap');

/* Light (Pastel) Theme Variables */
:root {
    --background-main: linear-gradient(135deg, #f8c8c8, #c8f8d0, #c8d8f8);
    --background-secondary: #ffffff;
    --primary-accent: #ff9eb5;
    --secondary-accent: #8fd3f4;
    --text-primary: #2d2d2d;
    --text-secondary: #555;
    --shadow-color: rgba(0, 0, 0, 0.15);
    --border-radius: 16px;
}

body {
    background: var(--background-main);
    font-family: 'Inter', sans-serif;
    color: var(--text-primary);
    margin: 0;
    padding: 0;
}

/* Sidebar Nav */
nav {
    position: fixed;
    top: 0;
    left: 0;
    width: 12vw;
    min-width: 90px;
    background: var(--secondary-accent);
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 20px;
    box-shadow: 5px 0 15px var(--shadow-color);
    height: 100vh;
    z-index: 5;
    box-sizing: border-box;
    border-top-right-radius: 20px;
    border-bottom-right-radius: 20px;
}

nav img#logo {
    height: 6vw;
    width: 6vw;
    min-width: 60px;
    min-height: 60px;
    border-radius: 50%;
    cursor: pointer;
    border: 3px solid var(--background-secondary);
}

/* Toggle Button */
#theme-toggle {
    margin-top: 20px;
    background: var(--primary-accent);
    color: #fff;
    border: none;
    padding: 10px 14px;
    font-size: 1.2rem;
    border-radius: 50%;
    cursor: pointer;
    transition: transform 0.2s ease, background 0.2s ease;
}

#theme-toggle:hover {
    transform: scale(1.1);
    background: #ffb8ca;
}

/* Content Area */
.content {
    margin-left: 12vw;
    padding: 2vw 3vw;
}

/* Search Bar */
.search-bar {
    width: 100%;
    padding: 15px;
    font-size: 1.1rem;
    border-radius: var(--border-radius);
    border: 2px solid var(--secondary-accent);
    background: var(--background-secondary);
    color: var(--text-primary);
    margin-bottom: 25px;
    box-shadow: 0 4px 10px var(--shadow-color);
}

/* Game Grid */
#games {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 25px;
    padding-bottom: 50px;
}

.game-card {
    background: var(--background-secondary); /* uses variable now */
    border-radius: var(--border-radius);
    overflow: hidden;
    text-decoration: none;
    color: var(--text-primary);
    box-shadow: 0 6px 14px var(--shadow-color);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
    display: block;
}

.game-card:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: 0 12px 24px var(--shadow-color);
}

.game-card img {
    width: 100%;
    height: 150px;
    object-fit: cover;
    border-bottom: 4px solid var(--primary-accent);
}

.game-card .game-title {
    padding: 15px;
    font-weight: 700;
    text-align: center;
    color: var(--text-primary);
}

/* Dark Mode Theme */
body.dark-mode {
    --background-main: #0f172a;
    --background-secondary: #1e293b;
    --primary-accent: #38bdf8;
    --secondary-accent: #475569;
    --text-primary: #e2e8f0;
    --text-secondary: #94a3b8;
    --shadow-color: rgba(0, 0, 0, 0.6);
}
