/* ================================================================
   THE CHURCH OF FAITH AND ENLIGHTENMENT
   A doctrine of disciplined inquiry, moral development, and service.
   ================================================================ */

/* ============================
   1. CUSTOM PROPERTIES
   ============================ */

:root {
  /* Backgrounds */
  --bg-primary: #FAF8F3;
  --bg-secondary: #F3EDE3;
  --bg-tertiary: #EBE4D8;
  --bg-dark: #1A1A2E;
  --bg-dark-mid: #222238;
  --bg-dark-light: #2A2A42;

  /* Text */
  --text-primary: #1C1C2E;
  --text-secondary: #3E3E52;
  --text-tertiary: #6B6878;
  --text-muted: #8A8694;
  --text-on-dark: #F0ECE2;
  --text-on-dark-muted: #A8A4B0;

  /* Accents */
  --gold: #B8963A;
  --gold-light: #CEAA4E;
  --gold-faint: rgba(184, 150, 58, 0.12);
  --gold-glow: rgba(184, 150, 58, 0.06);
  --pale-amber: #C8A44A;
  --blue-white: #D8DFE8;

  /* Borders */
  --border-light: #DDD6CA;
  --border-medium: #C4B9A8;
  --border-faint: rgba(0,0,0,0.06);

  /* Shadows */
  --shadow-sm: 0 1px 3px rgba(26,26,46,0.05);
  --shadow-md: 0 4px 16px rgba(26,26,46,0.07);
  --shadow-lg: 0 8px 40px rgba(26,26,46,0.10);

  /* Typography */
  --font-display: 'Cormorant Garamond', 'Garamond', 'Palatino Linotype', 'Book Antiqua', serif;
  --font-body: 'Source Serif 4', 'Source Serif Pro', 'Georgia', 'Palatino', serif;
  --font-ui: 'Inter', -apple-system, 'Segoe UI', 'Helvetica Neue', sans-serif;

  /* Layout */
  --content-max: 72rem;
  --reading-max: 42rem;
  --section-pad: 6rem;
  --nav-height: 4rem;
}


/* ============================
   2. RESET & BASE
   ============================ */

*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overscroll-behavior: none;
}

body {
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.75;
  color: var(--text-primary);
  background: var(--bg-primary);
  overflow-x: hidden;
  scrollbar-width: thin;
  scrollbar-color: rgba(100, 100, 120, 0.4) transparent;
}

/* Webkit scrollbar (Chrome, Safari, Edge) */
body::-webkit-scrollbar {
  width: 8px;
}

body::-webkit-scrollbar-track {
  background: transparent;
}

body::-webkit-scrollbar-thumb {
  background: rgba(100, 100, 120, 0.4);
  border-radius: 4px;
}

body::-webkit-scrollbar-thumb:hover {
  background: rgba(100, 100, 120, 0.6);
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--gold);
  text-decoration: none;
  transition: color 0.25s ease;
}

a:hover {
  color: var(--gold-light);
}

::selection {
  background: var(--gold-faint);
  color: var(--text-primary);
}


/* ============================
   3. TYPOGRAPHY
   ============================ */

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-display);
  font-weight: 400;
  line-height: 1.25;
  color: var(--text-primary);
}

h1 {
  font-size: 3rem;
  font-weight: 300;
  letter-spacing: -0.01em;
}

h2 {
  font-size: 2.125rem;
  font-weight: 400;
  margin-bottom: 1.5rem;
}

h3 {
  font-size: 1.5rem;
  font-weight: 500;
  margin-bottom: 1rem;
}

h4 {
  font-size: 1.25rem;
  font-weight: 600;
  margin-bottom: 0.75rem;
}

p {
  margin-bottom: 1.25rem;
}

p:last-child {
  margin-bottom: 0;
}

blockquote {
  font-family: var(--font-display);
  font-size: 1.375rem;
  font-style: italic;
  line-height: 1.6;
  color: var(--text-secondary);
  border-left: 2px solid var(--gold);
  padding: 0.5rem 0 0.5rem 2rem;
  margin: 2.5rem 0;
}

