.site-header {
    position: relative;
    z-index: 70;
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
    align-items: center;
    column-gap: clamp(12px, 2vw, 28px);
    height: 74px;
    padding: 0 38px;
    border-bottom: 1px solid #ddd8ce;
    background: rgb(255 253 249 / 98%);
}

.site-header .menu-trigger {
    display: grid;
    grid-column: 1;
    justify-self: start;
    flex: 0 0 auto;
    width: 44px;
    height: 44px;
    align-content: center;
    gap: 4px;
    padding: 13px;
    border: 0;
    background: transparent;
    cursor: pointer;
}

.site-header .menu-trigger span {
    display: block;
    width: 16px;
    height: 1.5px;
    background: #1f2521;
}

.site-header .wordmark {
    grid-column: 2;
    justify-self: center;
    color: #232723;
    font: 400 28px/1 Georgia, "Times New Roman", serif;
    text-decoration: none;
    white-space: nowrap;
}

.site-header .wordmark__name { display: block; }
.site-header .wordmark__tagline { display: none; }

.site-actions {
    grid-column: 3;
    display: flex;
    width: max-content;
    max-width: 100%;
    min-width: 0;
    align-items: center;
    justify-content: flex-end;
    justify-self: end;
    gap: 8px;
    white-space: nowrap;
}

.site-header .header-action {
    display: inline-flex;
    flex: 0 0 auto;
    min-height: 40px;
    align-items: center;
    justify-content: center;
    padding: 0 11px;
    border-radius: 6px;
    font: 700 12px/1.5 Inter, "Segoe UI", Arial, sans-serif;
    text-decoration: none;
    white-space: nowrap;
}

.site-header .header-action--primary {
    border: 1px solid #29483b;
    background: #29483b;
    color: #fff;
}

.site-header .header-action--secondary {
    border: 1px solid #cfd5cf;
    background: #fff;
    color: #35443d;
}

.site-header .header-action--text {
    border: 0;
    background: transparent;
    color: #737972;
}

.site-header .account-menu {
    position: relative;
    flex: 0 1 9.5rem;
    min-width: 0;
    max-width: 9.5rem;
}

.site-header .account-control {
    display: inline-flex;
    width: 100%;
    min-width: 0;
    max-width: 9.5rem;
    min-height: 40px;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 3px 7px 3px 4px;
    border: 1px solid #ddd8ce;
    border-radius: 6px;
    background: #f5f1e9;
    color: #232723;
    font: 700 12px/1.5 Inter, "Segoe UI", Arial, sans-serif;
    white-space: nowrap;
    cursor: pointer;
    list-style: none;
}

.site-header .account-control::-webkit-details-marker {
    display: none;
}

.site-header .account-control:is(:hover, :focus-visible),
.site-header .account-menu[open] .account-control {
    background: #fffdf9;
}

.site-header .account-control:focus-visible {
    outline: 2px solid #173f32;
    outline-offset: 2px;
}

.site-header .account-control__avatar {
    display: grid;
    flex: 0 0 28px;
    width: 28px;
    height: 28px;
    place-items: center;
    border: 1px solid #ddd8ce;
    border-radius: 50%;
    background: #fffdf9;
    color: #173f32;
    font-size: 10px;
    font-weight: 800;
    letter-spacing: .07em;
}

.site-header .account-control__separator,
.site-header .account-control__chevron {
    color: #737972;
}

.site-header .account-control__separator {
    font-size: 12px;
}

.site-header .account-control__name {
    min-width: 0;
    overflow: hidden;
    color: #232723;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.site-header .account-control__chevron {
    width: 6px;
    height: 6px;
    margin: -3px 2px 0 -1px;
    border-right: 1px solid currentcolor;
    border-bottom: 1px solid currentcolor;
    transform: rotate(45deg);
    transition: margin-top 180ms ease, transform 180ms ease;
}

.site-header .account-menu[open] .account-control__chevron {
    margin-top: 2px;
    transform: rotate(225deg);
}

.site-header .account-dropdown {
    position: absolute;
    z-index: 80;
    top: calc(100% + 8px);
    right: 0;
    min-width: 180px;
    padding: 6px;
    border: 1px solid #ddd8ce;
    border-radius: 6px;
    background: #fffdf9;
    box-shadow: 0 .75rem 2rem rgb(20 24 21 / 10%);
}

