:root {
    --bg-primary: #f8fafc;
    --bg-secondary: #ffffff;
    --bg-card: #ffffff;
    --accent: #6366f1;
    --accent-hover: #4f46e5;
    --text-primary: #0f172a;
    --text-secondary: #64748b;
    --border-color: #e2e8f0;
    --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
    --shadow: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
    --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
    --container-width: 1280px;
    --font-heading: 'Outfit', sans-serif;
    --font-body: 'Inter', sans-serif;
}

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

body {
    font-family: var(--font-body);
    background-color: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
}

h1, h2, h3, h4, .logo {
    font-family: var(--font-heading);
}

a {
    text-decoration: none;
    color: inherit;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 1.5rem;
}

/* Header */
.main-header {
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    padding: 1rem 0;
    border-bottom: 1px solid var(--border-color);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.main-header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 80px;
}

.logo {
    font-size: 1.5rem;
    font-weight: 800;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: linear-gradient(135deg, var(--accent) 0%, var(--accent-secondary) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    font-family: var(--font-heading);
    white-space: nowrap;
}

.main-nav {
    display: flex;
    gap: 1.25rem;
    align-items: center;
    margin-left: auto; /* Push to the right */
    white-space: nowrap;
}

.main-nav a {
    font-weight: 600;
    color: var(--text-secondary);
    font-size: 0.95rem;
    padding: 0.5rem 0.25rem;
    position: relative;
}

.main-nav a:hover, .main-nav a.active {
    color: var(--accent);
}

.main-nav a.active::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: var(--accent);
    border-radius: 99px;
}

/* Dropdown Styles */
.nav-dropdown {
    position: relative;
    display: inline-block;
}

.dropdown-trigger {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    cursor: pointer;
    font-weight: 600;
    color: var(--text-secondary);
    font-size: 0.95rem;
    padding: 0.5rem 0;
}

.dropdown-content {
    display: none;
    position: absolute;
    top: 100%;
    right: 0; /* Align to right since nav is on the right */
    background-color: white;
    min-width: 350px;
    max-height: 400px;
    overflow-y: auto;
    box-shadow: var(--shadow-lg);
    border-radius: 16px;
    z-index: 1000;
    padding: 1rem;
    border: 1px solid #f1f5f9;
    grid-template-columns: 1fr 1fr; /* 2 columns for better space */
    gap: 0.5rem;
}

.nav-dropdown:hover .dropdown-content {
    display: grid;
}

.dropdown-content a {
    color: var(--text-primary);
    padding: 0.6rem 1rem;
    text-decoration: none;
    display: block;
    font-size: 0.9rem;
    font-weight: 500;
    transition: all 0.2s;
    border: none !important;
    border-radius: 8px;
}

.dropdown-content a:hover {
    background-color: #f1f5f9;
    color: var(--accent);
}

/* Custom Scrollbar for Dropdown */
.dropdown-content::-webkit-scrollbar {
    width: 6px;
}
.dropdown-content::-webkit-scrollbar-track {
    background: #f8fafc;
    border-radius: 10px;
}
.dropdown-content::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 10px;
}
.dropdown-content::-webkit-scrollbar-thumb:hover {
    background: #94a3b8;
}

.mobile-menu-btn {
    display: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--text-primary);
    background: #f1f5f9;
    width: 45px;
    height: 45px;
    border-radius: 12px;
    align-items: center;
    justify-content: center;
    transition: all 0.3s;
}

.mobile-menu-btn:hover {
    background: #e2e8f0;
}

.header-right {
    display: flex;
    gap: 1rem;
    align-items: center;
}

.search-bar {
    position: relative;
}

.search-bar input {
    background: #f1f5f9;
    border: 1px solid transparent;
    padding: 0.6rem 1.2rem;
    padding-left: 2.5rem;
    border-radius: 99px;
    color: var(--text-primary);
    width: 140px; /* Smaller default width */
    font-size: 0.85rem;
    transition: all 0.3s;
}

.search-bar input:focus {
    outline: none;
    background: #ffffff;
    border-color: var(--accent);
    box-shadow: 0 0 0 4px rgba(99, 102, 241, 0.1);
    width: 180px; /* Smaller expanded width */
}

/* Hero Section */
.main-hero {
    padding: 8rem 0;
    background: #ffffff;
    overflow: hidden;
    position: relative;
}

