/*
 * Know Qatar (اعرف قطر): Qatari maroon (al-annabi), pearl, desert gold.
 * Motif: Sadu weaving band (Gulf Bedouin textile). Deliberately no flag serration or state emblem.
 * Type: Reem Kufi for headings (Arabic + Latin), Readex Pro for text.
 */

:root {
    --bg: #FBF9F7;
    --surface: #FFFFFF;
    --ink: #2A1219;
    --ink-soft: #6B5359;
    --line: #EADFE1;
    --line-strong: #D3C1C5;

    --brand: #8A1538;
    --brand-ink: #6E0F2C;
    --brand-wash: #F5E6EA;
    --gold: #C9A063;
    --gold-light: #EBD3A4;
    --pearl: #FBF6EF;
    --gold-ink: #8A6424;   /* gold for text on light backgrounds (5:1) */
    --field: #8E767C;      /* borders of inputs and controls (≥3:1) */
    --focus: #8A1538;      /* keyboard focus ring */

    --good: #1F7A4D;
    --bad: #C2410C;
    --neutral: #6B5359;

    --font-display: "Reem Kufi", "Readex Pro", system-ui, sans-serif;
    --font: "Readex Pro", system-ui, -apple-system, "Segoe UI", Tahoma, sans-serif;
    --wrap: 1180px;
    --gutter: clamp(16px, 4vw, 40px);
    --radius: 10px;

    /* Sadu band: gold triangles with pearl diamonds on maroon. */
    --sadu: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='32' height='14' viewBox='0 0 32 14'%3E%3Crect width='32' height='14' fill='%238A1538'/%3E%3Cpath d='M0 14 8 3l8 11 8-11 8 11z' fill='%23C9A063'/%3E%3Cpath d='M8 7l2.2 2.8L8 12.6 5.8 9.8zM24 7l2.2 2.8-2.2 2.8-2.2-2.8z' fill='%23FBF6EF'/%3E%3Cpath d='M0 1h32' stroke='%23C9A063' stroke-width='1'/%3E%3C/svg%3E");
    color-scheme: light;
}

@media (prefers-color-scheme: dark) {
    :root:not([data-theme="light"]) {
        --bg: #170A0E;
        --surface: #211015;
        --ink: #F4ECE6;
        --ink-soft: #BFA8AC;
        --line: #3A2028;
        --line-strong: #553039;
        --brand: #E07A93;
        --brand-ink: #F0A3B5;
        --brand-wash: #3A1620;
        --gold: #D9B477;
        --gold-light: #EBD3A4;
        --good: #5FCB94;
        --bad: #F59A6B;
        --neutral: #BFA8AC;
        --gold-ink: #D9B477;
        --field: #8E6E76;
        --focus: #EBD3A4;
        color-scheme: dark;
    }
}

:root[data-theme="dark"] {
    --bg: #170A0E; --surface: #211015; --ink: #F4ECE6; --ink-soft: #BFA8AC; --line: #3A2028; --line-strong: #553039;
    --brand: #E07A93; --brand-ink: #F0A3B5; --brand-wash: #3A1620; --gold: #D9B477; --gold-light: #EBD3A4;
    --good: #5FCB94; --bad: #F59A6B; --neutral: #BFA8AC; --gold-ink: #D9B477; --field: #8E6E76; --focus: #EBD3A4; color-scheme: dark;
}

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

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 96px; }

body {
    margin: 0;
    background: var(--bg);
    color: var(--ink);
    font-family: var(--font);
    font-size: 1.0625rem;
    font-weight: 300;
    line-height: 1.6;
    font-feature-settings: "tnum" 1;
    -webkit-font-smoothing: antialiased;
}

[dir="rtl"] body { line-height: 1.8; }

h1, h2, h3 { margin: 0; line-height: 1.2; }
h1, h2 { font-family: var(--font-display); font-weight: 500; }
h3 { font-weight: 500; }
p { margin: 0; }

a { color: var(--brand); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--brand-ink); }

:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; border-radius: 4px; }
/* On maroon and dark surfaces the ring turns light gold so it stays visible. */
.hero, .pagehead, .footer { --focus: #EBD3A4; }

.wrap { max-width: var(--wrap); margin-inline: auto; padding-inline: var(--gutter); }

.visually-hidden, .hp {
    position: absolute !important; width: 1px; height: 1px; overflow: hidden;
    clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap;
}

.skip {
    position: absolute; inset-inline-start: 16px; top: -60px; z-index: 20;
    background: var(--ink); color: var(--bg); padding: 10px 16px; border-radius: 6px;
}
.skip:focus { top: 12px; }

.sadu { height: 14px; background: var(--sadu) repeat-x center / auto 14px; }

/* ---------- Masthead ---------- */

.masthead {
    position: sticky; top: 0; z-index: 10;
    background: color-mix(in srgb, var(--bg) 92%, transparent);
    backdrop-filter: saturate(1.4) blur(10px);
    border-bottom: 1px solid var(--line);
}

.masthead-inner { display: flex; align-items: center; gap: 12px; min-height: 76px; }

.wordmark { display: inline-flex; align-items: center; color: var(--ink); text-decoration: none; }
/* Text-only logo: the name in both languages, aligned to the page's start edge. */
.wordmark-text { display: grid; justify-items: start; gap: 0; line-height: 1.15; }
.wordmark-primary { font-family: var(--font-display); font-weight: 600; font-size: 1.625rem; letter-spacing: -0.01em; color: var(--brand); white-space: nowrap; }
.wordmark-secondary { font-family: var(--font-display); font-weight: 500; font-size: 1.0625rem; color: var(--gold-ink); white-space: nowrap; }
[dir="rtl"] .wordmark-primary { letter-spacing: 0; }
.wordmark:hover .wordmark-primary { color: var(--brand-ink); }

.mainnav { display: flex; gap: 4px; margin-inline-start: auto; }
.mainnav a {
    color: var(--ink-soft); text-decoration: none; font-size: 0.9375rem; font-weight: 400;
    padding: 10px 12px; border-radius: 8px;
}
.mainnav a:hover { color: var(--brand); background: var(--brand-wash); }

.themeswitch {
    display: inline-grid; place-items: center; width: 44px; height: 44px; flex: none; cursor: pointer;
    color: var(--brand); background: transparent; border: 1px solid var(--field); border-radius: 50%;
    transition: background-color .2s;
}
.themeswitch:hover { background: var(--brand-wash); }
.themeswitch svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.themeswitch .icon-sun { display: none; }
.themeswitch[aria-pressed="true"] .icon-sun { display: block; }
.themeswitch[aria-pressed="true"] .icon-moon { display: none; }
.themeswitch[hidden] { display: none; }

.langswitch {
    display: inline-flex; align-items: center; min-height: 44px; padding: 0 18px;
    border: 1px solid var(--brand); border-radius: 999px;
    color: var(--brand); text-decoration: none; font-weight: 500; font-size: 0.9375rem;
    transition: background-color .2s, color .2s;
}
.langswitch:hover { background: var(--brand); color: var(--pearl); }

/* ---------- Search ---------- */

.search { position: relative; flex: 1 1 260px; max-width: 400px; margin-inline-start: 24px; }
.search input {
    width: 100%; height: 44px; padding-inline: 42px 14px;
    font: inherit; font-size: 0.9375rem; font-weight: 400; color: var(--ink);
    background: var(--surface); border: 1px solid var(--field); border-radius: 999px;
    -webkit-appearance: none; appearance: none;
}
.search input::placeholder { color: var(--ink-soft); opacity: .85; }
.search input:focus-visible { outline: 2px solid var(--brand); outline-offset: 0; border-color: var(--brand); }
.search-icon {
    position: absolute; inset-inline-start: 15px; top: 50%; width: 18px; height: 18px; transform: translateY(-50%);
    fill: none; stroke: var(--ink-soft); stroke-width: 2; stroke-linecap: round; pointer-events: none;
}

.search-list {
    position: absolute; top: calc(100% + 8px); inset-inline: 0; z-index: 30;
    min-width: min(460px, calc(100vw - 32px)); max-height: min(70vh, 520px); overflow-y: auto;
    margin: 0; padding: 6px; list-style: none;
    background: var(--surface); border: 1px solid var(--line-strong); border-radius: 14px;
    box-shadow: 0 18px 40px -12px rgba(42, 18, 25, .28);
}
.search-option a { display: grid; gap: 2px; padding: 10px 12px; border-radius: 10px; color: var(--ink); text-decoration: none; }
.search-option a:hover, .search-option[aria-selected="true"] a { background: var(--brand-wash); }
.search-type { font-size: 0.8125rem; font-weight: 500; color: var(--brand); }
.search-title { font-weight: 500; }
.search-text { font-size: 0.8125rem; color: var(--ink-soft); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.search-all { border-top: 1px solid var(--line); margin-top: 4px; }
.search-all a { display: block; padding: 10px 12px; font-size: 0.875rem; font-weight: 500; }

.search-page-form { display: flex; gap: 10px; max-width: 640px; margin-top: 24px; }
.search-page-form input {
    flex: 1; min-width: 0; min-height: 54px; padding: 0 18px; font: inherit; font-weight: 400;
    color: var(--ink); background: var(--pearl); border: 0; border-radius: var(--radius);
}
.search-page-form button {
    min-height: 54px; padding: 0 26px; font: inherit; font-weight: 500; cursor: pointer;
    color: #8A1538; background: var(--gold-light); border: 0; border-radius: var(--radius);
}
.search-page-form button:hover { background: var(--pearl); }
.search-count { font-size: 1.0625rem; margin-bottom: 20px; }
.search-results { list-style: none; margin: 0; padding: 0; border-top: 2px solid var(--brand); max-width: 760px; }
.search-results li { padding-block: 18px; border-bottom: 1px solid var(--line); }
.search-results a { display: block; margin-top: 2px; font-size: 1.125rem; font-weight: 500; }
.search-results p { margin-top: 4px; color: var(--ink-soft); font-size: 0.9375rem; }

/* ---------- Hero: maroon, pearl text, gold live figures ---------- */

.hero { background: #8A1538; color: var(--pearl); position: relative; }
.hero-inner { padding-block: clamp(56px, 10vw, 120px) clamp(48px, 8vw, 96px); }

.hero-title {
    font-size: clamp(2.75rem, 8vw, 6rem);
    font-weight: 500;
    letter-spacing: -0.01em;
    word-spacing: 0.08em;
    line-height: 1.05;
    color: var(--pearl);
}
[dir="rtl"] .hero-title { letter-spacing: 0; line-height: 1.3; }

.hero-live {
    max-width: 30em;
    margin-top: clamp(28px, 4vw, 44px);
    font-size: clamp(1.375rem, 2.7vw, 2.125rem);
    font-weight: 200;
    line-height: 1.45;
    color: rgba(251, 246, 239, .82);
}
[dir="rtl"] .hero-live { font-weight: 300; line-height: 1.75; }

.fig { font-weight: 500; color: var(--gold-light); }

.hero-meta {
    display: inline-flex; align-items: center; gap: 10px;
    margin-top: 28px; font-size: 0.875rem; color: rgba(251, 246, 239, .75);
}

/* The only ambient motion: a slow pulse that says these figures are live. */
.pulse { width: 8px; height: 8px; border-radius: 50%; background: var(--gold-light); position: relative; }
.pulse::after {
    content: ""; position: absolute; inset: 0; border-radius: 50%; background: var(--gold-light);
    animation: pulse 2.4s ease-out 4;
}
@keyframes pulse { from { transform: scale(1); opacity: .6; } to { transform: scale(3); opacity: 0; } }
@media (prefers-reduced-motion: reduce) { .pulse::after { animation: none; } html { scroll-behavior: auto; } }

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

.section { padding-block: clamp(56px, 8vw, 96px); border-bottom: 1px solid var(--line); }

.section-grid { display: grid; grid-template-columns: minmax(220px, 300px) 1fr; gap: clamp(32px, 6vw, 80px); align-items: start; }

.section-head { position: sticky; top: 110px; }
.section-head h2 { font-size: clamp(1.875rem, 3.2vw, 2.5rem); color: var(--brand); }
.section-head h2::after {
    content: ""; display: block; width: 48px; height: 7px; margin-top: 16px;
    background: var(--sadu) repeat-x center / auto 7px; border-radius: 1px;
}
.section-head p { margin-top: 16px; color: var(--ink-soft); max-width: 28em; }

.empty { color: var(--ink-soft); padding: 24px 0; }

/* ---------- Ledger: one indicator per row ---------- */

.ledger { list-style: none; margin: 0; padding: 0; border-top: 2px solid var(--brand); }

.ledger-row {
    display: grid;
    grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr) minmax(0, 0.9fr) minmax(0, 1.1fr);
    gap: 24px;
    align-items: start;
    padding-block: 28px;
    border-bottom: 1px solid var(--line);
}

.ledger-label h3 { font-size: 1.125rem; }
.ledger-label p { margin-top: 4px; font-size: 0.9375rem; color: var(--ink-soft); line-height: 1.5; }

.ledger-value .value {
    display: block;
    font-size: clamp(1.75rem, 2.6vw, 2.25rem);
    font-weight: 300;
    letter-spacing: -0.02em;
    line-height: 1.1;
    white-space: nowrap;
}
[dir="rtl"] .ledger-value .value { letter-spacing: 0; font-size: clamp(1.5rem, 2.3vw, 1.9rem); }

.year { display: block; margin-top: 6px; font-size: 0.8125rem; color: var(--ink-soft); }

.change { display: inline-flex; align-items: center; gap: 6px; font-weight: 500; font-size: 1rem; white-space: nowrap; padding-top: 6px; }
.change-arrow { width: 0; height: 0; border-inline: 5px solid transparent; }
.dir-up .change-arrow { border-bottom: 7px solid currentColor; }
.dir-down .change-arrow { border-top: 7px solid currentColor; }
.dir-flat .change-arrow { width: 8px; height: 2px; border: 0; background: currentColor; }
.tone-good { color: var(--good); }
.tone-bad { color: var(--bad); }
.tone-neutral { color: var(--neutral); }

.ledger-trend { margin: 0; }
.spark { display: block; width: 100%; height: auto; overflow: visible; }
.spark-area { fill: var(--brand-wash); }
.spark-line { fill: none; stroke: var(--brand); stroke-width: 2; stroke-linejoin: round; stroke-linecap: round; vector-effect: non-scaling-stroke; }
.spark-dot { fill: var(--gold); stroke: var(--brand); stroke-width: 2; vector-effect: non-scaling-stroke; }
.ledger-trend figcaption > span[aria-hidden] { display: flex; justify-content: space-between; margin-top: 6px; font-size: 0.8125rem; color: var(--ink-soft); }

/* ---------- The riyal ---------- */

.fx-table { width: 100%; border-collapse: collapse; border-top: 2px solid var(--brand); }
.fx-table th, .fx-table td { padding: 14px 0; border-bottom: 1px solid var(--line); text-align: start; font-weight: 300; }
.fx-table thead th { font-size: 0.8125rem; color: var(--ink-soft); font-weight: 400; padding-block: 12px; }
.fx-table tbody th { font-weight: 400; }
.fx-table tbody tr:hover { background: var(--brand-wash); }
.fx-table .num { text-align: end; white-space: nowrap; padding-inline-start: 16px; }
.fx-table td.num bdi { font-size: 1.0625rem; }
.code { font-size: 0.8125rem; color: var(--ink-soft); font-weight: 400; letter-spacing: 0.04em; }
.fx-meta { margin-top: 14px; font-size: 0.8125rem; color: var(--ink-soft); }

/* ---------- Notify ---------- */

.notify { background: var(--surface); }
.notify-form { max-width: 520px; }
.notify-form label { display: block; font-size: 0.9375rem; font-weight: 400; margin-bottom: 8px; }
.notify-field { display: flex; gap: 10px; }
.notify-field input {
    flex: 1; min-width: 0; min-height: 52px; padding: 0 16px;
    font: inherit; font-weight: 400; color: var(--ink);
    background: var(--bg); border: 1px solid var(--field); border-radius: var(--radius);
}
.notify-field input:focus-visible { outline-offset: 0; border-color: var(--brand); }
.notify-field input[aria-invalid="true"] { border-color: var(--bad); }
.notify-field button {
    min-height: 52px; padding: 0 28px; flex: none; cursor: pointer;
    font: inherit; font-weight: 500; color: var(--pearl); background: #8A1538;
    border: 0; border-radius: var(--radius); transition: background-color .2s;
}
.notify-field button:hover { background: #6E0F2C; }
.notify-privacy { margin-top: 12px; font-size: 0.8125rem; color: var(--ink-soft); }
.notice { padding: 14px 16px; border-radius: var(--radius); font-weight: 400; }
.notice-ok { background: var(--brand-wash); color: var(--ink); }
.notice-error { margin-top: 10px; padding: 0; color: var(--bad); }

/* ---------- Prose pages ---------- */

.prose { max-width: 40em; }
.prose p + p { margin-top: 16px; }
.page h1 { font-size: clamp(2rem, 4vw, 3rem); color: var(--brand); margin-bottom: 28px; }
.page-lead { font-size: 1.3125rem; line-height: 1.55; color: var(--ink); }
.page-h2 { margin: 40px 0 10px; font-size: 1.375rem; color: var(--brand); }
.page-h2 + p { margin-top: 0; }
/* Reem Kufi's Arabic needs size to breathe; small Arabic headings use the text face. */
[dir="rtl"] .page-h2 { font-family: var(--font); font-weight: 600; }
.mainnav a[aria-current="page"] { color: var(--brand); background: var(--brand-wash); }
.sources .prose { color: var(--ink-soft); }

/* ---------- Page header (inner pages) ---------- */

.pagehead { background: #8A1538; color: var(--pearl); }
.pagehead .wrap { padding-block: clamp(40px, 7vw, 80px) clamp(36px, 6vw, 64px); }
.pagehead h1 { font-size: clamp(2.25rem, 5vw, 3.75rem); line-height: 1.15; color: var(--pearl); }
.pagehead-lead { max-width: 36em; margin-top: 18px; font-size: clamp(1.125rem, 2vw, 1.375rem); font-weight: 300; color: rgba(251, 246, 239, .88); }
.pagehead-note { max-width: 40em; margin-top: 14px; font-size: 0.9375rem; color: var(--gold-light); }
.pagehead-alt { margin-top: 8px; font-family: var(--font-display); font-size: 1.25rem; color: var(--gold-light); }
[dir="rtl"] .pagehead-alt { text-align: right; }
.pagehead a:not(.button) { color: var(--gold-light); }

.crumbs { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 18px; font-size: 0.875rem; color: rgba(251, 246, 239, .75); }

.button {
    display: inline-flex; align-items: center; gap: 10px; min-height: 48px; margin-top: 28px; padding: 0 22px;
    background: #8A1538; color: var(--pearl); border-radius: var(--radius);
    font-weight: 500; text-decoration: none; transition: background-color .2s;
}
.button:hover { background: #6E0F2C; color: var(--pearl); }
/* On the maroon headers, the main button turns pearl. */
.hero .button, .pagehead .button { background: var(--pearl); color: #8A1538; }
.hero .button:hover, .pagehead .button:hover { background: var(--gold-light); color: #6E0F2C; }
.section .button { margin-top: 20px; }
.button-host { font-size: 0.8125rem; font-weight: 400; opacity: .75; }

/* ---------- Guide: audience filter and directory ---------- */

.filter { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; margin-bottom: 48px; }
.filter-label { font-size: 0.9375rem; color: var(--ink-soft); }
.filter ul { display: flex; gap: 8px; flex-wrap: wrap; list-style: none; margin: 0; padding: 0; }
.filter a {
    display: inline-flex; align-items: center; min-height: 44px; padding: 0 18px;
    border: 1px solid var(--field); border-radius: 999px;
    color: var(--ink); text-decoration: none; font-weight: 400; transition: border-color .2s, background-color .2s;
}
.filter a:hover { border-color: var(--brand); }
.filter a[aria-current="page"] { background: #8A1538; border-color: #8A1538; color: var(--pearl); }

.dir-group + .dir-group { margin-top: 64px; }
.dir-group h2 { font-size: clamp(1.625rem, 3vw, 2.125rem); color: var(--brand); margin-bottom: 20px; }
.dir-list { list-style: none; margin: 0; padding: 0; border-top: 2px solid var(--brand); }
.dir-item {
    display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 0.8fr); gap: 32px;
    padding-block: 24px; border-bottom: 1px solid var(--line);
}
.dir-main h3 { font-size: 1.1875rem; }
.dir-main h3 a { color: var(--ink); text-decoration: none; }
.dir-main h3 a:hover { color: var(--brand); text-decoration: underline; }
.dir-main p { margin-top: 6px; color: var(--ink-soft); font-size: 0.9375rem; max-width: 40em; }
.dir-meta { font-size: 0.875rem; color: var(--ink-soft); padding-top: 4px; }
.dir-services { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; font-size: 0.9375rem; }
.dir-services li { padding-inline-start: 14px; border-inline-start: 2px solid var(--gold); }
.channel { display: block; font-size: 0.8125rem; color: var(--ink-soft); }
.dir-checked { margin-top: 32px; font-size: 0.8125rem; color: var(--ink-soft); }

.coming { background: var(--surface); }
.coming-list { list-style: none; margin: 0; padding: 0; border-top: 2px solid var(--brand); }
.coming-list li { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding-block: 18px; border-bottom: 1px solid var(--line); }
.badge { flex: none; padding: 4px 12px; border-radius: 999px; background: var(--sand-wash, #F1EADB); color: #6E4E1F; font-size: 0.8125rem; font-weight: 500; }

/* ---------- Entity page ---------- */

.entity-mandate { font-size: 1.25rem; line-height: 1.6; max-width: 36em; }
.services { list-style: none; margin: 0; padding: 0; border-top: 2px solid var(--brand); }
.service { padding-block: 24px; border-bottom: 1px solid var(--line); }
.service h3 { font-size: 1.125rem; }
.service dl { display: flex; flex-wrap: wrap; gap: 8px 32px; margin: 10px 0 0; font-size: 0.9375rem; }
.service dt { display: inline; color: var(--ink-soft); }
.service dt::after { content: ":"; margin-inline-end: 6px; }
.service dd { display: inline; margin: 0; }
.ledger-source, .service-link {
    display: inline-flex; align-items: center; gap: 6px; min-height: 36px; margin-top: 12px; padding: 0 14px;
    font-size: 0.875rem; font-weight: 500; text-decoration: none; color: var(--brand);
    border: 1px solid var(--brand); border-radius: 999px; transition: background-color .15s, color .15s;
}
.ledger-source::after, .service-link::after {
    content: ""; width: 6px; height: 6px; border-top: 1.5px solid currentColor; border-inline-end: 1.5px solid currentColor; transform: rotate(45deg);
}
[dir="rtl"] .ledger-source::after, [dir="rtl"] .service-link::after { transform: rotate(-45deg); }
.ledger-source:hover, .service-link:hover { background: #8A1538; border-color: #8A1538; color: var(--pearl); }
.notice-info { margin-top: 28px; background: var(--brand-wash); color: var(--ink); font-size: 0.9375rem; }
.entity-back { margin-top: 24px; }

.guide-teaser-lead { font-size: 1.25rem; max-width: 32em; }

/* ---------- Save (on-device bookmarks) ---------- */

.pagehead-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; margin-top: 28px; }
.pagehead-actions .button { margin-top: 0; }
.save-button {
    display: inline-flex; align-items: center; gap: 8px; min-height: 48px; padding: 0 20px; margin-top: 20px;
    font: inherit; font-weight: 500; color: var(--pearl); cursor: pointer;
    background: transparent; border: 1px solid rgba(251, 246, 239, .55); border-radius: var(--radius);
    transition: background-color .2s, border-color .2s;
}
.pagehead-actions .save-button { margin-top: 0; }
.save-button svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linejoin: round; }
.save-button:hover { border-color: var(--pearl); background: rgba(251, 246, 239, .08); }
.save-button[aria-pressed="true"] { background: var(--gold-light); border-color: var(--gold-light); color: #6E0F2C; }
.save-button[aria-pressed="true"] svg { fill: currentColor; }

.saved-list { list-style: none; margin: 0; padding: 0; border-top: 2px solid var(--brand); max-width: 760px; }
.saved-list li { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding-block: 16px; border-bottom: 1px solid var(--line); }
.saved-list a { display: block; font-size: 1.0625rem; font-weight: 500; }
.saved-remove {
    flex: none; min-height: 40px; padding: 0 14px; font: inherit; font-size: 0.875rem; cursor: pointer;
    color: var(--ink-soft); background: transparent; border: 1px solid var(--field); border-radius: 8px;
}
.saved-remove:hover { color: var(--bad); border-color: var(--bad); }

/* ---------- Buttons and calls to action ---------- */

.cta-row { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; margin-top: 28px; }
.cta-row .button { margin-top: 0; }
.hero-cta { margin-top: 36px; }
.button-ghost { background: transparent !important; color: var(--pearl) !important; border: 1px solid rgba(251, 246, 239, .6); }
.button-ghost:hover { background: rgba(251, 246, 239, .1) !important; border-color: var(--pearl); }
.section .button-ghost { color: var(--brand) !important; border-color: var(--brand); }
.section .button-ghost:hover { background: var(--brand-wash) !important; }
.button-outline, .button-solid {
    display: inline-flex; align-items: center; justify-content: center; min-height: 48px; padding: 0 20px;
    font: inherit; font-weight: 500; text-decoration: none; cursor: pointer;
    border-radius: var(--radius); transition: background-color .2s, color .2s;
}
.button-outline { color: var(--brand); background: transparent; border: 1px solid var(--brand); }
.button-outline:hover { background: var(--brand-wash); color: var(--brand); }
.button-solid { color: var(--pearl); background: #8A1538; border: 0; padding: 0 28px; justify-self: start; }
.button-solid:hover { background: #6E0F2C; }

.help-box { padding: 22px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
.help-box h2 { font-size: 1.0625rem; font-family: var(--font); font-weight: 600; color: var(--ink); margin: 0 0 6px; }
.help-box p { font-size: 0.9375rem; color: var(--ink-soft); }
.help-box .cta-row { margin-top: 14px; gap: 8px; }
.help-box .button-outline { min-height: 44px; padding: 0 14px; font-size: 0.9375rem; }
.services + .notice-info + .help-box, .notice-info + .help-box { margin-top: 20px; }

.ready { padding: 28px; background: var(--brand-wash); border-radius: var(--radius); }
.ready h2 { margin-bottom: 8px; }
.ready .button { margin-top: 16px; }

/* ---------- Forms (feedback) ---------- */

.fb-form { max-width: 640px; display: grid; gap: 28px; }
.field { display: grid; gap: 8px; }
.field label, .fb-kinds legend { font-weight: 500; font-size: 1rem; }
.optional { font-weight: 300; color: var(--ink-soft); }
.field input, .field textarea {
    width: 100%; min-height: 52px; padding: 12px 16px; font: inherit; font-weight: 400; color: var(--ink);
    background: var(--surface); border: 1px solid var(--field); border-radius: var(--radius);
}
.field textarea { min-height: 160px; resize: vertical; line-height: 1.6; }
.field input:focus-visible, .field textarea:focus-visible { outline-offset: 0; border-color: var(--brand); }
.field [aria-invalid="true"] { border: 2px solid var(--bad); }
.hint { font-size: 0.875rem; color: var(--ink-soft); }
.field-error { font-size: 0.9375rem; font-weight: 500; color: var(--bad); }
.fb-kinds { border: 0; margin: 0; padding: 0; display: grid; gap: 10px; }
.fb-kinds legend { margin-bottom: 10px; padding: 0; }
.fb-kind {
    display: flex; align-items: flex-start; gap: 12px; padding: 14px 16px; cursor: pointer;
    background: var(--surface); border: 1px solid var(--field); border-radius: var(--radius);
}
.fb-kind:has(input:checked) { border: 2px solid var(--brand); background: var(--brand-wash); padding: 13px 15px; }
.fb-kind input { width: 20px; height: 20px; margin-top: 3px; accent-color: #8A1538; flex: none; }
.fb-kind span { color: var(--ink-soft); }
.fb-kind strong { color: var(--ink); font-weight: 500; }
.fb-privacy, .fb-alt { font-size: 0.875rem; color: var(--ink-soft); }
.fb-alt { margin-top: 24px; }
.error-summary { padding: 18px 20px; border: 2px solid var(--bad); border-radius: var(--radius); background: var(--surface); }
.error-summary h2 { font-size: 1.125rem; font-family: var(--font); font-weight: 600; color: var(--bad); margin-bottom: 8px; }
.error-summary ul { margin: 0; padding-inline-start: 20px; }
.fb-done { max-width: 640px; padding: 28px; }
.fb-done h2 { font-size: 1.375rem; margin-bottom: 8px; }
.a11y-list { margin: 0; padding-inline-start: 22px; display: grid; gap: 8px; }

/* ---------- Whole-row links ----------
 * The row's only link is stretched over the row, so the full row is one big target
 * while screen readers still hear a single link named after the ministry or guide. */

.row-link { position: relative; transition: background-color .15s; }
.row-link a::after { content: ""; position: absolute; inset: 0; z-index: 1; }
.row-link:hover { background: var(--brand-wash); }
.row-link:hover a { color: var(--brand); text-decoration: underline; }
.row-link a:focus-visible { outline: none; }
.row-link:has(a:focus-visible) { outline: 3px solid var(--focus); outline-offset: 2px; border-radius: 6px; }
.row-arrow {
    position: absolute; inset-inline-end: 16px; top: 50%; width: 10px; height: 10px; margin-top: -5px;
    border-top: 2px solid var(--brand); border-inline-end: 2px solid var(--brand);
    transform: rotate(45deg); transition: transform .15s;
}
[dir="rtl"] .row-arrow { transform: rotate(-45deg); }
.row-link:hover .row-arrow { transform: translateX(3px) rotate(45deg); }
[dir="rtl"] .row-link:hover .row-arrow { transform: translateX(-3px) rotate(-45deg); }
.dir-item.row-link { padding-inline: 16px 48px; margin-inline: -16px; border-radius: 6px; }
.coming-list .row-link { padding-inline: 12px 44px; margin-inline: -12px; border-radius: 6px; }
@media (prefers-reduced-motion: reduce) { .row-link, .row-arrow { transition: none; } }

/* ---------- Guide list on the Guide page ---------- */

.topics { display: grid; gap: 40px; }
.topic h3 { font-size: 1.0625rem; color: var(--ink-soft); font-weight: 500; margin-bottom: 10px; }
.coming-list a { font-size: 1.0625rem; font-weight: 400; color: var(--ink); text-decoration: none; }
.coming-list a:hover { color: var(--brand); text-decoration: underline; }
.guide-aud { flex: none; font-size: 0.8125rem; color: var(--ink-soft); }

/* ---------- Step-by-step guide article ---------- */

.pagehead-meta { display: flex; flex-wrap: wrap; gap: 8px 28px; margin-top: 18px; font-size: 0.9375rem; color: var(--gold-light); }

.article-grid {
    display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: clamp(32px, 6vw, 80px);
    padding-block: clamp(48px, 7vw, 88px);
}
.article { max-width: 44em; }
.article > section + section { margin-top: 56px; }
.article h2 { font-size: clamp(1.5rem, 2.6vw, 1.875rem); color: var(--brand); margin-bottom: 16px; }
[dir="rtl"] .article h2 { font-family: var(--font); font-weight: 600; }
.article p { font-size: 1.0625rem; }

.checklist, .tips { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.checklist li { position: relative; padding-inline-start: 34px; }
.checklist li::before {
    content: ""; position: absolute; inset-inline-start: 0; top: 0.3em;
    width: 18px; height: 18px; border: 2px solid var(--brand); border-radius: 5px;
}
.tips li { padding: 14px 18px; background: var(--surface); border-inline-start: 3px solid var(--gold); border-radius: 0 var(--radius) var(--radius) 0; }
[dir="rtl"] .tips li { border-radius: var(--radius) 0 0 var(--radius); }

/* Steps are a real sequence, so they are numbered. */
.steps { list-style: none; margin: 0; padding: 0; counter-reset: step; }
.step { position: relative; counter-increment: step; padding-inline-start: 64px; padding-bottom: 32px; }
.step::before {
    content: counter(step); position: absolute; inset-inline-start: 0; top: 0;
    width: 42px; height: 42px; display: grid; place-items: center;
    background: #8A1538; color: var(--pearl); border-radius: 50%;
    font-family: var(--font-display); font-weight: 600; font-size: 1.125rem;
}
.step:not(:last-child)::after {
    content: ""; position: absolute; inset-inline-start: 20px; top: 46px; bottom: 4px; width: 2px; background: var(--line-strong);
}
.step h3 { font-size: 1.1875rem; padding-top: 8px; }
.step p { margin-top: 6px; color: var(--ink-soft); }

.facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 16px; }
.facts > div { padding: 20px 22px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
.facts h2 { font-size: 1.125rem; margin-bottom: 8px; }
.facts p { font-size: 0.9375rem; }

.sources-list p { color: var(--ink-soft); font-size: 0.9375rem; }
.sources-list ul { margin: 12px 0 0; padding-inline-start: 20px; display: grid; gap: 6px; font-size: 0.875rem; overflow-wrap: anywhere; }

.article-aside { position: sticky; top: 110px; align-self: start; display: grid; gap: 24px; }
.aside-block { padding: 22px; background: var(--surface); border: 1px solid var(--line); border-top: 3px solid var(--brand); border-radius: var(--radius); }
.aside-block h2 { font-size: 1rem; font-family: var(--font); font-weight: 600; color: var(--ink-soft); margin-bottom: 10px; }
.aside-block ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.aside-block a { font-weight: 400; }
.article-aside .notice-info { margin-top: 0; font-size: 0.875rem; }

@media (max-width: 960px) {
    .article-grid { grid-template-columns: 1fr; }
    .article-aside { position: static; }
}

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

.footer { background: #2A0B15; color: rgba(251, 246, 239, .78); font-size: 0.875rem; }
.footer-inner { display: grid; grid-template-columns: 1fr auto; gap: 40px; align-items: start; padding-block: 48px 64px; }
.footer-disclaimer { max-width: 44em; }
.footer-meta { text-align: end; display: grid; gap: 4px; }
.footer a { color: var(--gold-light); }
.footer-links { display: flex; gap: 20px; justify-content: flex-end; flex-wrap: wrap; }

/* ---------- Responsive ---------- */

@media (max-width: 960px) {
    .section-grid { grid-template-columns: 1fr; }
    .section-head { position: static; }
    html { scroll-padding-top: 200px; }
    /* Phones and tablets: the three-item nav moves to its own row under the logo. */
    .masthead-inner { flex-wrap: wrap; gap: 0 16px; padding-block: 10px 0; }
    .a11y-wrap { margin-inline-start: auto; }
    .themeswitch { margin-inline-start: 0; }
    .langswitch { margin-inline-start: 0; }
    .mainnav { order: 3; flex-basis: 100%; margin-inline-start: 0; gap: 4px; padding-block: 6px; margin-inline: -12px; }
    .search { order: 4; flex-basis: 100%; max-width: none; margin: 2px 0 12px; }
    .dir-item { grid-template-columns: 1fr; gap: 12px; }
}

@media (max-width: 640px) {
    .ledger-row {
        grid-template-columns: 1fr 1fr;
        grid-template-areas: "label label" "value change" "trend trend";
        gap: 16px 20px;
        padding-block: 24px;
    }
    .ledger-label { grid-area: label; }
    .ledger-value { grid-area: value; }
    .ledger-change { grid-area: change; }
    .ledger-trend { grid-area: trend; max-width: 320px; }
    .fx-table thead th:nth-child(3), .fx-table td:nth-child(3) { display: none; }
    .notify-field { flex-direction: column; }
    .footer-inner { grid-template-columns: 1fr; }
    .footer-meta { text-align: start; }
    .footer-links { justify-content: flex-start; }
    .wordmark-primary { font-size: 1.375rem; }
    .wordmark-secondary { font-size: 0.9375rem; }
}

/* Arabic headings below title size read better in the text face. */
[dir="rtl"] h2, [dir="rtl"] h3 { font-family: var(--font); font-weight: 600; }

/* ---------- Accessibility tools panel ---------- */

.a11y-wrap { position: relative; }
.a11yswitch {
    display: inline-grid; place-items: center; width: 44px; height: 44px; cursor: pointer;
    color: var(--pearl); background: #8A1538; border: 0; border-radius: 50%;
}
.a11yswitch[hidden] { display: none; }
.a11yswitch:hover { background: #6E0F2C; }
.a11yswitch svg { width: 24px; height: 24px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }
.a11yswitch svg circle { fill: currentColor; stroke: none; }

.a11y-panel {
    position: absolute; top: calc(100% + 10px); inset-inline-end: 0; z-index: 40; width: min(320px, calc(100vw - 32px));
    padding: 18px; background: var(--surface); border: 1px solid var(--field); border-radius: 14px;
    box-shadow: 0 18px 40px -12px rgba(42, 18, 25, .3); display: grid; gap: 16px;
}
.a11y-panel[hidden] { display: none; }
.a11y-panel-head { display: flex; justify-content: space-between; align-items: center; }
.a11y-panel-head h2 { font-family: var(--font); font-size: 1.0625rem; font-weight: 600; color: var(--ink); }
.a11y-close { width: 40px; height: 40px; display: grid; place-items: center; background: transparent; border: 0; border-radius: 8px; cursor: pointer; color: var(--ink); }
.a11y-close:hover { background: var(--brand-wash); }
.a11y-close svg { width: 20px; height: 20px; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }
.a11y-size { display: grid; gap: 8px; font-size: 0.9375rem; font-weight: 500; }
.a11y-size-controls { display: grid; grid-template-columns: 1fr 1.2fr 1fr; gap: 6px; }
.a11y-size-controls button, .a11y-toggle, .a11y-reset {
    min-height: 44px; font: inherit; font-weight: 500; color: var(--ink); cursor: pointer;
    background: var(--bg); border: 1px solid var(--field); border-radius: 10px;
}
.a11y-size-controls button:hover:not(:disabled), .a11y-toggle:hover, .a11y-reset:hover { border-color: var(--brand); background: var(--brand-wash); }
.a11y-size-controls button:disabled { opacity: .45; cursor: not-allowed; }
.a11y-toggles { display: grid; gap: 6px; }
.a11y-toggle { display: flex; align-items: center; gap: 12px; padding: 0 14px; text-align: start; font-size: 0.9375rem; }
.a11y-check { width: 20px; height: 20px; flex: none; border: 2px solid var(--field); border-radius: 5px; position: relative; }
.a11y-toggle[aria-pressed="true"] { border: 2px solid var(--brand); background: var(--brand-wash); }
.a11y-toggle[aria-pressed="true"] .a11y-check { background: #8A1538; border-color: #8A1538; }
.a11y-toggle[aria-pressed="true"] .a11y-check::after {
    content: ""; position: absolute; left: 5px; top: 1px; width: 6px; height: 11px;
    border: solid #fff; border-width: 0 2px 2px 0; transform: rotate(45deg);
}
.a11y-panel-foot { display: flex; justify-content: space-between; align-items: center; gap: 12px; font-size: 0.875rem; }
.a11y-reset { padding: 0 14px; font-size: 0.875rem; }

/* Text size: everything is sized in rem, so the root size scales the whole page. */
html[data-size="1"] { font-size: 112%; }
html[data-size="2"] { font-size: 125%; }
html[data-size="3"] { font-size: 150%; }

/* Readable font: a plain, heavier system face for both scripts. */
html[data-font="readable"] { --font: Arial, "Segoe UI", Tahoma, sans-serif; --font-display: Arial, "Segoe UI", Tahoma, sans-serif; }
html[data-font="readable"] body { font-weight: 400; }
html[data-font="readable"] .hero-title, html[data-font="readable"] .hero-live { font-weight: 600; letter-spacing: 0; }

/* Underline every link. */
html[data-links="underline"] a { text-decoration: underline !important; text-decoration-thickness: 2px !important; }

/* Wider spacing (WCAG 1.4.12 values). Letter spacing only for Latin: it would break Arabic letter joining. */
html[data-spacing="wide"] body { line-height: 1.9; word-spacing: 0.16em; }
html[data-spacing="wide"] p, html[data-spacing="wide"] li { margin-bottom: 0.6em; }
html[data-spacing="wide"]:lang(en) body { letter-spacing: 0.12em; }

/* Stop all motion. */
html[data-motion="off"] *, html[data-motion="off"] *::before, html[data-motion="off"] *::after {
    animation: none !important; transition: none !important; scroll-behavior: auto !important;
}

/* High contrast: black on white, deep maroon accents, solid borders. Overrides light and dark themes. */
html[data-contrast="high"] {
    --bg: #FFFFFF; --surface: #FFFFFF; --ink: #000000; --ink-soft: #1A1A1A;
    --line: #000000; --line-strong: #000000; --field: #000000;
    --brand: #5C0C24; --brand-ink: #3D0718; --brand-wash: #F2E4E8;
    --gold-ink: #5C3D0B; --good: #0B5A33; --bad: #9A2B00; --neutral: #000000; --focus: #000000;
    color-scheme: light;
}
html[data-contrast="high"] .hero, html[data-contrast="high"] .pagehead { background: #000000; --focus: #FFD200; }
html[data-contrast="high"] .fig, html[data-contrast="high"] .pagehead-note, html[data-contrast="high"] .pagehead-meta,
html[data-contrast="high"] .pagehead-alt, html[data-contrast="high"] .pagehead a:not(.button) { color: #FFD200; }
html[data-contrast="high"] .hero-live, html[data-contrast="high"] .pagehead-lead, html[data-contrast="high"] .hero-meta,
html[data-contrast="high"] .crumbs { color: #FFFFFF; }
html[data-contrast="high"] .footer { background: #000000; color: #FFFFFF; }
html[data-contrast="high"] .footer a { color: #FFD200; }
html[data-contrast="high"] .sadu { filter: grayscale(1) contrast(1.4); }
html[data-contrast="high"] a { text-decoration: underline; }

/* ---------- Journeys: "What brings you to Qatar?" ---------- */

.journeys { background: var(--surface); }
.journeys-head { max-width: 40em; margin-bottom: 32px; }
.journeys-head h2 { font-size: clamp(1.875rem, 3.4vw, 2.625rem); color: var(--brand); }
.journeys-head p { margin-top: 10px; color: var(--ink-soft); font-size: 1.125rem; }
.journey-cards { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 16px; }
.journey-card {
    padding: 24px 52px 24px 24px; background: var(--bg); border: 1px solid var(--field); border-radius: 14px;
}
[dir="rtl"] .journey-card { padding: 24px 24px 24px 52px; }
.journey-card:hover { border-color: var(--brand); }
.journey-card a { display: block; margin-top: 14px; font-size: 1.1875rem; font-weight: 600; color: var(--ink); text-decoration: none; }
.journey-card p { margin-top: 6px; font-size: 0.9375rem; color: var(--ink-soft); line-height: 1.5; }
.journey-icon { width: 40px; height: 40px; padding: 8px; border-radius: 10px; background: var(--brand-wash); fill: none; stroke: var(--brand); stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.journeys-cta { margin-top: 28px; }

.journey-title { display: flex; align-items: center; gap: 16px; }
.journey-title .journey-icon { width: 56px; height: 56px; padding: 12px; background: rgba(251, 246, 239, .12); stroke: var(--gold-light); flex: none; }

/* ---------- Wizard ---------- */

.wizard { max-width: 760px; display: grid; gap: 32px; }
.wizard-q { border: 0; margin: 0; padding: 0; }
.wizard-q legend { display: flex; align-items: center; gap: 12px; margin-bottom: 14px; padding: 0; font-size: 1.25rem; font-weight: 600; }
.wizard-n { width: 32px; height: 32px; display: grid; place-items: center; border-radius: 50%; background: #8A1538; color: var(--pearl); font-size: 0.9375rem; flex: none; }
.wizard-options { display: grid; gap: 10px; }
.wizard-options-who { grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); }
.wizard-options-yn { grid-template-columns: repeat(2, minmax(0, 160px)); }
.wizard-option {
    display: flex; align-items: center; gap: 12px; min-height: 56px; padding: 12px 16px; cursor: pointer;
    background: var(--surface); border: 1px solid var(--field); border-radius: 12px;
}
.wizard-option:hover { border-color: var(--brand); }
.wizard-option:has(input:checked) { border: 2px solid var(--brand); background: var(--brand-wash); padding: 11px 15px; }
.wizard-option:has(input:focus-visible) { outline: 3px solid var(--focus); outline-offset: 2px; }
.wizard-option input { width: 20px; height: 20px; accent-color: #8A1538; flex: none; }
.wizard-option .journey-icon { width: 34px; height: 34px; padding: 6px; }
.wizard-option strong { font-weight: 500; }

/* ---------- Journey checklist ---------- */

.journey-progress { display: inline-block; margin-bottom: 24px; padding: 8px 16px; border-radius: 999px; background: var(--brand-wash); font-weight: 600; color: var(--brand); }
.journey-stages { list-style: none; margin: 0; padding: 0; counter-reset: stage; display: grid; gap: 40px; max-width: 860px; }
.journey-stage { counter-increment: stage; }
.journey-stage h2 { display: flex; align-items: center; gap: 12px; font-size: clamp(1.375rem, 2.4vw, 1.75rem); color: var(--brand); margin-bottom: 14px; }
.journey-stage h2::before {
    content: counter(stage); width: 36px; height: 36px; display: grid; place-items: center; flex: none;
    border-radius: 50%; background: #8A1538; color: var(--pearl); font-size: 1rem; font-family: var(--font);
}
.checklist-items { list-style: none; margin: 0; padding: 0; border-top: 2px solid var(--brand); }
.check-item { display: flex; gap: 16px; align-items: flex-start; padding: 18px 4px; border-bottom: 1px solid var(--line); }
.check-item input[type="checkbox"] { position: absolute; opacity: 0; width: 1px; height: 1px; }
.check-box {
    width: 28px; height: 28px; flex: none; margin-top: 2px; cursor: pointer; position: relative;
    border: 2px solid var(--field); border-radius: 7px; background: var(--surface);
}
.check-item input:focus-visible + .check-box { outline: 3px solid var(--focus); outline-offset: 2px; }
.check-item.is-done .check-box { background: #8A1538; border-color: #8A1538; }
.check-item.is-done .check-box::after {
    content: ""; position: absolute; left: 8px; top: 3px; width: 7px; height: 13px;
    border: solid #fff; border-width: 0 3px 3px 0; transform: rotate(45deg);
}
.check-body a { font-size: 1.125rem; font-weight: 600; }
.check-body p { margin-top: 4px; color: var(--ink-soft); font-size: 0.9375rem; }
.check-item.is-done .check-body a { text-decoration: line-through; color: var(--ink-soft); }
.tag { display: inline-block; margin-inline-start: 8px; padding: 2px 10px; border-radius: 999px; background: var(--sand-wash, #F1EADB); color: #6E4E1F; font-size: 0.8125rem; font-weight: 500; vertical-align: middle; }
.journey-note { margin-top: 20px; }

/* ---------- Contacts on guides ---------- */

.contacts { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 12px; }
.contact { display: grid; gap: 4px; padding: 16px 18px; background: var(--surface); border: 1px solid var(--line); border-inline-start: 4px solid var(--brand); border-radius: var(--radius); }
.contact-label { font-size: 0.875rem; color: var(--ink-soft); }
.contact-value { font-size: 1.25rem; font-weight: 600; text-decoration: none; color: var(--brand); }
.contact-phone .contact-value { font-size: 1.5rem; letter-spacing: 0.02em; }
.contact-source { font-size: 0.8125rem; color: var(--ink-soft); }

/* ---------- Print: checklists and guides print cleanly ---------- */

@media print {
    .masthead, .footer, .sadu, .pagehead-actions, .save-button, .help-box, .coming, .journeys, .a11y-panel,
    .article-aside .notice-info ~ *, .search, .hero-cta { display: none !important; }
    .pagehead, .hero { background: none !important; color: #000 !important; }
    .pagehead h1, .pagehead-lead, .crumbs, .pagehead-meta { color: #000 !important; }
    body { background: #fff; color: #000; font-size: 12pt; }
    .section { padding-block: 12pt; border: 0; }
    .check-box { border: 1.5pt solid #000 !important; }
    a { color: #000; }
    .check-body a::after { content: " (" attr(href) ")"; font-size: 9pt; font-weight: 400; }
}

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

.calc-dates { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.calc-result { margin-top: 40px; padding: 28px; background: var(--brand-wash); border-radius: 14px; }
.calc-result h2 { font-size: 1.25rem; font-family: var(--font); font-weight: 600; color: var(--ink); }
.calc-amount { margin-top: 8px; font-size: clamp(2.25rem, 5vw, 3.25rem); font-weight: 600; color: var(--brand); line-height: 1.2; }
.calc-none { font-size: 1.25rem; }
.calc-breakdown { margin: 20px 0 0; display: grid; gap: 8px; }
.calc-breakdown div { display: flex; justify-content: space-between; gap: 16px; padding-bottom: 8px; border-bottom: 1px solid var(--line); }
.calc-breakdown dt { color: var(--ink-soft); }
.calc-breakdown dd { margin: 0; font-weight: 600; }
.calc-result .notice-info { margin-top: 20px; background: var(--surface); }
.calc-how { font-size: 0.9375rem; color: var(--ink-soft); }
.calc-how + .calc-how { margin-top: 10px; }
@media (max-width: 640px) { .calc-dates { grid-template-columns: 1fr; } }

/* ---------- Explore and live: lifestyle tiles ---------- */

.explore { background: var(--bg); }
.explore-tiles { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 12px; }
.explore-tile {
    display: flex; align-items: center; gap: 14px; min-height: 76px; padding: 14px 16px;
    background: var(--surface); border: 1px solid var(--field); border-radius: 12px;
}
.explore-tile:hover { border-color: var(--brand); }
.explore-tile .journey-icon { width: 44px; height: 44px; padding: 9px; flex: none; }
.explore-tile a { font-weight: 600; color: var(--ink); text-decoration: none; line-height: 1.3; }

/* ---------- Map ---------- */

.map-filters { border: 0; margin: 0 0 16px; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.map-filters[hidden] { display: none; }
.map-filters legend { width: 100%; margin-bottom: 8px; font-weight: 500; }
.map-chip { display: inline-flex; align-items: center; gap: 8px; min-height: 40px; padding: 0 14px; cursor: pointer; border: 1px solid var(--field); border-radius: 999px; background: var(--surface); font-size: 0.9375rem; }
.map-chip input { width: 18px; height: 18px; accent-color: #8A1538; }
.map-chip:has(input:focus-visible) { outline: 3px solid var(--focus); outline-offset: 2px; }
.map-dot { width: 12px; height: 12px; border-radius: 50%; border: 2px solid #fff; box-shadow: 0 0 0 1px rgba(0,0,0,.25); flex: none; display: inline-block; }
.map-chip-airport .map-dot, .map-dot-airport { background: #1D4E7A; }
.map-chip-metro .map-dot, .map-dot-metro { background: #8A1538; }
.map-chip-hospital .map-dot, .map-dot-hospital { background: #B42318; }
.map-chip-health_centre .map-dot, .map-dot-health_centre { background: #1F7A4D; }
.map-chip-service_centre .map-dot, .map-dot-service_centre { background: #6E4E1F; }
.map-chip-mall .map-dot, .map-dot-mall { background: #7A3E9D; }
.map-chip-park .map-dot, .map-dot-park { background: #2E7D32; }
.map-chip-landmark .map-dot, .map-dot-landmark { background: #C9A063; }
.map-canvas { height: min(70vh, 620px); border-radius: 14px; border: 1px solid var(--field); overflow: hidden; z-index: 0; }
.map-canvas[hidden] { display: none; }
.map-attrib { margin-top: 8px; font-size: 0.8125rem; color: var(--ink-soft); }
.map-list-title { margin: 40px 0 12px; font-size: 1.5rem; color: var(--brand); }
.map-list { max-width: 860px; }
.map-group summary { display: flex; align-items: center; gap: 10px; }
.map-group ul { list-style: none; margin: 10px 0 0; padding: 0; }
.map-group li { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 8px 0; border-bottom: 1px solid var(--line); }
.map-group .ledger-source { margin-top: 0; flex: none; }
.leaflet-container { font-family: var(--font); }
.leaflet-popup-content a { color: #8A1538; font-weight: 600; }
