/* --- General Setup & Variables --- */
:root {
    --primary-color: #6a11cb;
    --secondary-color: #2575fc;
    --dark-color: #333;
    --light-color: #f4f4f4;
    --white-color: #fff;
    --font-family: 'Poppins', sans-serif;
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-family);
    line-height: 1.6;
    background-color: var(--white-color);
    color: var(--dark-color);
}

.container {
    max-width: 1100px;
    margin: auto;
    padding: 4rem 2rem;
    overflow-x: hidden;
}

h1, h2, h3 {
    font-weight: 600;
    line-height: 1.2;
}

h2 {
    font-size: 2.5rem;
    text-align: center;
    margin-bottom: 1rem;
}

.section-subtitle {
    text-align: center;
    max-width: 600px;
    margin: 0 auto 3rem auto;
    font-size: 1.1rem;
    color: #666;
}

.highlight {
    color: var(--primary-color);
}

.cta-button {
    margin-top: 1.5rem;
    display: inline-block;
    padding: 12px 28px;
    background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
    color: var(--white-color);
    text-decoration: none;
    border-radius: 50px;
    font-weight: 600;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.light {
 background-color: var(--light-color);
}
.center {
    text-align: center;
}
.cta-button:hover {
    color: pink;
    transform: translateY(-3px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.1);
}

/* --- 1. Header & Hero Section --- */
.hero {
    height: 90vh;
    background: linear-gradient(rgba(255, 255, 255, 0.8), rgba(255, 255, 255, 0.8));
    color: var(--dark-color);
    display: flex;
    flex-direction: column;
    text-align: center;
    position: relative;
}

.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem 2rem;
    width: 100%;
    position: fixed;
    top: 0;
    left: 0;
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(10px);
    z-index: 1000;
    transition: background 0.3s ease;
}

.nav-logo {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--primary-color);
    text-decoration: none;
}

.nav-menu {
    display: flex;
    list-style: none;
}

.nav-item {
    margin-left: 2rem;
}

.nav-link {
    text-decoration: none;
    color: var(--dark-color);
    font-weight: 600;
    transition: color 0.3s ease;
}

.nav-link:hover {
    color: var(--primary-color);
}

.hamburger {
    display: none;
    cursor: pointer;
}

.bar {
    display: block;
    width: 25px;
    height: 3px;
    margin: 5px auto;
    background-color: var(--dark-color);
    transition: all 0.3s ease-in-out;
}

.hero-content {
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.hero-content h1 {
    font-size: 4rem;
    margin-bottom: 1rem;
}

.hero-content p {
    font-size: 1.2rem;
    margin-bottom: 2rem;
    max-width: 600px;
}

/* --- Initial Load Animation --- */
.animate-on-load {
    animation: fadeInDown 1s ease-out forwards;
    opacity: 0;
}
.animate-on-load:nth-child(2) { animation-delay: 0.2s; }
.animate-on-load:nth-child(3) { animation-delay: 0.4s; }

@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* --- On Scroll Reveal Animation --- */
.reveal {
    opacity: 0;
    transform: translateY(50px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

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


/* --- 3. Featured Games Section --- */
#games {
    background: var(--light-color);
}
.games-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
}

.game-card {
    background: var(--white-color);
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
    overflow: hidden;
    text-align: center;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.game-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(0,0,0,0.1);
}

.game-card img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.game-card h3 {
    margin: 1rem 0 0.5rem 0;
    color: var(--primary-color);
}

.game-card p {
    padding: 0 1.5rem;
    font-size: 0.9rem;
    color: #666;
}

.card-link {
    display: inline-block;
    margin: 1rem 0 1.5rem 0;
    text-decoration: none;
    color: var(--secondary-color);
    font-weight: 600;
}

.card-link i {
    transition: transform 0.3s ease;
}

.card-link:hover i {
    transform: translateX(5px);
}

/* --- 4. Features Section --- */
.features-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    text-align: center;
}

.feature-item i {
    font-size: 3rem;
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.feature-item h3 {
    margin-bottom: 0.5rem;
}

/* --- 5. How It Works Section --- */
.how-it-works {
    background: var(--light-color);
}

.steps-container {
    display: flex;
    justify-content: space-around;
    align-items: center;
    text-align: center;
}

.step {
    max-width: 250px;
}

.step-number {
    width: 50px;
    height: 50px;
    background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
    color: var(--white-color);
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 1.5rem;
    font-weight: 700;
    margin: 0 auto 1rem auto;
}

.step-arrow {
    font-size: 2rem;
    color: var(--primary-color);
    font-weight: bold;
}

/* --- 6. Spotlight Section --- */
.spotlight-content {
    display: flex;
    align-items: center;
    gap: 2rem;
}

.spotlight-content img {
    max-width: 400px;
    border-radius: 10px;
}

.spotlight-content h3 {
    margin-bottom: 1rem;
}
.spotlight-content p {
    margin-bottom: 1.5rem;
}

/* --- 7. Testimonials Section --- */
.testimonials {
    background-color: var(--light-color);
}
.testimonial-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}

