@font-face {
    font-family: 'Gluten';
    src: url('fonts/Gluten-Regular.ttf') format('truetype'),
         url('fonts/Gluten-Regular.woff') format('woff');
    font-weight: normal;
    font-style: normal;
}
@font-face {
    font-family: 'Quicksand';
    src: url('fonts/Quicksand-Light.ttf') format('truetype');
    font-weight: 300;
    font-style: normal;
}
@font-face {
    font-family: 'Quicksand';
    src: url('fonts/Quicksand-Regular.ttf') format('truetype');
    font-weight: 400;
    font-style: normal;
}
@font-face {
    font-family: 'Quicksand';
    src: url('fonts/Quicksand-Medium.ttf') format('truetype');
    font-weight: 500;
    font-style: normal;
}
@font-face {
    font-family: 'NotoSansSC';
    src: url('fonts/NotoSansSC-Medium.ttf') format('truetype');
    font-weight: 400;
    font-style: normal;
}
@font-face {
    font-family: 'NotoSansJP';
    src: url('fonts/NotoSansJP-Medium.ttf') format('truetype');
    font-weight: 400;
    font-style: normal;
}

:root {
    --deep-green: #012c13;
    --fog-green: #023a1c;
    --clear-green: #025a1c;
    --starlight: #e2e8f0;
    --accent-gold: #fce732;
    --glass-white: rgba(255, 255, 255, 0.05);
    --elegant-bronze: #a89f91;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background-color: var(--deep-green);
    color: var(--starlight);
    font-family: 'Quicksand', 'NotoSansJP', 'NotoSansSC', sans-serif;
    overflow-x: hidden;
    min-height: 100vh;
    width: 100vw;
    overflow-y: auto;
}

.ambient-background {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: radial-gradient(circle at 50% 50%, var(--fog-green) 0%, #001a0a 80%);
    z-index: -2;
    transition: transform 0.2s ease-out;
}

.noise-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0.03;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.8' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)'/%3E%3C/svg%3E");
    z-index: -1;
    pointer-events: none;
}

nav {
    position: fixed;
    top: 0;
    width: 100%;
    padding: 40px 60px;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    z-index: 100;
}

.nav-logo {
    font-family: 'Gluten', 'NotoSansJP', 'NotoSansSC', sans-serif;
    font-size: 1.2rem;
    color: var(--fog-green);
    text-decoration: none;
    letter-spacing: 1px;
    opacity: 0.8;
    transition: opacity 0.3s;
    mix-blend-mode: overlay;
}

.nav-logo:hover { opacity: 1; }

#nav-topright {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    z-index: 101;
}

#chosenLanguage {
    font-family: 'Quicksand', 'NotoSansJP', 'NotoSansSC', sans-serif;
    font-size: small;
    text-decoration: none;
    color: var(--clear-green);
    background-color: var(--deep-green);
    border-color: var(--fog-green);
    border-radius: 10%;
    padding: 6px;
    letter-spacing: 2px;
    transition: border 0.3s;
    width: 120px;
    mix-blend-mode: overlay;
}

main {
    position: relative;
    z-index: 10;
}

.hero-section {
    height: 60vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    perspective: 1000px;
    position: relative;
}

.hero-content {
    text-align: center;
    transform-style: preserve-3d;
}

h1 {
    font-family: 'Gluten', 'NotoSansJP', 'NotoSansSC', sans-serif;
    font-size: 3.5rem;
    font-weight: 300;
    margin-bottom: 20px;
    line-height: 1.1;
    background: linear-gradient(180deg, #fff 0%, #aabdc6 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    opacity: 0;
    animation: fadeUp 1.5s ease-out 0.3s forwards;
}

.hero-subtitle {
    font-size: 1.1rem;
    max-width: 700px;
    margin: 0 auto;
    color: #8da399;
    font-weight: 300;
    line-height: 1.6;
    opacity: 0;
    animation: fadeUp 1.5s ease-out 0.6s forwards;
}

.scroll-line {
    position: absolute;
    bottom: 0;
    width: 1px;
    height: 80px;
    background: linear-gradient(to bottom, var(--starlight), transparent);
    left: 50%;
    opacity: 0.3;
}

.games-section {
    padding: 100px 20px 150px;
    display: flex;
    justify-content: center;
}

.games-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 50px;
    max-width: 1000px;
    width: 100%;
}

.game-card {
    opacity: 0;
    transform: translateY(50px);
    transition: all 1s ease-out;
}

.game-card.visible {
    opacity: 1;
    transform: translateY(0);
}

.game-link {
    display: block;
    text-decoration: none;
    color: inherit;
    transition: transform 0.3s ease;
}

.game-link:hover {
    transform: translateY(-10px);
}

.game-image-wrapper {
    position: relative;
    border-radius: 24px;
    overflow: hidden;
    aspect-ratio: 1/1;
    background: linear-gradient(135deg, rgba(255,255,255,0.05) 0%, rgba(255,255,255,0.02) 100%);
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 20px 50px rgba(0,0,0,0.3);
    margin-bottom: 24px;
}

.game-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.game-link:hover .game-image {
    transform: scale(1.05);
}

.game-info {
    padding: 0 12px;
}

.game-title {
    font-family: 'Gluten', 'NotoSansJP', 'NotoSansSC', sans-serif;
    font-size: 2rem;
    margin-bottom: 12px;
    color: var(--starlight);
    transition: color 0.3s ease;
}

.game-link:hover .game-title {
    color: var(--accent-gold);
}

.game-description {
    font-size: 1rem;
    color: #94a3b8;
    line-height: 1.6;
    font-weight: 300;
}

hr {
    border: none;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    margin: 80px auto;
    max-width: 1200px;
}

.footer-section {
    padding: 60px 20px;
    text-align: center;
}

#copyrightText {
    font-family: 'Quicksand', 'NotoSansJP', 'NotoSansSC', sans-serif;
    font-size: 0.9rem;
    color: #6b7280;
    font-weight: 300;
    letter-spacing: 1px;
}

@keyframes fadeUp {
    to { opacity: 1; transform: translateY(0); }
}

@media (max-width: 968px) {
    .games-grid {
        grid-template-columns: 1fr;
        gap: 60px;
        max-width: 500px;
    }
    
    h1 {
        font-size: 2.5rem;
    }
    
    nav {
        padding: 30px 40px;
    }
}

@media (max-width: 600px) {
    .games-grid {
        max-width: 350px;
    }
    
    h1 {
        font-size: 2rem;
    }
    
    .hero-subtitle {
        font-size: 1rem;
    }
    
    .game-title {
        font-size: 1.6rem;
    }
    
    .game-description {
        font-size: 0.95rem;
    }
    
    nav {
        padding: 20px 30px;
    }
    
    .nav-logo {
        font-size: 1rem;
    }
    
    #chosenLanguage {
        width: 100px;
        font-size: 0.8rem;
    }
}