:root {
  --paper: #f7f1e5;
  --paper-deep: #efe2cf;
  --ink: #1f2430;
  --muted: #596275;
  --accent: #bc5b43;
  --accent-deep: #833d2d;
  --line: rgba(31, 36, 48, 0.12);
  --card: rgba(255, 252, 246, 0.84);
  --shadow: 0 24px 60px rgba(72, 53, 38, 0.12);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  font-family: "Iowan Old Style", "Palatino Linotype", "Book Antiqua", Georgia, serif;
  background:
    radial-gradient(circle at top left, rgba(188, 91, 67, 0.16), transparent 36%),
    radial-gradient(circle at right 20%, rgba(132, 166, 126, 0.16), transparent 28%),
    linear-gradient(180deg, #fbf7ef 0%, var(--paper) 38%, #f3eadb 100%);
  min-height: 100vh;
}

a {
  color: inherit;
  text-decoration: none;
}

.page-shell {
  width: min(1120px, calc(100vw - 32px));
  margin: 0 auto;
  padding: 32px 0 64px;
}

.masthead {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  align-items: center;
  padding: 16px 0 32px;
}

.brand {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.brand-mark {
  font-family: "Avenir Next", "Segoe UI", sans-serif;
  font-size: 0.76rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--accent-deep);
}

.brand-name {
  font-size: clamp(1.7rem, 3vw, 2.5rem);
  line-height: 1;
}

.brand-note {
  max-width: 560px;
  color: var(--muted);
  font-size: 1rem;
}

.hero {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(131, 61, 45, 0.12);
  border-radius: 28px;
  padding: clamp(28px, 6vw, 56px);
  background: linear-gradient(140deg, rgba(255, 252, 246, 0.92), rgba(255, 244, 229, 0.78));
  box-shadow: var(--shadow);
}

.hero::after {
  content: "";
  position: absolute;
  inset: auto -32px -42px auto;
  width: 220px;
  height: 220px;
  background: radial-gradient(circle, rgba(188, 91, 67, 0.16), transparent 68%);
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 8px 14px;
  border-radius: 999px;
  border: 1px solid rgba(188, 91, 67, 0.18);
  font-family: "Avenir Next", "Segoe UI", sans-serif;
  font-size: 0.82rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent-deep);
}

.hero h1 {
  margin: 20px 0 12px;
  font-size: clamp(2.6rem, 6vw, 5rem);
  line-height: 0.95;
}

.hero p {
  max-width: 650px;
  margin: 0;
  font-size: clamp(1.05rem, 2vw, 1.3rem);
  line-height: 1.7;
  color: #414958;
}

.hero-links {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 28px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 48px;
  padding: 0 18px;
  border-radius: 999px;
  font-family: "Avenir Next", "Segoe UI", sans-serif;
  transition: transform 180ms ease, box-shadow 180ms ease, background 180ms ease;
}

.button-primary {
  background: var(--accent);
  color: #fff7f0;
  box-shadow: 0 16px 28px rgba(131, 61, 45, 0.25);
}

.button-secondary {
  border: 1px solid rgba(31, 36, 48, 0.12);
  background: rgba(255, 255, 255, 0.46);
}

.button:hover {
  transform: translateY(-2px);
}

.section-head {
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 12px;
  margin: 56px 0 20px;
}

.section-head h2 {
  margin: 0;
  font-size: clamp(2rem, 4vw, 2.8rem);
}

.section-head p {
  margin: 0;
  color: var(--muted);
  font-family: "Avenir Next", "Segoe UI", sans-serif;
}

.post-grid {
  display: grid;
  gap: 20px;
  grid-template-columns: repeat(12, 1fr);
}

.post-card {
  grid-column: span 6;
  display: grid;
  gap: 14px;
  padding: 24px;
  border-radius: 24px;
  background: var(--card);
  border: 1px solid var(--line);
  box-shadow: 0 18px 42px rgba(90, 72, 51, 0.08);
  transition: transform 180ms ease, box-shadow 180ms ease;
}

.post-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 24px 54px rgba(90, 72, 51, 0.12);
}

.post-meta,
.post-tags,
.article-meta,
.footer-note {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 12px;
  color: var(--muted);
  font-family: "Avenir Next", "Segoe UI", sans-serif;
  font-size: 0.92rem;
}

.pill {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 0 12px;
  border-radius: 999px;
  background: rgba(188, 91, 67, 0.08);
  color: var(--accent-deep);
}

.post-card h3 {
  margin: 0;
  font-size: 1.8rem;
  line-height: 1.16;
}

.post-card p {
  margin: 0;
  line-height: 1.72;
  color: #414958;
}

.post-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--accent-deep);
  font-family: "Avenir Next", "Segoe UI", sans-serif;
}

.article-shell {
  width: min(860px, calc(100vw - 32px));
  margin: 0 auto;
  padding: 32px 0 72px;
}

.article-top {
  margin-bottom: 24px;
}

.article-card {
  padding: clamp(24px, 4vw, 40px);
  border-radius: 28px;
  background: rgba(255, 252, 246, 0.9);
  border: 1px solid rgba(31, 36, 48, 0.12);
  box-shadow: var(--shadow);
}

.article-card h1 {
  margin: 18px 0 12px;
  font-size: clamp(2.4rem, 5vw, 4rem);
  line-height: 0.98;
}

.article-body {
  font-size: 1.1rem;
  line-height: 1.9;
  color: #2b3240;
}

.article-body h2,
.article-body h3 {
  margin-top: 2.1em;
  margin-bottom: 0.6em;
  line-height: 1.2;
}

.article-body p,
.article-body ul,
.article-body blockquote,
.article-body pre {
  margin: 0 0 1.1em;
}

.article-body ul {
  padding-left: 1.3em;
}

.article-body code {
  padding: 0.14em 0.38em;
  border-radius: 6px;
  background: rgba(31, 36, 48, 0.08);
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  font-size: 0.92em;
}

.article-body pre {
  overflow-x: auto;
  padding: 18px;
  border-radius: 18px;
  background: #21252d;
  color: #f7f1e5;
}

.article-body pre code {
  padding: 0;
  background: transparent;
  color: inherit;
}

.article-body blockquote {
  padding: 2px 0 2px 18px;
  border-left: 3px solid rgba(188, 91, 67, 0.44);
  color: #4c5566;
}

.footer-note {
  margin-top: 36px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
}

@media (max-width: 820px) {
  .masthead,
  .section-head {
    display: grid;
  }

  .post-card {
    grid-column: 1 / -1;
  }
}

@media (prefers-reduced-motion: no-preference) {
  .hero,
  .post-card,
  .article-card {
    animation: rise-in 560ms ease both;
  }

  .post-card:nth-child(2) {
    animation-delay: 90ms;
  }

  .post-card:nth-child(3) {
    animation-delay: 140ms;
  }
}

@keyframes rise-in {
  from {
    opacity: 0;
    transform: translateY(18px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}
