/* ============================================================
   Leiðvís — design system
   Navy/teal surfaces, light-blue actions, green for completion.
   ============================================================ */

:root {
    --navy-950: #071a2b;
    --navy-900: #0b2239;
    --navy-800: #102d47;
    --navy-700: #173d5c;
    --navy-600: #235274;
    --teal-700: #0f5f5c;
    --teal-500: #1f9c94;
    --teal-300: #6fd6cf;
    --cyan-300: #8fe6f0;
    --blue-700: #185c9e;
    --blue-600: #1f6fbf;
    --blue-500: #2d84d8;
    --blue-100: #e3f0fc;
    --blue-050: #f1f8ff;
    --green-700: #1c6b47;
    --green-500: #2f9e6b;
    --green-100: #e0f4e9;
    --amber-700: #8a5a00;
    --amber-500: #b7791f;
    --amber-100: #fdf3dd;
    --red-700: #a3261b;
    --red-500: #c0392b;
    --red-100: #fdeceb;
    --paper: #f3f7fa;
    --paper-warm: #f8fafc;
    --surface: #ffffff;
    --surface-soft: #f7fafc;
    --ink: #122537;
    --ink-soft: #2b4055;
    --muted: #526a7f;
    --muted-light: #6b8194;
    --line: #dbe4ec;
    --line-strong: #c3d2de;
    --radius-lg: 18px;
    --radius: 14px;
    --radius-sm: 9px;
    --shadow-sm: 0 1px 2px rgba(9, 30, 48, 0.05);
    --shadow: 0 1px 2px rgba(9, 30, 48, 0.05), 0 10px 28px rgba(9, 30, 48, 0.07);
    --shadow-lg: 0 24px 60px rgba(7, 26, 43, 0.22);
    --focus: 0 0 0 3px rgba(45, 132, 216, 0.4);
    --font: "Segoe UI", "Noto Sans", -apple-system, BlinkMacSystemFont, "Helvetica Neue", Arial, sans-serif;
    --mono: "Cascadia Mono", "SFMono-Regular", Consolas, monospace;
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    -webkit-text-size-adjust: 100%;
    scroll-behavior: smooth;
    scroll-padding-top: 90px;
}

body {
    margin: 0;
    background: var(--paper);
    color: var(--ink);
    font-family: var(--font);
    font-size: 16px;
    line-height: 1.6;
    text-rendering: optimizeLegibility;
}

h1, h2, h3, h4 {
    margin: 0 0 0.5rem;
    color: var(--navy-900);
    line-height: 1.2;
    letter-spacing: -0.015em;
    font-weight: 700;
    text-wrap: balance;
}

h1 {
    font-size: clamp(1.85rem, 3.4vw, 2.7rem);
}

h2 {
    font-size: clamp(1.35rem, 2.1vw, 1.7rem);
}

h3 {
    font-size: 1.12rem;
}

h4 {
    font-size: 1.02rem;
    margin: 0;
}

p {
    margin: 0 0 0.8rem;
}

p:last-child {
    margin-bottom: 0;
}

a {
    color: var(--blue-700);
    text-decoration-thickness: 1px;
    text-underline-offset: 3px;
}

a:hover {
    color: var(--blue-600);
}

ul, ol {
    margin: 0;
    padding-left: 1.2rem;
}

:focus-visible {
    outline: 0;
    box-shadow: var(--focus);
    border-radius: 6px;
}

/* Blazor moves focus to the page <h1> after in-app navigation so screen readers start
   in the right place. A heading is not a keyboard control, so the ring only adds noise;
   every interactive element keeps its own focus indicator. */
h1[tabindex="-1"]:focus-visible,
main[tabindex="-1"]:focus-visible {
    box-shadow: none;
}

::selection {
    background: var(--blue-100);
    color: var(--navy-900);
}

img, svg {
    max-width: 100%;
}

button, input, select, textarea {
    font: inherit;
    color: inherit;
}

[hidden] {
    display: none !important;
}

.visually-hidden {
    position: absolute !important;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.skip-link {
    position: absolute;
    left: 1rem;
    top: -60px;
    z-index: 200;
    background: var(--navy-900);
    color: #fff;
    padding: 0.65rem 1rem;
    border-radius: 0 0 10px 10px;
    transition: top 0.15s ease;
}

.skip-link:focus {
    top: 0;
    color: #fff;
}

.shell {
    width: min(1180px, calc(100% - 2.5rem));
    margin-inline: auto;
}

.icon {
    flex: none;
    vertical-align: -0.15em;
}

.small {
    font-size: 0.86rem;
    line-height: 1.45;
}

.muted {
    color: var(--muted);
}

.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    margin: 0 0 0.5rem;
    font-size: 0.76rem;
    font-weight: 700;
    letter-spacing: 0.09em;
    text-transform: uppercase;
    color: var(--teal-700);
}

.eyebrow-light {
    color: var(--cyan-300);
}

.lead {
    font-size: 1.08rem;
    color: var(--ink-soft);
    max-width: 68ch;
}

/* ---------- Header ---------- */

.site-header {
    background: var(--navy-900);
    color: #fff;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    position: relative;
    z-index: 20;
}

.header-row {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    padding: 0.85rem 0;
    flex-wrap: wrap;
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 0.7rem;
    color: #fff;
    text-decoration: none;
    margin-right: auto;
}

.brand:hover {
    color: #fff;
}

.brand-mark {
    display: grid;
    place-items: center;
    width: 42px;
    height: 42px;
    border-radius: 12px;
    background: linear-gradient(145deg, var(--teal-500), var(--navy-700));
    color: #fff;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.25);
}

.brand-copy {
    display: flex;
    flex-direction: column;
    line-height: 1.15;
}

.brand-copy strong {
    font-size: 1.02rem;
    letter-spacing: 0.01em;
}

.brand-copy span {
    font-size: 0.75rem;
    color: #b9cddd;
}

.main-nav {
    display: flex;
    align-items: center;
    gap: 0.15rem;
    flex-wrap: wrap;
}

.main-nav a {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    color: #d8e5ef;
    text-decoration: none;
    font-size: 0.92rem;
    padding: 0.5rem 0.7rem;
    border-radius: 8px;
    border-bottom: 2px solid transparent;
}

.main-nav a:hover {
    background: rgba(255, 255, 255, 0.08);
    color: #fff;
}

.main-nav a.active {
    color: #fff;
    border-bottom-color: var(--teal-300);
    background: rgba(255, 255, 255, 0.05);
}

.nav-count {
    display: inline-grid;
    place-items: center;
    min-width: 1.35rem;
    height: 1.35rem;
    padding: 0 0.3rem;
    border-radius: 999px;
    background: var(--teal-500);
    color: #fff;
    font-size: 0.72rem;
    font-weight: 700;
}

