/* ============================================================
   Ogrod - design system
   Paleta: głęboka zieleń (natura, wzrost, zaufanie) +
   słoneczna żółć (słońce, energia, plony) + ziemisty brąz +
   kremowe tło. Typografia: Prata (display) + Karla (body).
   ============================================================ */

:root {
  --green-900: #123a24;
  --green-800: #16482d;
  --green-700: #1a5c38;
  --green-600: #217a47;
  --green-500: #2e8b57;
  --green-100: #e3f0e6;
  --green-50: #f0f7f1;

  --sun-600: #d9a413;
  --sun-500: #eab308;
  --sun-400: #f4c430;
  --sun-100: #fdf3d7;

  --earth-700: #5d452f;
  --earth-500: #7c5c3e;
  --earth-100: #efe6da;

  --cream: #faf7f0;
  --cream-2: #f3eee3;
  --paper: #ffffff;

  --ink: #26221c;
  --ink-soft: #4d463c;
  --muted: #6f675a;

  --dark-bg: #0f1a12;
  --dark-surface: #16251a;
  --dark-surface-2: #1c2e20;
  --dark-text: #eae6db;
  --dark-muted: #a39c8c;

  --border: #e5ddd0;
  --border-dark: #2a3d2e;

  --radius: 12px;
  --radius-sm: 8px;
  --header-h: 64px;
  --sidebar-w: 300px;

  --font-display: "Prata", Georgia, serif;
  --font-body: "Karla", "Segoe UI", sans-serif;

  --shadow-card: 0 1px 2px rgba(38, 34, 28, 0.05), 0 4px 16px rgba(38, 34, 28, 0.06);
  --shadow-card-hover: 0 2px 4px rgba(38, 34, 28, 0.06), 0 10px 28px rgba(26, 92, 56, 0.12);

  --transition: all 0.2s ease-out;
}

/* ---------- Reset / base ---------- */
*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.7;
  color: var(--ink);
  background-color: var(--cream);
  background-image:
    radial-gradient(ellipse 60% 45% at 88% -5%, rgba(234, 179, 8, 0.10), transparent 60%),
    radial-gradient(ellipse 55% 40% at -5% 105%, rgba(46, 139, 87, 0.10), transparent 60%);
  background-attachment: fixed;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; }
a { color: var(--green-700); }
a:hover { color: var(--green-600); }

h1, h2, h3 {
  font-family: var(--font-display);
  font-weight: 400;
  line-height: 1.25;
  text-wrap: balance;
  color: var(--ink);
}

::selection { background: var(--sun-100); color: var(--ink); }

:focus-visible {
  outline: 3px solid var(--sun-500);
  outline-offset: 2px;
  border-radius: 4px;
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--green-700);
  color: #fff;
  padding: 10px 16px;
  z-index: 200;
  border-radius: 0 0 var(--radius-sm) 0;
  font-weight: 600;
}
.skip-link:focus { left: 0; color: #fff; }

/* ---------- Header ---------- */
.app-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--header-h);
  background: rgba(250, 247, 240, 0.92);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
  z-index: 100;
}
.app-header::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -1px;
  height: 2px;
  background: linear-gradient(90deg, transparent, rgba(26, 92, 56, 0.25), transparent);
  opacity: 0.6;
  pointer-events: none;
}

.header-inner {
  max-width: 1400px;
  margin: 0 auto;
  height: 100%;
  padding: 0 20px;
  display: flex;
  align-items: center;
  gap: 16px;
}

.menu-btn {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 42px;
  height: 42px;
  padding: 10px;
  background: transparent;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: var(--transition);
}
.menu-btn span {
  display: block;
  height: 2px;
  background: var(--ink);
  border-radius: 2px;
  transition: var(--transition);
}
.menu-btn:hover { border-color: var(--green-600); }

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  flex-shrink: 0;
}
.brand-mark {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 10px;
  background: linear-gradient(135deg, var(--green-700), var(--green-500));
  font-size: 19px;
  box-shadow: 0 2px 8px rgba(26, 92, 56, 0.25);
}
.brand-name {
  font-family: var(--font-display);
  font-size: 1.25rem;
  color: var(--ink);
  letter-spacing: -0.01em;
}
.brand-name em {
  font-style: normal;
  color: var(--green-700);
}

