/* --- CSS Variables & Reset --- */
:root {
    --bg-color: #0b0e14;
    --bg-alt: #111620;
    --text-main: #e2e8f0;
    --text-muted: #94a3b8;
    --primary: #6366f1; /* Indigo */
    --primary-hover: #4f46e5;
    --accent: #ec4899; /* Pink */
    --gradient: linear-gradient(135deg, var(--primary), var(--accent));
    --glass: rgba(17, 22, 32, 0.85);
    --border: #1e293b;
    --font-main: 'Outfit', sans-serif;
    --container-width: 1200px;
    --radius: 12px;
    --transition: all 0.3s ease;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-main);
    background-color: var(--bg-color);
    color: var(--text-main);
    line-height: 1.6;
    overflow-x: hidden;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

ul {
    list-style: none;
}

img {
    max-width: 100%;
    display: block;
    border-radius: var(--radius);
}

/* --- Utility Classes --- */
.container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 20px;
}

.section {
    padding: 80px 0;
}

.bg-alt {
    background-color: var(--bg-alt);
}

.section-title {
    font-size: 2.5rem;
    margin-bottom: 50px;
    text-align: center;
    background: var(--gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    font-weight: 700;
}

.btn {
    display: inline-block;
    padding: 12px 30px;
    border-radius: 50px;
    font-weight: 600;
    cursor: pointer;
    border: none;
    transition: var(--transition);
}

.btn-primary {
    background: var(--gradient);
    color: white;
    box-shadow: 0 4px 15px rgba(99, 102, 241, 0.4);
}

    .btn-primary:hover {
        transform: translateY(-2px);
        box-shadow: 0 8px 25px rgba(99, 102, 241, 0.6);
    }

.btn-outline {
    background: transparent;
    border: 2px solid var(--primary);
    color: white;
}

    .btn-outline:hover {
        background: var(--primary);
    }

.btn-large {
    padding: 15px 40px;
    font-size: 1.1rem;
}

.full-width {
    width: 100%;
}

/* --- Header & Nav --- */
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    background: var(--glass);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border);
    padding: 15px 0;
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 1.5rem;
    font-weight: 800;
    letter-spacing: -1px;
}

    .logo .highlight {
        color: var(--primary);
    }

.nav-menu ul {
    display: flex;
    align-items: center;
    gap: 30px;
}

.nav-menu a {
    font-weight: 500;
    color: var(--text-muted);
}

    .nav-menu a:hover {
        color: var(--primary);
    }

.hamburger {
    display: none;
    cursor: pointer;
}

    .hamburger span {
        display: block;
        width: 25px;
        height: 3px;
        background: white;
        margin: 5px 0;
        transition: var(--transition);
    }

