/* Site header (staging Elementor header template, post 638). */

.site-header {
    --justify: center;
    --align: center;
    --row-gap: 0px;
    --col-gap: 0px;
    --pt: 0px;
    --pr: 0px;
    --pb: 0px;
    --pl: 0px;
    border-bottom: 5px solid var(--bg-secondary);
    background-color: var(--bg-primary);
}

.header-row {
    --justify: flex-start;
    --row-gap: 0px;
    --col-gap: 0px;
    --pt: 5px;
    --pr: 5px;
    --pb: 5px;
    --pl: 5px;
}

.header-logo {
    display: block;
    flex: 0 1 auto;
    align-self: center;
    width: 50%;
    max-width: 50%;
    text-align: center;
}

/* Staging's site-logo image stays at its natural 313px, centred, until
   the column is narrower than that. */
.header-logo img {
    display: inline-block;
    width: auto;
    max-width: 100%;
    vertical-align: middle;
}

.header-right {
    --justify: flex-end;
    --row-gap: 0px;
    --col-gap: 0px;
    --pt: 20px;
    --pr: 0px;
    --pb: 0px;
    --pl: 0px;
    --min-height: 0px;
}

.header-contact {
    --justify: flex-end;
    --align: center;
    --row-gap: 0px;
    --col-gap: 15px;
    --pt: 0px;
    --pr: 0px;
    --pb: 0px;
    --pl: 0px;
}

.header-contact-link {
    font-size: 16px;
    font-weight: 600;
    line-height: 1.2em;
    color: var(--color-primary);
    transition: color 0.5s;
}

.header-contact-link:hover {
    color: var(--color-secondary);
}

.social-links {
    display: flex;
    align-items: center;
    gap: 10px;
    list-style: none;
    margin: 0;
    padding: 0;
}

.social-links a {
    display: block;
    color: var(--color-primary);
}

.social-links a:hover {
    color: var(--color-secondary);
}

.social-links svg {
    width: 20px;
    height: 20px;
}

.header-nav {
    align-self: flex-end;
    width: 100%;
    padding-top: 7px;
}

.header-nav ul {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 0 30px;
    list-style: none;
}

/* Hover: the text turns blue and a 2px underline fades in (Elementor
   "underline" pointer, fade animation). The current page gets neither. */
.header-nav a {
    position: relative;
    display: block;
    font-size: 20px;
    font-weight: 600;
    line-height: 1.2em;
    color: var(--text-secondary);
}

.header-nav a::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 2px;
    background-color: var(--color-primary);
    opacity: 0;
    transition: opacity 0.3s;
}

.header-nav a:hover {
    color: var(--color-primary);
}

.header-nav a:hover::after {
    opacity: 1;
}

.header-nav a[aria-current="page"]::after {
    display: none;
}

.header-nav a[aria-current="page"] {
    color: var(--color-secondary);
}

/* Phone menu: a <details> disclosure, so no JavaScript is needed. */
.mobile-nav {
    display: none;
}

.mobile-nav summary {
    display: flex;
    justify-content: center;
    width: fit-content;
    margin: 0 auto;
    padding: 0.25em;
    list-style: none;
    cursor: pointer;
    color: #33373d;
    font-size: 22px;
}

.mobile-nav summary::-webkit-details-marker {
    display: none;
}

.mobile-nav summary svg {
    width: 1em;
    height: 1em;
}

.mobile-nav-panel {
    position: absolute;
    left: 0;
    right: 0;
    z-index: 100;
    margin-top: 10px;
    background-color: var(--nd-white);
}

.mobile-nav-panel ul {
    list-style: none;
}

.mobile-nav-panel a {
    display: block;
    padding: 10px 0;
    font-size: var(--fs-secondary);
    font-weight: 600;
    line-height: 1.2em;
    text-align: center;
    color: var(--color-primary);
}

.mobile-nav-panel a:hover {
    color: var(--nd-white);
    background-color: var(--color-primary);
}

.mobile-nav-panel a[aria-current="page"] {
    color: var(--color-secondary);
}

@media (min-width: 768px) {
    .header-row { --width: 60%; }
    .header-right { --width: 100%; }
    .header-contact { --width: 100%; }
}

@media (max-width: 1024px) {
    .header-contact-link { font-size: 14px; }
    .header-contact .social-links { justify-content: center; }
}

@media (min-width: 768px) and (max-width: 1024px) {
    .header-row { --width: 80%; }
}

@media (max-width: 767px) {
    .header-logo {
        width: 100%;
        max-width: 100%;
        padding: 10px;
    }

    .header-nav {
        display: none;
    }

    .header-right {
        position: static;
    }

    .mobile-nav {
        display: block;
    }

    .header-nav a {
        font-size: 16px;
    }
}
