.lesson-presentation{min-width:0;border:1px solid #d6dfd7;border-radius:16px;overflow:hidden;background:#f1f4f0}.presentation-toolbar{display:flex;align-items:center;gap:10px;flex-wrap:wrap;padding:12px;background:#fff;border-bottom:1px solid #d6dfd7;font-size:13px}.presentation-toolbar label{display:flex;align-items:center;gap:6px}.presentation-toolbar input{width:64px}.presentation-toolbar button,.presentation-toolbar input,.presentation-toolbar select{min-height:36px;border:1px solid #b9c9be;border-radius:8px;padding:5px 8px;background:#fff;color:#254c40}.presentation-toolbar button:disabled{opacity:.45}.presentation-toolbar a{color:#254c40}.presentation-follow{margin-left:auto;color:#52685b;font-size:12px}.presentation-viewport{height:65vh;min-height:320px;max-height:850px;overflow:auto;padding:16px;overscroll-behavior:contain}.presentation-viewport canvas{display:block;margin:auto;background:#fff;box-shadow:0 3px 16px #254c4020}.presentation-status{padding:0 16px;color:#52685b;font-size:13px}.presentation-status:empty{display:none}.presentation-toolbar [data-pdf-count]{white-space:nowrap}@media(max-width:600px){.presentation-toolbar{gap:6px}.presentation-follow{width:100%;margin:0}.presentation-viewport{height:55vh;padding:8px}}
.presentation-web-frame{display:block;width:100%;height:65vh;min-height:360px;border:0;background:white}.presentation-web-help{margin:10px 16px;color:#52685b;font-size:12px}.presentation-toolbar [data-web-address]{display:flex;flex:1;gap:6px;min-width:220px}.presentation-toolbar [data-web-address] label{flex:1}.presentation-toolbar [data-web-url]{width:100%;min-width:100px}
.wb-lesson-presentation{margin-bottom:16px;padding:12px;border:1px solid #c5d6ca;border-radius:18px;background:#f6f9f4}.wb-lesson-heading{display:flex;justify-content:space-between;gap:12px;align-items:center;padding:0 4px 12px;font-size:13px;color:#476b58}.wb-material-picker{padding:14px;border-bottom:1px solid #d6dfd7;background:#f7faf5}.wb-material-picker p{font-size:12px;color:#52685b}.wb-material-choices{display:flex;gap:8px;flex-wrap:wrap;max-height:220px;overflow:auto}.wb-material-choices button{max-width:320px;padding:9px 12px;background:white;border:1px solid #b8cdbd;border-radius:10px;text-align:left}.wb-material-card{display:flex;flex-direction:column;gap:12px;justify-content:center;height:100%;padding:18px;color:#254c40;font:16px/1.4 Manrope,system-ui,sans-serif;overflow:hidden}.wb-material-card small{font-size:12px;color:#52685b}.wb-material-card strong{display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:2;overflow:hidden}.wb-material-card button{font-size:13px;min-height:36px;pointer-events:auto}.wb-material-card span{font-size:12px}.wb-upload-status{padding:0 14px;font-size:13px;color:#52685b}

/* Let documents use the lesson width and most of the available screen height. */
.cl-stage:has(.lesson-presentation){max-width:none;padding:16px}
.cl-stage:has(.lesson-presentation) .cl-stage-header{padding-bottom:12px;margin-bottom:12px}
.cl-stage:has(.lesson-presentation) .cl-stage-header h2{font-size:clamp(22px,2vw,30px)}
.presentation-viewport,.presentation-web-frame{height:calc(100dvh - 160px);min-height:560px;max-height:none}
.presentation-toolbar label{white-space:nowrap}
.lesson-presentation:fullscreen,.lesson-presentation.is-expanded{display:flex;flex-direction:column;width:100vw;height:100dvh;max-width:none;max-height:none;margin:0;border:0;border-radius:0;background:#f1f4f0}
.lesson-presentation.is-expanded{position:fixed;inset:0;z-index:10000}
.lesson-presentation:fullscreen .presentation-toolbar,.lesson-presentation.is-expanded .presentation-toolbar{flex-shrink:0}
.lesson-presentation:fullscreen .presentation-viewport,.lesson-presentation.is-expanded .presentation-viewport,.lesson-presentation:fullscreen .presentation-web-frame,.lesson-presentation.is-expanded .presentation-web-frame{flex:1;height:0;min-height:0;max-height:none}
body.presentation-expanded{overflow:hidden}
@media(max-width:600px){.cl-stage:has(.lesson-presentation){padding:10px}.presentation-viewport,.presentation-web-frame{height:calc(100dvh - 140px);min-height:400px}.presentation-toolbar [data-web-address]{flex-basis:100%;min-width:0}.presentation-toolbar [data-web-address] label{min-width:0}.presentation-toolbar [data-web-url]{min-width:0}}

/* Annotation coordinates follow the original page/image at every zoom. */
.annotation-surface{position:relative;width:max-content;max-width:none;margin:0 auto;line-height:0}
.annotation-surface>[data-annotation-layer]{position:absolute;inset:0;width:100%;height:100%;overflow:hidden;touch-action:none;pointer-events:none}
[data-annotation-layer] [data-annotation-node]{pointer-events:all;cursor:move}
[data-annotation-layer].is-editing{pointer-events:all;cursor:crosshair}
[data-annotation-layer].is-readonly,[data-annotation-layer].is-readonly [data-annotation-node]{pointer-events:none;cursor:default}
.annotation-toolbar{display:flex;flex-wrap:wrap;align-items:center;gap:6px;padding:8px 10px;background:#f8faf6;border-bottom:1px solid #d6dfd7;font-size:12px;line-height:1.4}
.annotation-tools{display:flex;align-items:center;flex-wrap:wrap;gap:5px}
.annotation-toolbar [hidden]{display:none!important}
.annotation-toolbar button{border:1px solid #c5d4c9;border-radius:7px;background:#fff;color:#254c40;font:inherit;min-height:32px;padding:5px 8px;cursor:pointer}
.annotation-toolbar button[aria-pressed=true]{background:#dcefe5;border-color:#2b7159}
.annotation-toolbar button:disabled{opacity:.5;cursor:default}
.annotation-toolbar label{display:flex;align-items:center;gap:5px}
.annotation-toolbar input[type=color]{width:28px;height:28px;border:0;background:transparent;padding:0}
.annotation-toolbar input[type=range]{width:65px;min-width:0}
.annotation-toolbar [data-annotation-status]{color:#5a6d61;font-size:11px;flex-basis:100%}
.annotation-stickers{display:flex;flex-wrap:wrap;gap:4px;max-height:145px;overflow:auto;flex-basis:100%}
.annotation-stickers button{padding:2px;width:52px;height:52px}.annotation-stickers svg{width:100%;height:100%}
.lesson-image-presentation{background:transparent;border:0;border-radius:0}
.lesson-image-presentation .annotation-surface{max-width:100%;margin:12px auto}
.lesson-image-presentation .cl-stage-image{margin:0;display:block;max-width:100%;height:auto;object-fit:fill}
.lesson-presentation:fullscreen .annotation-toolbar,.lesson-presentation.is-expanded .annotation-toolbar{flex-shrink:0;max-height:30vh;overflow:auto}
.lesson-audio{display:block;width:100%;max-width:680px;margin:16px auto}
.lesson-youtube{width:100%;aspect-ratio:16/9;min-height:200px;background:#111;border-radius:12px;overflow:hidden}
.lesson-youtube iframe{display:block;width:100%;height:100%;min-height:200px;border:0}

/* Inline documents grow with the lesson. Fullscreen keeps its own viewport. */
.cl-stage-scroll [data-presentation=pdf]:not(.is-expanded):not(:fullscreen)>.presentation-viewport {
  height:auto; min-height:0; overflow-x:auto; overflow-y:hidden; overscroll-behavior:auto;
}
.cl-stage-scroll [data-presentation=web]:not(.is-expanded):not(:fullscreen)>.presentation-web-frame {
  height:var(--web-content-height, 360px); min-height:0;
}
.cl-stage-scroll .lesson-presentation:not(.is-expanded):not(:fullscreen)>.presentation-annotation-controls { max-height:none; }

/* Drawing tools can be opened without taking the whole page on narrow screens. */
.presentation-annotation-controls { flex:0 1 auto; min-height:38px; max-height:35%; overflow:auto; background:#f8faf6; border-bottom:1px solid #d6dfd7; font-size:13px; line-height:1.5; }
.presentation-annotation-controls>summary { padding:9px 12px; cursor:pointer; color:#476b58; position:sticky; top:0; background:#f8faf6; z-index:1; }
.presentation-annotation-controls .annotation-toolbar { border-bottom:0; }

.catalog-picture {
  display:block; position:relative; width:100%; min-width:0; max-height:none; aspect-ratio:auto;
  padding:0; border:0; border-radius:12px; overflow:hidden; background:#f1f4f0; cursor:pointer;
}
.catalog-picture.cl-lesson-illustration { max-width:680px; margin-inline:auto; }
.catalog-picture.learn-question-picture { max-height:none; aspect-ratio:auto; }
.catalog-picture-art { display:block; overflow:hidden; line-height:0; }
.catalog-picture .catalog-picture-art img, .catalog-picture-dialog .catalog-picture-art img {
  display:block; width:100%; height:auto; max-height:none; aspect-ratio:auto; margin:0; border-radius:0;
}
.catalog-picture-marks { position:absolute; inset:0; width:100%; height:100%; pointer-events:none; }
.catalog-picture-marks [data-annotation-node] { pointer-events:none; }
.catalog-picture-label {
  position:absolute; bottom:8px; right:8px; padding:6px 11px; border-radius:8px;
  background:#fff; color:#254c40; box-shadow:0 1px 6px #0003; font-size:13px; font-weight:600; line-height:1.4;
}
.catalog-picture:focus-visible { outline:3px solid #2b7159; outline-offset:2px; }
.catalog-picture-dialog {
  box-sizing:border-box; width:min(960px,96vw); max-height:96dvh; padding:0; margin:auto; overflow:auto;
  border:1px solid #c5d4c9; border-radius:16px; background:#fff; color:#254c40;
}
.catalog-picture-dialog::backdrop { background:#16282099; }
.catalog-picture-dialog header { display:flex; align-items:center; justify-content:space-between; gap:12px; padding:10px 14px; }
.catalog-picture-sheet { padding:12px; background:#f1f4f0; }
.catalog-picture-sheet .annotation-surface { max-width:100%; }
.catalog-picture-dialog .catalog-picture-art img { width:auto; max-width:100%; max-height:65dvh; }
