/*
Theme Name: Quiz Test
Theme URI: https://freshgovtexam.com/
Description: An extremely premium, modern, and professional child theme for GeneratePress that copies the layout and quiz engine of currentaffairsquiz.in with high-quality visual aesthetics, micro-animations, and custom typography.
Author: Fresh Govt Exam
Author URI: https://freshgovtexam.com/
Template: generatepress
Version: 1.1.0
*/

/* ============================================================
   style.css — Current Affairs Quiz | currentaffairsquiz.in
   Mobile-First, SEO-Optimized, Premium Design System
   ============================================================ */

/* ---- Variables (Curated Harmonious Color Palette) ---- */
:root {
  --primary:    #4f46e5; /* Indigo */
  --primary-l:  #6366f1; /* Light Indigo */
  --primary-d:  #0f172a; /* Slate Dark / Dark Navy */
  --daily:      #059669; /* Emerald Green */
  --weekly:     #7c3aed; /* Modern Violet */
  --monthly:    #f43f5e; /* Rose Red */
  --accent:     #f59e0b; /* Amber Gold */
  --bg:         #f8fafc; /* Very soft Slate background */
  --card:       #ffffff; /* Card background */
  --border:     #e2e8f0; /* Soft border */
  --text:       #0f172a; /* Deep Slate Black for readability */
  --text-m:     #475569; /* Medium Slate */
  --text-l:     #94a3b8; /* Light Slate */
  --radius:     16px;    /* Rounded corners */
  --radius-s:   10px;    /* Slightly rounder buttons */
  --shadow:     0 4px 6px -1px rgba(15, 23, 42, 0.05), 0 2px 4px -2px rgba(15, 23, 42, 0.05);
  --shadow-h:   0 20px 25px -5px rgba(79, 70, 229, 0.1), 0 8px 10px -6px rgba(79, 70, 229, 0.05);
  --font:       'Inter', system-ui, -apple-system, sans-serif;
  --transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ---- Reset & Base Elements ---- */
body.quiz-theme-active {
  font-family: var(--font);
  color: var(--text);
  background: var(--bg);
  line-height: 1.6;
  font-size: 15px;
}
.quiz-theme-active img {
  max-width: 100%;
  height: auto;
  display: block;
  border-radius: var(--radius-s);
}
.quiz-theme-active a {
  color: var(--primary);
  text-decoration: none;
  transition: var(--transition);
}
.quiz-theme-active a:hover {
  color: var(--primary-l);
}
/* Ensure play buttons inside quiz cards always keep white text */
.quiz-card a.btn-play {
  color: #ffffff !important;
  text-decoration: none;
}
.quiz-card a.btn-play:hover {
  color: #ffffff !important;
  text-decoration: none;
}
.quiz-theme-active ul {
  list-style: none;
  margin: 0;
  padding: 0;
}
.quiz-theme-active input, 
.quiz-theme-active button, 
.quiz-theme-active select, 
.quiz-theme-active textarea {
  font-family: var(--font);
}

/* ---- Layout ---- */
.quiz-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 10px;
}
.layout-main {
  display: flex;
  gap: 32px;
  padding: 32px 0;
}
.content-area {
  flex: 1;
  min-width: 0;
}
.sidebar {
  width: 320px;
  flex-shrink: 0;
}
@media(max-width:960px){
  .layout-main {
    flex-direction: column;
    padding: 20px 0;
  }
  .sidebar {
    width: 100%;
  }
}

/* ---- Header / Navbar ---- */
.site-header {
  background: #ffffff !important;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
  position: sticky;
  top: 0;
  z-index: 100;
  border-bottom: 1px solid var(--border);
}
.navbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
  gap: 16px;
}
.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 20px;
  font-weight: 800;
  letter-spacing: -0.5px;
}
.logo img {
  height: 38px;
  width: auto;
}
.logo-text {
  color: #0f172a;
  font-weight: 800;
  font-size: 21px;
  letter-spacing: -0.75px;
  display: flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
}
.nav-menu ul {
  display: flex;
  align-items: center;
  gap: 8px;
}
.nav-menu a {
  color: #334155;
  padding: 8px 16px;
  border-radius: var(--radius-s);
  font-size: 14px;
  font-weight: 600;
  transition: var(--transition);
}
.nav-menu a:hover:not(.active) {
  color: var(--primary);
  background: rgba(99, 102, 241, 0.05);
}
.nav-menu a.active {
  color: #fff;
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-l) 100%);
  box-shadow: 0 4px 12px rgba(79, 70, 229, 0.2);
}
.nav-toggle,
.nav-toggle:focus,
.nav-toggle:active,
.nav-toggle:hover,
.nav-toggle.open {
  display: none;
  background: transparent !important;
  border: none !important;
  cursor: pointer;
  padding: 8px;
  flex-direction: column;
  gap: 5px;
  outline: none !important;
  box-shadow: none !important;
  -webkit-tap-highlight-color: transparent !important;
}
.nav-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  background: #0f172a;
  border-radius: 2px;
  transition: var(--transition);
}
.nav-toggle.open span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}
.nav-toggle.open span:nth-child(2) {
  opacity: 0;
}
.nav-toggle.open span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}
@media(max-width:768px){
  .nav-toggle,
  .nav-toggle:focus,
  .nav-toggle:active,
  .nav-toggle:hover,
  .nav-toggle.open {
    display: flex !important;
  }
  .nav-menu {
    display: none;
    position: absolute;
    top: 64px;
    left: 0;
    right: 0;
    background: #ffffff !important;
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    padding: 20px;
    box-shadow: 0 10px 30px rgba(15, 23, 42, 0.1);
    border-bottom: 1px solid var(--border);
    animation: slideDown 0.3s cubic-bezier(0.4, 0, 0.2, 1) forwards;
  }
  @keyframes slideDown {
    from {
      opacity: 0;
      transform: translateY(-10px);
    }
    to {
      opacity: 1;
      transform: translateY(0);
    }
  }
  .nav-menu.open {
    display: block;
  }
  .nav-menu ul {
    flex-direction: column;
    gap: 4px;
    align-items: stretch;
  }
  .nav-menu a {
    display: block;
    padding: 12px 16px;
  }
}

/* ---- Hero (Homepage - Glassmorphism Mesh) ---- */
.hero {
  background: radial-gradient(circle at 80% 20%, var(--primary) 0%, var(--primary-d) 100%);
  color: #fff;
  padding: 60px 0 48px;
  text-align: center;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}
.hero h1 {
  font-size: clamp(28px, 6vw, 44px);
  font-weight: 800;
  line-height: 1.15;
  margin-bottom: 12px;
  color: #fff;
  letter-spacing: -1px;
}
.hero p {
  font-size: clamp(15px, 3vw, 19px);
  opacity: .85;
  max-width: 600px;
  margin: 0 auto 32px;
  color: rgba(255, 255, 255, 0.9);
}
.hero-tabs {
  display: flex;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
}
.htab {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  background: rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: var(--radius);
  padding: 16px 28px;
  color: #fff;
  font-weight: 700;
  font-size: 14px;
  cursor: pointer;
  text-decoration: none;
  transition: var(--transition);
  min-width: 130px;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
}
.htab span.emoji {
  font-size: 32px;
  transition: var(--transition);
}
.htab.daily { border-color: rgba(16, 185, 129, 0.3); }
.htab.weekly { border-color: rgba(124, 92, 246, 0.3); }
.htab.monthly { border-color: rgba(244, 63, 94, 0.3); }

.htab:hover {
  background: rgba(255, 255, 255, 0.15);
  transform: translateY(-4px);
  box-shadow: 0 10px 20px rgba(0,0,0,0.15);
  border-color: rgba(255, 255, 255, 0.35);
  color: #fff;
}
.htab:hover span.emoji {
  transform: scale(1.15) rotate(5deg);
}

/* ---- Section Headers ---- */
.section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
  padding-bottom: 12px;
  border-bottom: 2px solid var(--border);
}
.section-head h2 {
  font-size: 22px;
  font-weight: 800;
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0;
  color: var(--primary-d);
  letter-spacing: -0.5px;
}
.section-head h2 .badge {
  font-size: 11px;
  background: var(--primary);
  color: #fff;
  padding: 3px 10px;
  border-radius: 20px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.section-head h2.daily-head .badge { background: var(--daily); }
.section-head h2.weekly-head .badge { background: var(--weekly); }
.section-head h2.monthly-head .badge { background: var(--monthly); }
.see-all {
  font-size: 13px;
  font-weight: 700;
  color: var(--primary);
  white-space: nowrap;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}
.see-all:hover {
  color: var(--primary-l);
  transform: translateX(3px);
}

/* ---- Quiz Cards ---- */
.quiz-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 20px;
}
@media(max-width:640px) {
  .quiz-grid {
    grid-template-columns: 1fr;
  }
}
.quiz-card {
  background: var(--card);
  border-radius: var(--radius);
  box-shadow: 0 2px 4px rgba(15, 23, 42, 0.02), 0 1px 2px rgba(15, 23, 42, 0.03);
  overflow: hidden;
  transition: border-color 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
  border: 1px solid rgba(226, 232, 240, 0.8);
  display: flex;
  flex-direction: column;
}
.quiz-card:hover {
  transform: translateY(-4px);
}
.quiz-card:hover.daily { 
  border-color: var(--daily); 
  box-shadow: 0 12px 25px -5px rgba(5, 150, 105, 0.15), 0 8px 10px -6px rgba(5, 150, 105, 0.08);
}
.quiz-card:hover.weekly { 
  border-color: var(--weekly); 
  box-shadow: 0 12px 25px -5px rgba(124, 92, 246, 0.15), 0 8px 10px -6px rgba(124, 92, 246, 0.08);
}
.quiz-card:hover.monthly { 
  border-color: var(--monthly); 
  box-shadow: 0 12px 25px -5px rgba(244, 63, 94, 0.15), 0 8px 10px -6px rgba(244, 63, 94, 0.08);
}

.quiz-card-thumb {
  aspect-ratio: 1200/630;
  background: linear-gradient(135deg, #f8fafc, #f1f5f9);
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  border-bottom: 1px solid rgba(226, 232, 240, 0.5);
}
.quiz-card-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  position: absolute;
  inset: 0;
  transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  border-radius: 0;
}
.quiz-card:hover .quiz-card-thumb img {
  transform: scale(1.04);
}
.quiz-card-thumb-placeholder {
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-l) 100%);
  display: flex;
  align-items: center;
  justify-content: center;
}
.quiz-card-thumb-placeholder::after {
  content: 'QUIZ';
  color: rgba(255, 255, 255, 0.25);
  font-size: 20px;
  font-weight: 800;
  letter-spacing: 6px;
}
.qtype-badge {
  position: absolute;
  top: 12px;
  left: 12px;
  font-size: 10px;
  font-weight: 800;
  padding: 4px 10px;
  border-radius: 20px;
  text-transform: uppercase;
  letter-spacing: 0.75px;
  z-index: 2;
  border: 1px solid rgba(255, 255, 255, 0.25);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.08);
}
.qtype-daily { 
  background: rgba(5, 150, 105, 0.85); 
  color: #fff; 
}
.qtype-weekly { 
  background: rgba(124, 92, 246, 0.85); 
  color: #fff; 
}
.qtype-monthly { 
  background: rgba(244, 63, 94, 0.85); 
  color: #fff; 
}