.testimonial {
    background: var(--white-color);
    padding: 2rem;
    border-left: 5px solid var(--primary-color);
    border-radius: 5px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
}

.testimonial cite {
    display: block;
    margin-top: 1rem;
    font-weight: 600;
    font-style: normal;
    color: var(--primary-color);
}

/* --- 8. Categories Section --- */
.category-tags {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 1rem;
}
.tag {
    background: #e9e3f5;
    color: var(--primary-color);
    padding: 10px 20px;
    border-radius: 50px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}
.tag:hover {
    background: var(--primary-color);
    color: var(--white-color);
}

/* --- 9. Newsletter Section --- */
.newsletter {
    background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
    color: var(--white-color);
    text-align: center;
    border-radius: 15px;
    padding: 3rem 2rem;
}

.newsletter h2 { color: var(--white-color); }
.newsletter p { margin-bottom: 1.5rem; }

.newsletter-form {
    display: flex;
    justify-content: center;
    max-width: 500px;
    margin: auto;
}

.newsletter-form input {
    width: 100%;
    padding: 12px;
    border: none;
    border-radius: 50px 0 0 50px;
    outline: none;
}

.newsletter-form button {
    padding: 12px 25px;
    border: none;
    background: var(--dark-color);
    color: var(--white-color);
    cursor: pointer;
    border-radius: 0 50px 50px 0;
    font-weight: 600;
    transition: background 0.3s ease;
}

.newsletter-form button:hover {
    background: #000;
}

/* --- 10 & 11. Contact and Form Sections --- */
.contact-info {
    padding-bottom: 2rem;
}
.contact-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    text-align: center;
}
.contact-item i {
    font-size: 2rem;
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.form-section {
    padding-top: 0;
}
#contact-form {
    max-width: 700px;
    margin: auto;
    background: var(--light-color);
    padding: 2rem;
    border-radius: 10px;
}
.form-group {
    margin-bottom: 1.5rem;
}
.form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: 600;
}
.form-group input,
.form-group textarea {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-family: var(--font-family);
}
.form-group-checkbox {
    display: flex;
    align-items: center;
    margin-bottom: 1.5rem;
}
.form-group-checkbox input {
    margin-right: 10px;
}
.form-group-checkbox a {
    color: var(--primary-color);
    text-decoration: none;
}

/* --- Footer --- */
footer {
    background: var(--dark-color);
    color: var(--white-color);
    padding: 2rem;
    text-align: center;
}
.footer-content {
    display: flex;
    flex-direction: column-reverse;

    justify-content: space-between;
    align-items: center;
}
a {
    color: var(--white-color);
    text-decoration: none;
    transition: color 0.3s ease;
}
a:hover {
    color: var(--secondary-color);
}
.social-icons a {
    color: var(--white-color);
    font-size: 1rem;
    margin-left: 1rem;
    transition: color 0.3s ease;
}
.social-icons a:hover {
    color: var(--secondary-color);
}

/* --- Responsive Design --- */
@media(max-width: 768px) {
    h2 { font-size: 2rem; }
    
    .nav-menu {
        position: fixed;
        left: -100%;
        top: 5rem;
        flex-direction: column;
        background-color: var(--white-color);
        width: 100%;
        text-align: center;
        transition: 0.3s;
        box-shadow: 0 10px 20px rgba(0,0,0,0.1);
    }
    .nav-menu.active {
        left: 0;
    }
    .nav-item {
        margin: 1.5rem 0;
    }
    .hamburger {
        display: block;
    }
    .hamburger.active .bar:nth-child(2) {
        opacity: 0;
    }
    .hamburger.active .bar:nth-child(1) {
        transform: translateY(8px) rotate(45deg);
    }
    .hamburger.active .bar:nth-child(3) {
        transform: translateY(-8px) rotate(-45deg);
    }

    .hero-content h1 { font-size: 2.8rem; }
    
    .features-grid, .testimonial-grid, .contact-grid {
        grid-template-columns: 1fr;
    }
    
    .steps-container {
        flex-direction: column;
    }
    .step-arrow {
        transform: rotate(90deg);
        margin: 1rem 0;
    }
    
    .spotlight-content {
        flex-direction: column;
        text-align: center;
    }

    .footer-content {
        flex-direction: column;
        gap: 1rem;
    }
}