:root {
  --color-ink: #17201b;
  --color-muted: #5b675f;
  --color-line: #dbe3dc;
  --color-paper: #fbfcf9;
  --color-soft: #eef5f1;
  --color-brand: #116a57;
  --color-brand-dark: #0b493e;
  --color-accent: #c96b2c;
  --color-blue: #294c7a;
  --shadow: 0 18px 40px rgba(22, 38, 31, 0.12);
  --max-width: 1120px;
  --radius: 8px;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  color: var(--color-ink);
  background: var(--color-paper);
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.75;
  letter-spacing: 0;
  overflow-x: hidden;
}

.nav-is-open body {
  overflow: hidden;
}

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

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

.skip-link,
.screen-reader-text {
  position: absolute;
  left: -9999px;
}

.skip-link:focus {
  left: 1rem;
  top: 1rem;
  z-index: 20;
  padding: 0.75rem 1rem;
  background: #fff;
  border: 2px solid var(--color-brand);
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  border-bottom: 1px solid rgba(219, 227, 220, 0.9);
  background: rgba(251, 252, 249, 0.94);
  backdrop-filter: blur(14px);
}

.site-header__inner,
.section__inner,
.article-header__inner,
.article-body,
.article-footer,
.site-footer__inner {
  width: min(calc(100% - 32px), var(--max-width));
  margin: 0 auto;
}

.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 76px;
  gap: 1rem;
}

.site-brand {
  display: inline-flex;
  flex-direction: column;
  gap: 0.08rem;
  color: var(--color-ink);
  text-decoration: none;
}

.site-brand__name {
  font-weight: 800;
  font-size: 1.25rem;
}

.site-brand__tagline {
  color: var(--color-muted);
  font-size: 0.78rem;
}

