:root {
  color-scheme: dark;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: #0c1014;
  color: #f5f7f9;

  --bg: #0c1014;
  --bg-raised: #14191f;
  --bg-card: #161c23;
  --bg-input: #131920;
  --border: #262f38;
  --border-strong: #33404c;
  --text: #f5f7f9;
  --text-dim: #a4b0bb;
  --text-muted: #7c8893;
  --accent: #36c27f;
  --accent-hover: #45d690;
  --accent-soft: rgba(54, 194, 127, 0.16);
  --accent-strong: #1f9d67;
  --danger: #ff7474;
  --shadow-card: 0 8px 24px rgba(0, 0, 0, 0.28);
  --shadow-lift: 0 14px 36px rgba(0, 0, 0, 0.42);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--bg);
}

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

button,
.download-cta {
  border: 1px solid var(--border-strong);
  background: #1b232b;
  color: var(--text);
  min-height: 38px;
  border-radius: 7px;
  padding: 0 13px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  cursor: pointer;
  transition: background 120ms ease, border-color 120ms ease, transform 120ms ease;
}

button:hover,
.download-cta:hover {
  border-color: #5b7386;
  background: #24303a;
}

button:disabled,
button:disabled:hover {
  cursor: not-allowed;
  opacity: 0.5;
  transform: none;
  box-shadow: none;
}

input,
select,
textarea {
  border: 1px solid var(--border-strong);
  background: var(--bg-input);
  color: var(--text);
  min-height: 40px;
  border-radius: 7px;
  padding: 0 12px;
}

input:focus,
select:focus,
textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
}

.btn {
  border-radius: 8px;
  min-height: 42px;
  padding: 0 18px;
  font-weight: 600;
  font-size: 14px;
  letter-spacing: 0.1px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: background 120ms ease, border-color 120ms ease, transform 120ms ease, box-shadow 120ms ease;
}

.btn-primary {
  background: var(--accent);
  border: 1px solid var(--accent);
  color: #062019;
  box-shadow: 0 6px 18px rgba(54, 194, 127, 0.22);
}

.btn-primary:hover {
  background: var(--accent-hover);
  border-color: var(--accent-hover);
  transform: translateY(-1px);
}

.btn-primary:active {
  transform: translateY(0);
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-strong);
  color: var(--text);
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: #5b7386;
}

.btn-ghost {
  background: transparent;
  border: 1px solid transparent;
  color: var(--text-dim);
  min-height: 38px;
  padding: 0 12px;
}

.btn-ghost:hover {
  color: var(--text);
  background: rgba(255, 255, 255, 0.04);
}

.link-btn {
  background: transparent;
  border: none;
  color: var(--text-dim);
  padding: 4px 0;
  min-height: 0;
  cursor: pointer;
  font-size: 13px;
}

.link-btn:hover {
  color: var(--accent);
  background: transparent;
  border-color: transparent;
}

.hidden {
  display: none !important;
}

.global-notice {
  position: sticky;
  top: 0;
  z-index: 30;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin: 10px auto 0;
  max-width: 1180px;
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: rgba(13, 22, 31, 0.96);
  color: var(--text);
  box-shadow: 0 16px 35px rgba(0, 0, 0, 0.25);
}

.global-notice.success {
  border-color: rgba(54, 194, 127, 0.42);
  background: rgba(19, 54, 40, 0.96);
}

.global-notice.muted {
  color: var(--text-muted);
}

.global-notice button {
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.06);
  color: var(--text);
  border-radius: 8px;
  padding: 6px 10px;
}

.accent {
  color: var(--accent);
}

textarea {
  min-height: 120px;
  padding: 10px 12px;
  resize: vertical;
}

.shell {
  min-height: 100vh;
}

.topbar {
  min-height: 64px;
  border-bottom: 1px solid var(--border);
  background: rgba(20, 25, 31, 0.92);
  backdrop-filter: blur(14px);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 clamp(18px, 4vw, 56px);
  position: sticky;
  top: 0;
  z-index: 5;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 42px;
  min-width: 0;
}

.brand-mark {
  width: 32px;
  height: 32px;
  flex: 0 0 auto;
}

.brand {
  text-decoration: none;
  color: inherit;
}

.brand strong {
  display: block;
  font-size: 17px;
  font-weight: 800;
  letter-spacing: -0.2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  color: var(--text);
}

.brand-tld {
  color: var(--accent);
  font-weight: 700;
}

nav {
  display: flex;
  gap: 4px;
}

nav button,
nav a {
  background: transparent;
  border-color: transparent;
  color: #b8c1ca;
}

nav .nav-utility {
  font-size: 13px;
  min-height: 34px;
  padding: 0 11px;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid transparent;
  border-radius: 7px;
}

nav button:hover,
nav a:hover {
  background: #1e2831;
  border-color: transparent;
  color: #ffffff;
}

main {
  width: min(1180px, calc(100% - 36px));
  margin: 0 auto;
  padding: 18px 0 54px;
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
  align-items: stretch;
  gap: 28px;
  margin: 36px 0 32px;
}

.hero-text {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 18px;
  min-width: 0;
}

.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  align-self: flex-start;
  border: 1px solid var(--border-strong);
  background: rgba(54, 194, 127, 0.08);
  color: var(--accent);
  border-radius: 999px;
  padding: 5px 12px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.3px;
  text-transform: uppercase;
}

.hero-eyebrow .dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 4px var(--accent-soft);
}

.hero-text h1 {
  margin: 0;
  font-size: clamp(32px, 4.6vw, 52px);
  line-height: 1.05;
  letter-spacing: -0.6px;
  font-weight: 800;
  color: #fbfdff;
}

.hero-sub {
  margin: 0;
  max-width: 620px;
  font-size: 16px;
  line-height: 1.55;
  color: var(--text-dim);
}

.hero-cta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 4px;
}

.hero-banner {
  position: relative;
  min-height: 320px;
  border: 1px solid #2b3a45;
  border-radius: 14px;
  background:
    linear-gradient(135deg, rgba(20, 27, 34, 0.96), rgba(11, 15, 20, 0.86)),
    radial-gradient(circle at 20% 15%, rgba(84, 200, 220, 0.16), transparent 28%);
  overflow: hidden;
  padding: 22px;
  box-shadow: var(--shadow-card);
}

.stats-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  border: 1px solid var(--border);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.02), rgba(255, 255, 255, 0));
  border-radius: 12px;
  padding: 18px 20px;
  margin: 0 0 32px;
}

.stats-strip .stat {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}

.stats-strip .stat strong {
  font-size: 28px;
  font-weight: 800;
  letter-spacing: -0.4px;
  color: var(--text);
}

.stats-strip .stat span {
  font-size: 12px;
  font-weight: 500;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.6px;
}

.featured-games {
  margin: 0 0 36px;
}

.featured-games-grid {
  display: flex;
  gap: 12px;
  margin: 0 -2px;
  padding: 0 2px 10px;
  overflow-x: auto;
  overflow-y: hidden;
  overscroll-behavior-x: contain;
  scroll-padding-inline: 2px;
  scroll-snap-type: x proximity;
  scrollbar-color: rgba(91, 115, 134, 0.8) transparent;
  scrollbar-width: thin;
}

