/* Custom CSS */
:root {
    --bg-dark: #f8f9fa;
    /* Light gray for alternating sections */
    --bg-surface: #ffffff;
    /* White for main surface */
    --text-primary: #111827;
    /* Dark slate text */
    --text-secondary: #4b5563;
    /* Medium gray text */
    --accent: #2563eb;
    /* Vibrant blue */
    --accent-hover: #1d4ed8;
    /* Darker blue */
    --glass-bg: rgba(255, 255, 255, 0.85);
    --glass-border: rgba(0, 0, 0, 0.05);
    --font-main: 'Inter', system-ui, -apple-system, sans-serif;
    --nav-height: 80px;
    --transition: 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-main);
    background-color: var(--bg-surface);
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

li {
    list-style: none;
}

.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

/* Typography */
h1,
h2,
h3,
h4 {
    line-height: 1.2;
    font-weight: 700;
    color: var(--text-primary);
}

.section-title {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    letter-spacing: -0.02em;
}

.section-subtitle {
    font-size: 1.125rem;
    color: var(--text-secondary);
    margin-bottom: 3rem;
    font-weight: 500;
    text-align: center;
    max-width: 600px;
}

.section-desc {
    font-size: 1.125rem;
    color: var(--text-secondary);
    font-weight: 500;
    margin-bottom: 1.5rem;
}

.text-center {
    text-align: center;
}

.mt-3 {
    margin-top: 1.5rem;
}

.mt-4 {
    margin-top: 2rem;
}

.mt-5 {
    margin-top: 3rem;
}

.mx-auto {
    margin-left: auto;
    margin-right: auto;
}

.max-w-md {
    max-width: 800px;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 28px;
    font-size: 1rem;
    font-weight: 600;
    border-radius: 9999px;
    transition: var(--transition);
    cursor: pointer;
    border: none;
}

.btn-primary {
    background-color: var(--accent);
    color: white;
}

.btn-primary:hover {
    background-color: var(--accent-hover);
    transform: translateY(-2px);
    box-shadow: 0 10px 20px -10px var(--accent);
}

.btn-secondary {
    background-color: transparent;
    color: var(--text-primary);
    border: 1px solid #d1d5db;
}

.btn-secondary:hover {
    background-color: #f3f4f6;
    border-color: #9ca3af;
    transform: translateY(-2px);
}

/* App Store Button */
.btn-appstore {
    background-color: #000000;
    color: #ffffff;
    font-weight: 600;
    font-size: 1.125rem;
    padding: 16px 40px;
    gap: 0.75rem;
    border-radius: 100px;
}

.btn-appstore::before {
    content: '';
    display: inline-block;
    width: 24px;
    height: 24px;
    background: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 384 512"><path fill="%23ffffff" d="M318.7 268.7c-.2-36.7 16.4-64.4 50-84.8-18.8-26.9-47.2-41.7-84.7-44.6-35.5-2.8-74.3 20.7-88.5 20.7-15 0-49.4-19.7-76.4-19.7C63.3 141.2 4 184.8 4 273.5q0 39.3 14.4 81.2c12.8 36.7 59 126.7 107.2 125.2 25.2-.6 43-17.9 75.8-17.9 31.8 0 48.3 17.9 76.4 17.9 48.6-.7 90.4-82.5 102.6-119.3-65.2-30.7-61.7-90-61.7-91.9zm-56.6-164.2c27.3-32.4 24.8-61.9 24-72.5-24.1 1.4-52 16.4-67.9 34.9-17.5 19.8-27.8 44.3-25.6 71.9 26.1 2 49.9-11.4 69.5-34.3z"/></svg>') no-repeat center;
    background-size: contain;
}

.btn-appstore:hover {
    transform: translateY(-2px);
    box-shadow: none;
    background-color: #333333;
}

/* Glassmorphism / Cards for Light Theme */
.glass-card {
    background: #ffffff;
    border: 1px solid var(--glass-border);
    border-radius: 20px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.03);
    overflow: hidden;
}

/* --- NAVIGATION HEADER --- */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: var(--nav-height);
    z-index: 1000;
    background-color: transparent;
    transition: background-color 0.3s ease, border-bottom 0.3s ease, box-shadow 0.3s ease;
    border-bottom: 1px solid transparent;
}

.navbar.scrolled {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--glass-border);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.03);
}

