/* Geekrew Library — "Lamplight": ivory paper, ink, terracotta + olive. Literata for reading, Work Sans for UI. */
@font-face { font-family: Literata; src: url(/fonts/Literata.woff2) format('woff2'); font-weight: 200 900; font-display: swap }
@font-face { font-family: Literata; src: url(/fonts/Literata-Italic.woff2) format('woff2'); font-style: italic; font-weight: 400; font-display: swap }
@font-face { font-family: 'Work Sans'; src: url(/fonts/WorkSans.woff2) format('woff2'); font-weight: 100 900; font-display: swap }
:root { --bg: #fbf6ec; --bg2: #f3ebdc; --card: #fffdf7; --ink: #23201b; --ink2: #4a443a; --muted: #7c7466; --line: #e6dccb; --acc: #b4532a; --acc2: #8f3f1f; --olive: #4d5a2a;
  --serif: Literata, Georgia, 'Times New Roman', serif; --sans: 'Work Sans', system-ui, -apple-system, 'Segoe UI', sans-serif; --fs: 19px; --mw: 680px }
[data-theme=sepia] { --bg: #f4e8d0; --bg2: #ead9b9; --card: #f8eedb; --ink: #3a2e1f; --ink2: #5a4a35; --line: #dcc8a4 }
[data-theme=night] { --bg: #171512; --bg2: #211e1a; --card: #1e1b17; --ink: #e9e2d4; --ink2: #c9bfad; --muted: #9a907f; --line: #34302a; --acc: #e08a5f; --acc2: #f0a27a }
* { box-sizing: border-box }
html { -webkit-text-size-adjust: 100% }
body { margin: 0; background: var(--bg); color: var(--ink); font: 16px/1.6 var(--sans); -webkit-font-smoothing: antialiased }
a { color: var(--acc); text-decoration: none } a:hover { color: var(--acc2) }
h1, h2, h3 { font-family: var(--serif); font-weight: 700; letter-spacing: -.01em; line-height: 1.15; margin: 0 0 .5em }
.wrap { max-width: 1160px; margin: 0 auto; padding: 0 18px } .narrowish { max-width: 900px }
.top { position: sticky; top: 0; z-index: 20; background: color-mix(in srgb, var(--bg) 92%, transparent); backdrop-filter: blur(10px); border-bottom: 1px solid var(--line) }
.top-in { display: flex; align-items: center; gap: 22px; height: 60px }
.logo { display: flex; align-items: center; gap: 9px; color: var(--ink); font: 600 1.05rem var(--sans) } .logo b { color: var(--acc); font-weight: 700 }
.logo-m { width: 32px; height: 32px; border-radius: 8px 8px 8px 2px; background: var(--acc); color: #fffdf7; display: grid; place-items: center; font: 700 1.15rem var(--serif) }
.top nav { display: flex; gap: 18px } .top nav a { color: var(--ink2); font-weight: 500; font-size: .95rem } .top nav a:hover { color: var(--acc) }
.q { margin-left: auto } .q input { border: 1px solid var(--line); background: var(--card); color: var(--ink); border-radius: 999px; padding: 8px 15px; font: inherit; font-size: .92rem; width: 230px }
@media (max-width: 760px) { .top nav { display: none } .q input { width: 150px } }
.hero { padding: 56px 0 30px }
.hero-in { display: grid; grid-template-columns: 1.3fr 1fr; gap: 40px; align-items: center }
.eyebrow { color: var(--olive); font-weight: 600; font-size: .85rem; letter-spacing: .06em; text-transform: uppercase; margin: 0 0 14px }
.hero h1 { font-size: clamp(2.3rem, 5.4vw, 3.9rem); line-height: 1.03 }
.lede { color: var(--ink2); font-size: 1.12rem; max-width: 34em; margin: 0 0 22px }
.q.big { margin: 0; display: flex; gap: 8px; max-width: 560px; background: var(--card); border: 1.5px solid var(--ink); border-radius: 14px; padding: 6px }
.q.big input { flex: 1; border: 0; width: auto; background: transparent; font-size: 1.02rem; padding: 10px 12px; border-radius: 10px; outline: 0; min-width: 0 }
.q.big button, .btn { border: 0; cursor: pointer; background: var(--acc); color: #fffdf7; font: 600 .98rem var(--sans); padding: 11px 20px; border-radius: 10px; display: inline-block }
.btn:hover, .q.big button:hover { background: var(--acc2); color: #fffdf7 }
.btn.ghost { background: transparent; color: var(--ink); box-shadow: inset 0 0 0 1.5px var(--line) } .btn.ghost:hover { box-shadow: inset 0 0 0 1.5px var(--ink); color: var(--ink) }
.hero-stack { position: relative; height: 330px }
.hero-stack .cover { position: absolute; width: 170px; top: 20px; box-shadow: 0 18px 40px rgba(35, 32, 27, .22) }
.hero-stack .cover:nth-child(1) { left: 0; transform: rotate(-8deg) } .hero-stack .cover:nth-child(2) { left: 70px; top: 0; transform: rotate(-3deg) } .hero-stack .cover:nth-child(3) { left: 150px; top: 14px; transform: rotate(3deg) }
.hero-stack .cover:nth-child(4) { left: 230px; top: 34px; transform: rotate(8deg) } .hero-stack .cover:nth-child(5) { display: none }
@media (max-width: 860px) { .hero-in { grid-template-columns: 1fr } .hero-stack { display: none } .hero { padding-top: 34px } }
/* covers */
.cover { --c: #b4532a; --cb: #fbe9dc; aspect-ratio: 2 / 3; background: var(--c); color: var(--cb); border-radius: 4px 10px 10px 4px; padding: 1.4em 1em 1.1em; display: flex; flex-direction: column; position: relative; overflow: hidden;
  box-shadow: inset 6px 0 0 rgba(0, 0, 0, .18), 0 6px 18px rgba(35, 32, 27, .14) }
.cover::after { content: ""; position: absolute; inset: 6% 7% 6% 9%; border: 1px solid color-mix(in srgb, var(--cb) 45%, transparent); border-radius: 3px; pointer-events: none }
.cv-g { font: 600 .55em/1 var(--sans); letter-spacing: .14em; text-transform: uppercase; opacity: .8 }
.cv-t { font: 700 1.25em/1.08 var(--serif); margin-top: 1.3em; overflow-wrap: break-word; hyphens: auto } .cv-r { width: 30%; height: 2px; background: var(--cb); opacity: .7; margin: .8em 0 }
.cv-a { font: italic 400 .8em/1.25 var(--serif); margin-top: auto }
.cover.sm { font-size: 15px } .cover.lg { font-size: 22px; width: 260px; flex: none }
/* shelves & cards */
.row { margin: 34px 0 } .row-h { display: flex; justify-content: space-between; align-items: baseline } .row-h h2 { font-size: 1.55rem } .row-h a { font-weight: 600; font-size: .92rem }
.shelf { display: grid; grid-auto-flow: column; grid-auto-columns: 150px; gap: 18px; overflow-x: auto; padding: 6px 2px 14px; scrollbar-width: thin; scroll-snap-type: x proximity }
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 26px 18px; margin: 18px 0 40px }
.bk { color: var(--ink); display: flex; flex-direction: column; gap: 4px; scroll-snap-align: start } .bk .cover { font-size: 13px; transition: transform .2s } .bk:hover .cover { transform: translateY(-4px) rotate(-1deg) }
.bk-t { font: 600 .98rem/1.25 var(--serif); margin-top: 8px } .bk-a { color: var(--ink2); font-size: .85rem } .bk-m { color: var(--muted); font-size: .78rem }
.bk .pct { font-size: .78rem; color: var(--olive); font-weight: 600 }
.filter { width: 100%; max-width: 420px; border: 1.5px solid var(--line); background: var(--card); color: var(--ink); border-radius: 10px; padding: 11px 14px; font: inherit }
.gl { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 12px; margin: 20px 0 40px } .gl a { background: var(--card); border: 1px solid var(--line); border-radius: 12px; padding: 18px; color: var(--ink); display: flex; flex-direction: column }
.gl b { font: 700 1.15rem var(--serif) } .gl span { color: var(--muted); font-size: .88rem } .gl a:hover { border-color: var(--acc) }
.al { list-style: none; padding: 0; columns: 2 280px; margin: 20px 0 40px } .al li { display: flex; justify-content: space-between; padding: 8px 0; border-bottom: 1px dashed var(--line); break-inside: avoid } .al span { color: var(--muted); font-size: .85rem }
/* book page */
.crumb { font-size: .88rem; color: var(--muted); margin: 22px 0 } .crumb a { color: var(--ink2) }
.book-in { display: flex; gap: 40px; align-items: flex-start } .book-b { min-width: 0 } .book-b h1 { font-size: clamp(2rem, 4.5vw, 3rem) }
.by { font: italic 1.15rem var(--serif); margin: 0 0 6px } .meta { color: var(--muted); margin: 0 0 18px } .cta { display: flex; gap: 10px; flex-wrap: wrap; margin: 18px 0 }
.opening { font: italic 1.08rem/1.6 var(--serif); color: var(--ink2); border-left: 3px solid var(--acc); margin: 22px 0 0; padding: 4px 0 4px 18px }
@media (max-width: 700px) { .book-in { flex-direction: column; gap: 20px } .cover.lg { width: 170px; font-size: 15px } }
.toc { margin: 40px 0 } .toc ol { list-style: none; padding: 0; margin: 0; columns: 2 320px; column-gap: 30px }
.toc li a { display: flex; gap: 12px; padding: 9px 4px; border-bottom: 1px solid var(--line); color: var(--ink); break-inside: avoid } .toc li a:hover { color: var(--acc) }
.toc .n { color: var(--muted); font: 600 .82rem var(--sans); min-width: 26px; padding-top: 2px } .toc li.read a { color: var(--muted) } .toc li.here a { color: var(--acc); font-weight: 600 }
/* reader */
.pg-read .foot { display: none }
.bar { position: fixed; top: 60px; left: 0; right: 0; height: 3px; z-index: 19 } .bar span { display: block; height: 100%; width: 0; background: var(--acc) }
.reader { max-width: var(--mw); margin: 0 auto; padding: 34px 20px 80px }
.r-head { text-align: center; margin-bottom: 34px } .r-book { font: 600 .85rem var(--sans); letter-spacing: .08em; text-transform: uppercase; color: var(--olive) }
.r-by { color: var(--muted); font-size: .88rem; margin: 6px 0 14px } .r-head h1 { font-size: clamp(1.6rem, 4vw, 2.2rem) }
.r-text { font: 400 var(--fs)/1.75 var(--serif); hyphens: auto; -webkit-hyphens: auto } .r-text p { margin: 0 0 1.05em; text-align: left } .r-text p.dc::first-letter { font-size: 3.1em; float: left; line-height: .9; padding: .05em .08em 0 0; color: var(--acc); font-weight: 700 }
.r-nav { display: flex; justify-content: space-between; gap: 12px; margin-top: 46px; padding-top: 24px; border-top: 1px solid var(--line) }
.tools { position: fixed; right: 16px; bottom: 18px; display: flex; gap: 4px; background: var(--card); border: 1px solid var(--line); border-radius: 999px; padding: 5px; box-shadow: 0 8px 24px rgba(0, 0, 0, .12); z-index: 30 }
.tools button { border: 0; background: transparent; color: var(--ink); font: 600 .92rem var(--sans); width: 38px; height: 34px; border-radius: 999px; cursor: pointer } .tools button:hover { background: var(--bg2) }
.ad-slot { margin: 2em 0; min-height: 1px }
.prose p { font: 1.08rem/1.7 var(--serif); color: var(--ink2) } .prose h1 { margin-top: 30px }
.foot { border-top: 1px solid var(--line); margin-top: 50px; padding: 26px 0; color: var(--muted); font-size: .88rem }
ins.adsbygoogle[data-ad-status=unfilled] { display: none !important }
[hidden] { display: none !important }
