:root {
    --bg: #0a0a12;
    --panel: #12121d;
    --panel-2: #191927;
    --accent-a: #d4a537;
    --accent-b: #e0b84d;
    --text: #f0f1f5;
    --muted: #8c90a6;
    --turquoise: #40e0d0;
    --line: rgba(240, 241, 245, 0.08);
}

/* ===== RESET ===== */
* { box-sizing: border-box; }
html {
    scroll-behavior: smooth;
    scroll-padding-top: 90px;
}
body {
    margin: 0;
    min-height: 100vh;
    background: var(--bg);
    color: var(--text);
    font-family: 'Inter', sans-serif;
    overflow-x: clip;
    line-height: 1.5;
}

/* ===== BACKGROUND EFFECT ===== */
body::before {
    content: "";
    position: fixed;
    inset: 0;
    background-image:
        radial-gradient(circle at 20% 20%, rgba(212, 165, 55, 0.10), transparent 40%),
        radial-gradient(circle at 80% 70%, rgba(224, 184, 77, 0.08), transparent 40%);
    pointer-events: none;
    z-index: 0;
}
body > * {
    position: relative;
    z-index: 1;
}

/* ===== TYPOGRAPHY ===== */
.eyebrow,
.eyebrow2 {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.72rem;
    letter-spacing: 0.18em;
    text-transform: uppercase;
}
.eyebrow { color: var(--accent-b); }
.eyebrow2 { color: var(--turquoise); }
h1, h2, h3 {
    font-family: 'Space Grotesk', sans-serif;
    margin: 0;
}
a {
    color: inherit;
    text-decoration: none;
}
button,
input,
textarea,
select {
    font: inherit;
}

/* ===== NAVIGATION ===== */
nav {
    position: sticky;
    top: 0;
    z-index: 50;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.5rem;
    padding: 1.1rem 6vw;
    background: rgba(10, 10, 18, 0.85);
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--line);
}
.logo {
    font-family: 'JetBrains Mono', monospace;
    font-weight: 700;
    letter-spacing: 0.05em;
    white-space: nowrap;
}
.logo span { color: var(--accent-a); }
nav .links {
    display: flex;
    align-items: center;
    gap: 2rem;
    font-size: 0.85rem;
    color: var(--muted);
}
nav .links a { transition: color 0.2s ease; }
nav .links a:hover,
nav .links a:focus-visible { color: var(--text); }

/* ===== HERO ===== */
.hero {
    position: relative;
    min-height: 88vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 4rem 6vw 2rem;
}
.boot-line {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    margin-bottom: 1.4rem;
    font-family: 'JetBrains Mono', monospace;
    color: var(--muted);
    font-size: 0.8rem;
}
.boot-line .dot {
    flex: 0 0 8px;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--accent-b);
    box-shadow: 0 0 10px var(--accent-b);
    animation: pulse 1.6s ease-in-out infinite;
}
.hero h1 {
    max-width: 100%;
    font-size: clamp(2.6rem, 7vw, 5.2rem);
    line-height: 1.02;
    font-weight: 700;
    background: linear-gradient(120deg, var(--text) 40%, var(--accent-a) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    color: transparent;
}
.hero p.sub {
    max-width: 560px;
    margin: 1.2rem 0 0;
    color: var(--muted);
    font-size: 1.05rem;
    line-height: 1.7;
}
.press-start {
    display: inline-block;
    margin-top: 2.6rem;
    padding: 0.9rem 1.8rem;
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.85rem;
    letter-spacing: 0.08em;
    color: var(--text);
    background: transparent;
    border: 1px solid var(--accent-a);
    border-radius: 2px;
    cursor: pointer;
    text-decoration: none;
    transition: background 0.2s ease, color 0.2s ease, box-shadow 0.2s ease;
}
.press-start:hover,
.press-start:focus-visible {
    background: var(--accent-a);
    color: var(--bg);
    box-shadow: 0 0 20px rgba(212, 165, 55, 0.2);
}
@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.3; }
}

/* ===== SECTION HEADERS ===== */
.section-head { margin-bottom: 2rem; }
.section-head h2 {
    margin-top: 0.5rem;
    font-size: 1.6rem;
}

