
:root {
  --bg-1: #09090d;
  --bg-2: #0f1015;
  --bg-3: #15161d;
  --surface: #14151c;
  --surface-2: #1a1c24;
  --surface-3: #20222b;
  --panel: linear-gradient(180deg, #191b22 0%, #12141a 100%);
  --panel-soft: linear-gradient(180deg, #171921 0%, #111319 100%);
  --line: rgba(255, 255, 255, 0.08);
  --line-strong: rgba(255, 255, 255, 0.12);
  --text: #f5efe8;
  --muted: #b8aea6;
  --muted-strong: #cbc1b8;
  --red: #8e1f2f;
  --red-2: #b12d3f;
  --red-soft: rgba(177, 45, 63, 0.16);
  --gold: #b98a4b;
  --green: #7ee787;
  --shadow: 0 18px 40px rgba(0, 0, 0, 0.38);
  --shadow-sm: 0 10px 24px rgba(0, 0, 0, 0.26);
  --radius: 22px;
  --radius-sm: 14px;
  --max-width: 1180px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--text);
  min-height: 100vh;
  overflow-x: hidden;
  background-color: var(--bg-1);
}

body.site-bg,
body.vote-bg,
body.donate-bg,
body.login-bg {
  background:
    radial-gradient(circle at 50% -10%, rgba(142, 31, 47, 0.22), transparent 32%),
    radial-gradient(circle at 85% 8%, rgba(185, 138, 75, 0.08), transparent 18%),
    linear-gradient(180deg, var(--bg-1) 0%, var(--bg-2) 42%, #0d0e13 100%);
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(180deg, rgba(255,255,255,0.02), transparent 22%, transparent 78%, rgba(0,0,0,0.16));
  opacity: 0.65;
}

.container {
  width: min(var(--max-width), calc(100% - 32px));
  margin: 0 auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: linear-gradient(180deg, rgba(18, 19, 25, 0.98) 0%, rgba(13, 14, 19, 0.98) 100%);
  border-bottom: 1px solid var(--line);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.32);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 14px 0;
  flex-wrap: wrap;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: var(--text);
  font-weight: 900;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.brand-mark {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  overflow: hidden;
  border: 1px solid var(--line);
  background: linear-gradient(180deg, #1d1f27 0%, #15171d 100%);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.04);
}

.brand-mark img {
  display: block;
  width: 100%;
  height: 100%;
}

.buttons,
.actions,
.navlinks,
nav ul {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  list-style: none;
  padding: 0;
  margin: 0;
}

.user-dropdown {
  position: relative;
  display: inline-flex;
  align-items: center;
}

.user-menu {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  min-width: 220px;
  padding: 8px;
  border-radius: 16px;
  background: linear-gradient(180deg, #1c1d25 0%, #15161d 100%);
  border: 1px solid var(--line);
  box-shadow: 0 18px 34px rgba(0,0,0,0.45);
  opacity: 0;
  visibility: hidden;
  transform: translateY(6px);
  transition: all 0.2s ease;
  z-index: 9999;
}

.user-dropdown:hover .user-menu,
.user-dropdown.open .user-menu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.user-menu a {
  display: block;
  padding: 10px 12px;
  border-radius: 10px;
  color: var(--muted-strong);
  text-decoration: none;
}

.user-menu a:hover {
  background: rgba(255,255,255,0.05);
  color: var(--text);
}

.menu-divider {
  height: 1px;
  margin: 8px 4px;
  background: var(--line);
}

.user-toggle { gap: 8px; }
.user-toggle .caret { transition: transform 0.2s ease; }
.user-dropdown:hover .caret { transform: rotate(180deg); }

.nav-user-avatar {
  width: 28px;
  height: 28px;
  border-radius: 999px;
  object-fit: cover;
  border: 1px solid var(--line);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.22);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 46px;
  text-decoration: none;
  color: var(--text);
  padding: 0 18px;
  border-radius: 12px;
  font-weight: 700;
  background: linear-gradient(180deg, #23252f 0%, #1a1c24 100%);
  border: 1px solid var(--line);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.04);
  transition: transform 0.16s ease, background 0.16s ease, border-color 0.16s ease, box-shadow 0.16s ease;
  cursor: pointer;
}

.btn:hover {
  transform: translateY(-1px);
  background: linear-gradient(180deg, #282b35 0%, #1d2028 100%);
  border-color: var(--line-strong);
}

.btn.primary {
  background: linear-gradient(180deg, var(--red-2) 0%, var(--red) 100%);
  border-color: rgba(255,255,255,0.12);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.06), 0 10px 22px rgba(142, 31, 47, 0.25);
  color: #fff7f5;
}

.btn.primary:hover {
  background: linear-gradient(180deg, #c23448 0%, #972334 100%);
}

.panel,
.card,
.stat,
.reward,
.site,
.support-note,
.perk-panel,
.info-card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.section-copy,
.card p,
.site p,
.panel p,
.reward span,
.support-note p,
.perk-panel li,
.info-card p,
.info-card li,
li,
.field-note {
  color: var(--muted);
  line-height: 1.7;
}

h1, h2, h3, h4 {
  color: var(--text);
}

.section-title,
h2 {
  font-size: clamp(1.8rem, 3vw, 2.6rem);
  margin: 0 0 12px;
}

label {
  color: var(--muted-strong);
}

input,
select,
textarea {
  width: 100%;
  font: inherit;
  color: var(--text);
  background: linear-gradient(180deg, #171920 0%, #111319 100%);
  border: 1px solid var(--line);
  border-radius: 14px;
  outline: none;
}

input:focus,
select:focus,
textarea:focus {
  border-color: rgba(177, 45, 63, 0.55);
  box-shadow: 0 0 0 3px rgba(177, 45, 63, 0.12);
}

.footer {
  padding: 6px 0 16px;
  color: var(--muted);
}

.footer-inner {
  border-top: 1px solid var(--line);
  padding-top: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  flex-wrap: wrap;
  text-align: center;
}

.footer-inline {
  justify-content: center;
  font-size: 12px;
  line-height: 1.3;
}

.footer-inline-link {
  color: var(--muted-strong);
  text-decoration: none;
}

.footer-inline-link:hover {
  color: var(--text);
}

.footer-discord-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.footer-discord-link img {
  width: 14px;
  height: 14px;
  display: block;
}

.footer-separator {
  display: inline-block;
  margin: 0 6px;
  color: rgba(255, 255, 255, 0.28);
}

.reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.45s ease, transform 0.45s ease;
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

.alert {
  padding: 14px 16px;
  border-radius: 16px;
  margin: 0 0 18px;
  border: 1px solid var(--line);
  background: linear-gradient(180deg, #1b1c23 0%, #14151b 100%);
}

.alert.error {
  border-color: rgba(177, 45, 63, 0.36);
  background: linear-gradient(180deg, rgba(177, 45, 63, 0.18) 0%, rgba(20, 21, 27, 0.96) 100%);
}

.alert.success {
  border-color: rgba(126, 231, 135, 0.28);
  background: linear-gradient(180deg, rgba(126, 231, 135, 0.12) 0%, rgba(20, 21, 27, 0.96) 100%);
  margin-bottom: 22px;
}

.alert.info {
  border-color: rgba(185, 138, 75, 0.34);
  background: linear-gradient(180deg, rgba(185, 138, 75, 0.12) 0%, rgba(20, 21, 27, 0.96) 100%);
}

.badge,
.tag,
.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 9px 14px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: rgba(255,255,255,0.04);
  color: var(--gold);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.78rem;
  font-weight: 800;
}

.divider {
  width: 100%;
  margin-bottom: 20px;
  opacity: .85;
}

@media (max-width: 980px) {
  .footer-inner {
    justify-content: center;
  }
}

@media (max-width: 760px) {
  .nav {
    flex-direction: column;
    align-items: flex-start;
  }

  .buttons,
  .actions {
    width: 100%;
  }

  .footer {
    padding: 6px 0 14px;
  }
}
