/* Header Builder owns only its own layout; saved WordPress headers keep their styling. */
.nfh-header {
    position: relative;
    isolation: isolate;
    color: var(--nfx-ui-header-text, #242725);
    background: var(--nfx-ui-header-bg, #fff);
}
.nfh-device {
    display: none;
}
.nfh-row {
    position: relative;
    background: var(--nfx-ui-header-bg, #fff);
    color: var(--nfx-ui-header-text, #242725);
}
.nfh-row-top {
    z-index: 3;
    background: var(--nfx-ui-top-bg, #283b32);
    color: var(--nfx-ui-top-text, #faf8f2);
}
.nfh-row-main {
    z-index: 2;
}
.nfh-row:has(.nfh-pop[open], .nfx-main-group[data-nfx-open]) {
    z-index: 10;
}
.nfh-row-bottom {
    z-index: 1;
    background: var(--nfx-ui-nav-bg, #faf8f4);
    color: var(--nfx-ui-nav-text, #242725);
}
.nfh-inner {
    width: min(var(--nfx-width), calc(100% - 2 * var(--nfx-gutter)));
    margin: auto;
    display: grid;
    grid-template-columns: minmax(0, var(--nfh-start, 1fr)) minmax(0, var(--nfh-middle, 1.2fr)) minmax(
            0,
            var(--nfh-end, 1fr)
        );
    gap: clamp(8px, 1.6vw, 24px);
    align-items: center;
    padding-block: 14px;
}
.nfh-row-top .nfh-inner {
    padding-block: 3px;
}
.nfh-row-bottom .nfh-inner {
    padding-block: 3px;
}
.nfh-inner:has(> .nfh-left:empty) {
    --nfh-start: 0fr;
}
.nfh-inner:has(> .nfh-center:empty) {
    --nfh-middle: 0fr;
}
.nfh-inner:has(> .nfh-right:empty) {
    --nfh-end: 0fr;
}
.nfh-inner:has(> .nfh-center .nfh-item-main) {
    --nfh-middle: 4fr;
}
.nfh-inner:has(> .nfh-left .nfh-item-main) {
    --nfh-start: 3fr;
}
.nfh-inner:has(> .nfh-right .nfh-item-main) {
    --nfh-end: 3fr;
}
.nfh-cell {
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 0;
    flex-wrap: wrap;
}
.nfh-cell:empty {
    display: none;
}
.nfh-left {
    grid-column: 1;
    justify-content: flex-start;
}
.nfh-center {
    grid-column: 2;
    justify-content: center;
}
.nfh-right {
    grid-column: 3;
    justify-content: flex-end;
}
.nfh-item {
    min-width: 0;
    max-width: 100%;
    overflow-wrap: anywhere;
}
.nfh-item-search {
    width: 100%;
}
.nfh-item :where(p, form) {
    margin-block: 0;
}
.nfh-item img {
    max-width: 100%;
    height: auto;
}
.nfh-item .nfx-notice {
    padding: 5px 0;
    background: transparent;
    color: inherit;
}
.nfh-item .wc-block-mini-cart__button {
    min-width: 44px;
    min-height: 44px;
    padding: 7px;
    color: inherit;
}
.nfh-item .wc-block-mini-cart__amount {
    font-size: 0.8rem;
}
.nfh-item .nfm-logo {
    margin: 0;
    width: 100%;
    max-width: 100%;
}
.nfh-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    padding: 9px 18px;
    border-radius: 8px;
    background: var(--nfx-ui-button, #733249);
    color: var(--nfx-ui-button-text, #fff);
    text-decoration: none;
    font-size: 0.875rem;
    font-weight: 600;
}
.nfh-header a {
    color: inherit;
}
.nfh-header .nfh-button {
    color: var(--nfx-ui-button-text, #fff);
}
.nfh-nav {
    font-size: 0.9rem;
    font-weight: 550;
}
.nfh-tree {
    color: inherit;
    background: transparent;
}
.nfh-tree .wp-block-navigation-item__content {
    text-decoration: none;
    overflow-wrap: anywhere;
}
.nfh-tree .wp-block-navigation-item__content:hover,
.nfh-tree .current-menu-item > a {
    color: var(--nfx-ui-nav-active, #87663c);
}
.nfh-inline > .wp-block-navigation .wp-block-navigation__container {
    gap: 2px 20px;
    flex-wrap: wrap;
    justify-content: inherit;
}
.nfh-inline .wp-block-navigation__container > li > a {
    padding-block: 12px;
    min-height: 44px;
}
.nfh-tree .wp-block-navigation__submenu-icon {
    width: 28px;
    height: 40px;
    margin: 0;
    display: grid;
    place-items: center;
}
.nfh-tree .wp-block-navigation__submenu-icon svg {
    width: 12px;
    height: 12px;
}
.nfh-inline .wp-block-navigation__submenu-container {
    border: 0;
    border-radius: 12px;
    box-shadow: 0 12px 40px #192a2524;
    background: var(--nfx-ui-nav-bg, #fff);
    color: var(--nfx-ui-nav-text, #242725);
    max-width: calc(100vw - 24px);
    translate: var(--nfh-flyout-shift, 0px) 0;
}
.nfh-inline
    .has-child:is(:hover, :focus-within, :has(> button[aria-expanded='true']))
    > .wp-block-navigation__submenu-container {
    padding: 8px;
}
.nfh-inline .wp-block-navigation__submenu-container a {
    min-height: 44px;
    padding: 10px 12px;
}
.nfh-pop {
    position: relative;
}
.nfh-pop > summary {
    display: flex;
    align-items: center;
    gap: 10px;
    min-height: 44px;
    padding: 8px 0;
    cursor: pointer;
    list-style: none;
}
.nfh-pop > summary::-webkit-details-marker {
    display: none;
}
.nfh-lines {
    display: grid;
    gap: 4px;
    width: 20px;
    flex: none;
}
.nfh-lines i {
    display: block;
    height: 2px;
    background: currentColor;
    border-radius: 1px;
}
.nfh-panel {
    background: var(--nfx-ui-nav-bg, #fff);
    color: var(--nfx-ui-nav-text, #242725);
    border-radius: 14px;
    box-shadow: 0 14px 48px #1b2c292b;
    padding: 12px;
}
.nfh-dropdown > .nfh-panel {
    position: absolute;
    z-index: 10;
    top: 100%;
    left: var(--nfh-panel-left, 0);
    width: min(23rem, calc(100vw - 24px));
    max-height: min(var(--nfh-available-height, 70vh), 640px);
    overflow: auto;
    overscroll-behavior: contain;
}
.nfh-dropdown > .nfh-panel[data-nfh-above] { inset-block: auto 100%; }
.nfh-panel-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 0 4px 10px;
    font-size: 1rem;
}
.nfh-panel-head button {
    display: grid;
    place-items: center;
    min-width: 44px;
    min-height: 44px;
    border: 0;
    background: transparent;
    color: inherit;
    font-size: 28px;
    cursor: pointer;
}
.nfh-panel .wp-block-navigation,
.nfh-panel .wp-block-navigation__responsive-container,
.nfh-panel .wp-block-navigation__responsive-container-content {
    display: block;
}
.nfh-panel .wp-block-navigation__container {
    display: flex;
    flex-direction: column;
    gap: 0;
    align-items: stretch;
}
.nfh-panel .wp-block-navigation-item {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0;
    width: 100%;
}
.nfh-panel .wp-block-navigation-item > a {
    flex: 1;
    min-width: 0;
    min-height: 44px;
    padding: 10px 12px;
    line-height: 1.4;
    border-radius: 8px;
}
.nfh-panel .wp-block-navigation-item > a:hover {
    background: color-mix(in srgb, currentColor 5%, transparent);
}
.nfh-panel .wp-block-navigation__submenu-icon {
    flex: none;
    width: 44px;
    min-height: 44px;
}
.nfh-panel .wp-block-navigation__submenu-container {
    display: none;
    position: static;
    inset: auto;
    opacity: 1;
    visibility: visible;
    width: 100%;
    min-width: 0;
    height: auto;
    overflow: visible;
    padding: 0 0 0 12px;
    border: 0;
    background: transparent;
    box-shadow: none;
    color: inherit;
}
.nfh-panel li:has(> button[aria-expanded='true']) > .wp-block-navigation__submenu-container {
    display: flex;
    flex-direction: column;
    align-items: stretch;
}
.nfh-drawer[open]::before {
    content: '';
    position: fixed;
    inset: 0;
    background: #15201c70;
    z-index: 20;
    cursor: pointer;
}
.nfh-drawer > .nfh-panel {
    position: fixed;
    left: 0;
    top: var(--wp-admin--admin-bar--height, 0px);
    bottom: 0;
    width: min(25rem, 90vw);
    border-radius: 0 18px 18px 0;
    z-index: 21;
    overflow: auto;
    overscroll-behavior: contain;
    padding: max(14px, env(safe-area-inset-top)) max(16px, env(safe-area-inset-right)) max(20px, env(safe-area-inset-bottom)) max(16px, env(safe-area-inset-left));
}
.nfh-drawer-right > .nfh-panel { left: auto; right: 0; border-radius: 18px 0 0 18px; }
.nfh-fullscreen > .nfh-panel { inset-inline: 0; width: 100%; border-radius: 0; }
.nfh-panel-pieces { display: grid; gap: 12px; }
.nfh-panel-piece { min-width: 0; max-width: 100%; overflow-wrap: anywhere; }
.nfh-panel-piece .nfm-logo { justify-content: start; }
.nfh-panel-piece .nfm-search { width: 100%; max-width: none; }
.nfh-panel-piece .nfxp-brand-lockup { max-width: 100%; }
.nfh-panel-piece .custom-logo { max-height: 50px; width: auto; object-fit: contain; }
.nfh-panel-piece .nfxp-consult--header .nfxp-consult__copy { position: static; clip-path: none; overflow: visible; width: auto; height: auto; }
.nfh-section-menu > summary, .nfh-cart-link {
    display: flex; align-items: center; min-height: 44px; gap: 8px; padding: 7px 12px;
    border-radius: 8px; font-weight: 600; cursor: pointer;
}
.nfh-section-menu > summary { justify-content: space-between; list-style: none; }
.nfh-section-menu > summary::-webkit-details-marker { display: none; }
.nfh-section-menu > summary::after {
    content: ''; width: 8px; height: 8px; border: solid currentColor;
    border-width: 0 1.5px 1.5px 0; transform: rotate(45deg);
}
.nfh-section-menu[open] > summary::after { transform: rotate(225deg); }
.nfh-section-menu > summary, .nfh-cart-link { background: color-mix(in srgb, currentColor 6%, transparent); text-decoration: none; }
html.nfh-drawer-open {
    overflow: hidden;
}
@media (min-width: 1025px) {
    .nfh-desktop {
        display: block;
    }
    .nfh-desktop .nfh-inner { width: min(var(--nfx-header-width), calc(100% - 2 * var(--nfx-header-gutter))); }
    .nfh-desktop .nfh-row-main .nfh-inner { padding-block: clamp(18px,1.6vw,24px); }
    .nfh-desktop .nfh-row-bottom .nfh-inner { padding-block: 7px; }
    /* When both menus have their own cells, the links share the remaining row width. */
    .nfh-desktop .nfh-inner:has(> .nfh-cell > .nfh-item-vertical:only-child):has(> .nfh-cell > .nfh-item-main:only-child > .nfh-inline) {
        display: flex;
        --nfh-link-pad: clamp(5px,.72vw,12px);
        --nfh-menu-width: 100%;
        --nfh-menu-align: space-evenly;
        --nfh-menu-gap: 0px;
        column-gap: var(--nfh-link-pad);
    }
    .nfh-desktop .nfh-cell:has(> .nfh-item-vertical:only-child) { flex: 0 1 auto; }
    .nfh-desktop .nfh-cell:has(> .nfh-item-main:only-child > .nfh-inline) { flex: 1 1 0; }
    .nfh-desktop .nfh-item-main:has(> .nfh-inline) { width: var(--nfh-menu-width,auto); }
    .nfh-desktop .nfh-item-main > .nfh-inline .wp-block-navigation__container {
        width: var(--nfh-menu-width,auto); justify-content: var(--nfh-menu-align,inherit); column-gap: var(--nfh-menu-gap,clamp(16px,2vw,34px));
    }
    .nfh-desktop .nfh-item-main > .nfh-inline .wp-block-navigation__container > li { padding-inline: var(--nfh-link-pad,3px); }

}
@media (max-width: 1024px) {
    .nfh-mobile {
        display: block;
    }
    .nfh-inner {
        gap: 8px;
        padding-block: 9px;
    }
    .nfh-inner:has(> .nfh-center .nfh-item-logo) {
        --nfh-middle: 3fr;
    }
    .nfh-inner:has(> .nfh-left .nfh-item-main) {
        --nfh-start: 1fr;
    }
    .nfh-item-main .nfh-nav-label {
        position: absolute;
        width: 1px;
        height: 1px;
        overflow: hidden;
        clip-path: inset(50%);
    }
    .nfh-item-main > .nfh-pop > summary { min-width: 44px; justify-content: center; }
    /* Inline links need the usable row width even when the menu was placed in a side cell. */
    .nfh-inner:has(.nfh-item-main > .nfh-inline) {
        grid-template-columns: repeat(3, minmax(0, 1fr));
        grid-auto-flow: row dense;
    }
    .nfh-cell:has(> .nfh-item-main > .nfh-inline) { grid-column: 1 / -1; }
    .nfh-inner:has(> .nfh-cell:not(:empty) ~ .nfh-cell:not(:empty)) > .nfh-cell:has(> .nfh-item-main > .nfh-inline) { grid-row: 2; }
    .nfh-cell > .nfh-item-main:has(> .nfh-inline) { flex-basis: 100%; }
    .nfh-item-main > .nfh-inline .wp-block-navigation__container { column-gap: 12px; }
    .nfh-cell {
        gap: 6px;
    }
    .nfh-item-logo .wp-block-site-title {
        font-size: clamp(1rem, 3.7vw, 1.4rem);
    }
    .nfh-item-logo .nfxp-sample-mark {
        width: 32px;
        height: 32px;
    }
    .nfh-item-logo .nfxp-brand-lockup {
        gap: 7px;
    }
    .nfh-item-cart .wc-block-mini-cart__amount {
        display: none;
    }
    .nfh-item .nfxp-consult__copy {
        font-size: 0.75rem;
    }
    .nfh-item .nfm-search {
        width: 100%;
        max-width: none;
    }
    .nfh-item-logo .custom-logo {
        max-height: 52px;
        width: auto;
    }
    .nfh-item-logo .wp-block-site-logo {
        max-width: 100%;
    }
}
