/* Another God (dakebible.org): shared stylesheet.
   Design A, chosen October 8, 2026: today's cream and green, cleaned up.
   Every page links this file and carries no <style> block of its own. */

@import url("https://fonts.googleapis.com/css2?family=Source+Serif+4:ital,opsz,wght@0,8..60,400;0,8..60,600;0,8..60,700;1,8..60,400;1,8..60,600&display=swap");

:root {
  --page-bg: #ece9e1;
  --paper: #fffdf8;
  --ink: #20211f;
  --muted: #4f5a55;
  --green: #2e6e5e;
  --green-dark: #173e35;
  --rule: #c9ddd5;
  --quote-bg: #eef5f1;
  --quote-ink: #1f4a40;
  --dake-bg: #f6f1fa;    --dake-border: #d9c9ea;  --dake-ink: #5b3f86;
  --terms-bg: #f8efe7;   --terms-border: #e3c8b2; --terms-ink: #8a4524;
  --note-bg: #eef3f8;    --note-border: #c8d7e6;  --note-ink: #2c5878;
  --key-bg: #fbf6e6;     --key-border: #e6d29a;   --key-ink: #7a5a0c;
}

html { background: var(--page-bg); }
body {
  margin: 0;
  background: var(--page-bg);
  color: var(--ink);
  font-family: "Source Serif 4", Georgia, "Times New Roman", serif;
  font-size: 19px;
  line-height: 1.7;
  -webkit-text-size-adjust: 100%;
}
a { color: var(--green); }
a:hover { color: var(--green-dark); }
a:focus-visible { outline: 2px solid var(--green); outline-offset: 2px; }

/* ---------- Site header (the site name on every page) ---------- */
.site-header { background: var(--green-dark); padding: 1.25rem 1rem; text-align: center; }
.site-header .site-name {
  color: var(--paper); text-decoration: none;
  font-size: 1.55rem; font-weight: 600; letter-spacing: 0.01em;
}
.site-header .site-name:hover { color: #ffffff; text-decoration: underline; }
.site-header .site-name img { display: block; max-width: 100%; height: auto; margin: 0 auto; } /* a future banner */

/* ---------- The paper column ---------- */
.page {
  display: block;
  max-width: 50rem; margin: 0 auto;
  background: var(--paper);
  padding: 1.5rem clamp(1rem, 5vw, 4rem) 3rem;
  box-sizing: border-box;
}

/* ---------- Navigation ---------- */
nav.chapter-nav {
  display: flex; flex-wrap: wrap; justify-content: center; gap: 0.25rem 1.25rem;
  margin: 0 0 2rem; padding: 0.6rem 0;
  border-top: 1px solid var(--rule); border-bottom: 1px solid var(--rule);
  font-size: 0.9em; font-style: italic;
}
nav.chapter-nav a { color: var(--green); text-decoration: none; }
nav.chapter-nav a:hover { text-decoration: underline; }
nav.chapter-nav .nav-sep { display: none; }
nav.chapter-nav.bottom { margin: 3rem 0 0; }

/* ---------- Chapter heading ---------- */
.chapter-num {
  margin: 2.5rem 0 0; text-align: center;
  font-size: 0.82em; letter-spacing: 0.18em; text-transform: uppercase; color: var(--green);
}
h1 { margin: 0.3rem 0 0; text-align: center; font-size: 2.3em; line-height: 1.2; font-weight: 700; color: var(--green-dark); }
.chapter-subtitle { margin: 0.6rem 0 2.5rem; text-align: center; font-style: italic; color: var(--muted); }

/* ---------- Body text ---------- */
h2 { margin: 2.2em 0 0.6em; font-size: 1.4em; line-height: 1.3; font-weight: 700; color: var(--green); }
h3 { margin: 1.8em 0 0.5em; font-size: 1.15em; line-height: 1.35; font-weight: 700; color: var(--green-dark); }
p { margin: 0 0 1.1em; }
p.no-indent { text-indent: 0; }
ul, ol { margin: 0 0 1.1em; padding-left: 1.6em; }
li { margin-bottom: 0.35em; }

/* ---------- Quotations ---------- */
blockquote { margin: 1.4em 0; }
blockquote p { margin: 0 0 0.6em; }
blockquote p:last-child { margin-bottom: 0; }
blockquote.source {
  padding: 1rem 1.4rem; background: var(--quote-bg); border-radius: 6px;
  font-style: italic; color: var(--quote-ink);
}
blockquote.scripture { margin: 1.2em 0; padding: 0 0 0 1.6rem; font-style: italic; color: var(--quote-ink); }
.attribution {
  display: block; margin-top: 0.5rem;
  font-style: normal; font-size: 0.85em; text-align: right; color: var(--muted);
}

/* ---------- Callout boxes ---------- */
.callout { margin: 1.8em 0; padding: 1.1rem 1.4rem; border: 1px solid; border-radius: 8px; }
.callout p { margin: 0 0 0.55em; }
.callout > p:first-child {
  margin-bottom: 0.6rem;
  font-size: 0.78em; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase;
}
.callout > p:last-child { margin-bottom: 0; }
.callout-source { background: var(--dake-bg); border-color: var(--dake-border); }
.callout-source > p:first-child { color: var(--dake-ink); }
.callout-source blockquote.source { margin: 0; padding: 0; background: none; border-radius: 0; color: var(--ink); }
.callout-terms { background: var(--terms-bg); border-color: var(--terms-border); }
.callout-terms > p:first-child { color: var(--terms-ink); }
.callout-note { background: var(--note-bg); border-color: var(--note-border); }
.callout-note > p:first-child { color: var(--note-ink); }
.callout-key { background: var(--key-bg); border-color: var(--key-border); }
.callout-key > p:first-child { color: var(--key-ink); }

/* ---------- Photographs of pages ---------- */
figure.plate { margin: 1.8em 0; text-align: center; }
figure.plate img { max-width: 100%; height: auto; border: 1px solid var(--rule); border-radius: 2px; }
figure.plate figcaption { margin-top: 0.5em; font-size: 0.85em; font-style: italic; color: var(--muted); }

/* ---------- Tables (appendices) ---------- */
.table-wrap { overflow-x: auto; margin: 1.4em 0; }
table.compare { width: 100%; border-collapse: collapse; font-size: 0.92em; line-height: 1.5; }
table.compare th, table.compare td { border: 1px solid var(--rule); padding: 0.5em 0.7em; text-align: left; vertical-align: top; }
table.compare th { background: var(--quote-bg); color: var(--green-dark); }
span.verdict {
  display: inline-block; margin-top: 0.3em;
  font-size: 0.78em; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--terms-ink);
}

