/* ===== Block 1 ===== */
:root {
        /* Color Palette */
        --dark-dashboard-1: #1C2526;
        --dark-dashboard-2: #2E3A3B;
        --accent-cyan: #33C1CF;
        --hover-cyan: #069BAA;
        --text-light: #D3D8D9;
        --metallic-accent: #3F4E50;
        --content-bg-1: #f5f7fa;
        --content-bg-2: #e4e9f0;
        --offer-bg: #FFF5B7;
        --timer-red: #940924;
        --success-green: #28A745;
        --border-gray: #E0E0E0;
    }

    body {
        font-family: 'Poppins', sans-serif;
        margin: 0;
        padding: 0;
        background: linear-gradient(135deg, var(--dark-dashboard-1), var(--dark-dashboard-2));
        color: var(--text-light);
        min-height: 100vh;
        padding-bottom: 70px;
        overflow-x: hidden;
    }

    main {
        padding-top: 60px;
        padding-bottom: 70px;
        transition: background 0.5s ease;
    }

    /* Desktop Header */
    #header-main-desktop {
        position: fixed;
        top: 0;
        width: 100%;
        z-index: 1000;
        background: rgba(28, 37, 38, 0.85);
        backdrop-filter: blur(10px);
        border-bottom: 1px solid var(--metallic-accent);
        box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
        padding: 15px 40px;
        display: flex;
        justify-content: center;
        transition: transform 0.3s ease;
    }

    #header-main-desktop.sticky {
        transform: translateY(0);
        animation: slideDown 0.3s ease-in-out;
    }

    .header-container {
        width: 100%;
        max-width: 1200px;
        display: flex;
        justify-content: space-between;
        align-items: center;
    }

    .left-section, .right-section {
        display: flex;
        align-items: center;
    }

    .logo {
        margin-right: 20px;
    }

    .logo a {
        text-decoration: none;
        font-size: 22px;
        font-weight: 600;
        color: var(--accent-cyan);
        letter-spacing: 0.5px;
        transition: color 0.3s ease, text-shadow 0.3s ease;
    }

    .logo a:hover {
        color: var(--hover-cyan);
        text-shadow: 0 0 5px rgba(51, 193, 207, 0.3);
    }

    .location-box {
        display: flex;
        align-items: center;
        cursor: pointer;
        position: relative;
        background: rgba(63, 78, 80, 0.4);
        padding: 6px 12px;
        border-radius: 15px;
        border: 1px solid var(--metallic-accent);
        transition: background 0.3s ease, transform 0.3s ease;
    }

    .location-box:hover {
        background: rgba(63, 78, 80, 0.7);
        transform: scale(1.03);
    }

    .location-box i {
        margin-right: 4px;
        color: var(--text-light);
        font-size: 16px;
    }

    .location-text span {
        font-size: 12px;
        font-weight: 600;
        color: var(--text-light);
        text-transform: uppercase;
    }

    .nav-menu {
        display: flex;
        align-items: center;
        margin-left: 20px;
    }

    .nav-item {
        position: relative;
        margin-right: 20px;
        font-size: 13px;
        font-weight: 600;
        color: var(--accent-cyan) !important;
        cursor: pointer;
        text-transform: uppercase;
        letter-spacing: 0.3px;
        transition: color 0.3s ease, transform 0.3s ease;
    }

    .nav-item:hover {
        color: var(--hover-cyan) !important;
        transform: translateY(-1px);
    }

    /* Ensure nav links match logo color */
    .nav-menu a, 
    .nav-menu .nav-item,
    .header-container .nav-item {
        color: var(--accent-cyan) !important;
    }

    .nav-menu a:hover,
    .nav-menu .nav-item:hover,
    .header-container .nav-item:hover {
        color: var(--hover-cyan) !important;
    }

    .dropdown-menu {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        background: rgba(63, 78, 80, 0.95);
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
        border-radius: 6px;
        padding: 8px 0;
        border: 1px solid var(--metallic-accent);
        min-width: 150px;
    }

    .nav-item:hover .dropdown-menu {
        display: block;
        animation: fadeIn 0.3s ease-in-out;
    }

    .dropdown-menu a {
        display: block;
        padding: 8px 16px;
        color: var(--accent-cyan) !important;
        text-decoration: none;
        font-size: 12px;
        font-weight: 500;
        border-bottom: 1px solid var(--metallic-accent);
    }

    .dropdown-menu a:last-child {
        border-bottom: none;
    }

    .dropdown-menu a:hover {
        background: var(--hover-cyan) !important;
        color: #FFFFFF !important;
    }

    .search-bar {
        width: 350px;
        display: flex;
        align-items: center;
        background: rgba(63, 78, 80, 0.4);
        border-radius: 20px;
        padding: 8px 12px;
        margin-right: 30px;
        border: 1px solid var(--metallic-accent);
        transition: box-shadow 0.3s ease, transform 0.3s ease, background 0.3s ease;
    }

    .search-bar:hover {
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
        transform: scale(1.01);
        background: rgba(63, 78, 80, 0.6);
    }

    .search-bar i {
        margin-right: 8px;
        color: var(--accent-cyan);
        font-size: 14px;
    }

    .search-bar input {
        border: none;
        outline: none;
        font-family: 'Poppins', sans-serif;
        font-size: 12px;
        font-weight: 500;
        color: var(--text-light);
        width: 100%;
        background: transparent;
    }

    .search-bar input::placeholder {
        color: rgba(211, 216, 217, 0.7);
    }

    .account-icon, .cart-icon {
        margin-right: 20px;
        cursor: pointer;
        color: var(--text-light);
        font-size: 18px;
        transition: color 0.3s ease, transform 0.3s ease;
    }

    .account-icon:hover, .cart-icon:hover {
        color: var(--accent-cyan);
        transform: scale(1.05);
    }

    .cart-icon {
        position: relative;
    }

    .cart-badge {
        position: absolute;
        top: -8px;
        left: 12px;
        background: var(--timer-red);
        color: #FFFFFF;
        border-radius: 50%;
        padding: 2px 6px;
        font-size: 9px;
        font-weight: 500;
        visibility: hidden;
    }

    .sell-button {
        display: flex;
        align-items: center;
        justify-content: center;
        text-decoration: none;
        position: relative;
        width: 100px;
        height: 40px;
        background: linear-gradient(45deg, var(--accent-cyan), var(--hover-cyan));
        border-radius: 20px;
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2), inset 0 0 5px rgba(255, 255, 255, 0.2);
        transition: transform 0.3s ease, box-shadow 0.3s ease;
    }

    .sell-button:hover {
        transform: scale(1.03);
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3), inset 0 0 7px rgba(255, 255, 255, 0.3);
    }

    .sell-button-content {
        display: flex;
        align-items: center;
        z-index: 1;
        color: #FFFFFF;
        font-size: 13px;
        font-weight: 600;
        text-transform: uppercase;
    }

    .sell-button-content i {
        margin-right: 6px;
        font-size: 16px;
    }

    /* Mobile Top Bar */
    #mobile-top-bar {
        display: none;
        position: fixed;
        top: 0;
        width: 100%;
        z-index: 1000;
        background: rgba(28, 37, 38, 0.95);
        backdrop-filter: blur(10px);
        box-shadow: 0 2px 6px rgba(0,0,0,0.05);
        padding: 8px 12px;
        justify-content: space-between;
        align-items: center;
        border-bottom: 1px solid var(--metallic-accent);
    }

    .location-box-mobile {
        display: flex;
        align-items: center;
        cursor: pointer;
        position: relative;
    }

    .location-box-mobile i {
        margin-right: 3px;
        font-size: 18px;
        color: var(--text-light);
    }

    .location-box-mobile span {
        font-size: 11px;
        font-weight: 600;
        color: var(--text-light);
    }

    .right-icons i {
        font-size: 18px;
        margin: 0 6px;
        color: var(--text-light);
        cursor: pointer;
    }

    .right-icons {
        position: relative;
    }

    /* Mobile Search Bar */
    #mobile-search-bar {
        display: none;
        position: fixed;
        top: 36px;
        width: 100%;
        z-index: 999;
        background: rgba(28, 37, 38, 0.95);
        backdrop-filter: blur(10px);
        box-shadow: 0 1px 4px rgba(0,0,0,0.1);
        padding: 4px 12px;
    }

    .mobile-search-container {
        display: flex;
        align-items: center;
        background: rgba(63, 78, 80, 0.4);
        box-shadow: 0px 2px 6px rgba(0, 0, 0, 0.05);
        border-radius: 20px;
        padding: 3px 10px;
        width: 100%;
        max-width: 350px;
        border: 1px solid var(--metallic-accent);
        transition: background 0.3s ease;
    }

    .mobile-search-container:hover {
        background: rgba(63, 78, 80, 0.6);
    }

    .mobile-search-container i {
        margin-right: 6px;
        color: var(--accent-cyan);
        font-size: 14px;
    }

    .mobile-search-container input {
        border: none;
        outline: none;
        font-family: 'Work Sans', sans-serif;
        font-size: 11px;
        font-weight: 400;
        color: var(--text-light);
        width: 100%;
        background: transparent;
    }

    .mobile-search-container input::placeholder {
        color: rgba(211, 216, 217, 0.7);
    }

    /* Mobile Footer */
    #header-main-mobile {
        display: none;
        position: fixed;
        bottom: 0;
        width: 100%;
        z-index: 1000;
        background: rgba(28, 37, 38, 0.95);
        backdrop-filter: blur(10px);
        box-shadow: 0 -2px 8px rgba(0, 0, 0, 0.2);
        padding: 10px 0;
        border-top: 1px solid var(--metallic-accent);
    }

    #header-main-mobile ul {
        list-style: none;
        margin: 0;
        padding: 0;
        display: flex;
        justify-content: space-around;
        align-items: center;
        position: relative;
    }

    #header-main-mobile li {
        text-align: center;
        flex: 1;
        position: relative;
        transition: transform 0.3s ease, background 0.3s ease;
    }

    #header-main-mobile li:hover {
        transform: translateY(-1px);
        background: rgba(6, 155, 170, 0.1);
    }

    #header-main-mobile a {
        color: var(--accent-cyan) !important;
        text-decoration: none;
        font-size: 10px;
        font-weight: 500;
        text-transform: uppercase;
        letter-spacing: 0.3px;
    }

    #header-main-mobile i {
        display: block;
        font-size: 16px;
        margin-bottom: 3px;
        color: #FFFFFF;
        transition: color 0.3s ease;
    }

    #header-main-mobile li:hover i {
        color: #FFFFFF;
    }

    #header-main-mobile .sub-menu {
        display: none;
        position: absolute;
        bottom: 100%;
        left: 50%;
        transform: translateX(-50%);
        background: rgba(63, 78, 80, 0.95);
        box-shadow: 0 -2px 8px rgba(0, 0, 0, 0.2);
        border-radius: 6px;
        padding: 8px 0;
        border: 1px solid var(--metallic-accent);
        min-width: 150px;
    }

    #header-main-mobile li:hover .sub-menu {
        display: block;
        animation: slideUp 0.3s ease-in-out;
    }

    #header-main-mobile .sub-menu li {
        margin: 0;
        flex: none;
        border-bottom: 1px solid var(--metallic-accent);
    }

    #header-main-mobile .sub-menu li:last-child {
        border-bottom: none;
    }

    #header-main-mobile .sub-menu a {
        padding: 6px 12px;
        display: block;
        font-size: 11px;
        font-weight: 500;
        color: var(--accent-cyan) !important;
    }

    #header-main-mobile .sub-menu a:hover {
        background: var(--hover-cyan) !important;
        color: #FFFFFF !important;
    }

    .sell-button-mobile {
        display: flex;
        align-items: center;
        justify-content: center;
        width: 50px;
        height: 50px;
        background: linear-gradient(45deg, var(--accent-cyan), var(--hover-cyan));
        border-radius: 50%;
        text-decoration: none;
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2), inset 0 0 5px rgba(255, 255, 255, 0.2);
        position: absolute;
        left: 50%;
        transform: translateX(-50%) scale(1);
        top: -25px;
        z-index: 1;
        transition: transform 0.3s ease, box-shadow 0.3s ease;
    }

    .sell-button-mobile:hover {
        transform: translateX(-50%) scale(1.05);
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3), inset 0 0 7px rgba(255, 255, 255, 0.3);
    }

    .sell-button-mobile i {
        color: #FFFFFF;
        font-size: 20px;
    }

    .location-dropdown {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        background: rgba(63, 78, 80, 0.95);
        box-shadow: 0 2px 8px rgba(0,0,0,0.2);
        border-radius: 6px;
        padding: 8px;
        z-index: 1001;
        width: 250px;
        border: 1px solid var(--metallic-accent);
    }

    .location-box:hover .location-dropdown,
    .location-box-mobile:hover .location-dropdown {
        display: block;
        animation: fadeIn 0.3s ease-in-out;
    }

    .location-dropdown button {
        display: block;
        width: 100%;
        text-align: left;
        padding: 6px 12px;
        background: none;
        border: none;
        font-size: 12px;
        color: var(--text-light);
        cursor: pointer;
        transition: background 0.3s ease;
    }

    .location-dropdown button:hover {
        background: var(--hover-cyan);
        color: #FFFFFF;
    }

    .location-dropdown select {
        width: 100%;
        padding: 6px;
        margin-top: 6px;
        font-size: 12px;
        border: 1px solid var(--metallic-accent);
        border-radius: 4px;
        background: var(--dark-dashboard-1);
        color: var(--text-light);
    }

    .location-form {
        display: none;
        flex-direction: column;
        gap: 6px;
        margin-top: 8px;
    }

    .location-form input {
        width: 100%;
        padding: 6px;
        font-size: 12px;
        border: 1px solid var(--metallic-accent);
        border-radius: 4px;
        background: var(--dark-dashboard-1);
        color: var(--text-light);
    }

    .location-form button {
        background: var(--hover-cyan);
        color: #FFFFFF;
        border: none;
        padding: 6px;
        border-radius: 4px;
        cursor: pointer;
        font-weight: 600;
    }

    .suggestions {
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: rgba(63, 78, 80, 0.95);
        border: 1px solid var(--metallic-accent);
        border-radius: 4px;
        max-height: 120px;
        overflow-y: auto;
        z-index: 1002;
        display: none;
    }

    .suggestion {
        padding: 6px 12px;
        cursor: pointer;
        color: var(--text-light);
    }

    .suggestion:hover {
        background: var(--hover-cyan);
        color: #FFFFFF;
    }

    @keyframes slideDown {
        from {
            transform: translateY(-100%);
        }
        to {
            transform: translateY(0);
        }
    }

    @keyframes fadeIn {
        from {
            opacity: 0;
            transform: translateY(8px);
        }
        to {
            opacity: 1;
            transform: translateY(0);
        }
    }

    @keyframes slideUp {
        from {
            opacity: 0;
            transform: translateX(-50%) translateY(8px);
        }
        to {
            opacity: 1;
            transform: translateX(-50%) translateY(0);
        }
    }

    @media (max-width: 767px) {
        #header-main-desktop {
            display: none;
        }

        #mobile-top-bar, #mobile-search-bar {
            display: flex;
        }

        #header-main-mobile {
            display: block;
        }

        main {
            padding-top: 60px;
            padding-bottom: 70px;
        }

        .search-bar {
            display: none;
        }

        #mobile-top-bar {
            height: 36px;
        }

        #mobile-search-bar {
            top: 36px;
            padding: 4px 12px;
            height: 36px;
        }

        .mobile-search-container {
            padding: 3px 10px;
        }

        .location-dropdown {
            width: 200px;
        }
    }

    @media (min-width: 768px) {
        #mobile-top-bar, #mobile-search-bar, #header-main-mobile {
            display: none;
        }
    }