:root {
  --bg: #0f1318;
  --bg-strong: #171c24;
  --panel: #1e2430;
  --panel-strong: #252d3a;
  --ink: #e3e9f2;
  --ink-soft: #aab5c7;
  --line: rgba(203, 213, 225, 0.12);
  --accent: #61afef;
  --accent-deep: #d19a66;
  --accent-soft: rgba(97, 175, 239, 0.16);
  --shadow: 0 24px 60px rgba(0, 0, 0, 0.42);
  --radius: 22px;
  --shell: 1120px;
  --bg-radial-top: rgba(97, 175, 239, 0.13);
  --bg-radial-right: rgba(209, 154, 102, 0.09);
  --bg-top: #0c1015;
  --bg-bottom: #0a0e13;
  --surface-elevated: rgba(30, 36, 48, 0.92);
  --surface-line: rgba(203, 213, 225, 0.08);
  --header-bg: rgba(15, 19, 24, 0.86);
  --footer-bg: rgba(12, 16, 21, 0.9);
  --inline-code-bg: rgba(255, 255, 255, 0.07);
  --inline-code-ink: #e5c07b;
  --code-bg: #1f232b;
  --code-ink: #abb2bf;
  --header-button-bg: rgba(97, 175, 239, 0.18);
  --header-button-line: rgba(97, 175, 239, 0.22);
  --header-button-hover: rgba(97, 175, 239, 0.26);
  --header-icon-bg: rgba(255, 255, 255, 0.06);
  --header-icon-line: rgba(203, 213, 225, 0.12);
  --button-secondary-bg: rgba(255, 255, 255, 0.06);
  --feature-accent-start: rgba(97, 175, 239, 0.14);
  --blockquote-bg: rgba(255, 255, 255, 0.04);
  --tag-bg: rgba(97, 175, 239, 0.14);
  --tag-ink: #b9d9f7;
}

html[data-theme="light"],
html[data-theme="pink"] {
  --bg: #fff5fa;
  --bg-strong: #ffeaf4;
  --panel: #fffafd;
  --panel-strong: #ffe3ef;
  --ink: #5f2b49;
  --ink-soft: #8d5d78;
  --line: rgba(233, 106, 155, 0.3);
  --accent: #f85f9c;
  --accent-deep: #e53f84;
  --accent-soft: rgba(248, 95, 156, 0.18);
  --shadow: 0 22px 50px rgba(214, 104, 146, 0.2);
  --bg-radial-top: rgba(255, 151, 197, 0.36);
  --bg-radial-right: rgba(255, 196, 219, 0.3);
  --bg-top: #fffafc;
  --bg-bottom: #fff0f7;
  --surface-elevated: rgba(255, 250, 253, 0.96);
  --surface-line: rgba(233, 106, 155, 0.22);
  --header-bg: rgba(255, 245, 250, 0.92);
  --footer-bg: rgba(255, 237, 246, 0.96);
  --inline-code-bg: rgba(255, 203, 223, 0.46);
  --inline-code-ink: #aa2562;
  --code-bg: #fff1f7;
  --code-ink: #763553;
  --header-button-bg: rgba(248, 95, 156, 0.2);
  --header-button-line: rgba(248, 95, 156, 0.32);
  --header-button-hover: rgba(248, 95, 156, 0.3);
  --header-icon-bg: rgba(255, 203, 223, 0.32);
  --header-icon-line: rgba(233, 106, 155, 0.28);
  --button-secondary-bg: rgba(255, 220, 235, 0.62);
  --feature-accent-start: rgba(255, 151, 197, 0.32);
  --blockquote-bg: rgba(255, 220, 235, 0.54);
  --tag-bg: rgba(248, 95, 156, 0.22);
  --tag-ink: #aa2562;
}

* {
  box-sizing: border-box;
}

html {
  font-size: 17px;
}

