/* Quiet clinical theme for every signed-in page (Claude, 17 October 2026).
   Matches the public homepage: warm ivory page, warm-white cards, navy Georgia headings, emerald actions, gold focus.
   Loaded last so it re-points shared tokens; activity accents (practise blue, learn amber, AI violet,
   progress rose) are unchanged because the homepage uses them too. */
:root{
 --qc-ivory:#faf7f0;--qc-ivory-deep:#f3ede1;--qc-card:#fffdf8;--qc-navy:#102d50;--qc-ink:#1f3540;--qc-muted:#5b6b66;
 --qc-line:#e7e1d4;--qc-line-strong:#d5ccb9;--qc-emerald:#065f46;--qc-emerald-deep:#054c39;--qc-teal-ink:#176b5c;--qc-gold:#af8541;
 --qc-serif:Georgia,"Times New Roman",serif;
 --bg:var(--qc-ivory);--surface:var(--qc-card);--paper:var(--qc-card);--surface-2:#f6f1e7;--panel-strong:#ede6d8;
 --ink:var(--qc-ink);--muted:var(--qc-muted);--line:var(--qc-line);--line-strong:var(--qc-line-strong);
 --teal:var(--qc-emerald);--teal-strong:var(--qc-emerald-deep);--accent:#e7f1ea;--tint:#f5f0e6;--tint-strong:#ebe3d3;
 --focus:var(--qc-gold);--warm:#f8f1e2;
 --shadow:0 18px 40px -24px #3a2f1a33;--shadow-soft:0 6px 18px -12px #3a2f1a2e;
}
html,body{background:var(--qc-ivory)}
body{background:radial-gradient(1100px 520px at 88% -10%,#f1ebdd,transparent 60%),var(--qc-ivory)!important;color:var(--qc-ink)}
/* Header: warm white like the homepage's solid header. */
#app-shell .top,.top,.account-page .account-header,body>header{background:color-mix(in srgb,var(--qc-card) 92%,transparent)!important;border-bottom-color:var(--qc-line)!important}
/* Sidebar: soft ivory instead of mint. */
.sidebar,#app-shell .sidebar{background:var(--qc-ivory-deep)!important;border-color:var(--qc-line)!important}
/* Page titles: navy serif, as in the homepage hero. */
#main .intro h1,#main>h1,.dash-head h1,.account-page .account-heading h1,main .hero h1,.privacy h1,main>h1{color:var(--qc-navy)!important;font-family:var(--qc-serif)!important;font-weight:500!important;letter-spacing:-.045em!important}
/* Section and card headings: navy serif at card size. */
.dash-tile h2,.account-page .account-card h2,#main .card>h2,#main .intro h2,.zys-help-head h2,main section>h2{color:var(--qc-navy)!important;font-family:var(--qc-serif)!important;font-weight:600!important;letter-spacing:-.025em!important}
/* Eyebrows: the homepage's deep green, small caps. */
.eyebrow,.dash-eyebrow,.account-page .account-heading .eyebrow{color:var(--qc-teal-ink)!important}
/* Cards and tiles: warm white with a warm hairline. */
.card,.dash-tile,.account-page .account-card,.zys-help-panel,#account-popover,.dash-exams{background-color:var(--qc-card)!important;border-color:var(--qc-line)!important}
.dash-example{background:repeating-linear-gradient(135deg,var(--qc-card) 0 14px,#f7f2e8 14px 28px)!important;border-color:var(--qc-line-strong)!important}
.zys-dash{--dash-ink:var(--qc-ink);--dash-muted:var(--qc-muted);--dash-line:var(--qc-line);--dash-grey:#f1ece2}
.dash-upsell{border-color:var(--qc-line-strong)!important}
/* Primary actions: emerald, as the homepage's Get started. Secondary: emerald outline on warm white. */
.btn.primary,.dash-tile .btn.primary,.account-page .btn.primary,.zys-help-send,.zys-help-button,.dash-exams button[aria-pressed="true"]{background:var(--qc-emerald)!important;border-color:var(--qc-emerald)!important;color:#fff!important}
.btn.primary:hover,.zys-help-button:hover{background:var(--qc-emerald-deep)!important}
.btn:not(.primary):not(.text){background:var(--qc-card);border-color:var(--qc-line-strong);color:var(--qc-emerald)}
/* Account menu trigger and plan badges pick up the warm surfaces. */
#account-trigger,.account-page .account-menu>summary{background:var(--qc-card)!important;border-color:var(--qc-line-strong)!important}
.account-initials,.account-page .account-badge:not(.waiting){background:var(--qc-emerald)!important;color:#fff!important}
/* Footer bar. */
.footer,.zys-footer-bar,.account-page .account-footer{background:transparent!important;border-top:1px solid var(--qc-line)!important;color:var(--qc-muted)}
/* Gold focus ring, as on the homepage. */
a:focus-visible,button:focus-visible,summary:focus-visible,select:focus-visible,input:focus-visible,textarea:focus-visible,[tabindex]:focus-visible{outline:3px solid var(--qc-gold)!important;outline-offset:3px}
/* Plans, demo and privacy pages: headings and links in the homepage colours. */
main h2,.access-card h3,main .sample h2{color:var(--qc-navy);font-family:var(--qc-serif);font-weight:600;letter-spacing:-.025em}
#main h2{font-family:inherit}
#main .card>h2,#main .intro h2{font-family:var(--qc-serif)}
main p a,main li a{color:var(--qc-emerald)}
.access-card{background:var(--qc-card)!important;border-color:var(--qc-line)!important}
main>a:first-child{color:var(--qc-emerald)}

/* Simpler design, phase 1 (Claude, 22 October 2026, owner-approved).
   Focus mode: while a question is on screen, menus, notices and side links step back. */
#app-shell[data-focus="question"] .top,
#app-shell[data-focus="question"] .sidebar,
#app-shell[data-focus="question"] .footer,
#app-shell[data-focus="question"] .beta-notice,
#app-shell[data-focus="question"] .draft-notice,
#app-shell[data-focus="question"] .more-ways,
#app-shell[data-focus="question"] .panel-actions,
#app-shell[data-focus="question"] .qf-entry,
#app-shell[data-focus="question"] #main>.intro,
#app-shell[data-focus="question"] .written-guides{display:none!important}
/* A save problem always stays visible, with its Retry button; a successful save steps back. */
#app-shell[data-focus="question"] .progress-save-indicator:not(:has(#progress-save-retry:not([hidden]))){display:none}
#app-shell[data-focus="question"]{padding-top:0!important}
#app-shell[data-focus="question"] .layout{display:block!important;min-height:0;margin-top:0!important;padding-top:0!important}
#app-shell[data-focus="question"] #main{max-width:780px;margin:0 auto;padding:0 20px 32px}
#app-shell[data-focus="question"] .question-workspace{display:block}
#app-shell[data-focus="question"] .question-content .eyebrow{margin-top:14px}
.focus-bar{position:sticky;top:0;z-index:30;display:grid;grid-template-columns:1fr auto 1fr;align-items:center;gap:8px;margin:0 -20px;padding:8px 12px;background:var(--qc-card);border-bottom:1px solid var(--qc-line)}
.focus-bar .focus-exit{justify-self:start;min-height:44px;padding:0 10px;color:var(--qc-ink);font-weight:600}
.focus-bar .focus-finish{justify-self:end;min-height:44px;padding:0 10px;color:var(--qc-emerald);font-weight:700}
.focus-count{font-weight:700;color:var(--qc-navy);font-size:15px;white-space:nowrap}
.focus-progress{height:6px;margin:0 -20px;background:var(--panel-strong);overflow:hidden}
.focus-progress span{display:block;height:100%;background:var(--qc-emerald);transition:width .25s}
#app-shell[data-focus="question"] .option{min-height:56px}
@media (max-width:700px){
 #app-shell[data-focus="question"] #main{padding:0 16px 24px}
 .focus-bar,.focus-progress{margin-left:-16px;margin-right:-16px}
 /* Previous/Next are always pinned to the bottom; until the answer is checked, "Check answer" is
    pinned just above them. Nothing covers either bar, and scrolled content stops above them. */
 #app-shell[data-focus="question"] .question-nav{position:sticky;bottom:0;z-index:21;margin:16px -16px 0;min-height:64px;box-sizing:border-box;padding:10px 16px calc(10px + env(safe-area-inset-bottom));background:var(--qc-card);border-top:1px solid var(--qc-line);align-items:center}
 #app-shell[data-focus="question"] .session-actions{position:sticky;bottom:calc(64px + env(safe-area-inset-bottom));z-index:20;margin:16px -16px 0;padding:10px 16px;background:var(--qc-card);border-top:1px solid var(--qc-line)}
 #app-shell[data-focus="question"] .session-actions .btn.primary{width:100%;min-height:52px;font-size:17px}
 html:has(#app-shell[data-focus="question"]){scroll-padding-bottom:150px}
 /* Floating help and chat buttons sit above both pinned bars instead of covering them. */
 /* While the help panel is open it returns to its usual place, so the panel fits short screens. */
 body:has(#app-shell[data-focus="question"]) .zys-help:not(:has(.zys-help-panel:not([hidden]))),
 body:has(#app-shell[data-focus="question"]) .chat-launch{bottom:150px!important}
}
@media (prefers-reduced-motion:reduce){.focus-progress span{transition:none}}

/* Practice start page: one quick-start card; everything else under "More options". */
.written-start{display:flex;flex-direction:column;gap:18px;max-width:780px}
.written-start-head h1{margin:6px 0 6px}
.written-start-head p{margin:0;color:var(--qc-muted)}
.quick-start{display:flex;flex-direction:column;gap:14px}
.quick-start h2{margin:0}
.quick-count{border:0;margin:0;padding:0}
.quick-count legend{padding:0;margin-bottom:8px;font-size:14px;color:var(--qc-muted)}
.quick-count-options{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px}
.quick-chip{min-height:48px;border-radius:12px;border:1px solid var(--qc-line-strong);background:var(--qc-card);color:var(--qc-ink);font:inherit;font-size:16px;font-weight:600;cursor:pointer}
.quick-chip[aria-pressed="true"]{border:2px solid var(--qc-emerald);background:var(--accent);color:var(--qc-emerald);font-weight:700}
.quick-topic{display:flex;flex-direction:column;gap:6px;font-size:14px;color:var(--qc-muted)}
.quick-topic select{min-height:48px;border-radius:12px;border:1px solid var(--qc-line-strong);background:var(--qc-card);padding:0 12px;font-size:16px;color:var(--qc-ink)}
.quick-start .quick-begin{min-height:52px;font-size:17px;width:100%}
.written-more>summary{min-height:44px;display:flex;align-items:center;cursor:pointer;font-weight:700;color:var(--qc-emerald)}
.written-more .card{border:0;padding:0;margin:12px 0 0;background:transparent;box-shadow:none}
.written-more .written-session-controls{margin-top:8px}
.more-ways{margin-top:24px}
.more-ways h2{font-size:19px;margin:0 0 10px}
.more-ways-list{display:flex;flex-wrap:wrap;gap:10px}
.more-ways-list .panel-actions,.more-ways-list .qf-entry{margin:0}
.focus-bar .btn,.focus-bar #written-finish{margin:0;align-self:center}
.written-more{padding-top:10px!important;padding-bottom:10px!important}
.written-more[open]{padding-bottom:20px!important}

/* Simpler design, phase 2a (Claude, 22 October 2026, owner-approved): five destinations everywhere. */
.app-tabs{display:none}
.primary-nav{display:flex;flex-direction:column;gap:4px;margin-bottom:14px}
.primary-item{display:flex;align-items:center;gap:12px;width:100%;min-height:44px;padding:0 12px;border:0;border-radius:10px;background:transparent;color:var(--qc-ink);font:inherit;font-size:15px;text-align:left;cursor:pointer}
.primary-item:hover{background:var(--tint)}
.primary-item.active{background:var(--accent);color:var(--qc-emerald);font-weight:700}
.primary-item svg{flex:none;color:var(--qc-muted)}
.primary-item.active svg{color:var(--qc-emerald)}
.nav-all{border-top:1px solid var(--qc-line);padding-top:10px}
.nav-all>summary{min-height:40px;display:flex;align-items:center;padding:0 12px;cursor:pointer;font-size:13px;font-weight:700;color:var(--qc-muted);letter-spacing:.02em}
.nav-all[open]>summary{margin-bottom:6px}
/* Exam switcher in the top bar. */
.exam-switcher>summary{display:flex;align-items:center;gap:6px;font-weight:700;color:var(--qc-navy)}
.exam-switcher nav a[aria-current="true"]{font-weight:700;color:var(--qc-emerald)}
.exam-switcher .exam-switch-add{border-top:1px solid var(--qc-line);margin-top:4px;padding-top:10px;color:var(--qc-emerald);font-weight:600}
/* Home card. */
.home-hero{background:var(--qc-card);border:1px solid var(--qc-line);border-radius:16px;padding:20px;margin:0 0 18px;display:flex;flex-direction:column;gap:12px}
.home-hero h2{margin:0;font-family:var(--qc-serif);font-size:24px;color:var(--qc-navy)}
.home-hero-progress{display:flex;justify-content:space-between;gap:12px;font-size:14px;color:var(--qc-muted)}
.home-hero-exam{font-weight:700;letter-spacing:.06em;text-transform:uppercase;font-size:12px;color:var(--qc-teal-ink)}
.home-hero-bar{height:8px;border-radius:4px;background:var(--panel-strong);overflow:hidden}
.home-hero-bar span{display:block;height:100%;background:var(--qc-emerald)}
.home-hero-actions{display:flex;flex-wrap:wrap;gap:10px}
.home-hero-actions .btn{min-height:52px;font-size:16px;padding:0 22px}
.home-hero-actions .home-start{flex:1 1 220px}
.home-hero-actions .home-listen{flex:1 1 220px}
/* More page. */
.more-page{max-width:640px;display:flex;flex-direction:column;gap:22px}
.more-page h1{margin:0}
.more-page h2{margin:0 0 8px;font-family:inherit!important;font-size:13px;font-weight:700;letter-spacing:.08em;text-transform:uppercase;color:var(--qc-muted)}
.more-list{display:flex;flex-direction:column;background:var(--qc-card);border:1px solid var(--qc-line);border-radius:14px;overflow:hidden}
.more-row{display:flex;align-items:center;justify-content:space-between;gap:12px;min-height:52px;padding:8px 16px;border:0;border-bottom:1px solid var(--qc-line);background:transparent;color:var(--qc-navy);font:inherit;font-weight:600;text-align:left;text-decoration:none;cursor:pointer}
.more-row:last-child{border-bottom:0}
.more-row:hover{background:var(--tint)}
.more-row-text{display:flex;flex-direction:column;gap:2px}
.more-row-text small{font-weight:400;color:var(--qc-muted)}
.more-row.is-current{box-shadow:inset 4px 0 0 var(--qc-emerald)}
.more-current{font-size:13px;color:var(--qc-emerald)}
.more-add{color:var(--qc-emerald)}
.more-signout{color:var(--danger)}
@media (max-width:800px){
 /* Phones and small tablets: bottom tabs replace the menu button, the breadcrumb and the PACES bar. */
 .app-tabs{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));position:fixed;left:0;right:0;bottom:0;z-index:40;padding:4px 4px calc(6px + env(safe-area-inset-bottom));background:var(--qc-card);border-top:1px solid var(--qc-line)}
 .app-tab{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:3px;min-height:52px;border:0;background:transparent;color:var(--qc-muted);font:inherit;font-size:12px;cursor:pointer}
 .app-tab.active{color:var(--qc-emerald);font-weight:700}
 #app-shell .mobile-menu,#app-shell .paces-bar{display:none!important}
 #app-shell:not([data-focus="question"]) #main{padding-bottom:96px}
 #app-shell[data-focus="question"] .app-tabs{display:none}
 body:has(#app-shell:not([data-focus="question"])) .zys-help:not(:has(.zys-help-panel:not([hidden]))),
 body:has(#app-shell:not([data-focus="question"])) .chat-launch{bottom:calc(76px + env(safe-area-inset-bottom))!important}
}
.home-hero{text-align:left;align-items:stretch}
.home-hero h2,.home-hero-progress{width:100%}
.home-hero-actions .btn{justify-content:center}
/* On Home the card already names the exam and area; the strip that repeated it steps back. */
.zys-dash:has(.home-hero) .atlas-preview{display:none}
.more-list>p{margin:0;padding:14px 16px}

/* Progress dashboard (simpler design phase 2b, Claude, 22 October 2026). Light theme only, as the site. */
.zys-progress{display:grid;gap:14px;max-width:880px;margin:0 auto 18px}
.zys-progress .pg-head h1{margin:2px 0 0;font-family:var(--qc-serif);font-size:1.6rem}
.zys-progress .pg-tile,.zys-progress .pg-next{background:var(--surface);border:1px solid var(--line);border-radius:14px;padding:16px}
.zys-progress h2,.zys-progress h3{margin:0 0 6px;font-size:1.05rem}
.zys-progress .pg-next{background:var(--accent);border-color:#cfe3d5}
.zys-progress .pg-next p{margin:4px 0 12px;font-size:1.02rem}
.zys-progress .pg-muted{color:var(--muted);font-size:.9rem;margin:4px 0}
.zys-progress .pg-caveat{color:var(--muted);font-size:.88rem;font-style:italic;margin:6px 0 0}
.zys-progress .pg-tile-head{display:flex;justify-content:space-between;align-items:baseline;gap:10px}
.zys-progress .pg-change{color:var(--qc-teal-ink);white-space:nowrap}
.zys-progress .pg-chart{display:block;width:100%;height:auto;max-height:240px;margin:8px 0 4px}
.zys-progress .pg-grid{stroke:var(--line);stroke-width:1}
.zys-progress .pg-axis{fill:var(--muted);font-size:10px}
.zys-progress .pg-ref{stroke:var(--muted);stroke-width:1.5;stroke-dasharray:4 4}
.zys-progress .pg-line{fill:none;stroke:var(--qc-emerald);stroke-width:2;stroke-linejoin:round;stroke-linecap:round}
.zys-progress .pg-dot{fill:var(--qc-emerald);stroke:var(--surface);stroke-width:2}
.zys-progress .pg-dot.pg-thin{fill:var(--surface);stroke:var(--qc-emerald);stroke-width:2}
.zys-progress .pg-legend{display:flex;flex-wrap:wrap;align-items:center;gap:6px 10px;margin:4px 0 0;font-size:.92rem}
.zys-progress .pg-key{display:inline-block;width:18px;height:0;border-top:2px solid var(--qc-emerald);vertical-align:middle}
.zys-progress .pg-key-all{border-top:2px dashed var(--muted);margin-left:8px}
.zys-progress .pg-scale{display:flex;align-items:center;gap:4px;font-size:.85rem;color:var(--muted);margin:6px 0}
.zys-progress .pg-scale i{display:inline-block;width:22px;height:12px;border-radius:3px}
.zys-progress .pg-heat{list-style:none;margin:10px 0;padding:0;display:grid;grid-template-columns:repeat(auto-fill,minmax(98px,1fr));gap:6px}
.zys-progress .pg-square{aspect-ratio:1/1;width:100%;box-sizing:border-box;border:1px solid var(--line-strong);border-radius:10px;padding:7px;display:flex;flex-direction:column;justify-content:space-between;align-items:flex-start;text-align:left;font:inherit;background:var(--dash-grey);color:var(--ink);cursor:pointer;min-height:0}
.zys-progress .pg-square[disabled]{cursor:default}
.zys-progress .pg-square.pg-banded{border-color:transparent}
.zys-progress .pg-square.pg-low{background:var(--qc-ivory);border:2px dotted #b9ae96;color:var(--muted)}
.zys-progress .pg-square:focus-visible{outline:3px solid var(--focus);outline-offset:2px}
.zys-progress .pg-sq-name{font-size:.78rem;font-weight:600;line-height:1.15;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}
.zys-progress .pg-sq-value{font-size:1.25rem;font-weight:700;line-height:1}
.zys-progress .pg-sq-band{font-size:.72rem;line-height:1.1}
.zys-progress .pg-sq-cov{display:block;width:100%;height:4px;border-radius:2px;background:rgba(0,0,0,.12);overflow:hidden}
.zys-progress .pg-banded .pg-sq-cov{background:rgba(255,255,255,.3)}
.zys-progress .pg-sq-cov i{display:block;height:100%;background:currentColor}
.zys-progress .pg-tiles{display:grid;grid-template-columns:repeat(auto-fit,minmax(170px,1fr));gap:14px}
.zys-progress .pg-big{font-size:1.7rem;font-weight:700;margin:2px 0;color:var(--qc-navy)}
.zys-progress .pg-bar{height:8px;border-radius:4px;background:var(--dash-grey);overflow:hidden;margin-top:6px}
.zys-progress .pg-bar i{display:block;height:100%;background:var(--qc-emerald)}
.zys-progress .pg-edit{margin-top:10px}
.zys-progress .pg-edit summary{cursor:pointer;color:var(--qc-teal-ink);font-weight:600}
.zys-progress .pg-edit form{display:grid;gap:10px;margin-top:10px;max-width:360px}
.zys-progress .pg-edit label{display:grid;gap:4px;font-size:.92rem}
.zys-progress .pg-edit input{font:inherit;padding:8px;border:1px solid var(--line-strong);border-radius:8px;background:#fff}
.zys-progress .pg-switch{display:flex;gap:10px;align-items:flex-start;cursor:pointer}
.zys-progress .pg-switch input{margin-top:4px;width:18px;height:18px;accent-color:var(--qc-emerald)}
.zys-progress .pg-context{background:var(--warm)}
.progress-detail{max-width:880px;margin:8px auto 0}
.progress-detail>summary{cursor:pointer;font-weight:600;color:var(--qc-teal-ink);padding:10px 0}
@media (max-width:420px){.zys-progress .pg-heat{grid-template-columns:repeat(3,1fr)}.zys-progress .pg-sq-value{font-size:1.1rem}}
.zys-progress h2{font-family:var(--qc-serif);font-weight:700;color:var(--qc-navy)}
.zys-progress h3{font-family:inherit;font-weight:700;color:var(--ink)}
.zys-progress .pg-change.pg-down{color:var(--ink)}
.zys-progress .pg-tile-head h2{font-family:var(--qc-serif);margin:0}
