@import url('https://unpkg.com/@phosphor-icons/web@2.1.1/src/bold/style.css');
@import url('https://unpkg.com/@phosphor-icons/web@2.1.1/src/regular/style.css');

:root {
  /* Retro Skeuomorphic Palette (SOLID COLORS, NO GRADIENTS) */
  --blue-top: #3b88e0;
  --blue: #0066cc;
  --blue-mid: #0055b3;
  --blue-dark: #004085;
  --blue-edge: #003366;

  /* Classic Retro Green Play Button */
  --green-top: #2ecc71;
  --green: #1faa46;
  --green-mid: #188e3a;
  --green-dark: #12702d;
  --green-edge: #0c4d1f;

  /* Typography & Ink */
  --ink: #1e293b;
  --ink-light: #334155;
  --muted: #5e7188;
  --link: #0066cc;

  /* Solid Retro Page & Surface Backgrounds */
  --page-bg: #e8eff6;
  --card-bg: #ffffff;
  --field-bg: #ffffff;
  --well-bg: #f0f5fa;
  --well-border: #c4d7e8;
  --border: #a4bad0;
  --border-light: #cde0f0;
  --border-dark: #7a97b5;

  /* Topbar & Header Slate */
  --topbar-bg: #1e2b3c;
  --topbar-border: #121b26;
  --header-bg: #e4eef8;
  --footer-bg: #dbe7f4;

  --radius: 4px;
  --font: 'Trebuchet MS', 'Segoe UI', Arial, Helvetica, sans-serif;
}

/* ============================================================
   GLOBAL RESETS & UNIFIED TYPOGRAPHY
   ============================================================ */

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  font-family: inherit;
}

[hidden] { display: none !important; }