blockquote cite,
blockquote .cite {
  display: block;
  font-family: var(--font-ui);
  font-size: 0.8125rem;
  font-style: normal;
  color: var(--text-muted);
  letter-spacing: 0.04em;
  margin-top: 1rem;
}

.label {
  font-family: var(--font-ui);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gold);
}

.subtitle {
  font-family: var(--font-ui);
  font-size: 0.9375rem;
  color: var(--text-tertiary);
  line-height: 1.7;
}

.large-text {
  font-size: 1.1875rem;
  line-height: 1.85;
}

.small-text {
  font-size: 0.9375rem;
  color: var(--text-tertiary);
}


/* ============================
   4. LAYOUT
   ============================ */

.container {
  max-width: var(--content-max);
  margin: 0 auto;
  padding: 0 2rem;
}

.container--narrow {
  max-width: var(--reading-max);
}

.section {
  padding: var(--section-pad) 0;
}

.section--alt {
  background: var(--bg-secondary);
}

.section--dark {
  background: var(--bg-dark);
  color: var(--text-on-dark);
}

.section--dark h2,
.section--dark h3,
.section--dark h4 {
  color: var(--text-on-dark);
}

.section--dark .subtitle,
.section--dark .small-text {
  color: var(--text-on-dark-muted);
}

.text-center {
  text-align: center;
}

.grid-2 {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 2.5rem;
}

.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
}

.grid-4 {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 2rem;
}


/* ============================
   5. DIVIDERS
   ============================ */

.divider {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1.5rem;
  margin: 3.5rem auto;
  max-width: 16rem;
  color: var(--gold);
  font-size: 0.5rem;
  line-height: 1;
  user-select: none;
}

.divider::before,
.divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--gold), transparent);
  opacity: 0.45;
}

.divider--wide {
  max-width: 28rem;
}

.divider--light::before,
.divider--light::after {
  background: linear-gradient(90deg, transparent, var(--border-light), transparent);
  opacity: 0.7;
}

.divider--on-dark::before,
.divider--on-dark::after {
  background: linear-gradient(90deg, transparent, rgba(184,150,58,0.4), transparent);
  opacity: 1;
}


/* ============================
   6. NAVIGATION
   ============================ */

.main-nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  height: var(--nav-height);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 2rem;
  background: rgba(250, 248, 243, 0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-faint);
  transition: background 0.3s ease, box-shadow 0.3s ease;
}

.main-nav.scrolled {
  box-shadow: var(--shadow-sm);
}

.main-nav.nav--dark {
  background: rgba(26, 26, 46, 0.92);
  border-bottom-color: rgba(255,255,255,0.06);
}

.nav-brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  text-decoration: none;
}

.nav-brand img {
  width: 28px;
  height: 28px;
  object-fit: contain;
}

.nav-brand span {
  font-family: var(--font-display);
  font-size: 1.0625rem;
  font-weight: 500;
  color: var(--text-primary);
  letter-spacing: 0.01em;
}

.nav--dark .nav-brand span {
  color: var(--text-on-dark);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 2.25rem;
  list-style: none;
}

.nav-links a {
  font-family: var(--font-ui);
  font-size: 0.8125rem;
  font-weight: 500;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--text-tertiary);
  text-decoration: none;
  transition: color 0.25s ease;
  position: relative;
}

.nav-links a::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 1px;
  background: var(--gold);
  transition: width 0.3s ease;
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--text-primary);
}

.nav-links a:hover::after,
.nav-links a.active::after {
  width: 100%;
}

.nav--dark .nav-links a {
  color: var(--text-on-dark-muted);
}

.nav--dark .nav-links a:hover,
.nav--dark .nav-links a.active {
  color: var(--text-on-dark);
}

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
}

.nav-toggle span {
  display: block;
  width: 22px;
  height: 1.5px;
  background: var(--text-secondary);
  transition: all 0.3s ease;
}

.nav--dark .nav-toggle span {
  background: var(--text-on-dark-muted);
}


/* ============================
   7. HERO SECTIONS
   ============================ */

