.hp-info-row {
  position: relative;
  top: -80px;
  left: 0;
  right: 0;
  display: flex;
  gap: 15px;
  justify-content: center;
  max-width: clamp(200px, 90%, 300px);
  margin: 10px auto;
}

.hp-info-row .hp-text,
.hp-info-row .holds-left {
  flex: 1;
  background: #005473;
  padding: 9px 15px;
  border-radius: 8px;
  border-left: 0.6vw solid var(--score-border-color);
  border-right: 0.6vw solid var(--score-border-color);
  color: #fff;
  font-weight: 600;
  font-size: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.25);
  animation: pulse 4s infinite ease-in-out;
}

/* Position shifts */
.hp-info-row .holds-left {
  transform: translateX(-8px);
}

.hp-info-row .hp-text {
  transform: translateX(8px);
}

/* Pulse animation (only affects scale and shadow) */
@keyframes pulse {
  0%, 100% {
    scale: 1;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.25);
  }
  50% {
    scale: 1.03;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.35);
  }
}

/* Mobile responsiveness */
@media (max-width: 480px) {
  .hp-info-row {
    gap: 10px;
    max-width: 100%;
  }

  .hp-info-row .hp-text,
  .hp-info-row .holds-left {
    font-size: 13px;
    padding: 8px 12px;
    position: relative; /* add this */
  }

  .hp-info-row .holds-left {
    right: -50px; /* moves left */
  }

  .hp-info-row .hp-text {
    left: -50px; /* moves right */
  }
}

/* Icon and counter styling */
.hp-info-row .icon {
  font-size: 1.3rem;
  color: #f1c40f;
  user-select: none;
}

.hp-info-row #hpCount,
.hp-info-row #holdsLeftCount {
  color: #ddd;
  font-weight: 700;
}

h6 {
  font-size: 0.8em;
  font-weight: normal;
  color: #ffffffcc; /* semi-transparent white */
  text-align: center;
  position: relative;
  top: -160px; /* moves it up 30px */
  margin-bottom: 0;
  font-family: Arial, sans-serif;
  user-select: none; /* optional */
}

.marc-text {
  color: #ffcb4d; /* gold-ish color, adjust as you like */
  font-weight: bold;
}

#holdCountdown {
    font-size: 24px;
    font-weight: bold;
    color: #27ae60;
    margin-bottom: 5px;
    height: 100px;
  }


#holdProgressBarContainer {
  width: 70%;
  top: -50px;
  height: 20px;
  border-left: 0.6vw solid var(--score-border-color);
  border-right: 0.6vw solid var(--score-border-color);
  border-radius: 10px;
  overflow: hidden;
  margin-top:-20px;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.25);
  animation: pulse 4s infinite ease-in-out;
  background-color: #003248;
  position: relative;
}

#holdProgressBar {
  height: 90%;
  width: 0%;
  background: linear-gradient(to right, rgb(118, 255, 33), rgb(255, 157, 173), rgb(171, 29, 171));
  border-radius: 10px;
  transition: width 0.2s ease-in-out;
}

/* Overlay */
.overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(0, 0, 0, 0.6);
  z-index: 9998;
}

/* Fullscreen exchange dropdown */
#exchange-dropdown {
  display: none;
  position: fixed;
  top: 0;
  right: -100%;
  width: 60vw;
  max-width: 400px;
  height: 100vh;
  background-color: var(--wallet-bg);
  backdrop-filter: blur(30px); /* Optional blur for modern feel */
  border-left: 0.6vw solid var(--score-border-color);
  box-shadow: 0 0 15px rgba(0, 255, 179, 0.6);
  z-index: 9999;
  overflow-y: auto;
  padding: 60px 20px 20px;
  box-sizing: border-box;
  transition: right 0.3s ease;
}

#exchange-dropdown.fullscreen {
  right: 0;
  display: block;
}

.close-btn {
  position: fixed;
  top: 15px;
  right: 20px;
  background: rgba(0, 0, 0, 0.1);
  border: none;
  font-size: 2.2rem;
  cursor: pointer;
  z-index: 10000;
  padding: 5px 10px;
  border-radius: 5px;
}

/* Exchange links */
#exchange-dropdown a {
  display: flex;
  align-items: center;
  padding: 15px;
  font-size: 1.2rem;
  color: #fff;
  border-bottom: 1px solid #ffcb4d;
}

#exchange-dropdown a img {
  width: 32px;
  height: 32px;
  margin-right: 10px;
}

/* Responsive */
@media (max-width: 600px) {
  #exchange-dropdown a {
    font-size: 1rem;
    padding: 12px;
  }

  .close-btn {
    font-size: 2rem;
    right: 10px;
    top: 10px;
  }
}

/* Close Button */
.close-btn {
  position: absolute;
  top: 5vw;
  right: 6vw;
  font-size: 8vw;
  max-font-size: 32px;
  background: transparent;
  color: white;
  border: none;
  cursor: pointer;
  z-index: 10000;
}

/* Overlay */
#overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(4px);
  z-index: 9990;
}

/* Rank Modal Styles */
.rank-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: linear-gradient(to bottom, var(--background-color), var(--primary-color), var(--gradient-mid));
  backdrop-filter: blur(4px); /* Optional blur for modern feel */
  color: #fff;
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  padding: 10vw 6vw;
  box-sizing: border-box;
  transition: opacity 0.3s ease;
}

