/* IQBenchmark Pro - Complete Multi-Page Production Stylesheet */
:root {
  --bg: #f8fafc;
  --surface: #ffffff;
  --text: #0f172a;
  --muted: #475569;
  --border: #e2e8f0;
  --primary: #2563eb;
  --primary-hover: #1d4ed8;
  --accent: #7c3aed;
  --whatsapp: #16a34a;
  --whatsapp-hover: #15803d;
}

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

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  background-color: var(--bg);
  color: var(--text);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

.wide-wrap {
  max-width: 1420px;
  margin: 0 auto;
  padding: 0 18px;
}

/* Sticky Header directly at top: 0 */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.98);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border);
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.04);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 62px;
  gap: 12px;
}

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

.brand-icon {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  background: linear-gradient(135deg, #1d4ed8, #4f46e5);
  color: #fff;
  font-weight: 800;
  font-size: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 6px rgba(37, 99, 235, 0.25);
}

.brand-title {
  font-weight: 800;
  font-size: 18px;
  letter-spacing: -0.02em;
  display: block;
  line-height: 1.1;
}

.brand-sub {
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--primary);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 4px;
  flex-wrap: wrap;
}

.nav-link {
  text-decoration: none;
  color: #334155;
  font-size: 13px;
  font-weight: 600;
  padding: 7px 11px;
  border-radius: 8px;
  transition: all 0.15s ease;
}

.nav-link:hover, .nav-link.active {
  background: #eff6ff;
  color: var(--primary);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.lang-select {
  background: #f8fafc;
  border: 1px solid #cbd5e1;
  color: var(--text);
  font-size: 12px;
  font-weight: 700;
  padding: 7px 10px;
  border-radius: 8px;
  cursor: pointer;
}

/* Home 5 IQ Test Cards Grid */
.cards-section {
  padding: 16px 0 24px;
}

.cards-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

@media (max-width: 1024px) {
  .cards-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .nav-links {
    display: none;
  }
}

@media (max-width: 640px) {
  .cards-grid {
    grid-template-columns: 1fr;
  }
}

.iq-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.04);
}

.iq-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 14px 28px -6px rgba(15, 23, 42, 0.12);
  border-color: #93c5fd;
}

.card-thumb {
  height: 148px;
  padding: 16px;
  color: #fff;
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  overflow: hidden;
}

