/* --- Games Page (Dark, Indigo/Purple) --- */
@import url('../fonts.css');

:root {
    --games-bg:      #0D0D1F;
    --games-surface: #16162A;
    --games-indigo:  #6366F1;
    --games-purple:  #A855F7;
    --games-text:    #FFFFFF;
    --games-muted:   rgba(255,255,255,0.45);
    --games-border:  rgba(99, 102, 241, 0.12);

    --font-heading: 'Playfair Display', serif;
    --font-body:    'Inter', sans-serif;
}

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

html { scroll-behavior: smooth; font-size: 16px; }

body.games-page {
    background: var(--games-bg);
    color: var(--games-text);
    font-family: var(--font-body);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

/* --- Background --- */
.games-bg {
    position: fixed;
    inset: 0;
    z-index: 0;
    pointer-events: none;
}

.games-glow {
    position: absolute;
    border-radius: 50%;
    filter: blur(100px);
}

.games-glow-1 {
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(99, 102, 241, 0.15) 0%, transparent 70%);
    top: -150px;
    right: -100px;
}

.games-glow-2 {
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(168, 85, 247, 0.1) 0%, transparent 70%);
    bottom: -100px;
    left: -80px;
}

/* Subtle grid overlay */
.games-grid-overlay {
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(99, 102, 241, 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(99, 102, 241, 0.03) 1px, transparent 1px);
    background-size: 60px 60px;
    mask-image: radial-gradient(ellipse at center, black 20%, transparent 80%);
}

/* --- Back Button --- */
.games-back-btn {
    position: fixed;
    top: 24px;
    left: 24px;
    z-index: 99;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    background: rgba(22, 22, 42, 0.9);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border: 1px solid var(--games-border);
    border-radius: 999px;
    color: var(--games-muted);
    font-size: 0.875rem;
    font-weight: 500;
    text-decoration: none;
    transition: color 0.25s, transform 0.25s, background 0.25s;
}

.games-back-btn:hover {
    color: #818CF8;
    background: rgba(99, 102, 241, 0.08);
    transform: translateX(-2px);
}

/* --- Main --- */
.games-main {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 80px 32px;
    position: relative;
    z-index: 1;
}

.games-content {
    text-align: center;
    max-width: 680px;
    position: relative;
}

/* --- Icon --- */
.games-icon {
    font-size: 5rem;
    display: block;
    margin-bottom: 32px;
    filter: drop-shadow(0 0 40px rgba(99, 102, 241, 0.4));
    animation: float 4s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0); }
    50%       { transform: translateY(-12px); }
}

/* --- Tag --- */
.games-tag {
    display: inline-block;
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: #818CF8;
    background: rgba(99, 102, 241, 0.1);
    border: 1px solid rgba(99, 102, 241, 0.2);
    padding: 6px 16px;
    border-radius: 999px;
    margin-bottom: 28px;
}

/* --- Heading --- */
h1 {
    font-family: var(--font-heading);
    font-size: clamp(3rem, 7vw, 5rem);
    line-height: 1.1;
    letter-spacing: -0.02em;
    margin-bottom: 24px;
}

.games-gradient-text {
    background: linear-gradient(135deg, var(--games-indigo), var(--games-purple));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* --- Desc --- */
.games-desc {
    font-size: 1.15rem;
    color: var(--games-muted);
    line-height: 1.7;
    margin-bottom: 40px;
    max-width: 520px;
    margin-left: auto;
    margin-right: auto;
}

/* --- CTA Button --- */
.games-cta { margin-bottom: 0; }

.games-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 14px 28px;
    background: rgba(99, 102, 241, 0.1);
    border: 1px solid rgba(99, 102, 241, 0.25);
    border-radius: 999px;
    color: #818CF8;
    font-weight: 600;
    font-size: 0.95rem;
    text-decoration: none;
    transition: all 0.25s ease;
}

.games-btn:hover {
    background: rgba(99, 102, 241, 0.18);
    border-color: rgba(99, 102, 241, 0.4);
    color: #fff;
    transform: translateY(-2px);
}

/* --- Floating elements --- */
.games-floaties {
    position: absolute;
    inset: -60px;
    pointer-events: none;
}

.floaty {
    position: absolute;
    left: var(--x);
    top: var(--y);
    font-size: 1.2rem;
    opacity: 0.15;
    color: #818CF8;
    animation: floaty-drift 6s ease-in-out infinite;
    animation-delay: var(--d);
}

@keyframes floaty-drift {
    0%, 100% { transform: translate(0, 0) rotate(0deg); }
    33%       { transform: translate(8px, -12px) rotate(10deg); }
    66%       { transform: translate(-6px, 8px) rotate(-8deg); }
}

/* --- Footer --- */
.games-footer {
    position: relative;
    z-index: 1;
    text-align: center;
    padding: 24px 32px;
    border-top: 1px solid var(--games-border);
}

.games-footer-links {
    display: flex;
    gap: 24px;
    justify-content: center;
    margin-bottom: 12px;
    flex-wrap: wrap;
}

.games-footer-links a {
    font-size: 0.85rem;
    color: var(--games-muted);
    text-decoration: none;
    transition: color 0.25s;
}

.games-footer-links a:hover { color: #818CF8; }

.games-footer p {
    font-size: 0.8rem;
    color: rgba(255,255,255,0.2);
}

/* --- Focus & Selection --- */
a:focus-visible { outline: 2px solid #818CF8; outline-offset: 2px; }
::selection { background: rgba(99, 102, 241, 0.25); color: #fff; }

/* --- Responsive --- */
@media (max-width: 480px) {
    h1 { font-size: 2.8rem; }
    .games-icon { font-size: 4rem; }
    .games-main { padding: 60px 20px; }
}
