:root {
    --primary-color: #6366f1;
    --secondary-color: #ec4899;
    --accent-color: #f59e0b;
    --dark-bg: #0f172a;
    --card-bg: #1e293b;
    --text-primary: #f8fafc;
    --text-secondary: #cbd5e1;
    --success: #10b981;
    --gradient-1: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    --gradient-2: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    --gradient-3: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.1);
    --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.15);
    --shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.2);
}

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

body {
    font-family: 'Poppins', sans-serif;
    background: var(--dark-bg);
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
}

/* Cookie Consent Banner */
.cookie-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: rgba(30, 41, 59, 0.98);
    backdrop-filter: blur(10px);
    padding: 20px;
    z-index: 10000;
    border-top: 2px solid var(--primary-color);
    animation: slideUp 0.4s ease;
    display: none;
}

.cookie-banner.show {
    display: block;
}

@keyframes slideUp {
    from {
        transform: translateY(100%);
    }
    to {
        transform: translateY(0);
    }
}

.cookie-content {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
    flex-wrap: wrap;
}

.cookie-content p {
    flex: 1;
    font-size: 14px;
    color: var(--text-secondary);
}

.cookie-content a {
    color: var(--primary-color);
    text-decoration: underline;
}

.accept-btn {
    padding: 12px 32px;
    background: var(--primary-color);
    color: white;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.accept-btn:hover {
    background: #4f46e5;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.4);
}

/* Header & Navigation */
header {
    background: rgba(15, 23, 42, 0.95);
    backdrop-filter: blur(10px);
    position: sticky;
    top: 0;
    z-index: 1000;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.navbar {
    padding: 1rem 0;
}

.nav-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    display: flex;
    align-items: center;
    gap: 12px;
    font-family: 'Fredoka', sans-serif;
    font-size: 1.8rem;
    font-weight: 700;
    cursor: pointer;
    transition: transform 0.3s ease;
}

.logo:hover {
    transform: scale(1.05);
}

.logo-icon {
    font-size: 2rem;
    animation: bounce 2s infinite;
}

@keyframes bounce {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

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

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

.nav-menu a {
    color: var(--text-secondary);
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    position: relative;
    padding: 8px 0;
}

.nav-menu a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--gradient-1);
    transition: width 0.3s ease;
}

.nav-menu a:hover,
.nav-menu a.active {
    color: var(--text-primary);
}

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

.menu-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    cursor: pointer;
}

.menu-toggle span {
    width: 25px;
    height: 3px;
    background: var(--text-primary);
    border-radius: 3px;
    transition: all 0.3s ease;
}

/* Hero Section */
.hero {
    padding: 100px 2rem;
    max-width: 1400px;
    margin: 0 auto;
    position: relative;
    overflow: hidden;
}

.hero-content {
    text-align: center;
    position: relative;
    z-index: 2;
}

.hero-title {
    font-family: 'Fredoka', sans-serif;
    font-size: 4.5rem;
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 1.5rem;
    animation: fadeInUp 0.8s ease;
}

.title-line {
    display: block;
}

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

.hero-subtitle {
    font-size: 1.5rem;
    color: var(--text-secondary);
    margin-bottom: 3rem;
    animation: fadeInUp 0.8s ease 0.2s both;
}

.hero-stats {
    display: flex;
    justify-content: center;
    gap: 4rem;
    animation: fadeInUp 0.8s ease 0.4s both;
}

.stat {
    text-align: center;
}

.stat-number {
    display: block;
    font-size: 3rem;
    font-weight: 800;
    background: var(--gradient-3);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.stat-label {
    display: block;
    color: var(--text-secondary);
    font-size: 1rem;
    margin-top: 0.5rem;
}

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

/* Floating Shapes */
.hero-decoration {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    overflow: hidden;
}

.floating-shape {
    position: absolute;
    border-radius: 50%;
    opacity: 0.1;
    animation: float 20s infinite ease-in-out;
}

.shape-1 {
    width: 300px;
    height: 300px;
    background: var(--gradient-1);
    top: 10%;
    left: 10%;
    animation-delay: 0s;
}

.shape-2 {
    width: 200px;
    height: 200px;
    background: var(--gradient-2);
    top: 60%;
    right: 15%;
    animation-delay: 5s;
}

.shape-3 {
    width: 250px;
    height: 250px;
    background: var(--gradient-3);
    bottom: 10%;
    left: 20%;
    animation-delay: 10s;
}

@keyframes float {
    0%, 100% {
        transform: translate(0, 0) rotate(0deg);
    }
    33% {
        transform: translate(30px, -50px) rotate(120deg);
    }
    66% {
        transform: translate(-20px, 20px) rotate(240deg);
    }
}

/* Games Section */
.games-section {
    padding: 80px 2rem;
    max-width: 1400px;
    margin: 0 auto;
}

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

.section-title {
    font-family: 'Fredoka', sans-serif;
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 1rem;
}

.section-subtitle {
    color: var(--text-secondary);
    font-size: 1.2rem;
}

/* Filter Buttons */
.filter-buttons {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 3rem;
}

.filter-btn {
    padding: 12px 24px;
    background: var(--card-bg);
    color: var(--text-secondary);
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-radius: 50px;
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.3s ease;
    font-family: 'Poppins', sans-serif;
}

.filter-btn:hover {
    background: rgba(99, 102, 241, 0.1);
    border-color: var(--primary-color);
    color: var(--primary-color);
    transform: translateY(-2px);
}

.filter-btn.active {
    background: var(--gradient-1);
    border-color: transparent;
    color: white;
    box-shadow: 0 4px 15px rgba(99, 102, 241, 0.4);
}

.games-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 2rem;
}

