/* ════════════════════════════════════════
   SLED — Blog stylesheet
   Shared by /blog.html and /blog/*.html
   ════════════════════════════════════════ */

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

:root {
  --bg1: #0f0f14;
  --bg2: #0a0a1a;
  --bg-card: #17171f;
  --text: #ffffff;
  --text-dim: #e8e8f0;
  --muted: rgba(255,255,255,0.55);
  --subtle: rgba(255,255,255,0.28);
  --border: rgba(255,255,255,0.07);
  --grad-start: #4F6BFF;
  --grad-mid:   #8B5FFF;
  --grad-end:   #E658B0;
  --gradient: linear-gradient(135deg, #4F6BFF 0%, #8B5FFF 50%, #E658B0 100%);
  --release: #EA580C;
  --release-soft: #fb923c;
}

html { scroll-behavior: smooth; }
body {
  background: var(--bg1);
  color: var(--text);
  font-family: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  font-size: 17px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
a { color: inherit; }
img { display: block; max-width: 100%; }

.container { max-width: 1080px; margin: 0 auto; padding: 0 28px; }
.container-narrow { max-width: 720px; margin: 0 auto; padding: 0 28px; }

.gradient-text {
  background: var(--gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.sled-wordmark {
  font-family: 'Plus Jakarta Sans', 'Montserrat', system-ui, sans-serif;
  font-weight: 800;
  letter-spacing: -0.04em;
}

/* ════════════════════════════════════════
   TOP NAV
   ════════════════════════════════════════ */
.site-nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(15,15,20,0.72);
  -webkit-backdrop-filter: saturate(1.5) blur(20px);
  backdrop-filter: saturate(1.5) blur(20px);
  border-bottom: 1px solid var(--border);
}
.site-nav .nav-row {
  max-width: 1080px;
  margin: 0 auto;
  padding: 14px 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}
.nav-logo {
  font-family: 'Plus Jakarta Sans', system-ui, sans-serif;
  font-weight: 800;
  font-size: 22px;
  letter-spacing: -0.04em;
  background: var(--gradient);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  text-decoration: none;
  line-height: 1;
}
.nav-links {
  display: flex;
  align-items: center;
  gap: 28px;
}
.nav-links a {
  color: rgba(255,255,255,0.72);
  font-size: 14px;
  font-weight: 500;
  text-decoration: none;
  transition: color 0.15s ease;
}
.nav-links a:hover { color: var(--text); }
.nav-links a.active { color: var(--text); }
.nav-cta {
  padding: 9px 18px;
  border-radius: 999px;
  background: var(--gradient);
  color: #fff !important;
  font-weight: 600 !important;
  font-size: 13px !important;
  white-space: nowrap;
  transition: opacity 0.2s ease;
}
.nav-cta:hover { opacity: 0.88; }

@media (max-width: 560px) {
  .site-nav .nav-row { padding: 12px 20px; gap: 14px; }
  .nav-links { gap: 18px; }
  .nav-links a:not(.nav-cta) { font-size: 13px; }
  .nav-cta { padding: 7px 14px; }
}
@media (max-width: 400px) {
  .nav-links a:not(.nav-cta) { display: none; }
}

/* ════════════════════════════════════════
   GLOBAL — eyebrow, divider
   ════════════════════════════════════════ */
.eyebrow {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--subtle);
  margin-bottom: 18px;
}
.divider {
  width: 48px;
  height: 2px;
  background: var(--gradient);
  border-radius: 2px;
  margin-bottom: 40px;
}

/* ════════════════════════════════════════
   INDEX — hero
   ════════════════════════════════════════ */
.blog-hero {
  position: relative;
  padding: 96px 0 56px;
  text-align: left;
  overflow: hidden;
}
.blog-hero::before {
  content: "";
  position: absolute;
  top: -180px; left: 50%;
  width: 720px; height: 480px;
  transform: translateX(-50%);
  background: radial-gradient(ellipse, rgba(139,95,255,0.22) 0%, rgba(79,107,255,0.14) 35%, transparent 70%);
  pointer-events: none;
  z-index: 0;
}
.blog-hero .container-narrow { position: relative; z-index: 1; }
.blog-hero h1 {
  font-size: clamp(2.6rem, 6vw, 3.6rem);
  font-weight: 800;
  line-height: 1.05;
  letter-spacing: -0.035em;
  color: #fff;
  margin-bottom: 22px;
}
.blog-hero .lede {
  font-size: 18px;
  color: var(--muted);
  max-width: 560px;
  line-height: 1.65;
}

/* ════════════════════════════════════════
   INDEX — tag filter
   ════════════════════════════════════════ */
.tag-filter {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  padding: 0 0 8px;
  margin-bottom: 36px;
  border-bottom: 1px solid var(--border);
  padding-bottom: 28px;
}
.tag-filter button {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--muted);
  font-family: inherit;
  font-size: 13px;
  font-weight: 500;
  padding: 8px 16px;
  border-radius: 999px;
  cursor: pointer;
  transition: all 0.18s ease;
  letter-spacing: 0.02em;
}
.tag-filter button:hover {
  color: var(--text);
  border-color: rgba(255,255,255,0.18);
}
.tag-filter button.active {
  background: rgba(139,95,255,0.12);
  border-color: rgba(139,95,255,0.5);
  color: #fff;
}
.tag-filter .count {
  margin-left: 6px;
  font-size: 11px;
  opacity: 0.6;
  font-variant-numeric: tabular-nums;
}

/* ════════════════════════════════════════
   INDEX — post list
   ════════════════════════════════════════ */
.post-list {
  list-style: none;
  padding: 0;
  margin: 0 0 80px;
}
.post-row {
  border-bottom: 1px solid var(--border);
  transition: opacity 0.25s ease;
}
.post-row.hidden {
  display: none;
}
.post-row a {
  display: grid;
  grid-template-columns: 110px 1fr;
  gap: 32px;
  padding: 28px 0;
  text-decoration: none;
  transition: transform 0.25s ease;
}
.post-row a:hover { transform: translateX(4px); }
.post-row a:hover .post-title { color: #fff; }
.post-row a:hover .post-title::after { transform: translateX(6px); opacity: 1; }

.post-tagcol {
  display: flex;
  align-items: flex-start;
  padding-top: 2px;
}
.tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 5px 10px;
  border-radius: 6px;
  font-variant-numeric: tabular-nums;
}
.tag-post {
  background: rgba(139,95,255,0.12);
  color: #c4b1ff;
  border: 1px solid rgba(139,95,255,0.28);
}
.tag-release {
  background: rgba(234,88,12,0.12);
  color: #fbb072;
  border: 1px solid rgba(251,146,60,0.32);
}
.tag-release::before {
  content: "";
  width: 5px; height: 5px;
  border-radius: 50%;
  background: var(--release-soft);
  box-shadow: 0 0 6px var(--release-soft);
}

.post-body { min-width: 0; }
.post-title {
  font-size: clamp(20px, 2.4vw, 26px);
  font-weight: 700;
  letter-spacing: -0.018em;
  line-height: 1.25;
  margin-bottom: 8px;
  color: #f1f1f5;
  transition: color 0.18s ease;
}
.post-title::after {
  content: " →";
  display: inline-block;
  opacity: 0.5;
  transition: transform 0.25s ease, opacity 0.25s ease;
  margin-left: 2px;
}
.post-excerpt {
  color: var(--muted);
  font-size: 15px;
  line-height: 1.6;
  margin-bottom: 12px;
  max-width: 640px;
}
.post-meta {
  font-size: 12px;
  color: var(--subtle);
  letter-spacing: 0.04em;
  display: flex;
  gap: 10px;
  align-items: center;
  font-variant-numeric: tabular-nums;
}
.post-meta .dot { opacity: 0.5; }

@media (max-width: 720px) {
  .post-row a {
    grid-template-columns: 1fr;
    gap: 12px;
    padding: 24px 0;
  }
  .post-tagcol { padding-top: 0; }
}

/* ════════════════════════════════════════
   INLINE NEWSLETTER (mid-post)
   ════════════════════════════════════════ */
.newsletter-inline {
  margin: 56px 0;
  padding: 28px 28px;
  border-radius: 16px;
  background: linear-gradient(180deg, rgba(79,107,255,0.06), rgba(230,88,176,0.04));
  border: 1px solid var(--border);
  position: relative;
}
.newsletter-inline::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 16px;
  padding: 1px;
  background: linear-gradient(135deg, rgba(79,107,255,0.4), rgba(230,88,176,0.3));
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
          mask-composite: exclude;
  pointer-events: none;
}
.newsletter-inline h3 {
  font-size: 19px;
  font-weight: 700;
  letter-spacing: -0.015em;
  margin-bottom: 6px;
  color: #fff;
}
.newsletter-inline p {
  font-size: 14px;
  color: var(--muted);
  margin-bottom: 18px;
  line-height: 1.55;
}

