/* ============================================================
   Garden Guru ERP — Documentation theme
   Editorial, botanical, human. Paper + ink + forest + terracotta.
   No gradients, no glass, no bubbles — just clean typography,
   honest borders and real content.
   ============================================================ */

:root {
  --paper: #f7f4ee;
  --paper-deep: #efe9dd;
  --card: #fffdf8;
  --ink: #232a24;
  --ink-soft: #4d574e;
  --ink-faint: #7d857b;
  --forest: #1f4d36;
  --forest-soft: #2e6b4f;
  --moss: #6d8a6d;
  --terracotta: #b95c3f;
  --amber: #b0802d;
  --line: #e3dccb;
  --line-strong: #d3c9b2;
  --code-bg: #f0ebe0;
  --quote-bg: #f1ecdf;
  --sidebar-bg: #f0ebe0;
  --font-display: "Fraunces", Georgia, "Times New Roman", serif;
  --font-body: "Public Sans", -apple-system, BlinkMacSystemFont, "Segoe UI",
    Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-mono: "IBM Plex Mono", ui-monospace, SFMono-Regular, Menlo, Consolas,
    monospace;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
  line-height: 1.7;
  font-size: 16px;
}

/* ---------- Sidebar ---------- */

.sidebar {
  background: var(--sidebar-bg);
  border-right: 1px solid var(--line);
  font-family: var(--font-body);
}

.sidebar-toggle {
  background: var(--paper);
  border: none;
}

.sidebar .sidebar-nav {
  padding: 14px 0 40px;
}

.sidebar .sidebar-nav > ul > li > a,
.sidebar .sidebar-nav > ul > li > strong {
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  font-size: 11.5px;
  color: var(--ink-faint);
}

.sidebar .sidebar-nav ul li a {
  font-size: 14px;
  color: var(--ink-soft);
  border-left: 2px solid transparent;
  transition: color 0.15s ease, border-color 0.15s ease, background 0.15s ease;
  padding: 5px 12px;
  border-radius: 0 6px 6px 0;
}

.sidebar .sidebar-nav ul li a:hover {
  color: var(--forest);
  background: rgba(31, 77, 54, 0.06);
}

.sidebar .sidebar-nav ul li.active > a {
  color: var(--forest);
  border-left-color: var(--terracotta);
  font-weight: 600;
}

.sidebar ul li ul {
  padding-left: 8px;
}

.sidebar .app-name-link {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-display);
  font-size: 21px;
  font-weight: 600;
  color: var(--forest);
  padding: 18px 16px 8px;
}

.sidebar .app-name-link img {
  width: 30px;
  height: 30px;
  border-radius: 8px;
}

.sidebar .app-subtitle {
  display: block;
  padding: 0 16px 14px;
  font-size: 12px;
  color: var(--ink-faint);
  border-bottom: 1px solid var(--line);
  margin-bottom: 10px;
}

/* ---------- Content ---------- */

.markdown-section {
  max-width: 860px;
  padding: 40px 60px 80px;
  color: var(--ink);
}

.markdown-section h1,
.markdown-section h2,
.markdown-section h3,
.markdown-section h4 {
  font-family: var(--font-display);
  font-weight: 600;
  color: var(--ink);
  letter-spacing: -0.01em;
}

.markdown-section h1 {
  font-size: 2.35em;
  line-height: 1.15;
  margin: 0 0 0.4em;
  padding-bottom: 0.3em;
  border-bottom: 2px solid var(--forest);
}

.markdown-section h2 {
  font-size: 1.6em;
  margin-top: 2.2em;
  padding-bottom: 0.25em;
  border-bottom: 1px solid var(--line-strong);
}

.markdown-section h3 {
  font-size: 1.25em;
  margin-top: 1.8em;
  color: var(--forest);
}

.markdown-section h4 {
  font-size: 1.05em;
  color: var(--ink-soft);
}

.markdown-section p {
  margin: 0.9em 0;
  color: var(--ink-soft);
}

