:root {
    --bg-dark: #0f0c29;
    --bg-mid: #302b63;
    --bg-light: #24243e;
    --glass: rgba(255, 255, 255, 0.05);
    --glass-border: rgba(255, 255, 255, 0.1);
    --accent-purple: #b026ff;
    --accent-cyan: #00d4ff;
    --accent-pink: #ff006e;
    --text-white: #ffffff;
    --text-gray: #a0a0a0;
    --font-main: 'Inter', system-ui, -apple-system, sans-serif;
    --radius: 16px;
    --header-height: 80px;
}

a{
    text-decoration: none;
    color: inherit;
}

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

body {
    background: linear-gradient(135deg, var(--bg-dark), var(--bg-mid), var(--bg-light));
    background-attachment: fixed;
    font-family: var(--font-main);
    color: var(--text-white);
    min-height: 100vh;
    overflow-x: hidden;
    line-height: 1.6;
}

/* Glass Utility */
.glass-panel {
    background: var(--glass);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius);
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.1);
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 1rem;
}

.text-gradient {
    background: linear-gradient(to right, var(--accent-purple), var(--accent-cyan));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

a {
    text-decoration: none;
    color: inherit;
    transition: all 0.3s ease;
}

ul {
    list-style: none;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 24px;
    border-radius: 50px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    border: none;
    outline: none;
    font-size: 1rem;
}

.btn-glass {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--glass-border);
    color: var(--text-white);
}

.btn-glass:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: var(--accent-cyan);
    box-shadow: 0 0 15px rgba(0, 212, 255, 0.3);
}

.btn-gradient {
    background: linear-gradient(135deg, var(--accent-purple), var(--accent-cyan));
    color: white;
    border: none;
}

.btn-gradient:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 20px rgba(176, 38, 255, 0.4);
}

.btn-ghost {
    background: transparent;
    border: 1px solid var(--text-gray);
    color: var(--text-white);
}

.btn-ghost:hover {
    border-color: var(--text-white);
    background: rgba(255, 255, 255, 0.05);
}

/* Header */
header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: var(--header-height);
    background: rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--glass-border);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 5%;
}

.logo {
    font-size: 1.8rem;
    font-weight: 800;
    letter-spacing: 1px;
}

nav ul {
    display: flex;
    gap: 2rem;
}

nav a {
    color: var(--text-white);
    font-weight: 500;
    position: relative;
}

nav a:hover, nav a.active {
    text-shadow: 0 0 10px var(--accent-cyan);
    color: var(--accent-cyan);
}

.mobile-menu-btn {
    display: none;
    flex-direction: column;
    gap: 6px;
    cursor: pointer;
    background: none;
    border: none;
}

.mobile-menu-btn span {
    display: block;
    width: 25px;
    height: 2px;
    background: var(--text-white);
    transition: 0.3s;
}

.mobile-menu-btn.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}
.mobile-menu-btn.active span:nth-child(2) {
    opacity: 0;
}
.mobile-menu-btn.active span:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -6px);
}

/* Footer */
footer {
    background: rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(20px);
    border-top: 1px solid var(--glass-border);
    padding: 60px 5% 30px;
    margin-top: 80px;
}

.footer-content {
    display: flex;
    flex-wrap: wrap;
    gap: 40px;
    margin-bottom: 40px;
}

.footer-col {
    flex: 1;
    min-width: 200px;
}

.footer-col h4 {
    color: var(--text-white);
    margin-bottom: 20px;
    font-size: 1.2rem;
}

.footer-col ul li {
    margin-bottom: 10px;
}

.footer-col a {
    color: var(--text-gray);
}

.footer-col a:hover {
    color: var(--accent-cyan);
    padding-left: 5px;
}

.newsletter-section {
    padding: 60px;
    border-left: 3px solid var(--accent-purple);
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 30px;
}

.newsletter-form {
    display: flex;
    gap: 10px;
    margin-top: 15px;
}

.newsletter-form input {
    flex: 1;
    background: var(--glass);
    border: 1px solid var(--glass-border);
    padding: 10px 15px;
    border-radius: 50px;
    color: white;
    outline: none;
}

.newsletter-form input:focus {
    border-color: var(--accent-cyan);
    box-shadow: 0 0 10px rgba(0, 212, 255, 0.2);
}

.social-icons {
    display: flex;
    gap: 15px;
    margin-top: 20px;
}