.search-wrap {
  position: relative;
  flex: 1;
  max-width: 420px;
  margin-left: auto;
}
.search-input {
  width: 100%;
  height: 40px;
  padding: 0 14px 0 38px;
  font-family: var(--font-body);
  font-size: 0.95rem;
  color: var(--ink);
  background: var(--paper);
  border: 1px solid var(--border);
  border-radius: 999px;
  transition: var(--transition);
}
.search-input::placeholder { color: var(--muted); }
.search-input:focus {
  outline: none;
  border-color: var(--green-600);
  box-shadow: 0 0 0 3px rgba(26, 92, 56, 0.15);
}
.search-wrap::before {
  content: "";
  position: absolute;
  left: 13px;
  top: 50%;
  width: 14px;
  height: 14px;
  transform: translateY(-55%);
  border: 2px solid var(--muted);
  border-radius: 50%;
}
.search-wrap::after {
  content: "";
  position: absolute;
  left: 24px;
  top: 50%;
  width: 7px;
  height: 2px;
  transform: translateY(4px) rotate(45deg);
  background: var(--muted);
}

.search-results {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  right: 0;
  background: var(--paper);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-card-hover);
  overflow: hidden;
  display: none;
  z-index: 120;
}
.search-results.open { display: block; }
.search-item {
  display: block;
  padding: 11px 16px;
  text-decoration: none;
  border-bottom: 1px solid var(--border);
  transition: background 0.15s ease;
}
.search-item:last-child { border-bottom: none; }
.search-item:hover { background: var(--green-50); }
.si-title { font-weight: 600; font-size: 0.95rem; color: var(--ink); }
.si-section { font-size: 0.78rem; color: var(--muted); margin-top: 1px; }
.search-empty { padding: 14px 16px; color: var(--muted); font-size: 0.9rem; }

.header-tagline {
  font-size: 0.8rem;
  color: var(--muted);
  white-space: nowrap;
  border-left: 1px solid var(--border);
  padding-left: 16px;
}

/* ---------- Layout ---------- */
.layout {
  max-width: 1400px;
  margin: 0 auto;
  padding: calc(var(--header-h) + 24px) 20px 40px;
  display: grid;
  grid-template-columns: var(--sidebar-w) minmax(0, 1fr);
  gap: 32px;
}

.sidebar {
  position: sticky;
  top: calc(var(--header-h) + 24px);
  align-self: start;
  max-height: calc(100vh - var(--header-h) - 48px);
  overflow-y: auto;
  padding: 6px 16px 16px 4px;
  scrollbar-width: thin;
  scrollbar-color: var(--border) transparent;
}

.side-group { margin-bottom: 6px; }
.side-group-title {
  font-family: var(--font-body);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--muted);
  padding: 10px 10px 6px;
  cursor: pointer;
  list-style: none;
  display: flex;
  align-items: center;
  gap: 6px;
  user-select: none;
}
.side-group-title::-webkit-details-marker { display: none; }
.side-group-title::before {
  content: "";
  width: 7px;
  height: 7px;
  border-right: 2px solid var(--green-600);
  border-bottom: 2px solid var(--green-600);
  transform: rotate(45deg);
  transition: transform 0.2s ease;
  opacity: 0.7;
}
.side-group[open] > .side-group-title::before { transform: rotate(-135deg); }

.side-group-items { padding-bottom: 6px; }
.sidebar-link {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 6px 10px;
  font-size: 0.9rem;
  line-height: 1.35;
  color: var(--ink-soft);
  text-decoration: none;
  border-radius: var(--radius-sm);
  transition: var(--transition);
}
.sidebar-link .s-icon { font-size: 0.85rem; opacity: 0.85; flex-shrink: 0; }
.sidebar-link:hover {
  background: var(--green-50);
  color: var(--green-700);
  transform: translateX(2px);
}
.sidebar-link.active {
  background: var(--green-100);
  color: var(--green-800);
  font-weight: 600;
}

.sidebar-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(15, 26, 18, 0.5);
  z-index: 90;
}

.main-content { min-width: 0; }
.app-content { animation: fadeUp 0.25s ease-out; }

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

