:root {
  --bg: #fbfaf6;
  --surface: #ffffff;
  --surface-strong: #f0efe7;
  --ink: #10231f;
  --muted: #68726c;
  --line: #dfded6;
  --coral: #ff6b4a;
  --teal: #2a7f9e;
  --moss: #4e7c59;
  --gold: #e3b23c;
  --shadow: 0 22px 60px rgba(16, 35, 31, 0.12);
  --radius: 8px;
  --max: 1180px;
}

:root.dark {
  --bg: #0f1412;
  --surface: #171e1b;
  --surface-strong: #202b27;
  --ink: #f5f1e8;
  --muted: #b7c0ba;
  --line: #34403b;
  --shadow: 0 22px 60px rgba(0, 0, 0, 0.35);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.6;
}

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

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

button,
input,
textarea {
  font: inherit;
}

.skip-link {
  position: fixed;
  left: 16px;
  top: 12px;
  z-index: 20;
  transform: translateY(-160%);
  background: var(--ink);
  color: var(--bg);
  padding: 10px 14px;
  border-radius: var(--radius);
}

.skip-link:focus {
  transform: translateY(0);
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  border-bottom: 1px solid color-mix(in srgb, var(--line) 78%, transparent);
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: blur(18px);
}

.nav-shell {
  width: min(var(--max), calc(100% - 32px));
  margin: 0 auto;
  min-height: 74px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  letter-spacing: 0;
}

.brand-mark {
  width: 38px;
  height: 38px;
  display: inline-grid;
  place-items: center;
  border-radius: 50%;
  background: var(--ink);
  color: var(--bg);
  font-weight: 900;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 8px;
}

.nav-links a,
.icon-button,
.nav-toggle {
  min-height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid transparent;
  border-radius: var(--radius);
  color: var(--muted);
  background: transparent;
  padding: 0 14px;
  cursor: pointer;
}

.nav-links a:hover,
.nav-links a[aria-current="page"],
.icon-button:hover,
.nav-toggle:hover {
  color: var(--ink);
  background: var(--surface-strong);
}

.icon-button,
.nav-toggle {
  width: 42px;
  padding: 0;
}

.nav-toggle {
  display: none;
}

.hero {
  position: relative;
  min-height: calc(100svh - 74px);
  isolation: isolate;
  display: grid;
  align-items: end;
  overflow: hidden;
}

.home-hero {
  min-height: min(760px, calc(100svh - 74px));
}

.hero-media {
  position: absolute;
  inset: 0;
  z-index: -2;
  background:
    linear-gradient(90deg, rgba(16, 35, 31, 0.82), rgba(16, 35, 31, 0.36) 55%, rgba(16, 35, 31, 0.18)),
    url("https://images.unsplash.com/photo-1497366754035-f200968a6e72?auto=format&fit=crop&w=1800&q=80") center / cover;
}

.hero::after {
  content: "";
  position: absolute;
  inset: auto 0 0;
  height: 32%;
  z-index: -1;
  background: linear-gradient(transparent, var(--bg));
}

.hero-content {
  width: min(var(--max), calc(100% - 32px));
  margin: 0 auto;
  padding: 96px 0 128px;
  color: #fffaf0;
}

.hero-content h1 {
  margin: 0;
  font-size: clamp(4.25rem, 12vw, 9rem);
  line-height: 0.9;
  letter-spacing: 0;
}

.hero-content p {
  max-width: 660px;
  margin: 22px 0 0;
  font-size: 1.22rem;
  color: rgba(255, 250, 240, 0.86);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 30px;
}

.button {
  min-height: 46px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  border: 1px solid transparent;
  border-radius: var(--radius);
  padding: 0 18px;
  font-weight: 750;
  cursor: pointer;
}

.button.primary {
  background: var(--coral);
  color: #220f0a;
}

.button.secondary {
  border-color: rgba(255, 255, 255, 0.34);
  color: #fffaf0;
  background: rgba(255, 255, 255, 0.1);
}

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

