:root {
    --brand: #168fca;
    --brand-dark: #0b6594;
    --brand-light: #e8f7ff;
    --accent: #00bfe8;
    --ink: #182b3a;
    --muted: #596b78;
    --line: #d9e6ed;
    --surface: #ffffff;
    --surface-soft: #f4f9fc;
    --warning: #8a4b08;
    --warning-bg: #fff7e8;
    --success: #176b45;
    --success-bg: #ecf9f2;
    --shadow: 0 10px 30px rgba(17, 71, 101, 0.09);
    --radius: 14px;
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    font-size: 100%;
    scroll-padding-top: 1rem;
}

body {
    margin: 0;
    min-width: 320px;
    color: var(--ink);
    background: #f6f9fb;
    font-family: Arial, Helvetica, sans-serif;
    font-size: 1rem;
    line-height: 1.65;
    overflow-wrap: anywhere;
}

img {
    display: block;
    max-width: 100%;
}

a {
    color: var(--brand-dark);
    text-decoration-thickness: 0.08em;
    text-underline-offset: 0.18em;
}

a:hover {
    color: #084b70;
}

a:focus-visible,
button:focus-visible {
    outline: 3px solid #ffbf47;
    outline-offset: 3px;
    border-radius: 4px;
}

.skip-link {
    position: fixed;
    z-index: 100;
    top: 0.75rem;
    left: 0.75rem;
    padding: 0.75rem 1rem;
    color: #fff;
    background: #102a3a;
    border-radius: 8px;
    transform: translateY(-180%);
}

.skip-link:focus {
    transform: translateY(0);
}

