/* ==========================================================================
   The Fosgate Files: imageboard styles
   Light is a blue-grey board theme, dark is a soft charcoal one.
   With no saved choice the page follows the system setting.
   ========================================================================== */

:root {
  --bg: #eef2ff;
  --ink: #000;
  --muted: #707070;
  --link: #34345c;
  --hover: #dd0000;
  --post: #d6daf0;
  --post-line: #b7c5d9;
  --side: #b7c5d9;
  --title: #af0a0f;
  --subject: #0f0c5d;
  --name: #117743;
  --green: #789922;
  --quote: #dd0000;
  --hl: #d6bad0;
  --hl-line: #ba9dbf;
  --box-bar: #98e;
  --box-bar-ink: #000;
  --box: #fff;
  --input: #fff;
  --input-line: #aaa;
  --shadow: 0 0 5px rgba(0, 0, 0, .25);

  --fs: 14px;
  --f: arial, helvetica, sans-serif;
  --f-title: tahoma, "Segoe UI", sans-serif;
  /* banner scene: day */
  --sc-sky-top: var(--bg); --sc-sky-mid: #d4e0f6; --sc-sky-low: #f5ecdd; --sc-glow: #fff7e6;
  --sc-city: #9ba8bb; --sc-land: #3f4b56; --sc-hill: #4c5b66; --sc-shore: #6c7884; --sc-bridge: #343c48; --sc-truss: #56606d;
  --sc-water-top: #b3c4de; --sc-water-low: var(--bg); --sc-ripple: rgba(255, 255, 255, .55); --sc-refl-op: .38;
  --sc-tank: #fdfdfe; --sc-tank-shade: #b5bdc8;
  --sc-title-a: #c8141b; --sc-title-b: #8a0a0f; --sc-title-stroke: #ffffff; --sc-sub: #5a6474; --sc-nd: none; --sc-dd: inline;
  color-scheme: light;
}
:root[data-size="s"]  { --fs: 12.5px; }
:root[data-size="l"]  { --fs: 16px; }
:root[data-size="xl"] { --fs: 18.5px; }

:root[data-theme="dark"] {
  --bg: #1d1f21;
  --ink: #c5c8c6;
  --muted: #8a8d8b;
  --link: #81a2be;
  --hover: #a3c3e0;
  --post: #282a2e;
  --post-line: #111;
  --side: #4b4f54;
  --title: #c5c8c6;
  --subject: #b294bb;
  --name: #8abeb7;
  --green: #b5bd68;
  --quote: #5f89ac;
  --hl: #343a44;
  --hl-line: #5f89ac;
  --box-bar: #373b41;
  --box-bar-ink: #c5c8c6;
  --box: #282a2e;
  --input: #1d1f21;
  --input-line: #4b4f54;
  --shadow: 0 0 6px rgba(0, 0, 0, .6);
  /* banner scene: night */
  --sc-sky-top: var(--bg); --sc-sky-mid: #11141a; --sc-sky-low: #3b3935; --sc-glow: #cfc2a8;
  --sc-city: #25272c; --sc-land: #08090c; --sc-hill: #090b0e; --sc-shore: #14171c; --sc-bridge: #2c3037; --sc-truss: #3d424b;
  --sc-water-top: #1e1f22; --sc-water-low: var(--bg); --sc-ripple: rgba(255, 236, 200, .05); --sc-refl-op: .62;
  --sc-tank: #e6eaef; --sc-tank-shade: #8c939c;
  --sc-title-a: #ffffff; --sc-title-b: #d8ccb4; --sc-title-stroke: #07080b; --sc-sub: #b7b2a6; --sc-nd: inline; --sc-dd: none;
  color-scheme: dark;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme]) {
    --bg: #1d1f21;
    --ink: #c5c8c6;
    --muted: #8a8d8b;
    --link: #81a2be;
    --hover: #a3c3e0;
    --post: #282a2e;
    --post-line: #111;
    --side: #4b4f54;
    --title: #c5c8c6;
    --subject: #b294bb;
    --name: #8abeb7;
    --green: #b5bd68;
    --quote: #5f89ac;
    --hl: #343a44;
    --hl-line: #5f89ac;
    --box-bar: #373b41;
    --box-bar-ink: #c5c8c6;
    --box: #282a2e;
    --input: #1d1f21;
    --input-line: #4b4f54;
    --shadow: 0 0 6px rgba(0, 0, 0, .6);
    /* banner scene: night */
    --sc-sky-top: var(--bg); --sc-sky-mid: #11141a; --sc-sky-low: #3b3935; --sc-glow: #cfc2a8;
    --sc-city: #25272c; --sc-land: #08090c; --sc-hill: #090b0e; --sc-shore: #14171c; --sc-bridge: #2c3037; --sc-truss: #3d424b;
    --sc-water-top: #1e1f22; --sc-water-low: var(--bg); --sc-ripple: rgba(255, 236, 200, .05); --sc-refl-op: .62;
    --sc-tank: #e6eaef; --sc-tank-shade: #8c939c;
    --sc-title-a: #ffffff; --sc-title-b: #d8ccb4; --sc-title-stroke: #07080b; --sc-sub: #b7b2a6; --sc-nd: inline; --sc-dd: none;
    color-scheme: dark;
  }
}