html, body {
  font-family: var(--font);
  background-color: var(--page-bg);
  color: var(--ink);
  line-height: 1.45;
  font-size: 13px;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

a {
  color: var(--link);
  text-decoration: none;
  cursor: pointer;
}

a:hover {
  text-decoration: underline;
  color: var(--blue-dark);
}

button, input, select, textarea {
  font-family: var(--font);
  font-size: 13px;
}

:focus-visible {
  outline: 2px solid var(--blue);
  outline-offset: 1px;
}

::selection {
  background: #b8d7ff;
  color: #002244;
}

/* Classic Scrollbars */
:root { scrollbar-color: #9cb5ce var(--page-bg); }
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-thumb {
  background: #9cb5ce;
  border-radius: 3px;
  border: 2px solid var(--page-bg);
}
::-webkit-scrollbar-thumb:hover { background: #7a97b5; }
::-webkit-scrollbar-track { background: var(--page-bg); }

/* ============================================================
   TOPBAR
   ============================================================ */

.topbar {
  background-color: var(--topbar-bg);
  border-bottom: 2px solid var(--topbar-border);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.12), 0 2px 4px rgba(0, 0, 0, 0.15);
  position: sticky;
  top: 0;
  z-index: 1000;
}

.topbar-inner {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 16px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.topbar-left {
  display: flex;
  align-items: center;
  gap: 18px;
  min-width: 0;
}

.brand-logo {
  display: inline-flex;
  align-items: center;
  text-decoration: none;
  user-select: none;
  flex-shrink: 0;
  line-height: 1;
  transition: transform 0.1s ease, filter 0.1s ease;
}

.brand-logo-img {
  height: 36px;
  width: auto;
  display: block;
}

.brand-logo:hover {
  text-decoration: none;
  filter: brightness(1.06);
}

.brand-logo:active {
  transform: translateY(1px);
}

.topbar-nav {
  display: flex;
  gap: 2px;
  font-size: 13px;
  font-weight: 700;
}

.topbar-nav a {
  color: #c9d8ea;
  text-decoration: none;
  padding: 13px 10px;
  border-bottom: 3px solid transparent;
  transition: background-color 0.1s ease, color 0.1s ease;
}

.topbar-nav a:hover {
  color: #ffffff;
  text-decoration: none;
  background-color: rgba(255, 255, 255, 0.08);
}

.topbar-nav a.active,
.topbar-nav a[aria-current="page"] {
  color: #ffffff;
  border-bottom-color: var(--blue-top);
  background-color: rgba(0, 0, 0, 0.2);
}

.topbar-right,
.topbar-auth,
.topbar-user {
  display: flex;
  align-items: center;
}

.topbar-right { gap: 10px; }
.topbar-auth { gap: 8px; }
.topbar-user { gap: 8px; }

.topbar-btn {
  height: 28px;
  padding: 0 12px;
  line-height: 1;
  background-color: #344458;
  border: 1px solid #1c2734;
  border-radius: 3px;
  color: #f0f4f9;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.15), 0 1px 2px rgba(0, 0, 0, 0.2);
  flex-shrink: 0;
}

.topbar-btn:hover {
  background-color: #42556e;
  color: #ffffff;
  text-decoration: none;
}

.topbar-btn-primary {
  background-color: var(--blue);
  border-color: var(--blue-edge);
  color: #ffffff;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.35), 0 1px 2px rgba(0, 0, 0, 0.25);
}

.topbar-btn-primary:hover {
  background-color: #0077ee;
  color: #ffffff;
}

.topbar-icon-btn {
  display: none;
}

.mobile-search-bar,
.mobile-bottom-nav,
.mobile-drawer,
.mobile-drawer-backdrop {
  display: none;
}

.user-chip {
  height: 28px;
  padding: 0 8px;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  background-color: #2b3a4c;
  border: 1px solid #18222e;
  border-radius: 3px;
  color: #f0f4f9;
  font-size: 12px;
  font-weight: 700;
  max-width: 180px;
  text-decoration: none;
  flex-shrink: 0;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.user-chip:hover {
  background-color: #364960;
  text-decoration: none;
  color: #ffffff;
}

.user-avatar {
  width: 20px;
  height: 20px;
  border-radius: 2px;
  border: 1px solid rgba(255, 255, 255, 0.3);
  background-color: #eaf2fc;
  flex-shrink: 0;
}

.user-name {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* User account dropdown (decluttered topbar) */
.user-menu-wrap {
  position: relative;
  flex-shrink: 0;
}

.user-chip {
  cursor: pointer;
  font-family: inherit;
}

.user-chip-caret {
  font-size: 9px;
  color: #9fb2c6;
  margin-left: 1px;
}

.user-menu-backdrop {
  position: fixed;
  inset: 0;
  z-index: 90;
  background: transparent;
}

.user-menu {
  position: absolute;
  top: calc(100% + 6px);
  right: 0;
  z-index: 100;
  min-width: 190px;
  background-color: #1d2a3a;
  border: 1px solid #18222e;
  border-radius: 4px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.45);
  padding: 5px 0;
  display: flex;
  flex-direction: column;
}

.user-menu a,
.user-menu button {
  display: block;
  width: 100%;
  text-align: left;
  padding: 8px 14px;
  font-size: 13px;
  color: #dbe6f2;
  background: none;
  border: none;
  cursor: pointer;
  font-family: inherit;
  text-decoration: none;
  box-sizing: border-box;
}

.user-menu a:hover,
.user-menu button:hover {
  background-color: #2b3a4c;
  color: #ffffff;
}

.user-menu .user-menu-mod {
  color: #4a9eff;
  font-weight: 700;
}

.user-menu .user-menu-logout {
  color: #ff8a8a;
}

.user-menu .user-menu-logout:hover {
  background-color: #3a2b2b;
  color: #ffb3b3;
}

.user-menu-sep {
  height: 1px;
  margin: 4px 0;
  background-color: #2b3a4c;
}

/* Friends page */
.friends-layout {
  display: flex;
  flex-direction: column;
  gap: 14px;
  max-width: 640px;
}

.friends-add-form {
  display: flex;
  gap: 8px;
  margin: 0;
}

.friends-add-form input {
  flex: 1;
}

.friend-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
}

.friend-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 8px 0;
  border-bottom: 1px solid #eef2f7;
}

.friend-row:last-child {
  border-bottom: none;
}

.friend-avatar-link {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: inherit;
  min-width: 0;
}

.friend-avatar-link:hover .friend-name {
  color: var(--blue);
}

.friend-name {
  font-weight: 600;
  font-size: 14px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.friend-actions {
  display: flex;
  gap: 6px;
  flex-shrink: 0;
}

.topbar-search {
  position: relative;
  flex: 1 1 220px;
  max-width: 280px;
  min-width: 120px;
  display: flex;
  align-items: center;
  gap: 4px;
  background-color: #121b26;
  border: 1px solid #0a1017;
  border-radius: 3px;
  padding: 2px 3px 2px 8px;
  box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.5);
}

.topbar-search:focus-within {
  border-color: var(--blue-top);
  box-shadow: 0 0 0 1px var(--blue-top);
}

.topbar-search input {
  flex: 1;
  min-width: 0;
  background: transparent;
  border: none;
  outline: none;
  color: #ffffff;
  font-size: 12px;
}

.topbar-search input::placeholder { color: #73879c; }

.search-btn {
  height: 22px;
  padding: 0 8px;
  line-height: 1;
  background-color: #36485e;
  border: 1px solid #1e2a37;
  border-radius: 2px;
  color: #e6eef8;
  font-size: 11px;
  font-weight: 700;
  cursor: pointer;
  white-space: nowrap;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.15);
}

.search-btn:hover { background-color: #455c78; color: #fff; }

.search-dropdown {
  position: absolute;
  top: calc(100% + 4px);
  left: 0;
  right: 0;
  z-index: 1100;
  background-color: #ffffff;
  border: 1px solid var(--border-dark);
  border-radius: 3px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
  overflow: hidden;
}

.search-dd-heading {
  background-color: var(--header-bg);
  padding: 4px 10px;
  font-size: 10px;
  font-weight: 800;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  border-bottom: 1px solid var(--border-light);
}

.search-dropdown-item,
.search-dropdown-user-item {
  display: flex;
  padding: 6px 10px;
  text-decoration: none;
  color: var(--ink);
  border-bottom: 1px solid var(--border-light);
  background-color: #ffffff;
}

.search-dropdown-item {
  flex-direction: column;
  gap: 1px;
}

.search-dropdown-user-item {
  align-items: center;
  gap: 8px;
}

.search-dropdown-item:last-child,
.search-dropdown-user-item:last-child { border-bottom: none; }

.search-dropdown-item:hover,
.search-dropdown-user-item:hover {
  background-color: #e8f2fc;
  color: var(--blue-dark);
  text-decoration: none;
}

.search-user-avatar {
  width: 22px;
  height: 22px;
  border-radius: 2px;
  border: 1px solid var(--border);
  flex-shrink: 0;
  background-color: #eaf2fc;
}

.search-dd-name { font-size: 13px; font-weight: 700; }
.search-dd-meta { font-size: 11px; color: var(--muted); }

/* ============================================================
   PAGE LAYOUT & RETRO SIDEBAR
   ============================================================ */

.page-layout {
  max-width: 1100px;
  margin: 0 auto;
  padding: 16px;
  display: flex;
  gap: 16px;
  align-items: flex-start;
}

.page-sidebar {
  flex: 0 0 190px;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.side-section {
  background-color: #ffffff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
  overflow: hidden;
}

.side-title {
  background-color: var(--header-bg);
  border-bottom: 1px solid var(--border);
  color: var(--ink);
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  padding: 6px 10px;
}

.side-nav {
  display: flex;
  flex-direction: column;
}

.side-nav a,
.side-nav button {
  color: var(--ink-light);
  text-decoration: none;
  font-size: 13px;
  font-weight: 600;
  padding: 6px 10px;
  border-bottom: 1px solid var(--border-light);
  background-color: #ffffff;
  border-top: none;
  border-left: none;
  border-right: none;
  text-align: left;
  width: 100%;
  cursor: pointer;
  display: block;
}

.side-nav a:last-child,
.side-nav button:last-child { border-bottom: none; }

.side-nav a:hover,
.side-nav button:hover {
  background-color: #eef5fc;
  color: var(--blue);
  text-decoration: none;
}

.side-nav a.active,
.side-nav a[aria-current="page"] {
  background-color: #e2effa;
  color: var(--blue-dark);
  font-weight: 700;
  border-left: 3px solid var(--blue);
  padding-left: 7px;
}

.page-main {
  flex: 1;
  min-width: 0;
}



/* ============================================================
   RETRO HERO BANNER
   ============================================================ */

.hero {
  background-color: #ffffff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
  margin-bottom: 16px;
  overflow: hidden;
}

.hero-inner {
  padding: 20px 22px;
}

.hero-greeting {
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  color: var(--blue);
  margin-bottom: 2px;
}

.hero h1 {
  font-size: 24px;
  font-weight: 800;
  line-height: 1.25;
  color: var(--ink);
  margin-bottom: 4px;
}

.hero-tagline {
  color: var(--muted);
  font-size: 13px;
  margin-bottom: 14px;
}

.hero-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  align-items: center;
}

/* ============================================================
   RETRO COMMUNITY CARD (SOLID SKEUOMORPHIC - REPLACES GRADIENT)
   ============================================================ */

.community-card,
.discord-card {
  background-color: #ffffff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
  margin-bottom: 16px;
  overflow: hidden;
}

.community-card-header {
  background-color: var(--header-bg);
  border-bottom: 1px solid var(--border);
  padding: 6px 12px;
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
  color: var(--ink);
  display: flex;
  align-items: center;
  gap: 6px;
}

.community-card-body {
  padding: 14px 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

.community-card-text {
  flex: 1 1 280px;
}

.community-card-title {
  font-size: 15px;
  font-weight: 800;
  color: var(--ink);
  margin-bottom: 3px;
}

.community-card-copy {
  font-size: 12px;
  color: var(--ink-light);
  line-height: 1.4;
}

.community-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 16px;
  border-radius: 3px;
  background-color: #5865f2;
  border: 1px solid #454ec2;
  color: #ffffff;
  font-size: 13px;
  font-weight: 700;
  text-decoration: none;
  white-space: nowrap;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.25), 0 1px 2px rgba(0, 0, 0, 0.15);
}

.community-btn:hover {
  background-color: #4752c4;
  color: #ffffff;
  text-decoration: none;
}

.community-btn:active {
  transform: translateY(1px);
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.3);
}

/* ============================================================
   SECTIONS & RETRO CARDS
   ============================================================ */

.section { margin-bottom: 16px; }
.section-inner { width: 100%; }
.section-inner-narrow { max-width: 500px; margin: 0 auto; }

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

.section-head h2 {
  font-size: 17px;
  font-weight: 800;
  color: var(--ink);
}

.section-head h3 {
  font-size: 14px;
  font-weight: 800;
  color: var(--ink);
}

.section-sub {
  color: var(--muted);
  font-size: 12px;
  font-weight: 600;
}

.card {
  background-color: #ffffff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
  padding: 14px;
  margin-bottom: 12px;
}

.card-header,
.content-card-heading {
  background-color: var(--header-bg);
  border-bottom: 1px solid var(--border);
  border-radius: 3px 3px 0 0;
  color: var(--ink);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.4px;
  padding: 6px 12px;
  margin: -14px -14px 12px -14px;
}

.card p {
  font-size: 13px;
  color: var(--ink-light);
  margin-bottom: 8px;
}

.well {
  background-color: var(--well-bg);
  border: 1px solid var(--well-border);
  border-radius: var(--radius);
  padding: 12px 14px;
}

.hint {
  font-size: 11px;
  color: var(--muted);
  margin-top: 4px;
}

/* ============================================================
   SKEUOMORPHIC SOLID BUTTONS
   ============================================================ */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  font-family: var(--font);
  font-size: 13px;
  font-weight: 700;
  padding: 6px 14px;
  border-radius: 3px;
  border: 1px solid transparent;
  cursor: pointer;
  user-select: none;
  text-decoration: none;
  line-height: 1.2;
  transition: background-color 0.08s ease, border-color 0.08s ease, transform 0.04s ease;
}