/* ---------- Hero ---------- */
.home-hero {
  position: relative;
  overflow: hidden;
  background: linear-gradient(135deg, var(--green-900) 0%, var(--green-700) 55%, var(--green-600) 100%);
  border-radius: 18px;
  padding: 56px 48px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
  box-shadow: 0 8px 32px rgba(18, 58, 36, 0.25);
}
.home-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 50% 60% at 85% 20%, rgba(244, 196, 48, 0.14), transparent 65%),
    radial-gradient(ellipse 40% 50% at 10% 90%, rgba(46, 139, 87, 0.35), transparent 60%);
  pointer-events: none;
}

.hero-inner { position: relative; z-index: 2; max-width: 640px; }
.hero-eyebrow {
  display: inline-block;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--sun-400);
  background: rgba(250, 247, 240, 0.08);
  border: 1px solid rgba(244, 196, 48, 0.35);
  padding: 5px 12px;
  border-radius: 999px;
  margin-bottom: 18px;
}
.home-hero h1 {
  color: #fff;
  font-size: clamp(1.9rem, 4vw, 2.7rem);
  margin: 0 0 14px;
}
.home-hero h1 .accent-word {
  color: var(--sun-400);
  font-style: italic;
}
.hero-sub {
  color: rgba(250, 247, 240, 0.92);
  font-size: 1.05rem;
  line-height: 1.7;
  margin: 0 0 26px;
  max-width: 560px;
}
.hero-cta { display: flex; gap: 12px; flex-wrap: wrap; }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 22px;
  font-family: var(--font-body);
  font-size: 0.95rem;
  font-weight: 600;
  text-decoration: none;
  border-radius: 999px;
  transition: var(--transition);
  cursor: pointer;
}
.btn-primary {
  background: var(--sun-500);
  color: var(--green-900);
  box-shadow: 0 2px 10px rgba(234, 179, 8, 0.35);
}
.btn-primary:hover {
  background: var(--sun-400);
  color: var(--green-900);
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(234, 179, 8, 0.4);
}
.btn-ghost {
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.35);
}
.btn-ghost:hover {
  background: rgba(255, 255, 255, 0.18);
  color: #fff;
  transform: translateY(-2px);
}

.hero-visual { position: relative; z-index: 1; width: 240px; height: 200px; flex-shrink: 0; }
.leaf {
  position: absolute;
  color: rgba(250, 247, 240, 0.22);
  width: 46px;
  height: 46px;
  animation: floatLeaf 7s ease-in-out infinite;
}
.leaf svg { width: 100%; height: 100%; }
.leaf:nth-child(1) { top: 12%; left: 8%; animation-delay: 0s; }
.leaf:nth-child(2) { top: 55%; left: 2%; animation-delay: 1.2s; transform: scale(1.3); }
.leaf:nth-child(3) { top: 18%; left: 58%; animation-delay: 2.1s; transform: scale(0.8); }
.leaf:nth-child(4) { top: 62%; left: 46%; animation-delay: 0.6s; transform: scale(1.5); }
.leaf:nth-child(5) { top: 5%; left: 88%; animation-delay: 1.7s; transform: scale(0.9); }
.leaf:nth-child(6) { top: 78%; left: 82%; animation-delay: 2.6s; transform: scale(1.1); }
.leaf:nth-child(7) { top: 40%; left: 72%; animation-delay: 3.2s; transform: scale(0.7); }

@keyframes floatLeaf {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  50% { transform: translateY(-14px) rotate(8deg); }
}

/* ---------- Home sections ---------- */
.home-section { margin-top: 44px; }
.home-section h2 {
  display: flex;
  align-items: center;
  gap: 14px;
  font-size: 1.5rem;
  margin: 0 0 6px;
  color: var(--green-900);
}
.sec-count {
  display: inline-grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 10px;
  background: var(--green-100);
  color: var(--green-700);
  font-family: var(--font-body);
  font-size: 0.85rem;
  font-weight: 700;
  flex-shrink: 0;
}
.sec-desc {
  color: var(--muted);
  font-size: 0.95rem;
  margin: 0 0 18px 52px;
}

.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 16px;
}

.home-card {
  position: relative;
  display: flex;
  flex-direction: column;
  background: var(--paper);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px 20px 16px;
  text-decoration: none;
  color: var(--ink);
  box-shadow: var(--shadow-card);
  transition: var(--transition);
}
.home-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 20px;
  right: 20px;
  height: 3px;
  background: linear-gradient(90deg, var(--green-600), var(--sun-500));
  border-radius: 0 0 3px 3px;
  opacity: 0;
  transition: opacity 0.2s ease-out;
}
.home-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-card-hover);
  border-color: #d8cdba;
  color: var(--ink);
}
.home-card:hover::before { opacity: 1; }

