:root{--paper:#f8f5ed;--ink:#20282c;--muted:#708087;--line:#dce3dc;--blue:#2f6fed;--blue-dark:#1e4fb4;--yellow:#ffd66b;--green:#35a878;--red:#f06c5b;--white:#fff;--shadow:0 12px 35px rgba(32,40,44,.08)}
*{box-sizing:border-box}html,body{margin:0;min-height:100%;background:var(--paper);color:var(--ink);font-family:ui-rounded,"Avenir Next",system-ui,-apple-system,"PingFang SC","Microsoft YaHei",sans-serif}button,input,textarea{font:inherit}button{border:0;cursor:pointer}button:disabled{cursor:wait;opacity:.55}a{color:inherit;text-decoration:none}.hidden{display:none!important}
.shell{min-height:100vh;padding-bottom:calc(78px + env(safe-area-inset-bottom));}.topbar{max-width:760px;margin:0 auto;padding:18px 20px 14px;display:flex;align-items:center;justify-content:space-between}.brand{display:flex;gap:10px;align-items:center}.brand-mark{width:38px;height:38px;border-radius:13px;background:var(--blue);color:#fff;display:grid;place-items:center;font-weight:900;font-size:17px;box-shadow:0 6px 0 #173f94}.brand-name{font-weight:900;letter-spacing:.02em}.brand-sub{font-size:11px;color:var(--muted);margin-top:2px}.profile{display:flex;gap:8px;align-items:center;color:var(--muted);font-size:12px}.avatar{width:34px;height:34px;border-radius:12px;background:var(--yellow);display:grid;place-items:center;color:#6b4e00;font-weight:900}.page{max-width:760px;margin:0 auto;padding:0 20px 24px}.hero{padding:18px 0 20px;display:flex;justify-content:space-between;gap:16px;align-items:flex-end}.eyebrow{font-size:12px;color:var(--blue);font-weight:800;letter-spacing:.08em}.hero h1{font-size:32px;line-height:1.12;margin:6px 0 8px;letter-spacing:-.02em}.hero p{margin:0;color:var(--muted);font-size:14px;line-height:1.55}.spark{width:92px;height:92px;flex:none;border-radius:34% 66% 55% 45%;background:#dcecff;position:relative;display:grid;place-items:center;color:var(--blue);font-size:38px;font-weight:900;transform:rotate(-7deg)}.spark:after{content:"";position:absolute;inset:10px;border:2px dashed #8fb4ff;border-radius:44% 56% 42% 58%}.section-head{display:flex;align-items:center;justify-content:space-between;margin:22px 0 10px}.section-head h2{font-size:18px;margin:0}.section-head span{font-size:12px;color:var(--muted)}.panel{background:var(--white);border:1px solid var(--line);border-radius:22px;box-shadow:var(--shadow)}.capture{padding:18px}.capture.drop{border:2px dashed #9dbdf6;background:#f3f7ff}.capture-title{display:flex;align-items:center;gap:10px;margin-bottom:5px}.capture-title strong{font-size:17px}.capture-title small{color:var(--muted);font-size:12px}.capture-actions{display:grid;grid-template-columns:1fr 1fr;gap:10px;margin-top:15px}.primary,.secondary{min-height:48px;border-radius:15px;font-weight:800;display:flex;align-items:center;justify-content:center;gap:8px}.primary{background:var(--blue);color:#fff;box-shadow:0 5px 0 var(--blue-dark)}.secondary{background:#edf3ff;color:var(--blue)}.primary:active{transform:translateY(2px);box-shadow:0 3px 0 var(--blue-dark)}.upload-note{font-size:12px;color:var(--muted);margin:12px 0 0;text-align:center}.file-input{display:none}.stats{display:grid;grid-template-columns:repeat(3,1fr);gap:10px}.stat{padding:14px 12px}.stat b{display:block;font-size:24px;margin-bottom:3px}.stat span{font-size:12px;color:var(--muted)}.notebooks{display:grid;grid-template-columns:repeat(3,1fr);gap:10px}.book{padding:14px;min-height:104px;display:flex;flex-direction:column;justify-content:space-between;position:relative;overflow:hidden}.book:before{content:"";position:absolute;width:60px;height:60px;border-radius:50%;right:-16px;top:-18px;background:color-mix(in srgb,var(--book-color) 16%,white)}.book-name{font-weight:900;font-size:15px;position:relative}.book-count{font-size:12px;color:var(--muted);position:relative}.book-add{min-height:104px;border:1px dashed #aab9b5;background:transparent;color:var(--muted);border-radius:18px;font-weight:800}.recent-list{display:grid;gap:10px}.item{padding:15px;display:flex;gap:12px;align-items:flex-start}.item-badge{flex:0 0 38px;height:38px;border-radius:13px;background:#e5efff;color:var(--blue);display:grid;place-items:center;font-weight:900;font-size:12px}.item-main{min-width:0;flex:1}.item-top{display:flex;justify-content:space-between;gap:10px}.item-title{font-weight:800;line-height:1.4;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}.item-meta{font-size:12px;color:var(--muted);margin-top:7px}.empty{padding:28px;text-align:center;color:var(--muted);font-size:14px}.bottom-nav{position:fixed;z-index:5;bottom:0;left:0;right:0;padding:9px 18px calc(9px + env(safe-area-inset-bottom));background:rgba(248,245,237,.94);border-top:1px solid var(--line);backdrop-filter:blur(16px);display:flex;justify-content:center}.nav-inner{width:min(720px,100%);display:grid;grid-template-columns:repeat(3,1fr);gap:6px}.nav-btn{background:transparent;color:var(--muted);min-height:48px;border-radius:15px;font-size:11px;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:3px}.nav-btn.active{background:#e8f0ff;color:var(--blue);font-weight:900}.icon{width:20px;height:20px;fill:none;stroke:currentColor;stroke-width:2;stroke-linecap:round;stroke-linejoin:round}.modal-backdrop{position:fixed;z-index:10;inset:0;background:rgba(32,40,44,.42);display:grid;place-items:end center;padding:14px}.modal{width:min(100%,560px);max-height:92vh;overflow:auto;background:var(--paper);border-radius:24px 24px 18px 18px;padding:18px;box-shadow:0 -12px 40px rgba(0,0,0,.18)}.modal-head{display:flex;justify-content:space-between;align-items:center;margin-bottom:15px}.modal-head h2{font-size:20px;margin:0}.close{width:34px;height:34px;background:#e9efed;color:var(--muted);border-radius:12px;font-size:20px}.form-grid{display:grid;gap:12px}.field{display:grid;gap:7px}.field label{font-size:13px;font-weight:800}.field input,.field textarea,.field select{width:100%;border:1px solid var(--line);background:#fff;border-radius:13px;padding:12px 13px;outline:none}.field input:focus,.field textarea:focus,.field select:focus{border-color:var(--blue);box-shadow:0 0 0 3px #e5efff}.field textarea{min-height:92px;resize:vertical}.review-image{width:100%;max-height:230px;object-fit:contain;border-radius:16px;background:#e9efed;margin-bottom:12px}.pill-row{display:flex;gap:7px;flex-wrap:wrap}.pill{padding:8px 11px;border:1px solid var(--line);border-radius:999px;background:#fff;color:var(--muted);font-size:12px}.pill.selected{background:#e8f0ff;color:var(--blue);border-color:#a8c2fa;font-weight:800}.review-actions{display:grid;grid-template-columns:1fr 1fr;gap:10px;margin-top:15px}.toast{position:fixed;z-index:20;left:50%;bottom:92px;transform:translateX(-50%);background:var(--ink);color:#fff;padding:11px 15px;border-radius:12px;font-size:13px;box-shadow:var(--shadow)}.auth-shell{min-height:100vh;display:grid;place-items:center;padding:24px;background:var(--paper)}.auth-panel{width:min(100%,420px);padding:26px}.auth-panel h1{margin:0;font-size:28px}.auth-panel p{color:var(--muted);line-height:1.6;font-size:14px}.auth-panel .brand{margin-bottom:24px}.auth-toggle{display:flex;background:#eef2ee;border-radius:13px;padding:4px;margin:18px 0}.auth-toggle button{flex:1;padding:10px;border-radius:10px;background:transparent;color:var(--muted)}.auth-toggle button.active{background:#fff;color:var(--blue);font-weight:900;box-shadow:0 2px 6px rgba(32,40,44,.07)}.error{color:#c74f43;font-size:13px}
@media (min-width:700px){.topbar{padding-top:28px}.hero h1{font-size:40px}.modal-backdrop{place-items:center}.modal{border-radius:24px}.bottom-nav{position:static;background:transparent;border:0;backdrop-filter:none;padding:0;margin:0 auto 18px}.nav-inner{background:var(--white);border:1px solid var(--line);border-radius:18px;padding:5px}.nav-btn{font-size:13px}}
@media (max-width:390px){.page,.topbar{padding-left:15px;padding-right:15px}.notebooks{grid-template-columns:1fr 1fr}.hero h1{font-size:28px}.spark{width:76px;height:76px;font-size:30px}.capture-actions{grid-template-columns:1fr}.stats{gap:6px}.stat{padding:12px 8px}.stat b{font-size:21px}}