.btn:disabled {
  opacity: 0.55;
  cursor: not-allowed;
  transform: none !important;
}

.btn:hover { text-decoration: none; }

.btn:active:not(:disabled) {
  transform: translateY(1px);
}

/* Primary Retro Blue */
.btn-primary {
  background-color: var(--blue);
  border-color: var(--blue-edge);
  color: #ffffff;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.3), 0 1px 2px rgba(0, 0, 0, 0.2);
}

.btn-primary:hover {
  background-color: #0077ee;
  border-color: var(--blue-edge);
  color: #ffffff;
}

.btn-primary:active:not(:disabled) {
  background-color: var(--blue-dark);
  box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.4);
}

/* Play Button Green (Solid Retro) */
.btn-play,
.btn-green,
.launch {
  background-color: var(--green);
  border-color: var(--green-edge);
  color: #ffffff;
  font-size: 14px;
  font-weight: 800;
  padding: 7px 18px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.35), 0 1px 2px rgba(0, 0, 0, 0.2);
}

.btn-play:hover,
.btn-green:hover,
.launch:hover {
  background-color: #24be50;
  color: #ffffff;
}

.btn-play:active:not(:disabled),
.btn-green:active:not(:disabled),
.launch:active:not(:disabled) {
  background-color: var(--green-dark);
  box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.4);
}

/* Neutral Beveled Silver Button */
.btn-neutral {
  background-color: #f2f6fa;
  border-color: var(--border-dark);
  color: var(--ink);
  box-shadow: inset 0 1px 0 #ffffff, 0 1px 2px rgba(0, 0, 0, 0.08);
}

.btn-neutral:hover {
  background-color: #ffffff;
  border-color: #62809e;
  color: #000000;
}

.btn-neutral:active:not(:disabled) {
  background-color: #e0ebf5;
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.15);
}

/* Danger Button */
.btn-danger {
  background-color: #d92e2e;
  border-color: #8a1818;
  color: #ffffff;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.25), 0 1px 2px rgba(0, 0, 0, 0.2);
}

.btn-danger:hover {
  background-color: #ea3a3a;
  color: #ffffff;
}

.btn-danger:active:not(:disabled) {
  background-color: #b82020;
  box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.4);
}

.btn-lg { padding: 9px 22px; font-size: 14px; font-weight: 800; }
.btn-sm { padding: 3px 8px; font-size: 11px; }
.btn-block { width: 100%; }

/* ============================================================
   CATEGORY TABS & FILTER BAR
   ============================================================ */

.filter-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
  background-color: #ffffff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 6px 8px;
  margin-bottom: 12px;
}

.category-tabs {
  display: flex;
  gap: 4px;
  flex-wrap: wrap;
}

.category-tab {
  background-color: #f2f6fa;
  border: 1px solid var(--border);
  border-radius: 3px;
  color: var(--ink-light);
  font-size: 12px;
  font-weight: 700;
  padding: 4px 10px;
  cursor: pointer;
  box-shadow: inset 0 1px 0 #ffffff;
}

.category-tab:hover {
  background-color: #ffffff;
  color: var(--blue);
  border-color: var(--border-dark);
}

.category-tab.active {
  background-color: var(--blue);
  border-color: var(--blue-edge);
  color: #ffffff;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.3);
}

/* ============================================================
   GAMES GRID & DETAIL
   ============================================================ */

.games-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 12px;
}

.game-tile {
  display: flex;
  flex-direction: column;
  background-color: #ffffff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
  overflow: hidden;
  text-decoration: none;
  color: var(--ink);
}

.game-tile:hover {
  border-color: var(--blue);
  box-shadow: 0 2px 6px rgba(0, 102, 204, 0.15);
  text-decoration: none;
}

.tile-thumb {
  height: 96px;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: #245b98;
  border-bottom: 1px solid #143e6d;
  position: relative;
  overflow: hidden;
}

.tile-thumb-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.tile-thumb .thumb-logo {
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.5px;
  padding: 0 6px;
  text-align: center;
  color: #ffffff;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
}

.tile-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 7px 8px;
}

.tile-name {
  font-size: 13px;
  font-weight: 800;
  color: var(--ink);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.tile-creator {
  font-size: 11px;
  color: var(--muted);
}

.tile-stats {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 11px;
  color: var(--muted);
  margin-top: 4px;
  padding-top: 4px;
  border-top: 1px solid var(--border-light);
}

.tile-live {
  color: var(--green-mid);
  font-weight: 800;
}

/* Game Detail Page */
.game-detail-layout {
  display: grid;
  grid-template-columns: 1fr 240px;
  gap: 14px;
  align-items: flex-start;
}

@media (max-width: 800px) {
  .game-detail-layout { grid-template-columns: 1fr; }
}

.game-detail {
  padding: 14px;
}

.game-detail-thumb {
  width: 100%;
  height: 180px;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: #245b98;
  border: 1px solid #143e6d;
  border-radius: var(--radius);
  margin-bottom: 12px;
  overflow: hidden;
}

.game-detail-thumb-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.thumb-preview-card {
  width: 100%;
  max-width: 320px;
  height: 150px;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  overflow: hidden;
  background-color: #1a2736;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 6px;
}

.thumb-preview-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.thumb-preview-empty {
  color: var(--muted);
  font-size: 11px;
  text-align: center;
  padding: 12px;
  background-color: var(--bg-card);
  border: 1px dashed var(--border);
}

.game-detail-thumb .thumb-logo {
  font-size: 22px;
  font-weight: 800;
  letter-spacing: 1px;
  color: #ffffff;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.5);
}

.game-title-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 4px;
}

