:root {
  --bg: #fdfcfa;
  --bg-alt: #f4efe6;
  --text: #2b2622;
  --text-muted: #756c60;
  --accent: #846f4b;
  --accent-hover: #6c5a3d;
  --border: #e7e0d3;
  --max-width: 40rem;
}

* {
  box-sizing: border-box;
}

html {
  color-scheme: light;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", ui-sans-serif, system-ui, sans-serif;
  font-size: 1.0625rem;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

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

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

.wrap {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 1.5rem;
}

header.site-header {
  padding: 2.5rem 0 1.5rem;
  border-bottom: 1px solid var(--border);
}

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

.site-name {
  font-family: Georgia, "Iowan Old Style", "Palatino Linotype", serif;
  font-size: 1.35rem;
  font-weight: 600;
  color: var(--text);
  text-decoration: none;
}

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

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

nav.site-nav a:hover,
nav.site-nav a[aria-current="page"] {
  color: var(--accent);
}

main {
  padding: 3rem 0 4rem;
}

h1 {
  font-family: Georgia, "Iowan Old Style", "Palatino Linotype", serif;
  font-size: 2rem;
  line-height: 1.25;
  margin: 0 0 0.75rem;
}

h2 {
  font-family: Georgia, "Iowan Old Style", "Palatino Linotype", serif;
  font-size: 1.3rem;
  margin: 2.5rem 0 1rem;
  padding-bottom: 0.4rem;
  border-bottom: 1px solid var(--border);
}

.tagline {
  font-size: 1.15rem;
  color: var(--text-muted);
  margin: 0 0 2rem;
}

p {
  margin: 0 0 1.1rem;
}

.lede {
  font-size: 1.05rem;
}

.links-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem 1rem;
  margin: 1.75rem 0 0;
  padding: 0;
  list-style: none;
}

.links-row a {
  display: inline-block;
  padding: 0.45rem 0.9rem;
  border: 1px solid var(--border);
  border-radius: 999px;
  text-decoration: none;
  color: var(--text);
  font-size: 0.92rem;
  transition: border-color 0.15s ease, color 0.15s ease;
}

.links-row a:hover {
  border-color: var(--accent);
  color: var(--accent);
}

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

ul.services li {
  margin-bottom: 1rem;
  padding-left: 1.25rem;
  position: relative;
}

ul.services li::before {
  content: "\2013";
  position: absolute;
  left: 0;
  color: var(--accent);
}

.pub-group h3 {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
  margin: 2rem 0 0.9rem;
}

.pub-entry {
  margin: 0 0 1.15rem;
  padding-bottom: 1.15rem;
  border-bottom: 1px solid var(--border);
}

.pub-entry:last-child {
  border-bottom: none;
}

.pub-title {
  font-weight: 600;
  margin: 0 0 0.2rem;
}

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

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

.pub-meta {
  color: var(--text-muted);
  font-size: 0.92rem;
}

.pub-loading,
.pub-error {
  color: var(--text-muted);
  font-style: italic;
}

.cta {
  margin-top: 2rem;
  padding: 1.25rem 1.5rem;
  background: var(--bg-alt);
  border-radius: 0.5rem;
}

.cta p:last-child {
  margin-bottom: 1.25rem;
}

.contact-form {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.contact-form label {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-top: 0.65rem;
}

.contact-form label:first-of-type {
  margin-top: 0;
}

.contact-form input,
.contact-form textarea {
  font: inherit;
  font-size: 1rem;
  color: var(--text);
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 0.35rem;
  padding: 0.55rem 0.7rem;
  resize: vertical;
}

.contact-form input:focus,
.contact-form textarea:focus {
  outline: none;
  border-color: var(--accent);
}

.contact-form button {
  align-self: flex-start;
  margin-top: 1.1rem;
  font: inherit;
  font-size: 0.95rem;
  color: var(--bg);
  background: var(--accent);
  border: none;
  border-radius: 999px;
  padding: 0.55rem 1.3rem;
  cursor: pointer;
  transition: background 0.15s ease;
}

.contact-form button:hover {
  background: var(--accent-hover);
}

.contact-form button:disabled {
  opacity: 0.6;
  cursor: default;
}

.form-status {
  margin: 0.85rem 0 0;
  font-size: 0.9rem;
  color: var(--text-muted);
}

.form-status-success {
  color: var(--accent-hover);
}

.form-status-error {
  color: #a3392d;
}

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

footer.site-footer .links-row {
  margin-top: 0.9rem;
}

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

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

.article h1 {
  margin-top: 0.5rem;
}

.article > .pub-meta:first-child a {
  color: var(--text-muted);
  text-decoration: none;
}

.article > .pub-meta:first-child a:hover {
  color: var(--accent);
}

.article h2 {
  font-size: 1.35rem;
  margin: 2.25rem 0 1rem;
}

.article h3 {
  font-family: Georgia, "Iowan Old Style", "Palatino Linotype", serif;
  font-size: 1.1rem;
  margin: 1.75rem 0 0.75rem;
}

.article img {
  max-width: 100%;
  height: auto;
  border-radius: 0.4rem;
  margin: 0.5rem 0;
  display: block;
}

.article figure {
  margin: 1.75rem 0;
}

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

.article blockquote {
  margin: 1.5rem 0;
  padding: 0.25rem 1.25rem;
  border-left: 3px solid var(--accent);
  color: var(--text-muted);
}

.article pre {
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: 0.4rem;
  padding: 1rem;
  overflow-x: auto;
  font-size: 0.9rem;
}

.article code {
  font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  background: var(--bg-alt);
  border-radius: 0.25rem;
  padding: 0.1rem 0.35rem;
  font-size: 0.9em;
}

.article pre code {
  background: none;
  padding: 0;
}

.article ul,
.article ol {
  margin: 0 0 1.1rem;
  padding-left: 1.4rem;
}

.article li {
  margin-bottom: 0.4rem;
}

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

.article table {
  width: 100%;
  border-collapse: collapse;
  margin: 1.5rem 0;
  font-size: 0.95rem;
}

.article th,
.article td {
  border: 1px solid var(--border);
  padding: 0.5rem 0.75rem;
  text-align: left;
}

.article th {
  background: var(--bg-alt);
  font-weight: 600;
}

.article .kg-bookmark-card {
  margin: 1.75rem 0;
}

.article .kg-bookmark-container {
  display: flex;
  flex-direction: column;
  border: 1px solid var(--border);
  border-radius: 0.5rem;
  overflow: hidden;
  text-decoration: none;
  color: var(--text);
}

.article .kg-bookmark-container:hover {
  border-color: var(--accent);
}

.article .kg-bookmark-content {
  padding: 0.9rem 1.1rem;
}

.article .kg-bookmark-title {
  font-weight: 600;
  margin-bottom: 0.3rem;
}

.article .kg-bookmark-description {
  font-size: 0.9rem;
  color: var(--text-muted);
  margin-bottom: 0.6rem;
}

.article .kg-bookmark-metadata {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.82rem;
  color: var(--text-muted);
}

.article .kg-bookmark-icon {
  width: 16px;
  height: 16px;
  margin: 0;
  border-radius: 0;
}

.article .kg-bookmark-thumbnail img {
  margin: 0;
  border-radius: 0;
  max-height: 160px;
  width: 100%;
  object-fit: cover;
}

.article .kg-embed-card iframe {
  max-width: 100%;
}
