/* Shared navigation: one header size, tab order, and tab sizing across all pages. */
:root {
  --site-header-height: 76px;
  --site-nav-gap: 4px;
  --site-nav-pad-y: 10px;
  --site-nav-pad-x: 10px;
  --site-nav-font: 12px;
  --header-height: var(--site-header-height);
  --hh: var(--site-header-height);
  --site-radius: 8px;
  --site-focus: 0 0 0 3px rgba(255, 51, 102, 0.18);
  --site-card-border: #2a1820;
  --site-card-bg: #1a0f15;
  --site-card-bg-hover: #221319;
  --site-nav-scrollbar: rgba(255, 51, 102, 0.55);
}

html {
  -webkit-text-size-adjust: 100%;
}

body {
  overflow-x: hidden;
  text-rendering: geometricPrecision;
}

img,
svg,
canvas,
iframe,
video {
  max-width: 100%;
}

button,
input,
select,
textarea {
  font-family: Inter, "Segoe UI", Arial, sans-serif;
}

button,
a,
[role="button"] {
  touch-action: manipulation;
}

a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
[tabindex]:focus-visible {
  outline: none !important;
  box-shadow: var(--site-focus) !important;
}

.header,
header.header {
  height: var(--site-header-height) !important;
  min-height: var(--site-header-height) !important;
  background: rgba(10, 6, 8, 0.98) !important;
  border-bottom: 1px solid #2a1820 !important;
}

.header-container,
.hc {
  width: 100% !important;
  max-width: 1400px !important;
  height: var(--site-header-height) !important;
  min-height: var(--site-header-height) !important;
  margin: 0 auto !important;
  padding: 0 24px !important;
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  gap: 18px !important;
}

.logo {
  flex: 0 0 auto !important;
}

.logo,
.logo-text {
  white-space: nowrap !important;
}

.logo > span,
.logo-text > span {
  margin-left: 5px !important;
}

.nav {
  flex: 1 1 auto !important;
  min-width: 0 !important;
  max-width: none !important;
  display: flex !important;
  align-items: center !important;
  justify-content: flex-start !important;
  gap: var(--site-nav-gap) !important;
  row-gap: 0 !important;
  flex-wrap: nowrap !important;
  overflow-x: auto !important;
  overflow-y: hidden !important;
  scrollbar-width: none !important;
  scrollbar-color: var(--site-nav-scrollbar) rgba(255, 255, 255, 0.06) !important;
  scroll-behavior: smooth !important;
  padding-bottom: 0 !important;
  mask-image: none !important;
  -webkit-mask-image: none !important;
}

.nav::-webkit-scrollbar {
  display: none;
  height: 6px;
}

.nav::-webkit-scrollbar-track {
  background: rgba(255, 255, 255, 0.06);
  border-radius: 999px;
}

.nav::-webkit-scrollbar-thumb {
  background: var(--site-nav-scrollbar);
  border-radius: 999px;
}

.nav-link,
.nl,
.site-nav-link {
  flex: 0 0 auto !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  min-height: 34px !important;
  padding: var(--site-nav-pad-y) var(--site-nav-pad-x) !important;
  border-radius: 6px !important;
  color: #c9a0b0 !important;
  font-family: Inter, Arial, sans-serif !important;
  font-size: var(--site-nav-font) !important;
  font-weight: 700 !important;
  line-height: 1 !important;
  letter-spacing: 0 !important;
  text-transform: uppercase !important;
  text-decoration: none !important;
  white-space: nowrap !important;
  transition: background 150ms ease, color 150ms ease !important;
}

.eu-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.35em;
  min-width: 1.35em;
  margin-right: 0.45em;
  font-family: "Segoe UI Emoji", "Apple Color Emoji", "Noto Color Emoji", "Segoe UI Symbol", sans-serif;
  font-size: 1em;
  line-height: 1;
  filter: drop-shadow(0 0 8px rgba(255, 51, 102, 0.22));
}

html[data-game="isle"] .eu-icon {
  filter: drop-shadow(0 0 8px rgba(6, 215, 244, 0.28));
}

.card-icon .eu-icon,
.commands-section-icon .eu-icon,
.empty-state-icon .eu-icon,
.map-icon .eu-icon,
.map-error-icon .eu-icon,
.wc-icon .eu-icon {
  margin-right: 0;
  font-size: 1.15em;
}

.site-polished .page-title,
.site-polished .hero-title,
.site-polished .title,
.site-polished .pt {
  text-shadow: 0 0 28px rgba(255, 51, 102, 0.18);
}

html[data-game="isle"] .site-polished .page-title,
html[data-game="isle"] .site-polished .hero-title,
html[data-game="isle"] .site-polished .title,
html[data-game="isle"] .site-polished .pt {
  text-shadow: 0 0 28px rgba(6, 215, 244, 0.2);
}

.site-polished .status-value.online,
.site-polished .pill.online,
.site-polished .value.online {
  color: #22c55e !important;
  text-shadow: 0 0 18px rgba(34, 197, 94, 0.26);
}

.site-polished .status-value.offline,
.site-polished .pill.offline,
.site-polished .value.offline {
  color: #ef4444 !important;
}

.site-polished .nav-link,
.site-polished .nl,
.site-polished .site-nav-link,
.site-polished button,
.site-polished .btn {
  gap: 0.35em;
}

.nav-link:hover,
.nl:hover,
.site-nav-link:hover {
  color: #ffffff !important;
  background: rgba(255, 255, 255, 0.05) !important;
}

.nav-link.active,
.nl.active,
.site-nav-link.active {
  color: #ff3366 !important;
  background: rgba(255, 51, 102, 0.08) !important;
}

.nav-link.discord,
.nl.discord,
.site-nav-link.discord {
  background: #5865f2 !important;
  color: #ffffff !important;
}

.game-switcher {
  flex: 0 0 auto !important;
  display: inline-flex !important;
  align-items: center !important;
  gap: 2px !important;
  padding: 3px !important;
  border: 1px solid rgba(255, 255, 255, 0.12) !important;
  border-radius: 7px !important;
  background: rgba(255, 255, 255, 0.04) !important;
  margin-left: 4px !important;
}

