/* rukuma.dev — editorial dark theme for a leader's agentic site */

:root {
  --bg: #0f141b;
  --surface: #161d27;
  --surface-hover: #1c2531;
  --text: #e8e6e1;
  --text-dim: #9aa5b1;
  --accent: #c9732e;
  --accent-dim: #a85a1f;
  --border: #242e3a;
  --radius: 8px;
  --max-width: 820px;
  --serif: Georgia, 'Times New Roman', serif;
  --sans: -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  line-height: 1.7;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* Nav */
.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 2rem;
  border-bottom: 1px solid var(--border);
  background: var(--surface);
  position: sticky;
  top: 0;
  z-index: 100;
}

.nav-logo {
  font-family: var(--serif);
  font-weight: 700;
  font-size: 1.15rem;
  color: var(--text);
  text-decoration: none;
  letter-spacing: -0.01em;
}

.nav-links {
  display: flex;
  gap: 1.4rem;
  align-items: center;
}

.nav-links a {
  color: var(--text-dim);
  text-decoration: none;
  font-size: 0.9rem;
  transition: color 0.2s;
}

.nav-links a:hover { color: var(--accent); }

.nav-cta {
  color: var(--text) !important;
  font-weight: 600;
  border-bottom: 2px solid var(--accent);
  padding-bottom: 2px;
}

/* Container */
.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 2rem;
  flex: 1;
  width: 100%;
}

/* Hero */
.hero {
  padding: 3.5rem 0 2rem;
}

.eyebrow {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: var(--accent);
  margin-bottom: 1.2rem;
  font-weight: 600;
}

.hero h1 {
  font-family: var(--serif);
  font-size: clamp(2.2rem, 5vw, 3.2rem);
  font-weight: 500;
  letter-spacing: -0.02em;
  line-height: 1.1;
  margin-bottom: 1.4rem;
}

.tagline {
  font-size: 1.15rem;
  color: var(--text-dim);
  max-width: 38rem;
  margin-bottom: 1.8rem;
}

.hero-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.badge {
  background: var(--surface);
  border: 1px solid var(--border);
  padding: 0.3rem 0.8rem;
  border-radius: 20px;
  font-size: 0.8rem;
  color: var(--text-dim);
}

/* Content sections */
.content-section {
  padding: 2.5rem 0;
  border-top: 1px solid var(--border);
}

.content-section h2 {
  font-family: var(--serif);
  font-size: 1.6rem;
  font-weight: 500;
  margin-bottom: 1rem;
}

.section-num {
  color: var(--accent);
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  margin-right: 0.6rem;
  font-family: var(--sans);
  font-weight: 600;
  vertical-align: middle;
}

.section-lede {
  color: var(--text-dim);
  margin-bottom: 1.4rem;
}

.content-section > p {
  color: var(--text-dim);
  margin-bottom: 1rem;
  max-width: 42rem;
}

/* Feature grid (cards) */
.feature-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 1rem;
  margin: 1.2rem 0;
}

.feature-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.4rem;
  transition: border-color 0.2s, background 0.2s, transform 0.15s;
  text-decoration: none;
  color: var(--text);
  display: block;
}

a.feature-card:hover {
  border-color: var(--accent-dim);
  background: var(--surface-hover);
  transform: translateY(-2px);
}

.feature-icon { font-size: 1.8rem; margin-bottom: 0.5rem; }

.feature-card h3 {
  font-family: var(--serif);
  font-size: 1.05rem;
  margin-bottom: 0.5rem;
}

.feature-card p {
  font-size: 0.85rem;
  color: var(--text-dim);
  margin-bottom: 0.75rem;
}

/* Text links and buttons */
.text-link {
  color: var(--accent);
  text-decoration: none;
  font-weight: 600;
  font-size: 0.9rem;
  border-bottom: 1.5px solid transparent;
  transition: border-color 0.15s;
}

.text-link:hover { border-bottom-color: var(--accent); }

.btn {
  display: inline-block;
  background: var(--accent);
  color: var(--bg);
  padding: 0.75rem 1.6rem;
  border-radius: var(--radius);
  text-decoration: none;
  font-weight: 600;
  font-size: 0.95rem;
  margin: 0 0.5rem 0.5rem 0;
  transition: background 0.15s, transform 0.15s;
}

.btn:hover { background: var(--accent-dim); transform: translateY(-1px); }

.btn-ghost {
  background: transparent;
  color: var(--text);
  border: 1.5px solid var(--border);
}
.btn-ghost:hover { border-color: var(--text); background: transparent; }

/* Essay list */
.essay-list { display: flex; flex-direction: column; gap: 0.9rem; margin: 1.2rem 0; }

.essay-item {
  background: var(--surface);
  border: 1px solid var(--border);
  border-left: 3px solid var(--accent);
  border-radius: var(--radius);
  padding: 1.2rem 1.4rem;
  text-decoration: none;
  color: var(--text);
  display: block;
  transition: border-color 0.2s, background 0.2s;
}

.essay-item:hover { border-color: var(--accent-dim); background: var(--surface-hover); }

.essay-item h3 { font-family: var(--serif); font-size: 1.1rem; margin-bottom: 0.3rem; }
.essay-item p { color: var(--text-dim); font-size: 0.85rem; margin-bottom: 0.5rem; }

/* Close section */
.close-section h2 { margin-bottom: 1rem; }
.close-text { color: var(--text-dim); max-width: 36rem; margin-bottom: 1.5rem; }

/* Agentic note */
.agentic-note p {
  font-size: 0.8rem;
  color: var(--text-dim);
  text-align: center;
}
.agentic-note a { color: var(--accent); text-decoration: none; }

