/* ==========================================================================
   A BÍBLIA SAGRADA ILUSTRADA - LUXURY FOLIO & PDF READER STYLESHEET
   ========================================================================== */

:root {
  --font-serif: 'EB Garamond', Georgia, serif;
  --font-display: 'Cinzel', serif;
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  
  /* Parchment Theme (Default) */
  --bg-viewport: #1a1612;
  --bg-book: #fcf9f2;
  --bg-page: #fbf7ee;
  --text-main: #2b251d;
  --text-muted: #6e6456;
  --text-verse-num: #9c6c28;
  --border-gold: #d4af37;
  --border-subtle: #e6dfd1;
  --header-bg: #231e18;
  --header-text: #f5eedc;
  --header-border: #3b3226;
  --card-bg: #ffffff;
  --card-shadow: 0 15px 40px rgba(0, 0, 0, 0.25);
  --accent-gold: #c59b27;
  --accent-gold-light: #f7eed3;
  --accent-gold-hover: #b0881c;
  --badge-favorite: #c2410c;
  
  --font-size-base: 19px;
  --line-height-base: 1.78;
}

/* Dark Theme */
body.theme-dark {
  --bg-viewport: #0a0c0f;
  --bg-book: #161b22;
  --bg-page: #1b2028;
  --text-main: #e6edf3;
  --text-muted: #8b949e;
  --text-verse-num: #e3b341;
  --border-gold: #bb86fc;
  --border-subtle: #30363d;
  --header-bg: #0d1117;
  --header-text: #f0f6fc;
  --header-border: #21262d;
  --card-bg: #21262d;
  --card-shadow: 0 15px 40px rgba(0, 0, 0, 0.6);
  --accent-gold: #e3b341;
  --accent-gold-light: #2b2517;
  --accent-gold-hover: #f3c252;
}

/* Crisp Light Editorial Theme */
body.theme-light {
  --bg-viewport: #e5e7eb;
  --bg-book: #ffffff;
  --bg-page: #ffffff;
  --text-main: #1f2937;
  --text-muted: #4b5563;
  --text-verse-num: #1d4ed8;
  --border-gold: #c59b27;
  --border-subtle: #e5e7eb;
  --header-bg: #111827;
  --header-text: #f9fafb;
  --header-border: #1f2937;
  --card-bg: #ffffff;
  --card-shadow: 0 15px 35px rgba(0, 0, 0, 0.12);
  --accent-gold: #2563eb;
  --accent-gold-light: #eff6ff;
  --accent-gold-hover: #1d4ed8;
}

/* Classic Sepia Theme */
body.theme-sepia {
  --bg-viewport: #31281e;
  --bg-book: #f4ecd8;
  --bg-page: #f2e8d0;
  --text-main: #3d3124;
  --text-muted: #726250;
  --text-verse-num: #b05c19;
  --border-gold: #c68a3c;
  --border-subtle: #ded1b8;
  --header-bg: #211912;
  --header-text: #eddcc6;
  --header-border: #382b1f;
  --card-bg: #faf4e6;
  --card-shadow: 0 15px 40px rgba(0, 0, 0, 0.35);
  --accent-gold: #b05c19;
  --accent-gold-light: #faecd6;
  --accent-gold-hover: #8f4810;
}

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

button, .btn, .btn-tool, .nav-arrow, .page-pill, .search-chip, .btn-audio-ctrl, .btn-audio-play, .mobile-spread-tab, .toc-item, .verse-paragraph, .style-select, .book-select, .chapter-select {
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
}

body {
  font-family: var(--font-serif);
  background-color: var(--bg-viewport);
  color: var(--text-main);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  overflow-x: hidden;
  transition: background-color 0.3s ease, color 0.3s ease;
}

/* ==========================================================================
   TOP HEADER
   ========================================================================== */
.reader-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: var(--header-bg);
  color: var(--header-text);
  border-bottom: 2px solid var(--header-border);
  padding: 0.75rem 1.5rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
  box-shadow: 0 4px 15px rgba(0,0,0,0.3);
}

.header-left {
  display: flex;
  align-items: center;
  gap: 0.85rem;
}

.book-crest {
  font-size: 1.8rem;
  color: var(--border-gold);
  line-height: 1;
  text-shadow: 0 0 8px rgba(212, 175, 55, 0.4);
}

.header-title {
  font-family: var(--font-display);
  font-size: 1.15rem;
  letter-spacing: 2px;
  font-weight: 700;
  color: #ffffff;
}

.header-subtitle {
  font-family: var(--font-sans);
  font-size: 0.75rem;
  color: #bbb;
  letter-spacing: 0.5px;
}

.header-controls {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  flex-wrap: wrap;
}

