:root {
  --paper: #f6f1e9;
  --paper-deep: #ece3d5;
  --surface: #fbf8f3;
  --surface-strong: #fffaf2;
  --ink: #292622;
  --ink-soft: #625b52;
  --ink-faint: #8b8278;
  --line: #dcd2c3;
  --line-strong: #c8b9a5;
  --moss: #29413d;
  --moss-soft: #3d5c55;
  --terracotta: #b8614d;
  --terracotta-deep: #934a3a;
  --ochre: #d49b4d;
  --font-family: ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-display: ui-serif, Georgia, Cambria, "Times New Roman", serif;
  --container: 1180px;
  --reading-width: 720px;
  --space-1: 0.4rem;
  --space-2: 0.75rem;
  --space-3: 1rem;
  --space-4: 1.5rem;
  --space-5: 2rem;
  --space-6: 3rem;
  --space-7: 4.5rem;
  --space-8: 7rem;
  --radius-sm: 0.25rem;
  --radius-md: 0.75rem;
  --shadow-card: 0 0.75rem 2.5rem rgba(48, 39, 29, 0.07);
  --shadow-card-hover: 0 1.25rem 3.5rem rgba(48, 39, 29, 0.14);
  --ease: 220ms cubic-bezier(0.2, 0.75, 0.25, 1);
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  background: var(--paper);
}

body {
  min-width: 320px;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-family);
  font-size: 16px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

img, svg { max-width: 100%; }

a {
  color: var(--terracotta-deep);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.18em;
  transition: color var(--ease), background-color var(--ease), border-color var(--ease), transform var(--ease), box-shadow var(--ease);
}

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

a:focus-visible {
  outline: 3px solid var(--ochre);
  outline-offset: 4px;
  border-radius: var(--radius-sm);
}

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

.eyebrow {
  color: var(--terracotta-deep);
  font-size: 0.69rem;
  font-weight: 750;
  letter-spacing: 0.14em;
  line-height: 1.2;
  text-transform: uppercase;
}

.eyebrow-light { color: #e8bf88; }

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  border-bottom: 1px solid rgba(200, 185, 165, 0.78);
  background: rgba(246, 241, 233, 0.94);
  backdrop-filter: blur(12px);
}

.header-container {
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
  padding-block: 0.95rem 0.8rem;
}

.logo, .footer-logo {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  width: fit-content;
  color: var(--ink);
  text-decoration: none;
}

.logo:hover, .footer-logo:hover { color: var(--ink); }

.logo-mark {
  display: grid;
  width: 1.8rem;
  height: 1.8rem;
  place-items: center;
  border-radius: 50%;
  background: var(--terracotta);
  color: var(--surface-strong);
  font-family: var(--font-display);
  font-size: 1.1rem;
  font-weight: 700;
  line-height: 1;
}

.logo-type, .footer-logo {
  font-size: 1.06rem;
  font-weight: 650;
  letter-spacing: -0.045em;
}

.logo-type strong, .footer-logo strong { font-weight: 800; }

.main-nav {
  display: flex;
  align-items: baseline;
  min-width: 0;
  gap: 0.8rem;
  overflow-x: auto;
  overscroll-behavior-inline: contain;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
}

.main-nav::-webkit-scrollbar { display: none; }