.lang-switch {
    display: inline-flex;
    border: 1px solid rgba(255, 255, 255, 0.22);
    border-radius: 999px;
    padding: 2px;
    background: rgba(255, 255, 255, 0.04);
}

.lang-button {
    border: 0;
    background: transparent;
    color: #c9dae7;
    font-size: 0.78rem;
    font-weight: 700;
    padding: 0.32rem 0.65rem;
    border-radius: 999px;
    cursor: pointer;
}

.lang-button.is-active {
    background: #fff;
    color: var(--navy-900);
}

.site-main {
    padding: 2rem 0 3rem;
    min-height: 60vh;
}

.site-footer {
    background: var(--navy-950);
    color: #bed0de;
    padding: 2.4rem 0;
    font-size: 0.88rem;
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.4fr 1fr;
    gap: 2rem;
}

.footer-block p {
    margin-bottom: 0.6rem;
    max-width: 60ch;
}

.footer-brand {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: #fff;
    font-weight: 700;
}

.site-footer a {
    color: #d9ecf5;
}

/* ---------- Buttons ---------- */

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.45rem;
    border: 1px solid transparent;
    border-radius: 10px;
    padding: 0.62rem 1rem;
    font-size: 0.94rem;
    font-weight: 650;
    line-height: 1.2;
    text-decoration: none;
    cursor: pointer;
    transition: background-color 0.15s ease, border-color 0.15s ease, transform 0.1s ease;
    white-space: normal;
    text-align: center;
}

.btn:active {
    transform: translateY(1px);
}

.btn:disabled,
.btn[aria-disabled="true"] {
    cursor: not-allowed;
    opacity: 0.55;
    transform: none;
}

.btn-primary {
    background: var(--blue-600);
    color: #fff;
    border-color: var(--blue-600);
}

.btn-primary:hover:not(:disabled) {
    background: var(--blue-700);
    border-color: var(--blue-700);
    color: #fff;
}

.btn-secondary {
    background: #fff;
    color: var(--navy-800);
    border-color: var(--line-strong);
}

.btn-secondary:hover:not(:disabled) {
    background: var(--blue-050);
    border-color: var(--blue-500);
    color: var(--navy-900);
}

.btn-ghost {
    background: transparent;
    color: var(--blue-700);
    border-color: transparent;
}

.btn-ghost:hover:not(:disabled) {
    background: var(--blue-100);
    color: var(--blue-700);
}

.btn-danger {
    background: var(--red-500);
    color: #fff;
    border-color: var(--red-500);
}

.btn-danger:hover:not(:disabled) {
    background: var(--red-700);
    border-color: var(--red-700);
    color: #fff;
}

.btn-danger-ghost {
    background: transparent;
    color: var(--red-700);
    border-color: var(--red-100);
}

.btn-danger-ghost:hover:not(:disabled) {
    background: var(--red-100);
}

.btn-sm {
    padding: 0.42rem 0.7rem;
    font-size: 0.85rem;
    border-radius: 8px;
}

.btn-block {
    width: 100%;
}

.text-link {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    font-weight: 600;
    text-decoration: none;
}

.text-link:hover {
    text-decoration: underline;
}

.text-button {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    border: 0;
    background: transparent;
    color: var(--blue-700);
    font-size: 0.87rem;
    font-weight: 600;
    padding: 0.25rem 0;
    cursor: pointer;
}

.text-button:hover {
    text-decoration: underline;
}

.text-button-danger {
    color: var(--red-700);
}

/* ---------- Cards and badges ---------- */

.icon-tile {
    display: grid;
    place-items: center;
    width: 48px;
    height: 48px;
    border-radius: 13px;
    background: linear-gradient(150deg, var(--blue-100), #dff0f5);
    color: var(--teal-700);
    flex: none;
}

.icon-tile-sm {
    width: 36px;
    height: 36px;
    border-radius: 10px;
}

.icon-tile-lg {
    width: 60px;
    height: 60px;
    border-radius: 16px;
}

.icon-tile-muted {
    background: #eef2f6;
    color: var(--muted);
}

.badge {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    padding: 0.18rem 0.55rem;
    border-radius: 999px;
    font-size: 0.76rem;
    font-weight: 700;
    line-height: 1.4;
    border: 1px solid transparent;
    white-space: nowrap;
}

.badge-neutral {
    background: #eef2f6;
    color: var(--ink-soft);
    border-color: #e0e7ee;
}

.badge-row {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    flex-wrap: wrap;
    justify-content: flex-end;
}

.badge-success {
    background: var(--green-100);
    color: var(--green-700);
    border-color: #c6e8d6;
}

.badge-warning {
    background: var(--amber-100);
    color: var(--amber-700);
    border-color: #f0dfb4;
}

.status-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    padding: 0.2rem 0.55rem;
    border-radius: 999px;
    font-size: 0.76rem;
    font-weight: 700;
    border: 1px solid transparent;
    white-space: nowrap;
}

.status-not-started {
    background: #eef2f6;
    color: #3d5265;
    border-color: #dfe6ed;
}

.status-in-progress {
    background: var(--blue-100);
    color: var(--blue-700);
    border-color: #c9dff6;
}

.status-done {
    background: var(--green-100);
    color: var(--green-700);
    border-color: #c6e8d6;
}

.status-not-applicable {
    background: #f1f0f7;
    color: #4a4468;
    border-color: #e2e0ee;
}

.status-needs-review {
    background: var(--amber-100);
    color: var(--amber-700);
    border-color: #f0dfb4;
}

.status-blocked {
    background: var(--amber-100);
    color: var(--amber-700);
    border-color: #f0dfb4;
}

.verification {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    font-size: 0.74rem;
    font-weight: 700;
    padding: 0.12rem 0.45rem;
    border-radius: 999px;
    white-space: nowrap;
}

.verification-verified {
    background: var(--green-100);
    color: var(--green-700);
}

.verification-unverified {
    background: var(--amber-100);
    color: var(--amber-700);
}

.verification-outdated {
    background: var(--red-100);
    color: var(--red-700);
}

/* ---------- Callouts ---------- */

.callout {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    padding: 0.9rem 1rem;
    border-radius: var(--radius);
    border: 1px solid var(--line);
    background: #fff;
    margin-bottom: 1rem;
}

.callout .icon {
    margin-top: 0.1rem;
}

.callout p {
    margin: 0.2rem 0 0;
}

.callout strong {
    display: block;
}

.callout-info {
    background: var(--blue-050);
    border-color: #cfe3f7;
}