/* ---------- Footnotes ---------- */
sup.fn { line-height: 0; }
sup.fn a { font-size: 0.75em; font-weight: 600; text-decoration: none; }
.footnotes { margin-top: 2.5rem; font-size: 0.86em; line-height: 1.6; }
.footnotes h2 { margin-top: 0; font-size: 1.15em; }
.footnotes p { margin: 0 0 0.45rem; }
.fn-back { margin-right: 0.3em; text-decoration: none; }

/* ---------- Original languages ---------- */
.greek, .hebrew, .latin { font-style: normal; color: var(--quote-ink); }

/* ---------- Home page ---------- */
.book-title { margin: 2rem 0 0; font-size: 2.6em; }
.book-subtitle { margin: 0.5rem 0 0; text-align: center; font-size: 1.1em; font-style: italic; color: var(--muted); }
.book-author { margin: 1rem 0 0; text-align: center; color: var(--muted); }
.epigraph { margin: 2rem auto 0.3rem; max-width: 34rem; text-align: center; font-style: italic; color: var(--quote-ink); }
.epigraph-ref { margin: 0 0 2rem; text-align: center; font-size: 0.88em; color: var(--muted); }
.toc-part {
  margin: 2.2em 0 0.6em; padding-bottom: 0.25em; border-bottom: 1px solid var(--rule);
  font-size: 1.12em; font-weight: 700; color: var(--green-dark);
}
.toc-entry, .toc-appendix { margin: 0.7em 0; line-height: 1.5; }
.toc-entry a, .toc-appendix a { font-weight: 700; text-decoration: none; }
.toc-entry a:hover, .toc-appendix a:hover { text-decoration: underline; }
.toc-desc { display: block; margin-top: 0.15em; padding-left: 1.4em; font-size: 0.92em; font-style: italic; color: var(--muted); }
.site-footer {
  margin-top: 3rem; padding-top: 1.2rem; border-top: 1px solid var(--rule);
  text-align: center; font-size: 0.86em; line-height: 1.6; color: var(--muted);
}
.site-footer p { margin: 0 0 0.4em; }

/* ---------- Phones ---------- */
@media (max-width: 600px) {
  body { font-size: 18px; }
  h1 { font-size: 1.9em; }
  .book-title { font-size: 2.1em; }
  .site-header { padding: 1rem 0.75rem; }
  .site-header .site-name { font-size: 1.25rem; }
  blockquote.source, .callout { padding: 0.9rem 1rem; }
  blockquote.scripture { padding-left: 1rem; }
}

/* ---------- Print ---------- */
@media print {
  html, body { background: #ffffff; }
  .site-header, nav.chapter-nav { display: none; }
  .page { max-width: none; padding: 0; }
  .callout, figure.plate, blockquote { break-inside: avoid; }
  a { color: inherit; text-decoration: none; }
}