.control-group {
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.control-label {
  font-family: var(--font-sans);
  font-size: 0.75rem;
  color: #ccc;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.style-select {
  font-family: var(--font-sans);
  font-size: 0.85rem;
  padding: 0.45rem 0.85rem;
  background: #2d261e;
  color: #fff;
  border: 1px solid var(--border-gold);
  border-radius: 6px;
  outline: none;
  cursor: pointer;
  max-width: 280px;
  transition: all 0.2s ease;
}

body.theme-dark .style-select {
  background: #1c2128;
  border-color: #444c56;
}

.style-select:hover {
  border-color: #ffd700;
}

.btn {
  font-family: var(--font-sans);
  font-size: 0.82rem;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.45rem 0.85rem;
  border-radius: 6px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-secondary {
  background: #332a20;
  color: #f7eed3;
  border-color: #554432;
}

body.theme-dark .btn-secondary {
  background: #21262d;
  color: #c9d1d9;
  border-color: #30363d;
}

.btn-secondary:hover {
  background: #46392c;
  color: #fff;
  border-color: var(--border-gold);
}

.btn-primary {
  background: var(--accent-gold);
  color: #111;
  font-weight: 700;
}

.btn-primary:hover {
  background: var(--accent-gold-hover);
  color: #000;
}

.btn-icon {
  background: #332a20;
  color: #f7eed3;
  border: 1px solid #554432;
  border-radius: 6px;
  padding: 0.45rem 0.65rem;
  cursor: pointer;
  font-weight: 600;
  font-size: 0.85rem;
  transition: all 0.2s ease;
}

body.theme-dark .btn-icon {
  background: #21262d;
  color: #c9d1d9;
  border-color: #30363d;
}

.btn-icon:hover {
  border-color: var(--border-gold);
  color: #fff;
}

/* Primary Features: Audio Play & Random Page */
.btn-audio-read {
  background: linear-gradient(135deg, #d4af37 0%, #ffd700 100%) !important;
  color: #111 !important;
  border: 1px solid #ffd700 !important;
  font-weight: 700 !important;
  white-space: nowrap;
  box-shadow: 0 0 10px rgba(212, 175, 55, 0.4);
}

.btn-audio-read:hover {
  background: linear-gradient(135deg, #ffd700 0%, #fff099 100%) !important;
  transform: translateY(-1px);
  box-shadow: 0 0 14px rgba(255, 215, 0, 0.6);
}

.btn-audio-read.active {
  background: linear-gradient(135deg, #e65100 0%, #ff9800 100%) !important;
  border-color: #ffa726 !important;
  color: #fff !important;
  box-shadow: 0 0 14px rgba(255, 152, 0, 0.6);
}

.btn-random-page {
  background: #332a20;
  color: #ffd700 !important;
  border: 1px solid #775c2e !important;
  font-weight: 600;
  white-space: nowrap;
}

.btn-random-page:hover {
  background: #46392c;
  border-color: #ffd700 !important;
  color: #fff !important;
  transform: translateY(-1px);
}

/* Chapter Action Bar (Directly beneath chapter title on the page) */
.chapter-action-bar {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  margin: 0.75rem 0 1.25rem;
  flex-wrap: wrap;
}

.btn-chapter-action {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.45rem 1rem;
  font-family: var(--font-sans);
  font-size: 0.84rem;
  font-weight: 600;
  border-radius: 20px;
  cursor: pointer;
  transition: all 0.2s ease;
  border: 1px solid transparent;
}

.btn-chapter-audio {
  background: linear-gradient(135deg, #2b2217 0%, #3d2f1f 100%);
  color: #ffd700;
  border-color: #8b6d34;
  box-shadow: 0 2px 8px rgba(0,0,0,0.25);
}

.btn-chapter-audio:hover,
.btn-chapter-audio.active {
  background: linear-gradient(135deg, #d4af37 0%, #ffd700 100%);
  color: #111;
  border-color: #ffd700;
  box-shadow: 0 0 12px rgba(212, 175, 55, 0.5);
  transform: translateY(-1px);
}

.btn-chapter-random {
  background: #231c15;
  color: #e5d8be;
  border-color: #4a3824;
}

.btn-chapter-random:hover {
  background: #36291c;
  border-color: var(--border-gold);
  color: #fff;
  transform: translateY(-1px);
}

/* Bottom Toolbar Buttons */
.btn-tool-play {
  background: linear-gradient(135deg, #d4af37 0%, #ffd700 100%) !important;
  color: #111 !important;
  font-weight: 700 !important;
  border-color: #ffd700 !important;
  border-radius: 6px;
  padding: 0.4rem 0.75rem;
  box-shadow: 0 0 8px rgba(212, 175, 55, 0.4);
}

.btn-tool-play:hover,
.btn-tool-play.active {
  background: linear-gradient(135deg, #ffd700 0%, #fff099 100%) !important;
  box-shadow: 0 0 12px rgba(255, 215, 0, 0.7);
}

.btn-tool-random {
  background: #332a20 !important;
  color: #ffd700 !important;
  border: 1px solid #775c2e !important;
  border-radius: 6px;
  padding: 0.4rem 0.75rem;
  font-weight: 600;
}

.btn-tool-random:hover {
  background: #46392c !important;
  border-color: #ffd700 !important;
  color: #fff !important;
}

/* ==========================================================================
   CHOICE ALERT BANNER
   ========================================================================== */
.choice-alert {
  background: linear-gradient(90deg, #382414 0%, #291a10 100%);
  border-bottom: 1px solid #634320;
  color: #faecd6;
  padding: 0.6rem 1.5rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  font-family: var(--font-sans);
  font-size: 0.85rem;
}

.alert-content {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.alert-badge {
  background: #d97706;
  color: #ffffff;
  font-size: 0.68rem;
  font-weight: 800;
  padding: 0.2rem 0.5rem;
  border-radius: 4px;
  letter-spacing: 0.5px;
}

.alert-actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.alert-btn {
  background: #f59e0b;
  color: #1a1612;
  border: none;
  font-weight: 700;
  font-size: 0.78rem;
  padding: 0.35rem 0.75rem;
  border-radius: 4px;
  cursor: pointer;
  transition: all 0.2s;
}

.alert-btn:hover {
  background: #fbbf24;
}

.alert-close {
  background: transparent;
  border: none;
  color: #bbb;
  font-size: 1rem;
  cursor: pointer;
  padding: 0.2rem;
}

/* ==========================================================================
   MAIN VIEWPORT & BOOK/PDF CONTAINER
   ========================================================================== */
.reader-viewport {
  flex: 1;
  display: flex;
  justify-content: center;
  align-items: flex-start;
  padding: 2rem 1rem 4rem;
  position: relative;
}

.nav-arrow {
  position: fixed;
  top: 50%;
  transform: translateY(-50%);
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: var(--card-bg);
  border: 1px solid var(--border-subtle);
  color: var(--text-main);
  box-shadow: 0 4px 15px rgba(0,0,0,0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 40;
  transition: all 0.25s ease;
}

.nav-arrow-left {
  left: 20px;
}

.nav-arrow-right {
  right: 20px;
}

.nav-arrow:hover:not(:disabled) {
  background: var(--accent-gold);
  color: #000;
  transform: translateY(-50%) scale(1.1);
  box-shadow: 0 6px 20px rgba(0,0,0,0.4);
}

.nav-arrow:disabled {
  opacity: 0.25;
  cursor: not-allowed;
}

/* Book Container (Folio) */
.book-container {
  max-width: 920px;
  width: 100%;
  background: var(--bg-page);
  border-radius: 8px;
  box-shadow: var(--card-shadow);
  border: 1px solid var(--border-subtle);
  position: relative;
  overflow: hidden;
  transition: all 0.3s ease;
}

.book-spine {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  width: 12px;
  background: linear-gradient(to right, rgba(0,0,0,0.22), rgba(0,0,0,0.05), transparent);
  pointer-events: none;
}

.book-page {
  padding: 2.5rem 3.5rem 3rem;
  display: flex;
  flex-direction: column;
  gap: 1.75rem;
}

/* Page Top Header */
.page-top-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid var(--border-subtle);
  font-family: var(--font-display);
  font-size: 0.85rem;
  letter-spacing: 2px;
  color: var(--text-muted);
}

.page-running-book {
  font-weight: 700;
  color: var(--text-main);
}

.page-running-ornament {
  color: var(--border-gold);
  font-size: 0.75rem;
}

.page-number-top {
  font-weight: 600;
}

/* Illustration Card */
.page-illustration-card {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.illustration-frame {
  position: relative;
  width: 100%;
  border-radius: 6px;
  overflow: hidden;
  box-shadow: 0 8px 25px rgba(0,0,0,0.18);
  border: 1px solid var(--border-subtle);
  background: #000;
  aspect-ratio: 16 / 9;
}

.page-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: opacity 0.35s ease, transform 0.4s ease;
}

.illustration-frame:hover .page-image {
  transform: scale(1.02);
}

.image-overlay-badge {
  position: absolute;
  bottom: 10px;
  right: 12px;
  background: rgba(15, 12, 9, 0.82);
  backdrop-filter: blur(6px);
  color: #f7eed3;
  padding: 0.3rem 0.65rem;
  border-radius: 4px;
  font-family: var(--font-sans);
  font-size: 0.72rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  border: 1px solid rgba(212, 175, 55, 0.35);
}

.btn-zoom {
  background: transparent;
  border: none;
  color: #fff;
  cursor: pointer;
  font-size: 0.85rem;
}

.illustration-caption {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-family: var(--font-sans);
  font-size: 0.78rem;
  color: var(--text-muted);
  padding: 0 0.25rem;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.caption-title {
  font-style: italic;
  color: var(--text-main);
  font-weight: 500;
}

.caption-tag {
  background: var(--accent-gold-light);
  color: var(--accent-gold-hover);
  padding: 0.15rem 0.45rem;
  border-radius: 4px;
  font-weight: 600;
  font-size: 0.72rem;
}

/* Verse Content */
.page-text-content {
  font-size: var(--font-size-base);
  line-height: var(--line-height-base);
  text-align: justify;
  hyphens: auto;
  color: var(--text-main);
}

.chapter-title-wrapper {
  text-align: center;
  margin-bottom: 1.5rem;
  padding-bottom: 0.5rem;
}

.chapter-title {
  font-family: var(--font-display);
  font-size: 1.45rem;
  letter-spacing: 3px;
  font-weight: 700;
  color: var(--text-main);
  margin-bottom: 0.25rem;
}

.chapter-sub {
  font-family: var(--font-sans);
  font-size: 0.78rem;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--text-muted);
}

.verse-paragraph {
  margin-bottom: 1rem;
  text-indent: 1.75em;
  cursor: pointer;
  border-radius: 4px;
  transition: background-color 0.2s ease, border-left 0.2s ease;
}

.verse-paragraph:hover {
  background: rgba(212, 175, 55, 0.08);
}

.drop-cap {
  float: left;
  font-family: var(--font-display);
  font-size: 3.6rem;
  line-height: 0.8;
  padding-top: 4px;
  padding-right: 8px;
  padding-left: 2px;
  color: var(--border-gold);
  font-weight: 700;
  text-shadow: 1px 1px 2px rgba(0,0,0,0.1);
}

.v-num {
  font-family: var(--font-sans);
  font-size: 0.7em;
  font-weight: 700;
  color: var(--text-verse-num);
  vertical-align: super;
  margin-right: 0.35rem;
  user-select: none;
}

/* Page Footer */
.page-bottom-footer {
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid var(--border-subtle);
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  text-align: center;
  font-family: var(--font-sans);
  font-size: 0.75rem;
  color: var(--text-muted);
}

.footer-decoration {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
}

.deco-line {
  flex: 0 1 80px;
  height: 1px;
  background: var(--border-gold);
  opacity: 0.4;
}

.deco-symbol {
  color: var(--border-gold);
  font-size: 0.9rem;
}

.footer-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.page-folio-counter {
  font-weight: 700;
  color: var(--text-main);
}

/* ==========================================================================
   BOTTOM TOOLBAR & QUICK CHIPS
   ========================================================================== */
.bottom-toolbar {
  background: var(--header-bg);
  border-top: 2px solid var(--header-border);
  padding: 0.75rem 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  box-shadow: 0 -4px 15px rgba(0,0,0,0.3);
  z-index: 45;
}

.toolbar-nav {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.btn-tool {
  background: #332a20;
  color: #f7eed3;
  border: 1px solid #554432;
  border-radius: 6px;
  padding: 0.4rem 0.8rem;
  font-family: var(--font-sans);
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
}

body.theme-dark .btn-tool {
  background: #21262d;
  color: #c9d1d9;
  border-color: #30363d;
}

.btn-tool:hover {
  background: var(--accent-gold);
  color: #000;
  border-color: var(--border-gold);
}

.page-jump-wrap {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-right: 0.5rem;
}

.book-select,
.chapter-select {
  background: #27211a;
  color: #d4af37;
  border: 1px solid #6b5536;
  border-radius: 6px;
  padding: 0.4rem 0.8rem;
  font-family: 'EB Garamond', serif;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  outline: none;
  max-width: 280px;
  transition: all 0.2s ease;
}

body.theme-dark .book-select,
body.theme-dark .chapter-select {
  background: #161b22;
  color: #c9d1d9;
  border-color: #30363d;
}

.book-select:focus,
.chapter-select:focus {
  border-color: #ffd700;
  box-shadow: 0 0 8px rgba(212, 175, 55, 0.4);
}

.page-pills {
  display: flex;
  gap: 0.5rem;
  overflow-x: auto;
  max-width: 540px;
  padding: 4px;
  scroll-behavior: smooth;
  scrollbar-width: thin;
  scrollbar-color: var(--accent-gold) rgba(0,0,0,0.2);
}

.page-pills::-webkit-scrollbar {
  height: 6px;
}

.page-pills::-webkit-scrollbar-thumb {
  background: var(--accent-gold);
  border-radius: 3px;
}

.page-pill {
  display: flex;
  flex-direction: column;
  align-items: center;
  background: #27211a;
  border: 1px solid #47392b;
  color: #ddd;
  padding: 0.35rem 0.85rem;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.2s ease;
}

body.theme-dark .page-pill {
  background: #161b22;
  border-color: #30363d;
  color: #8b949e;
}

.page-pill:hover {
  border-color: var(--border-gold);
}

.page-pill.active {
  background: var(--accent-gold);
  color: #111;
  border-color: #ffd700;
  font-weight: 700;
  box-shadow: 0 0 10px rgba(212, 175, 55, 0.4);
}

.pill-num {
  font-size: 0.78rem;
  font-weight: 700;
}

.pill-desc {
  font-size: 0.68rem;
  opacity: 0.9;
}

.style-quick-strip {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  flex-wrap: wrap;
}

.quick-label {
  font-family: var(--font-sans);
  font-size: 0.72rem;
  color: #aaa;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.style-chips {
  display: flex;
  gap: 0.4rem;
  flex-wrap: wrap;
  justify-content: center;
}

.chip {
  background: #2a221b;
  border: 1px solid #4a3a2a;
  color: #f7eed3;
  padding: 0.25rem 0.55rem;
  border-radius: 4px;
  font-family: var(--font-sans);
  font-size: 0.72rem;
  cursor: pointer;
  transition: all 0.2s ease;
}

body.theme-dark .chip {
  background: #161b22;
  border-color: #30363d;
  color: #c9d1d9;
}

.chip:hover {
  border-color: var(--border-gold);
  background: #3b3026;
}

.chip.active {
  background: var(--accent-gold);
  color: #111;
  border-color: #ffd700;
  font-weight: 700;
}

.chip.favorite {
  border-color: #f59e0b;
}

/* ==========================================================================
   MODAL: COMPARISON GRID (ALL 10 STYLES)
   ========================================================================== */
.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.82);
  backdrop-filter: blur(8px);
  display: none;
  justify-content: center;
  align-items: center;
  z-index: 2000;
  padding: 1.5rem;
}

.modal-backdrop.open {
  display: flex;
}

.modal-card {
  background: var(--bg-page);
  color: var(--text-main);
  width: 100%;
  max-width: 1150px;
  max-height: 90vh;
  border-radius: 10px;
  box-shadow: 0 25px 50px rgba(0,0,0,0.5);
  border: 2px solid var(--border-gold);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.modal-header {
  padding: 1.25rem 1.5rem;
  border-bottom: 1px solid var(--border-subtle);
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: var(--header-bg);
  color: var(--header-text);
}

.modal-title {
  font-family: var(--font-display);
  font-size: 1.2rem;
  letter-spacing: 1.5px;
  font-weight: 700;
}

.modal-subtitle {
  font-family: var(--font-sans);
  font-size: 0.8rem;
  color: #ccc;
  margin-top: 0.2rem;
}

.modal-close {
  background: transparent;
  border: none;
  color: #fff;
  font-size: 1.4rem;
  cursor: pointer;
  padding: 0.3rem 0.5rem;
  border-radius: 4px;
}

.modal-close:hover {
  background: rgba(255,255,255,0.1);
}

.modal-body {
  padding: 1.5rem;
  overflow-y: auto;
  flex: 1;
}

.comparison-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.25rem;
}

.style-card {
  background: var(--card-bg);
  border: 1px solid var(--border-subtle);
  border-radius: 8px;
  overflow: hidden;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  transition: all 0.25s ease;
  box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.style-card:hover {
  transform: translateY(-4px);
  border-color: var(--border-gold);
  box-shadow: 0 10px 25px rgba(0,0,0,0.25);
}

.style-card.current {
  border: 2px solid var(--accent-gold);
  box-shadow: 0 0 15px rgba(212, 175, 55, 0.4);
}

.style-card.favorite {
  border-top: 3px solid #f59e0b;
}

.card-img-wrapper {
  position: relative;
  aspect-ratio: 16 / 9;
  background: #000;
  overflow: hidden;
}

.card-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.card-fav-tag {
  position: absolute;
  top: 8px;
  right: 8px;
  background: #f59e0b;
  color: #000;
  font-family: var(--font-sans);
  font-size: 0.65rem;
  font-weight: 800;
  padding: 0.2rem 0.45rem;
  border-radius: 4px;
  letter-spacing: 0.5px;
}

.card-body {
  padding: 0.85rem 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  flex: 1;
}

.card-title {
  font-family: var(--font-display);
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text-main);
}

.card-desc {
  font-family: var(--font-sans);
  font-size: 0.76rem;
  line-height: 1.4;
  color: var(--text-muted);
}

.card-select-btn {
  margin-top: auto;
  padding-top: 0.5rem;
  font-family: var(--font-sans);
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--accent-gold-hover);
  display: flex;
  align-items: center;
  gap: 0.3rem;
}

.modal-footer {
  padding: 0.85rem 1.5rem;
  border-top: 1px solid var(--border-subtle);
  background: var(--bg-page);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.modal-hint {
  font-family: var(--font-sans);
  font-size: 0.78rem;
  color: var(--text-muted);
}

/* ==========================================================================
   MODAL: IMAGE ZOOM LIGHTBOX
   ========================================================================== */
.zoom-content {
  position: relative;
  max-width: 90vw;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.zoom-img {
  max-width: 100%;
  max-height: 82vh;
  object-fit: contain;
  border-radius: 6px;
  box-shadow: 0 10px 40px rgba(0,0,0,0.8);
  border: 1px solid rgba(255,255,255,0.2);
}

.zoom-close {
  position: absolute;
  top: 15px;
  right: 15px;
  z-index: 2005;
  background: rgba(0, 0, 0, 0.75);
  border: 1px solid rgba(255, 255, 255, 0.4);
  color: #fff;
  font-size: 1.4rem;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.5);
  transition: all 0.2s ease;
}

.zoom-close:hover {
  background: var(--border-gold);
  color: #1a1612;
  transform: scale(1.08);
}

.zoom-caption {
  margin-top: 0.75rem;
  color: #fff;
  font-family: var(--font-sans);
  font-size: 0.85rem;
  text-align: center;
}

.zoom-nav-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(0, 0, 0, 0.65);
  color: #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.3);
  font-size: 1.3rem;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
  z-index: 10;
  backdrop-filter: blur(4px);
}

.zoom-nav-btn:hover {
  background: var(--accent-gold);
  color: #000;
  border-color: var(--accent-gold);
  transform: translateY(-50%) scale(1.1);
}

.zoom-nav-btn:disabled {
  opacity: 0.3;
  cursor: not-allowed;
  pointer-events: none;
}

.zoom-prev { left: -60px; }
.zoom-next { right: -60px; }

@media (max-width: 768px) {
  .zoom-prev { left: 10px; }
  .zoom-next { right: 10px; }
}

/* ==========================================================================
   PRINT / PDF EXPORT READY STYLES
   ========================================================================== */
@media print {
  body {
    background: #ffffff !important;
    color: #000000 !important;
  }

  .reader-header,
  .choice-alert,
  .nav-arrow,
  .bottom-toolbar,
  .modal-backdrop,
  .image-overlay-badge {
    display: none !important;
  }

  .reader-viewport {
    padding: 0 !important;
  }

  .book-container {
    box-shadow: none !important;
    border: none !important;
    max-width: 100% !important;
  }

  .book-page {
    padding: 1.5cm 2cm !important;
    page-break-after: always;
  }

  .illustration-frame {
    box-shadow: none !important;
    border: 1px solid #ccc !important;
  }

  .page-text-content {
    font-size: 11pt !important;
    line-height: 1.6 !important;
  }
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .book-page {
    padding: 1.5rem 1.25rem;
  }

  .nav-arrow {
    display: none;
  }

  .reader-header {
    padding: 0.5rem 1rem;
  }

  .style-select {
    max-width: 180px;
  }

  .spread-container {
    flex-direction: column !important;
  }

  .spread-spine-gutter {
    display: none !important;
  }

  .spread-columns {
    columns: 1 !important;
  }
}

/* ==========================================================================
   VIEW MODES CONTROLS & NEW STYLES
   ========================================================================== */
.view-modes {
  background: #2b2319;
  border-radius: 6px;
  padding: 2px;
  border: 1px solid #4a3a28;
}

body.theme-dark .view-modes {
  background: #161b22;
  border-color: #30363d;
}

.btn-view {
  background: transparent;
  color: #ccc;
  border: none;
  padding: 0.4rem 0.75rem;
  font-size: 0.78rem;
  font-weight: 600;
  border-radius: 4px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-view:hover {
  color: #fff;
  background: rgba(255,255,255,0.06);
}

.btn-view.active {
  background: var(--accent-gold);
  color: #111;
  font-weight: 700;
  box-shadow: 0 1px 4px rgba(0,0,0,0.2);
}

.btn-prompt-mini {
  background: rgba(212, 175, 55, 0.25);
  border: 1px solid var(--border-gold);
  color: #ffd700;
  border-radius: 4px;
  padding: 0.2rem 0.5rem;
  font-size: 0.72rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-prompt-mini:hover {
  background: var(--accent-gold);
  color: #000;
}

.alert-btn-prompt {
  background: #3b82f6 !important;
  color: #fff !important;
}

.alert-btn-prompt:hover {
  background: #2563eb !important;
}

/* ==========================================================================
   SPREAD MODE (LIVRO ABERTO / 2 PÁGINAS)
   ========================================================================== */
.spread-container {
  display: flex;
  max-width: 1560px;
  width: 96%;
  min-height: 840px;
  background: var(--bg-page);
  border-radius: 8px;
  box-shadow: var(--card-shadow);
  border: 1px solid var(--border-subtle);
  position: relative;
  overflow: hidden;
  transition: all 0.3s ease;
}

.spread-page {
  flex: 1;
  padding: 2.2rem 2.8rem 2.2rem;
  display: flex;
  flex-direction: column;
  gap: 1.2rem;
  position: relative;
}

.spread-page-left {
  border-top-left-radius: 8px;
  border-bottom-left-radius: 8px;
  background: linear-gradient(to right, rgba(0,0,0,0.03) 0%, transparent 8%, transparent 92%, rgba(0,0,0,0.06) 100%);
}

.spread-page-right {
  border-top-right-radius: 8px;
  border-bottom-right-radius: 8px;
  background: linear-gradient(to left, rgba(0,0,0,0.03) 0%, transparent 8%, transparent 92%, rgba(0,0,0,0.06) 100%);
}

.spread-spine-gutter {
  width: 32px;
  background: linear-gradient(
    to right,
    rgba(0,0,0,0.2) 0%,
    rgba(0,0,0,0.04) 30%,
    rgba(255,255,255,0.06) 50%,
    rgba(0,0,0,0.04) 70%,
    rgba(0,0,0,0.2) 100%
  );
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  border-left: 1px solid rgba(0,0,0,0.12);
  border-right: 1px solid rgba(0,0,0,0.12);
  flex-shrink: 0;
}

.spine-line {
  position: absolute;
  top: 0;
  bottom: 0;
  width: 1px;
  background: rgba(0,0,0,0.25);
}

.spread-art-wrapper {
  display: flex;
  flex-direction: column;
  flex: 1;
  height: 100%;
  min-height: 640px;
  justify-content: stretch;
}

.spread-art-frame {
  position: relative;
  width: 100%;
  flex: 1;
  min-height: 640px;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 14px 45px rgba(0,0,0,0.35);
  border: 2px solid var(--border-gold);
  cursor: pointer;
  background: #080605;
  display: flex;
}

.spread-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
  transition: transform 0.45s cubic-bezier(0.16, 1, 0.3, 1);
}

.spread-art-frame:hover .spread-image {
  transform: scale(1.025);
}

.spread-art-frame:hover .image-overlay-badge {
  opacity: 1;
}

.spread-text-wrapper {
  flex: 1;
  display: flex;
  flex-direction: column;
  padding-right: 0.5rem;
}

.spread-columns {
  columns: 1;
  font-size: 17.5px;
  line-height: 1.82;
  text-align: justify;
  hyphens: auto;
  flex: 1;
  max-width: 680px;
  margin: 0 auto;
  width: 100%;
}

.spread-columns .verse-paragraph {
  margin-bottom: 0.95rem;
  text-indent: 1.5em;
}

/* ==========================================================================
   CONTINUOUS PDF SCROLL MODE
   ========================================================================== */
.continuous-container {
  display: flex;
  flex-direction: column;
  gap: 3.5rem;
  max-width: 940px;
  width: 100%;
  margin: 0 auto;
  padding: 1rem 0 5rem;
}

.continuous-card,
.continuous-page-card {
  background: var(--bg-page) !important;
  color: var(--text-main) !important;
  border-radius: 8px;
  box-shadow: var(--card-shadow);
  border: 1px solid var(--border-subtle);
  position: relative;
  overflow: hidden;
  padding: 2.5rem 3.5rem 3rem;
  display: flex;
  flex-direction: column;
  gap: 1.75rem;
  scroll-margin-top: 90px;
  transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}

.continuous-card.current-focused-page {
  border-color: var(--border-gold) !important;
  box-shadow: 0 10px 35px rgba(212, 175, 55, 0.3), var(--card-shadow) !important;
}

.continuous-page-marker {
  align-self: center;
  background: var(--header-bg);
  color: var(--border-gold);
  font-family: var(--font-sans);
  font-size: 0.74rem;
  font-weight: 700;
  padding: 0.35rem 1.1rem;
  border-radius: 20px;
  border: 1px solid var(--border-gold);
  box-shadow: 0 2px 8px rgba(0,0,0,0.25);
  margin-bottom: 0.25rem;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  z-index: 10;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

/* ==========================================================================
   PROMPT INSPECTOR MODAL
   ========================================================================== */
.prompt-card {
  max-width: 820px;
}

.prompt-preview-row {
  display: flex;
  gap: 1.25rem;
  align-items: center;
  background: var(--card-bg);
  padding: 1rem;
  border-radius: 8px;
  border: 1px solid var(--border-subtle);
  margin-bottom: 1.25rem;
}

.prompt-thumb-frame {
  width: 170px;
  aspect-ratio: 16 / 9;
  border-radius: 6px;
  overflow: hidden;
  box-shadow: 0 4px 12px rgba(0,0,0,0.2);
  flex-shrink: 0;
  border: 1px solid var(--border-gold);
}

.prompt-thumb {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.prompt-details {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.prompt-details-title {
  font-family: var(--font-display);
  font-size: 1.05rem;
  color: var(--text-main);
}

.prompt-tag-list {
  display: flex;
  gap: 0.4rem;
  flex-wrap: wrap;
}

.ptag {
  background: var(--accent-gold-light);
  color: var(--accent-gold-hover);
  font-family: var(--font-sans);
  font-size: 0.7rem;
  font-weight: 700;
  padding: 0.15rem 0.5rem;
  border-radius: 4px;
}

.prompt-explanation {
  font-family: var(--font-sans);
  font-size: 0.8rem;
  color: var(--text-muted);
  line-height: 1.4;
}

.prompt-box-section {
  margin-bottom: 1.25rem;
}

.prompt-box-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.45rem;
}

.prompt-box-label {
  font-family: var(--font-sans);
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--text-muted);
  letter-spacing: 0.5px;
}

.btn-copy-prompt {
  background: var(--accent-gold);
  color: #111;
  border: none;
  border-radius: 4px;
  padding: 0.35rem 0.75rem;
  font-family: var(--font-sans);
  font-size: 0.75rem;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 0.4rem;
  transition: all 0.2s ease;
}

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

.prompt-code-block {
  background: #111418;
  color: #e2e8f0;
  font-family: 'SFMono-Regular', Consolas, 'Liberation Mono', Menlo, Courier, monospace;
  font-size: 0.85rem;
  line-height: 1.6;
  padding: 1.1rem 1.25rem;
  border-radius: 6px;
  border: 1px solid #2d3748;
  box-shadow: inset 0 2px 6px rgba(0,0,0,0.4);
  white-space: pre-wrap;
  word-break: break-word;
  user-select: all;
}

.prompt-parameters-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 0.85rem;
}

.param-box {
  background: var(--card-bg);
  border: 1px solid var(--border-subtle);
  border-radius: 6px;
  padding: 0.75rem 0.85rem;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.param-name {
  font-family: var(--font-sans);
  font-size: 0.7rem;
  color: var(--text-muted);
  text-transform: uppercase;
  font-weight: 600;
}

.param-value {
  font-family: var(--font-sans);
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--text-main);
}

/* ==========================================================================
   TABLE OF CONTENTS (TOC) MODAL
   ========================================================================== */
.toc-card {
  max-width: 850px;
}

.toc-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1.25rem;
}

.toc-item {
  background: var(--card-bg);
  border: 1px solid var(--border-subtle);
  border-radius: 8px;
  overflow: hidden;
  cursor: pointer;
  transition: all 0.25s ease;
  display: flex;
  flex-direction: column;
}

.toc-item:hover {
  transform: translateY(-4px);
  border-color: var(--border-gold);
  box-shadow: 0 10px 25px rgba(0,0,0,0.2);
}

.toc-item.active {
  border: 2px solid var(--accent-gold);
  box-shadow: 0 0 15px rgba(212, 175, 55, 0.4);
}

.toc-thumb-wrap {
  position: relative;
  aspect-ratio: 16 / 9;
  background: #000;
}

.toc-thumb-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.toc-badge {
  position: absolute;
  top: 8px;
  left: 8px;
  background: rgba(0,0,0,0.75);
  color: var(--border-gold);
  font-family: var(--font-sans);
  font-size: 0.7rem;
  font-weight: 700;
  padding: 0.2rem 0.5rem;
  border-radius: 4px;
}

.toc-body {
  padding: 0.85rem;
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  flex: 1;
}

.toc-title {
  font-family: var(--font-display);
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text-main);
}

.toc-desc {
  font-family: var(--font-sans);
  font-size: 0.75rem;
  color: var(--text-muted);
  line-height: 1.35;
}

.toc-action {
  margin-top: auto;
  padding-top: 0.5rem;
  font-family: var(--font-sans);
  font-size: 0.76rem;
  font-weight: 700;
  color: var(--accent-gold-hover);
}

/* ==========================================================================
   MOBILE & RESPONSIVE DESIGN OVERHAUL (SMARTPHONES & TABLETS)
   ========================================================================== */

/* Tablets and small laptops (<= 1024px) */
@media (max-width: 1024px) {
  .spread-container {
    max-width: 98%;
    min-height: 700px;
  }
  .spread-page {
    padding: 1.8rem 1.8rem;
  }
  .spread-columns {
    column-gap: 1.5rem;
    font-size: 15.5px;
  }
}

/* Mobile & Small Tablets (<= 768px) */
@media (max-width: 768px) {
  html, body {
    overflow-x: hidden;
    width: 100%;
    -webkit-text-size-adjust: 100%;
  }

  /* Header */
  .reader-header {
    padding: 0.6rem 0.85rem;
    gap: 0.6rem;
    flex-direction: column;
    align-items: stretch;
  }

  .header-left {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
  }

  .header-title {
    font-size: 1.05rem;
    letter-spacing: 1.2px;
  }

  .header-subtitle {
    font-size: 0.7rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 270px;
  }

  .header-controls {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    gap: 0.4rem;
    flex-wrap: nowrap;
    overflow-x: auto;
    padding-bottom: 2px;
    -webkit-overflow-scrolling: touch;
  }

  .view-modes {
    display: flex;
    flex-shrink: 0;
  }

  .btn-view {
    padding: 0.35rem 0.6rem;
    font-size: 0.74rem;
    white-space: nowrap;
  }

  .btn {
    padding: 0.35rem 0.65rem;
    font-size: 0.76rem;
  }

  .btn-icon {
    padding: 0.35rem 0.55rem;
    font-size: 0.8rem;
  }

  /* Main Viewport */
  .reader-viewport {
    padding: 0.65rem 0.5rem calc(11.5rem + env(safe-area-inset-bottom, 0px));
    width: 100%;
    align-items: center;
  }

  /* Hide floating desktop side arrows */
  .nav-arrow {
    display: none !important;
  }

  /* Single Folio Mode on Mobile */
  .book-container {
    max-width: 100% !important;
    width: 100% !important;
    border-radius: 8px;
    border: none;
    box-shadow: 0 4px 20px rgba(0,0,0,0.15);
  }

  .book-spine {
    display: none;
  }

  .book-page {
    padding: 1.2rem 1rem 2rem !important;
    gap: 1.2rem;
  }

  .page-top-header {
    font-size: 0.78rem;
    letter-spacing: 1px;
    padding-bottom: 0.5rem;
  }

  .chapter-title-wrapper {
    margin-bottom: 1rem;
  }

  .chapter-title {
    font-size: 1.35rem !important;
    letter-spacing: 2px;
  }

  .chapter-sub {
    font-size: 0.72rem;
  }

  .page-text-content {
    font-size: 17px !important;
    line-height: 1.72 !important;
    text-align: left !important;
    word-break: break-word;
  }

  .verse-paragraph {
    margin-bottom: 0.9rem;
    text-indent: 1.2em;
  }

  .drop-cap {
    font-size: 2.8rem !important;
    line-height: 0.85 !important;
    padding-top: 2px;
    padding-right: 6px;
    padding-left: 0;
  }

  /* Two-Page Spread Mode on Mobile */
  .spread-container {
    flex-direction: column !important;
    width: 100% !important;
    max-width: 100% !important;
    min-height: auto !important;
    border-radius: 8px !important;
    border: none !important;
    box-shadow: 0 4px 20px rgba(0,0,0,0.15) !important;
    overflow: visible !important;
  }

  /* Mobile Spread Controller Bar */
  .mobile-spread-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.45rem 0.75rem;
    background: rgba(26, 21, 15, 0.95);
    border-bottom: 1px solid var(--border-gold);
    width: 100%;
    box-sizing: border-box;
    border-radius: 8px 8px 0 0;
    gap: 0.5rem;
  }

  .mobile-spread-label {
    font-family: var(--font-display);
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--accent-gold);
    white-space: nowrap;
  }

  .mobile-spread-tabs {
    display: flex;
    gap: 0.35rem;
  }

  .mobile-spread-tab {
    background: #2b2217;
    border: 1px solid #4d3a24;
    color: #e5d8be;
    font-family: var(--font-sans);
    font-size: 0.76rem;
    font-weight: 600;
    padding: 0.3rem 0.65rem;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.2s ease;
  }

  .mobile-spread-tab.active {
    background: var(--accent-gold);
    color: #000;
    border-color: #ffd700;
    font-weight: 700;
    box-shadow: 0 0 8px rgba(212, 175, 55, 0.4);
  }

  /* View Tab Visibility Filters */
  .spread-container.mobile-show-text #spreadLeftPage,
  .spread-container.mobile-show-text .spread-spine-gutter {
    display: none !important;
  }

  .spread-container.mobile-show-art #spreadRightPage,
  .spread-container.mobile-show-art .spread-spine-gutter {
    display: none !important;
  }

  .spread-page {
    padding: 1.2rem 1rem 1.6rem !important;
    gap: 1rem !important;
    width: 100% !important;
    box-sizing: border-box !important;
  }

  .spread-spine-gutter {
    display: none !important;
  }

  .spread-art-wrapper {
    min-height: auto !important;
    height: auto !important;
  }

  .spread-art-frame {
    min-height: auto !important;
    height: auto !important;
    aspect-ratio: 16 / 9;
    max-height: 250px;
    width: 100% !important;
    border-radius: 6px;
  }

  .spread-container.mobile-show-art .spread-art-frame {
    max-height: 65vh;
    aspect-ratio: auto;
    min-height: 320px;
  }

  .spread-text-wrapper {
    max-height: none !important;
    overflow-y: visible !important;
    padding-right: 0 !important;
  }

  .spread-columns {
    columns: 1 !important;
    font-size: 17px !important;
    line-height: 1.72 !important;
    text-align: left !important;
  }

  .spread-columns .verse-paragraph {
    margin-bottom: 0.9rem;
    text-indent: 1.2em;
  }

  /* Continuous Mode on Mobile */
  .continuous-container {
    width: 100% !important;
    gap: 1.8rem !important;
    padding: 0.5rem 0 calc(12rem + env(safe-area-inset-bottom, 0px)) !important;
  }

  .continuous-card,
  .continuous-page-card,
  .continuous-page-card .book-page {
    padding: 1.2rem 1rem 1.8rem !important;
    gap: 1.2rem !important;
    border-radius: 6px !important;
    scroll-margin-top: 75px !important;
  }

  .continuous-page-marker {
    position: static !important;
    margin-bottom: 0.6rem !important;
    text-align: center !important;
    font-size: 0.68rem !important;
    display: inline-block !important;
    align-self: center !important;
  }

  /* Bottom Toolbar for Mobile (Fixed / Sticky with Safe Area) */
  .bottom-toolbar {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 80;
    padding: 0.5rem 0.75rem calc(0.5rem + env(safe-area-inset-bottom, 0px));
    gap: 0.4rem;
    box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(10px);
  }

  .toolbar-nav {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 0.4rem;
    width: 100%;
  }

  .page-jump-wrap {
    order: 1;
    width: 100%;
    margin-right: 0;
    display: flex;
    gap: 0.4rem;
  }

  .book-select {
    flex: 1.2;
    min-width: 0;
    max-width: none;
    font-size: 0.88rem;
    padding: 0.45rem 0.5rem;
    border-radius: 6px;
  }

  .chapter-select {
    flex: 1;
    min-width: 0;
    max-width: none;
    font-size: 0.88rem;
    padding: 0.45rem 0.5rem;
    border-radius: 6px;
  }

  .page-pills {
    order: 2;
    max-width: 100%;
    width: 100%;
    padding: 2px 0;
    -webkit-overflow-scrolling: touch;
  }

  .page-pill {
    padding: 0.25rem 0.6rem;
  }

  .pill-num {
    font-size: 0.72rem;
  }

  .pill-desc {
    font-size: 0.62rem;
    max-width: 70px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .btn-tool#btnFirst,
  .btn-tool#btnLast {
    display: none;
  }

  .btn-tool#btnPrevBottom {
    order: 3;
    flex: 1 1 45%;
    min-height: 40px;
    font-size: 0.9rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
  }

  .btn-tool#btnNextBottom {
    order: 4;
    flex: 1 1 45%;
    min-height: 40px;
    font-size: 0.9rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
  }

  .btn-tool#btnAudioBottom {
    order: 5;
    flex: 1 1 45%;
    min-height: 38px;
    font-size: 0.86rem;
    display: flex;
    align-items: center;
    justify-content: center;
  }

  .btn-tool#btnRandomBottom {
    order: 6;
    flex: 1 1 45%;
    min-height: 38px;
    font-size: 0.86rem;
    display: flex;
    align-items: center;
    justify-content: center;
  }

  .audio-player-bar {
    top: auto !important;
    bottom: calc(198px + env(safe-area-inset-bottom, 0px)) !important;
    left: 50% !important;
    transform: translateX(-50%) !important;
    width: 95% !important;
    max-width: 480px !important;
    padding: 0.5rem 0.75rem !important;
    z-index: 950 !important;
    border-radius: 25px !important;
    box-shadow: 0 6px 25px rgba(0,0,0,0.6), 0 0 15px rgba(212, 175, 55, 0.4);
  }

  /* Modals on Mobile */
  .modal-backdrop {
    padding: 0.5rem;
    align-items: flex-end;
  }

  .modal-card {
    max-height: 90vh;
    border-radius: 12px 12px 0 0;
  }

  .modal-header {
    padding: 0.85rem 1rem;
  }

  .modal-title {
    font-size: 1rem;
  }

  .modal-subtitle {
    font-size: 0.72rem;
  }

  .modal-body {
    padding: 0.85rem;
  }

  .toc-grid {
    grid-template-columns: 1fr;
    gap: 0.75rem;
  }

  /* Zoom Modal on Mobile */
  .zoom-content {
    max-width: 100vw;
    max-height: 92vh;
    width: 100%;
    justify-content: center;
  }

  .zoom-img {
    max-width: 96vw;
    max-height: 72vh;
  }

  .zoom-close {
    top: 10px;
    right: 10px;
    width: 38px;
    height: 38px;
    font-size: 1.2rem;
  }

  .zoom-nav-btn {
    width: 38px;
    height: 38px;
    font-size: 1rem;
  }

  .zoom-prev { left: 6px; }
  .zoom-next { right: 6px; }
}

/* Very Small Mobile Screens (<= 480px, e.g. iPhone SE, Galaxy A) */
@media (max-width: 480px) {
  .header-subtitle {
    display: none;
  }

  .font-btns,
  #btnPrint {
    display: none;
  }

  .header-title {
    font-size: 0.95rem;
  }

  .book-crest {
    font-size: 1.4rem;
  }

  .chapter-title {
    font-size: 1.2rem !important;
  }

  .book-page {
    padding: 1rem 0.75rem 1.75rem !important;
  }

  .page-text-content,
  .spread-columns {
    font-size: 16px !important;
  }

  .illustration-caption {
    font-size: 0.72rem;
  }
}

/* Default state: mobile spread bar hidden on desktop */
@media (min-width: 769px) {
  .mobile-spread-bar {
    display: none !important;
  }
}

/* Mobile & Tablet Landscape Mode: True Side-by-Side Open Book */
@media (max-width: 1024px) and (orientation: landscape) {
  .spread-container {
    flex-direction: row !important;
    width: 98% !important;
    max-width: 100% !important;
    height: calc(100vh - 125px) !important;
    min-height: 380px !important;
    max-height: 90vh !important;
    overflow: hidden !important;
  }

  .mobile-spread-bar {
    display: none !important;
  }

  .spread-page {
    flex: 1 1 50% !important;
    width: 50% !important;
    height: 100% !important;
    padding: 0.8rem 1.2rem !important;
    display: flex !important;
    overflow-y: hidden !important;
    box-sizing: border-box !important;
  }

  .spread-spine-gutter {
    display: flex !important;
  }

  .spread-art-wrapper {
    height: calc(100% - 60px) !important;
    min-height: auto !important;
    display: flex;
    align-items: center;
    justify-content: center;
  }

  .spread-art-frame {
    height: 100% !important;
    width: 100% !important;
    max-height: 100% !important;
    aspect-ratio: auto !important;
  }

  .spread-art-frame .spread-image {
    object-fit: contain !important;
    max-height: 100% !important;
  }

  .spread-text-wrapper {
    height: calc(100% - 60px) !important;
    max-height: none !important;
    overflow-y: auto !important;
    -webkit-overflow-scrolling: touch;
    padding-right: 0.5rem !important;
  }

  .spread-columns {
    columns: 1 !important;
    font-size: 15px !important;
    line-height: 1.6 !important;
  }
}

/* ==========================================================================
   AUTOCOMPLETE SEARCH MODAL
   ========================================================================== */
.search-card {
  max-width: 760px;
  width: 95%;
  max-height: 85vh;
  display: flex;
  flex-direction: column;
  background: var(--card-bg);
  border: 1px solid var(--border-gold);
  border-radius: 12px;
  box-shadow: 0 12px 40px rgba(0,0,0,0.6);
  overflow: hidden;
}

.search-header-title {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}

.search-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  background: rgba(212, 175, 55, 0.15);
  border: 1px solid rgba(212, 175, 55, 0.35);
  color: var(--accent-gold);
  font-size: 0.72rem;
  font-weight: 700;
  padding: 0.2rem 0.55rem;
  border-radius: 12px;
  width: fit-content;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.search-input-wrapper {
  display: flex;
  align-items: center;
  padding: 0.75rem 1.25rem;
  background: rgba(0,0,0,0.25);
  border-bottom: 1px solid var(--border-subtle);
  position: relative;
  gap: 0.75rem;
}

.search-input-icon {
  font-size: 1.2rem;
  opacity: 0.7;
}

.search-input-field {
  flex: 1;
  background: transparent;
  border: none;
  color: var(--text-main);
  font-family: var(--font-sans);
  font-size: 1.05rem;
  outline: none;
  width: 100%;
}

.search-input-field::placeholder {
  color: var(--text-muted);
  font-size: 0.95rem;
}

.btn-clear-search {
  background: rgba(255,255,255,0.1);
  border: none;
  color: var(--text-muted);
  width: 26px;
  height: 26px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.8rem;
  transition: all 0.2s;
}

.btn-clear-search:hover {
  background: rgba(255,255,255,0.2);
  color: var(--text-main);
}

.search-chips {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.6rem 1.25rem;
  background: rgba(0,0,0,0.12);
  border-bottom: 1px solid var(--border-subtle);
  overflow-x: auto;
  white-space: nowrap;
  -webkit-overflow-scrolling: touch;
}

.search-chips-label {
  font-size: 0.72rem;
  color: var(--text-muted);
  font-weight: 600;
  text-transform: uppercase;
  margin-right: 0.25rem;
}

.search-chip {
  background: rgba(212, 175, 55, 0.1);
  border: 1px solid rgba(212, 175, 55, 0.25);
  color: var(--text-main);
  border-radius: 20px;
  padding: 0.25rem 0.65rem;
  font-size: 0.76rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s;
  white-space: nowrap;
}

.search-chip:hover {
  background: var(--accent-gold);
  color: #000;
  border-color: var(--accent-gold);
}

.search-status-bar {
  padding: 0.45rem 1.25rem;
  font-size: 0.78rem;
  color: var(--text-muted);
  border-bottom: 1px solid var(--border-subtle);
}

.search-results-body {
  flex: 1;
  overflow-y: auto;
  max-height: 45vh;
  padding: 0.75rem 1.25rem;
}

.search-results-list {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.search-result-item {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  padding: 0.8rem 1rem;
  background: rgba(0,0,0,0.15);
  border: 1px solid var(--border-subtle);
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.search-result-item:hover,
.search-result-item.selected {
  background: rgba(212, 175, 55, 0.15);
  border-color: var(--border-gold);
  transform: translateX(4px);
}

.search-result-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.search-result-title {
  font-family: var(--font-display);
  font-size: 0.98rem;
  font-weight: 700;
  color: var(--accent-gold);
}

.search-result-badge {
  font-size: 0.7rem;
  background: rgba(212, 175, 55, 0.2);
  color: var(--accent-gold);
  padding: 0.15rem 0.5rem;
  border-radius: 4px;
  font-weight: 700;
}

.search-result-text {
  font-family: var(--font-serif);
  font-size: 0.95rem;
  line-height: 1.45;
  color: var(--text-main);
}

.search-result-text mark {
  background: rgba(255, 215, 0, 0.35);
  color: inherit;
  padding: 0 2px;
  border-radius: 2px;
  font-weight: 700;
}

.search-result-meta {
  display: flex;
  justify-content: space-between;
  font-size: 0.74rem;
  color: var(--text-muted);
}

/* ==========================================================================
   FLOATING AUDIO PLAYER BAR (TEXT-TO-SPEECH)
   ========================================================================== */
.audio-player-bar {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  width: 94%;
  max-width: 760px;
  background: rgba(26, 21, 15, 0.95);
  backdrop-filter: blur(14px);
  border: 1px solid var(--border-gold);
  border-radius: 35px;
  box-shadow: 0 10px 35px rgba(0,0,0,0.55), 0 0 18px rgba(212, 175, 55, 0.35);
  padding: 0.55rem 1.2rem;
  z-index: 95;
  animation: slideUpBar 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes slideUpBar {
  from { opacity: 0; transform: translate(-50%, 20px); }
  to { opacity: 1; transform: translate(-50%, 0); }
}

.audio-bar-content {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  width: 100%;
}

.audio-bar-info {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  min-width: 0;
  flex: 1;
}

.audio-bar-icon-wrap {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: rgba(212, 175, 55, 0.15);
  border: 1px solid var(--border-gold);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.audio-wave-anim {
  display: none;
  align-items: center;
  gap: 3px;
  height: 18px;
}

.audio-player-bar.playing .audio-wave-anim {
  display: flex;
}

.audio-player-bar.playing .audio-static-icon {
  display: none;
}

.audio-wave-anim span {
  width: 3px;
  background: var(--accent-gold);
  border-radius: 2px;
  animation: waveBar 1.2s ease-in-out infinite;
}

.audio-wave-anim span:nth-child(1) { height: 8px; animation-delay: 0.1s; }
.audio-wave-anim span:nth-child(2) { height: 16px; animation-delay: 0.25s; }
.audio-wave-anim span:nth-child(3) { height: 12px; animation-delay: 0.4s; }
.audio-wave-anim span:nth-child(4) { height: 6px; animation-delay: 0.15s; }

@keyframes waveBar {
  0%, 100% { transform: scaleY(0.4); }
  50% { transform: scaleY(1.2); }
}

.audio-bar-details {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.audio-bar-title {
  font-family: var(--font-display);
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--accent-gold);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.audio-bar-subtitle {
  font-family: var(--font-sans);
  font-size: 0.74rem;
  color: #ccc;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.audio-bar-controls {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-shrink: 0;
}

.btn-audio-ctrl {
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.15);
  color: #fff;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.85rem;
  transition: all 0.2s;
}

.btn-audio-ctrl:hover {
  background: rgba(212, 175, 55, 0.3);
  border-color: var(--accent-gold);
  color: var(--accent-gold);
}

.btn-audio-play {
  background: var(--accent-gold);
  color: #000;
  border: none;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  font-weight: bold;
  box-shadow: 0 0 12px rgba(212, 175, 55, 0.5);
  transition: all 0.2s;
}

.btn-audio-play:hover {
  transform: scale(1.08);
  background: #ffd700;
}

.audio-speed-wrap {
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.audio-speed-label {
  display: none;
}

.audio-speed-select {
  background: #2b2217;
  color: var(--accent-gold);
  border: 1px solid #5a452c;
  border-radius: 6px;
  font-size: 0.76rem;
  font-weight: 600;
  padding: 0.25rem 0.4rem;
  cursor: pointer;
  outline: none;
}

.btn-audio-close {
  background: transparent;
  border: none;
  color: #888;
  font-size: 1.1rem;
  cursor: pointer;
  padding: 0.2rem 0.4rem;
  margin-left: 0.25rem;
  transition: color 0.2s;
}

.btn-audio-close:hover {
  color: #fff;
}

/* TTS Speak Verse Number Toggle Switch */
.audio-toggle-verse-num {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  background: rgba(0, 0, 0, 0.35);
  border: 1px solid rgba(212, 175, 55, 0.3);
  padding: 0.25rem 0.55rem;
  border-radius: 14px;
  cursor: pointer;
  user-select: none;
  transition: all 0.2s ease;
}

.audio-toggle-verse-num:hover {
  border-color: var(--border-gold);
  background: rgba(0, 0, 0, 0.55);
}

.tts-switch {
  position: relative;
  display: inline-block;
  width: 32px;
  height: 18px;
  margin: 0;
  cursor: pointer;
}

.tts-switch input {
  opacity: 0;
  width: 0;
  height: 0;
  position: absolute;
}

.tts-slider {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: #3b3126;
  border-radius: 18px;
  transition: all 0.25s ease;
  border: 1px solid rgba(212, 175, 55, 0.4);
}

.tts-slider::before {
  position: absolute;
  content: "";
  height: 12px;
  width: 12px;
  left: 2px;
  bottom: 2px;
  background-color: #a89474;
  border-radius: 50%;
  transition: all 0.25s ease;
}

.tts-switch input:checked + .tts-slider {
  background-color: var(--accent-gold);
  border-color: #ffd700;
  box-shadow: 0 0 8px rgba(212, 175, 55, 0.5);
}

.tts-switch input:checked + .tts-slider::before {
  transform: translateX(14px);
  background-color: #1a150f;
}

.tts-switch-label {
  font-family: var(--font-sans);
  font-size: 0.74rem;
  font-weight: 600;
  color: #f7eed3;
  white-space: nowrap;
}

/* Spotlight Mode when TTS is Active: Dim background verses for crystal clarity */
body.tts-active .verse-paragraph:not(.speaking-verse) {
  opacity: 0.30 !important;
  filter: blur(0.2px);
  transition: opacity 0.3s ease, filter 0.3s ease;
}

/* Active Speaking Verse Highlight - Crystal Clear & Prominent */
.verse-paragraph {
  position: relative;
}

.verse-paragraph .v-num-dropcap {
  display: none;
}

.speaking-verse .v-num-dropcap {
  display: inline-block !important;
}

.speaking-verse {
  background: rgba(212, 175, 55, 0.28) !important;
  outline: 2px solid var(--accent-gold) !important;
  outline-offset: 3px;
  border-left: 6px solid #ffd700 !important;
  padding: 0.55rem 0.85rem 0.55rem 1rem !important;
  border-radius: 8px !important;
  box-shadow: 0 0 25px rgba(212, 175, 55, 0.55), inset 0 0 10px rgba(212, 175, 55, 0.2) !important;
  position: relative;
  transition: all 0.25s ease;
}

.speaking-verse .drop-cap {
  color: #ffd700 !important;
  text-shadow: 0 0 14px rgba(255, 215, 0, 0.85) !important;
}

body.theme-dark .speaking-verse {
  background: rgba(227, 179, 65, 0.3) !important;
  outline-color: #ffd700 !important;
  border-left-color: #ffd700 !important;
  color: #fff !important;
  box-shadow: 0 0 26px rgba(227, 179, 65, 0.6) !important;
}

body.theme-light .speaking-verse {
  background: rgba(37, 99, 235, 0.2) !important;
  outline-color: #2563eb !important;
  border-left-color: #2563eb !important;
  color: #0f172a !important;
  box-shadow: 0 0 22px rgba(37, 99, 235, 0.45) !important;
}

body.theme-sepia .speaking-verse {
  background: rgba(176, 92, 25, 0.26) !important;
  outline-color: #b05c19 !important;
  border-left-color: #b05c19 !important;
  box-shadow: 0 0 22px rgba(176, 92, 25, 0.45) !important;
}

.speaking-verse .v-num {
  display: inline-block !important;
  color: #ffd700 !important;
  font-weight: 800 !important;
  text-shadow: 0 0 8px rgba(255, 215, 0, 0.7);
}

.verse-reading-badge {
  position: absolute;
  top: -12px;
  right: 12px;
  background: linear-gradient(135deg, #ffd700 0%, #d4af37 100%);
  color: #1a1205 !important;
  font-family: var(--font-sans);
  font-size: 0.72rem;
  font-weight: 800;
  padding: 3px 10px;
  border-radius: 12px;
  box-shadow: 0 3px 12px rgba(0, 0, 0, 0.35), 0 0 10px rgba(255, 215, 0, 0.5);
  letter-spacing: 0.6px;
  text-transform: uppercase;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  z-index: 10;
  pointer-events: none;
  animation: pulseReadingBadge 1.8s ease-in-out infinite alternate;
}

@keyframes pulseReadingBadge {
  0% { transform: scale(0.97); box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3), 0 0 6px rgba(255, 215, 0, 0.4); }
  100% { transform: scale(1.03); box-shadow: 0 4px 16px rgba(0, 0, 0, 0.4), 0 0 16px rgba(255, 215, 0, 0.8); }
}

@media (max-width: 480px) {
  .audio-bar-icon-wrap {
    display: none !important;
  }
  .audio-bar-content {
    gap: 0.25rem !important;
  }
  .audio-bar-title {
    font-size: 0.8rem !important;
  }
  .audio-bar-subtitle {
    font-size: 0.68rem !important;
  }
  .audio-speed-wrap {
    display: flex !important;
  }
  .audio-speed-select {
    padding: 0.15rem 0.25rem !important;
    font-size: 0.72rem !important;
    max-width: 58px !important;
  }
  .audio-toggle-verse-num {
    padding: 0.15rem 0.35rem !important;
    gap: 0.25rem !important;
    border-radius: 10px !important;
  }
  .tts-switch {
    width: 28px !important;
    height: 16px !important;
  }
  .tts-slider::before {
    height: 10px !important;
    width: 10px !important;
    left: 2px !important;
    bottom: 2px !important;
  }
  .tts-switch input:checked + .tts-slider::before {
    transform: translateX(12px) !important;
  }
  .tts-switch-label {
    font-size: 0.65rem !important;
  }
  .btn-audio-ctrl {
    width: 28px !important;
    height: 28px !important;
    font-size: 0.75rem !important;
  }
  .btn-audio-play {
    width: 36px !important;
    height: 36px !important;
    font-size: 1rem !important;
  }
  .toast-notification {
    top: 15px !important;
    font-size: 0.8rem !important;
    padding: 0.45rem 0.9rem !important;
  }
}

/* Mobile Landscape Optimization (e.g. 844x390, 740x360) */
@media (max-height: 500px) and (orientation: landscape) {
  .reader-header {
    flex-direction: row !important;
    padding: 0.35rem 0.75rem !important;
    align-items: center !important;
  }
  .header-left {
    width: auto !important;
  }
  .header-controls {
    width: auto !important;
  }
  .bottom-toolbar {
    padding: 0.3rem 0.6rem calc(0.3rem + env(safe-area-inset-bottom, 0px)) !important;
  }
  .page-pills {
    display: none !important;
  }
  .reader-viewport {
    padding: 0.5rem 0.5rem calc(6.5rem + env(safe-area-inset-bottom, 0px)) !important;
  }
  .audio-player-bar {
    bottom: calc(90px + env(safe-area-inset-bottom, 0px)) !important;
  }
}

/* ==========================================================================
   TOAST NOTIFICATION
   ========================================================================== */
.toast-notification {
  position: fixed;
  top: 75px;
  left: 50%;
  transform: translateX(-50%) translateY(-20px);
  background: rgba(25, 20, 14, 0.95);
  color: #f7eed3;
  border: 1px solid var(--border-gold);
  padding: 0.65rem 1.25rem;
  border-radius: 30px;
  box-shadow: 0 8px 25px rgba(0,0,0,0.5);
  display: flex;
  align-items: center;
  gap: 0.65rem;
  font-family: var(--font-sans);
  font-size: 0.88rem;
  font-weight: 600;
  z-index: 100;
  opacity: 0;
  pointer-events: none;
  transition: all 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

.toast-notification.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
  pointer-events: auto;
}

.toast-icon {
  font-size: 1.15rem;
}

@media (max-width: 768px) {
  .toast-notification {
    top: 12px !important;
    font-size: 0.78rem !important;
    padding: 0.35rem 0.85rem !important;
    max-width: 90vw;
  }
}

/* ==========================================================================
   PRINT / PDF EXPORT STYLESHEET
   ========================================================================== */
@media print {
  .reader-header,
  .bottom-toolbar,
  .nav-arrow,
  .mobile-spread-bar,
  .audio-player-bar,
  .toast-notification,
  .chapter-action-bar,
  .image-overlay-badge,
  .modal-backdrop,
  .footer-decoration {
    display: none !important;
  }

  body {
    background: #ffffff !important;
    color: #000000 !important;
  }

  .reader-viewport {
    padding: 0 !important;
    margin: 0 !important;
    width: 100% !important;
  }

  .book-container,
  .spread-container,
  .continuous-card,
  .continuous-page-card {
    box-shadow: none !important;
    border: none !important;
    background: #ffffff !important;
    color: #000000 !important;
    width: 100% !important;
    max-width: 100% !important;
    padding: 0 !important;
    margin: 0 0 2rem 0 !important;
    page-break-after: always;
    break-after: page;
  }

  .page-text-content,
  .spread-columns,
  .verse-paragraph {
    color: #000000 !important;
  }
}