.hc-icon {
  font-size: 1.7rem;
  line-height: 1;
  margin-bottom: 12px;
  display: inline-block;
  transition: transform 0.2s ease-out;
}
.home-card:hover .hc-icon { transform: scale(1.12) rotate(-4deg); }

.home-card h3 {
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 0.95rem;
  line-height: 1.4;
  margin: 0 0 8px;
  color: var(--green-900);
}
.home-card p {
  font-size: 0.85rem;
  line-height: 1.55;
  color: var(--ink-soft);
  margin: 0 0 14px;
  flex-grow: 1;
}
.hc-more {
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--green-700);
  display: inline-flex;
  align-items: center;
  gap: 5px;
}
.hc-more .arrow { transition: transform 0.2s ease-out; }
.home-card:hover .hc-more .arrow { transform: translateX(4px); }

/* ---------- Article ---------- */
.article-header { margin-bottom: 30px; }
.breadcrumbs {
  font-size: 0.82rem;
  color: var(--muted);
  margin-bottom: 12px;
}
.breadcrumbs a { color: var(--green-700); text-decoration: none; }
.breadcrumbs a:hover { text-decoration: underline; }
.breadcrumbs .sep { margin: 0 7px; color: var(--border); }

.article-header h1 {
  font-size: clamp(1.7rem, 3.4vw, 2.35rem);
  color: var(--green-900);
  margin: 0 0 12px;
}
.article-excerpt {
  font-size: 1.06rem;
  line-height: 1.65;
  color: var(--ink-soft);
  margin: 0 0 16px;
  max-width: 760px;
}
.article-meta {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
  font-size: 0.8rem;
  color: var(--muted);
}
.tag {
  background: var(--green-100);
  color: var(--green-800);
  font-weight: 600;
  padding: 4px 12px;
  border-radius: 999px;
  font-size: 0.75rem;
}

.article-body {
  max-width: 780px;
  background: var(--paper);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 36px 40px;
  box-shadow: var(--shadow-card);
}

.article-body h2 {
  font-size: 1.45rem;
  color: var(--green-900);
  margin: 34px 0 14px;
  padding-top: 6px;
  scroll-margin-top: calc(var(--header-h) + 20px);
}
.article-body h2:first-child { margin-top: 0; }
.article-body h3 {
  font-size: 1.1rem;
  font-weight: 700;
  font-family: var(--font-body);
  color: var(--green-800);
  margin: 24px 0 10px;
  scroll-margin-top: calc(var(--header-h) + 20px);
}
.article-body p { margin: 0 0 16px; }
.article-body ul, .article-body ol { margin: 0 0 18px; padding-left: 24px; }
.article-body li { margin-bottom: 6px; }
.article-body strong { color: var(--ink); }
.article-body a { text-decoration: underline; text-underline-offset: 2px; }

.article-toc {
  background: var(--green-50);
  border: 1px solid var(--green-100);
  border-radius: var(--radius-sm);
  padding: 14px 18px;
  margin-bottom: 26px;
}
.article-toc summary {
  font-weight: 700;
  font-size: 0.9rem;
  color: var(--green-800);
  cursor: pointer;
  user-select: none;
}
.article-toc ol {
  margin: 10px 0 0;
  padding-left: 20px;
}
.article-toc li { margin-bottom: 4px; font-size: 0.9rem; }
.article-toc a { color: var(--green-700); text-decoration: none; }
.article-toc a:hover { text-decoration: underline; }

.info-box {
  background: var(--sun-100);
  border-left: 4px solid var(--sun-500);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  padding: 14px 18px;
  margin: 18px 0;
  font-size: 0.95rem;
  line-height: 1.6;
}
.info-box strong { color: var(--earth-700); }

.compare-table {
  width: 100%;
  border-collapse: collapse;
  margin: 18px 0 22px;
  font-size: 0.92rem;
  background: var(--paper);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  overflow: hidden;
}
.compare-table th {
  background: var(--green-700);
  color: #fff;
  text-align: left;
  padding: 11px 14px;
  font-weight: 600;
  font-size: 0.88rem;
}
.compare-table td {
  padding: 10px 14px;
  border-top: 1px solid var(--border);
  vertical-align: top;
}
.compare-table tr:nth-child(even) td { background: var(--cream-2); }
.compare-table td:first-child { font-weight: 600; color: var(--green-800); white-space: nowrap; }

