/* Shared corporate header; homepage content keeps its own stylesheet. */
.bw-header {
    --bw-hover: #ff3558;
    color: #fff;
    font: 400 20px/1.5 "Satoshi", Arial, Helvetica, sans-serif;
    letter-spacing: 0;
}

.bw-header,
.bw-header *,
.bw-header *::before,
.bw-header *::after {
    box-sizing: border-box;
}

.bw-header :where(div, figure) {
    margin: 0;
}

:is(.bw-home, .bw-header, .bw-footer) a {
    color: inherit;
    text-decoration: none;
}

:is(.bw-home, .bw-header, .bw-footer) a:is(:hover, :focus, :focus-visible, :active) {
    text-decoration: none;
}

@media (hover: hover) and (pointer: fine) {
    :is(.bw-home, .bw-header, .bw-footer) a:not(.bw-button):not([aria-disabled="true"]):not(:has(img)):hover,
    :is(.bw-home, .bw-header, .bw-footer) .bw-resources > summary:hover {
        color: var(--bw-hover);
    }

    :is(.bw-home, .bw-header, .bw-footer) .bw-button:not(:disabled):not([aria-disabled="true"]):hover {
        background: var(--bw-hover);
    }
}

:is(.bw-home, .bw-header, .bw-footer) :where(a, summary, button):focus-visible {
    outline: 3px solid #c6b4ff;
    outline-offset: 5px;
}

:is(.bw-home, .bw-header, .bw-footer) img {
    display: block;
    max-width: 100%;
    height: auto;
}

:is(.bw-home, .bw-header, .bw-footer) :is(a, button).bw-button {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    min-height: 48px;
    margin: 0;
    padding: 12px 24px;
    border: 0;
    border-radius: 4px;
    background: #d81b60;
    color: #fff;
    font-family: inherit;
    font-size: 16px;
    line-height: 24px;
    text-align: center;
}

:is(.bw-home, .bw-header, .bw-footer) :where([aria-disabled="true"], button:disabled) {
    cursor: not-allowed;
}

.bw-header {
    position: relative;
    z-index: 3;
    margin: 16px 16px 0;
    min-height: 100px;
    padding: 24px 40px;
    background: #0a0c21;
    display: flex;
    align-items: center;
    gap: clamp(40px, 9.375vw, 180px);
}

.bw-header > .wp-block-image {
    flex: 0 0 181.647px;
}

.bw-header > .wp-block-image > a {
    display: block;
}

.bw-header > .wp-block-image {
    display: flex;
    align-items: center;
}

.bw-header .bw-navigation,
.bw-header .bw-nav-primary {
    display: flex;
    align-items: center;
    gap: 40px;
    font-size: 16px;
    font-weight: 500;
}

.bw-header .bw-navigation {
    flex: 1;
    margin-block: 0;
}

.bw-header :where(.bw-navigation > a, .bw-navigation > span, .bw-nav-primary > a, .bw-contact > a, .bw-resources summary) {
    display: inline-flex;
    align-items: center;
    line-height: 24px;
    padding-block: 0;
}

.bw-header .bw-nav-primary::before,
.bw-header .bw-contact::before {
    content: "";
    display: inline-block;
    width: 8px;
    height: 8px;
    background: #ff3558;
    flex-shrink: 0;
}

.bw-header .bw-contact {
    display: flex;
    align-items: center;
    gap: 40px;
    margin-inline: auto;
}

.bw-header .bw-resources {
    position: relative;
}

.bw-header .bw-resources summary {
    cursor: pointer;
    list-style: none;
}

.bw-header .bw-resources summary::-webkit-details-marker {
    display: none;
}

.bw-header .bw-resources ul {
    position: absolute;
    top: 100%;
    left: -20px;
    min-width: 180px;
    margin: 12px 0 0;
    padding: 12px 20px;
    list-style: none;
    background: #0a0c21;
    border: 1px solid #323447;
}

.bw-header .bw-resources li a {
    display: block;
    padding: 10px 0;
}

/* Bridge the dropdown's 12px margin and 1px border for pointer navigation. */
.bw-header .bw-resources ul::before {
    content: "";
    position: absolute;
    bottom: 100%;
    inset-inline: 0;
    height: 13px;
}

@media (max-width: 1599px) {
    .bw-header,
    .bw-header .bw-navigation,
    .bw-header .bw-nav-primary,
    .bw-header .bw-contact {
        gap: 24px;
    }
}

/* Navigation remains visible until its toggle is initialized. */
.bw-header .bw-menu-toggle {
    display: none;
    width: 44px;
    height: 44px;
    padding: 10px;
    border: 0;
    background: transparent;
    color: inherit;
    cursor: pointer;
}

.bw-menu-toggle span,
.bw-menu-toggle span::before,
.bw-menu-toggle span::after {
    display: block;
    width: 24px;
    height: 2px;
    background: currentColor;
}

.bw-menu-toggle span::before,
.bw-menu-toggle span::after {
    content: "";
    position: relative;
    top: -8px;
}

.bw-menu-toggle span::after {
    top: 6px;
}

@media (max-width: 1279px) {
    .bw-header,
    .bw-home .bw-header {
        position: relative;
        inset: auto;
        margin: 16px 16px 0;
        min-height: 92px;
        padding: 24px;
        flex-wrap: wrap;
        gap: 12px;
    }

    .bw-header > .wp-block-image > a {
        display: flex;
        align-items: center;
        min-height: 44px;
    }

    .bw-header .bw-menu-toggle:not([hidden]) {
        display: flex;
        align-items: center;
        justify-content: center;
        margin-left: auto;
    }

    .bw-header .bw-navigation,
    .bw-header .bw-nav-primary,
    .bw-header .bw-contact {
        flex-direction: column;
        align-items: stretch;
        gap: 8px;
        width: 100%;
        margin: 0;
    }

    .bw-header .bw-navigation {
        flex: 0 0 100%;
        max-height: calc(100dvh - 140px);
        overflow-y: auto;
        padding: 8px;
    }

    .bw-header .bw-menu-toggle[aria-expanded="false"]:not([hidden]) + .bw-navigation {
        display: none;
    }

    .bw-header .bw-nav-primary::before,
    .bw-header .bw-contact::before {
        display: none;
    }

    .bw-header .bw-navigation :where(a, summary, [aria-disabled="true"]) {
        min-height: 44px;
        display: flex;
        align-items: center;
    }

    .bw-header .bw-resources ul {
        position: static;
        min-width: 0;
        margin: 0;
        padding: 0 0 0 20px;
        border: 0;
    }

    .bw-header .bw-resources ul::before {
        display: none;
    }
}
