/* ============================================
   vertigion.com — Main Stylesheet
   Clean, minimal, readable. No noise.
   ============================================ */

:root {
  --bg:         #0f1117;
  --bg-card:    #1a1d2e;
  --bg-hover:   #252840;
  --border:     #2a2d3e;
  --text:       #e2e8f0;
  --text-muted: #64748b;
  --text-dim:   #334155;
  --accent:     #4f8ef7;
  --accent-2:   #2dd4bf;
  --warning:    #fbbf24;
  --font-sans:  'Inter', system-ui, -apple-system, sans-serif;
  --font-mono:  'JetBrains Mono', 'Fira Code', monospace;
  --radius:     8px;
  --max-width:  720px;
}

/* Reset */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 16px; -webkit-text-size-adjust: 100%; }

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

/* Container */
.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 1.5rem;
}

/* ============ HEADER ============ */
.site-header {
  border-bottom: 1px solid var(--border);
  background: var(--bg);
  position: sticky;
  top: 0;
  z-index: 100;
}

.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 56px;
  max-width: 960px;
}

.site-title {
  font-family: var(--font-mono);
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--accent);
  text-decoration: none;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.site-nav {
  display: flex;
  gap: 0.25rem;
}

.site-nav a {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--text-muted);
  text-decoration: none;
  padding: 0.35rem 0.75rem;
  border-radius: 4px;
  transition: color 0.15s, background 0.15s;
}

.site-nav a:hover,
.site-nav a.active {
  color: var(--text);
  background: var(--bg-card);
}

.site-nav a.active {
  color: var(--accent);
}

/* ============ MAIN ============ */
.site-main {
  flex: 1;
  padding: 3rem 0 4rem;
}

/* ============ HOME PAGE ============ */
.home-hero {
  padding: 3rem 0 2rem;
}

.home-hero h1 {
  font-size: 2rem;
  font-weight: 600;
  color: var(--text);
  line-height: 1.2;
  letter-spacing: -0.02em;
}

.home-hero p {
  margin-top: 0.75rem;
  font-size: 1rem;
  color: var(--text-muted);
  max-width: 480px;
}

.home-section {
  margin-top: 3rem;
}

.section-label {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-dim);
  margin-bottom: 1rem;
}

/* ============ POST LIST ============ */
.post-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.post-list-item {
  display: flex;
  align-items: baseline;
  gap: 1rem;
  padding: 0.75rem 1rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  transition: border-color 0.15s, background 0.15s;
}

.post-list-item:hover {
  border-color: rgba(79, 142, 247, 0.4);
  background: var(--bg-hover);
}

.post-list-item time {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  color: var(--text-dim);
  flex-shrink: 0;
}

.post-list-item a {
  font-size: 0.9rem;
  color: var(--text);
  text-decoration: none;
  font-weight: 500;
}

.post-list-item a:hover {
  color: var(--accent);
}

.post-list-item .post-tag {
  margin-left: auto;
  font-family: var(--font-mono);
  font-size: 0.65rem;
  padding: 0.15rem 0.5rem;
  border-radius: 99px;
  background: rgba(79, 142, 247, 0.1);
  color: var(--accent);
  flex-shrink: 0;
}

/* ============ BLOG INDEX ============ */
.blog-header {
  padding-bottom: 2rem;
  border-bottom: 1px solid var(--border);
  margin-bottom: 2rem;
}

.blog-header h1 {
  font-size: 1.5rem;
  font-weight: 600;
}

.blog-header p {
  color: var(--text-muted);
  font-size: 0.875rem;
  margin-top: 0.25rem;
}

/* ============ POST ============ */
.post {
  padding-top: 1rem;
}

.post-header {
  margin-bottom: 2.5rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid var(--border);
}

.post-meta {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--text-muted);
  margin-bottom: 0.75rem;
  display: flex;
  gap: 1rem;
  align-items: center;
}

.post-categories {
  padding: 0.15rem 0.5rem;
  border-radius: 99px;
  background: rgba(45, 212, 191, 0.1);
  color: var(--accent-2);
}

.post-title {
  font-size: 1.75rem;
  font-weight: 600;
  line-height: 1.25;
  letter-spacing: -0.02em;
  color: var(--text);
}

.post-excerpt {
  margin-top: 0.75rem;
  font-size: 1rem;
  color: var(--text-muted);
  line-height: 1.6;
}

/* Post content typography */
.post-content h2 { font-size: 1.25rem; font-weight: 600; margin: 2rem 0 0.75rem; color: var(--text); }
.post-content h3 { font-size: 1.05rem; font-weight: 600; margin: 1.5rem 0 0.5rem; color: var(--text); }
.post-content p { margin-bottom: 1.25rem; color: var(--text); }
.post-content a { color: var(--accent); text-decoration: underline; text-underline-offset: 2px; }
.post-content ul, .post-content ol { margin: 0 0 1.25rem 1.5rem; }
.post-content li { margin-bottom: 0.35rem; }
.post-content blockquote {
  border-left: 3px solid var(--accent);
  padding: 0.5rem 1rem;
  margin: 1.5rem 0;
  background: var(--bg-card);
  border-radius: 0 var(--radius) var(--radius) 0;
  color: var(--text-muted);
  font-style: italic;
}
.post-content code {
  font-family: var(--font-mono);
  font-size: 0.85em;
  background: var(--bg-card);
  border: 1px solid var(--border);
  padding: 0.1em 0.4em;
  border-radius: 3px;
  color: var(--accent-2);
}
.post-content pre {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.25rem;
  overflow-x: auto;
  margin-bottom: 1.25rem;
}
.post-content pre code {
  background: none;
  border: none;
  padding: 0;
  font-size: 0.82rem;
  color: var(--text);
}
.post-content hr { border: none; border-top: 1px solid var(--border); margin: 2rem 0; }

.post-footer {
  margin-top: 3rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border);
}

.back-link {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--text-muted);
  text-decoration: none;
}

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

/* ============ ABOUT / PAGE ============ */
.page-header { margin-bottom: 2rem; padding-bottom: 1.5rem; border-bottom: 1px solid var(--border); }
.page-title { font-size: 1.5rem; font-weight: 600; }
.page-content p { margin-bottom: 1.25rem; }
.page-content a { color: var(--accent); }

/* ============ FOOTER ============ */
.site-footer {
  border-top: 1px solid var(--border);
  padding: 1.5rem 0;
}

.site-footer .container {
  max-width: 960px;
}

.site-footer p {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  color: var(--text-dim);
}

/* ============ RESPONSIVE ============ */
@media (max-width: 600px) {
  .home-hero h1 { font-size: 1.5rem; }
  .post-title { font-size: 1.35rem; }
  .site-header .container { padding: 0 1rem; }
  .post-list-item { flex-wrap: wrap; }
  .post-list-item .post-tag { margin-left: 0; }
}

/* ============ TAGS ============ */
.post-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-bottom: 1.25rem;
}

.tag {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  padding: 0.2rem 0.55rem;
  border-radius: 99px;
  background: rgba(45, 212, 191, 0.08);
  color: var(--accent-2);
  border: 1px solid rgba(45, 212, 191, 0.2);
}

/* ============ POST HERO IMAGE ============ */
.post-hero {
  margin-bottom: 2rem;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--border);
}

.post-hero img {
  width: 100%;
  height: auto;
  display: block;
  max-height: 400px;
  object-fit: cover;
}
