/* CSS Variables - Design System */
:root {
    --background: hsl(222, 47%, 11%);
    --foreground: hsl(210, 40%, 98%);
    --card: hsl(222, 40%, 15%);
    --card-foreground: hsl(210, 40%, 98%);
    --primary: hsl(15, 100%, 60%);
    --primary-foreground: hsl(0, 0%, 100%);
    --secondary: hsl(222, 35%, 20%);
    --secondary-foreground: hsl(210, 40%, 98%);
    --muted: hsl(222, 30%, 25%);
    --muted-foreground: hsl(215, 20%, 70%);
    --accent: hsl(25, 95%, 53%);
    --border: hsl(222, 30%, 25%);
    --radius: 0.75rem;
    
    --gaming-dark: hsl(222, 47%, 8%);
    --gradient-primary: linear-gradient(135deg, hsl(15, 100%, 60%), hsl(0, 90%, 50%));
    --gradient-secondary: linear-gradient(135deg, hsl(25, 95%, 53%), hsl(35, 90%, 60%));
    --gradient-dark: linear-gradient(180deg, hsl(222, 47%, 11%), hsl(222, 47%, 8%));
    --shadow-glow: 0 0 40px hsla(15, 100%, 60%, 0.3);
    --shadow-card: 0 10px 30px -10px hsla(0, 0%, 0%, 0.5);
}

/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background-color: var(--background);
    color: var(--foreground);
    line-height: 1.6;
    min-height: 100vh;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
}

/* Navigation */
.nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 50;
    background-color: hsla(222, 47%, 11%, 0.8);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border);
}

.nav-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 4rem;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    text-decoration: none;
    transition: all 0.3s ease;
}

.logo:hover .logo-icon {
    box-shadow: var(--shadow-glow);
}

.logo-icon {
    padding: 0.5rem;
    background: var(--gradient-primary);
    border-radius: var(--radius);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.logo-icon svg {
    width: 1.5rem;
    height: 1.5rem;
    color: var(--primary-foreground);
}

.logo-text {
    font-size: 1.25rem;
    font-weight: 700;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.nav-links {
    display: none;
    align-items: center;
    gap: 2rem;
}

@media (min-width: 768px) {
    .nav-links {
        display: flex;
    }
}

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

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

.cta-button {
    display: none;
    padding: 0.75rem 1.5rem;
    background: var(--gradient-primary);
    color: var(--primary-foreground);
    border: none;
    border-radius: var(--radius);
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

@media (min-width: 768px) {
    .cta-button {
        display: block;
    }
}

.cta-button:hover {
    box-shadow: var(--shadow-glow);
}

.mobile-menu-toggle {
    display: block;
    padding: 0.5rem;
    background: transparent;
    border: none;
    color: var(--foreground);
    cursor: pointer;
}

@media (min-width: 768px) {
    .mobile-menu-toggle {
        display: none;
    }
}

.menu-icon {
    width: 1.5rem;
    height: 1.5rem;
}

.mobile-menu {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
}

.mobile-menu.active {
    max-height: 24rem;
    padding-bottom: 1rem;
}

.mobile-nav-link {
    display: block;
    padding: 0.75rem 0;
    color: var(--foreground);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s ease;
}

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

.mobile-menu .cta-button {
    display: block;
    width: 100%;
    margin-top: 1rem;
}

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

.hero-bg {
    position: absolute;
    inset: 0;
}

.hero-bg img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        to bottom,
        hsla(222, 47%, 8%, 0.8),
        hsla(222, 47%, 11%, 0.9),
        var(--background)
    );
}

.hero-content {
    position: relative;
    padding: 8rem 0;
    text-align: center;
    max-width: 64rem;
    margin: 0 auto;
    animation: fadeIn 1s ease-out;
}

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

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    background-color: hsla(222, 40%, 15%, 0.5);
    backdrop-filter: blur(8px);
    border-radius: 9999px;
    border: 1px solid hsla(15, 100%, 60%, 0.2);
    margin-bottom: 2rem;
}

.badge-icon {
    width: 1rem;
    height: 1rem;
    color: var(--primary);
}

.hero-badge span {
    font-size: 0.875rem;
    font-weight: 500;
}

.hero-title {
    font-size: 3rem;
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 2rem;
}

@media (min-width: 768px) {
    .hero-title {
        font-size: 4.5rem;
    }
}

.hero-title-normal {
    color: var(--foreground);
}