/* ════════════════════════════════════════
   NEWSLETTER (full / bottom of index)
   ════════════════════════════════════════ */
.newsletter-block {
  margin: 40px 0 96px;
  padding: 56px 28px;
  border-radius: 24px;
  background: radial-gradient(120% 140% at 50% 0%, rgba(139,95,255,0.18) 0%, rgba(15,15,20,0) 60%), var(--bg2);
  border: 1px solid var(--border);
  text-align: center;
}
.newsletter-block h2 {
  font-size: clamp(28px, 4vw, 38px);
  font-weight: 800;
  letter-spacing: -0.025em;
  line-height: 1.1;
  margin-bottom: 12px;
}
.newsletter-block .sub {
  font-size: 16px;
  color: var(--muted);
  max-width: 460px;
  margin: 0 auto 28px;
  line-height: 1.6;
}

/* ════════════════════════════════════════
   NEWSLETTER FORM
   ════════════════════════════════════════ */
.news-form {
  width: 100%;
  max-width: 460px;
  margin: 0 auto;
}
.news-row {
  display: flex;
  gap: 10px;
  align-items: stretch;
}
.news-row input[type="email"] {
  flex: 1;
  padding: 13px 18px;
  border-radius: 12px;
  font-size: 15px;
  font-family: inherit;
  outline: none;
  background: rgba(255,255,255,0.04);
  color: var(--text);
  border: 1px solid rgba(255,255,255,0.12);
  transition: border-color 0.18s ease, background 0.18s ease;
}
.news-row input[type="email"]::placeholder { color: var(--subtle); }
.news-row input[type="email"]:focus {
  border-color: rgba(139,95,255,0.6);
  background: rgba(255,255,255,0.06);
}
.news-btn {
  padding: 13px 22px;
  border-radius: 12px;
  border: none;
  cursor: pointer;
  font-size: 14px;
  font-weight: 700;
  font-family: inherit;
  color: #fff;
  background: var(--gradient);
  white-space: nowrap;
  letter-spacing: 0.01em;
  transition: opacity 0.18s ease, transform 0.12s ease;
}
.news-btn:hover { opacity: 0.92; }
.news-btn:active { transform: scale(0.98); }
.news-success {
  display: none;
  margin-top: 14px;
  font-size: 14px;
  font-weight: 500;
  color: #c4b1ff;
}
.news-disclaimer {
  margin-top: 14px;
  font-size: 12px;
  color: var(--subtle);
  letter-spacing: 0.02em;
}
@media (max-width: 520px) {
  .news-row { flex-direction: column; }
  .news-btn { width: 100%; }
}

