@import url("https://fonts.googleapis.com/css2?family=Barlow:wght@500;600;700&family=Barlow+Condensed:wght@500;600;700;800&family=Roboto+Slab:wght@400;500;600;700&display=swap");

/* ===== FirePowered — Design System ===== */

/* ---------- CSS Custom Properties ---------- */
:root {
  --orange:       #b94724;
  --orange-dark:  #913719;
  --orange-light: #e7794d;
  --orange-bg:    #fff4ef;
  --orange-glow:  rgba(240,100,47,.18);

  --charcoal:     #2e2b29;
  --charcoal-2:   #3c3936;
  --charcoal-3:   #4a4744;

  --ink:          #3c3936;
  --text:         #4b4540;
  --muted:        #655e57;
  --subtle:       #756e67;

  --line:         #e3ded9;
  --line-light:   #eeebe7;
  --surface:      #ffffff;
  --surface-2:    #f9f6f3;
  --background:   #f5f2ef;

  --green:        #22c55e;
  --green-bg:     #f0fdf4;
  --red:          #ef4444;
  --red-bg:       #fef2f2;
  --blue:         #3b82f6;
  --blue-bg:      #eff6ff;
  --yellow:       #f59e0b;
  --yellow-bg:    #fffbeb;
  --purple:       #8b5cf6;
  --purple-bg:    #f5f3ff;

  /* TF2 rarity / quality colors */
  --tf2-unique:    #ffd700;
  --tf2-strange:   #cf6a32;
  --tf2-unusual:   #8650ac;
  --tf2-genuine:   #4d7455;
  --tf2-vintage:   #476291;
  --tf2-haunted:   #38f3ab;
  --tf2-collectors:#aa0000;
  --tf2-normal:    #b2b2b2;

  --font-body:    "Roboto Slab", Georgia, serif;
  --font-display: "Barlow Condensed", "Arial Narrow", sans-serif;
  --font-ui:      "Barlow", Arial, sans-serif;

  --radius-sm:    8px;
  --radius:       12px;
  --radius-lg:    16px;
  --radius-xl:    22px;

  --shadow-sm:    0 1px 4px rgba(60,53,48,.07);
  --shadow:       0 4px 18px rgba(60,53,48,.09);
  --shadow-lg:    0 14px 38px rgba(60,53,48,.11);
  --shadow-orange:0 8px 24px rgba(240,100,47,.22);

  --trans: 150ms ease;
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--background);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 15px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; }
img { display: block; max-width: 100%; }
svg {
  display: block; fill: none;
  stroke: currentColor; stroke-linecap: round;
  stroke-linejoin: round; stroke-width: 1.8;
}
ul { list-style: none; margin: 0; padding: 0; }
h1,h2,h3,h4,h5 { margin: 0; }
p { margin: 0; }

/* ---------- Layout shells ---------- */
.shell {
  width: min(1180px, calc(100% - 40px));
  margin: 0 auto;
}
.shell-narrow { width: min(780px, calc(100% - 40px)); margin: 0 auto; }
.shell-wide   { width: min(1320px, calc(100% - 40px)); margin: 0 auto; }

/* ---------- Demo Banner ---------- */
.demo-banner {
  background: var(--charcoal-2);
  color: #d3cbc5;
  font-size: 11px;
  font-weight: 600;
  text-align: center;
  padding: 7px 20px;
  letter-spacing: 0.02em;
}
.demo-banner span { color: var(--orange-light); font-weight: 800; }

/* ---------- Site Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255,255,255,.96);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(16px);
}
.nav-shell {
  width: min(1180px, calc(100% - 40px));
  margin: 0 auto;
  display: flex;
  min-height: 68px;
  align-items: center;
  gap: 32px;
}

/* Brand */
.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  flex: 0 0 auto;
  text-decoration: none;
}
.brand-mark {
  display: grid;
  width: 53px;
  height: 24px;
  place-items: center;
}
.brand-mark img {
  display: block;
  width: auto;
  height: 24px;
  object-fit: contain;
}
.brand strong { display: block; font-family: var(--font-display); font-size: 16px; line-height: 1; letter-spacing: -.03em; color: var(--charcoal); }
.brand small  { display: block; margin-top: 2px; color: var(--muted); font-size: 9px; line-height: 1; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; }

/* Primary nav */
.primary-nav {
  display: flex;
  align-self: stretch;
  align-items: center;
  gap: 4px;
}
.primary-nav > a, .primary-nav > .nav-drop > .nav-drop-toggle {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 0 10px;
  height: 68px;
  color: var(--text);
  font-size: 13px;
  font-weight: 700;
  transition: color var(--trans);
  background: none;
  border: none;
  cursor: pointer;
  white-space: nowrap;
}
.primary-nav > a:hover, .primary-nav > .nav-drop > .nav-drop-toggle:hover,
.primary-nav > a.active, .primary-nav > .nav-drop.active > .nav-drop-toggle { color: var(--orange); }
.primary-nav > a.nav-coming-soon {
  flex-direction: column;
  justify-content: center;
  gap: 2px;
  color: rgba(255, 246, 233, .45);
  cursor: not-allowed;
  pointer-events: none;
}
.nav-coming-soon small {
  font-size: 7px;
  font-weight: 800;
  line-height: 1;
  letter-spacing: .08em;
  text-transform: uppercase;
}
.primary-nav > a.active::after, .primary-nav > .nav-drop.active > .nav-drop-toggle::after {
  content: '';
  position: absolute;
  bottom: 0; left: 0; right: 0;
  height: 3px;
  border-radius: 3px 3px 0 0;
  background: var(--orange);
}
.nav-drop-caret { width: 14px; height: 14px; transition: transform var(--trans); }
.nav-drop:hover .nav-drop-caret, .nav-drop.open .nav-drop-caret { transform: rotate(180deg); }

/* Dropdown */
.nav-drop { position: relative; }
.nav-drop-menu {
  position: absolute;
  top: calc(100% + 4px);
  left: -12px;
  min-width: 200px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  padding: 8px;
  display: none;
  z-index: 200;
}
.nav-drop:hover .nav-drop-menu, .nav-drop.open .nav-drop-menu { display: block; }
.nav-drop-menu a {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 12px;
  border-radius: var(--radius-sm);
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
  transition: background var(--trans), color var(--trans);
}
.nav-drop-menu a:hover { background: var(--orange-bg); color: var(--orange); }
.nav-drop-menu a svg { width: 16px; flex: 0 0 auto; }
.nav-drop-menu a span { flex: 1; }
.nav-drop-menu a small { display: block; font-size: 10px; font-weight: 500; color: var(--muted); margin-top: 1px; }
.nav-drop-menu .drop-item-text { display: grid; }

/* Nav actions */
.nav-actions {
  display: flex;
  margin-left: auto;
  align-items: center;
  gap: 8px;
}

/* Buttons */
.btn, button.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  border: none;
  border-radius: var(--radius);
  cursor: pointer;
  font-size: 13px;
  font-weight: 700;
  padding: 0 18px;
  min-height: 40px;
  transition: transform var(--trans), box-shadow var(--trans), background var(--trans), color var(--trans);
  white-space: nowrap;
  text-decoration: none;
  line-height: 1;
}
.btn:hover { transform: translateY(-1px); }
.btn svg { width: 16px; flex: 0 0 auto; }

.btn-primary { background: var(--orange); color: white; box-shadow: var(--shadow-orange); }
.btn-primary:hover { background: var(--orange-dark); box-shadow: 0 10px 28px rgba(240,100,47,.30); }
.btn-secondary { background: var(--surface); color: var(--ink); border: 1.5px solid var(--line); box-shadow: var(--shadow-sm); }
.btn-secondary:hover { border-color: var(--orange); color: var(--orange); background: var(--orange-bg); }
.btn-ghost { background: transparent; color: var(--text); }
.btn-ghost:hover { background: var(--background); color: var(--ink); }
.btn-dark { background: var(--charcoal); color: white; }
.btn-dark:hover { background: var(--charcoal-2); }
.btn-discord { background: #5865f2; color: white; }
.btn-discord:hover { background: #4752c4; box-shadow: 0 8px 20px rgba(88,101,242,.3); }
.steam-signin-icon { width: 20px; height: 20px; flex: 0 0 20px; object-fit: contain; }

.signin-shell {
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: 32px 20px 48px;
}

.steam-openid-button {
  display: flex;
  width: max-content;
  margin: 0 auto;
  align-items: center;
  justify-content: center;
  border-radius: 3px;
  transition: filter .15s ease, transform .15s ease;
}

.steam-openid-button:hover {
  filter: brightness(1.08);
  transform: translateY(-1px);
}

.steam-openid-button:focus-visible {
  outline: 3px solid rgba(240, 100, 47, .38);
  outline-offset: 4px;
}

.steam-openid-button img {
  display: block;
  width: 180px;
  height: auto;
}
.member-connection-card { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 20px; }
.member-connection-copy h2 { margin: 0 0 8px; }
.member-connection-copy p { margin: 0; color: var(--muted); line-height: 1.55; }
.discord-identity { display: flex; align-items: center; gap: 12px; }
.discord-identity > div { display: grid; gap: 2px; }
.discord-identity span { color: var(--muted); font-size: 12px; }
.discord-avatar { width: 44px; height: 44px; border-radius: 50%; object-fit: cover; }
.connection-unavailable { color: var(--muted); font-size: 12px; max-width: 220px; text-align: right; }
.connection-success, .connection-error { flex-basis: 100%; padding: 10px 12px; border-radius: var(--radius); font-size: 13px; }
.connection-success { background: #e9f7ed; color: #17642d; }
.connection-error { background: #fef2f2; color: #991b1b; }
html[data-theme="dark"] .connection-success { background: #183c26; color: #bce9c9; }
html[data-theme="dark"] .connection-error { background: #4a2020; color: #ffd0d0; }
@media (max-width: 640px) {
  .member-connection-card { align-items: flex-start; flex-direction: column; }
  .connection-unavailable { max-width: none; text-align: left; }
}
.btn-green { background: var(--green); color: white; }
.btn-green:hover { background: #16a34a; }
.btn-danger { background: var(--red); color: white; }
.btn-outline-orange { background: transparent; color: var(--orange); border: 1.5px solid var(--orange); }
.btn-outline-orange:hover { background: var(--orange); color: white; }

.btn-sm { min-height: 32px; padding: 0 12px; font-size: 11px; border-radius: var(--radius-sm); }
.btn-lg { min-height: 50px; padding: 0 28px; font-size: 15px; border-radius: var(--radius-lg); }
.btn-xl { min-height: 58px; padding: 0 36px; font-size: 16px; border-radius: 14px; }
.btn-block { width: 100%; }
.btn-icon { width: 40px; height: 40px; padding: 0; min-height: 0; border-radius: 50%; }
.btn-icon-sq { width: 40px; height: 40px; padding: 0; min-height: 0; }
.btn-icon svg, .btn-icon-sq svg { width: 18px; }

/* Light glass button (for dark backgrounds) */
.btn-light { background: rgba(255,255,255,.13); color: white; border: 1px solid rgba(255,255,255,.22); }
.btn-light:hover { background: rgba(255,255,255,.20); }

/* Icon-only nav button */
.icon-btn {
  display: inline-grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border: none;
  border-radius: var(--radius);
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  transition: background var(--trans), color var(--trans);
}
.icon-btn svg { width: 20px; }
.icon-btn:hover { background: var(--background); color: var(--ink); }

/* ---------- Mobile Menu ---------- */
.hamburger {
  display: none;
  width: 40px;
  height: 40px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
  align-items: center;
  justify-content: center;
}
.hamburger-box {
  width: 22px;
  height: 16px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}
.hamburger-box span {
  display: block;
  width: 100%;
  height: 2px;
  background: var(--charcoal);
  border-radius: 2px;
  transition: transform .25s, opacity .25s;
}
.hamburger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.hamburger.open span:nth-child(2) { opacity: 0; }
.hamburger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

.mobile-nav {
  display: none;
  position: fixed;
  inset: 0;
  background: white;
  z-index: 99;
  overflow-y: auto;
  padding: 80px 24px 32px;
  flex-direction: column;
  gap: 4px;
}
.mobile-nav.open { display: flex; }
.mobile-nav a, .mobile-nav button.mob-link {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 13px 16px;
  border-radius: var(--radius);
  font-size: 15px;
  font-weight: 700;
  color: var(--ink);
  transition: background var(--trans);
  border: none;
  background: none;
  cursor: pointer;
  text-align: left;
}
.mobile-nav a:hover, .mobile-nav button.mob-link:hover { background: var(--background); }
.mobile-nav a.active { color: var(--orange); background: var(--orange-bg); }
.mobile-nav a.mobile-coming-soon {
  color: var(--muted);
  cursor: not-allowed;
  opacity: .6;
  pointer-events: none;
}
.mobile-coming-soon small {
  margin-left: auto;
  font-size: 9px;
  font-weight: 800;
  letter-spacing: .06em;
  text-transform: uppercase;
}
.mobile-nav svg { width: 20px; flex: 0 0 auto; color: var(--muted); }
.mobile-nav-divider { height: 1px; background: var(--line); margin: 8px 0; }
.mobile-nav-actions { display: flex; flex-direction: column; gap: 8px; margin-top: 16px; }
.mobile-nav-section { font-size: 10px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); padding: 8px 16px 4px; }

/* ---------- Search Overlay ---------- */
.search-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(46,43,41,.6);
  z-index: 200;
  align-items: flex-start;
  justify-content: center;
  padding-top: 80px;
  backdrop-filter: blur(4px);
}
.search-overlay.open { display: flex; }
.search-box {
  width: min(640px, calc(100% - 40px));
  background: white;
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-lg);
  overflow: hidden;
}
.search-input-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px 20px;
  border-bottom: 1px solid var(--line);
}
.search-input-row svg { width: 20px; color: var(--muted); flex: 0 0 auto; }
.search-input-row input {
  flex: 1;
  border: none;
  outline: none;
  font-size: 16px;
  background: none;
  color: var(--ink);
}
.search-input-row input::placeholder { color: var(--subtle); }
.search-close { background: none; border: none; cursor: pointer; color: var(--muted); padding: 4px; border-radius: var(--radius-sm); }
.search-close svg { width: 18px; }
.search-results-preview { padding: 12px 0; max-height: 400px; overflow-y: auto; }
.search-result-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 20px;
  transition: background var(--trans);
  cursor: pointer;
  text-decoration: none;
  color: inherit;
}
.search-result-item:hover { background: var(--background); }
.search-result-icon { width: 36px; height: 36px; border-radius: var(--radius-sm); background: var(--background); display: grid; place-items: center; flex: 0 0 auto; }
.search-result-icon svg { width: 18px; color: var(--orange); }
.search-result-item strong { display: block; font-size: 13px; }
.search-result-item small { display: block; font-size: 11px; color: var(--muted); }
.search-hint { padding: 12px 20px; font-size: 11px; color: var(--muted); }

/* ---------- Toast ---------- */
.toast-stack {
  position: fixed;
  bottom: 28px;
  right: 24px;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 10px;
  pointer-events: none;
}
.toast {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  background: white;
  border-radius: var(--radius-lg);
  box-shadow: 0 8px 32px rgba(60,53,48,.18);
  padding: 14px 18px;
  min-width: 280px;
  max-width: 380px;
  pointer-events: all;
  animation: toastIn .25s ease;
  border-left: 4px solid var(--orange);
}
.toast.toast-success { border-left-color: var(--green); }
.toast.toast-error   { border-left-color: var(--red); }
.toast.toast-info    { border-left-color: var(--blue); }
.toast-icon { width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; flex: 0 0 auto; }
.toast-icon svg { width: 13px; }
.toast.toast-success .toast-icon { background: var(--green-bg); color: var(--green); }
.toast.toast-error   .toast-icon { background: var(--red-bg); color: var(--red); }
.toast.toast-info    .toast-icon { background: var(--blue-bg); color: var(--blue); }
.toast-body strong { display: block; font-size: 13px; font-weight: 700; }
.toast-body p { font-size: 12px; color: var(--text); margin-top: 2px; }
@keyframes toastIn { from { opacity: 0; transform: translateX(20px); } to { opacity: 1; transform: translateX(0); } }

/* ---------- Typography ---------- */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--orange);
}
.eyebrow-dark { color: var(--text); }
.eyebrow .dot {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--orange);
  box-shadow: 0 0 0 3px rgba(240,100,47,.18);
  flex: 0 0 auto;
}
.section-title {
  font-family: var(--font-display);
  font-size: clamp(22px, 3vw, 30px);
  letter-spacing: -.04em;
  color: var(--charcoal);
  margin-top: 6px;
}
.section-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  margin-bottom: 24px;
  gap: 16px;
}
.section-head .text-link {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 12px;
  font-weight: 700;
  color: var(--orange);
  white-space: nowrap;
}
.section-head .text-link svg { width: 14px; }
.text-link { display: inline-flex; align-items: center; gap: 5px; font-size: 12px; font-weight: 700; color: var(--orange); }
.text-link svg { width: 14px; }
.text-link:hover { color: var(--orange-dark); }