/* --- Hero Section --- */
.hero {
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    background: radial-gradient(circle at center, #1e1b4b 0%, var(--bg-color) 70%);
    padding-top: 60px; /* Offset for header */
}

.hero-content h1 {
    font-size: 4rem;
    line-height: 1.1;
    margin-bottom: 20px;
}

.gradient-text {
    background: var(--gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero-content p {
    font-size: 1.2rem;
    color: var(--text-muted);
    margin-bottom: 40px;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.hero-buttons {
    display: flex;
    gap: 20px;
    justify-content: center;
}

/* --- Games Grid --- */
.games-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 30px;
}

.game-card {
    background: var(--bg-alt);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
    transition: var(--transition);
}

    .game-card:hover {
        transform: translateY(-10px);
        border-color: var(--primary);
        box-shadow: 0 10px 30px rgba(0,0,0,0.5);
    }

.card-image-wrapper {
    position: relative;
    height: 220px;
    overflow: hidden;
}

    .card-image-wrapper img {
        width: 100%;
        height: 100%;
        object-fit: cover;
        transition: transform 0.5s ease;
    }

.game-card:hover .card-image-wrapper img {
    transform: scale(1.05);
}

.card-overlay {
    position: absolute;
    top: 15px;
    right: 15px;
}

.tag {
    background: rgba(0,0,0,0.7);
    color: var(--accent);
    padding: 5px 12px;
    border-radius: 4px;
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
}

.card-content {
    padding: 25px;
}

    .card-content h3 {
        font-size: 1.5rem;
        margin-bottom: 10px;
        color: white;
    }

    .card-content p {
        color: var(--text-muted);
        margin-bottom: 20px;
        font-size: 0.95rem;
    }

.card-link {
    color: var(--primary);
    font-weight: 700;
    font-size: 0.9rem;
}

    .card-link:hover {
        text-decoration: underline;
    }

/* --- About Section --- */
.about-wrapper {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    align-items: center;
}

.about-text p {
    margin-bottom: 20px;
    color: var(--text-muted);
}

.stats {
    display: flex;
    gap: 40px;
    margin-top: 30px;
}

    .stats h4 {
        font-size: 2rem;
        color: white;
    }

    .stats span {
        color: var(--primary);
        text-transform: uppercase;
        font-size: 0.8rem;
        letter-spacing: 1px;
    }

/* --- Press Kit --- */
.press-desc {
    text-align: center;
    margin-bottom: 40px;
    color: var(--text-muted);
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.press-links {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
}

.press-card {
    background: var(--bg-alt);
    padding: 30px;
    border-radius: var(--radius);
    text-align: center;
    border: 1px solid var(--border);
    transition: var(--transition);
}

    .press-card:hover {
        border-color: var(--primary);
        background: #161d2b;
    }

    .press-card .icon {
        font-size: 2.5rem;
        margin-bottom: 15px;
    }

    .press-card h3 {
        margin-bottom: 10px;
    }

    .press-card p {
        color: var(--text-muted);
        font-size: 0.9rem;
    }

/* --- Contact Section --- */
.contact-wrapper {
    display: grid;
    grid-template-columns: 1.5fr 1fr;
    gap: 50px;
}

.form-group {
    margin-bottom: 20px;
}

    .form-group label {
        display: block;
        margin-bottom: 8px;
        font-size: 0.9rem;
        color: var(--text-muted);
    }

    .form-group input, .form-group textarea {
        width: 100%;
        padding: 12px 15px;
        background: var(--bg-color);
        border: 1px solid var(--border);
        border-radius: 8px;
        color: white;
        font-family: inherit;
    }

        .form-group input:focus, .form-group textarea:focus {
            outline: none;
            border-color: var(--primary);
        }

.contact-info {
    padding: 20px;
    background: var(--bg-color);
    border-radius: var(--radius);
}

    .contact-info h3 {
        margin-bottom: 15px;
        color: white;
    }

    .contact-info > p {
        color: var(--text-muted);
        margin-bottom: 30px;
    }

.info-item {
    margin-bottom: 15px;
}

    .info-item .label {
        display: block;
        color: var(--text-muted);
        font-size: 0.8rem;
    }

    .info-item a, .info-item span {
        color: white;
        font-weight: 500;
    }

.social-links {
    margin-top: 30px;
    display: flex;
    gap: 15px;
}

    .social-links a {
        color: var(--text-muted);
        font-size: 0.9rem;
    }

        .social-links a:hover {
            color: var(--accent);
        }

/* --- Footer --- */
.footer {
    padding: 40px 0;
    text-align: center;
    border-top: 1px solid var(--border);
    color: var(--text-muted);
    font-size: 0.9rem;
}

/* --- Animations --- */
.fade-in {
    opacity: 0;
    transform: translateY(20px);
    animation: fadeInUp 0.8s forwards;
}



/* --- Video Modal Styles --- */
.video-modal {
    display: none; /* پیش‌فرض مخفی */
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    z-index: 2000;
    justify-content: center;
    align-items: center;
}

.modal-overlay {
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background: rgba(0, 0, 0, 0.9); /* پس زمینه تیره و محو */
    backdrop-filter: blur(5px);
}

.modal-content {
    position: relative;
    width: 90%;
    max-width: 900px;
    z-index: 2001;
    background: transparent;
}

.close-btn {
    position: absolute;
    top: -40px;
    right: 0;
    background: none;
    border: none;
    color: white;
    font-size: 2.5rem;
    cursor: pointer;
    transition: 0.3s;
}

.close-btn:hover { color: var(--accent); transform: rotate(90deg); }

.video-wrapper {
    position: relative;
    padding-bottom: 56.25%;  
    height: 0;
    overflow: hidden;
    border-radius: 12px;
    box-shadow: 0 0 50px rgba(99, 102, 241, 0.3);
    background: black;
}

.video-wrapper iframe {
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
}
 
.video-btn {
    cursor: pointer; 
}
.video-btn:hover {
    border-color: var(--primary);
    transform: translateY(-5px);
}


@keyframes fadeInUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* --- Responsive Design --- */
@media (max-width: 768px) {
    .hero-content h1 {
        font-size: 2.5rem;
    }

    .hamburger {
        display: block;
        z-index: 1001;
    }

    .nav-menu {
        position: fixed;
        top: 0;
        right: -100%;
        width: 70%;
        height: 100vh;
        background: var(--bg-alt);
        padding: 80px 30px;
        transition: 0.4s ease;
        box-shadow: -5px 0 15px rgba(0,0,0,0.5);
    }

        .nav-menu.active {
            right: 0;
        }

        .nav-menu ul {
            flex-direction: column;
            align-items: flex-start;
        }

    .about-wrapper, .contact-wrapper {
        grid-template-columns: 1fr;
    }

    .hero-buttons {
        flex-direction: column;
    }
}