/* ════════════════════════════════════════
   ARTICLE PAGE
   ════════════════════════════════════════ */
.article {
  max-width: 680px;
  margin: 0 auto;
  padding: 64px 28px 96px;
  position: relative;
}
.article::before {
  content: "";
  position: absolute;
  top: -120px; left: 50%;
  width: 600px; height: 360px;
  transform: translateX(-50%);
  background: radial-gradient(ellipse, rgba(139,95,255,0.16) 0%, rgba(79,107,255,0.08) 40%, transparent 70%);
  pointer-events: none;
  z-index: -1;
}
.article-back {
  display: inline-block;
  font-size: 13px;
  color: var(--muted);
  text-decoration: none;
  margin-bottom: 40px;
  transition: color 0.15s ease;
  letter-spacing: 0.02em;
}
.article-back:hover { color: var(--text); }

.article-tagrow {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 22px;
}
.article-tagrow .date {
  font-size: 13px;
  color: var(--subtle);
  letter-spacing: 0.04em;
  font-variant-numeric: tabular-nums;
}

.article h1 {
  font-size: clamp(2.2rem, 5.5vw, 3rem);
  font-weight: 800;
  line-height: 1.08;
  letter-spacing: -0.03em;
  color: #fff;
  margin-bottom: 28px;
}

.byline {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 14px;
  color: var(--muted);
  margin-bottom: 40px;
  padding-bottom: 32px;
  border-bottom: 1px solid var(--border);
}
.byline .avatar {
  width: 34px; height: 34px;
  border-radius: 50%;
  background: var(--gradient);
  display: flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: 14px;
  color: #fff;
  flex-shrink: 0;
}
.byline .name { color: var(--text-dim); font-weight: 600; }
.byline .dot  { opacity: 0.4; }

