@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700;800&display=swap');

/* HealthGuide — Hale design system (front page only)
   Adapted from Hale by Claude Design (claude.ai/design) */

:root {
  --paper:     #F9FAFB; /* Himalayan Snow */
  --paper-2:   #F3F4F6; /* Warm Sand */
  --cream:     #FFFFFF;
  --ink:       #111827; /* Obsidian Slate */
  --ink-2:     #374151;
  --ink-3:     #6B7280;
  --line:      #E5E7EB;
  --line-2:    #D1D5DB;
  --moss:      #DC2626; /* Deep Crimson */
  --moss-deep: #B91C1C;
  --moss-pale: rgba(220, 38, 38, 0.1);
  --moss-tint: rgba(220, 38, 38, 0.05);
  --clay:      #1F2937; /* Obsidian Slate variant */
  --clay-pale: rgba(31, 41, 55, 0.1);
  --sky:       #06B6D4;
  --serif:     "Outfit", system-ui, sans-serif; 
  --sans:      "Outfit", system-ui, sans-serif;
  --mono:      "JetBrains Mono", "Space Mono", monospace;
  --gutter:    clamp(20px, 4vw, 56px);
  --maxw:      1200px;
  --density:   1;
}

/* ── Body ──────────────────────────────────────────────── */
body.home {
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  -webkit-font-smoothing: antialiased;
  letter-spacing: -0.01em;
}

/* ── Container ───────────────────── */
.hale-section .container,
.hale-tight .container { max-width: var(--maxw); margin: 0 auto; padding-inline: var(--gutter); }

/* ── Type utilities ────────────────────────────────────── */
.h-display {
  font-family: var(--sans);
  font-size: clamp(48px, 8vw, 96px);
  line-height: 0.9; letter-spacing: -0.04em; font-weight: 900; margin: 0;
  text-transform: uppercase;
  word-break: break-word;
  overflow-wrap: break-word;
}
.h-display em { color: var(--moss); font-style: normal; text-shadow: 0 0 20px rgba(34, 197, 94, 0.4); }

.h-1 { font-size: clamp(32px, 5vw, 56px); font-weight: 800; letter-spacing: -0.03em; line-height: 1; word-break: break-word; }
.h-2 { font-size: clamp(24px, 4vw, 40px); font-weight: 800; letter-spacing: -0.02em; }
.eyebrow {
  font-family: var(--mono);
  font-size: 11px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--ink-3);
}

/* ── Buttons ────────────────────────────────────────────── */
.hale-btn {
  padding: 16px 32px; border-radius: 12px;
  font-size: 16px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.02em;
  border: 3px solid transparent;
  display: inline-flex; align-items: center; gap: 8px; cursor: pointer; text-decoration: none;
  transition: transform .08s ease, background .15s, color .15s, border-color .15s;
}
.hale-btn-primary { 
  background: var(--moss); color: var(--paper); border-color: var(--moss);
  box-shadow: 0 0 20px rgba(34, 197, 94, 0.3);
}
.hale-btn-primary:hover { 
  background: var(--paper); color: var(--moss); 
  transform: translateY(-2px);
}
.hale-btn-outline { 
  border-color: var(--line-2); color: var(--ink); 
}
.hale-btn-outline:hover { 
  border-color: var(--moss); color: var(--moss);
}

/* ── Cards ───────────────────────────────────── */
.card { 
  background: var(--cream); border: 3px solid var(--line); border-radius: 24px; 
  transition: border-color 0.2s, transform 0.2s;
}
.card:hover { border-color: var(--moss); transform: translateY(-4px); }

/* ── Tags ─────────────────────────────────────────── */
.tag {
  background: var(--paper-2); border: 2px solid var(--line);
  font-weight: 700; color: var(--ink);
  display: inline-flex; align-items: center; gap: 6px;
  padding: 6px 10px; border-radius: 999px;
  font-family: var(--mono); font-size: 11px; letter-spacing: .06em; text-transform: uppercase;
}
.tag-moss { border-color: var(--moss); color: var(--moss); }

.spark { filter: drop-shadow(0 0 8px var(--moss)); }

