:root {
  --ink: #1c1917;
  --muted: #57534e;
  --paper: #f6f3ee;
  --paper-2: #fffdf9;
  --line: #e7e2d9;
  --accent: #3f4f3a;
  --accent-2: #8a6a3c;
  --ad-bg: #efebe3;
  --radius: 10px;
  --max: 72rem;
  --sidebar: 18.5rem;
  --gap: 2.5rem;
  --header-offset: 0px;
  --sticky-header: 4.85rem;
  --sans: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --serif: "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, "Times New Roman", serif;
}

.admin-bar {
  --header-offset: 32px;
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-offset) + var(--sticky-header));
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 1.0625rem;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

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

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

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

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

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

.skip-link {
  position: absolute;
  left: 1rem;
  top: -4rem;
  z-index: 100;
  background: var(--ink);
  color: #fff;
  padding: 0.6rem 0.9rem;
}

.skip-link:focus {
  position: absolute;
  top: 1rem;
  clip: auto;
  width: auto;
  height: auto;
  margin: 0;
  overflow: visible;
}

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

.site-header {
  position: sticky;
  top: var(--header-offset);
  z-index: 200;
  border-bottom: 1px solid var(--line);
  background: var(--paper-2);
}

.header-inner {
  display: grid;
  grid-template-columns: minmax(0, auto) 1fr auto;
  gap: 1rem 1.5rem;
  align-items: center;
  padding: 0.85rem 0;
}

.site-branding .site-title,
.site-branding .custom-logo-link {
  margin: 0;
  font-family: var(--serif);
  font-size: 1.45rem;
  font-weight: 650;
  letter-spacing: -0.02em;
  line-height: 1.15;
}

.site-title a,
.custom-logo-link {
  color: var(--ink);
  text-decoration: none;
}

.site-description {
  margin: 0.2rem 0 0;
  color: var(--muted);
  font-size: 0.8rem;
}

.primary-nav {
  justify-self: end;
}

