
:root{--ink:#35483d;--green:#52755b;--cream:#f7f3e9;--muted:#858b7b}*{box-sizing:border-box}body{margin:0;background:var(--cream);color:var(--ink);font-family:"Microsoft JhengHei","PingFang TC",sans-serif}button,a,input{-webkit-tap-highlight-color:transparent}button{font:inherit;cursor:pointer;border:1px solid #dddeda;color:var(--ink);background:white;border-radius:12px;padding:11px 14px;transition:transform .15s,background .15s}button:hover{background:#eef2e8;transform:translateY(-2px)}button:focus-visible,a:focus-visible,input:focus-visible{outline:3px solid #e8a540;outline-offset:4px}button:disabled{opacity:.4;cursor:default;transform:none}header{height:90px;border-bottom:1px solid #dedfd3;max-width:1440px;margin:auto;display:flex;align-items:center;gap:30px;padding:0 5%}.brand{text-decoration:none;color:var(--ink);font-size:23px;font-weight:800;display:flex;align-items:center;gap:12px}.logo{display:grid;place-items:center;background:#e4b36d;border-radius:14px;font-size:36px;width:44px;height:44px}.tag{font-size:13px;color:var(--muted);flex:1}header button{background:transparent;font-size:13px}main{max-width:1340px;padding:0 36px;margin:auto}.intro{display:flex;align-items:center;justify-content:space-between;padding:43px 0 32px}.eyebrow{font-size:10px;letter-spacing:2px;font-weight:bold;color:#8c947f}h1{font-size:32px;letter-spacing:1px;margin:12px 0}h1 em{font-style:normal;color:#6b8765}.intro p{font-size:14px;color:#7e8677;margin:0}.doodle{font-size:66px;line-height:1;color:#d7a450;transform:rotate(10deg);margin-right:45px;text-align:center}.doodle span{display:block;font-size:12px;margin-top:10px;letter-spacing:3px}.workspace{display:grid;grid-template-columns:185px minmax(0,1fr) 240px;gap:24px;align-items:start}aside h2{font-size:12px;color:#a4ad97;letter-spacing:1px;margin:3px 0 20px}aside h2 span{color:var(--ink);font-size:17px;margin-left:9px}.scene-card{display:block;width:100%;padding:10px;margin-bottom:13px;text-align:left;background:#eeeee3;border:2px solid transparent;border-radius:16px}.scene-card.active{background:white;border-color:#6b8765;box-shadow:0 4px 14px #44563c0a}.scene-card svg{width:100%;height:94px;display:block;border-radius:8px;background:#f9f8f2}.scene-card strong{font-size:14px;display:block;margin:8px 2px 3px}.scene-card small{font-size:11px;color:var(--muted);margin:2px}.little-note{font-size:14px;line-height:1.9;margin:25px 5px;color:#818c70}.little-note span{font-size:12px}.paper-panel{background:white;border-radius:22px;padding:24px 27px 18px;box-shadow:0 5px 25px #514a3307;border:1px solid #e8e7de}.canvas-heading{display:flex;align-items:center;justify-content:space-between;margin-bottom:20px}.canvas-heading h2{font-size:20px;margin:6px 0 0}.paper-tag{font-size:11px;background:#f4f1e8;padding:7px 10px;border-radius:20px;color:#989077}#drawing{background:#fffcf6;border-radius:12px;overflow:hidden;border:1px solid #ebe7de}#drawing svg{width:100%;display:block;max-height:510px}.region{cursor:pointer;transition:fill .2s;outline:none}.region:hover> :first-child,.region:focus> :first-child{stroke:#e9ac49;stroke-width:5}.region .region-number{pointer-events:none;font-size:16px;fill:#6e7166;font-weight:600;paint-order:stroke;stroke:#fff;stroke-width:3px;stroke-linejoin:round}.region.hint> :first-child{animation:pulse .65s 3}.hide-numbers .region .region-number{display:none}.progress-row{display:flex;justify-content:space-between;font-size:11px;color:#7d8977;margin:19px 0 8px}.progress-track{height:6px;background:#eef0e7;border-radius:10px;overflow:hidden}#progress{height:100%;width:0;background:#92af7d;transition:width .3s}.canvas-actions{display:flex;justify-content:space-between;gap:5px;margin-top:17px}.canvas-actions button{font-size:12px;border:0;background:transparent;padding:9px 6px}.canvas-actions button:last-child{background:#eff3e8;color:#58744e;padding:9px 12px}.tools{background:#eeeede;border-radius:20px;padding:22px 18px}.mode-switch{display:flex;background:#e0e3d3;padding:4px;border-radius:12px;gap:3px}.mode-switch button{flex:1;padding:9px 2px;font-size:12px;border:0;background:transparent}.mode-switch .active{background:white;box-shadow:0 2px 5px #00000008}#mode-help{font-size:11px;line-height:1.8;color:#828b74;margin:17px 0}#palette{display:grid;grid-template-columns:repeat(3,1fr);gap:12px 10px}.swatch{border:3px solid transparent;padding:4px;background:transparent;border-radius:16px;position:relative}.swatch.active{border-color:#52755b;background:#fff}.swatch span{display:grid;place-items:center;background:var(--color);height:43px;border-radius:10px;font-size:15px;font-weight:800;color:#25382e;box-shadow:inset 0 0 0 1px #00000009}.swatch small{font-size:9px;display:block;margin-top:5px;white-space:nowrap}.selected-note{font-size:12px;border-top:1px solid #d9ddcc;margin-top:20px;padding-top:17px}.number-toggle{font-size:12px;display:flex;align-items:center;gap:6px;margin:17px 0}.number-toggle input{accent-color:#5c7d58;width:17px;height:17px}.tip{display:flex;gap:9px;font-size:11px;line-height:1.9;color:#869078;border-top:1px dashed #cdd3c1;padding-top:15px}.tip p{margin:0}.status{text-align:center;font-size:13px;color:#708267;min-height:20px;margin:24px 0}footer{display:flex;justify-content:space-between;border-top:1px solid #e0e2d6;font-size:11px;color:#929985;padding:20px 0 25px}dialog{border:0;border-radius:20px;max-width:90vw;padding:28px;color:var(--ink);box-shadow:0 20px 100px #0003}dialog::backdrop{background:#263c3260}dialog h2{font-size:20px}dialog p{font-size:14px}dialog div{display:flex;gap:10px;justify-content:flex-end;margin-top:24px}#confirm-reset{background:#52755b;color:white}#celebration{position:fixed;inset:0;pointer-events:none;overflow:hidden}.confetti{position:absolute;top:-20px;width:12px;height:18px;animation:fall 2.7s ease-in forwards}@keyframes fall{to{transform:translateY(110vh) rotate(560deg)}}@keyframes pulse{50%{fill:#f3ce77;stroke:#cc8c31;stroke-width:6}}@media(min-width:1500px){main{padding-top:12px}}@media(max-width:1050px){.workspace{grid-template-columns:145px minmax(0,1fr) 205px;gap:14px}main{padding:0 22px}.paper-panel{padding:18px}.tools{padding:18px 12px}.swatch small{font-size:8px}}@media(max-width:780px){header{height:72px;padding:0 20px}.brand{font-size:20px}.tag,.doodle{display:none}header button{margin-left:auto;font-size:11px;padding:9px}main{padding:0 16px}.intro{padding:25px 0}h1{font-size:25px}.intro p{font-size:12px;line-height:1.8}.workspace{grid-template-columns:1fr}.library h2{margin-bottom:10px}#scenes{display:grid;grid-template-columns:repeat(3,1fr);gap:8px}.scene-card{margin:0;padding:6px}.scene-card svg{height:62px}.scene-card strong{font-size:12px}.scene-card small{font-size:9px}.little-note{display:none}.paper-panel{padding:17px}.tools{padding:18px}.tools h2{margin-bottom:12px}#palette{grid-template-columns:repeat(6,1fr);gap:4px}.swatch{padding:3px;border-radius:12px}.swatch span{height:38px}.swatch small{font-size:9px}.mode-switch{max-width:280px}#mode-help{margin:10px 0}.selected-note{margin-top:12px;padding-top:12px}.tip{display:none}.number-toggle{margin-bottom:0}footer{font-size:10px;gap:12px;line-height:1.8}.paper-tag{font-size:10px}.canvas-actions button{font-size:11px}}@media(prefers-reduced-motion:reduce){*,*::before,*::after{animation:none!important;transition:none!important}}

.collection-switch{display:flex;gap:4px;margin-bottom:12px;background:#e5e8db;padding:4px;border-radius:12px}.collection-switch button{flex:1;padding:9px 2px;font-size:12px;background:transparent;border:0}.collection-switch button.active{background:white}.scene-card[hidden]{display:none!important}#scenes{max-height:560px;overflow-y:auto;scrollbar-width:thin;padding-right:5px} @media(max-width:780px){#scenes{display:flex;overflow-x:auto;overflow-y:hidden;max-height:none;padding:2px 2px 10px;scroll-snap-type:x proximity}.scene-card{flex:0 0 125px;scroll-snap-align:start}.collection-switch{max-width:280px}}
.collection-switch{flex-wrap:wrap}.collection-switch button{flex:1 1 100%;text-align:left;padding:10px}.story-intro{font-size:13px;line-height:1.9;color:#76826b;background:#f4f5eb;border-radius:10px;padding:10px 13px;margin:-3px 0 16px}.story-intro[hidden]{display:none}@media(max-width:780px){.collection-switch{max-width:none;flex-wrap:nowrap}.collection-switch button{flex:1 1 0;text-align:center;padding:10px 3px;font-size:11px}}
@media(max-width:780px){.collection-switch{display:grid;grid-template-columns:repeat(2,minmax(0,1fr))}}
.story-audio{background:#f1f4eb;border:1px solid #dce4d2;border-radius:14px;padding:14px;margin-bottom:16px}.story-audio[hidden]{display:none}.story-audio-buttons{display:flex;gap:8px;flex-wrap:wrap}.story-audio-buttons button{font-size:13px;min-height:44px}.story-audio-buttons button:first-child{background:#52755b;color:white;border-color:#52755b}.story-audio-settings{display:flex;gap:12px;flex-wrap:wrap;margin-top:12px}.story-audio-settings label{font-size:12px;display:flex;align-items:center;gap:5px;min-width:0}.story-audio-settings select{max-width:220px;min-height:36px;border:1px solid #ccd6c5;border-radius:8px;background:white;padding:4px;color:#35483d}.story-audio p{font-size:12px;line-height:1.9}.story-audio summary{cursor:pointer;font-size:13px;padding:6px 0}.story-audio small{font-size:10px;color:#7a8471;display:block;margin-top:9px}.story-audio select:focus-visible{outline:3px solid #e8a540;outline-offset:2px}@media(max-width:480px){.story-audio-settings{display:grid;grid-template-columns:1fr}.story-audio-settings select{max-width:calc(100vw - 130px)}}
.photo-open{width:100%;background:#52755b;color:#fff;margin-bottom:12px;min-height:44px}.photo-open:hover{background:#42654b}[hidden]{display:none!important}.swatch span{color:var(--swatch-ink,#25382e)}#photo-dialog{width:560px;max-height:90vh;overflow:auto}#photo-dialog p{line-height:1.8}.photo-file-label{display:block;font-size:14px;padding:12px;background:#eef2e8;border-radius:10px}.photo-file-label input{display:block;max-width:100%;margin-top:9px}#photo-preview{max-width:100%;max-height:230px;display:block;object-fit:contain;margin:14px auto}#photo-preview:not([src]){display:none}.photo-density-label{display:flex;align-items:center;gap:10px;font-size:13px}.photo-density-label select{padding:10px;border:1px solid #ccd6c5;border-radius:8px;max-width:75%;background:white;color:#35483d}#photo-dialog .photo-note{font-size:12px;color:#728066}#photo-build{background:#52755b;color:white}#photo-dialog div{flex-wrap:wrap}#photo-reference{margin:0 0 15px;border:1px dashed #cdd7c5;border-radius:12px;padding:10px;font-size:13px}#photo-reference summary{cursor:pointer;padding:5px}#photo-reference-image svg{width:100%;max-height:260px}.photo-canvas .region .region-number{font-size:12px}
.poem-panel{margin:0 0 16px;border:1px solid #e2d7bc;background:#fffaf0;padding:17px;border-radius:14px}.poem-panel>p{margin:0 0 10px;font-size:12px;color:#8c7d5c}#poem-lines{white-space:pre-line;text-align:center;font-family:"Microsoft JhengHei",serif;line-height:1.9;font-size:19px;letter-spacing:2px}.poem-panel details{margin-top:13px;font-size:12px;line-height:1.9}.poem-panel summary{cursor:pointer}.poem-panel a{color:#52755b}.poem-panel[hidden]{display:none}@media(max-width:480px){#poem-lines{font-size:17px;letter-spacing:1px}}

/* Keep fillable letter glyphs visible when number labels are hidden. */
#drawing .alphabet-glyph{pointer-events:visiblePainted;stroke-width:1.7px;fill:inherit}#drawing.hide-numbers .alphabet-glyph{display:block;opacity:1} .alphabet-glyph{font-family:Arial,sans-serif}

#zhuyin-syllable{font-size:32px;letter-spacing:6px;padding:8px}#zhuyin-syllable mark{background:#f5d77d;color:#35483d;border-radius:8px;padding:4px}.zhuyin-glyph{fill:inherit;stroke-width:1.5px;pointer-events:visiblePainted}

.care-bar{display:flex;align-items:center;flex-wrap:wrap;gap:16px;background:#eaf0df;border:1px solid #cbd8bc;border-radius:16px;padding:18px;margin-bottom:24px}.care-bar>div{flex:1;min-width:220px}.care-bar p{font-size:13px;line-height:1.8;margin:6px 0}.care-bar b,.care-clock strong{font-variant-numeric:tabular-nums}.care-bar label{font-size:13px}.care-bar select{padding:10px;border-radius:8px;border:1px solid #b9c8af;background:white;font:inherit}.care-bar details{flex-basis:100%;font-size:13px;line-height:1.8}.care-bar summary{cursor:pointer}.care-bar a{color:#365d42}.care-bar button,#care-resume{background:#52755b;color:white;min-height:44px}#care-dialog{width:520px;max-height:90vh;overflow:auto}#care-dialog p{line-height:1.9}.care-clock strong{display:block;font-size:40px;margin-top:8px}#care-dialog::backdrop{background:#263c32bd}
