/* Princess Lucy Site – Categoriemenu in de onderste rij van de header.

   Zelfde uitzicht als het vroegere menu (snippet #31), maar nu op het
   menu-element van Blocksy:
     nav.menu-container > ul.menu > li > a.ct-menu-link
                                     └ ul.sub-menu > li > a.ct-menu-link

   Alles is beperkt tot de onderste rij, zodat het secundaire menu bovenaan
   en het mobiele menu niet veranderen. */

/* ---------- Rij ---------- */

.ct-header [data-row*="bottom"] {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 48px;
    background: #ffffff;
    border-top: 1px solid #f2ede8;
    border-bottom: 1px solid #f2ede8;
}

.ct-header [data-row*="bottom"] {
    position: relative;
    z-index: 4; /* Blocksy geeft de onderste rij z-index 1: uitklapmenu boven de rest houden */
}

/* Centreren: Blocksy zet het menu in een kolom die maar zo breed is als
   het menu zelf (links uitgelijnd). Kolom en items over de volle breedte. */
.ct-header [data-row*="bottom"] > .ct-container,
.ct-header [data-row*="bottom"] > .ct-container-fluid {
    display: flex !important;
    justify-content: center;
    width: 100%;
}

.ct-header [data-row*="bottom"] [data-column] {
    flex: 1 1 auto;
    width: 100%;
    justify-content: center;
}

.ct-header [data-row*="bottom"] [data-column] > [data-items] {
    width: 100%;
    justify-content: center;
}

.ct-header [data-row*="bottom"] .menu-container {
    --menu-items-spacing: 24px;   /* 2 × 24px = 48px tussen de items, zoals vroeger */
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
}

/* ---------- Hoofdmenu ---------- */

.ct-header [data-row*="bottom"] .menu-container > .menu {
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 0;
    padding: 10px 0;
    list-style: none;
}

.ct-header [data-row*="bottom"] .menu-container > .menu > li {
    position: relative;
}

.ct-header [data-row*="bottom"] .menu-container > .menu > li > .ct-menu-link {
    position: relative;
    display: flex;
    align-items: center;
    height: auto;
    padding: 8px 0;
    margin: 0 var(--menu-items-spacing);
    color: #55473d;
    font-family: inherit;
    font-size: 14px;
    font-weight: 600;
    line-height: 1.3;
    letter-spacing: .08em;
    text-transform: uppercase;
    text-decoration: none;
    transition: color .25s ease;
}

/* Pijltje: het Blocksy-icoon vervangen door het vroegere "▾" */
.ct-header [data-row*="bottom"] .menu-container > .menu > li > .ct-menu-link .ct-toggle-dropdown-desktop svg {
    display: none;
}

.ct-header [data-row*="bottom"] .menu-container > .menu > li.menu-item-has-children > .ct-menu-link::after {
    content: "▾";
    margin-left: 6px;
    font-size: 11px;
    color: #999;
}

.ct-header [data-row*="bottom"] .menu-container .ct-toggle-dropdown-desktop-ghost {
    display: none;
}

/* Hoverkleur */
.ct-header [data-row*="bottom"] .menu-container > .menu > li:hover > .ct-menu-link,
.ct-header [data-row*="bottom"] .menu-container > .menu > li:focus-within > .ct-menu-link {
    color: #b19067;
}

/* Lijntje onder het item (animatie) */
.ct-header [data-row*="bottom"] .menu-container > .menu > li > .ct-menu-link::before {
    content: "";
    position: absolute;
    left: 0;
    bottom: -3px;
    width: 0;
    height: 2px;
    background: #b19067;
    transition: width .25s ease;
}

.ct-header [data-row*="bottom"] .menu-container > .menu > li:hover > .ct-menu-link::before,
.ct-header [data-row*="bottom"] .menu-container > .menu > li:focus-within > .ct-menu-link::before {
    width: 100%;
}

/* Huidige categorie */
.ct-header [data-row*="bottom"] .menu-container .current-menu-item > .ct-menu-link,
.ct-header [data-row*="bottom"] .menu-container .current-menu-ancestor > .ct-menu-link,
.ct-header [data-row*="bottom"] .menu-container .current-product_cat-ancestor > .ct-menu-link {
    color: #b19067;
}

/* ---------- Uitklapmenu ----------
   Blocksy toont/verbergt het uitklapmenu zelf; wij nemen dat hier over
   (met !important) zodat het gecentreerd onder het item uitschuift. */

.ct-header [data-row*="bottom"] .menu-container .sub-menu {
    position: absolute;
    top: calc(100% + 4px) !important;
    left: 50% !important;
    right: auto !important;
    min-width: 240px;
    width: max-content;
    margin: 0 !important;
    padding: 8px 0 !important;
    list-style: none;
    background: #ffffff !important;
    border: 1px solid #ece7e2;
    border-radius: 10px !important;
    box-shadow: 0 12px 30px rgba(0, 0, 0, .08) !important;
    opacity: 0 !important;
    visibility: hidden !important;
    pointer-events: none !important;
    transform: translateX(-50%) translateY(8px) !important;
    transition: opacity .2s ease, transform .2s ease, visibility .2s ease !important;
    z-index: 99999;
    /* Blocksy zet overflow:hidden op een gesloten uitklapmenu; dat knipte
       de onzichtbare brug hieronder weg, waardoor het menu sloot. */
    overflow: visible !important;
    max-height: none !important;
}

/* Onzichtbare brug, zodat het menu niet sluit als de muis de 10px-tussenruimte kruist */
.ct-header [data-row*="bottom"] .menu-container .sub-menu::before {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    top: -12px;
    height: 12px;
}

/* Tweede brug, op het menu-item zelf: zolang je over het item hangt,
   loopt de "hoverzone" 16px door naar beneden, tot in het uitklapmenu. */
.ct-header [data-row*="bottom"] .menu-container > .menu > li.menu-item-has-children:hover::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    top: 100%;
    height: 16px;
    z-index: 99998;
}

.ct-header [data-row*="bottom"] .menu-container > .menu > li:hover > .sub-menu,
.ct-header [data-row*="bottom"] .menu-container > .menu > li:focus-within > .sub-menu,
.ct-header [data-row*="bottom"] .menu-container > .menu > li.ct-active > .sub-menu {
    opacity: 1 !important;
    visibility: visible !important;
    /* Blocksy maakt het menu pas aanraakbaar als zijn script het "actief" zet.
       Zonder dit valt de muis door het menu heen op de afbeelding eronder
       en sluit het menu. */
    pointer-events: auto !important;
    transform: translateX(-50%) translateY(0) !important;
}

.ct-header [data-row*="bottom"] .menu-container .sub-menu li {
    list-style: none;
}

.ct-header [data-row*="bottom"] .menu-container .sub-menu .ct-menu-link {
    display: block;
    padding: 10px 18px !important;
    color: #55473d !important;
    font-family: inherit;
    font-size: 14px;
    font-weight: 400;
    letter-spacing: normal;
    text-transform: none;
    text-decoration: none;
    background: transparent;
    transition: all .2s ease;
}

.ct-header [data-row*="bottom"] .menu-container .sub-menu .ct-menu-link:hover,
.ct-header [data-row*="bottom"] .menu-container .sub-menu .current-menu-item > .ct-menu-link {
    background: #faf8f5;
    color: #b19067 !important;
}
