/* Dashboard-only presentation. Shared header and the challenge editor are untouched. */
#dashboardView{--dash-font:'Inter',sans-serif;--dash-panel:var(--panel);--dash-text:var(--text);--dash-muted:#b1c0b8;--dash-border:#3b4b42;--dash-soft:#17251f;--dash-accent:var(--mint);--dash-button:#286344;--dash-green-bg:#233f2e;--dash-green:#a4efbb;--dash-blue-bg:#253a58;--dash-blue:#c4daff;--dash-orange-bg:#45331d;--dash-orange:#ffcf8d;--dash-red-bg:#492b2b;--dash-red:#ffd1cd;width:100%;max-width:1200px;margin-inline:auto;padding:0 0 48px;min-height:650px;font-family:var(--dash-font);font-size:16px;line-height:1.5;color:var(--dash-text)}
:root[data-theme=light] #dashboardView{--dash-panel:#fff;--dash-text:#10181A;--dash-muted:#4A5558;--dash-border:#E3E7E4;--dash-soft:#F8FAF9;--dash-accent:#0B7A3B;--dash-button:#0B7A3B;--dash-green-bg:#E3F1E8;--dash-green:#075C2C;--dash-blue-bg:#E5ECFD;--dash-blue:#25498D;--dash-orange-bg:#FDEBD3;--dash-orange:#7A4306;--dash-red-bg:#FBE4E2;--dash-red:#8C1D18}
#dashboardView :is(h1,h2,h3,button,input){font-family:var(--dash-font)}
#dashboardView>.eyebrow{font-size:12px;font-weight:700;letter-spacing:.09em;color:var(--dash-accent);line-height:1.5}
#dashboardView .dashboard-heading{display:flex;align-items:flex-end;justify-content:space-between;gap:24px;margin:4px 0 28px}
#dashboardView #dashboardTitle{margin:0 0 8px;font-size:36px;font-weight:700;letter-spacing:-.035em;line-height:1.2;color:var(--dash-text)}
#dashboardView #dashboardTitle>span{color:var(--dash-accent)}
#dashboardView #dashboardIntro{font-size:16px;line-height:1.6;margin:0;color:var(--dash-muted)}
#dashboardView #dashboardProfile{display:inline-flex;align-items:center;justify-content:center;min-height:44px;padding:10px 18px;flex-shrink:0;background:var(--dash-panel);border:1px solid var(--dash-border);border-radius:8px;font-size:14px;font-weight:600;line-height:1.5;color:var(--dash-text)}
#dashboardView .dashboard-summary{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:16px;margin:0 0 28px}
#dashboardView .dashboard-summary>div{padding:20px 24px;border:1px solid var(--dash-border);border-radius:14px;background:var(--dash-panel);min-width:0;min-height:144px}
#dashboardView .dashboard-summary span,#dashboardView .dashboard-summary small{display:block;font-size:14px;line-height:1.5;font-weight:400;color:var(--dash-muted);margin:0}
#dashboardView .dashboard-summary strong{display:block;font-size:34px;font-weight:700;line-height:1.25;letter-spacing:-.035em;color:var(--dash-text);margin:2px 0}
#dashboardView .dashboard-summary progress{appearance:none;display:block;width:100%;height:8px;margin:6px 0;border:0;border-radius:999px;overflow:hidden;background:var(--dash-border);color:var(--dash-accent)}
#dashboardView progress::-webkit-progress-bar{background:var(--dash-border);border-radius:999px}
#dashboardView progress::-webkit-progress-value{background:var(--dash-accent);border-radius:999px}
#dashboardView progress::-moz-progress-bar{background:var(--dash-accent);border-radius:999px}
#dashboardView .catalog-tools{display:flex;align-items:center;gap:16px;flex-wrap:wrap;margin:0 0 28px}
#dashboardView .catalog-tools .dashboard-search{display:block;position:relative;flex:1 1 300px;min-width:0;margin:0}
#dashboardView .dashboard-search svg{position:absolute;left:14px;top:15px;width:18px;height:18px;stroke:var(--dash-muted);stroke-width:1.8;fill:none;pointer-events:none}
#dashboardView #dashboardSearch{width:100%;height:48px;margin:0;padding:10px 14px 10px 42px;border:1px solid var(--dash-border);border-radius:9px;background:var(--dash-panel);font-size:16px;line-height:1.5;color:var(--dash-text)}
#dashboardView .dashboard-filters{display:flex;align-items:center;gap:8px;flex-wrap:wrap}
#dashboardView .dashboard-filters button{min-height:40px;min-width:44px;padding:8px 16px;border:1px solid var(--dash-border);border-radius:999px;font-size:14px;font-weight:600;background:var(--dash-panel);color:var(--dash-muted)}
#dashboardView .dashboard-filters button[aria-pressed=true]{background:var(--dash-button);color:#fff;border-color:var(--dash-button)}
#dashboardView #catalogCount{padding:0;font-size:14px;font-weight:600;white-space:nowrap;color:var(--dash-accent)}
#dashboardView #problemCatalog{display:flex;flex-direction:column;gap:14px}
#dashboardView .problem-section{margin:0;padding:20px 24px;border:1px solid var(--dash-border);border-radius:14px;background:var(--dash-panel)}
#dashboardView .problem-section.is-expanded{padding:24px;margin-bottom:14px}
#dashboardView .dashboard-section-heading{display:flex;align-items:center;justify-content:space-between;gap:24px;margin:0}
#dashboardView .problem-summary-copy{flex:1;min-width:0}
#dashboardView .tags{display:flex;align-items:center;gap:8px;flex-wrap:wrap;margin:0 0 8px}
#dashboardView .tag{font-size:12px;line-height:1.5;font-weight:600;letter-spacing:0;border:0;border-radius:999px;padding:3px 10px;color:var(--dash-green);background:var(--dash-green-bg)}
#dashboardView .tag.topic{background:var(--dash-blue-bg);color:var(--dash-blue)}
#dashboardView .tag[data-difficulty=Intermediate]{background:var(--dash-orange-bg);color:var(--dash-orange)}
#dashboardView .tag[data-difficulty=Advanced]{background:var(--dash-red-bg);color:var(--dash-red)}
#dashboardView .dashboard-section-heading h2{font-size:22px;font-weight:700;letter-spacing:-.025em;line-height:1.3;margin:0 0 4px;color:var(--dash-text)}
#dashboardView .dashboard-section-heading h2>span{color:var(--dash-accent)}
#dashboardView .problem-section:not(.is-expanded) h2>span{display:none}
#dashboardView .is-expanded .dashboard-section-heading h2{font-size:26px}
#dashboardView .dashboard-section-heading p{font-size:16px;line-height:1.5;color:var(--dash-muted);margin:0}
#dashboardView .problem-heading-actions{display:flex;align-items:center;justify-content:flex-end;gap:14px;margin:0;flex-shrink:0;flex-wrap:wrap}
#dashboardView .problem-heading-actions small{font-size:14px;color:var(--dash-muted);line-height:1.5}
#dashboardView :is(.dashboard-quick-start,.share-challenge-button,.dashboard-expand){min-height:42px;padding:9px 16px;background:var(--dash-panel);border:1px solid var(--dash-border);border-radius:8px;color:var(--dash-text);font-size:14px;font-weight:600;line-height:1.5}
#dashboardView .dashboard-quick-start{border-color:var(--dash-accent);color:var(--dash-accent)}
#dashboardView .dashboard-expand{display:grid;place-items:center;width:42px;padding:9px}
#dashboardView .dashboard-expand svg{width:18px;height:18px;stroke:currentColor;stroke-width:2;fill:none;transition:transform .15s}
#dashboardView .dashboard-expand[aria-expanded=true] svg{transform:rotate(180deg)}
#dashboardView .problem-section.is-expanded .dashboard-section-heading{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:8px 24px;align-items:start;margin-bottom:22px}
#dashboardView .is-expanded .problem-summary-copy{display:contents}
#dashboardView .is-expanded .problem-summary-copy>.tags{grid-column:1;grid-row:1;margin:0;align-self:center}
#dashboardView .is-expanded .problem-summary-copy>h2{grid-column:1/-1;grid-row:2}
#dashboardView .is-expanded .problem-summary-copy>p{grid-column:1/-1;grid-row:3}
#dashboardView .is-expanded .problem-heading-actions{grid-column:2;grid-row:1}
#dashboardView .problem-section.is-expanded .problem-heading-actions{padding-top:0}
#dashboardView .dashboard-tasks{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:16px}
#dashboardView .dashboard-task{min-width:0;display:flex;flex-direction:column;align-items:stretch;padding:20px;border:1px solid var(--dash-border);border-radius:12px;background:var(--dash-soft)}
#dashboardView .dashboard-task.is-next{border:2px solid var(--dash-accent);padding:19px;background:var(--dash-panel)}
#dashboardView .dashboard-task.completed{border-color:var(--dash-accent);background:var(--dash-panel)}
#dashboardView .round-card-heading{display:flex;align-items:center;justify-content:space-between;gap:8px;flex-wrap:wrap;margin-bottom:12px}
#dashboardView .task-round{font-size:12px;line-height:1.5;font-weight:700;letter-spacing:.06em;color:var(--dash-muted)}
#dashboardView .task-status{display:inline-flex;align-items:center;gap:4px;align-self:flex-start;font-size:12px;line-height:1.5;font-weight:600;letter-spacing:0;padding:2px 10px;border:0;border-radius:999px;background:var(--dash-border);color:var(--dash-muted);margin:0}
#dashboardView .task-status[data-status=ready],#dashboardView .task-status[data-status=completed]{background:var(--dash-green-bg);color:var(--dash-green)}
#dashboardView .dashboard-lock{width:12px;height:12px;flex-shrink:0}
#dashboardView .ready-dot{width:9px;height:9px;border-radius:50%;background:currentColor;flex-shrink:0}
#dashboardView .dashboard-task h3{font-size:20px;line-height:1.35;font-weight:700;letter-spacing:-.025em;margin:0 0 10px;color:var(--dash-text)}
#dashboardView .dashboard-task>p{font-size:16px;line-height:1.5;color:var(--dash-muted);margin:0 0 12px;flex:1}
#dashboardView .task-constraints{display:flex;gap:6px;flex-wrap:wrap;align-items:center;border:0;padding:0;margin:16px 0 10px;width:auto;font-size:13px;color:var(--dash-muted)}
#dashboardView .task-constraints span{padding:2px 7px;border:1px solid var(--dash-border);border-radius:5px;background:var(--dash-soft);font-size:13px;line-height:1.5;font-weight:600}
#dashboardView .dashboard-task>.primary{width:100%;margin:0;min-height:46px;padding:10px 16px;border:1px solid var(--dash-button);border-radius:8px;background:var(--dash-button);font-size:16px;line-height:1.5;font-weight:700;color:#fff}
#dashboardView .dashboard-task>.round-locked-note{margin:0;font-size:14px;line-height:1.5;flex:0;color:var(--dash-muted)}
#dashboardView .problem-complete{font-size:14px;margin:16px 0 0;padding:0;color:var(--dash-accent)}
#dashboardView #catalogEmpty{font-size:16px;padding:24px;border:1px solid var(--dash-border);border-radius:12px;background:var(--dash-panel);color:var(--dash-muted)}
.dashboard-sr-only{position:absolute;width:1px;height:1px;margin:-1px;padding:0;overflow:hidden;clip-path:inset(50%);white-space:nowrap;border:0}
#dashboardView [hidden]{display:none!important}
#dashboardView :is(button,input,a):focus-visible{outline:2px solid var(--dash-accent);outline-offset:3px}
@media(max-width:1100px){#dashboardView .dashboard-section-heading{align-items:flex-start;flex-wrap:wrap}#dashboardView .problem-heading-actions{margin-left:auto}#dashboardView .dashboard-task{padding:16px}#dashboardView .dashboard-task.is-next{padding:15px}}
@media(max-width:800px){#dashboardView .dashboard-heading{align-items:flex-start;flex-direction:column;gap:16px}#dashboardView .dashboard-summary>div{padding:16px}#dashboardView .dashboard-summary strong{font-size:28px}#dashboardView .dashboard-tasks{grid-template-columns:1fr}#dashboardView .dashboard-task{padding:20px}#dashboardView .dashboard-task.is-next{padding:19px}#dashboardView .dashboard-summary{gap:10px}#dashboardView .problem-section,#dashboardView .problem-section.is-expanded{padding:20px}}
@media(max-width:550px){#dashboardView #dashboardTitle{font-size:30px}#dashboardView .dashboard-summary{grid-template-columns:1fr}#dashboardView .dashboard-summary>div{min-height:0}#dashboardView .catalog-tools .dashboard-search{flex-basis:100%}#dashboardView .dashboard-filters{gap:6px}#dashboardView .dashboard-filters button{min-height:44px;padding-inline:12px}#dashboardView .problem-heading-actions{justify-content:flex-start;margin:0;gap:10px;width:100%}#dashboardView :is(.dashboard-quick-start,.share-challenge-button,.dashboard-expand){min-height:44px}#dashboardView .dashboard-task>p{font-size:16px}}
@media(prefers-reduced-motion:reduce){#dashboardView .dashboard-expand svg{transition:none}}

@media(max-width:800px){#dashboardView .problem-section.is-expanded .dashboard-section-heading{display:flex;flex-direction:column;gap:14px}#dashboardView .is-expanded .problem-summary-copy{display:block}#dashboardView .is-expanded .problem-summary-copy>.tags{margin-bottom:8px}}
#dashboardView .learning-collections{margin:0 0 32px;padding:24px;border:1px solid var(--dash-border);border-radius:14px;background:var(--dash-soft)}
#dashboardView .learning-collections h2{font-size:24px;line-height:1.3;margin:8px 0}
#dashboardView .learning-collections p{color:var(--dash-muted);overflow-wrap:anywhere}
#dashboardView .collection-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,300px),1fr));gap:16px;margin-top:20px}
#dashboardView .collection-card{display:flex;flex-direction:column;align-items:flex-start;background:var(--dash-panel);border:1px solid var(--dash-border);border-radius:12px;padding:24px;min-width:0}
#dashboardView .collection-card h3{font:700 22px/1.35 var(--dash-font);letter-spacing:-.02em;color:var(--dash-text);margin:8px 0}
#dashboardView .collection-card p{flex:1;margin:0 0 16px}
#dashboardView .collection-card progress{appearance:none;display:block;width:100%;height:8px;margin:12px 0 20px;border:0;border-radius:999px;overflow:hidden;background:var(--dash-border);accent-color:var(--dash-accent)}
#dashboardView .collection-status{font-size:12px;font-weight:700;color:var(--dash-accent);letter-spacing:.04em}
#dashboardView .learning-collections button{display:inline-flex;align-items:center;min-height:44px;border:1px solid var(--dash-border);background:var(--dash-panel);color:var(--dash-accent);padding:10px 16px;border-radius:8px;font-size:14px;font-weight:600}
#dashboardView .collection-sources{padding:4px 16px;border-left:3px solid var(--dash-accent);margin:20px 0}
#dashboardView .collection-sources a{color:var(--dash-accent);text-decoration:underline}
#dashboardView .collection-challenges{padding:0;list-style:none;counter-reset:lesson;display:grid;gap:12px}
#dashboardView .collection-challenges li{counter-increment:lesson;display:flex;align-items:center;gap:16px;padding:20px;background:var(--dash-panel);border:1px solid var(--dash-border);border-radius:10px}
#dashboardView .collection-challenges li::before{content:counter(lesson,decimal-leading-zero);font-size:22px;font-weight:700;color:var(--dash-accent)}
#dashboardView .collection-challenges li>div{flex:1;min-width:0}
#dashboardView .collection-challenges h3{margin:4px 0;font:700 19px/1.35 var(--dash-font);letter-spacing:-.02em;color:var(--dash-text)}
#dashboardView .collection-challenges p{margin:0 0 6px}
#dashboardView .collection-challenges small{color:var(--dash-muted)}
#dashboardView .learning-collections :focus-visible{outline:2px solid var(--dash-accent);outline-offset:4px}
@media(max-width:600px){#dashboardView .learning-collections{padding:16px}#dashboardView .collection-challenges li{display:grid;grid-template-columns:28px minmax(0,1fr);align-items:start;padding:16px;gap:12px}#dashboardView .collection-challenges li::before{grid-column:1;grid-row:1;font-size:18px}#dashboardView .collection-challenges li>div{grid-column:2;grid-row:1}#dashboardView .collection-challenges li>button{grid-column:2;justify-self:start;margin:0}}

.dashboard-pattern{display:flex;align-items:center;justify-content:space-between;gap:24px;flex-wrap:wrap;background:var(--panel);border:1px solid var(--line);border-radius:12px;padding:24px;margin:28px 0}.dashboard-pattern small{color:var(--accent);font-weight:700;letter-spacing:.08em}.dashboard-pattern h2{font-size:24px;margin:8px 0}.dashboard-pattern p{color:var(--muted);margin:0}.dashboard-pattern a{color:var(--accent);text-underline-offset:4px}.dashboard-pattern>a{font-weight:600;white-space:nowrap}
