
/* Portal light theme: override legacy dark-reader specificity. */
.reader .reader-header .back,.reader .reader-bottom .reading-hint{color:#615574}
.reader .zoom-control button,.reader .tool,.reader .small-icon{background:#eaf7ff;color:#301068;border:1px solid #c8dced}
.reader .tool:hover,.reader .small-icon:hover,.reader .zoom-control button:hover{background:#d9effd}
.reader .page-counter{background:#fff;border:1px solid #d9d0e9;color:#594569}
.reader .page-counter input{background:#f5f0fb;color:#301068}
.reader .tool.selected,.reader #activity-toggle[aria-expanded=true]{background:#fff1b0;color:#301068}
@font-face{font-family:Klassmaster Rubik;src:url('./fonts/Rubik-Regular.ttf') format('truetype');font-style:normal;font-weight:400 600;font-display:swap}
@font-face{font-family:Klassmaster Rubik;src:url('./fonts/Rubik-Bold.ttf') format('truetype');font-style:normal;font-weight:650 900;font-display:swap}
:root{--purple:#301068;--purple-dark:#230749;--ink:#28154a;--muted:#615574;--cyan:#009fdf;--yellow:#ffbf00;--line:#dcd4eb;--paper:#f6faff;--lav:#ede7f9;--bg:#f6faff;font-family:'Klassmaster Rubik','Trebuchet MS','Segoe UI',sans-serif}
body{font-size:16px}button,input,select,textarea{font-family:inherit}button,a,input,select{touch-action:manipulation}
.button{display:inline-flex;align-items:center;justify-content:center;gap:10px;padding:12px 18px;border:1px solid transparent;font-weight:700}.primary,.button.primary{background:var(--purple);color:#fff;border-radius:14px;font-size:16px;font-weight:700;min-height:46px;box-shadow:0 3px 0 #1d0645}.primary:hover,.button.primary:hover{background:#482180}
.secondary,.outline,.button.secondary{border-radius:14px;font-size:16px;min-height:44px;background:#e9f7ff;color:#244773;border:1px solid #b9def2}
.header,.site-header{border-bottom:3px solid var(--cyan)}.header-inner{gap:34px}.hero{background:linear-gradient(120deg,#f0eafb,#e8f7ff);border-radius:26px}.hero h1{letter-spacing:-.025em}.hero h1 em{color:var(--purple)}.hero-art{background:#dff3ff;border:2px solid #bee5fb}.hero-copy p{font-size:16px;color:var(--muted)}.eyebrow{font-size:13px;letter-spacing:.055em}.hero .eyebrow>span{background:var(--yellow);width:10px;height:10px}.hero-note,.catalog-total,.result-meta,.footer{font-size:14px}.search-bar{min-height:54px;border-radius:16px}.search-bar input,.filterbar input{font-size:16px}.filter-label,.filters select,.filter-title h3,.text-button,.tab,.sort select{font-size:14px}.filters select{height:44px;border-radius:11px}.tabs{gap:18px}.tab{min-height:44px}.book-card{border-radius:20px;border:2px solid #e1d8ef}.card-visual{background:#eaf6fd}.card-body h3,.book-meta h2{font-size:18px;min-height:50px}.authors{font-size:14px;line-height:1.5;height:42px}.subject-line,.book-kind,.status,.book-badge,.grade-badge{font-size:13px}.book-badge,.grade-badge{color:#301068;background:#fff1b5;border-radius:8px}.card-footer{flex-wrap:wrap}.card-read,.read-link{font-size:14px;border-radius:10px;min-height:40px}.card-read .icon{width:18px;height:18px}.save-button{width:36px;height:36px;color:var(--purple)}.save-button .icon{width:19px;height:19px}.pagination button{width:42px;height:42px;font-size:16px;border-radius:12px}.availability-note p{font-size:13px}.availability-note strong{font-size:14px}.placeholder-cover strong{font-size:12px}
.reader-header{border-bottom:2px solid #cceafb;padding:10px 20px;gap:16px}.reader-title strong,.reader-header h1{font-size:18px;color:var(--purple);font-weight:700}.reader-title>span{font-size:14px}.reader-brand{width:170px}.icon-button,.small-icon{width:44px;height:44px;border:1px solid #d9d0e9;border-radius:12px;color:var(--purple);background:#fff}.icon-button .icon,.small-icon .icon{width:23px;height:23px}.reader-actions .small{font-size:14px;min-height:44px}.reader-actions .icon-button{width:44px;height:44px}.reader-tools,.reader-toolbar{background:#fff;border-bottom:2px solid #dceaf4;gap:10px}.mode-switch,.mode-toggle{padding:4px;border:1px solid #dcd1ec;background:#f0eafa;border-radius:13px}.mode-switch button,.mode-toggle button{font-size:14px;padding:9px 12px;min-height:40px;border-radius:9px;font-weight:700}.mode-switch button[aria-pressed=true],.mode-toggle button[aria-pressed=true]{background:var(--purple);color:#fff}.zoom select,.zoom-control output{font-size:14px;color:var(--ink)}.zoom-control button{width:40px;height:40px;border-radius:11px;background:#eaf7ff;color:#301068}.zoom-control{margin-right:0}.tool{font-size:14px;min-height:42px;border-radius:11px;background:#f7f5fc;color:#402466;padding:10px 12px}.tool .icon{width:20px;height:20px}.tool.selected,#activity-toggle[aria-expanded=true]{background:#fff1b0;color:#301068}.back{font-size:14px;min-height:44px}.reader-header h1 small{display:block;font-size:13px;font-weight:400;color:var(--muted);overflow:hidden;text-overflow:ellipsis}
.page-stage,#stage,.reader-stage{background:#edf7fd}.reader-bottom{border-top:2px solid #cbe9f9;padding:9px 20px}.reader-bottom .icon-button,.reader-bottom .small-icon{width:44px;height:44px;background:#edf8ff;border:1px solid #bee1f7;color:#301068;border-radius:13px}.reader-bottom .icon{width:24px;height:24px}#page-form,.page-counter,.page-counter label,.reader-bottom label{font-size:14px;color:#594569}#page-number,.page-counter input{font-size:17px;font-weight:700;width:62px;height:40px;border:2px solid #d3c4e6;border-radius:10px;color:#301068}.keyboard-hint,.reading-hint,#spread-status,#reader-status{font-size:13px;color:#665b77}.page-arrow{width:44px;height:68px;background:#fff;border:2px solid #c4e8fb;border-radius:15px;box-shadow:0 3px 0 #c5e3f3}.page-arrow .icon{width:30px;height:30px;stroke-width:2.8}.page-arrow:hover:not(:disabled){background:var(--cyan);color:#fff}.page-range{height:7px;background:#cee9f8}.page-range::-webkit-slider-thumb{width:21px;height:21px;background:var(--purple);border:3px solid #ffbf00}
/* Equal side columns keep the transfer button at the true viewport centre. */
.reader-tools{display:grid;grid-template-columns:minmax(0,1fr) auto minmax(0,1fr);grid-template-areas:'mode transfer zoom' 'status status status';padding:10px 20px;align-items:center}.reader-tools .mode-switch{grid-area:mode;justify-self:start}.reader-tools .transfer-menu{grid-area:transfer;justify-self:center}.reader-tools .zoom{grid-area:zoom;justify-self:end;margin:0}.reader-tools #reader-status{grid-area:status;text-align:center;margin:0;min-height:0}.reader-tools #reader-status:empty{display:none}
.km-transfer-row{display:flex;justify-content:center;align-items:center;flex:0 0 100%;width:100%;padding:1px 0 9px;margin-bottom:2px;border-bottom:1px solid #e2eef7}.transfer-menu{margin:0;position:relative;font-size:16px;flex-shrink:0;width:max-content;max-width:100%;z-index:40}.transfer-menu summary{display:flex;align-items:center;justify-content:center;gap:11px;min-height:56px;padding:7px 8px 7px 16px;border:2px solid #301068;background:#301068;color:#fff;border-radius:17px;box-shadow:0 4px 0 #c9b9e2;cursor:pointer;font-weight:700;font-size:16px;line-height:1.25;list-style:none}.transfer-menu summary::-webkit-details-marker{display:none}.transfer-menu summary>.icon{width:27px;height:27px;color:#55d1ff;stroke-width:2}.transfer-chevron{display:grid;place-items:center;margin-left:8px;flex:none;width:39px;height:39px;border-radius:11px;background:#ffbf00;color:#301068;box-shadow:inset 0 -2px 0 #dda900}.transfer-chevron svg{width:26px;height:26px;transition:transform .18s}.transfer-menu[open] .transfer-chevron svg{transform:rotate(180deg)}.transfer-menu summary:hover{background:#43217c}.transfer-menu summary:focus-visible{outline:3px solid #009fdf;outline-offset:5px}
.transfer-options{left:50%;right:auto;transform:translateX(-50%);top:calc(100% + 12px);width:340px;max-width:calc(100vw - 32px);padding:8px;border:2px solid #d1eafb;border-radius:20px;box-shadow:0 12px 30px #29134b29;background:#fff}.transfer-options button{display:flex;gap:13px;width:100%;align-items:center;font-size:16px;min-height:77px;padding:12px;border-radius:13px;color:#301068;background:#fff;border:0;text-align:left}.transfer-options button>span{font-weight:700}.transfer-options button>.icon{box-sizing:content-box;padding:10px;width:25px;height:25px;border-radius:12px;background:#e1f5ff;color:#087ea8;stroke-width:2}.transfer-options button:nth-child(2)>.icon{background:#fff1b5;color:#5a4100}.transfer-options button:nth-child(3)>.icon{background:#eee5fb;color:#56308c}.transfer-options button:hover{background:#f0f8fd}.transfer-options small{font-size:13px;font-weight:400;line-height:1.45;margin-top:5px;color:#675b77}.book-transfer-dialog{font-family:inherit;border:2px solid #cfe8f7;border-radius:23px;background:#fff}.book-transfer-dialog>header{background:#f0f8ff;border-bottom:2px solid #d8ecf9}.book-transfer-dialog h2{font-size:23px;color:#301068}.book-transfer-dialog header p,.book-transfer-dialog label,.book-transfer-dialog .transfer-help,#transfer-status{font-size:15px;line-height:1.55}.book-transfer-dialog .button{font-size:15px;border-radius:12px;min-height:46px}.book-transfer-dialog footer{gap:12px}.exercise-choice{border:2px solid #d1e9f9;border-radius:16px;background:#f2faff}.exercise-choice strong{font-size:20px;color:#301068}
/* Existing book activities retain their contents and controls. */
.km-exercises{font-family:inherit;border-left:2px solid #cbe9fa;background:#fff}.km-ex-head{background:#edf8ff;border-bottom:2px solid #cceafb}.km-ex-head strong{font-size:18px}.km-selected-number{background:#ffbf00;color:#301068;border-radius:12px}.km-exercises button,.km-exercises input,.km-exercises select,.km-exercises textarea{font-family:inherit}.km-prompt{font-size:18px;line-height:1.5}.km-exercises .km-note,.km-exercises .km-review-alert{font-size:14px;line-height:1.5}.km-launch{background:#ffcb25;color:#301068;border:2px solid #fff;border-radius:9px;font-weight:700}.km-launch.is-active{background:#301068;color:#fff}.km-choices button,.km-ink-tools button{border-radius:10px;min-height:40px}.reader[data-notebook-embed=true] .km-transfer-row{display:none}
@media(max-width:1050px){.reader-tools{grid-template-columns:1fr 1fr;grid-template-areas:'transfer transfer' 'mode zoom' 'status status'}.reader-tools .transfer-menu{width:max-content}.reader-title>span{font-size:13px}.reader-header h1{font-size:16px}.reader-toolbar{justify-content:center}.reader-brand{width:145px}.book-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:760px){.reader-header{padding:8px 12px;gap:9px;flex-wrap:wrap}.reader-header .reader-title{max-width:none;flex:1}.reader-title strong{font-size:16px}.reader-header h1{font-size:16px}.reader-tools{padding:9px 12px;gap:9px}.transfer-menu{order:initial;flex-basis:auto}.transfer-menu summary{font-size:16px;padding-left:13px}.reader-tools .transfer-menu{width:max-content}.transfer-options{left:50%;right:auto;width:330px;max-width:calc(100vw - 24px)}.hero-copy p,.hero .button{font-size:16px}.hero .eyebrow,.hero-note,.header-saved,.section-heading .eyebrow,.catalog-total{font-size:13px}.card-body h3{font-size:17px;min-height:48px}.authors{font-size:13px;height:39px}.status,.card-read,.book-badge{font-size:13px}.reader-bottom{padding:8px 12px}.reading-hint{display:none}.reader-header .back span{display:none}.reader-brand{width:130px}.reader-header .back{width:36px}.reader-toolbar{padding:9px 12px}.tool{font-size:14px}.book-transfer-dialog{width:min(850px,96vw)}}
@media(max-width:480px){.transfer-menu summary{font-size:15px;gap:9px;min-height:54px}.transfer-chevron{width:36px;height:36px;margin-left:4px}.transfer-options button{font-size:16px}.mode-switch button,.mode-toggle button{font-size:13px;padding:8px 10px}.zoom select{font-size:13px;max-width:112px}.reader-title>span{max-width:190px;text-overflow:ellipsis;overflow:hidden;white-space:nowrap}.reader-header .reader-actions .icon-button{width:39px;height:41px}.reader-actions .small{padding:9px}.reader-brand{width:114px}.reader-header h1{flex-basis:calc(100% - 70px);white-space:normal}.reader-toolbar{gap:7px}.zoom-control button{width:36px}.tool{padding:8px 9px;font-size:13px}.hero .eyebrow{font-size:12px}.tab,.search-bar input{font-size:14px}.tabs{gap:12px}.authors{font-size:13px}.reader-bottom label{font-size:13px}#page-form,.page-counter{gap:6px}.reader-bottom{gap:10px}.reader-bottom .icon-button{width:40px;height:40px}.reader-bottom .small-icon{width:38px;height:40px}#spread-status{font-size:12px}.reader-bottom{flex-wrap:wrap;justify-content:center}#spread-status{flex-basis:100%;text-align:center}}
@media(prefers-reduced-motion:reduce){.transfer-chevron svg{transition:none}}
.reader-start{max-width:700px;margin:10vh auto;padding:28px;line-height:1.6;background:#fff;border:2px solid #cce8f9;border-radius:22px}.reader-start h1{font-size:26px;color:#301068}.reader-start a{margin-top:12px}.status.online{color:#08668c;background:#e7f6ff}.detail-source{line-height:1.55}.availability-note p{line-height:1.6}
/* Replace the previous dark reader chrome while keeping the original pages intact. */
:root .reader{background:#f0f8ff;color:#28154a;--ex-ink:#28154a;--ex-blue:#087aab;--ex-violet:#563092;--ex-line:#d4e8f6}
:root .reader .reader-header{background:#fff;border-bottom:2px solid #cceafb}
:root .reader .reader-toolbar{background:#fff;border-bottom:2px solid #dceaf4;padding:10px 22px;gap:8px}
:root .reader .reader-bottom{background:#fff;border-top:2px solid #cbe9f9;min-height:58px;padding:8px 20px}
:root .reader .reader-stage{background:#e4f2fb;box-shadow:inset 0 0 0 1px #c6e4f5,0 4px 15px #3020610c}
:root .reader .reader-workspace{margin-top:12px}
:root .reader .reader-brand{background:transparent;padding:0;border-radius:0}
:root .reader .km-exercises{background:#fff;border:2px solid #cce8f9;box-shadow:0 5px 18px #30106812;font-family:inherit}
:root .reader .km-ex-head,:root .reader .km-ex-head.km-has-selection{background:#e9f7ff;border-bottom:3px solid #009fdf}
:root .reader .km-ex-head strong{font-size:18px;color:#301068}
:root .reader .km-prompt{font-size:18px;color:#301068;line-height:1.5}
:root .reader .mode-toggle{background:#eee8fa;border:1px solid #d8cbed}
:root .reader .mode-toggle button{font-size:14px;color:#5e4679;min-height:40px}
:root .reader .mode-toggle button[aria-pressed=true]{background:#301068;color:#fff;box-shadow:0 2px 0 #bda9d6}
:root .reader .page-arrow{background:#fff;border:2px solid #b9dff5;color:#301068;box-shadow:0 3px 0 #beddf0}
:root .reader .page-arrow:hover:not(:disabled){background:#009fdf;color:#fff}
@media(max-width:760px){:root .reader .reader-toolbar{padding:8px 12px;gap:7px}:root .reader .reader-bottom{padding:7px 12px}:root .reader .km-ex-head strong{font-size:16px}:root .reader .km-prompt{font-size:17px}:root .reader .reader-workspace{margin-top:8px}:root .reader .mode-toggle button{font-size:13px}}
@media(max-width:480px){:root .reader .reader-bottom{display:flex;flex-wrap:wrap;justify-content:center}:root .reader #spread-status{width:100%;flex-basis:100%;text-align:center}}

.page-spread.quad{display:grid;grid-template-columns:repeat(2,max-content);gap:12px;justify-content:center;align-items:start}.page-spread.quad .page-image{flex:none}

@media(max-width:480px){.reader-tools{grid-template-columns:1fr;grid-template-areas:'transfer' 'mode' 'zoom' 'status'}.reader-tools .mode-switch,.reader-tools .zoom{justify-self:center}}

/* Prepared work is separate from the free writing workspace. */
.km-coverage{padding:12px 14px;margin:12px 0;border:1px solid #cbd8e3;border-radius:14px;background:#f5f8fc;color:#33254a;display:flex;flex-direction:column;gap:5px;font-size:14px;line-height:1.45}
.km-coverage.prepared{background:#ebfaff;border:2px solid #179ec2}.km-coverage strong{font-size:15px}.km-coverage small{font-size:13px}.km-coverage a{color:#341368;font-weight:800;text-decoration:underline;text-underline-offset:3px}
.km-reader-coverage{padding:0 22px}.km-reader-coverage .km-coverage{flex-direction:row;align-items:center;flex-wrap:wrap;gap:8px 18px;margin:8px 0}.km-reader-coverage .km-coverage a{margin-left:auto}
.reader[data-notebook-embed=true] .km-reader-coverage{display:none}
@media(max-width:650px){.km-reader-coverage{padding:0 10px}.km-reader-coverage .km-coverage{align-items:flex-start;flex-direction:column}.km-reader-coverage .km-coverage a{margin-left:0}}