.game-switcher-btn {
  min-height: 28px !important;
  border: 0 !important;
  border-radius: 5px !important;
  padding: 7px 9px !important;
  color: #c9a0b0 !important;
  background: transparent !important;
  font-family: Inter, Arial, sans-serif !important;
  font-size: 11px !important;
  font-weight: 800 !important;
  line-height: 1 !important;
  text-transform: uppercase !important;
  letter-spacing: 0 !important;
  cursor: pointer !important;
  white-space: nowrap !important;
}

.game-switcher-btn:hover {
  color: #ffffff !important;
  background: rgba(255, 255, 255, 0.06) !important;
}

.game-switcher-btn.active {
  color: #ffffff !important;
  background: #ff3366 !important;
}

.admin-link {
  background: rgba(255, 51, 102, 0.15) !important;
  border: 1px solid rgba(255, 51, 102, 0.3) !important;
  color: #ff3366 !important;
}

.admin-link[style*="display:none"],
.admin-link[style*="display: none"] {
  display: none !important;
}

.logout-link {
  color: #ef4444 !important;
}

.main,
.page-content,
.main-content,
.hero,
.page-hero,
.servers-section,
.features-section {
  overflow-x: hidden !important;
}

body > main.main,
body > .page-content {
  padding-top: calc(var(--site-header-height) + 40px) !important;
}

.container,
.wrap,
.header-container,
.hc,
.footer-container,
.fc,
.footer-inner {
  width: min(100%, 1400px) !important;
}

.page-title,
.hero-title,
.title,
.pt,
.server-name,
.panel-title,
.feature-title,
.game h2 {
  overflow-wrap: anywhere;
}

.main-server-card,
.feature-card,
.info-section,
.connect-section,
.leaderboard,
.map-card,
.chat-box,
.status-card,
.wallet-card,
.game,
.game-card,
.tcard,
.atrow,
.log-row,
.stat-card,
.catcard,
.tform,
.sukbox,
.row,
.empty,
.balance-bar,
.server-ip-box,
.no-server-message,
.table,
.card,
.panel,
.toast,
.modal,
.user-card,
.chatter-item,
.user-manage-panel,
.ticket-card {
  border-radius: var(--site-radius) !important;
}

.main-server-card,
.feature-card,
.info-section,
.connect-section,
.leaderboard,
.map-card,
.chat-box,
.status-card,
.game,
.game-card,
.tcard,
.atrow,
.log-row,
.stat-card,
.catcard,
.tform,
.sukbox,
.row,
.empty,
.balance-bar,
.server-ip-box,
.no-server-message {
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.16) !important;
}

.tabs,
.tabbar,
.region-tabs,
.mod-tabs {
  display: flex !important;
  align-items: center !important;
  justify-content: flex-start !important;
  gap: 6px !important;
  padding: 5px !important;
  background: rgba(26, 15, 21, 0.78) !important;
  border: 1px solid var(--site-card-border) !important;
  border-radius: var(--site-radius) !important;
  overflow-x: auto !important;
  overflow-y: hidden !important;
  scrollbar-width: none !important;
}

.tabs::-webkit-scrollbar,
.tabbar::-webkit-scrollbar,
.region-tabs::-webkit-scrollbar,
.mod-tabs::-webkit-scrollbar {
  display: none;
}

.tab-btn,
.tb,
.region-tab,
.mod-tab {
  flex: 1 0 auto !important;
  min-width: max-content !important;
  min-height: 38px !important;
  padding: 9px 14px !important;
  border-radius: 6px !important;
  border: 1px solid transparent !important;
  background: transparent !important;
  color: #c9a0b0 !important;
  font-size: 13px !important;
  font-weight: 800 !important;
  line-height: 1.1 !important;
  letter-spacing: 0 !important;
  text-transform: uppercase !important;
  white-space: nowrap !important;
}

.tab-btn:hover,
.tb:hover,
.region-tab:hover,
.mod-tab:hover {
  color: #ffffff !important;
  background: var(--site-card-bg-hover) !important;
  border-color: #463038 !important;
}

.tab-btn.active,
.tb.active,
.region-tab.active,
.mod-tab.active {
  color: #ffffff !important;
  background: #ff3366 !important;
  border-color: #ff3366 !important;
  box-shadow: 0 8px 20px rgba(255, 51, 102, 0.22) !important;
}

input,
select,
textarea {
  min-height: 40px;
}

button,
.btn,
.copy-btn,
.connect-btn,
.map-btn,
.send-btn,
.sbtn,
.ntbtn,
.claim-btn,
.open-chat-btn,
.resolve-btn,
.close-btn,
.spin-btn {
  border-radius: 6px !important;
}

.leaderboard,
.table-wrap,
.commands-table,
.mod-list,
.chat-msgs,
.chat-messages {
  overscroll-behavior: contain;
}

.leaderboard {
  overflow-x: auto !important;
}

.leaderboard table,
.commands-table {
  min-width: 560px;
}

.row,
.log-item,
.tc-top,
.at-top,
.chat-header,
.chat-bar,
.map-header,
.footer-container,
.fc,
.footer-inner {
  min-width: 0;
}

.name,
.player-name,
.msg-text,
.tc-preview,
.at-issue,
.log-desc {
  overflow-wrap: anywhere;
}

@media (max-width: 980px) {
  :root {
    --site-nav-pad-x: 9px;
    --site-nav-font: 12px;
  }

  .header-container,
  .hc {
    padding: 0 16px !important;
  }
}

@media (max-width: 760px) {
  .header,
  header.header {
    height: var(--site-header-height) !important;
    min-height: var(--site-header-height) !important;
  }

  .header-container,
  .hc {
    height: var(--site-header-height) !important;
    min-height: var(--site-header-height) !important;
    padding: 0 12px !important;
    display: flex !important;
    align-items: center !important;
    gap: 12px !important;
  }

  .logo {
    display: inline-flex !important;
    margin-bottom: 0 !important;
    min-width: max-content !important;
  }

  .nav {
    width: auto !important;
    justify-content: flex-start !important;
    padding-bottom: 0 !important;
  }

}

