:root {
  --color-text: #323232;
  --color-text-muted: #6b6b6b;
  --color-bg: #faf8f5;
  --color-surface: #ffffff;
  --color-accent: #dc5a25;
  --color-accent-hover: #c14d1e;
  --color-accent-soft: rgba(220, 90, 37, 0.1);
  --color-line: rgba(50, 50, 50, 0.12);
  --color-hero-from: #fff4ec;
  --color-hero-to: #f3ebe3;
  --font-display: "Fraunces", Georgia, serif;
  --font-body: "DM Sans", system-ui, sans-serif;
  --radius: 4px;
  --space: clamp(1.25rem, 3vw, 2rem);
  --max: 1120px;
  --article-max: 720px;
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.65;
  color: var(--color-text);
  background:
    radial-gradient(1200px 500px at 10% -10%, rgba(220, 90, 37, 0.08), transparent 60%),
    radial-gradient(900px 400px at 100% 0%, rgba(80, 60, 40, 0.05), transparent 55%),
    var(--color-bg);
  -webkit-font-smoothing: antialiased;
}

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

a {
  color: inherit;
  text-decoration-thickness: 1px;
  text-underline-offset: 0.18em;
}

a:hover {
  color: var(--color-accent);
}

.container {
  width: min(100% - 2 * var(--space), var(--max));
  margin-inline: auto;
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(250, 248, 245, 0.88);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--color-line);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 4.25rem;
  gap: 1rem;
}

.brand img {
  width: 98px;
  height: auto;
}

.nav {
  display: flex;
  gap: 1.5rem;
  font-size: 0.95rem;
  font-weight: 500;
}

.nav a {
  text-decoration: none;
}

.nav a[aria-current="page"] {
  color: var(--color-accent);
}

/* Blog hero */
.blog-hero {
  position: relative;
  overflow: hidden;
  padding: clamp(3rem, 8vw, 5.5rem) 0 clamp(2.5rem, 6vw, 4rem);
}

.blog-hero-inner {
  position: relative;
  z-index: 1;
  max-width: 38rem;
  animation: rise 0.7s ease both;
}

.hero-wash {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(135deg, var(--color-hero-from), var(--color-hero-to) 55%, transparent),
    repeating-linear-gradient(
      -12deg,
      transparent,
      transparent 18px,
      rgba(220, 90, 37, 0.03) 18px,
      rgba(220, 90, 37, 0.03) 19px
    );
  pointer-events: none;
}

.eyebrow {
  margin: 0 0 0.75rem;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--color-accent);
}

.blog-hero h1,
.article-header h1 {
  margin: 0 0 0.85rem;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(2rem, 4.5vw, 3.25rem);
  line-height: 1.15;
  letter-spacing: -0.02em;
}

.lede,
.article-lead {
  margin: 0;
  font-size: 1.125rem;
  color: var(--color-text-muted);
  max-width: 36rem;
}

/* Showcase */
.article-showcase {
  padding-bottom: clamp(3rem, 8vw, 5rem);
}

.post-card {
  background: var(--color-surface);
  border: 1px solid var(--color-line);
  overflow: hidden;
  transition: transform 0.25s ease, border-color 0.25s ease;
  animation: rise 0.7s ease both;
}

.post-card:nth-child(1) { animation-delay: 0.05s; }
.post-card:nth-child(2) { animation-delay: 0.1s; }
.post-card:nth-child(3) { animation-delay: 0.15s; }
.post-card:nth-child(4) { animation-delay: 0.2s; }

.post-card:hover {
  transform: translateY(-3px);
  border-color: rgba(220, 90, 37, 0.35);
}

.post-card--featured {
  display: grid;
  gap: 0;
  margin-bottom: clamp(1.5rem, 3vw, 2rem);
}

@media (min-width: 860px) {
  .post-card--featured {
    grid-template-columns: 1.15fr 1fr;
    min-height: 380px;
  }

  .post-card--featured .post-card-media {
    min-height: 100%;
  }

  .post-card--featured .post-card-media img {
    height: 100%;
    object-fit: cover;
  }

  .post-card--featured .post-card-body {
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: clamp(1.75rem, 3vw, 2.75rem);
  }

  .post-card--featured h2 {
    font-size: clamp(1.5rem, 2.4vw, 2rem);
  }
}

.post-grid {
  display: grid;
  gap: 1.25rem;
  grid-template-columns: 1fr;
}

@media (min-width: 640px) {
  .post-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

.post-card-media {
  display: block;
  overflow: hidden;
  aspect-ratio: 16 / 10;
  background: #e8e2db;
}

.post-card-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.45s ease;
}

.post-card:hover .post-card-media img {
  transform: scale(1.04);
}

.post-card-body {
  padding: 1.25rem 1.35rem 1.5rem;
}

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

.tag {
  display: inline-block;
  padding: 0.2rem 0.55rem;
  background: var(--color-accent-soft);
  color: var(--color-accent);
  font-weight: 600;
  font-size: 0.75rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  border-radius: var(--radius);
}

.post-card h2 {
  margin: 0 0 0.6rem;
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 600;
  line-height: 1.3;
  letter-spacing: -0.015em;
}

.post-card h2 a {
  text-decoration: none;
}

.post-card p {
  margin: 0 0 1rem;
  color: var(--color-text-muted);
  font-size: 0.98rem;
}

.text-link {
  font-weight: 600;
  font-size: 0.92rem;
  color: var(--color-accent);
  text-decoration: none;
}

.text-link:hover {
  color: var(--color-accent-hover);
  text-decoration: underline;
}

