:root {
    --blue: #4A90D9;
    --yellow: #E8A838;
    --green: #5DBB6D;
    --red: #E25555;
    --purple: #8B5CF6;
    --gray-dark: #2d3748;
    --gray-medium: #4a5568;
    --gray-light: #718096;
    --gray-bg: #f7fafc;
    --white: #ffffff;
    --shadow: 0 2px 8px rgba(0,0,0,0.06);
    --shadow-hover: 0 12px 32px rgba(0,0,0,0.12);
}

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

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    background: var(--white);
    color: var(--gray-dark);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* Header */
header {
    text-align: center;
    padding: 64px 24px 40px;
}

header h1 {
    font-family: 'Fredoka', sans-serif;
    font-size: 3.5rem;
    font-weight: 700;
    letter-spacing: -0.02em;
    color: var(--gray-dark);
    margin-bottom: 12px;
}

.tagline {
    font-size: 1.15rem;
    color: var(--gray-light);
    font-weight: 400;
}

/* Games Grid */
main {
    flex: 1;
    max-width: 900px;
    width: 100%;
    margin: 0 auto;
    padding: 0 24px 64px;
}

.games-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 24px;
    margin-bottom: 40px;
}

/* Game Card */
.game-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 40px 24px 32px;
    border-radius: 20px;
    background: var(--white);
    border: 2px solid transparent;
    box-shadow: var(--shadow);
    text-decoration: none;
    color: var(--gray-dark);
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
    position: relative;
    overflow: hidden;
}

.game-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--card-color, var(--blue));
    opacity: 0;
    transition: opacity 0.2s ease;
}

.game-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-hover);
    border-color: var(--card-color, var(--blue));
}

.game-card:hover::before {
    opacity: 1;
}

.card-icon {
    width: 72px;
    height: 72px;
    border-radius: 20px;
    background: var(--card-color, var(--blue));
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 20px;
    transition: transform 0.2s ease;
}

.game-card:hover .card-icon {
    transform: scale(1.08);
}

.card-icon svg {
    width: 36px;
    height: 36px;
    color: var(--white);
}

.game-card h2 {
    font-family: 'Fredoka', sans-serif;
    font-size: 1.4rem;
    font-weight: 600;
    margin-bottom: 12px;
    color: var(--gray-dark);
}

.card-label {
    display: inline-block;
    padding: 8px 20px;
    border-radius: 100px;
    background: var(--gray-bg);
    color: var(--gray-medium);
    font-size: 0.875rem;
    font-weight: 500;
    transition: background 0.2s ease, color 0.2s ease;
}

.game-card:hover .card-label {
    background: var(--card-color, var(--blue));
    color: var(--white);
}

/* Add Game Button */
.add-game {
    display: flex;
    justify-content: center;
    padding: 24px 0;
}

.add-btn {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 14px 28px;
    border-radius: 100px;
    border: 2px dashed var(--gray-light);
    background: transparent;
    color: var(--gray-light);
    font-family: 'Inter', sans-serif;
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
}

.add-btn:hover {
    border-color: var(--blue);
    color: var(--blue);
    background: rgba(74, 144, 217, 0.05);
}

.add-btn svg {
    width: 20px;
    height: 20px;
}

/* Footer */
footer {
    text-align: center;
    padding: 32px 24px;
    border-top: 1px solid #e2e8f0;
}

footer p {
    color: var(--gray-light);
    font-size: 0.9rem;
}

/* Responsive */
@media (max-width: 480px) {
    header h1 {
        font-size: 2.5rem;
    }

    .tagline {
        font-size: 1rem;
    }

    .games-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }

    .game-card {
        padding: 32px 20px 24px;
    }

    .card-icon {
        width: 64px;
        height: 64px;
    }

    .card-icon svg {
        width: 30px;
        height: 30px;
    }
}
