@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;600&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Press+Start+2P&display=swap');
@font-face {
  font-family: "Quency_Pixel";
  src: url("fonts/Quency_Pixel.woff") format("woff");
}

::selection {
  background-color: #efefef;
  color: #000;
}

:root {
  --electric-color: #3055bb;
  --western-color: #bb3030;
  --electric-light-color: oklch(from var(--electric-color) l c h);
  --gradient-color: oklch(
    from var(--electric-color) 0.3 calc(c / 2) h / 0.4
  );
  --color-neutral-900: oklch(0.185 0 0);
  --square-light: #292929;
  --square-dark: #171616;
  --highlight-select: #3055bbb4;
  --highlight-check: #bb3030b4;
  --highlight-move: #3055bb36;
  --highlight-dot: #ffffff83;
  --highlight-drag: #ffffff;
  --board-size: 572px;
  --square-size: calc(var(--board-size) / 8);
  --ping-color: #74ff79;
  --background-ping-color: #74ff7948;
}

#loadingscreen {
position: fixed;
top: 0;
left: 0;
width: 100%;
height: 100%;
background: rgba(0, 0, 0, 0.897);
display: flex;
justify-content: center;
align-items: center;
z-index: 100;
animation: fadeIn 0.5s forwards;
}

#loadingscreen.hidden {
display: none;
animation: fadeIn 0.5s forwards;
}

#loader {
  animation: pixel-spin 1s linear infinite;
  height: 10px;
  width: 10px;
  position: absolute;
  top: 50%;
  left: 50%;
  margin: -5px;
  z-index: 101;
}

header {
  position: relative;
  height: 22px;
  display: flex;
  align-items: center;
}

body {
  font-family: system-ui, -apple-system, sans-serif;
  background-color: oklch(0.145 0 0);
  color: #3055bb;
  height: 100vh;
  overflow: hidden;
  background: linear-gradient(
      -30deg,
      var(--gradient-color),
      transparent,
      var(--gradient-color)
    ),
    linear-gradient(
      to bottom,
      var(--color-neutral-900),
      var(--color-neutral-900)
    );
}

a {
  color: inherit;
  text-decoration: none;
}

#chess_icon {
  position: absolute;
  height: 52px;
  width: 52px;
  top: 24px;
  left: 30px;
}

#popup {
  padding: 10px;
  position: absolute;
  bottom: 20px;
  right: 20px;
  background-color: #18181885;
  border: solid;
  border-color: #3055bb;
  border-width: 1px;
  border-radius: 12px;
  text-align: center;
  z-index: 100;
}

#popupmsg {
  white-space: nowrap;
}

/* background */

.background_overlay {
  position: absolute;
  width: 100%;
  height: 100%;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  border-radius: 24px;
  opacity: 0.8;
  mix-blend-mode: overlay;
  transform: scale(1.1);
  filter: blur(4px);
  background: linear-gradient(
    -30deg,
    white,
    transparent 30%,
    transparent 70%,
    white
  );
}

body {
  font: 400 1em/1.5 "Neuton";
  text-align: center;
}

.hidden {
  display: none;
}

/* /background */

#welcometxt {
  color: #efefef;
  position: relative;
  font: 800 2rem "Agbalumo", system-ui;
  top: 26px;
  left: 90px;
}

#usernameDisplay {
  position: relative;
  top: 26px;
  left: 20px;
  color: #3055bb;
  text-align: left;
  margin: 0 0 0 80px;
  font-size: 2rem;
  font-family: "Agbalumo", system-ui;
  z-index: 2;
}

#usernameDisplay::after {
  content: "!";
}
/* Title */

#title {
  font: 900 6rem "Quency_Pixel", system-ui;
  letter-spacing: 0;
  display: block;
  text-shadow: 0 0 40px rgba(179, 212, 255, 0.356);
  padding-top: 40px;
  z-index: 10;

  /* Clip Background Image */
  background: url(img/animated-text-galaxy160.png) repeat-x;
  -webkit-background-clip: text;
  background-clip: text;

  /* Animate Background Image */
  -webkit-text-fill-color: transparent;
  -webkit-animation: aitf 300s linear infinite;

  /* Activate hardware acceleration for smoother animations */
  -webkit-transform: translate3d(0, 0, 0);
  -webkit-backface-visibility: hidden;
}

/* Animate Background Image */
@-webkit-keyframes aitf {
  0% {
    background-position: 0% 50%;
  }
  100% {
    background-position: 100% 50%;
  }
}

#subtitle {
  color: #efefef;
  font: 700 1.8rem "Quency_Pixel", system-ui;
  margin: 10px 0 70px 0;
  letter-spacing: 0;
  display: block;
  position: relative;
  z-index: 10;
}

#dotfun {
  color: #efefef;
  font: 700 1.4rem "Quency_Pixel", system-ui;
  margin: -50px 0 0 440px;
  letter-spacing: 0;
  display: block;
  position: relative;
  z-index: 10;
}

/* /Title */

/* Grid */

.grid {
  margin: 0 0 0 0;
  position: relative;
  display: grid;
  grid-template-columns: 360px 574px 360px;
  grid-template-rows: repeat(2, 270px) 576px;
  gap: 2rem;
  justify-content: center;
}