.quiz-card-body {
  padding: 20px;
  flex: 1;
  display: flex;
  flex-direction: column;
}
.quiz-card-body h3, 
.quiz-card-body h2 {
  font-size: 16px;
  font-weight: 700;
  line-height: 1.45;
  margin: 0 0 12px;
  color: var(--primary-d);
  letter-spacing: -0.25px;
}
.quiz-card-body h3 a, 
.quiz-card-body h2 a {
  color: var(--primary-d);
}
.quiz-card-body h3 a:hover, 
.quiz-card-body h2 a:hover {
  color: var(--primary);
}
.quiz-meta {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 11px;
  color: var(--text-m);
  flex-wrap: wrap;
  margin-bottom: 16px;
  letter-spacing: 0.25px;
}
.quiz-meta span {
  display: flex;
  align-items: center;
  gap: 4px;
  font-weight: 600;
}
.quiz-card-footer {
  margin-top: auto;
  padding-top: 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.btn-play {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--primary);
  color: #fff;
  padding: 8px 20px;
  border-radius: 30px;
  font-size: 12px;
  font-weight: 700;
  transition: var(--transition);
  border: none;
  cursor: pointer;
}
.btn-play:hover {
  opacity: 0.95;
  color: #fff;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(79, 70, 229, 0.2);
}
.btn-play.daily { background: var(--daily); }
.btn-play.daily:hover { box-shadow: 0 4px 12px rgba(5, 150, 105, 0.2); }
.btn-play.weekly { background: var(--weekly); }
.btn-play.weekly:hover { box-shadow: 0 4px 12px rgba(124, 92, 246, 0.2); }
.btn-play.monthly { background: var(--monthly); }
.btn-play.monthly:hover { box-shadow: 0 4px 12px rgba(244, 63, 94, 0.2); }
.quiz-q-count {
  font-size: 12px;
  color: var(--text-l);
  font-weight: 600;
}

/* ---- Category Pills ---- */
.cat-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 28px;
}
.cat-pill {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 30px;
  padding: 8px 18px;
  font-size: 13px;
  font-weight: 600;
  transition: var(--transition);
  color: var(--text-m);
  box-shadow: var(--shadow);
  flex-shrink: 0;
}
@media(max-width: 768px) {
  .cat-grid {
    flex-wrap: nowrap;
    overflow-x: auto;
    padding-bottom: 12px;
    margin-bottom: 20px;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }
  .cat-grid::-webkit-scrollbar {
    display: none;
  }
}
.cat-pill:hover {
  border-color: var(--primary);
  color: var(--primary);
  background: #f5f3ff;
  transform: translateY(-2px);
  box-shadow: 0 6px 12px rgba(79, 70, 229, 0.08);
}
.cat-pill .cnt {
  background: rgba(79, 70, 229, 0.1);
  color: var(--primary);
  font-size: 11px;
  padding: 2px 8px;
  border-radius: 20px;
  font-weight: 700;
}

.breadcrumb {
  display: none !important;
}
.breadcrumb a {
  color: var(--text-m);
  text-decoration: none;
  transition: var(--transition);
}
.breadcrumb a:hover {
  color: var(--primary);
}
.breadcrumb span {
  color: var(--text-l);
  display: inline-flex;
  align-items: center;
  font-weight: 700;
}
.breadcrumb span:last-child {
  color: var(--primary);
  font-weight: 700;
}

/* ---- Quiz Detail Page / Header ---- */
.quiz-header {
  background: var(--card);
  border-radius: var(--radius);
  padding: 28px;
  box-shadow: var(--shadow);
  margin-top: 10px;
  margin-bottom: 24px;
  border: 1px solid var(--border);
}
.quiz-header h1 {
  font-size: clamp(20px, 4vw, 28px);
  font-weight: 800;
  margin: 0 0 14px;
  color: var(--primary-d);
  letter-spacing: -0.75px;
  line-height: 1.3;
}
.quiz-info-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  font-size: 13px;
  color: var(--text-m);
  margin-bottom: 20px;
  font-weight: 600;
}
.quiz-info-bar span {
  display: flex;
  align-items: center;
  gap: 5px;
  background: var(--bg);
  padding: 6px 14px;
  border-radius: 30px;
  border: 1px solid rgba(15, 23, 42, 0.03);
}
.quiz-desc {
  color: var(--text-m);
  font-size: 15px;
  line-height: 1.75;
}

/* ---- Quiz Engine ---- */
.quiz-engine {
  background: var(--card);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
  border: 1px solid var(--border);
  margin-top: 24px;
}
.quiz-progress-bar {
  height: 6px;
  background: var(--border);
}
.quiz-progress-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--primary), var(--primary-l));
  transition: width .4s cubic-bezier(0.4, 0, 0.2, 1);
  width: 0%;
}
.quiz-top-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 24px;
  background: var(--bg);
  border-bottom: 1px solid var(--border);
}
.q-counter {
  font-size: 13px;
  font-weight: 800;
  color: var(--primary-d);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.q-timer {
  font-size: 14px;
  font-weight: 800;
  color: var(--primary);
  display: flex;
  align-items: center;
  gap: 6px;
  background: #fff;
  padding: 4px 12px;
  border-radius: 20px;
  border: 1px solid var(--border);
  box-shadow: 0 2px 4px rgba(0,0,0,0.02);
}
.q-timer.warn {
  color: var(--monthly);
  border-color: rgba(244, 63, 94, 0.3);
  background: #fff5f5;
  animation: pulse 1s infinite;
}
@keyframes pulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.05); }
}
.question-body {
  padding: 16px 20px;
}
.q-text {
  font-size: clamp(15px, 2.5vw, 18px);
  font-weight: 800;
  margin-bottom: 16px;
  line-height: 1.5;
  color: var(--primary-d);
  letter-spacing: -0.5px;
}
.options-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.option-btn {
  display: flex;
  align-items: center;
  gap: 16px;
  background: var(--bg);
  border: 2px solid var(--border);
  border-radius: var(--radius-s);
  padding: 12px 18px;
  cursor: pointer;
  font-size: 14.5px;
  font-weight: 600;
  text-align: left;
  transition: var(--transition);
  width: 100%;
  color: var(--text-m);
  -webkit-tap-highlight-color: transparent;
}
.option-btn:hover:not(:disabled) {
  border-color: var(--primary);
  background: #f5f3ff;
  color: var(--primary);
}
.option-btn .opt-label {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: #fff;
  border: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 12.5px;
  flex-shrink: 0;
  min-width: 28px;
  color: var(--text-m);
  transition: var(--transition);
}
.option-btn:hover:not(:disabled) .opt-label {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
}
.option-btn.correct {
  border-color: var(--daily);
  background: #f0fdf4;
  color: #065f46;
}
.option-btn.correct .opt-label {
  background: var(--daily);
  color: #fff;
  border-color: var(--daily);
}
.option-btn.wrong {
  border-color: var(--monthly);
  background: #fff5f5;
  color: #991b1b;
}
.option-btn.wrong .opt-label {
  background: var(--monthly);
  color: #fff;
  border-color: var(--monthly);
}
.option-btn:disabled {
  cursor: not-allowed !important;
  pointer-events: none !important;
}
.explanation-box {
  background: #fffbeb;
  border-left: 4px solid var(--accent);
  padding: 16px 20px;
  border-radius: 0 var(--radius-s) var(--radius-s) 0;
  font-size: 14px;
  color: var(--text-m);
  margin-top: 20px;
  display: none;
  line-height: 1.6;
}
.explanation-box.show {
  display: block;
}
.quiz-nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 28px;
  border-top: 1px solid var(--border);
  background: var(--bg);
}
.btn-next {
  background: var(--primary);
  color: #fff;
  border: none;
  padding: 12px 32px;
  border-radius: var(--radius-s);
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  transition: var(--transition);
}
.btn-next:hover {
  background: var(--primary-l);
  box-shadow: 0 4px 12px rgba(79, 70, 229, 0.2);
}
.btn-next:disabled {
  opacity: .5;
  cursor: default;
  box-shadow: none;
}

/* ---- Result Page ---- */
.result-card {
  background: var(--card);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 20px;
  text-align: center;
  margin-top: 10px !important;
  margin-bottom: 16px;
  border: 1px solid var(--border);
}
.result-emoji {
  font-size: 36px;
  margin-bottom: 8px;
  animation: bounce 2s infinite;
}
@keyframes bounce {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-4px); }
}
.result-score {
  font-size: clamp(32px, 8vw, 44px);
  font-weight: 800;
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-l) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  line-height: 1;
  margin-bottom: 4px;
}
.result-score span {
  font-size: 16px;
  color: var(--text-m);
  font-weight: 600;
  -webkit-text-fill-color: var(--text-m);
}
.result-stats {
  display: flex;
  justify-content: center;
  gap: 10px;
  flex-wrap: wrap;
  margin: 16px 0;
}
.rstat {
  background: var(--bg);
  border-radius: var(--radius-s);
  padding: 8px 12px;
  text-align: center;
  min-width: 80px;
  flex: 1;
  border: 1px solid rgba(15, 23, 42, 0.02);
}
.rstat .rv {
  font-size: 18px;
  font-weight: 800;
  color: var(--primary-d);
}
.rstat .rl {
  font-size: 10px;
  color: var(--text-m);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-top: 2px;
}
.rstat.correct .rv { color: var(--daily); }
.rstat.wrong   .rv { color: var(--monthly); }
.rstat.skip    .rv { color: var(--accent); }
.result-actions {
  display: flex;
  gap: 10px;
  justify-content: center;
  flex-wrap: wrap;
  margin-top: 16px;
}
.result-card .btn-primary,
.result-card .btn-outline {
  padding: 8px 18px !important;
  font-size: 12px !important;
}
.btn-primary {
  background: var(--primary);
  color: #fff !important;
  padding: 12px 28px;
  border-radius: var(--radius-s);
  font-weight: 700;
  font-size: 14px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: var(--transition);
  border: none;
  cursor: pointer;
  text-decoration: none;
}
.btn-primary:hover {
  background: var(--primary-l);
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(79, 70, 229, 0.25);
}
.btn-outline {
  background: #fff;
  color: var(--primary);
  border: 2px solid var(--primary);
  padding: 12px 28px;
  border-radius: var(--radius-s);
  font-weight: 700;
  font-size: 14px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: var(--transition);
  cursor: pointer;
  text-decoration: none;
}
.btn-outline:hover {
  background: #f5f3ff;
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(79, 70, 229, 0.05);
}

/* ---- Leaderboard ---- */
.leaderboard {
  background: var(--card);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
  margin-top: 28px;
  border: 1px solid var(--border);
}
.leaderboard-head {
  background: linear-gradient(90deg, var(--primary-d), var(--primary));
  color: #fff;
  padding: 16px 24px;
  font-weight: 800;
  font-size: 16px;
  letter-spacing: -0.25px;
}
.lb-row {
  display: grid;
  grid-template-columns: 60px 1fr 100px 100px;
  align-items: center;
  padding: 14px 24px;
  border-bottom: 1px solid var(--border);
  font-size: 14px;
  gap: 8px;
  color: var(--text-m);
}
.lb-row:last-child {
  border-bottom: none;
}
.lb-row.header {
  background: var(--bg);
  font-weight: 800;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--text-m);
}
.lb-rank {
  font-weight: 800;
  color: var(--text-l);
  display: flex;
  align-items: center;
}
.lb-rank.gold, 
.lb-rank.silver, 
.lb-rank.bronze {
  font-size: 20px;
}