@media (max-width: 560px) {
  :root {
    --site-nav-pad-x: 8px;
    --site-nav-font: 11px;
  }

  .logo,
  .logo-text {
    font-size: 20px !important;
    letter-spacing: 1px !important;
  }

  .main,
  .page-content,
  .main-content {
    padding-left: 14px !important;
    padding-right: 14px !important;
  }

  .tab-btn,
  .tb,
  .region-tab,
  .mod-tab {
    flex-basis: auto !important;
  }
}

html[data-game="isle"] {
  --site-nav-scrollbar: rgba(6, 215, 244, 0.55);
  --red: #06d7f4 !important;
  --accent-primary: #06d7f4 !important;
  --accent-secondary: #39e8ff !important;
  --accent-glow: rgba(6, 215, 244, 0.28) !important;
  --accent-purple: #27308f !important;
  --gold: #53ecff !important;
  --ruby: #2f6dff !important;
  --bg: #03070d !important;
  --bg2: #06131d !important;
  --bg-primary: #03070d !important;
  --bg-secondary: #06131d !important;
  --bg-card: #071826 !important;
  --bg-card-hover: #0a2637 !important;
  --bg-header: rgba(3, 7, 13, 0.98) !important;
  --card: #071826 !important;
  --card2: #0a2637 !important;
  --hdr: rgba(3, 7, 13, 0.98) !important;
  --txt2: #a9d9e8 !important;
  --text-secondary: #a9d9e8 !important;
  --muted: #6792a5 !important;
  --text-muted: #6792a5 !important;
  --bdr: #123145 !important;
  --border-color: #123145 !important;
  --border-light: #1c5470 !important;
  --site-card-border: #123145 !important;
  --site-card-bg: #071826 !important;
  --site-card-bg-hover: #0a2637 !important;
}