.eyebrow {
  margin: 0 0 10px;
  color: var(--coral);
  font-size: 0.8rem;
  font-weight: 850;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.feature-strip {
  width: min(var(--max), calc(100% - 32px));
  margin: -56px auto 70px;
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.feature-strip article {
  padding: 24px;
  border-right: 1px solid var(--line);
}

.feature-strip article:last-child {
  border-right: 0;
}

.feature-strip span {
  color: var(--teal);
  font-weight: 850;
}

.feature-strip strong {
  display: block;
  margin-top: 8px;
  font-size: 1.05rem;
}

.feature-strip p {
  margin: 6px 0 0;
  color: var(--muted);
}

.section {
  width: min(var(--max), calc(100% - 32px));
  margin: 0 auto 86px;
}

.intro-section,
.section-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 28px;
}

h1,
h2,
h3 {
  line-height: 1.05;
}

h2 {
  margin: 0;
  font-size: clamp(2rem, 4vw, 4rem);
  letter-spacing: 0;
}

.featured-link {
  width: min(440px, 100%);
  min-height: 132px;
  display: grid;
  grid-template-columns: 132px 1fr;
  align-items: center;
  gap: 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  overflow: hidden;
}

.featured-link img {
  width: 132px;
  height: 132px;
  object-fit: cover;
}

.featured-link span {
  padding-right: 18px;
}

.featured-link small {
  color: var(--moss);
  font-weight: 800;
}

.featured-link strong {
  display: block;
  margin-top: 6px;
  font-size: 1.2rem;
  line-height: 1.2;
}

.search-box {
  min-height: 48px;
  width: min(360px, 100%);
  display: flex;
  align-items: center;
  gap: 10px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  padding: 0 14px;
}

.search-box input {
  width: 100%;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--ink);
}

.filters {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 28px 0;
}

.filter-button {
  min-height: 40px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--muted);
  padding: 0 14px;
  cursor: pointer;
}

.filter-button.is-active {
  background: var(--ink);
  color: var(--bg);
  border-color: var(--ink);
}

.post-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
}

.post-card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  overflow: hidden;
  transition: transform 180ms ease, box-shadow 180ms ease;
}

.post-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow);
}

.post-image {
  display: block;
  aspect-ratio: 1 / 0.78;
  overflow: hidden;
}

.post-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 300ms ease;
}

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

.post-body {
  padding: 18px;
}

.post-meta {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  color: var(--muted);
  font-size: 0.8rem;
  font-weight: 700;
}

.post-body h3 {
  min-height: 92px;
  margin: 12px 0;
  font-size: 1.28rem;
}

.post-body p {
  margin: 0;
  color: var(--muted);
  font-size: 0.95rem;
}

.empty-state {
  border: 1px dashed var(--line);
  border-radius: var(--radius);
  padding: 28px;
  color: var(--muted);
  text-align: center;
}

.newsletter {
  width: min(var(--max), calc(100% - 32px));
  margin: 0 auto 90px;
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 36px;
  align-items: center;
  border-radius: var(--radius);
  background:
    linear-gradient(135deg, rgba(42, 127, 158, 0.18), rgba(227, 178, 60, 0.18)),
    var(--surface);
  border: 1px solid var(--line);
  padding: clamp(24px, 5vw, 52px);
}

.newsletter p {
  color: var(--muted);
}

.newsletter-form {
  display: flex;
  gap: 10px;
}

.newsletter-form label {
  flex: 1;
}

input,
textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--ink);
  padding: 13px 14px;
  outline-color: var(--teal);
}

.site-footer {
  width: min(var(--max), calc(100% - 32px));
  margin: 0 auto;
  padding: 34px 0 46px;
  border-top: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  color: var(--muted);
}

.footer-links {
  display: flex;
  gap: 18px;
  flex-wrap: wrap;
}

.page-hero {
  min-height: 420px;
  display: grid;
  align-items: end;
  color: #fffaf0;
  background-position: center;
  background-size: cover;
  position: relative;
  isolation: isolate;
}

.page-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  background: linear-gradient(90deg, rgba(16, 35, 31, 0.86), rgba(16, 35, 31, 0.28));
}

.about-hero {
  background-image: url("https://images.unsplash.com/photo-1519389950473-47ba0277781c?auto=format&fit=crop&w=1600&q=80");
}

.contact-hero {
  background-image: url("https://images.unsplash.com/photo-1516321497487-e288fb19713f?auto=format&fit=crop&w=1600&q=80");
}

