/* Material Design - Light Theme */
:root {
    /* Primary Colors - Material Blue */
    --primary-color: #1976d2;
    --primary-light: #63a4ff;
    --primary-dark: #004ba0;
    
    /* Secondary Colors */
    --secondary-color: #424242;
    --accent-color: #ff4081;
    
    /* Background Colors - White Theme */
    --bg-primary: #fafafa;
    --bg-secondary: #f5f5f5;
    --bg-card: #ffffff;
    --bg-hover: #eeeeee;
    
    /* Text Colors */
    --text-primary: #212121;
    --text-secondary: #757575;
    --text-hint: #9e9e9e;
    --text-white: #ffffff;
    
    /* Border & Divider */
    --border-color: #e0e0e0;
    --divider-color: #bdbdbd;
    
    /* Shadows - Material Design */
    --shadow-1: 0 1px 3px rgba(0,0,0,0.12), 0 1px 2px rgba(0,0,0,0.24);
    --shadow-2: 0 3px 6px rgba(0,0,0,0.16), 0 3px 6px rgba(0,0,0,0.23);
    --shadow-3: 0 10px 20px rgba(0,0,0,0.19), 0 6px 6px rgba(0,0,0,0.23);
    --shadow-card: 0 2px 4px rgba(0,0,0,0.1);
    
    /* Transitions */
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-fast: all 0.2s ease;
}

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

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

body {
    font-family: 'Roboto', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background-color: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition-fast);
}

ul {
    list-style: none;
}

/* Custom Scrollbar - Light Theme */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: var(--bg-secondary);
}
::-webkit-scrollbar-thumb {
    background: var(--divider-color);
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: var(--text-secondary);
}

/* Navbar - Material Design */
.navbar {
    background: var(--bg-card);
    border-bottom: 1px solid var(--border-color);
    padding: 0 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: sticky;
    top: 0;
    z-index: 1000;
    height: 64px;
    box-shadow: var(--shadow-1);
}

.logo {
    font-size: 1.5rem;
    font-weight: 500;
    color: var(--primary-color);
    letter-spacing: 0.5px;
    flex-shrink: 0;
}

/* Nav Search - Material Design */
.nav-search-wrapper {
    flex: 1;
    max-width: 400px;
    margin: 0 2rem;
}

.nav-search-input {
    width: 100%;
    padding: 0.6rem 1rem;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    background: var(--bg-secondary);
    color: var(--text-primary);
    font-size: 0.95rem;
    outline: none;
    transition: var(--transition-fast);
}

.nav-search-input::placeholder {
    color: var(--text-hint);
}

.nav-search-input:focus {
    border-color: var(--primary-color);
    background: var(--bg-card);
    box-shadow: 0 0 0 2px rgba(25, 118, 210, 0.2);
}

/* Mobile Search - Hidden by default on desktop */
.mobile-search-wrapper {
    display: none;
}

.nav-links {
    display: flex;
    gap: 0.5rem;
}

.nav-links a {
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text-secondary);
    padding: 0.5rem 0.8rem;
    border-radius: 4px;
    transition: var(--transition-fast);
}

.nav-links a:hover {
    color: var(--primary-color);
    background: rgba(25, 118, 210, 0.08);
}

/* Hamburger Menu */
.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
    gap: 4px;
    z-index: 1001;
    padding: 8px;
}

.hamburger span {
    width: 24px;
    height: 2px;
    background: var(--text-secondary);
    transition: var(--transition-fast);
    border-radius: 2px;
}

/* Main Content */
main {
    min-height: calc(100vh - 64px - 200px);
    padding: 2rem 0;
}

/* Sections */
.category-section {
    padding: 0 2rem;
    max-width: 1400px;
    margin: 0 auto 3rem auto;
    animation: fadeIn 0.5s ease-out;
}

.category-title {
    font-size: 1.5rem;
    font-weight: 500;
    color: var(--text-primary);
    margin-bottom: 1.5rem;
    padding-left: 0.5rem;
    border-left: 3px solid var(--primary-color);
}

/* Game Grid */
.game-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 1.5rem;
}

/* Game Card - Material Design */
.game-card {
    background: var(--bg-card);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: var(--shadow-card);
    transition: var(--transition-fast);
    display: flex;
    flex-direction: column;
    border: 1px solid var(--border-color);
}

.game-card:hover {
    box-shadow: var(--shadow-2);
    transform: translateY(-2px);
}

.game-thumb-wrapper {
    position: relative;
    width: 100%;
    padding-top: 75%;
    overflow: hidden;
    background: var(--bg-secondary);
}

.game-thumb {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition-fast);
}

.game-card:hover .game-thumb {
    transform: scale(1.03);
}