.callout-success {
    background: var(--green-100);
    border-color: #c6e8d6;
}

.callout-warning {
    background: var(--amber-100);
    border-color: #efdfb8;
}

.callout-error {
    background: var(--red-100);
    border-color: #f3cfcb;
}

.callout .btn {
    margin-left: auto;
}

/* ---------- Public preview notice ---------- */

.preview-notice {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    padding: 0.75rem 1rem;
    margin: 0 0 1.25rem;
    border: 1px solid #efdfb8;
    border-left: 4px solid var(--amber-500);
    border-radius: var(--radius);
    background: var(--amber-100);
}

.preview-notice .icon {
    margin-top: 0.1rem;
    color: var(--amber-700);
}

.preview-notice h2 {
    margin: 0;
    font-size: 0.95rem;
    letter-spacing: 0.01em;
    color: var(--amber-700);
}

.preview-notice p {
    margin: 0.2rem 0 0;
    font-size: 0.95rem;
}

/* ---------- Home hero ---------- */

.hero {
    position: relative;
    display: grid;
    grid-template-columns: minmax(0, 1.45fr) minmax(280px, 0.85fr);
    gap: 2.2rem;
    align-items: center;
    padding: clamp(1.8rem, 4vw, 3.4rem);
    border-radius: 24px;
    background:
        radial-gradient(1000px 500px at 85% -10%, rgba(31, 156, 148, 0.35), transparent 60%),
        radial-gradient(800px 400px at 10% 120%, rgba(45, 132, 216, 0.25), transparent 55%),
        linear-gradient(140deg, var(--navy-950), var(--navy-800) 55%, #0b4249);
    color: #fff;
    box-shadow: var(--shadow-lg);
    overflow: hidden;
}

.hero::after {
    content: "";
    position: absolute;
    inset: 0;
    background-image: radial-gradient(rgba(255, 255, 255, 0.055) 1px, transparent 1px);
    background-size: 18px 18px;
    pointer-events: none;
}

.hero-copy,
.hero-areas {
    position: relative;
    z-index: 1;
}

.hero h1 {
    color: #fff;
    font-size: clamp(2.1rem, 4.6vw, 3.5rem);
    margin-bottom: 0.7rem;
}

.hero-lead {
    color: #d3e3ee;
    font-size: 1.06rem;
    max-width: 56ch;
}

.search-box {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    background: #fff;
    border-radius: 13px;
    padding: 0.35rem 0.55rem 0.35rem 0.9rem;
    margin: 1.4rem 0 1rem;
    max-width: 560px;
    color: var(--muted);
    box-shadow: 0 6px 20px rgba(4, 18, 30, 0.18);
}

.search-box input {
    flex: 1;
    min-width: 0;
    border: 0;
    background: transparent;
    color: var(--ink);
    padding: 0.55rem 0;
    font-size: 1rem;
}

.search-box input:focus {
    outline: 0;
}

.search-box:focus-within {
    box-shadow: var(--focus);
}

.search-clear {
    display: grid;
    place-items: center;
    width: 2rem;
    height: 2rem;
    border: 0;
    border-radius: 8px;
    background: #eef2f6;
    color: var(--ink-soft);
    cursor: pointer;
}

.hero-points {
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem 1.4rem;
    list-style: none;
    padding: 0;
    margin: 0;
    color: #c8dbe7;
    font-size: 0.85rem;
}

.hero-points li {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
}

.hero-areas {
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
}

.area-tile {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    background: rgba(255, 255, 255, 0.09);
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: 16px;
    padding: 1rem;
    color: #fff;
    text-decoration: none;
    transition: background-color 0.15s ease, border-color 0.15s ease, transform 0.15s ease;
    backdrop-filter: blur(6px);
}

.area-tile:hover {
    background: rgba(255, 255, 255, 0.15);
    border-color: rgba(255, 255, 255, 0.3);
    color: #fff;
    transform: translateY(-1px);
}

.area-tile-icon {
    display: grid;
    place-items: center;
    width: 44px;
    height: 44px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.14);
    color: var(--cyan-300);
    flex: none;
}

.area-tile-copy {
    display: flex;
    flex-direction: column;
    gap: 0.15rem;
    line-height: 1.35;
}

.area-tile-copy strong {
    font-size: 1rem;
}

.area-tile-copy span {
    font-size: 0.83rem;
    color: #c9dbe7;
}

.area-tile-muted {
    opacity: 0.82;
}

/* ---------- Sections ---------- */

.section {
    margin-top: 2.6rem;
}

.section-muted {
    background: #fff;
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    padding: 1.6rem;
    box-shadow: var(--shadow-sm);
}

.section-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 1rem;
    flex-wrap: wrap;
}

.section-head h2 {
    margin-bottom: 0.2rem;
}

.section-intro {
    color: var(--muted);
    max-width: 72ch;
    margin-bottom: 1rem;
}

.card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(270px, 1fr));
    gap: 1rem;
}

.card-grid-3 {
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}

.journey-card {
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 1.15rem;
    box-shadow: var(--shadow-sm);
    transition: box-shadow 0.15s ease, border-color 0.15s ease, transform 0.15s ease;
}

.journey-card:hover {
    box-shadow: var(--shadow);
    border-color: var(--line-strong);
    transform: translateY(-2px);
}

.journey-card-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.8rem;
}

.journey-card-meta {
    font-size: 0.78rem;
    color: var(--muted);
    font-weight: 600;
}

.journey-card-body {
    flex: 1;
}

.journey-card-title {
    margin-bottom: 0.35rem;
    font-size: 1.15rem;
}

.journey-card-title a {
    color: var(--navy-900);
    text-decoration: none;
}

.journey-card-title a:hover {
    text-decoration: underline;
}

.journey-card-text {
    color: var(--muted);
    font-size: 0.92rem;
    margin: 0;
}

.journey-card-progress {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.journey-card-footer {
    display: flex;
    justify-content: flex-start;
}

.resume-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 1rem;
}

.resume-card {
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 1.1rem;
    box-shadow: var(--shadow-sm);
}

.resume-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.6rem;
}

.resume-card h3 {
    margin: 0;
    font-size: 1.05rem;
}

.resume-card h3 a {
    color: var(--navy-900);
    text-decoration: none;
}

.step-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
    gap: 1rem;
    margin-top: 1rem;
}

.info-card {
    background: var(--paper-warm);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 1.15rem;
}

.info-card h3 {
    margin: 0.7rem 0 0.3rem;
    font-size: 1rem;
}

.info-card p {
    color: var(--muted);
    font-size: 0.9rem;
    margin: 0;
}