.social-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--glass);
    border: 1px solid var(--glass-border);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s;
}

.social-icon:hover {
    background: var(--accent-purple);
    transform: scale(1.1);
    box-shadow: 0 0 15px var(--accent-purple);
}

/* Layout */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.main-content {
    padding-top: calc(var(--header-height) + 20px);
    min-height: calc(100vh - 300px);
}

/* Hero Section (Index) */
.hero-section {
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    margin-top: -80px; /* Offset header */
    padding-top: 80px;
}

.hero-bg-mesh {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    background: radial-gradient(circle at 20% 30%, rgba(176, 38, 255, 0.2) 0%, transparent 50%),
                radial-gradient(circle at 80% 70%, rgba(0, 212, 255, 0.2) 0%, transparent 50%);
    animation: pulse-glow 10s infinite alternate;
}

.hero-content {
    text-align: center;
    z-index: 1;
}

.hero-title {
    font-size: 4rem;
    margin-bottom: 1rem;
    line-height: 1.1;
}

.hero-subtitle {
    font-size: 1.5rem;
    color: var(--text-gray);
    margin-bottom: 2rem;
}

.hero-bg-elements {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    z-index: 0;
    pointer-events: none;
}

.hero-glow {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    opacity: 0.6;
}

.glow-1 {
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, var(--accent-purple), transparent);
    top: -100px;
    right: -100px;
    animation: pulse-glow 8s infinite alternate;
}

.glow-2 {
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, var(--accent-cyan), transparent);
    bottom: -50px;
    left: -100px;
    animation: pulse-glow 10s infinite alternate-reverse;
}