.site-header {
    color: #fff;
    background: linear-gradient(135deg, #168fca 0%, #00bfe8 100%);
    box-shadow: 0 3px 14px rgba(8, 78, 112, 0.18);
}

.site-header__inner {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    width: min(100% - 2rem, 1120px);
    margin-inline: auto;
    padding-block: 1rem;
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    width: fit-content;
    color: #fff;
    text-decoration: none;
}

.brand:hover {
    color: #fff;
}

.brand__logo {
    width: 3.25rem;
    height: 3.25rem;
    flex: 0 0 auto;
    border: 2px solid rgba(255, 255, 255, 0.75);
    border-radius: 50%;
    object-fit: cover;
}

.brand__text {
    display: grid;
    line-height: 1.2;
}

.brand__name {
    font-size: 1.18rem;
    font-weight: 800;
}

.brand__section {
    margin-top: 0.18rem;
    font-size: 0.82rem;
    opacity: 0.9;
}

.site-nav {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.site-nav a {
    display: inline-flex;
    min-height: 2.75rem;
    align-items: center;
    justify-content: center;
    padding: 0.55rem 0.9rem;
    color: #fff;
    border: 1px solid rgba(255, 255, 255, 0.6);
    border-radius: 999px;
    font-size: 0.94rem;
    font-weight: 700;
    text-decoration: none;
}

.site-nav a:hover {
    color: #083d5b;
    background: #fff;
}

.page-shell {
    width: min(100% - 2rem, 1120px);
    margin-inline: auto;
    padding-bottom: 4rem;
}

.breadcrumbs {
    padding-block: 1rem;
    color: var(--muted);
    font-size: 0.88rem;
}

.breadcrumbs ol {
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem 0.55rem;
    margin: 0;
    padding: 0;
    list-style: none;
}

.breadcrumbs li:not(:last-child)::after {
    margin-left: 0.55rem;
    color: #91a0a9;
    content: "/";
}

.breadcrumbs a {
    color: inherit;
}

.article-hero,
.index-hero,
.article-section,
.related,
.method,
.not-found {
    background: var(--surface);
    border: 1px solid rgba(192, 214, 225, 0.8);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
}

.article-hero,
.index-hero,
.not-found {
    padding: clamp(1.35rem, 4vw, 3rem);
}

.eyebrow {
    margin: 0 0 0.55rem;
    color: var(--brand-dark);
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

h1,
h2,
h3 {
    color: #143248;
    line-height: 1.18;
    text-wrap: balance;
}

h1 {
    max-width: 22ch;
    margin: 0;
    font-size: clamp(2rem, 7vw, 3.45rem);
    letter-spacing: -0.035em;
}

h2 {
    margin: 0 0 1rem;
    font-size: clamp(1.4rem, 4vw, 1.9rem);
    letter-spacing: -0.02em;
}

h3 {
    margin: 1.5rem 0 0.6rem;
    font-size: 1.15rem;
}

p,
ul,
ol,
dl {
    margin-top: 0;
}

.lead {
    max-width: 72ch;
    margin: 1rem 0 0;
    color: #2b4455;
    font-size: clamp(1.08rem, 2.6vw, 1.25rem);
    line-height: 1.6;
}

.answer-summary {
    max-width: 76ch;
    margin-top: 1.35rem;
    padding: 1rem 1.1rem;
    background: var(--brand-light);
    border-left: 4px solid var(--brand);
    border-radius: 0 10px 10px 0;
}

.answer-summary p:last-child,
.notice p:last-child,
.cta-panel p:last-child {
    margin-bottom: 0;
}

.verified-date {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem 0.85rem;
    align-items: center;
    margin-top: 1rem;
    color: var(--muted);
    font-size: 0.9rem;
}

.verified-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.25rem 0.65rem;
    color: var(--success);
    background: var(--success-bg);
    border-radius: 999px;
    font-weight: 700;
}

.cta-panel {
    margin-top: 1.4rem;
    padding: 1.2rem;
    color: #fff;
    background: linear-gradient(135deg, #106f9f 0%, #168fca 100%);
    border-radius: 12px;
}

.cta-panel h2,
.cta-panel h3 {
    margin: 0 0 0.45rem;
    color: #fff;
}

.cta-panel p {
    max-width: 66ch;
    margin-bottom: 0.9rem;
    color: #eefaff;
}

.cta-button {
    display: inline-flex;
    min-height: 3rem;
    align-items: center;
    justify-content: center;
    gap: 0.55rem;
    padding: 0.75rem 1rem;
    color: #0a4f73;
    background: #fff;
    border: 2px solid #fff;
    border-radius: 9px;
    font-weight: 800;
    line-height: 1.25;
    text-align: center;
    text-decoration: none;
}

.cta-button:hover {
    color: #fff;
    background: transparent;
}

.cta-button img {
    width: 1.4rem;
    height: 1.4rem;
    flex: 0 0 auto;
    filter: brightness(0) saturate(100%) invert(47%) sepia(93%) saturate(1647%) hue-rotate(164deg) brightness(91%) contrast(83%);
}

.cta-button:hover img {
    filter: none;
}

.article-layout {
    display: grid;
    gap: 1.25rem;
    margin-top: 1.25rem;
}

.table-of-contents,
.article-section,
.related,
.method {
    padding: clamp(1.2rem, 3vw, 2rem);
}

.table-of-contents {
    background: #eef7fb;
    border: 1px solid #cfe3ed;
    border-radius: var(--radius);
}

.table-of-contents strong {
    display: block;
    margin-bottom: 0.55rem;
    color: #143248;
}

.table-of-contents ol {
    margin: 0;
    padding-left: 1.25rem;
}

.table-of-contents li + li {
    margin-top: 0.35rem;
}

.article-content {
    display: grid;
    gap: 1.25rem;
    min-width: 0;
}

.article-section > :last-child {
    margin-bottom: 0;
}

.article-section {
    min-width: 0;
}

.article-section ul,
.article-section ol,
.method ul {
    padding-left: 1.3rem;
}

.article-section li + li,
.method li + li {
    margin-top: 0.55rem;
}

.steps {
    padding: 0;
    counter-reset: steps;
    list-style: none;
}

.steps > li {
    position: relative;
    min-height: 2.25rem;
    padding-left: 3rem;
    counter-increment: steps;
}

.steps > li::before {
    position: absolute;
    top: -0.1rem;
    left: 0;
    display: grid;
    width: 2.2rem;
    height: 2.2rem;
    place-items: center;
    color: #fff;
    background: var(--brand);
    border-radius: 50%;
    content: counter(steps);
    font-weight: 800;
}

.steps > li + li {
    margin-top: 1.2rem;
}

.checklist {
    padding: 0;
    list-style: none;
}

.checklist li {
    position: relative;
    padding-left: 1.8rem;
}

.checklist li::before {
    position: absolute;
    left: 0;
    color: var(--success);
    content: "✓";
    font-weight: 900;
}

.notice {
    margin: 1.1rem 0;
    padding: 1rem 1.1rem;
    background: var(--surface-soft);
    border: 1px solid var(--line);
    border-radius: 10px;
}

.notice strong:first-child {
    display: block;
    margin-bottom: 0.3rem;
    color: #143248;
}

.notice--warning {
    color: #5d390b;
    background: var(--warning-bg);
    border-color: #efcb91;
}

.notice--warning strong:first-child {
    color: var(--warning);
}

.notice--official {
    background: #edf8ff;
    border-color: #b9ddef;
}

.fact-grid,
.card-grid,
.related-grid {
    display: grid;
    gap: 1rem;
}

.fact-card,
.answer-card,
.related-card {
    min-width: 0;
    padding: 1.1rem;
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: 11px;
}

.fact-card h3,
.answer-card h2,
.related-card h3 {
    margin: 0 0 0.55rem;
}

.answer-card {
    display: flex;
    flex-direction: column;
    box-shadow: 0 6px 18px rgba(17, 71, 101, 0.06);
}

.answer-card p {
    flex: 1;
    color: var(--muted);
}

.answer-card__category {
    margin-bottom: 0.45rem;
    color: var(--brand-dark);
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

.answer-card__link,
.related-card a {
    font-weight: 800;
}

.table-wrap {
    width: 100%;
    max-width: 100%;
    overflow-x: auto;
    border: 1px solid var(--line);
    border-radius: 10px;
}

table {
    width: 100%;
    min-width: 38rem;
    border-collapse: collapse;
    font-size: 0.94rem;
}

th,
td {
    padding: 0.75rem;
    border-bottom: 1px solid var(--line);
    text-align: left;
    vertical-align: top;
}

th {
    color: #143248;
    background: #edf7fb;
}

tr:last-child td {
    border-bottom: 0;
}

.sources {
    padding-left: 1.25rem;
}

.sources li + li {
    margin-top: 0.8rem;
}

.source-label {
    display: inline-block;
    margin-left: 0.35rem;
    padding: 0.08rem 0.42rem;
    color: var(--success);
    background: var(--success-bg);
    border-radius: 999px;
    font-size: 0.72rem;
    font-weight: 800;
    text-transform: uppercase;
    vertical-align: 0.1em;
}

.related,
.method {
    margin-top: 1.25rem;
}

.related-card p {
    margin-bottom: 0;
    color: var(--muted);
    font-size: 0.94rem;
}

.index-hero h1 {
    max-width: 18ch;
}

.section-heading {
    margin: 2rem 0 1rem;
}

.section-heading p {
    max-width: 70ch;
    margin-bottom: 0;
    color: var(--muted);
}

.category-title {
    display: flex;
    gap: 0.6rem;
    align-items: center;
    margin: 2rem 0 0.85rem;
}

.category-title span {
    font-size: 1.35rem;
}

.category-title h2 {
    margin: 0;
}

.not-found {
    max-width: 760px;
    margin-inline: auto;
    text-align: center;
}

.not-found h1 {
    max-width: none;
}

.not-found .cta-button {
    color: #fff;
    background: var(--brand);
    border-color: var(--brand);
}

.not-found .cta-button:hover {
    color: var(--brand-dark);
    background: #fff;
}

.site-footer {
    color: #dcecf4;
    background: #12384e;
}

.site-footer__inner {
    display: grid;
    gap: 1rem;
    width: min(100% - 2rem, 1120px);
    margin-inline: auto;
    padding-block: 2rem;
}

.site-footer p {
    margin: 0;
}

.site-footer nav {
    display: flex;
    flex-wrap: wrap;
    gap: 0.55rem 1rem;
}

.site-footer a {
    color: #fff;
}

.footer-note {
    color: #afcbd9;
    font-size: 0.86rem;
}

@media (min-width: 640px) {
    .site-header__inner,
    .site-footer__inner {
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
    }

    .site-header__inner {
        display: flex;
    }

    .site-footer__inner {
        grid-template-columns: 1fr auto;
    }

    .fact-grid,
    .related-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .card-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (min-width: 900px) {
    .article-layout {
        grid-template-columns: minmax(0, 1fr) 17rem;
        align-items: start;
    }

    .article-content {
        grid-column: 1;
        grid-row: 1;
    }

    .table-of-contents {
        position: sticky;
        top: 1rem;
        grid-column: 2;
        grid-row: 1;
    }

    .card-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (prefers-reduced-motion: no-preference) {
    html {
        scroll-behavior: smooth;
    }

    .cta-button,
    .site-nav a {
        transition: color 150ms ease, background-color 150ms ease, transform 150ms ease;
    }

    .cta-button:hover {
        transform: translateY(-1px);
    }
}

@media print {
    body {
        color: #000;
        background: #fff;
    }

    .skip-link,
    .site-nav,
    .cta-panel,
    .site-footer,
    .table-of-contents {
        display: none;
    }

    .page-shell {
        width: 100%;
    }

    .article-hero,
    .article-section,
    .related,
    .method {
        border: 0;
        box-shadow: none;
    }
}