.primary-nav ul,
.footer-nav ul {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.primary-nav a,
.footer-nav a {
  display: inline-flex;
  align-items: center;
  min-height: 42px;
  padding: 0.45rem 0.65rem;
  border-radius: var(--radius);
  color: var(--color-ink);
  font-size: 0.9rem;
  font-weight: 700;
  text-decoration: none;
  transition: background 0.16s ease, color 0.16s ease;
}

.primary-nav a:hover,
.primary-nav a:focus-visible,
.primary-nav .current-menu-item a,
.footer-nav a:hover,
.footer-nav a:focus-visible,
.footer-nav .current-menu-item a {
  background: rgba(17, 106, 87, 0.09);
  color: var(--color-brand);
}

.nav-toggle {
  display: none;
  align-items: center;
  gap: 0.5rem;
  min-height: 44px;
  padding: 0.6rem 0.8rem;
  border: 1px solid var(--color-line);
  border-radius: var(--radius);
  background: #fff;
  color: var(--color-ink);
  font: inherit;
  font-weight: 700;
  transition: background 0.16s ease, border-color 0.16s ease, color 0.16s ease;
}

.nav-toggle[aria-expanded="true"] {
  border-color: rgba(17, 106, 87, 0.35);
  background: var(--color-brand);
  color: #fff;
}

.nav-toggle__bar,
.nav-toggle__bar::before,
.nav-toggle__bar::after {
  display: block;
  width: 18px;
  height: 2px;
  background: currentColor;
  content: "";
}

.nav-toggle__bar::before {
  transform: translateY(-6px);
}

.nav-toggle__bar::after {
  transform: translateY(4px);
}

.nav-toggle[aria-expanded="true"] .nav-toggle__bar {
  background: transparent;
}

.nav-toggle[aria-expanded="true"] .nav-toggle__bar::before {
  transform: translateY(0) rotate(45deg);
}

.nav-toggle[aria-expanded="true"] .nav-toggle__bar::after {
  transform: translateY(-2px) rotate(-45deg);
}

.hero {
  min-height: 520px;
  display: flex;
  align-items: center;
  background:
    linear-gradient(90deg, rgba(251, 252, 249, 0.97), rgba(251, 252, 249, 0.86) 58%, rgba(251, 252, 249, 0.72)),
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='1200' height='700' viewBox='0 0 1200 700'%3E%3Crect width='1200' height='700' fill='%23eef5f1'/%3E%3Cg fill='none' stroke='%23116a57' stroke-opacity='.20' stroke-width='2'%3E%3Cpath d='M110 470c120-170 235-150 330-80s185 87 300-20 230-110 350 10'/%3E%3Cpath d='M90 250c150-90 275-100 420-25s300 65 520-95'/%3E%3C/g%3E%3Cg fill='%23c96b2c' fill-opacity='.18'%3E%3Ccircle cx='885' cy='260' r='90'/%3E%3Ccircle cx='1020' cy='410' r='54'/%3E%3C/g%3E%3Cg fill='%23294c7a' fill-opacity='.16'%3E%3Crect x='720' y='405' width='210' height='120' rx='8'/%3E%3Crect x='935' y='190' width='130' height='86' rx='8'/%3E%3C/g%3E%3C/svg%3E");
  background-position: center;
  background-size: cover;
}

.hero__inner {
  width: min(calc(100% - 32px), var(--max-width));
  margin: 0 auto;
  padding: 5rem 0;
}

.eyebrow {
  margin: 0 0 0.75rem;
  color: var(--color-brand);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

h1,
h2,
h3 {
  margin: 0;
  line-height: 1.28;
  letter-spacing: 0;
}

.hero h1 {
  max-width: 760px;
  font-size: clamp(2.2rem, 5vw, 4.8rem);
}

.hero__lead {
  max-width: 680px;
  margin: 1.35rem 0 0;
  color: var(--color-muted);
  font-size: 1.08rem;
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.85rem;
  margin-top: 2rem;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0.75rem 1.15rem;
  border-radius: var(--radius);
  font-weight: 800;
  text-decoration: none;
}

.button--primary {
  background: var(--color-brand);
  color: #fff;
}

.button--secondary {
  border: 1px solid var(--color-line);
  background: #fff;
  color: var(--color-ink);
}

.section {
  padding: 4.5rem 0;
}

.section--intro,
.section--latest {
  background: #fff;
}

.split {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: 3rem;
  align-items: start;
}

.split h2,
.section-heading h2,
.cta-band h2 {
  font-size: clamp(1.7rem, 3vw, 2.45rem);
}

.split p:last-child,
.cta-band p {
  margin: 0;
  color: var(--color-muted);
  font-size: 1.04rem;
}

.author-panel {
  display: grid;
  grid-template-columns: minmax(180px, 260px) minmax(0, 1fr);
  gap: 2.2rem;
  align-items: center;
  padding: 2rem;
  border: 1px solid var(--color-line);
  border-radius: var(--radius);
  background: #fff;
  box-shadow: 0 12px 30px rgba(22, 38, 31, 0.08);
}

.author-panel--profile {
  margin-top: -1.5rem;
}

.author-panel__image {
  width: min(100%, 240px);
  aspect-ratio: 1;
  margin: 0 auto;
  overflow: hidden;
  border: 4px solid #f0c766;
  border-radius: 50%;
  background: var(--color-soft);
}

.author-panel__image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.author-panel__body h2 {
  max-width: 760px;
  font-size: clamp(1.65rem, 3vw, 2.35rem);
}

.author-panel__body p {
  max-width: 760px;
  color: var(--color-muted);
}

.author-panel__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.85rem;
  margin-top: 1.35rem;
}

.section-heading {
  margin-bottom: 1.8rem;
}

.section-heading--row {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 1rem;
}

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

.post-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.topic-card,
.post-card__link {
  display: flex;
  min-height: 100%;
  border: 1px solid var(--color-line);
  border-radius: var(--radius);
  background: #fff;
  color: var(--color-ink);
  text-decoration: none;
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}

.topic-card {
  flex-direction: column;
  gap: 1rem;
  padding: 1.25rem;
}

.topic-card:hover,
.post-card__link:hover {
  transform: translateY(-2px);
  border-color: rgba(17, 106, 87, 0.45);
  box-shadow: var(--shadow);
}

.topic-card__label,
.post-card__meta,
.article-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  color: var(--color-muted);
  font-size: 0.82rem;
  font-weight: 700;
}

