/* Westark Data - editorial blog theme (self-contained) */

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

:root {
  --ink: #17191e;
  --ink-soft: #51565f;
  --ink-faint: #8a8f98;
  --paper: #fbfaf7;
  --card: #ffffff;
  --line: #e8e4db;
  --line-soft: #f0ede6;
  --navy: #1a2332;
  --accent: #1f6f93;
  --accent-deep: #164f6a;
  --max: 1080px;
  --read: 720px;
  --sans: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --serif: 'Fraunces', Georgia, 'Times New Roman', serif;
}

html { -webkit-text-size-adjust: 100%; }
body {
  font-family: var(--sans);
  color: var(--ink);
  background: var(--paper);
  line-height: 1.65;
  font-size: 18px;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--accent-deep); }
img { max-width: 100%; display: block; }

.wrap { max-width: var(--max); margin: 0 auto; padding: 0 1.5rem; }

/* Nav */
.nav {
  position: sticky; top: 0; z-index: 50;
  background: rgba(251,250,247,0.85);
  backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid var(--line);
}
.nav .wrap { display: flex; align-items: center; justify-content: space-between; height: 64px; gap: 1rem; }
.brand { font-family: var(--serif); font-weight: 600; font-size: 1.3rem; color: var(--ink); letter-spacing: -0.01em; }
.brand span { color: var(--accent); }
.nav-links { display: flex; align-items: center; gap: 1.6rem; }
.nav-links a { color: var(--ink-soft); font-size: 0.92rem; font-weight: 500; }
.nav-links a:hover { color: var(--ink); }
.nav-links a.signin { color: var(--accent); }

/* Hero */
.hero { padding: 5.5rem 0 3rem; border-bottom: 1px solid var(--line-soft); }
.hero .kicker { font-size: 0.8rem; font-weight: 600; letter-spacing: 0.12em; text-transform: uppercase; color: var(--accent); margin-bottom: 1.1rem; }
.hero h1 {
  font-family: var(--serif);
  font-weight: 600;
  font-size: clamp(2.4rem, 6vw, 3.8rem);
  line-height: 1.04;
  letter-spacing: -0.02em;
  max-width: 16ch;
  margin-bottom: 1.4rem;
}
.hero p { font-size: 1.18rem; color: var(--ink-soft); max-width: 56ch; }

/* Topic pills */
.topics { display: flex; flex-wrap: wrap; gap: 0.55rem; margin-top: 2rem; }
.pill { font-size: 0.82rem; font-weight: 500; color: var(--ink-soft); background: var(--card); border: 1px solid var(--line); border-radius: 999px; padding: 0.35rem 0.9rem; }

/* Feed */
.feed { padding: 3.5rem 0 4rem; }
.feed-head { font-family: var(--serif); font-weight: 600; font-size: 0.95rem; letter-spacing: 0.04em; text-transform: uppercase; color: var(--ink-faint); margin-bottom: 1.8rem; }

.post-card {
  display: block;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 2.2rem 2.2rem;
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}
.post-card:hover { transform: translateY(-3px); box-shadow: 0 18px 40px -22px rgba(22,79,106,0.45); border-color: #d9d3c7; }
.post-card .meta { display: flex; gap: 0.9rem; align-items: center; font-size: 0.82rem; color: var(--ink-faint); margin-bottom: 0.9rem; }
.post-card .meta .tag { color: var(--accent); font-weight: 600; }
.post-card h2 { font-family: var(--serif); font-weight: 600; font-size: 1.85rem; line-height: 1.15; letter-spacing: -0.015em; color: var(--ink); margin-bottom: 0.8rem; }
.post-card p { color: var(--ink-soft); font-size: 1.02rem; }
.post-card .more { display: inline-block; margin-top: 1.2rem; font-weight: 600; font-size: 0.95rem; color: var(--accent); }

.feed-note { margin-top: 2rem; color: var(--ink-faint); font-size: 0.95rem; }

/* Article */
.article { padding: 4rem 0 2rem; }
.article .wrap { max-width: var(--read); }
.article .back { font-size: 0.88rem; color: var(--ink-faint); font-weight: 500; }
.article .back:hover { color: var(--accent); }
.article-head { margin: 1.8rem 0 2.4rem; }
.article-head .meta { display: flex; flex-wrap: wrap; gap: 0.9rem; align-items: center; font-size: 0.85rem; color: var(--ink-faint); margin-bottom: 1.2rem; }
.article-head .meta .tag { color: var(--accent); font-weight: 600; }
.article-head h1 { font-family: var(--serif); font-weight: 600; font-size: clamp(2.1rem, 5vw, 3rem); line-height: 1.08; letter-spacing: -0.02em; }
.byline { display: flex; align-items: center; gap: 0.7rem; margin-top: 1.4rem; padding-top: 1.4rem; border-top: 1px solid var(--line-soft); }
.byline .avatar { width: 40px; height: 40px; border-radius: 50%; background: linear-gradient(135deg, var(--navy), var(--accent)); color: #fff; display: grid; place-items: center; font-weight: 600; font-size: 0.95rem; }
.byline .who { font-size: 0.9rem; }
.byline .who strong { color: var(--ink); font-weight: 600; }
.byline .who span { color: var(--ink-faint); display: block; }

.prose { font-size: 1.16rem; line-height: 1.75; color: #25282e; }
.prose > p { margin: 0 0 1.4rem; }
.prose h2 { font-family: var(--serif); font-weight: 600; font-size: 1.6rem; line-height: 1.2; letter-spacing: -0.015em; color: var(--ink); margin: 2.8rem 0 1rem; }
.prose h3 { font-weight: 600; font-size: 1.2rem; color: var(--ink); margin: 2rem 0 0.7rem; }
.prose ul { margin: 0 0 1.4rem 1.2rem; }
.prose li { margin-bottom: 0.6rem; }
.prose strong { font-weight: 600; color: var(--ink); }
.prose blockquote { margin: 2rem 0; padding: 0.4rem 0 0.4rem 1.4rem; border-left: 3px solid var(--accent); color: var(--ink-soft); font-style: italic; font-size: 1.18rem; }
.prose code { font-family: 'SF Mono', ui-monospace, 'Cascadia Code', Menlo, monospace; font-size: 0.86em; background: #f1efe9; padding: 0.12em 0.4em; border-radius: 5px; color: var(--accent-deep); }
.prose hr { border: none; border-top: 1px solid var(--line); margin: 2.8rem 0; }
.kicker-line { font-family: var(--serif); font-style: italic; font-size: 1.3rem; color: var(--ink-soft); margin-bottom: 2rem; line-height: 1.5; }

.endmark { margin-top: 3rem; padding-top: 1.6rem; border-top: 1px solid var(--line); color: var(--ink-faint); font-size: 0.95rem; }

/* Footer */
.foot { border-top: 1px solid var(--line); padding: 2.5rem 0 3rem; margin-top: 2rem; }
.foot .wrap { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 1rem; color: var(--ink-faint); font-size: 0.88rem; }
.foot a { color: var(--ink-soft); }

@media (max-width: 640px) {
  body { font-size: 17px; }
  .nav-links { gap: 1rem; }
  .nav-links a:not(.signin):not(.blog-link) { display: none; }
  .hero { padding: 3.5rem 0 2.5rem; }
  .post-card { padding: 1.6rem; }
}