/* ---------- Pill / Badge ---------- */
.pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 10px;
  border-radius: 99px;
  font-size: 11px;
  font-weight: 700;
}
.pill-orange { background: var(--orange-bg); color: var(--orange); }
.pill-green  { background: var(--green-bg); color: #15803d; }
.pill-red    { background: var(--red-bg); color: #b91c1c; }
.pill-blue   { background: var(--blue-bg); color: #1d4ed8; }
.pill-purple { background: var(--purple-bg); color: #6d28d9; }
.pill-yellow { background: var(--yellow-bg); color: #92400e; }
.pill-gray   { background: var(--line-light); color: var(--text); }
.pill-dark   { background: var(--charcoal); color: white; }
.pill-live   { background: rgba(240,100,47,.12); color: var(--orange); }
.pill-live::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: var(--orange); animation: livePulse 1.5s infinite; }
@keyframes livePulse { 0%,100% { opacity: 1; } 50% { opacity: .4; } }

.badge {
  display: inline-grid;
  place-items: center;
  min-width: 20px;
  height: 20px;
  padding: 0 6px;
  border-radius: 99px;
  font-size: 10px;
  font-weight: 800;
  background: var(--orange);
  color: white;
}

/* TF2 quality labels */
.q-unique    { color: var(--tf2-unique); }
.q-strange   { color: var(--tf2-strange); }
.q-unusual   { color: var(--tf2-unusual); }
.q-genuine   { color: var(--tf2-genuine); }
.q-vintage   { color: var(--tf2-vintage); }
.q-haunted   { color: var(--tf2-haunted); }
.q-collectors{ color: var(--tf2-collectors); }
.pill-unusual  { background: rgba(134,80,172,.1); color: var(--tf2-unusual); }
.pill-strange  { background: rgba(207,106,50,.1); color: var(--tf2-strange); }
.pill-unique   { background: rgba(255,215,0,.1); color: #a07d00; }
.pill-genuine  { background: rgba(77,116,85,.1); color: var(--tf2-genuine); }

/* ---------- Avatar ---------- */
.avatar {
  display: inline-grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  font-size: 12px;
  font-weight: 800;
  color: white;
  flex: 0 0 auto;
  border: 2px solid white;
  box-shadow: 0 2px 8px rgba(60,53,48,.12);
}
.avatar-sm { width: 28px; height: 28px; font-size: 10px; }
.avatar-md { width: 44px; height: 44px; font-size: 15px; }
.avatar-lg { width: 60px; height: 60px; font-size: 20px; }
.avatar-xl { width: 80px; height: 80px; font-size: 28px; }
.avatar { position: relative; overflow: hidden; color: transparent; font-size: 0; }
.avatar::before { content: ""; position: absolute; inset: 0; background: url("assets/avatar-placeholder.svg") center / 88% no-repeat; }
.av-orange { background: linear-gradient(135deg, #ff9b65, #f55b32); }
.av-teal   { background: linear-gradient(135deg, #df9a7d, #b65c39); }
.av-violet { background: linear-gradient(135deg, #c084fc, #9333ea); }
.av-blue   { background: linear-gradient(135deg, #60a5fa, #2563eb); }
.av-mint   { background: linear-gradient(135deg, #34d399, #059669); }
.av-slate  { background: linear-gradient(135deg, #94a3b8, #475569); }
.av-red    { background: linear-gradient(135deg, #f87171, #dc2626); }
.av-yellow { background: linear-gradient(135deg, #fbbf24, #d97706); }

.avatar-stack { display: flex; }
.avatar-stack .avatar + .avatar { margin-left: -8px; }

/* ---------- Card ---------- */
.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
  transition: box-shadow var(--trans), transform var(--trans);
}
.card:hover { box-shadow: var(--shadow); transform: translateY(-2px); }
.card-padded { padding: 20px; }
.card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid var(--line);
  background: var(--surface-2);
}
.card-header h3 { font-family: var(--font-display); font-size: 15px; letter-spacing: -.02em; }
.card-body { padding: 20px; }
.card-footer { padding: 14px 20px; border-top: 1px solid var(--line); background: var(--surface-2); }

/* ---------- Item Card (marketplace) ---------- */
.item-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: box-shadow var(--trans), transform var(--trans);
  display: flex;
  flex-direction: column;
}
.item-card:hover { box-shadow: var(--shadow); transform: translateY(-2px); }
.item-card-img {
  background: linear-gradient(135deg, #f7f3ef, #eee9e4);
  padding: 20px;
  display: grid;
  place-items: center;
  min-height: 130px;
  position: relative;
}
.item-card-img .item-emoji { font-size: 52px; line-height: 1; }
.item-card-img .item-quality-bar { position: absolute; top: 0; left: 0; right: 0; height: 3px; }
.iqb-unusual  { background: linear-gradient(90deg, #8650ac, #c084fc); }
.iqb-strange  { background: linear-gradient(90deg, #cf6a32, #f59e0b); }
.iqb-unique   { background: linear-gradient(90deg, #ffd700, #f59e0b); }
.iqb-genuine  { background: linear-gradient(90deg, #4d7455, #22c55e); }
.iqb-haunted  { background: linear-gradient(90deg, #38f3ab, #0891b2); }
.item-card-body { padding: 14px 16px; flex: 1; display: flex; flex-direction: column; gap: 6px; }
.item-card-name { font-weight: 700; font-size: 13px; line-height: 1.3; }
.item-card-attrs { display: flex; flex-wrap: wrap; gap: 4px; }
.item-card-price { font-family: var(--font-display); font-size: 17px; font-weight: 700; color: var(--orange); letter-spacing: -.02em; margin-top: auto; padding-top: 8px; }
.item-card-price small { font-size: 11px; color: var(--muted); font-family: var(--font-body); font-weight: 600; margin-left: 4px; }
.item-card-footer {
  padding: 10px 16px;
  border-top: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.item-card-seller { display: flex; align-items: center; gap: 7px; font-size: 11px; color: var(--text); }

/* ---------- Auction Card ---------- */
.auction-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: box-shadow var(--trans), transform var(--trans);
}
.auction-card:hover { box-shadow: var(--shadow); transform: translateY(-2px); }
.auction-img {
  background: linear-gradient(135deg, #f7f3ef, #eee9e4);
  padding: 24px 20px 18px;
  position: relative;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
}
.auction-img .item-emoji { font-size: 48px; }
.auction-timer { background: var(--charcoal); color: white; border-radius: var(--radius-sm); padding: 5px 10px; font-family: var(--font-display); font-size: 13px; font-weight: 700; }
.auction-timer small { display: block; font-family: var(--font-body); font-size: 8px; font-weight: 600; color: rgba(255,255,255,.82); margin-bottom: 2px; text-transform: uppercase; letter-spacing: .06em; }
.auction-body { padding: 16px; }
.auction-name { font-weight: 700; font-size: 14px; }
.auction-bids { display: flex; align-items: center; justify-content: space-between; margin-top: 10px; padding-top: 10px; border-top: 1px solid var(--line); }
.current-bid-label { font-size: 10px; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: .06em; }
.current-bid { font-family: var(--font-display); font-size: 20px; font-weight: 700; color: var(--orange); letter-spacing: -.03em; }
.bid-count { font-size: 11px; color: var(--muted); }

/* ---------- Event Card ---------- */
.event-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  overflow: hidden;
  display: flex;
  gap: 0;
  transition: box-shadow var(--trans), transform var(--trans);
}
.event-card:hover { box-shadow: var(--shadow); transform: translateY(-2px); }
.event-date-block {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-width: 72px;
  background: var(--orange);
  color: white;
  padding: 16px 12px;
  text-align: center;
  flex: 0 0 auto;
}
.event-date-block .month { font-size: 9px; font-weight: 800; text-transform: uppercase; letter-spacing: .1em; opacity: .85; }
.event-date-block .day { font-family: var(--font-display); font-size: 28px; font-weight: 700; line-height: 1; }
.event-date-block .weekday { font-size: 9px; font-weight: 700; opacity: .75; margin-top: 2px; }
.event-body { padding: 16px 18px; flex: 1; min-width: 0; }
.event-body h3 { font-weight: 700; font-size: 15px; margin-bottom: 5px; }
.event-body p { font-size: 12px; color: var(--text); line-height: 1.5; }
.event-meta { display: flex; align-items: center; gap: 12px; margin-top: 12px; flex-wrap: wrap; }
.event-meta span { font-size: 11px; color: var(--muted); display: flex; align-items: center; gap: 5px; }
.event-meta span svg { width: 14px; }

/* ---------- Guide Card ---------- */
.guide-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: box-shadow var(--trans), transform var(--trans);
}
.guide-card:hover { box-shadow: var(--shadow); transform: translateY(-2px); }
.guide-thumb {
  background: linear-gradient(135deg, var(--charcoal-2), var(--charcoal));
  height: 140px;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
}
.guide-thumb-emoji { font-size: 48px; opacity: .85; }
.guide-play {
  position: absolute;
  width: 48px; height: 48px;
  border-radius: 50%;
  background: rgba(255,255,255,.15);
  border: 2px solid rgba(255,255,255,.4);
  display: grid;
  place-items: center;
  color: white;
  transition: background var(--trans);
}
.guide-play:hover { background: rgba(240,100,47,.7); }
.guide-play svg { width: 20px; fill: currentColor; stroke: none; }
.guide-card-body { padding: 14px 16px; }
.guide-card-body h3 { font-weight: 700; font-size: 14px; line-height: 1.35; }
.guide-card-body p { font-size: 12px; color: var(--text); margin-top: 5px; }
.guide-meta { display: flex; align-items: center; gap: 10px; margin-top: 10px; font-size: 11px; color: var(--muted); }

/* ---------- Stat Card ---------- */
.stat-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 20px;
  text-align: center;
}
.stat-card .stat-val {
  font-family: var(--font-display);
  font-size: 32px;
  font-weight: 700;
  letter-spacing: -.04em;
  color: var(--charcoal);
}
.stat-card .stat-label {
  font-size: 11px;
  font-weight: 700;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: .07em;
  margin-top: 4px;
}
.stat-card .stat-trend { font-size: 11px; color: var(--green); font-weight: 700; margin-top: 2px; }
.stat-card .stat-trend.down { color: var(--red); }

/* ---------- Forms ---------- */
.form-group { display: flex; flex-direction: column; gap: 6px; }
.form-label { font-size: 12px; font-weight: 700; color: var(--ink); }
.form-label .req { color: var(--orange); }
.form-control {
  width: 100%;
  padding: 10px 14px;
  border: 1.5px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--ink);
  font-size: 14px;
  outline: none;
  transition: border-color var(--trans), box-shadow var(--trans);
}
.form-control:focus { border-color: var(--orange); box-shadow: 0 0 0 3px rgba(240,100,47,.12); }
.form-control::placeholder { color: var(--subtle); }
.form-hint { font-size: 11px; color: var(--muted); }
.form-error { font-size: 11px; color: var(--red); display: none; }
.form-group.has-error .form-control { border-color: var(--red); }
.form-group.has-error .form-error { display: block; }
select.form-control { cursor: pointer; }
textarea.form-control { resize: vertical; min-height: 100px; }
.form-check { display: flex; align-items: flex-start; gap: 10px; }
.form-check input[type=checkbox], .form-check input[type=radio] { width: 16px; height: 16px; margin-top: 2px; accent-color: var(--orange); flex: 0 0 auto; }
.form-check label { font-size: 13px; color: var(--text); }

/* Input with icon */
.input-with-icon { position: relative; }
.input-with-icon .form-control { padding-left: 40px; }
.input-with-icon .input-icon { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); color: var(--muted); width: 18px; pointer-events: none; }

/* ---------- Breadcrumb ---------- */
.breadcrumb {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  color: var(--muted);
  flex-wrap: wrap;
}
.breadcrumb a { color: var(--text); font-weight: 600; }
.breadcrumb a:hover { color: var(--orange); }
.breadcrumb svg { width: 12px; color: var(--subtle); }

/* ---------- Pagination ---------- */
.pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  margin-top: 32px;
}
.page-btn {
  display: inline-grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border-radius: var(--radius-sm);
  font-size: 13px;
  font-weight: 700;
  color: var(--text);
  border: 1px solid var(--line);
  background: var(--surface);
  cursor: pointer;
  transition: background var(--trans), color var(--trans), border-color var(--trans);
}
.page-btn:hover { background: var(--background); color: var(--ink); }
.page-btn.active { background: var(--orange); color: white; border-color: var(--orange); }
.page-btn svg { width: 14px; }

/* ---------- Tabs ---------- */
.tabs {
  display: flex;
  border-bottom: 1.5px solid var(--line);
  gap: 0;
  overflow-x: auto;
  scrollbar-width: none;
}
.tabs::-webkit-scrollbar { display: none; }
.tab {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 12px 18px;
  font-size: 13px;
  font-weight: 700;
  color: var(--muted);
  border-bottom: 2.5px solid transparent;
  cursor: pointer;
  background: none;
  border-top: none;
  border-left: none;
  border-right: none;
  white-space: nowrap;
  transition: color var(--trans), border-color var(--trans);
}
.tab:hover { color: var(--ink); }
.tab.active { color: var(--orange); border-bottom-color: var(--orange); }
.tab svg { width: 16px; }

/* ---------- Filter Bar ---------- */
.filter-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  padding: 16px 0;
}
.filter-group { display: flex; align-items: center; gap: 6px; }
.filter-label { font-size: 11px; font-weight: 700; color: var(--muted); white-space: nowrap; }
.filter-select {
  padding: 7px 12px;
  border: 1.5px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  font-size: 12px;
  font-weight: 600;
  color: var(--ink);
  cursor: pointer;
  outline: none;
  transition: border-color var(--trans);
}
.filter-select:focus { border-color: var(--orange); }
.filter-search {
  flex: 1;
  min-width: 200px;
  max-width: 360px;
  position: relative;
}
.filter-search svg { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); color: var(--muted); width: 16px; pointer-events: none; }
.filter-search input {
  width: 100%;
  padding: 8px 12px 8px 36px;
  border: 1.5px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  font-size: 13px;
  color: var(--ink);
  outline: none;
  transition: border-color var(--trans);
}
.filter-search input:focus { border-color: var(--orange); }
.filter-toggle-group { display: flex; border: 1.5px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.filter-toggle { padding: 7px 14px; font-size: 12px; font-weight: 700; color: var(--muted); background: var(--surface); border: none; cursor: pointer; transition: background var(--trans), color var(--trans); }
.filter-toggle.active { background: var(--orange); color: white; }
.filter-toggle:hover:not(.active) { background: var(--background); color: var(--ink); }

/* ---------- Table ---------- */
.data-table { width: 100%; border-collapse: collapse; }
.data-table th {
  text-align: left;
  font-size: 10px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: .07em;
  color: var(--muted);
  padding: 10px 16px;
  border-bottom: 1.5px solid var(--line);
  white-space: nowrap;
}
.data-table td { padding: 14px 16px; border-bottom: 1px solid var(--line-light); vertical-align: middle; }
.data-table tr:last-child td { border-bottom: none; }
.data-table tr:hover td { background: var(--surface-2); }
.data-table th.right, .data-table td.right { text-align: right; }
.data-table th.center, .data-table td.center { text-align: center; }

/* ---------- Raffle / Giveaway Card ---------- */
.raffle-card {
  background: var(--surface);
  border: 1.5px solid var(--line);
  border-radius: var(--radius-xl);
  overflow: hidden;
}
.raffle-header {
  background: linear-gradient(135deg, var(--charcoal-2), var(--charcoal));
  color: white;
  padding: 24px;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}
.raffle-emoji { font-size: 52px; }
.raffle-header h2 { font-family: var(--font-display); font-size: 22px; letter-spacing: -.03em; }
.raffle-header p { font-size: 13px; color: rgba(255,255,255,.7); margin-top: 4px; }
.raffle-body { padding: 24px; }
.raffle-prize-list { display: grid; gap: 10px; }
.raffle-prize-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 16px;
  background: var(--surface-2);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}
.raffle-prize-num {
  width: 28px; height: 28px;
  border-radius: 50%;
  background: var(--orange);
  color: white;
  font-size: 12px;
  font-weight: 800;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
}
.raffle-prize-info { flex: 1; }
.raffle-prize-info strong { display: block; font-size: 13px; }
.raffle-prize-info span { font-size: 11px; color: var(--muted); }
.raffle-prize-val { font-family: var(--font-display); font-size: 16px; font-weight: 700; color: var(--orange); }
.raffle-meta-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin: 20px 0; }
.raffle-meta-item { text-align: center; padding: 14px; background: var(--surface-2); border-radius: var(--radius); }
.raffle-meta-item strong { display: block; font-family: var(--font-display); font-size: 22px; font-weight: 700; color: var(--charcoal); }
.raffle-meta-item span { font-size: 10px; color: var(--muted); font-weight: 700; text-transform: uppercase; letter-spacing: .07em; }

/* ---------- Forum Styles ---------- */
.forum-cat {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  overflow: hidden;
  margin-bottom: 16px;
}
.forum-cat-header {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px 20px;
  border-bottom: 1px solid var(--line);
  background: var(--surface-2);
}
.forum-cat-icon {
  width: 40px; height: 40px;
  border-radius: var(--radius);
  display: grid;
  place-items: center;
  flex: 0 0 auto;
}
.forum-cat-icon svg { width: 20px; }
.fci-orange { background: var(--orange-bg); color: var(--orange); }
.fci-purple { background: var(--purple-bg); color: var(--purple); }
.fci-green  { background: var(--green-bg); color: #15803d; }
.fci-blue   { background: var(--blue-bg); color: var(--blue); }
.fci-slate  { background: var(--background); color: var(--text); }
.forum-cat-header h3 { font-family: var(--font-display); font-size: 16px; letter-spacing: -.02em; flex: 1; }
.forum-cat-header p { font-size: 11px; color: var(--muted); }
.forum-cat-header .stat { font-size: 11px; color: var(--muted); font-weight: 700; }
.forum-row {
  display: grid;
  grid-template-columns: 44px minmax(200px,1fr) 80px 80px minmax(180px,.8fr);
  gap: 12px;
  align-items: center;
  padding: 14px 20px;
  border-bottom: 1px solid var(--line-light);
  transition: background var(--trans);
}
.forum-row:last-child { border-bottom: none; }
.forum-row:hover { background: var(--surface-2); }
.forum-row-icon { width: 44px; height: 44px; border-radius: var(--radius); display: grid; place-items: center; background: var(--orange-bg); color: var(--orange); }
.forum-row-icon svg { width: 22px; }
.forum-row-info strong { font-size: 13px; font-weight: 700; display: block; }
.forum-row-info span { font-size: 11px; color: var(--muted); display: block; margin-top: 3px; }
.forum-row-stat { text-align: right; }
.forum-row-stat strong { display: block; font-size: 13px; font-weight: 700; }
.forum-row-stat span { display: block; font-size: 10px; color: var(--muted); }
.forum-row-latest { display: flex; align-items: center; gap: 9px; min-width: 0; }
.forum-row-latest strong { display: block; font-size: 11px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.forum-row-latest span { display: block; font-size: 10px; color: var(--muted); }

/* Thread / Topic list */
.topic-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 20px;
  border-bottom: 1px solid var(--line-light);
  transition: background var(--trans);
  text-decoration: none;
  color: inherit;
}
.topic-row:last-child { border-bottom: none; }
.topic-row:hover { background: var(--surface-2); }
.topic-row .topic-icon { width: 38px; height: 38px; border-radius: var(--radius-sm); display: grid; place-items: center; background: var(--background); color: var(--muted); flex: 0 0 auto; }
.topic-row .topic-icon svg { width: 18px; }
.topic-row .topic-icon.pinned { background: var(--orange-bg); color: var(--orange); }
.topic-row .topic-icon.hot { background: var(--red-bg); color: var(--red); }
.topic-row .topic-info { flex: 1; min-width: 0; }
.topic-row .topic-info h4 { font-size: 13px; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.topic-row .topic-info small { font-size: 11px; color: var(--muted); }
.topic-row .topic-stats { display: flex; gap: 20px; flex: 0 0 auto; }
.topic-row .topic-stat { text-align: right; }
.topic-row .topic-stat strong { display: block; font-size: 12px; font-weight: 700; }
.topic-row .topic-stat span { display: block; font-size: 10px; color: var(--muted); }

/* Thread posts */
.post-item {
  display: flex;
  gap: 16px;
  padding: 24px 0;
  border-bottom: 1px solid var(--line);
}
.post-item:last-child { border-bottom: none; }
.post-aside { flex: 0 0 100px; }
.post-author-name { font-weight: 700; font-size: 13px; }
.post-author-role { font-size: 10px; color: var(--muted); margin-top: 2px; }
.post-author-stats { margin-top: 10px; display: grid; gap: 4px; }
.post-author-stats span { font-size: 10px; color: var(--muted); }
.post-author-stats strong { display: inline; color: var(--ink); font-size: 10px; }
.post-main { flex: 1; min-width: 0; }
.post-header { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; }
.post-number { font-size: 11px; color: var(--muted); }
.post-date { font-size: 11px; color: var(--muted); margin-left: auto; }
.post-content { font-size: 14px; line-height: 1.75; color: var(--text); }
.post-content p + p { margin-top: 12px; }
.post-footer { display: flex; align-items: center; gap: 10px; margin-top: 14px; }
.post-quote {
  background: var(--surface-2);
  border-left: 3px solid var(--orange);
  padding: 10px 14px;
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  font-size: 13px;
  color: var(--text);
  margin: 12px 0;
}
.post-quote cite { display: block; font-size: 11px; color: var(--muted); font-style: normal; margin-bottom: 5px; }

/* ---------- Member Card ---------- */
.member-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 20px;
  text-align: center;
  transition: box-shadow var(--trans), transform var(--trans);
}
.member-card:hover { box-shadow: var(--shadow); transform: translateY(-2px); }
.member-card .avatar { margin: 0 auto 12px; }
.member-card h3 { font-size: 15px; font-weight: 700; }
.member-card .member-role { font-size: 11px; color: var(--muted); margin-top: 3px; }
.member-card .member-stats { display: flex; justify-content: center; gap: 20px; margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--line); }
.member-card .member-stat strong { display: block; font-size: 14px; font-weight: 700; color: var(--charcoal); }
.member-card .member-stat span { display: block; font-size: 10px; color: var(--muted); }
.member-card .member-badges { display: flex; justify-content: center; gap: 6px; margin-top: 10px; flex-wrap: wrap; }

/* ---------- Discord Block ---------- */
.discord-block {
  background: linear-gradient(135deg, #5865f2 0%, #7289da 100%);
  border-radius: var(--radius-xl);
  padding: 48px;
  color: white;
  position: relative;
  overflow: hidden;
}
.discord-block::before {
  content: '';
  position: absolute;
  top: -60px; right: -60px;
  width: 260px; height: 260px;
  border-radius: 50%;
  background: rgba(255,255,255,.07);
}
.discord-block::after {
  content: '';
  position: absolute;
  bottom: -80px; left: 30px;
  width: 200px; height: 200px;
  border-radius: 50%;
  background: rgba(255,255,255,.05);
}
.discord-block h2 { font-family: var(--font-display); font-size: 28px; letter-spacing: -.04em; margin-bottom: 10px; }
.discord-block p { color: rgba(255,255,255,.8); font-size: 14px; line-height: 1.65; max-width: 500px; }
.discord-block-inner { position: relative; z-index: 1; display: flex; align-items: center; justify-content: space-between; gap: 32px; flex-wrap: wrap; }
.discord-stats { display: flex; gap: 28px; margin-top: 20px; }
.discord-stat strong { display: block; font-family: var(--font-display); font-size: 24px; font-weight: 700; }
.discord-stat span { display: block; font-size: 11px; opacity: .75; margin-top: 2px; }
.discord-icon-large {
  width: 80px; height: 80px;
  border-radius: 20px;
  background: rgba(255,255,255,.15);
  display: grid;
  place-items: center;
  flex: 0 0 auto;
}
.discord-icon-large svg { width: 44px; fill: white; stroke: none; }

/* ---------- Newsletter ---------- */
.newsletter-block {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-xl);
  padding: 36px 40px;
  display: flex;
  align-items: center;
  gap: 40px;
}
.newsletter-copy { flex: 1; }
.newsletter-copy h3 { font-family: var(--font-display); font-size: 22px; letter-spacing: -.03em; }
.newsletter-copy p { font-size: 13px; color: var(--text); margin-top: 6px; line-height: 1.65; }
.newsletter-form { flex: 0 0 360px; }
.newsletter-input-row { display: flex; gap: 8px; }
.newsletter-input-row input {
  flex: 1;
  padding: 11px 16px;
  border: 1.5px solid var(--line);
  border-radius: var(--radius);
  font-size: 13px;
  color: var(--ink);
  outline: none;
  transition: border-color var(--trans);
}
.newsletter-input-row input:focus { border-color: var(--orange); }
.newsletter-form p { font-size: 10px; color: var(--muted); margin-top: 8px; }

/* ---------- Hero Variants ---------- */
.page-hero {
  background: linear-gradient(120deg, var(--charcoal) 0%, var(--charcoal-2) 100%);
  color: white;
  padding: 52px 0;
  position: relative;
  overflow: hidden;
}
.page-hero::after {
  content: '';
  position: absolute;
  right: -80px; top: -80px;
  width: 400px; height: 400px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(240,100,47,.18), transparent 70%);
}
.page-hero-inner { position: relative; z-index: 1; }
.page-hero h1 { font-family: var(--font-display); font-size: clamp(28px, 4vw, 42px); letter-spacing: -.04em; margin-bottom: 8px; }
.page-hero p { color: rgba(255,255,255,.75); font-size: 15px; max-width: 560px; }
.page-hero-actions { display: flex; gap: 10px; margin-top: 24px; flex-wrap: wrap; }
.page-hero-breadcrumb { margin-bottom: 16px; color: #ffe7d0; }
.page-hero-breadcrumb a { color: #fff8ef; font-weight: 700; }
.page-hero-breadcrumb a:hover { color: #ffffff; }

/* ---------- Listing Detail ---------- */
.listing-detail-grid { display: grid; grid-template-columns: minmax(0,1fr) 320px; gap: 24px; align-items: start; }
.listing-img-panel {
  background: linear-gradient(135deg, #f7f3ef, #ede8e2);
  border-radius: var(--radius-xl);
  padding: 48px;
  text-align: center;
  position: relative;
}
.listing-img-panel .item-emoji-lg { font-size: 100px; }
.listing-item-title { font-family: var(--font-display); font-size: 26px; letter-spacing: -.04em; }
.listing-attrs { display: flex; flex-wrap: wrap; gap: 8px; margin: 12px 0; }
.listing-price-panel { background: var(--surface-2); border-radius: var(--radius-lg); padding: 20px; margin-top: 20px; }
.listing-price-panel .price-main { font-family: var(--font-display); font-size: 34px; letter-spacing: -.04em; color: var(--orange); }
.listing-price-panel .price-sub { font-size: 12px; color: var(--muted); }
.listing-safety { background: var(--green-bg); border: 1px solid #bbf7d0; border-radius: var(--radius-lg); padding: 16px; }
.listing-safety h4 { font-size: 13px; font-weight: 700; color: #15803d; display: flex; align-items: center; gap: 7px; }
.listing-safety h4 svg { width: 16px; }
.listing-safety p { font-size: 12px; color: #166534; margin-top: 4px; line-height: 1.55; }
.listing-safety ul { margin-top: 8px; display: grid; gap: 4px; padding-left: 16px; list-style: disc; }
.listing-safety ul li { font-size: 11px; color: #166534; }

/* ---------- Alert / Saved Search ---------- */
.alert-row {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px;
  border-bottom: 1px solid var(--line-light);
  transition: background var(--trans);
}
.alert-row:last-child { border-bottom: none; }
.alert-row:hover { background: var(--surface-2); }
.alert-icon { width: 40px; height: 40px; border-radius: var(--radius); background: var(--orange-bg); color: var(--orange); display: grid; place-items: center; flex: 0 0 auto; }
.alert-icon svg { width: 20px; }
.alert-info { flex: 1; min-width: 0; }
.alert-info h4 { font-size: 13px; font-weight: 700; }
.alert-info span { font-size: 11px; color: var(--muted); }
.alert-info .alert-tags { display: flex; gap: 5px; margin-top: 5px; flex-wrap: wrap; }

/* ---------- Empty State ---------- */
.empty-state { text-align: center; padding: 60px 20px; }
.empty-state svg { width: 56px; margin: 0 auto 16px; color: var(--subtle); }
.empty-state h3 { font-size: 18px; font-weight: 700; margin-bottom: 8px; }
.empty-state p { font-size: 14px; color: var(--muted); max-width: 360px; margin: 0 auto 20px; }

/* ---------- Footer ---------- */
.site-footer {
  background: var(--charcoal);
  color: white;
  margin-top: 80px;
}
.footer-top { padding: 56px 0; display: grid; grid-template-columns: 280px 1fr 1fr 1fr; gap: 40px; }
.footer-brand .brand strong { color: white; }
.footer-brand .brand small { color: rgba(255,255,255,.4); }
.footer-tagline { font-size: 13px; color: rgba(255,255,255,.55); margin-top: 12px; line-height: 1.65; max-width: 220px; }
.footer-col h4 { font-size: 11px; font-weight: 800; text-transform: uppercase; letter-spacing: .1em; color: rgba(255,255,255,.45); margin-bottom: 14px; }
.footer-col a { display: block; font-size: 13px; color: rgba(255,255,255,.65); margin-bottom: 8px; transition: color var(--trans); }
.footer-col a:hover { color: white; }
.footer-coming-soon {
  display: block;
  margin-bottom: 8px;
  color: rgba(255,255,255,.3);
  font-size: 13px;
}
.footer-coming-soon small {
  margin-left: 4px;
  font-size: 8px;
  font-weight: 800;
  letter-spacing: .06em;
  text-transform: uppercase;
}
.page-coming-soon {
  display: inline-flex;
  margin-bottom: 10px;
  padding: 5px 9px;
  border: 1px solid rgba(255,255,255,.32);
  border-radius: 999px;
  color: rgba(255,255,255,.8);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: .1em;
  text-transform: uppercase;
}
.feature-preview-disabled {
  filter: grayscale(1);
  opacity: .38;
  pointer-events: none;
  user-select: none;
}
.footer-bottom { border-top: 1px solid rgba(255,255,255,.08); padding: 18px 0; display: flex; align-items: center; gap: 24px; justify-content: space-between; }
.footer-bottom p { font-size: 11px; color: rgba(255,255,255,.35); }
.footer-bottom a { font-size: 11px; color: rgba(255,255,255,.4); transition: color var(--trans); }
.footer-bottom a:hover { color: rgba(255,255,255,.8); }
.footer-bottom .footer-links { display: flex; gap: 20px; }
.footer-social { display: flex; gap: 10px; }
.footer-social a { width: 36px; height: 36px; border-radius: var(--radius-sm); background: rgba(255,255,255,.08); display: grid; place-items: center; color: rgba(255,255,255,.6); transition: background var(--trans), color var(--trans); }
.footer-social a:hover { background: rgba(255,255,255,.15); color: white; }
.footer-social svg { width: 16px; }

/* ---------- Home Page Hero ---------- */
.home-hero {
  background:
    radial-gradient(ellipse at 80% -10%, rgba(240,100,47,.22), transparent 50%),
    linear-gradient(130deg, var(--charcoal) 0%, var(--charcoal-2) 100%);
  color: white;
  position: relative;
  overflow: hidden;
}
.home-hero-glow-1 { position: absolute; top: 60px; left: 55%; width: 6px; height: 6px; border-radius: 50%; background: #f2a181; box-shadow: 0 0 24px #f2a181; }
.home-hero-glow-2 { position: absolute; bottom: 20%; right: 8%; width: 7px; height: 7px; border-radius: 50%; background: var(--orange); box-shadow: 0 0 28px var(--orange); }
.home-hero-inner {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(320px, 0.8fr);
  gap: 72px;
  padding: 80px 0 72px;
  align-items: center;
}
.home-hero-copy .eyebrow { color: #f2aa8e; }
.home-hero-copy h1 { font-family: var(--font-display); font-size: clamp(36px,4.5vw,60px); letter-spacing: -.05em; line-height: 1.01; margin: 14px 0 16px; }
.home-hero-copy h1 em { color: var(--orange-light); font-style: normal; }
.home-hero-copy p { color: rgba(255,255,255,.72); font-size: 15px; line-height: 1.75; max-width: 560px; }
.home-hero-actions { display: flex; gap: 10px; margin-top: 28px; flex-wrap: wrap; }
.hero-pulse-card {
  background: rgba(255,255,255,.08);
  border: 1px solid rgba(255,255,255,.14);
  border-radius: var(--radius-xl);
  padding: 24px;
  backdrop-filter: blur(12px);
  box-shadow: 0 24px 48px rgba(0,0,0,.2);
}
.pulse-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 20px; font-size: 12px; font-weight: 700; }
.pulse-grid { display: grid; grid-template-columns: repeat(3,1fr); gap: 0; }
.pulse-stat { padding: 12px; border-right: 1px solid rgba(255,255,255,.1); text-align: center; }
.pulse-stat:last-child { border-right: none; }
.pulse-stat strong { display: block; font-family: var(--font-display); font-size: 24px; font-weight: 700; letter-spacing: -.04em; }
.pulse-stat span { display: block; font-size: 9px; color: rgba(255,255,255,.55); font-weight: 700; text-transform: uppercase; letter-spacing: .07em; margin-top: 3px; }
.hero-recent { margin-top: 16px; display: grid; gap: 8px; }
.hero-recent-item { display: flex; align-items: center; gap: 10px; background: rgba(0,0,0,.2); border-radius: var(--radius); padding: 10px 14px; }
.hero-recent-item .item-emoji { font-size: 22px; }
.hero-recent-item-info { flex: 1; min-width: 0; }
.hero-recent-item-info strong { display: block; font-size: 11px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hero-recent-item-info span { display: block; font-size: 10px; color: rgba(255,255,255,.5); }
.hero-recent-item .item-price { font-family: var(--font-display); font-size: 14px; font-weight: 700; color: var(--orange-light); white-space: nowrap; }

/* ---------- Home Page Search ---------- */
.home-search-bar {
  background: white;
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-lg);
  padding: 8px;
  display: flex;
  gap: 8px;
  align-items: center;
  max-width: 720px;
  margin: 0 auto;
}
.home-search-bar input {
  flex: 1;
  border: none;
  outline: none;
  font-size: 15px;
  padding: 10px 16px;
  color: var(--ink);
  background: none;
}
.home-search-bar input::placeholder { color: var(--subtle); }
.home-search-bar select {
  border: none;
  outline: none;
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
  background: var(--surface-2);
  border-radius: var(--radius);
  padding: 0 12px;
  min-height: 40px;
  cursor: pointer;
}

/* ---------- Page layout helpers ---------- */
.two-col { display: grid; grid-template-columns: minmax(0,1fr) 300px; gap: 24px; align-items: start; }
.three-col { display: grid; grid-template-columns: repeat(3,1fr); gap: 20px; }
.four-col  { display: grid; grid-template-columns: repeat(4,1fr); gap: 20px; }
.two-col-even { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }

.page-section { padding: 48px 0; }
.page-section + .page-section { border-top: 1px solid var(--line); }

.surface-section { background: var(--surface); }
.orange-section { background: var(--orange); color: white; }

/* Support/info pages */
.info-content { max-width: 720px; }
.info-content h2 { font-family: var(--font-display); font-size: 22px; letter-spacing: -.03em; margin-top: 36px; margin-bottom: 10px; color: var(--charcoal); }
.info-content h3 { font-size: 16px; font-weight: 700; margin-top: 24px; margin-bottom: 8px; }
.info-content p { font-size: 14px; color: var(--text); line-height: 1.8; margin-bottom: 14px; }
.info-content ul, .info-content ol { padding-left: 24px; margin-bottom: 14px; }
.info-content li { font-size: 14px; color: var(--text); line-height: 1.75; margin-bottom: 6px; }
.info-content a { color: var(--orange); font-weight: 600; }
.info-content .callout { background: var(--orange-bg); border-left: 4px solid var(--orange); border-radius: 0 var(--radius) var(--radius) 0; padding: 14px 18px; margin: 20px 0; }
.info-content .callout p { margin: 0; color: var(--charcoal-2); font-weight: 600; }

/* ---------- Store ---------- */
.store-tier {
  background: var(--surface);
  border: 2px solid var(--line);
  border-radius: var(--radius-xl);
  overflow: hidden;
  transition: box-shadow var(--trans), transform var(--trans), border-color var(--trans);
}
.store-tier:hover { box-shadow: var(--shadow-lg); transform: translateY(-3px); }
.store-tier.featured { border-color: var(--orange); }
.store-tier-header { padding: 28px; text-align: center; border-bottom: 1px solid var(--line); }
.store-tier.featured .store-tier-header { background: var(--orange); color: white; }
.store-tier-name { font-family: var(--font-display); font-size: 22px; font-weight: 700; letter-spacing: -.03em; }
.store-tier-price { font-family: var(--font-display); font-size: 36px; font-weight: 700; margin-top: 8px; letter-spacing: -.04em; }
.store-tier-price sub { font-size: 16px; font-weight: 600; }
.store-tier-period { font-size: 12px; opacity: .7; }
.store-tier-body { padding: 24px; }
.store-feature { display: flex; align-items: center; gap: 10px; padding: 8px 0; font-size: 13px; }
.store-feature svg { width: 16px; flex: 0 0 auto; color: var(--green); }
.store-feature.miss svg { color: var(--subtle); }
.store-feature.miss { color: var(--muted); }

/* ---------- Search Results ---------- */
.search-result-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 18px 20px;
  display: flex;
  align-items: flex-start;
  gap: 16px;
  transition: box-shadow var(--trans);
}
.search-result-card:hover { box-shadow: var(--shadow); }
.search-result-thumb { width: 56px; height: 56px; border-radius: var(--radius); background: var(--background); display: grid; place-items: center; flex: 0 0 auto; font-size: 28px; }
.search-result-body h3 { font-size: 15px; font-weight: 700; }
.search-result-body p { font-size: 13px; color: var(--text); margin-top: 4px; line-height: 1.55; }
.search-result-meta { display: flex; align-items: center; gap: 10px; margin-top: 8px; }
mark { background: rgba(240,100,47,.18); color: var(--orange-dark); border-radius: 3px; padding: 0 2px; }

/* ---------- Watch button ---------- */
.watch-btn { transition: all var(--trans); }
.watch-btn.watching { background: var(--orange-bg); color: var(--orange); border-color: var(--orange); }
.watch-btn.watching svg { fill: var(--orange); }

/* ---------- Utility ---------- */
.flex { display: flex; }
.flex-center { display: flex; align-items: center; }
.flex-between { display: flex; align-items: center; justify-content: space-between; }
.gap-8  { gap: 8px; }
.gap-12 { gap: 12px; }
.gap-16 { gap: 16px; }
.gap-20 { gap: 20px; }
.gap-24 { gap: 24px; }
.mt-4  { margin-top: 4px; }
.mt-8  { margin-top: 8px; }
.mt-12 { margin-top: 12px; }
.mt-16 { margin-top: 16px; }
.mt-20 { margin-top: 20px; }
.mt-24 { margin-top: 24px; }
.mt-32 { margin-top: 32px; }
.mt-40 { margin-top: 40px; }
.mb-8  { margin-bottom: 8px; }
.mb-16 { margin-bottom: 16px; }
.mb-24 { margin-bottom: 24px; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
.text-center { text-align: center; }
.text-right { text-align: right; }
.text-muted { color: var(--muted); }
.text-orange { color: var(--orange); }
.text-green { color: var(--green); }
.text-red { color: var(--red); }
.font-display { font-family: var(--font-display); }
.fw-700 { font-weight: 700; }
.divider { height: 1px; background: var(--line); margin: 20px 0; }
.divider-v { width: 1px; background: var(--line); align-self: stretch; }
.hidden { display: none !important; }

/* ---------- Focus States ---------- */
:focus-visible {
  outline: 2px solid var(--orange);
  outline-offset: 3px;
  border-radius: 4px;
}
a:focus-visible, button:focus-visible { outline: 2px solid var(--orange); outline-offset: 3px; }

/* ---------- Responsive ---------- */
@media (max-width: 1024px) {
  .primary-nav > a, .primary-nav > .nav-drop > .nav-drop-toggle { padding: 0 7px; font-size: 12px; }
  .four-col  { grid-template-columns: repeat(2,1fr); }
  .footer-top { grid-template-columns: 1fr 1fr; gap: 28px; }
  .listing-detail-grid { grid-template-columns: 1fr; }
  .newsletter-block { flex-direction: column; gap: 20px; }
  .newsletter-form { flex: none; width: 100%; }
}

@media (max-width: 860px) {
  .primary-nav { display: none; }
  .hamburger { display: inline-flex; }
  .home-hero-inner { grid-template-columns: 1fr; gap: 32px; padding: 60px 0 52px; }
  .two-col { grid-template-columns: 1fr; }
  .three-col { grid-template-columns: repeat(2,1fr); }
  .discord-block { padding: 32px 24px; }
  .discord-block-inner { flex-direction: column; align-items: flex-start; }
  .forum-row { grid-template-columns: 44px 1fr; }
  .forum-row-stat, .forum-row-latest { display: none; }
  .raffle-meta-grid { grid-template-columns: repeat(2,1fr); }
}

@media (max-width: 600px) {
  .shell { width: min(100% - 28px, 1180px); }
  .nav-shell { width: min(100% - 28px, 1180px); }
  .three-col { grid-template-columns: 1fr; }
  .two-col-even { grid-template-columns: 1fr; }
  .event-card { flex-direction: column; }
  .event-date-block { flex-direction: row; justify-content: flex-start; padding: 12px 16px; gap: 12px; }
  .four-col { grid-template-columns: 1fr; }
  .footer-top { grid-template-columns: 1fr; }
  .raffle-meta-grid { grid-template-columns: 1fr; }
  .post-item { flex-direction: column; }
  .post-aside { flex: none; display: flex; align-items: center; gap: 12px; }
  .post-author-stats { display: none; }
  .topic-row .topic-stats { display: none; }
  .footer-bottom { flex-direction: column; gap: 12px; text-align: center; }
  .home-search-bar { flex-direction: column; align-items: stretch; }
  .home-search-bar select { text-align: left; }
  .page-hero { padding: 36px 0; }
  .discord-block { padding: 24px 20px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: 0.01ms !important; animation-duration: 0.01ms !important; }
}

/* ---------- 2026 Community Workshop Direction ---------- */
:root {
  --orange: #c6532f;
  --orange-dark: #9f3f24;
  --orange-light: #ed9a57;
  --orange-bg: #f5e0cc;
  --charcoal: #292722;
  --charcoal-2: #35322c;
  --charcoal-3: #49443b;
  --ink: #2f2c27;
  --text: #5e574d;
  --muted: #83796d;
  --line: #c9bca9;
  --line-light: #ded4c5;
  --surface: #f8f1e7;
  --surface-2: #efe5d7;
  --background: #e8ddce;
  --radius-sm: 2px;
  --radius: 4px;
  --radius-lg: 6px;
  --radius-xl: 8px;
  --shadow-sm: 2px 2px 0 rgba(54, 46, 37, .12);
  --shadow: 4px 4px 0 rgba(54, 46, 37, .13);
  --shadow-lg: 8px 8px 0 rgba(30, 27, 23, .18);
  --shadow-orange: 3px 3px 0 #87351f;
}

body {
  font-size: 14px;
  line-height: 1.5;
  background:
    linear-gradient(rgba(83, 72, 58, .035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(83, 72, 58, .035) 1px, transparent 1px),
    var(--background);
  background-size: 24px 24px;
}

.shell { width: min(1240px, calc(100% - 32px)); }
.demo-banner {
  padding: 5px 16px;
  background: #1f1e1a;
  color: #c9bdad;
  font-family: var(--font-display);
  font-size: 12px;
  letter-spacing: .08em;
  text-transform: uppercase;
}
.demo-banner span { color: var(--orange-light); }
.site-header {
  background: #2d2a24;
  border-bottom: 4px solid var(--orange);
  backdrop-filter: none;
}
.nav-shell {
  width: min(1240px, calc(100% - 32px));
  min-height: 54px;
  gap: 24px;
}
.brand strong {
  color: #f3e9da;
  font-size: 24px;
  line-height: .85;
  letter-spacing: .015em;
  text-transform: uppercase;
}
.brand small {
  color: #a99c8b;
  font-family: var(--font-display);
  font-size: 10px;
  letter-spacing: .16em;
}
.primary-nav { gap: 0; }
.primary-nav > a {
  height: 54px;
  padding: 0 12px;
  color: #cfc3b3;
  font-family: var(--font-display);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: .055em;
  text-transform: uppercase;
}
.primary-nav > a:hover,
.primary-nav > a.active { color: #fff4e6; background: rgba(255, 255, 255, .055); }
.primary-nav > a.active::after { height: 4px; border-radius: 0; }
.nav-actions .icon-btn, .nav-actions .btn-ghost { color: #e9ddcd; }
.nav-actions .icon-btn:hover, .nav-actions .btn-ghost:hover { background: #403c34; color: white; }

.btn, button.btn {
  min-height: 34px;
  padding: 0 14px;
  border-radius: 3px;
  font-family: var(--font-display);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: .04em;
  text-transform: uppercase;
}
.btn:hover { transform: translate(-1px, -1px); }
.btn-lg { min-height: 40px; padding: 0 18px; font-size: 15px; }
.btn-xl { min-height: 44px; padding: 0 22px; font-size: 16px; }
.btn-primary { box-shadow: var(--shadow-orange); }
.btn-coming-soon,
.btn-coming-soon:disabled {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: #f1eee9;
  background: #6c6b6a;
  border-color: #8e8c89;
  box-shadow: 2px 2px 0 rgba(25, 24, 23, .28);
  cursor: not-allowed;
  opacity: 1;
}
.btn-coming-soon:hover,
.btn-coming-soon:disabled:hover { background: #6c6b6a; filter: none; transform: none; }
.btn-coming-soon-label {
  padding-left: 8px;
  border-left: 1px solid rgba(255, 255, 255, .35);
  color: #f7f4ef;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: .06em;
  text-transform: uppercase;
}

.card, .item-card, .auction-card, .event-card, .forum-cat {
  border: 1px solid var(--line);
  border-top-width: 3px;
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow-sm);
}
.card-padded { padding: 18px; }
.page-section { padding: 38px 0; }
.surface-section { background: rgba(248, 241, 231, .55); border-block: 1px solid var(--line); }
.section-head { margin-bottom: 18px; }
.section-title, .page-hero h1 {
  font-family: var(--font-display);
  font-weight: 800;
  letter-spacing: .015em;
  line-height: 1;
  text-transform: uppercase;
}
.section-title { font-size: clamp(25px, 3vw, 34px); }
.eyebrow {
  color: var(--orange-dark);
  font-family: var(--font-display);
  font-size: 12px;
  letter-spacing: .14em;
  text-transform: uppercase;
}
.page-hero {
  padding: 30px 0;
  color: #f7eddf;
  background: #91442f;
  border-bottom: 5px solid #292722;
}
.page-hero p, .page-hero .breadcrumb { color: #e2d4c2; }
.page-hero-inner { gap: 8px; }

.form-control, input, select, textarea { border-radius: 2px; }
.four-col { gap: 14px; }
.three-col { gap: 14px; }
.two-col { gap: 18px; }

.workshop-hero {
  position: relative;
  overflow: hidden;
  color: #f5eadb;
  background: #292722;
  border-bottom: 6px solid var(--orange);
}
.workshop-hero::after {
  content: none;
  position: absolute;
  right: 4%;
  bottom: -60px;
  color: rgba(255,255,255,.035);
  font-family: var(--font-display);
  font-size: 260px;
  font-weight: 800;
  line-height: 1;
  pointer-events: none;
}
.workshop-hero-grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(400px, .9fr);
  gap: 42px;
  align-items: center;
  min-height: 430px;
  padding: 34px 0;
}
.workshop-hero-grid.workshop-hero-single {
  grid-template-columns: minmax(0, 820px);
}
.workshop-hero-copy { position: relative; z-index: 2; }
.workshop-hero h1 {
  max-width: 680px;
  margin: 10px 0 14px;
  font-family: var(--font-display);
  font-size: clamp(42px, 5.1vw, 70px);
  font-weight: 800;
  letter-spacing: .01em;
  line-height: .88;
  text-transform: uppercase;
}
.workshop-hero h1 em { color: var(--orange-light); font-style: normal; }
.workshop-hero-intro { max-width: 600px; color: #d6caba; font-size: 15px; }
.workshop-hero-actions { display: flex; gap: 10px; margin-top: 22px; flex-wrap: wrap; }
.hero-giveaway-card {
  position: relative;
  align-self: center;
  justify-self: end;
  display: grid;
  grid-template-areas:
    "kicker"
    "prize"
    "title"
    "copy"
    "action";
  grid-template-columns: minmax(0, 1fr);
  row-gap: 8px;
  width: min(100%, 468px);
  min-height: 0;
  padding: 24px;
  overflow: hidden;
  color: #fff6e9;
  background: #6b351f;
  border: 1px solid #bd5b32;
  border-left: 7px solid #e7794d;
  box-shadow: 7px 7px 0 rgba(18, 15, 13, .28);
}
.hero-giveaway-card::before {
  content: none;
  position: absolute;
  right: -18px;
  bottom: -40px;
  color: rgba(255,255,255,.06);
  font-family: var(--font-display);
  font-size: 240px;
  font-weight: 800;
  line-height: 1;
  pointer-events: none;
}
.hero-giveaway-card::after {
  content: none;
  position: absolute;
  right: 18px;
  bottom: 12px;
  color: rgba(255,255,255,.12);
  font-family: var(--font-display);
  font-size: 42px;
  font-weight: 800;
  letter-spacing: .04em;
  line-height: 1;
  pointer-events: none;
}
.hero-giveaway-card > * { position: relative; z-index: 1; }
.hero-giveaway-kicker {
  grid-area: kicker;
  display: flex;
  align-items: center;
  gap: 7px;
  color: #ffd29e;
  font-family: var(--font-display);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .09em;
  text-transform: uppercase;
}
.hero-giveaway-kicker .dot { background: #f5a145; box-shadow: 0 0 0 3px rgba(245,161,69,.17); }
.hero-giveaway-prize {
  grid-area: prize;
  display: inline-block;
  justify-self: start;
  margin-top: 5px;
  padding: 5px 8px;
  color: #2d1f1a;
  background: #f3b169;
  font-family: var(--font-display);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .07em;
  line-height: 1;
  text-transform: uppercase;
}
.hero-giveaway-card h2 {
  grid-area: title;
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(34px, 3.3vw, 44px);
  font-weight: 800;
  letter-spacing: .01em;
  line-height: .83;
  text-transform: uppercase;
}
.hero-giveaway-card p { grid-area: copy; max-width: 380px; margin: 0; color: #f5ddca; font-size: 12px; line-height: 1.5; }
.hero-giveaway-tags { display: none; }
.hero-giveaway-tags span {
  padding: 4px 6px;
  color: #ffeedc;
  border: 1px solid rgba(255,235,215,.3);
  background: #59372e;
  font-family: var(--font-display);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .07em;
  line-height: 1;
  text-transform: uppercase;
}
.hero-giveaway-card > .btn { grid-area: action; align-self: end; justify-self: start; min-height: 32px; padding-inline: 12px; }
.class-lineup {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 7px;
  padding: 16px;
  border: 1px solid #777064;
  border-top: 5px solid var(--orange);
  background: rgba(12, 12, 10, .35);
  box-shadow: 8px 8px 0 rgba(0,0,0,.22);
}
.class-tile {
  display: grid;
  min-height: 70px;
  place-items: center;
  border: 1px solid rgba(255,255,255,.12);
  background: linear-gradient(145deg, rgba(201,82,47,.35), rgba(75,107,120,.22));
  font-family: var(--font-display);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .06em;
  text-transform: uppercase;
}
.class-tile span { display: block; font-size: 24px; line-height: 1; }

.trust-strip {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border-bottom: 1px solid var(--line);
  background: var(--surface);
}
.trust-item {
  padding: 15px 18px;
  border-right: 1px solid var(--line);
  text-align: center;
}
.trust-item:last-child { border-right: 0; }
.trust-item strong { display: block; font-family: var(--font-display); font-size: 24px; line-height: 1; }
.trust-item span { color: var(--muted); font-size: 11px; }

.event-feature-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.event-feature {
  position: relative;
  min-height: 230px;
  overflow: hidden;
  padding: 22px;
  color: #f6ecdd;
  background: #8f422d;
  border: 1px solid #292722;
  border-top: 6px solid var(--orange-light);
  box-shadow: var(--shadow);
}
.event-feature:nth-child(2) { background: #a35331; }
.event-feature:nth-child(3) { background: #774735; }
.event-feature::after {
  content: none;
  position: absolute;
  right: 10px;
  bottom: -14px;
  font-size: 92px;
  opacity: .16;
  transform: rotate(-8deg);
}
.event-feature h3 { position: relative; z-index: 1; margin: 30px 0 8px; font-family: var(--font-display); font-size: 28px; line-height: .95; text-transform: uppercase; }
.event-feature p { position: relative; z-index: 1; max-width: 400px; color: #fff0dc; font-size: 12px; }
.event-feature .pill-live { color: #612718; background: #ffe2c3; }
.event-feature .pill-live::before { background: #a83f1f; }
.event-feature-actions { position: absolute; z-index: 2; left: 22px; bottom: 18px; display: flex; gap: 8px; }

.community-pulse-grid {
  display: grid;
  grid-template-columns: 1.15fr .85fr .8fr;
  gap: 14px;
}
.community-pulse-section {
  background:
    linear-gradient(115deg, rgba(32, 28, 25, .82), rgba(67, 39, 27, .57)),
    url("assets/map-community-pulse.jpg") center / cover;
  border-color: #715344;
}
.community-pulse-section .section-title {
  color: #fff4e7;
  text-shadow: 0 2px 12px rgba(20, 16, 13, .72);
}
.community-pulse-section .eyebrow {
  color: #ffd0a3;
  text-shadow: 0 1px 8px rgba(20, 16, 13, .72);
}
.community-pulse-section .pulse-panel {
  background: rgba(255, 248, 239, .88);
  border-color: rgba(255, 222, 190, .52);
  backdrop-filter: blur(2px);
}
.pulse-panel { min-height: 280px; }
.pulse-panel-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin: -18px -18px 14px;
  padding: 11px 16px;
  border-bottom: 1px solid var(--line);
  background: var(--surface-2);
  font-family: var(--font-display);
  font-size: 17px;
  font-weight: 800;
  letter-spacing: .04em;
  text-transform: uppercase;
}
.community-pulse-grid .hero-recent-item {
  color: var(--ink);
  background: #f3eeea;
  border: 1px solid #ddd5ce;
}
.pulse-placeholder {
  width: 34px;
  height: 34px;
  flex: 0 0 34px;
  border: 1px solid rgba(85, 62, 45, .42);
  border-radius: 4px;
  object-fit: cover;
}
.community-pulse-grid .hero-recent-item-info span { color: var(--text); }
.community-pulse-grid .hero-recent-item .item-price { color: #963a1b; }
.community-pulse-grid .pulse-panel:not(.discord-roster) .roster-row { border-color: var(--line); }
.community-pulse-grid .pulse-panel:not(.discord-roster) .roster-row small { color: var(--text); }
.card.discord-roster {
  color: #f1eadf;
  background: #313338;
  border-color: #1f2023;
}
.discord-widget-frame { width: 100%; min-height: 360px; border: 0; }
.discord-community-hero {
  position: relative;
  overflow: hidden;
  padding: 46px 0;
  color: white;
  background:
    linear-gradient(110deg, rgba(45, 48, 71, .98), rgba(77, 84, 132, .9)),
    repeating-linear-gradient(135deg, transparent 0 16px, rgba(255,255,255,.06) 16px 18px);
  border-bottom: 6px solid #292722;
}
.discord-community-hero::after {
  content: none;
  position: absolute;
  right: 4%;
  bottom: -20px;
  color: rgba(255,255,255,.055);
  font-family: var(--font-display);
  font-size: 110px;
  font-weight: 800;
  transform: rotate(-4deg);
}
.card.discord-roster .pulse-panel-title { color: #f1eadf; background: #25272b; border-color: #45474e; }
.card.discord-roster .pill-live { color: #612718; background: #ffe2c3; }
.card.discord-roster .pill-live::before { background: #a83f1f; }
.roster-row { display: flex; align-items: center; gap: 10px; padding: 7px 0; border-bottom: 1px solid var(--line); }
.card.discord-roster .roster-row { border-color: rgba(255,255,255,.12); }
.roster-row:last-child { border-bottom: 0; }
.presence { width: 9px; height: 9px; border-radius: 50%; background: #23a55a; box-shadow: 0 0 0 2px #313338; }
.roster-row small { display: block; color: var(--text); font-size: 10px; }
.card.discord-roster .roster-row small { color: #d4d7dd; }
.discord-channel-overview { display: flex; flex-direction: column; }
.channel-overview-intro { margin: 0 0 12px; color: var(--text); font-size: 12px; line-height: 1.5; }
.channel-overview-list { display: grid; gap: 7px; }
.channel-overview-row {
  display: grid;
  grid-template-columns: 78px minmax(0, 1fr);
  gap: 8px;
  padding: 9px 10px;
  border: 1px solid var(--line);
  border-radius: 4px;
  background: var(--surface-2);
  font-size: 11px;
  line-height: 1.35;
}
.channel-overview-row strong { color: var(--ink); }
.channel-overview-row span { color: var(--text); }
.channel-overview-count {
  display: inline-flex;
  align-items: center;
  min-height: 22px;
  padding: 0 7px;
  border-radius: 999px;
  color: #fff;
  background: #5865f2;
  font-family: var(--font-body);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0;
}
.discord-channel-overview .btn { margin-top: auto; }

.forum-cat { overflow: hidden; }
.forum-cat-header {
  position: relative;
  min-height: 92px;
  padding: 16px 20px;
  color: #f4eadb;
  background: #774735;
  border-bottom: 4px solid var(--orange);
}
.forum-cat-header::after {
  content: none;
  position: absolute;
  right: 22px;
  font-size: 66px;
  opacity: .16;
  transform: rotate(-8deg);
}
.forum-cat-header h3 { font-size: 25px; text-transform: uppercase; }
.forum-cat-header p, .forum-cat-header .stat { color: #cfc2b1; }
.forum-cat-icon {
  width: 46px;
  height: 46px;
  border: 1px solid rgba(255,255,255,.18);
  border-radius: 2px;
  background: rgba(198,83,47,.75);
}
.forum-row { min-height: 68px; padding: 10px 16px; }
.forum-row-icon { width: 38px; height: 38px; border-radius: 2px; }
.forum-row-info strong { font-family: var(--font-display); font-size: 16px; letter-spacing: .02em; }
.forum-row-info span { margin-top: 1px; }

.site-footer {
  border-top: 6px solid var(--orange);
  background: #292722;
}

.brand-mark {
  width: 53px;
  height: 24px;
}
.brand-mark img {
  width: auto;
  height: 24px;
  object-fit: contain;
}
.brand strong { font-size: 18px; line-height: 1; white-space: nowrap; }
.brand small { margin-top: 2px; line-height: 1; }
.primary-nav { gap: 0; }
.primary-nav > a {
  color: #fff6e9;
  padding-inline: 10px;
  background: #2d2a24;
}
.primary-nav > a:hover,
.primary-nav > a.active {
  color: white;
  background: var(--orange);
  filter: none;
}
.nav-actions .btn-primary {
  background: #9c3f20;
  box-shadow: 2px 2px 0 rgba(156, 63, 32, .3);
}
.nav-actions .btn-primary:hover,
.nav-actions .btn-primary.active {
  background: #bd4c25;
  box-shadow: 0 8px 24px rgba(156, 63, 32, .3);
}

.btn, button.btn { border: 1px solid rgba(45, 39, 32, .35); box-shadow: 2px 2px 0 rgba(45, 39, 32, .24); }
.btn:hover { transform: none; box-shadow: 2px 2px 0 rgba(45, 39, 32, .24); filter: brightness(1.06); }
.btn-primary, .btn-secondary, .btn-dark, .btn-discord, .btn-green, .btn-danger, .btn-outline-orange, .btn-light {
  border-radius: 3px;
  box-shadow: 2px 2px 0 rgba(45, 39, 32, .24);
}
.card:hover, .item-card:hover, .auction-card:hover, .event-card:hover,
.member-card:hover, .store-tier:hover, .search-result-card:hover {
  transform: none;
  box-shadow: var(--shadow-sm);
}
a.item-card:hover, a.member-card:hover, .guide-card:hover, .event-link-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow);
}

.key-market-section { padding-block: 28px; color: #fff8ef; background: #38352f; border-block: 5px solid #a65235; }
.key-market-section .eyebrow { color: #ffd09c; }
.key-market-section .section-title { color: #fff8ef; }
.key-market-header { display: grid; grid-template-columns: minmax(240px, .9fr) minmax(320px, 1.1fr); gap: 16px 42px; align-items: end; margin-bottom: 18px; }
.key-market-header .eyebrow, .key-market-header .section-title { grid-column: 1; }
.key-market-header .section-title { margin-top: -12px; }
.key-market-header p { grid-column: 2; grid-row: 1 / span 2; color: #f0ddc7; font-size: 12px; line-height: 1.55; }
.key-source-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.key-source-card {
  position: relative;
  display: flex;
  min-height: 168px;
  flex-direction: column;
  padding: 18px 124px 15px 18px;
  color: #fff8ef;
  border: 1px solid #837667;
  border-top: 4px solid #c66a3c;
  background: #474139;
  box-shadow: 3px 3px 0 rgba(20, 17, 13, .25);
  transition: background var(--trans), border-color var(--trans), transform var(--trans);
}
.key-source-image { position: absolute; top: 3px; right: -8px; width: 112px; height: 94px; object-fit: contain; }
.key-source-card:hover { color: #fff; border-color: #ffd09c; background: #554b42; transform: translateY(-2px); }
.key-source-name, .key-source-detail, .key-source-action { display: block; }
.key-source-name { color: #ffd09c; font-family: var(--font-display); font-size: 13px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; }
.key-source-price { margin-top: 17px; color: #fff8ef; font-family: var(--font-display); font-size: 32px; line-height: 1; letter-spacing: -.035em; }
.key-source-detail { margin-top: 7px; color: #ead9c5; font-size: 11px; }
.key-source-action { margin-top: auto; padding-top: 14px; color: #ffd09c; font-family: var(--font-display); font-size: 11px; font-weight: 800; letter-spacing: .075em; text-transform: uppercase; }
.key-source-action span { font-size: 15px; line-height: 0; }
.key-source-community { border-top-color: #b44d2a; }
.key-source-community .key-source-price { font-size: 25px; letter-spacing: -.02em; }
.item-code, .panel-code {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  flex: 0 0 auto;
  background: var(--orange-bg);
  color: var(--orange-dark);
  border: 1px solid var(--line);
  font-family: var(--font-display);
  font-weight: 800;
}
.newsletter-workshop {
  display: grid;
  grid-template-columns: 1fr minmax(320px, .7fr);
  gap: 30px;
  align-items: center;
  padding: 24px;
  border: 1px solid var(--line);
  border-left: 7px solid var(--orange);
  background: var(--surface);
}
.newsletter-workshop p { color: var(--text); }
.newsletter-workshop-form { display: flex; gap: 8px; }
.newsletter-workshop-form input { flex: 1; }

.support-nav { display: flex; gap: 5px; margin-bottom: 18px; flex-wrap: wrap; }
.support-nav a { padding: 8px 14px; color: white; background: #84482f; font-family: var(--font-display); font-weight: 700; text-transform: uppercase; }
.support-nav a:nth-child(2) { background: #965033; }
.support-nav a:nth-child(3) { background: #74483a; }
.support-nav a:nth-child(4) { background: #89513c; }
.support-nav a:nth-child(5) { background: #9b5637; }
.support-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.support-panel { display: flex; flex-direction: column; align-items: flex-start; min-height: 245px; }
.support-panel h2 { margin-top: 14px; font-family: var(--font-display); font-size: 24px; text-transform: uppercase; }
.support-panel p { margin: 6px 0 16px; color: var(--text); font-size: 12px; }
.support-panel .btn { align-self: stretch; justify-content: center; margin-top: auto; }
.faq-section { max-width: 900px; margin-top: 40px; }
.faq-section details { border-bottom: 1px solid var(--line); background: var(--surface); }
.faq-section summary { padding: 14px 16px; cursor: pointer; font-family: var(--font-display); font-size: 17px; font-weight: 700; text-transform: uppercase; }
.faq-section details p { padding: 0 16px 16px; color: var(--text); }
.staff-link-card p { margin-top: 8px; color: var(--muted); font-size: 11px; }
.sourcebans-shell { min-height: 720px; overflow: hidden; border: 1px solid var(--line); border-top: 5px solid var(--orange); background: white; }
.sourcebans-shell iframe { width: 100%; min-height: 720px; border: 0; }
.embed-note { margin-top: 8px; color: var(--muted); font-size: 11px; }

.event-list-grid { display: grid; grid-template-columns: 1fr; gap: 16px; }
.event-list-grid .event-link-card { min-height: 214px; overflow: hidden; }
.event-list-grid .event-body { display: flex; flex: 1 1 auto; flex-direction: column; padding: 22px 24px; }
.event-list-grid .event-body p { max-width: 680px; }
.event-list-grid .event-detail-link { margin-top: auto; margin-bottom: 0; }
.event-map-art { position: relative; flex: 0 0 min(36%, 360px); min-width: 300px; overflow: hidden; background: #2c2924; }
.event-map-art::after { content: ''; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(45, 39, 32, .22), transparent 34%); pointer-events: none; }
.event-map-art img { display: block; width: 100%; height: 100%; object-fit: cover; transition: transform .28s ease; }
.event-link-card:hover .event-map-art img { transform: scale(1.035); }
.event-type-label { display: inline-block; color: var(--orange-dark); font-family: var(--font-display); font-size: 12px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.page-hero .event-type-label {
  padding: 5px 8px;
  border: 1px solid rgba(255, 244, 231, .42);
  border-radius: 3px;
  color: #fff8ef;
  background: rgba(64, 29, 21, .28);
}
.event-detail-link { display: inline-block; margin-top: 12px; color: var(--orange-dark); font-family: var(--font-display); font-weight: 700; text-transform: uppercase; }
.event-detail-layout { display: grid; grid-template-columns: 1fr 340px; gap: 18px; }
.event-detail-copy h2, .event-detail-copy h3 { font-family: var(--font-display); text-transform: uppercase; }
.event-detail-copy h2 { font-size: 28px; }
.event-detail-copy h3 { margin-top: 24px; font-size: 18px; }
.event-detail-copy p { margin-top: 10px; color: var(--text); }
.event-detail-copy ul { margin-top: 10px; padding-left: 20px; list-style: square; color: var(--text); }
.event-info-panel { display: grid; gap: 12px; }
.event-info-panel div { padding-bottom: 10px; border-bottom: 1px solid var(--line); }
.event-info-panel span, .event-info-panel strong { display: block; }
.event-info-panel span { color: var(--muted); font-size: 10px; text-transform: uppercase; }

.forum-cat-announcements .forum-cat-header { background: #87442f; }
.forum-cat-trading .forum-cat-header { background: #a05232; }
.forum-cat-team-fortress-2 .forum-cat-header { background: #714638; }
.forum-cat-off-topic .forum-cat-header { background: #92533b; }
.forum-cat-site .forum-cat-header { background: #65483d; }
.forum-cat-archived { border-top-width: 1px; box-shadow: none; }
.forum-cat-archived .forum-cat-header { min-height: 58px; padding-block: 9px; background: #51483e; border-bottom-width: 2px; }
.forum-cat-archived .forum-cat-header::after { font-size: 34px; }
.forum-cat-archived .forum-cat-icon { width: 36px; height: 36px; }
.forum-cat-archived .forum-row { min-height: 52px; }
.forum-sidebar-title { margin-bottom: 9px; font-family: var(--font-display); font-size: 17px; text-transform: uppercase; }
.forum-sidebar-item { display: block; padding: 9px 0; border-bottom: 1px solid var(--line-light); }
.forum-sidebar-item:last-child { border-bottom: 0; }
.forum-sidebar-item strong, .forum-sidebar-item span, .forum-sidebar-item p { display: block; }
.forum-sidebar-item strong { font-family: var(--font-display); font-size: 14px; line-height: 1.1; }
.forum-sidebar-item span { margin-top: 3px; color: var(--muted); font-size: 9px; }
.forum-sidebar-item p { margin-top: 4px; color: var(--text); font-size: 10px; line-height: 1.35; }

@media (max-width: 1100px) {
  .brand strong { font-size: 16px; }
  .primary-nav > a { padding-inline: 7px; font-size: 12px; }
}

@media (max-width: 860px) {
  .workshop-hero-grid { grid-template-columns: 1fr; gap: 14px; min-height: 0; padding: 40px 0 22px; }
  .hero-giveaway-card { min-height: 0; max-width: 460px; width: 100%; margin: 0 auto; }
  .class-lineup { display: none; }
  .event-feature-grid, .community-pulse-grid { grid-template-columns: 1fr; }
  .event-feature { min-height: 220px; }
  .trust-strip { grid-template-columns: repeat(2, 1fr); }
  .trust-item:nth-child(2) { border-right: 0; }
  .trust-item:nth-child(-n+2) { border-bottom: 1px solid var(--line); }
  .key-market-grid, .newsletter-workshop, .event-detail-layout { grid-template-columns: 1fr; }
  .support-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 600px) {
  .shell, .nav-shell { width: min(100% - 22px, 1240px); }
  .workshop-hero h1 { font-size: 40px; }
  .hero-giveaway-card {
    grid-template-columns: minmax(0, 1fr);
    min-height: 0;
    padding: 18px;
  }
  .hero-giveaway-prize { font-size: 10px; letter-spacing: .045em; }
  .hero-giveaway-card h2 { font-size: 34px; }
  .trust-strip { grid-template-columns: 1fr 1fr; }
  .page-section { padding: 28px 0; }
  .event-list-grid, .support-grid, .key-source-links { grid-template-columns: 1fr; }
  .event-list-grid .event-link-card { flex-direction: column; }
  .event-list-grid .event-body { padding: 18px; }
  .event-map-art { flex-basis: auto; width: 100%; min-width: 0; height: 180px; }
  .newsletter-workshop-form { flex-direction: column; }
}

/* ---------- Theme toggle / dark mode ---------- */
.theme-toggle {
  display: inline-grid;
  width: 34px;
  height: 34px;
  place-items: center;
  flex: 0 0 34px;
  padding: 0;
  color: #f6e9d8;
  border: 1px solid #6b5c4c;
  border-radius: 3px;
  background: #342f29;
  box-shadow: 2px 2px 0 rgba(0, 0, 0, .22);
  cursor: pointer;
}

.theme-toggle:hover,
.theme-toggle:focus-visible {
  color: #fff;
  border-color: #e5a46c;
  background: #4a4035;
  outline: none;
}

.theme-toggle svg { width: 18px; height: 18px; }
.theme-icon-sun { display: none; }
html[data-theme="dark"] .theme-icon-moon { display: none; }
html[data-theme="dark"] .theme-icon-sun { display: block; }

html[data-theme="dark"] {
  --background: #292a2c;
}

html[data-theme="dark"] body {
  background:
    linear-gradient(rgba(226, 214, 197, .035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(226, 214, 197, .035) 1px, transparent 1px),
    var(--background);
}

/* Trading utility pages use the orange-tinted dark palette for every inherited label and control. */
html[data-theme="dark"] body[data-page="alerts"],
html[data-theme="dark"] body[data-page="support"] {
  --ink: #fff0e2;
  --text: #f2ddca;
  --muted: #dfc1aa;
  --subtle: #cfae95;
  --line: #896150;
  --line-light: #795849;
  --surface: #5a3e35;
  --surface-2: #624439;
  --orange-bg: #4f332c;
}
html[data-theme="dark"] body[data-page="alerts"] .section-title,
html[data-theme="dark"] body[data-page="support"] .section-title { color: #fff0e2; }
html[data-theme="dark"] body[data-page="alerts"] .section-head .eyebrow,
html[data-theme="dark"] body[data-page="support"] .section-head .eyebrow { color: #ed9a57; }

/* Cool blue-black foundations with a warm orange patina on former white panels. */
html[data-theme="dark"] .surface-section {
  background: #47332f;
  border-color: #79594d;
}

html[data-theme="dark"] .surface-section .section-title { color: #f7ede0; }
html[data-theme="dark"] .surface-section .eyebrow { color: #ed9a57; }

html[data-theme="dark"] .surface-section .card:not(.discord-roster) {
  color: #f7ede0;
  background: #5a3e35;
  border-color: #896252;
}

html[data-theme="dark"] .community-pulse-grid .pulse-panel-title {
  color: #f7ede0;
  border-color: #896252;
  background: #624238;
}

html[data-theme="dark"] .community-pulse-grid .hero-recent-item {
  color: #f7ede0;
  border-color: #805c4e;
  background: #624238;
}

html[data-theme="dark"] .community-pulse-section {
  background:
    linear-gradient(115deg, rgba(17, 22, 26, .88), rgba(57, 34, 27, .68)),
    url("assets/map-community-pulse.jpg") center / cover;
  border-color: #896252;
}

html[data-theme="dark"] .community-pulse-section .pulse-panel {
  background: rgba(54, 38, 32, .88);
  border-color: rgba(163, 111, 81, .62);
}

html[data-theme="dark"] .community-pulse-section .pulse-panel-title {
  color: #fff4e7;
  background: rgba(30, 29, 28, .78);
  border-color: rgba(255, 222, 190, .24);
}

html[data-theme="dark"] .community-pulse-section .hero-recent-item {
  background: rgba(54, 38, 32, .90);
  border-color: rgba(163, 111, 81, .56);
}

html[data-theme="dark"] .card.discord-roster {
  color: #f1eadf;
  background: #313338;
  border-color: #1f2023;
}

html[data-theme="dark"] .card.discord-roster .pulse-panel-title {
  color: #f1eadf;
  background: #25272b;
  border-color: #45474e;
}

html[data-theme="dark"] .card.discord-roster .roster-row small { color: #d4d7dd; }
html[data-theme="dark"] .card.discord-roster .presence { box-shadow: 0 0 0 2px #313338; }

html[data-theme="dark"] .community-pulse-grid .hero-recent-item-info span,
html[data-theme="dark"] .community-pulse-grid .pulse-panel:not(.discord-roster) .roster-row small {
  color: #decfbd;
}

html[data-theme="dark"] .community-pulse-grid .pulse-panel:not(.discord-roster) .roster-row { border-color: #805c4e; }
html[data-theme="dark"] .community-pulse-grid .hero-recent-item .item-price { color: #ffc194; }

html[data-theme="dark"] .trust-strip {
  color: #f7ede0;
  background: #51382f;
  border-color: #7c594b;
}

html[data-theme="dark"] .trust-item { border-color: #7c594b; }
html[data-theme="dark"] .trust-item span { color: #d4c6b6; }

html[data-theme="dark"] .newsletter-workshop {
  color: #f7ede0;
  border-color: #896252;
  background: #5a3e35;
}

html[data-theme="dark"] .newsletter-workshop .section-title { color: #f7ede0; }
html[data-theme="dark"] .newsletter-workshop p { color: #decfbd; }

/* Lift the charcoal and rust foundations already present in the light theme. */
html[data-theme="dark"] .site-header {
  background: #2d2a24;
  border-bottom-color: #c6532f;
}

html[data-theme="dark"] .primary-nav > a {
  color: #fff6e9;
  background: #2d2a24;
}

html[data-theme="dark"] .primary-nav > a:hover,
html[data-theme="dark"] .primary-nav > a.active {
  color: #fff;
  background: #c6532f;
}

html[data-theme="dark"] .nav-actions .icon-btn,
html[data-theme="dark"] .nav-actions .btn-ghost { color: #e9ddcd; }

html[data-theme="dark"] .nav-actions .icon-btn:hover,
html[data-theme="dark"] .nav-actions .btn-ghost:hover {
  color: #fff;
  background: #403c34;
}

html[data-theme="dark"] .workshop-hero { background: #2e2f31; }
html[data-theme="dark"] .hero-giveaway-card {
  background: #592b1e;
  border-color: #a95030;
  border-left-color: #d86636;
}

html[data-theme="dark"] .page-hero { background: #a05038; }

html[data-theme="dark"] .event-feature { background: #a25031; }
html[data-theme="dark"] .event-feature:nth-child(2) { background: #b45e39; }
html[data-theme="dark"] .event-feature:nth-child(3) { background: #895640; }

html[data-theme="dark"] .events-giveaways-section {
  background: linear-gradient(135deg, #704b3c 0%, #624338 100%);
  border-color: #9a6a53;
}
html[data-theme="dark"] .events-giveaways-section .section-title { color: #fff0e2; }
html[data-theme="dark"] .events-giveaways-section .event-feature { background: #93583b; }
html[data-theme="dark"] .events-giveaways-section .event-feature:nth-child(2) { background: #9f6040; }
html[data-theme="dark"] .events-giveaways-section .event-feature:nth-child(3) { background: #85533e; }

html[data-theme="dark"] .key-market-section { background: #343537; }
html[data-theme="dark"] .key-source-card { background: #444446; }
html[data-theme="dark"] .key-source-card:hover { background: #514e4a; }

html[data-theme="dark"] .site-footer { background: #2c2d2e; }
html[data-theme="dark"] .forum-cat-header { filter: brightness(1.1); }

/* Transparent sections sit directly on the darker backdrop, so their headings remain legible. */
html[data-theme="dark"] main > .page-section:not(.surface-section):not(.key-market-section) > .shell > .section-head .section-title { color: #f7ede0; }
html[data-theme="dark"] main > .page-section:not(.surface-section):not(.key-market-section) > .shell > .section-head .eyebrow { color: #ed9a57; }

@media (max-width: 1100px) {
  .nav-shell { gap: 12px; }
}

@media (max-width: 860px) {
  .key-market-header { grid-template-columns: 1fr; gap: 8px; }
  .key-market-header .eyebrow, .key-market-header .section-title, .key-market-header p { grid-column: 1; grid-row: auto; }
  .key-market-header .section-title { margin-top: 0; }
}

@media (max-width: 640px) {
  .key-source-grid { grid-template-columns: 1fr; }
  .key-source-card { min-height: 142px; }
}

/* ---------- Typography refinement ---------- */
body { letter-spacing: .003em; }

.demo-banner,
.eyebrow,
.hero-giveaway-kicker,
.hero-giveaway-prize,
.hero-giveaway-tags span,
.key-source-name,
.key-source-action,
.event-type-label,
.event-detail-link {
  font-family: var(--font-ui);
  font-weight: 700;
  letter-spacing: .07em;
  text-transform: uppercase;
}

.demo-banner { font-size: 11px; letter-spacing: .045em; }
.brand strong { letter-spacing: .005em; text-transform: none; }
.brand small { font-family: var(--font-ui); font-weight: 700; letter-spacing: .09em; text-transform: uppercase; }

.primary-nav > a,
.mobile-nav a,
.mobile-nav button.mob-link,
.btn,
button.btn,
.support-nav a,
.faq-section summary {
  font-family: var(--font-ui);
  font-weight: 600;
  letter-spacing: .015em;
  text-transform: none;
}

.primary-nav > a { font-size: 13px; }
.btn, button.btn { font-size: 13px; letter-spacing: .045em; text-transform: uppercase; }

.section-title,
.page-hero h1,
.workshop-hero h1,
.hero-giveaway-card h2,
.event-feature h3,
.forum-cat-header h3,
.support-panel h2,
.event-detail-copy h2,
.event-detail-copy h3 {
  letter-spacing: -.012em;
  text-transform: none;
}

.workshop-hero h1 { line-height: .95; }
.hero-giveaway-card h2 { line-height: .91; }

.pulse-panel-title,
.forum-sidebar-title,
.mobile-nav-section,
.footer-col h4,
.auction-timer small,
.current-bid-label,
.event-date-block .month,
.raffle-meta-item span,
.pulse-stat span,
.event-info-panel span {
  font-family: var(--font-ui);
  font-weight: 600;
  letter-spacing: .025em;
  text-transform: none;
}

.pulse-panel-title { font-size: 16px; }
.forum-cat-header h3,
.event-feature h3,
.key-source-price,
.support-panel h2,
.faq-section summary { font-family: var(--font-display); }

/* ---------- Forum board redesign ---------- */
body[data-page="forums"] { background: #ece6df; }
body[data-page="forums"] .page-hero {
  padding: 34px 0 38px;
  color: #fff7ec;
  background: radial-gradient(circle at 78% 10%, rgba(220,114,66,.3), transparent 29%), linear-gradient(112deg, #2f2c28, #49352e);
  border-bottom: 4px solid var(--orange);
}
body[data-page="forums"] .page-hero-breadcrumb { margin-bottom: 22px; }
body[data-page="forums"] .page-hero h1 { max-width: 760px; font-size: clamp(34px, 5vw, 48px); line-height: .95; letter-spacing: -.02em; }
body[data-page="forums"] .page-hero p { max-width: 650px; margin-top: 10px; color: #ead9c7; font-size: 15px; }
body[data-page="forums"] .page-hero .page-hero-actions { margin-top: 20px; }
body[data-page="forums"] .page-section { padding: 26px 0 56px; }
body[data-page="forums"] .two-col { grid-template-columns: minmax(0, 1fr) 300px; gap: 22px; }
body[data-page="forums"] #forum-list { display: grid !important; gap: 14px !important; }

body[data-page="forums"] .forum-cat { margin: 0; border: 1px solid #cfc5ba; border-radius: 7px; box-shadow: 0 2px 0 rgba(63,51,43,.08); }
body[data-page="forums"] .forum-cat-header { min-height: 68px; padding: 12px 16px; color: #fff9f0; background: #403a35; border-bottom: 3px solid var(--orange); }
body[data-page="forums"] .forum-cat-header::after { display: none; }
body[data-page="forums"] .forum-cat-header h3 { font-size: 20px; line-height: 1; letter-spacing: -.01em; text-transform: none; }
body[data-page="forums"] .forum-cat-header p,
body[data-page="forums"] .forum-cat-header .stat { color: #decdbd; }
body[data-page="forums"] .forum-cat-icon {
  width: 38px; height: 38px; border: 1px solid rgba(255,235,214,.32); border-radius: 5px;
  color: #ffe0bd; background: rgba(0,0,0,.15); font-family: var(--font-display); font-size: 14px; font-weight: 700;
}
body[data-page="forums"] .forum-cat-announcements .forum-cat-header { border-bottom-color: #e77a48; }
body[data-page="forums"] .forum-cat-trading .forum-cat-header { border-bottom-color: #d99b58; }
body[data-page="forums"] .forum-cat-team-fortress-2 .forum-cat-header { border-bottom-color: #a888d7; }
body[data-page="forums"] .forum-cat-off-topic .forum-cat-header { border-bottom-color: #75a98a; }
body[data-page="forums"] .forum-cat-site .forum-cat-header { border-bottom-color: #8ea0be; }
body[data-page="forums"] .forum-cat-archived .forum-cat-header { border-bottom-color: #9a928a; }

body[data-page="forums"] .forum-row {
  min-height: 72px; grid-template-columns: 40px minmax(190px,1fr) 70px 70px minmax(180px,.82fr);
  gap: 13px; padding: 11px 16px; color: var(--ink); background: var(--surface);
}
body[data-page="forums"] .forum-row:hover { background: #fffaf4; box-shadow: inset 4px 0 0 var(--orange); }
body[data-page="forums"] .forum-row-icon {
  width: 34px; height: 34px; border: 1px solid #e2c6b1; border-radius: 50%;
  color: var(--orange-dark); background: var(--orange-bg); font-family: var(--font-display); font-size: 12px; font-weight: 700;
}
body[data-page="forums"] .forum-row-info strong { color: var(--charcoal); font-family: var(--font-ui); font-size: 14px; letter-spacing: 0; }
body[data-page="forums"] .forum-row-info span { max-width: 440px; font-size: 11px; }
body[data-page="forums"] .forum-row-stat { padding-left: 8px; border-left: 1px solid var(--line-light); }
body[data-page="forums"] .forum-row-stat strong { font-family: var(--font-ui); font-size: 13px; }
body[data-page="forums"] .forum-row-stat span { letter-spacing: .04em; text-transform: uppercase; }
body[data-page="forums"] .forum-row-latest { min-height: 36px; padding-left: 11px; border-left: 1px solid var(--line-light); }
body[data-page="forums"] .forum-row-latest .avatar { display: none; }
body[data-page="forums"] .forum-row-latest strong { color: var(--charcoal); font-family: var(--font-ui); font-size: 12px; }

body[data-page="forums"] .two-col > aside { display: grid; align-content: start; gap: 14px; }
body[data-page="forums"] .two-col > aside > .card {
  margin: 0 !important; padding: 18px !important; border: 1px solid #cfc5ba; border-radius: 7px; box-shadow: 0 2px 0 rgba(63,51,43,.08);
}
body[data-page="forums"] .two-col > aside > .card h3 { color: var(--charcoal); font-family: var(--font-display); font-size: 19px !important; text-transform: none; }
body[data-page="forums"] .forum-sidebar-item { padding: 11px 0; }
body[data-page="forums"] .forum-sidebar-item strong { color: var(--charcoal); font-family: var(--font-ui); font-size: 13px; }
body[data-page="forums"] .forum-sidebar-item span { color: var(--muted); font-family: var(--font-ui); font-size: 10px; }

body[data-forum-view="topics"] main > .shell,
body[data-forum-view="thread"] main > .shell { padding: 28px 0 60px !important; }
body[data-page="forums"] .breadcrumb { font-family: var(--font-ui); font-size: 12px; }
body[data-page="forums"] .breadcrumb a { color: var(--orange-dark); }
body[data-page="forums"] .flex-between > div > h1 { color: var(--charcoal); font-size: clamp(26px,4vw,34px) !important; line-height: 1; letter-spacing: -.02em !important; }

body[data-page="forums"] #topic-list {
  position: relative; overflow: hidden !important; border: 1px solid #cfc5ba; border-radius: 7px;
  box-shadow: 0 2px 0 rgba(63,51,43,.08); background: var(--surface);
}
body[data-page="forums"] #topic-list::before {
  display: block; padding: 9px 18px; color: #d8c9bb; background: #403a35;
  content: "Topic                                           Replies     Views";
  font-family: var(--font-ui); font-size: 10px; font-weight: 700; letter-spacing: .07em; text-transform: uppercase; white-space: pre;
}
body[data-page="forums"] .topic-row { min-height: 66px; gap: 13px; padding: 11px 18px; border-bottom-color: var(--line); }
body[data-page="forums"] .topic-row:hover { background: #fffaf4; box-shadow: inset 4px 0 0 var(--orange); }
body[data-page="forums"] .topic-row .topic-icon {
  width: 34px; height: 34px; border: 1px solid var(--line); border-radius: 50%; color: var(--muted); background: var(--surface-2);
  font-family: var(--font-ui); font-size: 9px; font-weight: 700; letter-spacing: .03em;
}
body[data-page="forums"] .topic-row .topic-icon.pinned { border-color: #e6c19f; color: var(--orange-dark); background: var(--orange-bg); }
body[data-page="forums"] .topic-row .topic-info h4 { color: var(--charcoal); font-family: var(--font-ui); font-size: 14px; }
body[data-page="forums"] .topic-row .topic-info small { display: block; margin-top: 3px; font-family: var(--font-ui); font-size: 11px; }
body[data-page="forums"] .topic-row .topic-stats { gap: 0; }
body[data-page="forums"] .topic-row .topic-stat { min-width: 70px; padding-left: 12px; border-left: 1px solid var(--line-light); }
body[data-page="forums"] .topic-row .topic-stat strong { color: var(--charcoal); font-family: var(--font-ui); font-size: 13px; }
body[data-page="forums"] .topic-row .topic-stat span { font-family: var(--font-ui); letter-spacing: .04em; text-transform: uppercase; }

body[data-page="forums"] .pagination { margin-top: 18px; }
body[data-page="forums"] .page-btn { border-radius: 4px; font-family: var(--font-ui); }
body[data-page="forums"] #new-topic-panel,
body[data-page="forums"] #reply-panel { margin: 0 0 16px; border: 1px solid #d6b69e; border-top: 4px solid var(--orange); border-radius: 7px; box-shadow: none; }
body[data-page="forums"] #new-topic-panel h2,
body[data-page="forums"] #reply-panel h2 { color: var(--charcoal); font-family: var(--font-display); font-size: 20px !important; }

body[data-page="forums"] #post-list { display: grid; gap: 14px; border: 0 !important; }
body[data-page="forums"] .post-item {
  overflow: hidden; gap: 0; padding: 0; border: 1px solid #cfc5ba; border-radius: 7px;
  background: var(--surface); box-shadow: 0 2px 0 rgba(63,51,43,.08);
}
body[data-page="forums"] .post-aside {
  flex: 0 0 158px; min-height: 168px; padding: 18px 16px; border-right: 1px solid var(--line); background: #f6f0e8;
}
body[data-page="forums"] .post-aside .avatar { margin-bottom: 11px; border: 2px solid #fff; box-shadow: 0 1px 4px rgba(58,45,36,.14); }
body[data-page="forums"] .post-author-name { color: var(--charcoal); font-family: var(--font-ui); font-size: 14px; }
body[data-page="forums"] .post-author-stats { margin-top: 8px; padding-top: 8px; border-top: 1px solid #dfd4c8; }
body[data-page="forums"] .post-main { padding: 18px 22px; }
body[data-page="forums"] .post-header { min-height: 25px; margin: -18px -22px 18px; padding: 10px 14px; border-bottom: 1px solid var(--line); background: var(--surface-2); }
body[data-page="forums"] .post-header .pill { border-radius: 3px; color: var(--orange-dark); background: var(--orange-bg); font-family: var(--font-ui); font-weight: 700; }
body[data-page="forums"] .post-date { font-family: var(--font-ui); }
body[data-page="forums"] .post-content { color: var(--text); font-size: 14px; line-height: 1.78; }
body[data-page="forums"] .post-footer { padding-top: 14px; border-top: 1px solid var(--line-light); }
body[data-page="forums"] .post-footer .btn { min-height: 28px; border-radius: 4px; font-size: 10px; }

html[data-theme="dark"] body[data-page="forums"] { background: #202328; }
html[data-theme="dark"] body[data-page="forums"] .forum-cat,
html[data-theme="dark"] body[data-page="forums"] #topic-list,
html[data-theme="dark"] body[data-page="forums"] .post-item,
html[data-theme="dark"] body[data-page="forums"] .two-col > aside > .card { border-color: #6b5d55; box-shadow: none; }
html[data-theme="dark"] body[data-page="forums"] .forum-row,
html[data-theme="dark"] body[data-page="forums"] #topic-list,
html[data-theme="dark"] body[data-page="forums"] .post-item { background: #373838; }
html[data-theme="dark"] body[data-page="forums"] .forum-row:hover,
html[data-theme="dark"] body[data-page="forums"] .topic-row:hover { background: #484442; }
html[data-theme="dark"] body[data-page="forums"] .forum-row-info strong,
html[data-theme="dark"] body[data-page="forums"] .forum-row-latest strong,
html[data-theme="dark"] body[data-page="forums"] .topic-row .topic-info h4,
html[data-theme="dark"] body[data-page="forums"] .flex-between > div > h1,
html[data-theme="dark"] body[data-page="forums"] .two-col > aside > .card h3,
html[data-theme="dark"] body[data-page="forums"] .forum-sidebar-item strong,
html[data-theme="dark"] body[data-page="forums"] .post-author-name,
html[data-theme="dark"] body[data-page="forums"] #new-topic-panel h2,
html[data-theme="dark"] body[data-page="forums"] #reply-panel h2 { color: #fff1e2; }
html[data-theme="dark"] body[data-page="forums"] .post-aside { border-color: #61564f; background: #45403c; }
html[data-theme="dark"] body[data-page="forums"] .post-header { background: #3e3d3b; border-color: #625a55; }

@media (max-width: 860px) {
  body[data-page="forums"] .two-col { grid-template-columns: 1fr; }
  body[data-page="forums"] .forum-row { grid-template-columns: 40px minmax(0,1fr) 62px; }
  body[data-page="forums"] .forum-row-latest { display: none; }
  body[data-page="forums"] .forum-row-stat:nth-of-type(2) { display: none; }
}

/* Forum message reading rhythm */
body[data-page="forums"] .post-main {
  padding: 22px 26px 24px;
}

body[data-page="forums"] .post-header {
  margin: -22px -26px 22px;
}

body[data-page="forums"] .post-content {
  max-width: 900px;
  font-size: 15px;
  line-height: 1.84;
}

body[data-page="forums"] .post-content > * {
  margin-top: 0;
  margin-bottom: 1.2em;
}

body[data-page="forums"] .post-content > :last-child {
  margin-bottom: 0;
}

body[data-page="forums"] .post-content p + p {
  margin-top: .2em;
}

body[data-page="forums"] .post-content br + br {
  display: block;
  content: "";
  margin-block: .8em;
}

body[data-page="forums"] .post-content ul,
body[data-page="forums"] .post-content ol {
  padding-left: 1.45em;
}

body[data-page="forums"] .post-content li + li {
  margin-top: .42em;
}

body[data-page="forums"] .post-content .post-quote,
body[data-page="forums"] .post-content blockquote {
}

/* ---------- Member profile ---------- */
.steam-avatar { object-fit: cover; background: var(--surface-2); }
.steam-avatar::before { display: none; }
body[data-community-view="profile"] .member-profile-card { padding: 30px; }
body[data-community-view="profile"] .member-profile-header { display: flex; align-items: center; gap: 20px; }
body[data-community-view="profile"] .member-profile-avatar { width: 96px; height: 96px; border-radius: 9px; border-color: var(--surface); box-shadow: 0 3px 10px rgba(60,53,48,.16); }
body[data-community-view="profile"] .member-profile-copy { min-width: 0; display: grid; gap: 4px; }
body[data-community-view="profile"] .member-profile-name { margin: 0; color: var(--charcoal); font-size: clamp(28px, 4vw, 34px); line-height: 1.08; }
body[data-community-view="profile"] .member-profile-role { margin: 0; color: var(--muted); font-size: 14px; line-height: 1.45; }
body[data-community-view="profile"] .member-profile-copy .btn { width: fit-content; margin-top: 8px; }
body[data-community-view="profile"] .member-profile-stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; margin-top: 28px; padding-top: 22px; border-top: 1px solid var(--line); }
body[data-community-view="profile"] .member-profile-stat { min-width: 0; padding: 13px 15px; background: var(--surface-2); border: 1px solid var(--line-light); border-radius: 6px; }
body[data-community-view="profile"] .member-profile-stat strong { display: block; color: var(--charcoal); font-family: var(--font-ui); font-size: 17px; line-height: 1.2; }
body[data-community-view="profile"] .member-profile-stat span { display: block; margin-top: 4px; color: var(--muted); font-size: 11px; letter-spacing: .02em; }
html[data-theme="dark"] body[data-community-view="profile"] .member-profile-name,
html[data-theme="dark"] body[data-community-view="profile"] .member-profile-stat strong { color: #fff1e2; }
html[data-theme="dark"] body[data-community-view="profile"] .member-profile-stat { background: #3e3d3b; border-color: #625a55; }
@media (max-width: 600px) {
  body[data-community-view="profile"] .member-profile-card { padding: 22px; }
  body[data-community-view="profile"] .member-profile-header { align-items: flex-start; gap: 15px; }
  body[data-community-view="profile"] .member-profile-avatar { width: 72px; height: 72px; }
  body[data-community-view="profile"] .member-profile-stats { grid-template-columns: 1fr; gap: 8px; margin-top: 22px; padding-top: 18px; }
}
/* ---------- Forum dark-mode completion ---------- */
html[data-theme="dark"] body[data-page="forums"] {
  --ink: #fff1e2;
  --text: #ead7c6;
  --muted: #cbb8a6;
  --subtle: #ad9a8b;
  --line: #665c55;
  --line-light: #554e48;
  --surface: #373838;
  --surface-2: #3e3d3b;
  --orange-bg: #4c352d;
}
html[data-theme="dark"] body[data-page="forums"] .topic-row .topic-icon,
html[data-theme="dark"] body[data-page="forums"] .forum-row-icon {
  background: #474542; border-color: #6c615a; color: #e7c3a4;
}
html[data-theme="dark"] body[data-page="forums"] .forum-row-stat,
html[data-theme="dark"] body[data-page="forums"] .forum-row-latest,
html[data-theme="dark"] body[data-page="forums"] .topic-row .topic-stat { border-color: #554e48; }
html[data-theme="dark"] body[data-page="forums"] #topic-list::before {
  background: #2e2f30; color: #dbc6b3; border-bottom: 1px solid #554e48;
}
html[data-theme="dark"] body[data-page="forums"] .two-col > aside > .card,
html[data-theme="dark"] body[data-page="forums"] #new-topic-panel,
html[data-theme="dark"] body[data-page="forums"] #reply-panel {
  background: #373838;
}
html[data-theme="dark"] body[data-page="forums"] .forum-row-info span,
html[data-theme="dark"] body[data-page="forums"] .forum-row-stat span,
html[data-theme="dark"] body[data-page="forums"] .forum-row-latest span,
html[data-theme="dark"] body[data-page="forums"] .topic-row .topic-info small,
html[data-theme="dark"] body[data-page="forums"] .topic-row .topic-stat span,
html[data-theme="dark"] body[data-page="forums"] .forum-sidebar-item span,
html[data-theme="dark"] body[data-page="forums"] .post-date,
html[data-theme="dark"] body[data-page="forums"] .post-author-stats span,
html[data-theme="dark"] body[data-page="forums"] .post-content { color: #cbb8a6; }
html[data-theme="dark"] body[data-page="forums"] .post-footer,
html[data-theme="dark"] body[data-page="forums"] .post-author-stats { border-color: #554e48; }
html[data-theme="dark"] body[data-page="forums"] .post-footer .btn-ghost {
  color: #f5e3d0; background: #45413e; border-color: #6c615a;
}
html[data-theme="dark"] body[data-page="forums"] .post-footer .btn-ghost:hover,
html[data-theme="dark"] body[data-page="forums"] .post-footer .btn-ghost.active {
  color: #fff7ed; background: #59433a;
}
html[data-theme="dark"] body[data-page="forums"] .post-content blockquote,
html[data-theme="dark"] body[data-page="forums"] .post-content .post-quote {
  color: #ead7c6; background: #43413f; border-color: #d67745;
}
html[data-theme="dark"] body[data-page="forums"] .form-control {
  color: #fff1e2; background: #2d2e30; border-color: #6c615a;
}
html[data-theme="dark"] body[data-page="forums"] .post-aside .avatar { border-color: #5d554e; }

/* ---------- Dark-mode availability and member profile contrast ---------- */
html[data-theme="dark"] .primary-nav > a.nav-coming-soon,
html[data-theme="dark"] .primary-nav > a.nav-coming-soon:hover {
  color: #a39c95;
  background: #2d2a24;
}

html[data-theme="dark"] .primary-nav > a.nav-coming-soon small { color: #79736d; }

html[data-theme="dark"] .btn-coming-soon,
html[data-theme="dark"] .btn-coming-soon:disabled,
html[data-theme="dark"] .btn-coming-soon:hover,
html[data-theme="dark"] .btn-coming-soon:disabled:hover {
  color: #f1eee9;
  background: #62615f;
  border-color: #84817e;
}

html[data-theme="dark"] body[data-community-view="profile"] {
  --ink: #fff1e2;
  --text: #ead7c6;
  --muted: #cbb8a6;
  --subtle: #ad9a8b;
  --line: #665c55;
  --line-light: #554e48;
  --surface: #373838;
  --surface-2: #3e3d3b;
}

html[data-theme="dark"] body[data-community-view="profile"] #member-profile > .card {
  color: var(--text);
  background: var(--surface);
  border-color: #6b5d55;
  box-shadow: none;
}

html[data-theme="dark"] body[data-community-view="profile"] .member-profile-name,
html[data-theme="dark"] body[data-community-view="profile"] #member-profile h2,
html[data-theme="dark"] body[data-community-view="profile"] #member-profile .topic-row h4 {
  color: #fff7ed;
}

html[data-theme="dark"] body[data-community-view="profile"] .member-profile-role,
html[data-theme="dark"] body[data-community-view="profile"] .member-profile-stat span,
html[data-theme="dark"] body[data-community-view="profile"] #member-profile .topic-row small { color: #d7c3b0; }

html[data-theme="dark"] body[data-community-view="profile"] .member-profile-avatar { border-color: #5d554e; box-shadow: 0 3px 10px rgba(0,0,0,.28); }
html[data-theme="dark"] body[data-community-view="profile"] .member-profile-stat { background: #3e3d3b; border-color: #625a55; }
html[data-theme="dark"] body[data-community-view="profile"] .member-profile-stat strong { color: #fff1e2; }
html[data-theme="dark"] body[data-community-view="profile"] #member-profile .topic-row { background: #373838; border-color: #554e48; }
html[data-theme="dark"] body[data-community-view="profile"] #member-profile .topic-row:hover { background: #484442; }

/* ---------- Staff administration console ---------- */
.admin-page { min-height: 80vh; background: var(--bg); }
.admin-shell { max-width: 1240px; padding: 30px 0 70px; display: grid; gap: 34px; }
.admin-hero { display: flex; justify-content: space-between; align-items: end; gap: 24px; padding: 30px; border-radius: 10px; background: #242a31; color: #f8eee3; border-left: 5px solid var(--orange); }
.admin-hero h1 { margin: 4px 0 5px; color: #fff; font: 700 clamp(30px,5vw,46px)/1 var(--font-display); }
.admin-hero p { margin: 0; color: #cbd1d7; }
.admin-identity { display: flex; align-items: center; gap: 8px; padding: 9px 12px; border: 1px solid #4b535d; border-radius: 6px; font-size: 12px; white-space: nowrap; }
.status-dot { width: 8px; height: 8px; border-radius: 50%; background: #61c77b; box-shadow: 0 0 0 4px rgba(97,199,123,.12); }
.admin-section-heading { display: flex; justify-content: space-between; align-items: end; gap: 20px; margin-bottom: 14px; }
.admin-section-heading.compact { margin-bottom: 16px; }
.admin-section-heading h2 { margin: 2px 0 0; color: var(--charcoal); font: 700 23px/1.15 var(--font-display); }
.admin-section-heading p { max-width: 560px; margin: 0; color: var(--muted); font-size: 12px; }
.admin-stat-grid { display: grid; grid-template-columns: repeat(6,minmax(0,1fr)); gap: 10px; margin-bottom: 14px; }
.admin-stat { padding: 18px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); box-shadow: var(--shadow-sm); }
.admin-stat strong { display: block; color: var(--charcoal); font: 700 25px/1 var(--font-ui); }
.admin-stat span { display: block; margin-top: 7px; color: var(--muted); font-size: 11px; }
.admin-grid-two { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 14px; }
.admin-panel { min-width: 0; padding: 20px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); box-shadow: var(--shadow-sm); }
.admin-panel > h3 { margin: 0 0 14px; color: var(--charcoal); font-size: 14px; }
.visitor-chart { height: 185px; display: flex; align-items: end; gap: 4px; padding-top: 15px; border-bottom: 1px solid var(--line); }
.visitor-bar { flex: 1; min-width: 3px; border-radius: 3px 3px 0 0; background: var(--orange); opacity: .82; }
.admin-list, .admin-member-list { display: grid; gap: 8px; }
.admin-list { max-height: 320px; overflow: auto; }
.admin-list-row, .admin-member, .admin-report { display: flex; justify-content: space-between; gap: 14px; padding: 12px; border: 1px solid var(--line-light); border-radius: 6px; background: var(--surface-2); }
.admin-list-row p, .admin-member p, .admin-report p { margin: 3px 0 0; color: var(--muted); font-size: 11px; line-height: 1.45; }
.admin-list-row time { color: var(--muted); font-size: 10px; white-space: nowrap; }
.admin-search { display: flex; gap: 8px; margin-bottom: 15px; }
.admin-search input { flex: 1; min-width: 0; }
.admin-member { align-items: center; }
.admin-member-heading { display: grid; gap: 3px; }
.admin-member-heading span { color: var(--muted); font-size: 11px; }
.admin-controls { display: flex; align-items: center; justify-content: flex-end; flex-wrap: wrap; gap: 6px; }
.admin-select, .admin-form input, .admin-form select, .admin-form textarea, .admin-search input { min-height: 39px; padding: 8px 10px; border: 1px solid var(--line); border-radius: 5px; color: var(--charcoal); background: var(--surface); font: inherit; }
.btn-danger { color: #fff; background: #9e3e35; border-color: #9e3e35; }
.admin-report { display: grid; }
.admin-report small { color: var(--muted); }
.admin-form { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 12px; }
.admin-form label { display: grid; gap: 5px; color: var(--muted); font-size: 11px; }
.admin-form .full { grid-column: 1/-1; }
.admin-form textarea { min-height: 82px; resize: vertical; }
.admin-message { position: sticky; top: 78px; z-index: 20; padding: 12px 15px; border-radius: 6px; color: #163d21; background: #dff3e4; border: 1px solid #93cea1; }
.admin-message.is-error { color: #6c211b; background: #f8dedb; border-color: #d9958e; }
.admin-empty { margin: 0; padding: 12px; color: var(--muted); font-size: 12px; }
.admin-dialog { width: min(760px,calc(100% - 30px)); max-height: 75vh; padding: 20px; border: 1px solid var(--line); border-radius: 9px; background: var(--surface); color: var(--charcoal); }
.admin-dialog::backdrop { background: rgba(15,17,20,.72); }
.admin-dialog-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 14px; }
html[data-theme="dark"] .admin-page { background: #25292d; }
html[data-theme="dark"] .admin-panel, html[data-theme="dark"] .admin-stat, html[data-theme="dark"] .admin-dialog { background: #34383d; border-color: #50565d; }
html[data-theme="dark"] .admin-list-row, html[data-theme="dark"] .admin-member, html[data-theme="dark"] .admin-report { background: #2c3035; border-color: #4a5057; }
html[data-theme="dark"] .admin-section-heading h2, html[data-theme="dark"] .admin-stat strong, html[data-theme="dark"] .admin-panel > h3 { color: #fff1e2; }
html[data-theme="dark"] .admin-select, html[data-theme="dark"] .admin-form input, html[data-theme="dark"] .admin-form select, html[data-theme="dark"] .admin-form textarea, html[data-theme="dark"] .admin-search input { color: #fff1e2; background: #292d31; border-color: #555c63; }
@media (max-width: 900px) { .admin-stat-grid { grid-template-columns: repeat(3,1fr); } .admin-grid-two { grid-template-columns: 1fr; } }
@media (max-width: 620px) { .admin-shell { padding-top: 20px; } .admin-hero, .admin-section-heading, .admin-member { align-items: flex-start; flex-direction: column; } .admin-stat-grid { grid-template-columns: repeat(2,1fr); } .admin-search { flex-direction: column; } .admin-form { grid-template-columns: 1fr; } .admin-form .full { grid-column: auto; } .admin-controls { justify-content: flex-start; } }

.member-profile-links { display:flex; flex-wrap:wrap; gap:8px; margin-top:8px; }
.member-profile-links .btn { margin-top:0 !important; }

.visitor-chart { justify-content:flex-start; }
.visitor-bar { flex:1 1 10px; max-width:18px; }

/* ---------- Forum topic-list and composer quality-of-life ---------- */
body[data-page="forums"] .topic-avatar-wrap { position:relative; flex:0 0 46px; display:grid; place-items:center; }
body[data-page="forums"] .topic-author-avatar { width:44px; height:44px; border-radius:8px; object-fit:cover; box-shadow:0 1px 4px rgba(35,26,20,.18); }
body[data-page="forums"] .topic-pin-badge { position:absolute; right:-4px; bottom:-4px; padding:2px 4px; border-radius:3px; color:#fff; background:var(--orange); font:800 8px/1 var(--font-ui); letter-spacing:.05em; }
body[data-page="forums"] .older-topics-toggle { padding:0; text-align:center; background:var(--surface-2); border-top:1px solid var(--line); }
body[data-page="forums"] .older-topics-toggle button { width:100%; padding:13px; border:0; color:var(--orange-dark); background:transparent; font:700 12px/1 var(--font-ui); cursor:pointer; }
body[data-page="forums"] .older-topics-toggle button:hover { background:var(--orange-bg); }
body[data-page="forums"] .pagination { align-items:center; flex-wrap:wrap; padding:9px; border:1px solid var(--line); border-radius:7px; background:var(--surface); box-shadow:var(--shadow-sm); }
body[data-page="forums"] .page-nav { min-width:auto; padding-inline:12px; }
body[data-page="forums"] .page-ellipsis { padding:0 4px; color:var(--muted); }
body[data-page="forums"] .page-summary { margin-left:auto; padding:0 9px; color:var(--muted); font-size:11px; }
body[data-page="forums"] .post-item { min-height:270px; margin:0 0 18px; border:1px solid var(--line); border-radius:8px; overflow:hidden; background:var(--surface); box-shadow:var(--shadow-sm); }
body[data-page="forums"] .post-aside { flex:0 0 178px; padding:28px 20px; text-align:center; }
body[data-page="forums"] .post-aside .avatar { width:76px; height:76px; margin:0 auto 14px; }
body[data-page="forums"] .post-main { display:flex; flex-direction:column; min-height:268px; padding:0 32px 25px; }
body[data-page="forums"] .post-header { margin:0 -32px 28px; padding:13px 18px; border-bottom:1px solid var(--line-light); background:var(--surface-2); }
body[data-page="forums"] .post-content { flex:1; min-height:125px; font-size:14px; line-height:1.9; }
body[data-page="forums"] .post-footer { margin-top:30px; padding-top:14px; border-top:1px solid var(--line-light); }
.forum-composer { overflow:hidden; border:1px solid var(--line); border-radius:7px; background:var(--surface); }
.composer-toolbar { display:flex; gap:2px; padding:7px; border-bottom:1px solid var(--line-light); background:var(--surface-2); }
.composer-toolbar button { min-width:34px; min-height:32px; padding:5px 9px; border:0; border-radius:4px; color:var(--text); background:transparent; font:600 12px var(--font-ui); cursor:pointer; }
.composer-toolbar button:hover { color:var(--orange-dark); background:var(--orange-bg); }
.forum-composer .composer-textarea { min-height:210px; border:0; border-radius:0; box-shadow:none; resize:vertical; }
.composer-dropzone { display:flex; align-items:center; flex-wrap:wrap; gap:7px; min-height:62px; padding:12px 15px; border-top:1px solid var(--line-light); color:var(--muted); background:var(--surface-2); font-size:12px; transition:.15s ease; }
.composer-dropzone.is-dragging { color:var(--orange-dark); background:var(--orange-bg); box-shadow:inset 0 0 0 2px var(--orange); }
.composer-dropzone small { flex-basis:100%; margin-left:25px; color:var(--subtle); font-size:10px; }
.composer-file-label { color:var(--orange-dark); font-weight:700; text-decoration:underline; cursor:pointer; }
.composer-previews { display:grid; grid-template-columns:repeat(auto-fill,minmax(210px,1fr)); gap:8px; padding:0 12px 12px; background:var(--surface-2); }
.composer-previews:empty { display:none; }
.composer-preview { display:grid; grid-template-columns:48px 1fr auto; align-items:center; gap:9px; min-width:0; padding:7px; border:1px solid var(--line); border-radius:5px; background:var(--surface); }
.composer-preview img { width:48px; height:48px; border-radius:4px; object-fit:cover; }
.composer-preview div { min-width:0; }
.composer-preview strong,.composer-preview small { display:block; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.composer-preview strong { font-size:11px; }.composer-preview small { color:var(--muted); font-size:9px; }
.composer-preview button { border:0; color:var(--red); background:transparent; font-size:10px; cursor:pointer; }
.post-attachment-gallery { display:grid; grid-template-columns:repeat(auto-fit,minmax(240px,1fr)); gap:12px; margin-top:22px; }
.post-image-attachment { overflow:hidden; margin:0; border:1px solid var(--line); border-radius:7px; background:var(--surface-2); }
.post-image-attachment img { display:block; width:100%; max-height:520px; object-fit:contain; background:#151515; }
.post-image-attachment figcaption { padding:8px 10px; color:var(--muted); font-size:10px; }
.attachment-unavailable { padding:10px; color:var(--muted); background:var(--surface-2); }
html[data-theme="dark"] body[data-page="forums"] .older-topics-toggle,html[data-theme="dark"] .composer-toolbar,html[data-theme="dark"] .composer-dropzone,html[data-theme="dark"] .composer-previews { background:#303235; }
html[data-theme="dark"] body[data-page="forums"] .pagination,html[data-theme="dark"] .forum-composer,html[data-theme="dark"] .composer-preview { background:#373838; border-color:#5b554f; }
html[data-theme="dark"] body[data-page="forums"] .older-topics-toggle button,html[data-theme="dark"] .composer-file-label { color:#ffad70; }
@media (max-width:700px) { body[data-page="forums"] .post-item { min-height:0; } body[data-page="forums"] .post-aside { flex:none; padding:16px; text-align:left; } body[data-page="forums"] .post-aside .avatar { width:52px; height:52px; margin:0; } body[data-page="forums"] .post-main { min-height:0; padding:0 18px 20px; } body[data-page="forums"] .post-header { margin:0 -18px 20px; } body[data-page="forums"] .page-summary { flex-basis:100%; margin:8px 0 0; text-align:center; } }

/* Compact forum author cards */
body[data-page="forums"] .post-aside {
  flex:0 0 190px;
  min-height:0;
  display:flex;
  flex-direction:column;
  align-items:center;
  gap:0;
  padding:24px 18px 20px;
  text-align:center;
}
body[data-page="forums"] .post-author-name {
  order:0;
  display:block;
  width:100%;
  margin:0 0 14px;
  color:var(--charcoal);
  font:800 15px/1.2 var(--font-ui);
  overflow-wrap:anywhere;
}
body[data-page="forums"] .post-aside .post-avatar {
  order:1;
  width:88px;
  height:88px;
  margin:0 0 11px;
  border-radius:50%;
  object-fit:cover;
}
body[data-page="forums"] .post-author-role {
  order:2;
  margin:0;
  color:var(--text);
  font:600 12px/1.3 var(--font-ui);
}
body[data-page="forums"] .post-author-stats {
  order:3;
  display:flex;
  align-items:center;
  justify-content:center;
  gap:5px;
  width:100%;
  margin:18px 0 0;
  padding:14px 0 0;
  border-top:1px solid var(--line);
}
body[data-page="forums"] .post-author-stats span { color:var(--muted); font-size:12px; }
body[data-page="forums"] .post-count-icon { display:grid; place-items:center; }
body[data-page="forums"] .post-count-icon svg { width:17px; height:17px; fill:none; stroke:#77879a; stroke-width:1.8; stroke-linecap:round; stroke-linejoin:round; }
body[data-page="forums"] .post-author-links {
  order:4;
  display:flex;
  justify-content:center;
  flex-wrap:wrap;
  gap:6px;
  width:100%;
  margin-top:12px;
}
body[data-page="forums"] .post-social-link {
  display:inline-flex;
  align-items:center;
  min-height:25px;
  padding:4px 7px;
  border:1px solid var(--line);
  border-radius:5px;
  color:var(--text);
  background:var(--surface);
  font:700 9px/1 var(--font-ui);
  text-decoration:none;
}
body[data-page="forums"] .post-social-link:hover { color:var(--orange-dark); border-color:var(--orange); transform:translateY(-1px); }
body[data-page="forums"] .post-social-link.is-steam { color:#fff; border-color:#31506b; background:#31506b; }
body[data-page="forums"] .post-social-link.is-rep { color:#fff; border-color:#4b9b67; background:#4b9b67; }
body[data-page="forums"] .post-social-link.is-backpack { color:#fff; border-color:#667785; background:#667785; }
html[data-theme="dark"] body[data-page="forums"] .post-author-name { color:#fff7ed; }
html[data-theme="dark"] body[data-page="forums"] .post-author-role { color:#d8c8b8; }
html[data-theme="dark"] body[data-page="forums"] .post-social-link { border-color:#615b55; }
@media (max-width:700px) {
  body[data-page="forums"] .post-aside { flex:none; flex-direction:column; align-items:center; padding:20px; text-align:center; }
  body[data-page="forums"] .post-aside .post-avatar { width:76px; height:76px; margin:0 0 10px; }
  body[data-page="forums"] .post-author-name { margin-bottom:12px; }
  body[data-page="forums"] .post-author-stats { max-width:220px; }
}

/* Aligned topic metrics */
body[data-page="forums"] #topic-list::before { display:none; content:none; }
body[data-page="forums"] .topic-list-header {
  display:grid;
  grid-template-columns:minmax(0,1fr) 176px;
  align-items:center;
  min-height:41px;
  padding:0 18px;
  color:#d8c9bb;
  background:#403a35;
  font:700 10px/1 var(--font-ui);
  letter-spacing:.07em;
  text-transform:uppercase;
}
body[data-page="forums"] .topic-list-heading { padding-left:59px; }
body[data-page="forums"] .topic-list-metric-headings {
  display:grid;
  grid-template-columns:repeat(2,88px);
  height:100%;
  margin-right:-18px;
}
body[data-page="forums"] .topic-list-metric-headings span {
  display:grid;
  place-items:center;
  border-left:1px solid rgba(255,255,255,.12);
}
body[data-page="forums"] .topic-row .topic-stats {
  display:grid;
  grid-template-columns:repeat(2,88px);
  flex:0 0 176px;
  align-self:stretch;
  margin:-11px -18px -11px 0;
}
body[data-page="forums"] .topic-row .topic-stat {
  min-width:0;
  display:flex;
  flex-direction:column;
  align-items:center;
  justify-content:center;
  gap:4px;
  padding:10px 8px;
  border-left:1px solid var(--line-light);
  text-align:center;
}
body[data-page="forums"] .topic-row .topic-stat strong,
body[data-page="forums"] .topic-row .topic-stat span { width:100%; text-align:center; }
html[data-theme="dark"] body[data-page="forums"] .topic-list-header { color:#e7d9cc; background:#2d3034; }
@media (max-width:700px) {
  body[data-page="forums"] .topic-list-header { grid-template-columns:1fr; }
  body[data-page="forums"] .topic-list-heading { padding-left:0; }
  body[data-page="forums"] .topic-list-metric-headings { display:none; }
  body[data-page="forums"] .topic-row .topic-stats { display:none; }
}

/* Keep topic headings and row metrics on one shared column grid. */
body[data-page="forums"] .topic-list-header,
body[data-page="forums"] .topic-row {
  display:grid !important;
  grid-template-columns:46px minmax(0,1fr) 176px;
  column-gap:13px;
  align-items:center;
}
body[data-page="forums"] .topic-list-heading {
  grid-column:1 / 3;
  padding-left:0;
}
body[data-page="forums"] .topic-list-metric-headings {
  grid-column:3;
  width:176px;
  margin:0;
}
body[data-page="forums"] .topic-row .topic-avatar-wrap { grid-column:1; }
body[data-page="forums"] .topic-row .topic-info {
  grid-column:2;
  min-width:0;
}
body[data-page="forums"] .topic-row .topic-stats {
  grid-column:3;
  width:176px;
  margin:-11px 0;
}
body[data-page="forums"] .topic-row .topic-stat {
  box-sizing:border-box;
  width:88px;
}
@media (max-width:700px) {
  body[data-page="forums"] .topic-list-header,
  body[data-page="forums"] .topic-row {
    grid-template-columns:46px minmax(0,1fr);
  }
  body[data-page="forums"] .topic-list-heading { grid-column:1 / 3; }
}

/* Text pagination controls need room beyond the square number buttons. */
body[data-page="forums"] .page-btn.page-nav {
  width:auto;
  min-width:76px;
  padding:0 14px;
  white-space:nowrap;
}

/* Forum rows no longer reserve a column for the old FP marker. */
body[data-page="forums"] .forum-row {
  grid-template-columns:minmax(190px,1fr) 70px 70px minmax(180px,.82fr);
}
@media (max-width:860px) {
  body[data-page="forums"] .forum-row { grid-template-columns:minmax(0,1fr); }
  body[data-page="forums"] .forum-row-stat,
  body[data-page="forums"] .forum-row-latest { display:none; }
}

/* Member identity in forum sidebar activity lists. */
body[data-page="forums"] .forum-sidebar-item.has-avatar {
  display:grid;
  grid-template-columns:36px minmax(0,1fr);
  align-items:start;
  gap:10px;
}
body[data-page="forums"] .forum-sidebar-avatar {
  width:36px;
  height:36px;
  border-radius:7px;
  object-fit:cover;
}
body[data-page="forums"] .forum-sidebar-copy { min-width:0; }
body[data-page="forums"] .forum-sidebar-copy > * { display:block; }


/* ---------- Site-wide dark-mode contrast completion ---------- */
html[data-theme="dark"] body {
  --ink: #fff4e8;
  --text: #ead7c6;
  --muted: #d7c5b4;
  --subtle: #c4b19f;
  --line: #6a6059;
  --line-light: #58514b;
  --surface: #37393b;
  --surface-2: #414143;
  --orange-bg: #4b342d;
  --green-bg: #193b28;
  --red-bg: #472526;
  --blue-bg: #24364d;
  --yellow-bg: #463a22;
  --purple-bg: #352c48;
  color: var(--ink);
}

html[data-theme="dark"] main { color: var(--ink); }

html[data-theme="dark"] main h1,
html[data-theme="dark"] main h2,
html[data-theme="dark"] main h3,
html[data-theme="dark"] main h4,
html[data-theme="dark"] main h5 { color: #fff4e8; }

html[data-theme="dark"] main p,
html[data-theme="dark"] main li,
html[data-theme="dark"] main label,
html[data-theme="dark"] main td,
html[data-theme="dark"] main th { color: var(--text); }

html[data-theme="dark"] main small,
html[data-theme="dark"] main .stat-label,
html[data-theme="dark"] main .filter-label,
html[data-theme="dark"] main .guide-meta,
html[data-theme="dark"] main .member-role,
html[data-theme="dark"] main .current-bid-label,
html[data-theme="dark"] main .bid-count,
html[data-theme="dark"] main .embed-note,
html[data-theme="dark"] main .admin-empty,
html[data-theme="dark"] main .post-author-stats span { color: var(--muted); }

html[data-theme="dark"] main a:not(.btn):not([class]),
html[data-theme="dark"] main .text-link,
html[data-theme="dark"] main .breadcrumb a,
html[data-theme="dark"] main .eyebrow,
html[data-theme="dark"] main .req { color: #ffb17c; }

html[data-theme="dark"] .page-hero p,
html[data-theme="dark"] .page-hero-breadcrumb,
html[data-theme="dark"] .page-hero-breadcrumb span { color: #fff1e2; }

html[data-theme="dark"] .card,
html[data-theme="dark"] .item-card,
html[data-theme="dark"] .auction-card,
html[data-theme="dark"] .stat-card,
html[data-theme="dark"] .listing-img-panel,
html[data-theme="dark"] .info-content,
html[data-theme="dark"] .home-search-bar,
html[data-theme="dark"] .search-box,
html[data-theme="dark"] .toast,
html[data-theme="dark"] .mobile-nav {
  color: var(--ink);
  background-color: var(--surface);
  border-color: var(--line);
}

html[data-theme="dark"] .card-header,
html[data-theme="dark"] .card-footer,
html[data-theme="dark"] .item-card-footer,
html[data-theme="dark"] .auction-bids,
html[data-theme="dark"] .item-card-img,
html[data-theme="dark"] .auction-img {
  color: var(--ink);
  background: var(--surface-2);
  border-color: var(--line-light);
}

html[data-theme="dark"] input,
html[data-theme="dark"] select,
html[data-theme="dark"] textarea,
html[data-theme="dark"] .form-control,
html[data-theme="dark"] .filter-toggle {
  color: #fff4e8;
  background: #2d3033;
  border-color: #6a6059;
}

html[data-theme="dark"] input::placeholder,
html[data-theme="dark"] textarea::placeholder {
  color: #c5b5a7;
  opacity: 1;
}

html[data-theme="dark"] .primary-nav > a.nav-coming-soon,
html[data-theme="dark"] .primary-nav > a.nav-coming-soon:hover { color: #bdb5ae; }
html[data-theme="dark"] .primary-nav > a.nav-coming-soon small { color: #aaa29c; }

html[data-theme="dark"] .footer-brand .brand small,
html[data-theme="dark"] .footer-tagline,
html[data-theme="dark"] .footer-col h4,
html[data-theme="dark"] .footer-col a,
html[data-theme="dark"] .footer-coming-soon,
html[data-theme="dark"] .footer-coming-soon small,
html[data-theme="dark"] .footer-bottom p,
html[data-theme="dark"] .footer-bottom a { color: #c9c1b9; }
html[data-theme="dark"] .footer-coming-soon { color: #b5aea7; }

html[data-theme="dark"] .pill-orange,
html[data-theme="dark"] .pill-live { color: #ffd0ad; background: #613d31; }
html[data-theme="dark"] .pill-gray { color: #f0dfcf; background: #574f49; }
html[data-theme="dark"] .pill-green { color: #c8f3d3; background: #225134; }
html[data-theme="dark"] .pill-red { color: #ffd0d0; background: #5a2f30; }
html[data-theme="dark"] .pill-blue { color: #d5e5ff; background: #294563; }
html[data-theme="dark"] .pill-purple { color: #eadcff; background: #493765; }
html[data-theme="dark"] .pill-yellow,
html[data-theme="dark"] .pill-unique { color: #ffe8a1; background: #59491f; }
html[data-theme="dark"] .pill-unusual,
html[data-theme="dark"] .q-unusual { color: #d9b5f3; }
html[data-theme="dark"] .pill-unusual { background: #49345b; }
html[data-theme="dark"] .pill-strange,
html[data-theme="dark"] .q-strange { color: #ffb57f; }
html[data-theme="dark"] .pill-strange { background: #5a392b; }
html[data-theme="dark"] .q-genuine { color: #a8d5b1; }
html[data-theme="dark"] .q-vintage { color: #afc4ed; }
html[data-theme="dark"] .q-haunted { color: #8af7cf; }
html[data-theme="dark"] .q-collectors { color: #ff9b9b; }

html[data-theme="dark"] .feature-preview-disabled { filter: grayscale(1); opacity: .74; }

html[data-theme="dark"] body[data-page="forums"] .post-header .pill,
html[data-theme="dark"] body[data-page="forums"] .breadcrumb a { color: #ffbd8d; }

html[data-theme="dark"] body[data-page="forums"] .post-social-link.is-rep {
  color: #fff;
  background: #32754a;
  border-color: #4f9f69;
}

html[data-theme="dark"] body[data-page="support"] .panel-code {
  color: #ffd0ad;
  background: #684438;
  border-color: #8f6554;
}

html[data-theme="dark"] .admin-stat,
html[data-theme="dark"] .admin-panel,
html[data-theme="dark"] .admin-dialog { color: var(--text); }

html[data-theme="dark"] .admin-section-heading p,
html[data-theme="dark"] .admin-list-row p,
html[data-theme="dark"] .admin-member p,
html[data-theme="dark"] .admin-report p,
html[data-theme="dark"] .admin-list-row time,
html[data-theme="dark"] .admin-member-heading span,
html[data-theme="dark"] .admin-report small,
html[data-theme="dark"] .admin-form label { color: var(--muted); }

html[data-theme="dark"] .discord-channel-overview .channel-overview-row span,
html[data-theme="dark"] .discord-channel-overview .channel-overview-row > span:first-child { color: var(--muted); }

html[data-theme="dark"] .btn-light {
  color: #fff;
  background: rgba(255,255,255,.19);
  border-color: rgba(255,255,255,.38);
}


/* ---------- Dark-mode contrast final pass ---------- */
html[data-theme="dark"] .page-hero .page-hero-breadcrumb,
html[data-theme="dark"] .page-hero .page-hero-breadcrumb a,
html[data-theme="dark"] .page-hero .page-hero-breadcrumb span {
  color: #fff7ee !important;
}

html[data-theme="dark"] main a:not(.btn):not([class]),
html[data-theme="dark"] main a[style*="var(--orange)"] {
  color: #ffc39a !important;
}

html[data-theme="dark"] .callout p,
html[data-theme="dark"] .callout li,
html[data-theme="dark"] .callout strong {
  color: #fff0e2 !important;
}

html[data-theme="dark"] .stat-val {
  color: #fff4e8 !important;
}

html[data-theme="dark"] .listing-safety h3,
html[data-theme="dark"] .listing-safety p,
html[data-theme="dark"] .listing-safety li,
html[data-theme="dark"] .card[style*="var(--green-bg)"] h3,
html[data-theme="dark"] .card[style*="var(--green-bg)"] p,
html[data-theme="dark"] .card[style*="var(--green-bg)"] li {
  color: #cef3d6 !important;
}

html[data-theme="dark"] .event-type-label,
html[data-theme="dark"] .event-detail-link,
html[data-theme="dark"] .item-card-price,
html[data-theme="dark"] .current-bid,
html[data-theme="dark"] .tab.active,
html[data-theme="dark"] main h3[style*="var(--orange)"] {
  color: #ffc39a !important;
}

html[data-theme="dark"] .pill-genuine {
  color: #c8edcf !important;
  background: #2f4b37 !important;
}

html[data-theme="dark"] .item-card-name[style*="var(--tf2-vintage)"] {
  color: #bed1f4 !important;
}

html[data-theme="dark"] .btn-light {
  color: #fff8f2 !important;
  background: #4a4542 !important;
  border-color: #8e8178 !important;
}

html[data-theme="dark"] .btn-secondary {
  color: #fff4e8 !important;
  background: #46484a !important;
  border-color: #6a6059 !important;
}

html[data-theme="dark"] .event-feature p,
html[data-theme="dark"] .discord-community-hero p,
html[data-theme="dark"] .discord-block p,
html[data-theme="dark"] .card[style*="#5865f2"] p {
  color: #fff5eb !important;
  opacity: 1 !important;
}

html[data-theme="dark"] .page-coming-soon,
html[data-theme="dark"] .status-active,
html[data-theme="dark"] .bidding-active {
  color: #dcf8e3 !important;
}


/* ---------- Dark-mode contrast precision overrides ---------- */
html[data-theme="dark"] main [style*="color:var(--orange)"],
html[data-theme="dark"] main [style*="color: var(--orange)"] {
  color: #ffe3d0 !important;
}

html[data-theme="dark"] main [style*="color:var(--green)"],
html[data-theme="dark"] main [style*="color: var(--green)"] {
  color: #81e8a0 !important;
}

html[data-theme="dark"] .admin-protected-label {
  color: #fff8f2 !important;
  background: #a94024 !important;
}

html[data-theme="dark"] .card[style*="#5865f2"] {
  background: #414cad !important;
}

html[data-theme="dark"] .card[style*="#5865f2"] h3,
html[data-theme="dark"] .card[style*="#5865f2"] p {
  color: #ffffff !important;
}

html[data-theme="dark"] .page-hero .page-hero-breadcrumb,
html[data-theme="dark"] .page-hero .page-hero-breadcrumb a,
html[data-theme="dark"] .page-hero .page-hero-breadcrumb span {
  color: #fffaf5 !important;
}


/* ---------- Dark-mode breadcrumb specificity fix ---------- */
html[data-theme="dark"] main .page-hero .page-hero-breadcrumb,
html[data-theme="dark"] main .page-hero .page-hero-breadcrumb a,
html[data-theme="dark"] main .page-hero .page-hero-breadcrumb span {
  color: #fffaf5 !important;
}

/* Allow the six-topic preview to override the aligned row grid. */
body[data-page="forums"] .topic-row.topic-row-older.hidden { display:none !important; }

/* Live Discord statistics */
.discord-live-avatar { width:32px; height:32px; flex:0 0 32px; border-radius:50%; object-fit:cover; background:#202225; }
.discord-stats-note { margin:12px 0; color:#d4d7dd; font-size:12px; line-height:1.5; }
