/* ==========================================================================
   Spain Home Guard — design system
   Direction: modern safety. Charcoal, high-visibility "butane" orange,
   cool greys, one geometric sans (Plus Jakarta Sans, loaded in _Layout.cshtml).
   The --cis-* names are kept from the template so existing rules still apply.
   ========================================================================== */

:root {
    /* Charcoal — solid, dependable */
    --cis-primary: #1e2a36;
    --cis-primary-dark: #111827;
    --cis-primary-deep: #0b1220;

    /* Safety orange — calls to action, rules, ticks, focus */
    --cis-accent: #e4692a;
    --cis-accent-dark: #b84d17;   /* AA on white and grey for text and white-on-orange buttons */
    --cis-accent-deep: #9a3f12;
    --cis-accent-soft: #fdf0e8;

    --cis-ink: #111827;      /* headings */
    --cis-text: #374151;     /* body */
    --cis-muted: #5f6b7a;    /* secondary text */

    --cis-bg-soft: #f4f5f7;  /* cool grey */
    --cis-border: #e5e7eb;
    --cis-border-strong: #d1d5db;

    --cis-shadow-sm: 0 1px 2px rgba(17, 24, 39, .05);
    --cis-shadow-md: 0 1px 2px rgba(17, 24, 39, .05), 0 10px 30px rgba(17, 24, 39, .07);

    --cis-radius: 12px;
    --cis-radius-sm: 8px;

    --cis-display: "Plus Jakarta Sans", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    --cis-body: "Plus Jakarta Sans", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;

    /* Bootstrap overrides */
    --bs-body-font-family: var(--cis-body);
    --bs-link-color: var(--cis-primary);
    --bs-link-color-rgb: 30, 42, 54;
    --bs-link-hover-color: var(--cis-primary-dark);
    --bs-link-hover-color-rgb: 17, 24, 39;
}

html {
    min-height: 100%;
    scroll-behavior: smooth;
}

body {
    margin: 0;
    color: var(--cis-text);
    font-family: var(--cis-body);
    font-size: 1.0625rem;
    line-height: 1.7;
    background: #fff;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
    
}

main { width: 100%; }

h1, h2, h3, h4 {
    color: var(--cis-ink);
    font-family: var(--cis-display);
    font-weight: 800;
    letter-spacing: -0.025em;
}

a { text-underline-offset: .18em; text-decoration-thickness: 1px; }

