/* --- Scrollbars --- */

.css-header-search-results::-webkit-scrollbar,
.css-minicart-list::-webkit-scrollbar {
    width: 6px;
}

.css-header-search-results::-webkit-scrollbar-track,
.css-minicart-list::-webkit-scrollbar-track {
    background: transparent;
}

.css-header-search-results::-webkit-scrollbar-thumb,
.css-minicart-list::-webkit-scrollbar-thumb {
    background: #dcdfe4;
    border-radius: 3px;
}

.css-header-search-results::-webkit-scrollbar-thumb:hover,
.css-minicart-list::-webkit-scrollbar-thumb:hover {
    background: #bcc0c6;
}

/* --- Top bar --- */

.css-topbar {
    background: #f3f4f6;
    color: #6b7280;
    border-bottom: 1px solid #e8eaed;
}

.css-topbar-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    min-height: 30px;
    padding: 5px 0;
}

.css-topbar-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    flex-wrap: wrap;
    gap: 12px;
    margin-left: auto;
}

.css-topbar-shipping,
.css-topbar-phone,
.css-topbar-account {
    display: flex;
    align-items: center;
    gap: 7px;
    font-size: 11.5px;
    font-weight: 500;
    letter-spacing: 0.1px;
    line-height: 1.3;
    color: #6b7280;
    text-decoration: none;
}

.css-topbar-shipping {
    justify-content: flex-start;
    text-align: left;
}

.css-topbar-account {
    flex-shrink: 0;
    color: #374151;
}

.css-topbar-account-text {
    font-weight: 600;
    color: #1f2937;
}

.css-topbar-account-sep {
    color: #9ca3af;
}

.css-topbar-logout {
    font-weight: 600;
    color: #6b7280;
    text-decoration: none;
    transition: color 0.18s ease;
}

.css-topbar-logout:hover {
    color: #ee1a19;
    text-decoration: none;
}

.css-topbar-phone {
    flex-shrink: 0;
    font-weight: 600;
    color: #1f2937;
    transition: color 0.18s ease;
}

.css-topbar-phone:hover {
    color: #ee1a19;
    text-decoration: none;
}

.css-topbar-shipping-icon,
.css-topbar-phone-icon {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    color: #ee1a19;
}

/* --- Header bar --- */

.section2 {
    background: #ffffff;
    border-bottom: 1px solid #f5c4c0;
    box-shadow: none;
    padding: 10px 0;
}

.section2 .container {
    border-bottom: 0px !important;
    padding: 0 20px;
}

.header-logo {
    max-height: 46px;
    width: auto;
    display: block;
    transition: opacity 0.2s ease;
}

a:hover .header-logo {
    opacity: 0.85;
}

.css-header-hamburger {
    font-size: 22px;
    color: #ee1a19;
}

.css-header-hamburger:hover {
    color: #c51514;
}

/* --- Categories button --- */

.btn-categories {
    position: relative;
    background: #ee1a19 !important;
    border: none;
    border-radius: 10px;
    padding: 9px 16px;
    font-weight: 600;
    font-size: 13px;
    line-height: 1;
    color: #ffffff !important;
    transition: background-color 0.18s ease, border-radius 0.18s ease;
    display: flex;
    align-items: center;
    gap: 9px;
    cursor: pointer;
    box-shadow: none;
    letter-spacing: 0.1px;
}

.btn-categories:hover {
    background: #d51413 !important;
    color: #ffffff !important;
}

.css-mega.css-open .btn-categories,
.css-mega.css-open .btn-categories:hover {
    display: none !important;
}

.btn-categories i,
.btn-categories span {
    color: #ffffff;
}

.btn-categories > i:first-child {
    flex-shrink: 0;
}

.btn-categories .css-mega-caret {
    font-size: 9px;
    opacity: 0.75;
}

/* --- Search --- */

.header-search {
    position: relative;
    z-index: 1000;
    width: 100%;
    max-width: 520px;
}

.header-search form {
    position: relative;
}

.header-search input {
    width: 100%;
    padding: 10px 46px 10px 16px;
    border: 1px solid #e4e7ec;
    border-radius: 10px;
    font-size: 13.5px;
    color: #1a1a1a;
    background: #ffffff;
    box-shadow: none;
    transition: border-color 0.18s ease, box-shadow 0.18s ease;
    outline: none;
}

.header-search input:focus {
    border-color: #ee1a19;
    background: #ffffff;
    box-shadow: 0 0 0 3px rgba(238, 26, 25, 0.08);
}

.header-search input::placeholder {
    color: #9aa1a9;
    font-weight: 400;
    font-size: 13.5px;
}

