:root {
  --primary: #2563eb;
  --primary-hover: #1d4ed8;
  --primary-light: #eff6ff;
  --primary-dark: #1e3a8a;
  --secondary: #0f172a;
  --accent: #10b981;
  --accent-light: #ecfdf5;
  --warning: #f59e0b;
  --danger: #ef4444;
  --gray-50: #f8fafc;
  --gray-100: #f1f5f9;
  --gray-200: #e2e8f0;
  --gray-300: #cbd5e1;
  --gray-400: #94a3b8;
  --gray-500: #64748b;
  --gray-600: #475569;
  --gray-700: #334155;
  --gray-800: #1e293b;
  --gray-900: #0f172a;
  --white: #ffffff;
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
  --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
}

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

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  color: var(--gray-800);
  background-color: var(--gray-50);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

a {
  color: var(--primary);
  text-decoration: none;
  transition: color 0.15s ease;
}

a:hover {
  color: var(--primary-hover);
}

/* Header & Navigation */
.site-header {
  background: var(--white);
  border-bottom: 1px solid var(--gray-200);
  position: sticky;
  top: 0;
  z-index: 1000;
  box-shadow: var(--shadow-sm);
}

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

.logo-link {
  display: flex;
  align-items: center;
}

.logo-img {
  height: 42px;
  width: auto;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 28px;
}

.nav-link {
  font-size: 15px;
  font-weight: 600;
  color: var(--gray-700);
  padding: 6px 0;
  position: relative;
}

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

.nav-link.active::after {
  content: '';
  position: absolute;
  bottom: -25px;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--primary);
  border-radius: 3px 3px 0 0;
}

.nav-cta {
  background: var(--primary);
  color: var(--white) !important;
  padding: 10px 18px;
  border-radius: var(--radius-md);
  font-size: 14px;
  font-weight: 700;
  transition: all 0.2s ease;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.nav-cta:hover {
  background: var(--primary-hover);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(37, 99, 235, 0.25);
}

/* Hero Section */
.hero {
  background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%);
  color: var(--white);
  padding: 64px 0 54px;
  position: relative;
  overflow: hidden;
}

.hero::after {
  content: '';
  position: absolute;
  top: -50%;
  right: -20%;
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(37, 99, 235, 0.25) 0%, rgba(37, 99, 235, 0) 70%);
  border-radius: 50%;
  pointer-events: none;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 40px;
  align-items: center;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(37, 99, 235, 0.2);
  border: 1px solid rgba(147, 197, 253, 0.3);
  padding: 6px 14px;
  border-radius: 50px;
  font-size: 13px;
  font-weight: 700;
  color: #93c5fd;
  margin-bottom: 20px;
}

.hero-title {
  font-size: 44px;
  line-height: 1.15;
  font-weight: 800;
  margin-bottom: 18px;
  letter-spacing: -0.8px;
}

.hero-title span {
  background: linear-gradient(90deg, #60a5fa, #38bdf8);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-subtitle {
  font-size: 18px;
  line-height: 1.55;
  color: #cbd5e1;
  margin-bottom: 28px;
}

.hero-actions {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

.btn-primary {
  background: var(--primary);
  color: var(--white) !important;
  font-weight: 700;
  font-size: 16px;
  padding: 14px 28px;
  border-radius: var(--radius-md);
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: all 0.2s;
  box-shadow: 0 4px 14px rgba(37, 99, 235, 0.4);
}

.btn-primary:hover {
  background: var(--primary-hover);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(37, 99, 235, 0.5);
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.1);
  color: var(--white) !important;
  border: 1px solid rgba(255, 255, 255, 0.2);
  font-weight: 700;
  font-size: 16px;
  padding: 14px 24px;
  border-radius: var(--radius-md);
  transition: all 0.2s;
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.18);
  border-color: rgba(255, 255, 255, 0.4);
}

.hero-features {
  display: flex;
  gap: 24px;
  margin-top: 32px;
  padding-top: 24px;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  font-size: 13px;
  color: #94a3b8;
}

.hero-feature-item {
  display: flex;
  align-items: center;
  gap: 6px;
}

.hero-feature-item svg {
  color: var(--accent);
}

.hero-graphic {
  text-align: center;
}

.hero-graphic img, .hero-graphic svg {
  max-width: 100%;
  height: auto;
}

