
  @font-face {
    font-family: 'Inter';
    font-style: normal;
    font-weight: 400 700;
    font-display: swap;
    src: url('../assets/fonts/inter-var.woff2') format('woff2');
  }

  :root {
    --page-bg: #FAFAF8;
    --page-surface: #FFFFFF;
    --page-text: #201E1B;
    --page-text-soft: #6B6862;
    --page-line: #E5E2DB;
    --ochre: #C6741E;
    --sienna: #A24E20;
    --amber: #D8994A;
    --wheat: #E4B877;
    --leaf: #7FAE5E;
    --sand: #EBD8B8;

    /* In-app product tokens — light, warm, atmospheric.
       Not theme-responsive: this is Rundle's product surface, not page chrome. */
    --ink: #2A2622;
    --ink-soft: #6B6258;
    --ink-onlight: #2A2622;
    --ink-onlight-soft: #6B6258;
    --bg: #E6EFEA;
    --surface: #FBFCFA;
    --surface-raised: #FBFCFA;
    --line: #DCE6E1;
    --line-onlight: #DCE6E1;
    --good: #2F6B57;
    --good-bg: #E3F0EA;
    --good-onlight: #2F6B57;
    --good-bg-onlight: #E3F0EA;
    --phone-notch: #000000;
    --shadow-color: 226 60% 10%;

    /* Deliberately NOT a brand color — used only for "this is a demo
       artifact, not the product" notices, so they never blend in. */
    --demo-accent: #6D28D9;
    --demo-accent-soft: #EDE6FB;
  }

  @media (prefers-color-scheme: dark) {
    :root:not([data-theme="light"]) {
      --page-bg: #131211;
      --page-surface: #1B1917;
      --page-text: #F1EFEA;
      --page-text-soft: #A7A29A;
      --page-line: #322E28;
    }
  }
  :root[data-theme="dark"] {
    --page-bg: #131211;
    --page-surface: #1B1917;
    --page-text: #F1EFEA;
    --page-text-soft: #A7A29A;
    --page-line: #322E28;
  }

  .card, .persona-card, .metric-box, .field-input, .demo-banner {
    box-shadow: 0 0.2rem 0.5rem rgba(60, 45, 20, 0.08);
  }

  * { box-sizing: border-box; }
  html, body {
    margin: 0;
    padding: 0;
    background: var(--page-bg);
    color: var(--page-text);
    font-family: 'Inter', ui-sans-serif, system-ui, sans-serif;
    overflow-x: hidden;
  }
  body {
    padding: 0 0 5rem;
    background:
      radial-gradient(60rem 30rem at 15% 0%, color-mix(in srgb, var(--ochre) 10%, transparent), transparent 70%),
      radial-gradient(50rem 26rem at 100% 8%, color-mix(in srgb, var(--amber) 9%, transparent), transparent 65%),
      var(--page-bg);
  }
  @media (prefers-color-scheme: dark) {
    :root:not([data-theme="light"]) body {
      background:
        radial-gradient(60rem 30rem at 15% 0%, color-mix(in srgb, var(--ochre) 16%, transparent), transparent 70%),
        radial-gradient(50rem 26rem at 100% 8%, color-mix(in srgb, var(--amber) 12%, transparent), transparent 65%),
        var(--page-bg);
    }
  }
  :root[data-theme="dark"] body {
    background:
      radial-gradient(60rem 30rem at 15% 0%, color-mix(in srgb, var(--ochre) 16%, transparent), transparent 70%),
      radial-gradient(50rem 26rem at 100% 8%, color-mix(in srgb, var(--amber) 12%, transparent), transparent 65%),
      var(--page-bg);
  }
  /* Desktop: the phone frame stays a fixed-width card, but the page around
     it fills with a full-bleed render instead of empty margins. On an
     actual phone the viewport is already narrower than #app's max-width, so
     #app fills the screen edge-to-edge on its own — no separate mobile rule
     needed. */
  @media (min-width: 40rem) {
    /* Every other screen is deliberately light. Landscape vs. portrait
       wasn't the actual bug: background-size:cover computes its zoom
       relative to EACH element's own box, and #app (tall, narrow) has a
       very different aspect ratio than the margin (short, wide) — so even
       the identical image zooms differently in each and still shows a seam.
       background-attachment:fixed anchors the sizing to the viewport
       instead of each element's own box, so #app and body render the exact
       same pixels at the exact same scale — true continuity, not just a
       closer approximation. */
    body { background: url('../assets/img/bg-desktop-light.png') center/cover no-repeat fixed; }
    body:not(.cover-active) #app { background: url('../assets/img/bg-desktop-light.png') center/cover no-repeat fixed; }
    /* Only the cover screen is meant to be one continuous dark-green 16:9
       image behind everything. app.js toggles body.cover-active only while
       the cover screen is showing. Rather than layering a second (portrait)
       cover image inside #app and trying to blend the seam between two
       different crops, just make #app and .cover-screen transparent here so
       body's single landscape image shows through uninterrupted underneath
       the content — there's no seam because there's only one image. */
    body.cover-active { background: url('../assets/img/bg-desktop.png') center/cover no-repeat; }
    body.cover-active #app { background: transparent; box-shadow: none; }
    body.cover-active #screen-cover { background: transparent; }
    body.cover-active .cover-screen { background: transparent; }
  }
  h1, h2, h3, .display {
    font-family: 'Fraunces', ui-sans-serif, system-ui, sans-serif;
    text-wrap: balance;
    margin: 0;
  }
  .mono {
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    font-variant-numeric: tabular-nums;
  }

  /* ---------- App shell (fills the real device viewport) ---------- */
  html, body, #app {
    height: 100%;
  }
  #app {
    position: fixed;
    top: 0; bottom: 0; left: 50%;
    transform: translateX(-50%);
    width: 100%;
    max-width: 30rem;
    background: url('../assets/img/bg-light.jpg?v=2') center/cover no-repeat, var(--bg);
    color: var(--ink);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    box-shadow: 0 2rem 5rem -1.5rem hsl(var(--shadow-color) / 0.35);
  }
  .screen {
    display: none;
    flex-direction: column;
    flex: 1;
    min-height: 0;
    position: relative;
    overflow: hidden;
    background: rgba(230, 239, 234, 0.75);
    color: var(--ink);
  }
  .screen.active { display: flex; }
  .statusbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.55rem 1.15rem 0.15rem;
    font-size: 0.72rem;
    font-weight: 600;
    color: var(--ink);
    flex: none;
  }
  .statusbar .icons { display: flex; align-items: center; gap: 0.28rem; }
  .screen-body {
    flex: 1;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    min-height: 0;
  }
  .scroll { overflow-y: auto; flex: 1; -webkit-overflow-scrolling: touch; }
  .scroll::-webkit-scrollbar { width: 0; }

  /* ---------- Tab bar ---------- */
  .tabbar {
    flex: none;
    display: flex;
    border-top: 1px solid rgba(60,45,20,0.1);
    background: rgba(240,247,244,0.75);
    backdrop-filter: blur(14px);
    padding: 0.5rem 0.4rem 0.7rem;
  }
  .tab {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.2rem;
    font-size: 0.62rem;
    font-weight: 600;
    color: var(--ink-soft);
  }
  .tab.active { color: var(--ochre); }
  .tab svg { width: 1.15rem; height: 1.15rem; }
  .tab { cursor: pointer; }

  /* ---------- Interactive affordances (real app, not gallery) ---------- */
  .cover-cta, .persona-card, .cta, .map-match-btn,
  .link-row, .match-positions-link, .match-card,
  .toggle-row .switch, .check-row { cursor: pointer; }

  /* ---------- Shared content bits ---------- */
  .app-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.7rem 1.1rem 0.5rem;
    flex: none;
  }
  .identity { display: flex; align-items: center; gap: 0.55rem; }
  .rec-badge {
    display: flex; align-items: center; gap: 0.32rem; flex: none;
    font-size: 0.64rem; font-weight: 700; letter-spacing: 0.03em;
    color: #D3352C; background: rgba(211,53,44,0.1);
    padding: 0.25rem 0.55rem; border-radius: 999px;
  }
  .rec-dot { width: 0.42rem; height: 0.42rem; border-radius: 999px; background: #D3352C; animation: recPulse 1.4s ease-in-out infinite; }
  @keyframes recPulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.25; } }
  .avatar {
    width: 2.1rem; height: 2.1rem; border-radius: 999px;
    background: var(--amber);
    color: #fff; display: flex; align-items: center; justify-content: center;
    font-family: 'Fraunces'; font-weight: 600; font-size: 0.75rem; flex: none;
    overflow: hidden;
  }
  .avatar svg, .avatar img { width: 100%; height: 100%; display: block; object-fit: cover; }
  .legend-note { font-size: 0.66rem; color: var(--ink-soft); margin-top: 0.35rem; line-height: 1.4; }
  .identity .name { font-weight: 600; font-size: 0.85rem; line-height: 1.15; }
  .identity .role { color: var(--ink-soft); font-size: 0.72rem; }
  .bell {
    width: 1.9rem; height: 1.9rem; border-radius: 999px;
    display: flex; align-items: center; justify-content: center;
    background: rgba(42,38,34,0.05); border: 1px solid rgba(42,38,34,0.12);
    position: relative; flex: none;
  }
  .bell svg { width: 0.95rem; height: 0.95rem; color: var(--ink-soft); }
  .header-mark { width: 1.7rem; height: auto; flex: none; }
  .bell .dot { position: absolute; top: 0.28rem; right: 0.32rem; width: 0.38rem; height: 0.38rem; background: var(--ochre); border-radius: 999px; }

  .section-pad { padding: 0.9rem 1.1rem; }
  .h-lead { font-family: 'Fraunces'; font-size: 1.28rem; line-height: 1.15; font-weight: 600; }
  .sub-lead { color: var(--ink-soft); font-size: 0.78rem; margin-top: 0.3rem; }

  .card {
    background: var(--surface-raised);
    border: 1px solid var(--line);
    border-radius: 1rem;
    padding: 0.85rem 0.9rem;
  }
  .card + .card { margin-top: 0.7rem; }
  .card-title-row {
    display: flex; align-items: center; justify-content: space-between;
    margin-bottom: 0.5rem;
  }
  .card-title { font-family: 'Fraunces'; font-weight: 600; font-size: 0.85rem; }
  .count-chip {
    font-size: 0.68rem; font-weight: 600; color: var(--ink-soft);
    background: color-mix(in srgb, var(--ink-onlight) 6%, #fff); border-radius: 999px; padding: 0.15rem 0.5rem;
  }

  .skill-row {
    display: flex; align-items: center; gap: 0.6rem;
    padding: 0.55rem 0; border-bottom: 1px solid var(--line);
  }
  .reveal-row { opacity: 0; animation: revealRow 0.5s cubic-bezier(.22,.8,.32,1) forwards; }
  .record-banner.reveal-banner { opacity: 0; animation: revealBanner 0.6s cubic-bezier(.3,1.4,.5,1) forwards; }
  @keyframes revealRow {
    from { opacity: 0; transform: translateY(0.6rem); }
    to { opacity: 1; transform: translateY(0); }
  }
  @keyframes revealBanner {
    from { opacity: 0; transform: translateY(0.6rem) scale(0.97); }
    to { opacity: 1; transform: translateY(0) scale(1); }
  }
  .skill-row:last-of-type { border-bottom: none; }
  .skill-row > div:nth-child(2) { flex: 1; min-width: 0; }
  .skill-icon {
    width: 2.1rem; height: 2.1rem; border-radius: 0.6rem; flex: none;
    display: flex; align-items: center; justify-content: center;
    position: relative;
  }
  .skill-icon svg { width: 1rem; height: 1rem; }
  .skill-icon {
    box-shadow: 0 0.15rem 0.3rem rgba(0,0,0,.22), inset 0 1px 0 rgba(255,255,255,.22), inset 0 -2px 3px rgba(0,0,0,.12);
  }
  .skill-icon.a { background: linear-gradient(155deg, #DB8940, var(--ochre) 55%, var(--sienna)); color: #fff; }
  .skill-icon.b { background: linear-gradient(155deg, #5FA38C, var(--good) 55%, #1F4A3C); color: #fff; }
  .skill-icon.c { background: linear-gradient(155deg, #E5AC5C, var(--amber) 55%, #B87730); color: #fff; }
  .skill-icon.d { background: linear-gradient(155deg, #8A8074, var(--ink-onlight-soft) 55%, #4A4238); color: #fff; }
  .skill-name { font-size: 0.8rem; font-weight: 600; line-height: 1.2; }
  .skill-evidence { font-size: 0.68rem; color: var(--ink-soft); margin-top: 0.1rem; }
  .skill-badges { margin-left: auto; display: flex; flex-direction: column; align-items: stretch; gap: 0.3rem; flex: none; }
  .skill-badges .tier, .skill-badges .trust { width: 7.6rem; text-align: center; }
  .tier {
    font-size: 0.65rem; font-weight: 700;
    padding: 0.22rem 0.5rem; border-radius: 999px; flex: none; white-space: nowrap;
  }
  .tier.expert { background: linear-gradient(155deg, #5FA38C, #2F6B57); color: #fff; }
  .tier.advanced { background: color-mix(in srgb, var(--amber) 68%, var(--surface-raised)); color: var(--ink); }
  .tier.developing { background: var(--line); color: var(--ink-soft); }
  .trust {
    font-size: 0.58rem; font-weight: 600; padding: 0.16rem 0.45rem; border-radius: 999px;
    flex: none; white-space: nowrap;
  }
  .skill-list-head { display: flex; align-items: center; gap: 0.6rem; padding: 0 0 0.4rem; }
  .skill-list-head-spacer { width: 2.1rem; flex: none; }
  .skill-list-head-name { flex: 1; min-width: 0; }
  .skill-list-head-badges { display: flex; flex-direction: column; gap: 0.3rem; flex: none; }
  .skill-list-head-badges span {
    width: 7.6rem; text-align: center; font-size: 0.56rem; font-weight: 700;
    text-transform: uppercase; letter-spacing: 0.04em; color: var(--ink-soft);
  }
  .trust.credential { background: color-mix(in srgb, var(--ochre) 16%, var(--surface-raised)); color: var(--sienna); }
  .trust.employer { background: var(--good-bg); color: var(--good); }
  .trust.documented { background: color-mix(in srgb, var(--amber) 22%, var(--surface-raised)); color: #8A5A1E; }
  .trust.simulated { background: color-mix(in srgb, var(--leaf) 22%, var(--surface-raised)); color: #3E6B2A; }

  .link-row {
    display: flex; align-items: center; justify-content: space-between;
    color: var(--sienna); font-size: 0.76rem; font-weight: 600;
    padding-top: 0.6rem;
  }
  .link-row svg { width: 0.85rem; height: 0.85rem; }

  /* Muted secondary action — deliberately not the bright primary .cta
     style, since this is a support/dispute utility, not part of the
     main flow. Not wired up to anything yet. */
  .dispute-btn {
    margin-top: 0.9rem; text-align: center; font-size: 0.74rem; font-weight: 600;
    color: var(--ink-soft); background: transparent; border: 1.5px solid var(--line);
    border-radius: 0.7rem; padding: 0.6rem 0.7rem; cursor: pointer;
  }
  .dispute-btn:active { transform: scale(0.98); }

  .record-banner {
    background: linear-gradient(135deg, #1F4A3C, var(--good) 70%);
    color: #fff; border-radius: 1rem; padding: 0.95rem 1rem; margin-top: 0.7rem;
    position: relative; overflow: hidden;
  }
  .record-eyebrow { font-size: 0.65rem; font-weight: 700; letter-spacing: 0.07em; opacity: 0.85; position: relative; z-index: 1; }
  .record-title { font-family: 'Fraunces'; font-weight: 600; font-size: 1.05rem; margin-top: 0.2rem; position: relative; z-index: 1; max-width: 68%; }
  .record-sub { font-size: 0.72rem; opacity: 0.9; margin-top: 0.2rem; line-height: 1.4; position: relative; z-index: 1; max-width: 70%; }
  .record-motif {
    position: absolute; right: -1.4rem; bottom: -1.6rem; width: 7.5rem; height: 7.5rem;
    opacity: 0.9; transform: rotate(-6deg); pointer-events: none;
  }
  .rungs-mini { position: absolute; right: 0.8rem; bottom: 0.7rem; display: flex; align-items: flex-end; gap: 0.18rem; opacity: 0.9; }
  .rungs-mini span { display: block; width: 0.5rem; border-radius: 3px; background: rgba(255,255,255,0.85); }

  .ready-card-highlight {
    border: 1.5px solid color-mix(in srgb, var(--ochre) 45%, transparent);
    background: linear-gradient(155deg, var(--surface-raised), color-mix(in srgb, var(--ochre) 7%, var(--surface-raised)));
    box-shadow: 0 0.4rem 1rem rgba(162,78,32,.14);
  }
  .ready-row {
    display: flex; align-items: center; gap: 0.55rem; padding: 0.6rem 0;
  }
  .ready-icon {
    width: 2.3rem; height: 2.3rem; border-radius: 0.6rem; flex: none;
    display: flex; align-items: center; justify-content: center;
    background: linear-gradient(155deg, #DB8940, var(--ochre) 65%, var(--sienna)); color: #fff;
    box-shadow: 0 0.15rem 0.3rem rgba(0,0,0,.22), inset 0 1px 0 rgba(255,255,255,.22);
  }
  .ready-icon svg { width: 1.1rem; height: 1.1rem; }
  .ready-title { font-family: 'Fraunces'; font-size: 0.88rem; font-weight: 600; }
  .ready-fit { font-size: 0.66rem; color: var(--ink-soft); }
  .ready-bar-track {
    height: 0.3rem; border-radius: 999px; margin-top: 0.35rem; width: 100%; position: relative;
    background: linear-gradient(90deg, var(--wheat), var(--amber) 42%, var(--leaf) 72%, var(--good) 100%);
    overflow: hidden;
  }
  .ready-bar-fill {
    height: 100%; border-radius: 999px; position: absolute; top: 0; right: 0; width: 100%;
    background: color-mix(in srgb, var(--ink) 8%, #fff);
    animation: readyBarGrow 0.7s cubic-bezier(.22,.8,.32,1) forwards;
  }
  @keyframes readyBarGrow { from { width: 100%; } to { width: calc(100% - var(--fit-pct)); } }
  @media (prefers-reduced-motion: reduce) {
    .ready-bar-fill { animation: none; width: calc(100% - var(--fit-pct)); }
  }

  .cta {
    display: flex; align-items: center; justify-content: center; gap: 0.4rem;
    background: linear-gradient(135deg, #5FA38C, var(--good));
    color: #fff; font-weight: 600; font-size: 0.85rem;
    padding: 0.7rem; border-radius: 0.8rem; margin-top: 0.85rem;
    transition: background 0.6s ease, color 0.5s ease;
  }
  .cta svg { width: 0.95rem; height: 0.95rem; }
  .cta.pending {
    background: linear-gradient(135deg, var(--amber), var(--ochre));
    color: rgba(255,255,255,0.55);
  }

  /* Matches list */
  .match-card {
    display: flex; gap: 0.7rem; align-items: flex-start;
    opacity: 0; transform: translateY(0.6rem);
    transition: opacity 0.45s cubic-bezier(.22,.8,.32,1), transform 0.45s cubic-bezier(.22,.8,.32,1);
  }
  .match-card.revealed { opacity: 1; transform: translateY(0); }
  @media (prefers-reduced-motion: reduce) {
    .match-card { transition: none; }
  }
  .match-scores { display: flex; flex-direction: column; align-items: center; gap: 0.35rem; flex: none; }
  .transfer-badge {
    display: flex; flex-direction: column; align-items: center; line-height: 1;
    width: 2.6rem; padding: 0.2rem 0 0.3rem; border-radius: 0.6rem;
    background: color-mix(in srgb, var(--amber) 16%, var(--surface-raised));
    border: 1px solid color-mix(in srgb, var(--amber) 40%, transparent);
  }
  .transfer-badge span { font-family: 'Fraunces'; font-weight: 700; font-size: 0.62rem; color: #8A5A1E; }
  .transfer-badge em {
    font-style: normal; font-size: 0.44rem; font-weight: 700; letter-spacing: 0.03em;
    text-transform: uppercase; color: #8A5A1E; opacity: 0.75; margin-top: 0.12rem;
  }
  .match-card-top {
    border: 1.5px solid color-mix(in srgb, var(--good) 45%, transparent);
    background: linear-gradient(155deg, var(--surface-raised), color-mix(in srgb, var(--good) 6%, var(--surface-raised)));
    box-shadow: 0 0.4rem 1rem rgba(47,107,87,.14);
  }
  .matches-empty-note {
    display: flex; flex-direction: row; align-items: center; justify-content: center;
    gap: 0.7rem; padding: 1.3rem 1.2rem 0.8rem;
  }
  /* Height-locked, width-auto: different Rudy poses have different pose
     silhouettes (arms raised wide vs. close to the body), so locking
     both dimensions would letterbox a wider pose and render it smaller.
     Matching on height alone keeps every pose the same apparent size. */
  .matches-empty-avatar {
    height: 5.3rem; width: auto; max-width: 5rem; flex: none;
  }
  .home-hero-note { padding: 0.3rem 0.1rem 1.1rem; justify-content: flex-start; }
  .home-hero-avatar { width: 5.2rem; height: auto; flex: none; }
  .matches-empty-bubble {
    position: relative; text-align: left; max-width: 12.5rem;
    background: var(--surface-raised); border: 1px solid var(--line);
    border-radius: 0.9rem; padding: 0.6rem 0.8rem;
    box-shadow: 0 0.3rem 0.7rem -0.3rem hsl(var(--shadow-color) / 0.25);
  }
  .matches-empty-bubble::before {
    content: ''; position: absolute; left: -0.42rem; top: 50%; margin-top: -0.4rem;
    border-width: 0.4rem 0.5rem 0.4rem 0; border-style: solid;
    border-color: transparent var(--surface-raised) transparent transparent;
    filter: drop-shadow(-0.05rem 0 0.05rem hsl(var(--shadow-color) / 0.08));
  }
  .matches-empty-bubble p { font-size: 0.72rem; color: var(--ink-soft); line-height: 1.5; margin: 0; }
  .matches-empty-bubble p.bubble-note { margin-top: 0.4rem; }
  .bubble-link { color: var(--sienna); font-weight: 600; text-decoration: underline; cursor: pointer; }
  /* Rudy is pinned dead-center of the stage (both beats use the same
     spot, regardless of pose width) and the bubble hops between his
     right and left — so he never visibly moves, only the bubble does. */
  #employment-rudy-note {
    position: relative; min-height: 5.3rem;
    transition: opacity 0.3s ease, transform 0.3s ease;
  }
  #employment-rudy-note.rudy-beat-out { opacity: 0; transform: translateY(4px); }
  #employment-rudy-avatar {
    position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%);
  }
  #employment-rudy-bubble {
    position: absolute; top: 50%; transform: translateY(-50%); max-width: 9.5rem;
  }
  #employment-rudy-bubble.bubble-right { left: calc(50% + 2.9rem); }
  #employment-rudy-bubble.bubble-left { right: calc(50% + 2.9rem); }
  #employment-rudy-bubble.bubble-left::before {
    left: auto; right: -0.42rem;
    border-width: 0.4rem 0 0.4rem 0.5rem;
    border-color: transparent transparent transparent var(--surface-raised);
    filter: drop-shadow(0.05rem 0 0.05rem hsl(var(--shadow-color) / 0.08));
  }
  /* Goodbye screen: a real speech bubble sitting right over the top of
     the clip, both as the "he's saying this" moment and to cover the
     faint leftover trace of the clip's own baked-in title text there. */
  .goodbye-bubble {
    position: absolute; top: -0.2rem; left: 50%; transform: translateX(-50%);
    z-index: 2; background: var(--surface-raised); border: 1px solid var(--line);
    border-radius: 0.9rem; padding: 0.5rem 1.1rem; white-space: nowrap;
    font-family: 'Fraunces'; font-weight: 600; font-size: 1rem; color: var(--ink);
    box-shadow: 0 0.3rem 0.7rem -0.3rem hsl(var(--shadow-color) / 0.25);
  }
  .goodbye-bubble::after {
    content: ''; position: absolute; left: 50%; bottom: -0.38rem; margin-left: -0.4rem;
    border-width: 0.5rem 0.4rem 0 0.4rem; border-style: solid;
    border-color: var(--surface-raised) transparent transparent transparent;
    filter: drop-shadow(0 0.05rem 0.05rem hsl(var(--shadow-color) / 0.08));
  }
  @media (prefers-reduced-motion: reduce) {
    #employment-rudy-note { transition: none; }
  }
  @property --fit {
    syntax: '<number>';
    inherits: true;
    initial-value: 0;
  }
  .fit-ring {
    width: 2.6rem; height: 2.6rem; border-radius: 999px; flex: none;
    display: flex; align-items: center; justify-content: center;
    font-family: 'Fraunces'; font-weight: 700; font-size: 0.68rem; color: #fff;
    background:
      conic-gradient(transparent calc(var(--fit) * 1%), var(--line) 0),
      conic-gradient(var(--wheat), var(--amber) 42%, var(--leaf) 72%, var(--good) 100%);
    transition: --fit 1.1s cubic-bezier(.22,.8,.32,1);
    position: relative;
  }
  .fit-ring::after {
    content: ''; position: absolute; inset: 3px; border-radius: 999px; background: var(--surface-raised);
  }
  .fit-ring span { position: relative; z-index: 1; color: var(--ink); }
  .match-body { flex: 1; min-width: 0; }
  .match-card-arrow { width: 0.8rem; height: 0.8rem; flex: none; align-self: center; color: var(--ink-soft); opacity: 0.6; }
  .match-title { font-family: 'Fraunces'; font-weight: 600; font-size: 0.82rem; }
  .match-meta { font-size: 0.68rem; color: var(--ink-soft); margin-top: 0.15rem; }
  .match-meta.good { color: var(--good); font-weight: 600; }
  .match-wage { font-size: 0.72rem; font-weight: 700; color: var(--sienna); margin-top: 0.25rem; }
  .match-credential { font-size: 0.68rem; color: var(--ink-soft); margin-top: 0.2rem; }
  .match-closes {
    display: inline-block; font-size: 0.65rem; font-weight: 600; color: var(--good);
    background: var(--good-bg); border-radius: 0.5rem; padding: 0.28rem 0.5rem; margin-top: 0.4rem;
  }
  .match-positions-link {
    display: flex; align-items: center; gap: 0.25rem;
    font-size: 0.68rem; font-weight: 700; color: var(--good); margin-top: 0.4rem;
  }
  .match-positions-link svg { width: 0.7rem; height: 0.7rem; }

  .divider-label {
    font-size: 0.65rem; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase;
    color: var(--ink-soft); margin: 1rem 0 0.4rem;
  }

  /* Gap / training */
  .gap-item { display: flex; align-items: flex-start; gap: 0.5rem; padding: 0.4rem 0; }
  .gap-item svg { width: 0.85rem; height: 0.85rem; margin-top: 0.15rem; flex: none; }
  .gap-item.have svg { color: var(--good); }
  .gap-item.need svg { color: var(--amber); }
  .gap-item .t { font-size: 0.78rem; font-weight: 600; }
  .gap-item .d { font-size: 0.68rem; color: var(--ink-soft); }

  .provider-card {
    display: flex; justify-content: space-between; align-items: center; gap: 0.5rem;
  }
  .provider-name { font-size: 0.78rem; font-weight: 600; }
  .provider-org { font-size: 0.68rem; color: var(--ink-soft); }
  .org-badge {
    display: inline-flex; align-items: center; gap: 0.28rem;
    font-size: 0.66rem; font-weight: 700; color: #0F6E8C; margin-top: 0.15rem;
  }
  .org-badge svg { width: 0.55rem; height: 0.55rem; }
  .org-mark {
    display: inline-flex; align-items: center; justify-content: center;
    width: 1.05rem; height: 1.05rem; border-radius: 0.3rem;
    background: linear-gradient(135deg, #12879F, #0F6E8C);
    color: #fff; font-family: 'Fraunces'; font-weight: 700; font-size: 0.5rem;
  }
  .badge-fund {
    font-size: 0.62rem; font-weight: 700; color: var(--sienna);
    background: color-mix(in srgb, var(--ochre) 14%, transparent);
    padding: 0.15rem 0.45rem; border-radius: 999px; white-space: nowrap;
  }

  /* Training: outside-institution links */
  .inst-intro { font-size: 0.68rem; color: var(--ink-soft); line-height: 1.45; margin: 0 0 0.5rem; }
  .inst-row {
    display: flex; align-items: center; gap: 0.7rem; padding: 0.7rem 0;
    border-bottom: 1px solid var(--line); text-decoration: none; color: inherit;
  }
  .inst-row:last-of-type { border-bottom: none; }
  .inst-mark {
    width: 2.2rem; height: 2.2rem; border-radius: 0.5rem; flex: none;
    display: flex; align-items: center; justify-content: center;
    color: #fff; font-family: 'Fraunces'; font-weight: 700; font-size: 0.56rem; letter-spacing: 0.01em;
    box-shadow: 0 0.1rem 0.2rem rgba(0,0,0,.15);
  }
  .inst-mark-img { background: #fff; border: 1px solid var(--line); padding: 0.3rem; box-shadow: none; }
  .inst-mark-img img { width: 100%; height: 100%; object-fit: contain; display: block; }
  .inst-body { flex: 1; min-width: 0; }
  .inst-name { font-size: 0.78rem; font-weight: 700; }
  .inst-name-row { display: flex; align-items: center; gap: 0.4rem; flex-wrap: wrap; }
  .inst-rec-tag {
    font-size: 0.56rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.03em;
    color: var(--sienna); background: color-mix(in srgb, var(--ochre) 18%, transparent);
    padding: 0.08rem 0.4rem; border-radius: 999px;
  }
  .inst-row-featured {
    margin: 0 -0.9rem; padding: 0.7rem 0.9rem;
    background: color-mix(in srgb, var(--ochre) 7%, transparent);
    border-bottom: 1px solid var(--line);
  }
  .inst-fund { color: var(--sienna); font-weight: 700; }
  .inst-desc { font-size: 0.68rem; color: var(--ink-soft); margin-top: 0.1rem; line-height: 1.4; }
  .inst-ext {
    display: flex; align-items: center; gap: 0.25rem; font-size: 0.62rem; font-weight: 600;
    color: var(--sienna); margin-top: 0.3rem;
  }
  .inst-ext svg { width: 0.62rem; height: 0.62rem; flex: none; }

  /* Simulation screen */
  .metric-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0.6rem; }
  .metric-box { background: var(--bg); border-radius: 0.7rem; padding: 0.55rem 0.65rem; }
  .metric-label { font-size: 0.62rem; color: var(--ink-soft); font-weight: 600; text-transform: uppercase; letter-spacing: 0.03em; }
  .metric-value { font-family: 'Fraunces'; font-size: 1.15rem; font-weight: 600; margin-top: 0.15rem; }
  .bar-row { margin: 0.45rem 0; }
  .bar-row .bar-label { display: flex; justify-content: space-between; font-size: 0.72rem; margin-bottom: 0.25rem; }
  .bar-track {
    height: 0.4rem; border-radius: 999px; overflow: hidden; position: relative;
    background: linear-gradient(90deg, var(--wheat), var(--amber) 42%, var(--leaf) 72%, var(--good) 100%);
  }
  .bar-fill {
    height: 100%; border-radius: 999px; position: absolute; top: 0; right: 0;
    background: color-mix(in srgb, var(--ink-onlight) 6%, #fff);
  }
  .verify-box {
    display: flex; gap: 0.5rem; align-items: flex-start;
    background: var(--good-bg); border-radius: 0.7rem; padding: 0.6rem 0.7rem; margin-top: 0.7rem;
  }
  .verify-box svg { width: 1rem; height: 1rem; color: var(--good); flex: none; margin-top: 0.1rem; }
  .verify-box .t { font-size: 0.72rem; font-weight: 600; color: var(--good); }
  .verify-box .d { font-size: 0.66rem; color: var(--ink-soft); margin-top: 0.1rem; line-height: 1.4; }

  /* Transcript / profile */
  .cred-row { display: flex; justify-content: space-between; align-items: center; }

  /* Open positions */
  .job-card { display: flex; align-items: flex-start; gap: 0.6rem; }
  .job-logo {
    width: 2.4rem; height: 2.4rem; border-radius: 0.55rem; flex: none;
    display: flex; align-items: center; justify-content: center;
    color: #fff; font-family: 'Fraunces'; font-weight: 700; font-size: 0.75rem;
    box-shadow: inset 0 1px 0 rgba(255,255,255,.15);
  }
  .job-logo.img {
    background: #fff; box-shadow: 0 0 0 1px var(--line); padding: 0.3rem;
  }
  .job-logo.img img { width: 100%; height: 100%; object-fit: contain; display: block; }
  .job-info { flex: 1; min-width: 0; }
  .job-role { font-family: 'Fraunces'; font-size: 0.8rem; font-weight: 700; }
  .job-company { font-size: 0.74rem; color: var(--ink-soft); margin-top: 0.05rem; }
  .job-meta { font-size: 0.68rem; color: var(--ink-soft); margin-top: 0.3rem; }
  .job-posted { font-size: 0.62rem; color: var(--ink-soft); opacity: 0.8; margin-top: 0.1rem; }
  .job-apply {
    flex: none; align-self: center; font-size: 0.68rem; font-weight: 700;
    color: var(--sienna); border: 1.5px solid color-mix(in srgb, var(--ochre) 45%, transparent);
    border-radius: 999px; padding: 0.3rem 0.65rem;
  }
  .cred-id { font-size: 0.68rem; color: var(--ink-soft); margin-top: 0.1rem; }
  .status-ok {
    display: inline-flex; align-items: center; gap: 0.25rem;
    font-size: 0.68rem; font-weight: 700; color: var(--good);
  }
  .status-ok svg { width: 0.75rem; height: 0.75rem; }
  .timeline { position: relative; padding-left: 1rem; }
  .timeline::before {
    content: ''; position: absolute; left: 0.22rem; top: 0.3rem; bottom: 0.3rem; width: 1px; background: var(--line);
  }
  .tl-item { position: relative; padding-bottom: 0.75rem; }
  .tl-item::before {
    content: ''; position: absolute; left: -1rem; top: 0.2rem; width: 0.45rem; height: 0.45rem;
    border-radius: 999px; background: var(--ochre);
  }
  .tl-date { font-size: 0.64rem; color: var(--ink-soft); font-weight: 600; }
  .tl-title { font-size: 0.78rem; font-weight: 600; margin-top: 0.05rem; }
  .tl-sub { font-size: 0.68rem; color: var(--ink-soft); }

  .toggle-row { display: flex; align-items: center; justify-content: space-between; padding: 0.5rem 0; }
  .toggle-row .t { font-size: 0.78rem; font-weight: 600; }
  .toggle-row .d { font-size: 0.65rem; color: var(--ink-soft); }
  .switch { width: 2rem; height: 1.15rem; border-radius: 999px; flex: none; position: relative; }
  .switch.on { background: var(--ochre); }
  .switch.off { background: var(--line); }
  .switch::after { content: ''; position: absolute; top: 0.15rem; width: 0.85rem; height: 0.85rem; border-radius: 999px; background: #fff; }
  .switch.on::after { right: 0.15rem; }
  .switch.off::after { left: 0.15rem; }

  /* Cover screen */
  .cover-screen {
    flex: 1; position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center;
    text-align: center; padding: 2rem 1.6rem; gap: 1.1rem;
    background: url('../assets/img/bg-cover.png?v=2') center/cover no-repeat, var(--bg);
  }
  .cover-mark { width: 2.5rem; height: 2.5rem; position: relative; z-index: 1; }
  .cover-rudy {
    width: 13.5rem; height: auto; position: relative; z-index: 1;
    opacity: 0; transition: opacity 0.4s ease;
  }
  .cover-rudy.loaded { opacity: 1; }
  .cover-brand-row { display: flex; align-items: center; gap: 0.5rem; }
  .figure-motif { position: absolute; pointer-events: none; }
  .map-fanfare, .matches-fanfare-overlay {
    position: absolute; inset: 0; z-index: 10;
    display: flex; align-items: center; justify-content: center;
    background: var(--bg);
    background-image:
      radial-gradient(65% 55% at 50% 40%, rgba(255,255,255,0.5), transparent),
      url('../assets/img/bg-light.jpg?v=2');
    background-size: cover; background-position: center;
    opacity: 0; pointer-events: none;
    transition: opacity 0.35s ease;
  }
  .map-fanfare.show, .matches-fanfare-overlay.show { opacity: 1; }
  .map-fanfare img, .matches-fanfare-overlay img {
    width: auto; height: 60%; max-width: 90%; max-height: 16.5rem;
    image-rendering: -webkit-optimize-contrast;
    filter: drop-shadow(0 1rem 2rem rgba(42,38,34,.3));
    transform: scale(0.85); transition: transform 0.45s cubic-bezier(.34,1.56,.64,1);
  }
  .map-fanfare.show img, .matches-fanfare-overlay.show img { transform: scale(1); }
  .map-figure { right: -1rem; bottom: -0.6rem; width: 6rem; height: 10.5rem; opacity: 0.1; }
  .cover-word { font-family: 'Fraunces'; font-weight: 700; font-size: 2.1rem; letter-spacing: 0.01em; color: #fff; text-shadow: 0 0.12rem 0.5rem rgba(20,30,22,0.4); }
  .cover-head { font-family: 'Fraunces'; font-weight: 600; font-size: 1.55rem; line-height: 1.2; margin-top: 0.4rem; color: #fff; text-shadow: 0 0.12rem 0.5rem rgba(20,30,22,0.4); }
  .cover-sub { color: var(--ink-soft); font-size: 0.85rem; line-height: 1.5; max-width: 15rem; }
  .cover-cta {
    margin-top: 0.6rem; width: 100%;
    background: linear-gradient(135deg, var(--ochre), var(--sienna));
    box-shadow: 0 0.4rem 1rem rgba(162,78,32,.35);
    color: #fff; font-weight: 600; font-size: 0.9rem; padding: 0.8rem; border-radius: 0.9rem;
  }
  .cover-foot { position: absolute; bottom: 1.2rem; left: 0; right: 0; text-align: center; font-size: 0.62rem; color: var(--ink-soft); }

  /* ---------- Pre-cover "audience QR" slide -- UCLA blue/gold, shown
     to a presenter's audience before the app demo itself starts ---------- */
  .qr-screen {
    flex: 1; position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center;
    text-align: center; padding: 2rem 1.6rem; gap: 0.8rem;
    background:
      radial-gradient(120% 90% at 15% -10%, rgba(255,209,0,0.16), transparent),
      linear-gradient(165deg, #2774AE 0%, #1E5A8A 55%, #123655 100%);
  }
  .qr-bruin-icon { width: 3.6rem; height: 3.6rem; flex: none; filter: drop-shadow(0 0.3rem 0.6rem rgba(0,0,0,0.25)); }
  .qr-eyebrow {
    font-size: 0.72rem; font-weight: 800; text-transform: uppercase; letter-spacing: 0.12em;
    color: #FFD100;
  }
  .qr-head {
    font-family: 'Fraunces'; font-weight: 600; font-size: 1.5rem; line-height: 1.25;
    color: #fff; text-shadow: 0 0.12rem 0.5rem rgba(0,0,0,0.25);
  }
  .qr-card {
    margin-top: 0.4rem; background: #fff; border-radius: 1.1rem; padding: 1rem;
    box-shadow: 0 0.6rem 1.6rem -0.3rem rgba(0,0,0,0.35), 0 0 0 0.3rem rgba(255,209,0,0.9);
  }
  .qr-code-img { display: block; width: 9.5rem; height: 9.5rem; }
  .qr-url {
    font-family: ui-monospace, Menlo, monospace; font-size: 0.72rem; letter-spacing: 0.01em;
    color: rgba(255,255,255,0.85);
  }
  .qr-skip {
    margin-top: 1rem; font-size: 0.7rem; font-weight: 600; color: rgba(255,255,255,0.65);
    cursor: pointer; padding: 0.4rem 0.7rem; border-radius: 999px; transition: color 0.2s ease, background 0.2s ease;
  }
  .qr-skip:hover, .qr-skip:active { color: #fff; background: rgba(255,255,255,0.12); }

  /* Persona picker */
  .persona-card {
    display: flex; align-items: center; gap: 0.65rem;
    background: var(--surface-raised);
    border: 1.5px solid var(--line); border-radius: 0.85rem; padding: 0.65rem 0.75rem; margin-bottom: 0.55rem;
    box-shadow: 0 0.25rem 0.6rem rgba(0,0,0,.28);
    transition: border-color 0.15s ease, background 0.15s ease, box-shadow 0.15s ease;
  }
  .persona-card.selected {
    border-color: var(--good);
    background: color-mix(in srgb, var(--good) 8%, var(--surface-raised));
    box-shadow: 0 0.3rem 0.75rem rgba(47,107,87,.22);
  }
  .persona-name { font-size: 0.8rem; font-weight: 600; }
  .persona-meta { font-size: 0.66rem; color: var(--ink-soft); margin-top: 0.1rem; }
  .persona-role { font-size: 0.68rem; color: var(--ink-soft); }
  .persona-stat { font-size: 0.64rem; color: var(--sienna); font-weight: 600; margin-top: 0.1rem; }
  .persona-arrow { margin-left: auto; width: 0.85rem; height: 0.85rem; flex: none; color: var(--ink-soft); }
  .persona-card.selected .persona-arrow { color: var(--good); }

  .demo-banner {
    display: inline-flex; gap: 0.4rem; align-items: flex-start;
    width: fit-content; max-width: calc(100% - 2.2rem);
    margin: 0 1.1rem 0.9rem;
    background: var(--demo-accent);
    border: 1px solid var(--demo-accent);
    border-radius: 1.1rem; padding: 0.4rem 0.65rem;
    box-shadow: 0 0.3rem 0.7rem -0.2rem color-mix(in srgb, var(--demo-accent) 50%, transparent);
  }
  .demo-banner svg { width: 0.85rem; height: 0.85rem; color: #fff; flex: none; margin-top: 0.1rem; }
  .demo-banner .t { font-size: 0.58rem; font-weight: 700; letter-spacing: 0.03em; color: #fff; text-transform: uppercase; }
  .demo-banner .d { font-size: 0.6rem; color: color-mix(in srgb, #fff 88%, transparent); line-height: 1.3; margin-top: 0.05rem; }

  /* ---------- Connect-sources checklist (screen 3) ---------- */
  .check-row { display: flex; align-items: center; gap: 0.65rem; padding: 0.7rem 0.15rem; border-bottom: 1px solid var(--line); }
  .check-row:last-of-type { border-bottom: none; }
  .check-box {
    width: 1.3rem; height: 1.3rem; border-radius: 0.4rem; border: 1.5px solid var(--ink-soft);
    display: flex; align-items: center; justify-content: center; flex: none; color: #fff;
    background: var(--surface); box-shadow: 0 1px 2px rgba(20,20,15,0.06);
    transition: background 0.25s ease, border-color 0.25s ease;
  }
  .check-row.checked .check-box { background: var(--ochre); border-color: var(--ochre); animation: checkPop 0.35s cubic-bezier(.3,1.4,.5,1); }
  @keyframes checkPop { from { transform: scale(0.7); } to { transform: scale(1); } }
  @media (prefers-reduced-motion: reduce) {
    .check-row.checked .check-box { animation: none; }
  }
  .check-box svg { width: 0.7rem; height: 0.7rem; }
  .check-title { font-size: 0.8rem; font-weight: 600; }
  .check-logo {
    width: 3.2rem; height: 3.2rem; border-radius: 999px; flex: none;
    background: #fff; overflow: hidden; padding: 0.2rem;
    box-shadow: 0 0 0 1px var(--line);
  }
  .check-logo img { width: 100%; height: 100%; object-fit: contain; display: block; }
  .check-logo.wide { width: 4.6rem; border-radius: 0.5rem; padding: 0.3rem 0.4rem; }
  .check-sub { font-size: 0.66rem; color: var(--ink-soft); margin-top: 0.05rem; }
  .check-fullname { font-size: 0.62rem; color: var(--ink-soft); font-style: italic; opacity: 0.85; }

  /* ---------- Demo login (screen 4) ---------- */
  .login-form { padding-top: 0.3rem; }
  .field-label { font-size: 0.68rem; font-weight: 600; color: var(--ink-soft); display: block; margin: 0.8rem 0 0.3rem; }
  .field-input {
    background: var(--surface-raised); border: 1px solid var(--line); border-radius: 0.6rem;
    padding: 0.6rem 0.7rem; font-size: 0.8rem; font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
    display: flex; align-items: center; min-height: 1.1rem;
  }
  .caret { width: 1px; height: 0.9rem; background: var(--ink-soft); margin-left: 2px; animation: blink 1s step-end infinite; }
  @keyframes blink { 50% { opacity: 0; } }
  .login-note { font-size: 0.62rem; color: var(--ink-soft); text-align: center; margin-top: 0.7rem; line-height: 1.4; }
  @media (prefers-reduced-motion: reduce) {
    .caret { animation: none; opacity: 0; }
  }

  /* ---------- Persona source-document accordion ---------- */
  .persona-block {
    border: 1px solid var(--line); border-radius: 0.85rem;
    margin-bottom: 0.55rem; overflow: hidden; background: var(--surface-raised);
  }
  .persona-block[open] { border-color: var(--ochre); }
  .persona-summary {
    list-style: none; cursor: pointer; display: flex; align-items: center;
    gap: 0.6rem; padding: 0.6rem 0.7rem;
  }
  .persona-summary::-webkit-details-marker { display: none; }
  .persona-summary .chev {
    margin-left: auto; width: 0.8rem; height: 0.8rem; color: var(--ink-soft);
    transition: transform 0.15s ease; flex: none;
  }
  .persona-block[open] .persona-summary .chev { transform: rotate(90deg); }
  .cred-chip {
    font-size: 0.6rem; font-weight: 700; padding: 0.16rem 0.45rem; border-radius: 999px;
    background: color-mix(in srgb, var(--ochre) 15%, var(--surface-raised));
    color: var(--sienna); white-space: nowrap; flex: none;
  }
  .cred-chip.pending { background: var(--line); color: var(--ink-soft); }
  .source-panels { padding: 0 0.65rem 0.75rem; display: flex; flex-direction: column; gap: 0.6rem; }
  .src-note { font-size: 0.62rem; color: var(--ink-soft); padding: 0 0.05rem; }
  .src-doc { border-radius: 0.55rem; overflow: hidden; border: 1px solid #D8D8D8; background: #fff; }
  #employment-result .src-doc { margin-top: 0.7rem; }
  .src-chrome { display: flex; align-items: center; gap: 0.35rem; padding: 0.32rem 0.5rem; background: #E7E7E5; }
  .src-chrome .sdot { width: 0.38rem; height: 0.38rem; border-radius: 999px; background: #C6C6C4; }
  .src-chrome .surl {
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    font-size: 0.53rem; color: #4A4A48; background: #fff; border-radius: 4px;
    padding: 0.08rem 0.35rem; flex: 1; overflow: hidden; text-overflow: ellipsis;
    white-space: nowrap; border: 1px solid #DADAD8;
  }
  /* Right gutter is reserved so a card-fly tile always has clear space to
     spawn from (see playCardFlight's originEl in render.js); the text
     column wraps within what's left rather than running edge to edge. */
  .src-head { padding: 0.4rem 3.6rem 0.4rem 0.55rem; color: #fff; display: flex; align-items: center; gap: 0.45rem; position: relative; }
  .src-head-text { flex: 1; min-width: 0; }
  .src-head .mark {
    width: 4.6rem; height: 4.6rem; border-radius: 0.7rem; flex: none;
    background: rgba(255,255,255,0.18);
    display: flex; align-items: center; justify-content: center;
    font-family: 'Fraunces'; font-weight: 700; font-size: 0.55rem; letter-spacing: -0.01em;
  }
  .src-head .mark.img { background: #fff; border-radius: 999px; overflow: hidden; padding: 0.15rem; }
  .src-head .mark.img img { width: 100%; height: 100%; object-fit: contain; display: block; }
  .src-head .mark.wide { width: 6.2rem; border-radius: 0.6rem; padding: 0.45rem 0.5rem; }
  .src-head .org { font-weight: 700; font-size: 0.66rem; letter-spacing: 0.01em; }
  .src-head .sub { font-size: 0.53rem; opacity: 0.88; margin-top: 0.05rem; line-height: 1.3; }
  .src-body { padding: 0.5rem 0.55rem; color: #1C1C1A; font-size: 0.6rem; line-height: 1.5; }
  .src-body .row { display: flex; justify-content: space-between; gap: 0.4rem; padding: 0.16rem 0; border-bottom: 1px solid #EEEEEC; }
  .src-body .row:last-child { border-bottom: none; }
  .src-body .row .k { color: #6B6B68; }
  .src-body .row .v { font-weight: 600; text-align: right; }
  .src-body .lbl { font-size: 0.54rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.04em; color: #8A8A87; margin: 0.4rem 0 0.15rem; }
  .src-foot { padding: 0.3rem 0.55rem; font-size: 0.5rem; color: #8A8A87; border-top: 1px solid #EEEEEC; font-style: italic; }
  .src-onet .src-head { background: #1B3A6B; }
  .src-bls .src-head { background: #14213D; }
  .src-aapc .src-head { background: #034246; }
  .src-ahima .src-head { background: #0F6E8C; }
  .src-status { font-size: 0.58rem; font-weight: 700; padding: 0.1rem 0.4rem; border-radius: 999px; }
  .src-status.active { background: #E1F0E4; color: #2C6E3F; }
  .src-status.pending { background: #F3EAD3; color: #8A6A1E; }
  .src-head .payroll-mark {
    width: auto; min-width: 4rem; height: 1.7rem; padding: 0.3rem 0.55rem; border-radius: 0.5rem;
    background: #fff;
  }
  .src-head .payroll-mark img { height: 100%; width: auto; max-width: 100%; object-fit: contain; display: block; }

  /* ---------- Skill-mapping "engine" screen ---------- */
  .map-panel {
    flex: 1; min-height: 0; color: #2A2622; position: relative; overflow: hidden;
    display: flex; flex-direction: column; padding: 1.1rem 1.1rem 1.2rem; gap: 1.15rem;
    background:
      radial-gradient(28rem 16rem at 88% -10%, rgba(216,153,74,0.12), transparent 60%),
      radial-gradient(24rem 14rem at 8% 105%, rgba(162,78,32,0.1), transparent 60%),
      linear-gradient(160deg, rgba(255,251,244,0.4), rgba(244,237,225,0.6)),
      url('../assets/img/bg-light.jpg?v=2') center/cover no-repeat;
  }
  .map-head { font-family: 'Fraunces'; font-weight: 600; font-size: 1rem; position: relative; flex: none; }
  .map-sub { font-size: 0.72rem; color: #6B6258; line-height: 1.4; position: relative; flex: none; }
  .map-match-btn {
    display: flex; align-items: center; justify-content: center; gap: 0.4rem;
    background: linear-gradient(135deg, #5FA38C, var(--good));
    color: #fff; font-weight: 700; font-size: 0.82rem;
    padding: 0.6rem; border-radius: 0.8rem; flex: none;
    margin-bottom: 0.9rem;
    box-shadow: 0 0.3rem 0.6rem rgba(0,0,0,.3); cursor: pointer;
    transition: transform 0.15s ease, opacity 0.2s ease;
  }
  /* #map-dynamic holds everything renderMap() injects (header, button,
     .map-scroll, footer). .map-scroll's flex:1/min-height:0 (which is what
     actually lets it scroll instead of just growing to fit the full chip
     list and getting clipped by .map-panel's overflow:hidden) only takes
     effect if ITS direct parent is a flex container — #map-dynamic had no
     rule at all, so it silently never scrolled. */
  #map-dynamic { display: flex; flex-direction: column; flex: 1; min-height: 0; gap: 1.15rem; }
  .map-match-btn svg { width: 0.95rem; height: 0.95rem; }
  .map-match-btn.done { background: linear-gradient(135deg, var(--good), #1F4A3C); cursor: pointer; }
  .map-scroll { flex: 1; min-height: 0; overflow-y: auto; overflow-x: hidden; margin: 0 -0.3rem; padding: 0 0.3rem; }
  .map-scroll::-webkit-scrollbar { width: 0; }
  .map-stage { position: relative; padding-bottom: 0.5rem; }
  .map-cols { position: relative; display: flex; justify-content: space-between; z-index: 2; }
  .map-col { display: flex; flex-direction: column; gap: 0.85rem; width: 5.3rem; }
  .map-col.right { align-items: flex-end; }
  .map-chip {
    background: linear-gradient(155deg, #FFFDF8, #F6EEE0);
    color: #2A2622;
    border: 1px solid #E4D8C2; border-radius: 0.42rem;
    padding: 0.28rem 0.4rem; font-size: 0.53rem; font-weight: 600; line-height: 1.2;
    opacity: 0; animation: chipIn 0.4s ease-out forwards;
    box-shadow: 0 0.15rem 0.3rem rgba(60,45,20,.14), inset 0 1px 0 rgba(255,255,255,.6);
  }
  .map-col.right .map-chip {
    text-align: right;
    background: linear-gradient(155deg, #FBFCFA, #E3F0EA);
    border-color: #C9DFD6;
  }
  .map-svg { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; z-index: 1; pointer-events: none; }
  /* Lines/nodes reveal via a plain CSS transition toggled by JS adding .in
     at the right moment — no animation-delay, no SMIL. A layout reposition
     later just moves the geometry (d/cx/cy) and never touches this class,
     so a transition can never replay or hide anything that's already shown
     — safe to pair with a stroke "draw-in" now that reveal timing is fully
     JS-controlled instead of racing separate CSS/SMIL clocks. */
  .map-path-halo {
    fill: none; stroke: rgba(251,252,250,0.9); stroke-width: 2.6; stroke-linecap: round;
    opacity: 0; stroke-dasharray: 1; stroke-dashoffset: 1;
    transition: opacity 0.4s ease, stroke-dashoffset 0.65s cubic-bezier(.35,.05,.25,1);
  }
  .map-path {
    fill: none; stroke-width: 1.2; stroke-linecap: round;
    opacity: 0; stroke-dasharray: 1; stroke-dashoffset: 1;
    transition: opacity 0.4s ease, stroke-dashoffset 0.65s cubic-bezier(.35,.05,.25,1);
  }
  .map-path-glow {
    fill: none; stroke-width: 2.6; stroke-linecap: round; filter: blur(3px);
    opacity: 0; stroke-dasharray: 1; stroke-dashoffset: 1;
    transition: opacity 0.4s ease, stroke-dashoffset 0.65s cubic-bezier(.35,.05,.25,1);
  }
  .map-path-halo.in { opacity: 1; stroke-dashoffset: 0; }
  .map-path.in { opacity: 1; stroke-dashoffset: 0; }
  .map-path-glow.in { opacity: 0.45; stroke-dashoffset: 0; }
  .map-node {
    fill: #A24E20; opacity: 0; filter: drop-shadow(0 0 3px rgba(162,78,32,.5));
    transition: opacity 0.3s ease-out;
  }
  .map-node.in { opacity: 1; }
  @keyframes chipIn { to { opacity: 1; } }
  .map-foot { font-size: 0.66rem; color: #6B6258; text-align: center; position: relative; }
  @media (prefers-reduced-motion: reduce) {
    .map-path-halo, .map-path, .map-path-glow, .map-node { transition: none; }
    .map-chip { animation: none; opacity: 1; }
  }

  /* ---------- API-grab skeleton state (screen 2) ---------- */
  .src-skel { border-radius: 0.55rem; overflow: hidden; border: 1px solid #D8D8D8; background: #fff; }
  .src-skel .src-chrome { background: #E7E7E5; }
  .src-skel-body { display: flex; align-items: center; gap: 0.5rem; padding: 0.7rem 0.6rem; }
  .spin {
    width: 0.85rem; height: 0.85rem; border-radius: 999px; flex: none;
    border: 2px solid #DADAD8; border-top-color: #A24E20;
    animation: spin 0.8s linear infinite;
  }
  @keyframes spin { to { transform: rotate(360deg); } }
  .src-skel-text { font-size: 0.6rem; color: #6B6B68; }
  .src-skel-text .u { display: block; font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 0.53rem; color: #9a9a97; margin-top: 0.1rem; }
  @media (prefers-reduced-motion: reduce) {
    .spin { animation: none; border-top-color: #DADAD8; }
  }

  /* ---------- Downloading: received counter + flying data-card animation ---------- */
  .dl-inbox {
    display: flex; align-items: center; gap: 0.35rem; flex: none;
    background: var(--surface-raised); border: 1px solid var(--line); border-radius: 999px;
    padding: 0.25rem 0.6rem 0.25rem 0.5rem; font-size: 0.72rem; font-weight: 700; color: var(--sienna);
    font-variant-numeric: tabular-nums;
  }
  /* Illustrated card that spawns center-screen and arcs up into the
     counter pill; see playCardFlight in render.js. Sizing is a fraction
     of the .screen's own width so it scales with the phone frame. */
  .card-fly {
    position: absolute; z-index: 40; width: 62%; max-width: 15.5rem;
    pointer-events: none; transform-origin: center center;
  }
  /* The art itself is drawn at a ~13.5deg tilt (measured off the source
     PNGs). Counter-rotate it here so the card reads perfectly level
     whenever the .card-fly container's own rotation is 0deg (spawn and
     hold) — the container's animated rotation during flight (see
     playCardFlight) is what puts it back at an angle as it zooms off. */
  .card-fly img { display: block; width: 100%; height: auto; transform: rotate(13.5deg); }
  .card-fly.reduced { width: 34%; max-width: 6.5rem; }
  @keyframes pillArrive {
    0% { transform: scale(1); box-shadow: 0 0 0 0 color-mix(in srgb, var(--ochre) 0%, transparent); }
    40% {
      transform: scale(1.08);
      box-shadow: 0 0 0 0.45rem color-mix(in srgb, var(--amber) 30%, transparent),
                  0 0 0.9rem 0.2rem color-mix(in srgb, var(--amber) 55%, transparent);
    }
    100% { transform: scale(1); box-shadow: 0 0 0 0 color-mix(in srgb, var(--ochre) 0%, transparent); }
  }
  .dl-inbox.pill-arrive { animation: pillArrive 0.5s ease-out; }
  @media (prefers-reduced-motion: reduce) {
    .card-fly { transition: opacity 0.25s ease; }
    .dl-inbox.pill-arrive { animation: none; }
  }


  /* Thinking / loading screen */
  .think-screen {
    flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center;
    gap: 1.3rem; padding: 2rem;
  }
  .think-rungs { display: flex; align-items: flex-end; gap: 0.3rem; height: 2.6rem; }
  .think-rungs span {
    display: block; width: 0.65rem; border-radius: 4px;
    background: var(--ochre);
    animation: rise 1.2s ease-in-out infinite;
  }
  .think-rungs span:nth-child(1) { height: 40%; animation-delay: 0s; background: var(--sienna); }
  .think-rungs span:nth-child(2) { height: 60%; animation-delay: 0.15s; background: var(--ochre); }
  .think-rungs span:nth-child(3) { height: 80%; animation-delay: 0.3s; background: var(--amber); }
  .think-rungs span:nth-child(4) { height: 100%; animation-delay: 0.45s; background: var(--wheat); }
  @keyframes rise {
    0%, 100% { transform: scaleY(0.6); opacity: 0.6; }
    50% { transform: scaleY(1); opacity: 1; }
  }
  @media (prefers-reduced-motion: reduce) {
    .think-rungs span { animation: none; opacity: 1; transform: none; }
  }
  .think-text { font-family: 'Fraunces'; font-weight: 600; font-size: 0.95rem; text-align: center; }
  .think-sub { color: var(--ink-soft); font-size: 0.75rem; text-align: center; max-width: 12rem; }

  @media (max-width: 30rem) {
    body { padding: 1.5rem 1rem 4rem; }
    .grid { justify-content: center; }
  }

  /* ---------- Strengthen-evidence entry card (Skill Detail) ---------- */
  .strengthen-card {
    background: linear-gradient(155deg, var(--surface-raised), color-mix(in srgb, var(--good) 6%, var(--surface-raised)));
    border: 1px solid color-mix(in srgb, var(--good) 35%, var(--line));
  }
  .strengthen-card .card-title { display: flex; align-items: center; gap: 0.4rem; }
  .strengthen-card .card-title svg { width: 0.9rem; height: 0.9rem; color: var(--good); }
  .strengthen-card p { font-size: 0.74rem; color: var(--ink-soft); line-height: 1.5; margin: 0 0 0.7rem; }
  .strengthen-cta {
    display: flex; align-items: center; justify-content: center; gap: 0.4rem;
    background: linear-gradient(135deg, #5FA38C, var(--good));
    color: #fff; font-weight: 600; font-size: 0.78rem;
    padding: 0.6rem; border-radius: 0.7rem; cursor: pointer;
  }
  .strengthen-cta svg { width: 0.85rem; height: 0.85rem; }
  .evidence-preview {
    width: 100%; text-align: left;
    background: var(--surface-raised); border: 1px solid var(--line); border-radius: 0.9rem; padding: 0.8rem 0.85rem;
  }
  .evidence-preview .tag {
    display: inline-flex; align-items: center; gap: 0.3rem;
    font-size: 0.62rem; font-weight: 700; color: var(--good);
    background: var(--good-bg); padding: 0.18rem 0.5rem; border-radius: 999px; margin-bottom: 0.5rem;
  }
  .evidence-preview .line { font-size: 0.76rem; line-height: 1.5; color: var(--ink); }
  .demo-stat-bar { margin-top: 0.7rem; }
  .demo-stat-bar:first-of-type { margin-top: 0.15rem; }
  .demo-stat-bar-head { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 0.3rem; }
  .demo-stat-bar-head span:first-child { font-size: 0.68rem; color: var(--ink-soft); font-weight: 600; }
  .demo-stat-bar-num { font-family: 'Fraunces'; font-weight: 700; font-size: 1.15rem; color: var(--ink); font-variant-numeric: tabular-nums; }
  .demo-stat-bar-track { height: 0.55rem; border-radius: 999px; background: var(--line); overflow: hidden; }
  .demo-stat-bar-fill { height: 100%; width: 0%; border-radius: 999px; transition: none; }
  .demo-stat-bar-fill.charts { background: linear-gradient(90deg, var(--ochre), var(--sienna)); }
  .demo-stat-bar-fill.pct { background: linear-gradient(90deg, #5FA38C, var(--good)); }

  /* ---------- Employment step (payroll connect / resume upload) ---------- */
  .employment-providers { display: grid; grid-template-columns: repeat(2, 1fr); gap: 0.5rem; margin-top: 0.4rem; }
  .employment-providers.locked .employment-provider:not(.connected) { pointer-events: none; opacity: 0.4; }
  .employment-provider {
    position: relative; display: flex; align-items: center; justify-content: space-between; gap: 0.5rem;
    border: 1.5px solid var(--line); border-radius: 0.7rem; padding: 0.65rem 0.7rem;
    cursor: pointer; background: var(--surface-raised);
    transition: background 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease, color 0.2s ease;
  }
  .employment-provider.selected {
    border-color: var(--sienna);
    background: color-mix(in srgb, var(--ochre) 10%, var(--surface-raised));
  }
  .employment-provider.connecting {
    border-color: var(--ochre);
    background: color-mix(in srgb, var(--ochre) 14%, var(--surface-raised));
  }
  .employment-provider.connected {
    border-color: transparent; color: #fff; cursor: default;
    background: linear-gradient(135deg, var(--ochre), var(--sienna));
    box-shadow: 0 0.2rem 0.5rem rgba(0,0,0,.15);
  }
  .ep-logo {
    height: 1.5rem; padding: 0.15rem 0.4rem; border-radius: 0.4rem; background: #fff;
    display: flex; align-items: center; justify-content: flex-start; flex: 1; min-width: 0;
  }
  .ep-logo img { height: 100%; max-width: 100%; object-fit: contain; display: block; }
  .ep-radio {
    width: 1.15rem; height: 1.15rem; border-radius: 999px; flex: none; position: relative;
    border: 1.5px solid var(--line); background: var(--surface);
    display: flex; align-items: center; justify-content: center;
    transition: background 0.2s ease, border-color 0.2s ease;
  }
  .employment-provider.selected .ep-radio { border-color: var(--sienna); background: var(--sienna); }
  .employment-provider.selected .ep-radio::after { content: ''; width: 0.4rem; height: 0.4rem; border-radius: 999px; background: #fff; }
  .employment-provider.connecting .ep-radio { border-color: var(--ochre); background: transparent; }
  .employment-provider.connected .ep-radio { border-color: rgba(255,255,255,.7); background: rgba(255,255,255,.22); }
  .ep-radio-spin { display: none; }
  .employment-provider.connecting .ep-radio-spin {
    display: block; width: 0.68rem; height: 0.68rem; border-radius: 999px;
    border: 1.5px solid color-mix(in srgb, var(--ochre) 40%, transparent); border-top-color: var(--ochre);
    animation: epSpin 0.7s linear infinite;
  }
  @keyframes epSpin { to { transform: rotate(360deg); } }
  .ep-radio-check { display: none; width: 0.65rem; height: 0.65rem; color: #fff; }
  .employment-provider.connected .ep-radio-check { display: block; }
  .employment-hint { font-size: 0.66rem; color: var(--ink-soft); margin-top: 0.6rem; }
  .employment-connect-cta {
    margin-top: 0.6rem; text-align: center; font-size: 0.78rem; font-weight: 700; color: #fff;
    background: linear-gradient(135deg, #5FA38C, var(--good)); border-radius: 0.7rem; padding: 0.65rem;
    cursor: pointer; transition: background 0.5s ease, color 0.4s ease, transform 0.15s ease;
  }
  .employment-connect-cta.pending {
    cursor: default; background: linear-gradient(135deg, var(--amber), var(--ochre)); color: rgba(255,255,255,0.75);
  }
  .employment-connect-cta.done { cursor: default; }
  .employment-connect-cta:not(.pending):not(.done):active { transform: scale(0.98); }
  .employment-collapse {
    display: grid; grid-template-rows: 1fr; opacity: 1;
    transition: grid-template-rows 0.5s ease, opacity 0.4s ease;
  }
  .employment-collapse.collapsed { grid-template-rows: 0fr; opacity: 0; }
  .employment-collapse-inner { overflow: hidden; min-height: 0; }
  .employment-result-card { margin-top: 1.4rem; }
  .employment-result-head {
    display: flex; align-items: center; gap: 0.4rem; font-size: 0.76rem; font-weight: 700; color: var(--good);
    margin-bottom: 0.5rem;
  }
  .employment-result-head .trust { margin-left: auto; }

  /* ---------- Verified Skills: "New" tag on the post-assessment skill ---------- */
  /* Sits as a small ribbon on the icon's corner rather than inline with
     the skill name -- inline wrapped onto its own line for longer names. */
  .skill-new-tag {
    position: absolute; top: -0.4rem; right: -0.4rem;
    font-size: 0.52rem; font-weight: 800; text-transform: uppercase; letter-spacing: 0.03em;
    color: #fff; background: linear-gradient(135deg, #5FA38C, var(--good)); padding: 0.14rem 0.4rem; border-radius: 999px;
    white-space: nowrap; box-shadow: 0 0.15rem 0.35rem -0.05rem color-mix(in srgb, var(--good) 60%, transparent), 0 0 0 2px var(--surface-raised);
  }

  /* ---------- Assessment gateway (five modules) ---------- */
  .gw-eyebrow {
    font-size: 0.66rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.06em;
    color: var(--sienna); margin-bottom: 0.2rem;
  }
  .gw-module {
    display: flex; align-items: flex-start; gap: 0.7rem; background: var(--surface-raised);
    border: 1.5px solid var(--line); border-radius: 0.9rem; padding: 0.85rem 0.9rem; margin-bottom: 0.6rem;
    transition: box-shadow 0.2s ease;
  }
  .gw-module-active {
    border-color: var(--good); background: linear-gradient(155deg, var(--surface-raised), color-mix(in srgb, var(--good) 7%, var(--surface-raised)));
    box-shadow: 0 0.4rem 1rem rgba(47,107,87,.14);
  }
  .gw-num {
    width: 1.7rem; height: 1.7rem; border-radius: 999px; flex: none; margin-top: 0.05rem;
    background: var(--line); color: var(--ink-soft);
    display: flex; align-items: center; justify-content: center; font-family: 'Fraunces'; font-weight: 700; font-size: 0.76rem;
  }
  .gw-num-active {
    background: linear-gradient(135deg, var(--amber), var(--ochre)); color: #fff;
    box-shadow: 0 0.18rem 0.4rem -0.08rem color-mix(in srgb, var(--ochre) 60%, transparent);
  }
  .gw-body { flex: 1; min-width: 0; padding-top: 0.05rem; }
  .gw-title-row { display: flex; align-items: center; gap: 0.4rem; flex-wrap: wrap; }
  .gw-name { font-size: 0.86rem; font-weight: 700; letter-spacing: -0.005em; }
  .gw-tag {
    font-size: 0.56rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.02em;
    background: var(--good-bg); color: var(--good);
    padding: 0.1rem 0.4rem; border-radius: 999px;
  }
  .gw-desc { font-size: 0.71rem; color: var(--ink-soft); margin-top: 0.25rem; line-height: 1.48; }
  .gw-side { flex: none; text-align: right; padding-top: 0.05rem; }
  .gw-time { font-size: 0.64rem; font-weight: 600; color: var(--ink-soft); margin-bottom: 0.4rem; }
  .gw-start-btn {
    font-size: 0.68rem; font-weight: 700; color: #fff; background: linear-gradient(135deg, #5FA38C, var(--good));
    box-shadow: 0 0.22rem 0.55rem -0.1rem color-mix(in srgb, var(--good) 55%, transparent);
    padding: 0.4rem 0.8rem; border-radius: 0.55rem; cursor: pointer; white-space: nowrap;
    transition: transform 0.12s ease, box-shadow 0.12s ease;
  }
  .gw-start-btn:active {
    transform: scale(0.96);
    box-shadow: 0 0.12rem 0.3rem -0.05rem color-mix(in srgb, var(--good) 55%, transparent);
  }
  .gw-unavailable { font-size: 0.6rem; color: var(--ink-soft); white-space: nowrap; }

  /* ---------- Results summary ("You are verified") ---------- */
  .results-stats { padding: 0.9rem; }
  .results-stats .results-cred-row {
    display: flex; align-items: center; justify-content: space-between; gap: 0.6rem;
    font-size: 0.68rem; color: var(--ink-soft); padding-top: 0.7rem; margin-top: 0.7rem; border-top: 1px solid var(--line);
  }
  .results-stat { display: inline-block; width: 48%; vertical-align: top; margin-bottom: 0.7rem; }
  .results-stat-label { font-size: 0.58rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.03em; color: var(--ink-soft); }
  .results-stat-value { font-family: 'Fraunces'; font-weight: 700; font-size: 1.05rem; margin-top: 0.15rem; }
  .results-stat-sub { font-size: 0.64rem; color: var(--ink-soft); margin-top: 0.1rem; }
  .results-teaser {
    display: flex; align-items: center; justify-content: space-between; gap: 0.8rem;
    background: color-mix(in srgb, var(--ochre) 8%, var(--surface-raised)); border: 1px solid color-mix(in srgb, var(--ochre) 30%, var(--line));
    border-radius: 0.9rem; padding: 0.85rem; margin-top: 0.7rem;
  }
  .results-teaser-title { font-size: 0.8rem; font-weight: 700; line-height: 1.35; }
  .results-teaser-sub { font-size: 0.66rem; color: var(--ink-soft); margin-top: 0.2rem; line-height: 1.4; }
  .results-teaser-pct { font-family: 'Fraunces'; font-weight: 700; font-size: 1.4rem; color: var(--sienna); flex: none; }
  .results-actions { margin-top: 0.8rem; }

  /* ---------- Chart review screen ---------- */
  .progress-row { display: flex; align-items: center; gap: 0.4rem; padding: 0.3rem 1.1rem 0.7rem; flex: none; }
  .progress-dot { flex: 1; height: 0.32rem; border-radius: 999px; background: var(--line); }
  .progress-dot.done { background: var(--good); }
  .progress-dot.active { background: var(--ochre); }
  .progress-label { font-size: 0.68rem; color: var(--ink-soft); flex: none; margin-left: 0.3rem; white-space: nowrap; }
  .chart-review-scroll { flex: 1; overflow-y: auto; padding: 0 1.1rem 1rem; }
  .chart-card { background: var(--surface-raised); border: 1px solid var(--line); border-radius: 1rem; overflow: hidden; margin-bottom: 0.8rem; }
  .chart-head { padding: 0.7rem 0.85rem; border-bottom: 1px solid var(--line); display: flex; align-items: center; justify-content: space-between; }
  .chart-head .id { font-family: 'Fraunces'; font-weight: 600; font-size: 0.82rem; }
  .chart-head .type { font-size: 0.68rem; color: var(--ink-soft); margin-top: 0.1rem; }
  .flag-chip {
    font-size: 0.6rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.03em;
    padding: 0.22rem 0.5rem; border-radius: 999px; flex: none;
    background: color-mix(in srgb, var(--ochre) 16%, transparent); color: var(--sienna);
  }
  .code-row { display: flex; justify-content: space-between; align-items: flex-start; gap: 0.5rem; padding: 0.6rem 0.85rem; border-bottom: 1px solid var(--line); font-size: 0.76rem; }
  .code-row:last-of-type { border-bottom: none; }
  .code-row .label { color: var(--ink-soft); font-size: 0.64rem; text-transform: uppercase; letter-spacing: 0.02em; }
  .code-row .code { font-weight: 600; margin-top: 0.15rem; }
  .code-row.flagged { background: color-mix(in srgb, var(--ochre) 6%, var(--surface-raised)); }
  .code-row .mono { font-family: ui-monospace, Menlo, monospace; }
  .prompt-box {
    display: flex; align-items: flex-start; gap: 0.6rem;
    padding: 0.8rem 0.9rem; border-radius: 0.85rem;
    background: color-mix(in srgb, var(--demo-accent) 7%, var(--surface-raised));
    border: 1px solid color-mix(in srgb, var(--demo-accent) 22%, transparent);
  }
  .prompt-q {
    flex: none; width: 1.4rem; height: 1.4rem; border-radius: 999px;
    background: var(--demo-accent); color: #fff; font-family: 'Fraunces'; font-weight: 700; font-size: 0.8rem;
    display: flex; align-items: center; justify-content: center; margin-top: 0.05rem;
  }
  .prompt-text { font-size: 0.8rem; font-weight: 600; color: var(--ink); line-height: 1.5; }
  .choice-row { display: flex; gap: 0.6rem; padding: 0.9rem 1.1rem 1.1rem; flex: none; }
  .choice-btn {
    flex: 1; text-align: center; font-size: 0.8rem; font-weight: 600;
    padding: 0.7rem 0.4rem; border-radius: 0.75rem; border: 1.5px solid var(--line);
    color: var(--ink-soft); cursor: pointer;
  }
  .choice-btn.primary { background: var(--good-bg); border-color: var(--good); color: var(--good); }
  .done-wrap { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: 2rem 1.5rem; gap: 0.9rem; }
  .done-badge {
    width: 3.2rem; height: 3.2rem; border-radius: 999px; background: linear-gradient(135deg, #5FA38C, var(--good));
    display: flex; align-items: center; justify-content: center; flex: none; position: relative;
    border: 0.15rem solid #fff;
    box-shadow: 0 0 0 1px color-mix(in srgb, var(--good) 45%, transparent), 0 0.35rem 0.7rem -0.15rem color-mix(in srgb, var(--good) 55%, transparent);
  }
  .done-badge::before, .done-badge::after {
    content: ''; position: absolute; bottom: -0.5rem; width: 0.5rem; height: 0.85rem;
    background: var(--sienna); z-index: -1;
    clip-path: polygon(0 0, 100% 0, 100% 100%, 50% 72%, 0 100%);
  }
  .done-badge::before { left: 0.35rem; transform: rotate(14deg); }
  .done-badge::after { right: 0.35rem; transform: rotate(-14deg); }
  .done-badge svg { width: 1.5rem; height: 1.5rem; color: #fff; }
  .module-badge-img {
    width: 7rem; height: auto; flex: none; position: relative; z-index: 2;
    filter: drop-shadow(0 0.35rem 0.7rem color-mix(in srgb, var(--sienna) 45%, transparent));
    animation: badgeRevealPop 0.65s cubic-bezier(.34,1.56,.64,1) both;
  }
  @keyframes badgeRevealPop {
    0% { opacity: 0; transform: scale(0.4) rotate(-8deg); }
    100% { opacity: 1; transform: scale(1) rotate(0deg); }
  }
  .badge-sparkle-wrap { position: relative; display: flex; align-items: center; justify-content: center; }
  .badge-flash {
    position: absolute; top: 50%; left: 50%; width: 7rem; height: 7rem; border-radius: 999px;
    background: radial-gradient(circle, color-mix(in srgb, #FFE9A8 75%, transparent) 0%, transparent 72%);
    transform: translate(-50%, -50%) scale(0); opacity: 0; z-index: 0;
    animation: badgeFlashPulse 1s ease-out both;
  }
  @keyframes badgeFlashPulse {
    0% { opacity: 0; transform: translate(-50%, -50%) scale(0.3); }
    30% { opacity: 1; transform: translate(-50%, -50%) scale(1.15); }
    100% { opacity: 0; transform: translate(-50%, -50%) scale(1.9); }
  }
  /* Deliberately BEHIND the badge (z-index 1, badge is 2) -- a sparkle
     mid-flight can pass "behind" the shield and get occluded by it
     instead of ever visually covering the artwork. */
  .badge-sparkle {
    position: absolute; top: 50%; left: 50%; opacity: 0; z-index: 1;
    margin: 0; --tx: 0rem; --ty: 0rem;
    animation-name: badgeSparklePop; animation-timing-function: cubic-bezier(.16,.84,.44,1); animation-fill-mode: both;
  }
  .badge-sparkle svg { width: 100%; height: 100%; display: block; filter: drop-shadow(0 0 0.3rem currentColor) drop-shadow(0 0 0.1rem #fff); }
  @keyframes badgeSparklePop {
    0% { opacity: 0; transform: translate(-50%, -50%) translate(calc(var(--tx) * 0.3), calc(var(--ty) * 0.3)) scale(0.15) rotate(0deg); }
    22% { opacity: 1; transform: translate(-50%, -50%) translate(calc(var(--tx) * 0.65), calc(var(--ty) * 0.65)) scale(1.15) rotate(25deg); }
    60% { opacity: 1; transform: translate(-50%, -50%) translate(var(--tx), var(--ty)) scale(0.85) rotate(60deg); }
    100% { opacity: 0; transform: translate(-50%, -50%) translate(calc(var(--tx) * 1.1), calc(var(--ty) * 1.1)) scale(0.55) rotate(80deg); }
  }
  .credential-badge { width: 2.7rem; height: 2.7rem; flex: none; position: relative; display: flex; align-items: center; justify-content: center; }
  .credential-badge svg { width: 100%; height: 100%; filter: drop-shadow(0 0.2rem 0.35rem color-mix(in srgb, var(--sienna) 45%, transparent)); }
  .credential-badge::before, .credential-badge::after {
    content: ''; position: absolute; bottom: -0.3rem; width: 0.45rem; height: 0.75rem;
    background: var(--sienna); z-index: -1;
    clip-path: polygon(0 0, 100% 0, 100% 100%, 50% 72%, 0 100%);
  }
  .credential-badge::before { left: 0.42rem; transform: rotate(12deg); }
  .credential-badge::after { right: 0.42rem; transform: rotate(-12deg); }
  .done-wrap h2 { font-size: 1.1rem; font-family: 'Fraunces'; font-weight: 600; }
  .done-wrap p { font-size: 0.82rem; color: var(--ink-soft); line-height: 1.55; max-width: 16rem; margin: 0; }
  .back-cta {
    margin-top: 0.4rem; width: 100%; max-width: 18rem;
    background: var(--surface-raised); border: 1.5px solid var(--line); color: var(--ink);
    font-weight: 600; font-size: 0.8rem; padding: 0.65rem; border-radius: 0.75rem; cursor: pointer;
  }
  .review-info-row { padding: 0.7rem 0; border-bottom: 1px solid var(--line); }
  .review-info-row:last-of-type { border-bottom: none; }
  .review-info-label {
    font-size: 0.64rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.04em;
    color: var(--good); margin-bottom: 0.3rem;
  }
  .review-info-value { font-size: 0.78rem; color: var(--ink); line-height: 1.55; }

  /* ---------- Module 2 demo (accelerated, auto-playing) ---------- */
  .demo-cta {
    display: flex; align-items: center; justify-content: center; gap: 0.4rem;
    margin-top: 0.5rem; background: var(--surface-raised); border: 1.5px dashed color-mix(in srgb, var(--ochre) 55%, var(--line));
    color: var(--sienna); font-weight: 600; font-size: 0.76rem; padding: 0.55rem; border-radius: 0.7rem; cursor: pointer;
  }
  .demo-cta-tag {
    font-size: 0.58rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.03em;
    background: color-mix(in srgb, var(--ochre) 18%, transparent); color: var(--sienna);
    padding: 0.1rem 0.4rem; border-radius: 999px;
  }
  .demo-ribbon {
    font-size: 0.68rem; font-weight: 700; color: #fff; text-align: center;
    background: var(--demo-accent);
    border: 1px solid var(--demo-accent);
    border-radius: 0.7rem; padding: 0.5rem 0.7rem; margin-bottom: 0.8rem;
    box-shadow: 0 0.3rem 0.7rem -0.2rem color-mix(in srgb, var(--demo-accent) 50%, transparent);
  }
  .demo-chart-num {
    width: 1.5rem; height: 1.5rem; border-radius: 999px; flex: none;
    background: linear-gradient(135deg, var(--amber), var(--ochre)); color: #fff;
    display: flex; align-items: center; justify-content: center;
    font-family: 'Fraunces'; font-weight: 700; font-size: 0.72rem;
  }
  @keyframes demoReveal { from { opacity: 0; transform: translateY(0.6rem); } to { opacity: 1; transform: translateY(0); } }
  .demo-reveal { opacity: 0; animation: demoReveal 0.5s cubic-bezier(.22,.8,.32,1) forwards; }

  /* code correction (old struck through, new revealed) — delay set per-instance inline */
  .demo-code-wrap { display: flex; flex-direction: column; gap: 0.15rem; margin-top: 0.15rem; }
  .demo-code-old { font-weight: 600; color: var(--ink-soft); animation: demoStrike 0.3s ease forwards; }
  @keyframes demoStrike { to { text-decoration: line-through; opacity: 0.55; } }
  .demo-code-new { font-weight: 600; color: var(--good); opacity: 0; animation: demoReveal 0.4s cubic-bezier(.22,.8,.32,1) forwards; }

  /* a missing code being added — ghost placeholder crossfades into the real code, stacked so no layout jump */
  .demo-code-stack { position: relative; min-height: 1.2rem; margin-top: 0.15rem; }
  .demo-code-ghost {
    position: absolute; left: 0; top: 0; display: inline-flex; align-items: center; gap: 0.3rem;
    font-weight: 600; color: var(--ink-soft); border: 1.5px dashed var(--line); border-radius: 0.4rem;
    padding: 0.15rem 0.5rem; font-size: 0.72rem;
    animation: demoFadeOutAbs 0.3s ease forwards;
  }
  @keyframes demoFadeOutAbs { to { opacity: 0; } }
  .demo-code-added {
    position: absolute; left: 0; top: 0; font-weight: 600; color: var(--good); opacity: 0;
    animation: demoReveal 0.4s cubic-bezier(.22,.8,.32,1) forwards;
  }

  /* the deliberating cursor that weighs the two answer choices before "clicking" one */
  #screen-module-demo .choice-btn {
    cursor: default; transition: background 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
    background: var(--surface-raised); border: 1.5px solid var(--line);
    box-shadow: 0 0.15rem 0.4rem -0.1rem rgba(42,38,34,0.1);
  }
  .demo-question-label {
    font-size: 0.66rem; font-weight: 800; text-transform: uppercase; letter-spacing: 0.05em;
    color: var(--sienna); margin-bottom: 0.15rem;
  }
  .demo-question-text {
    padding: 0.6rem 0.85rem; font-size: 0.78rem; font-weight: 700; color: var(--ink);
    border-bottom: 1px solid var(--line); background: #fff;
  }
  #screen-module-demo .code-row.flagged { background: #fff; }
  .choice-row#module-demo-choices { position: relative; flex-direction: column; padding: 0.6rem 0 0; gap: 0.5rem; margin-top: 0.6rem; }
  .choice-row#module-demo-choices .choice-btn { text-align: left; padding: 0.6rem 0.8rem; display: flex; align-items: center; gap: 0.6rem; }
  .choice-letter {
    flex: none; width: 1.5rem; height: 1.5rem; border-radius: 999px;
    border: 1.5px solid var(--line); display: flex; align-items: center; justify-content: center;
    font-family: 'Fraunces'; font-weight: 700; font-size: 0.7rem; color: var(--ink-soft);
    transition: background 0.25s ease, border-color 0.25s ease, color 0.25s ease;
  }
  #screen-module-demo .choice-btn.considering {
    border-color: var(--ochre); background: color-mix(in srgb, var(--ochre) 30%, var(--surface-raised));
    box-shadow: 0 0 0 1px var(--ochre), 0 0.25rem 0.5rem -0.1rem color-mix(in srgb, var(--ochre) 45%, transparent);
  }
  .choice-btn.considering .choice-letter { border-color: var(--ochre); background: var(--ochre); color: #fff; }
  #screen-module-demo .choice-btn.chosen { border-color: var(--sienna); background: color-mix(in srgb, var(--ochre) 18%, var(--surface-raised)); color: var(--sienna); }
  .choice-btn.chosen .choice-letter { border-color: var(--sienna); background: var(--sienna); color: #fff; }
  .demo-cursor {
    position: absolute; width: 1.1rem; height: 1.1rem; z-index: 5; opacity: 0; pointer-events: none;
    transform: translate(-20%, -12%);
    transition: left 0.6s cubic-bezier(.4,0,.2,1), top 0.6s cubic-bezier(.4,0,.2,1), opacity 0.3s ease;
    filter: drop-shadow(0 0.12rem 0.16rem rgba(0,0,0,.35));
  }
  .demo-cursor.visible { opacity: 1; }
  .demo-cursor svg { width: 100%; height: 100%; display: block; }
  .demo-click-ring2 {
    position: absolute; width: 0.1rem; height: 0.1rem; border-radius: 999px; margin: -0.05rem;
    border: 1.5px solid var(--sienna); opacity: 0.8; z-index: 4; pointer-events: none;
    animation: demoClickRing2 0.5s ease forwards;
  }
  @keyframes demoClickRing2 { to { opacity: 0; width: 1.6rem; height: 1.6rem; margin: -0.8rem; } }

  .demo-drg {
    display: flex; align-items: center; gap: 0.4rem; flex-wrap: wrap; font-size: 0.72rem; font-weight: 600;
    padding: 0.6rem 0.85rem; border-top: 1px solid var(--line);
    opacity: 0; animation: demoDrgIn 0.4s ease forwards;
  }
  @keyframes demoDrgIn { to { opacity: 1; } }
  .demo-drg-old { color: var(--ink-soft); text-decoration: line-through; }
  .demo-drg-arrow { color: var(--ink-soft); }
  .demo-drg-new {
    color: var(--sienna); background: color-mix(in srgb, var(--ochre) 14%, transparent);
    padding: 0.15rem 0.45rem; border-radius: 0.4rem;
    animation: demoFlash 0.6s ease;
  }
  @keyframes demoFlash { 0%, 100% { background: color-mix(in srgb, var(--ochre) 14%, transparent); } 40% { background: color-mix(in srgb, var(--ochre) 45%, transparent); } }

  .demo-explain { opacity: 0; animation: demoReveal 0.45s cubic-bezier(.22,.8,.32,1) forwards; }
  .demo-impact {
    display: inline-block; margin-top: 0.4rem; font-size: 0.64rem; font-weight: 700; color: var(--good);
    background: var(--good-bg); padding: 0.18rem 0.5rem; border-radius: 999px;
    opacity: 0; animation: demoPop 0.35s cubic-bezier(.3,1.4,.5,1) forwards;
  }
  @keyframes demoPop { from { opacity: 0; transform: scale(0.6); } to { opacity: 1; transform: scale(1); } }

  .demo-confirm {
    display: flex; align-items: center; gap: 0.25rem; font-size: 0.68rem; font-weight: 700; color: var(--good);
    flex: none; margin-top: 0.2rem; opacity: 0; animation: demoPop 0.4s cubic-bezier(.3,1.4,.5,1) forwards;
  }
  .demo-chosen {
    display: flex; align-items: center; gap: 0.55rem;
    padding: 0.6rem 0.85rem; border-bottom: 1px solid var(--line);
    font-size: 0.76rem; font-weight: 600; color: var(--ink);
  }
  .demo-chosen .choice-letter {
    flex: none; width: 1.4rem; height: 1.4rem; border-radius: 999px;
    background: var(--sienna); color: #fff; border: none;
    display: flex; align-items: center; justify-content: center;
    font-family: 'Fraunces'; font-weight: 700; font-size: 0.68rem;
  }

  .demo-summary { opacity: 0; animation: demoReveal 0.5s cubic-bezier(.22,.8,.32,1) forwards; margin-bottom: 1rem; }
  .demo-continue-cta {
    display: flex; align-items: center; justify-content: center; gap: 0.4rem;
    background: linear-gradient(135deg, #5FA38C, var(--good)); color: #fff; font-weight: 600; font-size: 0.8rem;
    padding: 0.65rem; border-radius: 0.75rem; cursor: pointer; margin-top: 0.6rem;
  }
  .demo-continue-cta svg { width: 0.85rem; height: 0.85rem; flex: none; }

  @media (prefers-reduced-motion: reduce) {
    .demo-reveal, .demo-code-old, .demo-code-new, .demo-code-ghost, .demo-code-added,
    .demo-drg, .demo-drg-new, .demo-explain, .demo-impact, .demo-confirm, .demo-summary {
      animation: none !important; opacity: 1 !important; transform: none !important;
    }
    .demo-code-old { text-decoration: line-through; opacity: 0.55; }
    .demo-code-ghost { display: none; }
    .employment-collapse { transition: none; }
  }

  /* hidden presenter tool: a faint dot so it can be found on purpose,
     without reading as a real app control */
  #demo-tap-zone::after {
    content: ''; position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%);
    width: 0.26rem; height: 0.26rem; border-radius: 999px;
    background: var(--ink-soft); opacity: 0.11;
    transition: opacity 0.25s ease, background 0.25s ease;
  }
  #demo-tap-zone.fast::after { background: var(--ochre); opacity: 0.35; }