.site-header .account-dropdown a,
.site-header .account-dropdown button {
    display: flex;
    width: 100%;
    min-height: 44px;
    align-items: center;
    padding: 8px 10px;
    border: 0;
    border-radius: 4px;
    background: transparent;
    color: #232723;
    font: 600 12px/1.4 Inter, "Segoe UI", Arial, sans-serif;
    text-align: left;
    text-decoration: none;
    cursor: pointer;
}

.site-header .account-dropdown a:is(:hover, :focus-visible),
.site-header .account-dropdown button:is(:hover, :focus-visible) {
    background: #f5f1e9;
}

.site-header .account-dropdown a:focus-visible,
.site-header .account-dropdown button:focus-visible {
    outline: 2px solid #173f32;
    outline-offset: -2px;
}

.site-header .account-dropdown form {
    margin: 0;
}

@media (max-width: 64rem) {
    .site-actions .header-action--secondary {
        display: none;
    }
}

@media (max-width: 84rem) {
    .site-header .account-menu,
    .site-header .account-control {
        flex-basis: auto;
        width: auto;
        max-width: none;
    }

    .site-header .account-control__separator,
    .site-header .account-control__name {
        display: none;
    }
}

@media (max-width: 52rem) {
    .site-actions .community-menu {
        display: none;
    }
}

@media (max-width: 48rem) {
    .site-header {
        padding: 0 14px;
    }

    .site-header .wordmark {
        font-size: 23px;
    }

    .site-header .header-action--primary {
        padding: 0 10px;
        font-size: 10px;
    }

    .site-header .account-control {
        padding-right: 5px;
    }

}

/* Task 12 global public navigation. */

.site-header .menu-trigger:is(:hover, :focus-visible),
.site-drawer__header button:is(:hover, :focus-visible) {
    background: #f5f1e9;
}

.site-header .menu-trigger:focus-visible,
.site-drawer__header button:focus-visible {
    outline: 2px solid #173f32;
    outline-offset: 2px;
}

.site-header .header-action:hover {
    border-color: #9ea9a2;
}

.site-header .header-action:focus-visible {
    outline: 2px solid #173f32;
    outline-offset: 2px;
}

.site-header .community-menu {
    position: relative;
}

.site-header .community-menu > summary,
.site-header .account-menu > summary {
    list-style: none;
    cursor: pointer;
}

.site-header .community-menu > summary::-webkit-details-marker {
    display: none;
}

.site-header .community-menu[open] > summary {
    color: #232723;
}

.site-header .header-chevron {
    width: 6px;
    height: 6px;
    margin: -3px 0 0 8px;
    border-right: 1px solid currentcolor;
    border-bottom: 1px solid currentcolor;
    transform: rotate(45deg);
}

.site-header .community-menu[open] .header-chevron {
    margin-top: 3px;
    transform: rotate(225deg);
}

.site-header .header-dropdown {
    position: absolute;
    z-index: 80;
    top: calc(100% + 8px);
    right: 0;
    min-width: 190px;
    padding: 6px;
    border: 1px solid #ddd8ce;
    border-radius: 6px;
    background: #fffdf9;
    box-shadow: 0 .75rem 2rem rgb(20 24 21 / 10%);
}

.site-header .header-dropdown a {
    display: flex;
    min-height: 44px;
    align-items: center;
    padding: 8px 10px;
    border-radius: 4px;
    color: #232723;
    font: 600 12px/1.4 Inter, "Segoe UI", Arial, sans-serif;
    text-decoration: none;
}

.site-header .header-dropdown a:is(:hover, :focus-visible) {
    background: #f5f1e9;
}

.site-header .header-dropdown a:focus-visible {
    outline: 2px solid #173f32;
    outline-offset: -2px;
}

body.is-navigation-open {
    overflow: hidden;
}

.site-drawer {
    position: fixed;
    inset: 0;
    width: 100vw;
    max-width: none;
    height: 100dvh;
    max-height: none;
    margin: 0;
    padding: 0;
    overflow: hidden;
    border: 0;
    background: transparent;
    color: #232723;
    opacity: 0;
    transition:
        opacity 260ms ease-out,
        display 260ms allow-discrete,
        overlay 260ms allow-discrete;
}

.site-drawer::backdrop {
    background: transparent;
    transition:
        background-color 260ms ease-out,
        display 260ms allow-discrete,
        overlay 260ms allow-discrete;
}

.site-drawer[open] {
    opacity: 1;
}

.site-drawer[open]::backdrop {
    background: rgb(20 24 21 / 58%);
}