/* Article page */
.article-header {
  padding: clamp(2rem, 5vw, 3.5rem) 0 1.5rem;
  max-width: var(--article-max);
  margin-inline: auto;
  width: min(100% - 2 * var(--space), var(--article-max));
  animation: rise 0.65s ease both;
}

.breadcrumb {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 1.25rem;
  font-size: 0.875rem;
  color: var(--color-text-muted);
}

.breadcrumb a {
  text-decoration: none;
}

.article-author {
  margin-top: 1.25rem;
  font-size: 0.9rem;
  color: var(--color-text-muted);
}

.author-name {
  font-weight: 600;
  color: var(--color-text);
}

.article-cover {
  margin: 0 auto 2rem;
  width: min(100% - 2 * var(--space), var(--max));
  animation: rise 0.7s ease 0.08s both;
}

.article-cover img,
.article-inline-image img {
  width: 100%;
  border-radius: var(--radius);
  aspect-ratio: 16 / 9;
  object-fit: cover;
  background: #e8e2db;
}

.article-cover figcaption,
.article-inline-image figcaption {
  margin-top: 0.55rem;
  font-size: 0.85rem;
  color: var(--color-text-muted);
}

.article-body {
  width: min(100% - 2 * var(--space), var(--article-max));
  margin-inline: auto;
  padding-bottom: 2rem;
  animation: rise 0.7s ease 0.12s both;
}

.article-body h2 {
  margin: 2rem 0 0.75rem;
  font-family: var(--font-display);
  font-size: 1.45rem;
  font-weight: 600;
  letter-spacing: -0.015em;
  line-height: 1.25;
}

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

.article-body ul {
  padding-left: 1.2rem;
}

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

.article-body blockquote {
  margin: 1.5rem 0;
  padding: 1rem 1.25rem;
  border-left: 3px solid var(--color-accent);
  background: var(--color-accent-soft);
}

.article-body blockquote p {
  margin: 0;
  font-family: var(--font-display);
  font-size: 1.1rem;
  line-height: 1.45;
}

.article-inline-image {
  margin: 2rem 0;
}

.product-gallery {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
  margin: 2rem 0 1.25rem;
}

.product-gallery img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  border-radius: var(--radius);
  background: #e8e2db;
}

.product-gallery figcaption {
  grid-column: 1 / -1;
  margin: 0;
  font-size: 0.85rem;
  color: var(--color-text-muted);
}

.article-cta {
  margin: 1.25rem 0 1rem;
  padding: 1.5rem 1.5rem 1.65rem;
  background: linear-gradient(145deg, #fff7f1, #ffffff);
  border: 1px solid rgba(220, 90, 37, 0.25);
}

.article-cta-label {
  margin: 0 0 0.35rem;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--color-accent);
}

.article-cta-title {
  margin: 0 0 0.5rem;
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 600;
}

.article-cta p {
  margin: 0 0 1rem;
  color: var(--color-text-muted);
}

.article-cta .btn {
  margin-right: 0.75rem;
}

.article-cta-note {
  display: block;
  margin-top: 0.85rem !important;
  margin-bottom: 0 !important;
  font-size: 0.85rem;
}

.crosslinks {
  margin-top: 2.5rem;
  padding-top: 1.75rem;
  border-top: 1px solid var(--color-line);
}

.crosslinks h2 {
  margin: 0 0 1rem !important;
  font-size: 1.25rem !important;
}

.crosslinks-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 0.65rem;
}

.crosslinks-list a {
  display: block;
  padding: 0.85rem 1rem;
  background: var(--color-surface);
  border: 1px solid var(--color-line);
  text-decoration: none;
  font-weight: 500;
  font-size: 0.95rem;
  line-height: 1.4;
  transition: border-color 0.2s ease, transform 0.2s ease;
}

.crosslinks-list a:hover {
  border-color: rgba(220, 90, 37, 0.4);
  transform: translateY(-1px);
}

.crosslinks-list .tag {
  margin-right: 0.5rem;
}

.btn {
  display: inline-block;
  padding: 0.7rem 1.25rem;
  background: var(--color-accent);
  color: #fff !important;
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  border-radius: var(--radius);
  transition: background 0.2s ease;
}

.btn:hover {
  background: var(--color-accent-hover);
}

/* Related */
.related {
  padding: 1rem 0 clamp(3rem, 7vw, 4.5rem);
  border-top: 1px solid var(--color-line);
}

.related-title {
  margin: 0 0 1.25rem;
  font-family: var(--font-display);
  font-size: 1.35rem;
  font-weight: 600;
}

.related-grid {
  display: grid;
  gap: 1rem;
}

@media (min-width: 640px) {
  .related-grid {
    grid-template-columns: 1fr 1fr;
  }
}

.related-card {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  padding: 1.15rem 1.25rem;
  background: var(--color-surface);
  border: 1px solid var(--color-line);
  text-decoration: none;
  transition: border-color 0.2s ease, transform 0.2s ease;
}

.related-card:hover {
  border-color: rgba(220, 90, 37, 0.4);
  transform: translateY(-2px);
}

.related-card-title {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.05rem;
  line-height: 1.35;
}

/* Footer */
.site-footer {
  border-top: 1px solid var(--color-line);
  background: #f3efe9;
}

.footer-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem 1.5rem;
  padding: 1.5rem 0;
  font-size: 0.9rem;
  color: var(--color-text-muted);
}

.footer-brand {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 600;
  color: var(--color-text);
}

.footer-copy {
  margin: 0;
}

.site-footer a {
  text-decoration: none;
  font-weight: 500;
}

@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }
}