.nav-container {
    width: 100%;
    height: 100%;
    padding: 0 48px;
    /* Classic wide padding */
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo-col {
    display: flex;
    justify-content: flex-start;
}

.nav-col {
    display: flex;
    justify-content: flex-end;
}

.action-col {
    display: none;
}

.logo {
    font-size: 1.5rem;
    font-weight: 700;
    letter-spacing: -0.05em;
    color: var(--text-primary);
}

.logo span {
    color: var(--accent);
}

.nav-list {
    display: flex;
    align-items: center;
    gap: 2.5rem;
}

.nav-item {
    position: relative;
    height: var(--nav-height);
    display: flex;
    align-items: center;
}

.nav-link {
    font-size: 0.95rem;
    font-weight: 900;
    letter-spacing: 0.05em;
    color: var(--text-secondary);
    position: relative;
    padding: 0.5rem 0;
}

.nav-link:hover,
.nav-link.active {
    color: var(--accent);
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0%;
    height: 2px;
    background-color: var(--accent);
    transition: var(--transition);
}

.nav-link:hover::after,
.nav-link.active::after {
    width: 100%;
}

.mobile-menu-btn {
    display: none;
    position: absolute;
    right: 24px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    cursor: pointer;
    width: 30px;
    height: 20px;
    z-index: 1001;
}

.hamburger {
    display: block;
    width: 100%;
    height: 2px;
    background-color: var(--text-primary);
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    transition: var(--transition);
}

.hamburger::before,
.hamburger::after {
    content: '';
    position: absolute;
    width: 100%;
    height: 2px;
    background-color: var(--text-primary);
    left: 0;
    transition: var(--transition);
}

.hamburger::before {
    top: -8px;
}

.hamburger::after {
    bottom: -8px;
}

.mobile-menu-btn.active .hamburger {
    background-color: transparent;
}

.mobile-menu-btn.active .hamburger::before {
    top: 0;
    transform: rotate(45deg);
}

.mobile-menu-btn.active .hamburger::after {
    bottom: 0;
    transform: rotate(-45deg);
}

/* Main layout / Sections */
.section {
    padding: 8rem 0;
}

/* Hero Section */
.hero {
    min-height: 75vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    position: relative;
    overflow: hidden;
}

/* Modern Animated Background Objects */
.hero::before {
    content: '';
    position: absolute;
    width: 60vw;
    height: 60vw;
    background: radial-gradient(circle, rgba(37, 99, 235, 0.08) 0%, transparent 60%);
    border-radius: 50%;
    top: -20%;
    left: -10%;
    animation: drift 15s infinite alternate ease-in-out;
    filter: blur(60px);
    z-index: 0;
    pointer-events: none;
}

.hero::after {
    content: '';
    position: absolute;
    width: 50vw;
    height: 50vw;
    background: radial-gradient(circle, rgba(147, 51, 234, 0.08) 0%, transparent 60%);
    border-radius: 50%;
    bottom: -10%;
    right: -10%;
    animation: drift 20s infinite alternate-reverse ease-in-out;
    filter: blur(60px);
    z-index: 0;
    pointer-events: none;
}

@keyframes drift {
    0% {
        transform: translate(0px, 0px) scale(1);
    }

    100% {
        transform: translate(100px, 50px) scale(1.1);
    }
}

.hero-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: var(--bg-surface);
    background-image: radial-gradient(#d1d5db 1px, transparent 1px);
    background-size: 32px 32px;
    opacity: 0.3;
    z-index: -2;
}

.hero-content {
    position: relative;
    z-index: 1;
    max-width: 800px;
    margin: 0 auto;
}

.hero-title {
    font-size: clamp(3rem, 6vw, 5rem);
    letter-spacing: -0.03em;
    margin-bottom: 1.5rem;
    line-height: 1.1;
}

.hero-title span {
    color: var(--accent);
}

.hero-subtitle {
    font-size: clamp(1.125rem, 2vw, 1.35rem);
    color: var(--text-secondary);
    font-weight: 500;
    max-width: 600px;
    margin: 0 auto 2.5rem;
}

/* About Section */
.about-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.about-image {
    aspect-ratio: 4/3;
    padding: 0;
}

.about-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 14px;
}

/* Games Section */
.section-dark {
    background-color: var(--bg-dark);
}

.games-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    width: 100%;
}

.game-card {
    transition: var(--transition);
    display: flex;
    flex-direction: column;
}

.game-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.08);
}

.game-card-img {
    aspect-ratio: 16/9;
    overflow: hidden;
    width: 100%;
}

.game-card-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    display: block;
    transition: transform 0.7s ease;
}

.game-card:hover .game-card-img img {
    transform: scale(1.05);
}