.rank-modal.active {
  display: flex;
  opacity: 1;
}

.rank-modal h2 {
  font-size: 7vw;
  max-font-size: 28px;
  margin-bottom: 3vw;
}

.rank-modal p {
  margin: 2vw 0;
  font-size: 4.5vw;
  max-font-size: 18px;
}

.rank-modal .progress {
  width: 90%;
  height: 4vw;
  max-height: 18px;
  background: #333;
  border-radius: 10px;
  margin: 4vw 0;
  overflow: hidden;
}

.rank-modal .bar {
  height: 100%;
  width: 0%;
  background: linear-gradient(to right, #f39c12, #f1c40f);
  transition: width 0.5s ease;
}

#upgrade-rank {
  background: #27ae60;
  color: white;
  border: none;
  padding: 3vw 6vw;
  font-size: 4.5vw;
  max-font-size: 16px;
  border-radius: 6px;
  margin-top: 5vw;
  cursor: pointer;
  transition: background 0.3s ease;
}

#upgrade-rank:hover {
  background: #2ecc71;
}

/* Responsive adjustments */
@media (max-width: 600px) {
  .exchange-dropdown.fullscreen a {
    font-size: 18px;
  }

  .rank-modal h2 {
    font-size: 22px;
  }

  .rank-modal p {
    font-size: 16px;
  }

  .rank-modal .progress {
    width: 90%;
  }
}

.name_con {
  display: flex;
  align-items: center;
  margin-bottom: 1vh;
}

.img1 {
  pointer-events: none;
  width: 15vw;
  border-radius: 60%;
}

.name {
  color: white;
  font-size: 2.5vw;
  font-weight: 600;
  margin-left: 10px;
}

.rank_perhour {
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1vh;
}

.rank_bar {
  width: 30%;
  height: 6vh;
  display: flex;
  justify-content: center;
  align-items: center;
  flex-direction: column;
  cursor: pointer;
  border-radius: 18px;
}

.rank {
  width: 90%;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.rank_txt1 {
  color: white;
  margin: 0;
  font-size: 3vw;
  font-weight: 600;
}

.rank_txt2 {
  color: rgb(131, 131, 131);
  margin: 0;
  font-size: 3vw;
  font-weight: 600;
}

.bar {
  display: flex;
  justify-content: left;
  align-items: center;
  width: 95%;
  height: 1vh;
  border-radius: 15px;
  margin-top: 1vh;
  border: 0.5px solid rgba(132, 132, 132, 0.433);
  background-color: #005473;
}

.extand_bar {
  height: 0.9vh;
  border-radius: 15px;
  background: linear-gradient(to right, rgb(118, 255, 33), rgb(255, 157, 173), rgb(171, 29, 171));
}

.perhour {
  background-color: #005473;
  width: 60%;
  height: 5vh;
  margin-right: 1vw;
  border-radius: 20px;
  display: flex;
  justify-content: space-evenly;
  align-items: center;
  cursor: pointer;
}

.img2 {
  pointer-events: none;
  width: 6.15vw;
}

.coinsperhour {
  display: flex;
  justify-content: center;
  align-items: center;
  flex-direction: column;
}

.profithour_txt {
  margin: 0;
  font-size: 2vw;
  color: rgb(165 165 165 / 81%);
}

.coins_hour {
  display: flex;
  justify-content: center;
  align-items: center;
}

.line {
  width: 0.60vw;
  height: 3vh;
  background-color: #898989a1;
}

.img3 {
  pointer-events: none;
  width: 4.6vw;
  margin-left: 0.8vw;
}

.coinsinhour_txt {
  color: white;
  font-size: 3.8vw;
  font-weight: 600;
  margin: 0 0 0.2vw 0.4vw;
}

.img4 {
  pointer-events: none;
  width: 4.6vw;
  margin-right: 0.8vw;
  margin-left: 0.6vw;
}

.setting {
  color: #eeeeee;
  font-size: 4.4vw;
}

#rank_name {
  cursor: pointer;
}
#rank_name:hover {
  color: gold;
  text-decoration: underline;
}

.exchange-dropdown {
  display: none;
  position: absolute;
  background-color: white;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  border-radius: 5px;
  margin-top: 5px;
  z-index: 1000;
}

.exchange-dropdown a {
  display: block;
  padding: 10px;
  text-decoration: none;
  color: #333;
  border-bottom: 1px solid #ddd;
}

.exchange-dropdown a img {
  width: 20px;
  margin-right: 10px;
}

.exchange-dropdown a:last-child {
  border-bottom: none;
}

.exchange-selector:hover .exchange-dropdown {
  display: block;
}

.language-dropdown {
  position: absolute;
  background: rgba(0, 0, 0, 0.3);
  backdrop-filter: blur(4px);
  border: 1px solid #00ff99;
  border-radius: 20px;
  padding: 10px;
  box-shadow: 0 0 20px rgba(0, 255, 179, 0.5);
  animation: modalFadeIn 0.3s ease forwards;
  z-index: 1000;
}

.language-dropdown p {
  margin: 0;
  padding: 8px 12px;
  cursor: pointer;
}
.language-dropdown p:hover {
  background-color: #f0f0f0;
}