.coming-card {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.55rem;
    background: var(--surface-soft);
    border: 1px dashed var(--line-strong);
    border-radius: var(--radius);
    padding: 1.1rem;
    color: var(--muted);
    min-height: 150px;
}

.coming-card h3 {
    color: var(--ink-soft);
    font-size: 1rem;
    margin: 0;
}

.trust-strip {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.5rem;
    margin-top: 2.6rem;
    padding: 1.5rem 1.7rem;
    border-radius: var(--radius-lg);
    background: linear-gradient(120deg, #e9f4f3, #eef6fd);
    border: 1px solid #d3e6e7;
}

.trust-strip h2 {
    font-size: 1.2rem;
    margin-bottom: 0.25rem;
}

.trust-strip p {
    margin: 0;
    color: var(--ink-soft);
    max-width: 70ch;
}

.trust-strip .trust-note {
    margin-top: 0.45rem;
}

.disclaimer {
    display: flex;
    gap: 0.8rem;
    align-items: flex-start;
    margin-top: 1.4rem;
    padding: 1rem 1.2rem;
    border-radius: var(--radius);
    background: #fff;
    border: 1px solid var(--line);
    color: var(--muted);
    font-size: 0.88rem;
}

.disclaimer h2 {
    font-size: 0.95rem;
    margin-bottom: 0.2rem;
}

.disclaimer p {
    margin: 0;
}

/* ---------- Page headers and breadcrumbs ---------- */

.breadcrumbs {
    display: flex;
    align-items: center;
    gap: 0.45rem;
    font-size: 0.84rem;
    color: var(--muted);
    margin-bottom: 1.1rem;
    flex-wrap: wrap;
}

.breadcrumbs a {
    color: var(--muted);
    text-decoration: none;
}

.breadcrumbs a:hover {
    color: var(--blue-700);
    text-decoration: underline;
}

.breadcrumbs [aria-current="page"] {
    color: var(--ink-soft);
    font-weight: 600;
}

.page-header {
    display: flex;
    align-items: flex-start;
    gap: 1.1rem;
    margin-bottom: 1.6rem;
}

.page-header h1 {
    margin-bottom: 0.3rem;
}

.journey-header {
    margin-bottom: 1.4rem;
}

.journey-heading {
    display: flex;
    align-items: flex-start;
    gap: 1.1rem;
}

.journey-heading h1 {
    margin-bottom: 0.35rem;
}

.journey-outcome {
    margin: 0.6rem 0 0;
    font-size: 0.92rem;
    color: var(--ink-soft);
    background: #fff;
    border-left: 3px solid var(--teal-500);
    padding: 0.5rem 0.8rem;
    border-radius: 0 8px 8px 0;
}

/* ---------- Panels ---------- */

.panel {
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    padding: 1.4rem;
    box-shadow: var(--shadow-sm);
    margin-bottom: 1.3rem;
}

.panel > h2:first-child,
.panel-head h2 {
    margin-top: 0;
}

.panel > h2 {
    font-size: 1.35rem;
}

.panel > p {
    color: var(--muted);
    max-width: 75ch;
}

.panel-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 1rem;
    flex-wrap: wrap;
}

.panel-head p {
    color: var(--muted);
    margin: 0.15rem 0 0;
    max-width: 72ch;
}

.panel-questions {
    margin-bottom: 1.3rem;
}

.scope-warning {
    margin: 0.9rem 0 1rem;
}

.page-loading {
    display: flex;
    align-items: center;
    gap: 0.7rem;
    padding: 2.5rem 0;
    color: var(--muted);
}

.spinner {
    width: 20px;
    height: 20px;
    border: 2.5px solid var(--line-strong);
    border-top-color: var(--blue-600);
    border-radius: 50%;
    animation: spin 0.9s linear infinite;
    flex: none;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

.empty-panel {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.7rem;
    padding: 2rem;
    border: 1px dashed var(--line-strong);
    border-radius: var(--radius-lg);
    background: var(--surface-soft);
    color: var(--muted);
}

.empty-panel h1 {
    margin: 0;
    font-size: 1.5rem;
    color: var(--navy-900);
}

/* ---------- Questions ---------- */

.question-block {
    border: 0;
    border-top: 1px solid var(--line);
    padding: 1.2rem 0 0;
    margin: 1.2rem 0 0;
}

.question-block:first-of-type {
    border-top: 0;
    padding-top: 0;
    margin-top: 0;
}

.question-title {
    display: block;
    font-size: 1.06rem;
    font-weight: 700;
    color: var(--navy-900);
    padding: 0;
    margin-bottom: 0.25rem;
}

.question-help {
    color: var(--muted);
    font-size: 0.9rem;
    max-width: 72ch;
}

.question-kind {
    margin-bottom: 0.65rem;
}

.option-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 0.7rem;
}

.option-card {
    position: relative;
    display: flex;
    align-items: flex-start;
    gap: 0.65rem;
    padding: 0.85rem 0.9rem;
    border: 1.5px solid var(--line);
    border-radius: 12px;
    background: #fff;
    cursor: pointer;
    transition: border-color 0.12s ease, background-color 0.12s ease, box-shadow 0.12s ease;
}

.option-card:hover {
    border-color: var(--blue-500);
    background: var(--blue-050);
}

.option-card.is-selected {
    border-color: var(--blue-600);
    background: var(--blue-050);
    box-shadow: inset 0 0 0 1px var(--blue-600);
}

.choice-input {
    position: absolute;
    opacity: 0;
    width: 1px;
    height: 1px;
    pointer-events: none;
}

.option-card:focus-within {
    box-shadow: var(--focus);
}

.option-check {
    display: grid;
    place-items: center;
    width: 22px;
    height: 22px;
    border: 1.5px solid var(--line-strong);
    border-radius: 50%;
    color: transparent;
    background: #fff;
    flex: none;
    margin-top: 1px;
}

.option-card.is-selected .option-check {
    background: var(--blue-600);
    border-color: var(--blue-600);
    color: #fff;
}

.option-card input[type="checkbox"] + .option-check {
    border-radius: 6px;
}

.option-body {
    display: flex;
    flex-direction: column;
    gap: 0.18rem;
    min-width: 0;
}

.option-prefix {
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--teal-700);
}

.option-label {
    font-weight: 650;
    color: var(--navy-900);
    line-height: 1.35;
}

.option-description {
    font-size: 0.86rem;
    color: var(--muted);
    line-height: 1.45;
}

.reuse-hint {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;
    margin-top: 0.7rem;
    padding: 0.55rem 0.75rem;
    background: #f3faf8;
    border: 1px solid #d3e9e4;
    border-radius: 10px;
    font-size: 0.86rem;
    color: var(--teal-700);
}

.reuse-hint .btn {
    margin-left: auto;
}