::selection { background: #fbd9c4; color: var(--cis-ink); }

/* --------------------------------------------------------------- Header / nav */

.site-header {
    position: sticky;
    top: 0;
    z-index: 1020;
}

.site-topbar {
    background: var(--cis-primary-dark);
    color: rgba(255, 255, 255, .78);
    font-size: .78rem;
    letter-spacing: .02em;
    padding: .4rem 0;
}

.site-topbar .container {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
}

.site-topbar a { color: #fff; text-decoration: none; }
.site-topbar a:hover { text-decoration: underline; }

.site-topbar-sep { color: var(--cis-accent); margin: 0 .5rem; }

.site-header .navbar {
    background: rgba(255, 255, 255, .97) !important;
    border-bottom: 1px solid var(--cis-border) !important;
    padding-top: .85rem;
    padding-bottom: .85rem;
}

/* Brand lock-up: shield mark + bold wordmark ("Guard" in orange) + small-caps descriptor */
.navbar-brand {
    display: inline-flex;
    align-items: center;
    gap: .75rem;
    color: var(--cis-primary-dark) !important;
    margin-right: 2rem;
}

.brand-mark {
    width: 2.5rem;
    height: 2.5rem;
    flex: 0 0 auto;
}

.brand-text {
    display: flex;
    flex-direction: column;
    line-height: 1.05;
}

.brand-name {
    font-family: var(--cis-display);
    font-weight: 800;
    font-size: 1.3rem;
    letter-spacing: -0.025em;
    color: var(--cis-primary-dark);
}

.brand-name b { color: var(--cis-accent-dark); font-weight: 800; }

.brand-tagline {
    font-family: var(--cis-body);
    font-size: .62rem;
    font-weight: 600;
    letter-spacing: .16em;
    text-transform: uppercase;
    color: var(--cis-muted);
    margin-top: .3rem;
}

.nav-link {
    font-weight: 500;
    font-size: .95rem;
    color: var(--cis-text);
    position: relative;
}

.navbar-nav .nav-link::after {
    content: "";
    position: absolute;
    left: .5rem;
    right: .5rem;
    bottom: .2rem;
    height: 1px;
    background: var(--cis-primary-dark);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform .2s ease;
}

.navbar-nav .nav-link:hover,
.navbar-nav .nav-link:focus { color: var(--cis-primary-dark); }

.navbar-nav .nav-link:hover::after,
.navbar-nav .nav-link.active::after { transform: scaleX(1); }

.navbar-nav .nav-link.active { color: var(--cis-primary-dark); font-weight: 600; }

.navbar-nav .nav-link.btn::after { display: none; }

/* Menu groups: keep each heading on one line, and give dropdown headings back Bootstrap's arrow
   (the underline above uses the same ::after). */
.navbar-nav .nav-link,
.navbar-nav .btn { white-space: nowrap; }

.navbar-nav .nav-link.dropdown-toggle::after {
    content: "";
    position: static;
    display: inline-block;
    width: 0;
    height: 0;
    margin-left: .35em;
    vertical-align: .15em;
    background: none;
    transform: none;
    transition: none;
    border-top: .3em solid;
    border-right: .3em solid transparent;
    border-left: .3em solid transparent;
    border-bottom: 0;
}

.navbar-nav .dropdown-toggle.active { color: var(--cis-primary-dark); font-weight: 600; }

.navbar .dropdown-menu {
    border: 1px solid var(--cis-border);
    border-radius: var(--cis-radius);
    box-shadow: var(--cis-shadow-md);
    padding: .5rem 0;
    min-width: 15rem;
}

.navbar .dropdown-item {
    font-size: .95rem;
    color: var(--cis-text);
    padding: .4rem 1.1rem;
}

.navbar .dropdown-item:hover,
.navbar .dropdown-item:focus { background: var(--cis-accent-soft); color: var(--cis-primary-dark); }

.navbar .dropdown-header {
    font-size: .7rem;
    font-weight: 600;
    letter-spacing: .12em;
    text-transform: uppercase;
    color: var(--cis-accent-dark);
    padding: .5rem 1.1rem .25rem;
}

@media (max-width: 991.98px) {
    .navbar .dropdown-menu { border: 0; box-shadow: none; padding-top: 0; }
    .navbar .dropdown-item { padding-left: 1.5rem; }
}

/* --------------------------------------------------------------- Buttons */

.btn {
    border-radius: var(--cis-radius-sm);
    font-weight: 600;
    letter-spacing: .01em;
    padding: .55rem 1.15rem;
    transition: background-color .15s ease, border-color .15s ease, color .15s ease;
}

.btn-lg { padding: .8rem 1.6rem; font-size: 1rem; }

.btn-primary {
    background-color: var(--cis-accent-dark);
    border-color: var(--cis-accent-dark);
    color: #fff;
}

.btn-primary:hover,
.btn-primary:focus,
.btn-primary:active {
    background-color: var(--cis-accent-deep) !important;
    border-color: var(--cis-accent-deep) !important;
    color: #fff;
}

.btn-outline-primary {
    color: var(--cis-primary-dark);
    border-color: var(--cis-primary-dark);
    background: transparent;
}

.btn-outline-primary:hover,
.btn-outline-primary:focus,
.btn-outline-primary:active {
    background-color: var(--cis-primary-dark) !important;
    border-color: var(--cis-primary-dark) !important;
    color: #fff !important;
}

/* light button used on dark CTA band */
.cta-band .btn-light {
    background: #fff;
    border-color: #fff;
    color: var(--cis-primary-dark);
    font-weight: 600;
}
.cta-band .btn-light:hover,
.cta-band .btn-light:focus {
    background: var(--cis-accent-soft);
    border-color: var(--cis-accent-soft);
}

/* --------------------------------------------------------------- Eyebrow label */

.eyebrow,
.hero .text-uppercase {
    display: inline-flex;
    align-items: center;
    gap: .7rem;
    font-family: var(--cis-body);
    font-size: .74rem !important;
    font-weight: 600 !important;
    letter-spacing: .18em;
    text-transform: uppercase;
    color: var(--cis-accent-dark) !important;
    margin-bottom: 1.25rem !important;
}

.eyebrow::before,
.hero .text-uppercase::before {
    content: "";
    width: 2rem;
    height: 1px;
    background: var(--cis-accent);
}

/* --------------------------------------------------------------- Hero */

.hero {
    position: relative;
    background: var(--cis-bg-soft);
    padding: 5.5rem 0 5rem;
    border-bottom: 1px solid var(--cis-border);
    overflow: hidden;
}

/* fine brass rule at the very top of the hero */
.hero::before {
    content: "";
    position: absolute;
    inset-inline: 0;
    top: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--cis-primary-dark) 0 70%, var(--cis-accent) 70% 100%);
}

