:root {
  --bg-dark: #0f1c14;
  --bg-mid: #18291f;
  --bg-soft: #21382a;
  --panel: rgba(22, 42, 31, 0.94);
  --panel-2: rgba(27, 49, 36, 0.97);
  --panel-light: rgba(146, 179, 141, 0.16);
  --line: rgba(158, 195, 148, 0.24);
  --line-strong: rgba(201, 224, 174, 0.42);
  --text: #e8f2de;
  --muted: #b7c8ae;
  --accent: #9bc873;
  --accent-deep: #5f8d43;
  --accent-soft: #cce6a8;
  --green: #8dbb69;
  --green-deep: #4f7440;
  --danger: #efb38f;
  --shadow: 0 20px 44px rgba(5, 12, 8, 0.42);
  --radius-xl: 24px;
  --radius-lg: 18px;
  --radius-md: 14px;
  --radius-sm: 10px;
  --max-width: 1220px;
  --section-gap: 22px;
  --content-pad: clamp(18px, 2.2vw, 28px);
  --pixel-shadow: 0 0 0 1px rgba(15, 28, 20, 0.45), 4px 4px 0 rgba(7, 14, 9, 0.32);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: Georgia, "Times New Roman", serif;
  line-height: 1.6;
  color: var(--text);
  background:
    radial-gradient(circle at 18% 8%, rgba(204, 230, 168, 0.08), transparent 34%),
    radial-gradient(circle at 85% 20%, rgba(141, 187, 105, 0.1), transparent 28%),
    linear-gradient(180deg, rgba(8, 16, 11, 0.28), rgba(8, 16, 11, 0.62)),
    linear-gradient(180deg, var(--bg-dark), var(--bg-mid) 42%, #0d1911 100%);
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  opacity: 0.25;
  background:
    linear-gradient(rgba(255, 255, 255, 0.015), rgba(255, 255, 255, 0.015)),
    repeating-linear-gradient(
      45deg,
      rgba(215, 239, 182, 0.02) 0,
      rgba(215, 239, 182, 0.02) 2px,
      transparent 2px,
      transparent 22px
    );
  mix-blend-mode: soft-light;
}

body::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  opacity: 0.08;
  background-image:
    linear-gradient(rgba(0, 0, 0, 0.14) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0, 0, 0, 0.14) 1px, transparent 1px);
  background-size: 20px 20px;
  mix-blend-mode: multiply;
}

img {
  max-width: 100%;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input,
select,
textarea {
  font: inherit;
}

.auth-screen,
.site-shell {
  position: relative;
  z-index: 1;
}

.auth-screen {
  padding: 34px 18px 64px;
}

.auth-layout,
.container,
.public-donation-footer,
.site-footer {
  width: min(var(--max-width), calc(100% - 32px));
  margin: 0 auto;
}

.auth-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  align-items: start;
  gap: var(--section-gap);
}

.panel {
  position: relative;
  overflow: hidden;
  background:
    linear-gradient(180deg, rgba(229, 245, 211, 0.05), transparent 24%),
    linear-gradient(180deg, var(--panel), var(--panel-2));
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: var(--content-pad);
  box-shadow: var(--shadow), var(--pixel-shadow);
}

.panel::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(140deg, rgba(204, 230, 168, 0.12), transparent 30%, transparent 68%, rgba(123, 174, 103, 0.12));
}

.auth-panel,
.application-panel {
  min-height: 100%;
}

.donation-panel {
  display: grid;
  gap: 12px;
}

.donation-footer {
  margin-top: 24px;
  padding-block: clamp(16px, 2vw, 22px);
  border-top: 1px solid rgba(233, 205, 162, 0.28);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.025), transparent 22%),
    linear-gradient(180deg, rgba(50, 35, 25, 0.98), rgba(63, 44, 31, 0.98));
}

.footer-heading {
  margin-bottom: 0;
}

.footer-donation-grid {
  align-items: stretch;
}

.compact-info-list {
  align-content: start;
}

.donation-status {
  margin: 0;
}

.public-donation-footer {
  margin-top: 18px;
}

.eyebrow {
  display: inline-block;
  margin-bottom: 10px;
  padding: 6px 12px;
  border: 1px solid rgba(170, 207, 130, 0.34);
  border-radius: 999px;
  background: rgba(120, 164, 94, 0.18);
  color: var(--accent-soft);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.eyebrow::before {
  content: "■ ";
  color: #b9db90;
}

h1,
h2 {
  margin: 0;
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: 0.01em;
  font-family: "Trebuchet MS", "Segoe UI", sans-serif;
  text-transform: uppercase;
}

h1 {
  font-size: clamp(2.5rem, 5vw, 4.2rem);
}

h2 {
  font-size: clamp(1.45rem, 2vw, 2rem);
  margin-bottom: 10px;
}

.lead,
.helper-text,
.form-feedback,
#statusMeta {
  color: var(--muted);
}