.locked-panel {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    padding: 1.3rem 1.4rem;
    border: 1px dashed var(--line-strong);
    border-radius: var(--radius-lg);
    background: var(--surface-soft);
    color: var(--ink-soft);
}

/* ---------- Journey layout ---------- */

.journey-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 320px;
    gap: 1.3rem;
    align-items: start;
}

.journey-main {
    min-width: 0;
}

.journey-aside {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    position: sticky;
    top: 1rem;
}

.side-card {
    background: #fff;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 1.1rem;
    box-shadow: var(--shadow-sm);
}

.side-card h2 {
    font-size: 1.05rem;
    margin-bottom: 0.5rem;
}

.side-card .btn {
    margin-top: 0.7rem;
}

.next-card {
    border-top: 4px solid var(--teal-500);
}

.next-card .eyebrow {
    margin-bottom: 0.25rem;
}

.next-card h2 {
    font-size: 1.12rem;
}

.side-profile-name {
    font-weight: 700;
    margin-bottom: 0.15rem;
    word-break: break-word;
}

.progress-track {
    height: 10px;
    border-radius: 999px;
    background: #e8eef4;
    overflow: hidden;
}

.progress-fill {
    display: block;
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(90deg, var(--blue-500), var(--teal-500));
    transition: width 0.35s ease;
}

.progress-fill.is-complete {
    background: linear-gradient(90deg, var(--green-500), #46b681);
}

.progress-caption {
    margin: 0.55rem 0 0.15rem;
    font-weight: 650;
    font-size: 0.9rem;
    color: var(--ink-soft);
}

.phase {
    margin-top: 1.4rem;
}

.phase:first-of-type {
    margin-top: 0.5rem;
}

.phase-title {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--teal-700);
    margin-bottom: 0.7rem;
}

.phase-title::after {
    content: "";
    width: 42px;
    height: 1px;
    background: var(--line-strong);
}

.step-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 0.85rem;
}

.step-card {
    display: grid;
    grid-template-columns: 38px minmax(0, 1fr);
    gap: 0.85rem;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 1rem 1.05rem;
    scroll-margin-top: 90px;
    box-shadow: var(--shadow-sm);
}

.step-card:target {
    border-color: var(--blue-600);
    box-shadow: var(--focus), var(--shadow-sm);
}

.step-card.is-resolved {
    background: #fbfefc;
    border-color: #d6eadf;
}

.step-card.is-blocked {
    background: #fffdf8;
    border-color: #efe1c3;
}

.step-rail {
    display: grid;
    place-items: center;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: var(--navy-900);
    color: #fff;
    font-weight: 700;
    font-size: 0.85rem;
    flex: none;
}

.step-card.is-resolved .step-rail {
    background: var(--green-500);
}

.step-card.is-blocked .step-rail {
    background: var(--amber-500);
}

.step-body {
    min-width: 0;
}

.step-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 0.8rem;
    margin-bottom: 0.35rem;
}

.step-head h4 {
    font-size: 1.03rem;
    line-height: 1.35;
    padding-top: 0.1rem;
}

.step-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.35rem 0.8rem;
    font-size: 0.8rem;
    color: var(--muted);
    margin-bottom: 0.55rem;
}

.step-meta > span {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
}

.step-instruction {
    color: var(--ink-soft);
    font-size: 0.94rem;
    margin-bottom: 0.55rem;
}

.blocker-panel {
    background: var(--amber-100);
    border: 1px solid #efdfb8;
    border-radius: 10px;
    padding: 0.7rem 0.85rem;
    margin: 0.55rem 0;
    font-size: 0.88rem;
}

.blocker-title {
    display: flex;
    align-items: center;
    gap: 0.35rem;
    font-weight: 700;
    color: var(--amber-700);
    margin-bottom: 0.3rem;
}

.blocker-panel ul {
    margin: 0 0 0.3rem;
    padding-left: 1.2rem;
}

.blocker-panel li {
    margin-bottom: 0.15rem;
}

.provider-action {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    flex-wrap: wrap;
    margin: 0.6rem 0;
}

.step-actions {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;
    margin: 0.8rem 0 0.5rem;
}

.inline-details {
    margin: 0.55rem 0;
    border: 1px solid var(--line);
    border-radius: 10px;
    background: var(--surface-soft);
    padding: 0.5rem 0.75rem;
}

.inline-details > summary {
    cursor: pointer;
    font-size: 0.85rem;
    font-weight: 650;
    color: var(--ink-soft);
    list-style-position: outside;
}

.inline-details > summary:hover {
    color: var(--blue-700);
}

.inline-details[open] > summary {
    margin-bottom: 0.6rem;
}

.inline-details p {
    font-size: 0.9rem;
    color: var(--muted);
}

.chip-row {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
    list-style: none;
    padding: 0;
    margin: 0.6rem 0;
}

.chip {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    background: #f0f5f9;
    border: 1px solid var(--line);
    border-radius: 999px;
    padding: 0.22rem 0.6rem;
    font-size: 0.78rem;
    color: var(--ink-soft);
}

.reason-panel {
    display: flex;
    flex-direction: column;
    gap: 0.45rem;
    background: #f7f9fb;
    border: 1px solid var(--line);
    border-radius: 10px;
    padding: 0.8rem;
    margin: 0.4rem 0 0.6rem;
    max-width: 520px;
}

.reason-actions {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.field-label {
    display: block;
    font-size: 0.82rem;
    font-weight: 700;
    color: var(--ink-soft);
    margin-bottom: 0.25rem;
}

input:not([type="radio"]):not([type="checkbox"]):not([type="file"]),
select,
textarea {
    width: 100%;
    border: 1px solid var(--line-strong);
    border-radius: 9px;
    background: #fff;
    padding: 0.55rem 0.7rem;
    font-size: 0.93rem;
    color: var(--ink);
}

textarea {
    resize: vertical;
    min-height: 84px;
    line-height: 1.5;
}

input:focus,
select:focus,
textarea:focus {
    outline: 0;
    border-color: var(--blue-500);
    box-shadow: var(--focus);
}

input:disabled,
select:disabled,
textarea:disabled {
    background: #f4f6f8;
    color: var(--muted);
}

.checkline {
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
    font-size: 0.88rem;
    color: var(--ink-soft);
    cursor: pointer;
}

.checkline input {
    width: 1.05rem;
    height: 1.05rem;
    margin-top: 0.15rem;
    accent-color: var(--blue-600);
}

.provider-help {
    margin: 0.2rem 0 0.6rem 1.55rem;
}

.note-editor {
    border-top: 1px solid var(--line);
    margin-top: 0.6rem;
    padding-top: 0.55rem;
}

.note-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.6rem;
    margin-top: 0.4rem;
}

