/* reader.css — the Bible (home, chapter reader, verse notes panel, sacred art, chant page). Every class starts with "rd-" (modifiers is-*). */

/* ------------------------------------------------------------------ home #/ */
.rd-home-goto { max-width: 34rem; margin: 0 auto; }
.rd-home-grid { display: grid; gap: 14px; margin-top: 20px; grid-template-columns: minmax(0, 1fr); }
@media (min-width: 860px) { .rd-home-grid { grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); align-items: start; } }
.rd-home-side { display: grid; gap: 14px; min-width: 0; grid-template-columns: minmax(0, 1fr); }
/* no picture of the day (no art on the site): the cards share the full width */
.rd-home-grid.is-one { grid-template-columns: minmax(0, 1fr); }
@media (min-width: 860px) { .rd-home-grid.is-one .rd-home-side { grid-template-columns: repeat(auto-fit, minmax(300px, 400px)); justify-content: center; align-items: start; } }
.rd-potd-in { display: grid; grid-template-columns: minmax(0, 1fr); gap: 16px; margin-top: 10px; }
@media (min-width: 560px) { .rd-potd-in { grid-template-columns: 42% minmax(0, 1fr); } }
.rd-potd-frame { display: block; width: auto; border: 0; padding: 0; cursor: zoom-in; border-radius: 6px; overflow: hidden; background: var(--surface-3); aspect-ratio: 4 / 5; margin: 6px;
  box-shadow: 0 0 0 1px var(--gold-2), 0 0 0 5px var(--surface), 0 0 0 6px var(--border-2), 0 10px 30px rgba(0, 0, 0, .18); }