body {
  margin: 0;
  color: var(--ink);
  background:
    radial-gradient(circle at top, var(--bg-radial-top), transparent 28rem),
    radial-gradient(circle at right top, var(--bg-radial-right), transparent 24rem),
    linear-gradient(180deg, var(--bg-top) 0%, var(--bg) 18rem, var(--bg-bottom) 100%);
  font-family: "Avenir Next", "Segoe UI", "Helvetica Neue", sans-serif;
  line-height: 1.7;
}

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

a {
  color: inherit;
  text-decoration-color: rgba(97, 175, 239, 0.4);
  text-decoration-thickness: 0.08em;
  text-underline-offset: 0.18em;
}

a:hover {
  color: #8fc6f5;
}

code,
pre {
  font-family: "IBM Plex Mono", "SFMono-Regular", Consolas, monospace;
}

code {
  padding: 0.14rem 0.4rem;
  border-radius: 0.5rem;
  background: var(--inline-code-bg);
  color: var(--inline-code-ink);
  font-size: 0.92em;
}

pre {
  overflow-x: auto;
  padding: 1.2rem 1.3rem;
  border-radius: 1rem;
  background: var(--code-bg);
  color: var(--code-ink);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.06);
}

pre code {
  padding: 0;
  background: transparent;
  color: inherit;
}

.site-shell {
  width: min(calc(100% - 2.4rem), var(--shell));
  margin: 0 auto;
}

.page-frame {
  padding-bottom: 5rem;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  backdrop-filter: blur(18px);
  background: var(--header-bg);
  border-bottom: 1px solid var(--line);
}

.header-shell {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: 4.6rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.9rem;
  text-decoration: none;
}

.brand-mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.75rem;
  height: 2.75rem;
  border-radius: 999px;
  overflow: hidden;
  background: linear-gradient(135deg, rgba(97, 175, 239, 0.22), rgba(209, 154, 102, 0.28));
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.08);
}

.brand-mark img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.brand-copy {
  display: grid;
}

.brand-name {
  font-family: "Iowan Old Style", "Palatino Linotype", "Book Antiqua", serif;
  font-size: 1.28rem;
  font-weight: 700;
}

.brand-tagline {
  color: var(--ink-soft);
  font-size: 0.88rem;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.site-nav-wrap {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.site-nav a {
  text-decoration: none;
  color: var(--ink-soft);
  font-weight: 600;
}

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

.nav-toggle {
  display: none;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0.55rem 0.95rem;
  background: var(--panel);
  color: var(--ink);
  font: inherit;
}

.header-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.7rem;
  padding: 0.65rem 1rem;
  border-radius: 999px;
  background: var(--header-button-bg);
  color: var(--ink);
  font-weight: 700;
  text-decoration: none;
  box-shadow: inset 0 0 0 1px var(--header-button-line);
}

.header-button:hover {
  background: var(--header-button-hover);
  color: #dfe9f5;
}

.header-icon-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.7rem;
  height: 2.7rem;
  border-radius: 999px;
  background: var(--header-icon-bg);
  color: var(--ink);
  text-decoration: none;
  box-shadow: inset 0 0 0 1px var(--header-icon-line);
}

.header-icon-button svg {
  width: 1.25rem;
  height: 1.25rem;
  fill: currentColor;
}

.header-icon-button:hover {
  background: rgba(97, 175, 239, 0.18);
  color: #dfe9f5;
}

.header-theme-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  min-height: 2.3rem;
  padding: 0.42rem 0.78rem;
  border: 0;
  border-radius: 999px;
  background: var(--button-secondary-bg);
  color: var(--ink);
  cursor: pointer;
  font: inherit;
  font-size: 0.9rem;
  font-weight: 700;
  box-shadow: inset 0 0 0 1px var(--header-icon-line);
  white-space: nowrap;
}

.header-theme-toggle:hover {
  background: var(--header-icon-bg);
}

.header-theme-toggle-swatch {
  width: 0.72rem;
  height: 0.72rem;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--accent), var(--panel-strong));
  box-shadow: 0 0 0 1px var(--header-icon-line);
}