.thumb-1 { background: linear-gradient(135deg, #1e3a8a, #2563eb); }
.thumb-2 { background: linear-gradient(135deg, #065f46, #0d9488); }
.thumb-3 { background: linear-gradient(135deg, #581c87, #7c3aed); }
.thumb-4 { background: linear-gradient(135deg, #9a3412, #ea580c); }
.thumb-5 { background: linear-gradient(135deg, #881337, #e11d48); }

.thumb-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  z-index: 2;
}

.badge-pill {
  background: rgba(255, 255, 255, 0.2);
  backdrop-filter: blur(4px);
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
  border: 1px solid rgba(255, 255, 255, 0.25);
}

.badge-dark {
  background: rgba(15, 23, 42, 0.35);
  padding: 4px 8px;
  border-radius: 6px;
  font-size: 11px;
  font-weight: 700;
}

.thumb-bottom {
  z-index: 2;
}

.thumb-cat {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  opacity: 0.85;
  font-weight: 700;
}

.thumb-heading {
  font-size: 20px;
  font-weight: 800;
  line-height: 1.2;
}

.card-body {
  padding: 16px;
  display: flex;
  flex-direction: column;
  flex: 1;
  justify-content: space-between;
}

.card-title {
  font-size: 17px;
  font-weight: 800;
  color: var(--text);
  margin-bottom: 6px;
}

.card-desc {
  font-size: 13px;
  color: var(--muted);
  margin-bottom: 14px;
}

.card-meta {
  display: flex;
  justify-content: space-between;
  padding-top: 10px;
  margin-bottom: 14px;
  border-top: 1px solid #f1f5f9;
  font-size: 12px;
  font-weight: 600;
  color: #64748b;
}

.start-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  padding: 12px 16px;
  border-radius: 12px;
  font-size: 14px;
  font-weight: 800;
  text-decoration: none;
  color: #fff;
  border: none;
  cursor: pointer;
  transition: opacity 0.15s ease, transform 0.1s ease;
}

.start-btn:hover {
  opacity: 0.95;
}

.btn-blue { background: #2563eb; }
.btn-emerald { background: #059669; }
.btn-purple { background: #7c3aed; }
.btn-amber { background: #ea580c; }
.btn-rose { background: #e11d48; }

/* AdSense Safe Containers (Zero CLS) */
.ad-slot {
  background: #f8fafc;
  border: 1px dashed #cbd5e1;
  border-radius: 14px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 12px;
  text-align: center;
  position: relative;
}

.ad-label {
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: #94a3b8;
  margin-bottom: 6px;
}

.ad-box-rect {
  min-height: 280px;
  width: 100%;
}

.ad-box-leader {
  min-height: 96px;
  width: 100%;
  margin: 16px 0;
}

/* Test Page Header & Quiz Interface */
.quiz-header-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 16px 20px;
  margin-top: 14px;
  margin-bottom: 16px;
  box-shadow: 0 1px 4px rgba(15, 23, 42, 0.03);
}

.quiz-header-top {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.quiz-title-group {
  display: flex;
  align-items: center;
  gap: 12px;
}

.quiz-badge-num {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: var(--primary);
  color: #fff;
  font-weight: 800;
  font-size: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.quiz-h1 {
  font-size: 20px;
  font-weight: 800;
  color: var(--text);
}

.quiz-sub {
  font-size: 12px;
  color: var(--muted);
  font-weight: 600;
}

.quiz-controls {
  display: flex;
  align-items: center;
  gap: 10px;
}

.timer-pill {
  background: #f1f5f9;
  border: 1px solid #cbd5e1;
  padding: 6px 12px;
  border-radius: 10px;
  font-family: monospace;
  font-size: 15px;
  font-weight: 800;
  color: var(--text);
}

.submit-top-btn {
  background: #059669;
  color: #fff;
  border: none;
  padding: 8px 14px;
  border-radius: 10px;
  font-size: 12px;
  font-weight: 800;
  cursor: pointer;
}

.progress-track {
  width: 100%;
  height: 8px;
  background: #f1f5f9;
  border-radius: 999px;
  overflow: hidden;
  margin-top: 12px;
}

.progress-fill {
  height: 100%;
  background: linear-gradient(90deg, #2563eb, #4f46e5);
  width: 4%;
  transition: width 0.25s ease;
}

.quiz-layout {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 18px;
  align-items: start;
}

@media (max-width: 960px) {
  .quiz-layout {
    grid-template-columns: 1fr;
  }
}

.question-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 24px;
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.04);
}

.q-tags {
  display: flex;
  justify-content: space-between;
  margin-bottom: 12px;
}

.q-tag {
  background: #eff6ff;
  color: #1d4ed8;
  font-size: 11px;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 6px;
  text-transform: uppercase;
}

.q-text {
  font-size: 20px;
  font-weight: 800;
  color: var(--text);
  margin-bottom: 20px;
  line-height: 1.4;
}

.options-list {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-bottom: 22px;
}

@media (max-width: 600px) {
  .options-list {
    grid-template-columns: 1fr;
  }
}

.opt-btn {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  text-align: left;
  padding: 14px 16px;
  border-radius: 12px;
  border: 2px solid var(--border);
  background: var(--surface);
  cursor: pointer;
  font-size: 15px;
  font-weight: 600;
  color: var(--text);
  transition: all 0.15s ease;
}

.opt-btn:hover {
  border-color: #60a5fa;
  background: #f8fafc;
}

.opt-btn.selected {
  border-color: var(--primary);
  background: #eff6ff;
  color: #1e3a8a;
}

.opt-letter {
  width: 30px;
  height: 30px;
  border-radius: 8px;
  background: #f1f5f9;
  color: #475569;
  font-weight: 800;
  font-size: 13px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.opt-btn.selected .opt-letter {
  background: var(--primary);
  color: #fff;
}

.quiz-footer-nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 16px;
  border-top: 1px solid #f1f5f9;
}

.nav-btn {
  padding: 10px 18px;
  border-radius: 10px;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  border: 1px solid #cbd5e1;
  background: #f8fafc;
  color: var(--text);
}

.nav-btn-primary {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
}

/* Question Palette 1-25 */
.side-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 18px;
  margin-bottom: 16px;
}

.palette-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 8px;
  margin: 12px 0;
}

.pal-btn {
  height: 36px;
  border-radius: 8px;
  border: 1px solid #cbd5e1;
  background: #f8fafc;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
}

.pal-btn.current {
  border: 2px solid var(--primary);
  background: #dbeafe;
  color: #1e3a8a;
}

.pal-btn.answered {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
}

/* Result & Locked WhatsApp Card */
.result-panel {
  background: var(--surface);
  border: 2px solid #93c5fd;
  border-radius: 18px;
  padding: 28px;
  margin-top: 18px;
  text-align: center;
}

.wa-cta-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  background: var(--whatsapp);
  color: #fff;
  font-size: 16px;
  font-weight: 800;
  padding: 15px 28px;
  border-radius: 14px;
  border: none;
  cursor: pointer;
  box-shadow: 0 8px 20px rgba(22, 163, 74, 0.3);
}

.wa-cta-btn:hover {
  background: var(--whatsapp-hover);
}

/* Sticky Bottom WhatsApp Share Bar */
.sticky-wa-bar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 150;
  background: linear-gradient(90deg, #052e16, #14532d, #064e3b);
  color: #fff;
  padding: 12px 18px;
  border-top: 2px solid #4ade80;
  box-shadow: 0 -8px 25px rgba(0, 0, 0, 0.25);
  display: none;
}

.sticky-wa-inner {
  max-width: 1420px;
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

/* SEO Content Box & Footer */
.seo-article {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 24px;
  margin: 24px 0;
}

.seo-article h2 {
  font-size: 20px;
  font-weight: 800;
  margin-bottom: 10px;
}

.seo-article h3 {
  font-size: 16px;
  font-weight: 700;
  margin: 16px 0 8px;
}

.seo-article p {
  font-size: 14px;
  color: var(--muted);
  margin-bottom: 10px;
}

.site-footer {
  background: #0f172a;
  color: #94a3b8;
  padding: 40px 0 70px;
  margin-top: 40px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1fr;
  gap: 24px;
  margin-bottom: 28px;
}

@media (max-width: 768px) {
  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }
}

.footer-col h4 {
  color: #fff;
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 12px;
}

.footer-col ul {
  list-style: none;
}

.footer-col li {
  margin-bottom: 8px;
}

.footer-col a {
  color: #94a3b8;
  text-decoration: none;
  font-size: 13px;
}

.footer-col a:hover {
  color: #fff;
}

.legal-box {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 28px;
  margin: 24px 0;
}

.legal-box h1 {
  font-size: 26px;
  font-weight: 800;
  margin-bottom: 12px;
}

.legal-box h2 {
  font-size: 18px;
  font-weight: 700;
  margin: 18px 0 8px;
}

.legal-box p, .legal-box li {
  font-size: 14px;
  color: var(--muted);
  margin-bottom: 10px;
}