.rd-potd-frame img { width: 100%; height: 100%; object-fit: cover; display: block; }
.rd-potd-cap { min-width: 0; }
.rd-potd-cap h3 { font-family: var(--display); font-size: 26px; font-weight: 600; margin: 4px 0 2px; line-height: 1.12; }
.rd-potd-by { color: var(--ink-2); font-style: italic; }
.rd-potd-ref { display: inline-block; margin-top: 10px; color: var(--rubric); font-variant: small-caps; letter-spacing: .05em; font-size: 17px; text-decoration: none; font-weight: 600; }
.rd-potd-cap blockquote { margin: 8px 0 0; font-size: 18px; line-height: 1.5; color: var(--ink-2); }
.rd-potd-more { display: inline-block; margin-top: 10px; font: 600 13px var(--sans); text-decoration: none; }
.rd-cont { display: flex; gap: 14px; align-items: center; }
.rd-cont-n { font-family: var(--display); font-size: 48px; font-weight: 600; color: var(--rubric); line-height: 1; min-width: 56px; text-align: center; font-variant-numeric: lining-nums; }
.rd-cont-b { min-width: 0; }
.rd-cont-t { font-size: 22px; font-weight: 600; line-height: 1.2; margin-top: 2px; }
.rd-cont-s { color: var(--muted); font-size: 16px; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.rd-today-t { color: var(--ink-2); font-size: 16px; margin-top: 4px; font-style: italic; }
.rd-today-none { margin: 8px 0 0; color: var(--muted); }
.rd-rlist { list-style: none; padding: 0; margin: 8px 0 0; }
.rd-rlist li { border-top: 1px solid var(--border); }
.rd-rlist li:first-child { border-top: 0; }
.rd-rd { display: flex; align-items: center; gap: 8px; }
.rd-rd-a, .rd-rlist li > a:only-child { flex: 1; min-width: 0; display: flex; justify-content: space-between; align-items: baseline; gap: 10px; padding: 9px 0; text-decoration: none; color: inherit; }
.rd-rd-k { font: 700 12px var(--sans); letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.rd-rd-r { color: var(--rubric); font-variant: small-caps; letter-spacing: .04em; font-weight: 600; white-space: nowrap; }
.rd-rd-s { flex: none; font: 600 12px var(--sans); border: 1px solid var(--border-2); border-radius: var(--r-pill); padding: 2px 9px; text-decoration: none; color: var(--ink-2); }
.rd-rd-s:hover { border-color: var(--gold-2); color: var(--ink); }
.rd-rl-t { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rd-rl-r { flex: none; color: var(--rubric); font-variant: small-caps; letter-spacing: .03em; white-space: nowrap; }
.rd-home-acts { display: flex; gap: 8px; justify-content: center; flex-wrap: wrap; margin-top: 20px; }
.rd-home-books { margin-top: 30px; }

/* ------------------------------------------------------------------ chapter reader */
.rd-page.is-side { max-width: 70rem; }
@media (min-width: 1000px) { body.nx-panel-open .rd-page { margin-right: 436px; } body.nx-panel-open .rd-page.is-side { margin-left: 16px; } }
.rd-chead { text-align: center; padding: 18px 0 6px; }
.rd-booktitle { font-variant: small-caps; letter-spacing: .1em; color: var(--muted); font-size: 16px; line-height: 1.35; max-width: 30rem; margin: 0 auto; }
.rd-cword { font-variant: small-caps; letter-spacing: .18em; color: var(--gold); font-size: 14px; margin-top: 6px; }
.rd-cnum { font-family: var(--display); font-weight: 600; font-size: 64px; line-height: 1; color: var(--rubric); margin-top: 4px; font-variant-numeric: lining-nums; }
.rd-cnum.is-word { font-size: 42px; margin-top: 10px; }
.rd-incipit { font-family: var(--display); font-style: italic; font-size: 26px; color: var(--rubric); margin-top: 6px; }
.rd-summary { font-style: italic; color: var(--ink-2); font-size: 18px; max-width: 30rem; margin: 12px auto 0; line-height: 1.45; }
.rd-ctools { display: flex; justify-content: center; gap: 8px; margin-top: 14px; flex-wrap: wrap; }
.rd-intro { font-size: 17px; color: var(--ink-2); border-left: 2px solid var(--gold-2); padding: 2px 0 2px 14px; margin: 18px 0 8px; }
.rd-intro summary { cursor: pointer; font: 700 12px var(--sans); letter-spacing: .12em; text-transform: uppercase; color: var(--gold); }
.rd-intro p { margin: 8px 0 0; }
.rd-body { margin-top: 16px; }
.rd-text p { margin: 0 0 .1em; text-indent: 1.2em; }
.rd-text p.rd-v:first-child, .rd-text .rd-oip, .rd-text p.rd-flow:first-child { text-indent: 0; }
.rd-text p.rd-oip { display: flow-root; }
.rd-text .rd-flow { margin-bottom: .5em; }
.rd-v { scroll-margin-top: calc(var(--nxh) + 12px); border-radius: 3px; }
.rd-v.is-sel { background: color-mix(in srgb, var(--gold-2) 22%, transparent); box-shadow: 0 0 0 2px color-mix(in srgb, var(--gold-2) 22%, transparent); }
.rd-poem { text-indent: 0 !important; padding-left: 1.4em; }
.rd-vn { font-family: var(--sans); font-size: .56em; font-weight: 700; color: var(--rubric); vertical-align: .55em; margin: 0 .22em 0 .12em; cursor: pointer; user-select: none; -webkit-user-select: none;
  font-variant-numeric: lining-nums; line-height: 0; }
.rd-oip > .rd-vn, .rd-oip > .rd-v:first-child > .rd-vn { display: none; }       /* the drop cap stands for verse 1 */
html[data-s-vn="off"] .rd-vn { display: none; }
.rd-fn { color: var(--rubric); font-size: .62em; vertical-align: .6em; line-height: 0; cursor: pointer; padding: 0 .12em; font-family: var(--sans); font-weight: 700; user-select: none; -webkit-user-select: none; }
.rd-hy { color: var(--gold); font-size: .5em; vertical-align: .62em; line-height: 0; cursor: pointer; padding: 0 .12em; font-family: var(--sans); font-weight: 800; user-select: none; -webkit-user-select: none; opacity: .6; }
.rd-hy:hover { opacity: 1; }
html[data-s-chal="off"] .rd-fn, html[data-s-hay="off"] .rd-hy { display: none; }
.rd-text mark .oi .oi-l, .rd-text .oi mark { background: none; }
.rd-lat { display: block; font-style: italic; color: var(--muted); font-size: .86em; line-height: 1.45; text-indent: 0; margin: .05em 0 .45em; }
.rd-acro { text-align: center; font-variant: small-caps; letter-spacing: .14em; color: var(--rubric); margin: .8em 0 .2em; text-indent: 0; font-size: .85em; }
/* side by side: Douay-Rheims | Vulgata Clementina */
.rd-par { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); column-gap: 34px; }
.rd-par .rd-v, .rd-par .rd-la { padding: .12em 0; }
.rd-par-full { grid-column: 1 / -1; }
.rd-la { font-style: italic; color: var(--ink-2); border-left: 1px solid var(--border); padding-left: 16px !important; }
.rd-lavn { font: normal 700 .56em var(--sans); color: var(--rubric); vertical-align: .55em; margin-right: .25em; line-height: 0; }
.rd-colh { font-variant: small-caps; letter-spacing: .12em; color: var(--muted); font-size: 15px; padding-bottom: 8px; border-bottom: 1px solid var(--border); margin-bottom: 6px; }
@media (max-width: 759px) {
  .rd-par { grid-template-columns: minmax(0, 1fr); }
  .rd-la { border-left: 0; padding-left: 0 !important; font-size: .88em; color: var(--muted); padding-bottom: .5em !important; }
  .rd-colh { display: none; }
}
/* inline sacred art */
.rd-art { margin: 26px -4px 22px; text-align: center; cursor: zoom-in; text-indent: 0; }
.rd-art .rd-frame { display: inline-block; max-width: 100%; padding: 7px; background: var(--surface); border: 1px solid var(--gold-2); border-radius: 2px;
  box-shadow: 0 0 0 5px var(--surface), 0 0 0 6px var(--border-2), 0 16px 40px rgba(30, 20, 5, .2); }
.rd-art img { display: block; max-width: 100%; max-height: 62vh; width: auto; height: auto; border-radius: 1px; background: var(--surface-3); }
.rd-art figcaption { margin-top: 14px; font-size: 16px; color: var(--ink-2); line-height: 1.35; text-align: center; }
.rd-art figcaption b { font-style: italic; font-weight: 500; font-size: 18px; color: var(--ink); }
.rd-art figcaption span { display: block; font-family: var(--sans); font-size: 12px; color: var(--muted); margin-top: 3px; letter-spacing: .02em; }
.rd-art.is-missing .rd-frame { display: none; }
html[data-s-art="off"] .rd-art { display: none; }
.rd-strip { display: flex; gap: 10px; overflow-x: auto; padding: 4px 2px 10px; scrollbar-width: thin; }
.rd-thumb { flex: none; border: 0; padding: 0; background: none; cursor: pointer; text-align: left; width: 132px; color: inherit; font: inherit; }
.rd-thumb img { width: 132px; height: 165px; object-fit: cover; border-radius: 6px; display: block; box-shadow: 0 0 0 1px var(--border-2); background: var(--surface-3); }
.rd-thumb.is-missing img { visibility: hidden; }
.rd-thumb span { display: block; font-size: 13.5px; line-height: 1.25; margin-top: 5px; color: var(--ink-2); }
.rd-thumb i { display: block; font: normal 11.5px var(--sans); color: var(--muted); margin-top: 1px; }
.rd-moreart { margin-top: 34px; }
.rd-endnav { display: flex; justify-content: space-between; gap: 12px; margin-top: 40px; padding-top: 16px; border-top: 1px solid var(--border); }
.rd-endnav a { text-decoration: none; color: var(--ink); max-width: 48%; padding: 4px 6px; border-radius: 10px; }
.rd-endnav a:hover { background: var(--surface-2); }
.rd-endnav small { display: block; font: 12px var(--sans); color: var(--muted); text-transform: uppercase; letter-spacing: .1em; }
.rd-endnav b { font-size: 20px; font-weight: 600; }
.rd-next { text-align: right; margin-left: auto; }
.rd-st-add { color: var(--gold-2) !important; }

/* ------------------------------------------------------------------ verse notes panel */
.rd-pbody { font-size: 17px; }
.rd-p-vtext { font-size: 19px; line-height: 1.5; margin: 0 0 12px; }
.rd-p-vtext.is-la { font-style: italic; color: var(--ink-2); font-size: 17.5px; margin: 0; }
.rd-p-vn { font: 700 .6em var(--sans); color: var(--rubric); vertical-align: .5em; margin-right: .25em; }
.rd-p-tools { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.rd-p-strip { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--border); }
.rd-badges { display: contents; }
.rd-badge { font: 600 12px var(--sans); text-decoration: none; color: var(--ink-2); border: 1px solid var(--border-2); border-radius: var(--r-pill); padding: 3px 9px; border-left: 3px solid var(--c, var(--gold)); }
.rd-badge b { color: var(--ink); }
.rd-badge.is-fa { --c: var(--c-fa); } .rd-badge.is-st { --c: var(--c-st); } .rd-badge.is-cat { --c: var(--c-cat); } .rd-badge.is-cm { --c: var(--c-cm); }
.rd-note { padding: 8px 0; border-top: 1px solid var(--border); }
.rd-note:first-of-type { border-top: 0; }
.rd-note-q { font-style: italic; color: var(--ink-2); font-size: 15.5px; }
.rd-note-t { white-space: pre-wrap; margin-top: 2px; }
.rd-note-m { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; font: 12px var(--sans); color: var(--muted); margin-top: 4px; }
.rd-note-l { font-variant: small-caps; color: var(--rubric); font-weight: 600; text-decoration: none; letter-spacing: .03em; }
.rd-comm { font-size: 17px; line-height: 1.55; }
.rd-comm p { margin: 0 0 .7em; }
.rd-comm .ui-prose { font-size: inherit; }
.rd-aside { display: block; font-size: 15px; color: var(--ink-2); background: var(--surface-2); border-radius: 8px; padding: 6px 10px; margin: .4em 0; }
.rd-src { font-variant: small-caps; color: var(--gold); letter-spacing: .04em; }
.rd-key { font-style: italic; color: var(--rubric); }
.rd-xlist { list-style: none; margin: 0; padding: 0; }
.rd-xlist li { border-top: 1px solid var(--border); }
.rd-xlist li:first-child { border-top: 0; }
.rd-xlist a { display: block; padding: 8px 0; text-decoration: none; color: inherit; font-size: 16.5px; line-height: 1.4; }
.rd-xlist a b { color: var(--rubric); font-weight: 600; font-variant: small-caps; letter-spacing: .03em; margin-right: 6px; }
.rd-xlist a b.is-cat { font: 700 13px var(--sans); font-variant: normal; letter-spacing: 0; }
.rd-pv { color: var(--ink-2); }
.rd-lbl { font: 700 11.5px var(--sans); color: var(--gold); margin: 0 6px 0 2px; }
.rd-lbl.is-qt { text-decoration: underline dotted; text-decoration-color: var(--gilt); text-underline-offset: 3px; }

/* ------------------------------------------------------------------ lightbox */
.rd-lb { pointer-events: auto; background: rgba(10, 8, 5, .95); color: #efe6d6; display: grid; grid-template-rows: auto minmax(0, 1fr) auto; opacity: 0; transition: opacity .2s; }
.rd-lb.on { opacity: 1; }
.rd-lb-top { display: flex; justify-content: flex-end; gap: 6px; padding: calc(10px + env(safe-area-inset-top)) 10px 10px; }
.rd-lb-b { border: 0; background: rgba(255, 255, 255, .12); color: #fff; width: 42px; height: 42px; border-radius: 50%; cursor: pointer; font-size: 21px; display: grid; place-items: center; text-decoration: none; }
.rd-lb-b[hidden] { display: none; }
.rd-lb-stage { min-height: 0; position: relative; overflow: hidden; }
.rd-lb-img { position: absolute; inset: 0; margin: auto; max-width: calc(100% - 16px); max-height: 100%; object-fit: contain; box-shadow: 0 20px 60px rgba(0, 0, 0, .5); }
.rd-lb-img.is-missing { min-width: 200px; min-height: 260px; background: rgba(255, 255, 255, .06); }
.rd-lb-nav { position: absolute; top: 50%; transform: translateY(-50%); border: 0; background: rgba(255, 255, 255, .12); color: #fff; width: 44px; height: 64px; border-radius: 10px; cursor: pointer; font-size: 26px; }
.rd-lb-nav.is-l { left: 8px; } .rd-lb-nav.is-r { right: 8px; }
.rd-lb-cap { padding: 14px 18px calc(20px + env(safe-area-inset-bottom)); text-align: center; font-family: var(--serif); }
.rd-lb-cap b { font-family: var(--display); font-size: 26px; font-weight: 600; font-style: italic; display: block; line-height: 1.2; }
.rd-lb-cap span { display: block; font: 12.5px var(--sans); color: #b9ad97; margin-top: 4px; }
.rd-lb-cap a { color: #e9c98a; font: 600 14px var(--sans); margin-top: 8px; display: inline-block; }

/* ------------------------------------------------------------------ gallery #/art */
.rd-gal-bar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin: 4px 0 8px; }
.rd-gal-ct { font: 12.5px var(--sans); color: var(--muted); }
.rd-gal-h { font-family: var(--display); font-size: 26px; font-weight: 600; margin: 18px 0 8px; display: flex; align-items: baseline; gap: 8px; }
.rd-gal-h .ui-ct { font: 600 13px var(--sans); }
.rd-masonry { columns: 2 150px; column-gap: 12px; }
@media (min-width: 900px) { .rd-masonry { columns: 4 200px; } }
.rd-tile { display: block; width: 100%; break-inside: avoid; margin: 0 0 12px; border: 0; background: none; padding: 0; cursor: zoom-in; text-align: left; color: inherit; font: inherit; }
.rd-tile img { width: 100%; height: auto; display: block; border-radius: 6px; background: var(--surface-3); box-shadow: 0 0 0 1px var(--border-2); }
.rd-tile.is-missing img { visibility: hidden; }
.rd-tile-t { display: block; font-size: 14.5px; line-height: 1.3; margin-top: 5px; color: var(--ink-2); }
.rd-tile-t i { display: block; font: normal 11.5px var(--sans); color: var(--muted); margin-top: 1px; }

/* ------------------------------------------------------------------ chant #/chant */
.rd-chant .rd-chead { padding-top: 6px; }
.rd-chantbox { margin-top: 18px; }
.rd-chant .cv-title { display: none; }
.rd-chant .cv-head { text-align: center; margin-top: 4px; }

@media print {
  .rd-endnav, .rd-ctools, .rd-art, .rd-strip, .rd-moreart, .mk, .rd-fn, .rd-hy { display: none !important; }
  .rd-text { font-size: 12pt; }
  .hl-yellow, .hl-green, .hl-blue, .hl-rose, .hl-violet { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
}
/* verse notes panel: parable, theme and glossary/dictionary chips (from the parables, study and words modules) */
.rd-ext { display: grid; gap: 8px; margin: 12px 0 2px; }
.rd-ext:not(:has(.rd-extrow:not([hidden]))) { display: none; }
.rd-extrow { display: grid; gap: 5px; }
.rd-extrow[hidden] { display: none; }
.rd-extl { font: 700 11px var(--sans); letter-spacing: .08em; text-transform: uppercase; color: var(--gold); }
.rd-extc { display: flex; flex-wrap: wrap; gap: 6px; }
.rd-ext .wd-see { font-size: 15px; padding: 3px 11px; }
