/* ============================================================
   HeartScore — Biological Age Calculator Page CSS
   Extends global style.css — page-specific rules only
   ============================================================ */
 
/* ── Bio Age Calculator Form ─────────────────────────────── */
.bio-calc-header {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 20px; flex-wrap: wrap; gap: 8px;
}
.bio-calc-header h2 { margin: 0; font-size: 18px; }
 
.bio-form-section {
  border-bottom: 1px solid var(--slate-100);
  padding-bottom: 20px;
  margin-bottom: 20px;
}
.bio-form-section:last-of-type { border-bottom: none; }
.bio-section-label {
  font-family: 'Lexend', sans-serif;
  font-weight: 700;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--slate-500);
  margin-bottom: 14px;
  display: flex; align-items: center; gap: 6px;
}
.bio-section-label span { color: var(--vitred); font-size: 16px; }
 
/* Slider Fields */
.slider-field { margin-bottom: 16px; }
.slider-label-row {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 6px;
}
.slider-label {
  font-family: 'Lexend', sans-serif;
  font-weight: 600; font-size: 13px;
  color: var(--navy);
}
.slider-value-badge {
  background: var(--navy);
  color: #fff;
  font-family: 'Lexend', sans-serif;
  font-size: 12px; font-weight: 700;
  padding: 2px 10px; border-radius: 20px;
  min-width: 52px; text-align: center;
}
.slider-value-badge.good { background: #16a34a; }
.slider-value-badge.warn { background: #ca8a04; }
.slider-value-badge.bad  { background: #dc2626; }
 
input[type="range"] {
  -webkit-appearance: none;
  appearance: none;
  width: 100%; height: 6px;
  border-radius: 6px;
  outline: none; cursor: pointer;
  background: var(--slate-200);
}
input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 18px; height: 18px;
  border-radius: 50%;
  background: var(--navy);
  border: 3px solid #fff;
  box-shadow: 0 2px 6px rgba(0,0,0,0.2);
  cursor: pointer;
}
input[type="range"]::-moz-range-thumb {
  width: 18px; height: 18px;
  border-radius: 50%;
  background: var(--navy);
  border: 3px solid #fff;
  cursor: pointer;
}
.slider-range-labels {
  display: flex; justify-content: space-between;
  font-family: 'Inter', sans-serif;
  font-size: 10px; color: var(--slate-400);
  margin-top: 2px;
}
 
/* Select Rows */
.select-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-bottom: 14px; }
.select-row-full { margin-bottom: 14px; }
 
/* Result Display */
#bio-result-area { display: none; }
#bio-result-area.show { display: block; }
 
.bio-result-header {
  text-align: center;
  padding: 24px 0 16px;
}
.bio-age-display {
  font-family: 'Lexend', sans-serif;
  font-size: 72px; font-weight: 800;
  line-height: 1;
  margin-bottom: 4px;
}
.bio-age-label {
  font-family: 'Inter', sans-serif;
  font-size: 13px; color: var(--slate-500);
  margin-bottom: 12px;
}
.bio-age-vs {
  display: flex; align-items: center; justify-content: center;
  gap: 12px; margin-bottom: 16px;
}
.vs-item { text-align: center; }
.vs-num {
  font-family: 'Lexend', sans-serif;
  font-weight: 800; font-size: 28px;
}
.vs-lbl {
  font-family: 'Inter', sans-serif;
  font-size: 11px; color: var(--slate-500);
}
.vs-sep {
  font-family: 'Lexend', sans-serif;
  font-weight: 700; font-size: 18px;
  color: var(--slate-300);
}
 
/* Age Meter Bar */
.age-meter { margin: 16px 0; }
.age-meter-track {
  height: 12px; border-radius: 8px;
  background: linear-gradient(90deg, #2ECC71 0%, #F1C40F 45%, #ea580c 70%, #dc2626 100%);
  position: relative;
}
.age-meter-needle {
  position: absolute; top: -6px;
  width: 4px; height: 24px;
  background: var(--navy);
  border-radius: 2px;
  transform: translateX(-50%);
  transition: left 0.8s ease;
  box-shadow: 0 2px 6px rgba(0,0,0,0.25);
}
.age-meter-labels {
  display: flex; justify-content: space-between;
  font-family: 'Inter', sans-serif;
  font-size: 10px; color: var(--slate-400);
  margin-top: 6px;
}
 
/* Breakdown Bars */
.breakdown-item {
  display: flex; align-items: center;
  gap: 10px; margin-bottom: 10px;
}
.breakdown-label {
  font-family: 'Lexend', sans-serif;
  font-size: 12px; font-weight: 600;
  color: var(--navy); min-width: 100px;
}
.breakdown-bar-wrap {
  flex: 1; height: 8px;
  background: var(--slate-100);
  border-radius: 6px; overflow: hidden;
}
.breakdown-bar {
  height: 100%; border-radius: 6px;
  transition: width 0.7s ease;
}
.bar-green  { background: #16a34a; }
.bar-yellow { background: #ca8a04; }
.bar-orange { background: #ea580c; }
.bar-red    { background: #dc2626; }
.breakdown-score {
  font-family: 'Lexend', sans-serif;
  font-size: 12px; font-weight: 700;
  min-width: 30px; text-align: right;
}
 
/* Tips Panel */
.tips-grid {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: 10px; margin-top: 12px;
}
.tip-card {
  background: var(--slate-50);
  border: 1px solid var(--slate-100);
  border-radius: 10px; padding: 12px;
}
.tip-icon { font-size: 22px; margin-bottom: 6px; }
.tip-title {
  font-family: 'Lexend', sans-serif;
  font-weight: 700; font-size: 12px;
  color: var(--navy); margin-bottom: 4px;
}
.tip-body {
  font-family: 'Inter', sans-serif;
  font-size: 11px; color: var(--slate-600);
  line-height: 1.6; margin: 0;
}
 
/* Comparison Table */
.compare-table { width: 100%; border-collapse: collapse; font-family: 'Inter', sans-serif; font-size: 13px; }
.compare-table th {
  background: var(--navy); color: #fff;
  font-family: 'Lexend', sans-serif; font-weight: 600;
  font-size: 12px; padding: 10px 14px; text-align: left;
}
.compare-table th:first-child { border-radius: 8px 0 0 0; }
.compare-table th:last-child  { border-radius: 0 8px 0 0; }
.compare-table td { padding: 10px 14px; color: var(--slate-600); border-bottom: 1px solid var(--slate-100); }
.compare-table tr:last-child td { border-bottom: none; }
.compare-table tr:nth-child(even) td { background: var(--slate-50); }
.compare-table .check { color: #16a34a; font-size: 16px; }
.compare-table .cross { color: #dc2626; font-size: 16px; }
 
/* Method Cards */
.method-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.method-card {
  background: #fff; border: 1px solid var(--slate-100);
  border-radius: 14px; padding: 20px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.04);
}
.method-icon { font-size: 28px; margin-bottom: 10px; }
.method-title {
  font-family: 'Lexend', sans-serif;
  font-weight: 700; font-size: 15px; color: var(--navy); margin-bottom: 8px;
}
.method-desc { font-family: 'Inter', sans-serif; font-size: 13px; color: var(--slate-600); line-height: 1.65; margin: 0; }
.method-tag {
  display: inline-block; margin-top: 10px;
  padding: 2px 10px; border-radius: 20px;
  font-family: 'Lexend', sans-serif; font-size: 11px; font-weight: 600;
}
.tag-free     { background: #dcfce7; color: #16a34a; }
.tag-clinical { background: #dbeafe; color: #1d4ed8; }
.tag-advanced { background: #fce7f3; color: #9d174d; }
 
/* Biomarker Chips */
.biomarker-grid { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.biomarker-chip {
  display: flex; align-items: center; gap: 6px;
  background: #f1f5f9; border: 1px solid var(--slate-200);
  border-radius: 20px; padding: 5px 12px;
  font-family: 'Lexend', sans-serif; font-size: 12px;
  font-weight: 600; color: var(--navy);
}
.biomarker-chip span { font-size: 14px; }
 
/* Content Prose */
.content-prose h2 { margin-top: 32px; margin-bottom: 14px; }
.content-prose h3 { margin-top: 24px; margin-bottom: 10px; }
.content-prose p  { margin-bottom: 16px; }
.content-prose ul, .content-prose ol { margin: 0 0 16px 22px; }
.content-prose li { font-family: 'Inter', sans-serif; color: var(--slate-600); line-height: 1.75; margin-bottom: 6px; font-size: 15px; }
 
/* Stat Bar (hero stats) */
.bio-stat-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin: 24px 0; }
.bio-stat-box {
  background: rgba(255,255,255,0.6);
  border: 1px solid rgba(255,255,255,0.8);
  border-radius: 12px; padding: 14px 12px;
  text-align: center; backdrop-filter: blur(10px);
}
.bio-stat-val {
  font-family: 'Lexend', sans-serif;
  font-weight: 800; font-size: 22px;
  color: var(--navy); line-height: 1.1;
}
.bio-stat-val.red { color: var(--vitred); }
.bio-stat-label {
  font-family: 'Inter', sans-serif;
  font-size: 11px; color: var(--slate-500);
  margin-top: 4px;
}
 
/* Share strip */
.bio-share-row {
  display: flex; gap: 8px; flex-wrap: wrap;
  margin-top: 16px;
}
.bio-share-btn {
  flex: 1; min-width: 80px;
  padding: 9px 4px; border-radius: 10px;
  border: none; cursor: pointer;
  font-family: 'Lexend', sans-serif; font-size: 11px; font-weight: 600;
  color: #fff; transition: transform 0.2s;
}
.bio-share-btn:hover { transform: translateY(-2px); }
.bsb-wa { background: #25D366; }
.bsb-fb { background: #1877f2; }
.bsb-tw { background: #0f0f0f; }
.bsb-em { background: var(--navy); }
 
/* Score Save/Track */
.track-box {
  background: linear-gradient(135deg, #f0fdf4, #dcfce7);
  border: 1px solid #86efac;
  border-radius: 12px; padding: 16px; margin-top: 16px;
}
.track-note {
  font-family: 'Inter', sans-serif;
  font-size: 12px; color: #15803d; line-height: 1.6; margin: 0;
}
 
/* Hero disclaimer */
.bio-disclaimer {
  font-family: 'Inter', sans-serif;
  font-size: 12px; color: var(--slate-500);
  line-height: 1.6; background: var(--slate-50);
  border-radius: 8px; padding: 10px 14px;
  border-left: 3px solid var(--slate-300);
  margin-top: 16px;
}
 
/* Responsive */
@media (max-width: 768px) {
  .bio-age-display { font-size: 52px; }
  .select-row { grid-template-columns: 1fr; }
  .tips-grid { grid-template-columns: 1fr; }
  .method-grid { grid-template-columns: 1fr; }
  .bio-stat-row { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 480px) {
  .bio-stat-row { grid-template-columns: 1fr 1fr; }
}