.page-hero > div {
  position: relative;
  z-index: 1;
  width: min(var(--max), calc(100% - 32px));
  margin: 0 auto;
  padding: 80px 0;
}

.page-hero h1 {
  max-width: 760px;
  margin: 0;
  font-size: clamp(2.6rem, 7vw, 5.8rem);
}

.page-hero p:not(.eyebrow) {
  max-width: 620px;
  color: rgba(255, 250, 240, 0.86);
  font-size: 1.1rem;
}

.split-section {
  display: grid;
  grid-template-columns: 0.75fr 1.25fr;
  gap: 48px;
  align-items: start;
  margin-top: 82px;
}

.principles {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

.principles article,
.contact-aside {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  padding: 22px;
}

.principles svg {
  color: var(--teal);
}

.principles h3 {
  margin-bottom: 6px;
}

.principles p,
.contact-aside p {
  color: var(--muted);
}

.contact-layout {
  display: grid;
  grid-template-columns: 1fr 0.72fr;
  gap: 26px;
  align-items: start;
  margin-top: 82px;
}

.contact-form {
  display: grid;
  gap: 16px;
}

.contact-form label {
  display: grid;
  gap: 7px;
  font-weight: 760;
}

.article-shell {
  width: min(920px, calc(100% - 32px));
  margin: 52px auto 90px;
}

.article-header {
  margin-bottom: 30px;
}

.back-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 26px;
  color: var(--muted);
  font-weight: 750;
}

.article-header h1 {
  margin: 0;
  font-size: clamp(2.6rem, 7vw, 5.6rem);
}

.article-lead {
  max-width: 760px;
  color: var(--muted);
  font-size: 1.25rem;
}

.article-cover {
  width: 100%;
  aspect-ratio: 16 / 9;
  border-radius: var(--radius);
  object-fit: cover;
  box-shadow: var(--shadow);
}

.article-content {
  width: min(720px, 100%);
  margin: 42px auto 0;
  font-size: 1.1rem;
}

.article-content h2 {
  margin-top: 42px;
  font-size: 2rem;
}

.article-content p {
  color: color-mix(in srgb, var(--ink) 78%, var(--muted));
}

blockquote {
  margin: 34px 0;
  border-left: 4px solid var(--coral);
  padding: 10px 0 10px 22px;
  color: var(--ink);
  font-size: 1.35rem;
  font-weight: 800;
  line-height: 1.35;
}

.not-found {
  min-height: 100vh;
  display: grid;
  place-items: center;
}

.not-found-shell {
  width: min(620px, calc(100% - 32px));
  text-align: center;
}

.not-found-shell h1 {
  font-size: clamp(2.4rem, 8vw, 5rem);
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

@media (max-width: 980px) {
  .post-grid,
  .principles {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .intro-section,
  .section-heading,
  .newsletter,
  .split-section,
  .contact-layout {
    grid-template-columns: 1fr;
  }

  .section-heading,
  .intro-section {
    align-items: start;
    flex-direction: column;
  }
}

@media (max-width: 720px) {
  .nav-toggle {
    display: inline-flex;
  }

  .nav-links {
    position: absolute;
    left: 16px;
    right: 16px;
    top: 74px;
    display: none;
    flex-direction: column;
    align-items: stretch;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: var(--surface);
    padding: 10px;
    box-shadow: var(--shadow);
  }

  .nav-links.is-open {
    display: flex;
  }

  .nav-links a,
  .icon-button {
    width: 100%;
    justify-content: flex-start;
  }

  .hero-content {
    padding: 78px 0 110px;
  }

  .hero-content h1 {
    font-size: clamp(4rem, 24vw, 6rem);
  }

  .feature-strip,
  .post-grid,
  .principles {
    grid-template-columns: 1fr;
  }

  .feature-strip article {
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .feature-strip article:last-child {
    border-bottom: 0;
  }

  .newsletter-form {
    flex-direction: column;
  }

  .featured-link {
    grid-template-columns: 104px 1fr;
  }

  .featured-link img {
    width: 104px;
    height: 124px;
  }

  .site-footer {
    align-items: flex-start;
    flex-direction: column;
  }

  .post-body h3 {
    min-height: auto;
  }
}