/* ---- Sidebar Widgets ---- */
.widget {
  background: var(--card);
  border-radius: 12px;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.03);
  overflow: hidden;
  margin-bottom: 24px;
  border: 1px solid var(--border);
  transition: var(--transition);
}
.widget:hover {
  box-shadow: 0 4px 12px rgba(15, 23, 42, 0.05);
}
.widget-title {
  background: rgba(248, 250, 252, 0.5);
  color: var(--text);
  padding: 16px 20px;
  font-weight: 750;
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  border-bottom: 1px solid var(--border);
  border-left: 4px solid var(--primary);
}
.widget-body {
  padding: 14px 16px;
}
.widget-link-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.widget-link-list li {
  padding: 0;
  border: none;
  font-size: 13.5px;
  font-weight: 600;
}
.widget-link-list a {
  color: var(--text-m) !important;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 12px;
  border-radius: 8px;
  text-decoration: none !important;
  transition: all 0.2s ease;
}
.widget-link-list a:hover {
  background: rgba(99, 102, 241, 0.05);
  color: var(--primary) !important;
  transform: translateX(3px);
}
.widget-link-list .cnt {
  font-size: 10.5px;
  padding: 3px 9px;
  border-radius: 30px;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(99, 102, 241, 0.06);
  color: var(--primary);
  border: none;
}
.widget-link-list .cnt.cnt-daily {
  background: rgba(16, 185, 129, 0.08);
  color: #10b981;
}
.widget-link-list .cnt.cnt-weekly {
  background: rgba(124, 58, 237, 0.08);
  color: #7c3aed;
}
.widget-link-list .cnt.cnt-monthly {
  background: rgba(244, 63, 94, 0.08);
  color: #f43f5e;
}

/* ---- Ads (Placeholders & Styling) ---- */
.ad-wrap {
  text-align: center;
  padding: 10px 0;
  overflow: hidden;
}
.ad-wrap ins, 
.ad-wrap iframe, 
.ad-wrap img {
  max-width: 100% !important;
}
.ad-sticky-bottom {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: #fff;
  box-shadow: 0 -4px 15px rgba(0,0,0,0.05);
  text-align: center;
  z-index: 500;
  padding: 8px;
  border-top: 1px solid var(--border);
}
.ad-sidebar {
  margin-bottom: 24px;
}

/* ---- Quiz Category/Type Pages ---- */
.type-hero {
  background: var(--card);
  border: 1px solid var(--border);
  padding: 24px 28px;
  margin-top: 24px;
  margin-bottom: 24px;
  text-align: left;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.02);
}
.type-hero.daily .type-label { color: var(--daily); }
.type-hero.weekly .type-label { color: var(--weekly); }
.type-hero.monthly .type-label { color: var(--monthly); }
.type-label {
  font-size: 24px !important;
  font-weight: 800;
  margin-bottom: 8px;
  margin-top: 0;
  letter-spacing: -0.5px;
  color: var(--text-d);
  line-height: 1.3;
}
.type-desc {
  color: var(--text-m);
  font-size: 13.5px;
  max-width: 100%;
  margin: 0;
  line-height: 1.6;
}

/* ---- Pagination ---- */
.pagination {
  display: flex;
  justify-content: center;
  gap: 8px;
  flex-wrap: wrap;
  margin: 36px 0;
}
.pagination a, 
.pagination span {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: var(--radius-s);
  font-size: 14px;
  font-weight: 700;
  border: 1px solid var(--border);
  color: var(--text-m);
  transition: var(--transition);
  background: #fff;
}
.pagination a:hover {
  background: var(--primary);
  color: #fff !important;
  border-color: var(--primary);
  transform: translateY(-2px);
  box-shadow: 0 4px 10px rgba(79, 70, 229, 0.15);
}
.pagination .current {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
  box-shadow: 0 4px 10px rgba(79, 70, 229, 0.15);
}

/* ---- Share Buttons ---- */
.share-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 20px;
  justify-content: center;
}
.share-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 18px;
  border-radius: var(--radius-s);
  font-size: 12px;
  font-weight: 700;
  color: #fff !important;
  transition: var(--transition);
  text-decoration: none;
  box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}
.share-btn.fb { background: #1877f2; }
.share-btn.tw { background: #000000; }
.share-btn.wa { background: #25d366; }
.share-btn.tg { background: #0088cc; }
.share-btn:hover {
  opacity: .9;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
  color: #fff;
}

/* ---- Name Form / Gate (Start button page) ---- */
.name-gate {
  background: var(--card);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 36px 28px;
  text-align: center;
  max-width: 440px;
  margin: 40px auto;
  border: 1px solid var(--border);
}
.name-gate h2 {
  font-size: 24px;
  font-weight: 800;
  margin: 0 0 8px;
  color: var(--primary-d);
  letter-spacing: -0.5px;
}
.name-gate p {
  color: var(--text-m);
  font-size: 14px;
  margin-bottom: 24px;
  font-weight: 600;
}
.form-group {
  margin-bottom: 16px;
  text-align: left;
}
.form-group label {
  display: block;
  font-size: 13px;
  font-weight: 700;
  margin-bottom: 6px;
  color: var(--primary-d);
}
.form-input {
  width: 100%;
  padding: 12px 16px;
  border: 2px solid var(--border);
  border-radius: var(--radius-s);
  font-size: 14px;
  font-family: var(--font);
  outline: none;
  transition: var(--transition);
  box-sizing: border-box;
}
.form-input:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 4px rgba(79, 70, 229, 0.1);
}

/* ---- Search Form ---- */
.search-form {
  display: flex;
  gap: 0;
  margin-bottom: 24px;
  width: 100%;
  box-shadow: var(--shadow);
  border-radius: var(--radius-s);
  overflow: hidden;
}
.search-input {
  flex: 1;
  padding: 12px 16px;
  border: 2px solid var(--border);
  border-right: none;
  border-radius: var(--radius-s) 0 0 var(--radius-s);
  font-size: 14px;
  font-family: var(--font);
  outline: none;
  box-sizing: border-box;
  transition: var(--transition);
}
.search-input:focus {
  border-color: var(--primary);
}
.search-btn {
  background: var(--primary);
  color: #fff;
  border: none;
  padding: 12px 24px;
  border-radius: 0 var(--radius-s) var(--radius-s) 0;
  cursor: pointer;
  font-size: 16px;
  transition: var(--transition);
}
.search-btn:hover {
  background: var(--primary-l);
}

/* ---- Alerts ---- */
.alert {
  padding: 14px 20px;
  border-radius: var(--radius-s);
  font-size: 14px;
  margin-bottom: 20px;
  font-weight: 600;
}
.alert-success {
  background: #f0fdf4;
  color: #065f46;
  border-left: 4px solid var(--daily);
}
.alert-error {
  background: #fff5f5;
  color: #991b1b;
  border-left: 4px solid var(--monthly);
}

/* ---- Footer ---- */
.site-footer {
  background: #090d16;
  color: rgba(255, 255, 255, 0.7);
  padding: 60px 0 0;
  margin-top: 30px !important;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
}
.site-footer a {
  color: rgba(255, 255, 255, 0.6);
}
.site-footer a:hover {
  color: #fff;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1fr;
  gap: 30px;
  padding-bottom: 40px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}
@media(max-width: 960px) {
  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 30px;
  }
  .footer-col:first-child {
    grid-column: span 2;
  }
}
@media(max-width: 600px) {
  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 24px;
  }
  .footer-col:first-child {
    grid-column: span 2;
  }
}
.footer-col h3 {
  color: #fff;
  font-size: 18px;
  font-weight: 800;
  margin: 0 0 14px;
  letter-spacing: -0.25px;
}
.footer-col h4 {
  color: #fff;
  font-size: 13px;
  font-weight: 800;
  margin: 0 0 14px;
  text-transform: uppercase;
  letter-spacing: 1px;
}
.footer-col p {
  font-size: 14px;
  color: rgba(255, 255, 255, 0.5);
  line-height: 1.8;
  margin-bottom: 16px;
}
.footer-col ul {
  list-style: none;
  padding: 0;
  margin: 0;
}
.footer-col ul li {
  margin-bottom: 8px;
}
.footer-col ul a {
  color: rgba(255, 255, 255, 0.5);
  font-size: 14px;
  transition: var(--transition);
}
.footer-col ul a:hover {
  color: #fff;
  padding-left: 2px;
}
.social-links {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}
.social-links a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  background: rgba(255, 255, 255, 0.06);
  border-radius: 50%;
  font-size: 18px;
  transition: var(--transition);
  color: #fff !important;
}
.social-links a:hover {
  background: var(--primary);
  transform: translateY(-2px);
}
.footer-bottom {
  padding: 24px 0;
  text-align: center;
  font-size: 13px;
  color: rgba(255, 255, 255, 0.4);
}

/* ---- Quiz Q&A Reference (collapsed details block) ---- */
.qa-reference {
  background: var(--card);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  margin-top: 24px;
  padding: 20px 24px;
  border: 1px solid var(--border);
}
.qa-reference summary {
  cursor: pointer;
  font-size: 15px;
  font-weight: 800;
  list-style: none;
  padding: 4px 0;
  color: var(--primary-d);
  display: flex;
  align-items: center;
  gap: 8px;
}
.qa-reference summary::-webkit-details-marker {
  display: none;
}
.qa-reference summary::before {
  content: '▶';
  display: inline-block;
  font-size: 12px;
  transition: transform 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  color: var(--primary);
}
.qa-reference[open] summary::before {
  transform: rotate(90deg);
}
.qa-reference summary:hover {
  color: var(--primary);
}
.qa-reference-body {
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
}
.qa-item {
  margin-bottom: 20px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--border);
}
.qa-item:last-child {
  border-bottom: none;
  margin-bottom: 0;
  padding-bottom: 0;
}
.qa-q {
  font-weight: 800;
  margin-bottom: 10px;
  font-size: 15px;
  color: var(--primary-d);
}
.qa-opt {
  font-size: 13px;
  color: var(--text-m);
  margin: 0 0 5px 20px;
  font-weight: 500;
}
.qa-answer {
  font-size: 14px;
  color: var(--daily);
  font-weight: 700;
  margin: 8px 0 0 20px;
}
.qa-explain {
  font-size: 13px;
  color: var(--text-m);
  margin: 8px 0 0 20px;
  line-height: 1.6;
  background: var(--bg);
  padding: 8px 12px;
  border-radius: var(--radius-s);
  border-left: 3px solid var(--border);
}

/* ---- Author Profile & Biography Card ---- */
.author-bio-card {
  background: var(--card);
  padding: 32px;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  display: flex;
  gap: 24px;
  align-items: center;
  margin: 24px 0 36px;
}
.author-avatar img {
  border-radius: 50%;
  border: 3px solid var(--border);
  box-shadow: var(--shadow);
  transition: transform 0.3s ease;
}
.author-avatar img:hover {
  transform: scale(1.05);
}
@media(max-width: 640px) {
  .author-bio-card {
    flex-direction: column;
    text-align: center;
    padding: 24px;
    gap: 16px;
  }
}

/* ---- WordPress Comments & Form Styling resets ---- */
.comment-respond {
  margin-top: 32px;
}
.comment-reply-title {
  font-size: 18px;
  font-weight: 800;
  color: var(--primary-d);
  letter-spacing: -0.25px;
  margin-bottom: 16px;
}
.comment-form input[type="text"],
.comment-form input[type="email"],
.comment-form textarea {
  width: 100%;
  padding: 12px 16px;
  border: 2px solid var(--border);
  border-radius: var(--radius-s);
  font-size: 14px;
  font-family: var(--font);
  outline: none;
  background: var(--bg);
  box-sizing: border-box;
  transition: var(--transition);
}
.comment-form input[type="text"]:focus,
.comment-form input[type="email"]:focus,
.comment-form textarea:focus {
  border-color: var(--primary);
  background: #fff;
  box-shadow: 0 0 0 4px rgba(79, 70, 229, 0.1);
}
.comment-form .submit {
  background: var(--primary);
  color: #fff;
  border: none;
  padding: 12px 28px;
  border-radius: var(--radius-s);
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  transition: var(--transition);
}
.comment-form .submit:hover {
  background: var(--primary-l);
  box-shadow: 0 4px 12px rgba(79, 70, 229, 0.2);
}
.comment-list {
  list-style: none;
  margin: 24px 0 0;
  padding: 0;
}
.comment-body {
  padding: 20px;
  background: var(--bg);
  border-radius: var(--radius-s);
  border: 1px solid var(--border);
  margin-bottom: 16px;
}
.comment-meta {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 10px;
  font-size: 12px;
  color: var(--text-m);
}
.comment-author cite {
  font-weight: 700;
  font-style: normal;
  color: var(--primary-d);
}

