header {
    position: sticky;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 99;
    isolation: isolate;
    transition: .4s all;
    -webkit-transition: .4s all;
    -moz-transition: .4s all;
    -ms-transition: .4s all;
    -o-transition: .4s all
}

header nav {
    padding-block: 0;
    justify-content: space-between;
    position: relative;
    align-items: center;
    transition: .4s all;
    -webkit-transition: .4s all;
    -moz-transition: .4s all;
    -ms-transition: .4s all;
    -o-transition: .4s all
}

.menu-link {
    display: flex;
    padding-block: 0;
    column-gap: .69em;
    align-items: center;
    font-size: var(--text-16);
    color: #fff;
    position: relative
}

.has-submenu>a {
    padding-block: 2.1em
}

.has-submenu .menu-link::after {
    content: '';
    display: none;
    width: .73em;
    height: .45em;
    background: url(../images/down-arrow.svg) no-repeat center;
    background-size: contain;
    filter: brightness(0) invert(1);
    -webkit-filter: brightness(0) invert(1);
    transition: .4s all;
    -webkit-transition: .4s all;
    -moz-transition: .4s all;
    -ms-transition: .4s all;
    -o-transition: .4s all
}

.hamburger {
    width: 1.5em;
    height: 1.3em;
    position: relative
}

.hamburger span {
    position: absolute;
    display: block;
    right: 0;
    width: 100%;
    height: .1em;
    background-color: #fff;
    transition: .4s all;
    -webkit-transition: .4s all;
    -moz-transition: .4s all;
    -ms-transition: .4s all;
    -o-transition: .4s all
}

.hamburger span:first-child {
    top: 0%
}

.hamburger span:nth-child(2) {
    width: 70%;
    top: 50%
}

.hamburger span:last-child {
    bottom: 0%
}

.hamburger.active {
    rotate: 45deg
}

.hamburger.active span {
    top: 50%;
    translate: 0 -30%
}

.hamburger.active span:nth-child(2) {
    scale: 0 1
}

.hamburger.active span:nth-child(3) {
    rotate: 90deg
}

header.header-sticky {
    background: #fff
}

header.header-sticky nav {
    padding-block: 0
}

header.header-sticky nav .has-submenu>a {
    padding-block: 1.5em
}

header.header-sticky .menu-link {
    color: var(--color-black)
}

header .menu-link {
    border-bottom: 0 solid transparent
}

header.header-sticky .menu-link::after {
    filter: brightness(0);
    -webkit-filter: brightness(0)
}

header.header-sticky .hamburger span {
    background: var(--color-black)
}

.has-submenu>a {
    position: relative
}

.megamenu {
    position: absolute;
    left: 0;
    top: 100%;
    width: 100%;
    max-height: calc(90vh - 100px);
    padding: 0 0 0;
    padding-inline: 0;
    display: none
}

header.header-sticky .megamenu {
    top: 100%;
    z-index: 999;
    padding: 0;
}

body.show-overlay::before {
    content: '';
    position: fixed;
    inset: 0;
    background: #000b;
    z-index: 5
}

.product-megamenu .container {
    padding-inline: 2em
}