.item {
  position: relative;
  display: flex;
  background-color: #18181885;
  border: solid;
  border-width: 1px;
  border-radius: 12px;
  border-color: #3055bb6e;
  align-items: center;
  justify-content: center;
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.5);
}

.item:nth-child(1) {
  display: grid;
  grid-template-rows: 1fr 1fr;
  grid-row: 1 / 3;
}

#leaderboard-container {
  grid-column: 1;
  grid-row: 1;
}

#wallet-container {
  grid-column: 1;
  grid-row: 2;
}

#stat-container {
  grid-column: 2;
  grid-row: 1 / 3;
}

#referrals-container {
  grid-column: 3;
  grid-row: 1;
}

#rewards-container {
  grid-column: 3;
  grid-row: 2;
  border: 1px, solid, #d4af3748;
}

/* /Grid */

#signinbutton {
  position: absolute;
  color: #3055bb;
  background: #181818;
  border: solid, #3055bb48;
  height: 50px;
  width: 100px;
  border-width: 1px;
  border-radius: 16px;
  top: 32px;
  right: 95px;
  font-weight: 600;
  font-family: 'Inter', sans-serif;
  transition: all 0.3s ease;
  transform-origin: center;
  z-index: 2;
}

#signinbutton:hover {
  transform: scale(1.05);
  cursor: pointer;
  color: #efefef;
}

#logoutbutton {
  position: absolute;
  color: #3055bb;
  background: #181818;
  border: solid, #3055bb48;
  height: 50px;
  width: 100px;
  border-width: 1px;
  border-radius: 16px;
  top: 32px;
  right: 95px;
  font-weight: 600;
  font-family: 'Inter', sans-serif;
  transition: all 0.3s ease;
  transform-origin: center;
  z-index: 1;
}

#logoutbutton:hover {
  transform: scale(1.05);
  cursor: pointer;
  color: #efefef;
}

#networkinfo {
  font-size: 1em;
  font-family: 'Inter', sans-serif;
  right: 210px;
  color: #efefef;
  position: absolute;
  top: 48px;
}

/* game menu */

.menu-container {
    position: absolute;
    top: 32px;
    right: 20px;
    z-index: 11;
}

.menu-btn {
    background-color: #181818;
    border: 1px solid #3055bb48;
    height: 50px;
    width: 60px;
    border-radius: 16px;
    color: #efefef;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.menu-btn:hover {
  transform: scale(1.05);
  cursor: pointer;
  color: #efefef;
}

.icon-wrapper {
    position: relative;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.icon-wrapper i {
    position: absolute;
    font-size: 20px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Animation de transformation de l'icône (Menu <-> Croix) */
.fa-xmark {
    opacity: 0;
    transform: rotate(-90deg) scale(0.5);
}

.menu-container.open .fa-bars {
    opacity: 0;
    transform: rotate(90deg) scale(0.5);
}

.menu-container.open .fa-xmark {
    opacity: 1;
    transform: rotate(0) scale(1);
}

.dropdown-menu {
    position: absolute;
    top: 100%;
    right: 0;
    margin-top: 12px;
    background-color: #181818;
    min-width: 200px;
    border-radius: 16px;
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.5), 0 8px 10px -6px rgba(0, 0, 0, 0.5);
    border: 1px solid #3055bb48;
    overflow: hidden;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    z-index: 50;
}

/* État ouvert du pop-up */
.menu-container.open .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

/* Style de la liste à l'intérieur du pop-up */
.dropdown-list {
    list-style: none;
    padding: 8px;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

/* Style des boutons dans la liste */
.dropdown-item {
    width: 100%;
    text-align: left;
    background: transparent;
    border: none;
    padding: 10px 14px;
    font-size: 14px;
    font-weight: 500;
    color: #d1d5db;
    cursor: pointer;
    border-radius: 10px;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 12px;
}

.dropdown-item i {
    font-size: 16px;
    color: #9ca3af;
    transition: color 0.2s ease;
    width: 20px;
    text-align: center;
}

.dropdown-item:hover {
    background-color: #efefef1c;
    color: #ffffff;
}

.dropdown-item:hover i {
    color: #ffffff;
}

/* Sign In menu */

#overlayclick {
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
background: rgba(0, 0, 0, 0.466);
display: flex;
justify-content: center;
align-items: center;
z-index: 29;
}

.overlay {
position: fixed;
top: 0;
left: 0;
width: 100%;
height: 100%;
display: flex;
background: rgba(0, 0, 0, 0.705);
justify-content: center;
align-items: center;
z-index: 30;
animation: fadeIn 0.5s forwards;
}

.overlay.hidden {
display: none;
animation: fadeIn 0.8s forwards;
}

#signinmenu {
background: #181818;
border-radius: 12px;
padding: 2rem;
width: 300px;
height: 260px;
box-shadow: 0 0 10px #3055bb;
animation: fadeIn 0.5s forwards;
z-index: 70;
}

#signintxt {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
}

#signintitle {
  color: #efefef;
  position: relative;
  text-align: center;
  font: 800 2rem "Agbalumo", system-ui;
}

#signinbio {
  color: #efefef;
  position: relative;
  top: 20px;
  font: 800 1rem "Inter", system-ui;
}

#bar {
  position: relative;
  top: 50px;
  background-color: #ffffff86;
  height: 1px;
  width: 300px;
  border-radius: 8px;
}

