/* Bhagavad Gita Cards — blue / gold / ivory; lll-* hooks */

.gita-cards-page {
  margin: 0;
  min-height: 100vh;
  font-family: Georgia, "Times New Roman", serif;
  background: linear-gradient(168deg, #faf8f2 0%, #f0ebe0 42%, #e6dfd0 100%);
  color: #1a2438;
}

.gita-hero {
  padding: 1.75rem 1.25rem 1.5rem;
  text-align: center;
  background: radial-gradient(ellipse 120% 85% at 50% 0%, #1e4a7a 0%, #153a62 48%, #0c2848 100%);
  color: #faf8f2;
  border-bottom: 4px solid #c9a227;
}

.gita-eyebrow {
  margin: 0 0 0.35rem;
  font-size: 0.78rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  opacity: 0.88;
}

.gita-hero h1 {
  margin: 0 0 0.5rem;
  font-size: clamp(1.65rem, 3.8vw, 2.3rem);
  font-weight: 600;
  letter-spacing: 0.02em;
}

.gita-subtitle {
  margin: 0 auto 1rem;
  max-width: 40rem;
  font-size: 1.05rem;
  line-height: 1.45;
  opacity: 0.93;
}

.gita-hero-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 0.5rem;
  justify-content: center;
  font-size: 0.92rem;
}

.gita-hero-links a {
  color: #e8d4a0;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.gita-hero-links a:hover,
.gita-hero-links a:focus {
  color: #fff;
}

.gita-hero-links__sep {
  opacity: 0.5;
}

.gita-main {
  max-width: 72rem;
  margin: 0 auto;
  padding: 1.25rem 1rem 3rem;
}

.gita-loading,
.gita-error {
  text-align: center;
  padding: 2rem 1rem;
  font-size: 1.05rem;
}

.gita-error {
  color: #7a1e2e;
}

.gita-error a {
  color: #1e4a7a;
  font-weight: 600;
}

.gita-controls {
  margin-bottom: 1.25rem;
}

.gita-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1rem;
  align-items: flex-end;
  margin-bottom: 0.75rem;
}

.gita-search-label {
  flex: 1 1 14rem;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  font-size: 0.85rem;
  font-weight: 600;
  color: #1a3a5c;
}

.gita-search {
  padding: 0.55rem 0.75rem;
  border: 1px solid #b8c4d4;
  border-radius: 8px;
  font-size: 1rem;
  background: #fffef9;
  color: #1a2438;
}

.gita-search:focus {
  outline: 2px solid #1e4a7a;
  outline-offset: 1px;
}

.gita-toolbar__actions {
  flex: 0 0 auto;
}

.gita-btn {
  cursor: pointer;
  border-radius: 8px;
  padding: 0.55rem 1rem;
  font-size: 0.95rem;
  font-weight: 600;
  border: 1px solid #1e4a7a;
  background: #fffef9;
  color: #0c2848;
}

.gita-btn:hover,
.gita-btn:focus {
  background: #e8eef6;
}

.gita-btn--accent {
  background: linear-gradient(180deg, #2a5f9a 0%, #1e4a7a 100%);
  color: #faf8f2;
  border-color: #0c2848;
}

.gita-btn--accent:hover,
.gita-btn--accent:focus {
  filter: brightness(1.06);
}

.gita-btn--ghost {
  border-color: #9a8b6a;
  background: transparent;
}

.gita-count {
  margin: 0 0 0.75rem;
  font-size: 0.95rem;
  color: #3a4a5c;
}

.gita-filter-row {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.gita-chapter-bar,
.gita-theme-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.gita-chip {
  cursor: pointer;
  border: 1px solid #c4b896;
  background: #fffef9;
  color: #1a2438;
  padding: 0.32rem 0.7rem;
  border-radius: 999px;
  font-size: 0.8rem;
  font-weight: 600;
}

.gita-chip--chapter {
  font-size: 0.78rem;
}

.gita-chip:hover,
.gita-chip:focus {
  border-color: #1e4a7a;
}

.gita-chip--active {
  background: #1e4a7a;
  color: #faf8f2;
  border-color: #0c2848;
}

.gita-empty {
  margin: 1rem 0;
  padding: 1rem 1.25rem;
  border-radius: 10px;
  border: 1px dashed #b8a888;
  background: rgba(255, 254, 249, 0.8);
  color: #3a4a5c;
}

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

.gita-card {
  border-radius: 12px;
  border: 1px solid #d4c8b0;
  background: #fffef9;
  box-shadow: 0 4px 14px rgba(12, 40, 72, 0.08);
  padding: 1.1rem 1.15rem 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.gita-card__title {
  margin: 0;
  font-size: 1.1rem;
  color: #0c2848;
  line-height: 1.3;
}

.gita-card__chapter {
  margin: 0;
  font-size: 0.88rem;
  font-style: italic;
  color: #4a5a6c;
}

.gita-card__ref {
  margin: 0;
  font-size: 0.75rem;
  letter-spacing: 0.04em;
  color: #6a7a8c;
  font-family: system-ui, sans-serif;
}

.gita-card__verse {
  font-size: 1.2rem;
  line-height: 1.65;
  color: #1a1424;
  padding: 0.75rem 0.6rem;
  border-left: 3px solid #c9a227;
  background: linear-gradient(90deg, rgba(201, 162, 39, 0.12) 0%, transparent 100%);
  white-space: pre-wrap;
  font-family: "Noto Sans Devanagari", "Devanagari MT", "Mangal", Georgia, serif;
}

.gita-card__block {
  margin: 0;
  font-size: 0.92rem;
  line-height: 1.55;
  color: #2a3a4c;
}

.gita-card__label {
  display: block;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #5a6a7c;
  margin-bottom: 0.2rem;
}

.gita-card__meta {
  margin-top: auto;
  padding-top: 0.5rem;
  font-size: 0.7rem;
  color: #7a8a9c;
}

.gita-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
}

.gita-badge {
  display: inline-block;
  padding: 0.2rem 0.5rem;
  border-radius: 6px;
  font-size: 0.72rem;
  font-weight: 600;
  background: #e8eef6;
  color: #1e4a7a;
  border: 1px solid #b8c8dc;
}

.gita-badge--primary {
  background: #1e4a7a;
  color: #faf8f2;
  border-color: #0c2848;
}

.gita-load-wrap {
  text-align: center;
  margin-top: 1.5rem;
}

.gita-modal {
  position: fixed;
  inset: 0;
  z-index: 80;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}

.gita-modal[hidden] {
  display: none;
}

.gita-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(12, 40, 72, 0.55);
}

.gita-modal__panel {
  position: relative;
  z-index: 1;
  max-width: 38rem;
  width: 100%;
  max-height: 90vh;
  overflow: auto;
  background: #fffef9;
  border-radius: 12px;
  border: 1px solid #d4c8b0;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.2);
}

.gita-modal__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.75rem 1rem;
  border-bottom: 1px solid #ddd4c8;
  background: #1e4a7a;
  color: #faf8f2;
}

.gita-modal__head h2 {
  margin: 0;
  font-size: 1rem;
}

.gita-modal__close {
  border: none;
  background: transparent;
  color: #faf8f2;
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
  padding: 0.15rem 0.4rem;
}

.gita-modal__body {
  padding: 1rem;
}

@media (max-width: 540px) {
  .gita-chapter-bar {
    max-height: 8rem;
    overflow-y: auto;
  }
}