.primary-nav ul {
  display: flex;
  flex-wrap: wrap;
  gap: 0.15rem 1.25rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.primary-nav a {
  color: var(--ink);
  text-decoration: none;
  font-size: 0.92rem;
}

.primary-nav a:hover,
.primary-nav .current-menu-item > a {
  color: var(--accent);
}

.menu-toggle {
  display: none;
  width: 2.5rem;
  height: 2.5rem;
  border: 1px solid var(--line);
  background: var(--paper-2);
  border-radius: 8px;
  cursor: pointer;
}

.menu-toggle-bars,
.menu-toggle-bars::before,
.menu-toggle-bars::after {
  display: block;
  width: 1rem;
  height: 1.5px;
  background: var(--ink);
  margin: 0 auto;
  position: relative;
}

.menu-toggle-bars::before,
.menu-toggle-bars::after {
  content: "";
  position: absolute;
  left: 0;
}

.menu-toggle-bars::before { top: -5px; }
.menu-toggle-bars::after { top: 5px; }

.search-form {
  display: flex;
  align-items: stretch;
  gap: 0.4rem;
  width: min(100%, 18rem);
  min-width: 0;
}

.search-label {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
}

.search-field {
  flex: 1 1 auto;
  width: 100%;
  min-width: 0;
  border: 1px solid var(--line);
  background: var(--paper);
  color: var(--ink);
  border-radius: 999px;
  padding: 0.5rem 0.9rem;
  font: inherit;
  font-size: 0.88rem;
}

.search-submit {
  flex: 0 0 auto;
  white-space: nowrap;
}

.search-submit,
button {
  border: 0;
  background: var(--ink);
  color: #fff;
  border-radius: 999px;
  padding: 0.45rem 0.9rem;
  font: inherit;
  font-size: 0.85rem;
  cursor: pointer;
}

.search-submit:hover,
button:hover {
  background: var(--accent);
}

.header-ad-wrap,
.footer-ad-wrap {
  padding: 0;
  min-width: 0;
}

.site-shell {
  padding: 1.5rem 0 3.5rem;
  width: 100%;
}

.content-layout {
  display: flex;
  align-items: flex-start;
  gap: var(--gap);
  width: 100%;
}

.primary-column {
  flex: 1 1 0%;
  min-width: 0;
  max-width: 100%;
}

.primary-column > .header-ad-wrap,
.primary-column > .footer-ad-wrap {
  margin-bottom: 1.15rem;
}

.primary-column > .footer-ad-wrap {
  margin-top: 1.15rem;
  margin-bottom: 0;
}

.has-sidebar .content-layout {
  display: flex;
  align-items: flex-start;
  gap: var(--gap);
}

.has-sidebar .content-layout > .site-sidebar {
  flex: 0 0 var(--sidebar);
  width: var(--sidebar);
  max-width: 100%;
  position: sticky;
  top: calc(var(--header-offset) + var(--sticky-header) + 0.75rem);
  align-self: flex-start;
}

.breadcrumbs {
  font-size: 0.8rem;
  color: var(--muted);
  margin-bottom: 1.25rem;
}

.breadcrumbs ol {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 0.5rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.breadcrumbs li:not(:last-child)::after {
  content: "/";
  margin-left: 0.5rem;
  color: #a8a29e;
}

.site-main {
  flex: 1 1 0%;
  min-width: 0;
  width: auto;
  max-width: 100%;
}

.site-sidebar {
  flex: 0 0 var(--sidebar);
  width: var(--sidebar);
  max-width: 100%;
}

.sidebar-sticky {
  min-width: 0;
}

.no-sidebar .content-layout,
body.page-template-template-full-width .content-layout {
  display: block;
}

.no-sidebar .primary-column {
  width: 100%;
  max-width: 100%;
  flex: 1 1 100%;
}

.home-title,
.article-title,
.archive-title,
.error-404 h1,
.no-results h1,
.entry-content,
.home-lede {
  overflow-wrap: break-word;
}

.home-intro,
.archive-header,
.article-header {
  margin-bottom: 1.5rem;
}

.eyebrow {
  margin: 0 0 0.4rem;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: 0.72rem;
  color: var(--accent-2);
}

.home-title,
.article-title,
.archive-title,
.error-404 h1,
.no-results h1 {
  margin: 0 0 0.6rem;
  font-family: var(--serif);
  font-weight: 650;
  letter-spacing: -0.03em;
  line-height: 1.18;
}

.home-title { font-size: clamp(1.75rem, 3vw, 2.5rem); max-width: 40rem; }
.article-title { font-size: clamp(1.85rem, 3.4vw, 2.6rem); }
.archive-title { font-size: clamp(1.7rem, 3vw, 2.2rem); }

.archive-intro,
.home-lede {
  color: var(--muted);
  max-width: 42rem;
}

.home-tagline {
  margin: 0 0 1rem;
  color: var(--muted);
  font-size: 1.05rem;
  max-width: 42rem;
}

.entry-meta {
  margin: 0;
  color: var(--muted);
  font-size: 0.88rem;
}

.entry-meta .updated { display: none; }

.section-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 1rem;
  margin: 2rem 0 1rem;
  border-top: 1px solid var(--line);
  padding-top: 1.25rem;
}

.site-main > .home-info:first-child .section-head,
.site-main > .home-latest:first-child .section-head {
  margin-top: 0.25rem;
  padding-top: 0;
  border-top: 0;
}

.home-info-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
}

.info-card {
  background: var(--paper-2);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.05rem 1.15rem 1.2rem;
}

.info-card .card-title {
  font-size: 1.15rem;
}

.info-card-cta {
  margin: 0.75rem 0 0;
  font-size: 0.88rem;
}

.section-head h2 {
  margin: 0;
  font-family: var(--serif);
  font-size: 1.35rem;
}

.section-link {
  font-size: 0.88rem;
}