/* ---- Premium Hero Section ---- */
.quiz-theme-active .hero-premium a {
  color: #ffffff !important;
}
.hero-premium {
  background: radial-gradient(circle at 10% 20%, rgba(79, 70, 229, 0.12) 0%, rgba(15, 23, 42, 0) 40%), 
              radial-gradient(circle at 90% 80%, rgba(99, 102, 241, 0.12) 0%, rgba(9, 13, 22, 0) 50%), 
              #0b0f19;
  color: #fff;
  padding: 40px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  position: relative;
  overflow: hidden;
}
.hero-premium::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(99, 102, 241, 0.3), transparent);
}
.hero-grid {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 48px;
  align-items: center;
}
@media(max-width: 960px) {
  .hero-grid {
    grid-template-columns: 1fr;
    gap: 36px;
  }
}
.hero-left {
  text-align: left;
}
.hero-badge {
  display: inline-block;
  background: rgba(99, 102, 241, 0.15);
  border: 1px solid rgba(99, 102, 241, 0.3);
  color: #a5b4fc;
  font-size: 11px;
  font-weight: 800;
  padding: 6px 14px;
  border-radius: 30px;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 16px;
}
.hero-left h1 {
  font-size: clamp(26px, 4.5vw, 36px);
  font-weight: 800;
  line-height: 1.2;
  margin-bottom: 10px;
  color: #fff;
  letter-spacing: -1px;
}
.hero-left h1 .highlight {
  background: linear-gradient(135deg, #818cf8 0%, #c084fc 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}
.hero-left p {
  font-size: 14px;
  color: #94a3b8;
  line-height: 1.5;
  margin-bottom: 18px;
}
.hero-search {
  display: flex;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 40px;
  padding: 5px 5px 5px 16px;
  max-width: 460px;
  align-items: center;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2);
  margin-bottom: 20px;
  transition: var(--transition);
}
.hero-search:focus-within {
  border-color: #818cf8;
  background: rgba(255, 255, 255, 0.12);
  box-shadow: 0 10px 25px rgba(99, 102, 241, 0.2);
}
.hero-search-input,
.quiz-theme-active .hero-premium input.hero-search-input,
.quiz-theme-active .hero-premium input[type="text"].hero-search-input {
  flex: 1;
  background: transparent !important;
  border: none !important;
  box-shadow: none !important;
  outline: none !important;
  color: #ffffff !important;
  font-size: 14px;
  padding: 8px 0;
}
.hero-search-input::placeholder {
  color: #cbd5e1 !important;
  opacity: 0.8;
}
.hero-search-btn {
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-l) 100%);
  color: #fff;
  border: none;
  padding: 10px 24px;
  border-radius: 30px;
  font-weight: 700;
  font-size: 13px;
  cursor: pointer;
  transition: var(--transition);
  box-shadow: 0 4px 12px rgba(79, 70, 229, 0.3);
}
.hero-search-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 16px rgba(79, 70, 229, 0.4);
}
.hero-categories-label {
  font-size: 12px;
  font-weight: 700;
  color: #64748b;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 10px;
}
.hero-tags {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}
.htag-capsule {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 30px;
  padding: 8px 18px;
  font-size: 13px;
  font-weight: 600;
  color: #cbd5e1;
  text-decoration: none;
  transition: var(--transition);
}
.htag-capsule:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #fff !important;
  transform: translateY(-2px);
}
.htag-capsule.daily:hover { border-color: var(--daily); }
.htag-capsule.weekly:hover { border-color: var(--weekly); }
.htag-capsule.monthly:hover { border-color: var(--monthly); }

/* Right Column Spotlight Card */
.hero-right {
  display: flex;
  justify-content: flex-end;
}
@media(max-width: 960px) {
  .hero-right {
    justify-content: flex-start;
  }
}
.spotlight-card {
  background: rgba(255, 255, 255, 0.02);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 16px;
  padding: 20px;
  width: 100%;
  max-width: 380px;
  box-shadow: 0 15px 30px rgba(0, 0, 0, 0.25);
  position: relative;
}
.spotlight-card::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 20px;
  padding: 1px;
  background: linear-gradient(135deg, rgba(255,255,255,0.1), transparent, rgba(99,102,241,0.2));
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  pointer-events: none;
}
.spotlight-head {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 10px;
  font-weight: 800;
  color: #818cf8;
  letter-spacing: 1px;
  margin-bottom: 16px;
}
.pulse-dot {
  width: 6px;
  height: 6px;
  background: #f43f5e;
  border-radius: 50%;
  box-shadow: 0 0 0 0 rgba(244, 63, 94, 0.7);
  animation: pulse-dot 1.5s infinite;
}
@keyframes pulse-dot {
  0% {
    transform: scale(0.95);
    box-shadow: 0 0 0 0 rgba(244, 63, 94, 0.7);
  }
  70% {
    transform: scale(1);
    box-shadow: 0 0 0 6px rgba(244, 63, 94, 0);
  }
  100% {
    transform: scale(0.95);
    box-shadow: 0 0 0 0 rgba(244, 63, 94, 0);
  }
}
.spotlight-card h3 {
  font-size: 18px;
  font-weight: 800;
  margin: 0 0 8px;
  color: #fff;
  line-height: 1.4;
  letter-spacing: -0.25px;
}
.spotlight-card p {
  font-size: 12.5px;
  color: #94a3b8;
  line-height: 1.5;
  margin-bottom: 16px;
}
.spotlight-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.spotlight-stats {
  font-size: 12px;
  color: #64748b;
  font-weight: 600;
}

/* ---- Dark Mode Theme Override ---- */
body.dark-mode {
  --bg:         #090d16;
  --card:       #111827;
  --border:     rgba(255, 255, 255, 0.08);
  --text:       #f3f4f6;
  --text-m:     #9ca3af;
  --text-l:     #6b7280;
}
body.dark-mode .breadcrumb {
  background: #111827;
  border-color: rgba(255, 255, 255, 0.08);
}
body.dark-mode .option-btn {
  background: #111827;
  border-color: rgba(255, 255, 255, 0.08);
}
body.dark-mode .option-btn:hover:not(:disabled) {
  background: #1f2937;
}
body.dark-mode .lb-row.header {
  background: #111827;
  border-bottom-color: rgba(255, 255, 255, 0.08);
}
body.dark-mode .lb-row {
  border-bottom-color: rgba(255, 255, 255, 0.08);
}
body.dark-mode .rstat {
  background: #111827;
}
body.dark-mode .qa-reference {
  background: #111827;
  border-color: rgba(255, 255, 255, 0.08);
}
body.dark-mode .qa-explain {
  background: #111827;
  border-left-color: rgba(255, 255, 255, 0.08);
}
body.dark-mode .widget {
  background: var(--card);
  border-color: var(--border);
}
body.dark-mode .widget-title {
  background: rgba(30, 41, 59, 0.45) !important;
  color: #fff !important;
}
body.dark-mode .widget-link-list a:hover {
  background: rgba(99, 102, 241, 0.12) !important;
}
body.dark-mode .widget-link-list .cnt {
  background: rgba(255, 255, 255, 0.05) !important;
  color: #cbd5e1 !important;
}
body.dark-mode .comments-area-wrap,
body.dark-mode .comment-body,
body.dark-mode .comment-form input[type="text"],
body.dark-mode .comment-form input[type="email"],
body.dark-mode .comment-form textarea {
  background: #111827;
  border-color: rgba(255, 255, 255, 0.08);
  color: #fff;
}
body.dark-mode .comment-meta {
  color: var(--text-m);
}
body.dark-mode .quiz-top-bar {
  background: #111827;
  border-bottom-color: rgba(255, 255, 255, 0.08);
}
body.dark-mode .q-timer {
  background: #111827;
  border-color: rgba(255, 255, 255, 0.08);
}
body.dark-mode .quiz-nav {
  background: #111827;
  border-top-color: rgba(255, 255, 255, 0.08);
}
body.dark-mode .cat-pill {
  background: #111827;
  border-color: rgba(255, 255, 255, 0.08);
}
body.dark-mode .cat-pill:hover {
  background: #1f2937;
}
body.dark-mode .pagination a {
  background: #111827;
  border-color: rgba(255, 255, 255, 0.08);
}
body.dark-mode .pagination a:hover {
  background: var(--primary);
  border-color: var(--primary);
}
body.dark-mode .quiz-header,
body.dark-mode .quiz-engine,
body.dark-mode .result-card,
body.dark-mode .leaderboard {
  border-color: rgba(255, 255, 255, 0.08);
}
body.dark-mode .logo-text {
  background: linear-gradient(135deg, #ffffff 0%, #94a3b8 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}
body.dark-mode .nav-menu a:hover:not(.active) {
  background: rgba(255, 255, 255, 0.06);
}

/* Shake animation for wrong answers */
.option-btn.shake {
  animation: option-shake 0.3s cubic-bezier(.36,.07,.19,.97) both;
}
@keyframes option-shake {
  10%, 90% { transform: translate3d(-2px, 0, 0); }
  20%, 80% { transform: translate3d(4px, 0, 0); }
  30%, 50%, 70% { transform: translate3d(-6px, 0, 0); }
  40%, 60% { transform: translate3d(6px, 0, 0); }
}

/* Ensure all text elements, headings, card titles, sidebars and links stay highly visible in dark mode */
body.dark-mode h1,
body.dark-mode h2,
body.dark-mode h3,
body.dark-mode h4,
body.dark-mode h5,
body.dark-mode h6,
body.dark-mode .entry-title,
body.dark-mode .entry-title a,
body.dark-mode h1 a,
body.dark-mode h2 a,
body.dark-mode h3 a,
body.dark-mode .logo-text,
body.dark-mode .widget-title,
body.dark-mode .q-text {
  color: #ffffff !important;
}

body.dark-mode,
body.dark-mode p,
body.dark-mode li,
body.dark-mode td,
body.dark-mode th,
body.dark-mode .quiz-desc,
body.dark-mode .explanation-box,
body.dark-mode .qa-q,
body.dark-mode .qa-opt,
body.dark-mode .qa-explain,
body.dark-mode .comment-author cite,
body.dark-mode .q-counter,
body.dark-mode .quiz-q-count {
  color: #e2e8f0 !important;
}

body.dark-mode a:not(.btn-play):not(.btn-primary):not(.share-btn):not(.htag-capsule):not(.active) {
  color: #818cf8 !important;
}
body.dark-mode a:not(.btn-play):not(.btn-primary):not(.share-btn):not(.htag-capsule):not(.active):hover {
  color: #a5b4fc !important;
}

body.dark-mode .breadcrumb a {
  color: #94a3b8 !important;
}
body.dark-mode .breadcrumb a:hover {
  color: #818cf8 !important;
}
body.dark-mode .breadcrumb span {
  color: #475569 !important;
}
body.dark-mode .breadcrumb span:last-child {
  color: #818cf8 !important;
}

body.dark-mode .sidebar a {
  color: #cbd5e1 !important;
}
body.dark-mode .sidebar a:hover {
  color: #818cf8 !important;
}
body.dark-mode .see-all {
  color: #818cf8 !important;
}

body.dark-mode .quiz-meta span {
  color: #94a3b8 !important;
}

body.dark-mode .widget-body {
  background: #111827 !important;
}

/* Explanation Box contrast overrides in Dark Mode */
body.dark-mode .explanation-box {
  background: #1e293b !important;
  border-left-color: var(--accent) !important;
}
body.dark-mode .explanation-box strong {
  color: #ffffff !important;
}

/* ---- Coaching Mock Test Portal Styles ---- */
.test-specs-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin: 24px 0;
}
@media(max-width: 640px) {
  .test-specs-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
  }
}
.spec-card {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-s);
  padding: 14px;
  text-align: center;
  transition: var(--transition);
}
.spec-card:hover {
  border-color: var(--primary);
  background: var(--card);
}
.spec-label {
  display: block;
  font-size: 11px;
  color: var(--text-m);
  text-transform: uppercase;
  font-weight: 700;
  letter-spacing: 0.5px;
  margin-bottom: 4px;
}
.spec-value {
  display: block;
  font-size: 18px;
  font-weight: 800;
  color: var(--primary-d);
}
.instructions-card {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
  margin-bottom: 24px;
}
.instructions-card h3 {
  margin: 0 0 12px;
  font-size: 14px;
  font-weight: 800;
  color: var(--primary-d);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.instructions-card ul {
  list-style: disc;
  padding-left: 20px;
  margin: 0;
}
.instructions-card li {
  font-size: 13px;
  color: var(--text-m);
  margin-bottom: 8px;
  line-height: 1.6;
}
.start-test-action {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  margin: 28px 0;
}
.btn-start-test {
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-l) 100%);
  color: #fff !important;
  font-size: 15px;
  font-weight: 800;
  padding: 14px 44px;
  border-radius: 40px;
  border: none;
  cursor: pointer;
  box-shadow: 0 8px 20px rgba(79, 70, 229, 0.25);
  transition: var(--transition);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.btn-start-test:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 24px rgba(79, 70, 229, 0.35);
}
.attempts-indicator {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-m);
}

