
:root {
  --ink: #111;
  --muted: #666;
  --line: #d8d8d8;
  --paper: #fff;
  --accent: #7e22ce;
}
html, body {
  background: var(--paper) !important;
  color: var(--ink) !important;
  font-family: Georgia, "Times New Roman", serif;
}
body {
  line-height: 1.7;
  min-height: 100vh;
  position: relative;
  overflow-x: hidden;
}
a {
  color: var(--ink);
  text-decoration-color: var(--ink);
  text-underline-offset: 0.16em;
}
a:hover { color: #000; }
.site-header {
  border-bottom: 1px solid var(--line);
  background: #fff !important;
  position: sticky;
  top: 0;
  z-index: 1020;
}
.site-title {
  font-size: clamp(2rem, 4vw, 3.5rem);
  letter-spacing: -0.03em;
  line-height: 1;
  margin: 0;
}
.site-tagline {
  color: var(--muted);
  font-size: 1.05rem;
  max-width: 42rem;
  margin: 1rem 0 0;
}
.nav-link {
  color: var(--ink);
  padding-left: 0;
  padding-right: 1.5rem;
}
.nav-link:hover, .nav-link:focus, .nav-link.active {
  color: #000;
  text-decoration: underline;
  text-underline-offset: 0.2em;
}
.section-label, .essay-meta, .writing-meta, .year-marker {
  font-family: Arial, Helvetica, sans-serif;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.78rem;
  color: var(--muted);
  margin-bottom: 1rem;
}
.hero-card, .writing-card, .essay-shell, .about-shell {
  border: 1px solid var(--line);
  background: #fff !important;
}
.hero-card { padding: 2rem; }
.writing-card { padding: 1.5rem; height: 100%; }
.writing-meta, .essay-meta, .about-copy, .footer-copy {
  color: var(--muted);
  font-family: Arial, Helvetica, sans-serif;
  font-size: 0.95rem;
  line-height: 1.6;
}
.feature-title, .card-title, .essay-title, .about-title {
  line-height: 1.15;
  letter-spacing: -0.02em;
}
.feature-title {
  font-size: clamp(2rem, 4vw, 3rem);
  max-width: 14ch;
}
.feature-deck, .card-deck, .essay-deck {
  font-size: 1.05rem;
  color: var(--muted);
  max-width: 44rem;
}
.essay-shell, .about-shell { padding: 2rem; }
.essay-shell { max-width: 52rem; margin: 0 auto; }
.essay-body p { margin-bottom: 1.35rem; font-size: 1.1rem; }
.essay-break {
  text-align: center;
  margin: 2rem 0;
  color: var(--muted);
  font-size: 1.25rem;
}
.chapter-title {
  font-size: 1.6rem;
  line-height: 1.12;
  letter-spacing: -0.02em;
  margin: 2.2rem 0 1rem;
}
.chapter-title:first-child { margin-top: 0; }
.year-block { margin: 1.5rem 0 1.35rem; }
.year-marker { display: block; margin-bottom: 0.35rem; }
.coordinate-link {
  font-family: Arial, Helvetica, sans-serif;
  font-size: 0.95rem;
  color: var(--muted);
}
.coordinate-link:hover { color: var(--ink); }
.writing-list-item {
  border-top: 1px solid var(--line);
  padding: 1.25rem 0;
}
.writing-list-item:first-child {
  border-top: 0;
  padding-top: 0;
}
.about-shell { max-width: 44rem; }
.site-footer { border-top: 1px solid var(--line); }
.page-section { scroll-margin-top: 6rem; }
@media (max-width: 767.98px) {
  body {
    background-size: min(24vw, 110px);
    background-position: right 0.9rem bottom 0.9rem;
  }
  .hero-card, .essay-shell, .about-shell, .writing-card { padding: 1.25rem; }
  .essay-body p { font-size: 1.02rem; }
}


.footer-links a { color: var(--muted); text-decoration: none; }
.footer-links a:hover { color: var(--ink); text-decoration: underline; }
.small-muted { color: var(--muted); }
.legal-shell { max-width: 48rem; }
.legal-shell p, .legal-shell li { font-size: 1.05rem; }
.notfound-shell { max-width: 42rem; }



body::after {
  content: "";
  position: fixed;
  right: 1.5rem;
  bottom: 1.25rem;
  width: min(24vw, 260px);
  aspect-ratio: 180 / 320;
  background: url("../img/semicolon-bg.svg") no-repeat center / contain;
  opacity: 0.8;
  pointer-events: none;
  z-index: 0;
  filter: saturate(1.05);
}

.site-header, main, .site-footer {
  position: relative;
  z-index: 1;
}

@media (min-width: 768px) {
  .py-md-6 {
    padding-top: 4.5rem !important;
    padding-bottom: 4.5rem !important;
  }
}

.nav-button {
  border: 0;
  background: transparent;
  font: inherit;
  text-decoration-color: currentColor;
}

.admin-shell, .app-shell {
  max-width: 72rem;
}

.admin-table-wrap {
  border: 1px solid var(--line);
  background: #fff;
  overflow-x: auto;
}

.admin-filter {
  border: 1px solid var(--line);
  background: #fff;
  padding: 1rem;
  font-family: Arial, Helvetica, sans-serif;
}

.admin-table {
  font-family: Arial, Helvetica, sans-serif;
  font-size: 0.95rem;
}

.admin-table th {
  color: var(--muted);
  font-size: 0.78rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-weight: 400;
}

.admin-form {
  border: 1px solid var(--line);
  background: #fff;
  padding: 1.5rem;
  font-family: Arial, Helvetica, sans-serif;
}

.admin-action, .admin-button {
  border: 1px solid var(--ink);
  background: var(--ink);
  color: #fff;
  display: inline-flex;
  align-items: center;
  min-height: 2.6rem;
  padding: 0.45rem 0.85rem;
  text-decoration: none;
  font-family: Arial, Helvetica, sans-serif;
  font-size: 0.95rem;
}

.admin-action:hover, .admin-button:hover {
  background: #000;
  color: #fff;
}

.link-button {
  border: 0;
  background: transparent;
  color: var(--ink);
  padding: 0;
  text-decoration: underline;
  text-underline-offset: 0.16em;
}

.status-pill {
  border: 1px solid var(--line);
  display: inline-flex;
  align-items: center;
  min-height: 1.7rem;
  padding: 0.15rem 0.5rem;
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.status-published {
  border-color: #7e22ce;
  color: #5b1599;
}

.status-draft {
  color: var(--muted);
}

.status-archived {
  border-color: #aaa;
  color: #444;
  background: #f7f7f7;
}

.cms-body-textarea {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.9rem;
  line-height: 1.5;
}

.app-placeholder {
  min-height: 9rem;
}

.app-nav {
  border: 1px solid var(--line);
  background: #fff;
  padding: 1rem;
  font-family: Arial, Helvetica, sans-serif;
}

.app-nav-label, .app-kicker {
  color: var(--muted);
  font-size: 0.78rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.app-nav-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem 1rem;
  margin-top: 0.65rem;
}

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

.app-nav-links a:hover, .app-nav-links a.active {
  text-decoration: underline;
  text-underline-offset: 0.18em;
}

.app-dashboard-grid {
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(auto-fit, minmax(13rem, 1fr));
}

.app-card {
  border: 1px solid var(--line);
  background: #fff;
  color: var(--ink);
  display: flex;
  flex-direction: column;
  min-height: 11rem;
  padding: 1.25rem;
  text-decoration: none;
}

.app-card:hover {
  color: var(--ink);
  border-color: var(--accent);
}

.app-count {
  display: block;
  font-size: 2.5rem;
  font-weight: 400;
  line-height: 1;
  margin: 1.4rem 0 0.7rem;
}

.app-empty {
  border: 1px solid var(--line);
  background: #fff;
  padding: 1.5rem;
  max-width: 46rem;
}

.app-empty h2 {
  font-size: 1.45rem;
  margin-bottom: 0.45rem;
}

.app-empty p {
  color: var(--muted);
  margin-bottom: 0;
}

.app-list {
  border: 1px solid var(--line);
  background: #fff;
}

.app-list-item {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 1.5rem;
  padding: 1.25rem;
  border-top: 1px solid var(--line);
}

.app-list-item:first-child {
  border-top: 0;
}

.app-list-item p {
  color: var(--muted);
  margin-bottom: 0;
  white-space: pre-line;
}

.app-list-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.65rem;
  justify-content: flex-end;
  min-width: 14rem;
  font-family: Arial, Helvetica, sans-serif;
}

.app-list-actions form {
  display: inline-flex;
}

.app-form {
  max-width: 56rem;
}

.status-planned {
  color: var(--muted);
}

.status-active {
  border-color: var(--accent);
  color: #5b1599;
}

.status-completed {
  border-color: #555;
  color: #222;
}

@media (max-width: 767.98px) {
  body::after {
    right: 0.75rem;
    bottom: 0.75rem;
    width: min(22vw, 120px);
    opacity: 0.72;
  }

  .app-list-item {
    display: block;
  }

  .app-list-actions {
    justify-content: flex-start;
    margin-top: 1rem;
    min-width: 0;
  }

  .app-list-item > a, .app-list-item > .status-pill {
    margin-top: 1rem;
  }
}