.topic-card__label {
  color: var(--color-accent);
}

.post-card__link {
  flex-direction: column;
  overflow: hidden;
}

.post-card__image {
  aspect-ratio: 16 / 9;
  margin: 0;
  background: var(--color-soft);
}

.post-card__image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.post-card__body {
  padding: 1.15rem;
}

.post-card h3 {
  margin-top: 0.6rem;
  font-size: 1.15rem;
}

.post-card p:last-child {
  margin-bottom: 0;
  color: var(--color-muted);
  font-size: 0.94rem;
}

.text-link {
  color: var(--color-brand);
  font-weight: 800;
}

.empty-state,
.cta-band,
.post-cta {
  border: 1px solid var(--color-line);
  border-radius: var(--radius);
  background: #fff;
  padding: 1.5rem;
}

.cta-band {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  background: var(--color-brand-dark);
  color: #fff;
}

.cta-band .eyebrow,
.cta-band p {
  color: rgba(255, 255, 255, 0.78);
}

.page-hero {
  padding: 4rem 0;
  background: var(--color-soft);
}

.page-hero h1 {
  font-size: clamp(2rem, 4vw, 3.4rem);
}

.page-hero p {
  max-width: 720px;
  color: var(--color-muted);
}

.article-header {
  padding: 4.2rem 0 2rem;
  background: var(--color-soft);
}

.article-header__inner {
  max-width: 880px;
}

.article-header h1 {
  margin-top: 0.8rem;
  font-size: clamp(2rem, 4vw, 3.7rem);
}

.article-lead {
  color: var(--color-muted);
  font-size: 1.08rem;
}

.article-visual {
  width: min(calc(100% - 32px), 960px);
  margin: 2rem auto 0;
}

.article-visual img {
  width: 100%;
  border-radius: var(--radius);
}

.article-toc {
  width: min(calc(100% - 32px), 760px);
  margin: 2rem auto 0;
  border: 1px solid var(--color-line);
  border-radius: var(--radius);
  background: #fff;
  box-shadow: 0 10px 24px rgba(22, 38, 31, 0.06);
}

.article-toc summary {
  min-height: 48px;
  padding: 0.85rem 1rem;
  color: var(--color-ink);
  cursor: pointer;
  font-weight: 800;
}

.article-toc nav {
  padding: 0 1rem 1rem;
}

.article-toc ol {
  display: grid;
  gap: 0.45rem;
  margin: 0;
  padding-left: 1.25rem;
}

.article-toc li::marker {
  color: var(--color-accent);
  font-weight: 800;
}

.article-toc li.is-child {
  margin-left: 1rem;
  color: var(--color-muted);
}

.article-toc a {
  color: var(--color-ink);
  font-weight: 700;
  text-decoration: none;
}

.article-toc a:hover {
  color: var(--color-brand);
}

.article-body {
  max-width: 760px;
  padding: 3rem 0;
  font-size: 1.04rem;
}

.article-body h2 {
  margin-top: 2.2rem;
  font-size: 1.75rem;
}

.article-body h3 {
  margin-top: 1.8rem;
  font-size: 1.35rem;
}

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

.article-body a {
  color: var(--color-brand);
  font-weight: 700;
}

.article-body figure {
  margin: 1.8rem 0;
}

.article-body figure img {
  width: 100%;
  border-radius: var(--radius);
}

.article-body figcaption {
  margin-top: 0.5rem;
  color: var(--color-muted);
  font-size: 0.9rem;
  text-align: center;
}

.article-body blockquote {
  margin: 1.5rem 0;
  padding: 0.8rem 1.1rem;
  border-left: 4px solid var(--color-brand);
  background: var(--color-soft);
}

.source-note {
  padding: 0.85rem 1rem;
  border: 1px solid var(--color-line);
  border-radius: var(--radius);
  background: var(--color-soft);
  color: var(--color-muted);
  font-size: 0.93rem;
}