#css-searchBoxEffect,
#css-searchBoxEffect.open {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 990;
    width: auto;
    height: auto;
    background: rgba(18, 14, 16, 0.32);
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    -webkit-transform: none;
    transform: none;
    transition: opacity 0.28s ease;
}

#css-searchBoxEffect {
    opacity: 0;
    pointer-events: none;
}

#css-searchBoxEffect.open {
    opacity: 1;
    pointer-events: auto;
}

html.css-search-lock {
    overflow: hidden;
}

#header {
    position: relative;
    z-index: 1000;
}

.css-header-search-btn {
    position: absolute;
    right: 5px;
    top: 50%;
    z-index: 2;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    background: #ee1a19;
    border: none;
    border-radius: 8px;
    color: #ffffff;
    font-size: 13px;
    cursor: pointer;
    box-shadow: none;
    transform: translateY(-50%);
    transition: background-color 0.18s ease;
}

.css-header-search-btn:hover {
    background: #d51413;
}

.css-header-search-results {
    display: none;
    top: 100%;
    left: 0;
    right: 0;
    z-index: 1000000;
    max-height: 480px;
    margin-top: 8px;
    padding: 8px;
    background: #ffffff;
    border: 1px solid #e4e7ec;
    border-radius: 12px;
    box-shadow: 0 12px 28px rgba(25, 31, 38, 0.10);
    overflow: auto;
}

.css-header-search-panel {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.css-header-search-list {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.css-header-search-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 8px 10px;
    background: #fcfcfd;
    border: 1px solid #e9ecf0;
    border-radius: 10px;
    color: #1b1f24;
    text-decoration: none;
    transition: background-color 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
}

.css-header-search-item:hover {
    background: #ffffff;
    border-color: #ee1a19;
    box-shadow: 0 8px 18px rgba(41, 47, 55, 0.08);
    text-decoration: none;
}

.css-header-search-thumb {
    width: 64px;
    height: 64px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #ffffff;
    border: 1px solid #eef1f4;
    border-radius: 8px;
    overflow: hidden;
}

.css-header-search-img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
}

.css-header-search-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
    flex: 1 1 auto;
    min-width: 0;
}