.game-title-row h2 {
  font-size: 20px;
  font-weight: 800;
  color: var(--ink);
}

.game-creator {
  color: var(--muted);
  font-size: 12px;
  margin-bottom: 10px;
}

.game-desc {
  color: var(--ink-light);
  font-size: 13px;
  line-height: 1.5;
  margin-bottom: 14px;
}

.game-actions-bar {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 0;
  border-top: 1px solid var(--border-light);
  border-bottom: 1px solid var(--border-light);
  margin-bottom: 12px;
  flex-wrap: wrap;
}

.place-meta-box {
  background-color: #ffffff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
  overflow: hidden;
}

.place-meta-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12px;
}

.place-meta-table td {
  padding: 6px 10px;
  border-bottom: 1px solid var(--border-light);
}

.place-meta-table tr:last-child td { border-bottom: none; }
.place-meta-label { font-weight: 600; color: var(--muted); width: 45%; }
.place-meta-val { font-weight: 800; color: var(--ink); text-align: right; }

/* Active Servers Table */
.servers-card { margin-top: 12px; }

.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12px;
  margin-top: 6px;
}

.data-table th {
  background-color: var(--header-bg);
  border: 1px solid var(--border);
  padding: 6px 8px;
  font-weight: 800;
  text-align: left;
  color: var(--ink);
}

.data-table td {
  padding: 6px 8px;
  border: 1px solid var(--border-light);
  color: var(--ink-light);
  background-color: #ffffff;
}

.data-table tr:nth-child(even) td { background-color: #f7fbff; }

.status-pill {
  display: inline-block;
  font-size: 10px;
  font-weight: 800;
  padding: 1px 6px;
  border-radius: 2px;
  text-transform: uppercase;
}

.status-online {
  background-color: #e6f6e6;
  color: #177317;
  border: 1px solid #a8dfa8;
}

/* ============================================================
   PROFILE & RETRO USER CARDS
   ============================================================ */

.profile-layout {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 14px;
  align-items: flex-start;
}

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

.profile-avatar-box {
  background-color: #ffffff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
  padding: 12px;
  text-align: center;
}

.profile-avatar-frame {
  width: 150px;
  height: 150px;
  margin: 0 auto 10px;
  border: 1px solid var(--border-dark);
  border-radius: 3px;
  background-color: #dbe7f4;
  overflow: hidden;
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.1);
}

.profile-avatar-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.profile-username {
  font-size: 17px;
  font-weight: 800;
  color: var(--ink);
}

.profile-badges-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin: 3px 0 8px;
  flex-wrap: wrap;
}

.profile-staff-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: linear-gradient(135deg, #d97706, #f59e0b);
  border: 1px solid #b45309;
  color: #ffffff;
  font-size: 11px;
  font-weight: 800;
  padding: 2px 8px;
  border-radius: 3px;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
  box-shadow: 0 1px 3px rgba(217, 119, 6, 0.3);
}

.profile-staff-badge i {
  font-size: 13px;
}

.profile-rank-badge {
  display: inline-block;
  background-color: var(--header-bg);
  border: 1px solid var(--border);
  color: var(--blue-dark);
  font-size: 11px;
  font-weight: 800;
  padding: 2px 8px;
  border-radius: 3px;
}

.profile-bio {
  font-size: 13px;
  color: var(--ink-light);
  line-height: 1.5;
  white-space: pre-line;
}

/* Early Roblox Style Friends Grid on Profile */
.profile-friends-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
  flex-wrap: wrap;
  gap: 8px;
}

.profile-friends-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(88px, 1fr));
  gap: 10px;
}

.profile-friend-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-decoration: none;
  background: #ffffff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 6px 4px 8px;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

.profile-friend-card:hover {
  border-color: var(--blue);
  box-shadow: 0 2px 6px rgba(0, 102, 204, 0.15);
  text-decoration: none;
}

.profile-friend-avatar-wrap {
  width: 72px;
  height: 72px;
  border: 1px solid var(--border-dark);
  border-radius: 3px;
  background-color: #dbe7f4;
  overflow: hidden;
  margin-bottom: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.08);
}

.profile-friend-avatar-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.profile-friend-name {
  font-size: 11px;
  font-weight: 700;
  color: var(--brand);
  text-align: center;
  max-width: 80px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1.2;
}

.profile-friend-card:hover .profile-friend-name {
  color: var(--brand-hover);
  text-decoration: underline;
}

/* ============================================================
   FORMS, TABS & INPUTS
   ============================================================ */

.form { display: flex; flex-direction: column; gap: 10px; }

.form label {
  display: flex;
  flex-direction: column;
  gap: 3px;
  font-size: 12px;
  font-weight: 700;
  color: var(--ink);
}

.form input,
.form textarea,
.form select {
  font-family: var(--font);
  font-size: 13px;
  color: var(--ink);
  background-color: #ffffff;
  border: 1px solid var(--border-dark);
  border-radius: 3px;
  padding: 6px 8px;
  outline: none;
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.08);
}

.form input:focus,
.form textarea:focus,
.form select:focus {
  border-color: var(--blue);
  box-shadow: 0 0 0 1px var(--blue);
}

.form textarea { resize: vertical; line-height: 1.45; }

.check-row {
  display: flex !important;
  flex-direction: row !important;
  align-items: center;
  gap: 8px;
  font-weight: 600 !important;
  cursor: pointer;
}

/* Retro Folder Tabs */
.tabs {
  display: flex;
  gap: 3px;
  border-bottom: 1px solid var(--border);
  margin-bottom: 12px;
}

.tab {
  background-color: #e5edf5;
  border: 1px solid var(--border);
  border-bottom: none;
  border-radius: 3px 3px 0 0;
  font-size: 12px;
  font-weight: 700;
  color: var(--muted);
  padding: 6px 14px;
  cursor: pointer;
  margin-bottom: -1px;
}

