/* ---------- Palette ---------- */
:root {
    --navy: #0e2a4d;
    --navy-900: #0a1f3a;
    --navy-700: #1b3d66;
    --red: #c1121f;
    --red-700: #9e0f1a;
    --cream: #fbf7f2;
    --sky: #eaf1f8;
    --focus: #f2b705;
    --sans: "Source Sans 3", "Segoe UI", system-ui, -apple-system, sans-serif;
    --serif: "Source Serif 4", Georgia, "Times New Roman", serif;
    --bs-body-font-family: var(--sans);
    --bs-body-font-size: 1.0625rem;
    --bs-body-line-height: 1.6;
    --bs-body-color: #1d2a3a;
    --bs-body-color-rgb: 29, 42, 58;
    --bs-secondary-color: #5b6878;
    --bs-secondary-color-rgb: 91, 104, 120;
    --bs-border-color: #dde3ea;
    --bs-border-radius: 6px;
    --bs-border-radius-lg: 10px;
    --bs-link-color: var(--navy-700);
    --bs-link-color-rgb: 27, 61, 102;
    --bs-link-hover-color: var(--red);
    --bs-link-hover-color-rgb: 193, 18, 31;
    --bs-heading-color: var(--navy);
}

/* ---------- Base ---------- */
h1,
h2,
h3 {
    margin: 0;
    font-family: var(--serif);
    font-weight: 700;
    line-height: 1.15;
}

.container {
    max-width: 1200px;
    padding-inline: 1.25rem;
}

.container-narrow {
    max-width: 780px;
}

:focus-visible {
    outline: 3px solid var(--focus);
    outline-offset: 2px;
}

/* ---------- Utilities ---------- */
.font-serif {
    font-family: var(--serif);
}

.text-navy {
    color: var(--navy) !important;
}

.text-red {
    color: var(--red) !important;
}

.rule {
    width: 48px;
    height: 3px;
    background: var(--red);
}

.icon {
    width: 1em;
    height: 1em;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
}

/* ---------- Buttons ---------- */
.btn-serif {
    --bs-btn-font-family: var(--serif);
    --bs-btn-font-size: 1.0625rem;
    --bs-btn-font-weight: 600;
    --bs-btn-line-height: 1;
    --bs-btn-padding-y: .8rem;
    --bs-btn-padding-x: 1.4rem;
    --bs-btn-border-width: 0;
}

.btn-serif .icon {
    width: 1.1em;
    height: 1.1em;
    stroke-width: 2.25;
    transition: transform .15s ease;
}

.btn-navy {
    --bs-btn-color: #fff;
    --bs-btn-bg: var(--navy);
    --bs-btn-hover-color: #fff;
    --bs-btn-hover-bg: var(--navy-700);
    --bs-btn-active-color: #fff;
    --bs-btn-active-bg: var(--navy-700);
}

.btn-red {
    --bs-btn-color: #fff;
    --bs-btn-bg: var(--red);
    --bs-btn-hover-color: #fff;
    --bs-btn-hover-bg: var(--red-700);
    --bs-btn-active-color: #fff;
    --bs-btn-active-bg: var(--red-700);
    box-shadow: 0 6px 16px rgba(193, 18, 31, .25);
}

.btn-red:hover {
    transform: translateY(-1px);
}

.btn-red:hover .icon {
    transform: translateX(3px);
}

/* ---------- Pagination ---------- */
.pagination {
    --bs-pagination-color: var(--navy-700);
    --bs-pagination-hover-color: var(--red);
    --bs-pagination-focus-color: var(--red);
    --bs-pagination-active-bg: var(--red);
    --bs-pagination-active-border-color: var(--red);
}

/* ---------- Header ---------- */
.skip-link {
    background: var(--navy);
}

.site-header {
    background: rgba(255, 255, 255, .96);
    -webkit-backdrop-filter: saturate(1.4) blur(8px);
    backdrop-filter: saturate(1.4) blur(8px);
}

.site-header__inner {
    column-gap: 1rem;
    min-height: 72px;
}

