/* same look as the launcher (app/ui/style.css) */
:root {
  --bg: #070a14;
  --glass: rgba(10, 14, 28, 0.66);
  --line: rgba(255, 255, 255, 0.1);
  --line-2: rgba(255, 255, 255, 0.16);
  --text: #f1efe8;
  --muted: #a7acbf;
  --blue: #148eff;
  --gold: #f1c45b;
  --ok: #3fd47a;
  --ko: #ef6b6b;
}
* { box-sizing: border-box; }
html { color-scheme: dark; scroll-behavior: smooth; }
body {
  margin: 0; min-height: 100vh;
  background: var(--bg); color: var(--text);
  font: 15px/1.6 Inter, system-ui, -apple-system, "Segoe UI", sans-serif;
  -webkit-font-smoothing: antialiased;
}
a { color: #8cc8ff; text-decoration: none; }
a:hover { text-decoration: underline; }
.muted { color: var(--muted); }
.label { font-size: 11px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: var(--gold); }

/* ------------------------------------------------------------------ background art */
.backdrop { position: fixed; inset: 0; z-index: -1; overflow: hidden; }
.bg { position: absolute; inset: -3%; background-size: cover; background-position: center 35%; opacity: 0; transition: opacity 1.6s ease; }
.bg.on { opacity: 1; animation: drift 24s ease-out both; }
@keyframes drift { from { transform: scale(1.08); } to { transform: scale(1); } }
/* photographic backdrop, on every page (opacity set here so it shows without JS) */
.bg.scene-photo {
  background-image: url("/static/img/hero-valley-2.webp"); background-position: center 45%;
  opacity: 1; animation: drift 34s ease-out both;
}
/* the photo brings its own landscape: the drawn ridges and clouds are gone everywhere */
.land, .clouds { display: none !important; }
/* stormy valley, drawn in CSS (no game artwork in this repo); three moods that slowly cross-fade */
.bg.scene-1 { background:
  radial-gradient(34% 22% at 50% 51%, rgba(255, 221, 164, 0.6), transparent 72%),
  radial-gradient(48% 34% at 50% 47%, rgba(226, 196, 158, 0.3), transparent 72%),
  radial-gradient(58% 46% at 12% 2%, rgba(11, 16, 28, 0.94), transparent 66%),
  radial-gradient(58% 46% at 89% 0%, rgba(9, 14, 26, 0.96), transparent 68%),
  radial-gradient(70% 38% at 50% 20%, rgba(122, 142, 174, 0.5), transparent 74%),
  linear-gradient(180deg, #0e1626 0%, #27344a 28%, #64708a 44%, #b39c86 52%, #3c4967 66%, #0d1421 100%); }
.bg.scene-2 { background:
  radial-gradient(34% 24% at 52% 50%, rgba(255, 206, 130, 0.62), transparent 72%),
  radial-gradient(52% 36% at 55% 46%, rgba(214, 150, 90, 0.34), transparent 72%),
  radial-gradient(58% 46% at 8% 0%, rgba(36, 22, 20, 0.9), transparent 66%),
  radial-gradient(60% 48% at 92% 4%, rgba(28, 18, 22, 0.9), transparent 68%),
  radial-gradient(70% 40% at 46% 18%, rgba(148, 138, 160, 0.45), transparent 74%),
  linear-gradient(180deg, #221a2c 0%, #4a3550 30%, #8f6b64 46%, #d3a172 53%, #4a3b4e 68%, #100c18 100%); }
.bg.scene-3 { background:
  radial-gradient(22% 18% at 62% 26%, rgba(224, 236, 255, 0.55), transparent 70%),
  radial-gradient(46% 32% at 50% 52%, rgba(126, 158, 198, 0.28), transparent 74%),
  radial-gradient(58% 46% at 10% 0%, rgba(5, 9, 18, 0.95), transparent 66%),
  radial-gradient(60% 48% at 90% 2%, rgba(4, 8, 16, 0.96), transparent 68%),
  radial-gradient(70% 38% at 50% 22%, rgba(64, 84, 118, 0.5), transparent 74%),
  linear-gradient(180deg, #060a14 0%, #111b2e 32%, #2c3d57 50%, #445a75 55%, #16202f 74%, #05080f 100%); }
/* mountain ridges below the sky */
.land { position: absolute; left: 0; right: 0; bottom: 0; width: 100%; height: 66vh; display: block; }
/* slow clouds drifting across the sky */
.clouds {
  position: absolute; inset: -25% -20% -5%; pointer-events: none; opacity: 0.9;
  background-image:
    radial-gradient(38% 30% at 50% 50%, rgba(186, 200, 222, 0.16), transparent 70%),
    radial-gradient(30% 24% at 50% 50%, rgba(255, 232, 196, 0.1), transparent 70%);
  background-size: 72% 58%, 48% 38%; background-position: 0 0, 28% 12%; background-repeat: repeat;
  animation: cloud-drift 140s linear infinite;
}
@keyframes cloud-drift { to { background-position: 72% 4%, 100% 12%; } }
.shade {
  position: absolute; inset: 0;
  background:
    linear-gradient(180deg, rgba(5, 8, 18, 0.8) 0%, rgba(5, 8, 18, 0.12) 20%, rgba(5, 8, 18, 0.3) 58%, rgba(5, 8, 18, 0.93) 100%),
    linear-gradient(90deg, rgba(5, 8, 18, 0.6) 0%, rgba(5, 8, 18, 0) 55%);
}

/* ------------------------------------------------------------------ hanging banners (wind) */
.flags { position: absolute; top: 156px; left: 0; right: 0; height: 1200px; pointer-events: none; z-index: 1; }
.flag-wrap { position: absolute; top: 0; width: clamp(256px, 24vw, 500px); filter: drop-shadow(0 22px 38px rgba(0, 0, 0, 0.55)); }
.flag-wrap.left { left: 6px; }
.flag-wrap.right { right: 6px; transform: scaleX(-1); }
/* no room beside the content column any more */
@media (max-width: 1100px) { .flags { display: none; } }
.flag { display: block; width: 100%; height: auto; transform-origin: 50% 3%; animation: flag-sway 9.5s ease-in-out infinite; will-change: transform; }
.flag-wrap.right .flag { animation-duration: 11s; animation-delay: -3.2s; }
/* the banners are photos now: the image is the cloth, the SVG wind filter ripples it */
.flag img { display: block; width: 100%; height: auto; }
.flag .flag-cloth { filter: url(#bannerWind); }
@keyframes flag-sway {
  0%, 100% { transform: rotate(-1.5deg) translate(0, 0); }
  35% { transform: rotate(0.7deg) translate(2px, 1px); }
  70% { transform: rotate(-0.5deg) translate(-2px, 3px); }
}
/* the cloth itself rides on the wind, on top of the first, slower swing */
.flag-cloth { transform-origin: 50% 2%; animation: cloth-flutter 6.5s ease-in-out infinite; }
.flag-wrap.right .flag-cloth { animation-duration: 7.8s; animation-delay: -1.9s; }
/* keeps the cloth's 20,14 offset: a CSS animation replaces the transform attribute */
@keyframes cloth-flutter {
  0%, 100% { transform: translate(20px, 14px) rotate(-0.7deg) skewX(1deg); }
  50% { transform: translate(20px, 14px) rotate(0.6deg) skewX(-1.2deg) scaleY(1.006); }
}
.svg-defs { position: absolute; width: 0; height: 0; overflow: hidden; }

/* ------------------------------------------------------------------ top bar: the banner rail, the crest and the nav */
.topbar {
  position: relative; z-index: 5;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  grid-template-areas: "left logo right" "nav nav nav";
  grid-template-rows: 168px auto;   /* the first row is the stone bar */
  align-items: center; column-gap: 20px;
  padding: 0 clamp(86px, 6.6vw, 124px) 22px;
}
/* riveted metal band with gold edges, carrying the gems */
.rail {
  position: absolute; left: 0; right: 0; top: 40px; height: 120px; z-index: 0; pointer-events: none;
  background: url("/static/img/topbar-stone.webp") center / 100% 100% no-repeat;
  filter: drop-shadow(0 18px 34px rgba(0, 0, 0, 0.7));
}
/* the two gryphon statues that cap the stone bar, as in the reference art */
.rail::before, .rail::after {
  content: ""; position: absolute; bottom: -18px; width: clamp(70px, 6.1vw, 102px);
  aspect-ratio: 176 / 305;
  background: url("/static/img/topbar-gryphon.webp") center bottom / contain no-repeat;
}
.rail::before { left: clamp(0px, 0.6vw, 14px); }
.rail::after { right: clamp(0px, 0.6vw, 14px); transform: scaleX(-1); }
.bar-right {
  grid-area: right; justify-self: end; position: relative; z-index: 3; transform: translateY(30px);
  display: flex; align-items: center; gap: 10px;
}
.top-logo {
  grid-area: logo; justify-self: center; position: relative; z-index: 3; transform: translateY(16px);
  display: grid; line-height: 1; text-decoration: none; filter: drop-shadow(0 6px 18px rgba(0, 0, 0, 0.75));
}
.top-logo strong {
  font: 700 34px/1 Georgia, "Times New Roman", serif; letter-spacing: 0.09em;
  background: linear-gradient(180deg, #fff3cf, #f1c45b 55%, #b8822a); -webkit-background-clip: text; background-clip: text; color: transparent;
}
.topbar nav {
  grid-area: nav; justify-self: center; margin-top: 10px;
  display: flex; flex-wrap: wrap; justify-content: center;
  gap: clamp(12px, 1.8vw, 26px); padding: 9px 28px; border-radius: 999px;
  background: rgba(6, 10, 18, 0.42); border: 1px solid rgba(201, 162, 74, 0.22);
  backdrop-filter: blur(4px);
}
.topbar nav a {
  color: rgba(255, 255, 255, 0.86); font-weight: 600; font-size: 15.5px; letter-spacing: 0.05em; text-transform: uppercase;
  white-space: nowrap; text-shadow: 0 2px 8px rgba(0, 0, 0, 0.95), 0 0 2px rgba(0, 0, 0, 0.9);
}
.topbar nav a:hover { color: #fff; text-decoration: none; }
.topbar nav a.on { color: var(--gold); }
.langs { display: flex; gap: 2px; padding: 3px; border-radius: 999px; background: rgba(0, 0, 0, 0.45); border: 1px solid var(--line); }
.langs a { padding: 3px 9px; border-radius: 999px; font-size: 12px; font-weight: 700; color: rgba(255, 255, 255, 0.7); }
.langs a:hover { color: #fff; text-decoration: none; }
.langs a.on { background: var(--blue); color: #fff; }
.status {
  display: inline-flex; align-items: center; gap: 8px; white-space: nowrap;
  padding: 6px 14px; border-radius: 999px; font-size: 13px; font-weight: 600;
  background: rgba(0, 0, 0, 0.45); border: 1px solid var(--line); backdrop-filter: blur(8px);
}
.status .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--muted); }
.status[data-online="yes"] .dot { background: var(--ok); box-shadow: 0 0 10px var(--ok); }
.status[data-online="no"] .dot { background: var(--ko); }

/* ------------------------------------------------------------------ discord invite: riveted into the left end of the stone bar */
.social-discord {
  position: absolute; z-index: 4; left: clamp(96px, 7.4vw, 148px); top: 100px; transform: translateY(-50%);
  display: inline-flex; align-items: center; gap: 9px; padding: 8px 16px 8px 13px; border-radius: 999px;
  text-decoration: none; color: rgba(233, 240, 255, 0.92);
  font: 600 12.5px/1 Inter, system-ui, sans-serif; letter-spacing: 0.07em; text-transform: uppercase;
  background: linear-gradient(180deg, rgba(18, 24, 40, 0.82), rgba(6, 10, 18, 0.9));
  border: 1px solid rgba(201, 162, 74, 0.32);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.07), 0 8px 20px rgba(0, 0, 0, 0.45);
  transition: color 0.15s, border-color 0.15s, box-shadow 0.15s;
}
.social-discord svg { width: 18px; height: 18px; display: block; color: #8ea6ff; transition: color 0.15s; }
.social-discord:hover {
  color: #fff; border-color: rgba(201, 162, 74, 0.7); text-decoration: none;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.12), 0 10px 26px rgba(0, 0, 0, 0.55), 0 0 18px rgba(88, 101, 242, 0.35);
}
.social-discord:hover svg { color: #a9bcff; }
.social-discord:focus-visible { outline: 2px solid var(--gold); outline-offset: 3px; }

/* ------------------------------------------------------------------ sections */
main { position: relative; z-index: 2; max-width: 1080px; margin: 0 auto; padding: 0 clamp(16px, 4vw, 48px); }
.card {
  background: var(--glass); border: 1px solid var(--line); border-radius: 10px;
  backdrop-filter: blur(14px); box-shadow: 0 20px 60px rgba(0, 0, 0, 0.4);
}
.hero {
  display: grid; grid-template-columns: 1fr 380px; align-items: center; gap: 40px;
  padding: 8px 0 24px;
}
.pitch h1 { margin: 6px 0 10px; font-size: clamp(1.8rem, 3.6vw, 2.6rem); line-height: 1.1; font-weight: 700; text-shadow: 0 4px 30px rgba(0, 0, 0, 0.6); }
.pitch p { margin: 0 0 18px; max-width: 520px; font-size: 1.08rem; color: rgba(255, 255, 255, 0.85); text-shadow: 0 2px 16px rgba(0, 0, 0, 0.7); }
.cta { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
[hidden] { display: none !important; }
.signup { padding: 22px; }

/* hero card: sign in / create account tabs */
.auth { overflow: hidden; padding: 0; }
.auth-tabs { display: flex; border-bottom: 1px solid var(--line); background: rgba(0, 0, 0, 0.25); }
.auth-tab {
  flex: 1; padding: 12px 10px; text-align: center; text-decoration: none;
  font-size: 11px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--muted); border-bottom: 2px solid transparent; transition: color 0.15s, background 0.15s, border-color 0.15s;
}
.auth-tab:hover { color: var(--text); background: rgba(255, 255, 255, 0.05); text-decoration: none; }
.auth-tab.on { color: var(--gold); border-bottom-color: var(--gold); background: rgba(241, 196, 91, 0.07); }
.auth-body { padding: 20px 22px 22px; }
.auth-body h2 { font-size: 1.4rem; }
.auth-body > .muted { margin: 0 0 18px; font-size: 0.92rem; }
.auth-body .success { margin: 0; }
h2 { margin: 2px 0 4px; font-size: 1.4rem; font-weight: 700; }
.signup h2 { font-size: 1.4rem; }
.signup > .muted { margin: 0 0 18px; font-size: 0.92rem; }
h3 { margin: 0; font-size: 1.05rem; }
form { display: grid; gap: 11px; }
label { display: grid; gap: 6px; font-size: 0.8rem; font-weight: 600; color: var(--muted); }
input {
  font: 15px Inter, system-ui, sans-serif; color: var(--text);
  background: rgba(0, 0, 0, 0.4); border: 1px solid var(--line-2); border-radius: 4px;
  padding: 11px 13px; transition: border-color 0.15s, box-shadow 0.15s;
}
input:focus { outline: none; border-color: var(--blue); box-shadow: 0 0 0 3px rgba(20, 142, 255, 0.25); }
.hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }

.btn {
  display: inline-flex; justify-content: center; align-items: center;
  font: 600 0.95rem Inter, system-ui, sans-serif; color: var(--text); text-decoration: none; cursor: pointer;
  border: 1px solid var(--line-2); border-radius: 4px; padding: 10px 18px;
  background: rgba(255, 255, 255, 0.07);
  transition: transform 0.1s, background 0.15s;
}
.btn:hover { text-decoration: none; background: rgba(255, 255, 255, 0.13); }
.btn:active { transform: translateY(1px); }
.btn.primary { background: var(--blue); border-color: transparent; color: #fff; box-shadow: 0 10px 28px rgba(20, 142, 255, 0.3); }
.btn.primary:hover { background: #2f9dff; }
.btn.big { padding: 14px; font-size: 1.05rem; }
.btn.outline { background: rgba(0, 0, 0, 0.35); }
.btn.small { font-size: 0.85rem; padding: 7px 14px; }
.btn.disabled { color: var(--muted); cursor: default; background: rgba(255, 255, 255, 0.05); }
.hint { color: var(--muted); font-size: 0.8rem; margin: 0; text-align: center; }
.alert { background: rgba(239, 107, 107, 0.12); border: 1px solid rgba(239, 107, 107, 0.35); color: #ffc9c9; padding: 10px 14px; border-radius: 4px; margin: 0 0 14px; font-size: 0.92rem; }
.success { display: grid; gap: 14px; text-align: center; }
.success p { margin: 0; }
.link { font-size: 0.9rem; }

.block { padding: 28px 0 4px; scroll-margin-top: 16px; }
.steps { list-style: none; padding: 0; margin: 14px 0 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.steps li { padding: 16px 18px; display: grid; align-content: start; gap: 6px; }
.num {
  width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; margin-bottom: 6px;
  font-weight: 700; color: #fff; background: var(--blue); box-shadow: 0 6px 18px rgba(20, 142, 255, 0.35);
}
.steps p { margin: 0; color: var(--muted); font-size: 0.92rem; }
.downloads { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.btn.os { gap: 7px; }
.btn.os img { display: block; }
.btn.os.disabled img { opacity: 0.5; }
.mac-note { margin-top: 12px; padding: 12px 18px; font-size: 0.9rem; color: var(--muted); display: flex; flex-wrap: wrap; gap: 8px 16px; align-items: center; }
.mac-note.mine { border-color: rgba(20, 142, 255, 0.55); }
.mac-note p { margin: 0; flex: 1 1 340px; }
.mac-note strong { color: var(--text); }
.cmd { display: flex; gap: 8px; align-items: center; flex: 0 1 auto; min-width: 0; }
.cmd code { min-width: 0; padding: 7px 10px; font-size: 0.82rem; user-select: all; word-break: normal; overflow-wrap: anywhere; }
code { background: rgba(0, 0, 0, 0.4); padding: 1px 6px; border-radius: 4px; font-size: 0.85em; word-break: break-all; }

.news { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; margin-top: 14px; }
.news-card {
  overflow: hidden; background: var(--glass); border: 1px solid var(--line); border-radius: 6px;
  backdrop-filter: blur(10px); transition: transform 0.18s ease, border-color 0.18s, box-shadow 0.18s;
}
.news-card:hover { transform: translateY(-3px); border-color: rgba(140, 200, 255, 0.45); box-shadow: 0 14px 34px rgba(0, 0, 0, 0.45); }
.news-card img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; display: block; }
.news-card .thumb { aspect-ratio: 16 / 9; display: grid; place-items: center; font: 700 34px Georgia, serif; color: rgba(255, 255, 255, 0.35); }
.news-card:nth-child(3n + 1) .thumb { background: radial-gradient(70% 80% at 30% 30%, rgba(64, 140, 220, 0.6), transparent), #10203f; }
.news-card:nth-child(3n + 2) .thumb { background: radial-gradient(70% 80% at 70% 30%, rgba(140, 70, 200, 0.55), transparent), #1a1036; }
.news-card:nth-child(3n + 3) .thumb { background: radial-gradient(70% 80% at 50% 70%, rgba(40, 170, 140, 0.5), transparent), #0a2230; }
.news-card .body { display: grid; gap: 4px; padding: 10px 12px 12px; }
.news-card .tag { font-size: 10.5px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: #8cc8ff; }
.news-card strong { font-size: 0.98rem; line-height: 1.35; }

/* bug-report band: live counts of the in-game ticket table */
.reports {
  margin-top: 14px; padding: 22px 24px 20px; text-align: center; border-radius: 10px;
  background: linear-gradient(180deg, rgba(18, 46, 30, 0.82), rgba(9, 24, 16, 0.88));
  border: 1px solid rgba(241, 196, 91, 0.5); box-shadow: 0 20px 60px rgba(0, 0, 0, 0.4);
}
.reports .counts { display: flex; align-items: center; justify-content: center; gap: clamp(16px, 4vw, 52px); margin: 8px 0 14px; }
.reports .counts strong { display: block; font: 700 clamp(2rem, 5vw, 2.9rem)/1.05 Cinzel, Georgia, serif; color: var(--gold); }
.reports p strong { color: var(--gold); font-weight: 600; }
.reports .counts span { font-size: 0.9rem; color: #d6ddcf; }
.reports .counts span.arrow { font-size: 2.2rem; line-height: 1; color: var(--gold); opacity: 0.9; }
.reports p { margin: 0 auto; max-width: 760px; font-size: 0.98rem; color: #dfe5da; }

footer { position: relative; z-index: 2; text-align: center; color: var(--muted); font-size: 0.78rem; padding: 28px 16px 18px; opacity: 0.85; }

@media (max-width: 1180px) {
  .top-logo strong { font-size: 30px; }
  .top-logo small { font-size: 9.5px; }
}
@media (max-width: 900px) {
  .hero { grid-template-columns: 1fr; min-height: 0; gap: 28px; padding-top: 12px; }
  .steps, .news { grid-template-columns: 1fr; }
  .topbar nav { display: none; }
  .flags { display: none; }
  .topbar {
    grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr); grid-template-areas: "left logo right";
    grid-template-rows: 88px auto;
    align-items: center; padding: 0 clamp(16px, 4vw, 48px) 18px;
  }
  .top-logo, .bar-right { margin-top: 0; }
  .top-logo { transform: translateY(10px); }
  .bar-right { transform: translateY(16px); }
  .rail { top: 8px; height: 74px; }
  .rail::before, .rail::after { width: 42px; bottom: -9px; }
  /* the invite keeps its place next to the gryphon, but shrinks to the bare glyph */
  .social-discord { left: 62px; top: 45px; padding: 0; width: 34px; height: 34px; justify-content: center; }
  .social-discord span { display: none; }
  .social-discord svg { width: 16px; height: 16px; }
  .top-logo strong { font-size: 20px; }
  .status { display: none; }
}
/* /account, /shop, /vote and /admin share the homepage chrome: stone bar, flags, photo backdrop */
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation: none !important; transition: none !important; } html { scroll-behavior: auto; } }