.site-drawer__panel {
    display: flex;
    width: min(28rem, 88vw);
    height: 100%;
    flex-direction: column;
    padding: clamp(1.5rem, 4vw, 2.5rem);
    overflow-x: hidden;
    overflow-y: auto;
    overscroll-behavior: contain;
    background: #fffdf9;
    box-shadow: .75rem 0 2rem rgb(17 21 18 / 16%);
    transform: translateX(-100%);
    transition: transform 260ms ease-out;
}

.site-drawer[open] .site-drawer__panel {
    transform: translateX(0);
}

@starting-style {
    .site-drawer[open] {
        opacity: 0;
    }

    .site-drawer[open]::backdrop {
        background: transparent;
    }

    .site-drawer[open] .site-drawer__panel {
        transform: translateX(-100%);
    }
}

.site-drawer__header {
    position: sticky;
    z-index: 2;
    top: 0;
    display: flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: space-between;
    gap: 2rem;
    padding-bottom: 1.25rem;
    border-bottom: 1px solid #ddd8ce;
    background: #fffdf9;
}

.site-drawer__header p {
    margin: 0;
    color: #232723;
    font: 400 1.45rem/1 Georgia, "Times New Roman", serif;
    letter-spacing: .015em;
}

.site-drawer__header button {
    position: relative;
    width: 44px;
    height: 44px;
    border: 0;
    border-radius: 50%;
    background: #f5f1e9;
    color: #232723;
    cursor: pointer;
}

.site-drawer__header button span::before,
.site-drawer__header button span::after {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 17px;
    height: 1px;
    background: currentcolor;
    content: "";
    transform: translate(-50%, -50%) rotate(45deg);
}

.site-drawer__header button span::after {
    transform: translate(-50%, -50%) rotate(-45deg);
}

.site-drawer__navigation {
    display: flex;
    flex: 1 0 auto;
    flex-direction: column;
}

.site-drawer__primary-links,
.site-drawer__secondary-links,
.site-drawer__account-links {
    display: grid;
}

.site-drawer__primary-links {
    gap: .1rem;
    padding: 1rem 0;
    border-bottom: 1px solid #ddd8ce;
}

.site-drawer__primary-links a {
    display: flex;
    min-height: 44px;
    align-items: center;
    padding: .5rem 0;
    color: #232723;
    font: 400 clamp(1.25rem, 3vw, 1.55rem)/1.25 Georgia, "Times New Roman", serif;
    text-decoration: none;
}

.site-drawer__secondary-links {
    gap: .1rem;
    padding: .8rem 0;
    border-bottom: 1px solid #ddd8ce;
}

.site-drawer__secondary-links a,
.site-drawer__account-links a {
    display: flex;
    min-height: 44px;
    align-items: center;
    padding: .45rem 0;
    color: #425049;
    font: 600 .86rem/1.45 Inter, "Segoe UI", Arial, sans-serif;
    text-decoration: none;
}

.site-drawer__account {
    padding-top: 1.15rem;
}

.site-drawer__account > p {
    margin: 0 0 .5rem;
    color: #737972;
    font: 700 .67rem/1.4 Inter, "Segoe UI", Arial, sans-serif;
    letter-spacing: .16em;
    text-transform: uppercase;
}

.site-drawer__support {
    margin-top: auto;
    padding-top: clamp(1.75rem, 5vh, 3.5rem);
}

.site-drawer__support a {
    display: inline-flex;
    min-height: 44px;
    align-items: center;
    justify-content: center;
    padding: .55rem .9rem;
    border: 1px solid #aeb8b1;
    border-radius: 7px;
    color: #29483b;
    font: 700 .75rem/1.4 Inter, "Segoe UI", Arial, sans-serif;
    text-decoration: none;
}

.site-drawer__navigation a:is(:hover, :focus-visible) {
    color: #2f4138;
}

.site-drawer__support a:is(:hover, :focus-visible) {
    border-color: #29483b;
    background: #f5f1e9;
}

.site-drawer__navigation a:focus-visible {
    outline: 2px solid #173f32;
    outline-offset: 3px;
}

@media (max-width: 30rem) {
    .site-drawer__panel {
        width: min(92vw, 28rem);
        padding-inline: 1.25rem;
    }

    .site-drawer__support a {
        width: 100%;
    }
}

@media (max-width: 42rem) {
    .site-header .header-action--primary {
        display: none;
    }
}

@media (prefers-reduced-motion: reduce) {
    .site-header .account-control__chevron,
    .site-drawer,
    .site-drawer::backdrop,
    .site-drawer__panel {
        transition: none;
    }
}