/* prose */
.prose p {
  color: var(--text-dim);
  margin-bottom: 24px;
  font-size: 17px;
  line-height: 1.78;
  text-wrap: pretty;
}
.prose p.lead {
  font-size: 19px;
  color: #d8d8e8;
  line-height: 1.7;
}
.prose p:last-child { margin-bottom: 0; }
.prose h2 {
  font-size: 22px;
  font-weight: 700;
  color: #fff;
  letter-spacing: -0.018em;
  margin: 44px 0 14px;
  line-height: 1.3;
}
.prose h3 {
  font-size: 17px;
  font-weight: 700;
  color: #fff;
  margin: 32px 0 10px;
}
.prose ul, .prose ol {
  margin: 0 0 24px 0;
  padding-left: 22px;
}
.prose li {
  color: var(--text-dim);
  margin-bottom: 10px;
  line-height: 1.7;
}
.prose li::marker { color: var(--muted); }
.prose a {
  color: #c4b1ff;
  text-decoration: underline;
  text-decoration-color: rgba(139,95,255,0.4);
  text-underline-offset: 3px;
  transition: text-decoration-color 0.18s;
}
.prose a:hover { text-decoration-color: var(--grad-mid); }
.prose strong { color: #fff; font-weight: 600; }
.prose code {
  font-family: 'SFMono-Regular', Menlo, Consolas, monospace;
  font-size: 0.92em;
  background: rgba(255,255,255,0.06);
  padding: 2px 6px;
  border-radius: 4px;
}

/* release changelog list */
.changelog {
  list-style: none;
  margin: 24px 0;
  padding: 0;
}
.changelog li {
  display: grid;
  grid-template-columns: 80px 1fr;
  gap: 16px;
  padding: 14px 0;
  border-bottom: 1px solid var(--border);
  margin: 0;
  line-height: 1.55;
}
.changelog li:last-child { border-bottom: none; }
.changelog .kind {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding-top: 4px;
}
.changelog .kind-fix { color: var(--release-soft); }
.changelog .kind-new { color: #a5b4fc; }
.changelog .kind-tweak { color: var(--muted); }
.changelog .body { color: var(--text-dim); font-size: 15px; }

.callout {
  border-left: 3px solid;
  border-image: linear-gradient(180deg, var(--grad-start), var(--grad-end)) 1;
  padding: 18px 22px;
  background: var(--bg-card);
  border-radius: 0 12px 12px 0;
  margin: 36px 0;
}
.callout p {
  margin: 0;
  color: #c8c8e0;
  font-size: 16px;
  line-height: 1.65;
}

.signoff {
  margin-top: 52px;
  padding-top: 28px;
  border-top: 1px solid var(--border);
  font-size: 14px;
  color: var(--muted);
}

/* "more posts" */
.more-posts {
  max-width: 720px;
  margin: 0 auto;
  padding: 0 28px 96px;
}
.more-posts h4 {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--subtle);
  margin-bottom: 24px;
  padding-top: 56px;
  border-top: 1px solid var(--border);
}
.more-list {
  list-style: none;
  display: flex;
  flex-direction: column;
}
.more-list a {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 18px;
  padding: 18px 0;
  border-bottom: 1px solid var(--border);
  text-decoration: none;
  transition: transform 0.2s ease;
}
.more-list a:hover { transform: translateX(4px); }
.more-list .title {
  font-size: 16px;
  font-weight: 600;
  color: var(--text);
  letter-spacing: -0.01em;
}
.more-list .meta {
  font-size: 12px;
  color: var(--subtle);
  flex-shrink: 0;
  letter-spacing: 0.04em;
  font-variant-numeric: tabular-nums;
}

/* ════════════════════════════════════════
   FOOTER
   ════════════════════════════════════════ */
footer.site-footer {
  padding: 44px 0;
  background: var(--bg2);
  border-top: 1px solid var(--border);
}
.site-footer .footer-row {
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
}
.site-footer .footer-logo { font-size: 22px; }
.site-footer .footer-copy { font-size: 13px; color: #aaaaaa; }
.site-footer .footer-links { display: flex; gap: 24px; }
.site-footer .footer-links a {
  font-size: 13px;
  color: var(--muted);
  text-decoration: none;
  transition: color 0.15s;
}
.site-footer .footer-links a:hover { color: var(--text); }

/* ════════════════════════════════════════
   FADE IN
   ════════════════════════════════════════ */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: translateY(0); }
}
.fade-in { animation: fadeUp 0.6s cubic-bezier(0.16,1,0.3,1) both; }
.fade-in:nth-child(2) { animation-delay: 0.06s; }
.fade-in:nth-child(3) { animation-delay: 0.12s; }
.fade-in:nth-child(4) { animation-delay: 0.18s; }
.fade-in:nth-child(5) { animation-delay: 0.24s; }
.fade-in:nth-child(6) { animation-delay: 0.30s; }
