:root {
  --bg: #0a0d0c;
  --ink: #f2ebe0;
  --muted: #b8aea0;
  --gold: #d4b06a;
  --gold-deep: #a8843d;
  --line: rgba(212, 176, 106, 0.28);
  --card: rgba(18, 24, 22, 0.72);
  --danger: #e07a6a;
  --ok: #7dbf8a;
}

* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; }
body {
  color: var(--ink);
  font-family: "Source Serif 4", Georgia, serif;
  background:
    radial-gradient(1200px 700px at 50% -10%, rgba(196, 92, 42, 0.18), transparent 55%),
    radial-gradient(900px 500px at 80% 20%, rgba(212, 176, 106, 0.08), transparent 50%),
    linear-gradient(180deg, #121816 0%, var(--bg) 45%, #070908 100%);
}
a { color: var(--gold); text-decoration: none; }
a:hover { text-decoration: underline; }

.shell { min-height: 100vh; display: grid; grid-template-rows: auto 1fr auto; }
.topbar {
  display: flex; flex-wrap: wrap; gap: 1rem; align-items: center; justify-content: space-between;
  padding: 0.9rem 1.35rem; border-bottom: 1px solid var(--line);
  background: rgba(10, 13, 12, 0.82); backdrop-filter: blur(10px); position: sticky; top: 0; z-index: 20;
}
.brand { display: flex; gap: 0.75rem; align-items: center; color: var(--ink); text-decoration: none; }
.brand img { width: 42px; height: 42px; border-radius: 50%; border: 1px solid var(--line); object-fit: cover; }
.brand strong { display: block; font-family: Cinzel, serif; letter-spacing: 0.03em; }
.brand small { display: block; color: var(--muted); font-size: 0.78rem; }
.nav { display: flex; flex-wrap: wrap; gap: 0.55rem; }
.nav a {
  color: var(--muted); padding: 0.35rem 0.65rem; border-radius: 999px; text-decoration: none;
}
.nav a:hover, .nav a.active { color: var(--ink); background: rgba(212, 176, 106, 0.12); text-decoration: none; }
.btn {
  appearance: none; border: 0; border-radius: 999px; padding: 0.85rem 1.3rem;
  font-family: Cinzel, serif; font-size: 0.92rem; letter-spacing: 0.03em; cursor: pointer;
  text-decoration: none; display: inline-block; transition: transform 160ms ease;
}
.btn:hover { transform: translateY(-1px); text-decoration: none; }
.btn-primary { background: linear-gradient(180deg, var(--gold), var(--gold-deep)); color: #1a140a; }
.btn-ghost { background: transparent; color: var(--ink); border: 1px solid var(--line); }
.page { width: min(960px, calc(100% - 2rem)); margin: 2rem auto 3rem; }
.hero { text-align: center; padding: 2.5rem 0 1rem; }
.hero h1 {
  margin: 0.8rem 0 0; font-family: Cinzel, serif; font-size: clamp(2.4rem, 7vw, 4.2rem);
  line-height: 1.05; letter-spacing: 0.03em;
}
.hero .logo { width: 96px; height: 96px; border-radius: 50%; border: 1px solid var(--line); object-fit: cover; }
.tagline { color: var(--muted); font-size: 1.15rem; line-height: 1.55; max-width: 36rem; margin: 1rem auto 0; }
.actions { margin-top: 1.75rem; display: flex; flex-wrap: wrap; gap: 0.75rem; justify-content: center; }
.card {
  background: var(--card); border: 1px solid var(--line); border-radius: 18px;
  padding: 1.25rem 1.35rem; margin-top: 1.25rem;
}
.card h2 { margin: 0 0 0.5rem; font-family: Cinzel, serif; font-size: 1.35rem; }
.muted { color: var(--muted); }
.soon {
  display: inline-block; margin-top: 0.75rem; padding: 0.25rem 0.65rem; border-radius: 999px;
  border: 1px solid var(--line); color: var(--gold); font-size: 0.85rem; font-family: Cinzel, serif;
}
.footer {
  padding: 1.25rem; text-align: center; color: var(--muted); border-top: 1px solid var(--line); font-size: 0.9rem;
}
.grid-2 { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
.form { display: grid; gap: 0.75rem; }
.form label { display: grid; gap: 0.35rem; color: var(--muted); font-size: 0.95rem; }
.form input, .form textarea, .form select {
  width: 100%; padding: 0.7rem 0.8rem; border-radius: 10px; border: 1px solid var(--line);
  background: #0f1412; color: var(--ink); font: inherit;
}
.error { color: var(--danger); }
.ok { color: var(--ok); }
.table { width: 100%; border-collapse: collapse; }
.table th, .table td { text-align: left; padding: 0.55rem 0.4rem; border-bottom: 1px solid var(--line); }
.hidden { display: none !important; }
.quiz-q { margin-top: 1rem; }
.quiz-q label { display: block; margin: 0.35rem 0; cursor: pointer; }
.virtue-grid {
  display: grid;
  gap: 0.85rem;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  margin-top: 1rem;
}
.virtue-card {
  display: block; text-align: center; color: inherit; text-decoration: none;
  border: 1px solid var(--line); border-radius: 14px; padding: 0.75rem 0.55rem 0.7rem;
  background: rgba(18, 24, 22, 0.55);
}
.virtue-card:hover { border-color: var(--gold); text-decoration: none; }
.virtue-card .virtue-icon {
  width: 72px; height: 72px; margin: 0 auto; display: grid; place-items: center;
  border-radius: 12px; border: 1px solid var(--line);
  background: linear-gradient(180deg, #1a221e, #0f1412);
}
.virtue-card img {
  width: 48px; height: 48px; display: block;
  image-rendering: pixelated; image-rendering: crisp-edges;
}
.virtue-card strong { display: block; margin-top: 0.55rem; font-family: Cinzel, serif; font-size: 0.92rem; }
.virtue-card span { display: block; color: var(--muted); font-size: 0.78rem; margin-top: 0.15rem; }
.virtue-card.featured { box-shadow: 0 0 0 1px rgba(212, 176, 106, 0.35); }
.tag-row { display: flex; flex-wrap: wrap; gap: 0.4rem; margin: 0.75rem 0 0; }
.tag {
  display: inline-block; padding: 0.2rem 0.55rem; border-radius: 999px;
  border: 1px solid var(--line); font-size: 0.8rem; color: var(--gold);
}
.prose h2 { font-family: Cinzel, serif; margin: 1.5rem 0 0.5rem; }
.prose h3 { font-family: Cinzel, serif; margin: 1.1rem 0 0.35rem; font-size: 1.1rem; }
.prose p, .prose li { color: var(--muted); line-height: 1.55; }
.prose ul { padding-left: 1.2rem; }
.prose strong { color: var(--ink); }
@media (max-width: 700px) {
  .topbar { align-items: flex-start; }
  .nav { width: 100%; }
}