/* Homepage hero */
.hero {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 6rem 2rem 4rem;
  background:
    radial-gradient(ellipse at 50% 40%, rgba(184,150,58,0.06) 0%, transparent 55%),
    radial-gradient(ellipse at 50% 50%, rgba(216,223,232,0.03) 0%, transparent 35%),
    var(--bg-dark);
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: url("data:image/svg+xml,%3Csvg width='60' height='60' xmlns='http://www.w3.org/2000/svg'%3E%3Ccircle cx='30' cy='30' r='0.4' fill='rgba(184,150,58,0.15)'/%3E%3C/svg%3E");
  opacity: 0.5;
  pointer-events: none;
}

.hero-logo {
  width: 120px;
  height: 120px;
  object-fit: contain;
  margin-bottom: 3rem;
  opacity: 0;
  animation: heroFadeIn 1.2s ease 0.2s forwards;
}

.hero-motto {
  font-family: var(--font-display);
  font-size: 3.5rem;
  font-weight: 300;
  line-height: 1.2;
  color: var(--text-on-dark);
  max-width: 40rem;
  margin-bottom: 1.75rem;
  opacity: 0;
  animation: heroFadeIn 1.2s ease 0.5s forwards;
}

.hero-motto em {
  font-style: italic;
  color: var(--gold-light);
}

.hero-latin {
  font-family: var(--font-ui);
  font-size: 0.75rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--gold);
  opacity: 0;
  animation: heroFadeIn 1s ease 0.9s forwards;
  margin-bottom: 2.5rem;
}

.hero-tagline {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 300;
  color: var(--text-on-dark-muted);
  max-width: 36rem;
  line-height: 1.7;
  opacity: 0;
  animation: heroFadeIn 1s ease 1.1s forwards;
}

.hero-scroll {
  position: absolute;
  bottom: 2.5rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  color: var(--text-on-dark-muted);
  font-family: var(--font-ui);
  font-size: 0.625rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  opacity: 0;
  animation: heroFadeIn 1s ease 1.5s forwards;
}

.hero-scroll .scroll-line {
  width: 1px;
  height: 40px;
  background: linear-gradient(to bottom, var(--gold), transparent);
  animation: scrollPulse 2s ease-in-out infinite;
}

/* Page hero (interior pages) */
.page-hero {
  padding: 8rem 2rem 4rem;
  text-align: center;
  background:
    radial-gradient(ellipse at 50% 60%, rgba(184,150,58,0.05) 0%, transparent 50%),
    var(--bg-dark);
  position: relative;
}

.page-hero .label {
  margin-bottom: 1.25rem;
  display: block;
}

.page-hero h1 {
  color: var(--text-on-dark);
  margin-bottom: 1.25rem;
}

.page-hero .subtitle {
  color: var(--text-on-dark-muted);
  max-width: 36rem;
  margin: 0 auto;
}

/* Book hero */
.book-hero {
  padding: 9rem 2rem 4.5rem;
  text-align: center;
  background:
    radial-gradient(ellipse at 50% 55%, rgba(184,150,58,0.06) 0%, transparent 50%),
    var(--bg-dark);
}

.book-hero .book-number {
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 400;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 1.5rem;
  display: block;
}

.book-hero h1 {
  color: var(--text-on-dark);
  font-size: 2.75rem;
  max-width: 32rem;
  margin: 0 auto 1.5rem;
}

.book-hero .subtitle {
  color: var(--text-on-dark-muted);
  max-width: 34rem;
  margin: 0 auto;
  font-family: var(--font-display);
  font-size: 1.125rem;
  font-style: italic;
  line-height: 1.7;
}


/* ============================
   8. CONTENT SECTIONS
   ============================ */

.section-header {
  text-align: center;
  max-width: 36rem;
  margin: 0 auto 3.5rem;
}

.section-header .label {
  margin-bottom: 1rem;
  display: block;
}

.section-header h2 {
  margin-bottom: 1rem;
}

.section-header .subtitle {
  font-size: 1rem;
}

/* Doctrine statement */
.doctrine-statement {
  font-family: var(--font-display);
  font-size: 1.5rem;
  line-height: 1.65;
  color: var(--text-secondary);
  text-align: center;
  max-width: 40rem;
  margin: 0 auto;
  font-weight: 300;
}

.doctrine-statement strong {
  color: var(--text-primary);
  font-weight: 500;
}

/* Content prose */
.prose {
  max-width: var(--reading-max);
  margin: 0 auto;
}