.product-megamenu .megamenu-inner {
    background: transparent linear-gradient(294deg, #fff 0%, #e3e9e9 100%) 0% 0% no-repeat padding-box;
    border-radius: 1.9em;
    padding: 1em 1em 1em 5em;
    display: flex;
    -webkit-border-radius: 1.6em;
    -moz-border-radius: 1.6em;
    -ms-border-radius: 1.6em;
    -o-border-radius: 1.6em;
    position: relative;
    overflow: hidden
}



.product-megamenu .megamenu-left {
    max-width: 30%;
    border-right: 1px solid #e6e6e6;
    display: flex;
    flex-direction: column;
    padding-top: 2.5em;
    padding-right: 5.5em
}

.product-megamenu .megamenu-left p {
    font-size: var(--text-28);
    font-weight: 300;
    line-height: 1.1;
    color: var(--color-dark);
    padding-right: 8rem;
    margin-bottom: 1.1em
}

.product-megamenu .megamenu-left ul {
    display: flex;
    flex-direction: column;
    position: relative;
    z-index: 99
}

.product-megamenu .megamenu-left .btn {
    width: 100%;
    text-align: left;
    padding: 0;
    font-size: var(--text-16);
    font-weight: 400;
    border: none;
    margin-bottom: .2em
}

.product-megamenu .megamenu-left .btn.active,
.product-megamenu .megamenu-left .btn:hover {
    background: var(--color-accent, #c96b3c);;
    border: none;
    font-weight: 600
}

.product-megamenu .megamenu-left a {
    color: var(--color-dark);
    display: block;
    padding: .5em 1.4em
}

.product-megamenu .megamenu-left a span {
    display: block
}

.product-megamenu .megamenu-left a:hover,
.product-megamenu .megamenu-left .btn.active a,
.product-megamenu .megamenu-left .btn:hover a {
    color: #fff
}

.product-megamenu .megamenu-right {
    flex-grow: 1;
    height: 60vh;
    max-height: 800px;
    overflow-y: auto
}

.product-megamenu .megamenu-right::-webkit-scrollbar {
    width: 5px;
    height: 5px;
    background: var(--color-secondary);
    border-radius: 5px;
    -webkit-border-radius: 5px;
    -moz-border-radius: 5px;
    -ms-border-radius: 5px;
    -o-border-radius: 5px
}

.product-megamenu .megamenu-right::-webkit-scrollbar-thumb {
    background: var(--color-accent);
    border-radius: 5px;
    -webkit-border-radius: 5px;
    -moz-border-radius: 5px;
    -ms-border-radius: 5px;
    -o-border-radius: 5px
}

.product-megamenu ul.d-grid {
    grid-template-columns: repeat(2, 1fr)
}

.product-megamenu ul.d-grid a {
    display: flex;
    flex-direction: column;
    row-gap: 0;
    font-size: var(--text-16);
    font-weight: 700;
    color: var(--color-accent);
    align-items: center;
    padding-block: 2em
}

.product-megamenu ul.d-grid li:not(:nth-child(2n)) {
    border-right: .1em solid #e6e6e6
}

.product-megamenu ul.d-grid li:not(:nth-child(-n + 2)) {
    border-top: .1em solid #e6e6e6
}

.megamenu-right .right-menu {
    display: none
}

.megamenu-right .right-menu.show {
    display: block
}

.megamenu-right .right-menu img {
    max-width: 15em;
    max-height: 8em;
    object-fit: contain
}

@media screen and (max-width:2400px) {
    .product-megamenu .megamenu-right {
        height: 66vh
    }
}

@media screen and (max-width:2200px) {
    .product-megamenu .megamenu-right {
        height: 870px
    }
}

@media (max-width:2000px) {
    .product-megamenu .megamenu-right {
        height: 570px
    }
}

@media (max-width:1800px) {
    .product-megamenu .megamenu-inner {
        padding: 2em 2em 2em 6em
    }

    .product-megamenu .megamenu-left p {
        padding-right: 60px
    }

    .product-megamenu .megamenu-left {
        padding-right: 3.5em
    }

    .product-megamenu .megamenu-right {
        height: 500px
    }
}

@media (max-width:1650px) {
    .product-megamenu .megamenu-right {
        height: 490px
    }
}

@media (max-width:1550px) {
    .product-megamenu .megamenu-right {
        height: 450px
    }
}

@media (max-width:1450px) {
    .product-megamenu .megamenu-right {
        height: 440px
    }
}

@media (max-width:1399px) {
    .megamenu {
        padding-top: .1em
    }

    .product-megamenu ul.d-grid a {
        padding-block: 2em;
        row-gap: .73em
    }

    .product-megamenu .megamenu-inner {
        padding: 1em 1em 1em 4em
    }

    .product-megamenu .megamenu-right {
        height: 460px
    }

    .product-megamenu .megamenu-inner .megamenu-left:after {
        height: 120px
    }
}

@media (max-width:1300px) {
    .product-megamenu .megamenu-right {
        height: 410px
    }
}

@media (max-width:991.98px) {

    header nav {
        justify-content: center
    }

    .navbar-toggler {
        display: block !important;
        background: transparent;
        border: none;
        box-shadow: none;
    }

    .hamburger-toggle {
        border-left: none !important;
        padding-left: 0 !important;
        transform: scale(0.85);
        /* Make the hamburger slightly smaller on mobile */
        transform-origin: right center;
    }

    header.header-sticky {
        /* padding: 0 0 4px; */
        /* Reduced padding */
    }

    header nav {
        justify-content: space-between;
        align-items: center
    }

}

@media screen and (min-width:2400px) {
    .product-megamenu .megamenu-right {
        height: 570px
    }
}

.cart-icon-btn {
    background: transparent;
    border: none;
    /* color: var(--color-white, #fff); */
    font-size: 1.20rem;
    padding: 3px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

header.header-sticky .cart-icon-btn {
    color: var(--color-black, #333);
}

.cart-icon-btn:hover {
    color: var(--color-accent, #c96b3c);
}



/* Premium Cart Dropdown Styling */
.cart-dropdown-menu {
    width: 380px;
    padding: 1.25rem !important;
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.12);
    border: 1px solid rgba(0, 0, 0, 0.05);
    margin-top: 15px !important;
    background: #fff;
    z-index: 1050;
    max-height: 90vh;
    overflow-y: hidden;
    flex-direction: column;
}

.cart-dropdown-menu.show {
    display: flex;
}

.cart-dropdown-menu::before {
    content: '';
    position: absolute;
    top: -6px;
    right: 22px;
    width: 12px;
    height: 12px;
    background: #fff;
    transform: rotate(45deg);
    border-left: 1px solid rgba(0, 0, 0, 0.05);
    border-top: 1px solid rgba(0, 0, 0, 0.05);
}

.cart-dropdown-menu>li {
    display: flex;
    flex-direction: column;
    max-height: calc(90vh - 40px);
}

.cart-scroll-list {
    max-height: 250px;
    /* Reduced further to ensure buttons are visible */
    overflow-y: auto;
    overflow-x: hidden;
    margin-bottom: 10px;
    padding-right: 5px;
    flex-shrink: 1;
}

/* Custom Scrollbar for Cart */
.cart-scroll-list::-webkit-scrollbar {
    width: 5px;
}

.cart-scroll-list::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 10px;
}

.cart-scroll-list::-webkit-scrollbar-thumb {
    background: #ccc;
    border-radius: 10px;
}

.cart-scroll-list::-webkit-scrollbar-thumb:hover {
    background: var(--color-accent, #c96b3c);
}

.cart-dropdown-menu .table {
    margin-bottom: 0;
}

.cart-dropdown-menu .table td {
    vertical-align: middle;
    border-bottom: 1px solid #f5f5f5;
    padding: 12px 5px;
}

.cart-dropdown-menu .table tr:last-child td {
    border-bottom: none;
}

.cart-dropdown-menu .img-thumbnail {
    border-radius: 8px;
    border: 1px solid #eee;
    padding: 4px;
    width: 65px;
}

.cart-dropdown-menu .product-name {
    color: #333;
    font-weight: 600;
    font-size: 14px;
    text-decoration: none;
    transition: color 0.3s;
    display: block;
    margin-bottom: 4px;
}

.cart-dropdown-menu .product-name:hover {
    color: var(--color-accent, #c96b3c);
}

.cart-dropdown-menu .btn-danger {
    /* background-color: #ffeaea; */
    color: #dc3545;
    border: none;
    border-radius: 6px;
    padding: 5px 10px;
    transition: all 0.3s;
}

.cart-dropdown-menu .btn-danger:hover {
    background-color: #dc3545;
    color: #fff;
}

.cart-total-box {
    background: #fcfcfc;
    padding: 15px;
    border-radius: 8px;
    margin-top: 10px;
    border: 1px solid #f0f0f0;
}

.cart-total-box .table-sm td {
    border: none;
    padding: 4px 0;
    font-size: 14px;
    color: #555;
}

.cart-total-box .table-sm tr:last-child td {
    font-weight: 700;
    font-size: 16px;
    color: var(--color-accent, #c96b3c);
    padding-top: 8px;
}

.cart-buttons {
    display: flex;
    gap: 12px;
    margin-top: 15px;
}

.cart-buttons a {
    flex: 1;
    text-align: center;
    padding: 12px;
    border-radius: 8px;
    font-weight: 600;
    font-size: 14px;
    text-decoration: none;
    transition: all 0.3s;
}

.cart-buttons .btn-view-cart {
    background: #fff;
    border: 1px solid #ddd;
    color: #333;
}

.cart-buttons .btn-view-cart:hover {
    border-color: var(--color-accent, #c96b3c);
    color: var(--color-accent, #c96b3c);
    background: #fffafa;
}

.cart-buttons .btn-checkout {
    background: var(--color-accent, #c96b3c);
    border: 1px solid var(--color-accent, #c96b3c);
    color: #fff;
}

.cart-buttons .btn-checkout:hover {
    background: #b55e32;
    border-color: #b55e32;
    color: #fff;
}

.empty-cart-msg {
    text-align: center;
    padding: 30px 10px;
    color: #777;
    font-size: 15px;
}

.empty-cart-msg i {
    font-size: 40px;
    color: #ddd;
    margin-bottom: 15px;
    display: block;
}

@media (max-width: 575.98px) {
    .cart-dropdown-menu {
        width: 320px;
        right: -20px !important;
    }

    .cart-dropdown-menu::before {
        right: 35px;
    }
}

.search-dropdown {
    position: relative;
    display: inline-block;
}

.search-icon-btn {
    background: transparent;
    border: none;
    color: var(--color-white, #fff);
    font-size: 1.20rem;
    /* padding: 12px; */
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

header.header-sticky .search-icon-btn {
    color: var(--color-black, #333);
}

.search-icon-btn:hover {
    color: var(--color-accent, #c96b3c);
}



.search-dropdown-menu {
    padding: 15px;
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
    border: 1px solid rgba(0, 0, 0, 0.05);
    min-width: 320px;
    margin-top: 15px !important;
    background: #fff;
    z-index: 1050;
}

/* Arrow indicator */
.search-dropdown-menu::before {
    content: '';
    position: absolute;
    top: -6px;
    right: 20px;
    width: 12px;
    height: 12px;
    background: #fff;
    transform: rotate(45deg);
    border-left: 1px solid rgba(0, 0, 0, 0.05);
    border-top: 1px solid rgba(0, 0, 0, 0.05);
}

.search-dropdown-menu .input-group {
    background: #f4f4f4;
    border-radius: 50px;
    border: 1px solid #e0e0e0;
    overflow: hidden;
    display: flex;
    flex-wrap: nowrap;
    transition: all 0.3s;
}

.search-dropdown-menu .input-group:focus-within {
    border-color: var(--color-accent, #c96b3c);
    background: #fff;
    box-shadow: 0 0 0 3px rgba(201, 107, 60, 0.1);
}

.search-dropdown-menu input {
    border: none !important;
    background: transparent !important;
    box-shadow: none !important;
    padding-left: 20px;
    height: 45px;
    font-size: 14px;
    flex-grow: 1;
    color: #333;
}

.search-dropdown-menu input:focus {
    outline: none;
}

.search-dropdown-menu input::placeholder {
    color: #999;
}

.search-dropdown-menu .search-submit {
    background: var(--color-accent, #c96b3c);
    color: #fff;
    border: none;
    padding: 0 20px;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.search-dropdown-menu .search-submit:hover {
    background: #a5552c;
}

@media (max-width: 575.98px) {
    .search-dropdown-menu {
        min-width: 280px;
    }
}

#cart {
    margin-bottom: 0px !important;
}

:root {
    --primary: #8B1A1A;
    --primary-dark: #6B1010;
    --accent: #f69d1c;
    --accent-hover: #e08c0e;
    --accent-2: #c9024c;
    --accent-2-hover: #a8023e;
    --bg: #f5f5f5;
    --bg-cream: #FFF8F0;
    --bg-warm: #FDF3E7;
    --bg-card: #ffffff;
    --text: #000000;
    --text-muted: #666666;
    --text-light: #999999;
    --border: #dddddd;
    --border-light: #e8e8e8;
    --shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
    --shadow-hover: 0 8px 30px rgba(0, 0, 0, 0.12);
    --radius: 8px;
    --radius-lg: 12px;
    --font: 'Jost', sans-serif;
    --transition: 0.3s ease;
}

.header__actions .dropdown-toggle::after,
.nav-icons .dropdown-toggle::after,
#form-language .dropdown-toggle::after {
    display: none !important;
}

.header {
    background: transparent;
    border-bottom: 1px solid transparent;
    position: sticky;
    top: 0;
    z-index: 1000;
    transition: background-color 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}

.header.scrolled {
    background: #fff;
    /* border-bottom: 1px solid var(--border); */
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
}

/* Transparent Header Overrides (White items) */
.header:not(.scrolled) .header__logo img {
    /* filter: brightness(0) invert(1); */
}

.header:not(.scrolled) .header__logo-text {
    color: #fff;
}

.header:not(.scrolled) .header__logo-icon {
    background: #fff;
    color: var(--primary);
}

.header:not(.scrolled) .header__nav>ul>li>a {
    color: #fff;
}

.header:not(.scrolled) .header__menu-btn span {
    background: #fff;
}

.header .header-cart-wrap button i,
.header .header-cart-wrap button.cart-icon-btn,
.header .header-search-wrap button i,
.header .header-search-wrap button,
.header .header-action-icon,
.header .header-action-icon i {
    color: #fff !important;
}

.header__actions-row {
    display: flex;
    align-items: center;
    gap: 14px;
}

.header__actions-row>* {
    display: flex;
    align-items: center;
    justify-content: center;
}

.header__inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 20px;
    /* max-width: 1420px; */
    margin: 0 auto;
}

.header__logo {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
}

.header__logo img {
    max-height: 65px;
    width: auto;
    transition: filter 0.3s ease, max-height 0.3s ease;
}

.header__logo-icon {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: var(--primary);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    font-size: 18px;
    flex-shrink: 0;
}

.header__logo-text {
    font-size: 2rem;
    font-weight: 700;
    color: var(--primary);
    line-height: 1.2;
    margin: 0;
}

.header__logo-text small {
    display: block;
    font-size: 1rem;
    font-weight: 500;
    color: var(--text-muted);
    letter-spacing: 1px;
    text-transform: uppercase;
}

/* Navigation */
.header__nav {
    position: static !important;
    margin-left: auto;
    margin-right: 30px;
}

/* JS-controlled hover state */
.has-submenu.hover-open>.megamenu {
    display: block !important;
}

/* Remove CSS hover for has-megamenu — JS handles it */
.has-megamenu:hover>.megamenu {
    display: none;
}

.has-megamenu.hover-open>.megamenu {
    display: block !important;
}

.product-megamenu .megamenu-inner {
    padding: 1em 2em !important;
}

.product-megamenu .megamenu-left,
.product-megamenu .megamenu-right {
    /* height: auto !important; */
    /* max-height: 45vh !important; */
    overflow-y: auto !important;
    padding-top: 1em !important;
}

.product-megamenu .megamenu-left::-webkit-scrollbar,
.product-megamenu .megamenu-right::-webkit-scrollbar {
    width: 4px;
}

.product-megamenu .megamenu-left::-webkit-scrollbar-thumb,
.product-megamenu .megamenu-right::-webkit-scrollbar-thumb {
    background: #ccc;
    border-radius: 4px;
}

.header__nav ul {
    /* display: flex; */
    /* align-items: center;
    gap: 24px; */
    margin-bottom: 0;
    padding-left: 0;
}

.header__nav ul li {
    list-style: none;
}

.header__nav a {
    /* font-size: 1.4rem; */
    font-weight: 500;
    color: var(--text);
    padding: 4px 5px;
    position: relative;
    transition: color var(--transition);
    text-decoration: none;
}

.header__nav a:hover,
.header__nav a.active {
    color: var(--accent-2);
}

.header__nav a.active::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    right: 0;
    height: 2px;
    background: var(--accent-2);
}

.has-submenu {
    position: relative;
}

.has-submenu.touch-open .megamenu {
    display: block !important;
}

.has-megamenu {
    position: static !important;
}

/* Header Actions */
.header__actions {
    display: flex;
    align-items: center;
    gap: 10px;
}

/* Responsive Mobile Nav */
@media (max-width: 991px) {

    /* Force header to be white on mobile and sticky */
    .header {
        position: sticky !important;
        top: 0;
        width: 100%;
        z-index: 1000;
        /* background: #fff !important;
                border-bottom: 1px solid var(--border) !important; */
    }

    /* Revert logo/text/hamburger overrides for mobile */
    .header:not(.scrolled) .header__logo img {
        /* filter: none !important; */
        transition: all 0.3s ease;
        /* padding: 8px; */
        max-height: 100%;
    }

    .header:not(.scrolled) .header__logo-text {
        color: var(--primary) !important;
    }

    .header:not(.scrolled) .header__logo-icon {
        background: var(--primary) !important;
        color: #fff !important;
    }

    /* Hamburger spans — white on transparent header */
    .header:not(.scrolled) .hamburger span {
        background: #fff !important;
    }

    .header .header-cart-wrap button i,
    .header .header-cart-wrap button.cart-icon-btn,
    .header .header-search-wrap button i,
    .header .header-search-wrap button,
    .header .header-account-wrap .header-action-icon,
    .header .header-account-wrap .header-action-icon i {
        color: #fff !important;
    }

    /* Removed dark icons override for mobile scrolled header */

    .header.scrolled .hamburger span {
        background: #fff !important;
    }

    /* Hide wishlist, language, separator on mobile */
    .mobile-hide-action {
        display: none !important;
    }

    .header__nav.d-none {
        display: none !important;
    }

    .header__logo-text {
        font-size: 1.6rem;
    }

    .header__logo img {
        max-height: 85px !important;
        width: auto !important;
        object-fit: contain;
    }

    /* Shrink logo when header is scrolled (white background) */
    .header.scrolled .header__logo img {
        max-height: 54px !important;
    }

    .header__logo {
        gap: 6px;
    }
}

#form-language .dropdown-menu {
    background: #ffffff;
    border-radius: 8px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, .15);
    border: 1px solid rgba(0, 0, 0, 0.05);
    padding: 8px 0;
    margin-top: 8px;
    min-width: 140px;
    z-index: 99999;
}

#form-language .dropdown-item {
    color: #333333 !important;
    font-size: 14px;
    padding: 10px 20px;
    display: flex;
    align-items: center;
    gap: 8px;
    opacity: 1;
    transition: all 0.2s;
}

#form-language .dropdown-item:hover {
    background: #f9f6fd;
    color: #5e2e7a !important;
    padding-left: 24px;
}

#form-language .dropdown-toggle {
    display: flex;
    align-items: center;
    gap: 6px;
    color: #ffffff;
    text-decoration: none;
    font-size: 13px;
    font-weight: 500;
    opacity: 0.9;
    transition: all 0.2s;
}

#form-language .dropdown-toggle:hover {
    opacity: 1;
    color: #ffeb3b;
}