.inline-error {
    display: block;
    color: var(--red-700);
    background: var(--red-100);
    border: 1px solid #f3cfcb;
    border-radius: 8px;
    padding: 0.45rem 0.65rem;
    font-size: 0.86rem;
    margin: 0.4rem 0;
}

.inline-warning {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    color: var(--amber-700);
    background: var(--amber-100);
    border-radius: 8px;
    padding: 0.3rem 0.55rem;
    font-size: 0.84rem;
    font-weight: 600;
}

.step-updated {
    margin-top: 0.5rem;
}

/* ---------- Documents ---------- */

.document-list {
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
}

.document-card {
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 0.95rem 1rem;
    background: var(--surface-soft);
}

.document-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 0.7rem;
    margin-bottom: 0.25rem;
}

.document-head h3 {
    font-size: 1rem;
    margin: 0;
}

.document-card p {
    font-size: 0.9rem;
    color: var(--ink-soft);
}

.segmented {
    display: inline-flex;
    flex-wrap: wrap;
    gap: 2px;
    padding: 3px;
    border-radius: 10px;
    background: #e9eff4;
    border: 1px solid var(--line);
    margin-top: 0.4rem;
}

.segmented-button {
    border: 0;
    background: transparent;
    color: var(--ink-soft);
    font-size: 0.82rem;
    font-weight: 650;
    padding: 0.35rem 0.65rem;
    border-radius: 7px;
    cursor: pointer;
}

.segmented-button.is-active {
    background: #fff;
    color: var(--blue-700);
    box-shadow: var(--shadow-sm);
}

.segmented-button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* ---------- Sources ---------- */

.source-list {
    list-style: none;
    padding: 0;
    margin: 0.6rem 0 0;
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
}

.source-card {
    border: 1px solid var(--line);
    border-radius: 10px;
    background: #fff;
    padding: 0.7rem 0.8rem;
}

.source-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.6rem;
    margin-bottom: 0.15rem;
}

.source-publisher {
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--teal-700);
}

.source-title {
    margin: 0 0 0.2rem;
    font-weight: 650;
    font-size: 0.9rem;
}

.source-title a {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    color: var(--navy-800);
}

.source-claim {
    font-size: 0.85rem;
    color: var(--ink-soft);
    margin: 0 0 0.2rem;
}

.source-label {
    font-weight: 700;
}

.source-note {
    font-size: 0.82rem;
    color: var(--amber-700);
    background: var(--amber-100);
    border-radius: 6px;
    padding: 0.3rem 0.45rem;
    margin: 0.25rem 0;
}

.source-meta {
    font-size: 0.76rem;
    color: var(--muted);
    margin: 0;
}

.source-disclaimer {
    color: var(--muted);
    margin: 0.6rem 0 0;
}

/* ---------- Forms and data ---------- */

.two-col {
    display: grid;
    grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
    gap: 1.2rem;
    align-items: start;
    margin-top: 1.2rem;
}

.form-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.85rem;
    margin: 1rem 0;
}

.field {
    display: flex;
    flex-direction: column;
}

.field-wide {
    grid-column: 1 / -1;
}

.field input,
.field select {
    width: 100%;
}

.form-actions {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    flex-wrap: wrap;
    margin-top: 0.8rem;
}

.data-actions {
    display: flex;
    gap: 0.6rem;
    flex-wrap: wrap;
    margin: 0.8rem 0 1rem;
}

.file-field {
    border-top: 1px solid var(--line);
    padding-top: 0.9rem;
}

.file-control {
    position: relative;
    display: inline-flex;
    margin-top: 0.2rem;
}

.file-control-button {
    pointer-events: none;
}

.file-control-input {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    cursor: pointer;
}

.file-control:focus-within {
    border-radius: 10px;
    box-shadow: var(--focus);
}

.file-name {
    margin: 0.35rem 0 0;
    color: var(--ink-soft);
    overflow-wrap: anywhere;
}

.profile-details {
    margin-top: 0.9rem;
    padding: 0.75rem 0.9rem;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: var(--surface-soft);
}

.profile-details > summary {
    cursor: pointer;
    font-weight: 650;
    color: var(--ink-soft);
    padding: 0.15rem 0;
}

.profile-details > summary:hover {
    color: var(--blue-700);
}

.profile-details[open] > summary {
    margin-bottom: 0.85rem;
}

.profile-details > .callout {
    margin-top: 0;
}

.preview-panel {
    border: 1px solid var(--line);
    border-radius: 10px;
    background: var(--surface-soft);
    padding: 0.9rem;
    margin: 0.8rem 0;
}

.preview-panel h3 {
    font-size: 0.98rem;
}

.warning-list {
    margin: 0.4rem 0 0;
    font-size: 0.85rem;
    color: var(--ink-soft);
}

.confirm-panel {
    border: 1px solid #f3cfcb;
    background: var(--red-100);
    border-radius: 10px;
    padding: 0.8rem;
    margin: 0.7rem 0;
}

.confirm-inline {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;
    width: 100%;
}

.saved-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1rem;
}

.saved-card {
    background: #fff;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 1.1rem;
    box-shadow: var(--shadow-sm);
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.saved-head {
    display: flex;
    align-items: flex-start;
    gap: 0.7rem;
}

.saved-head h3 {
    font-size: 1rem;
    margin: 0;
}

.saved-head h3 a {
    color: var(--navy-900);
    text-decoration: none;
}

.saved-head p {
    margin: 0;
}

.saved-actions {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;
    margin-top: 0.45rem;
}

/* ---------- Prose ---------- */

.prose {
    max-width: 78ch;
}

.prose section {
    margin-bottom: 1.6rem;
}

.prose h2 {
    font-size: 1.25rem;
    margin-bottom: 0.4rem;
}

.prose p {
    color: var(--ink-soft);
}

/* ---------- Print sheet ---------- */

.print-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 0.6rem;
    flex-wrap: wrap;
}

.print-sheet {
    background: #fff;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: clamp(1.2rem, 4vw, 18mm);
    max-width: 210mm;
    margin: 1rem auto 2rem;
    box-shadow: var(--shadow);
}

.sheet-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    border-bottom: 2px solid var(--navy-900);
    padding-bottom: 0.7rem;
    margin-bottom: 1.2rem;
}

.sheet-head p {
    margin: 0;
}

.sheet-brand {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 800;
    color: var(--navy-900);
    letter-spacing: 0.01em;
}

.sheet-title {
    margin-bottom: 1.4rem;
}

.sheet-title h1 {
    font-size: 1.75rem;
    margin-bottom: 0.4rem;
}