.floating-shapes .shape {
    position: absolute;
    filter: blur(80px);
    z-index: 1;
    opacity: 0.4;
    border-radius: 50%;
}

.shape.s1 { width: 400px; height: 400px; background: var(--accent); top: -100px; right: -100px; }
.shape.s2 { width: 300px; height: 300px; background: var(--accent-secondary); bottom: -50px; left: -50px; }
.shape.s3 { width: 200px; height: 200px; background: var(--accent); top: 20%; left: 10%; opacity: 0.2; }

.hero-wrapper {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 4rem;
    align-items: center;
    position: relative;
    z-index: 2;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    background: rgba(99, 102, 241, 0.1);
    color: var(--accent);
    padding: 0.6rem 1.2rem;
    border-radius: 99px;
    font-weight: 700;
    font-size: 0.9rem;
    margin-bottom: 2rem;
    border: 1px solid rgba(99, 102, 241, 0.2);
}

.hero-badge .pulse {
    width: 8px; height: 8px; background: var(--accent); border-radius: 50%; position: relative;
}

.hero-badge .pulse::after {
    content: ''; position: absolute; width: 100%; height: 100%; background: inherit; border-radius: inherit; animation: pulse-ring 1.5s infinite;
}

@keyframes pulse-ring {
    0% { transform: scale(1); opacity: 0.8; }
    100% { transform: scale(3); opacity: 0; }
}

.hero-h1 {
    font-size: 4rem; font-weight: 900; line-height: 1.1; margin-bottom: 1.5rem; letter-spacing: -0.04em; background: linear-gradient(135deg, var(--text-primary) 0%, #475569 100%); -webkit-background-clip: text; -webkit-text-fill-color: transparent;
}

.hero-p {
    font-size: 1.25rem; color: var(--text-secondary); line-height: 1.6; margin-bottom: 2.5rem; max-width: 600px;
}

.hero-actions {
    display: flex; gap: 1.25rem;
}

.btn-hero-primary {
    background: var(--accent); color: white; padding: 1rem 2.5rem; border-radius: 14px; font-weight: 800; font-size: 1.1rem; display: flex; align-items: center; box-shadow: 0 10px 20px -5px rgba(99, 102, 241, 0.4);
}

.btn-hero-primary:hover {
    background: var(--accent-hover); transform: translateY(-3px); box-shadow: 0 15px 25px -5px rgba(99, 102, 241, 0.5);
}

.btn-hero-secondary {
    background: white; color: var(--text-primary); padding: 1rem 2.5rem; border-radius: 14px; font-weight: 800; font-size: 1.1rem; border: 1px solid var(--border-color);
}

.btn-hero-secondary:hover {
    background: #f8fafc; border-color: var(--accent); color: var(--accent);
}

.hero-visual { position: relative; }

.hero-image-grid {
    display: grid; grid-template-columns: 1fr 1fr; gap: 1.5rem; transform: perspective(1000px) rotateY(-15deg) rotateX(10deg);
}

.hero-img-card {
    background: rgba(255, 255, 255, 0.8); backdrop-filter: blur(10px); padding: 12px; border-radius: 24px; box-shadow: 0 20px 40px -10px rgba(0,0,0,0.1); border: 1px solid rgba(255, 255, 255, 0.5); transition: all 0.6s cubic-bezier(0.34, 1.56, 0.64, 1); animation: float-hero 6s ease-in-out infinite;
}

.hero-img-card img { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 18px; }

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

.hero-img-card:nth-child(even) { transform: translateY(3rem); animation: float-hero-even 6s ease-in-out infinite; animation-delay: -3s; }

@keyframes float-hero-even {
    0%, 100% { transform: translateY(3rem); }
    50% { transform: translateY(1.5rem); }
}

/* Sections */
.section-header { display: flex; justify-content: space-between; align-items: center; margin: 4rem 0 2rem; }
.section-title { font-size: 1.875rem; font-weight: 800; color: var(--text-primary); display: flex; align-items: center; gap: 0.75rem; }

.game-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 2rem; margin-bottom: 4rem; }

