*,*:before,*:after{box-sizing:border-box}html,body,#root{margin:0;padding:0;min-height:100vh}body{font-family:system-ui,-apple-system,Segoe UI,Roboto,sans-serif;background:#f7f7f5;color:#1a1a1a}button{cursor:pointer;padding:.5rem 1rem;border:1px solid #1a1a1a;background:#1a1a1a;color:#fff;border-radius:4px;font-size:.95rem}button:disabled{opacity:.5;cursor:not-allowed}.workbook-theme{min-height:100vh}.workbook-header{position:sticky;top:0;z-index:5;display:flex;justify-content:space-between;align-items:center;padding:1rem 1.5rem;background:#fff;border-bottom:1px solid #e0e0e0;font-family:system-ui,sans-serif}.workbook-header-back{color:#1a1a1a;text-decoration:none;font-weight:600}.workbook-header-actions{display:flex;gap:12px;align-items:center}.workbook-header-hint{font-size:.8rem;color:#666;max-width:36ch;line-height:1.4}.workbook-pages{display:flex;flex-direction:column;align-items:center;gap:24px;padding:24px 12px 48px}.workbook-page{width:210mm;min-height:297mm;padding:18mm;background:var(--color-background, #ffffff);color:var(--color-text, #1a1a1a);box-sizing:border-box;box-shadow:0 2px 12px #00000014;page-break-after:always;break-after:page;display:flex;flex-direction:column}.workbook-page:last-child{page-break-after:auto;break-after:auto}.workbook-page-header{display:flex;justify-content:space-between;align-items:baseline;gap:12px;margin-bottom:16mm}.workbook-page-number{font-size:10pt;color:var(--color-muted, #777)}.workbook-page-encouragement{margin:0;font-size:12pt;color:var(--color-accent, #ff8a00);font-weight:600}.workbook-cover{align-items:center;justify-content:center;text-align:center}.workbook-cover-inner{display:flex;flex-direction:column;align-items:center;gap:18mm;margin:auto}.workbook-cover-decoration{filter:var(--svg-filter, none)}.workbook-cover-title{font-family:var(--font-title, system-ui);color:var(--color-primary, #1a1a1a);font-size:var(--size-title, 32pt);margin:0}.workbook-cover-author{font-size:14pt;color:var(--color-text)}.workbook-cover-author-name{border-bottom:2px solid var(--color-text);padding:0 1ch;margin-left:6px}.workbook-equation-grid{list-style:none;margin:0;padding:0;display:grid;gap:6mm 12mm;flex:1}.workbook-equation{display:flex;align-items:center;gap:8px;font-size:var(--size-problem, 20pt)}.workbook-equation-number{font-weight:600;color:var(--color-muted, #888);min-width:2ch}.workbook-equation-body{display:flex;align-items:center;gap:6px}.workbook-equation-operand,.workbook-equation-op,.workbook-equation-eq{font-variant-numeric:tabular-nums}.workbook-equation-blank{display:inline-block;min-width:3ch;border-bottom:2px solid var(--color-text);height:1em}.workbook-equation-blank-large{min-width:5ch;height:1.4em}.workbook-page-story{align-items:center}.workbook-story-illustration{margin:0 auto 16mm}.workbook-story-text{font-family:var(--font-body, system-ui);font-size:18pt;line-height:1.6;text-align:center;max-width:160mm;margin:0 auto 16mm}.workbook-story-equation{display:flex;justify-content:center;align-items:center;gap:10px;font-size:var(--size-problem, 24pt)}.workbook-completion{align-items:center;justify-content:center;text-align:center}.workbook-completion-inner{display:flex;flex-direction:column;align-items:center;gap:16mm;margin:auto}.workbook-completion-title{font-family:var(--font-title);color:var(--color-primary);font-size:var(--size-title);margin:0}.workbook-completion-text{font-size:16pt;max-width:140mm;line-height:1.6;margin:0}.workbook-completion-decoration{filter:var(--svg-filter, none)}.workbook-toast{position:fixed;bottom:24px;left:50%;transform:translate(-50%);background:#1a1a1a;color:#fff;padding:10px 16px;border-radius:999px;font-family:system-ui,sans-serif;font-size:.9rem;z-index:10}.regenerate-button{font-family:system-ui,sans-serif}@page{size:A4;margin:0}@media print{html,body{margin:0;padding:0;background:#fff!important;-webkit-print-color-adjust:exact;print-color-adjust:exact}.no-print{display:none!important}.workbook-theme{background:#fff;-webkit-print-color-adjust:exact;print-color-adjust:exact}.workbook-pages{gap:0;padding:0}.workbook-page{box-shadow:none;margin:0;padding:14mm;page-break-after:always;break-after:page;page-break-inside:avoid;break-inside:avoid}.workbook-page:last-child{page-break-after:auto;break-after:auto}.workbook-equation-grid,.workbook-story-illustration,.workbook-cover-decoration,.workbook-completion-decoration{page-break-inside:avoid;break-inside:avoid}button,a{color:inherit!important;background:transparent!important;text-decoration:none!important}}