/* Dark Mode updates for Mock Test Console */
body.dark-mode .spec-card,
body.dark-mode .instructions-card {
  background: rgba(255, 255, 255, 0.02) !important;
  border-color: rgba(255, 255, 255, 0.08) !important;
}
body.dark-mode .spec-card:hover {
  background: rgba(255, 255, 255, 0.05) !important;
  border-color: var(--primary) !important;
}
body.dark-mode .spec-value,
body.dark-mode .instructions-card h3 {
  color: #ffffff !important;
}
body.dark-mode .spec-label,
body.dark-mode .instructions-card li,
body.dark-mode .attempts-indicator {
  color: #94a3b8 !important;
}

/* ---- Imageless Coaching Style Quiz Cards ---- */
.card-badge-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 14px;
}
.card-badge-format {
  font-size: 10px;
  font-weight: 800;
  padding: 4px 12px;
  border-radius: 20px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.card-badge-format.daily { background: rgba(5, 150, 105, 0.1); color: var(--daily); }
.card-badge-format.weekly { background: rgba(124, 92, 246, 0.1); color: var(--weekly); }
.card-badge-format.monthly { background: rgba(244, 63, 94, 0.1); color: var(--monthly); }

.card-badge-subject {
  font-size: 10px;
  font-weight: 700;
  color: var(--text-m);
  background: var(--bg);
  padding: 3px 10px;
  border-radius: 4px;
  border: 1px solid var(--border);
}
.card-specs-row {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 12px;
  color: var(--text-m);
  margin-bottom: 18px;
  font-weight: 600;
}
.card-specs-row .divider {
  color: var(--text-l);
  font-weight: normal;
}
.card-footer-date {
  font-size: 12px;
  color: var(--text-l);
  font-weight: 600;
}

/* Dark Mode Updates for Imageless Cards */
body.dark-mode .card-badge-subject {
  background: rgba(255, 255, 255, 0.05) !important;
  color: #e2e8f0 !important;
  border-color: rgba(255, 255, 255, 0.08) !important;
}
body.dark-mode .card-specs-row,
body.dark-mode .card-footer-date {
  color: #94a3b8 !important;
}
body.dark-mode .card-specs-row .divider {
  color: #475569 !important;
}

/* Global Layout Spacing */
.content-area section {
  margin-bottom: 30px !important;
}
.content-area section:last-child {
  margin-bottom: 0 !important;
}

/* Sharp Boxy Layout (Border Radius 0 overrides) */
#subjects,
#exams,
#latest-mocks,
.testbook-cat-card,
.testbook-quiz-card,
.testbook-cat-card .tb-card-icon-wrap,
.tb-badge-exam,
.tb-badge-free,
.widget,
.widget-title,
.widget-link-list a,
.hero-trending-searches a,
.type-hero,
.breadcrumb,
.premium-post-article,
.post-header-premium,
.quiz-header,
.qa-reference,
.result-card,
.social-join-banner {
  border-radius: 0 !important;
}

/* Custom button border radius (Start Now button) */
.tb-quiz-btn {
  border-radius: 5px !important;
}

/* Custom rounded search elements (25px-30px style) */
.hero-centered-content .hero-search {
  border-radius: 28px !important;
}
.hero-centered-content .hero-search-btn {
  border-radius: 24px !important;
}
.search-form {
  border-radius: 26px !important;
}
.search-input {
  border-radius: 26px 0 0 26px !important;
}
.search-btn {
  border-radius: 0 26px 26px 0 !important;
}


/* Dark Mode Header Overrides */
body.dark-mode .site-header {
  background: #0f172a !important;
  border-bottom-color: rgba(255, 255, 255, 0.08) !important;
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.25) !important;
}
body.dark-mode .logo-text {
  color: #ffffff !important;
}
body.dark-mode .nav-menu {
  background: rgba(15, 23, 42, 0.98) !important;
  border-bottom-color: rgba(255, 255, 255, 0.08) !important;
}
body.dark-mode .nav-menu a {
  color: rgba(255, 255, 255, 0.8) !important;
}
body.dark-mode .nav-menu a:hover:not(.active) {
  color: #ffffff !important;
  background: rgba(255, 255, 255, 0.08) !important;
}
body.dark-mode .nav-toggle span {
  background: #ffffff !important;
}

/* ---- Mock Test Dashboard Template Styles ---- */
.mock-dashboard-wrapper {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 32px;
  margin: 40px 0;
}
@media(max-width: 960px) {
  .mock-dashboard-wrapper {
    grid-template-columns: 1fr;
    gap: 24px;
  }
}
.mock-filter-sidebar {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
  align-self: start;
}
.mock-filter-title {
  font-size: 13px;
  font-weight: 800;
  color: var(--primary-d);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 16px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--border);
}
body.dark-mode .mock-filter-title {
  color: #fff;
}
.mock-filter-list {
  list-style: none;
  margin: 0;
  padding: 0;
}
.mock-filter-item {
  margin-bottom: 8px;
}
.mock-filter-link {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 12px;
  font-size: 13px;
  color: var(--text-m);
  text-decoration: none;
  border-radius: 6px;
  transition: var(--transition);
  font-weight: 600;
}
.mock-filter-link:hover,
.mock-filter-link.active {
  background: rgba(79, 70, 229, 0.08);
  color: var(--primary) !important;
}
body.dark-mode .mock-filter-link:hover,
body.dark-mode .mock-filter-link.active {
  background: rgba(99, 102, 241, 0.15);
  color: #a5b4fc !important;
}
.mock-filter-link .badge-count {
  font-size: 10px;
  font-weight: 800;
  background: var(--bg);
  border: 1px solid var(--border);
  color: var(--text-l);
  padding: 2px 6px;
  border-radius: 20px;
}
.mock-stats-banner {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-l) 100%);
  border-radius: var(--radius);
  padding: 24px;
  color: #fff;
  margin-bottom: 32px;
  box-shadow: 0 10px 25px rgba(79, 70, 229, 0.2);
}
@media(max-width: 640px) {
  .mock-stats-banner {
    grid-template-columns: 1fr;
    gap: 16px;
    text-align: center;
  }
}
.mock-stat-item h4 {
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: rgba(255, 255, 255, 0.8);
  margin: 0 0 4px;
}
.mock-stat-item p {
  font-size: 24px;
  font-weight: 800;
  margin: 0;
}

/* Option selected style in mock test mode */
.option-btn.selected {
  background: var(--primary) !important;
  color: #fff !important;
  border-color: var(--primary) !important;
  box-shadow: 0 4px 12px rgba(79, 70, 229, 0.2) !important;
}
body.dark-mode .option-btn.selected {
  background: var(--primary) !important;
  color: #fff !important;
  border-color: var(--primary) !important;
}

/* Theme Toggle Button visibility and color rules */
.theme-toggle-btn {
  display: flex !important;
  align-items: center;
  justify-content: center;
  color: #0f172a !important;
}
body.dark-mode .theme-toggle-btn {
  color: #ffffff !important;
}

/* Homepage Section Styling Overrides: Cards & Alternate Gradient Layouts */
#subjects, #exams, #latest-mocks {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 32px 28px;
  margin-bottom: 40px;
  box-shadow: var(--shadow);
  transition: var(--transition);
}
#subjects:hover, #exams:hover, #latest-mocks:hover {
  border-color: rgba(99, 102, 241, 0.2);
}
#exams, #latest-mocks {
  background: linear-gradient(135deg, var(--card) 0%, rgba(99, 102, 241, 0.02) 100%);
  border-color: rgba(99, 102, 241, 0.1);
}
body.dark-mode #exams, body.dark-mode #latest-mocks {
  background: linear-gradient(135deg, var(--card) 0%, rgba(99, 102, 241, 0.04) 100%);
  border-color: rgba(99, 102, 241, 0.15);
}
@media(max-width: 640px) {
  #subjects, #exams, #latest-mocks {
    padding: 20px 14px;
    margin-bottom: 24px;
    border-radius: 12px;
  }
  .section-head {
    flex-direction: column !important;
    align-items: flex-start !important;
    gap: 6px !important;
    padding-bottom: 8px !important;
    border-bottom-width: 1px !important;
  }
  .section-head h2 {
    font-size: 15px !important;
    font-weight: 700 !important;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    width: 100%;
    flex-wrap: wrap;
  }
  .section-head h2 .badge {
    font-size: 9.5px !important;
    padding: 2px 8px !important;
    margin-left: 0 !important;
  }
  .section-head span {
    font-size: 11.5px !important;
    line-height: 1.3;
    display: block;
  }
}

/* ============================================================
   Premium Single Post Layout (single.php)
   ============================================================ */

.premium-post-article {
  margin-bottom: 30px;
}

.post-header-premium {
  background: var(--card);
  border-radius: var(--radius);
  padding: 36px 36px 28px;
  box-shadow: var(--shadow);
  margin-top: 10px;
  margin-bottom: 24px;
  border: 1px solid var(--border);
  position: relative;
}

.post-title-premium {
  font-size: clamp(22px, 5vw, 32px);
  font-weight: 800;
  margin: 0 0 20px;
  color: var(--primary-d);
  letter-spacing: -0.75px;
  line-height: 1.35;
}

.post-meta-bar-premium {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  font-size: 13px;
  font-weight: 600;
}

.meta-item-premium {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 16px;
  border-radius: 30px;
  transition: var(--transition);
}

.meta-item-premium.author-item {
  background: rgba(79, 70, 229, 0.05); /* Soft Indigo */
  color: var(--primary);
  border: 1px solid rgba(79, 70, 229, 0.1);
}