.game-card-content {
    padding: 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.game-title {
    font-size: 1.5rem;
}

.game-link {
    color: var(--text-secondary);
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.game-link .arrow {
    transition: transform 0.3s ease;
}

.game-link:hover {
    color: var(--accent);
}

.game-card:hover .game-link .arrow {
    transform: translateX(5px);
    color: var(--accent);
}

.page-hero {
    padding: 7rem 0 3rem;
    position: relative;
}

.hero-glow {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 60vw;
    height: 40vw;
    background: radial-gradient(circle, rgba(37, 99, 235, 0.08) 0%, transparent 70%);
    z-index: -1;
    filter: blur(40px);
    pointer-events: none;
}

.game-details-section {
    padding-bottom: 8rem;
}

.game-list {
    display: flex;
    flex-direction: column;
    gap: 8rem;
}

.game-showcase {
    overflow: hidden;
}

.game-showcase-header {
    margin-bottom: 2rem;
}

.game-detail-title {
    font-size: 3.5rem;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.game-detail-desc {
    color: var(--text-secondary);
    font-size: 1.25rem;
    font-weight: 500;
    max-width: 700px;
    line-height: 1.7;
    text-align: center;
    /* Enforcing text center */
}

/* Screenshots Layout */
.game-screenshots {
    display: flex;
    gap: 1.5rem;
    justify-content: center;
    align-items: center;
    padding: 2rem 0;
}

.rounded-screenshot {
    width: 23.5%;
    max-width: 250px;
    aspect-ratio: 1242 / 2688;
    object-fit: cover;
    border-radius: 28px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    border: 1px solid rgba(0, 0, 0, 0.05);
    transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275), box-shadow 0.4s ease;
    cursor: pointer;
    flex-shrink: 0;
}

.rounded-screenshot:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.15);
}

/* --- FOOTER --- */
.footer {
    background: #0f172a;
    /* Dark background */
    border-top: 1px solid #1e293b;
    padding: 4rem 24px 2rem;
}

.footer-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
}

.footer-top {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2rem;
    margin-bottom: 3rem;
}

.footer-logo {
    font-size: 2rem;
    color: #f8fafc;
}

.footer-nav {
    display: flex;
    align-items: center;
    gap: 2rem;
    flex-wrap: wrap;
    justify-content: center;
}

.footer-nav li a {
    font-weight: 600;
    color: #cbd5e1;
    font-size: 0.95rem;
    letter-spacing: 0.05em;
}

.footer-nav li a:hover {
    color: var(--accent);
}

.footer-divider {
    height: 1px;
    background-color: #1e293b;
    width: 100%;
    margin-bottom: 2rem;
}

.footer-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
    color: #94a3b8;
    font-size: 0.875rem;
}

.footer-bottom-left {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.footer-email {
    color: #f8fafc;
    font-weight: 500;
}

.footer-email:hover {
    color: var(--accent);
}

.footer-bottom-left .copyright::before {
    content: "•";
    margin: 0 0.5rem;
    color: #475569;
}

.footer-bottom-right {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.footer-bottom-right a:hover {
    color: #f8fafc;
}

.separator {
    color: #475569;
}

/* Animations */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.reveal.active {
    opacity: 1;
    transform: translateY(0);
}

/* Responsive Design */
@media (max-width: 900px) {
    .hero-content {
        margin: 0 auto;
        text-align: center;
    }

    .hero-subtitle {
        margin: 0 auto 2.5rem auto;
    }

    .about-container {
        grid-template-columns: 1fr;
    }

    /* 2x2 Grid for game screenshots on mobile/tablet */
    .game-screenshots {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 1.5rem;
        padding: 2rem;
        max-width: 600px;
        margin: 0 auto;
    }

    .rounded-screenshot {
        width: 100%;
        max-width: none;
        box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
    }

    .nav-container {
        padding: 0 24px;
    }

    .footer-bottom {
        flex-direction: column;
        justify-content: center;
        text-align: center;
    }

    .footer-bottom-left {
        flex-direction: column;
    }

    .footer-bottom-left .copyright::before {
        display: none;
    }
}

@media (max-width: 768px) {
    .nav-container {
        grid-template-columns: auto 1fr;
    }

    .nav-col {
        justify-content: flex-end;
    }

    .action-col {
        display: none;
    }

    .mobile-menu-btn {
        display: block;
    }

    .nav-menu {
        position: fixed;
        top: var(--nav-height);
        left: 0;
        width: 100%;
        height: calc(100vh - var(--nav-height));
        background: rgba(255, 255, 255, 0.98);
        backdrop-filter: blur(20px);
        transform: translateX(100%);
        transition: transform 0.4s ease;
        padding: 2rem;
        overflow-y: auto;
    }

    .nav-menu.active {
        transform: translateX(0);
    }

    .nav-list {
        flex-direction: column;
        align-items: flex-start;
        gap: 0;
    }

    .nav-item {
        width: 100%;
        height: auto;
        flex-direction: column;
        align-items: flex-start;
        border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    }

    .nav-link {
        width: 100%;
        padding: 1.5rem 0;
        font-size: 1.125rem;
        color: var(--text-primary);
    }
}

@media (max-width: 480px) {
    .game-screenshots {
        gap: 1rem;
        padding: 1rem;
    }

    .game-detail-title {
        font-size: 2.5rem;
    }
}