.tab:hover { color: var(--ink); background-color: #ffffff; }

.tab.active {
  background-color: #ffffff;
  color: var(--blue-dark);
  font-weight: 800;
  border-bottom: 1px solid #ffffff;
}

.tab-danger.active {
  color: #b82020;
}

/* ============================================================
   RETRO SKEUOMORPHIC MODALS & DIALOGS
   ============================================================ */

.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(10, 20, 35, 0.65);
  backdrop-filter: blur(3px);
  -webkit-backdrop-filter: blur(3px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  opacity: 0;
  pointer-events: none;
  padding: 16px;
  transition: opacity 0.2s ease;
}

.modal-overlay.active { opacity: 1; pointer-events: auto; }

.modal {
  background-color: #ffffff;
  border: 2px solid var(--topbar-bg);
  border-radius: 12px;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.4), 0 0 0 1px rgba(255, 255, 255, 0.1) inset;
  width: 440px;
  max-width: 100%;
  overflow: hidden;
  transform: scale(0.96);
  transition: transform 0.2s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.modal-overlay.active .modal {
  transform: scale(1);
}

.modal-header {
  background-color: var(--topbar-bg);
  background-image: linear-gradient(180deg, rgba(255, 255, 255, 0.15) 0%, rgba(0, 0, 0, 0.1) 100%);
  border-bottom: 1px solid var(--topbar-border);
  color: #ffffff;
  font-size: 13.5px;
  font-weight: 800;
  padding: 10px 14px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.modal-close {
  color: #cdd9e8;
  font-size: 20px;
  font-weight: 700;
  cursor: pointer;
  line-height: 1;
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 4px;
  transition: background-color 0.15s ease, color 0.15s ease;
}

.modal-close:hover {
  color: #ffffff;
  background-color: rgba(255, 255, 255, 0.15);
}

.modal-body {
  padding: 18px 20px;
}

.launcher-modal-body {
  padding: 16px 20px 20px;
  text-align: center;
}

.launcher-modal-icon {
  display: flex;
  justify-content: center;
  margin-bottom: 12px;
}

.launcher-pulse-icon {
  width: 40px;
  height: 40px;
  opacity: 0.85;
}

.launch-status {
  font-size: 14px;
  font-weight: 700;
  color: var(--ink);
  text-align: center;
  margin-bottom: 10px;
}

.progress-bar-container {
  width: 100%;
  height: 10px;
  background-color: var(--well-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  margin: 10px 0 12px;
  overflow: hidden;
}

.progress-bar-fill {
  height: 100%;
  background-color: var(--blue);
  border-radius: var(--radius);
  transition: width 0.3s ease;
}

.modal-note {
  font-size: 12px;
  color: var(--muted);
  margin-top: 10px;
  line-height: 1.45;
  text-align: center;
}

.modal-note a {
  color: var(--link);
  text-decoration: underline;
}

.modal-note a:hover {
  color: var(--blue-dark);
}

.toast-container {
  position: fixed;
  bottom: 20px;
  right: 20px;
  z-index: 10000;
  display: flex;
  flex-direction: column;
  gap: 6px;
  pointer-events: none;
}

.toast {
  background-color: #1e2b3c;
  color: #ffffff;
  padding: 8px 14px;
  border-radius: 3px;
  font-size: 12px;
  font-weight: 700;
  border: 1px solid #0f1722;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.25);
  pointer-events: auto;
  opacity: 0;
  transition: opacity 0.15s ease;
}

.toast.show { opacity: 1; }
.toast-error { background-color: #a81c1c; border-color: #630c0c; }
.toast-success { background-color: #1a7a37; border-color: #0f4a21; }

/* ============================================================
   FOOTER
   ============================================================ */

.footer {
  background-color: var(--footer-bg);
  border-top: 1px solid var(--border);
  margin-top: 28px;
  padding: 18px 0;
}

.footer-inner {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 16px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.footer-links { display: flex; gap: 16px; }
.footer-links a { color: var(--link); font-size: 12px; font-weight: 700; }
.footer-links a:hover { text-decoration: underline; color: var(--blue-dark); }

.footer .brand-logo {
  background: none;
  border: none;
  box-shadow: none;
  color: var(--ink);
  padding: 0;
  font-size: 16px;
}
.footer .brand-logo span { color: var(--blue); }

.footer-copy {
  width: 100%;
  text-align: center;
  color: var(--muted);
  font-size: 11px;
  border-top: 1px solid var(--border);
  padding-top: 10px;
  margin-top: 4px;
}

/* ============================================================
   AVATAR EDITOR & FRAMING STYLE (MUGSHOT VS RETRO FULL-BODY)
   ============================================================ */

.avatar-editor-root {
  display: flex;
  gap: 16px;
  margin-top: 12px;
  align-items: flex-start;
}

@media (max-width: 760px) {
  .avatar-editor-root { flex-direction: column; }
}

.avatar-viewport {
  position: relative;
  flex: 1 1 400px;
  min-height: 400px;
  border-radius: var(--radius);
  border: 1px solid var(--border-dark);
  background-color: #dbe7f4;
  box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.12);
  overflow: hidden;
  cursor: grab;
}

.avatar-viewport:active { cursor: grabbing; }

#avatar-canvas {
  display: block;
  width: 100%;
  height: 400px;
}

.avatar-loading {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--muted);
  font-weight: 700;
  font-size: 13px;
}

.avatar-hint {
  position: absolute;
  bottom: 8px;
  left: 50%;
  transform: translateX(-50%);
  background-color: rgba(18, 30, 46, 0.7);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  padding: 2px 10px;
  border-radius: 2px;
  pointer-events: none;
  user-select: none;
}

.avatar-side {
  flex: 0 0 280px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.avatar-acc {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background-color: #ffffff;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
  overflow: hidden;
}

.avatar-acc-summary {
  list-style: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 12px;
  font-weight: 800;
  color: var(--ink);
  background-color: var(--header-bg);
  border-bottom: 1px solid var(--border);
  padding: 7px 10px;
  user-select: none;
}

.avatar-acc-summary::-webkit-details-marker { display: none; }
.avatar-acc-summary::after { content: "▾"; font-size: 11px; color: var(--muted); font-weight: 800; }
.avatar-acc[open] .avatar-acc-summary::after { content: "▴"; }
.avatar-acc-body { padding: 10px; }

.face-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 6px;
}

.face-option {
  padding: 0;
  border: 1px solid var(--border);
  border-radius: 3px;
  background-color: #ffffff;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: inset 0 1px 0 #ffffff;
}

.face-option:hover { border-color: var(--blue); background-color: #f0f7ff; }
.face-option.selected,
.face-option.active {
  border-color: var(--blue);
  box-shadow: 0 0 0 2px var(--blue);
}

.face-option img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Profile Picture Framing Switcher (Classic Mugshot vs Retro Full-Body) */
.shot-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-bottom: 10px;
}

.shot-option {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
  text-align: left;
  padding: 8px 10px;
  border: 1px solid var(--border);
  border-radius: 3px;
  background-color: #f6faff;
  cursor: pointer;
  box-shadow: inset 0 1px 0 #ffffff;
  transition: border-color 0.1s ease, background-color 0.1s ease;
}

.shot-option:hover {
  border-color: var(--blue);
  background-color: #eaf2fc;
}

.shot-option.selected,
.shot-option.active {
  border-color: var(--blue);
  background-color: #e2effa;
  box-shadow: 0 0 0 2px var(--blue);
}

.shot-option-name {
  font-size: 12px;
  font-weight: 800;
  color: var(--ink);
}

.shot-option-desc {
  font-size: 10px;
  line-height: 1.3;
  color: var(--muted);
}

.avatar-preview {
  display: block;
  width: 100%;
  height: auto;
  max-height: 140px;
  object-fit: contain;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background-color: #dbe7f4;
  margin-top: 6px;
}

/* Color Parts and Swatches */
.color-part {
  margin-bottom: 10px;
}

.color-part:last-child {
  margin-bottom: 0;
}

.color-part-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 4px;
}

.color-part-label {
  font-size: 11px;
  font-weight: 800;
  color: var(--ink-light);
}

.color-input {
  width: 28px;
  height: 18px;
  padding: 0;
  border: 1px solid var(--border-dark);
  border-radius: 2px;
  cursor: pointer;
  background-color: #ffffff;
}

.color-swatches {
  display: grid;
  grid-template-columns: repeat(8, 1fr);
  gap: 4px;
}

.swatch {
  display: block;
  width: 100%;
  aspect-ratio: 1 / 1;
  border-radius: 2px;
  border: 1px solid rgba(0, 0, 0, 0.25);
  cursor: pointer;
  padding: 0;
  box-shadow: 0 1px 1px rgba(0, 0, 0, 0.1);
  transition: transform 0.08s ease;
}

.swatch:hover {
  transform: scale(1.15);
  z-index: 5;
  box-shadow: 0 0 3px rgba(0, 0, 0, 0.4);
}

.swatch.selected {
  border: 2px solid #000000;
  outline: 1px solid #ffffff;
  outline-offset: -2px;
  transform: scale(1.08);
  z-index: 4;
}

.avatar-actions {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  margin-top: 4px;
}

.avatar-actions .btn {
  flex: 1 1 calc(50% - 3px);
  font-size: 12px;
  padding: 6px 8px;
}

.avatar-actions #avatar-save {
  flex: 1 1 100%;
  font-size: 13px;
  padding: 8px 12px;
}

.avatar-status {
  font-size: 11px;
  font-weight: 700;
  min-height: 16px;
  text-align: center;
  margin-top: 2px;
}

.avatar-status-success { color: #167a16; }
.avatar-status-error { color: #b81414; }
.avatar-status-info { color: var(--blue); }

.avatar-guest {
  padding: 28px 20px;
  text-align: center;
  background-color: #ffffff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

.avatar-guest p {
  margin-bottom: 14px;
  color: var(--muted);
  font-size: 13px;
}

/* Skeletons */
.skeleton-line {
  display: block;
  height: 10px;
  background-color: var(--border-light);
  border-radius: 2px;
  margin-bottom: 6px;
}
.skeleton-line-short { width: 50%; }
.skeleton-title { height: 14px; width: 70%; }

/* Table responsive wrapper */
.table-responsive {
  width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

/* Animations */
@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes slideInRight {
  from { transform: translateX(100%); }
  to { transform: translateX(0); }
}

/* ============================================================
   MOBILE RESPONSIVE SYSTEM (<= 768px)
   Maintains the retro skeuomorphic aesthetic while providing
   an app-native mobile user experience.
   ============================================================ */

@media (max-width: 768px) {
  body {
    overflow-x: hidden;
  }

  /* Layout & Sidebar */
  .page-layout {
    flex-direction: column;
    padding: 10px 10px calc(70px + env(safe-area-inset-bottom, 0px)) 10px;
    gap: 0;
  }

  .page-sidebar {
    display: none !important;
  }

  /* Topbar Mobile Transformation */
  .topbar-inner {
    padding: 0 10px;
    height: 48px;
    gap: 8px;
  }

  .topbar-left {
    gap: 8px;
  }

  .brand-logo-img {
    height: 30px;
  }

  .topbar-nav {
    display: none !important;
  }

  .topbar-search {
    display: none !important;
  }

  .topbar-download-btn {
    display: none !important;
  }

  .user-menu-wrap {
    display: none !important;
  }

  .topbar-auth {
    display: none !important;
  }

  .topbar-right {
    gap: 6px;
  }

  .topbar-icon-btn {
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    background-color: #2b3a4c;
    border: 1px solid #18222e;
    border-radius: 3px;
    color: #f0f4f9;
    cursor: pointer;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.12), 0 1px 2px rgba(0, 0, 0, 0.2);
    padding: 0;
    flex-shrink: 0;
  }

  .topbar-icon-btn:hover,
  .topbar-icon-btn:active {
    background-color: #364960;
    color: #ffffff;
  }

  .topbar-icon-btn i.ph-bold,
  .topbar-icon-btn i.ph {
    font-size: 19px;
    line-height: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }

  /* Mobile Search Bar & Suggestions */
  .mobile-search-bar {
    display: block !important;
    background-color: #223040;
    border-top: 1px solid #18222e;
    border-bottom: 2px solid #101720;
    padding: 8px 10px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.25);
    position: relative;
    z-index: 99;
    animation: fadeIn 0.15s ease-out;
  }

  .mobile-search-form {
    display: flex;
    gap: 6px;
    align-items: center;
  }

  .mobile-search-form input {
    flex: 1;
    height: 32px;
    font-size: 13px;
    border: 1px solid #18222e;
    border-radius: 3px;
    padding: 0 8px;
    background-color: #ffffff;
    color: var(--ink);
    outline: none;
    box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.15);
  }

  .mobile-search-form input:focus {
    border-color: var(--blue);
  }

  .mobile-search-close {
    background: none;
    border: none;
    color: #ffffff;
    font-size: 24px;
    line-height: 1;
    cursor: pointer;
    padding: 0 4px;
    opacity: 0.8;
  }

  .mobile-search-close:hover {
    opacity: 1;
  }

  .mobile-search-suggestions {
    background: #ffffff;
    border: 1px solid var(--border-dark);
    border-radius: 3px;
    margin-top: 6px;
    max-height: 240px;
    overflow-y: auto;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
  }

  /* Mobile Bottom Navigation Dock */
  .mobile-bottom-nav {
    display: flex !important;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    height: calc(52px + env(safe-area-inset-bottom, 0px));
    padding-bottom: env(safe-area-inset-bottom, 0px);
    background: linear-gradient(180deg, #2b3a4c 0%, #1c2734 100%);
    border-top: 2px solid var(--gold-border);
    box-shadow: 0 -2px 8px rgba(0, 0, 0, 0.3);
    z-index: 1000;
    justify-content: space-around;
    align-items: stretch;
  }

  .dock-tab {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: #a9bed6;
    text-decoration: none;
    font-size: 10px;
    font-weight: 700;
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px 2px;
    transition: color 0.1s ease;
    -webkit-tap-highlight-color: transparent;
  }

  .dock-tab:hover,
  .dock-tab:active,
  .dock-tab.active {
    color: #ffffff;
    text-decoration: none;
  }

  .dock-tab.active .dock-icon,
  .dock-tab:active .dock-icon {
    color: var(--gold-bright);
  }

  .dock-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 22px;
    margin-bottom: 2px;
  }

  .dock-icon i.ph-bold,
  .dock-icon i.ph {
    font-size: 20px;
    line-height: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }

  .dock-label {
    font-size: 10px;
    line-height: 1;
    font-weight: 700;
    letter-spacing: 0.2px;
  }

  /* Mobile Slide-out Navigation Drawer */
  .mobile-drawer-backdrop {
    display: block !important;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.6);
    z-index: 1100;
    backdrop-filter: blur(1px);
    animation: fadeIn 0.15s ease-out;
  }

  .mobile-drawer {
    display: flex !important;
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    width: 280px;
    max-width: 85vw;
    background-color: #ffffff;
    z-index: 1101;
    box-shadow: -4px 0 20px rgba(0, 0, 0, 0.35);
    flex-direction: column;
    overflow-y: auto;
    animation: slideInRight 0.2s ease-out;
  }

  .mobile-drawer-header {
    background: linear-gradient(180deg, #2b3a4c 0%, #1e2b3c 100%);
    padding: 12px 14px;
    border-bottom: 2px solid var(--gold-border);
    display: flex;
    align-items: center;
    justify-content: space-between;
    color: #ffffff;
  }

  .drawer-user-info {
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 0;
  }

  .drawer-user-avatar {
    width: 36px;
    height: 36px;
    border-radius: 3px;
    border: 1px solid rgba(255, 255, 255, 0.4);
    background-color: #ffffff;
    flex-shrink: 0;
    object-fit: cover;
  }

  .drawer-user-text {
    min-width: 0;
    display: flex;
    flex-direction: column;
  }

  .drawer-user-name {
    font-size: 14px;
    font-weight: 800;
    color: #ffffff;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .drawer-user-badge {
    font-size: 10px;
    font-weight: 700;
    color: var(--gold-bright);
    text-transform: uppercase;
    letter-spacing: 0.5px;
  }

  .drawer-guest-info {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    gap: 10px;
  }

  .drawer-guest-title {
    font-size: 16px;
    font-weight: 800;
    color: #ffffff;
    letter-spacing: 0.5px;
  }

  .drawer-auth-btns {
    display: flex;
    gap: 6px;
  }

  .drawer-close-btn {
    background: none;
    border: none;
    color: #ffffff;
    font-size: 24px;
    line-height: 1;
    cursor: pointer;
    padding: 0 4px;
    opacity: 0.8;
  }

  .drawer-close-btn:hover {
    opacity: 1;
  }

  .mobile-drawer-body {
    padding: 8px 0;
    flex: 1;
    overflow-y: auto;
  }

  .drawer-section {
    padding: 8px 12px 10px 12px;
    border-bottom: 1px solid var(--border-light);
  }

  .drawer-section-title {
    font-size: 10px;
    font-weight: 800;
    color: var(--ink-light);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 6px;
    padding-left: 4px;
  }

  .drawer-nav a {
    display: block;
    padding: 8px 10px;
    color: var(--blue-dark);
    text-decoration: none;
    font-size: 13px;
    font-weight: 700;
    border-radius: 3px;
    margin-bottom: 2px;
  }

  .drawer-nav a:hover,
  .drawer-nav a:active {
    background-color: #eef4fb;
    color: var(--blue);
  }

  .drawer-nav-mod {
    color: #c2410c !important;
  }

  .drawer-logout-btn {
    width: 100%;
    padding: 8px 10px;
    background-color: #fee2e2;
    border: 1px solid #fca5a5;
    color: #b91c1c;
    font-size: 13px;
    font-weight: 700;
    border-radius: 3px;
    cursor: pointer;
    text-align: center;
    margin-top: 4px;
  }

  .drawer-logout-btn:hover {
    background-color: #fecaca;
  }

  /* Responsive Games Grid */
  .games-grid {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 8px !important;
  }

  .game-tile {
    width: 100%;
    max-width: none;
  }

  .game-thumb-wrap {
    aspect-ratio: 16 / 9;
    width: 100%;
  }

  .game-title {
    font-size: 12px;
    line-height: 1.25;
    max-height: 2.5em;
    overflow: hidden;
  }

  .game-meta {
    font-size: 10px;
  }

  /* Responsive Hero */
  .hero-content {
    padding: 12px;
  }

  .hero-title {
    font-size: 18px;
    line-height: 1.2;
  }

  .hero-sub {
    font-size: 12px;
    margin-bottom: 12px;
  }

  .hero-actions {
    flex-direction: column;
    width: 100%;
    gap: 6px;
  }

  .hero-actions .btn {
    width: 100%;
    text-align: center;
  }

  /* Responsive Category Tabs */
  .category-tabs {
    overflow-x: auto;
    flex-wrap: nowrap;
    -webkit-overflow-scrolling: touch;
    padding-bottom: 4px;
    gap: 4px;
  }

  .filter-tab {
    flex-shrink: 0;
    white-space: nowrap;
    font-size: 11px;
    padding: 4px 8px;
  }

  /* Responsive Game Detail */
  .game-detail-layout {
    grid-template-columns: 1fr !important;
  }

  .game-action-bar {
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
  }

  .game-action-bar .btn-play-lg {
    width: 100%;
    justify-content: center;
  }

  /* Responsive Profile */
  .profile-layout {
    grid-template-columns: 1fr !important;
  }

  .profile-friends-grid {
    grid-template-columns: repeat(auto-fill, minmax(76px, 1fr)) !important;
    gap: 8px;
  }

  .profile-friend-avatar-wrap {
    width: 64px;
    height: 64px;
  }

  .profile-places-grid {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 8px;
  }

  /* Responsive Avatar Editor */
  .avatar-editor-root {
    flex-direction: column !important;
  }

  .avatar-viewport {
    width: 100%;
    height: 260px;
    min-height: 260px;
    touch-action: none;
  }

  #avatar-canvas {
    touch-action: none;
  }

  .face-grid {
    grid-template-columns: repeat(4, 1fr);
  }

  .color-swatches {
    grid-template-columns: repeat(8, 1fr);
    gap: 4px;
  }

  .swatch {
    min-height: 28px;
  }

  /* Responsive Modal & Toast */
  .modal {
    width: 92vw;
    max-width: 440px;
    margin: 12px;
  }

  .toast-host {
    left: 10px;
    right: 10px;
    bottom: calc(60px + env(safe-area-inset-bottom, 0px));
  }
}

/* ============================================================
   MODERATION NOTICE & REVIEW
   ============================================================ */

.moderation-page-wrapper {
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: calc(100vh - 120px);
  padding: 24px 16px;
  background-color: var(--canvas);
}

.moderation-card {
  width: 100%;
  max-width: 600px;
  background-color: #ffffff;
  border: 1px solid #d1d5db;
  border-radius: var(--radius);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
  overflow: hidden;
}

.moderation-header {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px 20px;
  background: linear-gradient(180deg, #fef2f2 0%, #fee2e2 100%);
  border-bottom: 1px solid #fca5a5;
}

.moderation-icon-box {
  display: flex;
  align-items: center;
  justify-content: center;
}

.moderation-title {
  font-size: 20px;
  font-weight: 800;
  color: #991b1b;
  margin: 0;
  letter-spacing: -0.2px;
}

.moderation-body {
  padding: 20px;
}

.moderation-intro {
  font-size: 13px;
  color: var(--ink);
  margin-bottom: 16px;
  line-height: 1.5;
}

.moderation-details-box {
  background-color: #f9fafb;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 12px 14px;
  margin-bottom: 18px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.moderation-detail-row {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

@media (min-width: 480px) {
  .moderation-detail-row {
    flex-direction: row;
    gap: 8px;
  }
}

.moderation-label {
  font-size: 12px;
  font-weight: 700;
  color: var(--muted);
  min-width: 110px;
}

.moderation-value {
  font-size: 13px;
  color: var(--ink);
  word-break: break-word;
}

.moderation-action-area {
  padding-top: 14px;
  border-top: 1px solid var(--border-light);
}

.moderation-notice-text {
  font-size: 13px;
  color: var(--muted);
  margin-bottom: 16px;
  line-height: 1.4;
}

.moderation-reset-form {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 12px;
}

@media (min-width: 480px) {
  .moderation-reset-form {
    flex-direction: row;
  }
  .moderation-reset-form .input {
    flex: 1;
  }
}

.status-pill-red {
  background: #fef2f2 !important;
  color: #991b1b !important;
  border: 1px solid #fca5a5 !important;
}

.status-pill-orange {
  background: #fff7ed !important;
  color: #c2410c !important;
  border: 1px solid #fdba74 !important;
}

.status-pill-yellow {
  background: #fefce8 !important;
  color: #a16207 !important;
  border: 1px solid #fde047 !important;
}

.status-pill-green {
  background: #f0fdf4 !important;
  color: #15803d !important;
  border: 1px solid #86efac !important;
}

.status-pill-purple {
  background: #fdf4ff !important;
  color: #86198f !important;
  border: 1px solid #f0abfc !important;
}

.status-pill-blue {
  background: #eff6ff !important;
  color: #1d4ed8 !important;
  border: 1px solid #bfdbfe !important;
}

/* ============================================================
   EXPANDED MODERATION PANEL
   ============================================================ */

.mod-panel-container {
  max-width: 1200px !important;
  margin: 0 auto;
  width: 100%;
}

.mod-panel-card {
  background: #ffffff;
  border: 1px solid var(--border);
  border-radius: 4px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06);
  padding: 22px 24px;
  margin-bottom: 24px;
}

.mod-header-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: 16px;
  margin-bottom: 18px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--border-light);
}

.mod-title-area h2 {
  font-size: 22px;
  font-weight: 800;
  color: var(--ink);
  margin-bottom: 4px;
}

.mod-title-area p {
  color: var(--muted);
  font-size: 13px;
  margin: 0;
}

.mod-stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 12px;
  margin-bottom: 20px;
}

