/* ============================================================
   HomeLeafs Answer Pages — Shared Stylesheet
   Design tokens mirror HOMELEAFS_STYLE_GUIDE.md
   Light palette only. No dark colors.
   ============================================================ */

/* --- Tokens ------------------------------------------------ */
:root {
  --hl-green:        #7CB342;
  --hl-green-light:  rgba(124, 179, 66, 0.10);
  --hl-navy:         #0f172a;
  --hl-blue:         #1e3a8a;
  --hl-blue-mid:     #2563eb;
  --hl-blue-light:   rgba(37, 99, 235, 0.08);
  --hl-text:         #475569;
  --hl-subtext:      #64748b;
  --hl-border-soft:  #e2e8f0;
  --hl-bg:           linear-gradient(135deg, #f8fafc 0%, #eff6ff 55%, #eef2ff 100%);
  --hl-card-shadow:  0 8px 30px rgba(0, 0, 0, 0.04);
  --hl-hover-shadow: 0 24px 60px rgba(15, 23, 42, 0.10);
  --hl-chip-shadow:  0 1px 4px rgba(15, 23, 42, 0.06);
  --radius-card:     1.25rem;   /* rounded-2xl */
  --radius-large:    1.5rem;    /* rounded-3xl */
}

/* --- Reset ------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  font-family: 'Lato', sans-serif;
  font-weight: 400;
  font-size: 1rem;
  line-height: 1.7;
  color: var(--hl-text);
  background: var(--hl-bg);
  min-height: 100vh;
}

/* --- Typography ------------------------------------------- */
h1, h2, h3, h4 {
  font-family: 'Lato', sans-serif;
  color: var(--hl-navy);
  line-height: 1.25;
}
h1 { font-weight: 900; font-size: clamp(1.75rem, 4vw, 2.75rem); }
h2 { font-weight: 700; font-size: clamp(1.25rem, 2.5vw, 1.75rem); }
h3 { font-weight: 700; font-size: clamp(1rem, 2vw, 1.25rem); }
h4 { font-weight: 700; font-size: 0.95rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--hl-subtext); }

p { margin-bottom: 1rem; color: var(--hl-text); }
p:last-child { margin-bottom: 0; }

a { color: var(--hl-blue-mid); text-decoration: none; }
a:hover { text-decoration: underline; }

strong { font-weight: 700; color: var(--hl-navy); }

/* --- Layout ----------------------------------------------- */
.page-wrap {
  max-width: 820px;
  margin: 0 auto;
  padding: 0 1.25rem 5rem;
}

/* --- Nav -------------------------------------------------- */
.site-nav {
  padding: 1.25rem 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 2rem;
}

.nav-logo {
  font-weight: 900;
  font-size: 1.1rem;
  color: var(--hl-navy);
  display: flex;
  align-items: center;
  gap: 0.5rem;
  text-decoration: none;
}
.nav-logo span.leaf { color: var(--hl-green); font-size: 1.3rem; }

.nav-cta {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  background: var(--hl-green);
  color: #fff;
  font-weight: 700;
  font-size: 0.8rem;
  padding: 0.55rem 1.1rem;
  border-radius: 999px;
  text-decoration: none;
  box-shadow: var(--hl-chip-shadow);
  transition: box-shadow 0.2s, transform 0.2s;
}
.nav-cta:hover {
  box-shadow: 0 8px 24px rgba(124, 179, 66, 0.3);
  transform: translateY(-1px);
  text-decoration: none;
}

/* --- Breadcrumb ------------------------------------------- */
.breadcrumb {
  font-size: 0.78rem;
  color: var(--hl-subtext);
  margin-bottom: 1.75rem;
  display: flex;
  align-items: center;
  gap: 0.4rem;
  flex-wrap: wrap;
}
.breadcrumb a { color: var(--hl-subtext); }
.breadcrumb a:hover { color: var(--hl-blue-mid); }
.breadcrumb .sep { color: var(--hl-border-soft); }

/* --- Hero ------------------------------------------------- */
.page-hero {
  margin-bottom: 2.5rem;
}

.page-tag {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  background: var(--hl-green-light);
  color: var(--hl-green);
  font-weight: 700;
  font-size: 0.7rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 0.35rem 0.85rem;
  border-radius: 999px;
  box-shadow: var(--hl-chip-shadow);
  margin-bottom: 1rem;
}

.page-hero h1 { margin-bottom: 1rem; }

.page-hero .lead {
  font-size: 1.1rem;
  color: var(--hl-text);
  max-width: 680px;
  margin-bottom: 1.25rem;
}

.verified-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--hl-subtext);
}
.verified-badge .dot {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--hl-green);
  box-shadow: 0 0 6px rgba(124, 179, 66, 0.5);
}

/* --- Cards ------------------------------------------------ */
.card {
  background: rgba(255, 255, 255, 0.72);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-radius: var(--radius-card);
  padding: 2rem;
  box-shadow: var(--hl-card-shadow);
  margin-bottom: 1.5rem;
  transition: box-shadow 0.25s, transform 0.25s;
}
.card:hover { box-shadow: var(--hl-hover-shadow); }

.card-section { margin-bottom: 2rem; }

/* --- Answer Block ----------------------------------------- */
.answer-block {
  background: linear-gradient(135deg, rgba(30, 58, 138, 0.05) 0%, rgba(37, 99, 235, 0.04) 100%);
  border-radius: var(--radius-card);
  padding: 1.75rem 2rem;
  box-shadow: var(--hl-card-shadow);
  margin-bottom: 2rem;
}