.lead {
  margin: 12px 0 0;
  max-width: 65ch;
  font-size: 1rem;
}

.helper-text,
.form-feedback {
  margin: 0;
}

.section-intro {
  margin: 8px 0 0;
}

.error-text {
  color: var(--danger);
}

.success-text {
  color: #bfd8a9;
}

.info-stack,
.notes-list {
  display: grid;
  gap: 12px;
  margin-top: 22px;
}

.info-card,
.note-card,
.stats-tile,
.server-chip,
.status-pill,
.tag-button,
.player-card,
.list-card {
  background: rgba(255, 248, 235, 0.04);
  border: 1px solid rgba(212, 181, 141, 0.16);
  border-radius: var(--radius-lg);
}

.info-card,
.note-card {
  padding: 15px 16px;
}

.featured-card {
  border-color: rgba(227, 192, 137, 0.38);
  background: linear-gradient(135deg, rgba(213, 163, 93, 0.16), rgba(122, 155, 99, 0.11));
}

.info-label {
  display: block;
  margin-bottom: 6px;
  color: var(--muted);
  font-size: 0.76rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.stack-form {
  display: grid;
  gap: 15px;
  margin-top: 22px;
}

.field {
  display: grid;
  gap: 8px;
}

.field span {
  color: #d9ebc5;
  font-weight: 700;
}

input,
select,
textarea {
  width: 100%;
  padding: 13px 14px;
  border: 1px solid rgba(165, 198, 151, 0.24);
  border-radius: var(--radius-md);
  background: rgba(13, 25, 18, 0.7);
  color: var(--text);
  outline: none;
  transition: border-color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease;
}

textarea {
  min-height: 110px;
  resize: vertical;
}

input::placeholder,
textarea::placeholder {
  color: #9bb391;
}

input:focus,
select:focus,
textarea:focus {
  border-color: var(--accent-soft);
  box-shadow: 0 0 0 3px rgba(155, 200, 115, 0.18);
}

select {
  appearance: none;
  padding-right: 40px;
  cursor: pointer;
  border-color: rgba(180, 220, 146, 0.36);
  box-shadow: inset 0 0 0 1px rgba(155, 200, 115, 0.16);
  background-image:
    linear-gradient(45deg, transparent 50%, #c2df9b 50%),
    linear-gradient(135deg, #c2df9b 50%, transparent 50%);
  background-position:
    calc(100% - 19px) 50%,
    calc(100% - 13px) 50%;
  background-size: 6px 6px, 6px 6px;
  background-repeat: no-repeat;
}

select option {
  background: #17281d;
  color: var(--text);
}

.platform-select {
  font-weight: 700;
  letter-spacing: 0.01em;
}

.button-row,
.section-heading,
.search-row,
.status-top,
.info-row,
.server-chip-row,
.status-pill-row,
.stats-tile-grid,
.donation-grid,
.content-grid,
.clean-list,
.info-list,
.player-list,
#leaderboardList,
#playtimeLeaderboard,
.roster-preview {
  position: relative;
  z-index: 1;
}

.button-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

.button-row.center {
  justify-content: flex-start;
}

.button-row .helper-text {
  flex: 1 1 220px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 18px;
  border: 1px solid transparent;
  border-radius: 10px;
  cursor: pointer;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease, background 0.18s ease;
}

.btn:hover {
  transform: translateY(-1px);
}

.btn.primary {
  background: linear-gradient(180deg, #8abf5f, #5e8d41);
  color: #f2ffe5;
  border-color: rgba(198, 230, 164, 0.42);
  box-shadow: 0 12px 24px rgba(20, 44, 18, 0.34), 0 0 0 1px rgba(22, 47, 18, 0.44), 3px 3px 0 rgba(11, 22, 10, 0.38);
}

.btn.secondary {
  background: rgba(224, 244, 204, 0.08);
  border-color: rgba(168, 198, 143, 0.24);
  color: var(--text);
  box-shadow: 0 0 0 1px rgba(22, 39, 27, 0.3), 2px 2px 0 rgba(8, 14, 10, 0.24);
}

.btn.secondary:hover {
  background: rgba(224, 244, 204, 0.14);
}

.btn:disabled,
.btn.is-disabled,
.btn[aria-disabled="true"] {
  opacity: 0.6;
  cursor: not-allowed;
  pointer-events: none;
  box-shadow: none;
  transform: none;
}

.hero-header {
  position: relative;
  overflow: hidden;
  padding: 46px 0 32px;
  border-bottom: 1px solid rgba(171, 201, 143, 0.18);
}

.header-overlay {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at top center, rgba(196, 226, 159, 0.18), transparent 36%),
    linear-gradient(180deg, rgba(10, 20, 13, 0.16), rgba(10, 20, 13, 0.6));
}

.header-content,
.container {
  position: relative;
  z-index: 1;
}

.header-content {
  width: min(var(--max-width), calc(100% - 32px));
  margin: 0 auto;
  display: grid;
  gap: 18px;
}

.logo {
  width: 88px;
  height: 88px;
  border-radius: 20px;
  border: 1px solid rgba(174, 206, 146, 0.26);
  background: rgba(229, 245, 211, 0.08);
  padding: 10px;
}

.announcement-banner,
.status-panel,
.donation-callout {
  padding: 14px 16px;
  border: 1px solid rgba(169, 201, 142, 0.24);
  border-radius: var(--radius-lg);
  background: rgba(222, 242, 199, 0.06);
}

.announcement-banner {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 12px;
  align-items: start;
}

.announcement-banner p {
  margin: 0;
}

.announcement-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 56px;
  height: 32px;
  border-radius: 999px;
  background: rgba(136, 187, 98, 0.32);
  color: #efffe1;
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
}

.server-chip-row {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.server-chip,
.status-pill,
.stats-tile,
.tag-button {
  padding: 14px 16px;
  box-shadow: 0 0 0 1px rgba(18, 35, 24, 0.24), 2px 2px 0 rgba(8, 15, 11, 0.24);
}

.status-panel {
  display: grid;
  gap: 14px;
}

.status-top {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
}

.status-bar {
  height: 12px;
  border-radius: 999px;
  background: rgba(227, 245, 210, 0.08);
  overflow: hidden;
  border: 1px solid rgba(170, 202, 144, 0.16);
}

.status-fill {
  width: 30%;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #4f7440 0 33%, #79a75a 33% 66%, #c4e09f 66% 100%);
}

.status-fill.online {
  background: linear-gradient(90deg, #5a8247 0 33%, #7eae5c 33% 66%, #d8edb6 66% 100%);
}

.status-pill-row,
.stats-tile-grid,
.content-grid,
.donation-grid {
  display: grid;
  gap: 14px;
}

.status-pill-row {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.container {
  padding: 28px 0 60px;
}

.content-grid {
  margin-top: var(--section-gap);
}

.intro-grid {
  grid-template-columns: repeat(2, minmax(320px, 1fr));
  align-items: stretch;
}

.two-up {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.section-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 16px;
}

.section-heading.tight-top {
  margin-top: 18px;
  margin-bottom: 12px;
}

.subheading {
  font-size: clamp(1.15rem, 1.6vw, 1.45rem);
  margin: 0;
}

.info-list,
.clean-list,
.notes-list,
.player-list,
#leaderboardList,
#playtimeLeaderboard,
.roster-preview {
  display: grid;
  gap: 12px;
}

.info-row {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  padding: 12px 0;
  border-bottom: 1px solid rgba(212, 181, 141, 0.12);
}

.info-row:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}

.info-row span {
  color: var(--muted);
}

.clean-list {
  margin: 0;
  padding-left: 20px;
}

.clean-list li + li {
  margin-top: 10px;
}

.stats-tile-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.intro-grid .stats-tile-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.stats-tile-grid.wide {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-top: 18px;
}

.note-card {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: center;
  flex-wrap: wrap;
}

.note-card span:last-child,
.note-card strong:last-child {
  text-align: right;
}

.note-card strong:first-child,
.note-card span:first-child {
  flex: 1 1 180px;
}

.note-card span:last-child,
.note-card strong:last-child {
  flex: 1 1 180px;
}

.search-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
  margin-top: 14px;
}

.player-list,
#leaderboardList,
#playtimeLeaderboard,
.roster-preview {
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
}

.player-item,
.directory-row,
.leaderboard-row {
  width: 100%;
  min-height: 54px;
  padding: 14px 16px;
  border-radius: var(--radius-lg);
  border: 1px solid rgba(212, 181, 141, 0.14);
  background: rgba(255, 248, 235, 0.04);
}

.player-item {
  color: var(--text);
  text-align: left;
  cursor: pointer;
  transition: border-color 0.18s ease, background 0.18s ease, transform 0.18s ease;
}

.player-item:hover,
.tag-button:hover {
  border-color: rgba(189, 220, 153, 0.4);
  background: rgba(227, 245, 210, 0.12);
  transform: translateY(-1px);
}

.directory-row,
.leaderboard-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.directory-row span,
.leaderboard-row span:first-child {
  min-width: 0;
}

.directory-row span:first-child,
.leaderboard-row span:first-child,
.stats-tile strong,
.server-chip strong,
.status-pill,
.info-card strong,
.note-card strong,
.donation-callout strong {
  overflow-wrap: anywhere;
}

.tag-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  color: var(--text);
  background: rgba(255, 248, 235, 0.05);
  border: 1px solid rgba(212, 181, 141, 0.14);
}

.member-donation-panel {
  margin-top: 18px;
}

.donation-grid {
  grid-template-columns: 1fr;
  align-items: start;
  gap: 12px;
}

.donation-panel .section-heading {
  margin-bottom: 0;
  align-items: center;
}

.donation-panel h2 {
  margin-bottom: 0;
}

.donation-callout {
  gap: 4px;
}

.donation-callout strong,
.donation-callout span {
  display: block;
}

.donation-callout span {
  display: none;
  font-size: 0.95rem;
}

.compact-info-list,
.donation-status {
  display: none;
}

.map-frame {
  width: 100%;
  min-height: 520px;
  margin-top: 14px;
  border: 1px solid rgba(166, 196, 139, 0.2);
  border-radius: 18px;
  background: #122119;
}

.site-footer {
  margin: 0 auto 34px;
  padding-top: 14px;
  color: var(--muted);
  text-align: center;
}

#playerList > *,
#leaderboardList > *,
#playtimeLeaderboard > *,
#rosterPreview > * {
  padding: 14px 16px;
  border-radius: var(--radius-lg);
  border: 1px solid rgba(212, 181, 141, 0.14);
  background: rgba(255, 248, 235, 0.04);
}

@media (max-width: 1120px) {
  .two-up,
  .donation-grid {
    grid-template-columns: 1fr 1fr;
  }

  .stats-tile-grid,
  .stats-tile-grid.wide {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 900px) {
  .auth-layout,
  .intro-grid,
  .two-up,
  .donation-grid,
  .server-chip-row,
  .status-pill-row,
  .stats-tile-grid,
  .stats-tile-grid.wide {
    grid-template-columns: 1fr;
  }

  .section-heading,
  .status-top,
  .note-card,
  .info-row,
  .directory-row,
  .leaderboard-row {
    grid-template-columns: 1fr;
    display: grid;
    align-items: start;
  }

  .note-card strong:last-child,
  .note-card span:last-child {
    text-align: left;
  }

  .btn {
    width: 100%;
  }

  .footer-heading .btn {
    width: 100%;
  }

  .button-row.center {
    justify-content: flex-start;
  }

  .search-row {
    grid-template-columns: 1fr;
  }

  .map-frame {
    min-height: 380px;
  }

  .donation-footer {
    padding-block: 14px;
  }

  .donation-panel {
    gap: 10px;
  }

  .donation-panel .section-heading {
    gap: 10px;
  }

  .donation-callout {
    padding: 12px 14px;
  }

  .donation-status {
    font-size: 0.84rem;
  }
}

@media (max-width: 560px) {
  .auth-screen,
  .container,
  .hero-header {
    padding-left: 0;
    padding-right: 0;
  }

  .auth-layout,
  .header-content,
  .container,
  .site-footer,
  .public-donation-footer {
    width: min(var(--max-width), calc(100% - 20px));
  }

  .panel {
    padding: 18px;
    border-radius: 18px;
  }

  .donation-footer {
    padding-block: 12px;
  }

  .public-donation-footer,
  .member-donation-panel {
    margin-top: 14px;
  }

  .donation-panel {
    gap: 8px;
  }

  .donation-panel .eyebrow {
    margin-bottom: 8px;
    padding: 5px 10px;
  }

  .donation-panel h2 {
    font-size: 1.3rem;
  }

  .donation-callout {
    padding: 10px 12px;
    border-radius: 14px;
  }

  .donation-callout strong {
    font-size: 0.95rem;
  }

  .donation-callout span {
    display: none;
    font-size: 0.88rem;
  }

  .compact-info-list,
  .donation-status {
    display: none;
  }

  .donation-panel .btn {
    min-height: 42px;
  }

  .donation-status {
    font-size: 0.8rem;
  }

  h1 {
    font-size: 2.2rem;
  }

  .button-row,
  .footer-heading {
    align-items: stretch;
  }

  .announcement-banner {
    grid-template-columns: 1fr;
  }

  .note-card span:last-child,
  .note-card strong:last-child {
    text-align: left;
  }
}