.mod-stat-card {
  background: #f8fafc;
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 12px 16px;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.mod-stat-card.alert {
  background: #fff7ed;
  border-color: #fed7aa;
}

.mod-stat-num {
  font-size: 24px;
  font-weight: 800;
  color: var(--ink);
}

.mod-stat-card.alert .mod-stat-num {
  color: #c2410c;
}

.mod-stat-label {
  font-size: 11px;
  font-weight: 700;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.mod-controls-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  background: #f1f5f9;
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 10px 14px;
  margin-bottom: 16px;
}

.mod-search-box {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 1;
  min-width: 240px;
  max-width: 480px;
}

.mod-search-input {
  width: 100%;
  padding: 7px 12px;
  font-size: 13px;
  border: 1px solid var(--border);
  border-radius: 3px;
  background: #ffffff;
  color: var(--ink);
}

.mod-search-input:focus {
  outline: none;
  border-color: var(--blue);
  box-shadow: 0 0 0 2px rgba(36, 91, 152, 0.2);
}

.mod-filter-select {
  padding: 7px 12px;
  font-size: 12px;
  font-weight: 600;
  border: 1px solid var(--border);
  border-radius: 3px;
  background: #ffffff;
  color: var(--ink);
  cursor: pointer;
}

.mod-table-wrapper {
  overflow-x: auto;
  border: 1px solid var(--border);
  border-radius: 4px;
  background: #ffffff;
}

.mod-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
  text-align: left;
}