.game-card { background: var(--bg-card); border-radius: 16px; overflow: hidden; transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1); display: flex; flex-direction: column; border: 1px solid var(--border-color); box-shadow: var(--shadow-sm); }
.game-card:hover { transform: translateY(-8px); box-shadow: var(--shadow-lg); border-color: var(--accent); }
.game-card .thumb { position: relative; aspect-ratio: 16/10; overflow: hidden; background: #e2e8f0; }
.game-card .thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.5s; }
.game-card:hover .thumb img { transform: scale(1.1); }

.category-tag { position: absolute; top: 12px; right: 12px; background: rgba(255, 255, 255, 0.9); backdrop-filter: blur(4px); color: var(--text-primary); font-size: 0.7rem; font-weight: 700; padding: 4px 10px; border-radius: 99px; text-transform: uppercase; letter-spacing: 0.05em; box-shadow: var(--shadow-sm); }

.game-card .details { padding: 1.25rem; flex-grow: 1; display: flex; flex-direction: column; }
.game-card h3 { font-size: 1.125rem; margin-bottom: 0.5rem; font-weight: 700; color: var(--text-primary); }
.game-card p { color: var(--text-secondary); font-size: 0.875rem; margin-bottom: 1.25rem; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }

.btn-play { margin-top: auto; background: #f1f5f9; color: var(--accent); padding: 0.6rem; border-radius: 10px; text-align: center; font-weight: 700; font-size: 0.9rem; transition: all 0.3s; }
.game-card:hover .btn-play { background: var(--accent); color: white; }

/* Game Page */
.game-container-layout { display: grid; grid-template-columns: 1fr 350px; gap: 2.5rem; margin-top: 2rem; }
.game-player-wrapper { position: relative; width: 100%; padding-top: 56.25%; background: #000; border-radius: 20px; overflow: hidden; box-shadow: var(--shadow-lg); margin-bottom: 1.5rem; }
.game-iframe { position: absolute; top: 0; left: 0; width: 100%; height: 100%; border: none; }
.game-title-h1 { font-size: 2.5rem; font-weight: 900; margin-bottom: 1.5rem; color: var(--text-primary); }
.game-actions-bar { display: flex; gap: 1rem; margin-bottom: 2rem; }
.game-actions-bar button { display: flex; align-items: center; gap: 0.5rem; padding: 0.8rem 1.5rem; border-radius: 12px; font-weight: 700; cursor: pointer; border: 1px solid var(--border-color); background: white; transition: all 0.3s; }
.game-actions-bar button:hover { background: #f8fafc; border-color: var(--accent); color: var(--accent); }
.btn-primary { background: var(--accent) !important; color: white !important; border: none !important; }

.game-info-box { background: white; padding: 2rem; border-radius: 20px; border: 1px solid var(--border-color); box-shadow: var(--shadow); }
.info-section h2 { font-size: 1.5rem; margin-bottom: 1rem; }
.info-section p { color: var(--text-secondary); margin-bottom: 2rem; font-size: 1.05rem; }

/* Footer */
.main-footer { background: white; padding: 5rem 0 2rem; margin-top: 5rem; border-top: 1px solid var(--border-color); }
.footer-cols { display: grid; grid-template-columns: 2fr 1fr 1fr 1.5fr; gap: 4rem; margin-bottom: 4rem; }
.footer-cols h3 { font-size: 1.1rem; font-weight: 700; margin-bottom: 1.5rem; }
.footer-cols ul { list-style: none; }
.footer-cols ul li { margin-bottom: 0.75rem; }
.footer-cols ul li a { color: var(--text-secondary); font-size: 0.95rem; }
.footer-cols ul li a:hover { color: var(--accent); padding-left: 5px; }
.copyright { text-align: center; padding-top: 2rem; border-top: 1px solid var(--border-color); color: var(--text-secondary); font-size: 0.9rem; }

/* Sidebar */
.sidebar-game-card { display: flex; gap: 1rem; padding: 1rem; background: white; border-radius: 12px; margin-bottom: 1rem; border: 1px solid var(--border-color); transition: all 0.3s; }
.sidebar-game-card:hover { border-color: var(--accent); box-shadow: var(--shadow); }
.sidebar-game-card img { width: 90px; height: 70px; object-fit: cover; border-radius: 8px; }
.sidebar-game-card .text h4 { font-size: 1rem; margin-bottom: 0.25rem; }
.sidebar-game-card .text span { font-size: 0.8rem; color: var(--text-secondary); }

/* Ads */
.ad-placeholder { background: #f1f5f9; border: 2px dashed #cbd5e1; color: #94a3b8; border-radius: 12px; text-align: center; padding: 2rem; font-weight: 700; }

/* Responsive */
@media (max-width: 1024px) {
    .hero-wrapper { grid-template-columns: 1fr; text-align: center; gap: 3rem; }
    .hero-h1 { font-size: 2.8rem; }
    .hero-p { margin: 0 auto 2.5rem; }
    .hero-actions { justify-content: center; }
    .hero-visual { max-width: 500px; margin: 0 auto; }
    .hero-image-grid { transform: none; }
    .game-container-layout { grid-template-columns: 1fr; }
    .footer-cols { grid-template-columns: 1fr 1fr; gap: 2rem; }

    .main-nav {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: white;
        flex-direction: column;
        padding: 1.5rem;
        gap: 0;
        box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
        border-top: 1px solid #f1f5f9;
        z-index: 1000;
        margin: 0;
    }

    .main-nav.active { 
        display: flex !important;
        max-height: 80vh;
        overflow-y: auto;
    }
    .main-nav a { width: 100%; padding: 1rem 0; font-size: 1.1rem; border-bottom: 1px solid #f8fafc; display: block; }

    .nav-dropdown { display: block; width: 100%; }
    .dropdown-trigger { 
        display: block; 
        padding: 1.5rem 0 0.5rem 0; 
        font-size: 0.8rem;
        text-transform: uppercase;
        color: var(--text-secondary);
        font-weight: 800;
        letter-spacing: 0.1em;
        pointer-events: none; /* Make it just a label on mobile */
    }
    .dropdown-content { display: block; position: static; box-shadow: none; border: none; padding: 0; }
    .dropdown-content a { padding: 0.75rem 0 0.75rem 1rem; border: none !important; font-size: 1rem; color: var(--text-primary); }

    .mobile-menu-btn { display: flex; }
    .search-bar { display: none; }
}

@media (max-width: 640px) {
    .hero-section h1 { font-size: 2.5rem; }
    .footer-cols { grid-template-columns: 1fr; }
    .game-grid { grid-template-columns: 1fr 1fr; gap: 1rem; }
}

/* Blog Styles */
.home-blog-card { background: white; border-radius: 20px; overflow: hidden; border: 1px solid var(--border-color); box-shadow: var(--shadow-sm); transition: all 0.4s; display: flex; flex-direction: column; }
.home-blog-card:hover { transform: translateY(-10px); box-shadow: var(--shadow-lg); }
.home-blog-thumb { height: 180px; overflow: hidden; position: relative; }
.home-blog-thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.5s; }
.home-blog-card:hover .home-blog-thumb img { transform: scale(1.1); }
.home-blog-content { padding: 1.5rem; flex-grow: 1; }
.home-blog-date { color: var(--accent); font-size: 0.85rem; font-weight: 700; display: block; margin-bottom: 0.75rem; }
.home-blog-title a { color: var(--text-primary); transition: color 0.3s; }
.home-blog-card:hover .home-blog-title a { color: var(--accent); }
.home-blog-excerpt { color: var(--text-secondary); font-size: 0.95rem; line-height: 1.6; margin-bottom: 1.5rem; }

/* Breadcrumbs */
.breadcrumb-wrapper { background: #ffffff; padding: 1.25rem 0; border-bottom: 1px solid var(--border-color); margin-bottom: 3rem; }
.breadcrumb { display: flex; align-items: center; gap: 0.75rem; color: var(--text-secondary); font-size: 0.9rem; font-weight: 500; }
.breadcrumb a { color: var(--text-secondary); }
.breadcrumb a:hover { color: var(--accent); }
.breadcrumb span.current { color: var(--text-primary); font-weight: 700; }

/* Content Layout */
.content-layout { display: grid; grid-template-columns: 1fr 350px; gap: 4rem; }
@media (max-width: 1200px) { .content-layout { grid-template-columns: 1fr 280px; gap: 2rem; } }
@media (max-width: 768px) { .content-layout { grid-template-columns: 1fr; } }

.post-content img, .content img, .ck-content img { max-width: 100% !important; height: auto !important; border-radius: 12px; }
.post-content, .content, .ck-content { width: 100%; overflow-wrap: break-word; }
.post-content table, .content table { display: block; overflow-x: auto; width: 100%; }