.hero-title-gradient {
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero-description {
    font-size: 1.25rem;
    color: var(--muted-foreground);
    max-width: 42rem;
    margin: 0 auto 2rem;
}

@media (min-width: 768px) {
    .hero-description {
        font-size: 1.5rem;
    }
}

.hero-buttons {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    padding-top: 1rem;
}

@media (min-width: 640px) {
    .hero-buttons {
        flex-direction: row;
    }
}

.hero-button-primary {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 1rem 2rem;
    background: var(--gradient-primary);
    color: var(--primary-foreground);
    font-size: 1.125rem;
    font-weight: 600;
    border-radius: var(--radius);
    text-decoration: none;
    transition: all 0.3s ease;
}

.hero-button-primary:hover {
    box-shadow: var(--shadow-glow);
}

.button-icon {
    width: 1.25rem;
    height: 1.25rem;
}

.hero-button-secondary {
    display: inline-block;
    padding: 1rem 2rem;
    font-size: 1.125rem;
    font-weight: 600;
    border: 2px solid hsla(15, 100%, 60%, 0.3);
    border-radius: var(--radius);
    color: var(--foreground);
    text-decoration: none;
    transition: all 0.3s ease;
}

.hero-button-secondary:hover {
    border-color: var(--primary);
    background-color: hsla(15, 100%, 60%, 0.1);
}

.hero-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    padding-top: 3rem;
    max-width: 42rem;
    margin: 0 auto;
}

.stat {
    text-align: center;
}

.stat-value {
    font-size: 2rem;
    font-weight: 700;
    color: var(--primary);
}

@media (min-width: 768px) {
    .stat-value {
        font-size: 2.5rem;
    }
}

.stat-label {
    font-size: 0.875rem;
    color: var(--muted-foreground);
}

/* Section Styles */
.section-games,
.section-categories,
.section-news {
    padding: 5rem 0;
}

.section-games {
    background: var(--gradient-dark);
}

.section-header {
    text-align: center;
    margin-bottom: 3rem;
}

.section-title {
    font-size: 2.25rem;
    font-weight: 700;
    margin-bottom: 1rem;
}

@media (min-width: 768px) {
    .section-title {
        font-size: 3rem;
    }
}

.text-gradient {
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.section-subtitle {
    font-size: 1.25rem;
    color: var(--muted-foreground);
    max-width: 42rem;
    margin: 0 auto;
}

/* Games Grid */
.games-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
    margin-bottom: 2rem;
}

@media (min-width: 768px) {
    .games-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 1024px) {
    .games-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

.game-card {
    background-color: var(--card);
    border: 1px solid hsla(222, 30%, 25%, 0.5);
    border-radius: var(--radius);
    overflow: hidden;
    transition: all 0.3s ease;
}

.game-card:hover {
    border-color: hsla(15, 100%, 60%, 0.5);
    box-shadow: var(--shadow-card);
}

.game-image-wrapper {
    position: relative;
    aspect-ratio: 1 / 1;
    overflow: hidden;
}

.game-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.game-card:hover .game-image {
    transform: scale(1.1);
}

.game-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        to top,
        var(--background),
        hsla(222, 47%, 11%, 0.5),
        transparent
    );
    opacity: 0.6;
}

.game-badge {
    position: absolute;
    top: 1rem;
    left: 1rem;
    padding: 0.25rem 0.75rem;
    background-color: var(--primary);
    color: var(--primary-foreground);
    font-size: 0.875rem;
    font-weight: 600;
    border-radius: 0.375rem;
}

.game-play-overlay {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.game-card:hover .game-play-overlay {
    opacity: 1;
}

.game-play-button {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    background: var(--gradient-primary);
    color: var(--primary-foreground);
    border: none;
    border-radius: var(--radius);
    font-weight: 600;
    cursor: pointer;
    box-shadow: var(--shadow-glow);
}

.game-play-button svg {
    width: 1.25rem;
    height: 1.25rem;
}

.game-content {
    padding: 1.5rem;
}

.game-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 0.5rem;
}

.game-category {
    padding: 0.25rem 0.75rem;
    background-color: var(--secondary);
    color: var(--secondary-foreground);
    font-size: 0.875rem;
    font-weight: 600;
    border-radius: 0.375rem;
}

.game-rating {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    color: var(--primary);
    font-weight: 600;
}

.star-icon {
    width: 1rem;
    height: 1rem;
}

.game-title {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    transition: color 0.3s ease;
}

.game-card:hover .game-title {
    color: var(--primary);
}