.hero-band {
  padding: 4rem 0 2rem;
}

.hero-grid {
  display: grid;
  gap: 2rem;
  grid-template-columns: minmax(0, 1.2fr) minmax(18rem, 0.9fr);
  align-items: center;
}

.hero-copy,
.hero-panel,
.feature-card,
.note-panel,
.content-page,
.series-block {
  background: var(--surface-elevated);
  border: 1px solid var(--surface-line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.hero-copy {
  padding: 2.2rem;
  container-type: inline-size;
}

.hero-panel {
  overflow: hidden;
  min-height: 22rem;
  padding: 1rem;
}

.hero-panel img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-montage {
  display: grid;
  gap: 0.9rem;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  height: 100%;
  min-height: 20rem;
}

.hero-montage-item {
  margin: 0;
  overflow: hidden;
  border-radius: 1.05rem;
  background: var(--bg-strong);
  border: 1px solid rgba(203, 213, 225, 0.08);
}

.hero-montage-wide {
  grid-column: 1 / -1;
}

.eyebrow {
  margin: 0 0 0.7rem;
  color: var(--accent-deep);
  font-size: 0.84rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

h1,
h2,
h3 {
  margin: 0;
  font-family: "Iowan Old Style", "Palatino Linotype", "Book Antiqua", serif;
  line-height: 1.08;
}

h1 {
  font-size: clamp(2.6rem, 6vw, 4.8rem);
}

.hero-title {
  width: 100%;
  max-width: none;
  font-size: clamp(2.95rem, 10.8cqw, 6.4rem);
  line-height: 1.04;
}

.hero-title span {
  display: block;
  white-space: nowrap;
}

h2 {
  font-size: clamp(1.8rem, 3vw, 2.7rem);
}

h3 {
  font-size: 1.35rem;
}

.hero-summary,
.page-summary,
.footer-copy,
.feature-card p,
.note-panel p,
.photo-card-copy p {
  color: var(--ink-soft);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.9rem;
  margin-top: 1.5rem;
}

.hero-note {
  margin-top: 1.2rem;
  color: var(--ink-soft);
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.85rem 1.2rem;
  border-radius: 999px;
  font-weight: 700;
  text-decoration: none;
}

.button-primary {
  background: var(--accent);
  color: #11151b;
}

.button-secondary {
  background: var(--button-secondary-bg);
  color: var(--ink);
}

.overview-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.4rem;
  margin-top: 1rem;
}

.feature-card,
.series-block,
.note-panel,
.content-page {
  padding: 1.8rem;
}

.feature-card-accent {
  background: linear-gradient(180deg, var(--feature-accent-start), var(--surface-elevated));
}

.text-link {
  display: inline-block;
  margin-top: 1rem;
  font-weight: 700;
}

.preview-section,
.series-stack {
  margin-top: 2.3rem;
}

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

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

.recent-card,
.listing-card {
  display: grid;
  overflow: hidden;
  min-width: 0;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 1.2rem;
  container-type: inline-size;
}

.recent-card-photo .recent-card-image {
  display: block;
  aspect-ratio: 5 / 4;
  overflow: hidden;
}

.recent-card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 180ms ease;
}

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

.recent-card-copy,
.listing-card {
  padding: 1rem;
}

.recent-card-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.7rem;
  align-items: center;
  margin: 0 0 0.8rem;
  color: var(--ink-soft);
  font-size: 0.92rem;
}

.recent-card-kind {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 1.8rem;
  padding: 0.2rem 0.6rem;
  border-radius: 999px;
  background: var(--tag-bg);
  color: var(--tag-ink);
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.recent-card h3,
.listing-card h2 {
  margin-bottom: 0.7rem;
  max-width: 100%;
  overflow-wrap: anywhere;
  text-wrap: balance;
  font-size: clamp(1rem, 6cqw, 1.3rem);
  line-height: 1.2;
}

.recent-card p:last-child,
.listing-card p:last-of-type {
  color: var(--ink-soft);
}

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

.photo-card {
  display: grid;
  overflow: hidden;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 1.2rem;
}

.photo-card-image {
  display: block;
  aspect-ratio: 5 / 4;
  overflow: hidden;
}

.photo-card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 180ms ease;
}

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