.hero h1 {
    font-family: var(--cis-display);
    font-size: clamp(2.2rem, 4.6vw, 3.5rem);
    line-height: 1.1;
    font-weight: 800;
    color: var(--cis-primary-dark);
    margin-bottom: 1.4rem;
    letter-spacing: -0.03em;
    max-width: 22ch;
}

.hero .lead {
    font-size: 1.18rem;
    line-height: 1.65;
    color: var(--cis-muted);
    max-width: 40rem;
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: .9rem;
    margin-top: 2.25rem;
}

/* Header photo (see Models/SiteImages.cs and _HeroPhoto.cshtml): a background to the .hero section.
   Phones: a band across the top that fades down into the ivory. Large screens: the right-hand side, fading left behind the text. */
.hero-photo {
    position: absolute;
    inset: 0 0 auto 0;
    height: 240px;
    max-width: none;
    margin: 0;
    padding: 0;
    z-index: 0;
    pointer-events: none;
}

.hero-photo img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: var(--photo-position, center);
    -webkit-mask-image: linear-gradient(to bottom, #000 55%, transparent 100%);
    mask-image: linear-gradient(to bottom, #000 55%, transparent 100%);
}

/* Room for the band above the text, and the text above the photo */
.hero:has(.hero-photo) {
    padding-top: calc(240px + 1rem);
}

.hero:has(.hero-photo) .row > :not(.hero-photo) {
    position: relative;
    z-index: 1;
}

.hero:has(.hero-photo)::before {
    z-index: 2;
}

/* Caption and credit: small, in the photo's top-right corner */
.hero-photo figcaption {
    position: absolute;
    top: .4rem;
    right: .4rem;
    max-width: calc(100% - .8rem);
    padding: .05rem .3rem;
    border-radius: var(--cis-radius-sm);
    background: rgba(17, 24, 39, .3);
    color: rgba(255, 255, 255, .8);
    font-size: .55rem;
    line-height: 1.3;
    text-align: right;
    pointer-events: auto;
}

.photo-credit {
    white-space: nowrap;
}

@media (min-width: 992px) {
    .hero-photo {
        inset: 0 0 0 auto;
        width: 52%;
        height: auto;
    }

    .hero-photo img {
        -webkit-mask-image: linear-gradient(to right, transparent 0, rgba(0, 0, 0, .35) 18%, #000 45%);
        mask-image: linear-gradient(to right, transparent 0, rgba(0, 0, 0, .35) 18%, #000 45%);
    }

    .hero:has(.hero-photo) {
        padding-top: 5.5rem;
    }

    .hero-photo figcaption {
        top: auto;
        bottom: .4rem;
        right: .4rem;
    }
}

/* Photo credits page */
.credits-table img {
    width: 120px;
    height: 90px;
    object-fit: cover;
    border-radius: var(--cis-radius-sm);
}

.hero-panel {
    background: #fff;
    border: 1px solid var(--cis-border);
    border-top: 3px solid var(--cis-primary-dark);
    border-radius: var(--cis-radius);
    box-shadow: var(--cis-shadow-md);
    padding: 1.6rem 1.6rem 1.4rem;
}

.hero-panel h2 {
    font-size: 1.15rem;
    color: var(--cis-ink);
    margin-bottom: 1rem;
}

.hero-panel .hero-panel-foot {
    margin-top: 1.1rem;
    padding-top: 1.1rem;
    border-top: 1px solid var(--cis-border);
    font-size: .9rem;
    color: var(--cis-muted);
}

/* --------------------------------------------------------------- Sections */

.content-section { padding: 5rem 0; }

.content-section-soft {
    background: var(--cis-bg-soft);
    border-top: 1px solid var(--cis-border);
    border-bottom: 1px solid var(--cis-border);
    padding: 5rem 0;
}

.section-heading {
    max-width: 44rem;
    margin-bottom: 2.75rem;
}

.section-heading h2 {
    font-size: clamp(1.75rem, 3vw, 2.35rem);
    color: var(--cis-primary-dark);
    letter-spacing: -0.015em;
    padding-bottom: 1rem;
    position: relative;
}

.section-heading h2::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: 0;
    width: 3rem;
    height: 2px;
    background: var(--cis-accent);
}

.section-heading p { color: var(--cis-muted); font-size: 1.1rem; margin-top: 1rem; }

.content-section h2,
.content-section-soft h2 {
    color: var(--cis-primary-dark);
}

/* --------------------------------------------------------------- Cards */

.service-card {
    height: 100%;
    border: 1px solid var(--cis-border);
    border-radius: var(--cis-radius);
    padding: 1.75rem;
    background: #fff;
    transition: border-color .2s ease, box-shadow .2s ease;
    position: relative;
}

/* cards stacked in a sidebar column must not each stretch to the column height */
.service-card:not(:only-child) { height: auto; }

.service-card:has(a):hover {
    border-color: var(--cis-border-strong);
    box-shadow: var(--cis-shadow-md);
}

.service-card h3 {
    font-size: 1.28rem;
    color: var(--cis-primary-dark);
    margin-bottom: .65rem;
    line-height: 1.3;
}

.service-card p { color: var(--cis-muted); }

.service-card > a:not(.btn) {
    display: inline-flex;
    align-items: center;
    gap: .4rem;
    margin-top: .4rem;
    font-weight: 600;
    font-size: .95rem;
    color: var(--cis-primary-dark);
    text-decoration: none;
    border-bottom: 1px solid var(--cis-accent);
    padding-bottom: .1rem;
}

.service-card > a:not(.btn)::after {
    content: "→";
    color: var(--cis-accent-dark);
    transition: transform .15s ease;
}

.service-card > a:not(.btn):hover { color: var(--cis-primary-deep); }
.service-card > a:not(.btn):hover::after { transform: translateX(3px); }

/* --------------------------------------------------------------- Numbered steps */

.step-grid { counter-reset: step; }

.step-card h3 {
    display: flex;
    align-items: baseline;
    gap: .75rem;
}

.step-card h3::before {
    counter-increment: step;
    content: counter(step, decimal-leading-zero);
    flex: 0 0 auto;
    font-family: var(--cis-display);
    font-weight: 600;
    font-size: 1rem;
    color: var(--cis-accent-dark);
    min-width: 1.9rem;
}

.step-card p { padding-left: 2.65rem; }

/* --------------------------------------------------------------- Check list */

.check-list { list-style: none; padding-left: 0; margin-bottom: 0; }

.check-list li {
    position: relative;
    padding-left: 1.9rem;
    margin-bottom: .85rem;
    line-height: 1.55;
}

.check-list li::before {
    content: "";
    position: absolute;
    left: .15rem;
    top: .38em;
    width: .9rem;
    height: .5rem;
    border-left: 2px solid var(--cis-accent);
    border-bottom: 2px solid var(--cis-accent);
    transform: rotate(-45deg);
}

/* --------------------------------------------------------------- Notice box */

.notice-box {
    border: 1px solid var(--cis-border);
    border-left: 3px solid var(--cis-primary-dark);
    background: #fff;
    padding: 1.25rem 1.5rem;
    border-radius: var(--cis-radius-sm);
    color: var(--cis-text);
    font-size: .98rem;
}

.notice-box strong { color: var(--cis-primary-dark); }

.content-section-soft .notice-box { background: #fff; }
.content-section .notice-box { background: var(--cis-bg-soft); }

/* --------------------------------------------------------------- CTA band */

.cta-band {
    background: var(--cis-primary-dark);
    color: #fff;
    padding: 4rem 0;
    position: relative;
}

.cta-band::before {
    content: "";
    position: absolute;
    inset-inline: 0;
    top: 0;
    height: 3px;
    background: var(--cis-accent);
}

.cta-band h2 {
    color: #fff;
    letter-spacing: -0.015em;
}

.cta-band p { color: rgba(255, 255, 255, .8); font-size: 1.1rem; }

/* --------------------------------------------------------------- Forms */

.insurance-form { max-width: 44rem; }

.form-label { font-weight: 600; font-size: .92rem; color: var(--cis-ink); }

.form-control, .form-select {
    border-radius: var(--cis-radius-sm);
    border-color: var(--cis-border-strong);
    padding: .65rem .85rem;
}

.form-control:focus, .form-select:focus {
    border-color: var(--cis-primary);
    box-shadow: 0 0 0 .2rem rgba(30, 42, 54, .14);
}

.form-check-input:checked {
    background-color: var(--cis-primary-dark);
    border-color: var(--cis-primary-dark);
}

/* Lead forms in steps (form-steps.js adds .is-stepped; without it every step shows) */

.form-step { margin-bottom: 2rem; }
.form-step:focus { outline: none; }
.form-step legend { color: var(--cis-ink); }

.form-steps.is-stepped .form-step { display: none; margin-bottom: 0; }
.form-steps.is-stepped .form-step.is-active { display: block; }

.step-progress,
.step-nav .step-back,
.step-nav [data-step-next] { display: none; }

.form-steps.is-stepped .step-progress { display: flex; }
.form-steps.is-stepped .step-nav .step-back,
.form-steps.is-stepped .step-nav [data-step-next] { display: inline-block; }

.step-progress {
    align-items: center;
    gap: .85rem;
    margin-bottom: 1.5rem;
    font-size: .85rem;
    font-weight: 600;
    color: var(--cis-muted);
}

.step-progress-text { white-space: nowrap; }

.step-progress-bar {
    flex: 1 1 auto;
    height: 6px;
    border-radius: 3px;
    background: var(--cis-border);
    overflow: hidden;
}

.step-progress-fill {
    display: block;
    height: 100%;
    width: 33%;
    background: var(--cis-primary);
    transition: width .25s ease;
}

.step-nav {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-top: 1.75rem;
}

.step-nav .btn-primary { margin-left: auto; }
.form-steps:not(.is-stepped) .step-nav .btn-primary { margin-left: 0; }

.step-back { color: var(--cis-primary); font-weight: 600; text-decoration: none; padding-left: 0; }
.step-back:hover { text-decoration: underline; }

.choice-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(14rem, 1fr));
    gap: .6rem;
}

/* Short answers: tiles keep their natural size and wrap as needed */
.choice-grid-compact { display: flex; flex-wrap: wrap; }
.choice-grid-compact .choice-tile { flex: 0 0 auto; justify-content: center; white-space: nowrap; padding-left: 1.1rem; padding-right: 1.1rem; }

.choice-tile {
    display: flex;
    align-items: center;
    min-height: 3.1rem;
    padding: .6rem .9rem;
    border: 1px solid var(--cis-border-strong);
    border-radius: var(--cis-radius-sm);
    background: #fff;
    color: var(--cis-text);
    line-height: 1.3;
    cursor: pointer;
    transition: border-color .15s ease, background-color .15s ease;
}

.choice-tile:hover { border-color: var(--cis-primary); }

.choice-tile-detailed { flex-direction: column; align-items: flex-start; justify-content: flex-start; gap: .15rem; padding-top: .75rem; }
.choice-tile-detailed strong { color: var(--cis-ink); }
.choice-tile-blurb { font-size: .85rem; color: var(--cis-muted); line-height: 1.35; }
.btn-check:checked + .choice-tile-detailed { font-weight: 400; }

.btn-check:checked + .choice-tile {
    border-color: var(--cis-primary-dark);
    background: #eef0f3;
    box-shadow: inset 0 0 0 1px var(--cis-primary-dark);
    color: var(--cis-ink);
    font-weight: 600;
}

.btn-check:focus-visible + .choice-tile { box-shadow: 0 0 0 .2rem rgba(30, 42, 54, .25); }

.choice-grid:has(.input-validation-error) .choice-tile { border-color: #dc3545; }

/* --------------------------------------------------------------- Footer */

.footer {
    background: var(--cis-primary-deep);
    color: rgba(255, 255, 255, .7);
    padding: 3.5rem 0 2rem;
    font-size: .95rem;
}

.footer a { color: #fff; }

.footer-brand .navbar-brand { margin-bottom: .5rem; }
.footer-brand .brand-name { color: #fff; }
.footer-brand .brand-name b { color: var(--cis-accent); }
.footer-brand .brand-tagline { color: rgba(255, 255, 255, .6); }

.footer-brand p {
    margin: .75rem 0 0;
    max-width: 24rem;
    color: rgba(255, 255, 255, .65);
}

.footer-heading {
    font-family: var(--cis-body);
    font-size: .74rem;
    font-weight: 600;
    letter-spacing: .16em;
    text-transform: uppercase;
    color: var(--cis-accent);
    margin-bottom: 1rem;
}

.footer-nav {
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-nav li { margin-bottom: .55rem; }

.footer-nav a {
    color: rgba(255, 255, 255, .82);
    text-decoration: none;
}

.footer-nav a:hover,
.footer-nav a:focus { color: #fff; text-decoration: underline; }

.footer-base {
    margin-top: 2.5rem;
    padding-top: 1.25rem;
    border-top: 1px solid rgba(255, 255, 255, .1);
    color: rgba(255, 255, 255, .5);
    line-height: 1.6;
}

/* --------------------------------------------------------------- A11y / motion */

a:focus-visible,
.btn:focus-visible,
.nav-link:focus-visible {
    outline: 2px solid var(--cis-accent);
    outline-offset: 2px;
}

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    *, *::before, *::after {
        transition: none !important;
        animation: none !important;
    }
}

@media (max-width: 991.98px) {
    .hero { padding: 3.5rem 0 3rem; }
    .content-section, .content-section-soft { padding: 3.25rem 0; }
    .site-topbar-secondary { display: none; }
}

@media (max-width: 575.98px) {
    .site-topbar { display: none; }
    .brand-tagline { display: none; }
    .brand-name { font-size: 1.2rem; }
    .brand-mark { width: 2.2rem; height: 2.2rem; }
}

/* --------------------------------------------------------------- Calculator */

.calc-card {
    background: #fff;
    border: 1px solid var(--cis-border);
    border-top: 3px solid var(--cis-primary-dark);
    border-radius: var(--cis-radius);
    box-shadow: var(--cis-shadow-md);
    padding: 1.75rem;
}

.calc-card h2 { font-size: 1.4rem; }

.calc-results table { width: 100%; }

.calc-results td {
    padding: .6rem 0;
    border-bottom: 1px solid var(--cis-border);
    vertical-align: top;
}

.calc-results td:last-child { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }

.calc-results .calc-total td {
    font-weight: 700;
    color: var(--cis-primary-dark);
    border-top: 2px solid var(--cis-primary-dark);
    border-bottom: 0;
    padding-top: .9rem;
    font-size: 1.15rem;
}

.calc-results .calc-note { display: block; font-size: .85rem; color: var(--cis-muted); }

.fx-highlight {
    background: var(--cis-accent-soft);
    border: 1px solid #f6c9ad;
    border-left: 3px solid var(--cis-accent);
    border-radius: var(--cis-radius-sm);
    padding: 1.1rem 1.25rem;
    margin-top: 1.25rem;
}

.fx-highlight strong { color: var(--cis-accent-dark); }

/* --------------------------------------------------------------- Glossary */

.glossary-letters { display: flex; flex-wrap: wrap; gap: .35rem; }
.glossary-letters a { display: inline-block; min-width: 2rem; padding: .25rem .5rem; text-align: center; border: 1px solid var(--cis-border); border-radius: var(--cis-radius-sm); text-decoration: none; font-weight: 600; }
.glossary-letters a:hover { background: var(--cis-accent-soft); }
.glossary .glossary-letter { margin-top: 2rem; padding-bottom: .25rem; border-bottom: 1px solid var(--cis-border); }
.glossary dt { margin-top: 1.25rem; font-weight: 700; color: var(--cis-ink); scroll-margin-top: 6rem; }
.glossary dt:target { background: var(--cis-accent-soft); }
.glossary-en { font-weight: 400; color: var(--cis-muted); }
.glossary dd { margin: .25rem 0 0; }

/* --------------------------------------------------------------- Printable checklist */

.buying-checklist .stage { margin-top: 2rem; }
.buying-checklist ol { padding-left: 1.25rem; }
.buying-checklist li { margin-bottom: .6rem; }
@media print {
    .site-header, .footer, .no-print, #cookieBanner, .cta-band { display: none !important; }
    .hero { padding: 0 !important; background: none !important; }
    .buying-checklist li { break-inside: avoid; }
    a[href]::after { content: none; }
}

/* --------------------------------------------------------------- Exchange-rate chart (server-rendered SVG) */

.rate-chart-wrap { width: 100%; margin: .5rem 0 .75rem; }
.rate-chart { width: 100%; height: auto; display: block; }
.rate-chart .grid { stroke: var(--cis-border); stroke-width: 1; vector-effect: non-scaling-stroke; }
.rate-chart .axis { fill: var(--cis-muted); font-size: 11px; font-family: var(--cis-body); }
.rate-chart .line { stroke: var(--cis-primary); stroke-width: 2; vector-effect: non-scaling-stroke; stroke-linejoin: round; }
.rate-chart .best { fill: #2e7d4f; }
.rate-chart .worst { fill: #b3412f; }
.rate-chart .now { fill: var(--cis-accent); stroke: #fff; stroke-width: 1.5; }
.rate-key { display: inline-block; width: .7rem; height: .7rem; border-radius: 50%; vertical-align: -1px; margin-right: .25rem; }
.rate-key.best { background: #2e7d4f; }
.rate-key.worst { background: #b3412f; }
.rate-key.now { background: var(--cis-accent); }

/* --------------------------------------------------------------- Guide pages */

.guide-body h2 { margin-top: 2.75rem; font-size: 1.85rem; }
.guide-body h3 { margin-top: 1.5rem; font-size: 1.3rem; }

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

.step-list > li {
    counter-increment: step;
    position: relative;
    padding: 0 0 1.75rem 3.5rem;
}

/* thin vertical timeline line joining the numerals */
.step-list > li:not(:last-child)::after {
    content: "";
    position: absolute;
    left: 1.1rem;
    top: 2.6rem;
    bottom: .4rem;
    width: 1px;
    background: var(--cis-border-strong);
}

.step-list > li::before {
    content: counter(step);
    position: absolute;
    left: 0;
    top: 0;
    width: 2.2rem;
    height: 2.2rem;
    border-radius: 50%;
    border: 1px solid var(--cis-primary-dark);
    background: #fff;
    color: var(--cis-primary-dark);
    font-family: var(--cis-display);
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
}

.step-list > li h3 { margin-top: .2rem; }

.toc-card ul { padding-left: 1.1rem; margin-bottom: 0; }
.toc-card li { margin-bottom: .4rem; }
.toc-card li::marker { color: var(--cis-accent); }

.disclosure { font-size: .9rem; color: var(--cis-muted); }

/* --------------------------------------------------------------- Cookie banner */

.cookie-banner {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 1080;
    background: #fff;
    border-top: 3px solid var(--cis-primary-dark);
    box-shadow: 0 -8px 24px rgba(17, 24, 39, .10);
    padding: 1rem 0;
}

.cookie-banner[hidden] { display: none; }

.cookie-banner-inner {
    display: flex;
    gap: 1rem 1.5rem;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
}

.cookie-banner-inner p { flex: 1 1 420px; font-size: .95rem; }

.cookie-banner-actions { display: flex; gap: .75rem; }

.cookie-banner-actions .btn { min-width: 7.5rem; }

/* mark sits on navy in the footer — give it a hairline so it doesn't disappear */
.footer-brand .brand-mark { outline: 1px solid rgba(255, 255, 255, .22); border-radius: 10px; }

/* --------------------------------------------------------------- Guide extras */

.crumbs { font-size: .88rem; color: var(--cis-muted); margin-bottom: 1rem; }
.crumbs a { color: var(--cis-muted); }
.crumbs span[aria-hidden] { margin: 0 .4rem; }

.reviewed { font-size: .9rem; color: var(--cis-muted); margin-top: 1rem; margin-bottom: 0; }

.data-table-wrap { overflow-x: auto; margin: 1.5rem 0; }

.data-table {
    width: 100%;
    border-collapse: collapse;
    font-size: .95rem;
    background: #fff;
}

.data-table th,
.data-table td {
    padding: .65rem .75rem;
    border-bottom: 1px solid var(--cis-border);
    text-align: left;
    vertical-align: top;
}

.data-table thead th {
    color: var(--cis-primary-dark);
    border-bottom: 2px solid var(--cis-primary-dark);
    font-weight: 600;
}

.data-table td.num,
.data-table th.num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }

.faq-list h3 { font-size: 1.15rem; margin-top: 1.75rem; }
.faq-list p:last-child { margin-bottom: 0; }

/* --------------------------------------------------------------- After-purchase checklist */

.checklist-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    background: #fff;
    border: 1px solid var(--cis-border);
    border-radius: var(--cis-radius);
    box-shadow: var(--cis-shadow-sm);
    padding: .75rem 1rem;
    margin-bottom: 1.5rem;
}

.checklist-meter { width: 12rem; max-width: 40vw; height: 6px; background: var(--cis-bg-soft); border-radius: 3px; margin-top: .4rem; overflow: hidden; }
.checklist-meter span { display: block; height: 100%; width: 0; background: var(--cis-accent); transition: width .2s ease; }
.checklist-actions { display: flex; gap: .25rem; align-items: center; }

.checklist-stage { margin-bottom: 2.5rem; scroll-margin-top: 8rem; }
.checklist { list-style: none; padding: 0; margin: 0; }

.checklist-item {
    display: flex;
    gap: .85rem;
    align-items: flex-start;
    padding: 1rem 0;
    border-bottom: 1px solid var(--cis-border);
}

.checklist-item .form-check-input { width: 1.35rem; height: 1.35rem; margin-top: .15rem; flex: 0 0 auto; cursor: pointer; }
.checklist-item .form-check-input:checked { background-color: var(--cis-primary-dark); border-color: var(--cis-primary-dark); }

.checklist-title { font-weight: 600; color: var(--cis-ink); cursor: pointer; margin-right: .5rem; }

.checklist-who {
    display: inline-block;
    font-size: .72rem;
    font-weight: 600;
    letter-spacing: .06em;
    text-transform: uppercase;
    color: var(--cis-accent-dark);
    background: var(--cis-accent-soft);
    border-radius: 999px;
    padding: .1rem .55rem;
    vertical-align: .1rem;
}

.checklist-detail { margin: .35rem 0 0; color: var(--cis-text); }
.checklist-link { white-space: nowrap; margin-left: .25rem; }

.checklist-item.is-done .checklist-title { color: var(--cis-muted); text-decoration: line-through; }
.checklist-item.is-done .checklist-detail { color: var(--cis-muted); }

@media print {
    .site-header, .footer, .no-print, .checklist-actions, .cookie-banner, .hero .reviewed { display: none !important; }
    .checklist-bar { box-shadow: none; }
    .checklist-item { break-inside: avoid; }
    .col-lg-8 { width: 100% !important; flex: 0 0 100% !important; max-width: 100% !important; }
    a { color: inherit; text-decoration: none; }
}

/* Country code beside the mobile number on the currency quote form. */
.input-group > .phone-code { flex: 0 0 8.5rem; width: 8.5rem; }