.markdown-section a {
  color: var(--terracotta);
  text-decoration: none;
  border-bottom: 1px solid rgba(185, 92, 63, 0.35);
  transition: color 0.15s ease, border-color 0.15s ease;
}

.markdown-section a:hover {
  color: var(--forest);
  border-bottom-color: var(--forest);
}

.markdown-section ul,
.markdown-section ol {
  padding-left: 1.5em;
}

.markdown-section li {
  margin: 0.4em 0;
  color: var(--ink-soft);
}

.markdown-section li::marker {
  color: var(--moss);
}

/* ---------- Code ---------- */

.markdown-section pre {
  background: #262b26;
  border-radius: 10px;
  border: none;
  box-shadow: 0 2px 0 rgba(0, 0, 0, 0.12);
  padding: 18px 22px;
  line-height: 1.6;
}

.markdown-section pre code {
  font-family: var(--font-mono);
  font-size: 13.5px;
  color: #e8e4d8;
  background: transparent;
}

.markdown-section code {
  font-family: var(--font-mono);
  font-size: 0.88em;
  background: var(--code-bg);
  color: #8a4b31;
  border-radius: 5px;
  padding: 0.15em 0.4em;
}

/* ---------- Tables ---------- */

.markdown-section table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.95em;
  margin: 1.4em 0;
  border: 1px solid var(--line);
  border-radius: 10px;
  overflow: hidden;
}

.markdown-section table thead th {
  background: var(--forest);
  color: #fdfaf3;
  font-weight: 600;
  text-align: left;
  padding: 10px 14px;
  font-size: 0.9em;
  letter-spacing: 0.02em;
}

.markdown-section table tbody tr:nth-child(odd) {
  background: var(--card);
}

.markdown-section table tbody tr:nth-child(even) {
  background: var(--paper-deep);
}

.markdown-section table tbody td {
  padding: 10px 14px;
  border-top: 1px solid var(--line);
  color: var(--ink-soft);
}

/* ---------- Quotes & callouts ---------- */

.markdown-section blockquote {
  background: var(--quote-bg);
  border-left: 4px solid var(--terracotta);
  border-radius: 0 10px 10px 0;
  padding: 14px 20px;
  margin: 1.4em 0;
  color: var(--ink-soft);
}

.markdown-section blockquote p {
  margin: 0.4em 0;
}

/* ---------- Home page cards ---------- */

.doc-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 16px;
  margin: 28px 0;
}

.doc-card {
  display: block;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 22px 20px;
  text-decoration: none !important;
  border-bottom: 3px solid var(--line-strong);
  transition: transform 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease;
}

.doc-card:hover {
  transform: translateY(-2px);
  border-color: var(--moss);
  border-bottom-color: var(--forest);
  box-shadow: 0 8px 22px rgba(31, 77, 54, 0.08);
}

.doc-card .doc-card-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: 10px;
  background: var(--paper-deep);
  margin-bottom: 12px;
}

.doc-card .doc-card-icon svg {
  width: 22px;
  height: 22px;
  stroke: var(--forest);
}

.doc-card .doc-card-title {
  font-family: var(--font-display);
  font-size: 1.05em;
  font-weight: 600;
  color: var(--ink);
  margin: 0 0 4px;
  display: block;
}

.doc-card .doc-card-desc {
  font-size: 0.9em;
  color: var(--ink-faint);
  margin: 0;
  line-height: 1.55;
}

/* Hero on the home page */

.doc-hero {
  margin: 8px 0 30px;
  padding: 40px 38px;
  background: var(--forest);
  border-radius: 16px;
  border-bottom: 3px solid var(--terracotta);
  color: #fdfaf3;
  position: relative;
}

.doc-hero .doc-hero-mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 54px;
  height: 54px;
  border-radius: 14px;
  background: #fdfaf3;
  margin-bottom: 18px;
}

.doc-hero .doc-hero-mark svg {
  width: 30px;
  height: 30px;
  stroke: var(--forest);
}