#googlebutton {
  color: #efefef;
  background: #181818;
  border: solid, #3055bb48;
  margin: 75px 0 0 0;
  height: 40px;
  width: 80%;
  border-width: 1px;
  border-radius: 16px;
  font-weight: 600;
  position: relative;
  font-family: 'Inter', sans-serif;
  transition: all 0.3s ease;
  transform-origin: center;
  padding: 0 0 2px 20px;
}

#googlebutton:hover {
  transform: scale(1.05);
  cursor: pointer;
  color: #efefef;
}

#googlelogo {
  position: absolute;
  top: 6px;
  left: 24px;
  height: 24px;
  width: 24px;
  margin: 0 10px 0 0;
}

#googlebutton {
  color: #efefef;
  background: #181818;
  border: solid, #3055bb48;
  margin: 80px 0 0 0;
  height: 40px;
  width: 80%;
  border-width: 1px;
  border-radius: 16px;
  font-weight: 600;
  position: relative;
  font-family: 'Inter', sans-serif;
  transition: all 0.3s ease;
  transform-origin: center;
  padding: 0 0 2px 20px;
}

#googlebutton:hover {
  transform: scale(1.05);
  cursor: pointer;
  color: #efefef;
}

#googlelogo {
  position: absolute;
  top: 9px;
  left: 32px;
  height: 20px;
  width: 20px;
  margin: 0 10px 0 0;
}

#termsUrl {
  color: #3055bb;
}

/* endgame menu */

.endgameoverlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 100;
  animation: fadeIn 0.5s forwards;
}

.endgameoverlay.hidden {
display: none;
animation: fadeIn 0.8s forwards;
}

#endgamemenu {
  background: #181818e0;
  border-radius: 12px;
  padding: 2rem;
  width: 300px;
  height: 260px;
  box-shadow: 0 0 3px #3055bb;
  animation: fadeIn 0.5s forwards;
}

#endgametxt {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
}

#winnertxt {
  position: relative;
  top: 0;
  right: 60px;
}

#losertxt {
  position: relative;
  top: 0;
  right: 100px;
}

#drawtxt {
  position: relative;
  top: 0;
  right: 100px;
}

#laughingemoji {
  position: absolute;
  top: 8px;
  left: 135px;
  height: 40px;
  width: 40px;
}

#pointingemoji {
  position: absolute;
  top: 8px;
  left: 175px;
  height: 40px;
  width: 40px;
}

#winnertitle {
  color: #efefef;
  position: absolute;
  font: 800 2rem "Agbalumo", system-ui;
  white-space: nowrap;
}

#losertitle {
  color: #efefef;
  position: absolute;
  font: 800 2rem "Agbalumo", system-ui;
  white-space: nowrap;
}

#drawtitle {
  color: #efefef;
  position: absolute;
  left: 50px;
  font: 800 2.2rem "Agbalumo", system-ui;
  white-space: nowrap;
}

#restartbutton {
  color: #efefef;
  background: #181818;
  border: solid, #3055bb48;
  margin: 160px 0 0 0;
  height: 40px;
  width: 80%;
  border-width: 1px;
  border-radius: 16px;
  font-weight: 600;
  position: relative;
  font-family: 'Inter', sans-serif;
  transition: all 0.3s ease;
  transform-origin: center;
  padding: 0 0 2px 10px;
}

#restartbutton:hover {
  transform: scale(1.05);
  cursor: pointer;
  color: #efefef;
}

#lobbybutton {
  color: #efefef;
  background: #181818;
  border: solid, #3055bb48;
  margin: 20px 0 0 0;
  height: 40px;
  width: 80%;
  border-width: 1px;
  border-radius: 16px;
  font-weight: 600;
  position: relative;
  font-family: 'Inter', sans-serif;
  transition: all 0.3s ease;
  transform-origin: center;
  padding: 0 0 2px 10px;
}

#lobbybutton:hover {
  transform: scale(1.05);
  cursor: pointer;
  color: #efefef;
}

/* Wallet Overlay */

.dwoverlay {
position: fixed;
top: 0;
left: 0;
width: 100%;
height: 100%;
display: flex;
justify-content: center;
align-items: center;
z-index: 70;
animation: fadeIn 0.5s forwards;
}

.dwoverlay.hidden {
display: none;
animation: fadeIn 0.8s forwards;
}

#dwmenu {
background: #181818e0;
border-radius: 12px;
padding: 2rem;
width: 300px;
height: 280px;
box-shadow: 0 0 3px #3055bb;
animation: fadeIn 0.5s forwards;
z-index: 100;
}

#overlayclick2 {
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
background: rgba(0, 0, 0, 0.466);
display: flex;
justify-content: center;
align-items: center;
z-index: 80;
}

#withdrawDisplay {
  position: relative;
  top: 20px;
  margin: 0 0 0px 0;
  font-size: 3rem;
  font-family: "Agbalumo", system-ui;
  color: #3055bb;
}

#adressinput {
  color: #3055bb;
  background: #181818;
  border: solid, #3055bb48;
  top: 100px;
  margin: 0 10px 0 0;
  padding: 0 0 0 10px;
  height: 40px;
  width: 242px;
  border-width: 1px;
  border-radius: 16px;
  font-weight: 600;
  position: relative;
  font-family: 'Inter', sans-serif;
  transition: all 0.3s ease;
}