.game-info {
    padding: 1rem;
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.game-title {
    font-size: 0.95rem;
    font-weight: 500;
    color: var(--text-primary);
    margin-bottom: 0.75rem;
    line-height: 1.4;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.btn-play {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.5rem 1rem;
    background: var(--primary-color);
    color: var(--text-white);
    border-radius: 4px;
    font-size: 0.85rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: var(--transition-fast);
    box-shadow: var(--shadow-1);
}

.game-card:hover .btn-play {
    background: var(--primary-dark);
    box-shadow: var(--shadow-2);
}

/* SEO Content Section */
.seo-content-section {
    padding: 3rem 2rem;
    background: var(--bg-secondary);
    border-top: 1px solid var(--border-color);
}

.seo-content-wrapper {
    max-width: 800px;
    margin: 0 auto;
}

.seo-title {
    font-size: 1.75rem;
    font-weight: 500;
    color: var(--text-primary);
    margin-bottom: 1.5rem;
    text-align: center;
}

.seo-content {
    color: var(--text-secondary);
    line-height: 1.8;
    font-size: 1rem;
}

.seo-content h3 {
    color: var(--text-primary);
    font-size: 1.25rem;
    margin: 2rem 0 1rem 0;
    font-weight: 500;
}

.seo-content h4 {
    color: var(--primary-color);
    font-size: 1.1rem;
    margin: 1.5rem 0 0.75rem 0;
    font-weight: 500;
}

.seo-content p {
    margin-bottom: 1rem;
}

/* Footer */
.footer {
    background: var(--bg-card);
    border-top: 1px solid var(--border-color);
    padding: 2rem;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 3rem;
}

.footer-brand .logo {
    margin-bottom: 1rem;
    display: inline-block;
}

.footer-brand p {
    color: var(--text-secondary);
    font-size: 0.9rem;
    line-height: 1.6;
}

.footer-links-group h4 {
    color: var(--text-primary);
    font-size: 1rem;
    font-weight: 500;
    margin-bottom: 1rem;
}

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

.footer-links-group ul li a {
    color: var(--text-secondary);
    font-size: 0.9rem;
    transition: var(--transition-fast);
}

.footer-links-group ul li a:hover {
    color: var(--primary-color);
}

.footer-bottom {
    max-width: 1200px;
    margin: 2rem auto 0 auto;
    padding-top: 1.5rem;
    border-top: 1px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.copyright {
    color: var(--text-hint);
    font-size: 0.85rem;
}

/* Detail Page Styles */
.detail-container {
    max-width: 1200px;
    margin: 2rem auto;
    padding: 0 2rem;
}

.back-home{
    display: flex;
    align-items: center;
    margin-bottom: 1rem;
}

.game-detail-header {
    display: grid;
    grid-template-columns: 400px 1fr;
    gap: 3rem;
    margin-bottom: 3rem;
    background: var(--bg-card);
    padding: 2rem;
    border-radius: 8px;
    box-shadow: var(--shadow-card);
    border: 1px solid var(--border-color);
}

.detail-thumb {
    width: 100%;
    border-radius: 8px;
    box-shadow: var(--shadow-1);
}

.detail-info h1 {
    font-size: 2rem;
    font-weight: 500;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.detail-desc {
    font-size: 1rem;
    color: var(--text-secondary);
    margin-bottom: 2rem;
    line-height: 1.7;
}

.play-now-large {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.875rem 2rem;
    background: var(--primary-color);
    color: var(--text-white);
    border-radius: 4px;
    font-size: 1rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: var(--transition-fast);
    box-shadow: var(--shadow-1);
}

.play-now-large:hover {
    background: var(--primary-dark);
    box-shadow: var(--shadow-2);
}

/* Content Blocks */
.content-block {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    box-shadow: var(--shadow-card);
}

.content-block h2 {
    color: var(--text-primary);
    font-size: 1.25rem;
    margin-bottom: 1rem;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.content-body {
    color: var(--text-secondary);
    line-height: 1.7;
    font-size: 0.95rem;
}

.content-body p {
    margin-bottom: 0.75rem;
}

.feature-list {
    list-style: none;
    padding: 0;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 0.5rem;
}

.feature-list li {
    padding: 0.6rem 0.75rem;
    background: var(--bg-secondary);
    border-left: 3px solid var(--primary-color);
    border-radius: 0 4px 4px 0;
    color: var(--text-primary);
    font-size: 0.9rem;
}

.feature-list li::before {
    content: "✓";
    color: var(--primary-color);
    margin-right: 0.5rem;
    font-weight: bold;
}

.game-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin: 1rem 0;
    padding: 1rem;
    background: var(--bg-secondary);
    border-radius: 4px;
}

.meta-item {
    color: var(--text-secondary);
    font-size: 0.85rem;
    padding: 0.4rem 0.8rem;
    background: var(--bg-card);
    border-radius: 16px;
    border: 1px solid var(--border-color);
}

/* Cookie Consent Banner */
.cookie-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: var(--bg-card);
    border-top: 1px solid var(--border-color);
    padding: 1rem 2rem;
    z-index: 9999;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
    box-shadow: var(--shadow-3);
}

.cookie-banner.hidden {
    display: none;
}

.cookie-content {
    flex: 1;
    min-width: 280px;
}

.cookie-content h3 {
    color: var(--text-primary);
    margin-bottom: 0.25rem;
    font-size: 1rem;
    font-weight: 500;
}

.cookie-content p {
    color: var(--text-secondary);
    font-size: 0.85rem;
}

.cookie-buttons {
    display: flex;
    gap: 0.75rem;
}

.cookie-btn {
    padding: 0.6rem 1.25rem;
    border-radius: 4px;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition-fast);
    border: none;
    font-size: 0.85rem;
}

.cookie-btn.accept {
    background: var(--primary-color);
    color: var(--text-white);
    box-shadow: var(--shadow-1);
}

.cookie-btn.accept:hover {
    background: var(--primary-dark);
    box-shadow: var(--shadow-2);
}

.cookie-btn.reject {
    background: transparent;
    color: var(--text-secondary);
    border: 1px solid var(--border-color);
}

.cookie-btn.reject:hover {
    background: var(--bg-secondary);
    color: var(--text-primary);
}

/* Page Header */
.page-header {
    background: var(--bg-card);
    border-bottom: 1px solid var(--border-color);
    padding: 2rem;
    margin-bottom: 2rem;
}

.page-header h1 {
    max-width: 1200px;
    margin: 0 auto;
    font-size: 2rem;
    font-weight: 500;
    color: var(--text-primary);
}

.page-content {
    max-width: 800px;
    margin: 0 auto;
    padding: 0 2rem;
    color: var(--text-secondary);
    line-height: 1.8;
}

.page-content h2 {
    color: var(--text-primary);
    font-size: 1.5rem;
    margin: 2rem 0 1rem 0;
    font-weight: 500;
}

.page-content p {
    margin-bottom: 1rem;
}

/* Mobile Navigation */
@media (max-width: 768px) {
    .navbar {
        padding: 0 1rem;
        flex-wrap: nowrap;
        height: 56px;
    }
    
    /* Hide desktop search on mobile */
    .desktop-only {
        display: none !important;
    }
    
    /* Show mobile search in nav menu */
    .mobile-search-wrapper {
        display: block;
        width: 100%;
        margin-bottom: 1rem;
        padding-bottom: 1rem;
        border-bottom: 1px solid var(--border-color);
    }
    
    .mobile-search-input {
        width: 100%;
        padding: 0.75rem 1rem;
        border: 1px solid var(--border-color);
        border-radius: 4px;
        background: var(--bg-secondary);
        color: var(--text-primary);
        font-size: 1rem;
        outline: none;
        transition: var(--transition-fast);
    }
    
    .mobile-search-input::placeholder {
        color: var(--text-hint);
    }
    
    .mobile-search-input:focus {
        border-color: var(--primary-color);
        background: var(--bg-card);
        box-shadow: 0 0 0 2px rgba(25, 118, 210, 0.2);
    }
    
    .nav-links {
        position: fixed;
        top: 0;
        right: -100%;
        width: 80%;
        height: 100vh;
        background: var(--bg-card);
        flex-direction: column;
        align-items: flex-start;
        justify-content: flex-start;
        padding: 5rem 2rem 2rem 2rem;
        gap: 0.5rem;
        transition: var(--transition);
        z-index: 1000;
        box-shadow: var(--shadow-3);
    }
    
    .nav-links.active {
        right: 0;
    }
    
    .nav-links a {
        width: 100%;
        padding: 0.75rem 1rem;
    }
    
    .hamburger {
        display: flex;
    }
    
    .hamburger.active span:nth-child(1) {
        transform: rotate(45deg) translate(5px, 5px);
    }
    
    .hamburger.active span:nth-child(2) {
        opacity: 0;
    }
    
    .hamburger.active span:nth-child(3) {
        transform: rotate(-45deg) translate(5px, -5px);
    }
    
    main {
        padding: 1rem 0;
    }
    
    .category-section {
        padding: 0 1rem;
        margin-bottom: 2rem;
    }
    
    .category-title {
        font-size: 1.25rem;
        margin-bottom: 1rem;
    }
    
    .game-grid {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
        gap: 1rem;
    }
    
    .seo-content-section {
        padding: 2rem 1rem;
    }
    
    .seo-title {
        font-size: 1.5rem;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    .footer-bottom {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }
    
    .game-detail-header {
        grid-template-columns: 1fr;
        gap: 1.5rem;
        padding: 1.5rem;
    }
    
    .detail-info h1 {
        font-size: 1.5rem;
    }
    
    .cookie-banner {
        flex-direction: column;
        text-align: center;
        padding: 1rem;
    }
    
    .cookie-buttons {
        width: 100%;
        justify-content: center;
    }
    
    .page-header {
        padding: 1.5rem 1rem;
    }
    
    .page-header h1 {
        font-size: 1.5rem;
    }
    
    .page-content {
        padding: 0 1rem;
    }
}

@media (max-width: 480px) {
    .game-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 0.75rem;
    }
    
    .game-info {
        padding: 0.75rem;
    }
    
    .game-title {
        font-size: 0.85rem;
    }
    
    .btn-play {
        padding: 0.4rem 0.75rem;
        font-size: 0.75rem;
    }
}