.nav-kicker {
  flex: 0 0 auto;
  color: var(--ink-faint);
  font-size: 0.65rem;
  font-weight: 750;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.nav-list {
  display: flex;
  flex: 0 0 auto;
  gap: 1.15rem;
  list-style: none;
  white-space: nowrap;
}

.nav-list a {
  display: block;
  border-bottom: 1px solid transparent;
  color: var(--ink-soft);
  font-size: 0.8rem;
  font-weight: 650;
  line-height: 1.5;
  text-decoration: none;
}

.nav-list a:hover {
  border-color: var(--terracotta);
  color: var(--ink);
}

/* Shared page rhythm */
main { min-height: calc(100vh - 19rem); }

.page-container, .home-latest, .category-page, .article-page, .static-content {
  padding-block: var(--space-7);
}

.section-heading {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin-bottom: 2rem;
}

.section-heading h2 {
  margin-top: 0.55rem;
  color: var(--ink);
  font-family: var(--font-display);
  font-size: clamp(2rem, 6vw, 3.35rem);
  font-weight: 500;
  letter-spacing: -0.055em;
  line-height: 0.98;
}

.section-description {
  max-width: 25rem;
  color: var(--ink-soft);
  font-size: 0.95rem;
}

.section-heading-compact { margin-bottom: 1.5rem; }
.section-heading-compact h2 { font-size: clamp(1.7rem, 4vw, 2.2rem); }

/* Home hero */
.hero {
  position: relative;
  overflow: hidden;
  background: var(--moss);
  color: var(--surface-strong);
}

.hero::before {
  position: absolute;
  top: -7rem;
  right: -6rem;
  width: 18rem;
  height: 18rem;
  border: 1px solid rgba(232, 191, 136, 0.35);
  border-radius: 50%;
  content: "";
}

.hero::after {
  position: absolute;
  right: 12%;
  bottom: -5rem;
  width: 12rem;
  height: 12rem;
  border: 1px solid rgba(232, 191, 136, 0.18);
  border-radius: 50%;
  content: "";
}

.hero-inner {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 3.25rem;
  padding-block: clamp(4.3rem, 13vw, 8rem) clamp(4rem, 10vw, 7rem);
}

.hero-copy { max-width: 44rem; }

.hero h1 {
  max-width: 11ch;
  margin-top: 1rem;
  color: var(--surface-strong);
  font-family: var(--font-display);
  font-size: clamp(3.35rem, 13vw, 7.7rem);
  font-weight: 500;
  letter-spacing: -0.075em;
  line-height: 0.91;
}

.hero h1 em {
  color: #e8bf88;
  font-style: italic;
  white-space: nowrap;
}

.hero-intro {
  max-width: 34rem;
  margin-top: 1.6rem;
  color: rgba(255, 250, 242, 0.78);
  font-size: clamp(1rem, 2.5vw, 1.2rem);
  line-height: 1.55;
}

.hero-link {
  display: inline-flex;
  align-items: center;
  gap: 0.8rem;
  margin-top: 2rem;
  border-bottom: 1px solid #e8bf88;
  color: #f4d8ac;
  font-size: 0.78rem;
  font-weight: 750;
  letter-spacing: 0.07em;
  text-decoration: none;
  text-transform: uppercase;
}

.hero-link span {
  font-size: 1.1rem;
  line-height: 1;
  transition: transform var(--ease);
}

.hero-link:hover { color: var(--surface-strong); }
.hero-link:hover span { transform: translateY(0.2rem); }

.hero-aside {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  max-width: 24rem;
}

.hero-card {
  display: flex;
  flex-direction: column;
  gap: 1.15rem;
  width: min(100%, 19rem);
  padding: 1.2rem 1.25rem 1.35rem;
  border: 1px solid rgba(232, 191, 136, 0.45);
  border-radius: 0.15rem;
  background: rgba(38, 60, 56, 0.7);
  transform: rotate(-2deg);
}

.hero-card-label, .hero-card-caption {
  color: rgba(255, 250, 242, 0.63);
  font-size: 0.66rem;
  letter-spacing: 0.1em;
  line-height: 1.45;
  text-transform: uppercase;
}

.hero-card strong {
  color: #f4d8ac;
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 6vw, 2.65rem);
  font-weight: 500;
  letter-spacing: -0.055em;
  line-height: 0.94;
}

.hero-card-caption {
  max-width: 11rem;
  letter-spacing: 0.04em;
  text-transform: none;
}

.hero-index {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  padding-bottom: 0.35rem;
  color: #e8bf88;
  font-size: 0.64rem;
  font-weight: 750;
  letter-spacing: 0.1em;
}

.hero-index-line {
  display: block;
  width: 2rem;
  height: 1px;
  background: rgba(232, 191, 136, 0.65);
}

/* Article listing */
.home-latest { padding-top: clamp(4rem, 10vw, 7rem); }

.featured-layout {
  display: grid;
  gap: 1rem;
}

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

.article-card {
  position: relative;
  display: flex;
  min-height: 17rem;
  flex-direction: column;
  align-items: flex-start;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: var(--surface);
  box-shadow: 0 0 0 rgba(48, 39, 29, 0);
  color: var(--ink);
  text-decoration: none;
}

.article-card-media {
  width: 100%;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: var(--paper-deep);
}

.article-card-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 600ms cubic-bezier(.2,.75,.2,1);
}

.article-card:hover .article-card-media img,
.article-card:focus-visible .article-card-media img {
  transform: scale(1.035);
}

