/* ── PRABHU VAANI — MAIN STYLES ── */
@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;600;700&family=Noto+Sans+Devanagari:wght@300;400;600;700&family=Noto+Sans+Gurmukhi:wght@300;400;600;700&family=Noto+Sans+Malayalam:wght@300;400;600;700&family=Noto+Sans+Tamil:wght@300;400;600;700&family=Noto+Sans+Gujarati:wght@300;400;600;700&display=swap');

:root {
  --bg: #0f0f1a;
  --bg2: #1a1a2e;
  --bg3: #16213e;
  --card: #16213e;
  --primary: #8b2fc9;
  --primary2: #7a28b8;
  --accent: #f5a623;
  --text: #f0ebe0;
  --text2: #aa9f95;
  --divider: #ffffff0f;
  --error: #e53935;
  --success: #4caf50;
  --border: #ffffff15;
  --sidebar-w: 280px;
}

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

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: 'Poppins', 'Noto Sans Devanagari', 'Noto Sans Gurmukhi',
               'Noto Sans Malayalam', 'Noto Sans Tamil', 'Noto Sans Gujarati', sans-serif;
  min-height: 100vh;
  line-height: 1.6;
}

[data-lang="pa"] .vtext { font-family: 'Noto Sans Gurmukhi', sans-serif; }
[data-lang="hi"] .vtext { font-family: 'Noto Sans Devanagari', sans-serif; }
[data-lang="ml"] .vtext { font-family: 'Noto Sans Malayalam', sans-serif; }
[data-lang="ta"] .vtext { font-family: 'Noto Sans Tamil', sans-serif; }
[data-lang="gu"] .vtext { font-family: 'Noto Sans Gujarati', sans-serif; }

/* ── HEADER ── */
.header {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  background: rgba(15,15,26,0.96);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  height: 60px;
  display: flex; align-items: center;
  padding: 0 20px; gap: 16px;
}

.header-logo {
  display: flex; align-items: center; gap: 10px;
  text-decoration: none; color: var(--text);
}

.logo-icon {
  width: 36px; height: 36px;
  background: linear-gradient(135deg, var(--primary), var(--primary2));
  border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  font-size: 18px; color: #fff;
  flex-shrink: 0;
}

.logo-text { font-size: 18px; font-weight: 700; }

.header-spacer { flex: 1; }

/* ── GLOBE LANGUAGE BUTTON ── */
.lang-globe-btn {
  display: flex; align-items: center; gap: 6px;
  padding: 6px 12px;
  background: var(--card);
  border: 1px solid rgba(139,47,201,0.4);
  border-radius: 10px;
  color: var(--primary);
  font-size: 13px; font-weight: 600;
  cursor: pointer; transition: all 0.2s;
  font-family: inherit;
  white-space: nowrap;
}

.lang-globe-btn:hover {
  background: rgba(139,47,201,0.15);
  border-color: var(--primary);
}

.lang-globe-arrow { font-size: 10px; opacity: 0.7; }

/* ── LANGUAGE BOTTOM SHEET ── */
.lang-sheet-overlay {
  position: fixed; inset: 0; z-index: 500;
  background: rgba(0,0,0,0.65);
  backdrop-filter: blur(4px);
  opacity: 0; transition: opacity 0.25s;
}

.lang-sheet-overlay.show { opacity: 1; }

.lang-sheet {
  position: fixed; bottom: 0; left: 0; right: 0;
  background: var(--card);
  border-radius: 20px 20px 0 0;
  border-top: 1px solid var(--border);
  padding: 12px 20px 32px;
  z-index: 501;
  transform: translateY(100%);
  transition: transform 0.3s cubic-bezier(0.32, 0.72, 0, 1);
  max-height: 80vh; overflow-y: auto;
}

.lang-sheet.show { transform: translateY(0); }

.lang-sheet-handle {
  width: 40px; height: 4px;
  background: var(--border);
  border-radius: 2px;
  margin: 0 auto 16px;
}

.lang-sheet-title {
  font-size: 15px; font-weight: 700;
  color: var(--text); margin-bottom: 12px;
}

.lang-sheet-item {
  display: flex; align-items: center; gap: 14px;
  padding: 12px; border-radius: 12px;
  cursor: pointer; transition: background 0.15s;
  border: none; background: none; width: 100%;
  text-align: left; font-family: inherit;
}

.lang-sheet-item:hover { background: rgba(139,47,201,0.1); }
.lang-sheet-item.active { background: rgba(139,47,201,0.15); }

.lang-item-icon {
  width: 40px; height: 40px; border-radius: 10px;
  background: var(--bg2);
  display: flex; align-items: center; justify-content: center;
  font-size: 18px; flex-shrink: 0;
}

.lang-item-icon.active-icon { background: rgba(139,47,201,0.2); }