.featured-games-grid::-webkit-scrollbar {
  height: 8px;
}

.featured-games-grid::-webkit-scrollbar-track {
  background: transparent;
}

.featured-games-grid::-webkit-scrollbar-thumb {
  background: rgba(91, 115, 134, 0.72);
  border-radius: 999px;
}

.game-tile-card {
  position: relative;
  display: block;
  flex: 0 0 clamp(170px, 15vw, 190px);
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
  cursor: pointer;
  text-align: left;
  padding: 0;
  background: var(--bg-card);
  min-height: 120px;
  scroll-snap-align: start;
  transition: transform 140ms ease, border-color 140ms ease, box-shadow 140ms ease;
}

.game-tile-card:hover {
  transform: translateY(-2px);
  border-color: var(--accent);
  box-shadow: var(--shadow-lift);
  background: var(--bg-card);
}

.game-tile-card .game-tile-art {
  position: relative;
  width: 100%;
  height: 88px;
  background: linear-gradient(135deg, #2a3744, #161e26);
  background-size: cover;
  background-position: center;
}

.game-tile-card .game-tile-art::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(8, 12, 16, 0.78), transparent 60%);
}

.game-tile-wordmark {
  position: absolute;
  inset: 0;
  z-index: 1;
  display: grid;
  place-items: center;
  text-align: center;
  padding: 0 10px;
  color: #ffffff;
  font-size: 18px;
  font-weight: 800;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.55);
  line-height: 1.05;
  pointer-events: none;
}

.game-tile-card .game-tile-meta {
  padding: 10px 12px 12px;
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.game-tile-card .game-tile-meta strong {
  font-size: 14px;
  font-weight: 700;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.game-tile-card .game-tile-meta span {
  font-size: 12px;
  color: var(--text-muted);
}

.section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 14px;
}

.section-head h2 {
  margin: 0;
  font-size: 18px;
  font-weight: 700;
  letter-spacing: -0.2px;
  color: var(--text);
}

.section-hint {
  font-size: 13px;
  color: var(--text-muted);
}

.content-section {
  margin: 0 0 40px;
}

.search-field {
  position: relative;
  display: flex;
  align-items: center;
  min-width: 0;
}

.search-field .search-icon {
  position: absolute;
  left: 12px;
  font-size: 16px;
  color: var(--text-muted);
  pointer-events: none;
}

.search-field input {
  width: 100%;
  padding-left: 36px;
  padding-right: 44px;
}

.empty-state {
  border: 1px solid var(--border);
  background: linear-gradient(180deg, rgba(54, 194, 127, 0.06), rgba(54, 194, 127, 0));
  border-radius: 14px;
  padding: 36px 28px;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  margin-top: 16px;
}

.empty-state-icon {
  width: 56px;
  height: 56px;
  border-radius: 14px;
  background: var(--accent-soft);
  color: var(--accent);
  display: grid;
  place-items: center;
  font-size: 28px;
  font-weight: 800;
}

.empty-state h3 {
  margin: 0;
  font-size: 18px;
  font-weight: 700;
}

.empty-state p {
  margin: 0;
  max-width: 540px;
  color: var(--text-dim);
  font-size: 14px;
  line-height: 1.55;
}

.empty-state-cta {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 6px;
  justify-content: center;
}

.site-footer {
  border-top: 1px solid var(--border);
  margin-top: 24px;
  padding: 24px clamp(18px, 4vw, 56px);
  background: var(--bg-raised);
}

.footer-inner {
  width: min(1180px, 100%);
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 18px;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 12px;
}

.footer-brand img {
  width: 32px;
  height: 32px;
}

.footer-brand strong {
  display: block;
  font-size: 14px;
  font-weight: 700;
}

.footer-brand small {
  display: block;
  margin-top: 2px;
  font-size: 12px;
  color: var(--text-muted);
}

.footer-links {
  display: flex;
  gap: 18px;
  flex-wrap: wrap;
}

.download-app-card {
  min-height: 100%;
  border-color: rgba(54, 194, 127, 0.55);
  background:
    linear-gradient(145deg, rgba(31, 157, 103, 0.28), rgba(24, 31, 38, 0.96)),
    radial-gradient(circle at 50% 20%, rgba(104, 220, 255, 0.22), transparent 42%);
  box-shadow: 0 22px 48px rgba(0, 0, 0, 0.28);
  display: grid;
  align-content: center;
  justify-items: start;
  gap: 16px;
  text-align: left;
  padding: 22px;
}

.download-app-card:hover {
  border-color: #36c27f;
  background:
    linear-gradient(145deg, rgba(31, 157, 103, 0.36), rgba(28, 38, 46, 0.98)),
    radial-gradient(circle at 50% 20%, rgba(104, 220, 255, 0.28), transparent 42%);
}

.download-app-card img {
  width: 74px;
  height: 74px;
  border-radius: 18px;
}

.download-app-card strong,
.download-app-card small {
  display: block;
}

.download-app-card strong {
  font-size: 24px;
  font-weight: 900;
}

.download-app-card small {
  color: #b8c6d0;
  margin-top: 5px;
}

.hero-banner {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr);
  grid-template-rows: 1fr 1fr;
  gap: 10px;
  min-height: 280px;
  padding: 0;
}

.hero-tile {
  position: relative;
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
  background-color: #14191f;
  background-size: cover;
  background-position: center;
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.32);
  isolation: isolate;
  display: flex;
  align-items: flex-end;
  padding: 12px 14px;
}

.hero-tile::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(8, 12, 16, 0) 0%, rgba(8, 12, 16, 0) 45%, rgba(8, 12, 16, 0.85) 100%);
  z-index: 0;
}

.hero-tile-feature {
  grid-column: 1;
  grid-row: 1 / span 2;
  min-height: 280px;
}

.hero-tile-secondary {
  grid-column: 2;
  min-height: 0;
}

.hero-tile-name {
  position: relative;
  z-index: 1;
  color: #ffffff;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.6);
}

.hero-tile-feature .hero-tile-name {
  font-size: 18px;
}

.quick-actions {
  border: 1px solid #28333d;
  background: #141b22;
  border-radius: 8px;
  padding: 10px;
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}

.quick-actions span {
  color: #9aa8b4;
  font-size: 13px;
}

.view-tabs {
  border: 1px solid #28333d;
  background: #141b22;
  border-radius: 8px;
  padding: 4px;
  margin-bottom: 10px;
  display: inline-flex;
  gap: 4px;
}

.view-tabs button {
  min-height: 34px;
  border-color: transparent;
  background: transparent;
  color: #aab6c0;
  font-weight: 600;
}

.view-tabs button:hover {
  background: #1c252e;
  border-color: transparent;
  color: #d6e0e8;
}

.view-tabs button.active {
  background: #25313b;
  border-color: #3a4a57;
  color: #ffffff;
  box-shadow: inset 0 -2px 0 #36c27f;
}

.toolbar {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 180px;
  gap: 10px;
  margin-bottom: 8px;
}