#range-slider {
  position: relative;
  top: 60px;
}

input[type="range"] {
  -webkit-appearance: none;
  appearance: none;
  width: 300px;
  height: 12px;
  background: #ddd;
  border-radius: 999px;
  border: solid, #2563eb;
  border-width: 1px;
  outline: none;
}

input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 24px;
  height: 24px;
  background: #2563eb;
  border-radius: 50%;
  cursor: pointer;
}

#sendbutton {
  color: #3055bb;
  background: #181818;
  border: solid, #3055bb48;
  top: 100px;
  height: 45px;
  width: 45px;
  border-width: 1px;
  border-radius: 16px;
  font-weight: 600;
  position: relative;
  font-family: 'Inter', sans-serif;
  transition: all 0.3s ease;
  transform-origin: center;
  z-index: 1;
}

#sendbutton:hover {
  transform: scale(1.05);
  cursor: pointer;
  color: #efefef;
}

.send-container {
  display: flex;
  align-items: center;
}

#dwtitle {
  color: #efefef;
  font-size: 150%;
  font-weight: 800;
  margin: 0 0 20px 0;
  position: relative;
  top: 0;
}

#qrcode {
  position: relative;
  top: 20px;
}

#adressDisplay {
  display: inline-block;
  color: #3055bb;
  background: #181818;
  border: solid, #3055bb48;
  height: 25px;
  width: 190px;
  margin: 0 10px 0 0;
  padding: 10px 10px 10px 10px;
  border-width: 1px;
  border-radius: 16px;
  font-weight: 600;
  position: relative;
  top: 40px;
  font-family: 'Inter', sans-serif;
  transition: all 0.3s ease;
}

#dwcopybutton {
  color: #3055bb;
  background: #181818;
  border: solid, #3055bb48;
  top: 40px;
  height: 45px;
  width: 45px;
  border-width: 1px;
  border-radius: 16px;
  font-weight: 600;
  position: relative;
  font-family: 'Inter', sans-serif;
  transition: all 0.3s ease;
  transform-origin: center;
  z-index: 1;
}

#dwcopybutton:hover {
  transform: scale(1.05);
  cursor: pointer;
  color: #efefef;
}

/* Leaderboard */

#leaderboardicon {
  color: #efefef;
  position: absolute;
  top: 33px;
  left: 20px;
}

#leaderboardtitle {
  color: #efefef;
  position: absolute;
  top: 0;
  left: 60px;
  font-size: 1.5rem;
  font-weight: 700;
  margin: 18px 0 0 0;
  font-family: 'Quency_Pixel', sans-serif;
}

@keyframes pulse {
  0% {
    transform: scale(1);
    opacity: 1;
}
  50% {
    transform: scale(2.4);
    opacity: 0;
  }
  100% {
    transform: scale(2.4);
    opacity: 0;
  }
}

#leaderboard {
  position: absolute;
  top: 80px;
  left: 26px;
}

.row {
  display: flex;
  justify-content: space-between;
  padding: 1px 0;
}

.place {
  color: #c0c0c0;
  width: 30px;
}

.playertag1 {
  color: #c0c0c0;
  flex: 1;
  text-align: left;
}

.playerwealth1 {
  min-width: 100px;
  margin: 0 0 0 200px;
  text-align: right;
  position: fixed;
  color: #3055bb;
  font-family: monospace, sans-serif;
}

.playertag2 {
  color: #c0c0c0;
  flex: 1;
  text-align: left;
}

.playerwealth1::after {
  content: " SOL";
}

.playerwealth2 {
  min-width: 100px;
  margin: 0 0 0 200px;
  text-align: right;
  position: fixed;
  color: #3055bb;
  font-family: monospace, sans-serif;
}

.playerwealth2::after {
  content: " SOL";
}

.playertag3 {
  color: #c0c0c0;
  flex: 1;
  text-align: left;
}

.playerwealth3 {
  min-width: 100px;
  margin: 0 0 0 200px;
  text-align: right;
  position: fixed;
  color: #3055bb;
  font-family: monospace, sans-serif;
}

.playerwealth3::after {
  content: " SOL";
}

#seemore {
  position: absolute;
  color: #3055bb;
  background: #181818;
  border: solid, #3055bb48;
  bottom: 22px;
  left: 22px;
  height: 50px;
  width: 314px;
  border-width: 1px;
  border-radius: 16px;
  position: center;
  font-weight: 600;
  font-family: 'Inter', sans-serif;
  transition: all 0.3s ease;
  transform-origin: center;
}

#seemore:hover {
  transform: scale(1.05);
  cursor: pointer;
  color: #efefef;
}

/* /Leaderboard */

/* Wallet */

#walleticon {
  color: #efefef;
  position: absolute;
  left: 20px;
  top: 33px;
}

#wallettitle {
  color: #efefef;
  position: absolute;
  font-size: 1.5rem;
  font-weight: 700;
  top: 17px;
  left: 60px;
  font-family: 'Quency_Pixel', sans-serif;
}

#soldfiatDisplay {
  position: absolute;
  top: 60px;
  margin: 0 0 100px 0;
  font-size: 3rem;
  font-family: "Agbalumo", system-ui;
  color: #3055bb;
}

