* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Roboto', sans-serif;
}

body {
    background-image: url('https://phpstack-1549214-5994814.cloudwaysapps.com/img/bg.png');
    background-color: #97f7e7;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    background-attachment: fixed;
    min-height: 100vh;
    position: relative;
}

body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    
    z-index: -1;
}

/* Header Styles */
header {
    background: white;
    padding: 0.5rem 0;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

nav {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    align-items: center;
    padding: 0 1rem;
}

.logo {
    display: flex;
    align-items: center;
}

.logo h1 {
    color: #333;
    font-size: 24px;
    font-weight: 700;
}

.logo-img {
    height: 40px;
    width: auto;
    display: block;
}

.desktop-search {
    display: flex;
    align-items: center;
    background: #f5f5f5;
    border-radius: 20px;
    padding: 0.5rem 1rem;
    width: 300px;
    margin: 0 1rem;
}

.desktop-search input {
    border: none;
    background: none;
    outline: none;
    width: 100%;
    padding-right: 10px;
}

.desktop-search button {
    background: none;
    border: none;
    cursor: pointer;
    color: #666;
}

.mobile-search {
    display: none;
    width: 100%;
    margin-bottom: 15px;
}

.mobile-search input {
    width: 100%;
}

.nav-links a {
    text-decoration: none;
    color: #333;
    margin-left: 2rem;
    font-weight: 500;
}

.nav-links a.active {
    color: #00a8ff;
}

.menu-toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    font-size: 24px;
    color: #333;
    padding: 5px;
    margin-left: 15px;
    transition: color 0.3s ease;
}

.menu-toggle:hover {
    color: #007bff;
}

.menu-toggle.active i {
    color: #007bff;
}

/* Main Content Styles */
main {
    max-width: 1200px;
    margin: 2rem auto;
    padding: 0 1rem;
}

section {
    margin-bottom: 3rem;
}

h2 {
    color: #333;
    margin-bottom: 1.5rem;
}

.games-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 1.2rem;
    padding: 0.5rem;
}

.game-card {
    position: relative;
    border-radius: 20px;
    overflow: hidden;
    transition: transform 0.3s ease;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    width: 100%;
    aspect-ratio: 1/1;
    background: white;
}

.game-card:hover {
    transform: translateY(-5px);
}

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

.game-info {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 0.8rem;
    background: linear-gradient(to top, rgba(0,0,0,0.8), rgba(0,0,0,0));
    color: white;
    transform: translateY(100%);
    transition: transform 0.3s ease;
}

.game-card:hover .game-info {
    transform: translateY(0);
}

.game-info h3 {
    color: white;
    font-size: 1rem;
    margin-bottom: 0.2rem;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.5);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.game-info p {
    color: rgba(255,255,255,0.9);
    font-size: 0.9rem;
    margin: 0;
}

@media (max-width: 768px) {
    .games-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 1rem;
        padding: 0.5rem;
    }
}

@media (max-width: 480px) {
    .games-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 0.8rem;
        padding: 0.5rem;
    }

    .game-info {
        padding: 0.6rem;
    }

    .game-info h3 {
        font-size: 0.9rem;
    }

    .game-info p {
        font-size: 0.8rem;
    }
}

/* Game Page Styles */
.game-frame-container {
    width: 100%;
    max-width: 600px;
    margin: 0 auto;
    aspect-ratio: 16/9;
    background: #000;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.game-frame {
    width: 100%;
    height: 100%;
    border: none;
}

.game-container {
    max-width: 1000px;
    margin: 0 auto;
    padding: 20px;
}

/* About Section Styles */
.about-section {
    background: white;
    padding: 2rem 0;
    margin: 1rem 0;
}

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

.section-title {
    color: #333;
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
}

.about-content {
    line-height: 1.6;
}

.about-content h3 {
    color: #1a1a1a;
    font-size: 1.25rem;
    font-weight: 600;
    margin: 1.5rem 0 1rem;
}

.about-content p {
    color: #444;
    margin-bottom: 1rem;
}

.category-list {
    list-style: none;
    padding: 0;
    margin: 1rem 0;
}

.category-list li {
    margin: 0.5rem 0;
}

.category-list a {
    color: #007bff;
    text-decoration: none;
    transition: color 0.3s;
}

.category-list a:hover {
    color: #0056b3;
}

.category-badge {
    display: inline-block;
    background: #f1f3f5;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 14px;
    color: #495057;
    text-decoration: none;
    transition: all 0.3s ease;
    margin-top: 8px;
}

.category-badge:hover {
    background: #e9ecef;
    color: #007bff;
    transform: translateY(-1px);
}

/* Category Page Styles */
.category-header {
    background: white;
    padding: 2rem 0;
    margin-bottom: 2rem;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.category-header h1 {
    color: #333;
    font-size: 2rem;
    margin-bottom: 0.5rem;
}

.category-header p {
    color: #666;
    font-size: 1.1rem;
}

.category-games {
    padding: 2rem 0;
}

.no-games {
    text-align: center;
    padding: 3rem 0;
    color: #666;
    font-size: 1.1rem;
}

/* Footer Styles */
footer {
    background: white;
    padding: 3rem 0 1rem;
    margin-top: 3rem;
}

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

.footer-section h3 {
    color: #333;
    margin-bottom: 1rem;
}

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

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

.footer-section a {
    color: #666;
    text-decoration: none;
}

.footer-bottom {
    text-align: center;
    margin-top: 2rem;
    padding-top: 1rem;
    border-top: 1px solid #eee;
}

/* Responsive Design */
@media (max-width: 768px) {
    nav {
        display: grid;
        grid-template-columns: auto 1fr auto;
        align-items: center;
        
        gap: 10px;
    }

    .logo {
        grid-column: 1;
        margin-right: 0;
    }

    .logo-img {
        height: 35px;
    }

    .desktop-search {
        display: none;
    }
    
    .mobile-search {
        display: flex;
        align-items: center;
        background: #f5f5f5;
        border-radius: 20px;
        padding: 0.5rem 1rem;
        width: 100%;
        margin-bottom: 15px;
    }

    .menu-toggle {
        grid-column: 3;
        display: flex;
        align-items: center;
        justify-content: center;
        margin: 0;
        padding: 8px;
        font-size: 22px;
    }

    .nav-links {
        grid-column: 1 / -1;
        grid-row: 2;
        width: 100%;
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: white;
        padding: 1rem;
        flex-direction: column;
        align-items: center;
        gap: 15px;
        box-shadow: 0 4px 6px rgba(0,0,0,0.1);
        border-radius: 0 0 10px 10px;
        z-index: 1000;
    }

    .nav-links.active {
        display: flex;
    }

    .about-section {
        padding: 1.5rem 0;
    }

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

    .about-content h3 {
        font-size: 1.1rem;
    }

    .category-header {
        padding: 1.5rem 0;
    }

    .category-header h1 {
        font-size: 1.5rem;
    }

    .category-header p {
        font-size: 1rem;
    }
}
