/* Agentive Academy v4: mirrors the Agentive Client OS v12 (tab layout, option A navy and gold). */
@font-face { font-family: "Fraunces"; src: url("/assets/fonts/fraunces.woff2") format("woff2"); font-weight: 300 700; font-style: normal; font-display: swap; }
@font-face { font-family: "Fraunces"; src: url("/assets/fonts/fraunces-italic.woff2") format("woff2"); font-weight: 300 700; font-style: italic; font-display: swap; }
@font-face { font-family: "Manrope"; src: url("/assets/fonts/manrope.woff2") format("woff2"); font-weight: 300 800; font-style: normal; font-display: swap; }
@font-face { font-family: "JetBrains Mono"; src: url("/assets/fonts/jetbrains-mono.woff2") format("woff2"); font-weight: 400 700; font-style: normal; font-display: swap; }

:root {
  --page: #01020D;
  --navy-1: #070A24;
  --navy-2: #0C1030;
  --navy-3: #12173D;
  --box: #1B2150;
  --box-2: #222a5e;
  --edge: #A67A2C;
  --gold: #D9A84C;
  --gold-hi: #F2D68E;
  --gold-tx: #E5BD63;
  --fg: #F4EFE4;
  --muted: #C9C3B4;
  --subtle: #A39D8F;
  --line: rgba(226, 191, 110, 0.18);
  --line-2: rgba(226, 191, 110, 0.32);
  --success: #8fe0a9;
  --danger: #ff9d88;
  --serif: "Fraunces", Georgia, "Times New Roman", serif;
  --sans: "Manrope", -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
  --mono: "JetBrains Mono", Menlo, Consolas, monospace;
  --r: 6px;
  --r-lg: 10px;
  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);
  --topbar-h: 60px;
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html, body { margin: 0; padding: 0; }
body { font-family: var(--sans); background: var(--page); color: var(--fg); line-height: 1.5; font-size: 15px; min-height: 100vh; display: flex; flex-direction: column; }
a { color: var(--gold-tx); text-decoration: none; }
a:hover { color: var(--gold-hi); text-decoration: underline; }
p a:not(.btn), .lead a, .auth-links a, dd a, li a:not(.btn), .alert a { text-decoration: underline; text-underline-offset: 2px; }
h1, h2, h3 { font-family: var(--serif); font-weight: 500; letter-spacing: -0.015em; margin: 0 0 .5rem; color: var(--fg); }
h1 { font-size: clamp(1.5rem, 2.6vw, 2rem); }
h2 { font-size: 1.35rem; }
h3 { font-size: 1.08rem; color: var(--gold-hi); }
p { margin: 0 0 .75rem; }
.muted { color: var(--muted); }
.subtle { color: var(--subtle); }
.small { font-size: .85rem; }
.mono { font-family: var(--mono); font-size: .88em; overflow-wrap: anywhere; }
.nowrap { white-space: nowrap; }
.right { text-align: right; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; border: 0; }
.kicker { font-size: .72rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--gold); margin: 0 0 .35rem; }
.kicker a { color: var(--gold); }
.lede { max-width: 46rem; }
.hint { color: var(--subtle); font-weight: 400; font-size: .8rem; }
.skip-link { position: absolute; left: .75rem; top: -3rem; z-index: 1000; padding: .55rem .9rem; border-radius: var(--r); background: var(--gold); color: var(--page); font-weight: 700; }
.skip-link:focus { top: .75rem; }
:focus-visible { outline: 2px solid var(--gold-hi); outline-offset: 2px; }
main:focus { outline: none; }

/* ---------- top bar ---------- */
.topbar { position: sticky; top: 0; z-index: 50; height: var(--topbar-h); display: flex; align-items: center; gap: 1.5rem; padding: 0 var(--side-gutter); background: rgba(1, 2, 13, .94); border-bottom: 1px solid var(--line-2); backdrop-filter: blur(8px); }
.brand { display: flex; align-items: center; gap: .6rem; color: var(--fg); flex-shrink: 0; }
.brand:hover { text-decoration: none; }
.brand img { height: 34px; width: auto; }
.brand-label { font-family: var(--serif); font-size: 1.05rem; color: var(--gold-hi); padding-left: .6rem; border-left: 1px solid var(--line-2); }
.topnav { display: flex; gap: 1.4rem; align-self: stretch; overflow-x: auto; scrollbar-width: none; }
.topnav a { display: flex; align-items: center; color: var(--muted); font-weight: 600; font-size: .92rem; border-bottom: 2px solid transparent; white-space: nowrap; padding-top: 2px; }
.topnav a:hover { color: var(--fg); text-decoration: none; }
.topnav a.active { color: var(--gold-hi); border-bottom-color: var(--gold); }
.topbar-user { margin-left: auto; display: flex; align-items: center; gap: .75rem; }
.topbar-user form { margin: 0; }
.topbar-user .who { color: var(--muted); font-size: .88rem; max-width: 14rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ---------- page ---------- */
/* Side gutter: the same share of the screen on every device. 3.75vw is 1 inch (96px) on a 2560px-wide monitor; change this one value to adjust it everywhere. */
:root { --side-gutter: 3.75vw; }
.main { flex: 1; width: 100%; max-width: none; margin: 0; padding: 1.5rem var(--side-gutter) 2rem; }
.page-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 1rem; flex-wrap: wrap; margin-bottom: 1.1rem; }
.page-head h1 { margin-bottom: .2rem; }
.page-head .lede { margin: 0; }
.head-actions { display: flex; gap: .5rem; flex-wrap: wrap; align-items: center; }
.site-footer { display: flex; justify-content: space-between; flex-wrap: wrap; gap: .5rem 1rem; padding: 1rem var(--side-gutter); border-top: 1px solid var(--line); color: var(--subtle); font-size: .8rem; }
.site-footer nav { display: flex; gap: 1rem; }
.site-footer a { color: var(--muted); }