/* Category Quick Bar */
.category-bar-section {
  background: var(--white);
  padding: 20px 0;
  border-bottom: 1px solid var(--gray-200);
}

.category-bar {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  flex-wrap: wrap;
}

.category-pill {
  padding: 10px 22px;
  border-radius: 50px;
  font-size: 14px;
  font-weight: 700;
  background: var(--gray-100);
  color: var(--gray-700);
  border: 1px solid var(--gray-200);
  transition: all 0.2s;
  display: flex;
  align-items: center;
  gap: 8px;
}

.category-pill:hover, .category-pill.active {
  background: var(--primary-light);
  color: var(--primary);
  border-color: var(--primary);
}

/* Scorecard Section */
.scorecards-section {
  padding: 56px 0;
}

.section-header {
  text-align: center;
  max-width: 760px;
  margin: 0 auto 42px;
}

.section-tag {
  font-size: 13px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--primary);
  margin-bottom: 8px;
}

.section-title {
  font-size: 32px;
  font-weight: 800;
  color: var(--gray-900);
  margin-bottom: 12px;
  letter-spacing: -0.5px;
}

.section-subtitle {
  font-size: 16px;
  color: var(--gray-600);
}

/* Provider Scorecards */
.scorecards-list {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.scorecard-card {
  background: var(--white);
  border-radius: var(--radius-lg);
  border: 1px solid var(--gray-200);
  box-shadow: var(--shadow-sm);
  padding: 28px;
  position: relative;
  transition: all 0.2s ease;
}

.scorecard-card:hover {
  box-shadow: var(--shadow-lg);
  border-color: var(--gray-300);
}

.scorecard-card.featured {
  border: 2px solid var(--primary);
  background: linear-gradient(180deg, #ffffff 0%, #f8fafc 100%);
}

.card-top-badge {
  position: absolute;
  top: -14px;
  left: 28px;
  background: linear-gradient(90deg, #2563eb, #1d4ed8);
  color: var(--white);
  padding: 4px 14px;
  border-radius: 50px;
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  box-shadow: var(--shadow-sm);
}

.card-header-row {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1.2fr;
  gap: 20px;
  align-items: center;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--gray-100);
}

.card-brand-col {
  display: flex;
  align-items: center;
  gap: 16px;
}

.brand-rank-circle {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: var(--gray-100);
  color: var(--gray-700);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 16px;
  flex-shrink: 0;
}

.scorecard-card.featured .brand-rank-circle {
  background: var(--primary-light);
  color: var(--primary);
}

.brand-title-wrap h3 {
  font-size: 22px;
  font-weight: 800;
  color: var(--gray-900);
  line-height: 1.2;
}

.brand-category-pill {
  display: inline-block;
  font-size: 11px;
  font-weight: 700;
  background: var(--gray-100);
  color: var(--gray-600);
  padding: 2px 8px;
  border-radius: 4px;
  margin-top: 4px;
  text-transform: uppercase;
}

.card-metric-col {
  text-align: center;
}

.metric-label {
  font-size: 12px;
  font-weight: 600;
  color: var(--gray-500);
  text-transform: uppercase;
  margin-bottom: 4px;
}

.metric-value {
  font-size: 20px;
  font-weight: 800;
  color: var(--gray-900);
}

.metric-value.highlight {
  color: var(--primary);
}

.rating-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: var(--accent-light);
  color: var(--accent);
  padding: 4px 10px;
  border-radius: var(--radius-sm);
  font-weight: 800;
  font-size: 18px;
}

.rating-badge svg {
  fill: currentColor;
}

.card-cta-col {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.btn-visit {
  background: var(--accent);
  color: var(--white) !important;
  font-weight: 800;
  font-size: 15px;
  padding: 12px 18px;
  border-radius: var(--radius-md);
  text-align: center;
  display: block;
  transition: all 0.2s;
  box-shadow: 0 3px 10px rgba(16, 185, 129, 0.3);
}

.btn-visit:hover {
  background: #059669;
  transform: translateY(-1px);
  box-shadow: 0 5px 14px rgba(16, 185, 129, 0.4);
}

.cta-subtext {
  font-size: 11px;
  color: var(--gray-500);
  text-align: center;
}

/* Card Body Details */
.card-body-row {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 24px;
  margin-top: 20px;
}

.card-summary {
  font-size: 14px;
  color: var(--gray-700);
  line-height: 1.6;
  margin-bottom: 14px;
}

.card-features-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
  background: var(--gray-50);
  padding: 14px;
  border-radius: var(--radius-md);
  font-size: 13px;
}

.feature-cell {
  display: flex;
  flex-direction: column;
}

.feature-cell-name {
  font-size: 11px;
  color: var(--gray-500);
  font-weight: 600;
}

.feature-cell-val {
  font-size: 13px;
  font-weight: 700;
  color: var(--gray-800);
}

/* Pros and Cons */
.pros-cons-box {
  background: var(--gray-50);
  border-radius: var(--radius-md);
  padding: 16px;
}

.pros-list, .cons-list {
  list-style: none;
  font-size: 13px;
}

.pros-list li {
  position: relative;
  padding-left: 20px;
  margin-bottom: 8px;
  color: var(--gray-700);
}

.pros-list li::before {
  content: '✓';
  position: absolute;
  left: 0;
  color: var(--accent);
  font-weight: 800;
}

.cons-list li {
  position: relative;
  padding-left: 20px;
  margin-bottom: 6px;
  color: var(--gray-600);
}

.cons-list li::before {
  content: '✕';
  position: absolute;
  left: 0;
  color: var(--danger);
  font-weight: 800;
}

/* Comparison Table */
.comparison-table-wrap {
  overflow-x: auto;
  background: var(--white);
  border-radius: var(--radius-lg);
  border: 1px solid var(--gray-200);
  box-shadow: var(--shadow-sm);
}

.compare-table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
}