/* ── Benchmark Ribbon ───────────────────────────────────── */
.benchmark-ribbon {
  background: var(--moss);
  padding-block: 16px;
}
.benchmark-inner {
  display: flex;
  justify-content: space-between;
  gap: 32px;
  align-items: center;
  flex-wrap: wrap;
}
.benchmark-item { display: flex; flex-direction: column; gap: 4px; }
.benchmark-val {
  font-family: var(--mono); font-weight: 800; color: var(--paper); font-style: normal;
  font-size: 24px;
}
.benchmark-item .eyebrow { color: rgba(0,0,0,0.6); font-weight: 800; }
@media (max-width: 640px) {
  .benchmark-inner { justify-content: center; text-align: center; }
}

/* ── Section spacing ────────────────────────────────────── */
.hale-section { padding-block: 60px; }
.hale-tight   { padding-block: 40px; }
.hale-divider { height: 1px; background: var(--line); border: 0; margin: 0; }

/* ═══════════════════════════════════════════════════════════
   HERO
   ══════════════════════════════════════════════════════════ */
.hero-inner {
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  gap: clamp(32px, 5vw, 80px);
  align-items: center;
}
.hero-value-prop { color: var(--clay); font-weight: 800; text-transform: uppercase; margin-bottom: 32px; display: flex; align-items: center; gap: 8px; font-size: 13px; font-family: var(--mono); }
.hero-eye { display: flex; align-items: center; gap: 12px; margin-bottom: 28px; }
.hero-lede { margin: 28px 0 16px; max-width: 50ch; font-size: clamp(16px, 1.1vw, 18px); color: var(--ink-2); line-height: 1.55; }
.hero-cta { display: flex; gap: 12px; flex-wrap: wrap; margin-bottom: 32px; }

.hero-quick-calc { background: var(--paper-2); border-color: var(--moss); padding: 16px 20px; max-width: 500px; margin-bottom: 48px; }
.quick-calc-inputs { display: flex; gap: 8px; margin-bottom: 12px; }
.hero-quick-calc .field-input { 
  background: var(--paper); border: 2px solid var(--line); color: var(--ink);
  border-radius: 10px; flex: 1; padding: 10px 14px;
}
.hero-quick-calc .field-input:focus { border-color: var(--moss); }

.hero-foot {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 24px; padding-top: 28px; border-top: 1px solid var(--line);
}
@media (max-width: 640px) {
  .hero-foot { grid-template-columns: 1fr; gap: 16px; text-align: center; }
}
.hero-stat .stat-num { color: var(--moss); font-weight: 900; font-style: normal; font-size: 36px; line-height: 1; }
.hero-stat .stat-label { font-family: var(--mono); font-size: 11px; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-3); margin: 8px 0 0; line-height: 1.4; }

.hero-collage {
  position: relative;
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  grid-template-rows: 280px 220px;
  gap: 14px;
}
.hero-slot-1 { grid-column: 1 / 2; grid-row: 1 / 3; height: 100%; border-radius: 20px; background: var(--line-2); overflow: hidden; }
.hero-slot-2 { grid-column: 2 / 3; grid-row: 2 / 3; border-radius: 14px; background: var(--line-2); overflow: hidden; }
.hero-card {
  grid-column: 2 / 3; grid-row: 1 / 2;
  padding: 18px 18px 16px; border-radius: 16px;
  display: flex; flex-direction: column; gap: 8px;
}
.hero-card-title { font-size: 13px; color: var(--ink-3); font-family: var(--mono); letter-spacing: .06em; text-transform: uppercase; }
.hero-card-value { font-family: var(--sans); font-size: 22px; font-weight: 800; }
.hero-card-bars {
  display: flex; gap: 4px; align-items: flex-end; height: 38px; margin-top: 6px;
}
.hero-card-bars span { flex: 1; background: var(--moss-deep); border-radius: 2px; min-height: 30%; }
.hero-card-foot { display: flex; gap: 6px; margin-top: 8px; flex-wrap: wrap; }
.hero-card-2 {
  position: absolute; left: -28px; bottom: -18px; width: 62%;
  padding: 16px 18px 14px; border-radius: 14px; z-index: 2;
}

@media (max-width: 960px) {
  .hero-inner { grid-template-columns: 1fr; }
  .hero-collage { grid-template-rows: 240px 200px; }
  .hero-card-2 { position: relative; left: 0; bottom: 0; width: 100%; }
}