.hidden {
  display: none !important;
}

dialog:not([open]) {
  display: none;
}

.bug-panel {
  border: 1px solid #33404c;
  background: #12181e;
  border-radius: 10px;
  padding: 0;
}

.bug-panel h2 {
  margin: 0;
  font-size: 16px;
}

.bug-form {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  padding: 16px;
}

.bug-form label {
  display: grid;
  gap: 5px;
  color: #aab6c0;
  font-size: 12px;
}

.bug-form .span-all {
  grid-column: 1 / -1;
}

.bug-form.no-impact #bug-category-field {
  grid-column: 1 / -1;
}

#bug-status {
  color: #a8b5c1;
  font-size: 12px;
  align-self: center;
}

dialog.account-panel {
  width: min(720px, calc(100% - 34px));
}

.account-panel .account-grid {
  padding: 16px;
}

.account-grid {
  display: grid;
  grid-template-columns: minmax(280px, 0.9fr) minmax(360px, 1.1fr);
  gap: 14px;
}

.account-card {
  border: 1px solid var(--border);
  background: var(--bg-card);
  border-radius: 10px;
  padding: 16px;
  display: grid;
  gap: 10px;
}

.account-card.account-wide {
  grid-column: 1 / -1;
}

.account-card h2,
.account-card h3 {
  margin: 0;
}