.compare-table th {
  background: var(--gray-100);
  padding: 16px 20px;
  font-size: 13px;
  font-weight: 700;
  color: var(--gray-700);
  border-bottom: 1px solid var(--gray-200);
}

.compare-table td {
  padding: 16px 20px;
  border-bottom: 1px solid var(--gray-100);
  font-size: 14px;
  color: var(--gray-800);
}

.compare-table tr:hover {
  background: var(--gray-50);
}

/* Calculator Section */
.calc-card {
  background: var(--white);
  border-radius: var(--radius-xl);
  border: 1px solid var(--gray-200);
  box-shadow: var(--shadow-md);
  padding: 36px;
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 40px;
}

.form-group {
  margin-bottom: 22px;
}

.form-label {
  display: block;
  font-size: 14px;
  font-weight: 700;
  color: var(--gray-700);
  margin-bottom: 8px;
}

.input-with-prefix {
  position: relative;
  display: flex;
  align-items: center;
}

.input-prefix {
  position: absolute;
  left: 14px;
  font-weight: 700;
  color: var(--gray-400);
}

.form-control {
  width: 100%;
  padding: 12px 14px 12px 32px;
  border: 1px solid var(--gray-300);
  border-radius: var(--radius-md);
  font-size: 16px;
  font-weight: 600;
  color: var(--gray-900);
  transition: border-color 0.15s;
}

.form-control:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.15);
}

.calc-output-box {
  background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%);
  color: var(--white);
  border-radius: var(--radius-lg);
  padding: 32px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.output-hero-label {
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: #94a3b8;
}

.output-hero-number {
  font-size: 46px;
  font-weight: 800;
  color: #38bdf8;
  line-height: 1.1;
  margin: 8px 0 20px;
}

.output-breakdown {
  border-top: 1px solid rgba(255, 255, 255, 0.15);
  padding-top: 20px;
}

.breakdown-row {
  display: flex;
  justify-content: space-between;
  font-size: 14px;
  margin-bottom: 10px;
  color: #cbd5e1;
}

.breakdown-row span:last-child {
  font-weight: 700;
  color: var(--white);
}

/* Quiz Wizard Styles */
.quiz-container {
  max-width: 760px;
  margin: 40px auto 80px;
  background: var(--white);
  border-radius: var(--radius-xl);
  border: 1px solid var(--gray-200);
  box-shadow: var(--shadow-lg);
  padding: 40px;
}

.quiz-progress-bar-wrap {
  width: 100%;
  height: 8px;
  background: var(--gray-100);
  border-radius: 4px;
  overflow: hidden;
  margin-bottom: 28px;
}

