/* snoo.at — clean light theme */

@import url('https://fonts.googleapis.com/css2?family=Cardo:ital,wght@0,400;0,700;1,400&display=swap');

:root {
  --bg: #ffffff;
  --bg2: #f8f9fa;
  --bg3: #f1f3f5;
  --text: #1a1a2e;
  --text-muted: #6c757d;
  --accent: #2563eb;
  --accent-hover: #1d4ed8;
  --border: #e9ecef;
  --tag-bg: #e9ecef;
  --tag-text: #495057;
  --font: 'Cardo', Georgia, serif;
  --font-display: 'Cardo', Georgia, serif;
  --font-mono: "SF Mono", "Fira Code", "Cascadia Code", Consolas, monospace;
  --max-width: 720px;
}

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

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

body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-display);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--accent-hover); text-decoration: underline; }

/* ── Preview banner ── */
.preview-banner {
  background: #fef3c7;
  color: #92400e;
  text-align: center;
  padding: 0.5rem 1rem;
  font-size: 0.85rem;
  font-weight: 600;
  border-bottom: 1px solid #fde68a;
}

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

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

.site-name {
  font-family: var(--font-display);
  font-weight: normal;
  font-size: 1.2rem;
  color: var(--text);
  letter-spacing: 0;
  text-decoration: none;
}
.site-name:hover { color: var(--accent); text-decoration: none; }

.site-header nav { display: flex; gap: 1.5rem; }
.site-header nav a {
  font-size: 0.9rem;
  color: var(--text-muted);
  font-weight: 500;
}
.site-header nav a:hover { color: var(--accent); text-decoration: none; }

/* ── Layout ── */
.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 1.25rem;
}

main.container { padding-top: 3rem; padding-bottom: 4rem; }

/* ── Index ── */
.posts-header {
  margin-bottom: 2.5rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid var(--border);
}
.posts-header h1 { font-size: 1.5rem; font-weight: 700; margin: 0; }

.post-list { list-style: none; padding: 0; margin: 0; }

.post-card {
  padding: 1.75rem 0;
  border-bottom: 1px solid var(--border);
}
.post-card:first-child { padding-top: 0; }
.post-card:last-child { border-bottom: none; }

.post-card-meta {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-bottom: 0.5rem;
}

.post-card h2 {
  font-family: var(--font-display);
  margin: 0 0 0.5rem;
  font-size: 1.35rem;
  font-weight: normal;
  line-height: 1.4;
}
.post-card h2 a { color: var(--text); }
.post-card h2 a:hover { color: var(--accent); text-decoration: none; }

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

.post-card-footer {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
}

/* ── Tags ── */
.tag {
  margin-right: 0.5rem;
  margin-left: 0;
  margin-bottom: 0.4rem;
  display: inline-block;
  background: var(--tag-bg);
  color: var(--tag-text);
  font-size: 0.72rem;
  font-weight: 600;
  padding: 0.2rem 0.6rem;
  border-radius: 4px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  text-decoration: none;
  transition: background 0.2s ease, color 0.2s ease;
}

.tag:hover {
  background: var(--accent);
  color: #fff;
  text-decoration: none;
}