.account-card p {
  margin: 0;
  color: var(--text-dim);
  font-size: 13px;
}
.account-auth {
  padding: 18px 20px 22px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.auth-banner {
  border: 1px solid rgba(54, 194, 127, 0.4);
  background: rgba(54, 194, 127, 0.08);
  color: var(--text);
  border-radius: 8px;
  padding: 10px 12px;
  font-size: 13px;
}

.auth-tagline {
  margin: 0;
  color: var(--text-dim);
  font-size: 14px;
  line-height: 1.5;
}

.auth-providers {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.auth-provider {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  min-height: 46px;
  padding: 0 14px;
  border: 1px solid var(--border-strong);
  background: var(--bg-card);
  color: var(--text);
  border-radius: 9px;
  font-weight: 600;
  font-size: 14px;
  cursor: pointer;
  position: relative;
}

.auth-provider:hover {
  border-color: var(--accent);
  background: rgba(54, 194, 127, 0.05);
}

.auth-provider-icon {
  width: 24px;
  height: 24px;
  display: grid;
  place-items: center;
  background: #ffffff;
  border-radius: 6px;
  flex: 0 0 24px;
}

.auth-provider-icon svg {
  display: block;
}

.auth-provider-icon img {
  width: 24px;
  height: 24px;
  display: block;
  border-radius: 6px;
  object-fit: cover;
}

.auth-google .auth-provider-icon {
  background: #ffffff;
}

.auth-discord .auth-provider-icon {
  background: #5865f2;
  color: #ffffff;
}

.auth-discord:hover {
  border-color: #7f8cff;
  background: rgba(88, 101, 242, 0.12);
}

.auth-guest .auth-provider-icon {
  background: rgba(54, 194, 127, 0.16);
  color: var(--accent);
}

.auth-guest:hover {
  border-color: var(--accent);
  background: rgba(54, 194, 127, 0.1);
}

.auth-captcha-wrap {
  display: flex;
  justify-content: center;
  min-height: 65px;
}

.auth-captcha {
  max-width: 100%;
}

.auth-provider-tag {
  position: absolute;
  right: 14px;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.6px;
  text-transform: uppercase;
  color: var(--text-muted);
  background: rgba(255, 255, 255, 0.06);
  padding: 3px 8px;
  border-radius: 999px;
}

.auth-email {
  border: 1px solid var(--border);
  border-radius: 9px;
  padding: 10px 12px;
}

.auth-email summary {
  cursor: pointer;
  font-size: 13px;
  color: var(--text-dim);
  font-weight: 500;
  list-style: none;
  user-select: none;
}

.auth-email summary::after {
  content: " ▾";
  color: var(--text-muted);
}

.auth-email[open] summary::after {
  content: " ▴";
}

.auth-email .form-grid {
  margin-top: 10px;
}

.auth-status {
  display: block;
  margin-top: 8px;
  font-size: 12px;
  color: var(--text-dim);
}

.form-note {
  margin: -2px 0 0;
  color: var(--text-muted);
  font-size: 12px;
  line-height: 1.45;
}

.auth-fineprint {
  margin: 0;
  font-size: 11px;
  color: var(--text-muted);
  text-align: center;
}
.account-body {
  padding: 18px 20px 22px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.profile-card {
  border: 1px solid var(--border);
  background: linear-gradient(180deg, rgba(54, 194, 127, 0.04), transparent 40%), var(--bg-card);
  border-radius: 12px;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.guest-upload-card {
  border-color: rgba(54, 194, 127, 0.34);
}

.guest-upload-card strong {
  display: block;
  margin-bottom: 6px;
  font-size: 16px;
}

.guest-upload-card p {
  margin: 0;
  color: var(--text-dim);
  font-size: 14px;
  line-height: 1.5;
}

.profile-card-header {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 14px;
  align-items: start;
}

.avatar.xlarge {
  width: 72px;
  height: 72px;
  border-radius: 16px;
  font-size: 22px;
  font-weight: 700;
  display: grid;
  place-items: center;
  flex: 0 0 72px;
  overflow: hidden;
  background: linear-gradient(135deg, var(--tone-a, #2e6c86), var(--tone-b, #162733));
  position: relative;
}

.avatar.xlarge img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.profile-card-fields {
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-width: 0;
}

.profile-card-fields label {
  display: flex;
  flex-direction: column;
  gap: 4px;
  color: var(--text-muted);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.4px;
  text-transform: uppercase;
}

.profile-card-fields input {
  font-size: 15px;
  font-weight: 600;
  color: var(--text);
  text-transform: none;
  letter-spacing: 0;
}

.profile-extras {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 10px;
}

.profile-extra {
  display: flex;
  flex-direction: column;
  gap: 5px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.4px;
  text-transform: uppercase;
  color: var(--text-muted);
}

.profile-extra select,
.profile-extra input {
  text-transform: none;
  letter-spacing: 0;
  font-weight: 500;
  font-size: 13px;
  color: var(--text);
}

.avatar-actions {
  display: flex;
  gap: 6px;
  align-items: center;
}

.avatar-actions input[type="file"] {
  flex: 1;
  min-width: 0;
}

.avatar-actions .ghost {
  background: transparent;
  border-color: var(--border-strong);
  color: var(--text-dim);
  min-height: 36px;
}

.profile-card-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.profile-section {
  border: 1px solid var(--border);
  background: var(--bg-card);
  border-radius: 12px;
  padding: 16px;
}

.profile-section[open] {
  background: var(--bg-card);
}

.profile-section summary {
  list-style: none;
  cursor: pointer;
  display: flex;
  align-items: baseline;
  gap: 8px;
  flex-wrap: wrap;
}

.profile-section summary::after {
  content: "▾";
  color: var(--text-muted);
  margin-left: auto;
  font-size: 12px;
}

.profile-section[open] summary::after {
  content: "▴";
}

.profile-section summary strong {
  font-size: 15px;
  font-weight: 700;
}

.profile-section summary span {
  font-size: 12px;
  color: var(--text-muted);
}

.profile-section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
}

.profile-section-head strong {
  font-size: 15px;
  font-weight: 700;
}

.profile-section-head span {
  font-size: 12px;
  color: var(--text-muted);
}

.profile-section .form-grid,
.profile-section .form-actions {
  margin-top: 12px;
}

.profile-section .empty-line {
  margin: 0;
  color: var(--text-dim);
  font-size: 13px;
}

.upload-wizard {
  margin-top: 14px;
  display: grid;
  gap: 14px;
}

.upload-steps {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.upload-steps span {
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 7px 10px;
  color: var(--text-muted);
  font-size: 12px;
  text-align: center;
  background: rgba(255, 255, 255, 0.02);
}

.upload-steps span.active {
  border-color: rgba(54, 194, 127, 0.55);
  color: var(--accent);
  background: rgba(54, 194, 127, 0.1);
}

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

.upload-game-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(168px, 1fr));
  gap: 10px;
  max-height: 360px;
  overflow: auto;
  padding-right: 4px;
}

.upload-game-option {
  min-height: 154px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--bg);
  color: var(--text);
  display: grid;
  grid-template-rows: 68px minmax(76px, 1fr);
  text-align: left;
  padding: 0;
  cursor: pointer;
  overflow: hidden;
  min-width: 0;
}

.upload-game-option:hover,
.upload-game-option.selected {
  border-color: rgba(54, 194, 127, 0.65);
  background: rgba(54, 194, 127, 0.08);
}

.upload-game-art {
  display: block;
  width: 100%;
  min-height: 68px;
  background: linear-gradient(135deg, var(--tone-a), var(--tone-b));
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.upload-game-copy {
  display: grid;
  align-content: start;
  gap: 5px;
  min-width: 0;
  padding: 10px 11px 12px;
}

.upload-game-option strong {
  display: -webkit-box;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  line-height: 1.18;
  min-height: 2.36em;
  overflow-wrap: anywhere;
}

.upload-game-copy span {
  color: var(--text-muted);
  font-size: 12px;
  line-height: 1.2;
  white-space: nowrap;
}

.upload-guide {
  border: 1px solid var(--border);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.025);
  padding: 12px;
  display: grid;
  gap: 5px;
}

.upload-guide span {
  color: var(--text-dim);
  font-size: 13px;
  line-height: 1.4;
}

.upload-source-choice {
  display: inline-grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 4px;
  width: min(100%, 390px);
  padding: 4px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.035);
}

.upload-source-option {
  position: relative;
  min-height: 42px;
  border: 1px solid transparent;
  border-radius: 999px;
  padding: 0 16px;
  background: transparent;
  color: var(--text-dim);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  transition: background 140ms ease, border-color 140ms ease, color 140ms ease, box-shadow 140ms ease;
}

.upload-source-option input {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
}

.upload-source-option:hover {
  color: var(--text);
  background: rgba(255, 255, 255, 0.045);
}

.upload-source-option.selected,
.upload-source-option:has(input:checked) {
  border-color: rgba(54, 194, 127, 0.52);
  background: rgba(54, 194, 127, 0.16);
  color: #b9ffe1;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.18);
}

.upload-source-option input:focus-visible + span {
  outline: 2px solid rgba(54, 194, 127, 0.65);
  outline-offset: 5px;
}

.upload-source-panel label {
  display: grid;
  gap: 6px;
}

.upload-file-label {
  color: #f4f7fb;
  font-weight: 700;
}

.file-upload-control {
  position: relative;
  min-height: 42px;
  border: 1px solid var(--border-strong);
  border-radius: 8px;
  background: rgba(7, 11, 16, 0.38);
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 5px 12px 5px 5px;
  overflow: hidden;
}

.file-upload-control:hover {
  border-color: rgba(54, 194, 127, 0.42);
}

.file-upload-control input[type="file"] {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
}

.file-upload-button {
  min-height: 30px;
  padding: 0 13px;
  border: 1px solid var(--border-strong);
  border-radius: 6px;
  background: #1b232b;
  color: var(--text);
  display: inline-grid;
  place-items: center;
  font-size: 13px;
  font-weight: 700;
  line-height: 1;
  flex: 0 0 auto;
}

.file-upload-name {
  min-width: 0;
  color: var(--text-dim);
  font-size: 13px;
  font-weight: 500;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.upload-tag-presets {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.upload-tag-presets button {
  min-height: 30px;
  border-radius: 999px;
  border: 1px solid var(--tag-border, var(--border));
  background: var(--tag-bg, var(--bg));
  color: var(--tag-color, var(--text-dim));
  padding: 0 10px;
}

.upload-tag-presets button.selected {
  border-color: var(--tag-border);
  color: var(--tag-color);
  background: var(--tag-bg);
  box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.06) inset;
}

.upload-status {
  min-height: 18px;
  margin: 0;
  color: var(--text-muted);
  font-size: 12px;
}

.upload-status.success {
  color: var(--accent);
}

.upload-status.error {
  color: #ff9f9f;
}

.upload-sanitize-summary {
  border: 1px solid var(--border);
  border-radius: 9px;
  background: rgba(255, 255, 255, 0.025);
  padding: 10px 12px;
  display: grid;
  gap: 8px;
  font-size: 12px;
  color: var(--text-muted);
}

.upload-sanitize-summary.hidden {
  display: none;
}

.sanitize-counts {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.sanitize-counts span {
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 4px 8px;
  background: rgba(255, 255, 255, 0.03);
}

.sanitize-counts strong {
  color: var(--text);
}

.sanitize-list {
  list-style: none;
  padding: 0;
  margin: 8px 0 0;
  display: grid;
  gap: 5px;
  max-height: 150px;
  overflow: auto;
}

.sanitize-list li {
  display: flex;
  gap: 8px;
  justify-content: space-between;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  padding-top: 5px;
}

.sanitize-list code {
  color: var(--text-dim);
  word-break: break-all;
}

.upload-wizard-actions {
  display: flex;
  gap: 8px;
  justify-content: flex-end;
}

.form-grid {
  display: grid;
  gap: 10px;
}

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

.form-grid label,
.form-grid .form-field {
  display: grid;
  gap: 5px;
  color: #aab6c0;
  font-size: 12px;
}

.form-grid .form-field > span {
  color: #aab6c0;
}

.form-grid .span-all {
  grid-column: 1 / -1;
}

.upload-tag-field small {
  color: var(--text-muted);
  font-size: 12px;
  line-height: 1.4;
}

.tag-picker {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.tag-picker button {
  min-height: 30px;
  padding: 0 10px;
  border-radius: 999px;
  border: 1px solid #33404c;
  background: #1d252d;
  color: #c7d4de;
  font-size: 12px;
}

.tag-picker button:hover {
  border-color: rgba(54, 194, 127, 0.45);
  background: rgba(54, 194, 127, 0.08);
}

.tag-picker button.active,
.tag-picker button[aria-pressed="true"] {
  border-color: rgba(54, 194, 127, 0.65);
  background: rgba(54, 194, 127, 0.16);
  color: #9dffd8;
}

.avatar-picker > div {
  border: 1px solid #2a3540;
  background: #111820;
  border-radius: 8px;
  padding: 10px;
  display: flex;
  align-items: center;
  gap: 12px;
}

.avatar-controls {
  min-width: 0;
  flex: 1;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) auto;
  gap: 8px;
}

.avatar-controls input[type="file"] {
  height: 40px;
  padding: 6px;
  min-width: 0;
  line-height: 1;
}

.avatar-controls input[type="file"]::file-selector-button {
  height: 28px;
  margin: 0 8px 0 0;
  border: 1px solid var(--border-strong);
  border-radius: 6px;
  background: #1b232b;
  color: var(--text);
  cursor: pointer;
}

.form-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.subtle-button {
  color: #a8b5c1;
}

.my-config-list {
  display: grid;
  gap: 9px;
}

.my-config-row {
  border: 1px solid #26333e;
  background: #101820;
  border-radius: 8px;
  padding: 10px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
}

.my-config-row strong,
.my-config-row small {
  display: block;
}

.my-config-row small {
  color: #8f9da9;
  margin-top: 4px;
}

.my-config-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
}

.my-config-actions select {
  width: 116px;
}

button.danger {
  border-color: #6e3b3e;
  color: #ffd6d6;
}

.status {
  color: #9aa8b4;
  margin: 8px 0 12px;
  font-size: 13px;
}

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 210px), 1fr));
  gap: 12px;
}