.meta-item-premium.author-item a {
  color: var(--primary);
  text-decoration: none;
  font-weight: 700;
}

.meta-item-premium.author-item a:hover {
  text-decoration: underline;
}

.meta-item-premium.date-item {
  background: rgba(71, 85, 105, 0.05); /* Soft Slate */
  color: var(--text-m);
  border: 1px solid rgba(71, 85, 105, 0.1);
}

.post-featured-image-premium {
  margin-bottom: 28px;
  overflow: hidden;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  transition: var(--transition);
}

.post-featured-image-premium img {
  width: 100%;
  height: auto;
  display: block;
  transition: transform 0.5s ease;
}

.post-featured-image-premium:hover img {
  transform: scale(1.02);
}

.post-content-body-premium {
  background: var(--card);
  padding: 40px;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  color: var(--text);
  font-size: 16px;
  line-height: 1.85;
}

/* Typography elements inside post body */
.post-content-body-premium p {
  margin-top: 0;
  margin-bottom: 1.6rem;
}

.post-content-body-premium h2 {
  font-size: clamp(20px, 4vw, 24px);
  font-weight: 700;
  margin-top: 2.2rem;
  margin-bottom: 1.2rem;
  color: var(--primary-d);
  letter-spacing: -0.5px;
  border-left: 4px solid var(--primary);
  padding-left: 14px;
}

.post-content-body-premium h3 {
  font-size: clamp(17px, 3vw, 20px);
  font-weight: 700;
  margin-top: 2rem;
  margin-bottom: 1rem;
  color: var(--primary-d);
}

.post-content-body-premium ul, 
.post-content-body-premium ol {
  margin-top: 0;
  margin-bottom: 1.6rem;
  padding-left: 24px;
}

.post-content-body-premium li {
  margin-bottom: 0.6rem;
}

.post-content-body-premium blockquote {
  margin: 2rem 0;
  padding: 20px 24px;
  background: rgba(79, 70, 229, 0.02);
  border-left: 4px solid var(--primary);
  border-radius: 0 var(--radius-s) var(--radius-s) 0;
  font-style: italic;
  color: var(--text-m);
}

.post-content-body-premium blockquote p:last-child {
  margin-bottom: 0;
}

/* Post Meta Footer */
.post-meta-footer-premium {
  margin-top: 36px;
  padding-top: 24px;
  border-top: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.post-categories-footer {
  font-size: 14px;
  color: var(--text-m);
}

.post-categories-footer a {
  color: var(--primary);
  text-decoration: none;
  font-weight: 600;
}

.post-categories-footer a:hover {
  text-decoration: underline;
}

.footer-meta-label {
  font-weight: 700;
  color: var(--text);
  margin-right: 6px;
}

.post-tags-footer {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}

.tag-link-badge {
  background: var(--bg);
  color: var(--primary);
  border: 1px solid var(--border);
  padding: 5px 14px;
  font-size: 12px;
  font-weight: 600;
  border-radius: 30px;
  text-decoration: none;
  transition: var(--transition);
}

.tag-link-badge:hover {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
  box-shadow: 0 4px 10px rgba(79, 70, 229, 0.2);
}

/* Share Row Premium */
.share-row-premium {
  margin: 28px 0;
  background: var(--card);
  padding: 24px;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
}

.share-title {
  display: block;
  text-align: center;
  font-size: 12px;
  font-weight: 800;
  color: var(--text-l);
  letter-spacing: 1px;
  margin-bottom: 16px;
}

.share-buttons-grid {
  display: flex;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
}

.share-btn-prem {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 24px;
  font-size: 14px;
  font-weight: 700;
  color: #fff;
  text-decoration: none;
  border-radius: 30px;
  transition: var(--transition);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.share-btn-prem.wa {
  background: #25d366;
}
.share-btn-prem.wa:hover {
  background: #20ba5a;
  box-shadow: 0 4px 12px rgba(37, 211, 102, 0.2);
  transform: translateY(-1px);
}

.share-btn-prem.tw {
  background: #000000;
}
.share-btn-prem.tw:hover {
  background: #1a1a1a;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
  transform: translateY(-1px);
}

.share-btn-prem.tg {
  background: #0088cc;
}
.share-btn-prem.tg:hover {
  background: #0077b3;
  box-shadow: 0 4px 12px rgba(0, 136, 204, 0.2);
  transform: translateY(-1px);
}

/* Comments premium */
.comments-area-wrap-premium {
  background: var(--card);
  padding: 40px;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
}

/* Dark Mode support for Premium Post */
body.dark-mode .post-header-premium,
body.dark-mode .post-content-body-premium,
body.dark-mode .share-row-premium,
body.dark-mode .comments-area-wrap-premium {
  background: var(--card);
  border-color: var(--border);
}

body.dark-mode .post-title-premium {
  color: #f1f5f9;
}

body.dark-mode .post-content-body-premium h2,
body.dark-mode .post-content-body-premium h3 {
  color: #f1f5f9;
}

body.dark-mode .tag-link-badge {
  background: #1e293b;
  border-color: #334155;
  color: #94a3b8;
}

body.dark-mode .tag-link-badge:hover {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
}

@media (max-width: 640px) {
  .post-header-premium {
    padding: 24px;
  }
  .post-content-body-premium {
    padding: 24px;
  }
  .comments-area-wrap-premium {
    padding: 24px;
  }
  .share-btn-prem {
    padding: 8px 16px;
    font-size: 13px;
    flex-grow: 1;
    justify-content: center;
  }
}

/* ============================================================
   Testbook style Category Grid & Cards
   ============================================================ */

.testbook-cat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 16px;
  margin-top: 15px;
}

.testbook-cat-card {
  display: flex;
  align-items: center;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 14px 16px;
  text-decoration: none !important;
  color: var(--text) !important;
  transition: var(--transition);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.02);
}

.testbook-cat-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.05), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
  border-color: var(--primary-l);
}

.tb-card-icon-wrap {
  width: 42px;
  height: 42px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.tb-card-icon {
  font-size: 18px;
}

.tb-card-info {
  margin-left: 14px;
  flex-grow: 1;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.tb-card-title {
  font-size: 14px !important;
  font-weight: 700;
  color: var(--text);
  margin: 0 !important;
  line-height: 1.3;
}

.tb-card-count {
  font-size: 11.5px;
  color: var(--text-m);
  font-weight: 600;
}

.tb-card-arrow {
  color: var(--text-l);
  display: flex;
  align-items: center;
  transition: var(--transition);
}

.testbook-cat-card:hover .tb-card-arrow {
  color: var(--primary);
  transform: translateX(2px);
}

/* Dark mode compatibility */
body.dark-mode .testbook-cat-card {
  background: var(--card);
  border-color: var(--border);
  color: #f1f5f9 !important;
}
body.dark-mode .tb-card-title {
  color: #f1f5f9 !important;
}
body.dark-mode .tb-card-count {
  color: #94a3b8;
}

/* ============================================================
   Testbook style Horizontal Quiz Cards (List Layout)
   ============================================================ */

.testbook-quiz-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin-top: 15px;
}

.testbook-quiz-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.02);
  transition: var(--transition);
  display: flex;
  flex-direction: column;
}

.testbook-quiz-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(15, 23, 42, 0.05);
  border-color: rgba(0, 194, 243, 0.4);
}

.tb-quiz-card-main {
  padding: 20px 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
}

.tb-quiz-card-left {
  display: flex;
  flex-direction: column;
  gap: 8px;
  flex-grow: 1;
}

