/* Standalone "Sung Bible" audio browser. Kept separate from style.css/app.js
   on purpose (see CLAUDE.md/plan) -- it borrows the app's house style via
   the shared :root custom properties (--bg, --card-bg, --accent, --text,
   --text-muted, --radius) defined in style.css, which is loaded first. */

.sung-bible-modal.hidden { display: none; }

.sung-bible-modal {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 5vh 0;
}

.sung-bible-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(2px);
}

.sung-bible-modal-content {
  position: relative;
  width: 100%;
  max-width: 480px;
  height: 88vh;
  max-height: 640px;
  margin: 1rem;
  background: var(--card-bg);
  border-radius: var(--radius);
  padding: 2rem 1.2rem 1.2rem;
  box-shadow: 0 12px 32px rgba(0,0,0,0.4);
  display: flex;
  flex-direction: column;
}

.sung-bible-modal-close {
  position: absolute;
  top: 0.6rem;
  right: 0.8rem;
  background: none;
  border: none;
  color: var(--text-muted);
  font-size: 1.6rem;
  line-height: 1;
  cursor: pointer;
  padding: 0.2rem;
}

.sung-bible-modal-close:hover {
  color: var(--text);
}

.sung-bible-back-btn {
  display: none;
  align-self: flex-start;
  align-items: center;
  gap: 0.3rem;
  background: none;
  border: none;
  color: var(--accent);
  font: inherit;
  font-weight: 600;
  cursor: pointer;
  padding: 0.2rem 0.4rem 0.6rem;
}

.sung-bible-back-btn.visible {
  display: inline-flex;
}

.sung-bible-heading {
  flex: none;
  margin: 0 0 0.6rem;
  font-size: 1.1rem;
  font-weight: 600;
  text-align: center;
}

.sung-bible-scroll {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  padding-right: 0.2rem;
  scrollbar-width: thin;
  scrollbar-color: rgba(255,255,255,0.25) transparent;
}

.sung-bible-scroll::-webkit-scrollbar {
  width: 6px;
}

.sung-bible-scroll::-webkit-scrollbar-track {
  background: transparent;
}

.sung-bible-scroll::-webkit-scrollbar-thumb {
  background: rgba(255,255,255,0.25);
  border-radius: 3px;
}

.sung-bible-section-label {
  margin: 0.9rem 0.2rem 0.5rem;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--text-muted);
}

.sung-bible-section-label:first-child {
  margin-top: 0;
}

.sung-bible-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 0.4rem;
}

.sung-bible-bubble {
  border: 1px solid rgba(255,255,255,0.14);
  background: var(--card-bg);
  color: var(--text);
  font: inherit;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  border-radius: 999px;
}

.sung-bible-grid--books .sung-bible-bubble {
  padding: 0.5rem 0.9rem;
  min-width: 3.2rem;
  text-align: center;
}

.sung-bible-grid--chapters .sung-bible-bubble {
  width: 2.4rem;
  height: 2.4rem;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.sung-bible-bubble:hover {
  border-color: rgba(255,255,255,0.3);
}

.sung-bible-bubble.playing {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}

.sung-bible-bubble.loading {
  opacity: 0.6;
  cursor: wait;
}

@media (max-width: 480px) {
  .sung-bible-modal-content { height: 92vh; padding: 1.6rem 0.8rem 1rem; }
  .sung-bible-grid--chapters .sung-bible-bubble { width: 2.1rem; height: 2.1rem; font-size: 0.8rem; }
}