.lang-item-text { flex: 1; }

.lang-item-name {
  font-size: 15px; font-weight: 500; color: var(--text);
}

.lang-item-name.active-name { color: var(--primary); font-weight: 700; }

.lang-item-sub { font-size: 11px; color: var(--text2); margin-top: 1px; }

.lang-check { color: var(--primary); font-size: 16px; font-weight: 700; }

/* ── MENU BUTTON (mobile) ── */
#menu-btn {
  display: none;
  background: none; border: none;
  color: var(--text); font-size: 22px; cursor: pointer;
  padding: 4px 8px;
}

/* ── LAYOUT ── */
.page-body { padding-top: 60px; min-height: 100vh; }

/* ── HOMEPAGE CARDS ── */
.home-hero {
  text-align: center;
  padding: 60px 24px 40px;
}

.home-hero h1 {
  font-size: clamp(28px, 5vw, 48px);
  font-weight: 800;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  -webkit-background-clip: text; -webkit-text-fill-color: transparent;
  margin-bottom: 12px;
}

.home-hero p { color: var(--text2); font-size: 16px; }

.section-label {
  display: flex; align-items: center; gap: 8px;
  font-size: 11px; font-weight: 700; letter-spacing: 2px;
  text-transform: uppercase; color: var(--accent);
  margin-bottom: 16px;
}

.section-label::after { content: ''; flex: 1; height: 1px; background: var(--divider); }

/* VOTD Card */
.votd-card {
  background: linear-gradient(135deg, #1e0a3c, #12112a);
  border: 1px solid rgba(139,47,201,0.3);
  border-radius: 20px;
  padding: 24px;
  margin-bottom: 24px;
}

.votd-text {
  font-size: 18px; line-height: 1.8;
  color: var(--text); margin-bottom: 12px;
}

.votd-ref {
  color: var(--accent); font-weight: 600; font-size: 14px;
  margin-bottom: 16px;
}

.votd-actions { display: flex; gap: 10px; flex-wrap: wrap; }

/* Quick Access */
.quick-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
  margin-bottom: 32px;
}

.quick-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 20px;
  text-decoration: none; color: var(--text);
  display: flex; align-items: center; gap: 14px;
  transition: all 0.2s;
}

.quick-card:hover {
  border-color: var(--primary);
  transform: translateY(-2px);
}

.quick-icon {
  width: 48px; height: 48px;
  border-radius: 14px;
  display: flex; align-items: center; justify-content: center;
  font-size: 22px; flex-shrink: 0;
}

.quick-card h3 { font-size: 15px; font-weight: 600; margin-bottom: 2px; }
.quick-card p { font-size: 12px; color: var(--text2); }

/* ── BUTTONS ── */
.btn {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 10px 18px;
  border: none; border-radius: 10px;
  font-size: 13px; font-weight: 600; cursor: pointer;
  transition: all 0.2s; font-family: inherit;
  text-decoration: none;
}

.btn-primary { background: var(--primary); color: #fff; }
.btn-primary:hover { background: var(--primary2); transform: translateY(-1px); }

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

.btn-ghost { background: var(--bg2); color: var(--text2); }
.btn-ghost:hover { color: var(--text); }

.btn-sm { padding: 7px 12px; font-size: 12px; }

/* ── TOAST ── */
#toast {
  position: fixed; bottom: 80px; left: 50%; transform: translateX(-50%) translateY(20px);
  background: var(--success); color: #000;
  padding: 10px 22px; border-radius: 30px;
  font-size: 13px; font-weight: 600;
  opacity: 0; transition: all 0.3s; pointer-events: none; z-index: 999;
  white-space: nowrap;
}

#toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

/* ── LOADING SPINNER ── */
.loading-spinner {
  display: flex; flex-direction: column; align-items: center;
  justify-content: center; padding: 60px 20px; gap: 14px;
  color: var(--text2);
}

.spinner {
  width: 36px; height: 36px;
  border: 3px solid var(--border);
  border-top-color: var(--primary);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

@keyframes spin { to { transform: rotate(360deg); } }

.error-msg {
  text-align: center; color: var(--error);
  padding: 40px; font-size: 14px;
}

/* ── CONTAINER ── */
.container { max-width: 900px; margin: 0 auto; padding: 0 20px; }

/* ── TESTAMENT BOOK CHIPS ── */
.testament-books {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 8px;
}

.book-chip {
  display: inline-flex;
  align-items: center;
  padding: 6px 14px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 20px;
  font-size: 13px;
  color: var(--text2);
  text-decoration: none;
  transition: all 0.15s;
  white-space: nowrap;
  line-height: 1.5;
}

.book-chip:hover {
  border-color: var(--primary);
  color: var(--primary);
  background: rgba(139,47,201,0.1);
}