.tb-quiz-badges {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.tb-badge-free {
  background: #10b981; /* Green */
  color: #ffffff;
  font-size: 10px;
  font-weight: 800;
  padding: 3px 8px;
  border-radius: 4px;
  letter-spacing: 0.5px;
  line-height: 1;
}

.tb-badge-exam {
  background: rgba(100, 116, 139, 0.06);
  border: 1px solid var(--border);
  color: var(--text-m);
  font-size: 11px;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: 4px;
  line-height: 1.2;
}

.tb-quiz-title {
  font-size: 16px !important;
  font-weight: 700;
  color: var(--text);
  margin: 4px 0 !important;
  line-height: 1.4;
}

.tb-quiz-title a {
  color: var(--text) !important;
  text-decoration: none !important;
  transition: var(--transition);
}

.tb-quiz-title a:hover {
  color: var(--primary) !important;
}

.tb-quiz-specs {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 16px;
  color: var(--text-m);
  font-size: 12.5px;
  font-weight: 500;
}

.tb-spec-item {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.tb-spec-icon {
  color: var(--text-l);
  flex-shrink: 0;
}

.tb-quiz-card-right {
  flex-shrink: 0;
}

.tb-quiz-btn {
  display: inline-block;
  background: var(--primary); /* Matched to homepage brand color */
  color: #ffffff !important;
  font-weight: 700;
  padding: 10px 24px;
  border-radius: 6px;
  text-decoration: none !important;
  font-size: 13.5px;
  transition: var(--transition);
  border: none;
  cursor: pointer;
  box-shadow: 0 2px 4px rgba(79, 70, 229, 0.15);
}

.tb-quiz-btn:hover {
  background: var(--primary-l);
  box-shadow: 0 4px 10px rgba(79, 70, 229, 0.25);
  transform: translateY(-1px);
}

.tb-quiz-card-footer {
  background: rgba(248, 250, 252, 0.6);
  border-top: 1px solid var(--border);
  padding: 10px 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 12px;
  color: var(--text-m);
  font-weight: 600;
}

.tb-footer-left, .tb-footer-right {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.tb-footer-icon {
  color: var(--text-l);
}

.tb-share-link {
  color: var(--text-m) !important;
  text-decoration: none !important;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: var(--transition);
}

.tb-share-link:hover {
  color: var(--primary) !important;
}

/* Dark mode compatibility */
body.dark-mode .testbook-quiz-card {
  background: var(--card);
  border-color: var(--border);
}

body.dark-mode .tb-quiz-title a {
  color: #f1f5f9 !important;
}

body.dark-mode .tb-quiz-title a:hover {
  color: var(--primary-l) !important;
}

body.dark-mode .tb-badge-exam {
  background: rgba(255, 255, 255, 0.04);
  border-color: rgba(255, 255, 255, 0.08);
  color: #94a3b8;
}

body.dark-mode .tb-quiz-specs {
  color: #94a3b8;
}

body.dark-mode .tb-quiz-card-footer {
  background: rgba(30, 41, 59, 0.3);
  border-color: var(--border);
  color: #94a3b8;
}

body.dark-mode .tb-share-link {
  color: #94a3b8 !important;
}
body.dark-mode .tb-share-link:hover {
  color: var(--primary-l) !important;
}

@media(max-width: 640px) {
  .tb-quiz-card-main {
    flex-direction: row !important; /* Keep horizontal on mobile */
    align-items: center;
    padding: 12px 14px;
    gap: 12px;
  }
  
  .tb-quiz-card-left {
    min-width: 0; /* Let it shrink and wrap cleanly */
  }
  
  .tb-quiz-title {
    font-size: 13.5px !important;
    line-height: 1.35;
    margin: 2px 0 !important;
  }
  
  .tb-badge-exam {
    font-size: 9.5px;
    padding: 1px 6px;
  }
  
  .tb-quiz-specs {
    font-size: 11px;
    gap: 8px;
  }
  
  .tb-spec-icon {
    width: 11px;
    height: 11px;
  }
  
  .tb-quiz-card-right {
    width: auto;
  }
  
  .tb-quiz-btn {
    display: inline-block;
    padding: 6px 12px;
    font-size: 11.5px;
    border-radius: 4px;
    width: auto;
    text-align: center;
  }
  
  .tb-quiz-card-footer {
    padding: 8px 14px;
    font-size: 11px;
  }
}

/* Compact & Centered Hero Section style override */
.hero-premium.compact-hero {
  background: radial-gradient(circle at 50% 50%, rgba(79, 70, 229, 0.15) 0%, rgba(15, 23, 42, 0) 70%),
              linear-gradient(180deg, #090d16 0%, #0f172a 100%) !important;
  padding: 50px 0 !important;
  position: relative;
  overflow: hidden;
}

.hero-premium.compact-hero::after {
  content: '';
  position: absolute;
  width: 140px;
  height: 140px;
  background: rgba(99, 102, 241, 0.15);
  filter: blur(80px);
  border-radius: 50%;
  top: 10%;
  left: 20%;
  pointer-events: none;
}

.hero-premium.compact-hero::before {
  content: '';
  position: absolute;
  width: 180px;
  height: 180px;
  background: rgba(16, 185, 129, 0.08);
  filter: blur(100px);
  border-radius: 50%;
  bottom: 10%;
  right: 20%;
  pointer-events: none;
}

.hero-centered-content {
  text-align: center;
  max-width: 680px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  position: relative;
  z-index: 10;
}

.hero-centered-content .hero-badge {
  background: linear-gradient(90deg, rgba(99, 102, 241, 0.18) 0%, rgba(16, 185, 129, 0.1) 100%) !important;
  border: 1px solid rgba(99, 102, 241, 0.3) !important;
  color: #a5b4fc !important;
  font-size: 10px !important;
  letter-spacing: 0.8px;
  padding: 5px 12px !important;
  border-radius: 30px;
  font-weight: 700;
  text-transform: uppercase;
  margin-bottom: 14px;
  display: inline-block;
}

.hero-centered-content h1 {
  font-size: clamp(25px, 4.5vw, 36px) !important;
  font-weight: 800;
  line-height: 1.25;
  margin-bottom: 12px !important;
  color: #fff;
  letter-spacing: -0.5px !important;
}

.hero-centered-content h1 .highlight {
  background: linear-gradient(135deg, #00c2f3 0%, #818cf8 50%, #c084fc 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  display: inline-block;
}

.hero-centered-content p {
  font-size: 14px !important;
  color: #94a3b8;
  line-height: 1.5;
  margin-bottom: 22px !important;
}

/* Glassmorphic Search Bar */
.hero-centered-content .hero-search {
  backdrop-filter: blur(8px);
  background: rgba(255, 255, 255, 0.04) !important;
  border: 1px solid rgba(255, 255, 255, 0.1) !important;
  box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.25) !important;
  transition: all 0.3s ease !important;
}

.hero-centered-content .hero-search:focus-within {
  border-color: rgba(99, 102, 241, 0.5) !important;
  box-shadow: 0 0 20px rgba(99, 102, 241, 0.25) !important;
  background: rgba(255, 255, 255, 0.08) !important;
}

/* Trending tags sub-bar */
.hero-trending-searches {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: center;
  font-size: 11.5px;
  color: #64748b;
  font-weight: 600;
  margin-top: -8px;
}

.hero-trending-searches a {
  color: #94a3b8 !important;
  text-decoration: none !important;
  background: rgba(255, 255, 255, 0.04);
  padding: 3px 10px;
  border-radius: 20px;
  border: 1px solid rgba(255, 255, 255, 0.06);
  transition: var(--transition);
}

.hero-trending-searches a:hover {
  color: #fff !important;
  border-color: var(--primary-l);
  background: rgba(99, 102, 241, 0.15);
  transform: translateY(-1px);
}

@media(max-width: 640px) {
  .hero-premium.compact-hero {
    padding: 35px 16px !important; /* Add padding to prevent edges cutting off */
  }
  .hero-centered-content h1 {
    font-size: 21px !important;
  }
  .hero-centered-content p {
    font-size: 12.5px !important;
    margin-bottom: 16px !important;
  }
  .hero-trending-searches {
    font-size: 10px;
  }
  /* Mobile Search Bar Cut-off Fix */
  .hero-centered-content .hero-search {
    box-sizing: border-box !important;
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 0 16px !important;
    padding: 4px 4px 4px 12px !important;
  }
  .hero-centered-content .hero-search-input {
    min-width: 0 !important;
    width: 100% !important;
    font-size: 13px !important;
  }
  .hero-centered-content .hero-search-btn {
    padding: 8px 16px !important;
    font-size: 12px !important;
    flex-shrink: 0 !important;
  }

  /* --- Mobile Quiz & Mock Test Styling Adjustments --- */
  .quiz-header {
    padding: 16px 18px !important;
    margin-bottom: 16px !important;
  }
  .quiz-header h1 {
    font-size: 16.5px !important;
    line-height: 1.35 !important;
    margin-bottom: 10px !important;
  }
  .quiz-info-bar {
    gap: 6px !important;
    font-size: 11px !important;
  }
  .quiz-info-bar span {
    padding: 4px 10px !important;
  }
  
  /* Spec instruction cards on landing gate */
  .instructions-card {
    padding: 16px !important;
    margin-bottom: 20px !important;
  }
  .instructions-card h3 {
    font-size: 13.5px !important;
  }
  .instructions-card ul li {
    font-size: 12.5px !important;
    line-height: 1.5 !important;
    margin-bottom: 6px !important;
  }
  .attempts-indicator {
    font-size: 11px !important;
  }

  /* Active Engine: Compact Elements on Mobile */
  .question-body {
    padding: 16px !important;
  }
  .quiz-engine .question-body {
    padding: 16px !important;
  }
  #quiz-engine-wrap .play-card-body {
    padding: 16px !important;
  }
  .quiz-top-bar {
    padding: 8px 16px !important;
  }
  .q-header-bar {
    padding: 10px 16px !important;
    gap: 10px !important;
    margin-bottom: 16px !important;
  }
  
  /* Question counter and timer badge styling */
  .q-counter, .q-counter-val {
    font-size: 11px !important;
    font-weight: 800 !important;
    padding: 3px 8px !important;
    border-radius: 4px !important;
    display: inline-flex !important;
    align-items: center !important;
  }
  .q-timer {
    font-size: 11px !important;
    padding: 3px 8px !important;
  }

  
  /* Question Description Size */
  #q-text, .q-text, .question-text {
    font-size: 16.5px !important;
    line-height: 1.5 !important;
    margin-bottom: 24px !important;
  }

  /* Option Buttons Size - Optimized for one-hand reachability */
  .options-list, .options-grid {
    gap: 12px !important;
  }
  .option-btn {
    padding: 12px 16px !important;
    gap: 10px !important;
    font-size: 14px !important;
    border-width: 2px !important;
    border-radius: var(--radius) !important;
  }
  .option-btn .opt-label {
    width: 24px !important;
    height: 24px !important;
    line-height: 24px !important;
    font-size: 11px !important;
    min-width: 24px !important;
  }
  .option-btn .opt-text {
    font-size: 13.5px !important;
    line-height: 1.4 !important;
  }
  
  /* Navigation Footer Button */
  .play-card-footer, .quiz-nav {
    margin-top: 16px !important;
    padding-top: 14px !important;
  }
  .btn-next, #btn-next {
    padding: 10px 20px !important;
    font-size: 12.5px !important;
  }
  
  /* Mobile Testbook Category Grid: 2-per-row */
  .testbook-cat-grid {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 8px !important;
    margin-top: 10px !important;
  }
  .testbook-cat-card {
    padding: 8px 10px !important;
    gap: 8px !important;
    border-radius: 6px !important;
  }
  .testbook-cat-card .tb-card-icon-wrap {
    width: 32px !important;
    height: 32px !important;
    border-radius: 6px !important;
  }
  .testbook-cat-card .tb-card-icon {
    font-size: 14px !important;
  }
  .testbook-cat-card .tb-card-title {
    font-size: 12px !important;
    line-height: 1.25 !important;
    margin-bottom: 2px !important;
  }
  .testbook-cat-card .tb-card-count {
    font-size: 10px !important;
  }
  .testbook-cat-card .tb-card-arrow {
    display: none !important; /* Hide arrows on mobile to maximize content width */
  }
}

/* Custom styles for Mock Test progress headers */
.q-header-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 24px;
  background: var(--bg);
  border-bottom: 1px solid var(--border);
  margin-bottom: 24px;
}
.q-progress-wrapper {
  display: flex;
  align-items: center;
  gap: 12px;
  flex: 1;
}
.q-progress-wrapper .quiz-progress-bar {
  flex: 1;
  max-width: 150px;
  background: var(--border);
  height: 6px;
  border-radius: 3px;
  overflow: hidden;
}
body.dark-mode .q-header-bar {
  background: rgba(30, 41, 59, 0.2);
}
body.dark-mode .q-counter, body.dark-mode .q-counter-val {
  background: rgba(255, 255, 255, 0.05) !important;
  color: var(--primary-l) !important;
}

/* Premium Floating Sticky WhatsApp Button */
.tb-sticky-whatsapp {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 9999;
  display: flex;
  align-items: center;
  gap: 10px;
  background: linear-gradient(135deg, #25D366 0%, #128C7E 100%);
  color: #ffffff !important;
  padding: 12px 20px;
  border-radius: 50px;
  font-family: 'Outfit', sans-serif;
  font-size: 14px;
  font-weight: 700;
  text-decoration: none !important;
  box-shadow: 0 10px 25px rgba(18, 140, 126, 0.3);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  border: 1.5px solid rgba(255, 255, 255, 0.15);
}

.tb-sticky-whatsapp:hover {
  transform: translateY(-4px) scale(1.03);
  box-shadow: 0 14px 35px rgba(18, 140, 126, 0.45);
  background: linear-gradient(135deg, #128C7E 0%, #25D366 100%);
}

.wa-icon-pulse-wrapper {
  display: flex;
  align-items: center;
  justify-content: center;
}

.tb-sticky-whatsapp .wa-icon {
  width: 20px;
  height: 20px;
  fill: #ffffff;
  animation: wa-pulse-anim 2s infinite ease-in-out;
}

@keyframes wa-pulse-anim {
  0% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.18);
  }
  100% {
    transform: scale(1);
  }
}

/* Mobile responsive adjustments */
@media (max-width: 600px) {
  .tb-sticky-whatsapp {
    bottom: 20px;
    right: 20px;
    padding: 10px 16px;
    font-size: 13px;
    box-shadow: 0 8px 20px rgba(18, 140, 126, 0.25);
  }
  .tb-sticky-whatsapp .wa-icon {
    width: 18px;
    height: 18px;
  }
  
  /* Mobile responsive overrides for type-hero titles */
  .type-hero {
    padding: 16px 20px !important;
    margin-top: 16px !important;
    margin-bottom: 16px !important;
  }
  .type-label {
    font-size: 19px !important;
    letter-spacing: -0.3px !important;
    margin-bottom: 6px !important;
  }
  .type-desc {
    font-size: 12px !important;
    line-height: 1.5 !important;
  }
}

/* Dark Mode Typography & Contrast Fixes */
body.dark-mode .rstat .rv {
  color: #ffffff !important;
}
body.dark-mode .rstat.correct .rv {
  color: var(--daily) !important;
}
body.dark-mode .rstat.wrong .rv {
  color: var(--monthly) !important;
}
body.dark-mode .rstat.skip .rv {
  color: var(--accent) !important;
}

body.dark-mode .tb-sticky-whatsapp,
body.dark-mode .tb-sticky-whatsapp span,
body.dark-mode .tb-sticky-whatsapp .wa-text {
  color: #ffffff !important;
}