#soldDisplay {
  position: absolute;
  top: 130px;
  font-size: 1rem;
  font-family: "Agbalumo", system-ui;
  color: #c0c0c0;
}

#depositbutton {
  color: #3055bb;
  background: #181818;
  border: solid, #3055bb48;
  margin: 180px 8px 0 auto;
  height: 50px;
  width: 40%;
  border-width: 1px;
  border-radius: 16px;
  font-weight: 600;
  position: relative;
  font-family: 'Inter', sans-serif;
  transition: all 0.3s ease;
  transform-origin: center;
}

#depositbutton:hover {
  transform: scale(1.05);
  cursor: pointer;
  color: #efefef;
}

#withdrawbutton {
  color: #3055bb;
  background: #181818;
  border: solid, #3055bb48;
  margin: 180px auto 0 8px;
  height: 50px;
  width: 40%;
  border-width: 1px;
  border-radius: 16px;
  font-weight: 600;
  position: relative;
  font-family: 'Inter', sans-serif;
  transition: all 0.3s ease;
  transform-origin: center;
}

#withdrawbutton:hover {
  transform: scale(1.05);
  cursor: pointer;
  color: #efefef;
}

#refreshbutton {
  color: #3055bb;
  background-color: transparent;
  border: none;
  position: absolute;
  right: 20px;
  top: 20px;
  padding: 6px 6px;
  border-radius: 6px;
  transition: all 0.3s ease;
}

#refreshbutton:hover {
  background-color: #efefef1c;
  cursor: pointer;
}

#copybutton {
  color: #3055bb;
  background-color: transparent;
  border: none;
  position: absolute;
  right: 55px;
  top: 20px;
  padding: 6px 6px;
  border-radius: 6px;
  transition: all 0.3s ease;
}

#copybutton:hover {
  background-color: #efefef1c;
  cursor: pointer;
}

/* /Wallet */

/* stat */

#statcs {
  color: #efefef;
  position: absolute;
  font-size: 1.5rem;
  font-weight: 700;
  position: center;
  white-space: nowrap;
  font-family: "Agbalumo", system-ui;
}

/* referrals */

#referralsicon {
  color: #efefef;
  position: absolute;
  left: 20px;
  top: 33px;
}

#referralstitle {
  color: #efefef;
  position: absolute;
  font-size: 1.5rem;
  font-weight: 700;
  top: 17px;
  left: 60px;
  font-family: 'Quency_Pixel', sans-serif;
}

#referralscs {
  color: #efefef;
  position: absolute;
  font-size: 1.5rem;
  font-weight: 700;
  position: center;
  white-space: nowrap;
  font-family: "Agbalumo", system-ui;
}

/* /referrals */

/* rewards */ 

#rewardsicon {
  color: #efefef;
  position: absolute;
  left: 20px;
  top: 33px;
}

#rewardstitle {
  color: #efefef;
  position: absolute;
  font-size: 1.5rem;
  font-weight: 700;
  top: 17px;
  left: 60px;
  font-family: 'Quency_Pixel', sans-serif;
}

.xp-counter {
    color: #d4af37;
    position: absolute;
    top: 90px;
    margin: 0 0 100px 0;
    font-size: 2rem;
    text-shadow: 0 0 10px rgba(212, 175, 55, 0.4);
    font-family: 'Press Start 2P', cursive;
}

#xpRateDisplay {
  position: absolute;
  top: 140px;
  font-size: 0.5rem;
  font-family: 'Press Start 2P', cursive;
  color: #c0c0c0;
}

#xpRateDisplay::after {
  content: " SOL";
}

#claimButton {
  position: absolute;
  color: #d4af37;
  background: #181818;
  border: solid, #d4af3748;
  bottom: 22px;
  left: 22px;
  height: 50px;
  width: 314px;
  border-width: 1px;
  border-radius: 16px;
  position: center;
  font-weight: 600;
  font-family: 'Press Start 2P', cursive;
  transition: all 0.3s ease;
  transform-origin: center;
}

#claimButton:hover {
  transform: scale(1.05);
  cursor: pointer;
  color: #efefef;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to   { opacity: 1; }
  }