/* Game Cards */
.game-card {
    background: var(--card-bg);
    border-radius: 20px;
    overflow: hidden;
    transition: all 0.4s ease;
    cursor: pointer;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.game-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
    border-color: var(--primary-color);
}

.game-thumbnail {
    position: relative;
    overflow: hidden;
    aspect-ratio: 16 / 9;
}

.game-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

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

.play-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

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

.play-button {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: var(--gradient-1);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    color: white;
    transform: scale(0.8);
    transition: transform 0.3s ease;
}

.game-card:hover .play-button {
    transform: scale(1);
}

.game-info {
    padding: 1.5rem;
}

.game-title {
    font-family: 'Fredoka', sans-serif;
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.game-description {
    color: var(--text-secondary);
    margin-bottom: 1rem;
    font-size: 0.95rem;
}

.game-meta {
    display: flex;
    justify-content: space-between;
    margin-bottom: 1rem;
    font-size: 0.9rem;
}

.game-category {
    background: rgba(99, 102, 241, 0.2);
    padding: 4px 12px;
    border-radius: 20px;
    color: var(--primary-color);
}

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

.play-btn {
    display: block;
    width: 100%;
    padding: 12px;
    background: var(--gradient-1);
    color: white;
    text-align: center;
    text-decoration: none;
    border-radius: 10px;
    font-weight: 600;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
    font-family: 'Poppins', sans-serif;
    font-size: 1rem;
}

.play-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 16px rgba(99, 102, 241, 0.4);
}

/* Ad Container */
.ad-container {
    max-width: 1400px;
    margin: 60px auto;
    padding: 0 2rem;
}

.ad-label {
    text-align: center;
    font-size: 0.75rem;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 10px;
}

.ad-space {
    display: flex;
    justify-content: center;
}

/* Categories Section */
.categories-section {
    padding: 80px 2rem;
    max-width: 1400px;
    margin: 0 auto;
}

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