body.dark-mode .tb-quiz-btn {
  color: #ffffff !important;
  background: var(--primary) !important;
}
body.dark-mode .tb-quiz-btn:hover {
  background: var(--primary-l) !important;
  color: #ffffff !important;
}

/* ==========================================================================
   Premium Testbook-Style Quiz Layout & Modal Custom Styles
   ========================================================================== */

/* Testbook style quiz header */
.tb-quiz-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: #ffffff;
  padding: 12px 24px;
  border-radius: var(--radius) var(--radius) 0 0;
  border-bottom: 2px solid #e2e8f0;
}
body.dark-mode .tb-quiz-header {
  background: #1e293b;
  border-bottom-color: rgba(255, 255, 255, 0.08);
}

.tb-header-left {
  display: flex;
  align-items: center;
  gap: 12px;
}

/* Pause Button style */
.tb-pause-btn {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 2px solid #cbd5e1;
  background: #ffffff;
  font-size: 14px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
  color: #475569;
  padding: 0;
  outline: none;
}
.tb-pause-btn:hover {
  border-color: var(--primary);
  color: var(--primary);
  background: #f8fafc;
}
body.dark-mode .tb-pause-btn {
  background: #334155;
  border-color: #475569;
  color: #cbd5e1;
}
body.dark-mode .tb-pause-btn:hover {
  border-color: var(--primary-l);
  color: var(--primary-l);
}

/* Timer Wrap */
.tb-timer-wrap {
  display: flex;
  flex-direction: column;
}
.tb-timer-val {
  font-size: 18px;
  font-weight: 800;
  color: #0f172a;
  line-height: 1.2;
}
body.dark-mode .tb-timer-val {
  color: #ffffff;
}
.tb-header-quiz-title {
  font-size: 11.5px;
  color: #64748b;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 180px;
}
body.dark-mode .tb-header-quiz-title {
  color: #94a3b8;
}

/* Submit Quiz Button */
.tb-submit-btn {
  background: var(--primary);
  color: #ffffff !important;
  border: none;
  padding: 6px 14px;
  border-radius: 4px;
  font-weight: 700;
  font-size: 12.5px;
  cursor: pointer;
  transition: var(--transition);
  box-shadow: 0 2px 6px rgba(79, 70, 229, 0.2);
  outline: none;
}
.tb-submit-btn:hover {
  background: var(--primary-l);
  box-shadow: 0 4px 10px rgba(79, 70, 229, 0.35);
}

/* Question card header line */
.tb-q-card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-bottom: 8px;
  margin-bottom: 12px;
  border-bottom: 1px solid #e2e8f0;
}
body.dark-mode .tb-q-card-header {
  border-bottom-color: rgba(255, 255, 255, 0.08);
}

/* Circle index question number badge */
.tb-q-num-badge {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: #94a3b8;
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 14px;
}
body.dark-mode .tb-q-num-badge {
  background: #475569;
}

/* Three dots report trigger button */
.tb-report-trigger {
  background: none;
  border: none;
  font-size: 20px;
  color: #64748b;
  cursor: pointer;
  padding: 4px 8px;
  line-height: 1;
  transition: var(--transition);
  outline: none;
}
.tb-report-trigger:hover {
  color: var(--primary);
}
body.dark-mode .tb-report-trigger {
  color: #94a3b8;
}
body.dark-mode .tb-report-trigger:hover {
  color: var(--primary-l);
}

/* Testbook Style Footer navigation bar */
.tb-quiz-footer-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: #2d3748;
  padding: 10px 24px;
  border-radius: 0 0 var(--radius) var(--radius);
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}
body.dark-mode .tb-quiz-footer-bar {
  background: #111827;
}

.btn-tb-nav {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: transparent;
  color: #cbd5e1 !important;
  border: none;
  font-weight: 700;
  font-size: 13.5px;
  cursor: pointer;
  padding: 8px 16px;
  transition: var(--transition);
  outline: none;
}
.btn-tb-nav:hover:not(:disabled) {
  color: #ffffff !important;
}
.btn-tb-nav:disabled {
  color: #4a5568 !important;
  cursor: not-allowed;
}

.btn-tb-next {
  background: var(--primary);
  color: #ffffff !important;
  border: none;
  padding: 10px 24px;
  border-radius: 4px;
  font-weight: 700;
  font-size: 13.5px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: var(--transition);
}
.btn-tb-next:hover:not(:disabled) {
  background: var(--primary-l);
}
.btn-tb-next:disabled {
  background: #4a5568;
  color: #718096 !important;
  cursor: not-allowed;
}

/* Premium Popup Modal for Question Reporting */
.tb-modal {
  position: fixed !important;
  top: 0 !important;
  left: 0 !important;
  width: 100vw !important;
  height: 100vh !important;
  background: rgba(15, 23, 42, 0.6) !important;
  backdrop-filter: blur(4px) !important;
  z-index: 9999999 !important;
  display: none;
  align-items: center !important;
  justify-content: center !important;
  box-sizing: border-box !important;
}
.tb-modal-content {
  background: #ffffff;
  border-radius: 8px;
  max-width: 360px !important;
  width: 85% !important;
  box-shadow: 0 20px 25px -5px rgba(0,0,0,0.15), 0 10px 10px -5px rgba(0,0,0,0.04);
  animation: modalShow 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  overflow: hidden;
  box-sizing: border-box !important;
  margin: auto !important;
}
body.dark-mode .tb-modal-content {
  background: #1e293b;
  border: 1px solid rgba(255, 255, 255, 0.08);
}

@keyframes modalShow {
  from {
    opacity: 0;
    transform: scale(0.95) translateY(10px);
  }
  to {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
}

.tb-modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 20px;
  border-bottom: 1px solid #e2e8f0;
}
body.dark-mode .tb-modal-header {
  border-bottom-color: rgba(255, 255, 255, 0.08);
}
.tb-modal-header h3 {
  font-size: 16px;
  font-weight: 800;
  margin: 0;
  color: #0f172a;
}
body.dark-mode .tb-modal-header h3 {
  color: #ffffff;
}

.close-modal {
  background: none;
  border: none;
  font-size: 24px;
  color: #94a3b8;
  cursor: pointer;
  padding: 0;
  line-height: 1;
  outline: none;
}
.close-modal:hover {
  color: #f43f5e;
}

.tb-modal-body {
  padding: 20px;
}

.report-options {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.report-options label {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  font-weight: 600;
  color: #475569;
  cursor: pointer;
}
body.dark-mode .report-options label {
  color: #cbd5e1;
}
.report-options input[type="radio"] {
  accent-color: var(--primary);
  width: 16px;
  height: 16px;
}
.btn-submit-report {
  width: 100%;
  margin-top: 16px;
  padding: 10px 16px;
  background: var(--primary);
  color: #ffffff !important;
  border: none;
  border-radius: 6px;
  font-weight: 700;
  font-size: 14px;
  cursor: pointer;
  transition: var(--transition);
  outline: none;
}
.btn-submit-report:hover {
  background: var(--primary-l);
}
.btn-submit-report:disabled {
  background: #cbd5e1;
  color: #94a3b8 !important;
  cursor: not-allowed;
}

/* ==========================================================================
   Testbook Fullscreen Mode, Inner Scrolling & Question Palette Styles
   ========================================================================== */

/* Fullscreen and scrollable layouts apply ONLY on mobile viewports */
@media (max-width: 600px) {
  /* Fullscreen Exam Mode Core toggles */
  body.quiz-active-fullscreen {
    overflow: hidden !important;
    padding-top: 0 !important;
    background: #f1f5f9 !important;
  }
  body.quiz-active-fullscreen.dark-mode {
    background: #0f172a !important;
  }

  body.quiz-active-fullscreen .site-header,
  body.quiz-active-fullscreen .site-footer,
  body.quiz-active-fullscreen .tb-sticky-whatsapp,
  body.quiz-active-fullscreen .breadcrumb,
  body.quiz-active-fullscreen #wpadminbar {
    display: none !important;
  }

  /* Force container full width/height in fullscreen mode */
  body.quiz-active-fullscreen .quiz-container {
    max-width: 100vw !important;
    width: 100vw !important;
    height: 100vh !important;
    max-height: 100vh !important;
    padding: 0 !important;
    margin: 0 !important;
    overflow: hidden !important;
  }

  /* Position fixed overlay ensures the quiz matches device screen dimensions, avoiding address bar crop */
  body.quiz-active-fullscreen .quiz-engine {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    margin-top: 0 !important;
    height: 100% !important;
    max-height: 100% !important;
    width: 100% !important;
    max-width: 100% !important;
    z-index: 999999 !important;
    display: flex !important;
    flex-direction: column !important;
    border: none !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    background: #ffffff !important;
  }
  body.quiz-active-fullscreen.dark-mode .quiz-engine {
    background: #1e293b !important;
  }

  /* Pinned top elements inside flex container */
  body.quiz-active-fullscreen .tb-quiz-header {
    flex-shrink: 0 !important;
    border-radius: 0 !important;
  }

  body.quiz-active-fullscreen .quiz-progress-bar {
    flex-shrink: 0 !important;
  }

  /* Question body gets the inner scrolling */
  body.quiz-active-fullscreen .question-body {
    flex: 1 1 auto !important;
    overflow-y: auto !important;
    overflow-x: hidden !important;
    -webkit-overflow-scrolling: touch !important;
    padding: 16px !important;
  }

  /* Pinned bottom elements inside flex container */
  body.quiz-active-fullscreen .tb-quiz-footer-bar {
    flex-shrink: 0 !important;
    border-radius: 0 !important;
  }
}

/* Horizontal scrolling question palette - visible on both Desktop and Mobile */
.tb-questions-palette {
  display: flex;
  gap: 8px;
  padding: 10px 20px;
  background: #f8fafc;
  overflow-x: auto;
  white-space: nowrap;
  border-bottom: 1px solid #e2e8f0;
  -webkit-overflow-scrolling: touch;
  flex-shrink: 0;
}
body.dark-mode .tb-questions-palette {
  background: #0f172a;
  border-bottom-color: rgba(255, 255, 255, 0.08);
}

/* Hide palette scrollbar scroll indicators */
.tb-questions-palette::-webkit-scrollbar {
  height: 4px;
}
.tb-questions-palette::-webkit-scrollbar-track {
  background: transparent;
}
.tb-questions-palette::-webkit-scrollbar-thumb {
  background: rgba(0, 0, 0, 0.15);
  border-radius: 2px;
}
body.dark-mode .tb-questions-palette::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.15);
}

.palette-badge {
  width: 28px;
  height: 28px;
  border-radius: 4px;
  background: #e2e8f0;
  color: #475569;
  border: none;
  font-size: 11.5px;
  font-weight: 700;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: var(--transition);
  outline: none;
}
body.dark-mode .palette-badge {
  background: #334155;
  color: #cbd5e1;
}

.palette-badge.active {
  background: var(--primary) !important;
  color: #ffffff !important;
  box-shadow: 0 2px 6px rgba(79, 70, 229, 0.3);
}

.palette-badge.correct,
.palette-badge.answered {
  background: #10b981 !important;
  color: #ffffff !important;
}

.palette-badge.wrong {
  background: #ef4444 !important;
  color: #ffffff !important;
}

.palette-badge.skipped {
  background: #f59e0b !important;
  color: #ffffff !important;
}

/* Make inner scrollbar look elegant */
.question-body::-webkit-scrollbar {
  width: 6px;
}
.question-body::-webkit-scrollbar-track {
  background: transparent;
}
.question-body::-webkit-scrollbar-thumb {
  background: rgba(0, 0, 0, 0.15);
  border-radius: 3px;
}
body.dark-mode .question-body::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.15);
}


