.student-app{--student-accent:#411358;--student-soft:#f3edf8;--student-line:#e5dfeb;--student-muted:#685b73;--motion-out:cubic-bezier(.16,1,.3,1);color:#261c35;background:#fff}
.student-lesson[data-view=completion] .student-navigation{display:none}
.student-lesson[data-view=completion] .student-layout{display:block;background:#fffdf8}
.student-lesson[data-view=completion] .lesson-task,.student-lesson[data-view=completion] .lesson-workbench{display:none}
.student-lesson[data-view=completion] .student-footer>:not(.completion-footer):not(#lesson-navigation-status){display:none}
.student-completion{height:100%;overflow:auto;display:grid;grid-template-columns:minmax(0,1.08fr) minmax(0,1fr);align-items:start;gap:clamp(40px,7vw,100px);padding:clamp(28px,4vw,56px);max-width:1360px;margin:auto;scrollbar-gutter:stable}
.completion-story h2{font-size:clamp(42px,4.7vw,64px);line-height:1.03;letter-spacing:-.04em;color:#30113f;margin:0 0 24px;max-width:12ch}
.completion-story h2 em{position:relative;font-style:normal;isolation:isolate;white-space:nowrap}
.completion-story h2 em:after{content:'';position:absolute;z-index:-1;height:12px;bottom:3px;left:-2px;right:-5px;background:#ffdf66;border-radius:3px;transform-origin:left}
.completion-intro{font-size:16px;line-height:1.65;max-width:46ch;color:#65516e;margin-bottom:24px}
.completion-project{padding:22px 24px;background:#30113f;color:#fff;border-radius:16px}
.completion-project h3{font-size:24px;line-height:1.25;color:#fff;letter-spacing:-.02em}
.completion-project p{font-size:13px;line-height:1.7;margin-top:10px;color:#e7d5f2;overflow-wrap:anywhere}
.student-app .completion-project .button{background:#ffdf66;color:#30113f;border:0;margin-top:18px;justify-content:space-between;width:100%;box-shadow:0 4px 10px #00000024}
.student-app .completion-project .button:hover{background:#ffe98d}
.completion-progress{font-size:13px;line-height:1.65;margin:22px 0 12px;color:#604e6b}
.completion-journey{display:grid;grid-template-columns:repeat(6,minmax(0,1fr));gap:8px}
.completion-journey a{position:relative;display:flex;align-items:center;justify-content:center;min-height:44px;color:#604576;background:#f4edf9;border-radius:10px;text-decoration:none;font-size:13px;font-weight:600;transition:background 160ms,transform 160ms var(--motion-out)}
.completion-journey a:hover{background:#e9dbf3;transform:translateY(-2px)}
.completion-journey svg{display:none;width:20px;height:20px;stroke:currentColor;fill:none;stroke-width:2}
.completion-journey a.tasks-done{background:#d9efe1;color:#24583d}.completion-journey a.tasks-done span{display:none}.completion-journey a.tasks-done svg{display:block}
.completion-local{font-size:12px;line-height:1.7;color:#6b5777;margin-top:14px}
.student-app .project-export{background:#f0e8f5;color:#442054;border:0;justify-content:space-between;flex-shrink:0;min-height:44px;font-size:12px}
.resume-project{display:flex;align-items:center;justify-content:space-between;gap:24px;padding:18px 22px;margin-bottom:24px;background:#f6f0fa;border:1px solid #e5d8ed;border-radius:16px}
.resume-project h2{font-size:18px;margin:0 0 5px;color:#442054}
.resume-project p{font-size:13px;line-height:1.6;max-width:55ch;color:#65516e}
.student-app .resume-project .button{min-height:48px;white-space:nowrap;background:#fff;border-color:#cdb7dc;color:#442054}
#import-status:not(:empty){margin-top:10px;max-width:42ch;color:#442054}#import-status:empty{display:none}
.workspace-bottom.python-save{padding:8px 16px}
@media(max-width:700px){.resume-project{flex-direction:column;align-items:stretch;gap:14px;max-width:650px;margin-inline:auto}.student-app .resume-project .button{width:100%;justify-content:space-between;font-size:13px}.workspace-bottom.python-save>span{display:none}.python-save .project-export{width:100%}}
.completion-next{margin:0;min-width:0}
.completion-next>h3{font-size:30px;line-height:1.15;letter-spacing:-.03em;color:#30113f;margin:0 0 12px}
.completion-next>p{font-size:14px;line-height:1.65;color:#65516e;margin:0 0 20px}
.completion-next fieldset{border:0;padding:0;margin:0 0 22px;display:flex;flex-direction:column;gap:10px}
.next-project-choice{display:flex;align-items:center;gap:14px;min-height:58px;padding:14px 16px;margin:0;border:1px solid #d8cce1;border-radius:12px;background:#fff;cursor:pointer;color:#442054;font-size:15px;font-weight:600;line-height:1.4;transition:background 160ms,border-color 160ms}
.next-project-choice:hover{background:#f6f0fa;border-color:#9b7cab}.next-project-choice:has(input:checked){background:#efe4f8;border-color:#542078}
.next-project-choice input{appearance:auto;flex:none;width:22px;height:22px;margin:0;accent-color:#542078}
.next-project-choice span{flex:1}.next-project-choice svg{width:20px;height:20px;flex:none;fill:none;stroke:currentColor;stroke-width:1.8;transition:transform 180ms var(--motion-out)}
.next-project-choice:has(input:checked) svg{transform:translateX(3px)}
.completion-reflection,.completion-custom{display:block;font-size:14px;font-weight:600;color:#442054;margin:0 0 22px;line-height:1.6}
.completion-reflection>span{font-weight:400;color:#705d7b}
.completion-next input:not([type=radio]){display:block;width:100%;background:#fff;padding:12px 14px;min-height:48px;border:1px solid #c8b8d3;border-radius:10px;font-family:inherit;font-size:14px;font-weight:400;line-height:1.5;color:#30113f;margin-top:8px;caret-color:#542078}
.completion-next input::placeholder{color:#776682;opacity:1}
.completion-reception{display:flex;gap:14px;border-top:1px solid #e5dce9;padding-top:20px;margin:6px 0 20px}
.completion-reception>svg{flex:none;width:24px;height:24px;fill:none;stroke:#542078;stroke-width:1.6}
.completion-reception h4{font-size:15px;color:#442054;margin:0 0 6px}.completion-reception p{font-size:13px;line-height:1.7;color:#65516e;max-width:46ch}
.student-app .completion-receipt{background:#f0e8f5;border:0;color:#442054;width:100%;justify-content:space-between;font-size:13px}
.completion-next #completion-status{font-size:13px;line-height:1.7;margin:12px 0 0;color:#442054}.completion-next #completion-status:empty{display:none}
.completion-footer{grid-column:1/-1;display:flex;align-items:center;justify-content:space-between;gap:20px;width:100%}
.completion-footer>span{font-size:13px;color:#65516e}.completion-footer>.button{min-height:52px}.student-app .completion-footer>.button:first-child{background:#f0e8f5;color:#442054;border:0}
.student-lesson[data-view=completion] .completion-footer>.button{min-height:50px}
.student-app .completion-footer>.completion-idea{background:#fff;color:#442054;border:1px solid #d8cce1}
.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap;border:0}
@keyframes finish-underline{from{transform:scaleX(.1)}to{transform:scaleX(1)}}
@media(prefers-reduced-motion:no-preference){.student-lesson[data-view=completion] .completion-story h2 em:after{animation:finish-underline 650ms var(--motion-out) both}}
@media(max-width:800px){.student-completion{display:block;padding:30px 24px}.completion-story{max-width:600px;margin:auto}.completion-story h2{font-size:48px}.completion-next{max-width:600px;margin:38px auto 10px}.completion-footer>span{display:none}.completion-footer{gap:12px}.completion-footer>.button{font-size:12px;padding-inline:14px}}
@media(max-width:420px){.student-completion{padding:28px 20px}.completion-story h2{font-size:44px}.completion-next>h3{font-size:28px}.completion-project{padding:20px}.completion-intro{font-size:15px}.completion-footer>.button{gap:8px;padding-inline:12px}}
@media(max-width:600px){.student-lesson[data-view=completion] .completion-footer>.button:first-child{width:44px;min-width:44px;padding:8px}.completion-footer>.button:first-child span{display:none}.student-lesson .completion-footer>.button{font-size:12px;padding-inline:12px;gap:8px}.completion-footer{gap:10px}}
.student-app [hidden]{display:none!important}
.student-app .button{position:relative;isolation:isolate;overflow:hidden;min-height:46px;gap:10px;padding:11px 16px;border-radius:12px;font-size:13px;font-weight:700;white-space:normal;transition:background 160ms,box-shadow 160ms,transform 160ms var(--motion-out)}
.student-app .button svg,.student-app summary svg{width:18px;height:18px;flex-shrink:0}
.student-app .button:active{transform:translateY(2px) scale(.97);box-shadow:none}
.student-app .button:disabled{transform:none;box-shadow:none}
.student-app .button.primary{background:#542078;box-shadow:0 5px 12px #41135822}
.student-app .button.primary:hover{background:#66308d;box-shadow:0 7px 16px #41135830}
.button-ink{position:absolute;z-index:-1;pointer-events:none;border-radius:50%;background:currentColor;opacity:0;aspect-ratio:1}
.student-header{max-width:1240px;margin:auto;padding:24px 32px;display:flex;align-items:center;gap:24px;border-bottom:1px solid var(--student-line);font-size:14px}
.student-header img{display:block;width:158px}
.student-header>span{font-weight:600}
.student-header .lesson-length,.student-back{margin-left:auto;font-size:13px;color:var(--student-muted)}
.student-back{min-height:44px;display:flex;align-items:center;gap:8px;text-decoration:none}
.student-back svg{width:16px;height:16px}
.lesson-picker{width:100%;max-width:1320px;margin:0 auto;padding:32px 32px 20px}
.lesson-picker h1{font-size:42px;color:var(--student-accent);margin:0 0 24px}
.lesson-options{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:24px}
.lesson-option{display:flex;flex-direction:column;min-width:0;background:#f5effa;border-radius:24px;overflow:hidden}
.lesson-option[data-course=ps]{background:#edf7f3}.lesson-option[data-course=pp]{background:#fff2ec}
.lesson-option-heading{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:22px 24px}
.lesson-option-heading h2{font-size:20px;color:var(--student-accent);letter-spacing:-.02em}
.lesson-option-heading>span{font-size:12px;color:#685476;white-space:nowrap}
.course-art{height:222px;margin:0 14px;overflow:hidden;border-radius:16px;display:flex;align-items:center;justify-content:center;background:#291038}
.course-art img{display:block;width:100%;height:100%;object-fit:contain}
.lesson-option[data-course=pp] .course-art{background:#fff}.lesson-option[data-course=pp] .course-art img{object-fit:cover;object-position:top}
.lesson-option-content{display:flex;align-items:stretch;flex-direction:column;flex:1;gap:24px;padding:24px}
.lesson-option-content h3{font-size:22px;letter-spacing:-.02em;margin:0 0 12px}
.lesson-option-content p{font-size:14px;line-height:1.7;max-width:58ch}
.lesson-option-content>div>span{display:block;font-size:12px;color:var(--student-muted);margin-top:14px}
.lesson-option-content .button{margin-top:auto;min-height:54px;justify-content:space-between;border-radius:14px;font-size:14px}
.student-lesson{height:100dvh;min-height:0;display:flex;flex-direction:column;overflow:hidden;background:#f4f1f8}
.student-lesson .student-header{height:64px;min-height:64px;max-width:none;width:100%;margin:0;padding:8px 22px;gap:24px;background:#30113f;border:0;color:#fff}
.student-lesson .student-header>a:first-child{flex-shrink:0}
.student-lesson .student-header img{width:126px}
.lesson-identity{display:flex;align-items:center;gap:14px;min-width:0}
.lesson-identity>span{font-size:12px;color:#dac6e8;white-space:nowrap}
.lesson-identity>strong{font-size:16px;color:#fff;font-weight:700;letter-spacing:-.02em}
.student-header .lesson-duration{font-size:12px;color:#dac6e8;margin-left:auto;font-weight:400;white-space:nowrap}
.student-lesson .screen-button{min-height:44px;flex-shrink:0;padding:9px 13px;border:1px solid #76558a;background:#ffffff0c;color:#fff;font-size:12px;border-radius:10px}
.student-lesson .screen-button:hover{background:#ffffff20}
.student-lesson .student-back{margin-left:0;min-height:44px;color:#dac6e8;font-size:12px;white-space:nowrap}
.student-navigation{height:60px;min-height:60px;display:flex;align-items:center;justify-content:space-between;gap:20px;padding:6px 22px;background:#fff;border-bottom:1px solid var(--student-line)}
.navigation-caption{font-size:12px;font-weight:600;color:var(--student-accent);display:flex;align-items:center;gap:14px;white-space:nowrap}
.navigation-caption>span{font-size:12px;font-weight:400;color:var(--student-muted);font-variant-numeric:tabular-nums}
.student-navigation ol{display:flex;align-items:center;list-style:none;padding:0;margin:0;gap:8px}
.student-navigation li{position:relative}
.student-navigation li:not(:last-child):after{content:'';height:2px;width:8px;position:absolute;right:-8px;top:50%;background:#e5dbed}
.student-navigation li a{display:flex;align-items:center;justify-content:center;width:42px;height:42px;border:1px solid #ded3e6;border-radius:12px;color:#745d83;text-decoration:none;font-size:12px;font-weight:600;background:#fff;font-variant-numeric:tabular-nums;transition:background 160ms,color 160ms,transform 160ms var(--motion-out)}
.student-navigation li a:hover{background:var(--student-soft);border-color:#a88bb9;transform:translateY(-2px)}
.student-navigation li a:active{transform:scale(.92)}
.student-navigation li a[aria-current=step]{background:var(--student-accent);border-color:var(--student-accent);color:#fff;box-shadow:0 3px 8px #41135826}
.mobile-step-label{display:none}
.view-controls{position:relative;display:flex;gap:4px;padding:4px;border-radius:12px;background:#eee8f3;flex-shrink:0}
.view-controls:before{content:'';position:absolute;inset:4px auto 4px 4px;width:calc(50% - 4px);background:#fff;border-radius:9px;box-shadow:0 2px 6px #41135812;transition:transform 240ms var(--motion-out)}
.student-lesson[data-view=project] .view-controls:before{transform:translateX(100%)}
.view-controls button{z-index:1;display:flex;align-items:center;justify-content:center;gap:7px;background:none;border:0;min-height:36px;min-width:100px;padding:6px 12px;color:#786086;font-size:12px;font-weight:600;border-radius:9px}
.view-controls button[aria-pressed=true]{color:#411358}
.view-controls svg{width:17px;height:17px}
.student-layout{position:relative;width:100%;max-width:none;margin:0;padding:0;display:grid;grid-template-columns:380px minmax(0,1fr);gap:0;min-width:0;min-height:0;flex:1;overflow:hidden}
.student-lesson[data-view=project] .student-layout{grid-template-columns:0 minmax(0,1fr)}
.lesson-task{display:flex;flex-direction:column;min-width:0;min-height:0;background:#fbf8ff;border-right:1px solid var(--student-line);position:relative;overflow:hidden}
.student-lesson[data-view=project] .lesson-task{visibility:hidden}
.lesson-task-scroll{flex:1;min-height:0;overflow:auto;padding:24px 24px 28px;scrollbar-gutter:stable;overscroll-behavior-y:contain}
.student-position{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:16px;color:var(--student-muted);font-size:11px;font-variant-numeric:tabular-nums}
.student-position>span{font-weight:600;color:#75598b}
.student-position time{display:flex;align-items:center;gap:5px;white-space:nowrap}
.student-position svg{width:14px;height:14px}
.lesson-task h1{font-size:25px;line-height:1.2;letter-spacing:-.035em;color:var(--student-accent);margin:0;text-wrap:balance}
.student-intro{font-size:14px;line-height:1.7;color:var(--student-muted);margin:14px 0 20px;max-width:65ch}
.student-actions{list-style:none;counter-reset:instruction;padding:0;margin:0;display:grid;gap:17px}
.student-actions li{counter-increment:instruction;position:relative;padding:0;margin:0;font-size:14px;line-height:1.75;overflow-wrap:anywhere;color:#35273f}
.student-actions li:before{display:none;content:counter(instruction);position:absolute;left:0;top:1px;display:flex;align-items:center;justify-content:center;width:22px;height:22px;border-radius:6px;font-size:11px;font-weight:700;background:var(--student-soft);color:#674079}
.student-result{margin-top:24px;padding-top:20px;border-top:1px solid var(--student-line)}
.student-result h2,.student-question h2{font-size:14px;letter-spacing:-.01em;line-height:1.4;color:var(--student-accent);margin:0 0 8px}
.student-result p,.student-hint p{font-size:13px;line-height:1.75;color:#64546f}
.student-hint,.lesson-reference{margin-top:16px;border:1px solid #e5dced;border-radius:8px;background:#fcfaff;overflow:hidden}
.student-hint summary,.lesson-reference summary{display:flex;align-items:center;gap:9px;min-height:44px;padding:10px 12px;font-size:12px;font-weight:600;line-height:1.6;color:#603779;cursor:pointer;list-style:none}
.student-hint summary::-webkit-details-marker,.lesson-reference summary::-webkit-details-marker{display:none}
.student-hint summary:after,.lesson-reference summary:after{content:'';width:6px;height:6px;border-right:1.5px solid currentColor;border-bottom:1.5px solid currentColor;transform:rotate(45deg);margin-left:auto;flex-shrink:0}
.student-hint[open] summary:after,.lesson-reference[open] summary:after{transform:rotate(225deg)}
.hint-mark{display:flex;align-items:center;justify-content:center;border:1px solid #a88bb9;border-radius:50%;width:16px;height:16px;font-size:11px}
.student-hint p{margin:0;padding:0 12px 14px}
.scratch-blocks{display:grid;justify-items:start;gap:4px;margin:0;padding:8px 10px 14px;overflow:auto}
.scratch-block{white-space:pre-wrap;font-size:11px;font-weight:600;color:#fff;border-radius:4px;padding:8px 10px;max-width:100%;line-height:1.55}
.scratch-block.motion{background:#2466d0}.scratch-block.control{background:#815400}.scratch-block.events{background:#805900}.scratch-block.variables{background:#9e4600}.scratch-block.looks{background:#713fba}
.student-question{margin-top:24px;padding-top:20px;border-top:1px solid var(--student-line)}
.student-question fieldset{border:0;padding:0;margin:0 0 12px;min-width:0}
.student-question legend{font-size:13px;line-height:1.75;margin-bottom:12px;color:#35273f}
.student-question label{display:flex;align-items:flex-start;gap:10px;min-height:44px;padding:11px 10px;border:1px solid #e5dced;border-radius:7px;font-size:12px;font-weight:400;line-height:1.6;margin:0 0 8px;cursor:pointer}
.student-question label:has(input:checked){background:#f4eef9;border-color:#a886c0}
.student-question input{width:16px;height:16px;min-height:16px;flex-shrink:0;margin:1px 0 0;accent-color:var(--student-accent)}
.student-question .button{width:100%;font-size:12px;justify-content:center}
#answer-feedback{font-size:12px;line-height:1.75;margin-top:10px;color:var(--student-accent);min-height:20px}
#answer-feedback[data-result=correct]{color:#236747}
.student-footer{display:grid;grid-template-columns:1fr auto 1fr;align-items:center;gap:20px;flex-shrink:0;min-height:84px;padding:12px 22px max(12px,env(safe-area-inset-bottom));border-top:1px solid var(--student-line);background:#fff;position:relative;z-index:5}
.footer-back{justify-self:start}.footer-next{justify-self:end}
.student-footer .previous-step{background:#f3edf7;color:#624872;border:0;min-height:52px;padding:12px 18px;box-shadow:none}
.student-footer .previous-step:hover{background:#e8ddf0}
.student-footer .project-toggle{min-height:54px;padding:13px 24px;background:#ffdf66;color:#381148;border:0;box-shadow:0 4px 12px #b4841824;font-size:14px}
.student-footer .project-toggle:hover{background:#ffe88c;box-shadow:0 6px 16px #b4841830}
.student-footer .project-toggle svg{fill:currentColor;stroke-width:1.3}
.student-lesson[data-view=project] .project-toggle svg{fill:none}
.student-footer .next-step{min-height:56px;min-width:164px;padding:8px 8px 8px 24px;justify-content:space-between;gap:24px;border-radius:16px;font-size:14px}
.button-arrow{display:grid;place-items:center;flex-shrink:0;width:38px;height:38px;border-radius:11px;background:#ffffff20;transition:background 180ms,transform 180ms var(--motion-out)}
.next-step:hover .button-arrow{background:#ffdf66;color:#381148;transform:translateX(2px)}
#lesson-navigation-status{grid-column:1/-1;background:#fff5d4;font-size:12px;line-height:1.65;color:#73521a;padding:8px 12px;border:1px solid #ebdba5;border-radius:8px}
#lesson-navigation-status:empty{display:none}
.lesson-workbench{min-width:0;min-height:0;margin:0;border:0;border-radius:0;display:flex;flex-direction:column;overflow:hidden;background:#f4f1f8}
.workspace-heading{height:46px;min-height:46px;display:flex;align-items:center;justify-content:space-between;gap:16px;padding:4px 18px;border-bottom:1px solid var(--student-line);background:#f8f5fb;flex-shrink:0}
.workspace-heading>div{display:flex;align-items:center;gap:9px;min-width:0}
.workspace-heading h2{font-size:12px;font-weight:600;line-height:1.5;letter-spacing:0;color:#4e365f;overflow-wrap:anywhere}
.workspace-dot{width:7px;height:7px;border-radius:50%;background:#7b4a98;flex-shrink:0}
.workspace-caption{font-size:11px;color:var(--student-muted);padding-left:10px;border-left:1px solid #ddd1e6}
.workspace-heading .button{border:0;background:transparent;min-height:36px;padding:6px 0 6px 10px;font-size:11px;white-space:nowrap;box-shadow:none}
.workspace-heading .button:hover{color:#76469a}
.scratch-editor-scroll{flex:1;min-height:0;min-width:0;overflow:auto;overscroll-behavior-x:contain;background:#eaf0fb}
#scratch-editor{display:block;width:100%;min-width:800px;height:100%;min-height:400px;border:0}
.workspace-bottom{display:flex;align-items:center;justify-content:space-between;gap:10px;min-height:28px;flex-shrink:0;padding:5px 16px;background:#f8f5fb;border-top:1px solid var(--student-line);font-size:11px;line-height:1.5;color:#6b5b76}
.editor-pan-controls{display:flex;gap:6px;padding:6px 12px;background:#faf8fc;border-bottom:1px solid var(--student-line);flex-shrink:0}
.editor-pan-controls button{flex:1;border:1px solid #ddcfe7;border-radius:8px;padding:6px 8px;min-height:44px;background:#fff;color:#603779;font-size:12px;font-weight:600}
.editor-pan-controls button:active{background:#e5d7ee}
.scratch-editor-shell:fullscreen{width:100%;height:100dvh;min-height:0;background:#fff;display:flex;flex-direction:column;visibility:visible}
.scratch-editor-shell:fullscreen .scratch-editor-scroll{min-height:0;flex:1}
.scratch-editor-shell:fullscreen #scratch-editor{height:100%;min-height:400px}
.student-game{display:block;width:100%;height:100%;flex:1;min-height:0;margin:0;border:0;background:#271035}
.python-workspace-content{flex:1;min-height:0;overflow:auto;padding:24px;display:flex;flex-direction:column;gap:20px}
.student-example{display:flex;flex-direction:column;gap:12px;margin:0}
.example-controls{display:flex;align-items:center;flex-wrap:wrap;gap:10px}
.student-example>p,.student-files>p{font-size:13px;line-height:1.75;color:#685578}
.example-links{display:flex;flex-wrap:wrap;gap:10px}
.example-links .button{font-size:12px;background:#fff}
.student-files{display:flex;flex-wrap:wrap;gap:12px;align-items:center;margin:0}
.project-files{flex-basis:100%;display:flex;align-items:center;gap:0;flex-wrap:wrap;background:#fff;border:1px solid var(--student-line);border-radius:10px;padding:8px}
.project-files>*{display:flex;align-items:center;padding:12px 14px;font:12px Consolas,monospace;color:#745b88}
.project-files>strong{color:var(--student-accent);font-weight:600}
.code-document{overflow:hidden;border-radius:10px;border:1px solid #372a44;background:#231b2d;flex-shrink:0}
.code-document-header{display:flex;align-items:center;gap:14px;padding:8px 18px;min-height:44px;border-bottom:1px solid #42344f;color:#cbb9db;font-size:11px}
.copy-code{margin-left:auto;border:0;background:transparent;display:inline-flex;align-items:center;gap:6px;min-height:44px;padding:4px 0;color:#eddef9;font:12px Inter,sans-serif;cursor:pointer}
.copy-code svg{width:15px;height:15px}
.copy-code:hover{color:#fff}
#copy-status{font-size:11px;color:#c9e7d3}
.student-code{font:15px/1.85 Consolas,'Courier New',monospace;white-space:pre-wrap;overflow-wrap:anywhere;padding:28px;margin:0;color:#f1e8f8;background:transparent;border:0;min-height:150px;tab-size:4}
.student-code code{font:inherit;color:inherit}
.syntax-string{color:#e8ca84}.syntax-number{color:#93ddcf}.syntax-keyword{color:#d4adff}.syntax-comment{color:#aaa0b7}
.project-preview{display:flex;flex-direction:column;align-items:center;justify-content:center;flex:none;min-height:0;margin:0;border:1px solid #e6deed;border-radius:12px;background:#ede6f4;overflow:hidden}
.project-preview img{display:block;width:100%;height:auto;max-height:490px;object-fit:contain;min-height:0}
.project-preview figcaption{width:100%;padding:9px 14px;background:#faf8fc;font-size:11px;color:#6d5b7a;border-top:1px solid #e6deed;flex-shrink:0}
#poll-example{width:100%;height:100%;min-height:500px;flex:1;border:1px solid var(--student-line);border-radius:10px;background:#fff}
.lesson-task h1{font-size:28px;line-height:1.17;letter-spacing:-.035em;color:var(--student-accent);margin:0;text-wrap:balance}
.student-position{margin-bottom:18px}
.student-intro{font-size:14px;line-height:1.75;margin:16px 0 24px}
.student-actions{gap:12px}
.student-actions li{font-size:14px;line-height:1.8;padding:0}
.student-actions li:before{width:24px;height:26px;border-radius:8px;background:#eee5f5;font-size:12px}
.student-result{padding:18px;margin-top:26px;border:0;border-radius:12px;background:#eef6f0}
.student-result h2{color:#25593e;font-size:13px}
.student-result p{color:#3f6651;font-size:13px}
.student-question label{border-radius:10px;transition:background 160ms,border-color 160ms}
.student-question label:has(input:checked){background:#eee3f6;border-color:#8b57a7}
#answer-feedback[data-result=correct]{background:#eaf5ed;border-radius:10px;padding:12px;color:#236747}
.student-hint summary:focus-visible,.lesson-reference summary:focus-visible{outline:3px solid #9853bc;outline-offset:-3px}
.action-tracker{margin:0 0 16px}
.action-tracker>div{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:10px}
.action-tracker strong{font-size:14px;color:#442054}.action-tracker span{font-size:12px;font-weight:600;color:#70517f;font-variant-numeric:tabular-nums}
.action-tracker p{font-size:11px;color:#756082;margin-top:7px}
.action-pagination{display:flex;gap:8px;margin:0 0 12px}.action-pagination button{flex:1;min-height:44px;padding:7px 10px;border:1px solid #ddcde8;border-radius:11px;background:#fff;color:#765585;font-size:12px;font-weight:600}.action-pagination button[aria-pressed=true]{background:#542078;border-color:#542078;color:white}.action-pagination button:active{transform:scale(.97)}
#action-progress{appearance:none;display:block;border:0;width:100%;height:7px;border-radius:10px;background:#e9dff0;overflow:hidden}
#action-progress::-webkit-progress-bar{background:#e9dff0;border-radius:10px}#action-progress::-webkit-progress-value{background:#398561;border-radius:10px;transition:width 200ms var(--motion-out)}#action-progress::-moz-progress-bar{background:#398561;border-radius:10px}
.student-actions .action-check{position:relative;display:grid;grid-template-columns:28px minmax(0,1fr);align-items:start;gap:12px;padding:15px 14px;margin:0;border:1px solid #e1d4eb;background:#fff;border-radius:14px;cursor:pointer;transition:background 160ms,border-color 160ms}
.student-actions .action-check:hover{border-color:#a07bb6}.student-actions .action-check:has(input:checked){background:#eef8f0;border-color:#98c9a6}
.student-actions .action-copy{grid-column:2;grid-row:1;color:#3d2c46;font-size:14px;font-weight:400;line-height:1.7;overflow-wrap:anywhere}
.student-actions .action-check input{appearance:none;grid-column:1;grid-row:1;width:28px;height:28px;min-height:28px;margin:0;padding:0;border:2px solid #cfbddb;border-radius:9px;background:#fff;cursor:pointer}
.student-actions .action-check input:checked{background:#337850;border-color:#337850}
.action-tick{grid-column:1;grid-row:1;pointer-events:none;display:grid;place-items:center;width:28px;height:28px;color:white;opacity:0;transform:scale(.6);transition:opacity 120ms,transform 180ms var(--motion-out)}
.action-check input:checked~.action-tick{opacity:1;transform:scale(1)}.action-tick svg{width:20px;height:20px;stroke-width:2.5}
#action-status{margin-top:12px;font-size:12px;line-height:1.7;color:#2f7351}#action-status:empty{display:none}
.student-navigation li a.tasks-done:not([aria-current]){background:#edf6ef;border-color:#a8cfb2;color:#286344}
.python-playground{padding:20px 24px 0}
.code-input-label{font-size:12px;font-weight:400;color:#d1bedf;margin:0 0 12px}
.python-code-input{display:block;width:100%;margin:0;padding:16px;border:1px solid #62506e;border-radius:12px;background:#171120;color:#f4eaff;resize:vertical;min-height:120px;font:15px/1.8 Consolas,'Courier New',monospace;tab-size:4;caret-color:#ffe06b}
.python-code-input:focus-visible{outline:3px solid #e2b7ff;outline-offset:3px}
.python-run-controls{display:flex;align-items:center;flex-wrap:wrap;gap:10px;margin-top:16px}
.student-app .run-python{background:#9ee7ba;color:#183d28;border:0;min-height:48px;padding-inline:22px;box-shadow:0 4px 12px #00000020}.student-app .run-python:hover{background:#b7f0cb}.run-python svg{fill:currentColor}
.student-app .stop-python{background:#382741;border:1px solid #6c537c;color:#f2e3fb;min-height:48px}
#python-status{font-size:12px;color:#ddc9e9}.python-run-controls .stop-python:disabled{opacity:.4}
#python-output{margin:18px 0 0;padding:16px;min-height:76px;border-radius:12px;background:#130e1a;color:#c6e9d1;font:13px/1.7 Consolas,monospace;white-space:pre-wrap;overflow-wrap:anywhere}
#python-output[data-result=error]{color:#ffd5b6}
.python-transfer{font-size:11px;line-height:1.7;color:#c5b3d1;padding:12px 0 18px}
.python-workspace-content:has([data-python-playground]){display:grid;grid-template-columns:minmax(0,1.15fr) minmax(0,1fr);align-content:start;align-items:start;gap:18px}
.python-workspace-content:has([data-python-playground]) .code-document{min-width:0}
.python-live-preview{min-width:0;background:#fff;border-radius:14px;overflow:hidden;border:1px solid #e2d9ea}
.live-preview-heading{display:flex;justify-content:space-between;align-items:center;flex-wrap:wrap;gap:6px;padding:16px}
.student-lesson .python-live-preview .preview-edit{display:none;margin:0;min-height:44px;padding:8px 12px;font-size:11px}.live-preview-heading h3{font-size:16px;color:#411358}.live-preview-heading span{font-size:10px;color:#756082}
.game-readout{display:flex;justify-content:space-between;gap:8px;padding:12px;background:#eee6f5;color:#624873;font-size:10px}.game-readout strong{font-size:16px;color:#411358}
#python-game{display:block;width:calc(100% - 24px);max-width:360px;height:auto;margin:auto;border-radius:12px;touch-action:none;cursor:crosshair}
.python-live-preview .button{display:flex;margin:16px;min-height:48px}
.python-live-preview>p{font-size:12px;line-height:1.7;padding:0 16px 16px}
#python-vote-preview{display:block;width:100%;height:610px;border:0}
.python-playground{padding:16px 18px 0}.python-code-input{min-height:96px;font-size:14px;line-height:1.65;padding:12px}.python-run-controls{margin-top:12px}
@media(max-width:1200px){.python-workspace-content:has([data-python-playground]){display:flex;flex-direction:column;align-items:stretch}.python-workspace-content:has([data-python-playground])>.code-document,.python-workspace-content:has([data-python-playground])>.python-live-preview{width:100%;flex-shrink:0}.student-lesson .python-live-preview .preview-edit{display:inline-flex}}
@media(max-width:1000px){.lesson-options{grid-template-columns:1fr;max-width:650px;margin:auto}.lesson-option{border-radius:20px}.course-art{height:260px}.lesson-picker h1{text-align:center}.lesson-option-content{padding:24px}.student-actions .action-copy{font-size:15px}}
@media(max-width:600px){.lesson-option-heading{padding:20px}.course-art{height:220px;margin-inline:12px}.lesson-option-content{padding:20px}.lesson-option-content h3{font-size:22px}.lesson-option-content .button{width:100%;min-height:54px}.python-playground{padding:16px 14px 0}.python-code-input{font-size:14px;padding:13px}.python-run-controls{gap:8px}#python-status{flex-basis:100%;font-size:11px}.student-actions .action-copy{font-size:14px}.student-actions .action-check{padding:14px 12px}}
@media(hover:hover){.student-app .button:hover{transform:translateY(-2px)}.student-app .button:active{transform:translateY(1px) scale(.97)}}
@media(min-width:1600px){.student-layout{grid-template-columns:380px minmax(0,1fr)}.lesson-task-scroll{padding:32px}.student-actions li{font-size:15px}}
@media(max-width:1200px){.student-lesson .student-header{gap:18px}.student-lesson .student-back span,.student-header .lesson-duration{display:none}.student-lesson .student-back{margin-left:auto;width:44px;justify-content:center}.student-navigation{gap:12px}.navigation-caption{display:none}.student-navigation ol{gap:6px}.student-navigation li:not(:last-child):after{width:6px;right:-6px}.student-layout{grid-template-columns:330px minmax(0,1fr)}.lesson-task-scroll{padding:24px}}
@media(max-width:1000px){.student-lesson .student-header{height:60px;min-height:60px;padding:8px 16px;gap:16px}.student-lesson .student-header img{width:112px}.lesson-identity{display:block;flex:1}.lesson-identity>span{font-size:10px;display:block}.lesson-identity>strong{font-size:13px;display:block;line-height:1.6}.student-lesson .student-back{margin-left:0}.student-navigation{padding:6px 16px;gap:12px;height:60px;min-height:60px}.student-navigation ol{display:none}.mobile-step-label{display:block;flex:1;min-width:0;font-size:0;margin:0}.mobile-step-label select{display:block;width:100%;margin:0;min-height:44px;padding:10px 26px 10px 12px;font-size:12px;color:#563369;background:#fff;border:1px solid #d9c9e4;border-radius:10px;text-overflow:ellipsis}.view-controls button{min-height:36px;min-width:88px;padding:6px 10px}.student-layout,.student-lesson[data-view=project] .student-layout{display:grid;grid-template-columns:minmax(0,1fr)}.lesson-task,.lesson-workbench{grid-area:1 / 1;min-width:0;min-height:0}.lesson-task{z-index:1;border:0}.lesson-task-scroll{padding:28px 32px;max-width:720px;width:100%;align-self:center}.student-lesson:not([data-view=project]) .lesson-workbench{visibility:hidden;pointer-events:none}.student-lesson[data-view=project] .lesson-task{visibility:hidden;pointer-events:none}.student-lesson[data-view=project] .lesson-workbench{visibility:visible}.student-footer{min-height:80px;padding-inline:16px;gap:12px}.student-footer .previous-step{min-height:52px}.student-footer .project-toggle{min-height:52px;padding:12px 20px}.student-footer .next-step{min-height:54px}.workspace-heading .button{min-height:44px}.workspace-bottom{min-height:28px}.lesson-task h1{font-size:30px}.student-intro,.student-actions li{font-size:15px}}
@media(max-width:600px){.student-header{padding:18px 20px;gap:12px;flex-wrap:wrap}.student-header img{width:132px}.student-header>span{font-size:12px}.student-header .lesson-length{font-size:12px}.student-lesson .student-header{height:60px;min-height:60px;padding:7px 12px;gap:12px;flex-wrap:nowrap}.student-lesson .student-header img{width:94px}.lesson-identity>span{font-size:10px}.lesson-identity>strong{font-size:12px}.student-lesson .student-back{display:none}.student-lesson .screen-button{min-width:44px;width:44px;padding:10px}.screen-button span{display:none}.student-navigation{gap:8px;padding:6px 12px}.view-controls{gap:0;padding:4px}.view-controls button{min-width:70px;gap:5px;padding:6px}.view-controls svg{width:15px;height:15px}.view-controls:before{width:calc(50% - 4px)}.mobile-step-label select{font-size:11px;padding-left:9px}.lesson-task-scroll{padding:24px 22px 30px;scrollbar-gutter:auto}.lesson-task h1{font-size:29px}.student-intro{font-size:14px;margin:16px 0 24px}.student-actions li{font-size:14px}.student-footer{min-height:78px;padding:10px 12px max(10px,env(safe-area-inset-bottom));gap:8px}.student-footer .previous-step{width:44px;min-width:44px;min-height:50px;padding:10px}.previous-step span{display:none}.student-footer .project-toggle{font-size:12px;min-height:50px;padding:10px 13px;gap:7px;border-radius:13px}.student-footer .project-toggle svg{width:16px;height:16px}.student-footer .next-step{min-width:116px;min-height:50px;padding:6px 6px 6px 16px;gap:10px;font-size:13px;border-radius:13px}.button-arrow{width:32px;height:36px;border-radius:9px}.footer-next .next-step>span:first-child{max-width:90px}.workspace-heading{padding:3px 12px;gap:8px}.workspace-heading h2{font-size:11px}.workspace-caption{display:none}.workspace-heading .button{font-size:10px;gap:5px}.workspace-heading .button svg{width:15px;height:15px}.workspace-bottom{padding:5px 12px;font-size:10px}.python-workspace-content{padding:16px;gap:16px}.student-code{padding:22px 18px;font-size:13px;min-height:130px}.project-preview img{max-height:340px}.student-example .button{font-size:12px}.project-files>*{font-size:11px;padding:10px}.student-files>.button{width:100%;justify-content:center}.lesson-picker{padding:30px 20px 45px}.lesson-picker h1{font-size:32px;margin-bottom:25px}.lesson-option{padding:23px 0}.lesson-option-heading h2{font-size:21px}.lesson-option-heading>span{font-size:12px}.lesson-option-content{align-items:stretch;flex-direction:column;gap:20px}.lesson-option-content h3{font-size:16px}.lesson-option-content .button{min-width:0}.student-lesson .skip{left:12px}.student-lesson .skip:focus{top:6px}}
@media(max-width:360px){.student-footer .project-toggle{width:110px;padding:8px;gap:6px;font-size:11px;line-height:1.4}.student-footer .next-step{width:116px;min-width:0;padding-left:12px;gap:7px;font-size:12px}}
@media(max-height:500px) and (max-width:1000px){.student-lesson[data-view=project] .student-header,.student-lesson[data-view=project] .student-navigation,.student-lesson[data-view=project] .workspace-bottom{display:none}.student-footer{min-height:64px;padding-block:6px}.student-footer .project-toggle,.student-footer .previous-step{min-height:48px}.student-footer .next-step{min-height:50px}}
@media(max-height:600px) and (min-width:1001px){.student-lesson .student-header{height:52px;min-height:52px}.student-navigation{height:52px;min-height:52px}.student-footer{min-height:66px;padding-block:6px}.student-footer .next-step{min-height:50px}.student-footer .project-toggle{min-height:48px}.workspace-bottom{display:none}#scratch-editor{min-height:340px}}
@media(prefers-reduced-motion:reduce){html{scroll-behavior:auto}.student-app *, .student-app *:before,.student-app *:after{scroll-behavior:auto!important;animation-duration:.01ms!important;animation-iteration-count:1!important;transition:none!important}.student-app .button:hover,.student-app .button:active,.student-navigation li a:hover,.student-navigation li a:active,.next-step:hover .button-arrow{transform:none}.student-app .button:active{filter:brightness(.93)}}

.reference-source{white-space:pre-wrap;overflow-wrap:anywhere;background:#261b32;color:#f4eafa;padding:16px;border-radius:10px;font:12px/1.7 monospace;margin-top:12px}.vote-links{display:flex;gap:10px;flex-wrap:wrap;padding:0 16px 16px}.vote-links .button{font-size:11px;min-height:44px}