.article-card-body {
  display: flex;
  flex: 1;
  width: 100%;
  flex-direction: column;
  align-items: flex-start;
  padding: 1.35rem;
}

.article-card:hover {
  border-color: var(--line-strong);
  box-shadow: var(--shadow-card-hover);
  color: var(--ink);
  transform: translateY(-0.25rem);
}

.article-card:focus-visible {
  outline-color: var(--terracotta);
  outline-offset: 5px;
}

.article-card-top {
  display: flex;
  width: 100%;
  align-items: center;
  justify-content: space-between;
}

.category-badge {
  color: var(--terracotta-deep);
  font-size: 0.67rem;
  font-weight: 800;
  letter-spacing: 0.11em;
  line-height: 1.3;
  text-transform: uppercase;
}

.card-arrow {
  color: var(--terracotta);
  font-size: 1.35rem;
  line-height: 1;
  opacity: 0;
  transform: translate(-0.3rem, 0.3rem);
  transition: opacity var(--ease), transform var(--ease);
}

.article-card:hover .card-arrow,
.article-card:focus-visible .card-arrow {
  opacity: 1;
  transform: translate(0, 0);
}

.article-card h2, .article-card h3 {
  max-width: 20ch;
  margin-top: 1.7rem;
  color: var(--ink);
  font-family: var(--font-display);
  font-size: clamp(1.45rem, 4vw, 2rem);
  font-weight: 500;
  letter-spacing: -0.045em;
  line-height: 1.05;
}

.article-card p {
  max-width: 42ch;
  margin-top: 0.7rem;
  color: var(--ink-soft);
  font-size: 0.91rem;
  line-height: 1.52;
}

.article-card time {
  margin-top: auto;
  padding-top: 1.4rem;
  color: var(--ink-faint);
  font-size: 0.71rem;
  font-weight: 650;
  letter-spacing: 0.03em;
  text-transform: capitalize;
}

.article-card-featured {
  min-height: 25rem;
  border-color: var(--moss);
  background: var(--moss);
}

.article-card-featured .article-card-media {
  aspect-ratio: 16 / 9;
}

.article-card-featured .category-badge,
.article-card-featured .card-arrow { color: #e8bf88; }
.article-card-featured h2 { max-width: 15ch; color: var(--surface-strong); font-size: clamp(2rem, 8vw, 3.8rem); }
.article-card-featured p { max-width: 35ch; color: rgba(255, 250, 242, 0.73); }
.article-card-featured time { color: rgba(255, 250, 242, 0.58); }
.article-card-featured:hover { border-color: var(--moss-soft); color: var(--surface-strong); }
.article-card-featured:hover h2 { color: var(--surface-strong); }

.article-card-supporting { min-height: 15rem; }
.article-card-supporting h2 { margin-top: 1.2rem; font-size: clamp(1.3rem, 3vw, 1.7rem); }

.article-card-compact { min-height: 14rem; }
.article-card-compact h2 { margin-top: 1.2rem; font-size: 1.45rem; }

.empty-state {
  grid-column: 1 / -1;
  padding: 2.5rem 1.25rem;
  border: 1px dashed var(--line-strong);
  border-radius: var(--radius-md);
  color: var(--ink-soft);
  text-align: center;
}

/* Category pages */
.category-page { padding-top: clamp(3.5rem, 9vw, 6.5rem); }

.page-heading { max-width: 46rem; }

.page-heading h1 {
  margin-top: 0.75rem;
  color: var(--ink);
  font-family: var(--font-display);
  font-size: clamp(3.2rem, 11vw, 6.5rem);
  font-weight: 500;
  letter-spacing: -0.075em;
  line-height: 0.91;
}

.page-intro {
  max-width: 38rem;
  margin-top: 1.35rem;
  color: var(--ink-soft);
  font-size: clamp(1rem, 2.2vw, 1.18rem);
}

.category-rule {
  width: 100%;
  height: 1px;
  margin: 3.5rem 0 1.5rem;
  background: var(--line-strong);
}

/* Article pages */
.article-page {
  max-width: calc(var(--reading-width) + 4rem);
  padding-top: 0;
}

.breadcrumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  align-items: center;
  margin: 2rem 0 2.8rem;
  color: var(--ink-faint);
  font-size: 0.72rem;
  font-weight: 650;
}

.breadcrumbs a { color: var(--terracotta-deep); }
.breadcrumbs span { color: var(--line-strong); }