.game-description {
    color: var(--muted-foreground);
    margin-bottom: 1rem;
    font-size: 0.875rem;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.game-info {
    display: flex;
    align-items: center;
    gap: 1rem;
    font-size: 0.875rem;
    color: var(--muted-foreground);
}

.game-players {
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.users-icon {
    width: 1rem;
    height: 1rem;
}

/* Categories Grid */
.categories-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
}

@media (min-width: 768px) {
    .categories-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 1024px) {
    .categories-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

.category-card {
    position: relative;
    background-color: var(--card);
    border: 1px solid hsla(222, 30%, 25%, 0.5);
    border-radius: var(--radius);
    padding: 1.5rem;
    overflow: hidden;
    cursor: pointer;
    transition: all 0.3s ease;
}

.category-card:hover {
    border-color: hsla(15, 100%, 60%, 0.5);
    box-shadow: var(--shadow-card);
}

.category-icon {
    display: inline-flex;
    padding: 0.75rem;
    border-radius: var(--radius);
    margin-bottom: 1rem;
    transition: transform 0.3s ease;
}

.category-card:hover .category-icon {
    transform: scale(1.1);
}

.category-icon-0 {
    background: linear-gradient(135deg, hsl(25, 100%, 50%), hsl(0, 100%, 50%));
}

.category-icon-1 {
    background: linear-gradient(135deg, hsl(0, 100%, 50%), hsl(330, 100%, 50%));
}

.category-icon-2 {
    background: linear-gradient(135deg, hsl(30, 100%, 50%), hsl(25, 100%, 50%));
}

.category-icon-3 {
    background: linear-gradient(135deg, hsl(45, 100%, 50%), hsl(30, 100%, 50%));
}

.category-icon svg {
    width: 1.5rem;
    height: 1.5rem;
    color: white;
}

.category-title {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    transition: color 0.3s ease;
}

.category-card:hover .category-title {
    color: var(--primary);
}

.category-description {
    color: var(--muted-foreground);
    font-size: 0.875rem;
    margin-bottom: 1rem;
}

.category-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.category-count {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--primary);
}

.category-link {
    font-size: 0.875rem;
    color: var(--muted-foreground);
    transition: color 0.3s ease;
}

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

/* News Grid */
.news-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
    margin-bottom: 2rem;
}

@media (min-width: 768px) {
    .news-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

.news-card {
    background-color: var(--card);
    border: 1px solid hsla(222, 30%, 25%, 0.5);
    border-radius: var(--radius);
    padding: 1.5rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.news-card:hover {
    border-color: hsla(15, 100%, 60%, 0.5);
    box-shadow: var(--shadow-card);
}

.news-card-featured {
    grid-column: span 1;
}

@media (min-width: 768px) {
    .news-card-featured {
        grid-column: span 2;
    }
}

.news-meta {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 0.75rem;
}

.news-category {
    padding: 0.25rem 0.75rem;
    background-color: var(--secondary);
    color: var(--secondary-foreground);
    font-size: 0.875rem;
    font-weight: 600;
    border-radius: 0.375rem;
}

.news-date {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    font-size: 0.875rem;
    color: var(--muted-foreground);
}

.calendar-icon {
    width: 1rem;
    height: 1rem;
}

.news-title {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 0.75rem;
    transition: color 0.3s ease;
}

.news-card-featured .news-title {
    font-size: 1.5rem;
}

@media (min-width: 768px) {
    .news-card-featured .news-title {
        font-size: 1.875rem;
    }
}

.news-card:hover .news-title {
    color: var(--primary);
}

.news-excerpt {
    color: var(--muted-foreground);
    margin-bottom: 1rem;
}

.news-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--foreground);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s ease;
}

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

.arrow-icon {
    width: 1rem;
    height: 1rem;
    transition: transform 0.3s ease;
}

.news-card:hover .arrow-icon {
    transform: translateX(0.25rem);
}

/* Section Footer */
.section-footer {
    text-align: center;
}

.view-all-button {
    padding: 0.75rem 2rem;
    background: transparent;
    color: var(--foreground);
    border: 2px solid hsla(15, 100%, 60%, 0.3);
    border-radius: var(--radius);
    font-size: 1.125rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.view-all-button:hover {
    border-color: var(--primary);
    background-color: hsla(15, 100%, 60%, 0.1);
}

/* Footer */
.footer {
    background-color: var(--gaming-dark);
    border-top: 1px solid var(--border);
    padding: 3rem 0 1.5rem;
}

.footer-content {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
    margin-bottom: 2rem;
}

@media (min-width: 768px) {
    .footer-content {
        grid-template-columns: 2fr 3fr;
    }
}

.footer-brand {
    max-width: 20rem;
}

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

.footer-description {
    color: var(--muted-foreground);
    font-size: 0.875rem;
}

.footer-links {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 2rem;
}

.footer-column h4 {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 1rem;
}

.footer-column a {
    display: block;
    color: var(--muted-foreground);
    text-decoration: none;
    font-size: 0.875rem;
    margin-bottom: 0.5rem;
    transition: color 0.3s ease;
}

.footer-column a:hover {
    color: var(--primary);
}

.footer-bottom {
    padding-top: 2rem;
    border-top: 1px solid var(--border);
    text-align: center;
}

.footer-bottom p {
    color: var(--muted-foreground);
    font-size: 0.875rem;
}
