/* Scoped to the single, catalogue-first library. */
/* Temporarily withdraw unverified workbook/transform entry points, not saved user material. */
.quick-action-grid,.input-workbook-callout{display:none!important}
body[data-view="input"] .input-intro{grid-template-columns:minmax(0,1fr)}
.library-search-mode{display:flex;flex-wrap:wrap;gap:8px;align-items:center;font-size:12px;color:#435570;margin:10px 0}
.library-search-mode select{border:1px solid #cad5e1;background:white;color:#253b55;padding:6px;font:inherit}
.library-search-mode small{font-size:11px;color:#748195}
#passageLibraryList.library-workspace{display:grid;grid-template-columns:minmax(240px,34%) minmax(0,1fr);gap:0;max-height:none;overflow:visible;border:1px solid #d5dfe6;background:#fff;padding:0;align-items:stretch}
.library-workspace *{box-sizing:border-box}
.library-workspace h4{display:flex;gap:8px;align-items:center;font-size:14px;margin:0 0 12px;color:#192942}
.library-workspace h4 em{display:grid;place-items:center;width:23px;height:23px;border-radius:50%;font-style:normal;background:#1f3351;color:white;font-size:12px}
.library-workspace h4>span{font-size:12px;font-weight:500;color:#64748b}
.library-step-books{padding:16px 0 0;background:#f7f9fc;border-right:1px solid #d5dfe6;min-width:0}
.library-step-books>h4{padding:0 16px}
.library-book-list{max-height:450px;overflow:auto;padding:0 10px 12px;scrollbar-gutter:stable}
.library-workspace .library-book{display:flex;flex-direction:column;gap:6px;width:100%;padding:12px;text-align:left;background:#fff;border:1px solid #dce4ec;border-radius:6px;margin:0 0 7px;color:#24354e;cursor:pointer;line-height:1.45}
.library-book strong{font-size:14px;overflow-wrap:anywhere}
.library-book small,.library-book span{font-size:11px;color:#63758b}
.library-workspace .library-book.is-active{border-color:#405b92;background:#edf3ff;box-shadow:inset 3px 0 #405b92}
.library-step-content{min-width:0;padding:18px}
.library-current-book{font-size:14px;font-weight:700;color:#213754;margin:0 0 12px;line-height:1.5}
.library-round-list{display:flex;flex-wrap:wrap;gap:6px;max-height:180px;overflow:auto}
.library-workspace .library-round{border:1px solid #cad5e1;background:#fff;border-radius:5px;padding:9px 12px;display:flex;gap:8px;align-items:center;color:#263e59;cursor:pointer;max-width:100%;text-align:left}
.library-round b{font-size:13px;overflow-wrap:anywhere}.library-round span{font-size:11px;white-space:nowrap;color:#6c7e92}
.library-workspace .library-round.is-active{background:#263e59;border-color:#263e59;color:#fff}.library-round.is-active span{color:#d6e6f8}
.library-questions{border-top:1px solid #dde4ec;padding-top:16px;margin-top:18px}
.library-question-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(100px,1fr));gap:8px;max-height:300px;overflow:auto;padding:2px}
.library-question{display:grid;grid-template-columns:18px 1fr;align-items:center;gap:5px 7px;border:1px solid #d6dfe8;border-radius:5px;padding:12px 9px;cursor:pointer;background:#fff;margin:0;min-width:0}
.library-question input{width:17px;height:17px;accent-color:#256b59;margin:0}
.library-question b{font-size:14px;color:#243b52}.library-question small{grid-column:2;font-size:10px;color:#738094;line-height:1.5}
.library-question.is-selected{border-color:#589781;background:#f1faf5}
.library-question.is-drag-preview{border-color:#2d8b6d;background:#dff3e9;box-shadow:inset 0 0 0 1px #2d8b6d}.library-question-grid:has(.is-drag-preview){user-select:none}
.library-drag-hint{margin:-5px 0 9px;color:#61748a;font-size:11px;line-height:1.5}
.library-guide{grid-column:1/-1;font-size:13px;color:#748195;padding:28px 10px;text-align:center;line-height:1.6}
.library-error{padding:12px;background:#fff2ed;border:1px solid #eec4b7;color:#994c37;font-size:13px;line-height:1.6;margin:10px 0}
.library-error button{border:1px solid currentColor;padding:4px 8px;background:white;margin-left:7px;cursor:pointer}
.library-local,.library-basket{grid-column:1/-1;padding:16px;border-top:1px solid #d5dfe6;background:#fafcfe}
.library-basket>div{display:flex;gap:6px;flex-wrap:wrap;max-height:150px;overflow:auto}
.library-basket button,.library-local button{font:inherit;font-size:12px;line-height:1.5;border:1px solid #cfdae4;background:#fff;color:#284c62;border-radius:5px;padding:7px 10px;text-align:left;cursor:pointer}
.library-basket p{font-size:12px;color:#718298;margin:0}.library-basket b{margin-left:8px;color:#985640}
.library-workspace button:focus-visible,.library-workspace input:focus-visible{outline:3px solid #79a6df;outline-offset:2px}
.library-workspace button:disabled,.library-workspace input:disabled{cursor:wait;opacity:.6}
body[data-view="input"] #librarySelection{padding-top:16px;gap:12px;align-items:center}
body[data-view="input"] #createLibraryLesson{min-height:64px;max-height:84px;padding:12px 20px;font-size:14px;min-width:240px}
body[data-view="input"] #createLibraryLesson small{font-size:10px;margin-bottom:6px}
@media(max-width:760px){#passageLibraryList.library-workspace{grid-template-columns:1fr}.library-step-books{border-right:0;border-bottom:1px solid #d5dfe6}.library-book-list{max-height:210px}.library-step-content{padding:14px}.library-head{flex-wrap:wrap;gap:12px}.library-head-actions{flex-wrap:wrap}body[data-view="input"] #librarySelection{flex-direction:column;align-items:stretch}body[data-view="input"] #createLibraryLesson{width:100%;min-width:0}}
