:root {
  --violet: #7c3aed;
  --violet-dark: #6d28d9;
  --ink: #0f172a;
  --muted: #4b5563;
  --faint: #9ca3af;
  --bg: #faf8fc;
  --white: #ffffff;
  --line: #ede9fe;
  --soft: #f5f3ff;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--muted);
  font-family: Inter, system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
}

a {
  color: var(--violet);
  text-decoration: none;
}

a:hover {
  color: var(--violet-dark);
}

img {
  max-width: 100%;
  height: auto;
}

.skip-link {
  position: absolute;
  left: -999px;
  top: 0;
  background: var(--white);
  padding: 0.5rem 1rem;
  z-index: 50;
}

.skip-link:focus {
  left: 1rem;
  top: 1rem;
}

.site-header {
  background: var(--white);
  border-bottom: 1px solid var(--line);
}

.site-header-inner,
.site-footer-inner,
.blog-wrap,
.hero-inner {
  width: min(1280px, calc(100% - 2.5rem));
  margin: 0 auto;
}

.site-header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.25rem 0;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  color: var(--ink);
  font-family: Sora, sans-serif;
  font-weight: 700;
  font-size: 18px;
}

.brand:hover {
  color: var(--ink);
}

.brand-mark {
  display: flex;
  width: 36px;
  height: 36px;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  background: var(--violet);
  flex-shrink: 0;
}

.brand-mark img {
  width: 28px;
  height: 24px;
  object-fit: contain;
  object-position: bottom;
}

.header-nav {
  display: none;
  align-items: center;
  gap: 1.5rem;
}

.header-nav a {
  color: var(--muted);
  font-size: 0.875rem;
  font-weight: 500;
}

.header-nav a:hover,
.header-nav a[aria-current="page"] {
  color: var(--violet);
}

.header-nav .login-link {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  font-weight: 600;
  color: var(--violet);
}

.menu-toggle {
  display: inline-flex;
  background: none;
  border: 0;
  color: var(--muted);
  font-size: 0.875rem;
  font-weight: 600;
  cursor: pointer;
}

.mobile-nav {
  display: none;
  border-top: 1px solid var(--line);
  padding: 0.75rem 1.25rem 1rem;
}

.mobile-nav a {
  display: block;
  border-radius: 0.5rem;
  padding: 0.5rem 0.75rem;
  color: var(--muted);
  font-size: 0.875rem;
  font-weight: 500;
}

.mobile-nav a:hover,
.mobile-nav a[aria-current="page"] {
  background: var(--soft);
  color: var(--violet);
}

body.nav-open .mobile-nav {
  display: block;
}

.hero {
  background: var(--white);
  padding: 4rem 0 3rem;
  border-bottom: 1px solid var(--line);
}

.eyebrow {
  font-family: Sora, sans-serif;
  font-size: 0.875rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--violet);
  margin: 0 0 0.75rem;
}

.hero h1,
.post-header h1 {
  margin: 0;
  color: var(--ink);
  font-family: Sora, sans-serif;
  font-weight: 800;
  line-height: 1.15;
}

.hero h1 {
  font-size: clamp(2rem, 4vw, 3rem);
  max-width: 18ch;
}

.hero p {
  margin: 1rem 0 0;
  max-width: 42rem;
  font-size: 1.0625rem;
  line-height: 1.6;
}

.post-grid {
  display: grid;
  gap: 1.5rem;
  padding: 3rem 0 4.5rem;
  grid-template-columns: 1fr;
}

.post-card {
  display: flex;
  flex-direction: column;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 1.25rem;
  overflow: hidden;
  color: inherit;
  box-shadow: 0 24px 24px rgba(124, 58, 237, 0.03);
}

.post-card:hover {
  color: inherit;
  border-color: #ddd6fe;
}

.post-card img {
  width: 100%;
  aspect-ratio: 1200 / 630;
  object-fit: cover;
  background: var(--soft);
}

.post-card-body {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  padding: 1.25rem 1.35rem 1.5rem;
}

.post-card-body h2 {
  margin: 0;
  color: var(--ink);
  font-family: Sora, sans-serif;
  font-size: 1.25rem;
  font-weight: 700;
  line-height: 1.3;
}

.post-card-body p {
  margin: 0;
  font-size: 0.9375rem;
  line-height: 1.55;
}