.single-article { max-width: var(--reading-width); margin-inline: auto; }

.article-header {
  margin-bottom: clamp(2.5rem, 7vw, 4.3rem);
  text-align: left;
}

.article-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.7rem;
}

.article-meta time,
.reading-time {
  color: var(--ink-faint);
  font-size: 0.75rem;
  font-weight: 650;
}

.article-meta time { text-transform: capitalize; }
.reading-time { text-transform: none; }

.meta-separator {
  width: 0.25rem;
  height: 0.25rem;
  border-radius: 50%;
  background: var(--ochre);
}

.article-header h1 {
  margin-top: 1.15rem;
  color: var(--ink);
  font-family: var(--font-display);
  font-size: clamp(2.7rem, 9vw, 5.65rem);
  font-weight: 500;
  letter-spacing: -0.075em;
  line-height: 0.94;
}

.article-hero-image {
  width: min(100%, 60rem);
  margin: 0 auto clamp(2.5rem, 7vw, 4.5rem);
  overflow: hidden;
  border-radius: var(--radius-lg);
  background: var(--paper-deep);
  box-shadow: var(--shadow-card);
}

.article-hero-image img {
  display: block;
  width: 100%;
  height: auto;
  max-height: 42rem;
  object-fit: cover;
  aspect-ratio: 16 / 10;
}

.article-dek {
  max-width: 42rem;
  margin-top: 1.5rem;
  color: var(--ink-soft);
  font-size: clamp(1.05rem, 2.5vw, 1.25rem);
  line-height: 1.55;
}

.article-toc {
  margin: 0 0 clamp(2.5rem, 6vw, 3.8rem);
  padding: clamp(1.35rem, 4vw, 2rem);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-md);
  background: var(--paper-deep);
}

.article-toc-title {
  margin-bottom: 0.85rem;
  color: var(--terracotta-deep);
  font-size: 0.72rem;
  font-weight: 750;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.article-toc ol {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.65rem 1.8rem;
  margin: 0;
  padding-left: 1.25rem;
}

.article-toc li {
  padding-left: 0.2rem;
  color: var(--terracotta);
}

.article-toc a {
  color: var(--ink-soft);
  font-size: 0.9rem;
  font-weight: 600;
  line-height: 1.35;
  text-decoration: none;
}

.article-toc a:hover {
  color: var(--terracotta-deep);
  text-decoration: underline;
  text-underline-offset: 0.2em;
}

.article-content {
  color: var(--ink);
  font-size: 1.08rem;
  line-height: 1.78;
}

.article-content > * { max-width: 100%; }
.article-content p { margin-bottom: 1.4rem; }
.article-content a { color: var(--terracotta-deep); font-weight: 600; }

.article-content h2, .article-content h3 {
  margin: 3rem 0 0.9rem;
  color: var(--ink);
  font-family: var(--font-display);
  font-weight: 500;
  letter-spacing: -0.045em;
  line-height: 1.08;
}

.article-content h2 { font-size: clamp(1.8rem, 5vw, 2.55rem); }
.article-content h3 { font-size: clamp(1.4rem, 4vw, 1.85rem); }

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

.article-content li { margin-bottom: 0.55rem; padding-left: 0.25rem; }
.article-content li::marker { color: var(--terracotta); }

.article-content blockquote {
  margin: 2rem 0;
  padding: 0.35rem 0 0.35rem 1.25rem;
  border-left: 3px solid var(--ochre);
  color: var(--moss);
  font-family: var(--font-display);
  font-size: 1.35rem;
  font-style: italic;
  line-height: 1.35;
}

.article-content img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: var(--radius-md);
}

.article-section-image {
  margin: 2.2rem 0 2.7rem;
}

.article-section-image img {
  aspect-ratio: 3 / 2;
  object-fit: cover;
  box-shadow: 0 18px 45px rgba(55, 42, 33, 0.1);
}

.article-content hr {
  margin: 2.5rem 0;
  border: 0;
  border-top: 1px solid var(--line);
}

.article-content code {
  padding: 0.15em 0.35em;
  border-radius: 0.2rem;
  background: var(--paper-deep);
  font-size: 0.88em;
}

.related-articles {
  margin: 4.5rem auto 0;
  padding-top: 3rem;
  border-top: 1px solid var(--line-strong);
}

.article-grid-related { grid-template-columns: 1fr; }

