/* MorgenWM documentation theme overrides. */

:root, [data-theme="dark"] {
  --primary-background: #0e0e0e;
  --secondary-background: #141414;
  --third-background: #1a1a1a;
  --info-background: #1d3a1d;
  --warning-background: #3a3010;
  --error-background: #3a1414;
  --accent-color: #c03030;
  --text-color: #d4d0c8;
  --headline-font: 'Courier New', Courier, monospace;
  --body-font: 'Courier New', Courier, monospace;
  --code-block-font: 'Courier New', Courier, monospace;
  --document-font: 'Courier New', Courier, monospace;
}

body {
  background:
    radial-gradient(ellipse 80% 50% at 50% -10%, rgba(192, 48, 48, 0.08), transparent),
    radial-gradient(ellipse 60% 40% at 80% 100%, rgba(60, 60, 80, 0.12), transparent),
    #0e0e0e;
  background-attachment: fixed;
  color: #d4d0c8;
}

a { color: #c03030; }
a:hover { color: #ff6b6b; }

h1, h2, h3 {
  color: #e8e4e0;
}

/* Home link in the docgen nav points back to the landing page. */
#nav-home a { color: #c03030; }

/* Pre/min-table styling on dark. */
pre {
  background: #141414;
  border: 1px solid #333;
}

code, .pre, span.tok {
  color: #d4d0c8;
}

table { border-color: #333; }
th { background: #141414; }

/* --- Docgen nav bar ---------------------------------------------------
   Injected by site/nimdoc.cfg on every docs page; styled here because docs
   pages load only nimdoc.out.css + this file (not the landing page's style.css). */
.mw-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  padding: 10px 0 18px;
  border-bottom: 2px solid #333;
  margin-bottom: 24px;
}

.mw-nav a {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: #999;
}

.mw-nav a:hover { color: #ff6b6b; }

.mw-nav a:first-child { color: #c03030; font-weight: 700; }

.document .container { max-width: 1100px; margin: 0 auto; padding: 0 24px 48px; }

/* --- Docs sidebar ------------------------------------------------------ */
.mw-layout {
  display: flex;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px 48px;
  gap: 32px;
  align-items: flex-start;
}

.mw-sidebar {
  width: 220px;
  flex-shrink: 0;
  position: sticky;
  top: 20px;
  max-height: calc(100vh - 40px);
  overflow-y: auto;
  background: #141414;
  border: 1px solid #2a2a2a;
  border-radius: 4px;
  padding: 18px;
}

.mw-side-title {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: #666;
  margin: 18px 0 8px;
}

.mw-side-title:first-child { margin-top: 0; }

.mw-sidebar ul { list-style: none; }

.mw-sidebar li { margin: 4px 0; }

.mw-sidebar a { font-size: 0.85rem; }

.mw-sidebar a:hover { color: #ff6b6b; }

/* Content column: slightly lighter than the page background. */
.mw-layout .container {
  flex: 1;
  min-width: 0;
  max-width: none;
  margin: 0;
  padding: 24px 28px 48px;
  background: #121212;
  border: 1px solid #2a2a2a;
}

@media (max-width: 800px) {
  .mw-layout { display: block; }
  .mw-sidebar {
    width: auto;
    border-right: none;
    border-bottom: 1px solid #2a2a2a;
    padding: 16px;
    margin-bottom: 20px;
  }
  .mw-layout .container { padding-left: 0; }
}

/* --- Docs footer ------------------------------------------------------ */
.mw-doc-footer {
  margin-top: 48px;
  padding-top: 16px;
  border-top: 1px solid #2a2a2a;
  font-size: 0.8rem;
}

.mw-doc-footer a { color: #999; margin-right: 4px; }
.mw-doc-footer a:hover { color: #ff6b6b; }