.post-date {
  font-size: 0.75rem;
  color: var(--faint);
}

.badge {
  display: inline-flex;
  width: fit-content;
  border-radius: 999px;
  background: var(--soft);
  color: var(--violet);
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 0.25rem 0.6rem;
}

.article-page {
  padding: 2.5rem 0 4rem;
}

.article-shell {
  width: min(760px, calc(100% - 2.5rem));
  margin: 0 auto;
}

.post-cover {
  display: block;
  width: 100%;
  border-radius: 1.25rem;
  border: 1px solid var(--line);
  aspect-ratio: 1200 / 630;
  object-fit: cover;
  background: var(--soft);
}

.post-header {
  margin: 1.5rem 0 2rem;
}

.post-header h1 {
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  margin-top: 0.5rem;
}

.article-body {
  font-size: 1.0625rem;
  line-height: 1.75;
  color: #334155;
}

.article-body h2 {
  color: var(--ink);
  font-family: Sora, sans-serif;
  font-size: 1.25rem;
  font-weight: 700;
  margin: 2.25rem 0 0.75rem;
}

.article-body p {
  margin: 0 0 1.1rem;
}

.article-body ul,
.article-body ol {
  margin: 0 0 1.1rem;
  padding-left: 1.35rem;
}

.article-body li {
  margin: 0.35rem 0;
}

.article-body strong {
  color: var(--ink);
  font-weight: 650;
}

.article-body a {
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.series-nav {
  display: grid;
  gap: 0.75rem;
  margin-top: 2.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--line);
}

.series-nav a {
  display: block;
  border: 1px solid var(--line);
  background: var(--white);
  border-radius: 1rem;
  padding: 1rem 1.15rem;
  color: var(--ink);
}

.series-nav a:hover {
  border-color: #ddd6fe;
  color: var(--violet);
}

.series-nav span {
  display: block;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--violet);
  margin-bottom: 0.25rem;
}

.back-link {
  display: inline-flex;
  margin: 0 0 1.25rem;
  font-size: 0.875rem;
  font-weight: 600;
}

.site-footer {
  border-top: 1px solid var(--line);
  background: var(--bg);
  padding: 3.5rem 0 2.5rem;
}

.footer-top {
  display: flex;
  flex-direction: column;
  gap: 2.5rem;
}

.footer-about {
  max-width: 280px;
}

.footer-about p {
  margin: 0.75rem 0 0;
  font-size: 13px;
  line-height: 1.35;
}

.footer-cols {
  display: flex;
  gap: 4rem;
  font-size: 13px;
}

.footer-cols p {
  margin: 0 0 0.75rem;
  font-family: Sora, sans-serif;
  font-weight: 700;
  color: var(--ink);
}

.footer-cols a {
  display: block;
  margin: 0 0 0.75rem;
  color: var(--muted);
}

.footer-cols a:hover {
  color: var(--violet);
}

.footer-bottom {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin-top: 2.5rem;
  padding-top: 2rem;
  border-top: 1px solid var(--line);
}

.footer-bottom p {
  margin: 0;
  font-size: 0.75rem;
  color: var(--faint);
}

.socials {
  display: flex;
  gap: 1rem;
}

.socials img {
  width: 18px;
  height: 18px;
}

.not-found {
  padding: 5rem 1.25rem;
  text-align: center;
}

@media (min-width: 768px) {
  .header-nav {
    display: flex;
  }

  .menu-toggle,
  .mobile-nav,
  body.nav-open .mobile-nav {
    display: none;
  }

  .post-grid {
    grid-template-columns: 1fr 1fr;
  }

  .footer-top {
    flex-direction: row;
    justify-content: space-between;
    align-items: flex-start;
  }

  .footer-bottom {
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
  }

  .series-nav {
    grid-template-columns: 1fr 1fr;
  }

  .site-header-inner,
  .site-footer-inner,
  .blog-wrap,
  .hero-inner {
    width: min(1280px, calc(100% - 5rem));
  }
}

@media (min-width: 1024px) {
  .site-header-inner,
  .site-footer-inner,
  .blog-wrap,
  .hero-inner {
    width: min(1120px, calc(100% - 10rem));
  }

  .site-header-inner {
    width: min(1280px, calc(100% - 10rem));
  }
}