.css-header-search-name {
    color: #1b1f24;
    font-size: 13px;
    font-weight: 600;
    line-height: 1.35;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.css-header-search-item:hover .css-header-search-name {
    color: #ee1a19;
}

.css-header-search-meta {
    color: #949ba3;
    font-size: 11px;
    line-height: 1.3;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.css-header-search-foot {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    flex-wrap: wrap;
}

.css-header-search-stock {
    font-size: 10px;
    font-weight: 600;
    line-height: 1;
    padding: 4px 8px;
    border-radius: 999px;
    white-space: nowrap;
}

.css-header-search-stock-in {
    color: #198754;
    background: #eaf7ef;
}

.css-header-search-stock-out {
    color: #9aa1a9;
    background: #f3f4f6;
}

.css-header-search-price-wrap {
    display: flex;
    align-items: baseline;
    gap: 8px;
    flex-wrap: wrap;
    margin-left: auto;
}

.css-header-search-price-old {
    color: #9ca3af;
    font-size: 12px;
    text-decoration: line-through;
}

.css-header-search-price {
    color: #111827;
    font-size: 15px;
    font-weight: 700;
    line-height: 1.2;
}

.css-header-search-price-dual {
    color: #9aa1a9;
    font-size: 11px;
    font-weight: 500;
}

.css-header-search-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 8px 10px 2px;
    border-top: 1px solid #eef1f4;
}

.css-header-search-more-note {
    color: #949ba3;
    font-size: 11px;
}

.css-header-search-all {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin-left: auto;
    color: #ee1a19;
    font-size: 12px;
    font-weight: 600;
    text-decoration: none;
    white-space: nowrap;
}

.css-header-search-all:hover {
    color: #c91413;
    text-decoration: none;
}

.css-header-search-all i {
    font-size: 10px;
}

.css-header-search-empty {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 12px;
    color: #6f7680;
}

.css-header-search-empty-icon {
    width: 40px;
    height: 40px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #fff2f1;
    border-radius: 50%;
    color: #ee1a19;
    font-size: 15px;
}

.css-header-search-empty-text {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.css-header-search-empty-text strong {
    color: #1b1f24;
    font-size: 13px;
    font-weight: 600;
}

.css-header-search-empty-text span {
    font-size: 12px;
    line-height: 1.35;
}

.css-header-search-loading {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 22px 12px;
    color: #6f7680;
    font-size: 13px;
}

.css-header-search-loading i {
    color: #ee1a19;
}

.css-minicart-icon-wrap {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 22px;
    min-height: 22px;
}

.css-minicart-icon {
    display: block;
    font-size: 22px;
    line-height: 1;
    color: #2b3037;
}

.header-icons .icon-item:hover .css-minicart-icon {
    color: #ee1a19;
}

.header-icons .icon-item .icon-wrapper .css-minicart-qty {
    top: -7px;
    right: -11px;
    left: auto;
    bottom: auto;
    z-index: 2;
    transform: none;
    transform-origin: 100% 0%;
}

.header-icons .icon-item .icon-wrapper .css-minicart-qty.cart-effect {
    transform: none;
    -webkit-animation: cart_pulse 2s infinite;
    animation: cart_pulse 2s infinite;
}

.header-icons .css-minicart-dropdown {
    z-index: 1100;
    right: 0;
    left: auto;
    min-width: 380px;
    margin-top: 8px;
    padding: 12px 14px 10px;
    background: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    box-shadow: 0 12px 28px rgba(25, 31, 38, 0.12);
    font-size: 13px;
    color: #1f2937;
}

.header-icons .css-header-cenova-dropdown {
    z-index: 1100;
    right: 0;
    left: auto;
    width: 480px;
    max-width: calc(100vw - 24px);
    margin-top: 8px;
    padding: 10px;
    background: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    box-shadow: 0 12px 28px rgba(25, 31, 38, 0.12);
}

.css-header-cenova-search {
    margin-bottom: 8px;
}

.css-header-cenova-search-input {
    height: 34px;
    padding: 6px 10px;
    font-size: 13px;
    border: 1px solid #e5e7eb;
    border-radius: 6px;
    box-shadow: none;
}

.css-header-cenova-search-input:focus {
    border-color: #d1d5db;
    box-shadow: none;
}

.css-header-cenova-list {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2px 6px;
    max-height: 480px;
    overflow-y: auto;
}

.css-header-cenova-link {
    display: flex;
    align-items: flex-start;
    gap: 6px;
    padding: 7px 10px;
    color: #374151;
    font-size: 13px;
    font-weight: 500;
    text-decoration: none;
    border-radius: 6px;
    line-height: 1.3;
    word-break: break-word;
}

.css-header-cenova-num {
    flex-shrink: 0;
    min-width: 1.5em;
    color: #9ca3af;
    font-weight: 600;
}

.css-header-cenova-name {
    flex: 1;
}

.css-header-cenova-link:hover {
    background: #f7f8fa;
    color: #ee1a19;
    text-decoration: none;
}

.css-header-cenova-link:hover .css-header-cenova-num {
    color: #ee1a19;
}

.css-minicart-dropdown .css-minicart-go {
    display: inline-block;
    padding: 8px 28px;
    background: #ee1a19;
    border-radius: 4px;
    color: #ffffff;
    font-size: 13px;
    font-weight: 600;
    line-height: 1.2;
    text-align: center;
    text-decoration: none;
}

.css-minicart-dropdown .css-minicart-go:hover {
    background: #d51413;
    color: #ffffff;
    text-decoration: none;
}

.css-minicart-head,
.css-minicart-item {
    gap: 8px;
    border-bottom: 1px solid #ececec;
}

.css-minicart-head {
    margin-top: 10px;
    padding: 6px 0 6px 74px;
    color: #9aa1a9;
    font-size: 12px;
}

.css-minicart-head-product,
.css-minicart-name {
    flex: 1;
    min-width: 0;
}

.css-minicart-col-qty,
.css-minicart-col-price {
    flex-shrink: 0;
    font-size: 12px;
    white-space: nowrap;
}

.css-minicart-col-qty {
    width: 40px;
    text-align: center;
}

.css-minicart-col-price {
    width: 118px;
}

.css-minicart-item .css-minicart-col-qty,
.css-minicart-item .css-minicart-col-price {
    color: #374151;
}

.css-minicart-list {
    overflow-x: hidden;
    overflow-y: auto;
    max-height: 280px;
}

.css-minicart-item {
    padding: 8px 0;
}

.css-minicart-thumb {
    width: 42px;
    height: 42px;
    flex-shrink: 0;
    object-fit: contain;
    background: #f8f9fb;
}

.css-minicart-name {
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    overflow: hidden;
    font-size: 12px;
    font-weight: 700;
    line-height: 1.3;
    color: #1f2937;
    overflow-wrap: break-word;
}

.css-minicart-dropdown .css-minicart-remove {
    flex-shrink: 0;
    width: 16px;
    color: #9aa1a9;
    font-size: 12px;
    line-height: 1;
    text-align: center;
    text-decoration: none;
}

.css-minicart-dropdown .css-minicart-remove:hover {
    color: #ee1a19;
    text-decoration: none;
}

.css-minicart-free {
    margin-top: 8px;
    padding: 6px 8px;
    background: #ee1a19;
    color: #ffffff;
    font-size: 11px;
    text-align: center;
}

.css-minicart-total {
    gap: 8px;
    margin-top: 8px;
    padding-top: 8px;
    font-size: 13px;
    color: #1f2937;
}

.css-minicart-empty {
    padding: 12px 8px;
    color: #6b7280;
    text-align: center;
}

.css-search-thumb {
    max-width: 50px;
    max-height: 50px;
}

.css-search-details {
    overflow: hidden;
}

/* --- Header icons --- */

.header-icons {
    display: flex;
    align-items: center;
    gap: 4px;
}

.header-icons .icon-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    color: #555;
    text-decoration: none;
    font-size: 12px;
    font-weight: 500;
    transition: background-color 0.18s ease, color 0.18s ease;
    position: relative;
    padding: 7px 11px;
    border-radius: 10px;
    cursor: pointer;
}

.header-icons .icon-item:hover {
    background: #f7f8fa;
}

.header-icons .icon-item:hover,
.header-icons .icon-item:hover i,
.header-icons .icon-item:hover span:not(.badge) {
    color: #ee1a19;
}

.header-icons .icon-item i {
    font-size: 19px;
    color: #2b3037;
    transition: color 0.18s ease;
}

.header-icons .icon-item .icon-wrapper {
    position: relative;
    display: inline-block;
}

.header-icons .icon-item span:not(.badge) {
    font-size: 11px;
    font-weight: 500;
    color: #6b7280;
    transition: color 0.18s ease;
}

/* --- Badges --- */

.badge-wishlist,
.header-icons .icon-item .badge {
    background: #ee1a19 !important;
    color: #fff;
    font-size: 9.5px;
    font-weight: 700;
    padding: 0 4px;
    border: 2px solid #ffffff;
    border-radius: 999px;
    position: absolute;
    top: -6px;
    right: -9px;
    min-width: 17px;
    height: 17px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    line-height: 1;
    box-shadow: none;
}

.badge-wishlist.pop {
    animation: badgePop 0.4s ease;
}

@keyframes badgePop {
    0% {
        transform: scale(1);
    }

    30% {
        transform: scale(1.4);
    }

    70% {
        transform: scale(0.9);
    }

    100% {
        transform: scale(1);
    }
}

/* --- Wishlist button --- */

.wishlist-btn {
    position: absolute;
    top: 12px;
    right: 12px;
    z-index: 10;
    width: 36px;
    height: 36px;
    border: none;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.95);
    color: #ddd;
    font-size: 17px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
}