/* ---------- boxes ---------- */
.card { position: relative; background: var(--box); border: 1px solid var(--edge); border-radius: var(--r-lg); padding: 1.1rem 1.2rem; margin-bottom: 1rem; min-width: 0; }
.card-head { display: flex; justify-content: space-between; align-items: center; gap: .75rem; flex-wrap: wrap; margin-bottom: .6rem; }
.card-head h2, .card-head h3 { margin: 0; }
.card-feature { background: linear-gradient(135deg, rgba(217,168,76,.10), transparent 55%), var(--box); }
.card-attention { border-color: var(--gold); box-shadow: 0 0 0 1px rgba(217,168,76,.35); }
.card-danger { border-color: rgba(255,157,136,.55); }
.narrow { max-width: 38rem; margin: 2rem auto; }
.narrow-wide { max-width: none; margin: 0 0 1rem; }
.narrow-wide p, .narrow-wide li { max-width: 75ch; }
.grid-2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 1rem; }
.grid-2 > .card { margin-bottom: 0; }
.grid-2 + .card, .grid-main + .card { margin-top: 1rem; }
.grid-main { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); gap: 1rem; }
.grid-main > .card { margin-bottom: 0; }
.kpi-grid { display: grid; grid-template-columns: 1fr 1fr; gap: .75rem; }
.kpi-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: .75rem; margin-bottom: 1rem; }
.kpi { background: var(--box); border: 1px solid var(--edge); border-radius: var(--r-lg); padding: .85rem 1rem; }
.kpi .label { font-size: .7rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.kpi .value { font-family: var(--serif); font-size: 1.7rem; color: var(--gold-hi); line-height: 1.15; margin-top: .2rem; }
.kpi .hint { font-size: .8rem; color: var(--muted); }
.summary-strip { display: flex; flex-wrap: wrap; align-items: center; gap: .75rem 2rem; }
.strip-stats { display: flex; flex-wrap: wrap; gap: .5rem 1.5rem; color: var(--muted); font-size: .9rem; }
.strip-stats strong { color: var(--fg); }
.actions { display: flex; flex-wrap: wrap; gap: .5rem; margin-top: .9rem; }

/* ---------- tabs (the Client OS v12 pattern) ---------- */
.tabset { min-width: 0; }
.tabs { display: flex; gap: 1.5rem; border-bottom: 1px solid var(--line-2); margin-bottom: 1rem; overflow-x: auto; scrollbar-width: thin; }
.tabs [role="tab"] { appearance: none; background: none; border: 0; border-bottom: 2px solid transparent; color: var(--muted); font: 600 .95rem var(--sans); padding: .6rem 0 .55rem; cursor: pointer; white-space: nowrap; display: inline-flex; align-items: center; gap: .4rem; }
.tabs [role="tab"]:hover { color: var(--fg); }
.tabs [role="tab"][aria-selected="true"] { color: var(--gold-hi); border-bottom-color: var(--gold); }
.tabs .count { font-size: .72rem; color: var(--subtle); font-weight: 700; }
.js .tab-panel[hidden] { display: none; }
.tabs-select { display: none; margin-bottom: 1rem; }
@media (max-width: 720px) {
  .js .tabs { display: none; }
  .js .tabs-select { display: block; }
}

/* ---------- tables ---------- */
.table { width: 100%; border-collapse: collapse; font-size: .92rem; }
.table th, .table td { text-align: left; padding: .6rem .55rem; border-bottom: 1px solid var(--line); vertical-align: middle; }
.table th { color: var(--muted); font-weight: 700; font-size: .72rem; text-transform: uppercase; letter-spacing: .06em; }
.table th.right, .table td.right { text-align: right; }
.table tbody tr:hover td { background: rgba(255,255,255,.025); }
.table.compact th, .table.compact td { padding: .45rem .5rem; }
.table .sub { font-size: .8rem; margin-top: .15rem; }
.table tr[hidden] { display: none; }
.table-wrap { position: relative; overflow-x: auto; }
.pager { display: flex; align-items: center; justify-content: flex-end; gap: .6rem; margin-top: .75rem; }
.pager-info { color: var(--muted); font-size: .85rem; }
.tick { display: inline-grid; place-items: center; width: 1.3rem; height: 1.3rem; border-radius: 50%; background: var(--gold); color: var(--page); font-weight: 800; font-size: .8rem; }
.tick-empty { display: inline-block; width: 1.3rem; height: 1.3rem; border-radius: 50%; border: 1.5px solid var(--line-2); }
.tick-cell { width: 2rem; }

/* ---------- progress ---------- */
.pbar { display: inline-block; vertical-align: middle; width: 7rem; height: 8px; border-radius: 999px; background: rgba(255,255,255,.09); overflow: hidden; border: 1px solid var(--line); }
.pbar > span { display: block; height: 100%; background: linear-gradient(90deg, var(--edge), var(--gold-hi)); border-radius: 999px; }
.progress-line { display: flex; align-items: center; gap: .75rem; flex-wrap: wrap; margin-top: .5rem; }
.progress-line .pbar { width: min(22rem, 100%); }
.progress-line.big .pbar { height: 10px; width: min(26rem, 60vw); }
.progress-line strong { color: var(--gold-hi); font-size: 1.05rem; }

/* ---------- badges and pills ---------- */
.badge { display: inline-block; padding: .12rem .55rem; border-radius: 999px; font-size: .74rem; font-weight: 700; border: 1px solid var(--line-2); color: var(--muted); white-space: nowrap; }
.badge-gold { color: var(--gold-hi); border-color: var(--edge); }
.badge-success { color: var(--success); border-color: rgba(143,224,169,.45); }
.badge-danger { color: var(--danger); border-color: rgba(255,157,136,.5); }
.pill { display: inline-block; padding: .08rem .55rem; border-radius: 999px; background: var(--gold); color: var(--page); font-size: .72rem; font-weight: 800; white-space: nowrap; }

/* ---------- buttons ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: .4rem; font: 600 .9rem var(--sans); padding: .55rem .95rem; border-radius: var(--r); border: 1px solid var(--line-2); background: transparent; color: var(--fg); cursor: pointer; text-decoration: none; line-height: 1.2; transition: border-color .15s var(--ease), color .15s var(--ease), filter .15s var(--ease); }
.btn:hover { border-color: var(--gold); color: var(--gold-hi); text-decoration: none; }
.btn-primary { background: var(--gold); color: var(--page); border-color: var(--gold); }
.btn-primary:hover { color: var(--page); filter: brightness(1.08); }
.btn-ghost { border-color: transparent; color: var(--gold-tx); }
.btn-ghost:hover { border-color: var(--line-2); }
.btn-danger { border-color: rgba(255,157,136,.55); color: var(--danger); }
.btn-danger:hover { border-color: var(--danger); color: var(--danger); }
.btn-sm { padding: .32rem .65rem; font-size: .82rem; }
.btn-block { width: 100%; }
.btn.is-disabled, .btn:disabled { opacity: .45; cursor: not-allowed; pointer-events: none; }
.linklike { background: none; border: 0; padding: 0; color: var(--gold-tx); font: inherit; cursor: pointer; text-decoration: underline; }
form.inline { display: inline; margin: 0; }

/* ---------- forms ---------- */
.form { margin: 0; }
label { display: block; font-size: .85rem; color: var(--muted); margin-bottom: .3rem; font-weight: 600; }
input[type=text], input[type=email], input[type=password], input[type=search], input:not([type]), select, textarea {
  width: 100%; padding: .6rem .7rem; border-radius: var(--r); border: 1px solid var(--line-2); background: var(--navy-2); color: var(--fg); font: 400 .95rem var(--sans); margin-bottom: .85rem;
}
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--gold); box-shadow: 0 0 0 3px rgba(217,168,76,.35); }
label.check { display: flex; gap: .55rem; align-items: flex-start; font-weight: 500; color: var(--fg); margin: .2rem 0 .85rem; cursor: pointer; }
label.check input { width: auto; margin: .2rem 0 0; accent-color: var(--gold); }
fieldset.radios { border: 0; padding: 0; margin: 0 0 .5rem; }
.hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
.pw-wrap { position: relative; }
.pw-wrap input { padding-right: 4.2rem; }
.pw-toggle { position: absolute; right: .35rem; top: .35rem; background: transparent; border: 1px solid var(--line-2); color: var(--gold-tx); border-radius: 4px; padding: .22rem .5rem; font: 600 .78rem var(--sans); cursor: pointer; }
.toolbar { display: flex; flex-wrap: wrap; gap: .5rem; align-items: center; margin-bottom: .6rem; }
.toolbar input, .toolbar select { margin: 0; width: auto; min-width: 12rem; }
.toolbar-note { margin-left: auto; font-size: .85rem; }
.inline-filter { display: flex; align-items: center; gap: .5rem; margin: 0; }
.inline-filter span { font-size: .8rem; }
.inline-filter select { margin: 0; width: auto; min-width: 12rem; padding: .35rem .6rem; }
details.inline-details { display: inline-block; position: relative; }
details.inline-details > summary { list-style: none; }
details.inline-details > summary::-webkit-details-marker { display: none; }
.pop-form { position: absolute; right: 0; top: calc(100% + .35rem); z-index: 20; width: 18rem; background: var(--navy-3); border: 1px solid var(--edge); border-radius: var(--r-lg); padding: .8rem; text-align: left; box-shadow: 0 12px 30px rgba(0,0,0,.5); }
.pop-form input { margin-bottom: .6rem; }