.hero-grid {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: 
        linear-gradient(rgba(255, 255, 255, 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
    background-size: 50px 50px;
    mask-image: radial-gradient(circle at center, black 40%, transparent 80%);
    -webkit-mask-image: radial-gradient(circle at center, black 40%, transparent 80%);
}

.float-el {
    position: absolute;
    font-size: 4rem;
    color: rgba(255, 255, 255, 0.1);
    animation: float 6s ease-in-out infinite;
    filter: drop-shadow(0 0 10px rgba(255, 255, 255, 0.2));
}

.el-1 { top: 15%; left: 15%; animation-delay: 0s; transform: rotate(-15deg); }
.el-2 { bottom: 20%; right: 10%; animation-delay: 2s; transform: rotate(15deg); font-size: 3rem; }
.el-3 { top: 25%; right: 20%; animation-delay: 4s; transform: rotate(10deg); font-size: 2.5rem; }
.el-4 { bottom: 15%; left: 25%; animation-delay: 1.5s; transform: rotate(-10deg); font-size: 3.5rem; }

/* Featured Games */
.section-title {
    display: flex;
    flex-direction: column;
    margin-bottom: 30px;
}

.section-label {
    color: var(--accent-cyan);
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    font-weight: 600;
    margin-bottom: 5px;
}

.horizontal-scroll {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-start;
    gap: 20px;
    padding: 20px 0;
}

/* Remove spacer */
.horizontal-scroll::after {
    display: none;
}

.horizontal-scroll::-webkit-scrollbar {
    display: none;
}

.game-card {
    flex: 1 1 280px;
    max-width: 350px;
    min-width: 250px;
    width: auto;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    cursor: pointer;
    overflow: hidden;
}

@media (max-width: 768px) {
    .game-card {
        flex: 1 1 100%;
        width: 100%;
        min-width: 0;
        max-width: none;
    }
}

.game-card:hover {
    transform: translateY(-8px);
    border-color: var(--accent-cyan);
    box-shadow: 0 10px 30px rgba(0, 212, 255, 0.2);
    z-index: 2;
    position: relative;
}

.card-img {
    height: 160px;
    width: 100%;
    object-fit: cover;
    border-top-left-radius: var(--radius);
    border-top-right-radius: var(--radius);
}

.card-info {
    padding: 15px;
}

.card-title {
    font-size: 1.1rem;
    margin-bottom: 5px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.card-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.9rem;
}

.genre-tag {
    color: var(--accent-cyan);
    background: rgba(0, 212, 255, 0.1);
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 0.8rem;
}

.rating-stars {
    color: #ffd700;
}

/* Categories */
.category-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    justify-content: center;
    margin: 40px 0;
}

.cat-pill {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 24px;
    border-radius: 50px;
    cursor: pointer;
    transition: 0.3s;
}

.cat-pill:hover {
    background: rgba(255, 255, 255, 0.15);
    transform: scale(1.05);
}

/* Stats */
.stats-section {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-around;
    gap: 20px;
    margin: 60px 0;
}

.stat-card {
    flex: 1;
    min-width: 150px;
    text-align: center;
    padding: 30px;
    border-right: 1px solid var(--glass-border);
}

.stat-card:last-child {
    border-right: none;
}

@media (max-width: 768px) {
    .stat-card {
        border-right: none;
        border-bottom: 1px solid var(--glass-border);
        width: 100%;
    }
    
    .stat-card:last-child {
        border-bottom: none;
    }
}

.stat-number {
    font-size: 2.5rem;
    font-weight: 800;
    margin-bottom: 5px;
    background: linear-gradient(to bottom, #fff, #aaa);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.stat-label {
    color: var(--text-gray);
    font-size: 0.9rem;
}

/* Detail Page */
.breadcrumb {
    padding: 20px 0;
    color: var(--text-gray);
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 10px;
}

.breadcrumb a:hover {
    color: var(--accent-cyan);
}

.detail-hero {
    position: relative;
    height: 400px;
    border-radius: 24px;
    overflow: hidden;
    margin-bottom: 30px;
}

.detail-cover {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.detail-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    padding: 30px;
    background: linear-gradient(to top, rgba(0,0,0,0.8), transparent);
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
}

.play-btn-large {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    animation: pulse-glow 2s infinite;
}

.play-btn-large::after {
    content: '';
    width: 0;
    height: 0;
    border-left: 25px solid white;
    border-top: 15px solid transparent;
    border-bottom: 15px solid transparent;
    margin-left: 5px;
}

.info-bar {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    margin-bottom: 30px;
    padding: 20px;
}

.info-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.info-item i {
    font-size: 1.5rem;
    color: var(--accent-cyan);
    margin-bottom: 5px;
}

.detail-layout {
    display: grid;
    grid-template-columns: 70% 30%;
    gap: 30px;
}

.game-tabs {
    display: flex;
    gap: 20px;
    margin-bottom: 20px;
    border-bottom: 1px solid var(--glass-border);
    padding-bottom: 10px;
}

.tab-btn {
    background: none;
    border: none;
    color: var(--text-gray);
    font-size: 1.1rem;
    cursor: pointer;
    padding: 10px 0;
    position: relative;
}

.tab-btn.active {
    color: var(--text-white);
}

.tab-btn.active::after {
    content: '';
    position: absolute;
    bottom: -11px;
    left: 0;
    width: 100%;
    height: 2px;
    background: var(--accent-cyan);
}

.tab-content {
    display: none;
    animation: fade-up 0.5s ease;
}

.tab-content.active {
    display: block;
}

.screenshots-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
}

.screenshot-thumb {
    width: auto;
    flex: 1 1 150px;
    height: 120px;
    object-fit: cover;
    border-radius: 8px;
    cursor: pointer;
    transition: 0.3s;
}

.screenshot-thumb:hover {
    transform: scale(1.05);
}

.sticky-sidebar {
    position: sticky;
    top: 100px;
    padding: 25px;
}

.game-price {
    font-size: 2rem;
    font-weight: 700;
    color: var(--accent-cyan);
    margin-bottom: 20px;
    display: block;
}

.action-buttons {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-bottom: 25px;
}

/* Tags Page */
.tags-layout {
    display: flex;
    gap: 30px;
    margin-top: 30px;
}

.tags-sidebar {
    width: 280px;
    flex-shrink: 0;
    height: fit-content;
    position: sticky;
    top: 100px;
    padding: 20px;
}

.filter-group {
    margin-bottom: 25px;
}

.filter-title {
    font-size: 1.1rem;
    margin-bottom: 15px;
    border-bottom: 1px solid var(--glass-border);
    padding-bottom: 10px;
}

.filter-list li {
    padding: 8px 10px;
    cursor: pointer;
    border-left: 2px solid transparent;
    transition: 0.3s;
    color: var(--text-gray);
}

.filter-list li:hover, .filter-list li.active {
    border-left-color: var(--accent-cyan);
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-white);
    padding-left: 15px;
}

.tags-main {
    flex: 1;
}

.tags-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.view-toggles {
    display: flex;
    gap: 10px;
}

.view-btn {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    cursor: pointer;
    background: var(--glass);
    border: 1px solid var(--glass-border);
}