.prose h2 {
  margin-top: 3.5rem;
  margin-bottom: 1.25rem;
}

.prose h3 {
  margin-top: 2.5rem;
  margin-bottom: 1rem;
}

.prose h4 {
  margin-top: 2rem;
}

.prose ul,
.prose ol {
  margin: 1.25rem 0;
  padding-left: 1.75rem;
}

.prose li {
  margin-bottom: 0.5rem;
}

.prose li::marker {
  color: var(--gold);
}

.prose strong {
  font-weight: 600;
  color: var(--text-primary);
}

.prose em {
  font-style: italic;
}

.prose hr {
  border: none;
  height: 1px;
  background: var(--border-light);
  margin: 3rem 0;
}

/* Principle blocks */
.principle {
  padding: 2.5rem 0;
  border-bottom: 1px solid var(--border-light);
}

.principle:last-child {
  border-bottom: none;
}

.principle-number {
  font-family: var(--font-display);
  font-size: 0.875rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  color: var(--gold);
  margin-bottom: 0.75rem;
  display: block;
}

.principle h3 {
  font-size: 1.375rem;
  margin-bottom: 0.75rem;
}

.principle .formulation {
  font-family: var(--font-display);
  font-size: 1.1875rem;
  font-style: italic;
  color: var(--text-secondary);
  margin-bottom: 1rem;
  line-height: 1.6;
}

.principle p {
  font-size: 1rem;
  color: var(--text-secondary);
  line-height: 1.75;
}

/* Definition list */
.definition-item {
  padding: 1.75rem 0;
  border-bottom: 1px solid var(--border-light);
}

.definition-item:last-child {
  border-bottom: none;
}

.definition-item dt {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 500;
  color: var(--text-primary);
  margin-bottom: 0.5rem;
}

.definition-item dd {
  color: var(--text-secondary);
  line-height: 1.75;
}

/* Creed / Manifesto formatting */
.creed-text {
  font-family: var(--font-display);
  font-size: 1.3125rem;
  line-height: 1.75;
  color: var(--text-secondary);
  max-width: 36rem;
  margin: 0 auto;
  text-align: center;
}

.creed-text p {
  margin-bottom: 1.5rem;
}

.creed-text strong {
  color: var(--text-primary);
  font-weight: 500;
}

.manifesto-text {
  font-family: var(--font-display);
  font-size: 1.1875rem;
  line-height: 1.75;
  color: var(--text-secondary);
  max-width: var(--reading-max);
  margin: 0 auto;
}

.manifesto-text p {
  margin-bottom: 1.5rem;
}

.manifesto-text strong {
  font-weight: 500;
  color: var(--text-primary);
}


/* ============================
   9. BOOK CARDS (CANON PAGE)
   ============================ */

.book-card {
  background: var(--bg-primary);
  border: 1px solid var(--border-light);
  padding: 2.25rem 2rem;
  border-left: 3px solid var(--gold);
  transition: box-shadow 0.3s ease, transform 0.3s ease;
  display: flex;
  flex-direction: column;
}

.book-card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.book-card .book-card-number {
  font-family: var(--font-ui);
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 0.75rem;
}

.book-card h3 {
  font-size: 1.3125rem;
  margin-bottom: 1rem;
  line-height: 1.3;
}

.book-card h3 a {
  color: var(--text-primary);
  text-decoration: none;
  transition: color 0.25s ease;
}

.book-card h3 a:hover {
  color: var(--gold);
}

.book-card p {
  font-size: 0.9375rem;
  color: var(--text-tertiary);
  line-height: 1.7;
  flex: 1;
}

.book-card .book-card-link {
  margin-top: 1.5rem;
  font-family: var(--font-ui);
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--gold);
  letter-spacing: 0.03em;
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  transition: gap 0.25s ease;
}

.book-card .book-card-link:hover {
  gap: 0.625rem;
}

.book-card .book-card-link::after {
  content: '\2192';
}

.canon-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 2rem;
}


/* ============================
   10. BOOK READING LAYOUT
   ============================ */

