@font-face {
  font-family: "Cinzel";
  src: url("/assets/Cinzel-Bold.ttf") format("truetype");
  font-weight: 700;
  font-display: swap;
}
@font-face {
  font-family: "Philosopher";
  src: url("/assets/Philosopher-Regular.ttf") format("truetype");
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: "Philosopher";
  src: url("/assets/Philosopher-Bold.ttf") format("truetype");
  font-weight: 700;
  font-display: swap;
}

:root {
  --night: #14201b;      /* forest shadow from the splash art */
  --night-2: #1c2c25;
  --parchment: #f4e7c5;
  --parchment-dim: #cdbf9c;
  --ink: #2a1c10;
  --gold: #e0ad4a;
  --gold-deep: #9a6a1f;
  --teal: #58d8c8;       /* the sword glow */
  --ember: #d9694a;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--night);
  color: var(--parchment);
  font-family: "Philosopher", Georgia, serif;
  font-size: 1.125rem;
  line-height: 1.55;
}
h1, h2, h3, p { margin: 0; }
h2, h3, .kicker, .ribbon { font-family: "Cinzel", Georgia, serif; font-weight: 700; }

/* ---------- hero ---------- */
.hero {
  position: relative;
  height: 100svh;
  min-height: 34rem;
  max-height: 56.25vw;          /* never taller than the art on wide screens */
  overflow: hidden;
  isolation: isolate;
  background: #d9c796;
}
@media (max-aspect-ratio: 16/9) { .hero { max-height: none; } }

.hero-art img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 38% 50%;     /* keeps the adventurers in frame on narrow screens */
  z-index: -2;
}
.hero::after {                  /* fade the art into the page */
  content: "";
  position: absolute;
  inset: auto 0 0 0;
  height: 22%;
  background: linear-gradient(to bottom, transparent, var(--night));
  z-index: -1;
  pointer-events: none;
}

.hero-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: clamp(1rem, 4vh, 3rem) 1rem 0;
  text-align: center;
}

.logo {
  position: relative;
  container-type: inline-size;
  width: min(34rem, 82vw, 52vh);
  line-height: 0;
  filter: drop-shadow(0 0.4rem 0.9rem rgba(42, 28, 16, 0.35));
}
.logo img { width: 100%; height: auto; display: block; }
.ribbon {                        /* sits in the logo's empty scroll */
  position: absolute;
  left: 50%;
  top: 75.6%;
  transform: translate(-50%, -50%);
  font-size: 4.1cqw;
  line-height: 1;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  white-space: nowrap;
  color: #5a3a14;
}

.plate {                         /* keeps the words readable over busy art */
  margin-top: clamp(0.4rem, 1.5vh, 1rem);
  padding: 0.85rem 1.4rem 0.8rem;
  border: 1px solid rgba(224, 173, 74, 0.6);
  border-radius: 0.375rem;
  background: rgba(20, 32, 27, 0.88);
  box-shadow: 0 0.5rem 1.5rem rgba(20, 32, 27, 0.35);
}
.tagline {
  max-width: 22ch;
  margin: 0 auto;
  font-size: clamp(1.15rem, 0.95rem + 1vw, 1.6rem);
  font-weight: 700;
  line-height: 1.25;
  text-wrap: balance;
  color: var(--parchment);
}
@media (min-width: 48rem) { .tagline { max-width: none; } }

.status {
  display: inline-flex;
  align-items: center;
  gap: 0.55em;
  margin-top: 0.45rem;
  color: var(--parchment-dim);
  font-size: 0.95rem;
  line-height: 1.2;
}
.dot {
  width: 0.6em;
  height: 0.6em;
  border-radius: 50%;
  background: var(--parchment-dim);
}
.status[data-state="online"] .dot { background: var(--teal); box-shadow: 0 0 0.5em var(--teal); }
.status[data-state="offline"] .dot { background: var(--ember); }
.status[data-state="checking"] .dot { animation: pulse 1.2s ease-in-out infinite; }
@keyframes pulse { 50% { opacity: 0.25; } }

/* ---------- body ---------- */
main {
  max-width: 68rem;
  margin: 0 auto;
  padding: clamp(2.5rem, 7vw, 5rem) 1.25rem clamp(3rem, 8vw, 6rem);
}

.intro { max-width: 40rem; margin: 0 auto; text-align: center; }
.kicker {
  color: var(--gold);
  font-size: 0.85rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}
.intro h2 {
  margin: 0.5rem 0 1rem;
  font-size: clamp(1.75rem, 1.2rem + 2.6vw, 3rem);
  line-height: 1.12;
  text-wrap: balance;
}
.intro p:last-child { color: var(--parchment-dim); text-wrap: pretty; }

.features {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(16rem, 1fr));
  gap: 1.25rem;
  margin-top: clamp(2.5rem, 6vw, 4rem);
}
.features article {
  padding: 1.5rem 1.5rem 1.6rem;
  border: 1px solid rgba(224, 173, 74, 0.28);
  border-top: 3px solid var(--gold);
  border-radius: 0.25rem;
  background: var(--night-2);
}
.features h3 {
  margin-bottom: 0.55rem;
  color: var(--gold);
  font-size: 1.15rem;
  line-height: 1.25;
}
.features p { color: var(--parchment); text-wrap: pretty; }

footer {
  padding: 1.5rem 1.25rem 2.5rem;
  border-top: 1px solid rgba(224, 173, 74, 0.2);
  color: var(--parchment-dim);
  font-size: 0.9rem;
  text-align: center;
}

@media (prefers-reduced-motion: reduce) {
  .status[data-state="checking"] .dot { animation: none; }
}