* { box-sizing: border-box; }
html { scroll-padding-top: 20px; -webkit-text-size-adjust: 100%; }
body {
  margin: 0; padding: 0 10px;
  background: var(--bg); color: var(--ink);
  font-family: var(--f); font-size: var(--fs); line-height: 1.4;
}
a { color: var(--link); text-decoration: none; }
a:hover { color: var(--hover); text-decoration: underline; }
button { font: inherit; }
hr { border: 0; border-top: 1px solid var(--post-line); margin: 8px 0; clear: both; }
[hidden] { display: none !important; }
:focus-visible { outline: 2px solid var(--link); outline-offset: 1px; }
.muted { color: var(--muted); }
code { font-family: monospace; }
.skip { position: absolute; left: -999px; top: 4px; z-index: 200; background: var(--post); padding: 6px 10px; border: 1px solid var(--post-line); }
.skip:focus { left: 4px; }
.ref { font-family: var(--f); color: var(--quote); }
a.ref:hover { color: var(--hover); }
mark { background: #ff0; color: #000; }

/* ---------- board list (top and bottom navigation) ---------- */
.boardlist {
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: 2px 12px;
  font-size: 12px; color: var(--muted); padding: 4px 0;
}
.boardlist a { color: var(--link); }
.boardlist a.cur { font-weight: bold; }
.boardlist button { background: none; border: 0; padding: 0; color: var(--link); cursor: pointer; font-size: 12px; }
.boardlist button:hover { color: var(--hover); text-decoration: underline; }
.boardlist.bottom { border-top: 1px solid var(--post-line); margin-top: 10px; padding-top: 6px; }

.app { outline: none; }
.loading, .notice { text-align: center; color: var(--muted); padding: 60px 0; }

/* ---------- board header ---------- */
.board-head { text-align: center; padding-top: 6px; }
.banner { display: inline-block; width: 320px; max-width: 100%; line-height: 0; }
.banner:hover { filter: brightness(1.06); }
/* the night-river illustration (banner and front-page logo); day or night follows the theme */
.scene { display: block; width: 100%; height: auto; }
.scene-title {
  font-family: var(--f-title); font-weight: bold; font-size: 31px; letter-spacing: 6px;
  stroke: var(--sc-title-stroke); stroke-width: 3px; stroke-opacity: .45; paint-order: stroke; stroke-linejoin: round;
}
.scene-sub { font-family: var(--f-title); font-size: 8.5px; letter-spacing: 3px; fill: var(--sc-sub); }
.banner .scene-sub { display: none; }               /* too small to read on the board banner */
.sc-night { display: var(--sc-nd); }
.sc-day { display: var(--sc-dd); }
.s-sky-top { stop-color: var(--sc-sky-top); } .s-sky-mid { stop-color: var(--sc-sky-mid); } .s-sky-low { stop-color: var(--sc-sky-low); }
.s-glow { stop-color: var(--sc-glow); } .s-water-top { stop-color: var(--sc-water-top); } .s-water-low { stop-color: var(--sc-water-low); }
.s-tank { stop-color: var(--sc-tank); } .s-tank-shade { stop-color: var(--sc-tank-shade); }
.s-title-a { stop-color: var(--sc-title-a); } .s-title-b { stop-color: var(--sc-title-b); }
.sc-city { fill: var(--sc-city); } .sc-land { fill: var(--sc-land); } .sc-hill { fill: var(--sc-hill); }
.sc-shore { fill: var(--sc-shore); } .sc-bridge { fill: var(--sc-bridge); } .sc-lattice { stroke: var(--sc-truss); }
.sc-tanktop { fill: var(--sc-tank); } .sc-tankband { fill: var(--sc-tank-shade); }
.sc-refl { opacity: var(--sc-refl-op); }
.sc-ripple { fill: var(--sc-ripple); }
.board-title {
  margin: 8px 0 0; font-family: var(--f-title); font-size: 28px; font-weight: bold; letter-spacing: -2px;
  color: var(--title); line-height: 1.2; overflow-wrap: anywhere;
}
.board-sub { font-size: 12px; color: var(--muted); margin-top: 2px; }
.searchbar { display: flex; justify-content: center; gap: 4px; margin: 10px auto 0; max-width: 420px; }
.searchbar input {
  flex: 1; min-width: 0; padding: 3px 6px; font: inherit; font-size: 13px;
  background: var(--input); color: var(--ink); border: 1px solid var(--input-line); border-radius: 0;
}
.searchbar button, .qr button {
  padding: 2px 12px; font-size: 13px; cursor: pointer; color: var(--ink);
  background: var(--post); border: 1px solid var(--input-line); border-radius: 2px;
}
.searchbar button:hover, .qr button:hover { border-color: var(--link); }

.navlinks { font-size: 13px; color: var(--muted); margin: 6px 0; }
.navlinks a.cur { font-weight: bold; color: var(--ink); }
.navlinks button { background: none; border: 0; padding: 0; color: var(--link); cursor: pointer; }
.navlinks button:hover { color: var(--hover); text-decoration: underline; }
.navlinks.filters { font-size: 12px; line-height: 1.7; }
.navlinks.more { text-align: center; margin: 14px 0; }

.board-info { max-width: 720px; margin: 8px auto; text-align: center; }
.board-info p { margin: 4px 0; }

/* ---------- posts ---------- */
.thread::after, .results::after { content: ""; display: block; clear: both; }
.post { overflow-wrap: anywhere; }
.post.op { margin: 4px 0 6px; }
.post.op::after { content: ""; display: block; clear: both; }
.reply-wrap { display: flex; align-items: flex-start; margin: 4px 0; }
.side { color: var(--side); font-size: 12px; padding: 4px 4px 0 2px; flex: none; user-select: none; }
.post.reply {
  background: var(--post); border: 1px solid var(--post-line); border-left: 0; border-top: 0;
  padding: 4px 10px 6px 8px; max-width: 100%; min-width: 0; display: flow-root;
}
.post.highlight, .post.reply.highlight { background: var(--hl); border: 1px solid var(--hl-line); }
.post.op.highlight { padding: 4px; }

.phead { font-size: 13px; line-height: 1.6; }
.phead .subject { color: var(--subject); font-weight: bold; }
.phead .name { color: var(--name); font-weight: bold; }
.phead .date { white-space: nowrap; }
.phead .no, .phead .no-ref { color: inherit; }
.phead .no:hover, .phead .no-ref:hover { color: var(--hover); }
.phead .likes { color: var(--muted); font-size: 12px; white-space: nowrap; }
.no-meta .phead .likes { display: none; }
.phead .rank { color: var(--title); font-weight: bold; }
.phead .board-tag { font-weight: bold; }
.acts { font-size: 12px; color: var(--muted); white-space: nowrap; }
.act { background: none; border: 0; padding: 0; margin: 0; color: var(--link); cursor: pointer; font-size: 12px; }
.act:hover { color: var(--hover); text-decoration: underline; }
.act b { font-weight: normal; }
.act.vote.on { color: var(--quote); font-weight: bold; }
.act.vote.on b { font-weight: bold; }

.ptext { margin: 6px 0 4px 2px; white-space: normal; }
.post.op .ptext { margin-left: 4px; }
.greentext { color: var(--green); }
.mention { color: var(--quote); }
.quotelink { color: var(--quote); text-decoration: underline; }
.quotelink:hover { color: var(--hover); }
.link { overflow-wrap: anywhere; }

.file { margin: 2px 0; }
.fileinfo { font-size: 12px; color: var(--muted); margin: 2px 0 3px; overflow-wrap: anywhere; }
.thumbs { display: flex; flex-wrap: wrap; gap: 6px; float: left; margin: 0 16px 6px 0; }
.thumb { display: block; line-height: 0; }
.thumb img { display: block; max-width: 125px; max-height: 125px; cursor: zoom-in; }
.op-file .thumb img { max-width: 250px; max-height: 250px; }
video.thumb { width: 220px; max-width: 100%; max-height: 260px; background: #000; }
.op-file video.thumb { width: 320px; max-height: 360px; }
.file.expanded .thumbs { float: none; }
.file.expanded .thumb img { max-width: 100%; max-height: none; cursor: zoom-out; }
.post.op .file { float: left; margin-right: 16px; }
.post.op .file .thumbs { float: none; margin-right: 0; }
.post.op .file.expanded { float: none; }

.thread-stats { font-size: 12px; color: var(--muted); margin: 10px 0 0; }

/* the final thread */
.thread.final .post.op .ptext, .thread.final .post.reply .ptext { font-size: 1.5em; }
.the-end { text-align: center; color: var(--muted); padding: 30px 0 10px; }
.the-end p { margin: 0; font-weight: bold; }
.the-end .care { margin-top: 12px; font-weight: normal; font-size: 12.5px; }

/* inline comments */
.replies { margin: 2px 0 8px 28px; max-width: 640px; }
.creply {
  background: var(--post); border: 1px solid var(--post-line); border-left: 0; border-top: 0;
  padding: 3px 8px 5px; margin: 3px 0; display: flow-root;
}
.creply .name.anon, .recent .name.anon { color: var(--name); font-weight: bold; }
.creply .cno { color: var(--muted); }
.clist > p { margin: 4px 0; }
.qr { display: grid; gap: 4px; margin-top: 6px; padding: 6px; background: var(--post); border: 1px solid var(--post-line); }
.qr-head { font-size: 12px; font-weight: bold; }
.qr input, .qr textarea {
  width: 100%; font: inherit; font-size: 13px; padding: 3px 5px;
  background: var(--input); color: var(--ink); border: 1px solid var(--input-line); border-radius: 0; resize: vertical;
}
.qr-row { display: flex; justify-content: space-between; align-items: center; font-size: 11px; }
.qr button:disabled { opacity: .5; cursor: default; }

/* search / top lists */
.results .post.op { background: var(--post); border: 1px solid var(--post-line); border-left: 0; border-top: 0; padding: 4px 10px 6px; margin: 6px 0; }

/* ---------- catalog ---------- */
.catalog { display: grid; grid-template-columns: repeat(auto-fill, minmax(165px, 1fr)); gap: 18px 10px; padding: 6px 0; }
.cat { display: flex; flex-direction: column; align-items: center; text-align: center; color: var(--ink); font-size: 12px; overflow-wrap: anywhere; }
.cat:hover { text-decoration: none; color: var(--ink); }
.cat img { max-width: 150px; max-height: 150px; box-shadow: var(--shadow); }
.cat:hover img { box-shadow: 0 0 0 2px var(--link); }
.cat .noimg { width: 120px; height: 90px; display: flex; align-items: center; justify-content: center; background: var(--post); border: 1px solid var(--post-line); color: var(--muted); font-size: 11px; }
.cat-meta { margin-top: 5px; font-size: 11px; color: var(--muted); }
.cat-meta b { color: var(--ink); }
.cat-text { margin-top: 2px; line-height: 1.35; display: -webkit-box; -webkit-line-clamp: 5; -webkit-box-orient: vertical; overflow: hidden; max-width: 180px; }
.cat-text b { color: var(--subject); }

/* ---------- front page ---------- */
.front { max-width: 760px; margin: 0 auto; padding: 10px 0 20px; }
.logo { display: block; max-width: 640px; margin: 4px auto 10px; line-height: 0; }
.logo:hover { filter: brightness(1.08); }
.box { border: 1px solid var(--post-line); margin: 0 0 12px; background: var(--box); }
.box h2 { margin: 0; padding: 3px 8px; background: var(--box-bar); color: var(--box-bar-ink); font-size: 14px; font-weight: bold; font-family: var(--f); }
.box-body { padding: 8px 10px; }
.box-body p { margin: 4px 0 8px; }
.box-body.cols { display: grid; grid-template-columns: 1fr 1fr; gap: 6px 20px; }
.box-body h3 { margin: 4px 0; font-size: 13px; text-decoration: underline; font-family: var(--f); }
.box-body ul { list-style: none; margin: 0; padding: 0; }
.box-body li { padding: 1px 0; }
.box-body .post.op { margin: 0; }
.stats { display: flex; flex-wrap: wrap; gap: 4px 24px; }
.popular { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.pop { display: flex; flex-direction: column; align-items: center; text-align: center; color: var(--ink); font-size: 12px; overflow-wrap: anywhere; }
.pop:hover { text-decoration: none; color: var(--ink); }
.pop img { max-width: 100%; max-height: 140px; margin: 4px 0; box-shadow: var(--shadow); }
.pop:hover img { box-shadow: 0 0 0 2px var(--link); }
.pop-board { font-weight: bold; color: var(--link); }
.pop-text { display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.pop-meta { color: var(--muted); font-size: 11px; margin-top: 2px; }
.recent { list-style: none; margin: 0; padding: 0; }
.recent li { padding: 4px 0; border-bottom: 1px solid var(--post-line); font-size: 13px; }
.recent li:last-child { border-bottom: 0; }
.recent-body { overflow-wrap: anywhere; }
.front-search { margin: 18px auto 0; }

/* ---------- settings window ---------- */
.modal { position: fixed; inset: 0; z-index: 90; background: rgba(0, 0, 0, .35); display: flex; align-items: flex-start; justify-content: center; padding: 70px 12px 12px; }
.window { width: min(420px, 100%); background: var(--post); border: 1px solid var(--post-line); box-shadow: var(--shadow); }
.window-head { display: flex; justify-content: space-between; align-items: center; padding: 3px 4px 3px 8px; background: var(--box-bar); color: var(--box-bar-ink); font-weight: bold; }
.window-x { background: none; border: 0; color: inherit; font-size: 18px; line-height: 1; cursor: pointer; padding: 0 6px; }
.window-body { padding: 6px 10px 10px; }
.setting { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 7px 0; border-bottom: 1px solid var(--post-line); font-size: 13px; }
.setting:last-child { border-bottom: 0; }
.setting.check { justify-content: flex-start; cursor: pointer; }
.seg { display: inline-flex; gap: 0; }
.seg button { padding: 2px 8px; font-size: 12px; background: var(--input); color: var(--ink); border: 1px solid var(--input-line); margin-left: -1px; cursor: pointer; }
.seg button.on { background: var(--link); color: var(--bg); border-color: var(--link); font-weight: bold; }

/* ---------- toast / footer ---------- */
.toast {
  position: fixed; top: 10px; left: 50%; transform: translateX(-50%); z-index: 130;
  background: var(--post); color: var(--ink); border: 1px solid var(--post-line); box-shadow: var(--shadow);
  padding: 6px 14px; font-size: 13px; max-width: calc(100vw - 24px); text-align: center;
}
.footer { text-align: center; font-size: 11px; color: var(--muted); padding: 8px 0 24px; }
.footer p { margin: 3px 0; }

/* ---------- small screens ---------- */
@media (max-width: 640px) {
  body { padding: 0 6px; }
  .boardlist { font-size: 11.5px; }
  .boardlist .nav-right { width: 100%; }
  .banner { width: 260px; }
  .board-title { font-size: 23px; letter-spacing: -1px; }
  .side { display: none; }
  .post.reply { border-left: 1px solid var(--post-line); width: 100%; }
  .thumb img { max-width: 100px; max-height: 100px; }
  .op-file .thumb img { max-width: 150px; max-height: 150px; }
  .post.op .file { margin-right: 10px; }
  video.thumb, .op-file video.thumb { width: 100%; }
  .thumbs { margin-right: 10px; }
  .replies { margin-left: 8px; }
  .catalog { grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); }
  .cat img { max-width: 130px; max-height: 130px; }
  .box-body.cols { grid-template-columns: 1fr; }
  .popular { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* ---------- /pond/: the readers' board ---------- */
.navlinks.center { text-align: center; font-size: 15px; font-weight: bold; margin: 10px 0; }
.pf-wrap { max-width: 520px; margin: 10px auto; }
.postform { display: grid; gap: 3px; }
.postform label { display: grid; grid-template-columns: 86px minmax(0, 1fr); gap: 3px; align-items: stretch; }
.postform label > span {
  background: var(--box-bar); color: var(--box-bar-ink); border: 1px solid var(--post-line);
  font-weight: bold; font-size: 12.5px; padding: 3px 6px; display: flex; align-items: center;
}
.postform input, .postform textarea {
  width: 100%; font: inherit; font-size: 13px; padding: 3px 5px;
  background: var(--input); color: var(--ink); border: 1px solid var(--input-line); border-radius: 0; resize: vertical;
}
.postform .hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.pf-row { display: flex; justify-content: space-between; align-items: center; gap: 10px; font-size: 11px; margin-top: 2px; }
.pf-row button { padding: 3px 14px; font-size: 13px; cursor: pointer; color: var(--ink); background: var(--post); border: 1px solid var(--input-line); border-radius: 2px; }
.pf-row button:hover { border-color: var(--link); }
.pf-row button:disabled { opacity: .5; cursor: default; }
.board-rules { font-size: 11.5px; color: var(--muted); margin-top: 8px; line-height: 1.45; }
.omitted { font-size: 12px; color: var(--muted); margin: 2px 0 4px 2px; }
.phead .you { color: var(--muted); font-weight: bold; font-size: 12px; }
.backlinks { font-size: 11.5px; }
.backlinks .quotelink { margin-right: 3px; }
.post.bpost.highlight { background: var(--hl); border: 1px solid var(--hl-line); }
.readers-board { grid-column: 1 / -1; border-top: 1px solid var(--post-line); padding-top: 6px; margin-top: 4px; }
.readers-board p { margin: 2px 0; }
@media (max-width: 640px) {
  .postform label { grid-template-columns: 70px minmax(0, 1fr); }
  .pf-row { flex-direction: column; align-items: flex-end; }
}

/* ---------- verse references written by readers, and hover previews ---------- */
.vref {
  color: var(--quote); font-weight: bold; text-decoration: none; white-space: nowrap;
  padding: 0 3px; border-radius: 3px;
  background: color-mix(in srgb, var(--quote) 12%, transparent);
  box-shadow: 0 0 0 1px color-mix(in srgb, var(--quote) 25%, transparent);
  animation: vref-shine 3.2s ease-in-out infinite;
}
.vref:hover {
  color: var(--hover); text-decoration: none;
  background: color-mix(in srgb, var(--quote) 22%, transparent);
}
@keyframes vref-shine {
  0%, 100% { text-shadow: 0 0 0 transparent; }
  50% { text-shadow: 0 0 7px color-mix(in srgb, var(--quote) 70%, transparent); }
}
@media (prefers-reduced-motion: reduce) { .vref { animation: none; } }
.ref-preview {
  position: fixed; z-index: 150; max-width: 360px; pointer-events: none;
  background: var(--post); color: var(--ink); border: 1px solid var(--post-line); box-shadow: var(--shadow);
  padding: 6px 9px 7px; font-size: 13px; line-height: 1.4; overflow: hidden;
}
.ref-preview::after { content: ""; display: block; clear: both; }
.ref-preview img { float: left; max-width: 110px; max-height: 110px; margin: 2px 9px 3px 0; }
.ref-preview .pv-head { font-size: 11.5px; color: var(--muted); margin-bottom: 4px; }
.ref-preview .pv-head b { color: var(--name); }
.ref-preview .pv-media { float: left; font-size: 11px; color: var(--muted); margin-right: 8px; }
.ref-preview .pv-text { overflow-wrap: anywhere; }
.ref-preview .pv-post .phead .acts { display: none; }
.ref-preview .pv-post .ptext { margin: 4px 0 0; }

/* ---------- /pond/ images, reports and the moderation queue ---------- */
.pending-box {
  display: flex; align-items: center; justify-content: center; text-align: center;
  width: 125px; height: 90px; font-size: 11px; color: var(--muted);
  background: var(--bg); border: 1px dashed var(--post-line);
}
.file.pending img { outline: 2px dashed var(--title); outline-offset: 2px; min-width: 40px; min-height: 40px; }
.act.mod { color: var(--title); }
.queue-item .post.op { background: var(--post); border: 1px solid var(--post-line); padding: 4px 10px 6px; }
.queue-meta { font-size: 12px; margin: 4px 0 0 2px; }
.queue-meta b { color: var(--title); }
.postform input[type=file] { padding: 2px; font-size: 12px; }

/* ---------- /pond/ catalog (4chan X style) ---------- */
.board-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; font-size: 13px; color: var(--muted); margin: 4px 0 10px; }
.board-bar a.cur { font-weight: bold; color: var(--ink); }
.board-bar input, .board-bar select {
  font: inherit; font-size: 12.5px; padding: 2px 6px; background: var(--input); color: var(--ink);
  border: 1px solid var(--input-line); border-radius: 0;
}
.board-bar input { width: 160px; }
.pcatalog { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 22px 14px; padding: 4px 0 10px; }
.pcat { display: flex; flex-direction: column; align-items: center; text-align: center; color: var(--ink); font-size: 12.5px; overflow-wrap: anywhere; }
.pcat:hover { text-decoration: none; color: var(--ink); }
.pcat-thumb { display: flex; align-items: flex-end; justify-content: center; min-height: 60px; }
.pcat-thumb img { max-width: 150px; max-height: 150px; box-shadow: var(--shadow); }
.pcat:hover .pcat-thumb img { box-shadow: 0 0 0 2px var(--link); }
.pcat-thumb .pending-img { outline: 2px dashed var(--title); outline-offset: 2px; }
.pcat .noimg { width: 120px; height: 80px; display: flex; align-items: center; justify-content: center; text-align: center; background: var(--post); border: 1px solid var(--post-line); color: var(--muted); font-size: 11px; }
.pcat-meta { margin-top: 5px; font-size: 11px; color: var(--muted); }
.pcat-meta b { color: var(--ink); }
.pcat-text { margin-top: 2px; line-height: 1.35; max-width: 200px; display: -webkit-box; -webkit-line-clamp: 7; -webkit-box-orient: vertical; overflow: hidden; }
.pcat-text .subject { color: var(--subject); display: block; }
.ref-preview.wide { max-width: min(560px, 90vw); padding: 8px 10px; }
.ref-preview .pv-big { display: block; float: none; max-width: 100%; max-height: 60vh; margin: 0 0 6px; }

.captcha { margin: 2px 0 0 89px; min-height: 0; }
@media (max-width: 640px) { .captcha { margin-left: 0; } }

/* ==========================================================================
   Scripture pages (#/bible): the archive typeset like a printed Bible.
   ========================================================================== */
body.bible {
  --b-bg: #f3ead6; --b-paper: #faf5e9; --b-ink: #2a2017; --b-ink2: #5b4b38; --b-muted: #8b7a60;
  --b-rubric: #9f2a1d; --b-gold: #97701f; --b-rule: #d9c9a7;
  --f-bible: "Palatino Linotype", "Book Antiqua", Palatino, "Iowan Old Style", Georgia, serif;
  background: var(--b-bg); color: var(--b-ink);
}
:root[data-theme="dark"] body.bible {
  --b-bg: #15120e; --b-paper: #1d1913; --b-ink: #e9ddc7; --b-ink2: #c7b79c; --b-muted: #958670;
  --b-rubric: #e0826b; --b-gold: #d3aa55; --b-rule: #3b3126;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme]) body.bible {
    --b-bg: #15120e; --b-paper: #1d1913; --b-ink: #e9ddc7; --b-ink2: #c7b79c; --b-muted: #958670;
    --b-rubric: #e0826b; --b-gold: #d3aa55; --b-rule: #3b3126;
  }
}
body.bible .boardlist { color: var(--b-muted); }
body.bible .boardlist a, body.bible .boardlist button { color: var(--b-ink2); }
body.bible .boardlist a:hover, body.bible .boardlist button:hover { color: var(--b-rubric); }
body.bible .boardlist.bottom, body.bible hr { border-color: var(--b-rule); }
body.bible .footer { color: var(--b-muted); }
body.bible .footer a { color: var(--b-ink2); }

.bible-page { max-width: 700px; margin: 0 auto; padding: 0 6px 24px; font-family: var(--f-bible); }
.b-mast { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 14px 0 10px; border-bottom: 1px solid var(--b-rule); }
.b-mast-title { font-variant: small-caps; letter-spacing: .14em; font-size: 15px; color: var(--b-ink2); }
.b-mast-title:hover { color: var(--b-rubric); text-decoration: none; }
.b-goto input {
  font-family: var(--f-bible); font-size: 14px; width: 170px; padding: 4px 12px;
  background: var(--b-paper); color: var(--b-ink); border: 1px solid var(--b-rule); border-radius: 999px; outline: none;
}
.b-goto input:focus { border-color: var(--b-gold); }
.b-goto input::placeholder { color: var(--b-muted); font-style: italic; }

/* title page and contents */
.b-titlepage { text-align: center; padding: 48px 0 26px; }
.b-orn { color: var(--b-rubric); font-size: 26px; line-height: 1; }
.b-titlepage h1 { font-family: var(--f-bible); font-weight: normal; font-variant: small-caps; letter-spacing: .07em; font-size: clamp(34px, 7vw, 54px); margin: 12px 0; color: var(--b-ink); }
.b-tp-sub { font-style: italic; font-size: 18px; color: var(--b-ink2); line-height: 1.5; margin: 0; }
.b-tp-rule { color: var(--b-gold); margin: 18px 0 6px; font-size: 18px; }
.b-tp-small { font-variant: small-caps; letter-spacing: .16em; color: var(--b-muted); font-size: 13px; margin: 0; }
.b-contents { display: grid; grid-template-columns: 1fr 1fr; gap: 0 44px; padding: 14px 0 10px; }
.b-contents h2 { font-family: var(--f-bible); font-weight: normal; font-variant: small-caps; letter-spacing: .14em; font-size: 15px; color: var(--b-rubric); text-align: center; border-bottom: 1px solid var(--b-rule); padding-bottom: 6px; margin: 0 0 6px; }
.b-toc { display: grid; grid-template-columns: auto 1fr auto 24px; gap: 8px; align-items: baseline; padding: 6px 2px; color: var(--b-ink); font-size: 17px; }
.b-toc:hover { color: var(--b-rubric); text-decoration: none; }
.b-toc-dots { border-bottom: 1.5px dotted var(--b-rule); transform: translateY(-4px); }
.b-toc-abbr { font-size: 13px; color: var(--b-rubric); letter-spacing: .04em; }
.b-toc-ch { font-size: 13px; color: var(--b-muted); text-align: right; }

/* a book's opening page */
.b-bookpage { text-align: center; padding: 42px 0 18px; }
.b-kicker { font-variant: small-caps; letter-spacing: .14em; color: var(--b-muted); font-size: 13px; }
.b-bookpage h1, .b-chapter-book { font-family: var(--f-bible); font-weight: normal; font-size: clamp(36px, 7vw, 56px); letter-spacing: .02em; margin: 10px 0 2px; color: var(--b-ink); text-align: center; }
.b-book-title { font-style: italic; color: var(--b-ink2); font-size: 19px; margin: 0 0 12px; text-align: center; }
.b-book-desc { color: var(--b-ink2); max-width: 520px; margin: 0 auto 24px; line-height: 1.55; font-size: 16.5px; }
.b-chapters { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; max-width: 560px; margin: 0 auto; }
.b-chapters a {
  width: 42px; height: 42px; display: flex; align-items: center; justify-content: center; border-radius: 50%;
  border: 1px solid var(--b-rule); background: var(--b-paper); color: var(--b-rubric); font-size: 17px;
}
.b-chapters a:hover { border-color: var(--b-rubric); text-decoration: none; }
.b-book-meta { margin-top: 22px; color: var(--b-muted); font-size: 14px; font-style: italic; }
.b-book-meta a { color: var(--b-ink2); }

/* a chapter */
.b-runhead { display: flex; justify-content: space-between; padding: 6px 2px 0; font-variant: small-caps; letter-spacing: .16em; color: var(--b-muted); font-size: 12.5px; }
.b-chapter { padding: 16px 0 4px; }
.b-chapter-num { font-family: var(--f-bible); font-weight: normal; font-variant: small-caps; letter-spacing: .18em; color: var(--b-rubric); font-size: 17px; text-align: center; margin: 14px 0 2px; }
.b-super { text-align: center; font-style: italic; color: var(--b-muted); font-size: 15px; margin: 0 0 20px; }
.b-text { font-size: calc(var(--fs) * 1.32); line-height: 1.78; text-align: justify; hyphens: auto; color: var(--b-ink); }
.b-para { margin: 0 0 .85em; text-indent: 1.4em; }
.b-para:first-child { text-indent: 0; }
.b-para::after { content: ""; display: block; clear: both; }
.bv { overflow-wrap: anywhere; border-radius: 3px; -webkit-box-decoration-break: clone; box-decoration-break: clone; transition: background .3s; }
.bv.b-hl { background: color-mix(in srgb, var(--b-gold) 26%, transparent); }
.b-vn {
  font-family: var(--f-bible); font-size: .6em; font-weight: bold; vertical-align: super; line-height: 0;
  color: var(--b-rubric); margin: 0 .2em 0 .12em; text-indent: 0;
}
.b-vn:hover { text-decoration: underline; color: var(--b-rubric); }
.b-drop { float: left; font-size: 3.7em; line-height: .8; color: var(--b-rubric); margin: .06em .12em 0 0; }
.b-drop:hover { text-decoration: none; color: var(--b-gold); }
.b-text a.link { color: var(--b-rubric); }
.b-ill { display: inline-block; vertical-align: middle; margin: 2px 5px; text-indent: 0; line-height: 0; }
.b-ill img { display: block; max-height: 92px; max-width: 124px; padding: 2px; background: var(--b-paper); border: 1px solid var(--b-rule); box-shadow: 0 1px 3px rgba(0, 0, 0, .18); }
.b-ill:hover img { border-color: var(--b-gold); }
.b-vid { line-height: 1.4; font-size: .62em; font-variant: small-caps; letter-spacing: .08em; color: var(--b-gold); border: 1px solid var(--b-rule); padding: 0 7px; border-radius: 3px; }
.b-vid:hover { color: var(--b-rubric); text-decoration: none; }

/* the last chapter */
.b-chapter.final .b-text { text-align: center; font-size: calc(var(--fs) * 1.9); line-height: 1.5; }
.b-chapter.final .b-para { text-indent: 0; margin: 0 0 1.4em; }
.b-chapter.final .b-ill { display: block; margin: 14px auto 0; }
.b-chapter.final .b-ill img { max-height: none; max-width: 100%; margin: 0 auto; }
.b-end { text-align: center; font-variant: small-caps; letter-spacing: .18em; color: var(--b-muted); margin: 34px 0 0; }
.b-care { text-align: center; font-family: var(--f); font-size: 12.5px; color: var(--b-muted); }
.b-care a { color: var(--b-ink2); }

.navlinks.b-pager {
  display: flex; justify-content: space-between; align-items: center; gap: 10px; margin-top: 26px; padding-top: 14px;
  border-top: 1px solid var(--b-rule); font-variant: small-caps; letter-spacing: .1em; font-size: 15px; color: var(--b-muted);
}
.navlinks.b-pager a { color: var(--b-ink2); }
.navlinks.b-pager a:hover { color: var(--b-rubric); }
.b-discuss { text-align: center; font-size: 14px; font-style: italic; margin: 14px 0 0; }
.b-discuss a { color: var(--b-muted); }
.b-discuss a:hover { color: var(--b-rubric); }

@media (max-width: 640px) {
  .b-contents { grid-template-columns: 1fr; gap: 18px; }
  .b-text { text-align: left; }
  .b-mast { flex-wrap: wrap; }
  .b-goto input { width: 150px; }
}
