/* ==========================================================================
   KHEL ADDA - STYLING & DESIGN SYSTEM
   ========================================================================== */

:root {
    --desi-wood: #2b1704;
    --desi-wood-light: #42260c;
    --desi-gold: #f39c12;
    --desi-gold-light: #f1c40f;
    --desi-orange: #d35400;
    --desi-terracotta: #e67e22;
    --desi-teal: #16a085;
    --desi-bg: #f9f3e6;
    --desi-card-bg: #fffbf2;
}

body {
    background: #18110a url('https://images.unsplash.com/photo-1579546929518-9e396f3cc809?auto=format&fit=crop&w=1600&q=80') center center fixed;
    background-size: cover;
    color: #2c3e50;
    font-family: 'Tiro Devanagari Hindi', 'Plus Jakarta Sans', serif;
}

.desi-shell {
    background: rgba(249, 243, 230, 0.94);
    min-height: 100vh;
    backdrop-filter: blur(8px);
}

/* Top Wooden Header */
.desi-header {
    background: linear-gradient(180deg, #3d220a 0%, #231204 100%);
    border-bottom: 4px solid var(--desi-gold);
    padding: 12px 24px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.6);
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: sticky;
    top: 0;
    z-index: 500;
}

.desi-brand {
    display: flex;
    align-items: center;
    gap: 14px;
    text-decoration: none;
}

.desi-logo-icon {
    width: 44px;
    height: 44px;
    background: linear-gradient(135deg, var(--desi-gold), var(--desi-orange));
    border-radius: 50%;
    display: grid;
    place-items: center;
    color: #fff;
    font-size: 22px;
    border: 2px solid #fff;
    box-shadow: 0 0 12px rgba(243, 156, 18, 0.6);
}

.desi-brand-text {
    font-family: 'Rozha One', 'Cinzel', serif;
    font-size: 24px;
    color: var(--desi-gold-light);
    letter-spacing: 0.05em;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.8);
    line-height: 1.1;
}

.desi-brand-text small {
    display: block;
    font-size: 11px;
    color: #e2e8f0;
    font-family: 'Tiro Devanagari Hindi', serif;
}

/* Mobile Hamburger Toggle Button */
.desi-hamburger-btn {
    display: none;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    background: linear-gradient(135deg, var(--desi-gold), var(--desi-orange));
    color: #ffffff;
    border: 2px solid #ffffff;
    border-radius: 12px;
    font-size: 20px;
    cursor: pointer;
    box-shadow: 0 4px 14px rgba(243, 156, 18, 0.4);
    transition: all 0.25s ease;
    outline: none;
}

.desi-hamburger-btn:hover,
.desi-hamburger-btn:active {
    transform: scale(1.05);
    background: linear-gradient(135deg, var(--desi-gold-light), var(--desi-terracotta));
}

.desi-nav {
    display: flex;
    align-items: center;
    gap: 10px;
}

