@import url('https://fonts.googleapis.com/css2?family=Cinzel:wght@500;600;700&family=EB+Garamond:ital,wght@0,400;0,500;1,400&display=swap');

:root {
  --bg: #0b0a14;
  --panel: #16132a;
  --panel-line: #2a2440;
  --gold: #c9a46b;
  --gold-dim: #8f7548;
  --amethyst: #6b4e8e;
  --ink: #e9e3d3;
  --ink-dim: #a79ecf;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: 'EB Garamond', Georgia, serif;
  font-size: 19px;
  line-height: 1.7;
}

a { color: var(--gold); text-decoration: none; }
a:hover { color: var(--ink); text-decoration: underline; }

h1, h2, h3, .brand {
  font-family: 'Cinzel', serif;
  letter-spacing: 0.03em;
  font-weight: 600;
  color: var(--ink);
}

.gold-frame {
  max-width: 940px;
  margin: 18px auto 0;
  padding: 14px;
  border: 1px solid var(--gold-dim);
  border-radius: 6px;
  position: relative;
  background: linear-gradient(180deg, rgba(201,164,107,0.05), transparent 40%);
}

.gold-frame::before,
.gold-frame::after {
  content: "";
  position: absolute;
  width: 22px;
  height: 22px;
  border: 1px solid var(--gold);
  opacity: 0.9;
}

.gold-frame::before {
  top: -1px;
  left: -1px;
  border-right: none;
  border-bottom: none;
}

.gold-frame::after {
  top: -1px;
  right: -1px;
  border-left: none;
  border-bottom: none;
}

.site-header {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  gap: 8px;
  max-width: 900px;
  margin: 0 auto;
  padding: 14px 24px 10px;
}

.site-header-top {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  width: 100%;
}

.site-header .brand {
  font-size: 1.3rem;
  color: var(--gold);
}

.site-header nav {
  display: flex;
  align-items: center;
  justify-content: center;
}

.site-header nav a {
  color: var(--ink-dim);
  margin: 0 10px;
  font-family: 'Cinzel', serif;
  font-size: 0.85rem;
  letter-spacing: 0.05em;
}

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

/* Hamburger toggle: hidden on desktop, shown only on mobile (see media query) */
.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 32px;
  height: 32px;
  padding: 0;
  background: transparent;
  border: 1px solid var(--gold-dim);
  border-radius: 4px;
  cursor: pointer;
}

.nav-toggle-bar {
  display: block;
  width: 16px;
  height: 2px;
  margin: 0 auto;
  background: var(--gold);
  transition: transform 0.25s ease, opacity 0.2s ease;
}

.nav-toggle.is-active .nav-toggle-bar:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}
.nav-toggle.is-active .nav-toggle-bar:nth-child(2) {
  opacity: 0;
}
.nav-toggle.is-active .nav-toggle-bar:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

.hero-wrap {
  position: relative;
  max-width: 900px;
  margin: 6px auto 0;
  border-radius: 4px;
  overflow: hidden;
  border: 1px solid var(--panel-line);
}

.hero-bg {
  display: block;
  width: 100%;
  height: auto;
}

.hero-text {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 20px;
}

.hero-eyebrow {
  font-family: 'Cinzel', serif;
  font-size: 0.78rem;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 10px;
}

.hero-text h1 {
  font-size: 2.1rem;
  margin: 0;
  max-width: 640px;
  text-shadow: 0 2px 18px rgba(0,0,0,0.65);
}

.hero-lede {
  max-width: 620px;
  margin: 24px auto 0;
  text-align: center;
  color: var(--ink-dim);
  font-style: italic;
}

.moon-divider {
  display: block;
  margin: 36px auto;
  opacity: 0.85;
}

main {
  max-width: 900px;
  margin: 0 auto;
  padding: 40px 24px 60px;
}

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

.article-list li {
  border-top: 1px solid var(--panel-line);
  padding: 22px 0;
}

.article-list li:last-child { border-bottom: 1px solid var(--panel-line); }

.article-list a {
  font-family: 'Cinzel', serif;
  font-size: 1.05rem;
  color: var(--ink);
}

.article-list a:hover { color: var(--gold); }

.article-list .excerpt {
  margin-top: 8px;
  color: var(--ink-dim);
  font-size: 0.95rem;
}

.breadcrumb {
  font-size: 0.85rem;
  color: var(--ink-dim);
  margin: 24px 0;
}

.toc {
  background: var(--panel);
  border: 1px solid var(--gold-dim);
  border-radius: 4px;
  padding: 22px 28px;
  margin: 0 0 30px;
}

.toc-title {
  font-family: 'Cinzel', serif;
  color: var(--gold);
  font-size: 0.95rem;
  letter-spacing: 0.05em;
  margin: 0 0 12px;
  text-transform: uppercase;
}

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

.toc li {
  margin: 0 0 8px;
  line-height: 1.4;
}

.toc li.toc-sub {
  margin-left: 20px;
  font-size: 0.95rem;
}

.toc li::before {
  content: "\2022";
  color: var(--gold-dim);
  margin-right: 8px;
}

.toc a {
  color: var(--ink);
}

.toc a:hover {
  color: var(--gold);
  text-decoration: underline;
}

article.post-content {
  background: var(--panel);
  border: 1px solid var(--panel-line);
  border-radius: 4px;
  padding: 36px 40px;
  margin-top: -10px;
}

article.post-content p { margin: 0 0 1.2em; }
article.post-content h2, article.post-content h3 {
  color: var(--gold);
  margin-top: 1.6em;
}
article.post-content img { max-width: 100%; height: auto; border-radius: 3px; }
article.post-content blockquote {
  border-left: 3px solid var(--gold-dim);
  margin: 1.5em 0;
  padding: 0.2em 1.2em;
  color: var(--ink-dim);
  font-style: italic;
}
article.post-content a { text-decoration: underline; }

.wave-sep {
  display: flex;
  justify-content: center;
  margin: 18px 0;
}

.wave-divider {
  display: block;
}

footer {
  max-width: 900px;
  margin: 20px auto 0;
  padding: 30px 24px 50px;
  text-align: center;
  color: var(--ink-dim);
  font-size: 0.85rem;
  border-top: 1px solid var(--panel-line);
}

footer p { margin: 0 0 10px; }

.footer-nav a {
  color: var(--ink-dim);
  font-family: 'Cinzel', serif;
  font-size: 0.78rem;
  letter-spacing: 0.03em;
}

.footer-nav a:hover { color: var(--gold); }

/* Mobile accordion menu */
@media (max-width: 640px) {
  .site-header-top {
    justify-content: space-between;
  }

  .nav-toggle {
    display: flex;
  }

  .site-header nav {
    flex-direction: column;
    align-items: stretch;
    width: 100%;
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    transition: max-height 0.3s ease, opacity 0.25s ease;
  }

  .site-header nav.nav-open {
    max-height: 240px;
    opacity: 1;
    margin-top: 6px;
  }

  .site-header nav a {
    margin: 0;
    padding: 12px 0;
    border-top: 1px solid var(--panel-line);
    width: 100%;
  }

  .site-header nav a:first-child {
    border-top: none;
  }
}

@media (max-width: 480px) {
  body { font-size: 17px; }
  .hero-text h1 { font-size: 1.5rem; }
  article.post-content { padding: 24px 20px; }
  .site-header { flex-direction: column; gap: 10px; text-align: center; }
}