.faq-item {
  border: 1px solid var(--border);
  border-left: 4px solid var(--green-600);
  border-radius: var(--radius-sm);
  padding: 16px 18px;
  margin: 0 0 14px;
  background: var(--paper);
}
.faq-item h3 {
  margin: 0 0 8px;
  font-size: 1rem;
  color: var(--green-900);
}
.faq-item p { margin: 0; font-size: 0.95rem; }

.article-body dl {
  margin: 0 0 20px;
}
.article-body dt {
  font-weight: 700;
  color: var(--green-800);
  margin-top: 14px;
  font-size: 1rem;
}
.article-body dd {
  margin: 3px 0 0;
  color: var(--ink-soft);
  font-size: 0.95rem;
}

/* prev / next */
.article-nav {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-top: 36px;
  padding-top: 24px;
  border-top: 1px solid var(--border);
}
.article-nav a {
  display: block;
  text-decoration: none;
  background: var(--cream-2);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 14px 16px;
  transition: var(--transition);
}
.article-nav a:hover {
  background: var(--green-50);
  border-color: var(--green-100);
  transform: translateY(-2px);
}
.article-nav a.next { text-align: right; }
.an-label {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 4px;
}
.an-title { font-weight: 600; font-size: 0.92rem; color: var(--green-800); }