.contact-layout {
  display: grid;
  grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr);
  gap: 2rem;
  align-items: start;
}

.contact-intro,
.contact-form-wrap {
  min-width: 0;
}

.contact-intro h2 {
  font-size: clamp(1.7rem, 3vw, 2.45rem);
}

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

.contact-points {
  display: grid;
  gap: 0.7rem;
  margin: 1.4rem 0 0;
  padding: 0;
  list-style: none;
}

.contact-points li {
  padding: 0.85rem 1rem;
  border: 1px solid var(--color-line);
  border-radius: var(--radius);
  background: #fff;
  font-weight: 700;
}

.contact-form-wrap {
  border: 1px solid var(--color-line);
  border-radius: var(--radius);
  background: #fff;
  padding: 1.4rem;
  box-shadow: 0 12px 30px rgba(22, 38, 31, 0.08);
}

.contact-form {
  display: grid;
  gap: 1rem;
}

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

.form-field {
  display: grid;
  gap: 0.35rem;
  margin: 0;
}

.form-field label,
.privacy-check {
  font-weight: 800;
}

.form-field label span {
  display: inline-flex;
  margin-left: 0.35rem;
  padding: 0.08rem 0.35rem;
  border-radius: 999px;
  background: rgba(201, 107, 44, 0.12);
  color: var(--color-accent);
  font-size: 0.74rem;
}

.form-field input,
.form-field select,
.form-field textarea {
  width: 100%;
  min-height: 48px;
  border: 1px solid var(--color-line);
  border-radius: var(--radius);
  background: #fff;
  color: var(--color-ink);
  font: inherit;
  font-size: 16px;
  padding: 0.75rem 0.85rem;
}

.form-field textarea {
  resize: vertical;
}

.form-field input:focus,
.form-field select:focus,
.form-field textarea:focus {
  outline: 3px solid rgba(17, 106, 87, 0.16);
  border-color: var(--color-brand);
}

.privacy-check {
  display: flex;
  align-items: flex-start;
  gap: 0.65rem;
  color: var(--color-muted);
  font-size: 0.95rem;
}

.privacy-check input {
  width: 20px;
  height: 20px;
  margin-top: 0.25rem;
  accent-color: var(--color-brand);
}

.contact-submit {
  width: min(100%, 220px);
  border: 0;
  cursor: pointer;
  font: inherit;
}

.contact-form__hidden {
  position: absolute;
  left: -9999px;
}

.form-message {
  margin-bottom: 1rem;
  padding: 1rem;
  border-radius: var(--radius);
}

.form-message h3 {
  font-size: 1.15rem;
}

.form-message--success {
  border: 1px solid rgba(17, 106, 87, 0.3);
  background: rgba(17, 106, 87, 0.09);
}

.form-message--error {
  border: 1px solid rgba(201, 107, 44, 0.35);
  background: rgba(201, 107, 44, 0.1);
}

.form-message ul {
  margin-bottom: 0;
}

.article-footer {
  max-width: 760px;
  padding-bottom: 4rem;
}

.tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 1.2rem;
}

.tag-list a {
  padding: 0.35rem 0.65rem;
  border: 1px solid var(--color-line);
  border-radius: 999px;
  background: #fff;
  color: var(--color-muted);
  font-size: 0.85rem;
  text-decoration: none;
}

.search-form {
  display: flex;
  width: min(100%, 560px);
  margin: 1.2rem 0;
  border: 1px solid var(--color-line);
  border-radius: var(--radius);
  overflow: hidden;
  background: #fff;
}

.search-form input {
  min-width: 0;
  flex: 1;
  border: 0;
  padding: 0.85rem 1rem;
  font: inherit;
}

.search-form button {
  border: 0;
  padding: 0.85rem 1rem;
  background: var(--color-brand);
  color: #fff;
  font: inherit;
  font-weight: 800;
}

.site-footer {
  padding: 3rem 0 1.3rem;
  background: var(--color-ink);
  color: #fff;
}