/* Empty slots collapse until a real ad is inserted. */
.ad-slot {
  position: relative;
  margin: 1.5rem 0;
}

.ad-slot:empty {
  min-height: 1px;
  height: 1px;
  margin: 0.8rem 0;
  background: rgba(200, 185, 165, 0.65);
}

.ad-slot-header:empty { margin: 0.75rem 0; }
.ad-slot-inline:empty { margin: 1.6rem 0; }
.ad-slot-footer:empty { margin: 2rem auto 0; max-width: var(--reading-width); }

@media (max-width: 640px) {
  .article-toc ol { grid-template-columns: 1fr; }
}

/* Static and legal pages */
.static-content {
  max-width: var(--reading-width);
  color: var(--ink-soft);
}

.static-content-narrow { max-width: 800px; }

.static-content h1 {
  margin-bottom: 2.5rem;
  color: var(--ink);
  font-family: var(--font-display);
  font-size: clamp(2.8rem, 8vw, 5rem);
  font-weight: 500;
  letter-spacing: -0.07em;
  line-height: 0.95;
}

.static-content h2 {
  margin: 3rem 0 0.8rem;
  color: var(--ink);
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 4vw, 2.15rem);
  font-weight: 500;
  letter-spacing: -0.04em;
  line-height: 1.1;
}

.static-content p { margin-bottom: 1.25rem; }
.static-content strong { color: var(--ink); }
.static-content a { color: var(--terracotta-deep); font-weight: 650; }

.contact-page p { max-width: 35rem; margin-inline: auto; font-size: 1.1rem; }
.not-found-page h1 { color: var(--terracotta); font-size: clamp(6rem, 25vw, 12rem); }

.btn {
  display: inline-block;
  margin-top: 1rem;
  padding: 0.8rem 1.4rem;
  border: 1px solid var(--terracotta);
  border-radius: 999px;
  background: var(--terracotta);
  color: var(--surface-strong);
  font-size: 0.78rem;
  font-weight: 750;
  letter-spacing: 0.06em;
  text-decoration: none;
  text-transform: uppercase;
}

.btn:hover { background: var(--terracotta-deep); color: var(--surface-strong); }

/* Footer */
.site-footer {
  margin-top: 2rem;
  padding: 2.5rem 0 1.25rem;
  border-top: 1px solid var(--line-strong);
  background: var(--paper-deep);
}

.footer-top {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  padding-bottom: 2rem;
}

.footer-top p {
  max-width: 20rem;
  color: var(--ink-soft);
  font-size: 0.88rem;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.7rem 1.25rem;
  padding: 1.2rem 0;
  border-top: 1px solid rgba(200, 185, 165, 0.8);
  border-bottom: 1px solid rgba(200, 185, 165, 0.8);
}

.footer-links a {
  color: var(--ink-soft);
  font-size: 0.78rem;
  font-weight: 650;
}

.footer-bottom {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  padding-top: 1.1rem;
}

.copyright, .footer-note {
  color: var(--ink-faint);
  font-size: 0.72rem;
}

/* Responsive composition */
@media (min-width: 680px) {
  .container { width: min(100% - 4rem, var(--container)); }

  .header-container {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    gap: 2rem;
    padding-block: 1rem;
  }

  .main-nav { justify-content: flex-end; }
  .featured-layout { grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr); align-items: stretch; }
  .supporting-grid { grid-template-columns: 1fr 1fr; }
  .article-grid-related { grid-template-columns: repeat(2, 1fr); }
  .footer-top { flex-direction: row; align-items: baseline; justify-content: space-between; }
  .footer-bottom { flex-direction: row; align-items: center; justify-content: space-between; }
}

@media (min-width: 920px) {
  .hero-inner { grid-template-columns: minmax(0, 1.2fr) minmax(18rem, 0.8fr); align-items: end; }
  .hero-aside { justify-self: end; width: 100%; }
  .section-heading { flex-direction: row; align-items: end; justify-content: space-between; }
  .section-description { padding-bottom: 0.25rem; }
  .category-page .article-grid { grid-template-columns: repeat(3, 1fr); gap: 1.25rem; }
  .category-page .article-card:first-child { grid-column: span 2; }
  .category-page .article-card:first-child h2 { font-size: 2.35rem; }
}

@media (min-width: 1160px) {
  .hero-inner { min-height: 38rem; }
  .article-grid-related { grid-template-columns: repeat(3, 1fr); }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}