.photo-card-copy {
  padding: 1rem;
}

.photo-card-series,
.photo-meta {
  display: inline-block;
  margin-top: 0.45rem;
  font-size: 0.92rem;
  color: var(--ink-soft);
}

.note-panel {
  margin-top: 2.2rem;
}

.content-page {
  margin-top: 3rem;
}

.search-shell {
  display: grid;
  gap: 1rem;
}

.search-input {
  width: 100%;
  min-height: 3.3rem;
  padding: 0.9rem 1rem;
  border: 1px solid var(--line);
  border-radius: 1rem;
  background: rgba(255, 255, 255, 0.04);
  color: var(--ink);
  font: inherit;
}

.search-input::placeholder {
  color: var(--ink-soft);
}

.search-status {
  margin: 0;
  color: var(--ink-soft);
}

.search-results {
  display: grid;
  gap: 1.2rem;
}

.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;
}

.page-header {
  margin-bottom: 2rem;
}

.rich-content > * + * {
  margin-top: 1.15rem;
}

.rich-content h2,
.rich-content h3 {
  margin-top: 2rem;
}

.rich-content figure {
  margin: 2rem 0;
}

.rich-content img {
  width: 100%;
  border-radius: 1.1rem;
  box-shadow: var(--shadow);
}

.rich-content blockquote {
  margin: 1.5rem 0;
  padding: 1rem 1.2rem;
  border-left: 3px solid var(--accent);
  background: var(--blockquote-bg);
  border-radius: 0.8rem;
  color: var(--ink-soft);
}

.rich-content ul,
.rich-content ol {
  padding-left: 1.4rem;
}

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

.split-figure {
  display: grid;
  gap: 1.2rem;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.gallery-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-top: 2rem;
  justify-content: center;
}

.gallery-item {
  margin: 0;
  overflow: hidden;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 1rem;
  flex: 1 1 22rem;
  width: min(100%, 34rem);
  max-width: 34rem;
}

.gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.gallery-item figcaption {
  padding: 0.8rem 0.95rem 1rem;
  color: var(--ink-soft);
  font-size: 0.92rem;
  text-align: center;
}

.site-footer {
  border-top: 1px solid var(--line);
  background: var(--footer-bg);
}

.footer-shell {
  display: grid;
  gap: 1.2rem;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  padding: 2rem 0 2.4rem;
}

.footer-heading {
  margin: 0 0 0.4rem;
  font-weight: 700;
}

@media (max-width: 900px) {
  html {
    font-size: 16px;
  }

  .hero-title {
    font-size: clamp(2.5rem, 10vw, 4.2rem);
    line-height: 1.02;
  }

  .hero-title span {
    white-space: normal;
  }

  .hero-grid,
  .overview-grid,
  .recent-grid,
  .listing-grid,
  .card-grid,
  .footer-shell,
  .split-figure,
  .gallery-grid {
    grid-template-columns: 1fr;
  }

  .hero-montage {
    grid-template-columns: 1fr;
  }

  .nav-toggle {
    display: inline-flex;
  }

  .site-nav-wrap {
    position: absolute;
    top: calc(100% + 0.75rem);
    right: 1.2rem;
    left: 1.2rem;
    display: none;
    flex-direction: column;
    align-items: flex-start;
    padding: 1rem;
    background: var(--panel);
    border: 1px solid var(--line);
    border-radius: 1rem;
    box-shadow: var(--shadow);
  }

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

  .site-nav-wrap.is-open {
    display: flex;
  }

  .header-button {
    width: 100%;
  }

  .header-icon-button {
    width: 100%;
  }

  .header-theme-toggle {
    width: 100%;
  }
}
