/*! © 2026 LogosVox. All rights reserved. Copying, modifying or redistributing this code is not permitted. https://games.logosvox.com/terms */
/* Library app — four presentations of the same owned collection. */
.library-app{--shelf-paper:#f5f0e8;--shelf-edge:#d9c8ac;--shelf-top:#ebdfcd;--shelf-shadow:#46362226;--shelf-muted:#6e6254;color:var(--lib-ink);padding:8px 0 28px;min-width:0}
[data-library-theme=dark] .library-app{--shelf-paper:#252321;--shelf-edge:#665746;--shelf-top:#81715b;--shelf-shadow:#0008;--shelf-muted:#c2b8ac}
.library-view-bar{display:flex;align-items:center;justify-content:space-between;gap:16px;margin-bottom:16px;flex-wrap:wrap}
.library-view-bar nav{display:flex;gap:3px;padding:3px;background:var(--lib-hover);border-radius:12px;max-width:100%}
.page-database .library-view-bar nav button{border:0;background:transparent;color:var(--lib-muted);padding:8px 12px;border-radius:9px;min-height:38px;white-space:nowrap}
.page-database .library-view-bar nav button[aria-pressed=true]{background:var(--lib-panel);color:var(--lib-ink);box-shadow:0 2px 5px var(--lib-shadow)}
.page-database .library-resume{border:0;background:transparent;max-width:270px;justify-content:flex-start;padding:6px 0;text-align:left}
.library-resume>span{display:flex;flex-direction:column;gap:2px;min-width:0}.library-resume span span{font-size:11px;color:var(--lib-muted)}.library-resume strong{font-size:12px;font-weight:550;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.library-shelves{padding:24px 24px 6px;border-radius:16px;background:var(--shelf-paper);box-shadow:inset 0 3px 12px var(--shelf-shadow)}
.library-shelf{min-width:0;margin:0 0 12px}.library-shelf>header{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:4px}
.library-shelf h3{display:flex;align-items:center;gap:10px;font:500 13px/1.5 var(--lib-sans,system-ui);margin:0;color:var(--shelf-muted)}.library-shelf h3 span{font-size:11px;font-variant-numeric:tabular-nums}
.library-shelf header>div{display:flex;gap:2px;align-items:center}.page-database .library-shelf header button{border:0;background:transparent;color:var(--shelf-muted);padding:6px;min-width:32px;min-height:32px;font-size:11px}.library-full-shelf>span{display:flex;align-items:center;gap:4px}
.library-shelf-scroll{overflow:auto;scrollbar-width:thin;scrollbar-color:var(--shelf-edge) transparent;padding:8px 5px 26px;scroll-snap-type:x proximity}
.library-shelf-track{position:relative;display:flex;align-items:flex-end;gap:30px;width:max-content;min-width:100%;padding:0 12px 0;box-sizing:border-box;isolation:isolate}
.library-shelf-track::after{content:"";position:absolute;left:0;right:0;height:10px;bottom:40px;border-radius:2px;background:var(--shelf-edge);border-top:4px solid var(--shelf-top);box-shadow:0 14px 18px var(--shelf-shadow);z-index:-1}
.library-book{width:112px;flex:none;min-width:0;scroll-snap-align:start;position:relative}
.page-database .library-book-object{position:relative;display:flex;align-items:flex-end;justify-content:center;width:100%;height:var(--book-height);padding:0 0 4px;border:0;background:transparent;border-radius:2px;overflow:visible;transition:transform .2s cubic-bezier(.16,1,.3,1)}
.library-book-object canvas,.library-book-object img{display:block;max-width:100%;max-height:100%;width:auto;height:auto;object-fit:contain;filter:drop-shadow(4px 5px 4px var(--shelf-shadow));border-radius:1px}
.library-book-object:hover{transform:translateY(-5px) rotate(-1deg)}
.library-book-object .app-cover-placeholder{height:100%;width:100%;background:var(--book-cloth);color:var(--book-ink);border-radius:2px}
.library-book-caption{display:flex;align-items:center;height:44px;gap:2px;padding-top:8px;box-sizing:border-box}
.page-database .library-book-caption>button:first-child{display:block;flex:1;min-width:0;padding:0;border:0;background:transparent;text-align:left;min-height:32px;color:var(--shelf-muted)}
.library-book-caption strong,.library-book-caption small{display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-size:11px;font-weight:500;line-height:1.5}.library-book-caption small{font-size:10px;font-weight:400}
.page-database .library-book-caption>button:last-child{padding:5px;border:0;background:transparent;min-height:32px;min-width:28px;color:var(--shelf-muted)}
.library-cover-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(135px,1fr));gap:32px 28px;padding:28px 20px;background:var(--shelf-paper);border-radius:16px}
.library-cover-grid .library-book{width:100%;max-width:180px;justify-self:center}.library-cover-grid .library-book-object{height:210px}.library-cover-grid .library-book-caption{height:54px}.library-cover-grid .library-book-caption strong{font-size:12px}.library-cover-grid .library-book-caption small{font-size:11px}
.library-mode-spines .library-shelf-track{gap:5px;padding-inline:14px}.library-book.is-spine{width:var(--spine-width)}
.page-database .is-spine .library-book-object{display:flex;flex-direction:column;align-items:center;justify-content:flex-start;gap:9px;background:linear-gradient(90deg,#0003,transparent 14%,#fff1 70%,#0002),var(--book-cloth);color:var(--book-ink);box-shadow:3px 4px 5px var(--shelf-shadow);padding:10px 5px 8px;border-radius:2px 3px 0 0}
.library-spine-author{font-size:8px;line-height:1.3;max-height:22px;overflow:hidden;width:100%;text-align:center}.library-spine-title{writing-mode:vertical-rl;font:500 12px/1.2 Georgia,serif;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;flex:1;letter-spacing:.015em;max-height:calc(100% - 45px)}.library-spine-mark{height:12px}.library-spine-mark svg{width:12px;height:12px}
.is-spine .library-book-caption>button:first-child{display:none}.is-spine .library-book-caption{justify-content:center}
.library-categories{display:flex;gap:6px;flex-wrap:wrap;padding:0 0 16px}.page-database .library-categories button{background:transparent;border:0;color:var(--lib-muted);font-size:12px}.page-database .library-categories button[aria-pressed=true]{background:var(--lib-hover);color:var(--lib-ink)}
.library-empty{display:flex;flex-direction:column;align-items:center;text-align:center;min-height:290px;justify-content:center;padding:24px;background:var(--shelf-paper);border-radius:16px}.library-empty>.library-icon{width:36px;height:36px;color:var(--shelf-muted);margin-bottom:14px}.library-empty h3{font:500 24px/1.3 Georgia,serif;margin:0 0 10px}.library-empty p{color:var(--shelf-muted);font-size:13px;max-width:40ch;margin:0 0 20px}.library-load-more{margin:20px auto!important;display:flex!important}
.library-book-menu>button{justify-content:flex-start;width:100%;border:0;background:transparent}.library-book-menu label{display:flex;flex-direction:column;gap:8px;font-size:12px;margin-top:12px;padding:12px 4px 4px;border-top:1px solid var(--lib-line)}
.library-app button:focus-visible{outline:2px solid var(--lib-muted);outline-offset:3px}.library-app ::selection{background:var(--lib-ink);color:var(--lib-paper)}
@media(max-width:700px){.library-view-bar{gap:10px}.library-view-bar nav{width:100%;box-sizing:border-box}.page-database .library-view-bar nav button{flex:1;padding:7px 5px;font-size:11px;min-height:40px;gap:4px}.library-view-bar nav svg{width:15px;height:15px}.page-database .library-resume{max-width:100%}.library-shelves{padding:16px 10px 4px}.library-shelf-track{gap:22px;padding-inline:8px}.library-book{width:96px}.library-shelf-scroll{padding-bottom:22px}.library-shelf>header{gap:4px}.library-shelf h3{font-size:12px;gap:6px}.page-database .library-full-shelf{padding-inline:4px;font-size:10px}.library-full-shelf svg{display:none}.library-cover-grid{grid-template-columns:repeat(2,minmax(0,1fr));padding:22px 14px;gap:24px 16px}.library-cover-grid .library-book-object{height:180px}.library-shelf header>div button{min-width:40px!important;min-height:40px!important}.library-mode-spines .library-shelf-track{gap:6px}.library-book-caption>button:last-child{min-width:32px!important;min-height:36px!important}}
@media(prefers-reduced-motion:reduce){.library-book-object{transition:none!important}.library-book-object:hover{transform:none}}
