:root {
    --bbt-blue: #052785;
    --bbt-blue-mid: #052785;
    --bbt-blue-dark: #060166;
    --bbt-blue-light: #6495ED;
    --bbt-blue-pale: #f1f4ff;

    /* Compatibility aliases for the existing public pages. */
    --brand-aqua: #6495ED !important;
    --brand-teal: #052785 !important;
    --brand-dark: #060166 !important;
    --teal-dark: #052785 !important;
    --teal: #052785 !important;
    --teal-light: #6495ED !important;
    --teal-pale: #f1f4ff !important;
    --ink: #060166 !important;
    --muted: #52637d !important;
    --border: #c9d6f2 !important;
    --background: #f7f9ff !important;
}

.page h1,
.page h2,
.page h3,
.contact-page__card h1 {
    color: #052785 !important;
}

.site-header h1,
.site-header h2,
.site-header h3 {
    color: #fff !important;
}

.public-nav,
.site-header,
body:has(#map) > header {
    background: linear-gradient(120deg, #6495ED 0%, #052785 50%, #060166 100%) !important;
}

.public-nav__link[aria-current="page"] {
    color: #060166 !important;
    background: #6495ED !important;
}

.public-nav__link--button {
    appearance: none;
    border: 0;
    background: transparent;
    cursor: pointer;
}

body:has(#map) .eyebrow {
    color: #eef3ff !important;
}

body:has(#map) .row input,
body:has(#map) .filters select,
body:has(#map) .mobile-map-menu .row input,
body:has(#map) .mobile-menu-filters select {
    border-color: #b9c9ee !important;
}

body:has(#map) .close,
body:has(#map) .stop-direction,
body:has(#map) .mobile-how-link {
    background: #f1f4ff !important;
}

body:has(#map) .mobile-how-link:hover,
body:has(#map) .mobile-how-link:focus-visible {
    background: #e3eaff !important;
}

body:has(#map) .panel {
    border-top-color: #052785 !important;
}

body:has(#map) .panel,
body:has(#map) .stop-panel-scroll {
    scrollbar-color: #6495ED #f1f4ff !important;
}

body:has(#map) .panel::-webkit-scrollbar-track,
body:has(#map) .stop-panel-scroll::-webkit-scrollbar-track {
    background: #f1f4ff !important;
}

body:has(#map) .panel::-webkit-scrollbar-thumb,
body:has(#map) .stop-panel-scroll::-webkit-scrollbar-thumb {
    background: #6495ED !important;
    border-color: #f1f4ff !important;
}

body:has(#map) .refresh-track {
    background: #f1f4ff !important;
}

body:has(#map) .mobile-map-menu {
    border-color: #c9d6f2 !important;
    box-shadow: 0 14px 34px rgba(6, 1, 102, .22) !important;
}

.contact-dialog {
    width: min(620px, calc(100vw - 28px));
    max-height: min(760px, calc(100vh - 28px));
    padding: 0;
    overflow: hidden;
    border: 1px solid #c9d6f2;
    border-radius: 18px;
    color: #060166;
    background: #fff;
    box-shadow: 0 24px 70px rgba(6, 1, 102, .28);
}

.contact-dialog::backdrop {
    background: rgba(6, 1, 102, .62);
    backdrop-filter: blur(3px);
}

.contact-dialog__header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 18px;
    padding: 22px 24px 18px;
    color: #fff;
    background: linear-gradient(120deg, #6495ED 0%, #052785 50%, #060166 100%);
}

.contact-dialog__header h2 {
    margin: 0;
    color: #fff;
    font-size: 1.35rem;
}

.contact-dialog__header p {
    margin: 5px 0 0;
    color: rgba(255, 255, 255, .88);
    font-size: .92rem;
}

.contact-dialog__close {
    flex: 0 0 auto;
    width: 36px;
    height: 36px;
    border: 1px solid rgba(255, 255, 255, .3);
    border-radius: 50%;
    color: #fff;
    background: rgba(255, 255, 255, .12);
    font-size: 1.3rem;
    line-height: 1;
    cursor: pointer;
}

.contact-dialog__body {
    max-height: calc(100vh - 150px);
    padding: 22px 24px 24px;
    overflow-y: auto;
}

.contact-form__grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
}

.contact-form__field {
    display: grid;
    gap: 6px;
}

.contact-form__field--full {
    grid-column: 1 / -1;
}

.contact-form label {
    color: #052785;
    font-size: .83rem;
    font-weight: 800;
}

.contact-form input,
.contact-form select,
.contact-form textarea {
    width: 100%;
    border: 1px solid #b9c9ee;
    border-radius: 10px;
    padding: 10px 12px;
    color: #060166;
    background: #fff;
    font: inherit;
}

.contact-form textarea {
    min-height: 150px;
    resize: vertical;
}

.contact-form input:focus,
.contact-form select:focus,
.contact-form textarea:focus {
    border-color: #052785;
    outline: none;
    box-shadow: 0 0 0 3px rgba(5, 39, 133, .16);
}

.contact-form__error {
    min-height: 1em;
    color: #b42318;
    font-size: .78rem;
}

.contact-form__status {
    display: none;
    margin: 0 0 16px;
    padding: 11px 13px;
    border-radius: 10px;
    font-size: .9rem;
}

.contact-form__status.is-visible {
    display: block;
}

.contact-form__status.is-success {
    color: #14532d;
    background: #dcfce7;
}

.contact-form__status.is-error {
    color: #7f1d1d;
    background: #fee2e2;
}

.contact-form__actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    margin-top: 18px;
}

.contact-form__note {
    margin: 0;
    color: #64748b;
    font-size: .78rem;
    line-height: 1.4;
}

.contact-form__submit {
    flex: 0 0 auto;
    min-width: 120px;
    border: 0;
    border-radius: 10px;
    padding: 10px 16px;
    color: #fff;
    background: #052785;
    font: inherit;
    font-weight: 800;
    cursor: pointer;
}

.contact-form__submit:hover,
.contact-form__submit:focus-visible {
    background: #060166;
}

.contact-form__submit:disabled {
    opacity: .65;
    cursor: wait;
}

.contact-honeypot {
    position: absolute !important;
    left: -10000px !important;
    width: 1px !important;
    height: 1px !important;
    overflow: hidden !important;
}

.contact-page {
    width: min(760px, calc(100% - 32px));
    margin: 34px auto 60px;
}

.contact-page__card {
    padding: clamp(22px, 5vw, 36px);
    border: 1px solid #c9d6f2;
    border-radius: 18px;
    background: #fff;
    box-shadow: 0 10px 28px rgba(6, 1, 102, .08);
}

.contact-page__card h1 {
    margin: 0 0 8px;
    color: #052785;
}

.contact-page__intro {
    margin: 0 0 24px;
    color: #52637d;
}

@media (max-width: 620px) {
    .contact-form__grid {
        grid-template-columns: 1fr;
    }

    .contact-form__field--full {
        grid-column: auto;
    }

    .contact-form__actions {
        align-items: stretch;
        flex-direction: column;
    }

    .contact-form__submit {
        width: 100%;
    }
}