.book-layout {
  display: grid;
  grid-template-columns: 16rem 1fr;
  gap: 4rem;
  max-width: 68rem;
  margin: 0 auto;
  padding: 3.5rem 2rem var(--section-pad);
  align-items: start;
}

/* Table of Contents sidebar */
.book-toc {
  position: sticky;
  top: calc(var(--nav-height) + 2rem);
  max-height: calc(100vh - var(--nav-height) - 4rem);
  overflow-y: auto;
  padding-right: 1rem;
  scrollbar-width: thin;
  scrollbar-color: var(--border-light) transparent;
}

.book-toc::-webkit-scrollbar {
  width: 3px;
}

.book-toc::-webkit-scrollbar-thumb {
  background: var(--border-light);
  border-radius: 3px;
}

.book-toc-title {
  font-family: var(--font-ui);
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 1.25rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid var(--border-light);
}

.book-toc ul {
  list-style: none;
}

.book-toc li {
  margin-bottom: 0.25rem;
}

.book-toc a {
  font-family: var(--font-ui);
  font-size: 0.8125rem;
  color: var(--text-muted);
  text-decoration: none;
  display: block;
  padding: 0.3rem 0 0.3rem 0;
  border-left: 2px solid transparent;
  padding-left: 0.75rem;
  line-height: 1.4;
  transition: color 0.2s ease, border-color 0.2s ease;
}

.book-toc a:hover {
  color: var(--text-secondary);
}

.book-toc a.active {
  color: var(--gold);
  border-left-color: var(--gold);
  font-weight: 500;
}

.book-toc .toc-sub {
  padding-left: 0.75rem;
}

.book-toc .toc-sub a {
  font-size: 0.75rem;
}

/* Book content area */
.book-content {
  max-width: var(--reading-max);
  font-size: 1.0625rem;
  line-height: 1.85;
}

.book-content h2 {
  font-size: 1.875rem;
  margin-top: 4rem;
  margin-bottom: 1.5rem;
  padding-top: 2rem;
  border-top: 1px solid var(--border-light);
}

.book-content h2:first-child {
  margin-top: 0;
  padding-top: 0;
  border-top: none;
}

.book-content h3 {
  font-size: 1.3125rem;
  margin-top: 2.5rem;
  margin-bottom: 1rem;
  color: var(--text-secondary);
}

.book-content h4 {
  font-size: 1.0625rem;
  margin-top: 2rem;
  margin-bottom: 0.75rem;
  font-weight: 600;
  color: var(--text-secondary);
}

.book-content p {
  margin-bottom: 1.25rem;
}

.book-content ul,
.book-content ol {
  margin: 1.25rem 0;
  padding-left: 1.75rem;
}

.book-content li {
  margin-bottom: 0.5rem;
}

.book-content li::marker {
  color: var(--gold);
}

.book-content blockquote {
  font-size: 1.1875rem;
}

.book-content .chapter-num {
  font-family: var(--font-ui);
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gold);
  display: block;
  margin-bottom: 0.5rem;
}

/* Book navigation at bottom */
.book-nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 3rem 0;
  margin-top: 4rem;
  border-top: 1px solid var(--border-light);
  gap: 2rem;
}

.book-nav a {
  font-family: var(--font-ui);
  font-size: 0.8125rem;
  font-weight: 500;
  letter-spacing: 0.03em;
  color: var(--text-tertiary);
  text-decoration: none;
  transition: color 0.25s ease;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.book-nav a:hover {
  color: var(--gold);
}

.book-nav a span {
  font-family: var(--font-display);
  font-size: 1.125rem;
  font-weight: 400;
  color: var(--text-primary);
}

.book-nav a:hover span {
  color: var(--gold);
}

.book-nav .prev::before {
  content: '\2190 ';
}

.book-nav .next {
  text-align: right;
}

.book-nav .next::after {
  content: ' \2192';
}

/* Mobile ToC toggle */
.toc-toggle {
  display: none;
  width: 100%;
  padding: 1rem 1.5rem;
  background: var(--bg-secondary);
  border: 1px solid var(--border-light);
  font-family: var(--font-ui);
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-secondary);
  cursor: pointer;
  text-align: left;
  margin-bottom: 2rem;
}

.toc-toggle::after {
  content: ' +';
  float: right;
}