.doc-hero h1 {
  font-family: var(--font-display);
  font-size: 2.3em;
  line-height: 1.12;
  margin: 0 0 0.3em;
  color: #fdfaf3;
  border: none;
  padding: 0;
  letter-spacing: -0.015em;
}

.doc-hero p.doc-hero-sub {
  font-size: 1.08em;
  color: rgba(253, 250, 243, 0.82);
  max-width: 60ch;
  margin: 0;
}

.doc-hero .doc-hero-badges {
  margin-top: 22px;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.doc-hero .doc-hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  background: rgba(253, 250, 243, 0.12);
  border: 1px solid rgba(253, 250, 243, 0.25);
  color: #fdfaf3;
  font-size: 12.5px;
  font-weight: 600;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  padding: 6px 12px;
  border-radius: 999px;
}

.doc-hero .doc-hero-badge svg {
  width: 14px;
  height: 14px;
  stroke: #fdfaf3;
}

/* Hero call-to-action buttons */

.doc-cta-row {
  margin-top: 26px;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.markdown-section a.doc-cta {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 11px 18px;
  border-radius: 10px;
  font-weight: 600;
  font-size: 14.5px;
  text-decoration: none;
  border: none;
  border-bottom: none;
  transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.markdown-section a.doc-cta.doc-cta-primary {
  background: #fdfaf3;
  color: var(--forest);
}

.markdown-section a.doc-cta.doc-cta-primary:hover {
  background: #ffffff;
  color: var(--forest);
}

.markdown-section a.doc-cta.doc-cta-ghost {
  background: transparent;
  color: #fdfaf3;
  border: 1px solid rgba(253, 250, 243, 0.4);
}

.markdown-section a.doc-cta.doc-cta-ghost:hover {
  background: rgba(253, 250, 243, 0.12);
  color: #fdfaf3;
  border-color: rgba(253, 250, 243, 0.7);
}

.doc-cta svg {
  width: 16px;
  height: 16px;
  stroke: currentColor;
  flex: none;
}

/* Pill tags used inside content */

.doc-pill {
  display: inline-block;
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  padding: 3px 10px;
  border-radius: 999px;
  margin-right: 6px;
  vertical-align: middle;
}

.doc-pill-green {
  background: #e3ecdf;
  color: var(--forest-soft);
  border: 1px solid #c4d4bd;
}

.doc-pill-terracotta {
  background: #f6e4dc;
  color: var(--terracotta);
  border: 1px solid #e8c4b4;
}

.doc-pill-amber {
  background: #f6ecd7;
  color: var(--amber);
  border: 1px solid #e6d4a8;
}

/* Changelog date entries */

.doc-version-block {
  background: var(--card);
  border: 1px solid var(--line);
  border-left: 4px solid var(--forest);
  border-radius: 0 12px 12px 0;
  padding: 18px 22px;
  margin: 18px 0;
}

.doc-version-block h2 {
  border: none;
  margin: 0;
  padding: 0;
  font-family: var(--font-display);
  font-size: 1.35em;
}

/* ---------- Footer ---------- */

.guru-footer {
  margin-top: 60px;
  padding-top: 26px;
  border-top: 1px solid var(--line-strong);
  font-size: 13.5px;
  color: var(--ink-faint);
}

.guru-footer .guru-footer-top {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 22px;
  margin-bottom: 12px;
}

.guru-footer .guru-footer-top a {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: var(--ink-soft);
  text-decoration: none;
  border: none;
  font-weight: 600;
}

.guru-footer .guru-footer-top a:hover {
  color: var(--terracotta);
}

.guru-footer .guru-footer-top a svg {
  width: 15px;
  height: 15px;
  stroke: currentColor;
}

.guru-footer .guru-footer-note {
  margin: 0;
  font-size: 12.5px;
}

/* ---------- Responsive ---------- */

@media screen and (max-width: 768px) {
  .markdown-section {
    padding: 26px 22px 60px;
  }

  .markdown-section h1 {
    font-size: 1.9em;
  }

  .doc-hero {
    padding: 28px 22px;
  }

  .doc-hero h1 {
    font-size: 1.8em;
  }
}
