:root{font-family:Inter,ui-rounded,Segoe UI,system-ui,-apple-system,sans-serif;color:#32402d;background:#f7f3e9;font-synthesis:none;--sage: #667d54;--sage-dark: #405b35;--cream: #f7f3e9;--beige: #e9dfca;--white: #fffdf8;--shadow: 0 8px 28px rgba(66, 73, 54, .13)}*{box-sizing:border-box}html,body,#root{margin:0;min-width:320px;height:100%;overflow:hidden}button,select,input{font:inherit}button{color:inherit}button:focus-visible,a:focus-visible,select:focus-visible,input:focus-visible{outline:3px solid rgba(102,125,84,.38);outline-offset:2px}.initial-loader,.page-loading{display:grid;place-items:center;height:100%;color:#667d54;letter-spacing:.02em}.app-shell{height:100dvh;display:grid;grid-template-rows:58px minmax(0,1fr) 66px;background:radial-gradient(circle at 50% 10%,#fffdf9 0,#f7f3e9 70%)}.topbar,.bottombar{position:relative;z-index:20;display:flex;align-items:center;padding:max(8px,env(safe-area-inset-top)) 14px 8px}.topbar{justify-content:space-between;border-bottom:1px solid rgba(102,125,84,.12)}.brand{font-weight:700;letter-spacing:.02em;font-size:15px}.brand span{color:#9b7f52;font-weight:600}.icon-button{width:44px;height:44px;border:0;border-radius:50%;display:grid;place-items:center;background:#fffdf8cc;box-shadow:0 2px 10px #3c463214;cursor:pointer}.icon-button:active{transform:scale(.96)}.icon-button:disabled{opacity:.35;cursor:default}.page-stage{min-height:0;display:grid;place-items:center;position:relative;overflow:hidden;padding:8px 10px;touch-action:none;user-select:none;-webkit-user-select:none}.page-transform{position:relative;transform-origin:center;will-change:transform;transition:transform .16s ease-out;filter:drop-shadow(0 7px 18px rgba(66,73,54,.15))}.page-stage:active .page-transform{transition:none}.book-image{display:block;width:100%;height:100%;object-fit:contain;pointer-events:none;-webkit-user-select:none;user-select:none;-webkit-user-drag:none}.hotspot{position:absolute;padding:0;border:0;background:transparent;cursor:pointer;touch-action:none}.hotspot:before{content:"";position:absolute;inset:-30%}.hotspot svg{display:block;width:100%;height:100%;overflow:visible;animation:check-in .17s ease-out both;filter:drop-shadow(0 1px 0 rgba(255,255,255,.8))}.hotspot path{fill:none;stroke:#496c3f;stroke-width:13;stroke-linecap:round;stroke-linejoin:round}@keyframes check-in{0%{opacity:0;transform:scale(.72)}to{opacity:1;transform:scale(1)}}.page-loading{position:absolute;inset:0;font-size:14px}.zoom-reset{position:absolute;z-index:5;bottom:12px;border:0;border-radius:20px;padding:9px 15px;background:#fffdf8f0;box-shadow:var(--shadow);color:var(--sage-dark)}.missing-page{display:flex;flex-direction:column;gap:8px;max-width:330px;text-align:center;padding:30px;background:var(--white);border:1px dashed #a9b49a;border-radius:24px;box-shadow:var(--shadow)}.missing-page span{color:#6f756a;font-size:14px;line-height:1.45}.bottombar{justify-content:space-between;gap:8px;padding:7px max(14px,env(safe-area-inset-right)) max(8px,env(safe-area-inset-bottom)) max(14px,env(safe-area-inset-left));border-top:1px solid rgba(102,125,84,.12)}.nav-button,.page-counter{min-height:46px;border:0;border-radius:18px;background:#fffdf8eb;box-shadow:0 3px 12px #3c463217;cursor:pointer}.nav-button{min-width:96px;padding:0 14px 0 9px;display:flex;align-items:center;gap:5px;justify-content:center}.nav-button.next{padding:0 9px 0 14px}.nav-button:disabled{opacity:.32;cursor:default}.page-counter{min-width:82px;padding:0 18px;color:var(--sage-dark);font-weight:750}.page-counter span{color:#8a8e83;font-weight:500}.contents-screen{height:100dvh;overflow-y:auto;background:var(--cream)}.contents-header{position:sticky;top:0;z-index:3;display:grid;grid-template-columns:48px 1fr 48px;align-items:center;padding:max(12px,env(safe-area-inset-top)) 16px 12px;text-align:center;background:#f7f3e9ed;-webkit-backdrop-filter:blur(12px);backdrop-filter:blur(12px);border-bottom:1px solid rgba(102,125,84,.12)}.contents-header h1{margin:0;font-size:20px}.contents-header p{margin:2px 0 0;color:#777c71;font-size:13px}.thumbnail-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(116px,1fr));gap:18px 12px;padding:20px 16px calc(30px + env(safe-area-inset-bottom));max-width:980px;margin:auto}.thumbnail{border:0;background:transparent;cursor:pointer;padding:0;font-weight:700}.thumb-image-wrap{position:relative;aspect-ratio:1055/1491;border-radius:10px;overflow:hidden;background:#ece7db;box-shadow:0 5px 16px #3c463224;margin-bottom:7px}.thumbnail img{width:100%;height:100%;object-fit:cover;display:block}.thumbnail:active .thumb-image-wrap{transform:scale(.98)}.thumb-missing{height:100%;display:grid;place-items:center;color:#7c8176;padding:12px;font-size:12px}.progress-dot{position:absolute;right:7px;top:7px;width:12px;height:12px;border-radius:50%;background:#c3ae83;border:2px solid white;box-shadow:0 1px 4px #0003}.progress-dot.done{background:var(--sage)}.modal-backdrop{position:fixed;z-index:100;inset:0;background:#272e2340;display:flex;align-items:end;justify-content:center;padding:14px;-webkit-backdrop-filter:blur(3px);backdrop-filter:blur(3px)}.modal{width:min(100%,460px);max-height:85dvh;overflow:auto;background:var(--white);border-radius:24px;box-shadow:0 20px 60px #262d213d;padding:18px;animation:modal-in .18s ease-out}.modal>header{display:flex;align-items:center;justify-content:space-between;gap:12px}.modal h2{margin:0;font-size:20px}.modal-body{line-height:1.55;color:#50584b}.modal-body p:last-child{margin-bottom:4px}@keyframes modal-in{0%{opacity:0;transform:translateY(12px)}}.menu-list{display:grid;gap:7px;margin-top:14px}.menu-list button{min-height:48px;border:0;border-radius:14px;background:#f2eee4;text-align:left;padding:0 16px;cursor:pointer}.menu-list button:disabled{opacity:.62;cursor:default}.menu-list .accent{color:#fff;background:var(--sage);font-weight:700}.menu-list .offline-download{background:#e7eee0;color:var(--sage-dark);font-weight:650}.menu-list .danger{color:#8b4d44;background:#f6ebe7}.install-help{display:grid;gap:3px;padding:12px 14px;border:1px solid #d9dfd0;border-radius:14px;background:#f7f7f0}.install-help strong{color:var(--sage-dark);font-size:14px}.install-help span{color:#697064;font-size:13px;line-height:1.4}.download-progress{display:grid;gap:6px;padding:8px 3px 6px;color:#687063;font-size:13px}.progress-track{height:7px;overflow:hidden;border-radius:99px;background:#dce3d5}.progress-track span{display:block;height:100%;border-radius:inherit;background:var(--sage);transition:width .15s ease-out}.download-message{margin:2px 4px 6px;font-size:13px;line-height:1.4}.download-message.success{color:#41633a}.download-message.error{color:#8b4d44}.update-notice{position:fixed;z-index:80;left:50%;bottom:calc(78px + env(safe-area-inset-bottom));transform:translate(-50%);width:min(calc(100% - 28px),430px);display:flex;align-items:center;justify-content:space-between;gap:14px;padding:10px 11px 10px 16px;border:1px solid rgba(102,125,84,.22);border-radius:18px;background:#fffdf8f7;box-shadow:0 12px 35px #2c352733;color:var(--sage-dark);font-size:14px;font-weight:650;-webkit-backdrop-filter:blur(12px);backdrop-filter:blur(12px)}.update-notice button{min-height:38px;border:0;border-radius:12px;padding:0 14px;background:var(--sage);color:#fff;font-weight:700;cursor:pointer}.editor-shell{min-height:100dvh;background:#eeeade;color:#303b2c;overflow:auto}.editor-header{display:flex;justify-content:space-between;align-items:center;gap:20px;padding:18px 24px;background:#fffdf8;border-bottom:1px solid #ddd5c5}.editor-header h1{margin:0;font-size:22px}.editor-header p{margin:4px 0 0;color:#73786d;font-size:14px}.editor-toolbar{position:sticky;top:0;z-index:5;display:flex;flex-wrap:wrap;align-items:center;gap:10px;padding:10px 24px;background:#f7f3e9f5;border-bottom:1px solid #d8d0c1;-webkit-backdrop-filter:blur(10px);backdrop-filter:blur(10px)}.page-picker{display:flex;align-items:center;gap:8px}.page-picker label{font-weight:650}.page-picker select{min-height:42px;border:1px solid #bbc4af;border-radius:10px;background:#fff;padding:0 10px}.editor-count{margin-right:auto;color:#687063}.primary-button,.secondary-button,.danger-button{min-height:44px;display:inline-flex;align-items:center;justify-content:center;gap:7px;border-radius:12px;padding:0 14px;text-decoration:none;cursor:pointer}.primary-button{border:0;color:#fff;background:var(--sage)}.secondary-button{border:1px solid #b7c0ac;color:var(--sage-dark);background:#fffdf8}.danger-button{border:0;color:#884c43;background:#f5e6e2;width:100%}.editor-workspace{display:grid;grid-template-columns:minmax(520px,800px) 260px;align-items:start;justify-content:center;gap:22px;padding:24px}.editor-page{position:relative;width:100%;line-height:0;box-shadow:var(--shadow);cursor:crosshair;background:#fff}.editor-page>img{width:100%;height:auto;display:block;pointer-events:none;-webkit-user-select:none;user-select:none}.editor-hotspot{position:absolute;border:3px solid #db6c58;background:#eb6b522e;cursor:move;touch-action:none;line-height:1}.editor-hotspot:nth-of-type(3n+1){border-color:#4e8daf;background:#4e8daf2b}.editor-hotspot:nth-of-type(3n+2){border-color:#7d9b45;background:#7d9b452e}.editor-hotspot.selected{box-shadow:0 0 0 3px #fff,0 0 0 5px #2f5130;z-index:2}.editor-hotspot>span{position:absolute;left:50%;top:50%;transform:translate(-50%,-50%);min-width:22px;height:22px;border-radius:50%;display:grid;place-items:center;background:#34442f;color:#fff;font-size:12px;font-weight:800;pointer-events:none}.resize-handle{position:absolute;right:-8px;bottom:-8px;width:18px;height:18px;border:2px solid white;border-radius:50%;background:#34442f;cursor:nwse-resize}.editor-panel{position:sticky;top:78px;background:#fffdf8;border-radius:18px;padding:18px;box-shadow:var(--shadow)}.editor-panel h2{margin:0 0 14px;font-size:18px}.editor-panel label{display:grid;grid-template-columns:70px 1fr;align-items:center;gap:8px;margin-bottom:9px;font-family:ui-monospace,monospace}.editor-panel input{width:100%;min-height:40px;border:1px solid #c7cbbf;border-radius:9px;padding:0 8px}.editor-panel hr{border:0;border-top:1px solid #e3ded2;margin:18px 0}.editor-panel p{color:#70766b;line-height:1.45}.editor-help{font-size:13px}.editor-help code{overflow-wrap:anywhere}.password-screen{min-height:100dvh;display:grid;place-items:center;overflow:auto;padding:22px;background:radial-gradient(circle at 50% 8%,#fffdf9,#f7f3e9 72%)}.password-card{width:min(100%,420px);padding:30px;border:1px solid rgba(102,125,84,.14);border-radius:28px;background:#fffdf8f7;box-shadow:0 18px 55px #37413024;color:#50584b;text-align:center}.password-mark{width:64px;height:64px;display:grid;place-items:center;margin:0 auto 18px;border-radius:20px;background:var(--sage);color:#fff;font-size:20px;font-weight:800;letter-spacing:.06em}.password-card h1{margin:0 0 10px;color:#303b2c;font-size:27px}.password-card>p{line-height:1.5}.password-card form{display:grid;gap:9px;margin-top:24px;text-align:left}.password-card label{color:#3e4a39;font-size:14px;font-weight:700}.password-card input{width:100%;min-height:54px;border:1px solid #b8c2ad;border-radius:15px;padding:0 16px;background:#fff;color:#303b2c;font-size:18px}.password-card form button{min-height:52px;margin-top:4px;border:0;border-radius:15px;background:var(--sage);color:#fff;font-weight:750;cursor:pointer}.password-card form button:disabled{opacity:.6}.password-error{padding:10px 12px;border-radius:12px;background:#f7e9e5;color:#8b4d44;font-size:14px}.password-note{margin:16px 0 0;color:#70766b;font-size:13px}@media(min-width:700px){.modal-backdrop{align-items:center}.app-shell{grid-template-rows:62px minmax(0,1fr) 70px}.thumbnail-grid{grid-template-columns:repeat(auto-fill,minmax(135px,1fr))}}@media(max-width:700px){.nav-button span{display:none}.nav-button{min-width:58px;width:64px;padding:0}.editor-header{align-items:flex-start;padding:14px}.editor-header p{display:none}.editor-header h1{font-size:18px}.editor-toolbar{padding:8px}.editor-count{display:none}.editor-toolbar .primary-button,.editor-toolbar .secondary-button{font-size:0;width:44px;padding:0}.editor-toolbar svg{width:22px}.editor-workspace{display:block;padding:8px}.editor-page{min-width:0}.editor-panel{position:static;margin-top:12px}.page-picker{flex:1}.page-picker label{white-space:nowrap}.password-card{padding:24px 20px}}@media(prefers-reduced-motion:reduce){*,*:before,*:after{animation-duration:.01ms!important;transition-duration:.01ms!important}}