@keyframes pixel-spin {
  0% {
    box-shadow: 
      0px -30px #3055bb, 
      10px -30px #3055bb, 
      20px -20px #3055bb, 
      30px -10px #3055bb, 
      30px 0px #3055bb, 
      30px 10px #3055bb, 
      20px 20px #3055bb, 
      10px 30px #3055bb, 
      0px 30px transparent, 
      -10px 30px transparent, 
      -20px 20px transparent, 
      -30px 10px transparent, 
      -30px 0px transparent, 
      -30px -10px transparent, 
      -20px -20px transparent,
      -10px -30px transparent;
  }
  6.25% {
    box-shadow: 
      0px -30px transparent, 
      10px -30px #3055bb, 
      20px -20px #3055bb, 
      30px -10px #3055bb, 
      30px 0px #3055bb, 
      30px 10px #3055bb, 
      20px 20px #3055bb, 
      10px 30px #3055bb, 
      0px 30px #3055bb, 
      -10px 30px transparent, 
      -20px 20px transparent, 
      -30px 10px transparent, 
      -30px 0px transparent, 
      -30px -10px transparent, 
      -20px -20px transparent,
      -10px -30px transparent;
  }
  12.5% {
    box-shadow: 
      0px -30px transparent, 
      10px -30px transparent, 
      20px -20px #3055bb, 
      30px -10px #3055bb, 
      30px 0px #3055bb, 
      30px 10px #3055bb, 
      20px 20px #3055bb, 
      10px 30px #3055bb, 
      0px 30px #3055bb, 
      -10px 30px #3055bb, 
      -20px 20px transparent, 
      -30px 10px transparent, 
      -30px 0px transparent, 
      -30px -10px transparent, 
      -20px -20px transparent,
      -10px -30px transparent;
  }
  18.75% {
    box-shadow: 
      0px -30px transparent, 
      10px -30px transparent, 
      20px -20px transparent, 
      30px -10px #3055bb, 
      30px 0px #3055bb, 
      30px 10px #3055bb, 
      20px 20px #3055bb, 
      10px 30px #3055bb, 
      0px 30px #3055bb, 
      -10px 30px #3055bb, 
      -20px 20px #3055bb, 
      -30px 10px transparent, 
      -30px 0px transparent, 
      -30px -10px transparent, 
      -20px -20px transparent,
      -10px -30px transparent;
  }
  25% {
    box-shadow: 
      0px -30px transparent, 
      10px -30px transparent, 
      20px -20px transparent, 
      30px -10px transparent, 
      30px 0px #3055bb, 
      30px 10px #3055bb, 
      20px 20px #3055bb, 
      10px 30px #3055bb, 
      0px 30px #3055bb, 
      -10px 30px #3055bb, 
      -20px 20px #3055bb, 
      -30px 10px #3055bb, 
      -30px 0px transparent, 
      -30px -10px transparent, 
      -20px -20px transparent,
      -10px -30px transparent;
  }
  31.25% {
    box-shadow: 
      0px -30px transparent, 
      10px -30px transparent, 
      20px -20px transparent, 
      30px -10px transparent, 
      30px 0px transparent, 
      30px 10px #3055bb, 
      20px 20px #3055bb, 
      10px 30px #3055bb, 
      0px 30px #3055bb, 
      -10px 30px #3055bb, 
      -20px 20px #3055bb, 
      -30px 10px #3055bb, 
      -30px 0px #3055bb, 
      -30px -10px transparent, 
      -20px -20px transparent,
      -10px -30px transparent;
  }
  37.5% {
    box-shadow: 
      0px -30px transparent, 
      10px -30px transparent, 
      20px -20px transparent, 
      30px -10px transparent, 
      30px 0px transparent, 
      30px 10px transparent, 
      20px 20px #3055bb, 
      10px 30px #3055bb, 
      0px 30px #3055bb, 
      -10px 30px #3055bb, 
      -20px 20px #3055bb, 
      -30px 10px #3055bb, 
      -30px 0px #3055bb, 
      -30px -10px #3055bb, 
      -20px -20px transparent,
      -10px -30px transparent;
  }
  43.75% {
    box-shadow: 
      0px -30px transparent, 
      10px -30px transparent, 
      20px -20px transparent, 
      30px -10px transparent, 
      30px 0px transparent, 
      30px 10px transparent, 
      20px 20px transparent, 
      10px 30px #3055bb, 
      0px 30px #3055bb, 
      -10px 30px #3055bb, 
      -20px 20px #3055bb, 
      -30px 10px #3055bb, 
      -30px 0px #3055bb, 
      -30px -10px #3055bb, 
      -20px -20px #3055bb,
      -10px -30px transparent;
  }
  50% {
    box-shadow: 
      0px -30px transparent, 
      10px -30px transparent, 
      20px -20px transparent, 
      30px -10px transparent, 
      30px 0px transparent, 
      30px 10px transparent, 
      20px 20px transparent, 
      10px 30px transparent, 
      0px 30px #3055bb, 
      -10px 30px #3055bb, 
      -20px 20px #3055bb, 
      -30px 10px #3055bb, 
      -30px 0px #3055bb, 
      -30px -10px #3055bb, 
      -20px -20px #3055bb,
      -10px -30px #3055bb;
  }
  56.25% {
    box-shadow: 
      0px -30px #3055bb, 
      10px -30px transparent, 
      20px -20px transparent, 
      30px -10px transparent, 
      30px 0px transparent, 
      30px 10px transparent, 
      20px 20px transparent, 
      10px 30px transparent, 
      0px 30px transparent, 
      -10px 30px #3055bb, 
      -20px 20px #3055bb, 
      -30px 10px #3055bb, 
      -30px 0px #3055bb, 
      -30px -10px #3055bb, 
      -20px -20px #3055bb,
      -10px -30px #3055bb;
  }
  62.5% {
    box-shadow: 
      0px -30px #3055bb, 
      10px -30px #3055bb, 
      20px -20px transparent, 
      30px -10px transparent, 
      30px 0px transparent, 
      30px 10px transparent, 
      20px 20px transparent, 
      10px 30px transparent, 
      0px 30px transparent, 
      -10px 30px transparent, 
      -20px 20px #3055bb, 
      -30px 10px #3055bb, 
      -30px 0px #3055bb, 
      -30px -10px #3055bb, 
      -20px -20px #3055bb,
      -10px -30px #3055bb;
  }
  68.75% {
    box-shadow: 
      0px -30px #3055bb, 
      10px -30px #3055bb, 
      20px -20px #3055bb, 
      30px -10px transparent, 
      30px 0px transparent, 
      30px 10px transparent, 
      20px 20px transparent, 
      10px 30px transparent, 
      0px 30px transparent, 
      -10px 30px transparent, 
      -20px 20px transparent, 
      -30px 10px #3055bb, 
      -30px 0px #3055bb, 
      -30px -10px #3055bb, 
      -20px -20px #3055bb,
      -10px -30px #3055bb;
  }
  75% {
    box-shadow: 
      0px -30px #3055bb, 
      10px -30px #3055bb, 
      20px -20px #3055bb, 
      30px -10px #3055bb, 
      30px 0px transparent, 
      30px 10px transparent, 
      20px 20px transparent, 
      10px 30px transparent, 
      0px 30px transparent, 
      -10px 30px transparent, 
      -20px 20px transparent, 
      -30px 10px transparent, 
      -30px 0px #3055bb, 
      -30px -10px #3055bb, 
      -20px -20px #3055bb,
      -10px -30px #3055bb;
  }
  81.25% {
    box-shadow: 
      0px -30px #3055bb, 
      10px -30px #3055bb, 
      20px -20px #3055bb, 
      30px -10px #3055bb, 
      30px 0px #3055bb, 
      30px 10px transparent, 
      20px 20px transparent, 
      10px 30px transparent, 
      0px 30px transparent, 
      -10px 30px transparent, 
      -20px 20px transparent, 
      -30px 10px transparent, 
      -30px 0px transparent, 
      -30px -10px #3055bb, 
      -20px -20px #3055bb,
      -10px -30px #3055bb;
  }
  87.5% {
    box-shadow: 
      0px -30px #3055bb, 
      10px -30px #3055bb, 
      20px -20px #3055bb, 
      30px -10px #3055bb, 
      30px 0px #3055bb, 
      30px 10px #3055bb, 
      20px 20px transparent, 
      10px 30px transparent, 
      0px 30px transparent, 
      -10px 30px transparent, 
      -20px 20px transparent, 
      -30px 10px transparent, 
      -30px 0px transparent, 
      -30px -10px transparent, 
      -20px -20px #3055bb,
      -10px -30px #3055bb;
  }
  93.75% {
    box-shadow: 
      0px -30px #3055bb, 
      10px -30px #3055bb, 
      20px -20px #3055bb, 
      30px -10px #3055bb, 
      30px 0px #3055bb, 
      30px 10px #3055bb, 
      20px 20px #3055bb, 
      10px 30px transparent, 
      0px 30px transparent, 
      -10px 30px transparent, 
      -20px 20px transparent, 
      -30px 10px transparent, 
      -30px 0px transparent, 
      -30px -10px transparent, 
      -20px -20px transparent,
      -10px -30px #3055bb;
  }
  100% {
    box-shadow: 
      0px -30px #3055bb, 
      10px -30px #3055bb, 
      20px -20px #3055bb, 
      30px -10px #3055bb, 
      30px 0px #3055bb, 
      30px 10px #3055bb, 
      20px 20px #3055bb, 
      10px 30px #3055bb, 
      0px 30px transparent, 
      -10px 30px transparent, 
      -20px 20px transparent, 
      -30px 10px transparent, 
      -30px 0px transparent, 
      -30px -10px transparent, 
      -20px -20px transparent,
      -10px -30px transparent;
  }
}