.mod-table th {
  background: #e2e8f0;
  border-bottom: 2px solid #cbd5e1;
  padding: 10px 14px;
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: #334155;
  white-space: nowrap;
}

.mod-table td {
  padding: 10px 14px;
  border-bottom: 1px solid #f1f5f9;
  vertical-align: middle;
  color: var(--ink);
}

.mod-table tr:last-child td {
  border-bottom: none;
}

.mod-table tr:nth-child(even) td {
  background: #f8fafc;
}

.mod-table tr:hover td {
  background: #f1f5f9;
}

.mod-user-cell {
  display: flex;
  align-items: center;
  gap: 10px;
}

.mod-user-avatar {
  width: 36px;
  height: 36px;
  border-radius: 4px;
  background: #cbd5e1;
  object-fit: cover;
  flex-shrink: 0;
  border: 1px solid var(--border);
  display: block;
}

.mod-user-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.mod-user-name {
  font-weight: 700;
  color: var(--ink);
  text-decoration: none;
}

.mod-user-name:hover {
  text-decoration: underline;
  color: var(--blue);
}

.mod-user-orig {
  font-size: 11px;
  color: #991b1b;
  font-weight: 600;
}

.mod-actions-cell {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  align-items: center;
}

.btn-action-punish {
  background: #ef4444;
  border: 1px solid #dc2626;
  color: #ffffff;
  padding: 5px 10px;
  font-size: 11px;
  font-weight: 700;
  border-radius: 3px;
  cursor: pointer;
}

.btn-action-punish:hover:not(:disabled) {
  background: #dc2626;
}

.btn-action-reset {
  background: #f59e0b;
  border: 1px solid #d97706;
  color: #ffffff;
  padding: 5px 10px;
  font-size: 11px;
  font-weight: 700;
  border-radius: 3px;
  cursor: pointer;
}

.btn-action-reset:hover:not(:disabled) {
  background: #d97706;
}

.btn-action-unban {
  background: #16a34a;
  border: 1px solid #15803d;
  color: #ffffff;
  padding: 5px 10px;
  font-size: 11px;
  font-weight: 700;
  border-radius: 3px;
  cursor: pointer;
}

.btn-action-unban:hover:not(:disabled) {
  background: #15803d;
}

.btn-action-neutral {
  background: #f1f5f9;
  border: 1px solid #cbd5e1;
  color: #334155;
  padding: 5px 10px;
  font-size: 11px;
  font-weight: 700;
  border-radius: 3px;
  cursor: pointer;
  text-decoration: none;
}

.btn-action-neutral:hover:not(:disabled) {
  background: #e2e8f0;
  color: #0f172a;
}