.site-footer__inner {
  display: flex;
  justify-content: space-between;
  gap: 2rem;
}

.site-footer__brand {
  margin: 0;
  font-weight: 800;
  font-size: 1.15rem;
}

.site-footer__text,
.site-footer__copy {
  color: rgba(255, 255, 255, 0.72);
}

.site-footer__copy {
  width: min(calc(100% - 32px), var(--max-width));
  margin: 2rem auto 0;
  font-size: 0.85rem;
}

.footer-nav a {
  color: #fff;
}

.nav-links {
  display: flex;
  gap: 0.6rem;
  margin-top: 2rem;
}

.nav-links a,
.nav-links span {
  display: inline-flex;
  min-width: 42px;
  min-height: 42px;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--color-line);
  border-radius: var(--radius);
  background: #fff;
  text-decoration: none;
}

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

  .primary-nav {
    display: block;
    position: fixed;
    z-index: 9;
    top: 84px;
    left: 12px;
    right: 12px;
    max-height: calc(100dvh - 96px);
    overflow: auto;
    border: 1px solid var(--color-line);
    border-radius: var(--radius);
    background: #fff;
    box-shadow: var(--shadow);
    opacity: 0;
    pointer-events: none;
    transform: translateY(-8px);
    transition: opacity 0.18s ease, transform 0.18s ease;
  }

  .primary-nav.is-open {
    opacity: 1;
    pointer-events: auto;
    transform: translateY(0);
  }

  .admin-bar .primary-nav {
    top: 118px;
  }

  .primary-nav ul {
    width: 100%;
    padding: 0.45rem;
    flex-direction: column;
    align-items: stretch;
    gap: 0.15rem;
  }

  .primary-nav a {
    display: flex;
    width: 100%;
    min-height: 48px;
    justify-content: space-between;
    padding: 0.7rem 0.85rem;
    font-size: 1rem;
  }

  .primary-nav a::after {
    color: var(--color-muted);
    content: "›";
  }

  .hero {
    min-height: auto;
  }

  .split,
  .author-panel,
  .contact-layout,
  .cta-band,
  .site-footer__inner {
    grid-template-columns: 1fr;
    flex-direction: column;
  }

  .topic-grid,
  .post-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 620px) {
  .site-header__inner {
    min-height: 68px;
  }

  .primary-nav {
    top: 76px;
  }

  .admin-bar .primary-nav {
    top: 108px;
  }

  .site-brand__tagline {
    display: none;
  }

  .section {
    padding: 3.2rem 0;
  }

  .hero__inner {
    padding: 4rem 0;
  }

  .hero h1 {
    font-size: 2.05rem;
  }

  .author-panel {
    padding: 1.3rem;
  }

  .author-panel__image {
    width: min(72vw, 210px);
  }

  .article-header {
    padding-top: 3rem;
  }

  .article-body {
    padding-top: 2rem;
    font-size: 1rem;
  }

  .article-body h2 {
    font-size: 1.5rem;
  }

  .topic-grid,
  .post-grid {
    grid-template-columns: 1fr;
  }

  .post-grid {
    gap: 0.75rem;
  }

  .post-card__link {
    display: grid;
    grid-template-columns: 112px minmax(0, 1fr);
    min-height: 124px;
  }

  .post-card__image {
    height: 100%;
    min-height: 124px;
    aspect-ratio: auto;
  }

  .post-card__body {
    min-width: 0;
    padding: 0.8rem;
  }

  .post-card__meta {
    gap: 0.35rem;
    font-size: 0.74rem;
  }

  .post-card h3 {
    display: -webkit-box;
    margin-top: 0.35rem;
    overflow: hidden;
    font-size: 0.98rem;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
  }

  .post-card p:last-child {
    display: -webkit-box;
    overflow: hidden;
    font-size: 0.82rem;
    line-height: 1.55;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
  }

  .form-grid {
    grid-template-columns: 1fr;
  }

  .contact-form-wrap {
    padding: 1rem;
  }

  .contact-submit {
    width: 100%;
  }

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

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

  .search-form button {
    width: 100%;
  }
}
