:root[data-theme="dark"] {
  --paper: #171815;
  --ink: #f2f1ea;
  --muted: #a9ab9f;
  --line: #3b3d36;
  --accent: #ff7b50;
  --card: #252620;
  color-scheme: dark;
}

body {
  transition: background-color .2s ease, color .2s ease;
}

.heart-icon {
  width: 1.15em;
  height: 1.15em;
  display: inline-block;
  overflow: visible;
  vertical-align: -.16em;
}

.heart-icon path {
  stroke: currentColor;
  stroke-width: 1.9;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.save .heart-icon {
  width: 18px;
  height: 18px;
}

.save:disabled,
.wishlist-action:disabled {
  cursor: not-allowed;
  opacity: .42;
}

.wishlist-action {
  display: inline-flex;
  align-items: center;
  gap: 7px;
}

.theme-switch {
  width: 48px;
  height: 28px;
  padding: 3px;
  border-radius: 999px;
  background: var(--line);
  transition: background .2s ease;
  flex: 0 0 auto;
}

.theme-switch span {
  display: block;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--paper);
  box-shadow: 0 1px 4px #0004;
  transition: transform .2s ease;
}

.theme-switch[aria-checked="true"] {
  background: var(--accent);
}

.theme-switch[aria-checked="true"] span {
  transform: translateX(20px);
}

:root[data-theme="dark"] .avatar,
:root[data-theme="dark"] .sponsor,
:root[data-theme="dark"] .view-toggle .active,
:root[data-theme="dark"] .bottom small {
  background: #2a2c25;
}

:root[data-theme="dark"] .search {
  background: #22231f;
}

:root[data-theme="dark"] .chip.active,
:root[data-theme="dark"] .primary,
:root[data-theme="dark"] #toast {
  background: #f2f1ea;
  color: #171815;
}

:root[data-theme="dark"] .bottom {
  background: #191a17f2;
}

:root[data-theme="dark"] .add.selected {
  background: #2f3b29;
  border-color: #465941;
  color: #c2dbb1;
}

@media (prefers-reduced-motion: reduce) {
  body,
  .theme-switch,
  .theme-switch span {
    transition: none;
  }
}

/* Use fixed icon boxes so the heart matches neighboring navigation icons. */
.heart-icon { width:18px; height:18px; flex:0 0 18px; vertical-align:middle; overflow:hidden; }
.bottom button > span { display:inline-flex; align-items:center; justify-content:center; width:22px; height:22px; line-height:1; }
.bottom .heart-icon { width:20px; height:20px; flex-basis:20px; }
.save { display:flex; align-items:center; justify-content:center; padding:0; }
.save .heart-icon { width:17px; height:17px; flex-basis:17px; }
.list .save .heart-icon { width:15px; height:15px; flex-basis:15px; }
.header-theme { display:flex; align-items:center; gap:10px; font-size:11px; color:var(--muted); }
/* Absolute positioning isolates the thumb from global/mobile button padding. */
button.theme-switch { position:relative; display:block; width:48px; min-width:48px; height:28px; padding:0; border:0; box-sizing:border-box; }
button.theme-switch > span { position:absolute; left:3px; top:3px; width:22px; height:22px; margin:0; transform:translateX(0); }
button.theme-switch[aria-checked="true"] > span { transform:translateX(20px); }
.setting-row .secondary:disabled { opacity:.55; cursor:default; }
.setting-row a.secondary { white-space:nowrap; }
.settings .footer-note { text-align:left; line-height:1.9; }
#main { touch-action:pan-y; }
.chips { touch-action:pan-x; }
@media(max-width:700px) { .header-right{gap:12px}.header-theme{gap:7px}.header-theme>span{display:none}.status{display:none}.brand-note{max-width:92px;line-height:1.6}.setting-row{gap:15px} }

/* Swipe panels follow the finger; the header and tab bar remain anchored. */
.swipe-viewport { position:fixed; left:0; right:0; z-index:4; overflow:hidden; pointer-events:none; background:var(--paper); contain:layout paint; }
.swipe-panel { position:absolute; inset:0; background:var(--paper); will-change:transform; backface-visibility:hidden; }
.swipe-panel > main { width:100%; min-height:100%; }
.swipe-panel .cover-stage img { transition:none; }
.settings > .setting-row:first-child { padding-top:0; }