/* ===== GAME SHOWCASE ===== */
.games-section,
.websites-section {
    position: relative;
    width: 100%;
    max-width: 1000px;
    margin: 0 auto 6rem;
    padding: 0 6vw;
}
.game-card {
    position: relative;
    overflow: hidden;
    margin-bottom: 1.6rem;
    padding: 2.2rem;
    background: var(--panel);
    border: 1px solid var(--line);
    border-radius: 10px;
}
.game-card::after {
    content: "";
    position: absolute;
    inset: 0;
    background: repeating-linear-gradient(to bottom, rgba(255, 255, 255, 0.02) 0px, rgba(255, 255, 255, 0.02) 1px, transparent 1px, transparent 3px);
    pointer-events: none;
}
.tag-row {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin: 0.9rem 0 1.2rem;
}
.tag {
    padding: 0.25rem 0.6rem;
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.7rem;
    color: var(--accent-b);
    border: 1px solid var(--line);
    border-radius: 20px;
}
.game-card h3 {
    margin-bottom: 0.3rem;
    font-size: 1.6rem;
}
.game-card p {
    max-width: 620px;
    color: var(--muted);
    line-height: 1.65;
}
.game-card .cta {
    display: inline-flex;
    flex-wrap: wrap;
    gap: 1rem;
    margin-top: 1.4rem;
}
.game-card .cta a {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.78rem;
    color: var(--accent-a);
    border-bottom: 1px solid transparent;
    transition: border-color 0.2s ease;
}
.game-card .cta a:hover,
.game-card .cta a:focus-visible {
    border-bottom-color: var(--accent-a);
}

/* ===== IMAGE GALLERY ===== */
.gallery {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(220px, 100%), 1fr));
    gap: 0.8rem;
    margin-top: 1.4rem;
}
.gallery figure {
    margin: 0;
    min-width: 0;
    overflow: hidden;
    background: #000;
    border: 1px solid var(--line);
    border-radius: 6px;
}
.gallery img {
    display: block;
    width: 100%;
    aspect-ratio: 16 / 9;
    object-fit: cover;
    transition: transform 0.4s ease;
}
.gallery figure:hover img { transform: scale(1.04); }
.gallery figcaption {
    padding: 0.5rem 0.7rem;
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.68rem;
    color: var(--muted);
    border-top: 1px solid var(--line);
}

/* ===== WEBSITES SHOWCASE ===== */
.websites-section { margin-bottom: 6rem; }

/* ===== UPCOMING PROJECTS ===== */
.upcoming-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(220px, 100%), 1fr));
    gap: 1rem;
}
.upcoming-card {
    padding: 1.4rem 1.2rem;
    background: var(--panel-2);
    border: 1px dashed var(--line);
    border-radius: 8px;
    opacity: 0.65;
}
.upcoming-card .title {
    font-family: 'Space Grotesk', sans-serif;
    font-weight: 700;
    font-size: 1rem;
    color: var(--muted);
}
.upcoming-card .tag-row { margin: 0.5rem 0 0; }
.upcoming-card .note {
    margin-top: 0.4rem;
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.72rem;
    color: var(--muted);
}

/* ===== FOOTER ===== */
footer {
    position: relative;
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 1rem;
    padding: 2.4rem 6vw;
    color: var(--muted);
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.75rem;
    border-top: 1px solid var(--line);
}

/* ===== ACCESSIBILITY ===== */
:focus-visible {
    outline: 2px solid var(--accent-b);
    outline-offset: 4px;
}

/* ===== TABLETS AND MOBILE ===== */
@media (max-width: 640px) {
    nav { padding: 1rem 5vw; }
    nav .links { display: none; }
    .hero {
        min-height: 75vh;
        padding: 3rem 5vw 2rem;
    }
    .hero p.sub { font-size: 0.95rem; }
    .games-section,
    .websites-section {
        padding: 0 5vw;
        margin-bottom: 4rem;
    }
    .game-card { padding: 1.4rem; }
    .game-card h3 { font-size: 1.35rem; }
    .gallery { grid-template-columns: 1fr; }
    footer {
        flex-direction: column;
        padding: 2rem 5vw;
    }
}

/* ===== REDUCED MOTION ===== */
@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}