:root {
  --green-950: #132a1b;
  --green-900: #14532d;
  --green-800: #166534;
  --green-700: #15803d;
  --green-100: #dcfce7;
  --green-50: #f0fdf4;
  --cream: #fbfcf7;
  --yellow: #fbbf24;
  --ink: #1a2e12;
  --muted: #4b5563;
  --line: rgba(22, 101, 52, 0.16);
  --white: #fff;
  --shadow: 0 14px 40px rgba(20, 83, 45, 0.08);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 88px; }
body {
  margin: 0;
  color: var(--ink);
  background: var(--cream);
  font-family: "Segoe UI", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  line-height: 1.68;
  text-rendering: optimizeLegibility;
}
img { max-width: 100%; height: auto; }
a { color: var(--green-800); text-underline-offset: 0.18em; }
a:hover { color: var(--green-900); }
:focus-visible { outline: 3px solid var(--green-700); outline-offset: 3px; border-radius: 5px; }

.skip-link {
  position: fixed;
  z-index: 1000;
  left: 1rem;
  top: -5rem;
  padding: 0.65rem 1rem;
  border-radius: 0 0 10px 10px;
  background: var(--green-900);
  color: #fff;
  font-weight: 800;
}
.skip-link:focus { top: 0; }

.site-header {
  position: sticky;
  z-index: 100;
  top: 0;
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(12px);
}
.nav-wrap {
  width: min(1120px, calc(100% - 2rem));
  min-height: 68px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}