.desi-nav-link {
    padding: 8px 16px;
    border-radius: 999px;
    color: #f1f5f9;
    font-weight: 700;
    font-size: 14px;
    text-decoration: none;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.desi-nav-link.active,
.desi-nav-link:hover {
    background: var(--desi-gold);
    color: #2b1704;
}

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

.desi-dropdown-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    min-width: 250px;
    background: linear-gradient(180deg, #2b1704 0%, #170b02 100%);
    border: 2px solid var(--desi-gold);
    border-radius: 14px;
    padding: 8px 0;
    box-shadow: 0 14px 35px rgba(0, 0, 0, 0.9);
    z-index: 1000;
    margin-top: 6px;
    animation: desiSlideDown 0.2s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.desi-nav-dropdown .fa-chevron-down {
    transition: transform 0.25s ease;
}

.desi-nav-dropdown.active .fa-chevron-down {
    transform: rotate(180deg);
}

.desi-nav-dropdown.active .desi-dropdown-menu,
.desi-dropdown-menu.active {
    display: block;
}

.desi-dropdown-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 18px;
    color: #f1f5f9;
    font-size: 14px;
    font-weight: 700;
    text-decoration: none;
    transition: all 0.2s ease;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.desi-dropdown-item:last-child {
    border-bottom: none;
}

.desi-dropdown-item:hover {
    background: linear-gradient(135deg, var(--desi-gold), var(--desi-orange));
    color: #ffffff;
    padding-left: 22px;
}

@keyframes desiSlideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Mobile Responsive Adjustments */
@media (max-width: 768px) {
    .desi-header {
        padding: 10px 16px;
        position: sticky;
        top: 0;
        z-index: 1000;
    }

    .desi-brand {
        gap: 10px;
    }

    .desi-logo-icon {
        width: 36px;
        height: 36px;
        font-size: 18px;
    }

    .desi-brand-text {
        font-size: 18px;
    }

    .desi-brand-text small {
        font-size: 9px;
    }

    .desi-hamburger-btn {
        display: flex;
    }

    .desi-nav {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: linear-gradient(180deg, #2b1704 0%, #150901 100%);
        border-bottom: 4px solid var(--desi-gold);
        flex-direction: column;
        align-items: stretch;
        padding: 16px 20px;
        gap: 10px;
        box-shadow: 0 14px 35px rgba(0, 0, 0, 0.95);
        z-index: 999;
    }

    .desi-nav.active {
        display: flex !important;
        animation: desiSlideDown 0.25s cubic-bezier(0.16, 1, 0.3, 1) forwards;
    }

    .desi-nav-link {
        padding: 12px 18px;
        border-radius: 12px;
        font-size: 15px;
        justify-content: flex-start;
        background: rgba(255, 255, 255, 0.05);
        border: 1px solid rgba(255, 255, 255, 0.1);
        width: 100%;
    }

    .desi-nav-link.active,
    .desi-nav-link:hover {
        background: var(--desi-gold);
        color: #2b1704;
        border-color: var(--desi-gold-light);
    }

    .desi-nav-dropdown {
        width: 100%;
    }

    .desi-dropdown-menu {
        position: static;
        width: 100%;
        box-shadow: none;
        margin-top: 6px;
        background: rgba(0, 0, 0, 0.4);
        border: 1px solid var(--desi-gold);
        border-radius: 10px;
    }
}



/* Hero Banner Section (No Bottom Color Gap) */
.desi-hero-section {
    width: 100%;
    background: transparent;
    border-bottom: none;
    box-shadow: none;
    padding-bottom: 0;
    margin-bottom: 20px;
    position: relative;
}

.desi-hero-banner-container {
    width: 100%;
    max-width: 100%;
    height: 100%;
    margin: 0 auto;
    display: flex;
    justify-content: center;
}

.desi-hero-img {
    width: 100%;
    height: auto;
    max-height: 480px;
    object-fit: cover;
    display: block;
}

.desi-search-container {
    width: 100%;
    display: flex;
    justify-content: center;
    padding: 0 20px;
    margin-top: -24px;
    position: relative;
    z-index: 10;
}

/* Search Box */
.desi-search-box {
    background: #ffffff;
    border: 3px solid var(--desi-gold);
    border-radius: 999px;
    padding: 6px 8px 6px 20px;
    display: flex;
    align-items: center;
    width: min(560px, 100%);
    box-shadow: 0 12px 35px rgba(0, 0, 0, 0.4), 0 0 20px rgba(243, 156, 18, 0.3);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.desi-search-box:focus-within {
    transform: translateY(-2px);
    box-shadow: 0 14px 35px rgba(243, 156, 18, 0.35);
}

.desi-search-input {
    border: none;
    outline: none;
    width: 100%;
    font-size: 15px;
    font-family: inherit;
    color: #2c3e50;
    font-weight: 600;
    background: transparent;
}

.desi-search-btn {
    background: linear-gradient(135deg, var(--desi-gold), var(--desi-orange));
    border: none;
    width: 42px;
    height: 42px;
    border-radius: 50%;
    color: #fff;
    font-size: 16px;
    cursor: pointer;
    display: grid;
    place-items: center;
    transition: transform 0.2s ease;
    flex-shrink: 0;
}

.desi-search-btn:hover {
    transform: scale(1.08);
}

/* Games Grid Section */
.desi-section {
    max-width: 1200px;
    margin: 40px auto;
    padding: 0 20px 60px;
}

.desi-section-title {
    font-family: 'Rozha One', serif;
    font-size: 28px;
    color: #2c3e50;
    margin-bottom: 24px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.desi-section-title::after {
    content: '';
    flex: 1;
    height: 2px;
    background: linear-gradient(90deg, var(--desi-gold) 0%, transparent 100%);
}

.desi-games-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 24px;
}

.desi-game-card {
    background: var(--desi-card-bg);
    border: 3px solid #d4a359;
    border-radius: 18px;
    padding: 16px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    position: relative;
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    overflow: hidden;
}

.desi-game-card:hover {
    transform: translateY(-8px);
    border-color: var(--desi-orange);
    box-shadow: 0 18px 35px rgba(0, 0, 0, 0.2), 0 0 20px rgba(243, 156, 18, 0.4);
}

.desi-card-header-badge {
    background: linear-gradient(135deg, #27ae60, #2ecc71);
    color: #fff;
    font-size: 11px;
    font-weight: 800;
    padding: 4px 10px;
    border-radius: 999px;
    display: inline-block;
    margin-bottom: 10px;
    align-self: flex-start;
}

.desi-card-header-badge.coming-soon-badge {
    background: linear-gradient(135deg, #7f8c8d, #95a5a6);
    color: #ffffff;
}

.desi-card-image-frame {
    width: 100%;
    height: 160px;
    border-radius: 12px;
    border: 2px solid #e2c286;
    overflow: hidden;
    position: relative;
    background: #f4ece1;
    margin-bottom: 14px;
}

.desi-card-image-frame img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.desi-game-card:hover .desi-card-image-frame img {
    transform: scale(1.08);
}

.desi-card-title {
    font-family: 'Rozha One', serif;
    font-size: 22px;
    color: #2c3e50;
    margin-bottom: 4px;
}

.desi-card-stats {
    font-size: 12px;
    color: #7f8c8d;
    margin-bottom: 10px;
    font-family: 'DM Mono', monospace;
}

.desi-card-desc {
    font-size: 13px;
    color: #555;
    line-height: 1.5;
    margin-bottom: 18px;
    flex: 1;
}

.desi-card-btn {
    background: linear-gradient(135deg, var(--desi-gold), var(--desi-orange));
    color: #ffffff;
    border: none;
    padding: 12px 14px;
    border-radius: 12px;
    font-weight: 800;
    font-size: 14px;
    cursor: pointer;
    width: 100%;
    text-align: center;
    transition: all 0.2s ease;
    box-shadow: 0 4px 12px rgba(230, 126, 34, 0.3);
    text-decoration: none;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    white-space: nowrap;
    box-sizing: border-box;
}

.desi-card-btn:hover:not(:disabled) {
    background: linear-gradient(135deg, var(--desi-gold-light), #e67e22);
    color: #000;
    box-shadow: 0 6px 18px rgba(243, 156, 18, 0.5);
}

.desi-card-btn.disabled-btn,
.desi-card-btn:disabled {
    background: #bdc3c7 !important;
    color: #7f8c8d !important;
    cursor: not-allowed !important;
    box-shadow: none !important;
    opacity: 0.7;
}

/* Modal Styling */
.desi-modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(10px);
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.desi-modal-overlay.active {
    opacity: 1;
    pointer-events: auto;
}

.desi-modal-card {
    background: #111a21;
    border: 3px solid var(--desi-gold);
    border-radius: 24px;
    padding: 32px;
    max-width: 650px;
    width: 100%;
    color: #fff;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.8);
    position: relative;
    transform: scale(0.9);
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    max-height: 90vh;
    overflow-y: auto;
}

.desi-modal-overlay.active .desi-modal-card {
    transform: scale(1);
}

.desi-modal-close {
    position: absolute;
    top: 18px;
    right: 20px;
    background: rgba(255, 255, 255, 0.1);
    border: none;
    color: #aaa;
    font-size: 24px;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    cursor: pointer;
    display: grid;
    place-items: center;
}

.desi-modal-title {
    font-family: 'Rozha One', serif;
    font-size: 26px;
    color: var(--desi-gold-light);
    margin-bottom: 10px;
}

/* How To Play Highlighted Selector Styling */
.desi-doc-selector-wrapper {
    background: linear-gradient(135deg, #2b1704 0%, #1a0d02 100%);
    border: 2px solid var(--desi-gold);
    border-radius: 18px;
    padding: 16px;
    margin-bottom: 24px;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.5), 0 0 15px rgba(243, 156, 18, 0.25);
    text-align: center;
}

.desi-doc-header-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: linear-gradient(135deg, #f39c12, #d35400);
    color: #ffffff;
    font-weight: 800;
    font-size: 13px;
    padding: 6px 18px;
    border-radius: 999px;
    margin-bottom: 14px;
    letter-spacing: 0.05em;
    box-shadow: 0 4px 12px rgba(243, 156, 18, 0.4);
}

.desi-doc-tabs {
    display: flex;
    gap: 8px;
    justify-content: center;
    flex-wrap: wrap;
    margin-bottom: 14px;
}

.desi-doc-tab {
    background: rgba(255, 255, 255, 0.08);
    border: 1.5px solid rgba(243, 156, 18, 0.3);
    color: #cbd5e1;
    padding: 8px 14px;
    border-radius: 10px;
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s ease;
}

.desi-doc-tab:hover {
    background: rgba(243, 156, 18, 0.2);
    color: #f1c40f;
    border-color: var(--desi-gold);
}

.desi-doc-tab.active {
    background: linear-gradient(135deg, var(--desi-gold), var(--desi-orange));
    color: #ffffff;
    border-color: #ffffff;
    box-shadow: 0 4px 15px rgba(243, 156, 18, 0.5);
}

.desi-doc-select-box {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    flex-wrap: wrap;
}

.desi-doc-select-box label {
    color: var(--desi-gold-light);
    font-weight: 700;
    font-size: 14px;
}

.desi-highlight-select {
    background: #18110a;
    color: #f1c40f;
    border: 2px solid var(--desi-gold);
    border-radius: 10px;
    padding: 8px 16px;
    font-size: 14px;
    font-weight: 700;
    outline: none;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
    transition: all 0.2s ease;
}

.desi-highlight-select:focus,
.desi-highlight-select:hover {
    border-color: #f1c40f;
    box-shadow: 0 0 15px rgba(243, 156, 18, 0.6);
}

.desi-highlight-select option {
    background: #2b1704;
    color: #ffffff;
    padding: 10px;
}

.diagram-container {
    background: #090e13;
    border: 2px solid rgba(243, 156, 18, 0.3);
    border-radius: 18px;
    padding: 24px;
    margin: 20px 0;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.pass-circle-wrapper {
    position: relative;
    width: 220px;
    height: 220px;
    margin: 10px 0;
}

.pass-circle-ring {
    position: absolute;
    inset: 15px;
    border: 2px dashed rgba(255, 255, 255, 0.25);
    border-radius: 50%;
}

.pass-circle-center {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    font-family: 'DM Mono', monospace;
    font-weight: 800;
    font-size: 13px;
    color: #e2e8f0;
    letter-spacing: 0.1em;
}

.pass-node {
    position: absolute;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: #1e293b;
    border: 2px solid var(--desi-gold);
    color: #fff;
    display: grid;
    place-items: center;
    font-weight: 800;
    font-size: 15px;
}

.node-p1 {
    top: 0;
    left: 50%;
    transform: translateX(-50%);
}

.node-p2 {
    top: 50%;
    right: 0;
    transform: translateY(-50%);
}

.node-p3 {
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
}

.node-p4 {
    top: 50%;
    left: 0;
    transform: translateY(-50%);
}

.pass-arrow {
    position: absolute;
    color: var(--desi-gold-light);
    font-size: 18px;
    animation: pulse-arrow 1.5s infinite alternate;
}

.arrow-p1-p2 {
    top: 22px;
    right: 40px;
    transform: rotate(45deg);
}

.arrow-p2-p3 {
    bottom: 22px;
    right: 40px;
    transform: rotate(135deg);
}

.arrow-p3-p4 {
    bottom: 22px;
    left: 40px;
    transform: rotate(225deg);
}

.arrow-p4-p1 {
    top: 22px;
    left: 40px;
    transform: rotate(315deg);
}

.rule-list {
    text-align: left;
    font-size: 14px;
    color: #cbd5e1;
    line-height: 1.6;
    margin-bottom: 24px;
    list-style: none;
    padding: 0;
}

.rule-list li {
    margin-bottom: 8px;
}

.desi-footer {
    background: #1a0d03;
    border-top: 3px solid var(--desi-gold);
    color: #94a3b8;
    padding: 24px;
    text-align: center;
    font-size: 13px;
}