.bottom button.active::before { display:none; }
#tab-indicator { position:absolute; top:0; left:0; height:3px; background:var(--accent); border-radius:0 0 3px 3px; pointer-events:none; will-change:transform,width; }
.reveal-card { opacity:0; transform:translate3d(0,26px,0); transition:opacity .65s ease var(--reveal-delay,0ms),transform .85s cubic-bezier(.22,1,.36,1) var(--reveal-delay,0ms); }
.reveal-card.is-visible { opacity:1; transform:translate3d(0,0,0); }
.swipe-panel .reveal-card { opacity:1; transform:none; transition:none; }
@media(prefers-reduced-motion:reduce) { #tab-indicator { transition:none!important; } .reveal-card { opacity:1; transform:none; transition:none; } }

.detail-topbar { display:flex; justify-content:flex-end; margin-bottom:4px; }
.detail-close { width:42px; height:42px; padding:0; border:1px solid var(--line); border-radius:50%; background:var(--paper); display:inline-flex; align-items:center; justify-content:center; transition:background-color .18s ease,transform .18s ease; }
.detail-close svg { width:18px; height:18px; fill:none; stroke:currentColor; stroke-width:1.7; stroke-linecap:round; }
.detail-close:hover { background:var(--card); }
.detail-close:active { transform:scale(.95); }
.detail-topbar + .detail { margin-top:16px; }

header[hidden] { display:none; }



.scan-tab-icon { width:20px; height:20px; fill:none; stroke:currentColor; stroke-width:1.6; stroke-linecap:round; }
.bottom { gap:26px; }
.scanner-layout { display:grid; grid-template-columns:1.1fr 1fr; gap:60px; align-items:center; max-width:1080px; }
.scanner-card { border:1px solid var(--line); border-radius:14px; background:var(--card); padding:18px; }
.scan-camera { position:relative; aspect-ratio:1.4; border-radius:9px; overflow:hidden; background:var(--paper); }
.scan-camera video { width:100%; height:100%; object-fit:cover; }
.scan-placeholder { display:flex; flex-direction:column; gap:12px; align-items:center; justify-content:center; height:100%; text-align:center; padding:32px; }
.scan-placeholder svg { width:62px; height:62px; color:var(--accent); margin-bottom:12px; }
.scan-placeholder strong { font-size:15px; font-weight:500; }
.scan-placeholder span { font-size:11px; color:var(--muted); }
.scan-frame { position:absolute; pointer-events:none; inset:26% 13%; border:1px solid var(--accent); border-radius:12px; box-shadow:0 0 0 200px #0001; opacity:.55; }
.scan-camera:has(video[hidden]) .scan-frame { display:none; }
.scan-message { color:var(--muted); font-size:12px; line-height:1.6; min-height:38px; margin:16px 2px; }
.scan-controls { display:flex; gap:10px; }
.scan-controls button { min-height:50px; flex:1; }
.scan-help h2 { font:500 30px/1.3 Manrope,Arial,sans-serif; letter-spacing:-1px; margin:13px 0; }
.scan-help p { color:var(--muted); line-height:1.9; max-width:390px; }
.scan-privacy { padding:18px 0; border-top:1px solid var(--line); border-bottom:1px solid var(--line); color:var(--muted); font-size:12px; line-height:1.8; margin:25px 0; }
.isbn-form label { display:block; font-size:12px; margin-bottom:10px; }
.isbn-field { display:flex; gap:8px; }
.isbn-field input { min-width:0; flex:1; padding:13px; background:var(--paper); color:var(--ink); border:1px solid var(--line); border-radius:5px; font-size:12px; }
.isbn-field button { white-space:nowrap; }
.scan-result { max-width:950px; margin:0 auto; }
.scan-result-grid { display:grid; grid-template-columns:.8fr 1fr; gap:45px; align-items:center; margin-top:16px; }
.scan-result-cover { border-radius:12px; background:var(--card); padding:35px; display:flex; align-items:center; justify-content:center; }
.scan-result-cover img { width:100%; max-width:220px; max-height:340px; object-fit:contain; filter:drop-shadow(8px 12px 9px #0003); }
.scan-result h1 { font:500 34px/1.2 Manrope,Arial,sans-serif; letter-spacing:-1.2px; margin:15px 0 10px; }
.scan-author { color:var(--muted); margin:0 0 23px; }
.scan-result dl { display:grid; grid-template-columns:90px 1fr; gap:10px; font-size:12px; margin-bottom:27px; }
.scan-result dt { color:var(--muted); }.scan-result dd { margin:0; overflow-wrap:anywhere; }
.scan-actions { display:grid; grid-template-columns:1fr 1fr; gap:10px; }.scan-actions button { min-height:62px; padding:14px; font-size:13px; }
.scan-actions button:disabled { opacity:.55; cursor:default; }
.scan-again { display:flex; align-items:center; justify-content:center; gap:10px; min-height:48px; width:100%; margin-top:12px; }
.scan-again svg { width:20px; height:20px; }
.scan-missing { max-width:430px; margin:30px auto; text-align:center; }
.scan-missing-icon svg { width:64px; height:64px; color:var(--accent); margin-bottom:28px; }
.scan-missing p { color:var(--muted); line-height:1.8; font-size:13px; margin:20px 0; }
.scan-missing .primary { display:block; padding:18px; }.scan-missing .scan-placeholder-note { font-size:11px; margin:12px 0; }
[hidden] { display:none!important; }
@media(max-width:700px) { .bottom{gap:0}.bottom button{padding:11px 7px;flex:1;min-width:0;font-size:9px}.scanner-layout{grid-template-columns:1fr;gap:30px}.scan-help h2{font-size:25px}.scan-result-grid{grid-template-columns:1fr;gap:24px}.scan-result-cover{padding:22px}.scan-result-cover img{max-height:205px;width:auto;max-width:100%}.scan-result h1{font-size:29px}.scan-camera{aspect-ratio:1.2}.scan-actions button{font-size:12px}.scan-help p{max-width:none} }

/* Show the full sensor image: no hidden barcode edges behind a cropped preview. */
.scan-camera { background:#161814; }
.scan-camera video { object-fit:contain; }
.scan-placeholder { background:var(--paper); }
.scan-frame { inset:22% 4%; box-shadow:none; border-style:dashed; }
.camera-options { display:flex; gap:10px; margin-top:12px; }
.camera-options:has([hidden]):not(:has(:not([hidden]))) { display:none; }
.camera-options select { min-width:0; flex:1; padding:11px; background:var(--paper); color:var(--ink); border:1px solid var(--line); border-radius:5px; font:inherit; font-size:12px; }
.camera-options button { white-space:nowrap; }

/* App chrome is independent of page panels, just like the bottom tab bar. */
:root { --app-header-height:92px; }
body > header { position:fixed; inset:0 0 auto; width:100%; margin:0; padding:0 5%; height:var(--app-header-height); z-index:6; background:var(--paper); }
body.has-app-header > #main { margin-top:var(--app-header-height); }
body:not(.has-app-header) > #main { margin-top:0; }
@media(max-width:700px) { :root { --app-header-height:73px; } }

/* The guide is sized to the contained video image, never its letterbox area. */
.scan-frame { inset:auto; max-width:100%; max-height:100%; }

body > header { transition:transform .22s cubic-bezier(.22,1,.36,1); will-change:transform; }
body > header.header-scroll-hidden { transform:translate3d(0,-100%,0); pointer-events:none; }
.scan-controls #scan-cancel,.scan-controls #scan-torch { min-height:52px; }
.scan-controls #scan-torch:disabled { opacity:.5; cursor:default; }
@media(prefers-reduced-motion:reduce) { body > header { transition:none; } }

.collection-icon { width:20px; height:20px; fill:none; stroke:currentColor; stroke-width:1.7; stroke-linecap:round; stroke-linejoin:round; }

/* Fixed text rows keep every catalog card aligned, including long studio names. */
.book .category { white-space:nowrap; overflow:hidden; text-overflow:ellipsis; line-height:1.4; height:1.4em; min-width:0; }
.grid:not(.list) .book { display:flex; flex-direction:column; }
.grid:not(.list) .book h3 { line-height:1.3; height:2.6em; min-height:2.6em; overflow:hidden; display:-webkit-box; -webkit-line-clamp:2; -webkit-box-orient:vertical; }
.grid:not(.list) .book .meta { height:3.4em; min-height:3.4em; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.grid:not(.list) .book .bookbottom { margin-top:auto; padding-top:10px; }
#books { overflow-anchor:none; }
body > header { transition:transform .34s cubic-bezier(.22,.8,.25,1); }
.book-offers[hidden]{display:none!important}.book-offers{margin-top:26px;padding:20px;border:1px solid var(--line);border-radius:16px;background:var(--paper)}.book-offers h3{margin:0 0 15px;font-size:16px}.offer-options{display:grid;gap:12px}.offer-condition{display:block;font-size:12px;opacity:.7;margin-bottom:5px}.offer-link{display:flex;justify-content:center;align-items:center;text-align:center;text-decoration:none;min-height:48px;padding:12px 16px;box-sizing:border-box}.book-offers .offer-note{font-size:11px;line-height:1.6;opacity:.65;margin:14px 0 0}.book-offers .offer-status{font-size:13px;margin:0;line-height:1.6}.offer-retry{margin-top:12px}

/* Override the alternating light cover stages in dark mode. */
:root[data-theme="dark"] .book { background: var(--paper); }
:root[data-theme="dark"] .book .cover-stage { background: var(--card); }

.gem-icon{width:18px;height:18px;fill:none;stroke:currentColor;stroke-width:1.6;stroke-linecap:round;stroke-linejoin:round;vertical-align:middle}
.gem-toggle.selected{background:#f8e4d9;color:#ab401d}.gem-toggle.selected .gem-icon{fill:#e9684030}
:root[data-theme="dark"] .gem-toggle{background:#292b25;color:#d7dacd}
:root[data-theme="dark"] .gem-toggle.selected{background:#503526;color:#ffaf83}
.collection-filters{margin:0 0 16px}.gem-filter{display:inline-flex;align-items:center;gap:8px}.gem-filter.active .gem-icon{fill:currentColor;fill-opacity:.2}

.search input{min-width:0;flex:1}.search-clear{display:inline-flex;align-items:center;justify-content:center;flex:0 0 32px;width:32px;height:36px;padding:6px;color:var(--muted)}.search-clear[hidden]{display:none}.search-clear svg{width:18px;height:18px;fill:none;stroke:currentColor;stroke-width:2;stroke-linecap:round}.chips .gem-filter{flex-shrink:0}
.cover-stage,.detail-art,.scan-result-cover,.mini-stack{-webkit-touch-callout:none;user-select:none}.cover-stage img,.detail-art img,.scan-result-cover img,.mini-stack img{-webkit-user-drag:none;-webkit-touch-callout:none;user-select:none}
.terms-link{padding:12px;color:var(--ink);text-decoration:underline;text-underline-offset:3px}.terms-open{overflow:hidden}.terms-dialog{color:var(--ink);background:var(--paper);border:1px solid var(--line);border-radius:20px;padding:24px;max-width:600px;width:calc(100% - 32px);max-height:80dvh;overflow:auto;box-shadow:0 24px 90px #0006}.terms-dialog::backdrop{background:#0009;backdrop-filter:blur(5px)}.terms-heading{display:flex;justify-content:space-between;gap:20px;align-items:center}.terms-heading h2{font-size:24px;margin:0}.terms-content h3{font-size:15px;margin:24px 0 8px}.terms-content p{font-size:13px;line-height:1.8;color:var(--muted)}.terms-content a{color:var(--ink);text-decoration:underline;text-underline-offset:3px}.scanner-layout{grid-template-columns:minmax(0,1fr);max-width:620px;gap:24px}.scan-help .isbn-form{margin-top:0}

.terms-inline-link{display:inline;padding:0;color:var(--ink);font:inherit;text-align:left;text-decoration:underline;text-underline-offset:3px}.terms-content li{font-size:13px;line-height:1.8;margin:16px 0;color:var(--muted)}.terms-heading .detail-close{flex-shrink:0}
#pwa-update{position:fixed;z-index:60;left:50%;bottom:calc(88px + env(safe-area-inset-bottom));transform:translateX(-50%);width:max-content;max-width:calc(100% - 24px);display:flex;gap:12px;align-items:center;background:var(--ink);color:var(--paper);padding:12px 16px;border-radius:12px;box-shadow:0 8px 28px #0004;font-size:12px}#pwa-update button{color:inherit;font-weight:600;min-height:36px;flex-shrink:0}#pwa-update [data-update-app]{text-decoration:underline;text-underline-offset:3px}[data-install-app][hidden]{display:none}

html{overscroll-behavior-y:none}#pull-refresh{position:fixed;top:calc(82px + env(safe-area-inset-top));left:50%;z-index:55;width:38px;height:38px;border-radius:50%;display:grid;place-items:center;background:var(--paper);box-shadow:0 3px 16px #0004;opacity:0;pointer-events:none;transform:translate(-50%,-20px);transition:opacity .2s,transform .2s}#pull-refresh.visible{opacity:1;transform:translate(-50%,calc(var(--pull,60px)*.35))}#pull-refresh span{width:21px;height:21px;border:2px solid var(--line);border-top-color:var(--accent);border-radius:50%;transform:rotate(calc(var(--pull,0px)/1px*4deg))}#pull-refresh.spinning span{animation:refresh-spin .8s linear infinite}@keyframes refresh-spin{from{transform:rotate(0deg)}to{transform:rotate(360deg)}}@media(prefers-reduced-motion:reduce){#pull-refresh{transition:none}#pull-refresh.spinning span{animation-duration:1.8s}}

.terms-content .license-list{list-style:none;padding:0;margin:20px 0}.terms-content .license-list li{margin:0;border-bottom:1px solid var(--line)}.license-entry{display:grid;grid-template-columns:1fr auto;gap:4px 16px;text-align:left;width:100%;padding:18px 0;background:none;border:0;color:var(--ink);cursor:pointer;font:inherit}.license-entry strong{font-size:14px}.license-entry span:nth-child(2){grid-row:2;color:var(--muted);font-size:12px}.license-entry span:last-child{grid-column:2;grid-row:1 / 3;align-self:center;font-size:24px}.terms-content .license-text{white-space:pre-wrap;overflow-wrap:anywhere;font:12px/1.8 ui-monospace,monospace;color:var(--ink);margin:20px 0}.terms-heading{position:sticky;top:-24px;background:var(--paper);z-index:1;padding:12px 0}

.support-options{display:grid;gap:12px;margin:24px 0 8px}.support-link{display:flex;justify-content:space-between;align-items:center;text-decoration:none!important;padding:16px!important}.support-link.unavailable{opacity:.6;cursor:default}.support-link small{font-size:11px}.welcome-steps{padding-left:22px}.welcome-steps strong{display:block;color:var(--ink)}.welcome-start{width:100%;margin:10px 0}.info-dialog{animation:info-arrive .25s ease both}@keyframes info-arrive{from{opacity:0;transform:translateY(12px)}to{opacity:1;transform:translateY(0)}}@media(prefers-reduced-motion:reduce){.info-dialog{animation:none}}

/* A single content scroller keeps short dialogs snug and long notices readable. */
.terms-dialog{padding:0;overflow:hidden;max-height:min(80dvh,760px);height:auto;min-height:0;overscroll-behavior:contain}
.terms-dialog[open]{display:flex;flex-direction:column}
.terms-dialog .terms-heading{position:static;flex:0 0 auto;padding:20px 24px 16px;gap:16px;border-bottom:1px solid var(--line)}
.terms-dialog .terms-heading h2{font-size:22px;line-height:1.3;min-width:0}
.terms-dialog .terms-content{min-height:0;overflow-y:auto;overflow-x:hidden;overscroll-behavior:contain;padding:4px 24px 24px;scroll-behavior:auto}
.terms-dialog .terms-content>:last-child{margin-bottom:0}
.terms-content .license-text{font:inherit;white-space:normal;overflow-wrap:anywhere;margin:0}
.terms-content .license-text p{font-size:14px;line-height:1.75;margin:16px 0;color:var(--ink)}
.terms-content .license-text h3{font-size:14px;line-height:1.6;margin:24px 0 12px}
.welcome-label{display:inline-flex;align-items:center;gap:4px;color:var(--ink);white-space:nowrap;font-weight:500}
.welcome-label svg{width:17px;height:17px;fill:none;stroke:var(--accent);stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round;flex:none}
html:has(.terms-dialog[open]){overflow:hidden}
@media(max-width:480px){.terms-dialog .terms-heading{padding:18px 20px 14px}.terms-dialog .terms-content{padding:4px 20px 20px}.terms-dialog .terms-heading h2{font-size:20px}}

.bottom button{transition:color 80ms ease}.offer-isbn{display:flex;flex-wrap:wrap;align-items:center;gap:10px;margin:12px 0;font-size:12px}.offer-isbn .select{max-width:100%}

.scan-mode-row{max-width:620px;margin-bottom:24px;padding-top:0}.scan-mode-row p{max-width:420px}.settings .last-export{margin-top:8px;font-size:11px}

#scan-added-notice{position:fixed;left:50%;bottom:calc(96px + env(safe-area-inset-bottom));transform:translateX(-50%);width:min(380px,calc(100% - 32px));display:flex;align-items:center;gap:16px;padding:16px;background:var(--paper);color:var(--ink);border:1px solid var(--line);border-radius:16px;box-shadow:0 12px 40px #0004;z-index:60;pointer-events:none;animation:scan-notice-in .22s ease both}
#scan-added-notice img{width:54px;height:72px;object-fit:contain;flex:none;border-radius:3px;background:var(--card)}#scan-added-notice strong{display:flex;align-items:center;gap:6px;font-size:14px;color:#23733b}#scan-added-notice strong svg{width:19px;height:19px;fill:none;stroke:currentColor;stroke-width:2.5;flex:none}#scan-added-notice span{display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;font-size:12px;line-height:1.5;margin-top:6px}#scan-added-notice.leaving{animation:scan-notice-out .22s ease both}:root[data-theme="dark"] #scan-added-notice strong{color:#86d69a}
@keyframes scan-notice-in{from{opacity:0;transform:translate(-50%,10px)}to{opacity:1;transform:translate(-50%,0)}}@keyframes scan-notice-out{from{opacity:1;transform:translate(-50%,0)}to{opacity:0;transform:translate(-50%,6px)}}.donate-link{gap:12px;justify-content:center!important}.donate-link svg{width:22px;height:22px;fill:none;stroke:currentColor;stroke-width:1.8;flex:none}.terms-content a.donate-link{color:var(--paper)}
@media(prefers-reduced-motion:reduce){#scan-added-notice,#scan-added-notice.leaving{animation:none}}


.discover-icon{width:22px;height:22px;display:block;fill:none;stroke:currentColor;stroke-width:1.7;stroke-linecap:round;stroke-linejoin:round}.scan-preferences{max-width:620px;margin-top:24px}.scan-preferences .setting-row{margin:0;padding:22px 0}.scan-preferences .setting-row:first-child{padding-top:0}

/* Independent editions, automatically linked by normalized title. */
.edition-card-meta{display:flex;align-items:center;gap:6px;flex-wrap:wrap;margin:0 0 10px;min-width:0;font-size:10px}.edition-label{max-width:100%;overflow:hidden;white-space:nowrap;text-overflow:ellipsis;border:1px solid var(--line,#7776);padding:3px 7px;border-radius:4px}.other-editions-link{font-size:10px;text-decoration:underline;text-underline-offset:3px}.profile-edition-label{display:inline-block;border:1px solid var(--line,#7776);padding:5px 10px;border-radius:5px;font-size:12px!important}.related-editions{margin:42px 0 24px;padding-top:28px;border-top:1px solid var(--line,#7776);scroll-margin-top:24px}.related-editions h2{font-size:24px;letter-spacing:-.6px;margin-bottom:8px}.editions-intro{font-size:13px;opacity:.7}.edition-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(240px,1fr));gap:14px}.edition-option{display:flex;align-items:center;gap:16px;text-decoration:none;color:inherit;border:1px solid var(--line,#7776);border-radius:8px;padding:14px}.edition-option img{width:70px;height:95px;object-fit:contain;flex-shrink:0}.edition-option>span{display:grid;gap:5px;min-width:0}.edition-option strong{font-size:13px}.edition-title{font-size:12px;line-height:1.4}.edition-option small{font-size:11px;opacity:.75}.edition-option:hover,.edition-option:focus-visible{border-color:#ff7b50}.edition-option:focus-visible{outline:2px solid #ff7b50;outline-offset:3px}@media(max-width:600px){.edition-grid{grid-template-columns:1fr}}

.welcome-panel[hidden]{display:none}.backup-enable{display:flex;align-items:center;gap:12px;margin:22px 0}.backup-enable input{width:20px;height:20px;accent-color:#ff7b50}.backup-days{display:grid;gap:8px;margin:20px 0}.backup-days input{width:120px;padding:12px;border-radius:6px;border:1px solid #8888;background:transparent;color:inherit;font:inherit}.backup-dialog .actions{flex-wrap:wrap}.welcome-panel h3{font-size:21px}.welcome-panel .actions{margin-top:24px}

.review-app-icon{width:64px;height:64px;border-radius:16px;margin-bottom:8px}.review-actions{display:grid;gap:12px;margin-top:24px}.review-actions .primary,.review-actions .secondary{text-align:center;justify-content:center}.reminder-preview-note{font-size:12px;color:var(--muted)}

/* Compact, consistent reminders; scoped away from terms and import dialogs. */
.polished-reminder{max-width:440px;border-radius:24px;max-height:calc(100dvh - 32px);box-shadow:0 32px 100px #0008}
.polished-reminder .terms-heading{display:block;border:0;padding:28px 28px 0;background:transparent}
.reminder-mark{display:grid;place-items:center;width:48px;height:48px;border-radius:15px;background:color-mix(in srgb,var(--accent) 12%,transparent);color:var(--accent);margin-bottom:22px;border:1px solid color-mix(in srgb,var(--accent) 20%,transparent)}
.reminder-mark svg{width:25px;height:25px;fill:none;stroke:currentColor;stroke-width:1.6;stroke-linecap:round;stroke-linejoin:round}
.reminder-eyebrow{font-size:10px;letter-spacing:.13em;font-weight:700;color:var(--muted);margin-bottom:9px}
.polished-reminder .terms-heading h2{font-size:26px;font-weight:650;line-height:1.18;letter-spacing:-.7px;max-width:330px;text-wrap:balance}
.polished-reminder .terms-content{padding:0 28px 24px}
.polished-reminder .reminder-intro{font-size:14px;line-height:1.65;margin:14px 0 24px;text-wrap:pretty}
.reminder-buttons{display:grid;gap:10px;margin-top:24px}
.polished-reminder .reminder-buttons .primary,.polished-reminder .reminder-buttons .secondary{display:flex;align-items:center;justify-content:center;gap:12px;min-height:48px;width:100%;border-radius:12px;padding:12px 16px;font-size:14px;font-weight:650;text-decoration:none;line-height:1.4}
.polished-reminder .reminder-buttons .primary{background:var(--accent);color:#171815;border:1px solid transparent}
.polished-reminder .reminder-buttons .secondary{background:transparent;border:1px solid var(--line);color:var(--ink)}
.reminder-quiet{display:block;margin:12px auto 0;min-height:44px;padding:10px 18px;font-size:12px;color:var(--muted);background:transparent;border:0;text-decoration:none}
.polished-reminder .reminder-preview-note{font-size:10px;line-height:1.5;text-align:center;color:var(--muted);margin:12px 0 0}
.review-brand-row{display:flex;align-items:center;gap:12px;padding:16px;border:1px solid var(--line);border-radius:14px;background:var(--card)}
.review-brand-row img{border-radius:12px;flex:none}.review-brand-row strong{display:block;font-size:15px}.review-brand-row span{display:block;font-size:12px;color:var(--muted);margin-top:4px}
.reminder-status{display:flex;align-items:center;gap:18px;padding:18px;border:1px solid var(--line);background:var(--card);border-radius:14px}
.reminder-day-count{flex:none;font-size:36px;line-height:1;font-weight:650;letter-spacing:-1px;color:var(--accent);min-width:52px;text-align:center}.reminder-day-count small{display:block;font-size:11px;letter-spacing:0;font-weight:500;color:var(--muted);margin-top:6px}
.reminder-status strong{display:block;font-size:13px;line-height:1.5}.reminder-status div>span{display:block;font-size:12px;line-height:1.5;color:var(--muted);margin-top:4px}
.polished-reminder .reminder-helper{font-size:12px;line-height:1.65;margin:16px 0 0}
.reminder-toggle-row{display:flex;align-items:center;justify-content:space-between;gap:16px;padding:18px 16px;border:1px solid var(--line);border-radius:14px;background:var(--card);cursor:pointer}
.reminder-toggle-row strong,.reminder-interval strong{display:block;font-size:13px;font-weight:650}.reminder-toggle-row small,.reminder-interval small{display:block;font-size:11px;color:var(--muted);line-height:1.5;margin-top:5px}
.reminder-switch{position:relative;width:44px;height:26px;flex:none}.reminder-switch input{position:absolute;inset:0;opacity:0;margin:0;width:100%;height:100%;cursor:pointer;z-index:1}.reminder-switch>span{display:block;width:44px;height:26px;border-radius:20px;background:var(--line);transition:background .2s}.reminder-switch>span:after{content:'';position:absolute;top:3px;left:3px;width:20px;height:20px;border-radius:50%;background:var(--ink);transition:transform .2s}.reminder-switch input:checked+span{background:var(--accent)}.reminder-switch input:checked+span:after{transform:translateX(18px);background:#171815}.reminder-switch input:focus-visible+span{outline:2px solid var(--accent);outline-offset:4px}
.reminder-interval{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:20px 2px 0}.reminder-number{display:flex;align-items:center;gap:6px;border:1px solid var(--line);border-radius:10px;padding:8px 10px;background:var(--card)}.reminder-number input{width:55px;min-height:28px;border:0;background:transparent;color:var(--ink);font-family:inherit;font-size:17px;font-weight:600;text-align:center;padding:0}.reminder-number span{font-size:12px;color:var(--muted)}
@media(max-width:480px){.polished-reminder .terms-heading{padding:24px 22px 0}.polished-reminder .terms-content{padding:0 22px 20px}.polished-reminder .terms-heading h2{font-size:25px}.reminder-mark{margin-bottom:18px}}
@media(max-height:650px){.polished-reminder .terms-heading{padding-top:18px}.reminder-mark{width:36px;height:36px;margin-bottom:12px}.polished-reminder .reminder-intro{margin-bottom:16px}.reminder-buttons{margin-top:16px}}
@media(prefers-reduced-motion:reduce){.reminder-switch>span,.reminder-switch>span:after{transition:none}}

.card-isbns{min-height:34px;margin:10px 0 4px;display:grid;align-content:start;gap:4px;font-size:10px;line-height:1.4;color:var(--muted);overflow-wrap:anywhere}.card-isbns b{font-weight:600;color:var(--ink);margin-right:5px}.no-isbn{font-size:11px}.kickstarter-block{margin:20px 0}.kickstarter-link{display:flex;align-items:center;justify-content:center;gap:14px;padding:16px;border-radius:12px;background:#063b2b;color:#fff!important;border:1px solid #05ce78;text-decoration:none!important}.kickstarter-link img{width:34px;height:38px;object-fit:contain;flex:none}.kickstarter-link small{display:block;font-size:12px;line-height:1.6;color:#c3efdb}.kickstarter-link strong{display:block;font-size:15px;line-height:1.5}.kickstarter-block>p{font-size:11px!important;line-height:1.5!important;color:var(--muted);margin:9px 0 0}.book .kickstarter-link{gap:8px;padding:11px}.book .kickstarter-link strong{font-size:12px}.book .kickstarter-link img{width:24px;height:28px}.book .kickstarter-block{margin:12px 0 0}