h1 {
  position: absolute;
  bottom: 50px;
  width: 100%;
  text-align: center;
  text-transform: uppercase;
  font-family: 'Lato';
}

#discordbutton {
  color: #3055bb;
  background-color: transparent;
  border: none;
  position: absolute;
  left: 30px;
  bottom: 30px;
  border-radius: 6px;
  transition: all 0.3s ease;
  transform-origin: center;
}

#discordbutton:hover {
  transform: scale(1.1);
  cursor: pointer;
}

#copyrightTxt {
  position: absolute;
  color: #efefef;
  font: 900 0.7em 'Inter', sans-serif;
  bottom: 12px;
  left: 50%;
  transform: translateX(-50%);
  pointer-events: none;
}

/* Progress Bar Style */

/* Conteneur principal de la barre positionné en bas à droite */
.progress-wrapper {
    position: absolute;
    bottom: 30px;
    right: 30px;
    width: 512px;
    z-index: 10;
}

/* Le fond de la barre de progression (partie vide) */
.progress-track {
    width: 100%;
    height: 6px; /* Barre beaucoup plus fine */
    background-color: #1f2229;
    border-radius: 6px;
    box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.8), 0 1px 1px rgba(255, 255, 255, 0.05);
    position: relative;
}

/* La partie remplie (or/jaune) */
.progress-fill {
    height: 100%;
    border-radius: 6px;
    /* Dégradé symétrique fluide pour éviter la barre verticale qui coupe */
    background: linear-gradient(90deg, #d4af37 0%, #ffea99 25%, #ffffff 50%, #ffea99 75%, #d4af37 100%);
    background-size: 200% 100%;
    /* Animation fluide et infinie */
    animation: shimmer 1.5s linear infinite;
    position: relative;
    box-shadow: 0 0 10px rgba(212, 175, 55, 0.6);
    transition: width 0.3s ease;
}

/* Animation du dégradé (boucle parfaite de 200% à 0%) */
@keyframes shimmer {
    0% { background-position: 200% 0; }
    100% { background-position: 0 0; }
}

/* L'émetteur d'étincelles situé EXACTEMENT au centre du bout de la barre */
.spark-emitter {
    position: absolute;
    top: 50%;
    right: 0;
    width: 0;
    height: 0;
    z-index: 10;
}

/* Style individuel d'une étincelle générée en JS */
.spark {
    position: absolute;
    top: 0;
    left: 0;
    pointer-events: none;
    animation: shoot var(--duration) cubic-bezier(0.25, 1, 0.5, 1) forwards;
    transform-origin: center center;
}

/* L'animation de projection des étincelles (lignes) */
@keyframes shoot {
    0% {
        transform: translate(-50%, -50%) rotate(var(--angle)) scaleX(1);
        opacity: 0.5;
    }
    100% {
        transform: translate(calc(var(--tx) - 50%), calc(var(--ty) - 50%)) rotate(var(--angle)) scaleX(0);
        opacity: 0;
    }
}

/* /Progress Bar Style */

        @keyframes spin {
            100% {
                transform: rotate(360deg);
            }
        }
        
        /* Animation pour le statut de copie */
        @keyframes fade-out {
            0% { opacity: 1; transform: translateY(0); }
            80% { opacity: 1; transform: translateY(0); }
            100% { opacity: 0; transform: translateY(-5px); }
        }

        .step-label,
        #content-transition-wrapper {
            transition: all .5s ease-in-out;
        }
        
        .step-label::after {
            transition: opacity .5s ease-in-out, transform .5s ease-in-out;
        }
        
        .line-bar, .line-progress {
            transition: all .5s ease-in-out; 
        }
        
        .interaction-disabled {
            pointer-events: none;
            opacity: 0;
        }

