.cv-header {
    background: var(--cv-header-bg, #fdf0f6);
    position: relative;
    z-index: 999;
}

.cv-container {
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
}

.cv-header-main {
    background: linear-gradient(180deg, var(--cv-header-bg, #fcecf4) 0%, var(--white, #fff) 100%);
    padding: 16px 0 0px;
}

.cv-header-row {
    display: grid;
    grid-template-columns: 190px 390px 1fr;
    align-items: center;
    gap: 34px;
}

.cv-logo a {
    display: inline-block;
    text-decoration: none;
    color: var(--text);
    font-size: 20px;
    font-weight: 800;
}

.cv-logo img {
    width: 105px;
    max-height: 85px;
    object-fit: contain;
    display: block;
    margin: 0 auto;
}

.cv-search {
    padding-top: 10px;
    min-width: 0;
}

.cv-search form {
    width: 100%;
    height: 42px;
    background: var(--white);
    border-radius: 999px;
    display: flex;
    align-items: center;
    box-shadow: var(--cv-search-shadow, 0 12px 12px rgba(17, 24, 39, 0.14));
    overflow: hidden;
}

.cv-search-icon {
    width: 44px;
    min-width: 44px;
    height: 42px;
    border: 0;
    background: transparent;
    color: var(--primary);
    font-size: 17px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.cv-search input {
    width: 100%;
    min-width: 0;
    height: 42px;
    border: 0;
    outline: 0;
    background: transparent;
    font-size: 14px;
    color: var(--text);
    padding-right: 18px;
}

.cv-search input::placeholder {
    color: var(--text-light);
}

.cv-nav {
    padding-top: 21px;
}

.cv-menu {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 23px;
}

.cv-menu li {
    position: relative;
}

.cv-menu a {
    display: flex;
    align-items: center;
    color: var(--text);
    text-decoration: none;
    font-size: 15.5px;
    font-weight: 800;
    line-height: 1;
    white-space: nowrap;
}

.cv-menu a:hover {
    color: var(--primary);
}

.cv-menu > li.menu-item-has-children > a::after {
    content: "\f078";
    font-family: "Font Awesome 6 Free";
    font-weight: 900;
    font-size: 10px;
    margin-left: 7px;
}

.cv-menu-toggle {
    display: none;
}


/* ================================
   Header Store Search Results
================================ */

.cv-header,
.cv-header-inner,
.cv-header-main,
.cv-container,
.cv-search,
.cv-search form {
    overflow: visible !important;
}

.cv-search {
    position: relative;
    z-index: 99999;
}

.cv-search form {
    position: relative;
}

.cv-store-search-results {
    display: none;
    position: absolute;
    top: calc(100% + 8px);
    left: 0;
    right: 0;
    z-index: 999999;
    background: #fff;
    border-radius: 14px;
    box-shadow: 0 10px 28px rgba(0,0,0,.16);
    overflow: hidden;
}

.cv-store-search-results.is-active {
    display: block !important;
}

.cv-search-result,
.cv-search-empty {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 11px 15px;
    color: #151947;
    background: #fff;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
}

.cv-search-result:hover {
    background: #f6f7fb;
    color: #ff4d86;
}

.cv-search-result-logo {
    width: 36px;
    height: 36px;
    min-width: 36px;
    border: 1px solid #e5e7eb;
    border-radius: 50%;
    padding: 4px;
    background: #fff;
    object-fit: contain;
}

.cv-search-result span {
    line-height: 1.2;
}

.cv-search-empty {
    justify-content: center;
    color: #6b7280;
}
/* ================================
   Header Store Search Results End
================================ */


/* Desktop mega menu */
@media (min-width: 1201px) {
    .cv-menu > li.menu-item-has-children {
        position: relative;
    }

    .cv-menu > li.menu-item-has-children::after {
        content: "";
        position: absolute;
        left: 0;
        top: 100%;
        width: 610px;
        height: 22px;
        background: transparent;
        z-index: 9998;
    }

    .cv-menu > li.menu-item-has-children > .sub-menu {
        position: absolute;
        top: 34px;
        right: 0;
        transform: translateY(8px);
        width: 610px;
        background: linear-gradient(180deg, rgba(252, 236, 244, 0.96) 0%, rgba(255, 255, 255, 0.96) 100%);
        padding: 38px 34px;
        list-style: none;
        margin: 0;
        display: grid;
        grid-template-columns: repeat(3, 1fr);
        gap: 18px 46px;
        box-shadow: 0 22px 55px rgba(17, 24, 39, 0.10);
        opacity: 0;
        visibility: hidden;
        pointer-events: none;
        transition: 0.2s ease;
        z-index: 9999;
    }

    .cv-menu > li.menu-item-has-children:hover > .sub-menu,
    .cv-menu > li.menu-item-has-children:focus-within > .sub-menu {
        opacity: 1;
        visibility: visible;
        pointer-events: auto;
        transform: translateY(0);
    }

    .cv-menu .sub-menu a {
        font-size: 13px;
        font-weight: 800;
    }
}

/* Tablet + Mobile */
@media (max-width: 1200px) {
    .cv-container {
        width: calc(100% - 32px);
    }

    .cv-header-main {
        padding: 9px 0;
    }

    .cv-header-row {
        grid-template-columns: 54px minmax(0, 1fr) 22px;
        align-items: center;
        gap: 8px;
    }

    .cv-logo {
        width: 54px;
        text-align: left;
    }

    .cv-logo img {
        width: 54px;
        max-height: 36px;
        margin: 0;
    }

    .cv-search {
        width: 100%;
        padding-top: 0;
    }

    .cv-search form {
        height: 28px;
        box-shadow: 0 8px 10px rgba(17, 24, 39, 0.14);
    }

    .cv-search-icon {
        width: 28px;
        min-width: 28px;
        height: 28px;
        font-size: 11px;
    }

    .cv-search input {
        height: 28px;
        font-size: 10px;
        padding-right: 8px;
    }

    .cv-menu-toggle {
        display: flex;
        width: 22px;
        height: 22px;
        border: 0;
        background: transparent;
        color: var(--text);
        font-size: 14px;
        padding: 0;
        align-items: center;
        justify-content: center;
        cursor: pointer;
    }

    .cv-nav {
        display: none;
        grid-column: 1 / -1;
        width: calc(100% + 32px);
        margin-left: -16px;
        margin-top: 8px;
        padding-top: 0;
        background: var(--white);
        border-top: 1px solid var(--border);
    }

    .cv-nav.is-active {
        display: block;
    }

    .cv-menu {
        display: block;
        width: 100%;
        background: var(--white);
        padding: 0;
        margin: 0;
    }

    .cv-menu > li {
        border-bottom: 1px solid var(--border);
    }

    .cv-menu > li > a {
        padding: 13px 16px;
        font-size: 12px;
        font-weight: 700;
        justify-content: space-between;
    }

    .cv-menu > li.menu-item-has-children > a::after {
        content: "+";
        font-family: inherit;
        font-size: 18px;
        font-weight: 700;
        margin-left: 0;
    }

    .cv-menu > li.menu-item-has-children.active > a::after {
        content: "−";
    }

    .cv-menu .sub-menu {
        display: none;
        position: static;
        min-width: 100%;
        opacity: 1;
        visibility: visible;
        transform: none;
        box-shadow: none;
        border-radius: 0;
        padding: 0;
        background: #fafafa;
    }

    .cv-menu .menu-item-has-children.active > .sub-menu {
        display: block;
    }

    .cv-menu .sub-menu li {
        border-top: 1px solid #eeeeee;
    }

    .cv-menu .sub-menu a {
        padding: 11px 24px;
        font-size: 11px;
        font-weight: 500;
        color: var(--text);
    }
}

@media (max-width: 768px) {
    .cv-header-row {
        grid-template-columns: 78px minmax(0, 1fr) 36px;
        gap: 10px;
    }

    .cv-logo {
        width: 78px;
    }

    .cv-logo img {
        width: 72px;
        max-height: 48px;
    }

    .cv-menu-toggle {
        width: 36px;
        height: 36px;
        font-size: 20px;
    }

    .cv-search form {
        height: 34px;
    }

    .cv-search-icon,
    .cv-search input {
        height: 34px;
    }
}