/* ── How It Works ─────────────────── */
.hiw-eyebrow { text-align: center; margin-bottom: 32px; }
.hiw-steps { display: flex; align-items: flex-start; gap: 16px; }
.hiw-step { flex: 1; display: flex; gap: 16px; align-items: flex-start; }
.hiw-num {
  width: 40px; height: 40px; border-radius: 50%;
  background: var(--moss-pale); color: var(--moss);
  display: flex; align-items: center; justify-content: center;
  font-family: var(--sans); font-weight: 800; font-size: 18px; flex-shrink: 0;
}
.hiw-title { font-family: var(--sans); font-size: 19px; font-weight: 800; margin: 0 0 6px; }
.hiw-desc  { font-size: 14px; color: var(--ink-3); line-height: 1.55; margin: 0; }
.hiw-arrow { font-size: 22px; color: var(--line-2); margin-top: 9px; flex-shrink: 0; }

@media (max-width: 640px) {
  .hiw-steps { flex-direction: column; }
  .hiw-arrow { display: none; }
}

/* ── Calculator Grid ──────────────── */
.hale-calc-head { margin-bottom: 36px; display: flex; flex-direction: column; gap: 4px; }
.calc-head-sub { font-size: 14px; color: var(--ink-3); margin: 10px 0 0; }
.calc-filters { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 16px; }
.calc-filter {
  padding: 7px 18px; border-radius: 100px; border: 1px solid var(--line);
  background: transparent; color: var(--ink); font-family: var(--sans); font-size: 13.5px;
  cursor: pointer; transition: background .14s, border-color .14s, color .14s;
}
.calc-filter:hover { border-color: var(--moss); color: var(--moss); }
.calc-filter.active { background: var(--moss); color: var(--paper); border-color: var(--moss); }

.hale-calc-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 12px;
}
.hale-calc-card {
  border: 3px solid var(--line); border-radius: 20px;
  padding: 32px; display: flex; flex-direction: column; gap: 10px;
  background: var(--cream); text-decoration: none; color: var(--ink);
  transition: transform .15s ease, border-color .15s ease, box-shadow .15s ease;
}
.hale-calc-card:hover { border-color: var(--clay); transform: translateY(-3px); box-shadow: 0 0 30px rgba(139, 92, 246, 0.2); }
.hale-calc-icon { font-size: 26px; line-height: 1; }
.hale-calc-name { font-weight: 800; text-transform: uppercase; font-size: 20px; line-height: 1.1; }
.hale-calc-desc { font-size: 13.5px; color: var(--ink-3); line-height: 1.45; flex: 1; }
.hale-calc-arrow { font-family: var(--mono); color: var(--moss); font-size: 14px; margin-top: 6px; }
.hale-calc-card.is-hidden { display: none; }

.calc-badge {
  display: inline-block; font-family: var(--mono); font-size: 10px; letter-spacing: .08em; text-transform: uppercase;
  padding: 3px 9px; border-radius: 100px; align-self: flex-start; margin-bottom: 2px;
}
.calc-badge--popular { background: var(--clay-pale); color: var(--clay); }

/* ── Pro Squad / Articles ─────────── */
.prin-head { display: flex; flex-direction: column; gap: 4px; margin-bottom: 36px; max-width: 56ch; }
.articles { display: grid; grid-template-columns: 1.15fr 1fr; gap: 36px; }
.feat-lead {
  background: var(--cream); border: 1px solid var(--line); border-radius: 24px;
  padding: 28px; display: flex; flex-direction: column; gap: 22px;
  text-decoration: none; color: inherit; transition: transform .15s ease;
}
.feat-lead:hover { transform: translateY(-3px); border-color: var(--moss); }
.feat-slot { aspect-ratio: 4 / 3; border-radius: 12px; overflow: hidden; background: var(--line-2); }
.feat-slot img { width: 100%; height: 100%; object-fit: cover; }
.feat-body { display: flex; flex-direction: column; gap: 6px; }
.byline { display: flex; gap: 10px; align-items: center; margin-top: 14px; font-size: 13.5px; color: var(--ink-3); }
.byline .dot { width: 3px; height: 3px; border-radius: 50%; background: currentColor; }
.feat-grid { display: flex; flex-direction: column; gap: 18px; }
.feat-sm {
  display: grid; grid-template-columns: 0.9fr 1.1fr; gap: 18px;
  background: var(--paper-2); border: 1px solid var(--line); border-radius: 18px;
  padding: 16px; text-decoration: none; color: inherit; transition: transform .15s ease;
}
.feat-sm:hover { transform: translateY(-2px); border-color: var(--moss); }
.feat-sm-slot { aspect-ratio: 1 / 1; border-radius: 10px; overflow: hidden; background: var(--line-2); }
.feat-sm-slot img { width: 100%; height: 100%; object-fit: cover; }
.feat-sm-body { display: flex; flex-direction: column; gap: 6px; justify-content: center; }
.feat-sm-body .h-3 { font-size: 16px; font-weight: 800; }

