/* Shared site navigation and editorial select controls. */
.site-header.topbar{display:flex;position:relative;top:auto;align-items:center;height:70px;padding:0 24px;gap:20px;background:#101010;color:#fff;border:0;backdrop-filter:none}
.site-header .masthead-brand{color:#fff;font-size:30px;font-weight:900;letter-spacing:-1px;flex-shrink:0}
.site-header .masthead-nav{display:flex;align-self:stretch;align-items:stretch;gap:20px;flex-shrink:0}
.site-header .masthead-nav .nav-item{display:flex;position:relative;align-items:center;justify-content:center;min-height:0;width:auto;margin:0;padding:0;color:#fff;font-size:12px;font-weight:700;white-space:nowrap;background:transparent;border:0;border-radius:0;text-decoration:none}
.site-header .masthead-nav .nav-item.active::before{display:none}
.site-header .masthead-nav .nav-item.active::after{content:'';position:absolute;bottom:12px;inset-inline:0;height:3px;background:#f04e37}
.site-header .masthead-nav .nav-item:hover{color:#ffb5a7;background:transparent}
.site-header.topbar .search-box{margin-left:auto;width:clamp(180px,23vw,280px);min-width:100px;flex:1;max-width:280px;height:38px;min-height:38px;background:transparent;border:1px solid #d2d2cb;border-radius:3px;color:#fff}
.site-header.topbar .search-box input{width:100%;min-width:0;color:#fff;background:transparent;margin:0;font-size:12px;padding:8px 0;border:0;box-shadow:none}
.site-header.topbar .search-box input::placeholder{color:#a9aaa4}
.site-header.topbar .search-box svg{color:#fff;flex-shrink:0}
.site-header .topbar-right{display:flex;gap:10px;flex-shrink:0;align-items:center}
.site-header .account{margin:0;padding:0;border:0;display:flex;align-items:center;color:#fff;gap:8px}
.site-header .account b{color:inherit;font-size:12px;max-width:85px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.site-header .account .avatar{display:grid;place-items:center;background:#e0d8ff;color:#211630;width:30px;height:30px;border-radius:50%;font-size:12px}
.site-header .account .icon-button{color:#fff;width:30px;height:32px}
.site-header .account .icon-button:hover{background:#333}
.site-header .account .icon-button svg{width:16px;height:16px}
.site-header #lit-account{color:inherit;margin-left:0}
.site-header #new-top{display:none!important}
.lit-shell{width:calc(100% - 64px);max-width:1120px;margin:24px auto;min-height:calc(100dvh - 48px);border:1px solid #c8c3b9;background:#fffdf8}
.lit-shell .lit-main{max-width:none;margin:0;padding:36px 28px 64px}
.lit-shell .lit-intro{padding-bottom:28px;border-bottom:3px solid #24211f}
.lit-shell .lit-tools{justify-content:space-between;align-items:center;border-bottom:1px solid #ded7cb;padding-bottom:12px}
.lit-list-caption{font-size:11px;font-weight:750;letter-spacing:.08em;color:#74695d}
/* Keep native form semantics and values without exposing the system popup. */
select.select-native{position:absolute!important;width:1px!important;height:1px!important;padding:0!important;margin:-1px!important;overflow:hidden!important;clip:rect(0,0,0,0)!important;clip-path:inset(50%)!important;white-space:nowrap!important;border:0!important;opacity:0!important}
.custom-select{display:inline-block;position:relative;min-width:0;vertical-align:middle;width:100%;font-family:StudySans,StudyFallback,Manrope,ManropeFallback,sans-serif}
.custom-select .select-trigger{display:flex;align-items:center;justify-content:space-between;gap:18px;width:100%;min-width:0;min-height:42px;margin:0;padding:9px 12px;background:#fffdf8;color:#292823;border:1px solid #d6cbbd;border-radius:4px;text-align:left;font-family:inherit;font-size:12px;font-weight:600;line-height:1.5;cursor:pointer;transition:background .15s,border-color .15s,box-shadow .15s}
.custom-select .select-value{min-width:0;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}
.custom-select .select-chevron{width:7px;height:7px;flex-shrink:0;transform:rotate(45deg);border-right:1.5px solid currentColor;border-bottom:1.5px solid currentColor;margin:0 3px 4px 0;opacity:.65;transition:transform .15s}
.custom-select.is-open .select-chevron{transform:rotate(225deg);margin-bottom:0}
.custom-select .select-trigger:hover:not(:disabled){background:#f9f1e8;border-color:#ad7868}
.custom-select.is-open .select-trigger{background:#fff7ef;border-color:#cf3525;box-shadow:0 0 0 2px #cf352512}
.custom-select .select-trigger:focus-visible{outline:2px solid #cf3525;outline-offset:3px}
.custom-select .select-trigger:disabled{opacity:.48;cursor:default}
.select-popup{position:fixed;inset:auto;margin:0;padding:6px;background:#fffdf8;color:#292823;border:1px solid #cfc3b5;border-top:2px solid #cf3525;border-radius:5px;box-shadow:0 12px 36px #35231824,0 2px 5px #35231812;z-index:1000;overflow:hidden;font-family:StudySans,StudyFallback,Manrope,ManropeFallback,sans-serif;box-sizing:border-box;max-width:calc(100vw - 24px)}
.select-popup[hidden]{display:none!important}
.select-popup::backdrop{background:transparent}
.select-heading{padding:6px 8px 9px;color:#9d3024;font-size:10px;font-weight:750;line-height:1.4;letter-spacing:.06em;border-bottom:1px solid #eee5d9}
.select-popup .select-search{display:block;width:calc(100% - 8px);min-height:38px;margin:7px 4px;padding:8px 10px;background:#f6f1e9;color:#292823;border:1px solid #ded3c4;border-radius:3px;font-family:inherit;font-size:12px;line-height:1.5;box-sizing:border-box}
.select-popup .select-search:focus{outline:1px solid #cf3525;outline-offset:1px}
.select-options{position:relative;overflow-y:auto;overscroll-behavior:contain;scrollbar-width:thin;scrollbar-color:#c8b9aa transparent;padding:4px 0}
.select-option{position:relative;padding:10px 32px 10px 12px;min-height:38px;border-left:2px solid transparent;border-radius:2px;font-size:12px;line-height:1.6;overflow-wrap:anywhere;cursor:pointer}
.select-option:hover,.select-option.is-active{background:#f5eee5}
.select-option[aria-selected=true]{background:#eee7fb;border-left-color:#cf3525;color:#4c315c;font-weight:700}
.select-option[aria-selected=true]::after{content:'';position:absolute;right:13px;top:15px;width:5px;height:9px;border-right:1.5px solid #cf3525;border-bottom:1.5px solid #cf3525;transform:rotate(45deg)}
.select-option[aria-selected=true].is-active{background:#e4d9f7}
.select-option[aria-disabled=true]{color:#978c81;cursor:default;background:transparent;font-weight:400}
.select-empty{margin:0;padding:18px 12px;color:#827567;font-size:12px}
.select-popup-wide .select-option{font-size:12px;line-height:1.7;padding-block:12px}
.paper-picker .custom-select .select-trigger{min-height:36px;padding:6px 10px;background:#fffdf8;font-size:13px;gap:10px}
.custom-select[data-select-id=zoom]{width:110px}
.custom-select[data-select-id=zoom] .select-trigger{min-height:40px;font-size:12px}
.custom-select[data-select-id=notes-scope]{flex:1;width:auto}
.custom-select[data-select-id=paper-sort]{width:150px;flex-shrink:0}
.custom-select[data-select-id=upload-category]{display:block;width:180px;margin-top:6px}
.custom-select[data-select-id=move-category]{width:170px}
.literature-page dialog .custom-select{margin-top:8px}
.custom-select[data-select-id=sort]{width:154px;flex-shrink:0}
.custom-select[data-select-id=sort] .select-trigger{background:transparent;color:#fff;border:1px solid #ffffff70;border-radius:3px;min-height:36px;padding:7px 10px;font-size:12px;gap:8px}
.custom-select[data-select-id=sort] .select-trigger:hover,.custom-select[data-select-id=sort].is-open .select-trigger{background:#ffffff20;border-color:#fff;box-shadow:none}
.custom-select[data-select-id=sort] .select-trigger:focus-visible{outline-color:#fff}
@media(min-width:768px) and (max-width:1000px){.site-header.topbar{gap:12px;padding-inline:18px}.site-header .masthead-nav{gap:14px}.site-header .account b{display:none}}
@media(max-width:767px){
 .site-header.topbar{height:auto;min-height:64px;padding:14px 16px;gap:12px;flex-wrap:wrap}
 .site-header .masthead-brand{font-size:27px}
 .site-header .masthead-nav{order:3;flex-basis:100%;gap:18px;align-self:auto;min-height:34px;overflow-x:auto}
 .site-header .masthead-nav .nav-item{font-size:12px;min-height:34px}
 .site-header .masthead-nav .nav-item.active::after{bottom:0}
 .site-header .topbar-right{margin-left:auto;gap:5px}
 .site-header .account b{display:none}
 .site-header .account .avatar{width:26px;height:26px}
 .site-header .account .icon-button{width:28px}
 .site-header.topbar .search-box{order:4;flex:1 0 calc(100% - 52px);max-width:none;min-width:0;margin-left:0;height:40px}
 .site-header.topbar .search-box input{font-size:16px}
 .site-header.topbar .search-box input::placeholder{font-size:12px}
 .lit-shell{width:100%;margin:0;border:0;min-height:100dvh}
 .lit-shell .site-header .search-box{flex-basis:100%}
 .lit-shell .lit-main{padding:28px 18px 48px}
 .lit-shell .lit-intro{padding-bottom:22px}
 .custom-select[data-select-id=sort]{width:112px}
 .custom-select[data-select-id=sort] .select-trigger{font-size:10px;padding:6px 8px;gap:6px}
 .custom-select[data-select-id=upload-category]{width:100%}
 .select-popup .select-search{font-size:16px}
}
@media(max-width:600px){.paper-picker .custom-select .select-trigger{font-size:12px;min-height:34px;padding:5px 8px}.custom-select[data-select-id=zoom]{width:86px}.custom-select[data-select-id=zoom] .select-trigger{min-height:36px;padding:6px 8px;font-size:10px;gap:5px}}
@media(max-width:420px){.site-header .masthead-nav{gap:12px}.site-header .masthead-nav .nav-item{font-size:11px}.lit-shell .site-header #lit-admin{max-width:48px;white-space:normal;text-align:center}.lit-shell .site-header{gap:9px}.lit-shell .site-header .masthead-nav{gap:10px}}
@media(prefers-reduced-motion:reduce){.custom-select .select-trigger,.custom-select .select-chevron{transition:none}}

label>.custom-select{margin-top:8px}

/* Official Phosphor bookmark-simple asset, shared across all personal-reading entry points. */
.bookmark-icon{display:block;width:19px;height:19px;background:currentColor;mask:url('/static/public/8833ff60cd7af232b86e/bookmark.svg') center/contain no-repeat;-webkit-mask:url('/static/public/8833ff60cd7af232b86e/bookmark.svg') center/contain no-repeat}
.lit-bookmark[aria-pressed=true]{background:#cf3525;color:#fff;border-color:#cf3525;font-weight:750}
.lit-bookmark[aria-pressed=true]:hover{background:#a12e23;border-color:#a12e23;color:#fff}

.category-context-menu{position:fixed;z-index:70;min-width:164px;padding:5px;background:#fffdf8;border:1px solid #ded9d0;border-radius:5px;box-shadow:0 6px 22px #10101020}.category-context-menu[hidden]{display:none}.category-context-menu button{display:block;width:100%;padding:9px 12px;text-align:left;border:0;border-radius:3px;background:transparent;color:#b82f23;font:600 13px StudySans,Manrope,sans-serif;cursor:pointer}.category-context-menu button:hover,.category-context-menu button:focus-visible{background:#f04e3712;outline:1px solid #f04e3766}.category-context-target:focus-visible{outline:2px solid #c83224;outline-offset:-2px}

#editor .dialog-actions{flex-wrap:wrap}#editor-status{flex:0 0 100%;margin:0!important;min-width:0;overflow-wrap:anywhere}#editor-status:empty{display:none}#editor-status.is-error{color:#b82f23;font-weight:600}

/* Reader controls share one 40px baseline, below the paper field label. */
@media(min-width:1101px){
 .paper-reader .reader-toolbar{align-items:end;gap:14px;padding:12px 20px;min-height:86px}
 .paper-reader .paper-picker label{margin-bottom:6px;line-height:14px}
 .paper-reader .reader-toolbar .custom-select .select-trigger{height:40px;min-height:40px;padding:8px 12px}
 .paper-reader .reader-toolbar .page-controls{height:40px;box-sizing:border-box}
 .paper-reader .reader-toolbar .page-controls input{height:30px;min-height:30px}
 .paper-reader .reader-actions{height:40px;align-items:center}
 .paper-reader .reader-actions .reader-tool{height:40px;min-height:40px}
 .paper-reader .reader-actions .reader-reading-link{padding-left:8px;padding-right:10px}
}