.wishlist-btn:hover {
    transform: scale(1.12);
    background: #ffffff;
    box-shadow: 0 4px 18px rgba(0, 0, 0, 0.15);
}

.wishlist-btn.active {
    color: #ee1a19;
    background: rgba(238, 26, 25, 0.10);
}

.wishlist-btn.active:hover {
    background: rgba(238, 26, 25, 0.18);
}

.wishlist-btn i {
    transition: all 0.3s ease;
    font-size: 17px;
}

.wishlist-btn.active i {
    animation: heartBeat 0.4s ease;
}

.wishlist-btn.loading {
    opacity: 0.5;
    pointer-events: none;
}

@keyframes heartBeat {
    0% {
        transform: scale(1);
    }

    30% {
        transform: scale(1.3);
    }

    60% {
        transform: scale(0.9);
    }

    100% {
        transform: scale(1);
    }
}

/* --- Wishlist toast --- */

.css-wishlist-toast {
    position: fixed;
    bottom: 30px;
    left: 50%;
    z-index: 99999;
    max-width: 90%;
    padding: 12px 28px;
    background: #28a745;
    border-radius: 10px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    color: #ffffff;
    font-family: 'Montserrat', Arial, sans-serif;
    font-size: 15px;
    font-weight: 600;
    opacity: 0;
    pointer-events: none;
    transform: translateX(-50%) translateY(20px);
    transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.css-wishlist-toast.css-visible {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

/* --- Shared gradient elements --- */

.css-btn-add-cart.btn-add-cart,
.btn.btn-sm.rounded-3,
#btn-add-cart-single,
#form-chekout h5.orange-bg {
    background: linear-gradient(90deg, #D8061A 0%, #F24A1A 50%, #FB7413 100%) !important;
    padding-left: 20px;
    margin-left: 20px;
}