.view-btn.active {
    background: var(--accent-purple);
    border-color: var(--accent-purple);
}

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

.games-grid .game-card {
    width: 100%;
    max-width: none;
    min-width: 0;
}

.games-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.games-list .game-card {
    display: flex;
    flex-direction: row;
    height: 140px;
}

.games-list .card-img {
    width: 200px;
    height: 100%;
    border-radius: var(--radius) 0 0 var(--radius);
}

.games-list .card-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

/* Contact Page */
.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    margin-top: 40px;
}

.contact-form {
    padding: 40px;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    color: var(--text-gray);
}

.form-input, .form-textarea {
    width: 100%;
    background: rgba(0, 0, 0, 0.2);
    border: 1px solid var(--glass-border);
    border-radius: 8px;
    padding: 12px;
    color: white;
    outline: none;
    transition: 0.3s;
    font-family: inherit;
}

.form-input:focus, .form-textarea:focus {
    border-color: var(--accent-cyan);
    box-shadow: 0 0 10px rgba(0, 212, 255, 0.1);
}

.faq-section {
    margin-top: 60px;
}

.faq-item {
    margin-bottom: 15px;
}

.faq-question {
    padding: 20px;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-weight: 600;
}

.faq-answer {
    padding: 0 20px;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
    color: var(--text-gray);
}

.faq-item.active .faq-answer {
    padding-bottom: 20px;
    max-height: 200px;
}

.faq-item.active .faq-question i {
    transform: rotate(180deg);
}

/* Legal Pages */
.legal-container {
    max-width: 900px;
    margin: 40px auto;
}

.toc {
    position: sticky;
    top: 100px;
    height: fit-content;
    padding: 20px;
}

.toc a {
    display: block;
    padding: 8px 0;
    color: var(--text-gray);
    font-size: 0.9rem;
    border-left: 2px solid transparent;
    padding-left: 10px;
}

.toc a.active {
    color: var(--accent-cyan);
    border-left-color: var(--accent-cyan);
}

.legal-content h2 {
    margin-top: 40px;
    margin-bottom: 20px;
}

.legal-content p {
    color: var(--text-gray);
    margin-bottom: 15px;
    line-height: 1.8;
}

/* Animations */
@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-20px); }
}

@keyframes pulse-glow {
    0%, 100% { box-shadow: 0 0 20px rgba(0, 212, 255, 0.3); }
    50% { box-shadow: 0 0 40px rgba(176, 38, 255, 0.5); }
}

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

/* Responsive */
@media (max-width: 768px) {
    .detail-layout, .tags-layout, .contact-grid, .legal-container {
        display: block;
    }
    
    .tags-sidebar, .toc {
        width: 100%;
        position: static;
        margin-bottom: 20px;
    }

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

    nav ul {
        display: none;
        width: 100%;
        background: rgba(15, 12, 41, 0.95);
        backdrop-filter: blur(20px);
        flex-direction: column;
        padding: 20px;
        text-align: center;
    }

    nav ul.active {
        display: flex;
    }

    .mobile-menu-btn {
        display: flex;
    }

    header nav {
        position: relative;
        display: flex;
        align-items: center;
    }

    header nav ul {
        position: fixed;
        top: var(--header-height);
        left: 0;
        right: 0;
        width: 100%;
        z-index: 999;
        max-height: 70vh;
        overflow-y: auto;
    }

    header nav ul.active {
        display: flex;
        flex-direction: column;
        gap: 12px;
        padding: 16px;
        border-top: 1px solid var(--glass-border);
    }

    header nav ul.active li {
        width: 100%;
    }

    header nav ul.active a {
        display: block;
        width: 100%;
        padding: 12px 14px;
        border-radius: 12px;
        background: rgba(255, 255, 255, 0.06);
        border: 1px solid var(--glass-border);
    }

    header nav ul.active a:hover,
    header nav ul.active a.active {
        border-color: rgba(0, 212, 255, 0.65);
        background: rgba(0, 212, 255, 0.08);
        box-shadow: 0 0 18px rgba(0, 212, 255, 0.18);
    }
    
    .footer-content {
        flex-direction: column;
    }
    
    .stats-section {
        flex-direction: column;
    }
    
    .stat-card {
        width: 100%;
    }

    .games-grid {
        grid-template-columns: 1fr;
    }
    
    .newsletter-section {
        flex-direction: column;
    }
    
    .newsletter-form {
        width: 100%;
    }
}