.category-card {
    background: var(--card-bg);
    padding: 3rem 2rem;
    border-radius: 20px;
    text-align: center;
    transition: all 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.category-card:hover {
    transform: translateY(-5px);
    border-color: var(--primary-color);
    box-shadow: var(--shadow-lg);
}

.category-icon {
    font-size: 4rem;
    margin-bottom: 1rem;
}

.category-card h3 {
    font-family: 'Fredoka', sans-serif;
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
}

.category-card p {
    color: var(--text-secondary);
}

/* Footer */
footer {
    background: rgba(15, 23, 42, 0.95);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    margin-top: 100px;
}

.footer-content {
    max-width: 1400px;
    margin: 0 auto;
    padding: 60px 2rem 30px;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 3rem;
}

.footer-section h3 {
    font-family: 'Fredoka', sans-serif;
    font-size: 1.5rem;
    margin-bottom: 1rem;
}

.footer-section h4 {
    font-size: 1.2rem;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.footer-section p {
    color: var(--text-secondary);
    line-height: 1.8;
}

.footer-section ul {
    list-style: none;
}

.footer-section ul li {
    margin-bottom: 0.8rem;
}

.footer-section a {
    color: var(--text-secondary);
    text-decoration: none;
    transition: color 0.3s ease;
}

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

.footer-bottom {
    max-width: 1400px;
    margin: 0 auto;
    padding: 30px 2rem;
    text-align: center;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--text-secondary);
}

/* Responsive Design */
@media (max-width: 1024px) {
    .nav-container {
        padding: 0 1.5rem;
    }

    .games-grid {
        grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
        gap: 1.5rem;
    }

    .hero {
        padding: 80px 1.5rem;
    }

    .games-section {
        padding: 60px 1.5rem;
    }
}

@media (max-width: 768px) {
    /* Mobile Navigation */
    .nav-container {
        padding: 0 1rem;
    }

    .logo {
        font-size: 1.5rem;
    }

    .logo-icon {
        font-size: 1.8rem;
    }

    .menu-toggle {
        display: flex;
        z-index: 1001;
    }

    .menu-toggle.active span:nth-child(1) {
        transform: rotate(45deg) translate(7px, 7px);
    }

    .menu-toggle.active span:nth-child(2) {
        opacity: 0;
    }

    .menu-toggle.active span:nth-child(3) {
        transform: rotate(-45deg) translate(6px, -6px);
    }

    .nav-menu {
        position: fixed;
        top: 0;
        right: 0;
        width: 280px;
        height: 100vh;
        background: var(--card-bg);
        flex-direction: column;
        padding: 5rem 2rem 2rem;
        gap: 0.5rem;
        transform: translateX(100%);
        opacity: 0;
        pointer-events: none;
        transition: all 0.3s ease;
        box-shadow: -4px 0 20px rgba(0, 0, 0, 0.3);
        z-index: 1000;
    }

    .nav-menu.active {
        transform: translateX(0);
        opacity: 1;
        pointer-events: all;
    }

    .nav-menu li {
        width: 100%;
    }

    .nav-menu a {
        padding: 1rem;
        justify-content: flex-start;
        font-size: 1.1rem;
    }

    /* Hero Section */
    .hero {
        padding: 60px 1rem;
    }

    .hero-title {
        font-size: 2.5rem;
        line-height: 1.2;
    }

    .hero-subtitle {
        font-size: 1.2rem;
        margin-bottom: 2rem;
    }

    .hero-stats {
        flex-direction: row;
        flex-wrap: wrap;
        gap: 1.5rem;
        justify-content: space-around;
    }

    .stat {
        flex: 1;
        min-width: 120px;
    }

    .stat-number {
        font-size: 2.5rem;
    }

    .stat-label {
        font-size: 0.9rem;
    }

    /* Games Section */
    .games-section {
        padding: 50px 1rem;
    }

    .section-header {
        margin-bottom: 2.5rem;
    }

    .section-title {
        font-size: 2rem;
    }

    .section-subtitle {
        font-size: 1rem;
    }

    /* Filter Buttons */
    .filter-buttons {
        gap: 0.75rem;
        margin-bottom: 2rem;
    }

    .filter-btn {
        padding: 10px 18px;
        font-size: 0.9rem;
    }

    .games-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    /* Game Cards - Optimized for Mobile */
    .game-card {
        max-width: 100%;
    }

    .game-thumbnail {
        aspect-ratio: 16 / 9;
    }

    .game-info {
        padding: 1.25rem;
    }

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

    .game-description {
        font-size: 0.9rem;
        line-height: 1.5;
    }

    .game-meta {
        flex-wrap: wrap;
        gap: 0.5rem;
    }

    /* Categories */
    .categories-section {
        padding: 50px 1rem;
    }

    .categories-grid {
        grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
        gap: 1rem;
    }

    .category-card {
        padding: 2rem 1rem;
    }

    .category-icon {
        font-size: 3rem;
    }

    .category-card h3 {
        font-size: 1.2rem;
    }

    /* Footer */
    .footer-content {
        padding: 40px 1rem 20px;
        grid-template-columns: 1fr;
        gap: 2rem;
        text-align: center;
    }

    .footer-section ul {
        display: flex;
        flex-wrap: wrap;
        justify-content: center;
        gap: 1rem;
    }

    .footer-section ul li {
        margin-bottom: 0;
    }

    .footer-bottom {
        padding: 20px 1rem;
    }

    /* Ad Container */
    .ad-container {
        padding: 0 1rem;
        margin: 40px auto;
    }

    /* Action Buttons */
    .action-buttons {
        flex-direction: column;
    }

    .action-buttons button {
        width: 100%;
    }
}

@media (max-width: 480px) {
    /* Extra Small Screens */
    .hero-title {
        font-size: 2rem;
    }

    .hero-subtitle {
        font-size: 1rem;
    }

    .hero-stats {
        gap: 1rem;
    }

    .stat-number {
        font-size: 2rem;
    }

    .logo {
        font-size: 1.3rem;
    }

    .logo-icon {
        font-size: 1.5rem;
    }

    .section-title {
        font-size: 1.8rem;
    }

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

    /* Filter Buttons - Smaller on tiny screens */
    .filter-buttons {
        gap: 0.5rem;
    }

    .filter-btn {
        padding: 8px 14px;
        font-size: 0.85rem;
    }

    .cookie-content {
        flex-direction: column;
        text-align: center;
        gap: 1rem;
    }

    .cookie-content p {
        font-size: 0.85rem;
    }

    .accept-btn {
        width: 100%;
        padding: 10px 24px;
    }

    /* Floating shapes - hide on very small screens */
    .floating-shape {
        display: none;
    }

    .categories-grid {
        grid-template-columns: 1fr;
    }
}

/* Landscape Mobile Optimization */
@media (max-width: 896px) and (orientation: landscape) {
    .hero {
        padding: 40px 1rem;
    }

    .hero-title {
        font-size: 2rem;
    }

    .hero-stats {
        flex-direction: row;
        gap: 2rem;
    }

    .stat-number {
        font-size: 2rem;
    }
}

/* Touch Device Optimizations */
@media (hover: none) and (pointer: coarse) {
    /* Larger touch targets */
    .play-btn,
    .btn-primary,
    .btn-secondary {
        min-height: 48px;
        padding: 14px 24px;
    }

    .nav-menu a {
        min-height: 48px;
    }

    /* Remove hover effects that don't work on touch */
    .game-card:hover {
        transform: none;
    }

    .game-card:active {
        transform: scale(0.98);
    }

    .play-overlay {
        opacity: 0.7;
    }
}