/* Blog list (list + preview) */
.blog-list { display: flex; flex-direction: column; gap: 1rem; margin: 1.2rem 0; }

.blog-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
  transition: border-color 0.2s;
  text-decoration: none;
  color: var(--text);
  display: block;
}

.blog-card:hover { border-color: var(--accent-dim); }

.blog-card h3 { font-family: var(--serif); font-size: 1.1rem; margin-bottom: 0.3rem; }
.blog-card p { color: var(--text-dim); font-size: 0.9rem; margin-bottom: 0.5rem; }
.blog-card .meta { font-size: 0.75rem; color: var(--text-dim); display: flex; gap: 1rem; }
.blog-card .tag { background: var(--bg); padding: 0.1rem 0.5rem; border-radius: 10px; font-size: 0.7rem; color: var(--accent); }

.loading { color: var(--text-dim); }

/* Article (rendered markdown pages) */
.article-header {
  padding: 2rem 0 1.5rem;
  border-bottom: 1px solid var(--border);
  margin-bottom: 2rem;
}

.article-meta {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--accent);
  font-weight: 600;
  margin-bottom: 0.8rem;
}

.article-header h1 {
  font-family: var(--serif);
  font-size: clamp(1.9rem, 4vw, 2.6rem);
  font-weight: 500;
  line-height: 1.15;
  letter-spacing: -0.02em;
  margin-bottom: 0.7rem;
}

.article-summary { color: var(--text-dim); font-size: 1.05rem; max-width: 40rem; }

.article-body { max-width: 46rem; }

.article-body h2 {
  font-family: var(--serif);
  font-weight: 500;
  font-size: 1.4rem;
  margin: 2.2rem 0 0.8rem;
}

.article-body h3 {
  font-family: var(--serif);
  font-weight: 500;
  font-size: 1.15rem;
  margin: 1.8rem 0 0.6rem;
}

.article-body p { color: var(--text-dim); margin-bottom: 1.1rem; }

.article-body ul, .article-body ol { margin: 0 0 1.1rem 1.4rem; color: var(--text-dim); }
.article-body li { margin-bottom: 0.4rem; }

.article-body strong { color: var(--text); font-weight: 600; }

.article-body blockquote {
  border-left: 3px solid var(--accent);
  padding-left: 1.2rem;
  margin: 1.6rem 0;
  font-family: var(--serif);
  font-size: 1.1rem;
  color: var(--text);
}

.article-body a { color: var(--accent); text-decoration: none; border-bottom: 1.5px solid transparent; }
.article-body a:hover { border-bottom-color: var(--accent); }

.article-body table {
  width: 100%;
  border-collapse: collapse;
  margin: 0 0 1.4rem;
  font-size: 0.9rem;
}
.article-body th, .article-body td {
  text-align: left;
  padding: 0.6rem 0.8rem;
  border-bottom: 1px solid var(--border);
  vertical-align: top;
}
.article-body th { color: var(--text); border-bottom: 2px solid var(--accent); }
.article-body td { color: var(--text-dim); }

.article-body hr { border: none; border-top: 1px solid var(--border); margin: 2rem 0; }

.article-footer {
  margin-top: 3rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border);
  color: var(--text-dim);
  font-size: 0.9rem;
}

/* Search */
.search-desc { color: var(--text-dim); margin-bottom: 1.5rem; }

.search-box { display: flex; gap: 0.5rem; margin-bottom: 2rem; }

#search-input {
  flex: 1;
  padding: 0.75rem 1rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--text);
  font-size: 1rem;
  outline: none;
}

#search-input:focus { border-color: var(--accent); }

#search-btn {
  padding: 0.75rem 1.5rem;
  background: var(--accent);
  color: var(--bg);
  border: none;
  border-radius: var(--radius);
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s;
}

#search-btn:hover { background: var(--accent-dim); }

.search-results { display: flex; flex-direction: column; gap: 0.75rem; }

.search-result {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1rem 1.5rem;
}

.search-result h3 { font-family: var(--serif); font-size: 1.05rem; margin-bottom: 0.3rem; }
.search-result h3 a { color: var(--accent); text-decoration: none; }
.search-result p { color: var(--text-dim); font-size: 0.85rem; }
.search-result .score { font-size: 0.7rem; color: var(--text-dim); margin-top: 0.3rem; }

/* MCP code block */
.mcp-section { margin: 2.5rem 0; }
.mcp-section h2 { font-family: var(--serif); font-weight: 500; margin-bottom: 0.8rem; }

.code {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1rem;
  overflow-x: auto;
  font-size: 0.8rem;
  line-height: 1.5;
  margin: 1rem 0;
}

.code code { font-family: 'SF Mono', 'Fira Code', monospace; color: var(--text-dim); }

/* Footer */
.footer {
  border-top: 1px solid var(--border);
  padding: 1.5rem 2rem;
  text-align: center;
  color: var(--text-dim);
  font-size: 0.85rem;
}

.footer a { color: var(--accent); text-decoration: none; }
.footer span { color: var(--accent); font-weight: 600; }

/* Responsive */
@media (max-width: 600px) {
  .nav { padding: 1rem; flex-wrap: wrap; gap: 0.5rem; }
  .nav-links { gap: 0.9rem; flex-wrap: wrap; }
  .nav-links a { font-size: 0.8rem; }
  .hero h1 { font-size: 2rem; }
  .feature-grid { grid-template-columns: 1fr; }
  .container { padding: 1rem; }
}