/* ---------- alerts ---------- */
.alert { padding: .7rem .95rem; border-radius: var(--r); margin-bottom: 1rem; border: 1px solid var(--line-2); background: var(--navy-2); }
.alert-error { border-color: rgba(255,157,136,.55); color: var(--danger); }
.alert-success { border-color: rgba(143,224,169,.5); color: var(--success); }
.alert-info { border-color: var(--edge); color: var(--gold-hi); }
.empty { color: var(--muted); font-style: italic; margin: .25rem 0; }

/* ---------- auth ---------- */
.shell-auth .auth-main { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 2rem 1rem 0; gap: 1.5rem; }
.auth-card { width: min(440px, 100%); background: var(--box); border: 1px solid var(--edge); border-radius: var(--r-lg); padding: 1.75rem 1.75rem 1.4rem; }
.shell-auth .auth-card:has(.verify-result), .shell-auth .auth-card:has(.verify-form) { width: min(560px, 100%); }
.auth-logo { display: block; text-align: center; }
.auth-logo img { height: 52px; width: auto; }
.auth-kicker { text-align: center; color: var(--gold); font-size: .72rem; font-weight: 700; letter-spacing: .16em; text-transform: uppercase; margin: .4rem 0 1rem; }
.auth-card h1 { font-size: 1.5rem; text-align: center; color: var(--gold-hi); }
.auth-card .lead { text-align: center; color: var(--muted); font-size: .92rem; }
.auth-links { text-align: center; font-size: .88rem; color: var(--muted); margin: 1rem 0 0; }
.shell-auth .site-footer { width: 100%; border-top: 0; justify-content: center; }
.verify-form { display: grid; grid-template-columns: 1fr auto; gap: 0 .5rem; align-items: end; }
.verify-form label { grid-column: 1 / -1; }
.verify-form input { margin-bottom: 1rem; }
.verify-form .btn { margin-bottom: 1rem; }
.verify-result { border: 1px solid var(--gold); border-radius: var(--r-lg); padding: 1rem; background: var(--navy-2); }