.answer-block h2 {
  color: var(--hl-blue);
  margin-bottom: 0.75rem;
}

.answer-block p {
  font-size: 1.05rem;
  line-height: 1.75;
}

/* --- Step List -------------------------------------------- */
.step-list {
  list-style: none;
  counter-reset: steps;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin: 1rem 0;
}

.step-list li {
  counter-increment: steps;
  display: flex;
  align-items: flex-start;
  gap: 0.85rem;
}

.step-list li::before {
  content: counter(steps);
  flex-shrink: 0;
  width: 1.75rem; height: 1.75rem;
  background: var(--hl-blue);
  color: #fff;
  font-weight: 900;
  font-size: 0.75rem;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 0.15rem;
}

/* --- Avoid List ------------------------------------------- */
.avoid-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  margin: 1rem 0;
}

.avoid-list li {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  font-size: 0.95rem;
}

.avoid-list li::before {
  content: '✕';
  flex-shrink: 0;
  width: 1.5rem; height: 1.5rem;
  background: rgba(239, 68, 68, 0.08);
  color: #dc2626;
  font-weight: 900;
  font-size: 0.65rem;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 0.15rem;
}

/* --- CTA Card --------------------------------------------- */
.cta-card {
  background: linear-gradient(135deg, #1e3a8a 0%, #312e81 100%);
  border-radius: var(--radius-large);
  padding: 2.5rem;
  box-shadow: 0 24px 48px rgba(30, 58, 138, 0.20);
  margin: 2.5rem 0;
  text-align: center;
}

.cta-card h3 { color: #fff; font-size: 1.35rem; margin-bottom: 0.6rem; }
.cta-card p  { color: rgba(255,255,255,0.75); font-size: 0.92rem; margin-bottom: 1.5rem; }

.cta-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--hl-green);
  color: #fff;
  font-weight: 900;
  font-size: 0.875rem;
  letter-spacing: 0.04em;
  padding: 0.875rem 2rem;
  border-radius: 999px;
  text-decoration: none;
  box-shadow: 0 8px 24px rgba(124, 179, 66, 0.35);
  transition: box-shadow 0.2s, transform 0.2s;
}
.cta-btn:hover {
  box-shadow: 0 12px 32px rgba(124, 179, 66, 0.45);
  transform: translateY(-2px);
  text-decoration: none;
}

.cta-card .sub-link {
  display: block;
  margin-top: 1rem;
  font-size: 0.75rem;
  color: rgba(255,255,255,0.5);
}
.cta-card .sub-link a { color: rgba(255,255,255,0.65); }

/* --- Alert / Caution -------------------------------------- */
.alert {
  border-radius: var(--radius-card);
  padding: 1.25rem 1.5rem;
  box-shadow: var(--hl-card-shadow);
  margin-bottom: 1.25rem;
}
.alert-caution {
  background: rgba(245, 158, 11, 0.07);
}
.alert-caution strong { color: #92400e; }
.alert-caution p { color: #78350f; font-size: 0.92rem; }

.alert-info {
  background: rgba(37, 99, 235, 0.06);
}
.alert-info strong { color: var(--hl-blue); }
.alert-info p { color: #1e40af; font-size: 0.92rem; }

/* --- Divider ---------------------------------------------- */
.divider {
  width: 100%;
  height: 1px;
  background: linear-gradient(to right, transparent, #cbd5e1 30%, #cbd5e1 70%, transparent);
  margin: 2rem 0;
}

/* --- Sources ---------------------------------------------- */
.sources-block {
  background: rgba(248, 250, 252, 0.9);
  border-radius: var(--radius-card);
  padding: 1.5rem 2rem;
  box-shadow: var(--hl-chip-shadow);
  margin-top: 2rem;
}

.sources-block h4 { margin-bottom: 0.75rem; }

.sources-block ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.sources-block ul li {
  font-size: 0.78rem;
  color: var(--hl-subtext);
  display: flex;
  gap: 0.5rem;
}

.sources-block ul li::before {
  content: '→';
  color: var(--hl-green);
  font-weight: 700;
}

.disclaimer {
  font-size: 0.72rem;
  color: var(--hl-subtext);
  margin-top: 1rem;
  line-height: 1.6;
  padding-top: 1.25rem;
  background-image: linear-gradient(to right, transparent, rgba(203,213,225,0.6) 20%, rgba(203,213,225,0.6) 80%, transparent);
  background-size: 100% 1px;
  background-repeat: no-repeat;
  background-position: top center;
}

/* --- Footer ----------------------------------------------- */
.site-footer {
  margin-top: 4rem;
  padding-top: 2.5rem;
  text-align: center;
  font-size: 0.72rem;
  color: var(--hl-subtext);
  background-image: linear-gradient(to right, transparent, rgba(203,213,225,0.5) 15%, rgba(203,213,225,0.5) 85%, transparent);
  background-size: 100% 1px;
  background-repeat: no-repeat;
  background-position: top center;
}
.site-footer a { color: var(--hl-subtext); }

/* --- Responsive ------------------------------------------- */
@media (max-width: 640px) {
  .card { padding: 1.25rem; }
  .cta-card { padding: 1.75rem 1.25rem; }
  .answer-block { padding: 1.25rem; }
  .site-nav { flex-wrap: wrap; gap: 0.75rem; }
}
