/* =================================================================
   QUIZ HUB PAGE (qh- prefix)
   File: quiz/index.html
   Single premium violet theme for cards (distinct from the hero's
   blue-indigo gradient), gold CTA button, chip-style topics.
   ================================================================= */

:root {
  --qh-hero-1: #1a2472;
  --qh-hero-2: #312e81;
  --qh-hero-3: #4338ca;

  --qh-ink:       #1a1330;
  --qh-body-grey: #6b6478;
}

.qh-page-body {
  background: var(--quiz-light);
}

/* ---------- LANGUAGE TOGGLE CONTENT SWITCHING ---------- */
body.lang-en .qh-txt-ta { display: none !important; }
body.lang-ta .qh-txt-en { display: none !important; }

/* ---------- HERO (English, fixed) ---------- */
.qh-hero {
  background: linear-gradient(135deg, var(--qh-hero-1) 0%, var(--qh-hero-2) 55%, var(--qh-hero-3) 100%);
  padding: 24px 20px 22px;
  text-align: center;
}

.qh-hero-inner {
  max-width: 540px;
  margin: 0 auto;
}

.qh-hero h1 {
  font-family: 'Manrope', sans-serif;
  font-weight: 800;
  color: var(--quiz-white);
  font-size: clamp(26px, 8vw, 38px);
  line-height: 1.15;
  letter-spacing: -0.3px;
  margin: 0 0 10px;
}

.qh-hero p {
  font-family: 'Manrope', sans-serif;
  font-weight: 500;
  color: rgba(255,255,255,0.9);
  font-size: clamp(13.5px, 3.3vw, 15.5px);
  line-height: 1.55;
  max-width: 36ch;
  margin: 0 auto;
}

/* ---------- LANGUAGE TOGGLE (below hero) ---------- */
.qh-lang-bar {
  background: var(--quiz-white);
  padding: 12px 16px;
  display: flex;
  justify-content: center;
}

.qh-lang-toggle {
  display: inline-flex;
  background: var(--quiz-light);
  border: 1px solid #e2e8f0;
  border-radius: 30px;
  padding: 3px;
  gap: 2px;
}

.qh-lang-btn {
  border: none;
  background: transparent;
  font-family: 'Manrope', sans-serif;
  font-size: 13px;
  font-weight: 700;
  color: var(--qh-body-grey);
  padding: 6px 16px;
  border-radius: 24px;
  cursor: pointer;
  transition: background 0.2s, color 0.2s;
}

.qh-lang-btn.qh-active {
  background: linear-gradient(135deg, var(--qh-hero-2), var(--qh-hero-3));
  color: var(--quiz-white);
}

/* ---------- CARD GRID ---------- */
.qh-grid-wrap {
  max-width: 1080px;
  margin: 0 auto;
  padding: 22px 20px 40px;
}

.qh-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 26px;
  align-items: stretch;
}
@media (max-width: 900px) {
  .qh-grid { grid-template-columns: 1fr; max-width: 316px; margin: 0 auto; gap: 34px; }
}

/* ---------- CATEGORY CARD ---------- */
.qh-card {
  background: var(--quiz-white);
  border-radius: 16px;
  box-shadow: 0 8px 22px rgba(26,19,48,0.12);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  border: 1px solid #eef0f6;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.qh-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 18px 34px rgba(26,19,48,0.2);
}

/* Single premium hue, varied only by shade per card position */
.qh-card-head {
  padding: 22px 10px 18px;
  text-align: center;
}
.qh-grid .qh-card:nth-child(1) .qh-card-head { background: #3b0764; }
.qh-grid .qh-card:nth-child(2) .qh-card-head { background: #4c1d95; }
.qh-grid .qh-card:nth-child(3) .qh-card-head { background: #581c87; }

.qh-card-heading-ta {
  font-family: 'Baloo Thambi 2', sans-serif;
  font-weight: 700;
  color: var(--quiz-white);
  font-size: clamp(14px, 5.6vw, 20px);
  white-space: nowrap;
  letter-spacing: -0.2px;
  line-height: 1.3;
  margin: 0 0 9px;
}

.qh-card-heading-en-solo {
  font-family: 'Manrope', sans-serif;
  font-weight: 800;
  color: var(--quiz-white);
  font-size: clamp(15px, 6.6vw, 22px);
  white-space: nowrap;
  letter-spacing: -0.3px;
  line-height: 1.3;
  margin: 0 0 9px;
}

.qh-card-levels-badge {
  font-family: 'Manrope', sans-serif;
  font-weight: 700;
  font-size: 12px;
  color: var(--quiz-white);
  background: rgba(255,255,255,0.2);
  border-radius: 20px;
  padding: 4px 13px;
  display: inline-block;
}

/* Two-pill row — used on the Astrology Basics card to show level
   count and total question count side by side. */
.qh-card-badges {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 8px;
}

/* ---------- CARD BODY (white) ---------- */
.qh-card-body {
  padding: 18px 18px 20px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.qh-card-desc {
  font-family: 'Catamaran', sans-serif;
  font-weight: 500;
  font-size: 14.5px;
  color: var(--qh-body-grey);
  line-height: 1.7;
  text-align: center;
  margin: 0 0 20px;
  flex-grow: 1;
}

/* ---------- BUTTON ---------- */
.qh-card-cta {
  display: inline-block;
  align-self: center;
  text-align: center;
  font-family: 'Manrope', sans-serif;
  font-weight: 800;
  font-size: 14.5px;
  letter-spacing: 0.2px;
  border-radius: 50px;
  padding: 12px 34px;
  text-decoration: none;
  color: var(--quiz-navy);
  background: linear-gradient(135deg, var(--quiz-gold) 0%, var(--quiz-gold2) 100%);
  transition: opacity 0.2s, transform 0.15s, box-shadow 0.2s;
  margin-top: auto;
  box-shadow: 0 6px 16px rgba(201,168,76,0.4);
}

.qh-card-cta:hover {
  opacity: 0.94;
  transform: translateY(-1px);
  box-shadow: 0 8px 20px rgba(201,168,76,0.5);
}

.qh-card-cta:active {
  transform: scale(0.96);
}

/* Coming-soon state, kept for future levels/categories */
.qh-card[data-status="coming-soon"] .qh-card-cta {
  background: #e2e5eb;
  color: #8b95a3;
  cursor: default;
  pointer-events: none;
  box-shadow: none;
}