@media (max-width: 1080px) { .articles { grid-template-columns: 1fr; } }
@media (max-width: 580px)  { .feat-sm { grid-template-columns: 1fr; } .feat-sm-slot { aspect-ratio: 16/10; } }

/* ── Library ──────────────────────── */
.library { margin-top: 80px; }
.library-head { margin-bottom: 28px; }
.library-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.topic {
  position: relative; display: flex; flex-direction: column; gap: 10px;
  padding: 24px 22px 42px; border-radius: 16px; text-decoration: none; color: inherit;
  transition: transform .15s ease, border-color .15s ease;
  border: 1px solid var(--line);
}
.topic:hover { transform: translateY(-2px); }
.topic-name  { font-family: var(--sans); font-weight: 800; font-size: 28px; line-height: 1; color: var(--ink); }
.topic-count { font-family: var(--mono); font-size: 11px; color: var(--ink-3); letter-spacing: .08em; }
.topic-arrow { position: absolute; right: 18px; bottom: 16px; font-family: var(--mono); color: var(--ink-3); }

@media (max-width: 880px) { .library-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 480px) { .library-grid { grid-template-columns: 1fr; } }

/* ── Newsletter ─────────────────── */
.news-card {
  display: grid; grid-template-columns: 1.1fr 1fr; gap: clamp(32px, 5vw, 64px); align-items: center;
  background: var(--paper-2); border: 4px solid var(--moss); border-radius: 28px; padding: clamp(32px, 4vw, 60px);
}
.news-l { display: flex; flex-direction: column; }
.news-form { display: flex; gap: 8px; margin-top: 24px; max-width: 480px; flex-wrap: wrap; }
.news-form input {
  flex: 1; min-width: 200px; padding: 12px 16px; border-radius: 12px; font: inherit; outline: none;
  background: var(--paper); border: 2px solid var(--line); color: var(--ink);
}
.news-form input:focus { border-color: var(--moss); }
.news-success { display: none; margin-top: 16px; color: var(--moss); font-family: var(--sans); font-weight: 800; font-size: 18px; }
.news-r { display: flex; flex-direction: column; gap: 14px; background: var(--cream); border-radius: 20px; padding: 28px; border: 3px solid var(--line); }
.news-tag-row { display: flex; gap: 8px; flex-wrap: wrap; }
@media (max-width: 880px) { .news-card { grid-template-columns: 1fr; } }

/* ── Daily Ritual (Ritual) ────────── */
#ritual { position: relative; overflow: hidden; }
#ritual::before {
  content: ""; position: absolute; top: -100px; right: -100px;
  width: 400px; height: 400px; border-radius: 50%;
  background: var(--moss-pale); filter: blur(80px); z-index: -1;
}

.check-card { border-width: 4px; padding: 32px; background: var(--cream); position: relative; z-index: 1; }
.opts { display: grid; gap: 12px; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); }
.opt { border-width: 2px; border-radius: 16px; padding: 16px; cursor: pointer; border-color: var(--line); background: var(--paper); transition: 0.2s; position: relative; }
.opt.selected { border-color: var(--moss); background: var(--moss-pale); }
.opt-label { font-weight: 800; font-size: 20px; display: block; }
.opt-hint { font-size: 13px; color: var(--ink-3); }
.opt-check { position: absolute; top: 12px; right: 12px; color: var(--moss); font-weight: 800; }

.scale { display: flex; flex-direction: column; gap: 24px; padding: 12px 0; }
.scale-track { display: flex; align-items: flex-end; gap: 6px; height: 84px; }
.scale-tick { flex: 1; height: 100%; border: 0; background: transparent; padding: 0; cursor: pointer; display: flex; align-items: flex-end; }
.scale-tick span { width: 100%; border-radius: 2px; background: var(--line); transition: 0.2s; }
.scale-tick.cur span { box-shadow: 0 0 15px var(--moss); background: var(--moss); }
.scale-tick.on span { background: var(--moss); }
.scale-labels { display: flex; justify-content: space-between; font-family: var(--mono); font-size: 12px; color: var(--ink-3); }