/* ── Tag page ── */
.tag-page {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

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

.tag-label {
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-size: 0.7rem;
  color: var(--text-muted);
  margin: 0 0 0.4rem;
}

.tag-header h1 {
  margin: 0;
  font-size: 2rem;
  font-weight: normal;
}

.tag-count {
  color: var(--text-muted);
  margin-top: 0.3rem;
}

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

.post-title {
  font-family: var(--font-display);
  font-size: 2.2rem;
  font-weight: normal;
  line-height: 1.25;
  margin: 0 0 1rem;
  letter-spacing: 0;
}

.post-meta {
  display: flex;
  align-items: center;
  gap: 1rem;
  font-size: 0.85rem;
  color: var(--text-muted);
  flex-wrap: wrap;
}

.post-source {
  margin-top: 1.5rem;
  padding: 1rem 1.25rem;
  background: var(--bg2);
  border-left: 3px solid var(--accent);
  border-radius: 0 6px 6px 0;
  font-size: 0.88rem;
  color: var(--text-muted);
}
.post-source a { color: var(--accent); word-break: break-all; }

/* ── Post content ── */
.post-content {
  font-size: 1.0rem;
  line-height: 1.8;
  color: var(--text);
}

.post-disclaimer {
  margin: 2rem 0 1rem;
  padding: 1rem 1.25rem;
  background: var(--bg2);
  border-left: 3px solid var(--accent);
  border-radius: 0 6px 6px 0;
  color: var(--text-muted);
  font-size: 0.85rem;
  line-height: 1.5;
}

.post-content h1,
.post-content h2,
.post-content h3 {
  font-weight: 700;
  line-height: 1.3;
  margin-top: 2rem;
  margin-bottom: 0.75rem;
  letter-spacing: -0.01em;
}

.post-content h2 { font-family: var(--font-display); font-weight: normal; font-size: 1.6rem; border-bottom: 1px solid var(--border); padding-bottom: 0.4rem; }
.post-content h3 { font-family: var(--font-display); font-weight: normal; font-size: 1.2rem; }

.post-content p { margin: 0 0 1.2rem; }

.post-content ul,
.post-content ol { padding-left: 1.5rem; margin-bottom: 1.2rem; }
.post-content li { margin-bottom: 0.4rem; }

.post-content blockquote {
  margin: 1.5rem 0;
  padding: 0.75rem 1.25rem;
  border-left: 3px solid var(--accent);
  background: var(--bg2);
  color: var(--text-muted);
  border-radius: 0 6px 6px 0;
  font-style: italic;
}

.post-content code {
  font-family: var(--font-mono);
  font-size: 0.875em;
  background: var(--bg2);
  border: 1px solid var(--border);
  padding: 0.15em 0.4em;
  border-radius: 4px;
}

.post-content pre {
  background: #002b36;
  background: #002b36;
  border-radius: 8px;
  padding: 1.25rem;
  overflow-x: auto;
  margin: 1.5rem 0;
  border: 1px solid var(--border);
}

.post-content pre code {
  background: transparent;
  border: none;
  padding: 0;
  font-size: 0.875rem;
  color: #cdd6f4;
}

.post-content img {
  max-width: 100%;
  border-radius: 8px;
  border: 1px solid var(--border);
}

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

.post-content a { text-decoration: underline; text-underline-offset: 2px; }

/* ── About page ── */
.about, .about-page { max-width: 640px; }
.about-header { margin-bottom: 2rem; padding-bottom: 1.5rem; border-bottom: 1px solid var(--border); }
.about-header h1 { font-family: var(--font-display); font-size: 2.2rem; font-weight: normal; margin: 0 0 0.4rem; letter-spacing: 0; }
.about-tagline { color: var(--text-muted); font-size: 0.95rem; margin: 0; }
.about-bio p { color: var(--text); line-height: 1.8; margin-bottom: 1rem; }
.about-section { margin-top: 2.5rem; }
.about-section h2 {
  font-size: 0.75rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: .08em;
  font-weight: 700;
  margin-bottom: 1rem;
}
.about-list { list-style: none; padding: 0; }
.about-list li { padding: 0.7rem 0; border-bottom: 1px solid var(--border); line-height: 1.6; }
.about-list li:last-child { border-bottom: none; }
.about-tags { display: flex; flex-wrap: wrap; gap: 6px; }
.about-links { list-style: none; padding: 0; }
.about-links li { padding: 0.4rem 0; color: var(--text-muted); }
.about-links a { color: var(--accent); }

.two-columns {
  display: flex;
  gap: 2rem;
  flex-wrap: wrap;
}

.two-columns > div {
  flex: 1;
  min-width: 240px;
}

/* ── Footer ── */
.site-footer {
  border-top: 1px solid var(--border);
  padding: 1.5rem 0;
  margin-top: 4rem;
}
.site-footer .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.82rem;
  color: var(--text-muted);
}
.site-footer a { color: var(--text-muted); }
.site-footer a:hover { color: var(--accent); text-decoration: none; }

/* ── Code highlight ── */
.highlight { background: transparent !important; border-radius: 8px; border: none; }

/* ── Empty state ── */
.empty-state {
  text-align: center;
  padding: 4rem 0;
  color: var(--text-muted);
}

/* ── Mobile ── */
@media (max-width: 640px) {
  .post-title { font-size: 1.5rem; }
  main.container { padding-top: 2rem; }
  .site-header nav { gap: 1rem; }
}