/* ---------- Footer ---------- */
.app-footer {
  margin-top: 48px;
  background: var(--green-900);
  color: rgba(250, 247, 240, 0.85);
}
.footer-inner {
  max-width: 1400px;
  margin: 0 auto;
  padding: 36px 20px;
  font-size: 0.9rem;
  line-height: 1.6;
}
.footer-inner p { margin: 0 0 10px; }
.footer-inner strong { color: #fff; font-family: var(--font-display); font-weight: 400; }
.footer-note { color: rgba(250, 247, 240, 0.6); font-size: 0.82rem; }
.footer-copy { color: rgba(250, 247, 240, 0.5); font-size: 0.8rem; }

/* ---------- Responsive ---------- */
@media (max-width: 1020px) {
  .header-tagline { display: none; }
}

@media (max-width: 900px) {
  .layout {
    grid-template-columns: 1fr;
    padding-top: calc(var(--header-h) + 16px);
  }
  .menu-btn { display: flex; }
  .sidebar {
    position: fixed;
    top: var(--header-h);
    bottom: 0;
    left: 0;
    width: min(320px, 85vw);
    max-height: none;
    background: var(--cream);
    border-right: 1px solid var(--border);
    padding: 12px 16px 24px;
    transform: translateX(-105%);
    transition: transform 0.25s ease-out;
    z-index: 95;
    box-shadow: 8px 0 24px rgba(15, 26, 18, 0.12);
  }
  .sidebar.open { transform: translateX(0); }
  .sidebar-overlay.show { display: block; }
  .search-wrap { max-width: none; }
  .home-hero {
    flex-direction: column;
    padding: 40px 28px;
    text-align: left;
  }
  .hero-visual { width: 100%; height: 90px; }
  .sec-desc { margin-left: 0; }
  .article-body { padding: 28px 24px; }
}

@media (max-width: 600px) {
  body { font-size: 16.5px; }
  .header-inner { padding: 0 12px; gap: 10px; }
  .brand-name { font-size: 1.1rem; }
  .brand-mark { width: 34px; height: 34px; font-size: 17px; }
  .home-hero { padding: 32px 20px; border-radius: 14px; }
  .home-hero h1 { font-size: 1.65rem; }
  .hero-cta { flex-direction: column; }
  .btn { width: 100%; }
  .card-grid { grid-template-columns: 1fr; }
  .article-nav { grid-template-columns: 1fr; }
  .article-nav a.next { text-align: left; }
  .compare-table { font-size: 0.85rem; }
  .compare-table th, .compare-table td { padding: 8px 10px; }
}

/* ---------- Dark mode ---------- */
@media (prefers-color-scheme: dark) {
  body {
    color: var(--dark-text);
    background-color: var(--dark-bg);
    background-image:
      radial-gradient(ellipse 60% 45% at 88% -5%, rgba(234, 179, 8, 0.07), transparent 60%),
      radial-gradient(ellipse 55% 40% at -5% 105%, rgba(46, 139, 87, 0.12), transparent 60%);
  }
  h1, h2, h3 { color: var(--dark-text); }
  a { color: #7fb894; }
  a:hover { color: #9fd4b2; }
  ::selection { background: rgba(234, 179, 8, 0.3); color: var(--dark-text); }

  .app-header {
    background: rgba(15, 26, 18, 0.92);
    border-bottom-color: var(--border-dark);
  }
  .brand-name { color: var(--dark-text); }
  .menu-btn span { background: var(--dark-text); }
  .menu-btn { border-color: var(--border-dark); }
  .search-input {
    background: var(--dark-surface);
    color: var(--dark-text);
    border-color: var(--border-dark);
  }
  .search-input::placeholder { color: var(--dark-muted); }
  .search-results {
    background: var(--dark-surface);
    border-color: var(--border-dark);
  }
  .search-item { border-bottom-color: var(--border-dark); }
  .search-item:hover { background: var(--dark-surface-2); }
  .si-title { color: var(--dark-text); }
  .si-section { color: var(--dark-muted); }
  .header-tagline { color: var(--dark-muted); border-left-color: var(--border-dark); }

  .sidebar { background: var(--dark-bg); }
  .side-group-title { color: var(--dark-muted); }
  .sidebar-link { color: #c9c4b6; }
  .sidebar-link:hover { background: var(--dark-surface); color: #9fd4b2; }
  .sidebar-link.active { background: rgba(46, 139, 87, 0.22); color: #9fd4b2; }

  .home-section h2 { color: #d8e8dc; }
  .sec-count { background: rgba(46, 139, 87, 0.22); color: #9fd4b2; }
  .sec-desc { color: var(--dark-muted); }

  .home-card {
    background: var(--dark-surface);
    border-color: var(--border-dark);
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.3), 0 4px 16px rgba(0, 0, 0, 0.2);
  }
  .home-card:hover {
    border-color: #2f4a38;
    box-shadow: 0 10px 28px rgba(0, 0, 0, 0.4);
  }
  .home-card h3 { color: #d8e8dc; }
  .home-card p { color: #b3ad9f; }
  .hc-more { color: #9fd4b2; }

  .article-header h1 { color: #d8e8dc; }
  .article-excerpt { color: #b3ad9f; }
  .article-meta { color: var(--dark-muted); }
  .tag { background: rgba(46, 139, 87, 0.22); color: #9fd4b2; }

  .article-body {
    background: var(--dark-surface);
    border-color: var(--border-dark);
  }
  .article-body h2 { color: #d8e8dc; }
  .article-body h3 { color: #9fd4b2; }
  .article-body strong { color: var(--dark-text); }
  .article-body a { color: #7fb894; }

  .article-toc { background: rgba(46, 139, 87, 0.12); border-color: rgba(46, 139, 87, 0.25); }
  .article-toc summary { color: #9fd4b2; }
  .article-toc a { color: #7fb894; }

  .info-box {
    background: rgba(234, 179, 8, 0.1);
    border-left-color: var(--sun-500);
  }
  .info-box strong { color: var(--sun-400); }

  .compare-table { background: var(--dark-surface); border-color: var(--border-dark); }
  .compare-table th { background: var(--green-800); }
  .compare-table td { border-top-color: var(--border-dark); }
  .compare-table tr:nth-child(even) td { background: var(--dark-surface-2); }
  .compare-table td:first-child { color: #9fd4b2; }

  .faq-item { background: var(--dark-surface); border-color: var(--border-dark); }
  .faq-item h3 { color: #d8e8dc; }
  .faq-item p { color: #b3ad9f; }

  .article-body dt { color: #9fd4b2; }
  .article-body dd { color: #b3ad9f; }

  .article-nav { border-top-color: var(--border-dark); }
  .article-nav a { background: var(--dark-surface-2); border-color: var(--border-dark); }
  .article-nav a:hover { background: rgba(46, 139, 87, 0.18); }
  .an-label { color: var(--dark-muted); }
  .an-title { color: #9fd4b2; }

  .app-footer { background: #0a140d; }
  .footer-note { color: rgba(250, 247, 240, 0.45); }

  @media (max-width: 900px) {
    .sidebar { background: var(--dark-bg); border-right-color: var(--border-dark); }
  }
}

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}