.sheet-section {
    margin-bottom: 1.5rem;
}

.sheet-section h2 {
    font-size: 1.05rem;
    border-bottom: 1px solid var(--line);
    padding-bottom: 0.3rem;
    margin-bottom: 0.7rem;
}

.sheet-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 0.5rem 1.2rem;
    margin: 0;
}

.sheet-list > div {
    margin: 0;
}

.sheet-list dt {
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    font-weight: 700;
    color: var(--muted);
}

.sheet-list dd {
    margin: 0 0 0.35rem;
    font-size: 0.94rem;
    color: var(--ink);
    overflow-wrap: anywhere;
}

.sheet-steps {
    padding-left: 1.1rem;
    margin: 0;
}

.sheet-steps li {
    margin-bottom: 0.7rem;
}

.sheet-step-head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 0.7rem;
}

.sheet-step-title {
    font-weight: 650;
}

.sheet-step-status {
    font-size: 0.76rem;
    font-weight: 700;
    padding: 0.1rem 0.45rem;
    border-radius: 999px;
    background: #eef2f6;
    color: var(--ink-soft);
    white-space: nowrap;
}

.sheet-step-status.status-done {
    background: var(--green-100);
    color: var(--green-700);
}

.sheet-step-status.status-needs-review,
.sheet-step-status.status-blocked {
    background: var(--amber-100);
    color: var(--amber-700);
}

.sheet-step-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.2rem 0.9rem;
    font-size: 0.78rem;
    color: var(--muted);
}

.sheet-note {
    font-size: 0.85rem;
    background: var(--surface-soft);
    border-left: 3px solid var(--line-strong);
    padding: 0.25rem 0.5rem;
    margin: 0.25rem 0 0;
    white-space: pre-wrap;
    overflow-wrap: anywhere;
}

.sheet-documents {
    list-style: none;
    padding: 0;
    margin: 0;
}

.sheet-documents li {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 0.3rem 0.8rem;
    padding: 0.35rem 0;
    border-bottom: 1px solid var(--line);
}

.sheet-doc-name {
    font-weight: 600;
}

.sheet-doc-status {
    margin-left: auto;
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--ink-soft);
}

.print-sources {
    padding-left: 1rem;
    font-size: 0.85rem;
}

.print-sources li {
    margin-bottom: 0.55rem;
}

.print-sources a {
    color: var(--navy-800);
    overflow-wrap: anywhere;
}

.sheet-footer {
    border-top: 1px solid var(--line-strong);
    padding-top: 0.8rem;
    margin-top: 1.6rem;
}

.sheet-footer h2 {
    font-size: 0.95rem;
}

.sheet-footer p {
    font-size: 0.82rem;
    color: var(--muted);
}

/* ---------- Blazor error UI ---------- */

#blazor-error-ui {
    display: none;
    position: fixed;
    left: 50%;
    bottom: 1rem;
    transform: translateX(-50%);
    z-index: 1000;
    background: var(--red-100);
    color: var(--red-700);
    border: 1px solid #f3cfcb;
    border-radius: 10px;
    padding: 0.7rem 1rem;
    box-shadow: var(--shadow-lg);
    font-size: 0.88rem;
    gap: 0.8rem;
    align-items: center;
    max-width: min(92vw, 640px);
}

#blazor-error-ui .reload {
    color: var(--red-700);
    font-weight: 700;
}

#blazor-error-ui .dismiss {
    cursor: pointer;
    font-weight: 700;
    padding: 0 0.2rem;
}

/* ---------- Responsive ---------- */

@media (max-width: 1000px) {
    .journey-layout {
        grid-template-columns: minmax(0, 1fr);
    }

    .journey-aside {
        position: static;
        order: -1;
        display: grid;
        grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    }

    .hero {
        grid-template-columns: minmax(0, 1fr);
    }

    .hero-areas {
        display: grid;
        grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    }
}

@media (max-width: 860px) {
    .header-row {
        gap: 0.7rem;
    }

    .main-nav {
        order: 3;
        width: 100%;
        flex-wrap: wrap;
        row-gap: 0.1rem;
        padding-bottom: 0.15rem;
    }

    .main-nav a {
        white-space: nowrap;
    }

    .two-col {
        grid-template-columns: minmax(0, 1fr);
    }

    .footer-grid {
        grid-template-columns: minmax(0, 1fr);
        gap: 1.2rem;
    }

    .form-grid {
        grid-template-columns: minmax(0, 1fr);
    }

    .trust-strip {
        flex-direction: column;
        align-items: flex-start;
    }

    .option-grid {
        grid-template-columns: minmax(0, 1fr);
    }
}

@media (max-width: 640px) {
    body {
        font-size: 15.5px;
    }

    .shell {
        width: calc(100% - 1.5rem);
    }

    .site-main {
        padding-top: 1.2rem;
    }

    .hero {
        padding: 1.3rem;
        border-radius: 18px;
    }

    .hero h1 {
        font-size: 2rem;
    }

    .panel {
        padding: 1rem;
        border-radius: var(--radius);
    }

    .journey-heading,
    .page-header {
        gap: 0.7rem;
    }

    .icon-tile-lg {
        width: 46px;
        height: 46px;
        border-radius: 13px;
    }

    .step-card {
        grid-template-columns: minmax(0, 1fr);
        padding: 0.9rem;
    }

    .step-rail {
        width: 28px;
        height: 28px;
        font-size: 0.78rem;
    }

    .step-head {
        flex-direction: column;
        gap: 0.35rem;
    }

    .panel-head .badge-row {
        justify-content: flex-start;
    }

    .question-block {
        padding-top: 0.9rem;
        margin-top: 0.9rem;
    }

    .question-kind {
        margin-bottom: 0.5rem;
    }

    .option-grid {
        gap: 0.55rem;
    }

    .option-card {
        padding: 0.75rem 0.8rem;
    }

    .saved-actions .btn {
        flex: 1 1 auto;
    }

    .print-sheet {
        padding: 1rem;
        border: 0;
        box-shadow: none;
        margin: 0 auto 1rem;
    }

    .sheet-head {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.3rem;
    }

    .sheet-step-head {
        flex-direction: column;
        gap: 0.15rem;
    }
}

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }

    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* ---------- Print ---------- */

