:root {
  color-scheme: dark;
  --ink: #f4ecdd;
  --muted: #b9ad99;
  --night: #0a0b0e;
  --night-soft: #12151a;
  --panel: #181b20;
  --line: #3e392f;
  --gold: #d9a85a;
  --gold-light: #f1d39a;
  --moss: #8fa78d;
  --danger-soft: #2b211c;
  --measure: 72ch;
  font-family: Georgia, "Times New Roman", serif;
  background: var(--night);
  color: var(--ink);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(circle at 12% -10%, rgba(217, 168, 90, .13), transparent 35rem),
    linear-gradient(180deg, #0d0f13, var(--night) 34rem);
  color: var(--ink);
  line-height: 1.7;
}
a { color: var(--gold-light); text-underline-offset: .18em; }
a:hover { color: #fff2cf; }
:focus-visible { outline: 3px solid #fff2cf; outline-offset: 3px; }
img { display: block; max-width: 100%; height: auto; margin: 1.5rem auto; border-radius: .35rem; }
figure { margin: 2rem 0; }
figcaption { color: var(--muted); font-size: .94rem; text-align: center; }
table { display: block; max-width: 100%; overflow-x: auto; border-collapse: collapse; }
th, td { border: 1px solid var(--line); padding: .6rem .75rem; vertical-align: top; }
pre { max-width: 100%; overflow-x: auto; padding: 1rem; background: #08090b; border: 1px solid var(--line); border-radius: .3rem; }
code, kbd, samp { font-family: ui-monospace, SFMono-Regular, Consolas, monospace; }
blockquote { margin: 1.5rem 0; padding: .2rem 1.25rem; border-left: .25rem solid var(--gold); color: #ddd2c1; }

.skip-link { position: fixed; z-index: 100; top: .75rem; left: .75rem; transform: translateY(-200%); padding: .6rem .9rem; background: #fff; color: #000; }
.skip-link:focus { transform: none; }
.site-header { border-bottom: 1px solid var(--line); background: rgba(10, 11, 14, .94); }
.site-header__inner, .site-footer > div { width: min(74rem, calc(100% - 2rem)); margin: 0 auto; }
.site-header__inner { display: flex; align-items: center; justify-content: space-between; gap: 1.5rem; min-height: 5.4rem; }
.site-header__identity { display: flex; align-items: center; gap: clamp(.8rem, 2vw, 1.4rem); min-width: 0; }
.enter-vacantide {
  position: relative;
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  gap: .5rem;
  min-height: 3rem;
  padding: .22rem .72rem .22rem .34rem;
  overflow: hidden;
  border: 1px solid #e7b95f;
  border-radius: .45rem;
  background:
    radial-gradient(circle at 20% 50%, rgba(255, 220, 143, .18), transparent 48%),
    linear-gradient(145deg, #2d2112, #110e0a 72%);
  box-shadow: inset 0 0 0 1px rgba(255, 227, 165, .08), 0 0 .9rem rgba(217, 168, 90, .2);
  color: #ffe2a3;
  font-family: system-ui, sans-serif;
  text-decoration: none;
}
.enter-vacantide:hover {
  border-color: #ffe0a0;
  box-shadow: inset 0 0 0 1px rgba(255, 238, 196, .16), 0 0 1.35rem rgba(237, 184, 83, .42);
  color: #fff3d1;
}
.enter-vacantide__icon {
  width: 2.55rem;
  height: 2.55rem;
  flex: none;
  overflow: visible;
  color: #f5c76e;
  filter: drop-shadow(0 0 .22rem rgba(255, 204, 103, .42));
}
.enter-vacantide__rays,
.enter-vacantide__frame {
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 2.4;
}
.enter-vacantide__rays { stroke-width: 1.7; }
.enter-vacantide__light { fill: rgba(255, 218, 139, .3); }
.enter-vacantide__opening { fill: #fff0b8; }
.enter-vacantide__door {
  fill: #bd7624;
  stroke: #ffe0a0;
  stroke-linejoin: round;
  stroke-width: 1.15;
  transform-box: fill-box;
  transform-origin: left center;
}
.enter-vacantide__knob { fill: #fff4cb; stroke: #724310; stroke-width: .65; }
.enter-vacantide__label { display: flex; flex-direction: column; line-height: 1; }
.enter-vacantide__verb { font-size: .61rem; font-weight: 750; letter-spacing: .18em; text-transform: uppercase; }
.enter-vacantide__name { margin-top: .22rem; font-size: .84rem; font-weight: 800; letter-spacing: .055em; }
.enter-vacantide--corner { position: absolute; z-index: 10; top: 1rem; left: 1rem; }
.wordmark { display: inline-flex; flex-direction: column; color: var(--ink); line-height: 1.05; text-decoration: none; letter-spacing: .04em; }
.wordmark__title { font-size: 1.5rem; font-weight: 700; }
.wordmark__subtitle { margin-top: .3rem; color: var(--gold); font: 700 .68rem/1.1 system-ui, sans-serif; letter-spacing: .22em; text-transform: uppercase; }
.wordmark--center { align-items: center; margin-bottom: 2rem; }
.site-nav { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: .4rem 1.2rem; margin-left: auto; font: 600 .88rem/1.3 system-ui, sans-serif; }
.site-nav a { display: inline-flex; align-items: center; min-height: 2.75rem; padding: .45rem .15rem; color: var(--ink); text-decoration: none; }
.site-nav a:hover { color: var(--gold-light); }

.page-shell { width: min(var(--measure), calc(100% - 2rem)); margin: 0 auto; padding: 2rem 0 5rem; }
.page-shell--wide { width: min(74rem, calc(100% - 2rem)); }
.breadcrumbs { margin-bottom: 1.4rem; color: var(--muted); font: .82rem/1.4 system-ui, sans-serif; }
.breadcrumbs ol { display: flex; flex-wrap: wrap; gap: .35rem; margin: 0; padding: 0; list-style: none; }
.breadcrumbs li:not(:last-child)::after { content: "/"; margin-left: .35rem; color: #746d61; }
.breadcrumbs a { display: inline-flex; align-items: center; min-height: 2rem; color: var(--muted); }
.archive-notice, .historical-note { padding: .85rem 1rem; border: 1px solid #5b4c33; border-radius: .35rem; background: rgba(75, 57, 29, .25); color: #ded2bf; font: .92rem/1.55 system-ui, sans-serif; }
.historical-note { border-color: #4d5661; background: rgba(48, 58, 68, .25); }
.article-header { padding: 2.6rem 0 1.2rem; border-bottom: 1px solid var(--line); }
.article-header h1, .index-hero h1, .transition-card h1 { margin: .15rem 0 .65rem; font-size: clamp(2.15rem, 6vw, 4.2rem); line-height: 1.04; text-wrap: balance; }
.eyebrow { margin: 0; color: var(--gold); font: 700 .72rem/1.3 system-ui, sans-serif; letter-spacing: .18em; text-transform: uppercase; }
.metadata { color: var(--muted); font: .9rem/1.5 system-ui, sans-serif; }
.prose { padding: 1.5rem 0; font-size: clamp(1.03rem, 1.7vw, 1.15rem); }
.prose h2, .prose h3, .prose h4, .prose h5, .prose h6 { margin: 2.1rem 0 .5rem; line-height: 1.18; color: #fff7e8; }
.prose h2 { font-size: 1.75rem; }
.prose h3 { font-size: 1.4rem; }
.prose p, .prose ul, .prose ol, .prose blockquote { max-width: var(--measure); }
.current-links { margin: 2.5rem 0 1rem; padding: 1.25rem; border: 1px solid var(--line); background: var(--panel); }
.current-links h2 { margin-top: 0; font-size: 1.2rem; }
.current-links ul { margin-bottom: 0; }
.collection-nav { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; margin-top: 2rem; }
.collection-nav a { display: block; min-height: 100%; padding: 1rem; border: 1px solid var(--line); background: var(--panel); text-decoration: none; }
.collection-nav a:last-child { text-align: right; }

.index-hero { max-width: 58rem; padding: 3.4rem 0 2.2rem; }
.lede { max-width: 48rem; color: #d8ccbb; font-size: 1.2rem; }
.archive-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 16rem), 1fr)); gap: 1rem; margin: 1.5rem 0 3rem; }
.archive-card { padding: 1.25rem; border: 1px solid var(--line); border-radius: .35rem; background: linear-gradient(145deg, #1b1d22, #121419); }
.archive-card h2, .archive-card h3 { margin: 0 0 .35rem; font-size: 1.25rem; }
.archive-card p { margin: .5rem 0; color: var(--muted); }
.archive-card a { display: inline-block; }
.archive-list { columns: 3 16rem; gap: 2rem; padding: 0; list-style: none; }
.archive-list li { break-inside: avoid; margin: 0 0 .65rem; }
.section-heading { margin: 3rem 0 1rem; border-bottom: 1px solid var(--line); padding-bottom: .6rem; }

.search-form { max-width: 44rem; margin: 1.5rem 0; }
.search-form label { display: block; margin-bottom: .4rem; font: 700 .9rem/1.4 system-ui, sans-serif; }
.search-form > div { display: flex; gap: .5rem; }
.search-form input { min-width: 0; flex: 1; padding: .75rem; border: 1px solid #6a6257; border-radius: .25rem; background: #090a0c; color: var(--ink); font: inherit; }
.search-form button, .button { display: inline-block; padding: .75rem 1rem; border: 1px solid var(--gold); border-radius: .25rem; background: var(--gold); color: #18120a; font: 700 .9rem/1.2 system-ui, sans-serif; text-decoration: none; cursor: pointer; }
.button--quiet { background: transparent; color: var(--gold-light); }
.search-status { color: var(--muted); }
.search-results { padding: 0; list-style: none; }
.search-results li { margin: 1rem 0; padding: 1rem; border-left: .2rem solid var(--gold); background: var(--panel); }
.search-results h2 { margin: 0 0 .35rem; font-size: 1.25rem; }
.search-results p { margin: .35rem 0; color: var(--muted); }

.site-footer { border-top: 1px solid var(--line); background: #08090b; color: var(--muted); font: .85rem/1.5 system-ui, sans-serif; }
.site-footer > div { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: 2rem 0; }
.site-footer nav { display: flex; flex-wrap: wrap; gap: .35rem 1rem; }
.site-footer nav a { display: inline-flex; align-items: center; min-height: 2.75rem; }
.transition-body { position: relative; display: grid; min-height: 100vh; place-items: center; padding: 6rem 1rem 1rem; }
.transition-card { width: min(42rem, 100%); margin: 1rem auto 3rem; padding: clamp(1.5rem, 5vw, 3.5rem); border: 1px solid var(--line); border-radius: .5rem; background: rgba(24, 27, 32, .94); box-shadow: 0 1.5rem 5rem rgba(0, 0, 0, .4); text-align: center; }
.transition-card h1 { font-size: clamp(2rem, 7vw, 3.5rem); }
.action-list { display: flex; flex-wrap: wrap; justify-content: center; gap: .75rem; margin: 2rem 0; }
.quiet { color: var(--muted); font: .85rem/1.4 system-ui, sans-serif; }

@media (max-width: 45rem) {
  .site-header__inner, .site-footer > div { align-items: flex-start; flex-direction: column; padding: 1rem 0; }
  .site-header__identity { width: 100%; flex-wrap: wrap; }
  .site-nav { justify-content: flex-start; margin-left: 0; }
  .enter-vacantide--corner { top: .75rem; left: .75rem; }
  .collection-nav { grid-template-columns: 1fr; }
  .collection-nav a:last-child { text-align: left; }
  .archive-list { columns: 1; }
  .search-form > div { flex-direction: column; }
}

@media (max-width: 25rem) {
  .site-header__identity { align-items: flex-start; flex-direction: column; }
}

@media (prefers-reduced-motion: no-preference) {
  .enter-vacantide,
  .enter-vacantide__door { transition: border-color .16s ease, box-shadow .16s ease, color .16s ease, transform .16s ease; }
  .enter-vacantide:hover { transform: translateY(-1px); }
  .enter-vacantide:hover .enter-vacantide__door,
  .enter-vacantide:focus-visible .enter-vacantide__door { transform: translateX(-.7px) scaleX(.93); }
}

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

@media (forced-colors: active) {
  .enter-vacantide {
    forced-color-adjust: none;
    border-color: LinkText;
    background: Canvas;
    box-shadow: none;
    color: LinkText;
  }
  .enter-vacantide:focus-visible { outline-color: Highlight; }
  .enter-vacantide__icon { color: LinkText; filter: none; }
  .enter-vacantide__light,
  .enter-vacantide__opening { fill: Canvas; }
  .enter-vacantide__door { fill: LinkText; stroke: LinkText; }
  .enter-vacantide__knob { fill: Canvas; stroke: LinkText; }
}
