/* -----------------------------
   RESET & ROOT
----------------------------- */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  --bg-body: #fafaf9;
  --bg-surface: #ffffff;
  --text-primary: #111111;
  --text-secondary: #6b7280;
  --text-muted: #8b6b3d;
  --accent: #d97706;
  --accent-strong: #ea580c;
  --border-soft: rgba(0, 0, 0, 0.05);
  --shadow-soft: 0 24px 40px rgba(15, 23, 42, 0.08);

  --radius-lg: 18px;
  --radius-pill: 999px;

  --section-padding-desktop: 80px;
  --section-padding-mobile: 56px;

  --max-width: 960px;
}

html,
body {
  height: 100%;
}

body {
  background: var(--bg-body);
  color: var(--text-primary);
  font-family: "Poppins", system-ui, -apple-system, BlinkMacSystemFont,
    sans-serif;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

/* Tiro utility */
.tiro-devanagari-hindi-regular {
  font-family: "Tiro Devanagari Hindi", serif;
  font-weight: 400;
  font-style: normal;
}

/* -----------------------------
   SECTIONS & BACKGROUNDS
----------------------------- */
.section {
  position: relative;
  padding: var(--section-padding-desktop) 0;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  overflow: hidden;
}

.section::before {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(250, 250, 249, 0.78);
  backdrop-filter: blur(2px);
  z-index: 0;
}

.section-inner {
  position: relative;
  z-index: 1;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 20px;
}

/* Background Images*/
.section--hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  background-image: url(./Image2.jpg);
}

.section--chapter {
  background-image: url(./Image3.jpg);
}

.section--themes {
  background-image: url(./Image2.jpg);
}

.section--sanskrit {
  background-image: url(./Image1.jpg);
}

.section--daily {
  background-image: url(./Image4.jpg);
}

.section--footer {
  background-image: url(./Image3.jpg);
}

/* Footer overlay a bit darker for contrast */
.section--footer::before {
  background: linear-gradient(
    135deg,
    rgba(217, 119, 6, 0.9),
    rgba(234, 88, 12, 0.9)
  );
  backdrop-filter: blur(0);
}

/* -----------------------------
   HERO
----------------------------- */
.hero-inner {
  width: 100%;
}

.hero-title-block {
  text-align: center;
  max-width: 720px;
  margin: 0 auto;
}

.hero-eyebrow {
  font-family: "Montserrat", sans-serif;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  font-weight: 300;
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-bottom: 0.9rem;
}

.gita-title {
  font-size: clamp(2.8rem, 6vw, 4.8rem);
  letter-spacing: 0.02em;
  color: var(--text-primary);
  margin-bottom: 0.9rem;
}

.hero-subtitle {
  font-family: "Montserrat", sans-serif;
  font-weight: 100;
  font-size: clamp(1.1rem, 2.4vw, 1.6rem);
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--text-secondary);
  margin-bottom: 1.3rem;
}

.hero-accent {
  width: 64px;
  height: 2px;
  margin: 0 auto 1.3rem;
  background: var(--accent);
  border-radius: var(--radius-pill);
}

.hero-tagline {
  font-weight: 300;
  font-size: 0.98rem;
  color: var(--text-secondary);
}

/* -----------------------------
   SECTION HEADER
----------------------------- */
.section-header {
  text-align: center;
  margin-bottom: 32px;
}

.section-title {
  font-family: "Montserrat", sans-serif;
  font-weight: 300;
  font-size: 1.9rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 8px;
}

.section-subtitle {
  font-weight: 300;
  font-size: 0.98rem;
  color: var(--text-secondary);
}

/* -----------------------------
   CARDS
----------------------------- */
.card {
  background: var(--bg-surface);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-soft);
}

.card--soft {
  box-shadow: var(--shadow-soft);
  padding: 1.85rem 2rem;
}

.card-title {
  font-family: "Montserrat", sans-serif;
  font-size: 1.1rem;
  font-weight: 400;
  margin-bottom: 1rem;
  color: var(--text-primary);
}

.card-subtitle {
  font-family: "Montserrat", sans-serif;
  font-size: 0.95rem;
  font-weight: 400;
  margin-bottom: 0.5rem;
  color: var(--text-primary);
}

