/* ============================================
   Ravn AI Toolkit — GitHub Pages
   Inspired by ravn.co design language
   ============================================ */

@import url('https://fonts.googleapis.com/css2?family=Work+Sans:wght@400;600;800&family=Source+Code+Pro:wght@400;600&display=swap');

/* --- Reset & Base --- */

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

:root {
  --bg: #161616;
  --bg-elevated: #1e1e1e;
  --bg-card: #222222;
  --text: #ffffff;
  --text-muted: #adb5bd;
  --gold: #b7986a;
  --gold-dim: rgba(183, 152, 106, 0.15);
  --border: #2a2a2a;
  --code-bg: #1a1a1a;
  --font-sans: 'Work Sans', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-mono: 'Source Code Pro', monospace;
  --container: 780px;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-sans);
  font-weight: 400;
  background: var(--bg);
  color: var(--text);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

::selection {
  background: var(--gold);
  color: var(--bg);
}

/* --- Layout --- */

.container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 24px;
}

/* --- Header --- */

.site-header {
  padding: 48px 0 0;
  margin-bottom: 64px;
}

.site-header .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.site-logo {
  font-size: 18px;
  font-weight: 800;
  color: var(--text);
  text-decoration: none;
  letter-spacing: 2px;
  text-transform: uppercase;
}

.site-logo span {
  color: var(--gold);
}

.site-nav {
  display: flex;
  gap: 32px;
}

.site-nav a {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--text-muted);
  text-decoration: none;
  transition: color 0.3s ease;
}

.site-nav a:hover,
.site-nav a.active {
  color: var(--gold);
}

/* --- Hero --- */

.hero {
  margin-bottom: 80px;
}

.hero h1 {
  font-size: 52px;
  font-weight: 800;
  line-height: 1.15;
  margin-bottom: 20px;
}

.hero h1 span {
  color: var(--gold);
}

.hero p {
  font-size: 20px;
  color: var(--text-muted);
  max-width: 560px;
  line-height: 1.6;
}

/* --- Post List --- */

.post-list {
  list-style: none;
}

.post-item {
  padding: 40px 0;
  border-top: 1px solid var(--border);
}

.post-item:last-child {
  border-bottom: 1px solid var(--border);
}

.post-meta {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 12px;
}

.author-link {
  color: var(--gold);
  text-decoration: none;
  transition: opacity 0.3s ease;
}

.author-link:hover {
  opacity: 0.7;
}

.author-avatar {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  vertical-align: middle;
  margin-right: 4px;
  margin-top: -2px;
}

.post-item h2 {
  font-size: 28px;
  font-weight: 800;
  line-height: 1.3;
  margin-bottom: 12px;
}

.post-item h2 a {
  color: var(--text);
  text-decoration: none;
  transition: color 0.3s ease;
}

.post-item h2 a:hover {
  color: var(--gold);
}

.post-excerpt {
  color: var(--text-muted);
  font-size: 16px;
  line-height: 1.7;
}

.read-more {
  display: inline-block;
  margin-top: 16px;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--gold);
  text-decoration: none;
  transition: transform 0.3s ease;
}

.read-more:hover {
  transform: translateX(4px);
}

.read-more::after {
  content: ' \2192';
}

/* --- Post (single) --- */

.post-header {
  margin-bottom: 48px;
}

.post-header .post-meta {
  margin-bottom: 16px;
}

.post-header h1 {
  font-size: 42px;
  font-weight: 800;
  line-height: 1.2;
}

.post-content {
  font-size: 17px;
  line-height: 1.8;
}

.post-content h2 {
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--gold);
  margin: 48px 0 8px;
  padding-top: 48px;
  border-top: 1px solid var(--border);
}

.post-content h2:first-child {
  margin-top: 0;
  padding-top: 0;
  border-top: none;
}

.post-content p {
  margin-bottom: 24px;
  color: var(--text-muted);
}

.post-content strong {
  color: var(--text);
  font-weight: 600;
}

.post-content a {
  color: var(--gold);
  text-decoration: none;
  border-bottom: 1px solid var(--gold-dim);
  transition: border-color 0.3s ease;
}

.post-content a:hover {
  border-bottom-color: var(--gold);
}

.post-content ul,
.post-content ol {
  margin: 0 0 24px 24px;
  color: var(--text-muted);
}

.post-content li {
  margin-bottom: 8px;
}

.post-content code {
  font-family: var(--font-mono);
  font-size: 0.88em;
  background: var(--code-bg);
  border: 1px solid var(--border);
  padding: 2px 6px;
  border-radius: 4px;
  color: var(--gold);
}

.post-content pre {
  background: var(--code-bg);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 20px 24px;
  overflow-x: auto;
  margin-bottom: 24px;
}

.post-content pre code {
  background: none;
  border: none;
  padding: 0;
  font-size: 14px;
  color: var(--text-muted);
}

.post-content blockquote {
  border-left: 3px solid var(--gold);
  padding: 16px 24px;
  margin: 0 0 24px;
  background: var(--gold-dim);
  border-radius: 0 8px 8px 0;
}

.post-content blockquote p {
  margin-bottom: 0;
}

.post-content hr {
  border: none;
  border-top: 1px solid var(--border);
  margin: 48px 0;
}

.post-content img {
  max-width: 100%;
  border-radius: 8px;
}

/* --- Back link --- */

.back-link {
  display: inline-block;
  margin-bottom: 48px;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--text-muted);
  text-decoration: none;
  transition: color 0.3s ease;
}

.back-link::before {
  content: '\2190 ';
}

.back-link:hover {
  color: var(--gold);
}

/* --- Footer --- */

.site-footer {
  margin-top: 96px;
  padding: 48px 0;
  border-top: 1px solid var(--border);
}

.site-footer .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.footer-text {
  font-size: 13px;
  color: var(--text-muted);
}

.footer-text a {
  color: var(--gold);
  text-decoration: none;
}

.footer-links {
  display: flex;
  gap: 24px;
}

.footer-links a {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--text-muted);
  text-decoration: none;
  transition: color 0.3s ease;
}

.footer-links a:hover {
  color: var(--gold);
}

/* --- Section label --- */

.section-label {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 32px;
}

/* --- Responsive --- */

@media (max-width: 768px) {
  .site-header {
    padding: 32px 0 0;
    margin-bottom: 48px;
  }

  .site-header .container {
    flex-direction: column;
    align-items: flex-start;
    gap: 20px;
  }

  .hero h1 {
    font-size: 32px;
  }

  .hero p {
    font-size: 17px;
  }

  .hero {
    margin-bottom: 48px;
  }

  .post-header h1 {
    font-size: 28px;
  }

  .post-item h2 {
    font-size: 22px;
  }

  .site-footer .container {
    flex-direction: column;
    gap: 16px;
    text-align: center;
  }
}
