:root {
  --bg: #f7f5f1;
  --surface: #ffffff;
  --ink: #1a1a1a;
  --muted: #5c5c5c;
  --accent: #c45c26;
  --accent-dark: #9a451c;
  --border: #e4ded4;
  --radius: 12px;
  --shadow: 0 8px 24px rgba(26, 26, 26, 0.06);
  --max: 720px;
  --wide: 960px;
  --font: "Segoe UI", system-ui, -apple-system, sans-serif;
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.65;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

a {
  color: var(--accent-dark);
  text-decoration-thickness: 1px;
  text-underline-offset: 2px;
}

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

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

.site-header {
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 10;
}

.site-header__inner,
.site-footer__inner,
.wrap {
  width: min(100% - 2rem, var(--wide));
  margin-inline: auto;
}

.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.9rem 0;
}

.brand {
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--ink);
  text-decoration: none;
  letter-spacing: -0.02em;
}

.brand span {
  color: var(--accent);
}

.nav {
  display: flex;
  gap: 1.25rem;
  font-size: 0.95rem;
}

.nav a {
  color: var(--muted);
  text-decoration: none;
  font-weight: 500;
}

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

main {
  flex: 1;
  padding: 2.5rem 0 3.5rem;
}

.hero {
  width: min(100% - 2rem, var(--wide));
  margin: 0 auto 2rem;
}

.hero h1 {
  font-size: clamp(1.75rem, 3vw, 2.4rem);
  line-height: 1.2;
  letter-spacing: -0.03em;
  margin: 0 0 0.75rem;
}

.hero p {
  margin: 0;
  color: var(--muted);
  font-size: 1.05rem;
  max-width: 40rem;
}

.article-grid {
  width: min(100% - 2rem, var(--wide));
  margin: 0 auto;
  display: grid;
  gap: 1.25rem;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
}

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  display: flex;
  flex-direction: column;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.card:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 28px rgba(26, 26, 26, 0.1);
}

.card__image {
  aspect-ratio: 16 / 9;
  object-fit: cover;
  width: 100%;
  background: var(--border);
}

.card__body {
  padding: 1.15rem 1.25rem 1.35rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  flex: 1;
}

.card__meta {
  font-size: 0.8rem;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.card h2 {
  margin: 0;
  font-size: 1.15rem;
  line-height: 1.35;
  letter-spacing: -0.02em;
}

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

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

.card p {
  margin: 0;
  color: var(--muted);
  font-size: 0.95rem;
  flex: 1;
}

.card__cta {
  margin-top: 0.5rem;
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--accent-dark);
  text-decoration: none;
}

.article-wrap {
  width: min(100% - 2rem, var(--max));
  margin: 0 auto;
}

.article-hero {
  margin-bottom: 1.75rem;
}

.article-hero .card__meta {
  margin-bottom: 0.6rem;
}

.article-hero h1 {
  font-size: clamp(1.7rem, 3.2vw, 2.35rem);
  line-height: 1.2;
  letter-spacing: -0.03em;
  margin: 0 0 0.85rem;
}

.article-hero .excerpt {
  color: var(--muted);
  font-size: 1.05rem;
  margin: 0 0 1.25rem;
}

.article-hero img {
  border-radius: var(--radius);
  border: 1px solid var(--border);
  width: 100%;
}

.prose {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem 1.35rem;
  box-shadow: var(--shadow);
}

.prose > *:first-child {
  margin-top: 0;
}

.prose h2 {
  margin-top: 2rem;
  font-size: 1.35rem;
  letter-spacing: -0.02em;
  line-height: 1.3;
}

.prose h3 {
  margin-top: 1.5rem;
  font-size: 1.1rem;
}

.prose p,
.prose li {
  font-size: 1.02rem;
}

.prose table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.92rem;
  margin: 1.25rem 0;
  display: block;
  overflow-x: auto;
}

.prose th,
.prose td {
  border: 1px solid var(--border);
  padding: 0.55rem 0.7rem;
  text-align: left;
  vertical-align: top;
}

.prose th {
  background: var(--bg);
}

.prose ul,
.prose ol {
  padding-left: 1.25rem;
}

.back-link {
  display: inline-block;
  margin-bottom: 1.25rem;
  font-size: 0.95rem;
  font-weight: 500;
  text-decoration: none;
  color: var(--muted);
}

.back-link:hover {
  color: var(--accent);
}

.site-footer {
  border-top: 1px solid var(--border);
  background: var(--surface);
  padding: 1.5rem 0;
  color: var(--muted);
  font-size: 0.9rem;
}

.site-footer__inner {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1.5rem;
  justify-content: space-between;
  align-items: center;
}

.site-footer a {
  color: var(--muted);
  text-decoration: none;
}

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

@media (max-width: 640px) {
  .nav {
    gap: 0.85rem;
    font-size: 0.88rem;
  }

  .prose {
    padding: 1.15rem 1rem;
  }
}
