/* Ian's Learning Hub · shared web / app direction, October 2026. */
.hub-v2 { --hub-canvas:#f5f2eb; --hub-surface:#fffefa; --hub-soft:#eae7de; --hub-text:#24352d; --hub-muted:#59685e; --hub-line:#d4d8cc; --hub-accent:#285c49; background:var(--hub-canvas); color:var(--hub-text); }
[data-theme="dark"] .hub-v2 { --hub-canvas:#17211c; --hub-surface:#202d25; --hub-soft:#2a3a30; --hub-text:#f1f0e5; --hub-muted:#b1beb2; --hub-line:#405044; --hub-accent:#a6d2b0; }
.hub-v2 *, .hub-v2 *::before, .hub-v2 *::after { box-sizing:border-box; }
.hub-v2, [data-theme="dark"] .hub-v2 {
 --bg:var(--hub-canvas); --bg-solid:var(--hub-canvas); --surface:var(--hub-surface); --surface-solid:var(--hub-surface);
 --surface-soft:var(--hub-soft); --surface-hover:var(--hub-soft); --surface-accent:color-mix(in srgb,var(--hub-accent) 8%,var(--hub-surface));
 --text:var(--hub-text); --text-soft:var(--hub-muted); --text-muted:var(--hub-muted); --line:var(--hub-line); --line-soft:var(--hub-line);
 --primary:var(--hub-accent); --primary-solid:var(--hub-accent); --primary-hover:var(--hub-accent);
 --learn-canvas:var(--hub-canvas); --learn-surface:var(--hub-surface); --learn-soft:var(--hub-soft); --learn-text:var(--hub-text);
 --learn-muted:var(--hub-muted); --learn-line:var(--hub-line); --learn-blue:var(--hub-accent);
 --font-display:"Aptos","Segoe UI",-apple-system,BlinkMacSystemFont,"Helvetica Neue",Arial,"Noto Sans SC",sans-serif;
 --font-ui:var(--font-display); font-family:var(--font-ui);
}
.hub-v2 > .container { padding:0; margin:0; max-width:none; width:100%; }
.hub-nav { display:block; position:sticky; top:0; z-index:30; margin:0; padding:0; border:0; border-bottom:1px solid #405044; border-radius:0; background:#24352d; box-shadow:none; backdrop-filter:none; animation:none; }
.hub-nav-inner { width:100%; max-width:1240px; min-height:68px; margin:auto; padding:10px 32px; display:flex; align-items:center; justify-content:space-between; gap:24px; }
.hub-brand { display:flex; align-items:center; gap:10px; color:#f3f0e5; text-decoration:none; font-size:15px; font-weight:650; white-space:nowrap; letter-spacing:-.3px; }
.hub-brand-mark { width:30px; height:32px; display:grid; place-items:center; background:#d8cba7; color:#24352d; border-radius:3px 3px 8px 3px; font-size:22px; line-height:1; }
.hub-nav nav { display:flex; flex-wrap:nowrap; gap:5px; align-items:center; }
.hub-nav-link, .hub-nav .theme-toggle { display:inline-flex; justify-content:center; align-items:center; min-height:40px; padding:8px 13px; border:0; border-radius:5px; color:#c2cfc3; background:transparent; font-size:14px; font-weight:500; text-decoration:none; white-space:nowrap; }
.hub-nav-link:hover, .hub-nav .theme-toggle:hover { background:#35483c; color:#fffefa; }
.hub-nav-link[aria-current="page"] { background:#e6ecdd; color:#24352d; font-weight:650; }
.hub-nav :focus-visible { outline-color:#d8cba7; }
.hub-v2 :focus-visible { outline:3px solid var(--hub-accent); outline-offset:4px; }
.hub-v2 :is(button,a,input,textarea,select):focus-visible { box-shadow:0 0 0 3px color-mix(in srgb,var(--hub-accent) 20%,transparent)!important; }
.hub-v2 :is(.submit-btn,.secondary-btn,.secondary-link,.prompt-action) { border-radius:6px; }
.hub-v2 :is(.learning-surface,.prompt-workbench,.editor-workbench,.records-panel,.library-dialog) { border-radius:8px; }
.hub-v2 :is(.prompt-action,.editor-toolbar,.records-table-header) { background:var(--hub-soft); }
.hub-v2 .editor-toolbar { border-radius:7px 7px 0 0; }
.hub-v2.site-login { background:var(--hub-canvas); }
.hub-v2.site-login .login-brand-panel { background:#24352d; border-radius:8px; }
.hub-v2.site-login .login-brand-panel :is(h1,.app-wordmark) { color:#f3f0e5; }
.hub-v2.site-login .login-brand-panel :is(p,.eyebrow) { color:#c2cfc3; }
.hub-v2.site-login .login-form-panel { background:transparent; animation:none; }
.hub-v2.site-login .login-card { border-radius:8px; box-shadow:none; animation:none; opacity:1; transform:none; }
.hub-skip { position:fixed; left:16px; top:-80px; z-index:100; padding:12px 18px; background:var(--hub-surface); color:var(--hub-accent); border:2px solid; border-radius:9px; }
.hub-skip:focus { top:10px; }
.hub-subnav { max-width:1240px; margin:0 auto; padding:12px 32px; display:flex; flex-wrap:wrap; gap:8px; border-bottom:1px solid var(--hub-line); }
.hub-subnav a { padding:8px 12px; font-size:14px; color:var(--hub-muted); border-radius:8px; text-decoration:none; }
.hub-subnav a[aria-current="page"] { color:var(--hub-accent); background:var(--hub-surface); font-weight:600; }
.hub-v2 .eyebrow { color:var(--hub-accent); font-size:11px; font-weight:700; letter-spacing:1.1px; line-height:1.5; margin:0 0 10px; }
.hub-home { max-width:1240px; margin:0 auto; padding:36px 32px 64px; }
.hub-home-heading { display:flex; justify-content:space-between; gap:24px; align-items:flex-end; margin-bottom:30px; padding:0; border:0; border-radius:0; background:none; box-shadow:none; animation:none; backdrop-filter:none; }
.hub-home-heading h1 { max-width:680px; font-size:clamp(32px,3.4vw,48px); line-height:1.12; letter-spacing:-1.9px; font-weight:600; margin:0 0 14px; }
.hub-home-heading p:not(.eyebrow) { color:var(--hub-muted); line-height:1.6; margin:0; font-size:15px; }
.hub-home-heading .hub-date { white-space:nowrap; font-size:13px; padding-bottom:4px; }
.hub-continue { background:color-mix(in srgb,var(--hub-accent) 8%,var(--hub-surface)); border:1px solid color-mix(in srgb,var(--hub-accent) 22%,var(--hub-line)); border-left:4px solid var(--hub-accent); border-radius:7px; padding:26px 28px; display:flex; align-items:center; justify-content:space-between; gap:28px; margin-bottom:34px; }
.hub-continue h2 { font-size:25px; line-height:1.3; letter-spacing:-.7px; margin:0 0 8px; }
.hub-continue p:not(.eyebrow) { margin:0; color:var(--hub-muted); font-size:14px; line-height:1.65; }
.hub-v2 .primary-link, .hub-v2 .primary-btn { background:var(--hub-accent); color:#fffefa; border-radius:6px; min-height:44px; padding:11px 18px; font-size:14px; font-weight:600; line-height:1.5; text-decoration:none; }
[data-theme="dark"] .hub-v2 .primary-link, [data-theme="dark"] .hub-v2 .primary-btn { color:#17211c; }
.hub-continue .primary-link { flex-shrink:0; }
.hub-home-grid { display:grid; grid-template-columns:minmax(0,1fr) 280px; gap:36px; align-items:start; }
.hub-section-heading { display:flex; justify-content:space-between; align-items:center; gap:16px; margin:0 0 16px; }
.hub-section-heading h2 { font-size:17px; line-height:1.4; letter-spacing:-.3px; margin:0; }
.hub-section-heading > span { color:var(--hub-muted); font-size:12px; }
.hub-subject-grid { display:block; border-top:1px solid var(--hub-line); }
.hub-subjects { margin:0; padding:0; border:0; border-radius:0; background:none; box-shadow:none; animation:none; }
.hub-subjects::before,.history-directory::before,.history-era::before,#quizSection::before { display:none; }
.hub-continue { box-shadow:none; animation:none; }
.hub-subject { position:relative; display:grid; grid-template-columns:150px minmax(0,1fr); column-gap:20px; min-height:138px; padding:24px 38px 24px 0; border:0; border-bottom:1px solid var(--hub-line); border-radius:0; background:transparent; color:var(--hub-text); text-decoration:none; transition:background .16s; }
.hub-subject:hover { background:color-mix(in srgb,var(--hub-accent) 4%,var(--hub-canvas)); }
.hub-subject-label { grid-column:1; grid-row:1 / span 3; padding-top:5px; font-size:11px; font-weight:650; letter-spacing:1px; color:var(--hub-muted); }
.hub-subject h3 { grid-column:2; font-size:23px; line-height:1.2; letter-spacing:-.6px; margin:0 0 8px; font-weight:600; }
.hub-subject p { grid-column:2; color:var(--hub-muted); font-size:14px; line-height:1.65; margin:0 0 10px; }
.hub-subject-action { grid-column:2; display:block; color:var(--hub-accent); font-size:12px; font-weight:650; }
.hub-subject::after { content:'↗'; position:absolute; right:6px; top:24px; font-size:21px; color:var(--hub-accent); }
.hub-today { padding:0 0 0 24px; border-left:1px solid var(--hub-line); }
.hub-subject-history h3 { font-size:22px; letter-spacing:0; }
.hub-task-list > a { display:block; padding:16px 0; color:var(--hub-text); border-bottom:1px solid var(--hub-line); text-decoration:none; }
.hub-task-list > a:first-child { padding-top:4px; }
.hub-task-list strong { display:block; font-size:14px; margin-bottom:6px; font-weight:650; }
.hub-task-list span { display:block; color:var(--hub-muted); font-size:13px; line-height:1.6; }
.hub-task-list a:hover strong { color:var(--hub-accent); }
.hub-review-link { padding-top:30px; }
.hub-review-link h3 { font-size:18px; line-height:1.35; letter-spacing:-.3px; margin:0 0 10px; }
.hub-review-link p:not(.eyebrow), .hub-home-status { color:var(--hub-muted); font-size:13px; line-height:1.7; }
.hub-review-link a { display:block; color:var(--hub-accent); font-size:13px; text-decoration:none; padding:8px 0; }
.hub-v2 .records-main, .hub-v2 .writing-app { max-width:1280px; margin:0 auto; padding:32px 32px 60px; }
.hub-v2 .records-page-header, .hub-v2 .workspace-header { margin-bottom:24px; padding-bottom:20px; border-bottom:1px solid var(--hub-line); }
.hub-v2 .records-page-header h1, .hub-v2 .workspace-header h1, .hub-page-heading h1 { font-size:36px; line-height:1.15; letter-spacing:-1.1px; margin:0 0 10px; }
.hub-v2 .records-page-header p, .hub-page-heading .page-intro { color:var(--hub-muted); font-size:14px; line-height:1.65; }
.hub-page-heading { display:block; margin:0 0 24px; padding:0 0 8px; border:0; border-radius:0; background:none; box-shadow:none; backdrop-filter:none; animation:none; grid-column:1 / -1; }
.hub-v2 .grammar-home, .hub-v2 .progress-flow, .hub-v2 .knowledge-layout, .hub-v2 .mixed-layout { padding-top:28px; }
.hub-v2.learning-page main { max-width:1240px; margin:0 auto; padding:28px 24px 60px; }
.hub-v2 .star-subnav { margin-bottom:20px; padding-top:0; }
.hub-v2 .mixed-intro { padding:24px; }
.hub-v2 .mixed-intro h2 { font-size:24px; line-height:1.25; margin-bottom:12px; }
.hub-v2 .learning-surface { border-color:var(--hub-line); box-shadow:none; }
.hub-v2 .history-intro { display:flex; align-items:flex-end; justify-content:space-between; gap:20px; }
.history-count { color:var(--hub-muted); font-size:13px; white-space:nowrap; }
.history-tabs { display:flex; gap:4px; align-items:center; padding:4px; background:var(--hub-soft); border-radius:11px; width:max-content; }
.history-tabs button { min-height:38px; border:0; background:transparent; color:var(--hub-muted); border-radius:8px; padding:8px 22px; font-size:14px; cursor:pointer; }
.history-tabs button.is-current { background:var(--hub-surface); color:var(--hub-text); box-shadow:0 1px 3px #0000000b; }
.history-toolbar { display:flex; align-items:center; gap:12px; flex-wrap:wrap; margin:20px 0 26px; }
.history-toolbar label { margin-left:auto; }
.history-toolbar input, .history-toolbar select { border:1px solid var(--hub-line); background:var(--hub-surface); color:var(--hub-text); padding:10px 12px; border-radius:9px; min-height:44px; font-size:14px; }
.history-toolbar input { width:230px; }
.history-toolbar select { width:auto; }
.history-directory { border:0; background:transparent; padding:0; box-shadow:none; }
.history-directory > h2 { font-size:16px; margin:0 0 14px; }
.history-era { margin:0 0 30px; padding:0; border:0; border-radius:0; background:none; box-shadow:none; animation:none; }
#quizSection { margin:0; padding:0; border:0; border-radius:0; background:none; box-shadow:none; animation:none; }
.history-era-heading { display:flex; align-items:baseline; gap:10px; margin-bottom:12px; }
.history-era-heading h3 { margin:0; font-size:20px; letter-spacing:-.5px; }
.history-era-heading span { color:var(--hub-muted); font-size:12px; }
.history-course-list { background:var(--hub-surface); border:1px solid var(--hub-line); border-radius:7px; overflow:hidden; }
.history-course { display:flex; align-items:center; gap:20px; justify-content:space-between; padding:19px 22px; border-bottom:1px solid var(--hub-line); }
.history-course:last-child { border-bottom:0; }
.history-course h4 { font-size:16px; line-height:1.5; margin:0 0 4px; font-weight:650; }
.history-course p { font-size:13px; color:var(--hub-muted); line-height:1.65; margin:0; max-width:640px; }
.history-course-meta { display:flex; align-items:center; gap:10px; flex-wrap:wrap; margin-top:8px; font-size:12px; color:var(--hub-muted); }
.history-badge { display:inline-flex; border-radius:6px; padding:3px 7px; color:var(--hub-muted); background:var(--hub-soft); font-size:11px; }
.history-badge.is-active { background:color-mix(in srgb,var(--hub-accent) 10%,var(--hub-surface)); color:var(--hub-accent); }
.history-course-actions { display:flex; align-items:center; gap:8px; flex-shrink:0; }
.hub-v2 .history-course-actions button { font-size:13px; padding:9px 12px; min-height:40px; border-radius:9px; }
.history-text-button { border:0; background:none; color:var(--hub-muted); cursor:pointer; }
.history-course .secondary-btn { background:var(--hub-surface); color:var(--hub-text); border:1px solid var(--hub-line); }
.hub-v2.history-page.is-answering .hub-nav, .history-page.is-answering .history-intro, .history-page.is-answering .history-toolbar { display:none; }
.hub-v2.history-page.is-answering .records-main { padding-top:24px; }
.history-session-top { display:flex; align-items:center; justify-content:space-between; gap:12px; margin-bottom:22px; }
.history-session-top h2 { margin:0; font-size:16px; line-height:1.4; }
.history-session-top button { min-height:44px; border:1px solid var(--hub-line); color:var(--hub-muted); background:var(--hub-surface); border-radius:9px; padding:9px 14px; font-size:13px; cursor:pointer; }
.history-progress { display:block; width:100%; height:5px; border:0; border-radius:4px; overflow:hidden; margin:12px 0 26px; accent-color:var(--hub-accent); background:var(--hub-soft); }
.history-progress::-webkit-progress-bar { background:var(--hub-soft); }
.history-progress::-webkit-progress-value { background:var(--hub-accent); }
.history-page .star-workspace.has-rail { display:grid; grid-template-columns:minmax(0,1fr) 220px; gap:24px; align-items:start; }
.history-page .question-card { padding:28px; border-radius:8px; }
.history-page .question-text { font-size:21px; font-weight:600; line-height:1.75; margin:20px 0; max-width:780px; }
.history-page .options-list { max-width:780px; }
.history-page .option-item { background:var(--hub-surface); border:1px solid var(--hub-line); border-radius:8px; padding:15px; font-size:16px; line-height:1.75; gap:12px; }
.history-page .option-item:has(input:checked) { border-color:var(--hub-accent); background:color-mix(in srgb,var(--hub-accent) 7%,var(--hub-surface)); }
.history-page .question-header h2 { font-size:15px; color:var(--hub-muted); font-weight:500; margin:0 0 6px; }
.history-page .question-header .eyebrow { display:none; }
.history-page #questionSubtitle { font-size:13px; line-height:1.6; color:var(--hub-muted); }
.history-page .session-rail { padding:22px; border-radius:8px; }
.history-page .session-rail h2 { font-size:17px; margin-bottom:16px; }
.history-page .session-rail p { font-size:12px; line-height:1.75; color:var(--hub-muted); }
.history-page .question-actions { display:flex; justify-content:space-between; gap:12px; padding-top:12px; }
.hub-v2 button:disabled { opacity:.5; cursor:not-allowed; }
.history-page dialog { width:min(440px,calc(100% - 32px)); border:1px solid var(--hub-line); background:var(--hub-surface); color:var(--hub-text); border-radius:16px; padding:28px; }
.history-page dialog::backdrop { background:#0006; }
.history-page dialog h2 { font-size:22px; margin:0 0 12px; }
.history-page dialog p { color:var(--hub-muted); font-size:14px; line-height:1.8; }
.history-page dialog .lesson-actions { display:flex; justify-content:flex-end; gap:10px; }
@media(min-width:1000px) { .hub-v2 .grammar-container,.hub-v2 .diagnostics-container,.hub-v2 .knowledge-container { max-width:none; } .hub-v2 .grammar-home,.hub-v2 .progress-flow { max-width:1200px; margin:auto; } }
@media(max-width:1000px) { .hub-home-grid { grid-template-columns:minmax(0,1fr) 240px; gap:24px; } .hub-nav-inner { padding-inline:24px; gap:16px; } .hub-brand { font-size:13px; } .hub-nav-link { padding-inline:10px; } .hub-subject { padding:20px; } }
@media(max-width:760px) {
 .hub-nav-inner { position:relative; padding:12px 16px 8px; display:block; }
 .hub-brand { font-size:14px; margin-bottom:10px; }
 .hub-brand-mark { width:26px; height:26px; font-size:20px; border-radius:7px; }
 .hub-nav nav { gap:2px; overflow-x:auto; scrollbar-width:none; padding-bottom:4px; }
 .hub-nav-link,.hub-nav .theme-toggle { min-height:40px; font-size:13px; padding:8px 10px; flex-shrink:0; }
 .hub-nav .theme-toggle { position:absolute; top:10px; right:16px; min-height:32px; padding:4px 8px; }
 .hub-subnav { padding:10px 16px; gap:2px; }
 .hub-subnav a { padding:8px; font-size:12px; }
 .hub-home { padding:26px 20px 40px; }
 .hub-home-heading { margin-bottom:24px; display:block; }
 .hub-home-heading h1 { font-size:32px; letter-spacing:-1.1px; }
 .hub-home-heading .hub-date { display:none; }
 .hub-continue { padding:20px; display:block; margin-bottom:28px; }
 .hub-continue h2 { font-size:22px; }
 .hub-continue .primary-link { display:inline-flex; margin-top:16px; }
 .hub-home-grid { grid-template-columns:1fr; gap:28px; }
 .hub-subject-grid { display:block; }
 .hub-subject { grid-template-columns:minmax(0,1fr); padding:20px 30px 20px 0; min-height:0; }
 .hub-subject-label { grid-column:1; grid-row:auto; padding-top:0; margin-bottom:10px; }
 .hub-subject h3 { grid-column:1; font-size:22px; }
 .hub-subject p { grid-column:1; font-size:14px; }
 .hub-subject-action { grid-column:1; }
 .hub-subject-action { font-size:12px; }
 .hub-section-heading > span { display:none; }
 .hub-today { padding:22px 0 0; border-left:0; border-top:1px solid var(--hub-line); }
 .hub-v2 .records-main,.hub-v2 .writing-app { padding:24px 16px 40px; }
 .hub-v2 .records-page-header h1,.hub-page-heading h1,.hub-v2 .workspace-header h1 { font-size:30px; letter-spacing:-.8px; }
 .hub-v2 .records-page-header { padding-bottom:16px; margin-bottom:18px; }
 .hub-v2 .mixed-intro { padding:20px; }
 .hub-v2 .mixed-intro h2 { font-size:22px; }
 .hub-v2 .star-page .star-subnav { gap:8px; }
 .history-toolbar { gap:10px; margin:18px 0 22px; }
 .history-toolbar label { margin:0; flex:1; min-width:150px; }
 .history-toolbar input { width:100%; }
 .history-toolbar select { flex:1; }
 .history-tabs { flex-basis:100%; }
 .history-tabs button { padding-inline:20px; }
 .history-count { display:none; }
 .history-course { padding:18px; align-items:flex-start; flex-direction:column; gap:14px; }
 .history-course-actions { flex-wrap:wrap; width:100%; }
 .history-course-actions .primary-btn { margin-left:auto; }
 .history-page .star-workspace.has-rail { display:block; }
 .history-page.is-answering .session-rail { display:none; }
 .history-page .question-card { padding:20px; }
 .hub-v2.history-page.is-answering .records-main { padding:14px 12px 30px; }
 .history-session-top { gap:8px; margin-bottom:14px; }
 .history-session-top h2 { font-size:14px; }
 .history-session-top button { padding-inline:10px; font-size:12px; }
 .history-page .question-text { font-size:19px; line-height:1.7; margin-top:18px; }
 .history-page .option-item { font-size:16px; padding:13px; }
 .history-progress { margin-bottom:20px; }
 .history-page .question-actions { align-items:center; }
}
@media(max-width:360px) { .hub-subject-grid { grid-template-columns:1fr; } .hub-subject { min-height:auto; } }

.hub-subject-groups .hub-subject { grid-template-columns:minmax(0,1fr); min-height:0; }
.hub-subject-groups .hub-subject :is(h3,p) { grid-column:1; }
.hub-subject-groups .hub-subject p { margin-bottom:0; }
.hub-subject-home { max-width:960px; }
.hub-course-list { list-style:none; margin:0; padding:0; border-top:1px solid var(--hub-line); }
.hub-course {
  display:grid;
  grid-template-columns:minmax(0,1fr) auto;
  gap:16px 32px;
  align-items:center;
  padding:22px 0;
  border-bottom:1px solid var(--hub-line);
}
.hub-course :is(h2,h3) { margin:0 0 6px; font-size:21px; font-weight:600; }
.hub-course p { margin:0; color:var(--hub-muted); font-size:14px; line-height:1.65; }
.hub-course-links { display:flex; flex-wrap:wrap; align-items:center; gap:12px 16px; }
.hub-course-links > a:not(.primary-link) { color:var(--hub-accent); font-size:14px; padding-block:8px; }
@media(max-width:680px) {
  .hub-course { grid-template-columns:1fr; gap:12px; }
}
@media(prefers-reduced-motion:reduce) { .hub-v2 *, .hub-v2 *::before,.hub-v2 *::after { transition:none!important; animation:none!important; scroll-behavior:auto!important; } }
