:root{color-scheme:dark;--bg:#17231f;--sidebar:#121c19;--surface:#202e27;--surface-hover:#29392f;--paper:#24322b;--text:#e8e5d9;--muted:#9da79a;--subtle:#758374;--line:#344237;--accent:#e4c48c;--ink:#26372d;--input:#1a2821;--hero:#2c4236;--shadow:0 18px 60px #08130d26;--serif:'Songti SC','Noto Serif CJK SC','STSong','SimSun',serif;--sans:-apple-system,BlinkMacSystemFont,'PingFang SC','Microsoft YaHei',sans-serif}
:root[data-theme=paper]{color-scheme:light;--bg:#f7f4ed;--sidebar:#eeece3;--surface:#fffdf6;--surface-hover:#efeee3;--paper:#fffdf6;--text:#34463a;--muted:#7a8376;--subtle:#969e90;--line:#dfdfd2;--accent:#42634c;--ink:#fff9e9;--input:#f5f2e9;--hero:#e6e9d9;--shadow:0 18px 60px #343e2910}
*{box-sizing:border-box}html{scroll-behavior:smooth;scroll-padding-top:30px}body{margin:0;font-family:var(--sans);font-size:14px;line-height:1.65;background:var(--bg);color:var(--text);-webkit-font-smoothing:antialiased}a{color:inherit;text-decoration:none}button,input,textarea,select{font:inherit}button{cursor:pointer;color:inherit}button:disabled{cursor:wait;opacity:.48}button,a,input,textarea,select{outline-offset:4px}button:focus-visible,a:focus-visible,input:focus-visible,textarea:focus-visible,select:focus-visible{outline:2px solid var(--accent)}button{background:none;border:0}input,textarea,select{color:var(--text);background:var(--input);border:1px solid var(--line);border-radius:9px;padding:12px 14px;width:100%;transition:border .2s}textarea{resize:vertical;line-height:1.8}input::placeholder,textarea::placeholder{color:var(--subtle)}select{cursor:pointer}input[type=checkbox],input[type=radio]{width:auto;accent-color:var(--accent)}h1,h2,h3,p{margin:0}h1,h2,h3{font-weight:500}h1,h2{font-family:var(--serif)}.icon{flex-shrink:0;vertical-align:middle}.button{display:inline-flex;align-items:center;justify-content:center;gap:10px;min-height:46px;padding:11px 20px;border-radius:9px;line-height:1.5;font-size:14px;font-weight:500;transition:transform .2s,background .2s}.button:hover:not(:disabled){transform:translateY(-1px)}.primary{background:var(--accent);color:var(--ink)}.secondary{border:1px solid var(--line);background:var(--surface)}.secondary:hover{background:var(--surface-hover)}.full{width:100%}.text-button{display:inline-flex;align-items:center;justify-content:center;gap:6px;font-size:12px;padding:10px 3px;color:var(--muted)}.text-button:hover{color:var(--accent)}.icon-button{display:inline-flex;align-items:center;justify-content:center;width:36px;height:36px;border:1px solid var(--line);border-radius:8px;font-size:15px;background:var(--surface)}.icon-button:hover{background:var(--surface-hover)}.muted{color:var(--muted)}.eyebrow{font-size:10px;letter-spacing:2px;color:var(--muted);font-weight:500}.sr-only{position:absolute;width:1px;height:1px;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}.initial-loading{height:100vh;display:grid;place-content:center;color:var(--accent)}
.sidebar{position:fixed;left:0;top:0;bottom:0;width:236px;background:var(--sidebar);border-right:1px solid var(--line);padding:36px 23px;display:flex;flex-direction:column;z-index:10}.brand{display:flex;align-items:center;gap:12px;font-family:var(--serif);font-size:21px;letter-spacing:1px;white-space:nowrap}.brand-mark{width:40px;height:44px;display:grid;place-items:center;background:var(--surface);border:1px solid var(--line);border-radius:13px;color:var(--accent)}.brand-mark .icon{width:23px;height:23px}.brand small{display:block;font-family:var(--sans);font-size:10px;color:var(--muted);letter-spacing:1px;margin-top:1px}.sidebar-caption{color:var(--subtle);font-size:10px;letter-spacing:1.3px;margin:23px 0 32px 3px}.sidebar nav{display:flex;flex-direction:column;gap:8px}.sidebar nav a{display:flex;align-items:center;gap:11px;padding:12px;border-radius:8px;color:var(--muted);font-size:13px;white-space:nowrap}.sidebar nav a.active{background:var(--surface);color:var(--accent)}.sidebar nav a:hover{background:var(--surface)}.nav-count{margin-left:auto;font-size:10px;border:1px solid var(--line);border-radius:5px;padding:0 5px}.sidebar-new{display:flex;gap:8px;align-items:center;justify-content:center;border:1px solid var(--line);border-radius:8px;padding:11px 6px;margin-top:28px;color:var(--accent);font-size:12px}.sidebar-new:hover{background:var(--surface)}.sidebar-bottom{margin-top:auto}.little-note{font-family:var(--serif);color:var(--subtle);font-size:14px;line-height:2;margin:40px 8px 24px}.theme-toggle,.connection{display:flex;align-items:center;gap:9px;font-size:11px;color:var(--muted);padding:8px 5px}.status-dot{display:inline-block;width:6px;height:6px;border-radius:50%;background:var(--subtle);flex-shrink:0}.status-dot.ready{background:#9ba985;box-shadow:0 0 0 3px #91a17515}.workspace{margin-left:236px}.topbar{height:77px;display:flex;align-items:center;justify-content:space-between;border-bottom:1px solid var(--line);padding:0 44px;color:var(--muted);font-size:11px;letter-spacing:.5px}.topbar>span{display:flex;gap:8px;align-items:center}.topbar .icon{width:14px;height:14px}.topbar-right{color:var(--subtle)}#main{max-width:1400px;margin:auto;padding:38px 44px 60px}.footer{border-top:1px solid var(--line);padding:24px 44px;font-size:10px;letter-spacing:.6px;color:var(--subtle);display:flex;justify-content:space-between;gap:16px}.hero{position:relative;display:flex;min-height:330px;border-radius:16px;background:var(--hero);overflow:hidden;padding:40px 42px;align-items:center;border:1px solid #8594791a}.hero-copy{position:relative;z-index:1;flex:1;min-width:330px}.hero .eyebrow{color:#aabb9b;font-size:9px;letter-spacing:2.4px}.hero h1{font-size:43px;line-height:1.4;font-weight:500;letter-spacing:2px;margin:15px 0 15px;color:#f1e8ce}.hero p{font-size:12px;line-height:1.9;color:#bcc8b2}.hero .button{margin-top:24px;font-size:12px;min-height:43px;background:#e4c48c;color:#29372a}.hero-art{width:48%;max-width:470px;align-self:stretch;display:flex;flex-direction:column;justify-content:center;align-items:center;position:relative;right:-16px}.story-art{width:100%;height:auto;display:block}.art-caption{font-family:var(--serif);font-size:12px;color:#adba9e;margin-top:8px;letter-spacing:2px}:root[data-theme=paper] .hero{background:#30463b}:root[data-theme=paper] .hero .eyebrow{color:#b0bea4}.continue-banner{margin:28px 0 36px;display:flex;align-items:center;gap:19px;padding:22px 26px;background:var(--surface);border:1px solid var(--line);border-radius:11px;transition:border-color .2s}.continue-banner:hover{border-color:var(--accent)}.reading-emblem{width:45px;height:51px;border:1px solid var(--line);border-radius:7px;display:grid;place-items:center;color:var(--accent);background:var(--input)}.reading-emblem .icon{width:24px;height:24px}.continue-banner .eyebrow{font-size:9px;letter-spacing:1.3px}.continue-banner h3{font-family:var(--serif);font-size:19px;margin:3px 0}.continue-banner p{font-size:11px;color:var(--muted)}.continue-label{margin-left:auto;display:flex;align-items:center;gap:12px;font-size:12px;color:var(--accent)}.continue-label .icon{width:16px}.section-heading{display:flex;align-items:end;justify-content:space-between;gap:18px;margin-bottom:22px}.section-heading h2{font-size:25px;margin-top:3px;letter-spacing:1px}.section-heading .muted{font-size:11px}.book-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:25px}.book-card{display:block}.cover{position:relative;aspect-ratio:1.2;background:#526250;color:#ede9d5;border-radius:5px 12px 12px 5px;padding:24px 25px 22px 32px;box-shadow:inset 5px 0 0 #263b2e44,inset 8px 0 0 #dfdbba12;transition:transform .25s;overflow:hidden}.cover-travel .cover{background:#53666a;color:#e4e6db}.cover-fantasy .cover{background:#5b5870;color:#e7e0d6}.cover-adventure .cover{background:#846b51;color:#f0e4c9}.book-card:hover .cover{transform:translateY(-5px)}.cover-kicker{font-size:9px;letter-spacing:2px;opacity:.7}.cover h3{font-family:var(--serif);font-size:25px;line-height:1.5;max-width:170px;margin-top:12px;letter-spacing:1px}.cover-scene{display:flex;align-items:center;justify-content:center;gap:13px;margin-top:23px;color:inherit;opacity:.8}.cover-scene>.icon{width:34px;height:34px;stroke-width:1}.cover-scene span{font-size:11px;letter-spacing:2px}.cover-line{border-bottom:1px solid #e5e5c82e;margin-top:20px}.cover-number{display:block;font-size:8px;letter-spacing:2px;margin-top:12px}.book-info{padding:15px 1px 0}.book-info h3{font-size:15px}.book-info p{font-size:11px;line-height:1.8;color:var(--muted);margin:7px 0 10px;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}.book-info>span{font-size:10px;color:var(--subtle);display:flex;align-items:center;justify-content:space-between}.book-info .icon{width:14px;height:14px}.new-book-card{border:1px dashed var(--line);border-radius:10px;display:flex;flex-direction:column;align-items:center;justify-content:center;min-height:270px;align-self:start;aspect-ratio:1.2;transition:background .2s}.new-book-card:hover{background:var(--surface)}.new-book-card>span{display:grid;place-items:center;width:45px;height:45px;border-radius:50%;border:1px solid var(--line);color:var(--accent);margin-bottom:15px}.new-book-card h3{font-family:var(--serif);font-size:20px}.new-book-card p{font-size:11px;line-height:1.9;color:var(--muted);margin-top:10px}.inspiration-section{margin-top:45px}.inspiration-grid{display:grid;grid-template-columns:1fr 1fr;gap:12px}.inspiration{display:flex;align-items:center;text-align:left;gap:15px;border:1px solid var(--line);border-radius:10px;padding:19px;background:var(--surface)}.inspiration:hover{background:var(--surface-hover)}.inspiration-icon{color:var(--accent);border:1px solid var(--line);border-radius:9px;padding:9px}.inspiration h3{font-size:13px;margin-bottom:4px}.inspiration p{font-size:10px;color:var(--muted)}.inspiration>.icon{margin-left:auto;width:14px;color:var(--subtle)}
.reader-top{display:flex;justify-content:space-between;align-items:center;margin-bottom:26px}.back-link{display:flex;align-items:center;gap:9px;color:var(--muted);font-size:12px}.back-link .icon{width:16px}.reader-actions{display:flex;gap:8px}.reader-layout{display:grid;grid-template-columns:166px minmax(300px,1fr) 260px;gap:27px;align-items:start}.chapter-sidebar{position:sticky;top:28px}.chapter-sidebar h2{font-size:20px;line-height:1.6;margin:9px 0}.chapter-sidebar>p{font-size:11px;line-height:1.9;color:var(--muted)}.chapter-list{margin-top:25px;border-top:1px solid var(--line);padding-top:15px}.chapter-list summary{font-size:11px;color:var(--subtle);cursor:pointer;padding-bottom:12px}.chapter-list summary span{float:right;font-size:10px}.chapter-link{display:flex;gap:8px;font-size:11px;padding:12px 9px;margin:3px -8px;border-radius:6px;line-height:1.7;color:var(--muted)}.chapter-link>span{font-size:10px;color:var(--subtle);padding-top:1px}.chapter-link small{display:block;font-size:9px;color:var(--subtle);margin-top:3px}.chapter-link.selected{background:var(--surface);color:var(--accent)}.chapter-link:hover{background:var(--surface)}.chapter-note{display:block;font-size:9px;line-height:1.9;color:var(--subtle);margin-top:30px;border-top:1px solid var(--line);padding-top:17px}.chapter-note .icon{width:12px;height:12px;margin-right:5px}.reading-paper{background:var(--paper);border:1px solid var(--line);border-radius:4px 13px 13px 4px;padding:27px 38px 25px;box-shadow:var(--shadow)}.paper-topline{display:flex;justify-content:space-between;font-size:9px;color:var(--subtle);letter-spacing:1px;border-bottom:1px solid var(--line);padding-bottom:15px}.paper-topline span{font-size:8px}.chapter-number{font-size:9px;letter-spacing:2.5px;color:var(--muted);text-align:center;margin-top:38px}.reading-paper h1{font-size:30px;line-height:1.55;text-align:center;margin:14px -4px}.chapter-meta{display:flex;gap:14px;justify-content:center;flex-wrap:wrap;font-size:9px;color:var(--subtle)}.chapter-meta>span:before{content:'·';padding-right:14px}.paper-divider{color:var(--subtle);text-align:center;font-size:11px;margin:28px 0}.prose{font-family:var(--serif);font-size:17px;line-height:2.15;letter-spacing:.3px;overflow-wrap:anywhere}.prose p{margin:0 0 1.2em}.prose h2,.prose h3,.prose h4{font-size:1.2em;margin:1.6em 0 .7em}.prose a{color:var(--accent);text-decoration:underline;text-underline-offset:4px}.prose blockquote{border-left:2px solid var(--accent);margin:1em 0;padding-left:1em;color:var(--muted)}.prose hr{border:0;border-top:1px solid var(--line);margin:2em 0}.end-flourish{font-family:var(--serif);font-size:12px;color:var(--muted);text-align:center;margin:38px 0 25px;letter-spacing:2px}.saved-note{font-size:9px;color:var(--subtle);text-align:center;margin-top:25px}.saved-note .icon{width:12px;height:12px;margin-right:4px}.reference-list{border-top:1px solid var(--line);padding-top:12px;font-family:var(--sans);font-size:11px;color:var(--muted)}.reference-list summary{cursor:pointer}.reference-list a{display:block;margin-top:9px;color:var(--accent)}.reference-list .icon{width:12px}.chapter-pagination{display:flex;justify-content:space-between;align-items:center;font-size:10px;color:var(--muted);padding:23px 2px}.chapter-pagination a{display:flex;align-items:center;gap:8px}.chapter-pagination .icon{width:15px}.versions{font-size:11px;border:1px solid var(--line);border-radius:8px;padding:13px;color:var(--muted)}.versions summary{cursor:pointer}.versions summary .icon{width:13px;margin-right:6px}.versions a{display:block;padding:8px 0}.versions a>.icon{width:12px}.continuation-panel{position:sticky;top:28px}.continuation-header{display:flex;align-items:center;gap:8px;font-family:var(--serif);font-size:19px;color:var(--accent)}.continuation-header .icon{width:18px}.panel-intro{font-size:11px;color:var(--muted);line-height:1.9;margin:10px 0 20px}.suggestions{display:flex;flex-direction:column;gap:10px}.suggestion{position:relative;border:1px solid var(--line);background:var(--surface);text-align:left;border-radius:9px;padding:16px 18px 15px;transition:background .2s,border-color .2s}.suggestion:not(:disabled):hover{background:var(--surface-hover);border-color:var(--accent)}.suggestion-number{font-size:9px;letter-spacing:1px;color:var(--subtle);margin-bottom:4px;display:block}.suggestion strong{display:block;font-size:12px;font-weight:500;color:var(--text)}.suggestion p{font-size:10px;line-height:1.9;color:var(--muted);margin:7px 16px 0 0}.suggestion>.icon{position:absolute;right:14px;bottom:18px;width:13px;color:var(--subtle)}.or-divider{display:flex;align-items:center;gap:9px;font-size:9px;color:var(--subtle);margin:23px 0 17px;white-space:nowrap}.or-divider:before,.or-divider:after{content:'';height:1px;background:var(--line);flex:1}.continuation-panel textarea{font-size:11px;min-height:112px;padding:11px}.compose-options{margin:14px 0 10px;font-size:10px;color:var(--muted)}.compose-options label{display:flex;align-items:center;gap:8px}.compose-options select{font-size:10px;padding:8px;flex:1;width:auto}.checkbox-label{display:flex!important;align-items:center;gap:8px;font-size:11px;color:var(--muted);margin:12px 0 17px!important;cursor:pointer}.checkbox-label input{margin:0;width:14px;height:14px;flex-shrink:0}.continuation-panel .button{font-size:11px;padding:11px 7px;gap:7px}.continuation-panel .button>.icon{width:16px}.panel-footnote{font-size:9px;color:var(--subtle);line-height:1.9;border-top:1px solid var(--line);padding-top:17px;margin-top:12px}.empty-chapter{padding:40px 0;text-align:center}.empty-chapter>.icon{color:var(--accent);width:35px;height:35px}.empty-chapter h1{font-size:26px}.empty-chapter p{font-size:13px;margin-top:20px;line-height:2}.job-card{display:flex;gap:12px;border:1px solid var(--line);background:var(--surface);border-radius:9px;padding:16px;margin:15px 0}.job-card strong{font-size:12px;font-weight:500;color:var(--accent)}.job-card p{font-size:10px;color:var(--muted);margin-top:5px}.job-time{display:block;font-size:9px;color:var(--subtle);margin-top:9px}.job-error strong{color:#d9a18c}.job-error .text-button{margin-right:13px}.writing-light{flex-shrink:0;width:9px;height:9px;background:var(--accent);border-radius:50%;margin-top:6px;animation:breathe 2.5s ease-in-out infinite}.continuation-panel .job-card{padding:12px}.continuation-panel .job-card strong{font-size:10px}.continuation-panel .job-card p{font-size:9px}@keyframes breathe{50%{opacity:.3;box-shadow:0 0 12px 4px #d7bb7e24}}:root[data-font=large] .prose{font-size:21px;line-height:2.15}
.page-intro{padding:14px 0 28px}.page-intro h1{font-size:32px;margin:13px 0;line-height:1.5}.page-intro p{font-size:13px;color:var(--muted);line-height:2}.source-summary{display:flex;justify-content:space-between;align-items:center;margin-top:24px}.source-summary>span{display:flex;align-items:center;gap:10px;font-size:12px;color:var(--muted)}.source-summary strong{font-size:23px;color:var(--accent);font-weight:400}.source-summary .button{font-size:12px}.search-field{display:flex;align-items:center;gap:10px;border:1px solid var(--line);border-radius:9px;padding:0 15px;background:var(--input)}.search-field .icon{width:17px;color:var(--subtle)}.search-field input{border:0;background:none;font-size:12px;padding:14px 0}.search-field input:focus{outline:0}.search-field:focus-within{outline:2px solid var(--accent);outline-offset:3px}.results-count{font-size:11px;color:var(--subtle);margin:22px 0 14px}.source-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:15px}.source-card{padding:22px;text-align:left;background:var(--surface);border:1px solid var(--line);border-radius:10px;transition:background .2s}.source-card:hover{background:var(--surface-hover)}.source-collection{font-size:9px;color:var(--subtle);display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.source-card h3{font-family:var(--serif);font-size:17px;margin:12px 0;line-height:1.5}.source-card p{font-size:10px;color:var(--muted);display:-webkit-box;-webkit-line-clamp:3;-webkit-box-orient:vertical;overflow:hidden;line-height:1.9}.source-card>span:last-child{display:flex;justify-content:space-between;align-items:center;font-size:9px;color:var(--subtle);margin-top:17px}.source-card>span:last-child .icon{width:14px}.source-pagination{display:flex;align-items:center;justify-content:center;gap:20px;margin-top:25px;font-size:12px;color:var(--muted)}.source-pagination .button{font-size:11px;min-height:35px}.character-grid{display:grid;grid-template-columns:1fr 1fr;gap:18px;margin-top:10px}.character-card{display:flex;align-items:center;gap:20px;background:var(--surface);border:1px solid var(--line);border-radius:12px;padding:26px}.character-face{display:grid;place-items:center;border-radius:50%;width:66px;height:66px;background:#d2ad63;color:#6d5735;font-size:19px;position:relative;flex-shrink:0}.character-face:before{content:'••';position:absolute;top:8px;left:0;right:0;text-align:center;font-size:19px;letter-spacing:13px;padding-left:13px;color:#4d4534}.character-face:after{content:'';position:absolute;bottom:16px;width:14px;height:7px;background:#b3793f;border-radius:40%}.xiaomei .character-face{background:#e8c981}.xiaomei .character-face:after{bottom:auto;top:-3px;right:10px;background:#b57d72;width:17px;height:11px;transform:rotate(20deg);border-radius:2px}.character-card h2{font-size:20px;margin-bottom:7px}.character-card p{font-size:11px;line-height:1.9;color:var(--muted)}.preference-tags{display:flex;gap:10px;flex-wrap:wrap;margin:22px 0 35px}.preference-tags>span{display:flex;gap:7px;align-items:center;font-size:10px;border:1px solid var(--line);padding:6px 11px;border-radius:30px;color:var(--muted)}.preference-tags .icon{width:13px;height:13px}.preferences-editor h2{font-size:23px;margin-bottom:8px}.preferences-editor textarea{font-family:var(--sans);font-size:12px;line-height:2;min-height:500px}.editor-footer{display:flex;justify-content:space-between;gap:18px;align-items:center;margin-top:20px}.editor-footer>span{font-size:10px;color:var(--subtle)}
dialog{color:var(--text);background:var(--bg);border:1px solid var(--line);border-radius:16px;padding:37px;width:min(570px,calc(100vw - 28px));max-height:90dvh;overflow:auto;box-shadow:0 25px 100px #0006}dialog::backdrop{background:#0c150fc4;backdrop-filter:blur(5px)}.modal-close{position:absolute;right:16px;top:16px;border:0;background:none}.modal-close .icon{width:18px}.modal-intro{font-size:12px;color:var(--muted);margin:10px 0 25px}.modal-intro+form{margin-top:20px}dialog h2{font-size:28px;line-height:1.5;margin:9px 0}dialog form>label{display:block;font-size:12px;margin:17px 0 9px;color:var(--muted)}dialog label>input,dialog label>textarea,dialog label>select{margin-top:8px;font-size:12px}dialog textarea{min-height:110px}.theme-choices{display:grid;grid-template-columns:repeat(4,1fr);gap:9px}.theme-choices label{cursor:pointer;position:relative}.theme-choices input{position:absolute;opacity:0;width:1px;height:1px}.theme-choices span{display:flex;align-items:center;justify-content:center;flex-direction:column;gap:7px;border:1px solid var(--line);border-radius:8px;padding:13px 4px;font-size:10px;color:var(--muted)}.theme-choices input:checked+span{border-color:var(--accent);color:var(--accent);background:var(--surface)}.theme-choices input:focus-visible+span{outline:2px solid var(--accent);outline-offset:3px}.form-row{display:flex;gap:15px;margin-top:18px}.form-row label{display:block;flex:1;font-size:12px;color:var(--muted)}.optional-setting{font-size:10px;color:var(--muted);margin:21px 0}.optional-setting summary{cursor:pointer}.optional-setting p{font-size:10px;line-height:1.9}.optional-setting .checkbox-label{margin:13px 0 5px!important}.form-note{font-size:10px;color:var(--subtle);text-align:center;margin-top:13px}.source-modal{width:min(800px,calc(100vw - 28px));padding:42px 56px}.source-modal .prose{font-size:16px;margin-top:30px}.source-modal h2{font-size:24px}.empty-state{padding:65px 20px;text-align:center}.empty-state h1{font-size:30px;margin-bottom:15px}.empty-state p{color:var(--muted);margin-bottom:25px}.login-page{min-height:100dvh;display:grid;place-items:center;padding:20px}.login-card{width:min(430px,100%);border:1px solid var(--line);border-radius:18px;background:var(--surface);padding:44px}.login-card .brand-mark{margin-bottom:30px}.login-card h1{font-size:28px;margin:15px 0}.login-card p{font-size:12px;color:var(--muted);margin-bottom:25px}.login-card label{font-size:12px;color:var(--muted)}.login-card input{margin:8px 0 20px}#toast{position:fixed;bottom:28px;left:50%;transform:translate(-50%,20px);opacity:0;pointer-events:none;background:var(--accent);color:var(--ink);border-radius:10px;padding:12px 22px;font-size:12px;line-height:1.8;z-index:100;max-width:calc(100vw - 32px);box-shadow:var(--shadow);transition:opacity .2s,transform .2s}#toast.visible{opacity:1;transform:translate(-50%,0)}
@media(min-width:1600px){.reader-layout{grid-template-columns:175px minmax(400px,1fr) 285px;gap:32px}.reading-paper{padding:32px 58px}.hero h1{font-size:48px}.hero{min-height:360px}}
@media(max-width:1250px){.sidebar{width:205px;padding:29px 17px}.brand{font-size:18px;gap:9px}.brand-mark{width:35px}.workspace{margin-left:205px}#main{padding:30px 28px 45px}.topbar{padding:0 28px;height:66px}.hero{padding:30px;min-height:310px}.hero h1{font-size:36px}.hero-copy{min-width:280px}.hero-art{width:47%;right:-15px}.reader-layout{grid-template-columns:minmax(300px,1fr) 250px;gap:24px}.chapter-sidebar{position:static;grid-column:1/-1;display:flex;gap:18px;align-items:center;border-bottom:1px solid var(--line);padding-bottom:18px}.chapter-sidebar>.eyebrow,.chapter-sidebar>p,.chapter-note{display:none}.chapter-sidebar h2{font-size:19px;flex:1;margin:0}.chapter-list{margin:0;border:0;padding:0;max-width:300px}.chapter-list summary{padding:0;font-size:11px;min-width:70px}.chapter-list[open]{max-width:none;width:100%;flex-basis:100%}.chapter-sidebar:has(.chapter-list[open]){flex-wrap:wrap}.chapter-list[open] .chapter-link{display:inline-flex;vertical-align:top;max-width:240px;margin:7px 7px 0 0;padding:8px 12px}.chapter-list[open] summary{padding-bottom:5px}.chapter-list summary span{float:none;margin-left:10px}.reading-paper{padding:25px 30px}.reading-paper h1{font-size:27px}.cover{padding:20px 19px 18px 26px}.cover h3{font-size:22px}.new-book-card{min-height:220px}.source-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:1000px){.sidebar{width:80px;padding:26px 12px}.brand{justify-content:center}.brand>span:last-child,.sidebar-caption,.sidebar nav a{font-size:0}.brand-mark{width:43px;height:43px}.sidebar nav{margin-top:30px;gap:13px}.sidebar nav a{justify-content:center;padding:12px}.nav-count{display:none}.sidebar-new{font-size:0;gap:0;margin-top:24px}.sidebar-new .icon{width:19px}.little-note{display:none}.theme-toggle{justify-content:center;font-size:0;padding:10px}.theme-toggle span{display:none}.connection span:last-child{display:none}.connection{justify-content:center;padding:14px}.workspace{margin-left:80px}.hero-art{right:-5px}.hero-copy{min-width:270px}.hero .eyebrow{font-size:8px}.book-grid{gap:18px}.inspiration{padding:16px 12px;gap:10px}.inspiration-icon{padding:7px}.inspiration>.icon{display:none}.character-card{padding:22px 17px;gap:13px}.character-face{width:54px;height:54px}.character-card p{font-size:10px}}
@media(max-width:760px){.sidebar{position:sticky;top:0;width:100%;height:66px;padding:0 18px;flex-direction:row;align-items:center;border-right:0;border-bottom:1px solid var(--line);background:var(--sidebar);gap:8px}.brand{font-size:17px;gap:9px}.brand-mark{width:30px;height:34px;border-radius:10px}.brand-mark .icon{width:19px}.brand>span:last-child{font-size:17px}.brand small{display:none}.sidebar nav{flex-direction:row;margin:0 0 0 auto;gap:2px}.sidebar nav a{padding:9px}.sidebar nav a .icon{width:18px}.sidebar-new,.sidebar-bottom{display:none}.workspace{margin-left:0}.topbar{display:none}#main{padding:20px 18px 35px}.hero{padding:28px 24px;min-height:unset;flex-direction:column;align-items:stretch;border-radius:13px}.hero-copy{min-width:unset}.hero h1{font-size:35px;line-height:1.4;margin:15px 0}.hero p{font-size:11px}.hero .button{margin-top:20px;font-size:11px}.hero-art{width:100%;max-width:330px;align-self:center;margin-top:-8px;right:0}.art-caption{font-size:10px;margin-top:0}.hero .eyebrow{font-size:8px}.hero .story-art{max-height:205px}.continue-banner{margin:20px 0 28px;padding:17px 14px;gap:12px}.continue-banner h3{font-size:17px}.continue-banner .eyebrow{font-size:8px}.reading-emblem{width:35px;height:42px;flex-shrink:0}.continue-label{font-size:0;gap:0}.continue-label .icon{width:20px}.continue-banner p{font-size:10px}.section-heading{margin-bottom:17px;gap:10px}.section-heading h2{font-size:23px}.section-heading .eyebrow{font-size:8px}.section-heading>.muted{font-size:9px}.book-grid{grid-template-columns:1fr 1fr;gap:22px 15px}.cover{aspect-ratio:.86;padding:20px 17px 16px 23px;min-height:220px}.cover h3{font-size:23px;margin-top:15px}.cover-kicker{font-size:8px}.cover-scene{flex-direction:column;gap:8px;margin-top:21px}.cover-scene span{font-size:9px;letter-spacing:1px}.cover-scene .icon{width:28px;height:28px}.cover-line{margin-top:17px}.cover-number{font-size:7px;letter-spacing:1px}.book-info h3{font-size:13px}.book-info p{font-size:10px;margin-top:6px}.book-info>span{font-size:9px}.new-book-card{aspect-ratio:.86;min-height:220px}.new-book-card h3{font-size:17px}.new-book-card p{font-size:10px}.inspiration-section{margin-top:33px}.inspiration-grid{grid-template-columns:1fr;gap:10px}.inspiration{padding:17px;gap:14px}.inspiration p{font-size:10px}.inspiration>.icon{display:block;width:14px}.footer{padding:20px 18px;font-size:9px;flex-direction:column;gap:5px}.reader-top{margin-bottom:20px}.reader-layout{display:flex;flex-direction:column;gap:22px}.chapter-sidebar{width:100%;padding-bottom:15px}.chapter-sidebar h2{font-size:18px}.chapter-list[open] .chapter-link{font-size:10px;max-width:100%}.reading-column{width:100%}.reading-paper{padding:22px 24px;border-radius:4px 9px 9px 4px}.reading-paper h1{font-size:27px;margin:13px 0;line-height:1.6}.chapter-number{margin-top:30px}.chapter-meta{gap:8px;font-size:8px}.chapter-meta>span:before{padding-right:8px}.prose{font-size:18px;line-height:2.15;letter-spacing:.2px}.paper-divider{margin:25px 0}.paper-topline{font-size:8px}.end-flourish{font-size:11px;margin:33px 0 20px}.continuation-panel{position:static;width:100%;padding-top:14px;border-top:1px solid var(--line);scroll-margin-top:85px}.continuation-header{font-size:23px}.panel-intro{font-size:12px;margin:9px 0 17px}.panel-intro br{display:none}.suggestion{padding:17px 19px}.suggestion strong{font-size:14px}.suggestion p{font-size:12px;line-height:1.8;margin-top:5px}.suggestion-number{font-size:10px}.suggestion>.icon{width:16px;bottom:22px}.or-divider{font-size:11px;margin:25px 0 17px}.continuation-panel textarea{font-size:13px;min-height:118px}.compose-options{font-size:12px}.compose-options select{font-size:12px}.checkbox-label{font-size:12px}.continuation-panel .button{font-size:13px;min-height:48px}.panel-footnote{font-size:10px}.text-button{font-size:12px}.page-intro{padding-top:4px}.page-intro h1{font-size:27px}.page-intro p{font-size:12px}.page-intro p br{display:none}.source-summary{gap:12px;align-items:start}.source-summary>span{font-size:10px;gap:6px;white-space:nowrap}.source-summary strong{font-size:21px}.source-summary .button{font-size:10px;padding:8px 10px;min-height:37px;gap:5px}.source-summary .button>.icon{width:14px}.source-grid{grid-template-columns:1fr}.source-card{padding:19px}.source-card h3{font-size:19px}.source-card p{font-size:11px}.character-grid{grid-template-columns:1fr;gap:13px}.character-card{padding:23px}.character-card p{font-size:12px}.character-face{width:60px;height:60px}.preference-tags{gap:8px}.preference-tags span{font-size:9px}.preferences-editor h2{font-size:21px}.preferences-editor .section-heading .muted{font-size:11px}.preferences-editor textarea{font-size:12px;min-height:500px}.editor-footer{flex-direction:column;align-items:stretch}.editor-footer>span{font-size:10px}.source-modal{padding:36px 24px}.source-modal .prose{font-size:17px}dialog{padding:32px 23px}dialog h2{font-size:26px;margin-top:12px}.modal-intro{font-size:11px}.theme-choices{gap:7px}.theme-choices span{font-size:9px}.optional-setting{font-size:11px}.form-note{font-size:9px}.login-card{padding:30px}.login-card h1{font-size:26px}#toast{width:max-content;max-width:calc(100vw - 30px);bottom:18px;font-size:11px;padding:11px 17px}:root[data-font=large] .prose{font-size:21px}}
/* Small, unhurried movements keep the original SVG's quiet silhouette. */
.art-motion-toggle{position:absolute;top:0;right:0;display:flex;align-items:center;gap:4px;min-height:32px;padding:5px 7px;border:1px solid transparent;border-radius:7px;color:#b9c6ad;font-size:9px;letter-spacing:.5px;background:#30463b80}
.art-motion-toggle:hover{background:#24382e;border-color:#aabb9b44}
.art-motion-toggle .icon{width:12px;height:12px}
.story-eyes{transform-box:fill-box;transform-origin:center;animation:story-blink 8.2s ease-in-out infinite}
.story-eyes-xiaomei{animation-duration:10.6s}
.story-light{animation:story-lamplight 5.6s ease-in-out infinite}
.story-lamp{animation:story-lampglow 5.6s ease-in-out infinite}
.story-star{animation:story-starlight 7s ease-in-out infinite}
.story-star-late{animation-delay:-3.5s}
/* Keep the hinge at the book's spine, in SVG viewBox coordinates. */
.story-page{opacity:0;transform-box:view-box;transform-origin:268px 248px;animation:story-page-turn 12s ease-in-out infinite}
@keyframes story-blink{0%,42%,46%,100%{transform:scaleY(1)}44%{transform:scaleY(.12)}}
@keyframes story-lamplight{0%,100%{opacity:.08}50%{opacity:.15}}
@keyframes story-lampglow{0%,100%{opacity:.85}50%{opacity:1}}
@keyframes story-starlight{0%,100%{opacity:.65}50%{opacity:1}}
@keyframes story-page-turn{
  0%,18%{opacity:0;transform:translateY(0) skewY(0deg) scaleX(1)}
  19%{opacity:1;transform:translateY(0) skewY(0deg) scaleX(1)}
  24%{opacity:1;transform:translateY(-2px) skewY(-12deg) scaleX(.55)}
  28%{opacity:1;transform:translateY(-3px) skewY(-16deg) scaleX(.05)}
  32%{opacity:1;transform:translateY(-2px) skewY(10deg) scaleX(-.55)}
  36%,37%{opacity:1;transform:translateY(0) skewY(0deg) scaleX(-1)}
  39%,100%{opacity:0;transform:translateY(0) skewY(0deg) scaleX(-1)}
}
:root[data-story-motion=paused] .story-art *,:root[data-story-hidden=true] .story-art *{animation-play-state:paused!important}
@media(prefers-reduced-motion:reduce){*{animation:none!important;transition:none!important;scroll-behavior:auto!important}.story-page{opacity:0}.art-motion-toggle{display:none}}
/* Story style is separate from cover art and chapter closure. */
.story-style-field{margin:18px 0 22px;padding:14px;border:1px solid var(--line);border-radius:10px;background:var(--surface)}
.story-style-field>label{display:block;font-size:12px;color:var(--accent);margin-bottom:8px}
.story-style-field>select{width:100%;min-width:0;min-height:40px;font-size:12px}
.style-hint,.style-scope,.closing-hint{font-size:11px;line-height:1.8;color:var(--muted);margin:9px 0 0}
.style-scope{font-size:10px;color:var(--subtle);margin-top:6px}
.closing-hint{margin:-5px 0 18px}
@media(max-width:760px){.story-style-field>select{font-size:14px;min-height:44px}.story-style-field>label,.style-hint,.closing-hint{font-size:12px}}