/* ---------- facts and prose ---------- */
dl.facts { display: grid; grid-template-columns: max-content 1fr; gap: .45rem 1rem; margin: 0; }
dl.facts dt { color: var(--muted); font-size: .85rem; }
dl.facts dd { margin: 0; }
ul.checklist { padding-left: 1.1rem; margin: .5rem 0 0; color: var(--fg); }
ul.checklist li { margin-bottom: .3rem; }
ul.checklist li::marker { color: var(--gold); }
.prose h2 { font-size: 1.1rem; color: var(--gold-hi); margin-top: 1.1rem; }

/* ---------- public home ---------- */
.hero { border: 1px solid var(--edge); border-radius: var(--r-lg); padding: 1.6rem 1.6rem 1.3rem; margin-bottom: 1rem; background: linear-gradient(135deg, rgba(217,168,76,.12), transparent 50%), var(--box); }
.hero h1 { font-size: clamp(1.7rem, 3.2vw, 2.4rem); }
.hero-meta { display: flex; flex-wrap: wrap; gap: .5rem 1.5rem; margin-top: 1rem; color: var(--muted); font-size: .9rem; }
.hero-meta strong { color: var(--gold-hi); }

@media (max-width: 860px) {
  .topbar { gap: .9rem; }
  .topbar-user .who { display: none; }
  .grid-main { grid-template-columns: 1fr; }
  .table-wrap, .card { overflow-x: auto; }
}
@media (max-width: 640px) {
  .topbar { height: auto; flex-wrap: wrap; padding: .5rem var(--side-gutter); gap: .5rem; position: static; }
  .topnav { order: 3; width: 100%; gap: 0 1.1rem; padding-bottom: .1rem; flex-wrap: wrap; overflow: visible; }
  .topnav a { padding: .45rem 0; }
  .brand-label { display: none; }
  .page-head { align-items: flex-start; }
  .kpi-grid { grid-template-columns: 1fr 1fr; }
  .table th, .table td { padding: .5rem .4rem; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; animation: none !important; } }

/* ---------- certificates (v5) ---------- */
.cert-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 320px), 1fr)); gap: 1rem; }
.cert-card { display: flex; flex-direction: column; gap: .75rem; margin-bottom: 0; }
.cert-thumb { display: block; border-radius: var(--r); overflow: hidden; border: 1px solid var(--line-2); line-height: 0; }
.cert-thumb img { width: 100%; height: auto; display: block; }
.cert-thumb:hover { border-color: var(--gold); }
.cert-meta h3 { margin: 0 0 .25rem; }
.cert-meta .actions { display: flex; flex-wrap: wrap; gap: .4rem; margin-top: .5rem; }


/* ==========================================================================
   v4.4 Portal parity (9 Oct 2026): the Agentive Client OS v16 look, mapped onto
   the Academy's own markup. Appended last so it wins; delete this block to roll back.
   Source of truth: Client OS assets/css/app.css, "Website parity" and "Clean signal" layers.
   ========================================================================== */