.card-grid {
  display: grid;
  gap: 18px;
}

@media (min-width: 768px) {
  .card-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

/* -----------------------------
   BODY TEXT UTILITIES
----------------------------- */
.body-text {
  font-size: 0.98rem;
  font-weight: 300;
  color: var(--text-primary);
}

.muted {
  color: var(--text-secondary);
}

/* -----------------------------
   CHAPTER NAV SECTION
----------------------------- */
.chapter-controls {
  max-width: 780px;
  margin: 0 auto 1.8rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  justify-content: center;
}

.chip-select {
  padding: 0.7rem 1.5rem;
  border-radius: var(--radius-pill);
  border: 1px solid var(--accent);
  background: #ffffff;
  color: var(--accent);
  font-family: "Montserrat", sans-serif;
  font-weight: 300;
  font-size: 0.9rem;
  cursor: pointer;
  appearance: none;
  transition: background 0.15s ease-out, color 0.15s ease-out,
    box-shadow 0.15s ease-out, transform 0.1s ease-out;
}

.chip-select:focus {
  outline: none;
  box-shadow: 0 0 0 2px rgba(234, 88, 12, 0.3);
}

.chip-select--button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.chip-select--button:hover {
  background: var(--accent);
  color: #ffffff;
  transform: translateY(-1px);
}

.progress-tracker {
  width: 100%;
  max-width: 640px;
  height: 8px;
  background: rgba(148, 163, 184, 0.25);
  border-radius: 999px;
  margin: 0 auto 24px;
  overflow: hidden;
}

.progress-bar {
  height: 100%;
  width: 4%;
  background: linear-gradient(90deg, var(--accent), var(--accent-strong));
  border-radius: 999px;
  transition: width 0.4s ease-out;
}

.chapter-content {
  max-width: 780px;
  margin: 0 auto;
}

.chapter-title {
  font-family: "Montserrat", sans-serif;
  font-size: 1.15rem;
  font-weight: 400;
  margin-bottom: 0.75rem;
}

.chapter-summary {
  font-size: 0.98rem;
  font-weight: 300;
  color: var(--text-secondary);
}

/* -----------------------------
   THEMES SECTION
----------------------------- */
.theme-filters {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.75rem;
  margin-bottom: 1.8rem;
}

.theme-filter {
  padding: 0.55rem 1.4rem;
  border-radius: var(--radius-pill);
  border: 1px solid #e5e7eb;
  background: #ffffff;
  color: #555;
  font-family: "Montserrat", sans-serif;
  font-weight: 300;
  font-size: 0.88rem;
  cursor: pointer;
  transition: background 0.15s ease-out, color 0.15s ease-out,
    border-color 0.15s ease-out, transform 0.1s ease-out;
}

.theme-filter.active {
  background: var(--accent);
  border-color: var(--accent);
  color: #ffffff;
  transform: translateY(-1px);
}

.theme-shlokas {
  max-width: 960px;
  margin: 0 auto;
}

.theme-shloka {
  background: #fff7df;
  border-radius: 14px;
  padding: 1.25rem 1.5rem;
  margin-bottom: 0.75rem;
  border-left: 4px solid var(--accent);
}

.theme-shloka .shloka-sanskrit {
  font-family: "Tiro Devanagari Hindi", serif;
  font-size: 1.25rem;
  margin-bottom: 0.4rem;
  color: #3f2a10;
}

.theme-shloka .shloka-translation {
  font-size: 0.97rem;
  font-weight: 300;
  color: var(--text-primary);
}

.theme-shloka small {
  display: inline-block;
  margin-top: 0.5rem;
  font-size: 0.85rem;
  color: var(--text-muted);
}

/* -----------------------------
   SANSKRIT TOOLS
----------------------------- */
.word-breakdown {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin: 1rem 0 1.25rem;
}

.sanskrit-word {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.45rem 0.9rem;
  border-radius: 10px;
  background: #fffdf5;
  border: 1px solid #fcdca4;
  font-family: "Tiro Devanagari Hindi", serif;
  font-size: 1.05rem;
  cursor: pointer;
  transition: background 0.15s ease-out, color 0.15s ease-out,
    border-color 0.15s ease-out, transform 0.1s ease-out;
}

.sanskrit-word:hover,
.sanskrit-word.active {
  background: var(--accent);
  color: #ffffff;
  border-color: var(--accent);
  transform: translateY(-1px);
}

.word-meaning {
  font-size: 0.95rem;
}

.audio-controls {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-start;
  gap: 0.75rem;
  margin: 1.5rem 0 1.25rem;
}

.devanagari-practice {
  margin-top: 0.75rem;
}

/* -----------------------------
   BUTTONS
----------------------------- */
.button-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.8rem 1.6rem;
  border-radius: var(--radius-pill);
  border: none;
  background: var(--accent);
  color: #ffffff;
  font-family: "Poppins", sans-serif;
  font-weight: 500;
  font-size: 0.92rem;
  cursor: pointer;
  box-shadow: 0 12px 20px rgba(217, 119, 6, 0.35);
  transition: background 0.15s ease-out, transform 0.1s ease-out,
    box-shadow 0.15s ease-out;
}