.nomobilescreen {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgb(0, 0, 0);
  display: none;
  justify-content: center;
  align-items: center;
  z-index: 100;
}

#nomobiletxt {
  color: #efefef;
  font: 900 1rem "Quency_Pixel";
}

/* Responsive Mobile */

@media (max-width: 1024px) {

  .background_overlay {
    position: fixed;
    inset: 0;
  }

  #welcometxt {
    display: none;
  }

  #usernameDisplay {
    display: none;
  }

  #title {
    position: relative;
    font-size: 5rem;
    padding-top: 70px;
    left: 50%;
    transform: translateX(-50%);
  }

  #subtitle {
    font-size: 1.5rem;
    margin: -10px 0 0 0;
    left: 50%;
    transform: translateX(-50%);
  }

  #dotfun {
    display: none;
  }

  #networkinfo {
    display: none;
  }

  .menu-container {
    top: 15px;
    right: 20px;
  }

  #signinbutton {
    top: 15px;
    right: 90px;
    z-index: 21;
  }

  #logoutbutton {
    top: 15px;
    right: 90px;
    z-index: 20;
  }

/* home */

.grid {
  left: 50%;
  transform: translateX(-50%);
  margin: 20px 0 0 0;
  width: 100%;
  max-width: 360px; 
  display: grid;
  grid-template-columns: 1fr;
  gap: clamp(16px, 5vh, 24px); 
}

.item:nth-child(1) {
  display: grid;
  grid-template-rows: repeat(5, auto);
}

#rewards-container {
  grid-column: 1;
  grid-row: 1;
  min-height: 25dvh; 
  height: auto; 
}

#wallet-container {
  grid-column: 1;
  grid-row: 2;
  min-height: 25dvh; 
  height: auto;
}

#leaderboard-container {
  display: none;
}

#referrals-container {
  display: none;
}

#stat-container {
  display: none;
}

/* footer */

.progress-wrapper {
    left: 50%;
    transform: translateX(-50%);
    position: absolute;
    bottom: 80px;
    width: 80%;
    z-index: 10;
}

  #discordbutton {
    bottom: 20px;
  }

  #copyrightTxt {
    bottom: 20px;
  }

}

@media (max-height: 750px) {

  #title {
    display: none;
  }

  #subtitle {
    display: none;
  }

  .grid {
    margin: 60px 0 0 0;
    gap: clamp(16px, 2vh, 128px); 
  }

  .grid2 {
    margin: 60px 0 0 0;
    gap: clamp(16px, 2vh, 128px); 
  }

  #wallet-container {
  grid-column: 1;
  grid-row: 2;
  height: 33dvh; 
  }

  #soldfiatDisplay {
  position: absolute;
  top: 40px;
  margin: 0 0 100px 0;
  font-size: 3rem;
  font-family: "Agbalumo", system-ui;
  color: #3055bb;
}

  #soldDisplay {
  position: absolute;
  top: 105px;
  font-size: 1rem;
  font-family: "Agbalumo", system-ui;
  color: #c0c0c0;
}

#depositbutton {
  margin: 110px 8px 0 auto;
}

#withdrawbutton {
  margin: 110px auto 0 8px;
}

 #discordbutton {
    bottom: 18px;
  }

}