.toc-toggle.open::after {
  content: ' \2212';
}

/* Reading progress bar */
.reading-progress {
  position: fixed;
  top: 0;
  left: 0;
  width: 0%;
  height: 2px;
  background: var(--gold);
  z-index: 200;
  transition: width 0.1s linear;
  pointer-events: none;
}


/* ============================
   11. FEATURE CARDS
   ============================ */

.feature-card {
  padding: 2rem;
  border: 1px solid var(--border-light);
  background: var(--bg-primary);
  transition: box-shadow 0.3s ease;
}

.feature-card:hover {
  box-shadow: var(--shadow-sm);
}

.feature-card .label {
  margin-bottom: 0.75rem;
  display: block;
}

.feature-card h3 {
  font-size: 1.25rem;
  margin-bottom: 0.75rem;
}

.feature-card p {
  font-size: 0.9375rem;
  color: var(--text-tertiary);
  line-height: 1.7;
}


/* ============================
   12. BUTTONS & LINKS
   ============================ */

.btn {
  font-family: var(--font-ui);
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 0.875rem 2rem;
  border: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  transition: all 0.25s ease;
  text-decoration: none;
}

.btn--gold {
  background: var(--gold);
  color: #fff;
}

.btn--gold:hover {
  background: var(--gold-light);
  color: #fff;
}

.btn--outline {
  background: transparent;
  border: 1px solid var(--gold);
  color: var(--gold);
}

.btn--outline:hover {
  background: var(--gold);
  color: #fff;
}

.btn--outline-light {
  background: transparent;
  border: 1px solid rgba(240,236,226,0.3);
  color: var(--text-on-dark);
}

.btn--outline-light:hover {
  background: rgba(240,236,226,0.08);
  border-color: rgba(240,236,226,0.5);
  color: var(--text-on-dark);
}

.link-arrow {
  font-family: var(--font-ui);
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--gold);
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  transition: gap 0.25s ease;
}

.link-arrow::after {
  content: '\2192';
}

.link-arrow:hover {
  color: var(--gold-light);
  gap: 0.625rem;
}


/* ============================
   13. FOOTER
   ============================ */

.site-footer {
  background: var(--bg-dark);
  color: var(--text-on-dark-muted);
  padding: 4rem 0 2.5rem;
}

.footer-inner {
  max-width: var(--content-max);
  margin: 0 auto;
  padding: 0 2rem;
}

.footer-top {
  display: grid;
  grid-template-columns: 1.5fr repeat(3, 1fr);
  gap: 3rem;
  padding-bottom: 3rem;
  border-bottom: 1px solid rgba(255,255,255,0.06);
}

.footer-brand {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.footer-brand img {
  width: 40px;
  height: 40px;
  object-fit: contain;
  opacity: 0.8;
}

.footer-brand .footer-motto {
  font-family: var(--font-display);
  font-size: 1.0625rem;
  font-style: italic;
  color: var(--text-on-dark-muted);
  line-height: 1.5;
}

.footer-brand .footer-latin {
  font-family: var(--font-ui);
  font-size: 0.6875rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--gold);
  opacity: 0.7;
}

.footer-col h4 {
  font-family: var(--font-ui);
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-on-dark-muted);
  margin-bottom: 1.25rem;
}

.footer-col ul {
  list-style: none;
}

.footer-col li {
  margin-bottom: 0.625rem;
}

.footer-col a {
  font-family: var(--font-ui);
  font-size: 0.875rem;
  color: var(--text-on-dark-muted);
  text-decoration: none;
  transition: color 0.25s ease;
}

.footer-col a:hover {
  color: var(--text-on-dark);
}

.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 2rem;
  font-family: var(--font-ui);
  font-size: 0.75rem;
  color: rgba(168,164,176,0.5);
}


/* ============================
   14. ANIMATIONS
   ============================ */