html[data-game="isle"] body { background-color: #03070d !important; }
html[data-game="isle"] .header,
html[data-game="isle"] header.header { background: rgba(3, 7, 13, 0.98) !important; border-bottom-color: #123145 !important; }
html[data-game="isle"] .nav-link.active,
html[data-game="isle"] .nl.active,
html[data-game="isle"] .site-nav-link.active,
html[data-game="isle"] .logo-text span,
html[data-game="isle"] .logo span { color: #06d7f4 !important; }
html[data-game="isle"] .nav-link.active,
html[data-game="isle"] .nl.active,
html[data-game="isle"] .site-nav-link.active { background: rgba(6, 215, 244, 0.1) !important; }
html[data-game="isle"] .btn-primary,
html[data-game="isle"] button:not(.game-switcher-btn):not(.secondary):not(.danger):not(.color-square),
html[data-game="isle"] .enter-server,
html[data-game="isle"] .copy-btn,
html[data-game="isle"] .play-btn,
html[data-game="isle"] .join-btn,
html[data-game="isle"] .flip-btn,
html[data-game="isle"] .spin-btn,
html[data-game="isle"] .guess-btn,
html[data-game="isle"] .cashout-btn {
  background: linear-gradient(135deg, #087ba8, #06d7f4) !important;
  box-shadow: 0 0 24px rgba(6, 215, 244, 0.18) !important;
}
html[data-game="isle"] .wallet-card.coins { background: linear-gradient(135deg, #031823, #06374d) !important; border-color: rgba(6, 215, 244, 0.28) !important; }
html[data-game="isle"] .wallet-card.rubies { background: linear-gradient(135deg, #050b27, #102b68) !important; border-color: rgba(47, 109, 255, 0.34) !important; }

/* =========================================================================
   RUINS — visual enhancement layer
   Atmospheric backgrounds, grain, glowing borders, animated states.
   Layered on top of the base — does not break existing structure.
   ========================================================================= */

@import url('https://fonts.googleapis.com/css2?family=Bebas+Neue&family=Rajdhani:wght@500;600;700&family=JetBrains+Mono:wght@500;700&display=swap');

:root {
  --rx-grain: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 0.08 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  --rx-accent: var(--red, #ff3366);
  --rx-accent-soft: rgba(255, 51, 102, 0.18);
  --rx-accent-glow: rgba(255, 51, 102, 0.35);
}
html[data-game="isle"] {
  --rx-accent: #06d7f4;
  --rx-accent-soft: rgba(6, 215, 244, 0.16);
  --rx-accent-glow: rgba(6, 215, 244, 0.32);
}

/* ---- Body atmosphere: drifting radial glow + film grain ---------------- */
body::before,
body::after {
  content: '';
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
}
body::before {
  background:
    radial-gradient(ellipse 60% 50% at 20% 0%,   var(--rx-accent-soft) 0%, transparent 55%),
    radial-gradient(ellipse 55% 45% at 90% 100%, var(--rx-accent-soft) 0%, transparent 55%),
    radial-gradient(ellipse 35% 25% at 50% 50%,  rgba(255,255,255,0.022) 0%, transparent 60%);
  animation: rxDrift 24s ease-in-out infinite alternate;
  opacity: 0.9;
}
body::after {
  background-image: var(--rx-grain);
  background-size: 200px 200px;
  opacity: 0.32;
  mix-blend-mode: overlay;
}
@keyframes rxDrift {
  0%   { transform: translate3d(0,0,0) scale(1); }
  100% { transform: translate3d(-2%, 1%, 0) scale(1.04); }
}
/* keep page content above the atmosphere layers */
body > * { position: relative; z-index: 1; }

@media (prefers-reduced-motion: reduce) {
  body::before { animation: none; }
}

/* ---- Logo: subtle text-shadow halo ------------------------------------- */
.logo,
.logo-text {
  text-shadow:
    0 0 18px var(--rx-accent-glow),
    0 1px 0 rgba(0,0,0,0.4) !important;
}

/* ---- Header: dark glass with a thin glowing seam ----------------------- */
.header,
header.header {
  backdrop-filter: blur(14px) saturate(1.1) !important;
  -webkit-backdrop-filter: blur(14px) saturate(1.1) !important;
  position: relative;
}
.header::after,
header.header::after {
  content: '';
  position: absolute;
  left: 0; right: 0; bottom: -1px;
  height: 1px;
  background: linear-gradient(90deg,
    transparent 0%,
    var(--rx-accent) 18%,
    transparent 35%,
    var(--rx-accent) 65%,
    transparent 100%);
  opacity: 0.55;
  pointer-events: none;
}

/* ---- Nav links: animated underline on hover, glow on active ------------ */
.nav-link,
.nl,
.site-nav-link {
  position: relative;
  letter-spacing: 0.6px !important;
}
.nav-link::after,
.nl::after,
.site-nav-link::after {
  content: '';
  position: absolute;
  left: 12%; right: 12%; bottom: 2px;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--rx-accent), transparent);
  transform: scaleX(0);
  transform-origin: center;
  transition: transform 220ms cubic-bezier(0.4, 0, 0.2, 1);
  pointer-events: none;
}
.nav-link:hover::after,
.nl:hover::after,
.site-nav-link:hover::after,
.nav-link.active::after,
.nl.active::after,
.site-nav-link.active::after { transform: scaleX(1); }
.nav-link.active,
.nl.active,
.site-nav-link.active {
  box-shadow: inset 0 0 0 1px var(--rx-accent-soft) !important;
}

/* ---- Game switcher: glowing active pill -------------------------------- */
.game-switcher-btn.active {
  box-shadow:
    0 0 0 1px var(--rx-accent),
    0 6px 18px var(--rx-accent-glow),
    inset 0 1px 0 rgba(255,255,255,0.18) !important;
}

/* ---- Page titles: heavy display treatment + chromatic shadow ----------- */
.page-title,
.hero-title,
.pt {
  font-family: 'Bebas Neue', 'Rajdhani', Impact, sans-serif !important;
  letter-spacing: 0.06em !important;
  text-shadow:
    0 0 28px var(--rx-accent-soft),
    0 2px 0 rgba(0,0,0,0.45) !important;
}
.page-title::after,
.hero-title::after {
  content: '';
  display: block;
  width: 64px;
  height: 3px;
  margin: 12px auto 0;
  background: linear-gradient(90deg, transparent, var(--rx-accent), transparent);
  border-radius: 2px;
  box-shadow: 0 0 14px var(--rx-accent-glow);
}

/* ---- Cards: gradient border halo on hover, decorative corner ticks ----- */
.main-server-card,
.feature-card,
.info-section,
.connect-section,
.map-card,
.chat-box,
.status-card,
.wallet-card,
.game,
.game-card,
.tcard,
.stat-card,
.catcard,
.balance-bar,
.server-ip-box,
.panel {
  position: relative;
  transition: transform 280ms cubic-bezier(0.2, 0.8, 0.2, 1),
              border-color 220ms ease,
              box-shadow 280ms ease !important;
}

/* faint gradient border halo that appears on hover */
.main-server-card::before,
.feature-card::before,
.game::before,
.game-card::before,
.stat-card::before,
.tcard::before,
.catcard::before {
  content: '';
  position: absolute;
  inset: -1px;
  border-radius: inherit;
  padding: 1px;
  background: linear-gradient(135deg,
    var(--rx-accent) 0%,
    transparent 35%,
    transparent 65%,
    var(--rx-accent) 100%);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
          mask-composite: exclude;
  opacity: 0;
  transition: opacity 280ms ease;
  pointer-events: none;
  z-index: 1;
}
.main-server-card:hover::before,
.feature-card:hover::before,
.game:hover::before,
.game-card:hover::before,
.stat-card:hover::before,
.tcard:hover::before,
.catcard:hover::before { opacity: 0.85; }

.main-server-card:hover,
.feature-card:hover,
.game:hover,
.game-card:hover {
  transform: translateY(-3px) !important;
  box-shadow:
    0 22px 60px rgba(0,0,0,0.4),
    0 0 0 1px var(--rx-accent-soft),
    0 0 50px var(--rx-accent-soft) !important;
}

/* ---- Tabs: glow + soft pulse on the active one ------------------------- */
.tab-btn.active,
.tb.active,
.region-tab.active,
.mod-tab.active {
  background: linear-gradient(135deg, var(--rx-accent), color-mix(in srgb, var(--rx-accent) 70%, #000)) !important;
  box-shadow:
    0 10px 28px var(--rx-accent-glow),
    inset 0 1px 0 rgba(255,255,255,0.22),
    0 0 0 1px var(--rx-accent) !important;
  position: relative;
}
.tab-btn.active::after,
.tb.active::after,
.region-tab.active::after,
.mod-tab.active::after {
  content: '';
  position: absolute;
  inset: -2px;
  border-radius: inherit;
  background: var(--rx-accent);
  filter: blur(14px);
  opacity: 0.35;
  z-index: -1;
}

/* ---- Buttons: gradient sheen + glow lift ------------------------------- */
button,
.btn,
.copy-btn,
.connect-btn,
.send-btn,
.sbtn,
.claim-btn,
.spin-btn,
.flip-btn,
.play-btn,
.cashout-btn,
.guess-btn,
.join-btn,
.buy-btn,
.sell-btn {
  position: relative;
  overflow: hidden;
  transition: transform 160ms ease, box-shadow 220ms ease, filter 160ms ease !important;
}
button:not(.color-square):not(:disabled):hover,
.btn:not(:disabled):hover,
.copy-btn:not(:disabled):hover,
.connect-btn:not(:disabled):hover,
.send-btn:not(:disabled):hover,
.claim-btn:not(:disabled):hover,
.spin-btn:not(:disabled):hover,
.flip-btn:not(:disabled):hover,
.play-btn:not(:disabled):hover,
.cashout-btn:not(:disabled):hover,
.guess-btn:not(:disabled):hover,
.join-btn:not(:disabled):hover,
.buy-btn:not(:disabled):hover,
.sell-btn:not(:disabled):hover {
  transform: translateY(-1px);
  filter: brightness(1.08);
}
button:not(.color-square):not(:disabled):active,
.btn:not(:disabled):active { transform: translateY(0); }

/* sheen sweep on primary action buttons */
.connect-btn::before,
.copy-btn::before,
.spin-btn::before,
.flip-btn::before,
.play-btn::before,
.guess-btn::before,
.join-btn::before,
.cashout-btn::before {
  content: '';
  position: absolute;
  top: 0; left: -120%;
  width: 60%; height: 100%;
  background: linear-gradient(100deg, transparent, rgba(255,255,255,0.22), transparent);
  transition: left 600ms ease;
  pointer-events: none;
}
.connect-btn:hover::before,
.copy-btn:hover::before,
.spin-btn:hover::before,
.flip-btn:hover::before,
.play-btn:hover::before,
.guess-btn:hover::before,
.join-btn:hover::before,
.cashout-btn:hover::before { left: 120%; }

/* ---- Inputs: refined focus glow ---------------------------------------- */
input:not([type="checkbox"]):not([type="radio"]),
select,
textarea {
  transition: border-color 180ms ease, box-shadow 180ms ease, background 180ms ease;
}
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  box-shadow:
    0 0 0 3px var(--rx-accent-soft),
    0 0 22px var(--rx-accent-soft) !important;
  border-color: var(--rx-accent) !important;
}

/* ---- Scrollbars: gradient thumb ---------------------------------------- */
*::-webkit-scrollbar { width: 8px; height: 8px; }
*::-webkit-scrollbar-track { background: rgba(0,0,0,0.25); }
*::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, var(--rx-accent), color-mix(in srgb, var(--rx-accent) 55%, #000));
  border-radius: 999px;
  box-shadow: 0 0 8px var(--rx-accent-glow);
}
* { scrollbar-color: var(--rx-accent) rgba(0,0,0,0.25); }

/* ---- Numeric balances and stats: tabular display font ------------------ */
.balance-bar span,
.wallet-card .amount,
.stat-card .value,
.stat-card .num,
.stat-card b,
.stat-num,
.amount,
.coins,
.rubies,
.balance,
.balance-bar b {
  font-family: 'Bebas Neue', 'Rajdhani', sans-serif !important;
  font-variant-numeric: tabular-nums !important;
  letter-spacing: 0.04em !important;
}

/* ---- Active-state pulse for live indicators ---------------------------- */
.live-dot,
.status-online,
.online-badge,
.dot.online,
.status-dot.online {
  position: relative;
}
.live-dot::after,
.status-online::after,
.online-badge::after,
.dot.online::after,
.status-dot.online::after {
  content: '';
  position: absolute;
  inset: -4px;
  border-radius: 50%;
  background: #22c55e;
  opacity: 0;
  animation: rxPulse 1.8s ease-out infinite;
  pointer-events: none;
}
@keyframes rxPulse {
  0%   { opacity: 0.55; transform: scale(0.6); }
  100% { opacity: 0;    transform: scale(2.2); }
}

/* ---- Discord nav button: subtle glow ----------------------------------- */
.nav-link.discord,
.nl.discord,
.site-nav-link.discord {
  box-shadow: 0 6px 18px rgba(88, 101, 242, 0.34) !important;
}
.nav-link.discord:hover,
.nl.discord:hover,
.site-nav-link.discord:hover {
  filter: brightness(1.1);
}

/* ---- Selection color --------------------------------------------------- */
::selection {
  background: var(--rx-accent);
  color: #fff;
}

/* ---- Reduce visual noise on tiny screens ------------------------------- */
@media (max-width: 560px) {
  body::after { opacity: 0.18; }
  .page-title,
  .hero-title { letter-spacing: 0.04em !important; }
}

/* =========================================================================
   RUINS — DEEP visual overhaul layer (v2)
   Pushes harder so every interior page transforms, not just gets polished.
   Targets the class names actually used across the codebase.
   ========================================================================= */

/* ---- BODY: stronger atmosphere on every page --------------------------- */
body {
  background-image:
    radial-gradient(ellipse 70% 50% at 15% -10%, var(--rx-accent-soft), transparent 55%),
    radial-gradient(ellipse 60% 50% at 85% 110%, var(--rx-accent-soft), transparent 55%),
    radial-gradient(ellipse 100% 60% at 50% 50%, rgba(255,255,255,0.012), transparent 70%) !important;
  background-attachment: fixed !important;
}

/* ---- HEADER: heavier glass, brighter logo seam ------------------------- */
.header,
header.header {
  background: linear-gradient(180deg,
    rgba(10, 6, 8, 0.95) 0%,
    rgba(10, 6, 8, 0.78) 100%) !important;
  border-bottom: none !important;
  box-shadow:
    0 1px 0 rgba(255,255,255,0.04),
    0 24px 60px rgba(0, 0, 0, 0.35) !important;
}
html[data-game="isle"] .header,
html[data-game="isle"] header.header {
  background: linear-gradient(180deg,
    rgba(3, 7, 13, 0.95) 0%,
    rgba(3, 7, 13, 0.78) 100%) !important;
}

/* logo text: real display weight on EVERY page */
.logo,
.logo-text {
  font-family: 'Bebas Neue', 'Rajdhani', Impact, sans-serif !important;
  letter-spacing: 0.18em !important;
  font-weight: 400 !important;
}

/* ---- PAGE TITLES: massive treatment across the board ------------------- */
.page-title,
.hero-title,
.title,
.pt,
.panel-title,
.section-title,
.feature-title,
.card-title {
  font-family: 'Bebas Neue', 'Rajdhani', Impact, sans-serif !important;
  letter-spacing: 0.05em !important;
  font-weight: 400 !important;
}
.page-title,
.hero-title {
  font-size: clamp(40px, 6vw, 72px) !important;
  line-height: 0.95 !important;
}

/* subtitles get a refined treatment */
.page-subtitle,
.subtitle {
  font-family: 'JetBrains Mono', 'Inter', monospace !important;
  font-size: 11px !important;
  font-weight: 600 !important;
  letter-spacing: 0.3em !important;
  text-transform: uppercase !important;
  color: rgba(255,255,255,0.55) !important;
}

/* ---- PANELS, CARDS, SURFACES: proper visual weight --------------------- */
.panel,
.card,
.feature-card,
.game,
.game-card,
.tcard,
.atrow,
.log-row,
.stat-card,
.stat-box,
.catcard,
.tform,
.sukbox,
.balance-bar,
.server-ip-box,
.status-card,
.wallet-card,
.map-card,
.chat-box,
.admin-card,
.connect-section,
.info-section,
.user-card,
.chatter-item,
.user-manage-panel,
.ticket-card,
.crate-btn,
.hub-section,
.mod-panel,
.empty,
.empty-state,
.no-server-message {
  background-image:
    radial-gradient(ellipse 80% 100% at 50% -20%, var(--rx-accent-soft), transparent 60%),
    linear-gradient(180deg, rgba(255,255,255,0.025) 0%, rgba(255,255,255,0.005) 30%, transparent 100%) !important;
  border: 1px solid rgba(255,255,255,0.06) !important;
  box-shadow:
    0 1px 0 rgba(255,255,255,0.04) inset,
    0 18px 44px rgba(0,0,0,0.28) !important;
  backdrop-filter: blur(2px);
  -webkit-backdrop-filter: blur(2px);
}

/* ---- HOVER LIFT for interactive cards ---------------------------------- */
.feature-card:hover,
.game:hover,
.game-card:hover,
.crate-btn:hover,
.admin-card:hover,
.tcard:hover,
.stat-card:hover {
  border-color: var(--rx-accent-soft) !important;
  box-shadow:
    0 1px 0 rgba(255,255,255,0.06) inset,
    0 22px 56px rgba(0,0,0,0.42),
    0 0 0 1px var(--rx-accent-soft),
    0 0 60px var(--rx-accent-soft) !important;
}

/* ---- FEATURE / CARD ICONS: glow them up -------------------------------- */
.feature-icon,
.card-icon,
.fact-icon,
.wc-icon,
.crate-icon,
.ico {
  border-radius: 12px !important;
  background: linear-gradient(135deg, var(--rx-accent-soft), transparent 60%) !important;
  border: 1px solid var(--rx-accent-soft) !important;
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.08),
    0 8px 22px var(--rx-accent-soft) !important;
  color: var(--rx-accent) !important;
}

/* ---- NUMERIC / STAT DISPLAYS: heavy display font ----------------------- */
.stat-value,
.metric-value,
.fact-value,
.wc-amount,
.feature-value,
.map-stat-value,
.status-value,
.crate-cost,
.amount,
.coins,
.rubies,
.balance-bar b,
.balance-bar span,
.val,
.mod-stat-pill b,
.rank,
.nm {
  font-family: 'Bebas Neue', 'Rajdhani', sans-serif !important;
  font-variant-numeric: tabular-nums !important;
  letter-spacing: 0.04em !important;
  font-weight: 400 !important;
}

.stat-label,
.metric .label,
.fact-label,
.wc-name,
.feature-description,
.map-stat-label,
.status-label,
.crate-name,
.lbl,
.card-desc {
  font-family: 'JetBrains Mono', 'Inter', monospace !important;
  font-size: 10.5px !important;
  font-weight: 600 !important;
  letter-spacing: 0.22em !important;
  text-transform: uppercase !important;
  opacity: 0.6;
}

/* ---- BUTTONS: real gradient primaries, glass secondaries --------------- */
.btn,
button:not(.game-switcher-btn):not(.tab-btn):not(.tb):not(.region-tab):not(.mod-tab):not(.nl):not(.nav-link):not(.site-nav-link):not(.bq):not(.crate-btn):not(.hub-tab):not(.friend-subtab):not(.mutation-slot):not(.dino-picker):not(.color-square) {
  background: linear-gradient(135deg,
    var(--rx-accent),
    color-mix(in srgb, var(--rx-accent) 60%, #000)) !important;
  border: 1px solid var(--rx-accent) !important;
  color: #fff !important;
  font-family: 'Bebas Neue', 'Rajdhani', sans-serif !important;
  letter-spacing: 0.1em !important;
  text-transform: uppercase !important;
  font-weight: 400 !important;
  font-size: 15px !important;
  padding: 12px 22px !important;
  box-shadow:
    0 10px 28px var(--rx-accent-glow),
    inset 0 1px 0 rgba(255,255,255,0.18),
    inset 0 -1px 0 rgba(0,0,0,0.18) !important;
  text-shadow: 0 1px 0 rgba(0,0,0,0.3) !important;
}

.btn.secondary,
.secondary,
button.secondary,
.btn-secondary {
  background: rgba(255,255,255,0.04) !important;
  border: 1px solid rgba(255,255,255,0.12) !important;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.04) !important;
  color: rgba(255,255,255,0.92) !important;
  text-shadow: none !important;
}
.btn.secondary:hover,
.secondary:hover {
  background: rgba(255,255,255,0.08) !important;
  border-color: var(--rx-accent-soft) !important;
  color: #fff !important;
}

.btn.danger,
.danger,
.btn-danger {
  background: linear-gradient(135deg, #ef4444, #991b1b) !important;
  border-color: #ef4444 !important;
  box-shadow: 0 10px 28px rgba(239,68,68,0.32) !important;
}

.btn.btn-warning,
.btn-warning {
  background: linear-gradient(135deg, #f59e0b, #b45309) !important;
  border-color: #f59e0b !important;
  box-shadow: 0 10px 28px rgba(245,158,11,0.32) !important;
}

/* ---- BET QUICK chips + crate buttons ----------------------------------- */
.bq,
.bet-quick {
  background: rgba(255,255,255,0.04) !important;
  border: 1px solid rgba(255,255,255,0.1) !important;
  color: rgba(255,255,255,0.85) !important;
  font-family: 'Bebas Neue', sans-serif !important;
  letter-spacing: 0.06em !important;
  transition: all 180ms ease !important;
}
.bq:hover,
.bet-quick:hover {
  background: var(--rx-accent-soft) !important;
  border-color: var(--rx-accent) !important;
  color: #fff !important;
  transform: translateY(-1px);
}
.bq.active,
.bet-quick.active {
  background: var(--rx-accent) !important;
  border-color: var(--rx-accent) !important;
  color: #fff !important;
  box-shadow: 0 8px 20px var(--rx-accent-glow) !important;
}

/* ---- PILLS, TAGS, ROLE-BADGES ----------------------------------------- */
.pill,
.tag,
.role-badge,
.mod-stat-pill {
  display: inline-flex !important;
  align-items: center !important;
  padding: 5px 11px !important;
  border-radius: 999px !important;
  background: rgba(255,255,255,0.04) !important;
  border: 1px solid rgba(255,255,255,0.1) !important;
  color: rgba(255,255,255,0.88) !important;
  font-family: 'JetBrains Mono', monospace !important;
  font-size: 10.5px !important;
  font-weight: 700 !important;
  letter-spacing: 0.12em !important;
  text-transform: uppercase !important;
  white-space: nowrap !important;
}

/* admin pill */
.admin-link,
.role-badge.admin {
  background: linear-gradient(135deg, var(--rx-accent-soft), rgba(0,0,0,0.4)) !important;
  border-color: var(--rx-accent) !important;
  color: var(--rx-accent) !important;
}

/* ok / online states */
.ok,
.online,
.gold {
  color: #22c55e !important;
}
.dot.online,
.status-online {
  color: #22c55e !important;
}

.bad,
.offline,
.status-offline {
  color: #ef4444 !important;
}

/* ---- TABLES (leaderboards, command lists) ----------------------------- */
.leaderboard table,
.commands-table,
.table {
  border-spacing: 0 !important;
  width: 100% !important;
}
.leaderboard thead th,
.commands-table thead th {
  background: linear-gradient(180deg, rgba(255,255,255,0.05), transparent) !important;
  font-family: 'JetBrains Mono', monospace !important;
  font-size: 10.5px !important;
  font-weight: 700 !important;
  letter-spacing: 0.22em !important;
  text-transform: uppercase !important;
  color: rgba(255,255,255,0.55) !important;
  padding: 14px 16px !important;
  border-bottom: 1px solid rgba(255,255,255,0.08) !important;
}
.leaderboard tbody tr,
.commands-table tbody tr {
  transition: background 160ms ease !important;
}
.leaderboard tbody tr:nth-child(even),
.commands-table tbody tr:nth-child(even) {
  background: rgba(255,255,255,0.018) !important;
}
.leaderboard tbody tr:hover,
.commands-table tbody tr:hover {
  background: var(--rx-accent-soft) !important;
}
.leaderboard tbody td,
.commands-table tbody td {
  padding: 12px 16px !important;
  border-bottom: 1px solid rgba(255,255,255,0.04) !important;
}

/* rank cell */
.rank,
.leaderboard td:first-child {
  font-family: 'Bebas Neue', sans-serif !important;
  font-size: 20px !important;
  color: var(--rx-accent) !important;
}

/* ---- FORM INPUTS: properly dark-glass --------------------------------- */
input:not([type="checkbox"]):not([type="radio"]):not([type="submit"]):not([type="button"]),
select,
textarea,
.bet-input {
  background: rgba(0,0,0,0.32) !important;
  border: 1px solid rgba(255,255,255,0.08) !important;
  color: #fff !important;
  border-radius: 8px !important;
  padding: 12px 14px !important;
  font-family: 'Inter', sans-serif !important;
  font-size: 14px !important;
  transition: border-color 180ms ease, box-shadow 180ms ease, background 180ms ease !important;
}
input::placeholder,
textarea::placeholder { color: rgba(255,255,255,0.32) !important; }

/* ---- FOOTER: subtle but polished -------------------------------------- */
.footer,
footer.footer {
  position: relative;
  margin-top: 60px !important;
  border-top: 1px solid rgba(255,255,255,0.06) !important;
  background: linear-gradient(180deg, transparent, rgba(0,0,0,0.34)) !important;
  padding: 36px 0 28px !important;
}
.footer::before,
footer.footer::before {
  content: '';
  position: absolute;
  top: -1px; left: 0; right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--rx-accent), transparent);
  opacity: 0.4;
}
.footer-logo {
  font-family: 'Bebas Neue', sans-serif !important;
  letter-spacing: 0.18em !important;
}
.footer-link {
  color: rgba(255,255,255,0.55) !important;
  font-family: 'JetBrains Mono', monospace !important;
  font-size: 11px !important;
  letter-spacing: 0.15em !important;
  text-transform: uppercase !important;
  transition: color 180ms ease;
}
.footer-link:hover { color: var(--rx-accent) !important; }
.footer-copyright {
  font-family: 'JetBrains Mono', monospace !important;
  font-size: 10.5px !important;
  letter-spacing: 0.18em !important;
  color: rgba(255,255,255,0.32) !important;
  text-transform: uppercase !important;
}

/* ---- TOAST: glassy, centered ------------------------------------------ */
.toast {
  background: rgba(18, 10, 15, 0.86) !important;
  backdrop-filter: blur(18px) saturate(1.2) !important;
  -webkit-backdrop-filter: blur(18px) saturate(1.2) !important;
  border: 1px solid var(--rx-accent-soft) !important;
  box-shadow:
    0 22px 50px rgba(0,0,0,0.5),
    0 0 40px var(--rx-accent-soft) !important;
}

/* ---- EMPTY STATES: dashed border with icon glow ----------------------- */
.empty,
.empty-state,
.mod-empty,
.no-server-message {
  border-style: dashed !important;
  border-color: rgba(255,255,255,0.12) !important;
  background: rgba(255,255,255,0.02) !important;
  text-align: center !important;
  color: rgba(255,255,255,0.55) !important;
  padding: 36px 24px !important;
}

/* ---- HUB / FRIEND TABS: refined ---------------------------------------- */
.hub-tab,
.friend-subtab {
  background: rgba(255,255,255,0.03) !important;
  border: 1px solid rgba(255,255,255,0.08) !important;
  color: rgba(255,255,255,0.7) !important;
  font-family: 'Bebas Neue', sans-serif !important;
  letter-spacing: 0.1em !important;
  font-size: 13px !important;
  transition: all 180ms ease !important;
}
.hub-tab:hover,
.friend-subtab:hover {
  background: rgba(255,255,255,0.06) !important;
  color: #fff !important;
}
.hub-tab.active,
.friend-subtab.active {
  background: var(--rx-accent) !important;
  border-color: var(--rx-accent) !important;
  color: #fff !important;
  box-shadow: 0 8px 22px var(--rx-accent-glow) !important;
}

/* ---- CRATE BUTTONS: showpiece treatment -------------------------------- */
.crate-btn {
  position: relative;
  overflow: hidden;
}
.crate-btn::before {
  content: '';
  position: absolute;
  top: -50%; right: -20%;
  width: 80%; height: 200%;
  background: radial-gradient(ellipse, var(--rx-accent-soft), transparent 60%);
  pointer-events: none;
  transition: opacity 280ms ease;
  opacity: 0.45;
}
.crate-btn:hover::before { opacity: 0.85; }
.crate-icon {
  font-size: 36px !important;
  filter: drop-shadow(0 4px 12px var(--rx-accent-glow));
}

/* ---- WALLET CARDS: jewel-tone gradients ------------------------------- */
.wallet-card.coins {
  background:
    radial-gradient(ellipse 80% 60% at 50% 0%, rgba(255, 215, 0, 0.18), transparent 60%),
    linear-gradient(135deg, #2a1810, #0d0608) !important;
  border-color: rgba(255, 215, 0, 0.32) !important;
}
.wallet-card.coins .wc-icon,
.wallet-card.coins .wc-amount { color: #ffd700 !important; }

.wallet-card.rubies {
  background:
    radial-gradient(ellipse 80% 60% at 50% 0%, rgba(225, 29, 72, 0.18), transparent 60%),
    linear-gradient(135deg, #2a0a14, #0d0306) !important;
  border-color: rgba(225, 29, 72, 0.32) !important;
}
.wallet-card.rubies .wc-icon,
.wallet-card.rubies .wc-amount { color: #ff4d6d !important; }

html[data-game="isle"] .wallet-card.coins {
  background:
    radial-gradient(ellipse 80% 60% at 50% 0%, rgba(83, 236, 255, 0.18), transparent 60%),
    linear-gradient(135deg, #03242c, #050d12) !important;
  border-color: rgba(83, 236, 255, 0.32) !important;
}
html[data-game="isle"] .wallet-card.coins .wc-icon,
html[data-game="isle"] .wallet-card.coins .wc-amount { color: #53ecff !important; }

html[data-game="isle"] .wallet-card.rubies {
  background:
    radial-gradient(ellipse 80% 60% at 50% 0%, rgba(47, 109, 255, 0.18), transparent 60%),
    linear-gradient(135deg, #0a1232, #050817) !important;
  border-color: rgba(47, 109, 255, 0.32) !important;
}
html[data-game="isle"] .wallet-card.rubies .wc-icon,
html[data-game="isle"] .wallet-card.rubies .wc-amount { color: #6e8dff !important; }

/* ---- SUBTLE corner accents on big cards ------------------------------- */
.feature-card::after,
.game::after,
.admin-card::after,
.stat-card::after,
.crate-btn::after {
  content: '';
  position: absolute;
  top: 10px; right: 10px;
  width: 12px; height: 12px;
  border-top: 1px solid var(--rx-accent);
  border-right: 1px solid var(--rx-accent);
  opacity: 0.45;
  transition: all 280ms ease;
  pointer-events: none;
}
.feature-card:hover::after,
.game:hover::after,
.admin-card:hover::after,
.stat-card:hover::after,
.crate-btn:hover::after {
  opacity: 1;
  width: 18px; height: 18px;
  top: 8px; right: 8px;
}
.feature-card,
.game,
.admin-card,
.stat-card,
.crate-btn { position: relative; }

/* ---- TYPOGRAPHY tightening across body ------------------------------- */
body { letter-spacing: 0.005em; }

/* ---- LIVE / ONLINE dots: green pulse ---------------------------------- */
.dot.online,
.status-dot.online,
.live::before {
  background-color: #22c55e !important;
  box-shadow: 0 0 8px #22c55e, 0 0 18px rgba(34,197,94,0.5) !important;
}

/* ---- MAP page card: special treatment for hero map -------------------- */
.map-card,
.map-image,
.map-canvas {
  border-radius: 14px !important;
  overflow: hidden !important;
}

/* ---- SECTION DIVIDERS / TITLES ---------------------------------------- */
.section-title {
  font-family: 'JetBrains Mono', monospace !important;
  font-size: 11px !important;
  font-weight: 700 !important;
  letter-spacing: 0.32em !important;
  color: rgba(255,255,255,0.5) !important;
}

/* ---- LOADING / SPINNER glow ------------------------------------------- */
.loading-spinner {
  border-top-color: var(--rx-accent) !important;
  box-shadow: 0 0 24px var(--rx-accent-glow);
}

/* ---- MUTATION SLOTS (Isle gene display) ------------------------------- */
.mutation-slot,
.dino-picker {
  background: rgba(255,255,255,0.025) !important;
  border: 1px solid rgba(255,255,255,0.08) !important;
}
.mutation-slot.active,
.dino-picker.active {
  background: var(--rx-accent-soft) !important;
  border-color: var(--rx-accent) !important;
  box-shadow: 0 8px 22px var(--rx-accent-glow) !important;
}

/* ---- Mobile tightening ------------------------------------------------- */
@media (max-width: 560px) {
  .page-title,
  .hero-title { font-size: clamp(34px, 8vw, 48px) !important; }
}