/* 1. Tokens */
:root {
  --page: #000312;
  --navy-0: #000312;
  --glass: rgba(0, 2, 14, .92);
  --box: rgba(255, 255, 255, .025);
  --box-inset: rgba(255, 255, 255, .045);
  --edge: rgba(226, 191, 110, .14);
  --line: rgba(226, 191, 110, .14);
  --line-2: rgba(226, 191, 110, .28);
  --line-3: rgba(226, 191, 110, .5);
  --surface: rgba(255, 255, 255, .025);
  --surface-2: rgba(255, 255, 255, .045);
  --copper: #C98A4C;
  --gold-lo: #A67A2C;
  --r-lg: 14px;
  --grad-btn: linear-gradient(135deg, #F2D68E 0%, #D9A84C 45%, #C98A4C 100%);
  --grad-text: linear-gradient(100deg, #F2D68E 0%, #D9A84C 45%, #C98A4C 100%);
  --grad-num: linear-gradient(180deg, #F2D68E, #D9A84C 60%, #A67A2C);
  --grad-rec: linear-gradient(180deg, rgba(217,168,76,.09), rgba(217,168,76,.02));
  --grad-panel: linear-gradient(180deg, rgba(255,255,255,.035), rgba(255,255,255,.012));
  --display: "SOFT" 40, "opsz" 144;
  --topbar-h: 4.5rem;
}

/* 2. Page ground: plain navy with a faint gold haze from the top */
body {
  background-color: var(--page);
  background-image: radial-gradient(90% 50% at 50% -10%, rgba(217,168,76,.04), transparent 60%);
  background-attachment: fixed;
}

/* 3. Type: Fraunces light for every heading, one gold italic phrase per page title */
h1, h2, h3, .kpi .value, .course-card h3 {
  font-weight: 300; font-variation-settings: var(--display); letter-spacing: -0.02em;
}
h1 { font-size: clamp(1.9rem, 3vw, 2.5rem); }
h3, .card h2, .card h3 { color: var(--fg); }
h1 em, h2 em {
  font-style: italic; background: var(--grad-text); -webkit-background-clip: text; background-clip: text; color: transparent;
  padding-right: .12em; margin-right: -.12em;
}

/* 4. Masthead: glass bar, larger logo, mono product label, gold trace leaving the logo */
.topbar { height: auto; min-height: var(--topbar-h); background: var(--glass); border-bottom: 0; backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); gap: 1.25rem; }
.topbar::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: -8px; height: 16px; pointer-events: none;
  background:
    url("data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%221440%22%20height%3D%2216%22%20viewBox%3D%220%200%201440%2016%22%3E%3Cdefs%3E%3ClinearGradient%20id%3D%22t%22%20x1%3D%220%22%20y1%3D%220%22%20x2%3D%221440%22%20y2%3D%220%22%20gradientUnits%3D%22userSpaceOnUse%22%3E%3Cstop%20offset%3D%220%22%20stop-color%3D%22%23D9A84C%22%20stop-opacity%3D%22.2%22%2F%3E%3Cstop%20offset%3D%22.15%22%20stop-color%3D%22%23E5BD63%22%20stop-opacity%3D%22.9%22%2F%3E%3Cstop%20offset%3D%22.55%22%20stop-color%3D%22%23D9A84C%22%20stop-opacity%3D%22.22%22%2F%3E%3Cstop%20offset%3D%221%22%20stop-color%3D%22%23D9A84C%22%20stop-opacity%3D%22.08%22%2F%3E%3C%2FlinearGradient%3E%3C%2Fdefs%3E%3Cpath%20d%3D%22M0%208%20H200%20L206%202%20H430%20L436%208%20H1440%22%20stroke%3D%22url(%23t)%22%20stroke-width%3D%221%22%20fill%3D%22none%22%2F%3E%3Ccircle%20cx%3D%22206%22%20cy%3D%222%22%20r%3D%222.4%22%20fill%3D%22%23F2D68E%22%2F%3E%3Ccircle%20cx%3D%22436%22%20cy%3D%228%22%20r%3D%222%22%20fill%3D%22%23D9A84C%22%20opacity%3D%22.7%22%2F%3E%3C%2Fsvg%3E") no-repeat 0 0 / 1440px 16px,
    linear-gradient(90deg, rgba(217,168,76,.08), rgba(217,168,76,.08)) no-repeat 1440px 7.5px / 100% 1px;
}
.brand { gap: 1.1rem; }
.brand img { height: 46px; }
.brand-label { font-family: var(--mono); font-size: .66rem; font-weight: 500; letter-spacing: .3em; text-transform: uppercase; color: var(--gold-tx); padding-left: 1.1rem; border-left: 1px solid var(--line-2); }
.topnav { align-self: center; gap: .15rem; }
.topnav a { padding: .45rem .7rem; border: 1px solid transparent; border-radius: var(--r); font-weight: 500; font-size: .92rem; color: var(--muted); }
.topnav a:hover { color: var(--fg); }
.topnav a.active { color: var(--fg); background: var(--surface-2); border-color: var(--line-2); }
.topbar-user .who { color: var(--fg); font-weight: 600; }

/* 5. Kickers: mono with the fading gold rule */
.kicker, .auth-kicker {
  display: inline-flex; align-items: center; gap: .75rem;
  font-family: var(--mono); font-size: .7rem; font-weight: 500; letter-spacing: .2em; text-transform: uppercase; color: var(--gold-tx);
}
.kicker::before { content: ""; width: 1.6rem; height: 1px; background: linear-gradient(90deg, var(--gold), transparent); flex: none; }
.kicker a { color: var(--gold-tx); }
.auth-kicker { display: flex; justify-content: center; }
.main { padding-top: 2rem; }
.page-head { margin-bottom: 1.4rem; }
.page-head .lede { font-size: .97rem; color: var(--muted); max-width: 40rem; }

/* 6. Page title on the gold spine (My Learning) */
.page-head.spine { position: relative; padding-left: 2.25rem; }
.page-head.spine::before { content: ""; position: absolute; left: .5rem; top: .9rem; bottom: -1.4rem; width: 1px; background: linear-gradient(180deg, rgba(242,214,142,.85), rgba(217,168,76,.25)); }
.page-head.spine::after { content: ""; position: absolute; left: calc(.5rem - 4px); top: .9rem; width: 9px; height: 9px; border-radius: 50%; background: var(--gold-hi); box-shadow: 0 0 10px rgba(242,214,142,.8); }

/* 7. Tabs: mono labels, hairline rule, gold underline on the open tab */
.tabs { gap: 0; border-bottom: 1px solid var(--line); margin-bottom: 1.75rem; }
.tabs [role="tab"] { font-family: var(--mono); font-size: .72rem; font-weight: 500; letter-spacing: .14em; text-transform: uppercase; padding: .85rem .9rem; min-height: 44px; border-bottom-width: 2px; margin-bottom: -1px; }
.tabs [role="tab"][aria-selected="true"] { color: var(--fg); border-bottom-color: var(--gold); }
.tabs .count { display: inline-block; background: rgba(217,168,76,.12); color: var(--gold-tx); border: 1px solid var(--line-3); border-radius: 999px; font-size: .68rem; padding: 0 .45rem; letter-spacing: 0; margin-left: .35rem; }

/* 8. Surfaces: 2.5% white, 14% gold hairline, 14px radius */
.card, .auth-card, .pop-form { background: var(--box); border: 1px solid var(--edge); border-radius: var(--r-lg); }
.card { padding: 1.6rem; }
.pop-form { background: #0C1030; border-color: var(--line-2); }
.card .card { background: var(--box-inset); border-color: var(--line); }
.card-feature { background: var(--grad-rec); border-color: var(--line-3); }
.card-attention { border-color: var(--line-3); box-shadow: none; }
.hero { background: var(--grad-panel); border: 1px solid var(--line); }
.verify-result { background: var(--grad-rec); border-color: var(--line-3); }
.alert { background: var(--surface); border-radius: var(--r-lg); }

/* 9. Readouts: one bordered grid with glowing gold dots and gradient numbers */
.kpi-row, .kpi-grid { gap: 1px; border: 1px solid var(--line); border-radius: var(--r-lg); background: rgba(255,255,255,.02); overflow: hidden; }
.kpi-row > .kpi, .kpi-grid > .kpi { border: 0; border-radius: 0; background: transparent; box-shadow: 0 0 0 1px var(--line); padding: 1.25rem 1.4rem; }
.kpi .label { display: flex; align-items: center; gap: .5rem; font-family: var(--mono); font-size: .72rem; font-weight: 500; letter-spacing: .14em; color: var(--muted); }
.kpi .label::before { content: ""; width: 5px; height: 5px; border-radius: 50%; flex: none; background: var(--gold-hi); box-shadow: 0 0 8px rgba(242,214,142,.7); }
.kpi .value { font-family: var(--serif); font-size: 2.5rem; background: var(--grad-num); -webkit-background-clip: text; background-clip: text; color: transparent; display: inline-block; }
.kpi .hint { color: var(--subtle); }

/* 10. Progress: a 3px gold trail */
.pbar { height: 3px; border: 0; background: var(--line); border-radius: 999px; overflow: visible; }
.pbar > span { background: var(--grad-text); box-shadow: 0 0 12px rgba(217,168,76,.45); }
.progress-line.big .pbar { height: 3px; }

/* 11. Buttons: gradient primary, glass secondary, underlined ghost */
.btn { background: rgba(255,255,255,.02); border-color: var(--line-2); transition: transform .2s var(--ease), box-shadow .2s var(--ease), background .2s var(--ease), border-color .2s var(--ease); }
.btn:hover { background: rgba(217,168,76,.08); border-color: var(--line-3); color: var(--fg); }
.btn-primary { background: var(--grad-btn); color: var(--page); border-color: rgba(255,235,180,.4); box-shadow: inset 0 1px 0 rgba(255,255,255,.35), 0 8px 24px -10px rgba(217,168,76,.6); }
.btn-primary:hover { filter: none; transform: translateY(-1px); color: var(--page); background: var(--grad-btn); box-shadow: inset 0 1px 0 rgba(255,255,255,.4), 0 12px 30px -10px rgba(217,168,76,.75); }
.btn-ghost { background: transparent; border-color: transparent; box-shadow: inset 0 -1px 0 var(--copper); border-radius: 0; color: var(--gold-tx); }
.btn-ghost:hover { background: transparent; border-color: transparent; color: var(--gold-hi); }
.btn-danger { color: var(--danger); border-color: rgba(255,157,136,.45); }
.table .btn-primary.btn-sm { background: rgba(255,255,255,.02); color: var(--fg); border-color: var(--line-2); box-shadow: none; }

/* 12. Chips */
.badge { font-family: var(--mono); font-size: .62rem; font-weight: 500; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); border-color: var(--line-2); padding: .2rem .55rem; }
.badge-gold { color: var(--gold-tx); border-color: var(--line-3); background: rgba(217,168,76,.08); }
.badge-success { color: var(--success); }
.badge-danger { color: var(--danger); }

/* 13. Fields and tables */
input[type=text], input[type=email], input[type=password], input[type=search], input:not([type]), select, textarea { background: var(--surface); border-color: var(--line-3); }
select option { background: #0C1030; color: var(--fg); }
.table th { font-family: var(--mono); font-weight: 500; font-size: .68rem; letter-spacing: .12em; color: var(--subtle); }
.table tbody tr:hover td { background: rgba(217,168,76,.035); }
.site-footer { border-top: 1px solid var(--line); }

/* 14. Course cards (My Learning and the Course catalog) */
.grid-toolbar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .75rem 1rem; margin: -.5rem 0 1.25rem; }
.grid-toolbar p { margin: 0; color: var(--muted); }
.course-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 330px), 1fr)); gap: 1rem; margin: 0; padding: 0; list-style: none; }
.course-card { display: flex; flex-direction: column; gap: .7rem; min-width: 0; height: 100%; background: var(--box); border: 1px solid var(--edge); border-radius: var(--r-lg); padding: 1.4rem 1.4rem 1.25rem; transition: border-color .2s var(--ease), transform .2s var(--ease), background .2s var(--ease); }
.course-card:hover { border-color: var(--line-3); background: rgba(217,168,76,.035); }
.course-card.is-active { background: var(--grad-rec); border-color: var(--line-3); }
.course-card .cc-top { display: flex; justify-content: space-between; align-items: center; gap: .5rem; flex-wrap: wrap; }
.course-card .cc-cat { font-family: var(--mono); font-size: .66rem; font-weight: 500; letter-spacing: .18em; text-transform: uppercase; color: var(--gold-tx); }
.course-card h3 { font-family: var(--serif); font-size: 1.45rem; line-height: 1.2; margin: 0; }
.course-card h3 a { color: var(--fg); text-decoration: none; }
.course-card h3 a:hover { color: var(--gold-hi); }
.course-card .cc-desc { color: var(--muted); font-size: .92rem; margin: 0; flex: 1 0 auto; }
.course-card .cc-facts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1px; margin: .2rem 0 0; border: 1px solid var(--line); border-radius: var(--r); overflow: hidden; }
.course-card .cc-facts > div { padding: .55rem .65rem; box-shadow: 0 0 0 1px var(--line); min-width: 0; }
.course-card .cc-facts dt { font-family: var(--mono); font-size: .6rem; letter-spacing: .14em; text-transform: uppercase; color: var(--subtle); }
.course-card .cc-facts dd { margin: .1rem 0 0; font-family: var(--serif); font-size: 1.15rem; line-height: 1.25; color: var(--gold-hi); overflow-wrap: anywhere; }
.course-card .cc-for { font-size: .82rem; color: var(--subtle); margin: 0; }
.course-card .cc-progress { display: flex; align-items: center; gap: .6rem; font-size: .85rem; color: var(--muted); }
.course-card .cc-progress .pbar { flex: 1 1 auto; width: auto; }
.course-card .cc-progress strong { color: var(--gold-hi); }
.course-card .cc-actions { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; margin-top: .2rem; }
.course-card .cc-actions .btn-ghost { margin-left: auto; padding-left: .2rem; padding-right: .2rem; }
.grid-pager { display: flex; align-items: center; justify-content: flex-end; gap: .6rem; margin-top: 1rem; }
.grid-pager[hidden] { display: none; }
.course-grid > li[hidden] { display: none; }