/* ── Check Head ── */
.check-head {
  display: grid; grid-template-columns: 1.2fr 1fr; gap: 48px;
  align-items: center; margin-bottom: 48px;
}
.check-head-content { display: flex; flex-direction: column; }
.check-head-visual { display: flex; flex-direction: column; gap: 24px; }

.check-progress-bar-wrap { 
  height: 8px; background: var(--line); border-radius: 4px; 
  position: relative; width: 100%; 
}
.check-progress-bar-fill { 
  height: 100%; background: var(--clay); border-radius: 4px; 
  transition: width 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.check-mini-report {
  background: var(--paper-2); border: 2px solid var(--line); border-radius: 16px;
  padding: 16px; display: flex; flex-direction: column; gap: 10px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.03);
}
.mini-report-title { font-family: var(--mono); font-size: 10px; text-transform: uppercase; color: var(--ink-3); letter-spacing: 0.05em; }
.mini-bar-row { height: 6px; background: var(--line); border-radius: 3px; overflow: hidden; }
.mini-bar { height: 100%; border-radius: 3px; }

.check-shape-wrap { position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); width: 120%; height: 120%; pointer-events: none; z-index: 1; transition: transform 0.6s ease, opacity 0.6s ease; }

@media (max-width: 768px) {
  .check-head { grid-template-columns: 1fr; gap: 32px; text-align: center; }
  .check-head-content { align-items: center; }
  .check-mini-report { display: none; }
}

/* ── Summary ── */
.summary { display: grid; grid-template-columns: 1.2fr 1fr; gap: 40px; }
.summary-chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 24px; }
.summary-actions { margin-top: 32px; }
.summary-r { background: var(--paper-2); padding: 24px; border-radius: 20px; border: 1px solid var(--line); }
.reads { list-style: none; padding: 0; margin: 16px 0 0; display: flex; flex-direction: column; gap: 12px; }
.read { display: flex; justify-content: space-between; align-items: center; text-decoration: none; color: inherit; padding: 12px; background: var(--cream); border-radius: 12px; border: 1px solid var(--line); transition: 0.2s; }
.read:hover { border-color: var(--moss); transform: translateX(4px); }
.read-arrow { color: var(--moss); font-weight: 800; }

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

/* ── Tracker ── */
.tracker-card { padding: 32px; }
.tracker-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.metric { border-radius: 18px; padding: 22px; display: flex; flex-direction: column; gap: 8px; border: 2px solid var(--line); background: var(--cream); }
.metric-wide { grid-column: span 4; }
.metric-head { display: flex; justify-content: space-between; align-items: center; }
.metric-value .serif { font-size: 40px; font-weight: 800; line-height: 1; }
.tracker-top { display: flex; justify-content: space-between; align-items: center; margin-bottom: 22px; flex-wrap: wrap; gap: 12px; }
@media (max-width: 1080px) { .tracker-grid { grid-template-columns: repeat(2, 1fr); } .metric-wide { grid-column: span 2; } }
@media (max-width: 580px)  { .tracker-grid { grid-template-columns: 1fr; } .metric-wide { grid-column: span 1; } }

/* ── Tracker Table ── */
.tracker-table-wrap { width: 100%; overflow-x: auto; margin-bottom: 24px; border-radius: 20px; border: 2px solid var(--line); background: var(--cream); }
.tracker-table { width: 100%; border-collapse: collapse; text-align: left; }
.tracker-table th, .tracker-table td { padding: 16px 20px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.tracker-table th { font-family: var(--mono); font-size: 11px; text-transform: uppercase; color: var(--ink-3); letter-spacing: 0.1em; background: var(--paper-2); }
.tracker-table tr:last-child td { border-bottom: 0; }
.tracker-table .pillar-tag { font-weight: 800; font-size: 14px; display: flex; align-items: center; gap: 8px; }
.tracker-table .status-cell { font-family: var(--sans); font-weight: 700; font-size: 16px; }
.tracker-table .progress-cell { width: 80px; }
.tracker-table .dot { width: 8px; height: 8px; border-radius: 50%; display: inline-block; }

@media (max-width: 640px) {
  .tracker-table th:nth-child(3), .tracker-table td:nth-child(3) { display: none; } /* Hide target on mobile */
}