.post-list {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.post-card {
  display: block;
  background: var(--paper-2);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  padding: 0;
}

.post-card.has-post-thumbnail:not(.is-featured) {
  display: grid;
  grid-template-columns: 8.5rem minmax(0, 1fr);
  align-items: stretch;
}

.post-card.is-featured .card-thumb {
  display: block;
  margin: 0;
  overflow: hidden;
  border-radius: 0;
  aspect-ratio: 16 / 9;
  background: var(--ad-bg);
}

.card-thumb {
  display: block;
  overflow: hidden;
  border-radius: 0;
  background: var(--ad-bg);
  min-height: 100%;
  aspect-ratio: 1 / 1;
}

.card-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.card-body {
  padding: 1.05rem 1.15rem 1.2rem;
}

.card-kicker {
  margin: 0 0 0.3rem;
  font-family: var(--sans);
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.card-kicker a {
  color: var(--accent-2);
  text-decoration: none;
}

.card-title {
  margin: 0;
  font-family: var(--serif);
  font-size: 1.2rem;
  line-height: 1.28;
}

.post-card.is-featured .card-title {
  font-size: clamp(1.45rem, 2.5vw, 1.95rem);
}

.card-title a {
  color: var(--ink);
  text-decoration: none;
}

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

.card-meta {
  margin: 0.4rem 0 0;
  color: var(--muted);
  font-family: var(--sans);
  font-size: 0.84rem;
}

.card-excerpt {
  margin: 0.45rem 0 0;
  color: var(--muted);
  font-family: var(--sans);
  font-size: 0.95rem;
}

.article-hero {
  margin: 0 0 1.5rem;
}

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

.entry-content {
  font-family: var(--serif);
  font-size: 1.125rem;
  max-width: 42rem;
}

.entry-content > * + * { margin-top: 1.05em; }

.entry-content h2,
.entry-content h3 {
  font-family: var(--serif);
  line-height: 1.25;
  margin-top: 1.6em;
}

.entry-content h2 { font-size: 1.45rem; }
.entry-content h3 { font-size: 1.2rem; }

.entry-content ul,
.entry-content ol { padding-left: 1.2rem; }

.entry-content blockquote {
  margin: 1.4rem 0;
  padding: 0 0 0 1rem;
  border-left: 3px solid var(--accent);
  color: var(--muted);
}

.article-footer,
.post-nav {
  margin-top: 2rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--line);
}

.comments-area {
  margin-top: 2.5rem;
  padding: 1.4rem 1.35rem 1.5rem;
  background: var(--paper-2);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.comments-header {
  margin-bottom: 1.15rem;
}

.comments-title,
.comment-reply-title {
  margin: 0 0 0.85rem;
  font-family: var(--serif);
  font-size: 1.25rem;
}

.comment-list,
.comment-list .children {
  list-style: none;
  margin: 0;
  padding: 0;
}

.comment-list .children {
  margin: 0.85rem 0 0 1.15rem;
  padding-left: 0.9rem;
  border-left: 2px solid var(--line);
}

.comment-item + .comment-item {
  margin-top: 0.9rem;
}

.comment-card {
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr);
  gap: 0.85rem;
}

.comment-avatar img {
  display: block;
  width: 44px;
  height: 44px;
  border-radius: 50%;
}

.comment-head {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 0.75rem;
  align-items: baseline;
  margin-bottom: 0.35rem;
}

.comment-author,
.comment-author a {
  color: var(--ink);
  font-weight: 650;
  text-decoration: none;
}

.comment-date {
  color: var(--muted);
  font-size: 0.82rem;
  text-decoration: none;
}

.comment-text {
  font-family: var(--serif);
  font-size: 1.02rem;
}

.comment-text p {
  margin: 0 0 0.7em;
}

.comment-text p:last-child {
  margin-bottom: 0;
}

.comment-awaiting {
  margin: 0 0 0.5rem;
  color: var(--accent-2);
  font-size: 0.88rem;
}

.comment-actions {
  margin-top: 0.55rem;
  display: flex;
  gap: 0.85rem;
  font-size: 0.85rem;
}

.comment-actions a {
  text-decoration: none;
}

.no-comments {
  margin: 0 0 1rem;
  color: var(--muted);
}

.comment-respond {
  margin-top: 1.4rem;
  padding-top: 1.2rem;
  border-top: 1px solid var(--line);
}

.comment-notes,
.logged-in-as {
  margin: 0 0 0.9rem;
  color: var(--muted);
  font-size: 0.88rem;
}

.comment-form p {
  margin: 0 0 0.85rem;
}

.comment-form label {
  display: block;
  margin-bottom: 0.3rem;
  font-size: 0.88rem;
}

.comment-form .required {
  color: var(--accent-2);
}

.comment-form input[type="text"],
.comment-form input[type="email"],
.comment-form textarea {
  width: 100%;
  max-width: 100%;
  border: 1px solid var(--line);
  background: var(--paper);
  color: var(--ink);
  border-radius: 8px;
  padding: 0.6rem 0.75rem;
  font: inherit;
}

.comment-form textarea {
  min-height: 8rem;
  resize: vertical;
}

.comment-submit {
  border: 0;
  background: var(--ink);
  color: #fff;
  border-radius: 999px;
  padding: 0.55rem 1.1rem;
  font: inherit;
  font-size: 0.9rem;
  cursor: pointer;
}

.comment-submit:hover {
  background: var(--accent);
}

.cancel-comment-reply {
  margin-left: 0.6rem;
  font-weight: 400;
  font-size: 0.85rem;
}

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

.nav-previous span,
.nav-next span {
  display: block;
  font-size: 0.75rem;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.pagination {
  margin-top: 2rem;
}

.page-numbers {
  display: inline-block;
  margin-right: 0.35rem;
  padding: 0.3rem 0.55rem;
  text-decoration: none;
  color: var(--ink);
}

.page-numbers.current {
  font-weight: 700;
}

.widget {
  margin-bottom: 1.5rem;
  padding: 1rem 1.05rem;
  background: var(--paper-2);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.widget-topics {
  padding: 0;
  background: transparent;
  border: 0;
  border-radius: 0;
}

.widget-title {
  margin: 0 0 0.7rem;
  font-size: 0.78rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
}

.widget ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

.widget li + li { margin-top: 0.4rem; }

.topic-list {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.topic-list li + li { margin-top: 0; }

.topic-card a {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.75rem;
  background: var(--paper-2);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 0.55rem 0.75rem;
  color: var(--ink);
  text-decoration: none;
}

.topic-card a:hover {
  border-color: #d4cdc2;
}

.topic-name {
  margin: 0;
  font-family: var(--serif);
  font-size: 1rem;
  font-weight: 650;
  line-height: 1.25;
}

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

.topic-meta,
.topic-count {
  margin: 0;
  flex: 0 0 auto;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
  font-size: 0.78rem;
}

.topic-empty {
  margin: 0;
  color: var(--muted);
  font-size: 0.92rem;
}

.contact-info {
  display: grid;
  gap: 1.1rem;
  margin: 2rem 0 0;
  padding-top: 1.4rem;
  border-top: 1px solid var(--line);
  max-width: 32rem;
}

.contact-info dt {
  margin: 0;
  font-family: var(--sans);
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
}

.contact-info dd {
  margin: 0.25rem 0 0;
  font-size: 1.05rem;
}

.ad-unit,
.ad-slot,
.bc-incontent-ad {
  margin: 0.65rem 0;
  width: 100%;
  max-width: 100%;
  line-height: 0;
  background: transparent;
}

.ad-label {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
}

.ad-image-link {
  display: block;
  line-height: 0;
}

.ad-unit img,
.ad-html img {
  display: block;
  width: 100%;
  height: auto;
  margin: 0;
  border: 0;
  vertical-align: top;
}

.ad-html {
  line-height: normal;
}

.ad-placeholder-box {
  min-height: 90px;
  width: 100%;
  display: grid;
  place-items: center;
  padding: 1rem;
  text-align: center;
  color: var(--muted);
  font-size: 0.85rem;
  font-family: var(--sans);
  background: repeating-linear-gradient(
    -45deg,
    var(--ad-bg),
    var(--ad-bg) 8px,
    #e8e2d6 8px,
    #e8e2d6 16px
  );
  border: 1px dashed #c4b8a5;
  border-radius: var(--radius);
}

.ad-slot-sidebar .ad-placeholder-box,
.ad-slot-sidebar-bottom .ad-placeholder-box {
  min-height: 250px;
}

.entry-content .ad-unit {
  font-family: var(--sans);
}

.site-footer {
  border-top: 1px solid var(--line);
  background: var(--paper-2);
  padding: 2rem 0 calc(1.5rem + env(safe-area-inset-bottom, 0px));
  font-size: 0.9rem;
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 1.5rem;
  flex-wrap: wrap;
}

.footer-name {
  margin: 0;
  font-family: var(--serif);
  font-size: 1.15rem;
}

.footer-tag,
.footer-copy {
  color: var(--muted);
}

.footer-copy {
  margin-top: 1.25rem;
  padding-top: 1.1rem;
  border-top: 1px solid var(--line);
}

.footer-copy p {
  margin: 0;
}

.footer-copy .footer-extra {
  margin-top: 0.35rem;
}

.footer-nav ul {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1.1rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.footer-nav a {
  color: var(--ink);
  text-decoration: none;
}

@media screen and (max-width: 782px) {
  .admin-bar {
    --header-offset: 46px;
  }
}

@media (max-width: 900px) {
  .content-layout,
  .has-sidebar .content-layout {
    display: block;
  }

  .has-sidebar .content-layout > .site-sidebar,
  .site-sidebar {
    position: static;
    width: 100%;
    max-height: none;
    overflow: visible;
    margin-top: 2rem;
  }

  .home-info-grid {
    grid-template-columns: 1fr;
  }

  .post-card.has-post-thumbnail:not(.is-featured) {
    grid-template-columns: 1fr;
  }

  .post-card.has-post-thumbnail:not(.is-featured) .card-thumb {
    aspect-ratio: 16 / 9;
    min-height: 0;
  }

  .header-inner {
    grid-template-columns: 2.75rem minmax(0, 1fr) 2.75rem;
    gap: 0.75rem 0.5rem;
    padding: 0.7rem 0;
  }

  .menu-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    grid-column: 1;
    grid-row: 1;
    justify-self: start;
  }

  .site-branding {
    grid-column: 2;
    grid-row: 1;
    text-align: center;
    justify-self: center;
    max-width: 100%;
  }

  .site-branding .site-title,
  .site-branding .custom-logo-link {
    font-size: 1.2rem;
  }

  .site-description {
    display: none;
  }

  .primary-nav {
    display: none;
    grid-column: 1 / -1;
    grid-row: 3;
    justify-self: stretch;
    padding: 0.35rem 0 0.15rem;
  }

  .primary-nav.is-open { display: block; }

  .primary-nav ul {
    flex-direction: column;
    gap: 0;
  }

  .primary-nav a {
    display: block;
    padding: 0.7rem 0.15rem;
    border-bottom: 1px solid var(--line);
  }

  .header-inner .search-form {
    grid-column: 1 / -1;
    grid-row: 2;
    width: 100%;
  }

  .search-field,
  .search-submit {
    min-height: 2.6rem;
  }

  .footer-inner,
  .footer-copy {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }

  .footer-nav ul {
    justify-content: center;
  }
}

@media (max-width: 480px) {
  .container {
    width: min(100% - 1.25rem, var(--max));
  }

  .search-form {
    flex-wrap: wrap;
  }

  .search-submit {
    width: 100%;
    border-radius: 999px;
  }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}

/* Keep WordPress global/layout styles from collapsing the classic layout */
body .content-layout,
body .site-shell,
body .site-shell > .container {
  max-width: none;
}

body .site-main,
body main.site-main {
  display: block;
  max-width: 100%;
}

body .content-layout > .site-main,
body .content-layout > .site-sidebar,
body .content-layout > .primary-column,
body .primary-column > .header-ad-wrap,
body .primary-column > .footer-ad-wrap {
  margin-left: 0;
  margin-right: 0;
}