.button-primary:hover {
  background: var(--accent-strong);
  transform: translateY(-1px);
  box-shadow: 0 16px 26px rgba(234, 88, 12, 0.4);
}

.button-primary:active {
  transform: translateY(0);
  box-shadow: 0 10px 18px rgba(234, 88, 12, 0.35);
}

.button-primary:disabled {
  opacity: 0.7;
  cursor: default;
  transform: none;
  box-shadow: 0 8px 16px rgba(217, 119, 6, 0.3);
}

.button-primary--ghost {
  background: #ffffff;
  color: var(--accent);
  box-shadow: 0 8px 16px rgba(15, 23, 42, 0.04);
}

.button-primary--ghost:hover {
  background: #fff7eb;
}

/* -----------------------------
   DAILY SHLOKA
----------------------------- */
.daily-shloka-inner {
  max-width: 780px;
  margin: 0 auto;
}

.shloka-card {
  margin-bottom: 1.5rem;
}

.shloka-meta {
  font-size: 0.85rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: var(--text-secondary);
  margin-bottom: 0.9rem;
}

.shloka-sanskrit {
  font-size: 1.45rem;
  line-height: 1.9;
  margin-bottom: 0.9rem;
  color: var(--text-primary);
}

.shloka-transliteration {
  font-size: 0.95rem;
  font-weight: 300;
  margin-bottom: 0.9rem;
  color: var(--text-secondary);
}

.shloka-translation {
  font-size: 0.98rem;
  font-weight: 300;
  margin-bottom: 1rem;
}

.shloka-footer {
  display: flex;
  justify-content: flex-end;
}

.shloka-author {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: var(--text-secondary);
}

.shloka-controls {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.45rem;
}

.loader {
  min-height: 1.2em;
  font-size: 0.85rem;
  color: var(--text-secondary);
}

.error-message {
  min-height: 1.2em;
  font-size: 0.85rem;
  color: #b91c1c;
}

/* -----------------------------
   FOOTER
----------------------------- */
.footer-inner {
  text-align: center;
}

.footer-title {
  font-size: 1.25rem;
  font-weight: 400;
  color: #ffffff;
  margin-bottom: 0.6rem;
}

.footer-subtitle {
  font-size: 0.95rem;
  font-weight: 300;
  color: rgba(255, 255, 255, 0.9);
  margin-bottom: 1.4rem;
}

.footer-credits {
  font-size: 0.85rem;
  font-weight: 300;
  color: rgba(255, 255, 255, 0.88);
}

.footer-highlight {
  font-weight: 500;
}

/* -----------------------------
   UTILITIES
----------------------------- */
.hidden {
  opacity: 0;
  pointer-events: none;
  visibility: hidden;
}

/* -----------------------------
   RESPONSIVE
----------------------------- */
@media (max-width: 768px) {
  .section {
    padding: var(--section-padding-mobile) 0;
  }

  .card--soft {
    padding: 1.5rem 1.4rem;
  }

  .section-title {
    font-size: 1.6rem;
  }

  .hero-title-block {
    padding-top: 32px;
  }
}