@keyframes heroFadeIn {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes scrollPulse {
  0%, 100% { opacity: 0.3; }
  50% { opacity: 0.8; }
}

/* Scroll-triggered fade in */
.fade-in {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

.fade-in-delay-1 { transition-delay: 0.1s; }
.fade-in-delay-2 { transition-delay: 0.2s; }
.fade-in-delay-3 { transition-delay: 0.3s; }


/* ============================
   15. RESPONSIVE
   ============================ */

@media (max-width: 1024px) {
  :root {
    --section-pad: 4.5rem;
  }

  .hero-motto {
    font-size: 2.75rem;
  }

  .canon-grid {
    grid-template-columns: 1fr;
  }

  .grid-3 {
    grid-template-columns: repeat(2, 1fr);
  }

  .grid-4 {
    grid-template-columns: repeat(2, 1fr);
  }

  .book-layout {
    grid-template-columns: 1fr;
    gap: 0;
  }

  .book-toc {
    position: static;
    max-height: none;
    display: none;
    margin-bottom: 2rem;
    padding: 1.5rem;
    background: var(--bg-secondary);
    border: 1px solid var(--border-light);
  }

  .book-toc.open {
    display: block;
  }

  .toc-toggle {
    display: block;
  }

  .footer-top {
    grid-template-columns: 1fr 1fr;
    gap: 2.5rem;
  }
}

@media (max-width: 768px) {
  :root {
    --section-pad: 3.5rem;
  }

  body {
    font-size: 1rem;
  }

  h1 {
    font-size: 2.25rem;
  }

  h2 {
    font-size: 1.75rem;
  }

  .hero-motto {
    font-size: 2.25rem;
  }

  .hero-logo {
    width: 88px;
    height: 88px;
  }

  .page-hero {
    padding: 7rem 1.5rem 3rem;
  }

  .book-hero {
    padding: 7.5rem 1.5rem 3.5rem;
  }

  .book-hero h1 {
    font-size: 2.125rem;
  }

  .container {
    padding: 0 1.5rem;
  }

  .grid-2 {
    grid-template-columns: 1fr;
  }

  .grid-3 {
    grid-template-columns: 1fr;
  }

  .grid-4 {
    grid-template-columns: 1fr;
  }

  .nav-links {
    display: none;
    position: fixed;
    top: var(--nav-height);
    left: 0;
    right: 0;
    background: var(--bg-primary);
    flex-direction: column;
    padding: 1.5rem 2rem;
    gap: 0;
    border-bottom: 1px solid var(--border-light);
    box-shadow: var(--shadow-md);
  }

  .nav-links.open {
    display: flex;
  }

  .nav--dark .nav-links {
    background: var(--bg-dark);
    border-bottom-color: rgba(255,255,255,0.06);
  }

  .nav-links li {
    width: 100%;
  }

  .nav-links a {
    display: block;
    padding: 0.75rem 0;
    border-bottom: 1px solid var(--border-faint);
  }

  .nav-links a::after {
    display: none;
  }

  .nav-toggle {
    display: flex;
  }

  .doctrine-statement {
    font-size: 1.25rem;
  }

  .creed-text {
    font-size: 1.125rem;
  }

  .book-content h2 {
    font-size: 1.625rem;
  }

  .book-nav {
    flex-direction: column;
    align-items: stretch;
  }

  .book-nav .next {
    text-align: left;
  }

  .footer-top {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .footer-bottom {
    flex-direction: column;
    gap: 0.75rem;
    text-align: center;
  }

  blockquote {
    font-size: 1.1875rem;
    padding-left: 1.5rem;
  }
}

@media (max-width: 480px) {
  .hero {
    padding: 5rem 1.25rem 3rem;
  }

  .hero-motto {
    font-size: 1.875rem;
  }

  .hero-tagline {
    font-size: 1.0625rem;
  }

  .page-hero {
    padding: 6.5rem 1.25rem 2.5rem;
  }

  h1 {
    font-size: 1.875rem;
  }

  h2 {
    font-size: 1.5rem;
  }

  .container {
    padding: 0 1.25rem;
  }
}


/* ============================
   16. PRINT STYLES
   ============================ */

@media print {
  .main-nav,
  .hero-scroll,
  .reading-progress,
  .book-toc,
  .toc-toggle,
  .site-footer {
    display: none !important;
  }

  .book-layout {
    display: block;
  }

  .book-content {
    max-width: 100%;
  }

  body {
    font-size: 11pt;
    color: #000;
  }

  a {
    color: #000;
  }
}