.card {
  border: 1px solid var(--border);
  background: var(--bg-card);
  border-radius: 12px;
  padding: 12px;
  min-width: 0;
  overflow: hidden;
  transition: transform 140ms ease, border-color 140ms ease, box-shadow 140ms ease;
}

.card.config-card,
.card.profile-card,
.card.game-card {
  cursor: pointer;
}

.card.config-card:hover,
.card.profile-card:hover,
.card.game-card:hover {
  transform: translateY(-2px);
  border-color: rgba(54, 194, 127, 0.55);
  box-shadow: var(--shadow-lift);
}

.card.config-card:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

.visual-card {
  display: grid;
  gap: 10px;
}

.card-art {
  --tone-a: #29556a;
  --tone-b: #1a2530;
  position: relative;
  min-height: 138px;
  border-radius: 7px;
  background:
    linear-gradient(145deg, color-mix(in srgb, var(--tone-a) 80%, #111820), var(--tone-b)),
    radial-gradient(circle at 24% 20%, rgba(255, 255, 255, 0.22), transparent 34%);
  display: grid;
  place-items: center;
  overflow: hidden;
}

.card-art::after,
.profile-banner::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 3;
  background:
    linear-gradient(to top, rgba(8, 12, 16, 0.76), transparent 62%),
    linear-gradient(115deg, rgba(255, 255, 255, 0.08), transparent 30%);
  pointer-events: none;
}

.art-image,
.card-art img,
.profile-banner img {
  position: absolute;
  inset: 0;
  z-index: 2;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.art-image[src=""] {
  display: none;
}

.art-initials {
  position: relative;
  z-index: 1;
  color: rgba(245, 247, 249, 0.92);
  font-size: 40px;
  font-weight: 900;
}

.card-art .upvote {
  position: absolute;
  right: 9px;
  top: 9px;
  z-index: 4;
  backdrop-filter: blur(10px);
  min-width: 56px;
  min-height: 32px;
  border-color: rgba(31, 125, 88, 0.7);
  background: rgba(15, 60, 46, 0.78);
  color: #b9ffe1;
  font-weight: 700;
  font-size: 14px;
  padding: 0 10px;
  gap: 4px;
}

.card-art .upvote[aria-pressed="true"] {
  background: #135041;
  color: #d4ffec;
  border-color: #62d6b5;
}

.creator-line {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.creator-line .meta {
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.avatar {
  --tone-a: #2c586c;
  --tone-b: #1d2835;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: linear-gradient(145deg, var(--tone-a), var(--tone-b));
  color: #f6fbff;
  display: grid;
  place-items: center;
  overflow: hidden;
  font-weight: 800;
}

.avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.avatar.small {
  flex: 0 0 auto;
  width: 26px;
  height: 26px;
  border-radius: 7px;
  font-size: 11px;
}

.avatar.large {
  width: 76px;
  height: 76px;
  border-radius: 12px;
  font-size: 24px;
  position: relative;
  z-index: 4;
}

.card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.card h2 {
  margin: 0 0 5px;
  font-size: 18px;
  letter-spacing: 0;
  line-height: 1.18;
}

.meta,
.description,
.stats {
  color: #a4b0bb;
  font-size: 13px;
}

.description {
  min-height: 0;
  margin: 8px 0 0;
}

.config-description {
  margin: -1px 0 2px;
  color: var(--text-muted);
  font-size: 13px;
  line-height: 1.35;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.dialog-description {
  margin: 6px 0 0;
  color: var(--text-muted);
  font-size: 13px;
  max-width: 680px;
}

.dialog-description.hidden {
  display: none;
}

.score {
  border: 1px solid #2b554e;
  color: #83f0d0;
  background: #10201e;
  border-radius: 999px;
  padding: 4px 9px;
  font-size: 12px;
  white-space: nowrap;
}

.tags,
.stats,
.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.stats {
  min-height: 18px;
}

.profile-card,
.game-card,
.config-card {
  cursor: pointer;
}

.profile-banner {
  --tone-a: #2f5b71;
  --tone-b: #111820;
  position: relative;
  min-height: 122px;
  border-radius: 7px;
  background:
    linear-gradient(145deg, var(--tone-a), var(--tone-b)),
    radial-gradient(circle at 28% 18%, rgba(137, 235, 255, 0.28), transparent 34%);
  display: flex;
  align-items: end;
  justify-content: space-between;
  padding: 12px;
  overflow: hidden;
}

.profile-banner .score {
  position: relative;
  z-index: 4;
  align-self: flex-start;
  backdrop-filter: blur(10px);
}

.profile-card h2,
.game-card h2 {
  margin-bottom: 0;
}

.profile-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.profile-stats span {
  border: 1px solid #2a3540;
  background: #111820;
  border-radius: 7px;
  min-height: 54px;
  min-width: 0;
  padding: 8px;
  display: grid;
  gap: 2px;
  color: #91a2b0;
  font-size: 12px;
}

.profile-stats strong {
  color: #f5f7f9;
  font-size: 17px;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.actions button[aria-pressed="true"] {
  border-color: #62d6b5;
  background: #12302b;
  color: #b7ffe7;
}

.upvote {
  min-width: 42px;
  font-weight: 900;
  font-size: 16px;
  border-color: #1f7d58;
  background: #0f3c2e;
  color: #9dffd8;
}

.tag,
.tag-control {
  --tag-border: #33404c;
  --tag-bg: #1d252d;
  --tag-color: #c7d4de;
  border: 1px solid var(--tag-border);
  background: var(--tag-bg);
  color: var(--tag-color);
}

.tag {
  min-height: auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  border-radius: 999px;
  padding: 4px 8px;
  font-size: 12px;
  line-height: 1.25;
  cursor: pointer;
}

.tag:hover {
  filter: brightness(1.12);
}

.tag-control {
  transition: background 120ms ease, border-color 120ms ease, color 120ms ease;
}

.tag-pvp {
  --tag-border: rgba(255, 91, 91, 0.48);
  --tag-bg: rgba(255, 91, 91, 0.13);
  --tag-color: #ffb4b4;
}

.tag-quality {
  --tag-border: rgba(84, 164, 255, 0.5);
  --tag-bg: rgba(84, 164, 255, 0.14);
  --tag-color: #b9d9ff;
}

.tag-performance {
  --tag-border: rgba(54, 194, 127, 0.5);
  --tag-bg: rgba(54, 194, 127, 0.13);
  --tag-color: #a8ffd9;
}

.tag-visibility {
  --tag-border: rgba(187, 130, 255, 0.52);
  --tag-bg: rgba(187, 130, 255, 0.14);
  --tag-color: #dfc4ff;
}

.tag-balanced {
  --tag-border: rgba(118, 221, 206, 0.48);
  --tag-bg: rgba(118, 221, 206, 0.12);
  --tag-color: #b5fff3;
}

.tag-latency {
  --tag-border: rgba(255, 105, 180, 0.5);
  --tag-bg: rgba(255, 105, 180, 0.13);
  --tag-color: #ffc1df;
}

.tag-low-end {
  --tag-border: rgba(180, 192, 208, 0.44);
  --tag-bg: rgba(180, 192, 208, 0.11);
  --tag-color: #d7e3ef;
}

.tag-high-end {
  --tag-border: rgba(96, 223, 255, 0.48);
  --tag-bg: rgba(96, 223, 255, 0.12);
  --tag-color: #bdf3ff;
}

.tag-creator,
.tag-verified {
  --tag-border: rgba(122, 162, 255, 0.5);
  --tag-bg: rgba(122, 162, 255, 0.13);
  --tag-color: #c7d6ff;
}

.tag-site-baseline,
.tag-starter {
  --tag-border: rgba(54, 194, 127, 0.5);
  --tag-bg: rgba(54, 194, 127, 0.16);
  --tag-color: #9dffd8;
}

.tag-popular,
.tag-trending,
.tag-featured {
  --tag-border: rgba(255, 185, 74, 0.58);
  --tag-bg: rgba(255, 185, 74, 0.16);
  --tag-color: #ffe0a8;
}

.tag-new {
  --tag-border: rgba(142, 157, 171, 0.42);
  --tag-bg: rgba(142, 157, 171, 0.1);
  --tag-color: #cbd6df;
  font-size: 11px;
  padding: 3px 7px;
}

.tag-app-apply {
  --tag-border: rgba(54, 194, 127, 0.45);
  --tag-bg: rgba(54, 194, 127, 0.12);
  --tag-color: #a8ffd9;
}

.tag-manual-copy {
  --tag-border: rgba(164, 176, 187, 0.42);
  --tag-bg: rgba(164, 176, 187, 0.1);
  --tag-color: #d4dde5;
}

dialog {
  width: min(760px, calc(100% - 34px));
  border: 1px solid #33404c;
  border-radius: 10px;
  background: #12181e;
  color: #f5f7f9;
  padding: 0;
}

dialog::backdrop {
  background: rgba(0, 0, 0, 0.55);
}

.dialog-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 16px;
  border-bottom: 1px solid #28333d;
}

.dialog-head h2 {
  margin: 0 0 5px;
}

.dialog-head p {
  margin: 0;
  color: #a4b0bb;
}

pre {
  margin: 0;
  padding: 16px;
  max-height: 60vh;
  overflow: auto;
  white-space: pre-wrap;
  color: #d6e0e8;
}

.app-dialog-body {
  padding: 16px;
  display: grid;
  gap: 12px;
}

.app-download-visual {
  border: 1px solid #26333e;
  background:
    linear-gradient(145deg, rgba(31, 157, 103, 0.16), rgba(16, 24, 32, 0.96)),
    radial-gradient(circle at 25% 20%, rgba(104, 220, 255, 0.22), transparent 42%);
  border-radius: 8px;
  padding: 14px;
  display: flex;
  align-items: center;
  gap: 12px;
}

.app-download-visual img {
  width: 52px;
  height: 52px;
  border-radius: 13px;
}

.app-download-visual strong {
  font-size: 18px;
}

.app-dialog-body ul {
  margin: 0;
  padding-left: 20px;
  color: #d6e0e8;
  display: grid;
  gap: 6px;
}

.app-benefits {
  display: grid;
  gap: 8px;
}

.app-benefits span {
  border: 1px solid #28333d;
  background: #151b21;
  border-radius: 7px;
  padding: 10px;
  color: #d6e0e8;
}

.app-dialog-body p {
  margin: 0;
  color: #9aa8b4;
  font-size: 13px;
}

a[aria-disabled="true"] {
  opacity: 0.55;
  pointer-events: none;
}

@media (max-width: 860px) {
  .hero {
    grid-template-columns: 1fr;
    gap: 18px;
    margin: 22px 0 24px;
  }

  .hero-text h1 {
    font-size: 32px;
    letter-spacing: -0.4px;
  }

  .hero-banner {
    min-height: 220px;
    grid-template-columns: 1fr;
    grid-template-rows: 200px 100px 100px;
  }

  .hero-tile-feature {
    grid-column: 1;
    grid-row: 1;
    min-height: 200px;
  }

  .hero-tile-secondary {
    grid-column: 1;
    min-height: 100px;
  }

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

  .stats-strip .stat strong {
    font-size: 22px;
  }

  .game-tile-card {
    flex-basis: min(74vw, 220px);
  }

  .topbar {
    height: auto;
    padding-top: 12px;
    padding-bottom: 12px;
    gap: 10px;
    flex-wrap: wrap;
  }

  nav {
    overflow-x: visible;
    flex-wrap: wrap;
  }

  .toolbar {
    grid-template-columns: 1fr;
  }

  .view-tabs {
    width: 100%;
  }

  .view-tabs button {
    flex: 1;
  }

  .footer-inner {
    flex-direction: column;
    align-items: flex-start;
  }

  .bug-form {
    grid-template-columns: 1fr;
  }

  .bug-form .span-all {
    grid-column: auto;
  }

  .account-grid,
  .form-grid.two {
    grid-template-columns: 1fr;
  }

  .account-card.account-wide {
    grid-column: auto;
  }

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

  .my-config-actions {
    justify-content: flex-start;
  }

  .avatar-picker > div {
    align-items: stretch;
    flex-direction: column;
  }

  .avatar-controls {
    grid-template-columns: 1fr;
  }
}
.content-layout {
  display: grid;
  grid-template-columns: 196px minmax(0, 1fr);
  gap: 20px;
  align-items: start;
}

.content-main {
  min-width: 0;
}

.content-rail {
  position: sticky;
  top: 80px;
  display: flex;
  flex-direction: column;
  gap: 18px;
  border: 1px solid var(--border);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.02), rgba(255, 255, 255, 0));
  border-radius: 12px;
  padding: 14px;
}

.rail-section {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.rail-eyebrow {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.6px;
  text-transform: uppercase;
  color: var(--text-muted);
}

.view-tabs-rail {
  display: flex;
  flex-direction: column;
  background: transparent;
  border: none;
  padding: 0;
  margin: 0;
  gap: 4px;
}

.view-tabs-rail button {
  display: grid;
  grid-template-columns: 22px 1fr auto;
  align-items: center;
  gap: 10px;
  width: 100%;
  min-height: 38px;
  padding: 0 10px;
  background: transparent;
  border: 1px solid transparent;
  border-radius: 8px;
  color: var(--text-dim);
  font-weight: 600;
  text-align: left;
  font-size: 14px;
  box-shadow: none;
}

.view-tabs-rail button:hover {
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
  border-color: transparent;
}

.view-tabs-rail button.active {
  background: rgba(54, 194, 127, 0.12);
  color: var(--text);
  border-color: rgba(54, 194, 127, 0.32);
  box-shadow: none;
}

.rail-tab-icon {
  font-size: 14px;
  color: var(--text-muted);
}

.view-tabs-rail button.active .rail-tab-icon {
  color: var(--accent);
}

.rail-tab-count {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-muted);
  background: rgba(255, 255, 255, 0.04);
  border-radius: 999px;
  padding: 2px 8px;
  min-width: 28px;
  text-align: center;
}

.view-tabs-rail button.active .rail-tab-count {
  background: rgba(54, 194, 127, 0.18);
  color: var(--accent);
}

.rail-action {
  border: 1px solid var(--border-strong);
  background: rgba(255, 255, 255, 0.02);
  border-radius: 8px;
  padding: 8px 10px;
  color: var(--text-dim);
  font-weight: 500;
  font-size: 13px;
  text-align: left;
  cursor: pointer;
  min-height: 36px;
}

.rail-action:hover {
  border-color: rgba(54, 194, 127, 0.4);
  background: rgba(54, 194, 127, 0.06);
  color: var(--text);
}

@media (max-width: 860px) {
  .content-layout {
    grid-template-columns: 1fr;
  }

  .content-rail {
    position: relative;
    top: auto;
    flex-direction: row;
    overflow-x: auto;
    padding: 10px;
  }

  .rail-section {
    flex-direction: row;
    align-items: center;
    flex: 1 0 auto;
  }

  .rail-eyebrow {
    display: none;
  }

  .view-tabs-rail {
    flex-direction: row;
    flex-wrap: wrap;
  }

  .view-tabs-rail button {
    width: auto;
    grid-template-columns: 22px auto auto;
  }
}
.featured-games-actions {
  margin-top: 12px;
  display: flex;
  justify-content: flex-end;
}
.search-field-wrap {
  position: relative;
  min-width: 0;
}

.search-field {
  width: 100%;
}

.search-clear {
  position: absolute;
  right: 8px;
  top: 50%;
  transform: translateY(-50%);
  width: 26px;
  height: 26px;
  min-height: 26px;
  padding: 0;
  border-radius: 50%;
  border: 1px solid transparent;
  background: rgba(255, 255, 255, 0.06);
  color: var(--text-dim);
  display: grid;
  place-items: center;
  font-size: 14px;
  line-height: 0;
  cursor: pointer;
}

.search-clear:hover {
  background: rgba(255, 255, 255, 0.12);
  color: var(--text);
  border-color: transparent;
}

.search-suggestions {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  right: 0;
  margin: 0;
  padding: 6px;
  list-style: none;
  background: var(--bg-card);
  border: 1px solid var(--border-strong);
  border-radius: 10px;
  box-shadow: var(--shadow-lift);
  z-index: 30;
  max-height: 360px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 1px;
}

.search-suggestions .suggestion-group {
  padding: 8px 10px 4px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.6px;
  text-transform: uppercase;
  color: var(--text-muted);
}

.search-suggestions .suggestion {
  display: grid;
  grid-template-columns: 28px 1fr auto;
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  border-radius: 7px;
  cursor: pointer;
  border: 1px solid transparent;
  background: transparent;
  width: 100%;
  text-align: left;
  color: var(--text);
  min-height: 0;
}

.search-suggestions .suggestion:hover,
.search-suggestions .suggestion[aria-selected="true"] {
  background: rgba(54, 194, 127, 0.08);
  border-color: rgba(54, 194, 127, 0.32);
}

.search-suggestions .suggestion-icon {
  width: 28px;
  height: 28px;
  border-radius: 7px;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, var(--tone-a, #2e6c86), var(--tone-b, #162733));
  color: #f5f7f9;
  font-size: 13px;
  font-weight: 700;
  flex: 0 0 28px;
  background-size: cover;
  background-position: center;
}

.search-suggestions .suggestion-label {
  display: flex;
  flex-direction: column;
  gap: 1px;
  min-width: 0;
}

.search-suggestions .suggestion-label strong {
  color: var(--text);
  font-size: 14px;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.search-suggestions .suggestion-label small {
  color: var(--text-muted);
  font-size: 12px;
}

.search-suggestions .suggestion-kind {
  font-size: 11px;
  color: var(--text-muted);
  background: rgba(255, 255, 255, 0.04);
  border-radius: 4px;
  padding: 2px 6px;
  letter-spacing: 0.4px;
  text-transform: uppercase;
}

.search-suggestions .suggestion mark {
  background: rgba(54, 194, 127, 0.22);
  color: inherit;
  border-radius: 3px;
  padding: 0 2px;
}
.game-tile-card .game-tile-art.cover-valorant {
  background-image:
    linear-gradient(160deg, rgba(255, 70, 85, 0.28), rgba(11, 7, 10, 0.85)),
    linear-gradient(135deg, #ff4655 0 24%, #1a1015 24% 56%, #2a1116 56% 100%);
}

.game-tile-card .game-tile-art.cover-league {
  background-image:
    linear-gradient(160deg, rgba(199, 156, 58, 0.22), rgba(2, 8, 18, 0.88)),
    linear-gradient(135deg, #0a2747 0 36%, #04132a 36% 64%, #1a1410 64% 100%);
}
.config-dialog-body {
  padding: 14px 16px 18px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.config-file-info {
  display: flex;
  flex-direction: column;
  gap: 6px;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.02);
  border-radius: 9px;
  padding: 10px 12px;
  font-size: 13px;
}

.config-admin-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  border: 1px solid rgba(245, 184, 109, 0.32);
  background: rgba(245, 184, 109, 0.08);
  border-radius: 9px;
  padding: 10px 12px;
}

.config-admin-actions.hidden {
  display: none;
}

.config-admin-actions strong {
  color: #ffd7a0;
  margin-right: 4px;
}

.config-admin-actions button {
  min-height: 30px;
  padding: 0 10px;
  border-radius: 7px;
}

.config-admin-actions button.danger {
  color: #ffb0b0;
  border-color: rgba(255, 115, 115, 0.45);
}

.config-file-info .config-file-row {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.config-file-info .config-file-row strong {
  color: var(--text);
  font-size: 13px;
  font-weight: 600;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: baseline;
}

.config-file-info .config-file-row strong .config-file-format {
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.6px;
  background: var(--accent-soft);
  color: var(--accent);
  border-radius: 4px;
  padding: 1px 6px;
  font-weight: 700;
}

.config-file-info .config-file-row code {
  font-size: 12px;
  color: var(--text-dim);
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: 5px;
  padding: 4px 6px;
  word-break: break-all;
  white-space: pre-wrap;
}

.config-file-info .config-file-row em {
  font-size: 12px;
  color: var(--text-muted);
  font-style: normal;
}

.site-config-info {
  border: 1px solid rgba(54, 194, 127, 0.26);
  background: rgba(54, 194, 127, 0.06);
  border-radius: 9px;
  padding: 10px 12px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.site-config-summary {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  color: var(--text-dim);
  font-size: 12px;
}

.site-config-info p {
  margin: 0;
  color: var(--text-dim);
  font-size: 13px;
}

.site-config-info details {
  color: var(--text-dim);
  font-size: 13px;
}

.site-config-info summary {
  cursor: pointer;
  color: var(--text);
  font-weight: 700;
}

.site-config-sources {
  display: grid;
  gap: 6px;
  margin-top: 8px;
}

.site-config-sources a,
.site-config-sources .source-note {
  color: var(--text);
  text-decoration: none;
  border: 1px solid var(--border);
  border-radius: 7px;
  background: rgba(255, 255, 255, 0.03);
  padding: 7px 8px;
}

.site-config-sources a span,
.site-config-sources .source-note span {
  display: block;
  margin-top: 2px;
  color: var(--text-muted);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.4px;
}

.config-view-tabs {
  display: inline-flex;
  gap: 4px;
  padding: 4px;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: 8px;
  align-self: flex-start;
}

.config-view-tabs button {
  min-height: 30px;
  padding: 0 12px;
  font-size: 13px;
  font-weight: 600;
  border-color: transparent;
  background: transparent;
  color: var(--text-dim);
}

.config-view-tabs button:hover {
  color: var(--text);
  background: rgba(255, 255, 255, 0.04);
  border-color: transparent;
}

.config-view-tabs button.active {
  background: rgba(54, 194, 127, 0.14);
  color: var(--text);
  border-color: rgba(54, 194, 127, 0.4);
}

.config-basic-view {
  display: flex;
  flex-direction: column;
  gap: 0;
  max-height: 60vh;
  overflow-y: auto;
  border: 1px solid var(--border);
  border-radius: 9px;
  background: var(--bg-input);
}

.config-basic-view .basic-empty {
  padding: 28px 18px;
  text-align: center;
  color: var(--text-muted);
  font-size: 14px;
}

.config-basic-view .basic-category {
  padding: 8px 12px 6px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.6px;
  text-transform: uppercase;
  color: var(--text-muted);
  background: rgba(255, 255, 255, 0.02);
  border-bottom: 1px solid var(--border);
  border-top: 1px solid var(--border);
  position: sticky;
  top: 0;
  backdrop-filter: blur(6px);
}

.config-basic-view .basic-category:first-child {
  border-top: none;
}

.config-basic-view .basic-row {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
  gap: 10px;
  padding: 10px 12px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
  align-items: center;
}

.config-basic-view .basic-row:last-child {
  border-bottom: none;
}

.config-basic-view .basic-row .basic-label {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.config-basic-view .basic-row .basic-label strong {
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
}

.config-basic-view .basic-row .basic-label small {
  font-size: 11px;
  color: var(--text-muted);
  font-family: ui-monospace, "SFMono-Regular", "Menlo", monospace;
  word-break: break-all;
}

.config-basic-view .basic-row .basic-value {
  display: flex;
  flex-direction: column;
  gap: 4px;
  align-items: flex-end;
  text-align: right;
}

.config-basic-view .basic-row .basic-value .basic-pill {
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
  background: rgba(54, 194, 127, 0.14);
  border: 1px solid rgba(54, 194, 127, 0.32);
  padding: 3px 9px;
  border-radius: 999px;
  white-space: nowrap;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
}

.config-basic-view .basic-row .basic-value .basic-pill.muted {
  background: rgba(255, 255, 255, 0.04);
  border-color: var(--border);
  color: var(--text-dim);
  font-weight: 500;
}

.config-basic-view .basic-row .basic-meter {
  width: 110px;
  height: 6px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.07);
  overflow: hidden;
  position: relative;
}

.config-basic-view .basic-row .basic-meter > span {
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, var(--accent), var(--accent-hover));
  border-radius: inherit;
  transform-origin: left center;
}

.config-basic-view .basic-row .basic-range-bounds {
  font-size: 10px;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.4px;
}

.config-basic-view .basic-row .basic-bool {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.4px;
  text-transform: uppercase;
  border-radius: 999px;
  padding: 3px 9px;
  border: 1px solid;
}

.config-basic-view .basic-row .basic-bool.on {
  color: #6ee2a4;
  border-color: rgba(54, 194, 127, 0.45);
  background: rgba(54, 194, 127, 0.12);
}

.config-basic-view .basic-row .basic-bool.off {
  color: var(--text-muted);
  border-color: var(--border);
  background: rgba(255, 255, 255, 0.02);
}

.config-basic-view .basic-row.unmapped .basic-label small.unmapped-tag {
  color: #c39854;
  font-style: italic;
}

.config-advanced-view {
  border: 1px solid var(--border);
  border-radius: 9px;
  overflow: hidden;
  background: var(--bg-input);
}

.advanced-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 12px;
  border-bottom: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.025);
}

.advanced-toolbar strong,
.advanced-toolbar small {
  display: block;
}

.advanced-toolbar strong {
  font-size: 13px;
  font-weight: 700;
  color: var(--text);
}

.advanced-toolbar small {
  margin-top: 2px;
  font-size: 11px;
  color: var(--text-muted);
}

.advanced-actions {
  display: flex;
  gap: 7px;
  flex: 0 0 auto;
}

.advanced-actions button {
  min-height: 30px;
  padding: 0 10px;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 700;
}

.config-advanced-view pre {
  margin: 0;
  padding: 14px 16px;
  max-height: 60vh;
  overflow: auto;
  font-size: 13px;
  line-height: 1.5;
  font-family: ui-monospace, "SFMono-Regular", "Menlo", monospace;
  user-select: text;
}

.config-advanced-view pre:focus,
#merge-preview:focus {
  outline: 2px solid rgba(54, 194, 127, 0.45);
  outline-offset: -2px;
}

@media (max-width: 640px) {
  .config-basic-view .basic-row {
    grid-template-columns: 1fr;
  }

  .config-basic-view .basic-row .basic-value {
    align-items: flex-start;
    text-align: left;
  }

  .advanced-toolbar {
    align-items: stretch;
    flex-direction: column;
  }

  .advanced-actions {
    width: 100%;
  }

  .advanced-actions button {
    flex: 1;
  }
}