.brand__name {
    font-size: clamp(1.5rem, 2.6vw, 2.15rem);
    line-height: 1;
    letter-spacing: -.01em;
    color: var(--navy);
}

.brand__tagline {
    font-size: clamp(.8rem, 1.1vw, .98rem);
    line-height: 1.2;
    color: var(--navy-700);
}

.site-nav a {
    font-size: .95rem;
    color: var(--navy);
}

.site-nav a[aria-current] {
    color: var(--red);
}

.site-nav a::after {
    content: "";
    position: absolute;
    inset: auto 0 0;
    height: 3px;
    background: var(--red);
    transform: scaleX(0);
    transition: transform .2s ease;
}

.powered-by {
    --bs-border-color: var(--navy);
    line-height: normal;
}

.powered-by__logo {
    --bs-border-color: var(--red);
    font-size: 1.6rem;
}

.powered-by__logo sup {
    font-size: .45em;
}

.powered-by__label {
    font-size: .8rem;
}

.powered-by__claim {
    font-size: .7rem;
}

.nav-toggle {
    width: 44px;
    height: 44px;
}

.nav-toggle span {
    height: 2px;
    margin-inline: 10px;
    background: var(--navy);
    transition: transform .2s ease, opacity .2s ease;
}

.nav-toggle[aria-expanded="true"] span:nth-child(1) {
    transform: translateY(6px) rotate(45deg);
}

.nav-toggle[aria-expanded="true"] span:nth-child(2) {
    opacity: 0;
}

.nav-toggle[aria-expanded="true"] span:nth-child(3) {
    transform: translateY(-6px) rotate(-45deg);
}

@media (min-width: 1200px) {
    .site-header__inner {
        column-gap: 2rem;
        min-height: 88px;
    }

    .site-nav a:hover::after,
    .site-nav a[aria-current]::after {
        transform: scaleX(1);
    }
}

@media (max-width: 1199.98px) {
    .site-nav a {
        border-top: 1px solid var(--bs-border-color);
    }
}

@media (max-width: 575.98px) {
    .site-header__inner {
        column-gap: 0;
    }
}

/* ---------- Content pages ---------- */
.page-hero {
    padding-block: clamp(2.5rem, 6vw, 4rem);
    background:
        radial-gradient(circle at 85% 20%, rgba(193, 18, 31, .25), transparent 45%),
        linear-gradient(120deg, var(--navy-900), var(--navy-700));
}

.page-hero .breadcrumb {
    --bs-breadcrumb-divider-color: rgba(255, 255, 255, .75);
    --bs-breadcrumb-item-active-color: rgba(255, 255, 255, .75);
}

.page-hero .breadcrumb a {
    color: rgba(255, 255, 255, .9);
    text-decoration: none;
}

.page-hero .breadcrumb a:hover {
    color: #fff;
    text-decoration: underline;
}

.page-hero__title {
    font-size: clamp(2rem, 4vw, 3rem);
}

.page-hero__intro {
    max-width: 44rem;
    color: rgba(255, 255, 255, .9);
}

.prose>*+* {
    margin-top: 1em;
}

.prose h2 {
    margin-top: 1.75em;
    font-size: 1.75rem;
}

.prose h2:first-child {
    margin-top: 0;
}

.prose h3 {
    margin-top: 1.5em;
    font-size: 1.35rem;
}

/* ---------- Footer ---------- */
.site-footer {
    font-size: .92rem;
    color: rgba(255, 255, 255, .85);
    background: var(--navy);
}

.site-footer a {
    color: rgba(255, 255, 255, .9);
    text-decoration: none;
}

.site-footer a:hover {
    color: #fff;
    text-decoration: underline;
}

@media (min-width: 576px) {
    .link-list li+li {
        padding-left: 1rem;
        border-left: 1px solid rgba(255, 255, 255, .35);
    }
}

@media (prefers-reduced-motion: reduce) {

    *,
    *::before,
    *::after {
        transition: none !important;
    }
}