/* ==========================================================
   dd.css — Free Fire Simulator dropdown navigation
   Extracted from index.html's inline <style> so every page
   sharing this nav markup can be updated from one file.
   Uses the same CSS custom properties defined in each page's
   :root block (--bg-secondary, --gold, --orange, --text, etc.)
   ========================================================== */

.fire-nav {
    background: linear-gradient(135deg, var(--bg-secondary), #1A3A5C);
    padding: 14px 0;
    border-radius: 8px;
    margin: 5px 0;
    box-shadow: 0 4px 18px rgba(0,0,0,0.45);
    border-bottom: 2px solid var(--border);
}

.nav-container {
    max-width: 100%;
    margin: 0 auto;
    padding: 0 20px;
}

.nav-menu {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
    list-style: none;
    margin: 0;
    padding: 0;
}

.nav-item {
    position: relative;
}

.nav-link {
    color: var(--gold);
    text-decoration: none;
    font-family: Verdana, Arial, Helvetica, sans-serif;
    font-size: 14px;
    font-weight: bold;
    padding: 11px 18px;
    border-radius: 6px;
    transition: all 0.25s ease;
    display: flex;
    align-items: center;
    gap: 7px;
    white-space: nowrap;
    border: 1px solid transparent;
}

.nav-link:hover {
    background: rgba(216, 154, 30, 0.12);
    color: var(--text);
    border-color: var(--border);
    transform: translateY(-2px);
    box-shadow: 0 4px 14px rgba(196, 74, 42, 0.25);
}

/* Upload Your Own Photo — standalone CTA link (no dropdown) */
.nav-link.nav-cta {
    background: rgba(196, 74, 42, 0.18);
    border-color: var(--orange);
    color: var(--text);
}

.nav-link.nav-cta:hover {
    background: rgba(196, 74, 42, 0.32);
    border-color: var(--gold);
}

.dropdown-arrow {
    font-size: 10px;
    transition: transform 0.3s ease;
}

.nav-item:hover .dropdown-arrow,
.nav-item.open .dropdown-arrow {
    transform: rotate(180deg);
}

/* Dropdown Menu Styles */
.dropdown-menu {
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    background: linear-gradient(160deg, var(--bg-secondary), #1A3A5C);
    border: 2px solid var(--gold);
    border-radius: 8px;
    min-width: 285px;
    opacity: 0;
    visibility: hidden;
    transition: all 0.25s ease;
    z-index: 1000;
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
}

.nav-item:hover .dropdown-menu,
.nav-item.open .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(5px);
}

.dropdown-item {
    display: block;
    color: var(--text-soft);
    text-decoration: none;
    padding: 11px 18px;
    font-family: Verdana, Arial, Helvetica, sans-serif;
    font-size: 13px;
    border-bottom: 1px solid var(--border);
    transition: all 0.25s ease;
}

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

.dropdown-item:hover {
    background: rgba(196, 74, 42, 0.15);
    color: var(--text);
    padding-left: 24px;
    border-left: 3px solid var(--orange);
}

.dropdown-title {
    font-weight: bold;
    color: var(--text);
    font-size: 13px;
}

.dropdown-desc {
    font-size: 11px;
    color: var(--text-muted);
    display: block;
    margin-top: 3px;
}

.nav-icon {
    font-size: 16px;
}

/* ---- Mobile / touch ---- */
@media only screen and (max-width: 768px) {
    .nav-menu {
        flex-direction: column;
        gap: 10px;
    }

    .nav-link {
        font-size: 13px;
        padding: 10px 15px;
    }

    .dropdown-menu {
        position: static;
        transform: none;
        width: 100%;
        margin-top: 10px;
        display: none;
        border: 1px solid var(--border);
        opacity: 1;
        visibility: visible;
    }

    /* On touch devices there's no real hover, so the open/closed state
       is driven entirely by the .open class (toggled by js/dd.js) */
    .nav-item:hover .dropdown-menu {
        display: none;
    }

    .nav-item.open .dropdown-menu {
        display: block;
        transform: none;
    }
}
