/* Grand Library Hall — scene, decade shelves, year carousel. */

.view-enter { animation: viewIn .45s ease both; }
@keyframes viewIn { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }

/* ---------- hall scene ---------- */
.hall-wrap { max-width: 1400px; margin: 0 auto; padding: 18px 16px 70px; }
/* ---------- 2.5D camera stage ---------- */
.hall-stage {
  position: relative;
  overflow: hidden;
  border-radius: 14px;
  border: 1px solid rgba(212, 169, 78, .35);
  box-shadow: 0 24px 70px rgba(0, 0, 0, .6);
  background: #0d0803;
  aspect-ratio: 16 / 9;
  max-height: 86vh;
  min-height: 380px;
  touch-action: none;
  cursor: grab;
  user-select: none;
  -webkit-user-select: none;
}
/* Touch screens: a vertical drag must scroll the PAGE, not fight the camera —
   with touch-action:none a landscape phone had no way to scroll down at all
   (Sapa, 2026-10-16). Horizontal drags still reach the camera. */
@media (pointer: coarse) {
  .hall-stage { touch-action: pan-y; }
}
/* Short landscape windows: let the stage take the scene's natural height so
   the whole hall is visible after a short page scroll — no cropped fit. */
@media (max-height: 500px) {
  .hall-stage { max-height: none; min-height: 0; }
}
.hall-stage.panning { cursor: grabbing; }
.hall-svg {
  display: block;
  width: 1600px;
  height: 900px;
  transform-origin: 0 0;
}
/* decorative SVG layers must never swallow clicks meant for the bays */
.hall-svg .bay, .hall-svg .bay * { pointer-events: auto; }
.bay { cursor: pointer; outline: none; }
.bay .bay-glow { transition: opacity .25s; }
.teke-sign { cursor: pointer; }
.teke-sign:focus { outline: 2px solid #d4a94e; outline-offset: 4px; }
.future-portal { cursor: pointer; }
.future-portal:focus { outline: 2px solid #5adcff; outline-offset: 4px; }

/* ---------- the future (2031 →) : sci-fi room ---------- */
.future-view {
  position: relative;
  max-width: 1200px; margin: 0 auto;
  padding: 26px 28px 64px;
  background: radial-gradient(ellipse at 50% 0%, #1b1440 0%, #0a0620 55%, #05030f 100%);
  border-radius: 14px;
  border: 1px solid rgba(90, 220, 255, .35);
  overflow: hidden;
  box-shadow: 0 24px 70px rgba(0, 0, 0, .6), inset 0 0 120px rgba(40, 80, 220, .12);
}
.stars { position: absolute; inset: 0; pointer-events: none; }
.star { position: absolute; background: #cfeaff; border-radius: 50%; animation: twinkle 3.2s infinite ease-in-out; }
@keyframes twinkle { 0%, 100% { opacity: .2; } 50% { opacity: 1; } }
.neon-floor {
  position: absolute; left: -20%; right: -20%; bottom: -14%; height: 48%;
  pointer-events: none;
  background:
    repeating-linear-gradient(90deg, rgba(90, 220, 255, .30) 0 2px, transparent 2px 72px),
    repeating-linear-gradient(0deg, rgba(90, 220, 255, .30) 0 2px, transparent 2px 46px);
  transform: perspective(560px) rotateX(62deg);
  transform-origin: top center;
  -webkit-mask-image: linear-gradient(to bottom, transparent, #000 42%);
  mask-image: linear-gradient(to bottom, transparent, #000 42%);
}
.future-view .crumb { position: relative; z-index: 2; }
.future-plaque {
  font-family: Georgia, serif; font-size: 1.5rem; letter-spacing: 4px;
  color: #9df1ff; text-shadow: 0 0 14px rgba(90, 220, 255, .9), 0 0 44px rgba(90, 220, 255, .5);
  border: 1px solid rgba(90, 220, 255, .55); border-radius: 10px;
  padding: 10px 26px; background: rgba(10, 20, 50, .55);
}
.future-decor {
  position: relative; z-index: 2;
  display: flex; justify-content: space-between; align-items: flex-end;
  margin: 18px 6px 6px; min-height: 150px;
}
.robot { filter: drop-shadow(0 0 14px rgba(90, 220, 255, .45)); animation: hover 4.5s ease-in-out infinite; }
.flyer { filter: drop-shadow(0 0 16px rgba(90, 220, 255, .5)); animation: hover 3.4s ease-in-out infinite; }
@keyframes hover { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-14px); } }
.f-shelf { position: relative; z-index: 2; margin: 30px 0 6px; padding: 0 18px; }
.f-top { display: flex; align-items: flex-end; gap: 18px; }
.f-year {
  width: 110px; flex: 0 0 auto; text-align: right;
  font-family: Georgia, serif; font-size: 1.7rem; color: #7de6ff;
  text-shadow: 0 0 12px rgba(125, 230, 255, .8);
  text-decoration: none; padding-bottom: 22px;
}
.f-year:hover { color: #d8f6ff; }
.f-books { flex: 1 1 auto; min-width: 0; }
.f-board {
  height: 14px; border-radius: 7px; margin-top: 2px;
  background: linear-gradient(#3a4a6e, #141c34);
  border: 1px solid rgba(125, 230, 255, .5);
  box-shadow: 0 0 18px rgba(90, 220, 255, .45), 0 10px 24px rgba(0, 0, 0, .6);
}
.spine.holo {
  background: linear-gradient(rgba(125, 230, 255, .30), rgba(125, 230, 255, .08));
  border: 1px solid rgba(125, 230, 255, .65);
  box-shadow: 0 0 14px rgba(90, 220, 255, .35), inset 0 0 12px rgba(125, 230, 255, .25);
}
.spine.holo .spine-band { background: rgba(125, 230, 255, .8); }
.spine.holo .spine-title { color: #d8f6ff; text-shadow: 0 0 8px rgba(125, 230, 255, .9); }
.future-note {
  position: relative; z-index: 2;
  text-align: center; color: #9db8d8; font-style: italic;
  margin: 30px 0 10px; font-size: 1.05rem;
}
@media (max-width: 720px) {
  .future-view { padding: 18px 14px 48px; }
  .f-top { gap: 12px; }
  .f-year { width: 64px; font-size: 1.3rem; }
  .future-decor { min-height: 110px; }
  .robot { width: 92px; height: auto; }
  .flyer { width: 140px; height: auto; }
}
.hall-controls {
  position: absolute; right: 12px; bottom: 12px;
  display: flex; gap: 8px; z-index: 5;
}
.hall-controls button {
  width: 42px; height: 42px; border-radius: 50%;
  border: 1px solid rgba(212, 169, 78, .6);
  background: rgba(20, 12, 5, .85); color: #d4a94e;
  font-size: 20px; line-height: 1; cursor: pointer;
}
.hall-controls button:hover { background: rgba(60, 36, 14, .95); }
.teke-caption {
  position: absolute; left: 12px; bottom: 12px; z-index: 5;
  max-width: 330px;
  background: rgba(20, 12, 5, .93);
  border: 1px solid rgba(212, 169, 78, .5);
  color: #e8d5a8; padding: 10px 14px; border-radius: 10px;
  font-size: .9rem; line-height: 1.45;
}
.bay:hover .bay-glow, .bay:focus-visible .bay-glow { opacity: .35; }
.bay .plaque-text { transition: fill .25s; }
.bay:hover .plaque-text, .bay:focus-visible .plaque-text { fill: #ffe9b8; }
.mote { animation: drift 9s ease-in-out infinite alternate; }
@keyframes drift { from { transform: translate(0, 0); opacity: .12; } to { transform: translate(14px, -34px); opacity: .5; } }

.decade-nav { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; margin-top: 20px; }

.special-shelf { max-width: 1100px; margin: 34px auto 0; padding: 0 20px; }

/* ---------- shared shelf bits ---------- */
.crumb {
  display: flex; align-items: center; gap: 18px; flex-wrap: wrap;
  max-width: 1100px; margin: 0 auto; padding: 26px 20px 4px;
}
.spine-row {
  display: flex; align-items: flex-end; gap: 7px;
  overflow-x: auto; padding: 12px 6px 0; min-height: 196px;
  scrollbar-width: thin;
  scrollbar-color: #c49a4a rgba(168, 129, 58, .25);
}
.spine-row::-webkit-scrollbar { height: 10px; }
.spine-row::-webkit-scrollbar-track { background: rgba(168, 129, 58, .25); border-radius: 5px; }
.spine-row::-webkit-scrollbar-thumb { background: linear-gradient(#cfa14e, #8a6a2e); border-radius: 5px; border: 1px solid rgba(0, 0, 0, .4); }
/* Timeline shelf: books stand where their month falls (Jan left → Dec right);
   spines inside are positioned in px by hall.js layoutTimelineRows(). */
.spine-row.timeline { display: block; position: relative; overflow: visible; }
/* Dense years (more books than the row holds even at the smallest spine
   width): the row scrolls horizontally instead of letting spines overlap. */
.spine-row.timeline.dense { overflow-x: auto; scrollbar-width: thin; scrollbar-color: #c49a4a rgba(168, 129, 58, .25); }
.spine-row.timeline.dense::-webkit-scrollbar { height: 10px; }
.spine-row.timeline.dense::-webkit-scrollbar-track { background: rgba(168, 129, 58, .25); border-radius: 5px; }
.spine-row.timeline.dense::-webkit-scrollbar-thumb { background: linear-gradient(#cfa14e, #8a6a2e); border-radius: 5px; border: 1px solid rgba(0, 0, 0, .4); }
.spine {
  --cover: #2b6cb0;
  width: 42px; flex: 0 0 auto;
  border-radius: 3px 6px 6px 3px;
  background:
    linear-gradient(90deg, rgba(0,0,0,.5) 0 8px, rgba(255,255,255,.09) 10px, rgba(255,255,255,0) 17px),
    var(--cover);
  box-shadow: inset 2px 0 4px rgba(0,0,0,.4), 4px 6px 12px rgba(0,0,0,.5);
  display: flex; flex-direction: column; align-items: center; justify-content: space-between;
  padding: 13px 4px; cursor: pointer;
  transition: transform .2s ease;
}
.spine:hover, .spine:focus-visible { transform: translateY(-8px); }
.spine-band { width: 70%; height: 5px; background: rgba(212,169,78,.8); border-radius: 2px; flex: 0 0 auto; }
.spine-title {
  writing-mode: vertical-rl;
  font-family: Georgia, serif; font-size: .78rem; line-height: 1.2;
  color: #f8ecd2; text-shadow: 0 1px 2px rgba(0,0,0,.65);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  max-height: 68%; flex: 1 1 auto; margin: 8px 0;
}
.spine-empty { opacity: .55; font-style: italic; padding: 0 10px 34px; white-space: nowrap; }

/* ---------- decade view ---------- */
.decade-shelves { max-width: 1100px; margin: 0 auto; padding: 14px 0 80px; }
.d-shelf { padding: 0 20px; margin-bottom: 38px; }
.d-top { display: flex; align-items: flex-end; gap: 20px; }
.d-year {
  flex: 0 0 auto; width: 104px; text-align: right;
  font-family: Georgia, serif; font-size: 1.9rem; color: var(--gold);
  text-decoration: none; padding-bottom: 26px; line-height: 1;
}
.d-year:hover { color: #ffe9b8; }
.d-books { flex: 1 1 auto; min-width: 0; position: relative; }
/* scroll buttons on crowded shelves — shown only when the row overflows */
.shelf-arrow {
  position: absolute; top: 46%; transform: translateY(-50%); z-index: 5;
  width: 52px; height: 52px; border-radius: 50%; padding: 0 0 4px;
  background: radial-gradient(circle at 35% 30%, #ffedb5 0%, #f3cd72 38%, #d4a94e 68%, #a8771f 100%);
  color: #3a240e;
  border: 2px solid #6e4f14;
  box-shadow: 0 0 16px rgba(255, 209, 102, .85), 0 0 34px rgba(255, 180, 60, .45),
    0 4px 10px rgba(0, 0, 0, .55), inset 0 1px 3px rgba(255, 255, 255, .65);
  font-size: 32px; font-weight: 700; line-height: 1; cursor: pointer;
  display: none; align-items: center; justify-content: center;
  transition: box-shadow .15s ease, transform .15s ease;
}
.d-books.scrollable .shelf-arrow, .capsule-scroll-wrap.scrollable .shelf-arrow { display: flex; }
.shelf-arrow.left { left: -10px; }
.shelf-arrow.right { right: -10px; }
.shelf-arrow:disabled { opacity: .38; filter: saturate(.45); box-shadow: 0 2px 6px rgba(0, 0, 0, .5); cursor: default; }
.shelf-arrow:hover:not(:disabled) {
  box-shadow: 0 0 22px rgba(255, 217, 130, 1), 0 0 46px rgba(255, 190, 70, .6),
    0 5px 12px rgba(0, 0, 0, .55), inset 0 1px 3px rgba(255, 255, 255, .75);
  transform: translateY(-50%) scale(1.08);
}

/* ---------- year view (carousel) ---------- */
.year-view { overflow: hidden; }
.car-title-line {
  text-align: center; font-family: Georgia, serif;
  font-size: 1.7rem; color: var(--gold);
  min-height: 2.6em; padding: 12px 20px 0;
  text-shadow: 0 2px 8px rgba(0,0,0,.5);
}
.carousel {
  display: flex; align-items: flex-end; gap: 30px;
  overflow-x: auto;
  scrollbar-width: thin;
  scrollbar-color: #a8813a rgba(0,0,0,.25);
  padding: 26px calc(50vw - 100px) 48px;
  perspective: 1400px;
}
.carousel::-webkit-scrollbar { height: 10px; }
.carousel::-webkit-scrollbar-track { background: rgba(0,0,0,.25); border-radius: 6px; }
.carousel::-webkit-scrollbar-thumb { background: #a8813a; border-radius: 6px; }
.car-book { flex: 0 0 auto; width: 200px; height: 290px; cursor: pointer; outline: none; }
.car-book-3d {
  --cover: #2b6cb0;
  width: 100%; height: 100%;
  border-radius: 4px 10px 10px 4px;
  background:
    linear-gradient(100deg, rgba(0,0,0,.55) 0, rgba(0,0,0,.55) 26px,
      rgba(255,255,255,.13) 30px, rgba(255,255,255,0) 46px),
    var(--cover);
  box-shadow: inset 4px 0 8px rgba(0,0,0,.35), 10px 14px 30px rgba(0,0,0,.6);
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  text-align: center; padding: 22px 16px 22px 42px; position: relative;
  transform: rotateY(58deg);
  transition: transform .5s cubic-bezier(.2,.7,.3,1.15);
}
.car-book-3d::after {
  content: ""; position: absolute; top: 6px; bottom: 6px; right: 0; width: 7px;
  background: repeating-linear-gradient(to bottom, #f3ecdb 0 2px, #cfc4a8 2px 3px);
  border-radius: 0 6px 6px 0;
}
.car-book.focused .car-book-3d { transform: rotateY(0deg) translateY(-10px) scale(1.04); }
.car-book:focus-visible .car-book-3d { box-shadow: inset 4px 0 8px rgba(0,0,0,.35), 0 0 0 3px var(--gold), 10px 14px 30px rgba(0,0,0,.6); }
.car-band { position: absolute; left: 0; right: 7px; top: 30px; height: 30px; background: rgba(212,169,78,.85); }
.car-title { font-family: Georgia, serif; font-size: 1.25rem; line-height: 1.35; color: #f8ecd2; text-shadow: 0 2px 4px rgba(0,0,0,.6); }
.car-month { display: inline-block; margin-bottom: 8px; padding: 2px 12px; font-size: .72rem; letter-spacing: .18em;
  text-transform: uppercase; color: #f3dfae; border: 1px solid rgba(214,178,106,.6); border-radius: 999px;
  background: rgba(0,0,0,.35); }
.car-sub { margin-top: 10px; font-size: .8rem; color: rgba(248,236,210,.75); font-style: italic; }
.car-hint { text-align: center; opacity: .6; font-size: .9rem; padding-bottom: 60px; }

/* ---------- responsive ---------- */
@media (max-width: 720px) {
  .topbar { flex-wrap: wrap; gap: 10px; padding: 12px 16px; }
  .topbar .who { flex-basis: 100%; order: 5; font-size: .85rem; }
  .d-top { gap: 12px; }
  .d-year { width: 64px; font-size: 1.4rem; padding-bottom: 22px; }
  .spine { width: 38px; }
  .car-book { width: 160px; height: 232px; }
  .carousel { gap: 22px; padding-left: calc(50vw - 80px); padding-right: calc(50vw - 80px); }
  .car-title { font-size: 1.05rem; }
  .crumb { gap: 12px; }
}

/* ---------- family games ---------- */
.game-card-btn { cursor: pointer; }
.game-card-btn .games-glow { animation: gameGlowPulse 2.6s ease-in-out infinite; }
.game-card-btn[data-game="match"] .games-glow { animation-delay: 1.3s; }
@keyframes gameGlowPulse {
  0%, 100% { opacity: .14; }
  50% { opacity: .3; }
}
.games-view { max-width: 860px; margin: 0 auto; padding: 26px 28px 64px; }
.games-tag { text-align: center; color: #cdbb96; font-size: 1.05rem; font-style: italic; margin: 18px 0 26px; }
.game-cards { display: flex; gap: 22px; justify-content: center; flex-wrap: wrap; }
.game-card {
  flex: 1 1 260px; max-width: 340px; cursor: pointer;
  background: linear-gradient(160deg, rgba(44,63,110,.55), rgba(20,16,8,.85));
  border: 2px solid rgba(255,209,102,.55); border-radius: 16px;
  padding: 26px 22px; color: #f8ecd2; font-family: inherit;
  display: flex; flex-direction: column; gap: 10px; align-items: center; text-align: center;
  box-shadow: 0 0 22px rgba(255,209,102,.18);
  transition: transform .18s ease, box-shadow .18s ease;
}
.game-card:hover { transform: translateY(-4px); box-shadow: 0 0 34px rgba(255,209,102,.35); }
.game-emoji { font-size: 2.6rem; }
.game-card b { font-size: 1.3rem; font-family: Georgia, serif; letter-spacing: 1px; }
.game-card span:last-child { opacity: .75; font-size: .92rem; line-height: 1.5; }
#game-stage { margin-top: 30px; }
.games-loading, .games-empty { text-align: center; opacity: .7; padding: 30px 0; }
.quiz-card {
  background: rgba(12,9,4,.72); border: 1px solid rgba(212,169,78,.4);
  border-radius: 16px; padding: 26px 26px 30px; max-width: 640px; margin: 0 auto;
}
.quiz-meta { display: flex; justify-content: space-between; opacity: .75; font-size: .9rem; margin-bottom: 14px; }
.quiz-q { font-family: Georgia, serif; font-size: 1.45rem; color: #f8ecd2; margin-bottom: 20px; line-height: 1.4; }
.quiz-choices { display: grid; gap: 10px; }
.quiz-choice {
  text-align: left; cursor: pointer; font-size: 1.02rem; font-family: inherit;
  background: rgba(255,255,255,.05); color: #f3e3bb;
  border: 1px solid rgba(212,169,78,.45); border-radius: 10px; padding: 12px 16px;
  transition: background .15s ease, transform .1s ease;
}
.quiz-choice:hover:not(:disabled) { background: rgba(212,169,78,.18); transform: translateX(3px); }
.quiz-choice:disabled { cursor: default; opacity: .85; }
.quiz-choice.right { background: rgba(46,204,113,.25); border-color: #2ecc71; }
.quiz-choice.wrong { background: rgba(231,76,60,.22); border-color: #e74c3c; }
.quiz-feedback { margin-top: 18px; font-size: 1.05rem; display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.quiz-feedback .ok { color: #7bed9f; }
.quiz-feedback .no { color: #ff9d9d; }
.quiz-end { text-align: center; }
.quiz-score { font-family: Georgia, serif; font-size: 3rem; color: #ffd166; margin-bottom: 8px; }
.quiz-end .meta { opacity: .65; margin: 10px 0 18px; }
.match-photo { text-align: center; margin-bottom: 18px; }
.match-photo img { width: 220px; height: 220px; object-fit: cover; border-radius: 50%; border: 4px solid rgba(255,209,102,.6); box-shadow: 0 0 30px rgba(255,209,102,.25); }
@media (max-width: 720px) {
  .games-view { padding: 18px 14px 48px; }
  .quiz-q { font-size: 1.2rem; }
  .match-photo img { width: 170px; height: 170px; }
}
/* ---------- people books ---------- */
.people-sign { cursor: pointer; }
.fam-sign { cursor: pointer; }
.fam-sign:focus { outline: 2px solid #d4a94e; outline-offset: 4px; }
.people-view { max-width: 1000px; margin: 0 auto; padding: 26px 28px 64px; }
.book-rows { display: flex; flex-direction: column; gap: 6px; margin-top: 10px; }
/* smaller side stand for the pets' generation shelves */
.book-rows.pet-shelf { max-width: 560px; margin-left: auto; margin-right: auto; }
.shelf-plaque.pet-plaque { display: table; margin-left: auto; margin-right: auto; }
.book-row { display: flex; gap: 18px; justify-content: center; flex-wrap: wrap; align-items: flex-end; position: relative; }
/* Cute decorations on the pet shelf — paw prints and treats */
.shelf-deco { position: absolute; font-size: 22px; opacity: 0.85; pointer-events: none; top: 0; }
/* Placeholder books for future generations */
.person-book.placeholder-book { cursor: default; opacity: 0.85; }
.person-book.placeholder-book:hover { transform: none; }
.person-book {
  background: none; border: none; cursor: pointer; font-family: inherit;
  display: flex; flex-direction: column; align-items: center; gap: 8px;
  width: 130px; padding: 6px 4px 0; transition: transform .16s ease;
}
.person-book:hover { transform: translateY(-6px); }
.pb-cover {
  width: 104px; height: 148px; border-radius: 4px 10px 10px 4px;
  display: flex; align-items: center; justify-content: center;
  border-left: 8px solid rgba(0,0,0,.35);
  box-shadow: 3px 5px 12px rgba(0,0,0,.5), inset 0 0 18px rgba(0,0,0,.25);
  position: relative; overflow: hidden;
}
/* Round photo medallion — the one consistent shape for every person/pet
   photo (tree cards, shelf covers, book profile). The member's saved crop
   is applied inline, matching the editor preview. */
.photo-medal {
  border-radius: 50%; overflow: hidden; flex: none;
  display: inline-flex; align-items: center; justify-content: center;
  border: 3px solid rgba(212,169,78,.7); box-shadow: 0 4px 14px rgba(0,0,0,.5);
  background: #2a2118;
}
.photo-medal img { object-fit: cover; flex: none; display: block; }
.pbook-photo.photo-medal { border-width: 4px; box-shadow: 0 0 24px rgba(212,169,78,.25); }
.pb-initials {
  width: 76px; height: 76px; border-radius: 50%; flex: none;
  display: inline-flex; align-items: center; justify-content: center;
  font-family: Georgia, serif; font-size: 1.7rem; color: rgba(255,248,230,.92);
  background: rgba(0,0,0,.28); border: 3px solid rgba(212,169,78,.45);
}
.pb-band {
  position: absolute; bottom: 10px; right: 8px; font-size: 1.1rem;
  background: rgba(0,0,0,.45); border-radius: 50%; width: 30px; height: 30px;
  display: flex; align-items: center; justify-content: center;
}
.pb-title { color: #f3e3bb; font-weight: bold; font-size: .95rem; text-align: center; line-height: 1.25; }
.pb-sub { color: #cdbb96; font-size: .8rem; font-style: italic; text-align: center; }
.shelf-board {
  height: 16px; margin: 2px 4% 22px; border-radius: 3px;
  background: linear-gradient(180deg, #8a5f36, #5e3d1f 60%, #3a2410);
  box-shadow: 0 6px 14px rgba(0,0,0,.55);
}
.pbook { max-width: 720px; margin: 6px auto 0; }
.pbook-head { display: flex; gap: 22px; align-items: center; margin-bottom: 26px; }
.pbook-photo {
  width: 120px; height: 120px; border-radius: 50%; object-fit: cover; flex: none;
  border: 4px solid rgba(212,169,78,.65); box-shadow: 0 0 24px rgba(212,169,78,.25);
}
.pbook-initials { display: flex; align-items: center; justify-content: center; font-family: Georgia, serif; font-size: 2.4rem; color: #f3e3bb; background: #4a3a22; }
.pbook-name { font-family: Georgia, serif; font-size: 2rem; color: #f8ecd2; }
.pbook-label { color: #d4a94e; font-style: italic; margin-top: 2px; }
.pbook-dates { color: #cdbb96; font-size: .9rem; margin-top: 6px; }
.pbook-bio { color: #e8d9b8; margin-top: 10px; line-height: 1.55; }
.pbook-sec {
  background: rgba(12,9,4,.6); border: 1px solid rgba(212,169,78,.3);
  border-radius: 12px; padding: 18px 20px; margin-bottom: 14px;
}
.pbook-sec h3 { margin: 0 0 8px; font-family: Georgia, serif; color: #ffd166; font-size: 1.15rem; }
.pbook-sec p { margin: 0; line-height: 1.6; color: #f0e2c0; white-space: pre-wrap; }
.pbook-empty { opacity: .5 !important; font-style: italic; }
.pbook-future-tag {
  display: inline-block; margin: 0 0 12px; padding: 8px 14px; border-radius: 20px;
  background: rgba(212,169,78,.12); border: 1px solid rgba(212,169,78,.45);
  color: #ffd97a; font-size: .9rem;
}
.pbook-form { flex: 1 1 100%; }
.pbook-form label { display: block; margin-bottom: 14px; color: #f3e3bb; font-weight: bold; }
.pbook-form .hint { display: block; font-weight: normal; opacity: .55; font-size: .85rem; margin: 2px 0 6px; }
.pbook-form textarea, .mem-form textarea {
  width: 100%; box-sizing: border-box; font-family: inherit; font-size: 1rem;
  background: rgba(255,255,255,.06); color: #f3e3bb;
  border: 1px solid rgba(212,169,78,.45); border-radius: 8px; padding: 10px 12px;
}
/* text inputs share the same dark/gold treatment — no default white boxes */
.pbook-form input[type="text"], .pbook-form input:not([type]) {
  display: block; width: 100%; box-sizing: border-box; font-family: inherit; font-size: 1rem;
  background: rgba(255,255,255,.06); color: #f3e3bb;
  border: 1px solid rgba(212,169,78,.45); border-radius: 8px; padding: 10px 12px;
  margin-top: 6px;
}
.pbook-form input[type="file"] {
  display: block; margin-top: 6px; color: #f3e3bb; font-family: inherit; font-size: .9rem;
}
.pbook-form input[type="file"]::file-selector-button {
  font-family: inherit; font-size: .85rem; cursor: pointer;
  background: rgba(212,169,78,.15); color: #ffd97a;
  border: 1px solid rgba(212,169,78,.45); border-radius: 8px; padding: 8px 14px;
  margin-right: 10px;
}
.pbook-form .row { display: flex; gap: 10px; }
.pbook-mem { margin-top: 30px; }
.pbook-mem h3 { font-family: Georgia, serif; color: #ffd166; }
.mem {
  background: rgba(255,255,255,.04); border-left: 3px solid rgba(212,169,78,.6);
  border-radius: 0 10px 10px 0; padding: 12px 16px; margin-bottom: 10px;
}
.mem p { margin: 0 0 6px; line-height: 1.55; color: #f0e2c0; white-space: pre-wrap; }
.mem .meta { opacity: .55; font-size: .82rem; }
.mem-actions { display: inline-flex; gap: 6px; margin-left: 8px; vertical-align: middle; }
.mem-actions .btn.small { padding: 2px 10px; font-size: .78rem; }
.mem-photo { width: 100%; max-height: 340px; object-fit: cover; border-radius: 10px; margin-bottom: 8px; display: block; }
.mem-edit-ta {
  width: 100%; box-sizing: border-box; margin: 0 0 8px;
  background: #171006; color: #f5e6c4; border: 1px solid rgba(212,169,78,.55);
  border-radius: 8px; padding: 10px 12px; font-size: 1rem; font-family: inherit;
  color-scheme: dark;
}
.mem-form { display: flex; flex-direction: column; gap: 10px; margin-top: 14px; }
.mem-form .btn { align-self: flex-start; }
#pbook-edit { margin: 6px 0 4px; }
.crumb .spacer { flex: 1; }
.book-pick { display: flex; flex-direction: column; gap: 6px; max-height: 46vh; overflow-y: auto; margin-top: 12px; padding-right: 6px; }
.book-pick-row {
  display: flex; align-items: center; gap: 12px; cursor: pointer;
  background: rgba(255,255,255,.04); border: 1px solid rgba(212,169,78,.25);
  border-radius: 8px; padding: 9px 12px; color: #f3e3bb; font-size: .98rem;
}
.book-pick-row input { width: 18px; height: 18px; accent-color: #d4a94e; flex: none; }
@media (max-width: 720px) {
  .people-view { padding: 18px 14px 48px; }
  .person-book { width: 104px; }
  .pb-cover { width: 88px; height: 126px; }
  .pbook-head { flex-direction: column; text-align: center; }
  .pbook-name { font-size: 1.6rem; }
}
@media (prefers-reduced-motion: reduce) {
  .hall-zoom, .car-book-3d, .spine, .view-enter, .mote, .heritage-web .web-plaque, .game-card-btn .games-glow { animation: none !important; transition: none !important; }
  .game-card:hover, .quiz-choice:hover:not(:disabled) { transform: none !important; }
  .hall-zoom.zoomed { transform: none; }
}

/* ---------- time capsules ---------- */
.capsule-shelf .f-board { box-shadow: 0 0 24px rgba(90,220,255,.35); }
.capsule-head { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 10px; }
.capsule-head b { color: #5adcff; letter-spacing: 2px; }
.capsule-head span { opacity: .65; font-size: .85rem; flex: 1 1 auto; }
.capsule-scroll-wrap { position: relative; min-width: 0; }
.capsule-row { display: flex; gap: 12px; flex-wrap: wrap; }
/* horizontal-scroll capsule rows: swipe/scroll sideways when a shelf overflows */
.capsule-row.scroll-x { flex-wrap: nowrap; overflow-x: auto; padding-bottom: 10px; scroll-snap-type: x proximity; }
.capsule-row.scroll-x .capsule-pod { flex: 0 0 auto; scroll-snap-align: start; }
.capsule-subhead { display: flex; align-items: baseline; gap: 8px; margin: 14px 0 10px; color: #eaf6ff; font-size: 1.02rem; font-weight: 700; letter-spacing: 1px; }
.capsule-subhead span { opacity: .6; font-size: .85rem; font-weight: 400; letter-spacing: 0; }
.capsule-head + .capsule-subhead { margin-top: 2px; }
.capsule-pod {
  display: flex; flex-direction: column; align-items: center; gap: 4px;
  min-width: 128px; max-width: 150px; padding: 12px 10px; border-radius: 16px;
  background: linear-gradient(180deg, rgba(20,30,60,.9), rgba(10,16,34,.95));
  border: 1px solid rgba(90,220,255,.5); cursor: pointer; color: #eaf6ff;
  font-family: inherit; transition: transform .15s, box-shadow .15s;
}
.capsule-pod:hover { transform: translateY(-3px); }
.capsule-pod.locked { box-shadow: 0 0 12px rgba(90,220,255,.25), inset 0 0 18px rgba(90,220,255,.12); }
.capsule-pod.ready {
  border-color: #ffd166; animation: capPulse 2.2s ease-in-out infinite;
  box-shadow: 0 0 18px rgba(255,209,102,.55), inset 0 0 18px rgba(255,209,102,.18);
}
@keyframes capPulse {
  0%, 100% { box-shadow: 0 0 14px rgba(255,209,102,.4), inset 0 0 16px rgba(255,209,102,.15); }
  50% { box-shadow: 0 0 26px rgba(255,209,102,.75), inset 0 0 22px rgba(255,209,102,.3); }
}
.cap-glyph { font-size: 1.7rem; }
.cap-title { font-weight: 700; font-size: .85rem; text-align: center; }
.cap-meta { font-size: .72rem; opacity: .75; text-align: center; line-height: 1.35; }
.capsule-overlay {
  position: fixed; inset: 0; z-index: 90; background: rgba(4,8,20,.72);
  display: flex; align-items: center; justify-content: center; padding: 18px;
}
.capsule-modal {
  width: min(520px, 100%); max-height: 88vh; overflow-y: auto;
  background: linear-gradient(180deg, #141c36, #0a1022);
  border: 1px solid rgba(90,220,255,.5); border-radius: 18px; padding: 22px;
  color: #eaf6ff; box-shadow: 0 0 44px rgba(90,220,255,.3);
}
.capsule-modal h3 { margin: 6px 0 10px; color: #ffd166; }
.capsule-modal label { display: block; margin: 10px 0; font-size: .9rem; }
.capsule-modal input, .capsule-modal textarea {
  width: 100%; margin-top: 6px; background: #0a0f22; color: #eaf6ff;
  border: 1px solid rgba(90,220,255,.4); border-radius: 10px; padding: 9px 11px;
  font-size: 1rem; font-family: inherit;
}
.cap-big { font-size: 2.6rem; text-align: center; }
.cap-open-date { color: #5adcff; font-size: 1.1rem; font-weight: 700; }
.cap-for { opacity: .7; font-size: .9rem; }
.cap-message {
  background: rgba(255,209,102,.08); border: 1px solid rgba(255,209,102,.4);
  border-radius: 12px; padding: 14px; margin-top: 10px; line-height: 1.55; white-space: pre-wrap;
}
.cap-err { color: #ff9d9d; min-height: 1.2em; margin: 6px 0; font-size: .9rem; }

/* ---------- the heritage shelf (pre-1970) ---------- */
.heritage-web { cursor: pointer; outline: none; }
.heritage-web:focus { outline: 2px solid #c9a86a; outline-offset: 6px; }
.heritage-web .web-spider { animation: spiderDangle 5s ease-in-out infinite; transform-origin: 170px 150px; transform-box: fill-box; }
@keyframes spiderDangle { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(7px); } }
.heritage-view {
  max-width: 1200px; margin: 0 auto;
  padding: 26px 28px 64px;
  background: radial-gradient(ellipse at 50% 0%, #241a10 0%, #120c06 55%, #070402 100%);
  border-radius: 14px;
  border: 1px solid rgba(201, 168, 106, .35);
  box-shadow: 0 24px 70px rgba(0, 0, 0, .6), inset 0 0 120px rgba(120, 80, 20, .10);
}
.heritage-plaque {
  font-family: Georgia, serif; font-size: 1.5rem; letter-spacing: 4px;
  color: #e8cf9a; text-shadow: 0 0 14px rgba(201, 168, 106, .7);
  border: 1px solid rgba(201, 168, 106, .55); border-radius: 10px;
  padding: 10px 26px; background: rgba(40, 26, 10, .55);
}
.heritage-note {
  max-width: 760px; margin: 22px auto 8px; text-align: center;
  color: #cdbb96; font-size: 1.05rem; line-height: 1.6; font-style: italic;
}
/* three heritage shelves, two books per shelf */
.heritage-shelf { margin: 30px auto 0; max-width: 620px; }
.heritage-shelf-books {
  display: flex; justify-content: center; align-items: flex-end; gap: 44px;
}
.heritage-plank {
  height: 14px; margin-top: -4px; border-radius: 4px;
  background: linear-gradient(#7a5527, #3d2812);
  box-shadow: 0 12px 26px rgba(0,0,0,.65), inset 0 2px 3px rgba(255,220,150,.25);
}
.heritage-shelf .car-book-3d { transform: rotateY(0deg); transition: transform .25s ease; }
.heritage-shelf .car-book:hover .car-book-3d,
.heritage-shelf .car-book:focus-visible .car-book-3d { transform: rotateY(0deg) translateY(-8px); }
/* phones: scale the shelf books to the viewport so two fit side by side */
@media (max-width: 520px) {
  .heritage-shelf { max-width: 100%; }
  .heritage-shelf-books { gap: 12px; }
  .heritage-shelf .car-book { width: 42vw; height: 61vw; }
  .heritage-shelf .car-book-3d { padding: 12px 8px 12px 26px; }
  .heritage-shelf .car-band { top: 18px; height: 20px; }
  .heritage-shelf .car-title { font-size: 1rem; line-height: 1.25; }
  .heritage-shelf .car-sub { font-size: .68rem; margin-top: 6px; }
  .heritage-shelf .car-month { font-size: .6rem; padding: 1px 8px; }
}
/* the spider-web plaque gently pulses so it's obvious the web is tappable */
.heritage-web { cursor: pointer; }
.heritage-web .web-plaque { animation: webPlaquePulse 2.8s ease-in-out infinite; }
@keyframes webPlaquePulse {
  0%, 100% { stroke-opacity: .55; }
  50% { stroke-opacity: 1; }
}
/* clickable signs glow so people know they can tap them */
.clickable-glow rect {
  animation: signGlow 2.8s ease-in-out infinite;
}
@keyframes signGlow {
  0%, 100% { stroke-opacity: .6; filter: drop-shadow(0 0 4px rgba(212,169,78,.4)); }
  50% { stroke-opacity: 1; filter: drop-shadow(0 0 12px rgba(212,169,78,.9)); }
}
@media (max-width: 720px) {
  .heritage-view { padding: 18px 14px 48px; }
}

/* ---------- time capsules 2.0 ---------- */
.capsule-pod.opened { opacity: .85; }
.capsule-pod.locked.mine { box-shadow: 0 0 12px rgba(255,209,102,.35), inset 0 0 18px rgba(255,209,102,.12); }
.cap-blocks { display: flex; flex-direction: column; gap: 14px; margin: 14px 0; }
.cap-note {
  background: rgba(255,209,102,.07); border: 1px solid rgba(255,209,102,.3);
  border-radius: 10px; padding: 12px 14px; line-height: 1.6; white-space: normal;
}
.cap-photo { margin: 0; }
.cap-photo img { width: 100%; border-radius: 10px; border: 1px solid rgba(255,255,255,.15); display: block; }
.cap-photo figcaption { font-size: .85rem; opacity: .75; margin-top: 6px; font-style: italic; }
.cap-link a { color: #7de6ff; }
.cap-audio { width: 100%; margin: 10px 0 4px; }
.cap-voice { margin: 0; }
.cap-voice audio { width: 100%; }
.cap-video { margin: 0; }
.cap-video video { width: 100%; border-radius: 10px; border: 1px solid rgba(255,255,255,.15); display: block; background: #000; }
.cap-voice figcaption, .cap-video figcaption { font-size: .85rem; opacity: .75; margin-top: 6px; font-style: italic; }
.cap-actions { display: flex; gap: 10px; justify-content: flex-end; margin-top: 14px; flex-wrap: wrap; }
.cf-blocks { display: flex; flex-direction: column; gap: 10px; margin: 12px 0 4px; }
.cf-empty { opacity: .6; font-style: italic; font-size: .9rem; margin: 4px 0; }
.cf-block {
  display: flex; gap: 8px; align-items: flex-start;
  background: rgba(255,255,255,.04); border: 1px solid rgba(255,255,255,.12);
  border-radius: 10px; padding: 10px;
}
.cf-block textarea, .cf-block input { flex: 1 1 auto; min-width: 0; }
.cf-block img { width: 74px; height: 74px; object-fit: cover; border-radius: 8px; flex: 0 0 auto; }
.cf-block audio { flex: 1 1 auto; min-width: 0; }
.cf-block video { width: 160px; flex: 0 0 auto; border-radius: 8px; background: #000; }
.cf-addrow { display: flex; gap: 8px; flex-wrap: wrap; margin: 8px 0; }
/* voice/video chooser + in-browser recorder */
.cf-choose { flex-direction: column; align-items: stretch; }
.cf-choose-label { font-size: .9rem; margin-bottom: 8px; }
.cf-rec {
  background: rgba(255,255,255,.04); border: 1px solid rgba(255,120,120,.35);
  border-radius: 10px; padding: 10px; margin: 4px 0;
}
.cf-rec-live { display: flex; align-items: center; gap: 10px; margin-bottom: 8px; }
.cf-rec-live video { width: 100%; max-height: 240px; border-radius: 8px; background: #000; }
.cf-rec-live audio { width: 100%; }
.cf-rec-dot {
  width: 14px; height: 14px; border-radius: 50%; background: #ff5a5a; flex: 0 0 auto;
  animation: cfblink 1s infinite;
}
@keyframes cfblink { 50% { opacity: .25; } }
.cf-rec-timer { font-variant-numeric: tabular-nums; font-size: 1rem; }
.cf-rec-btns { display: flex; gap: 8px; flex-wrap: wrap; }
.cf-rec-err { color: #ff9d9d; font-size: .85rem; margin-top: 6px; min-height: 1em; }
.cf-music { font-size: .9rem; margin: 6px 0; display: flex; align-items: center; gap: 10px; }

/* ---------------- the Teke tribe room ---------------- */
.teke-view {
  max-width: 1200px; margin: 0 auto;
  padding: 26px 28px 64px;
  background: radial-gradient(ellipse at 50% 0%, #2a1c0e 0%, #140d05 55%, #070402 100%);
  border-radius: 14px;
  border: 1px solid rgba(212, 169, 78, .4);
  box-shadow: 0 24px 70px rgba(0, 0, 0, .6), inset 0 0 120px rgba(150, 100, 30, .10);
}
.teke-plaque { background: linear-gradient(180deg, #5a3a16, #3a2410); border-color: #d4a94e; color: #ffe9b8; }
.teke-intro { max-width: 760px; margin: 14px auto 8px; text-align: center; line-height: 1.65; color: #e8dcc0; font-size: 1.02rem; }
.teke-sec {
  font-family: Georgia, serif; letter-spacing: 2px; color: #d4a94e;
  text-align: center; margin: 34px 0 14px; font-size: 1.25rem;
}
.teke-map-wrap { max-width: 860px; margin: 0 auto; }
.teke-map { width: 100%; height: auto; display: block; border-radius: 12px; border: 1px solid rgba(212,169,78,.35); }
.teke-map-note { max-width: 760px; margin: 12px auto 0; line-height: 1.65; color: #d8c9a8; text-align: center; }
.teke-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 18px; margin-top: 6px; }
.teke-card {
  background: rgba(255,255,255,.045); border: 1px solid rgba(212,169,78,.3);
  border-radius: 12px; overflow: hidden;
}
.teke-card img { width: 100%; height: 190px; object-fit: cover; object-position: center 30%; display: block; }
@media (max-width: 720px) {
  .teke-card img { height: 240px; }
}
.teke-card-body { padding: 12px 14px 16px; }
.teke-card-body h3 { margin: 0 0 8px; font-family: Georgia, serif; color: #ffe9b8; font-size: 1.05rem; }
.teke-card-body p { margin: 0; line-height: 1.6; color: #d8c9a8; font-size: .94rem; }
.teke-history { max-width: 760px; margin: 6px auto 0; padding-left: 22px; line-height: 1.7; color: #e8dcc0; }
.teke-history li { margin-bottom: 10px; }
@media (max-width: 640px) {
  .teke-view { padding: 18px 14px 48px; }
}

/* family books ledge in the hall */
.fam-book { cursor: pointer; }
.fam-book rect { transition: filter .15s ease; }
.fam-book:hover rect, .fam-book:focus rect { filter: brightness(1.25); }
.fam-book:focus { outline: none; }
.fam-book:focus rect { stroke: #ffd166; stroke-width: 2.5; }

/* ---------- mobile: the view fits, shelves scroll — no camera to fight ---------- */
.only-mobile { display: none; }
@media (max-width: 720px) {
  .only-mobile { display: inline-block; }
  .hall-controls { display: none; }
  .hall-stage { cursor: default; min-height: 300px; }
  .decade-nav { gap: 8px; }
  .decade-nav .btn { font-size: .85rem; padding: 8px 12px; }
}

/* ---------- DNA view (the globe door) ---------- */
.dna-globe { cursor: pointer; }
.dna-view { max-width: 1000px; margin: 0 auto; padding: 26px 28px 64px; }
.dna-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 14px; max-width: 900px; margin: 18px auto; padding: 0 12px;
}
.dna-card {
  background: #241708; border: 1px solid rgba(201,168,106,.4); border-radius: 14px;
  padding: 18px 10px 14px; text-align: center; cursor: pointer;
}
.dna-card:hover, .dna-card:focus { border-color: #ffd97a; outline: none; }
.dna-nophoto { font-size: 34px; background: #1d2a4a; }
.dna-name { color: #f3dfae; font-family: Georgia, serif; font-size: 17px; margin-top: 10px; }
.dna-sub { opacity: .65; font-size: 12px; margin-top: 2px; }
#dna-overlay {
  position: fixed; inset: 0; z-index: 1000;
  background: rgba(10, 7, 3, .82);
  display: flex; align-items: center; justify-content: center;
  padding: 20px;
}
.dna-modal {
  background: #1d1409; border: 1px solid rgba(214, 178, 106, .5); border-radius: 16px;
  max-width: 860px; width: 100%; max-height: 90vh; overflow: auto;
  padding: 22px; text-align: center; position: relative;
}
.dna-modal h3 { margin: 8px 0 4px; color: #f3dfae; }
.dna-modal .dna-note { opacity: .8; font-style: italic; margin: 0 0 14px; }
.dna-modal img { max-width: 100%; border-radius: 10px; }
.dna-modal iframe { width: 100%; height: 70vh; border: none; border-radius: 10px; background: #fff; }
.dna-modal #dna-close { float: right; }
@media (max-width: 720px) {
  .dna-view { padding: 18px 14px 48px; }
}

/* ---- revised glow: a book changed since you last read it (2026-10-20) ---- */
@keyframes spineGlowPulse {
  0%, 100% { box-shadow: inset 2px 0 4px rgba(0,0,0,.4), 4px 6px 12px rgba(0,0,0,.5), 0 0 4px 1px rgba(246,196,83,.35); }
  50% { box-shadow: inset 2px 0 4px rgba(0,0,0,.4), 4px 6px 12px rgba(0,0,0,.5), 0 0 16px 4px rgba(246,196,83,.75); }
}
.spine-revised { animation: spineGlowPulse 2.2s ease-in-out infinite; }
.spine-new { color: #ffd97a; font-size: 13px; line-height: 1; text-shadow: 0 0 8px rgba(246,196,83,.9); }
.car-revised .car-book-3d { position: relative; animation: spineGlowPulse 2.2s ease-in-out infinite; }
.car-new {
  position: absolute; top: 8px; right: 8px; z-index: 3;
  background: rgba(20,14,4,.85); color: #ffd97a; border: 1px solid rgba(246,196,83,.7);
  font-size: 11px; padding: 2px 8px; border-radius: 999px; letter-spacing: .04em;
}

/* ---- Mystery Album (2026-10-20) ---- */
.mystery-head {
  display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap;
  background: #141d33; border: 1px solid #233252; border-radius: 12px;
  padding: 12px 16px; margin: 18px 0 14px; color: #dbe4f5; font-size: 15px;
}
.mystery-new { color: #ffd97a; }
.mystery-empty { text-align: center; color: #9fb4d8; padding: 34px 12px; font-size: 16px; }
.mystery-card {
  background: #101828; border: 1px solid #233252; border-radius: 14px;
  padding: 16px; color: #e8eefb;
}
.mystery-nav { display: flex; justify-content: space-between; align-items: center; margin-bottom: 12px; color: #9fb4d8; }
.mystery-photo { display: block; max-width: 100%; max-height: 62vh; margin: 0 auto; border-radius: 10px; background: #000; object-fit: contain; }
.mystery-q { text-align: center; font-size: 22px; font-weight: 700; margin: 14px 0 2px; color: #f5ead0; }
.mystery-meta { text-align: center; color: #8fa3c4; font-size: 13px; margin-bottom: 10px; word-break: break-all; }
.mystery-sugg { background: #0d1526; border: 1px solid #1e2c49; border-radius: 10px; padding: 10px 12px; margin: 10px 0; font-size: 14px; }
.mystery-sugg.none { color: #8fa3c4; text-align: center; }
.mystery-sugg-row { padding: 5px 0; border-top: 1px dashed #22335c; }
.mystery-sugg-row:first-of-type { border-top: none; }
.mystery-conf { color: #ffd97a; font-size: 12.5px; }
.mystery-note { color: #b9c8e4; font-style: italic; margin-top: 2px; }
.mystery-form { margin-top: 12px; display: flex; flex-direction: column; gap: 10px; }
.mystery-pickrow { display: flex; gap: 12px; flex-wrap: wrap; align-items: center; }
.mystery-pickrow label { display: flex; gap: 6px; align-items: center; color: #c8d6f2; font-size: 14px; }
.mystery-pickrow select {
  background: #0d1526; color: #e8eefb; border: 1px solid #33507f;
  border-radius: 8px; padding: 7px 9px; font-size: 15px;
}
.mystery-conf-pick { display: inline-flex; gap: 8px; }
.chip-btn {
  background: #0d1526; color: #9fb4d8; border: 1px solid #33507f;
  border-radius: 999px; padding: 6px 12px; font-size: 13.5px; cursor: pointer;
}
.chip-btn.on { background: #f6c453; color: #241a02; border-color: #f6c453; font-weight: 700; }
.mystery-form input[type="text"] {
  background: #0d1526; color: #e8eefb; border: 1px solid #33507f;
  border-radius: 8px; padding: 9px 11px; font-size: 15px; width: 100%; box-sizing: border-box;
}
.mystery-formmsg { color: #ffd97a; font-size: 13.5px; }
.mystery-standings { margin-top: 20px; background: #141d33; border: 1px solid #233252; border-radius: 12px; padding: 14px 16px; color: #dbe4f5; }
.mystery-standings h3 { margin: 0 0 8px; }
.mystery-stand-row { display: flex; justify-content: space-between; padding: 5px 0; border-top: 1px dashed #22335c; font-size: 14.5px; }
.mystery-stand-row.me { color: #ffd97a; font-weight: 700; }
.mystery-review { margin-top: 22px; color: #dbe4f5; }
.mystery-rev-card { display: flex; gap: 12px; background: #101828; border: 1px solid #233252; border-radius: 12px; padding: 10px; margin-top: 10px; }
.mystery-rev-card img { width: 110px; height: 110px; object-fit: cover; border-radius: 8px; flex: none; }
.mystery-rev-body { flex: 1; min-width: 0; }
.mystery-rev-body .mystery-meta { text-align: left; }
.mystery-rev-row { padding: 6px 0; border-top: 1px dashed #22335c; font-size: 14px; }
.my-bulkmsg { color: #ffd97a; font-size: 13.5px; }

/* ---------- shelf status (2026-10-30): published lock + admin filter ---------- */
/* Gold lock on published books only: sits just above the bottom gold band
   (never covering it), sized to the spine so dense/narrow years never overflow. */
.spine-lock { flex: 0 0 auto; display: flex; align-items: center; justify-content: center; margin: 0 0 4px; line-height: 1; }
.spine-lock svg { width: 15px; height: 18px; filter: drop-shadow(0 1px 2px rgba(0,0,0,.65)); }
.spine-row.dense .spine-lock svg { width: 12px; height: 15px; }
@media (max-width: 720px) { .spine-lock svg { width: 14px; height: 17px; } }
.spine.spine-hidden { display: none !important; }
/* Admin-only filter, bookend-style at the right end of each shelf row.
   Contributors never get this element, so they can never empty a shelf. */
.shelf-filter {
  position: absolute; right: 2px; bottom: 2px; z-index: 6;
  display: flex; gap: 6px; padding: 4px;
  background: rgba(30,18,6,.6); border: 1px solid rgba(212,169,78,.55); border-radius: 10px;
}
.shelf-filter-btn {
  width: 32px; height: 32px; padding: 2px;
  display: flex; align-items: center; justify-content: center;
  background: transparent; border: 2px solid transparent; border-radius: 8px; cursor: pointer;
}
.shelf-filter-btn svg { width: 20px; height: 22px; }
.shelf-filter-btn.active { border-color: #f3cd72; background: rgba(212,169,78,.25); box-shadow: 0 0 10px rgba(255,209,102,.7); }
/* Empty-filter safety net: never a blank wall — message + one-tap Show all. */
.shelf-filter-empty {
  display: none; align-items: center; gap: 12px; flex-wrap: wrap;
  margin: 10px 6px 0; padding: 12px 14px;
  background: rgba(30,18,6,.55); border: 1px solid rgba(212,169,78,.4); border-radius: 10px;
  color: #f5ead0; font-family: Georgia, serif;
}
.shelf-filter-empty.show { display: flex; }
