.main-menu-area ul > li {
    display: inline-block;
    position: relative;
    padding: 0px 10px;
}

/* Profile Link Styles */
.profile-link {
    position: relative;
    display: inline-block;
    text-decoration: none;
    color: inherit;
}

.profile-link .profile-name {
    position: absolute;
    top: 100%;
    right: 0;
    background: #333;
    color: white;
    padding: 8px 12px;
    border-radius: 4px;
    font-size: 12px;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s ease;
    z-index: 1000;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.profile-link .profile-name::before {
    content: "";
    position: absolute;
    top: -5px;
    right: 10px;
    width: 0;
    height: 0;
    border-left: 5px solid transparent;
    border-right: 5px solid transparent;
    border-bottom: 5px solid #333;
}

.profile-link:hover .profile-name {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.profile-link:hover {
    color: #007bff;
}

.product-image > a img {
    width: 100%;
    height: 260px;
    object-fit: fill;
}

.dblocks {
    background: #ffcc00;
    color: black;
}

@media only screen and (max-width: 480px) {
    .Feature-tiem > a img {
        height: 165px !important;
    }

    .dblocks {
        display: block !important;
    }

    .mobwidth {
        width: 20%;
        padding-right: 0px;
    }

    .mobwidth1 {
        width: 21%;
        padding-left: 0px;
        padding-right: 0px;
    }

    .mobwidth2 {
        width: 57%;
    }
}

.newsletter-footer .subscribe-btn {
    border-radius: 10px;
}

.sidbar-product .sidbar-product-inner .product-image {
    padding-right: 10px;
    width: 83px;
}

/* ========== NEW TOPBAR & NAVBAR STYLES ========== */

/* Top Bar Styles */
.top-bar-new {
    background: #f8f9fa;
    padding: 8px 0;
    font-size: 13px;
    border-bottom: 1px solid #e9ecef;
}

.promo-items {
    gap: 2rem !important;
}

.promo-item {
    display: flex;
    align-items: center;
    gap: 6px;
    color: #495057;
    font-size: 12px;
}

.promo-item i {
    font-size: 16px;
    color: #6c757d;
}

.top-actions {
    gap: 1rem !important;
}

.lang-switch {
    padding: 2px 16px;
    font-size: 14px;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 90px;
    border: 1px solid #dee2e6;
    border-radius: 50px;
    background-color: #ffffff;
    color: #495057;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

.lang-switch:hover {
    background-color: #f8f9fa;
    border-color: #adb5bd;
    color: #212529;
    transform: translateY(-1px);
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.auth-buttons a {
    text-decoration: none;
    font-size: 13px;
    transition: color 0.2s;
}

.auth-buttons a:hover {
    color: #0056b3 !important;
}

/* New Navbar Styles */
.navbar-new {
    background: white;
    padding: 12px 0;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
    z-index: 1000;
}

.nav-content-wrapper {
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: relative; /* Essential for search dropdown positioning */
}

.nav-left,
.nav-right {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.btn-nav-action {
    background: transparent;
    border: none;
    padding: 8px 12px;
    display: flex;
    align-items: center;
    gap: 6px;
    color: #212529;
    font-size: 14px;
    cursor: pointer;
    text-decoration: none;
    transition: all 0.2s;
    border-radius: 4px;
}

.btn-nav-action:hover {
    background: #f8f9fa;
    color: #0056b3;
}

.btn-nav-action i {
    font-size: 20px;
}

.brand-image-logo img {
    height: 40px;
    width: auto;
}

/* Sticky behavior */
.navbar-new.nav-fixed-top {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    width: 100%;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    border-bottom: 1px solid #154a901a;
    transition: 0.3s all ease-out;
}

body.header-stuck {
    padding-top: var(--sticky-header-height, 0);
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .top-bar-new {
        padding: 6px 0;
    }

    .navbar-new {
        padding: 10px 0;
    }

    .btn-nav-action {
        padding: 6px 8px;
    }

    .btn-nav-action span {
        display: none;
    }

    .brand-image-logo img {
        height: 32px;
    }

    .top-actions {
        justify-content: flex-end !important;
    }
}

/* Additional sidebar grid utilities */
.g-3 {
    gap: 1rem;
}

.mb-4 {
    margin-bottom: 1.5rem !important;
}

.mt-2 {
    margin-top: 0.5rem !important;
}

.justify-content-end {
    justify-content: flex-end !important;
}

/* Search Dropdown Styles */
/* Search Dropdown Styles - Redesigned */
.search-dropdown-menu {
    position: absolute;
    top: 100%;
    right: 0;
    width: 400px;
    background: #ffffff;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.1);
    padding: 24px;
    border-radius: 16px;
    z-index: 1050;
    display: none;
    border: 1px solid rgba(0, 0, 0, 0.06);
    opacity: 0;
    transform: translateY(-10px);
    transition: all 0.3s cubic-bezier(0.165, 0.84, 0.44, 1);
    margin-top: 15px;
}

.search-dropdown-menu.show {
    display: block;
    opacity: 1;
    transform: translateY(0);
}

/* Triangle pointer for desktop */
.search-dropdown-menu::before {
    content: "";
    position: absolute;
    top: -8px;
    right: 36px;
    width: 16px;
    height: 16px;
    background: #fff;
    transform: rotate(45deg);
    border-left: 1px solid rgba(0, 0, 0, 0.06);
    border-top: 1px solid rgba(0, 0, 0, 0.06);
}

.search-input-wrapper {
    display: flex;
    align-items: center;
    border: 2px solid #f1f3f5;
    border-radius: 12px;
    background: #f8f9fa;
    transition: all 0.2s;
    padding: 4px;
}

.search-input-wrapper:focus-within {
    background: #fff;
    border-color: #ffcc00; /* Theme Color */
    box-shadow: 0 0 0 4px rgba(255, 204, 0, 0.1);
}

.search-input-wrapper input {
    border: none;
    padding: 12px 15px;
    width: 100%;
    outline: none;
    background: transparent;
    font-size: 15px;
    color: #212529;
    font-weight: 500;
}

.search-input-wrapper button {
    background: #ffcc00;
    border: none;
    width: 42px;
    height: 42px;
    border-radius: 8px;
    color: #212529;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.search-input-wrapper button:hover {
    background: #ffdb4d;
    transform: scale(1.05);
}

.search-tags {
    margin-top: 15px;
}

.search-tags-title {
    font-size: 12px;
    text-transform: uppercase;
    color: #adb5bd;
    font-weight: 600;
    letter-spacing: 0.5px;
    margin-bottom: 10px;
    display: block;
}

.tag-cloud {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.search-tag {
    font-size: 13px;
    color: #495057;
    background: #f8f9fa;
    padding: 6px 14px;
    border-radius: 20px;
    text-decoration: none;
    transition: all 0.2s;
    border: 1px solid #e9ecef;
}

.search-tag:hover {
    background: #ffcc00;
    color: #000;
    border-color: #ffcc00;
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .search-dropdown-menu {
        position: fixed;
        top: 80px; /* Position below the sticky navbar */
        left: 15px;
        right: 15px;
        width: auto;
        margin-top: 0;
        border-radius: 12px;
        box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
        padding: 20px;
        border: 1px solid rgba(0, 0, 0, 0.05);
        z-index: 1100; /* Higher than navbar */
    }

    .search-dropdown-menu::before {
        display: none;
    }

    /* Ensure the text doesn't overflow */
    .search-input-wrapper input {
        font-size: 16px; /* Stop iOS zoom */
    }
}

/* RTL Specific Fixes */
[dir="rtl"] .search-dropdown-menu {
    right: auto;
    left: 0;
}

[dir="rtl"] .search-dropdown-menu::before {
    right: auto;
    left: 36px;
    border-left: none;
    border-right: 1px solid rgba(0, 0, 0, 0.06); /* Flip border */
}

[dir="rtl"] #cart-total {
    right: auto;
    left: -5px;
}

/* Fix Offcanvas position for RTL if not handled by Bootstrap automatically (BS5 RTL usually handles this if classes are correct) */
/* .offcanvas-start in RTL becomes right side? No, start is right in RTL. correct. */

/* Header Toggle */
#es-header {
    display: none !important;
}

/* Cart Modal Animations */
@keyframes scaleIn {
    from {
        transform: scale(0);
        opacity: 0;
    }
    to {
        transform: scale(1);
        opacity: 1;
    }
}

#cartSuccessModal .modal-content {
    overflow: hidden;
}

/* Customer Header Dropdown */
/* Customer Header Dropdown */
.customer-header-dropdown {
    position: relative;
    display: inline-block;
}

.customer-header-dropdown .dropdown-toggle::after {
    display: none; /* Hide default caret for a cleaner look */
}

.customer-header-dropdown .dropdown-menu {
    position: absolute !important; /* Force absolute positioning */
    top: 100% !important;
    right: 0 !important;
    left: auto !important;
    transform: none !important; /* Disable Popper.js transforms if they conflict */
    min-width: 220px;
    padding: 8px 0;
    border-radius: 12px !important;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1) !important;
    border: 1px solid rgba(0, 0, 0, 0.05) !important;
    margin-top: 8px !important;
    z-index: 2000;
}

.customer-header-dropdown .dropdown-item {
    padding: 10px 20px;
    font-size: 14px;
    font-weight: 500;
    color: #495057;
    transition: all 0.2s ease;
}

.customer-header-dropdown .dropdown-item:hover {
    background-color: #f8f9fa;
    color: #0056b3;
}

.customer-header-dropdown .dropdown-item i {
    width: 20px;
    text-align: center;
}

.customer-header-dropdown .dropdown-divider {
    margin: 8px 0;
    opacity: 0.1;
}

/* RTL Support for Dropdown */
[dir="rtl"] .customer-header-dropdown .dropdown-menu {
    right: auto !important;
    left: 0 !important;
    text-align: right;
}

[dir="rtl"] .customer-header-dropdown .dropdown-item i {
    margin-right: 0 !important;
    margin-left: 0.5rem !important;
}

/* Custom Theme Danger Button */
.btn-theme-danger {
    background-color: #dc3545 !important;
    color: #fff !important;
    border: 1px solid #dc3545 !important;
    padding: 10px 24px !important;
    border-radius: 50px !important; /* Pill shape */
    font-weight: 500 !important;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 14px;
    height: auto;
    margin: 0;
}

.btn-theme-danger:hover {
    background-color: #bb2d3b !important;
    border-color: #b02a37 !important;
    color: #fff !important;
    transform: translateY(-1px) !important;
    box-shadow: 0 4px 12px rgba(220, 53, 69, 0.3) !important;
}

.swal2-actions .btn-theme-danger {
    margin-right: 10px;
}

[dir="rtl"] .swal2-actions .btn-theme-danger {
    margin-right: 0;
    margin-left: 10px;
}
