/* HESTIA — the Lady's design system.
   Palette: candlelight on oxblood and ink; gold where the eye should rest.
   Type: Cormorant Garamond for display, EB Garamond for the page.
   Everything self-hosted; the house makes no third-party requests. */

:root {
  --ink: #0c0a09;
  --panel: #16100e;
  --panel-2: #1b1310;
  --wine: #4a1524;
  --wine-deep: #2d0d17;
  --gold: #c9a24b;
  --gold-dim: #8a7136;
  --gold-faint: #5c4c26;
  --bone: #eae2d2;
  --muted: #a39885;
  --steel: #8b929c;
  --line: #2c211c;
  --serif-display: "Cormorant Garamond", Georgia, "Times New Roman", serif;
  --serif-body: "EB Garamond", Georgia, "Times New Roman", serif;
}

* { box-sizing: border-box; }

html { color-scheme: dark; }

body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(120rem 60rem at 50% -20%, #241118 0%, transparent 60%),
    radial-gradient(80rem 50rem at 85% 110%, #1c0f14 0%, transparent 55%),
    var(--ink);
  color: var(--bone);
  font-family: var(--serif-body);
  font-size: 1.15rem;
  line-height: 1.75;
  -webkit-font-smoothing: antialiased;
}

main {
  max-width: 44rem;
  margin: 0 auto;
  padding: 3.5rem 1.4rem 4rem;
}

/* ---------- sigil ---------- */
.sigil {
  display: block;
  width: 92px;
  height: 92px;
  margin: 0 auto 1.1rem;
  animation: glow 7s ease-in-out infinite;
}

@keyframes glow {
  0%, 100% { filter: drop-shadow(0 0 6px rgba(201, 162, 75, 0.25)); opacity: 0.92; }
  50%      { filter: drop-shadow(0 0 18px rgba(201, 162, 75, 0.55)); opacity: 1; }
}

@media (prefers-reduced-motion: reduce) {
  .sigil { animation: none; }
}

/* ---------- typography ---------- */
h1, h2, h3 { font-family: var(--serif-display); font-weight: 600; color: var(--bone); }

h1 {
  font-size: clamp(2.5rem, 7vw, 3.6rem);
  text-align: center;
  letter-spacing: 0.22em;
  margin: 0 0 0.4rem;
}

.subtitle {
  text-align: center;
  font-style: italic;
  color: var(--gold);
  font-size: 1.25rem;
  margin: 0 0 2.6rem;
  letter-spacing: 0.04em;
}

h2 {
  font-size: 1.7rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold);
  text-align: center;
  margin: 2.8rem 0 1.4rem;
}

h2::after {
  content: "";
  display: block;
  width: 5.5rem;
  height: 1px;
  margin: 0.8rem auto 0;
  background: linear-gradient(90deg, transparent, var(--gold-dim), transparent);
}

p { margin: 0 0 1.2rem; }

a { color: var(--gold); text-decoration: none; border-bottom: 1px solid var(--gold-faint); transition: color .25s, border-color .25s; }
a:hover { color: #e8c66e; border-color: var(--gold); }

.smallcaps {
  font-variant: small-caps;
  letter-spacing: 0.18em;
  color: var(--muted);
}

/* ---------- ornament ---------- */
.ornament {
  text-align: center;
  color: var(--gold-dim);
  letter-spacing: 0.9em;
  margin: 2.2rem 0;
  user-select: none;
}

/* ---------- doors (index) ---------- */
.doors {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  margin: 2.4rem 0 1rem;
}

@media (max-width: 620px) { .doors { grid-template-columns: 1fr; } }

.door {
  display: block;
  padding: 1.3rem 1.2rem 1.1rem;
  background: linear-gradient(180deg, var(--panel) 0%, var(--panel-2) 100%);
  border: 1px solid var(--line);
  outline: 1px solid transparent;
  outline-offset: 3px;
  transition: border-color .3s, outline-color .3s, transform .3s;
}

.door:hover, .door:focus-visible {
  border-color: var(--gold-dim);
  outline-color: var(--gold-faint);
  transform: translateY(-2px);
}

.door-name {
  font-family: var(--serif-display);
  font-size: 1.35rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--bone);
}

.door-desc { color: var(--muted); font-size: 1rem; margin: 0.35rem 0 0; font-style: italic; }

.door.warded .door-name { color: var(--steel); }

/* ---------- panels & forms ---------- */
.panel {
  background: linear-gradient(180deg, var(--panel) 0%, var(--panel-2) 100%);
  border: 1px solid var(--line);
  padding: 1.6rem 1.5rem;
  margin: 1.6rem 0;
}

label {
  display: block;
  font-variant: small-caps;
  letter-spacing: 0.16em;
  color: var(--muted);
  margin: 0 0 0.4rem;
}

input[type="password"], input[type="text"], textarea, select {
  width: 100%;
  background: #0f0b0a;
  color: var(--bone);
  border: none;
  border-bottom: 1px solid var(--gold-faint);
  padding: 0.55rem 0.2rem;
  font-family: var(--serif-body);
  font-size: 1.05rem;
  outline: none;
  transition: border-color .25s, box-shadow .25s;
}

input:focus, textarea:focus, select:focus {
  border-bottom-color: var(--gold);
  box-shadow: 0 6px 14px -10px rgba(201, 162, 75, 0.7);
}

textarea { resize: vertical; min-height: 5.5rem; }

button {
  font-family: var(--serif-display);
  font-size: 1.2rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--gold);
  background: transparent;
  border: 1px solid var(--gold-dim);
  padding: 0.8rem 2.2rem;
  cursor: pointer;
  transition: background .3s, color .3s, box-shadow .3s;
}

button:hover { background: var(--wine-deep); box-shadow: 0 0 24px -8px rgba(201,162,75,.5); }
button:active { transform: translateY(1px); }
button:disabled { opacity: 0.45; cursor: wait; }

.field { margin-bottom: 1.3rem; }

.status { min-height: 1.6rem; font-style: italic; color: var(--muted); }
.status.ok { color: #b9d1a8; }
.status.err { color: #c98383; }

/* ---------- creed articles ---------- */
.article { margin: 0 0 2.1rem; }

.article-num {
  font-family: var(--serif-display);
  color: var(--gold);
  letter-spacing: 0.3em;
  font-size: 1rem;
  text-transform: uppercase;
  display: block;
  margin-bottom: 0.15rem;
}

.article h3 {
  font-size: 1.55rem;
  font-weight: 500;
  font-style: italic;
  margin: 0 0 0.5rem;
  color: var(--bone);
}

/* ---------- records list (bell) ---------- */
.records { list-style: none; padding: 0; margin: 1rem 0 0; }

.records li {
  border-top: 1px solid var(--line);
  padding: 0.75rem 0.2rem;
  font-size: 1rem;
  color: var(--muted);
}

.records .rid { color: var(--gold); font-variant: small-caps; letter-spacing: 0.08em; }
.records .spent { color: #b9d1a8; }
.records .unspent { color: var(--steel); }

.centerline { text-align: center; }

/* ---------- footer ---------- */
footer {
  max-width: 44rem;
  margin: 0 auto;
  padding: 1.6rem 1.4rem 2.6rem;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.95rem;
  text-align: center;
  font-style: italic;
}

footer .rule { color: var(--gold-faint); font-style: normal; }
