.site-header {
    background-color: var(--color-beige-2);
}

.site-header__inner {
    max-width: var(--container-width-wide);
    margin-inline: auto;
    padding-block: var(--space-3);
    padding-inline: clamp(var(--space-3), 4vw, 3.75rem);
    display: flex;
    align-items: center;
    gap: var(--space-2);
}

.site-header__logo-link {
    display: block;
    order: 1;
    margin-right: auto;
    transition: opacity 0.15s ease;
}

/* The only interactive element in the header without any feedback — the menu
   button and the CTA both already have one. */
.site-header__logo-link:hover,
.site-header__logo-link:focus-visible {
    opacity: 0.8;
}

.site-header__logo {
    display: block;
    width: clamp(120px, 22vw, 163px);
    height: auto;
}

.site-header__menu-switcher {
    order: 2;
}

.site-header__menu-button {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border-radius: var(--radius);
    background-color: var(--color-beige-1);
    transition: opacity 0.15s ease;
}

.site-header__menu-button:hover,
.site-header__menu-button:focus-visible {
    opacity: 0.85;
}

.site-header__menu-button svg {
    display: block;
    width: 24px;
    height: 24px;
}

.site-header__button {
    position: relative;
    order: 3;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    padding-inline: var(--space-3);
    border-radius: 6px;
    font-family: var(--font-family-base);
    font-weight: 700;
    font-size: 16px;
    line-height: 24px;
    /* nowrap keeps the label on one line, but without min-width: 0 the flex item
       refuses to shrink below its own min-content, and the header row then
       overflowed the viewport on narrow phones — sooner still once this
       ACF-editable label is translated for another market. Ellipsis is a better
       failure than a page that scrolls sideways. */
    min-width: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    text-decoration: none;
    transition: opacity 0.15s ease;
}

.site-header__button:hover,
.site-header__button:focus-visible {
    opacity: 0.85;
}

.site-header__button--primary {
    background-color: var(--color-grey-1);
    color: var(--color-beige-2);
}

.site-header__button--login {
    background-color: var(--color-beige-1);
    color: var(--color-grey-1);
}

@media (max-width: 599px) {
    .site-header__inner {
        padding-inline: var(--space-2);
        padding-block: var(--space-2);
        gap: var(--space-1);
    }

    .site-header__logo {
        width: 136px;
    }

    /* Both of these are 44px from 600px up; shrinking them to 40px only on
       phones made the tap target smaller on the one device driven by a finger
       rather than a cursor. 40px still clears WCAG 2.2 AA (24x24), so this is
       about usability and Apple's 44pt guidance, not conformance. Only the
       horizontal padding needs to come down on narrow screens. */
    .site-header__button {
        padding-inline: var(--space-2);
    }
}

@media (max-width: 374px) {
    .site-header__logo {
        width: 120px;
    }

    .site-header__button {
        padding-inline: 0.75rem;
        font-size: 14px;
    }
}