/* 15. Small screens: no spine, label hidden, single column */
@media (max-width: 860px) {
  .topbar { min-height: 3.75rem; }
  .brand img { height: 34px; }
  .brand-label { display: none; }
  .page-head.spine { padding-left: 0; }
  .page-head.spine::before, .page-head.spine::after { display: none; }
  .card { padding: 1.15rem; }
}
@media (max-width: 640px) {
  .topbar::after { display: none; }
  .topbar { border-bottom: 1px solid var(--line); }
  .kpi .value { font-size: 2rem; }
}
@media (prefers-reduced-motion: reduce) { .btn-primary:hover { transform: none; } }

/* v4.4 gate fixes: long words never widen the page; the filter fits a phone; grids scroll to their top */
.page-head h1, .course-card .cc-cat, .course-card h3 { overflow-wrap: anywhere; }
.inline-filter select { max-width: 100%; }
.course-grid { scroll-margin-top: calc(var(--topbar-h) + 1rem); }

/* v4.5: public home and card details */
.kpi-row { margin-bottom: 1.75rem; }
.course-card .cc-for-label { color: var(--muted); font-weight: 600; }

/* ---------- v4.8: restricted courses and the scored exam ---------- */
.badge-lock { color: var(--gold-tx); border-color: var(--line-3, var(--edge)); background: rgba(217,168,76,.06); }
.badge-lock::before { content: ""; display: inline-block; width: .5rem; height: .45rem; margin-right: .35rem; border: 1.5px solid currentColor; border-radius: 1px; vertical-align: -.02rem; }
.cc-restricted { font-size: .82rem; color: var(--gold-tx); margin: .35rem 0 .2rem; }
.restricted-note p:last-child { margin-bottom: 0; }
.exam-card .exam-facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); gap: .5rem 1rem; margin: 0 0 .5rem; }
.exam-card .exam-facts dt { font-size: .7rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.exam-card .exam-facts dd { margin: 0; color: var(--fg); }
.exam-row { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: .5rem 1rem; }
.exam-row p { margin: 0; flex: 1 1 18rem; }
.exam-row .actions { margin-top: 0; }
.exam-verdict.is-pass { color: var(--success); }
.exam-verdict.is-fail { color: var(--danger); }

.exam-bar { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: .75rem 1.5rem; position: sticky; top: calc(var(--topbar-h) + .5rem); z-index: 20; background: var(--page); }
.exam-bar h1 { font-size: clamp(1.2rem, 2.4vw, 1.6rem); margin: 0; }
.exam-status { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem 1.5rem; }
.exam-status .label { display: block; font-size: .68rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.exam-timer strong, .exam-count strong { font-family: var(--mono); font-size: 1.25rem; color: var(--gold-hi); font-variant-numeric: tabular-nums; }
.exam-timer.is-low strong { color: var(--danger); }
.exam-saved { font-size: .82rem; color: var(--muted); min-width: 10rem; }
.exam-saved.is-bad { color: var(--danger); }
.exam-layout { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 18rem); gap: 1rem; align-items: start; }
.exam-nav { position: sticky; top: calc(var(--topbar-h) + 7rem); max-height: calc(100vh - var(--topbar-h) - 8rem); overflow: auto; }
.exam-nav h2 { font-size: 1rem; margin: 0 0 .3rem; }
.exam-legend { display: flex; align-items: center; gap: .35rem; flex-wrap: wrap; margin: 0 0 .6rem; }
.dot { display: inline-block; width: .7rem; height: .7rem; border-radius: 2px; border: 1px solid var(--line-2); }
.dot-answered { background: var(--gold); border-color: var(--gold); }
.dot-flagged { border: 2px solid var(--danger); }
.exam-grid { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(8, minmax(0, 1fr)); gap: .25rem; }
.exam-grid li a.ex-cell { text-decoration: none; }
.ex-cell { display: grid; place-items: center; min-height: 1.9rem; border-radius: var(--r); border: 1px solid var(--line-2); color: var(--fg); font: 600 .82rem var(--mono); text-decoration: none; }
.ex-cell:hover { border-color: var(--gold); text-decoration: none; }
.ex-cell.is-answered { background: rgba(217,168,76,.22); border-color: var(--gold); color: var(--gold-hi); }
.ex-cell.is-flagged { box-shadow: inset 0 0 0 2px var(--danger); }
.ex-cell.is-current { outline: 2px solid var(--gold-hi); outline-offset: 1px; }
.exam-q-head { display: flex; justify-content: space-between; align-items: baseline; gap: .5rem 1rem; flex-wrap: wrap; margin-bottom: .6rem; }
.exam-q-head h2 { font-size: 1.05rem; margin: 0; }
.exam-q-head h2:focus { outline: none; }
.exam-flag { display: inline-flex; align-items: center; gap: .4rem; font-size: .88rem; color: var(--muted); cursor: pointer; }
.exam-scenario .kicker { display: flex; margin-bottom: .3rem; }
.exam-scenario-text { margin: 0; }
.exam-scenario { border-left: 3px solid var(--gold); background: rgba(217,168,76,.06); padding: .7rem .9rem; border-radius: 0 var(--r) var(--r) 0; margin-bottom: .8rem; line-height: 1.55; }
.exam-options { border: 0; margin: 0; padding: 0; min-width: 0; }
.exam-stem { font-size: 1.02rem; line-height: 1.55; color: var(--fg); margin-bottom: .75rem; padding: 0; }
.exam-hint { display: block; margin-top: .35rem; font-size: .85rem; font-weight: 700; color: var(--gold-tx); }
.exam-opt { display: grid; grid-template-columns: auto auto 1fr; align-items: start; gap: .6rem; padding: .65rem .75rem; margin-bottom: .45rem; border: 1px solid var(--line-2); border-radius: var(--r); cursor: pointer; line-height: 1.45; }
.exam-opt:hover { border-color: var(--gold); }
.exam-opt input { margin-top: .2rem; width: 1.05rem; height: 1.05rem; accent-color: var(--gold); }
.exam-opt:has(input:checked) { border-color: var(--gold); background: rgba(217,168,76,.10); }
.exam-opt:has(input:focus-visible) { outline: 2px solid var(--gold-hi); outline-offset: 2px; }
.exam-letter { font: 700 .82rem var(--mono); color: var(--gold-tx); margin-top: .1rem; }
.exam-clear { margin-top: .25rem; }
.exam-controls { display: flex; flex-wrap: wrap; gap: .5rem; margin: 0 0 1rem; }
.exam:not(.exam-js) #ex-prev, .exam:not(.exam-js) #ex-next, .exam:not(.exam-js) .exam-clear { display: none; }
.exam-js .exam-q[hidden], .exam-review[hidden] { display: none; }
.exam-review:focus { outline: 2px solid var(--gold-hi); outline-offset: 2px; }
.exam:not(.exam-js) .exam-nav { position: static; max-height: none; }
@media (max-width: 900px) {
  .exam-layout { grid-template-columns: minmax(0, 1fr); }
  .exam-nav { position: static; max-height: none; }
  .exam-grid { grid-template-columns: repeat(auto-fill, minmax(2.4rem, 1fr)); }
  .exam-bar { top: calc(var(--topbar-h) + .25rem); }
}
@media (max-width: 520px) {
  .exam-status { gap: .4rem 1rem; }
  .exam-saved { min-width: 0; flex-basis: 100%; }
}
/* v4.8 gate F3: at phone width the top bar scrolls away (position: static), so the exam bar sticks to the
   very top with no gap, and is compact: the title stays for screen readers, the timer and count share one row. */
@media (max-width: 640px) {
  .exam-bar { top: 0; padding: .45rem .8rem; gap: .15rem .75rem; }
  .exam-bar .exam-title { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; border: 0; }
  .exam-status { width: 100%; justify-content: space-between; gap: .1rem .75rem; }
  .exam-status .label { display: inline; margin-right: .35rem; }
  .exam-timer strong, .exam-count strong { font-size: 1.05rem; }
  .exam-saved { flex-basis: 100%; font-size: .74rem; line-height: 1.3; }
}