.brand { display: inline-flex; align-items: center; line-height: 0; }
.brand img { width: 176px; height: 40px; object-fit: contain; object-position: left center; }
.nav-links { display: flex; align-items: center; gap: 1rem; font-size: 0.92rem; font-weight: 750; }
.nav-links a { text-decoration: none; }
.nav-cta {
  padding: 0.62rem 1rem;
  border-radius: 10px;
  background: var(--green-700);
  color: #fff;
  box-shadow: 0 5px 15px rgba(21, 128, 61, 0.2);
}
.nav-cta:hover { background: var(--green-900); color: #fff; }

.hero {
  position: relative;
  overflow: hidden;
  padding: 4.8rem 1rem 4.2rem;
  background:
    radial-gradient(circle at 80% 12%, rgba(251, 191, 36, 0.18), transparent 25rem),
    linear-gradient(150deg, #fff 0%, var(--green-50) 56%, #e8f7e7 100%);
}
.hero::after {
  content: "";
  position: absolute;
  width: 28rem;
  height: 28rem;
  left: -16rem;
  bottom: -21rem;
  border: 4rem solid rgba(22, 101, 52, 0.05);
  border-radius: 50%;
}
.hero-inner { position: relative; z-index: 1; width: min(920px, 100%); margin: 0 auto; }
.breadcrumbs { margin: 0 0 1.4rem; font-size: 0.85rem; color: var(--muted); }
.breadcrumbs ol { display: flex; flex-wrap: wrap; gap: 0.4rem; margin: 0; padding: 0; list-style: none; }
.breadcrumbs li + li::before { content: "/"; margin-right: 0.4rem; color: #9ca3af; }
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.32rem 0.72rem;
  border: 1px solid rgba(22, 101, 52, 0.18);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.76);
  color: var(--green-800);
  font-size: 0.76rem;
  font-weight: 850;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
h1, h2, h3 { line-height: 1.18; letter-spacing: -0.025em; }
h1 { max-width: 800px; margin: 1rem 0; font-size: clamp(2.25rem, 6vw, 4.15rem); }
.lead { max-width: 760px; margin: 0; color: var(--muted); font-size: clamp(1.05rem, 2vw, 1.24rem); }
.updated { margin: 1.25rem 0 0; color: #5f6b62; font-size: 0.84rem; }

.page-shell { width: min(1120px, calc(100% - 2rem)); margin: 0 auto; padding: 3rem 0 5rem; }
.content-grid { display: grid; grid-template-columns: minmax(0, 1fr) 290px; gap: 3rem; align-items: start; }
.article { min-width: 0; }
.article > section { padding: 1.2rem 0 2rem; border-bottom: 1px solid var(--line); }
.article > section:last-child { border-bottom: 0; }
.article h2 { margin: 0 0 0.85rem; font-size: clamp(1.55rem, 3vw, 2.1rem); }
.article h3 { margin: 1.4rem 0 0.55rem; font-size: 1.18rem; }
.article p { margin: 0.75rem 0; }
.article ul, .article ol { padding-left: 1.3rem; }
.article li { margin: 0.4rem 0; }
.sidebar { position: sticky; top: 92px; }
.sidebar-card {
  padding: 1.15rem;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: #fff;
  box-shadow: var(--shadow);
}
.sidebar-card + .sidebar-card { margin-top: 1rem; }
.sidebar-card h2 { margin: 0 0 0.7rem; font-size: 1rem; }
.sidebar-card ul { margin: 0; padding: 0; list-style: none; }
.sidebar-card li + li { border-top: 1px solid var(--line); }
.sidebar-card a { display: block; padding: 0.62rem 0; font-size: 0.9rem; font-weight: 700; text-decoration: none; }

.answer-box {
  margin: 0 0 1.5rem;
  padding: 1.4rem 1.5rem;
  border: 1px solid rgba(22, 101, 52, 0.22);
  border-left: 5px solid var(--green-700);
  border-radius: 16px;
  background: var(--green-50);
}
.answer-box strong:first-child { display: block; margin-bottom: 0.35rem; color: var(--green-900); }
.answer-box p { margin: 0; }

.card-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; }
.topic-card {
  display: block;
  padding: 1.25rem;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: #fff;
  color: inherit;
  text-decoration: none;
  box-shadow: 0 6px 24px rgba(20, 83, 45, 0.05);
  transition: transform 150ms ease, box-shadow 150ms ease, border-color 150ms ease;
}
.topic-card:hover { transform: translateY(-2px); border-color: rgba(22, 101, 52, 0.38); box-shadow: var(--shadow); color: inherit; }
.topic-card .icon { display: block; margin-bottom: 0.7rem; font-size: 1.8rem; }
.topic-card h3 { margin: 0 0 0.4rem; color: var(--green-950); font-size: 1.08rem; }
.topic-card p { margin: 0; color: var(--muted); font-size: 0.91rem; }
.topic-card .read-more { display: inline-block; margin-top: 0.8rem; color: var(--green-800); font-weight: 800; }

.pill-list { display: flex; flex-wrap: wrap; gap: 0.55rem; padding: 0 !important; list-style: none; }
.pill-list li {
  margin: 0;
  padding: 0.38rem 0.72rem;
  border: 1px solid rgba(22, 101, 52, 0.2);
  border-radius: 999px;
  background: #fff;
  color: var(--green-900);
  font-size: 0.88rem;
  font-weight: 700;
}

.check-list { list-style: none; padding: 0 !important; }
.check-list li { position: relative; padding-left: 1.7rem; }
.check-list li::before { content: "✓"; position: absolute; left: 0; color: var(--green-700); font-weight: 900; }

.note, .warning {
  margin: 1.25rem 0;
  padding: 1rem 1.15rem;
  border-radius: 14px;
}
.note { border: 1px solid #bbf7d0; background: #f0fdf4; }
.warning { border: 1px solid #fde68a; background: #fffbeb; color: #713f12; }

.table-wrap { margin: 1.2rem 0; overflow-x: auto; border: 1px solid var(--line); border-radius: 14px; background: #fff; }
table { width: 100%; border-collapse: collapse; font-size: 0.92rem; }
th, td { padding: 0.8rem 0.9rem; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
th { background: var(--green-50); color: var(--green-950); }
tr:last-child td { border-bottom: 0; }

.exercise-grid { display: grid; gap: 1rem; }
.exercise {
  padding: 1.2rem;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: #fff;
}
.exercise .label { color: var(--green-800); font-size: 0.75rem; font-weight: 850; letter-spacing: 0.08em; text-transform: uppercase; }
.exercise h3 { margin-top: 0.35rem; }
.exercise details { margin-top: 0.8rem; padding-top: 0.75rem; border-top: 1px solid var(--line); }
summary { cursor: pointer; color: var(--green-800); font-weight: 800; }

.step-list { counter-reset: learning-step; list-style: none; padding: 0 !important; }
.step-list li { position: relative; min-height: 3rem; padding: 0 0 1.15rem 3.4rem; }
.step-list li::before {
  counter-increment: learning-step;
  content: counter(learning-step);
  position: absolute;
  left: 0;
  top: -0.1rem;
  display: grid;
  place-items: center;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 12px;
  background: var(--green-800);
  color: #fff;
  font-weight: 900;
}

.sources { font-size: 0.9rem; color: var(--muted); }
.sources li { overflow-wrap: anywhere; }
.faq details { padding: 1rem 0; border-top: 1px solid var(--line); }
.faq details:last-child { border-bottom: 1px solid var(--line); }
.faq details p { margin-bottom: 0; }

.cta-box {
  margin-top: 2.5rem;
  padding: clamp(1.5rem, 5vw, 2.6rem);
  border-radius: 22px;
  background: linear-gradient(135deg, var(--green-900), var(--green-700));
  color: #fff;
  box-shadow: 0 18px 44px rgba(20, 83, 45, 0.2);
}
.cta-box h2 { margin-top: 0; }
.cta-box p { max-width: 650px; color: #e5f8e9; }
.button-row { display: flex; flex-wrap: wrap; gap: 0.75rem; margin-top: 1.2rem; }
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0.72rem 1.1rem;
  border: 2px solid #fff;
  border-radius: 11px;
  background: #fff;
  color: var(--green-900);
  font-weight: 850;
  text-decoration: none;
}
.button:hover { background: #f0fdf4; color: var(--green-900); }
.button.secondary { background: transparent; color: #fff; }
.button.secondary:hover { background: rgba(255, 255, 255, 0.1); color: #fff; }

.site-footer { padding: 2rem 1rem 3rem; border-top: 1px solid var(--line); background: #fff; color: var(--muted); }
.footer-wrap { width: min(1120px, 100%); margin: 0 auto; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 1rem 2rem; }
.footer-links { display: flex; flex-wrap: wrap; gap: 0.8rem 1.2rem; }
.footer-links a { font-size: 0.88rem; font-weight: 700; text-decoration: none; }
.site-footer p { margin: 0; font-size: 0.85rem; }

@media (max-width: 840px) {
  .content-grid { grid-template-columns: 1fr; }
  .sidebar { position: static; }
  .sidebar-card:first-child { display: none; }
}
@media (max-width: 680px) {
  .hero { padding-top: 3.2rem; }
  .nav-wrap { min-height: 62px; }
  .brand img { width: 150px; height: 34px; }
  .nav-links > a:not(.nav-cta) { display: none; }
  .card-grid { grid-template-columns: 1fr; }
  th, td { padding: 0.7rem; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: 0.01ms !important; }
}
@media print {
  .site-header, .sidebar, .cta-box, .site-footer { display: none; }
  .hero { padding: 1rem 0; background: #fff; }
  .page-shell { width: 100%; padding: 0; }
  .content-grid { display: block; }
  .article > section { break-inside: avoid; }
}