@media print {
    @page {
        size: A4;
        margin: 14mm;
    }

    body {
        background: #fff;
        color: #000;
        font-size: 10.5pt;
    }

    .site-header,
    .site-footer,
    .no-print,
    #blazor-error-ui,
    .components-reconnect-container,
    .callout .btn {
        display: none !important;
    }

    .site-main {
        width: 100%;
        max-width: none;
        padding: 0;
        margin: 0;
    }

    .print-sheet {
        max-width: none;
        margin: 0;
        padding: 0;
        border: 0;
        border-radius: 0;
        box-shadow: none;
    }

    .sheet-section {
        break-inside: avoid;
    }

    .sheet-steps li,
    .source-card,
    .document-card {
        break-inside: avoid;
    }

    .print-sources a[href]::after {
        content: " (" attr(href) ")";
        font-size: 8.5pt;
        color: #333;
    }

    a {
        color: #000;
        text-decoration: none;
    }

    .sheet-step-status,
    .verification {
        border: 1px solid #999;
        background: transparent !important;
        color: #000 !important;
    }
}

/* ---------- Task-first discovery ---------- */

.hero-simple {
    display: block;
}

.hero-simple .hero-copy {
    max-width: 780px;
}

.search-hint {
    color: #c8dbe7;
    font-size: 0.82rem;
    margin: -0.55rem 0 1rem;
}

.search-label {
    display: block;
    color: #d3e3ee;
    font-size: 0.85rem;
    font-weight: 600;
    margin: 1.2rem 0 0.35rem;
}

.search-label + .search-box {
    margin-top: 0.2rem;
}

.task-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1rem;
}

.task-card {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 0.65rem;
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    padding: 1.25rem;
    box-shadow: var(--shadow-sm);
    transition: box-shadow 0.15s ease, border-color 0.15s ease, transform 0.15s ease;
}

.task-card:hover {
    box-shadow: var(--shadow);
    border-color: var(--line-strong);
    transform: translateY(-2px);
}

.task-card:focus-within {
    border-color: var(--blue-500);
    box-shadow: var(--focus);
}

.task-card-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.8rem;
}

.task-card-title {
    font-size: 1.2rem;
    margin: 0;
}

.task-card-title a {
    color: var(--navy-900);
    text-decoration: none;
}

.task-card-title a::after {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: var(--radius-lg);
}

.task-card-title a:focus-visible {
    outline: none;
}

.task-card-text {
    color: var(--muted);
    margin: 0;
}

.task-card-note {
    background: var(--amber-100);
    color: var(--amber-700);
    border-radius: var(--radius-sm);
    padding: 0.55rem 0.7rem;
    font-size: 0.85rem;
    margin: 0;
}

@media (max-width: 640px) {
    .task-card-note {
        font-size: 0.8rem;
        padding: 0.45rem 0.55rem;
    }
}

.task-card-progress {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.task-card-cta {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    color: var(--blue-700);
    font-weight: 600;
    font-size: 0.9rem;
    margin-top: auto;
}

.task-card-upcoming {
    background: var(--surface-soft);
    border-style: dashed;
}

.task-card-upcoming .task-card-title a {
    color: var(--ink-soft);
}

.coverage-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    padding: 0.2rem 0.5rem;
    border-radius: 999px;
    font-size: 0.75rem;
    font-weight: 600;
    line-height: 1.4;
    border: 1px solid transparent;
    white-space: nowrap;
}

.coverage-available {
    background: var(--green-100);
    color: var(--green-700);
    border-color: #b9e4cc;
}

.coverage-partial {
    background: var(--amber-100);
    color: var(--amber-700);
    border-color: #efd9a8;
}

.coverage-upcoming {
    background: #e8eef4;
    color: var(--muted);
    border-color: var(--line-strong);
}

.search-group + .search-group {
    margin-top: 1.6rem;
}

.search-group-title {
    display: flex;
    align-items: baseline;
    gap: 0.4rem;
    font-size: 1.05rem;
    margin-bottom: 0.7rem;
}

.compact-links {
    list-style: none;
    padding: 0;
    margin: 0;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 0.7rem;
}

.compact-links a {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 0.85rem 1rem;
    text-decoration: none;
    color: var(--navy-900);
    box-shadow: var(--shadow-sm);
}

.compact-links a:hover {
    border-color: var(--line-strong);
    box-shadow: var(--shadow);
}

.compact-copy {
    display: flex;
    flex-direction: column;
    gap: 0.1rem;
    flex: 1;
    min-width: 0;
}

.compact-copy span {
    color: var(--muted);
    font-size: 0.85rem;
}

.check-list {
    list-style: none;
    padding: 0;
    display: grid;
    gap: 0.5rem;
}

.check-list li {
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
}

.button-row,
.journey-actions {
    display: flex;
    gap: 0.8rem;
    flex-wrap: wrap;
    margin-top: 1rem;
}

.report-link {
    font-size: 0.9rem;
}

.source-method {
    color: var(--amber-700);
}

@media (max-width: 820px) {
    .task-grid {
        grid-template-columns: 1fr;
    }
}

/* v1.1 breadth: coverage states, themes and scope pages */
.coverage-pending {
    background: #eef2f8;
    color: #35507a;
    border-color: #cdd9ea;
}

.task-card-pending {
    border-color: #cdd9ea;
}

.theme-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 1rem;
}

.theme-card {
    display: flex;
    flex-direction: column;
    gap: 0.45rem;
    padding: 1.1rem;
    border: 1px solid var(--line-strong);
    border-radius: var(--radius-lg);
    background: var(--surface);
}

.theme-card h3 {
    margin: 0;
    font-size: 1.05rem;
}

.theme-card h3 a {
    color: inherit;
    text-decoration: none;
}

.theme-card h3 a:hover {
    text-decoration: underline;
}

.theme-card p {
    margin: 0;
    color: var(--ink-soft);
}

.panel-scope {
    border-color: #efd9a8;
}

.contact-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 1rem;
    margin: 1rem 0;
}

.contact-card {
    padding: 1rem;
    border: 1px solid var(--line-strong);
    border-radius: var(--radius-md);
    background: var(--surface-soft);
}

.contact-card h4 {
    margin: 0 0 0.4rem;
    font-size: 1rem;
}

.contact-card p {
    margin: 0 0 0.7rem;
}

.advisory-panel {
    margin: 0.7rem 0;
    padding: 0.7rem 0.9rem;
    border-left: 3px solid #cdd9ea;
    background: var(--surface-soft);
    border-radius: var(--radius-sm);
}

.advisory-panel p {
    margin: 0.2rem 0;
}

.advisory-panel ul {
    margin: 0.2rem 0 0.35rem 1.1rem;
}

.scope-inline {
    display: flex;
    align-items: flex-start;
    gap: 0.4rem;
    margin: 0.4rem 0 1rem;
    padding: 0.6rem 0.8rem;
    border-radius: var(--radius-sm);
    background: var(--amber-100);
    color: var(--amber-700);
}

.user-reported {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    margin: 0.6rem 0;
}