.quiz-progress-bar {
  height: 100%;
  background: linear-gradient(90deg, #2563eb, #10b981);
  width: 25%;
  transition: width 0.35s ease;
}

.quiz-meta-row {
  display: flex;
  justify-content: space-between;
  font-size: 13px;
  font-weight: 700;
  color: var(--gray-500);
  margin-bottom: 12px;
}

.quiz-step {
  display: none;
}

.quiz-step.active {
  display: block;
  animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

.quiz-question-title {
  font-size: 26px;
  font-weight: 800;
  color: var(--gray-900);
  margin-bottom: 10px;
  letter-spacing: -0.4px;
}

.quiz-question-desc {
  font-size: 15px;
  color: var(--gray-600);
  margin-bottom: 28px;
}

.quiz-options-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.quiz-option-btn {
  background: var(--gray-50);
  border: 2px solid var(--gray-200);
  border-radius: var(--radius-lg);
  padding: 22px;
  text-align: left;
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.quiz-option-btn:hover {
  background: var(--primary-light);
  border-color: var(--primary);
  transform: translateY(-2px);
  box-shadow: var(--shadow-sm);
}

.quiz-option-btn.selected {
  border-color: var(--accent);
  background: var(--accent-light);
}

.quiz-option-title {
  font-size: 17px;
  font-weight: 700;
  color: var(--gray-900);
}

.quiz-option-subtitle {
  font-size: 13px;
  color: var(--gray-600);
  line-height: 1.4;
}

/* Quiz Loading & Recommendation Result */
.quiz-loading {
  display: none;
  text-align: center;
  padding: 60px 20px;
}

.quiz-loading.active {
  display: block;
}

.quiz-spinner {
  width: 56px;
  height: 56px;
  border: 5px solid var(--gray-200);
  border-top-color: var(--primary);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
  margin: 0 auto 20px;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.quiz-results {
  display: none;
}

.quiz-results.active {
  display: block;
  animation: fadeIn 0.4s ease;
}

.quiz-match-header {
  text-align: center;
  margin-bottom: 32px;
}

.match-score-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--accent-light);
  border: 1px solid rgba(16, 185, 129, 0.3);
  color: #065f46;
  font-weight: 800;
  font-size: 14px;
  padding: 6px 16px;
  border-radius: 50px;
  margin-bottom: 12px;
}

.result-card-primary {
  background: linear-gradient(180deg, #ffffff 0%, #f8fafc 100%);
  border: 2px solid var(--primary);
  border-radius: var(--radius-xl);
  padding: 32px;
  box-shadow: var(--shadow-md);
  margin-bottom: 24px;
}

.result-card-secondary {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-lg);
  padding: 24px;
}

/* Footer */
.site-footer {
  background: var(--gray-900);
  color: var(--gray-400);
  padding: 64px 0 32px;
  font-size: 14px;
  border-top: 1px solid var(--gray-800);
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 40px;
  margin-bottom: 48px;
}

.footer-brand p {
  color: var(--gray-400);
  margin-top: 14px;
  line-height: 1.6;
  max-width: 320px;
}

.footer-col h4 {
  color: var(--white);
  font-size: 15px;
  font-weight: 700;
  margin-bottom: 18px;
}

.footer-links {
  list-style: none;
}

.footer-links li {
  margin-bottom: 10px;
}

.footer-links a {
  color: var(--gray-400);
  transition: color 0.15s;
}

.footer-links a:hover {
  color: var(--white);
}

.footer-bottom {
  border-top: 1px solid var(--gray-800);
  padding-top: 28px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 13px;
  color: var(--gray-500);
  flex-wrap: wrap;
  gap: 16px;
}

/* Responsive */
@media (max-width: 900px) {
  .hero-grid {
    grid-template-columns: 1fr;
    text-align: center;
  }
  .hero-actions {
    justify-content: center;
  }
  .hero-features {
    justify-content: center;
  }
  .card-header-row {
    grid-template-columns: 1fr;
    gap: 16px;
    text-align: center;
  }
  .card-brand-col {
    flex-direction: column;
  }
  .card-body-row {
    grid-template-columns: 1fr;
  }
  .calc-card {
    grid-template-columns: 1fr;
  }
  .quiz-options-grid {
    grid-template-columns: 1fr;
  }
  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 600px) {
  .header-inner {
    flex-direction: column;
    height: auto;
    padding: 16px 0;
    gap: 12px;
  }
  .site-nav {
    flex-wrap: wrap;
    justify-content: center;
    gap: 14px;
  }
  .hero-title {
    font-size: 32px;
  }
  .footer-grid {
    grid-template-columns: 1fr;
  }
}
