/* Issue #95 / Denise v1: only the Shop component and its open-state containment. */
#masthead .cp-shop-item { position: relative; }
#masthead .cp-shop-item > .menu-link { padding-right: 4px; }
#masthead .cp-shop-toggle {
    display: inline-flex; align-items: center; justify-content: center;
    width: 44px; min-height: 44px; padding: 0; border: 0; border-radius: 4px;
    background: transparent; color: #012452; cursor: pointer; vertical-align: middle;
    touch-action: manipulation; -webkit-tap-highlight-color: #D7E4EB;
    text-transform: none;
}
#masthead .cp-shop-toggle[hidden], #masthead .cp-shop-panel[hidden], .cp-shop-scrim[hidden] { display: none !important; }
#masthead .cp-shop-toggle[aria-expanded="true"] svg { transform: rotate(180deg); }
#masthead .cp-shop-toggle:hover { background: #F2F8FB; }
#masthead .cp-shop-panel {
    font-family: 'Plus Jakarta Sans', sans-serif; text-align: left;
    background: #FFFFFF; color: #24364B; line-height: 1.5; font-size: 14px;
}
#masthead .cp-shop-panel a {
    display: flex; align-items: center; white-space: normal; overflow-wrap: anywhere;
    padding: 4px 0; min-height: 32px; color: #24364B; font-size: 14px;
    font-weight: 500; line-height: 24px; text-decoration: none; height: auto;
    background: transparent; border: 0;
    text-transform: none; letter-spacing: normal; font-family: inherit;
}
#masthead .cp-shop-panel a:hover { color: #012452; text-decoration: underline; text-underline-offset: 4px; }
#masthead .cp-shop-item a:focus-visible, #masthead .cp-shop-toggle:focus-visible {
    outline: 2px solid #012452; outline-offset: 3px; border-radius: 2px;
}
#masthead .cp-shop-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 24px; padding: 36px; }
#masthead .cp-shop-column { min-width: 0; }
#masthead .cp-shop-group + .cp-shop-group { margin-top: 42px; }
#masthead .cp-shop-panel .cp-shop-heading { color: #012452; font-size: 16px; font-weight: 700; margin-bottom: 3px; }
#masthead .cp-shop-products, #masthead .cp-shop-products li { display: block; list-style: none; padding: 0; margin: 0; border: 0; width: auto; }
#masthead .cp-shop-panel .cp-shop-all {
    padding: 20px 36px; min-height: 72px; gap: 10px; border-top: 1px solid #D7E4EB;
    color: #0287A1; font-size: 15px; font-weight: 700;
}
.cp-shop-scrim { position: fixed; inset: var(--cp-shop-top, 104px) 0 0; z-index: 998; background: rgb(1 36 82 / 10%); }

    body:not(.ast-header-break-point) #masthead .cp-shop-item { display: flex; align-items: center; }
    body:not(.ast-header-break-point) #masthead:has(.cp-shop-toggle[aria-expanded="true"]) { z-index: 999; position: relative; }
    body:not(.ast-header-break-point) #masthead .cp-shop-panel {
        position: fixed; z-index: 1000; top: var(--cp-shop-top, 104px);
        left: max(24px, calc((100vw - 1200px) / 2)); width: min(1200px, calc(100vw - 48px));
        height: min(612px, calc(100dvh - var(--cp-shop-top, 104px) - 16px));
        display: grid; grid-template-rows: minmax(0, 1fr) auto;
        border: 1px solid #D7E4EB; border-radius: 10px; box-shadow: 0 9px 23px rgb(1 36 82 / 7%);
    }
    body:not(.ast-header-break-point) #masthead .cp-shop-grid { overflow-y: auto; overscroll-behavior: contain; align-content: start; }
    body:not(.ast-header-break-point) #masthead .cp-shop-item:has([aria-expanded="true"]) > .menu-link { color: #012452; text-decoration: underline; text-decoration-color: #0287A1; text-decoration-thickness: 3px; text-underline-offset: 12px; }

    body.ast-header-break-point #masthead .cp-shop-item { display: block; }
    body.ast-header-break-point #masthead .cp-shop-item > .menu-link { padding-right: 56px; }
    body.ast-header-break-point #masthead .cp-shop-toggle { position: static; width: 100%; min-height: 50px; padding: 3px 20px; justify-content: space-between; font-family: 'Plus Jakarta Sans', sans-serif; font-size: 17px; font-weight: 700; border-bottom: 1px solid #D7E4EB; border-radius: 0; }
    body.ast-header-break-point #masthead .cp-shop-panel { position: static; width: 100%; border: 0; box-shadow: none; }
    body.ast-header-break-point #masthead .cp-shop-grid { grid-template-columns: minmax(0, 1fr); gap: 24px; padding: 12px 28px 24px; }
    body.ast-header-break-point #masthead .cp-shop-group + .cp-shop-group { margin-top: 24px; }
    body.ast-header-break-point #masthead .cp-shop-panel a { min-height: 44px; }
    body.ast-header-break-point #masthead .cp-shop-panel .cp-shop-heading { font-size: 14px; margin: 0; }
    body.ast-header-break-point #masthead .cp-shop-products a { padding-left: 8px; }
    body.ast-header-break-point #masthead .cp-shop-panel .cp-shop-all { padding: 16px 28px; min-height: 64px; }
    body.ast-header-break-point #masthead .ast-mobile-header-content { max-height: calc(100dvh - var(--cp-shop-mobile-top, 100px)); overflow-y: auto; overscroll-behavior: contain; padding-bottom: env(safe-area-inset-bottom); }
    body.ast-header-break-point .cp-shop-scrim { display: none; }
