.mines-container {
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 2rem;
  align-items: center;
  width: 100%;
  flex: 1;
}

.game-section {
  display: flex;
  gap: 3rem;
  justify-content: center;
  align-items: flex-start;
  width: 100%;
  max-width: 1600px;
}

.game-controls {
  width: 100%;
  max-width: 540px;
  min-width: 400px;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  padding: 2.2rem 2rem 2rem 2rem;
  background: var(--secondary-bg);
  border-radius: 16px;
  height: fit-content;
  box-shadow: 0 2px 16px rgba(0, 0, 0, 0.08);
}

.mode-selector {
  background: rgba(255, 255, 255, 0.03);
  padding: 0.5rem;
  border-radius: 10px;
  width: fit-content;
}

.mode-selector span {
  color: var(--text-color);
  font-weight: 500;
  font-size: 14px;
}

.bet-input {
  flex: 1;
  margin-right: 10px;
}

.bet-input input {
  width: 100%;
}

.input-label {
  color: var(--text-secondary);
  font-size: 14px;
  font-weight: 500;
}

.bet-input-field {
  display: flex;
  gap: 0.75rem;
  background: rgba(255, 255, 255, 0.03);
  padding: 0.75rem;
  border-radius: 10px;
  align-items: center;
}

.bet-input-field input {
  flex: 1;
  background: none;
  border: none;
  color: var(--text-color);
  font-size: 16px;
  padding: 0.25rem;
  width: 100%;
}

.bet-input-field input:focus {
  outline: none;
}

.quick-actions {
  display: flex;
  gap: 0.5rem;
  margin-left: auto;
}

.quick-actions button {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  color: var(--text-color);
  padding: 0.6rem 0.8rem;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
  min-width: 45px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.quick-actions button:hover {
  background: rgba(255, 255, 255, 0.12);
  border-color: var(--accent-color);
  transform: translateY(-1px);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
}

.quick-actions button:active {
  transform: translateY(0);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.mines-selector {
  display: none;
}

.mines-amount {
  background: rgba(255, 255, 255, 0.03);
  padding: 1rem;
  border-radius: 10px;
  position: relative;
}

.mines-display {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1rem;
}

.mines-value {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.mines-value i {
  color: rgba(255, 59, 48, 0.7);
  font-size: 18px;
}

.mines-value span {
  color: var(--text-color);
  font-weight: 500;
  font-size: 16px;
}

.mines-multiplier {
  color: var(--text-secondary);
  font-size: 14px;
}

.mines-slider {
  -webkit-appearance: none;
  width: 100%;
  height: 6px;
  border-radius: 3px;
  background: rgba(255, 255, 255, 0.05);
  outline: none;
  position: relative;
}

.mines-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: rgba(255, 59, 48, 0.8);
  cursor: pointer;
  transition: all 0.2s;
}

.mines-slider::-moz-range-thumb {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: rgba(255, 59, 48, 0.8);
  cursor: pointer;
  border: none;
  transition: all 0.2s;
}

.mines-slider::-webkit-slider-thumb:hover {
  transform: scale(1.1);
  background: #ff3b30;
}

.mines-slider::-moz-range-thumb:hover {
  transform: scale(1.1);
  background: #ff3b30;
}

.mines-ticks {
  display: flex;
  justify-content: space-between;
  padding: 0 10px;
  margin-top: 0.5rem;
}

.mines-tick {
  color: var(--text-secondary);
  font-size: 12px;
  cursor: pointer;
  transition: all 0.2s;
}

.mines-tick:hover {
  color: var(--text-color);
}

.total-earnings {
  margin-top: auto;
  padding-top: 1rem;
}

.total-earnings .input-label {
  margin-bottom: 0.5rem;
}

.earnings-display {
  background: rgba(255, 255, 255, 0.03);
  padding: 1rem;
  border-radius: 10px;
  text-align: center;
  color: var(--text-color);
  font-size: 18px;
  font-weight: 500;
}

.action-button {
  width: 100%;
  padding: 1rem;
  border: none;
  border-radius: 10px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s;
  font-size: 16px;
  margin-top: 1rem;
  background: var(--accent-color);
  color: #000;
}

.action-button:hover {
  filter: brightness(1.1);
}

.action-button.cashout {
  background: #4caf50;
  color: white;
}

.action-button.cashout:hover {
  background: rgba(76, 175, 80, 0.2);
  transform: translateY(-1px);
}

.action-button.cashout:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
}

.mines-game {
  background: var(--secondary-bg);
  border-radius: 16px;
  padding: 1rem;
  width: 650px;
}

.mines-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 0.5rem;
  width: 100%;
}

.mine-tile {
  aspect-ratio: 1;
  background: rgba(255, 255, 255, 0.03);
  border-radius: 10px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  color: rgba(255, 255, 255, 0.9);
  transition: all 0.2s ease;
  position: relative;
  overflow: hidden;
}

.mine-tile::before {
  content: "";
  position: absolute;
  width: 70%;
  height: 70%;
  background-image: url("/cdn/tiger.png");
  background-size: contain;
  background-position: center;
  background-repeat: no-repeat;
  opacity: 0.15;
  filter: grayscale(100%);
  transition: all 0.3s ease;
}

.mine-tile:hover {
  background: rgba(255, 255, 255, 0.05);
  transform: translateY(-2px);
}

.mine-tile.revealed {
  cursor: default;
  transform: none;
}

.mine-tile.revealed.gem::before {
  opacity: 0.6;
  filter: none;
  animation: gemReveal 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.mine-tile.revealed.mine {
  background: rgba(255, 59, 48, 0.1);
}

.mine-tile.revealed.mine i {
  color: #ff3b30;
  font-size: 42px;
  animation: mineReveal 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes gemReveal {
  0% {
    transform: scale(0) rotate(-180deg);
    opacity: 0;
  }
  100% {
    transform: scale(1) rotate(0deg);
    opacity: 0.6;
  }
}

@keyframes mineReveal {
  0% {
    transform: scale(0);
    opacity: 0;
  }
  50% {
    transform: scale(1.3);
  }
  100% {
    transform: scale(1);
    opacity: 1;
  }
}

.game-buttons {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.start-btn,
.cashout-btn {
  padding: 0.75rem;
  border: none;
  border-radius: 4px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s;
  font-size: 15px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
}

.start-btn {
  background: var(--accent-color);
  color: #000;
}

.start-btn:hover {
  filter: brightness(1.1);
  transform: translateY(-1px);
}

.cashout-btn {
  background: rgba(76, 175, 80, 0.1);
  color: #4caf50;
}

.cashout-btn:hover {
  background: rgba(76, 175, 80, 0.2);
  transform: translateY(-1px);
}

.cashout-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
}

.game-history {
  background: var(--secondary-bg);
  border-radius: 16px;
  padding: 1rem;
  max-width: 1300px;
  margin: 0 auto;
}
.history-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  margin-bottom: 0.75rem;
}

.history-title {
  font-weight: 600;
  color: var(--text-color);
}

.history-list {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.history-item {
  background: rgba(255, 255, 255, 0.02);
  border-radius: 10px;
  padding: 0.75rem;
  display: flex;
  align-items: center;
  gap: 1rem;
  animation: slideIn 0.3s ease-out;
  width: 100%;
}

.history-player {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-weight: 500;
  width: 280px;
}

.history-player img {
  width: 32px;
  height: 32px;
  border-radius: 4px;
}

.history-game-type {
  width: 140px;
  color: var(--text-secondary);
  font-size: 14px;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.history-result {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  width: 180px;
  font-weight: 500;
}

.history-details {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  color: var(--text-secondary);
  font-size: 14px;
  width: 380px;
}

.history-time {
  color: var(--text-secondary);
  font-size: 13px;
  width: 120px;
  text-align: right;
}

@keyframes slideIn {
  from {
    opacity: 0;
    transform: translateY(5px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

#livechat-container {
  width: 100%;
  max-width: 1300px;
  margin: 1.5rem auto 0;
}

#footer-container {
  margin-top: 2rem;
  width: 100%;
}

.towers-game {
  background: var(--secondary-bg);
  border-radius: 16px;
  padding: 2rem;
  width: 100%;
  max-width: 900px;
  min-width: 400px;
  box-shadow: 0 2px 16px rgba(0, 0, 0, 0.08);
  display: flex;
  flex-direction: column;
  align-items: center;
  position: relative;
  overflow: hidden;
}

.towers-game::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-image: url("/cdn/crashbg.png");
  background-size: cover;
  background-position: center;
  opacity: 0.07;
  z-index: 0;
}

.towers-grid {
  display: flex;
  flex-direction: column-reverse;
  gap: 0.75rem;
  width: 100%;
  max-width: 500px;
  position: relative;
  z-index: 1;
}

.tower-row {
  display: flex;
  gap: 0.5rem;
  width: 100%;
  justify-content: center;
  margin-bottom: 5px;
  transition: all 0.2s ease;
  position: relative;
}

.tower-row.current-row {
  background: rgba(255, 144, 0, 0.1);
  border-radius: 5px;
  box-shadow: 0 0 0 1px rgba(255, 144, 0, 0.3);
}

.tower-tile {
  background: rgba(255, 255, 255, 0.03);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  color: rgba(255, 255, 255, 0.9);
  transition: all 0.2s ease;
  position: relative;
  overflow: hidden;

  height: 50px;
  flex: 1;
  cursor: default;
  opacity: 0.7;
}

.tower-tile::before {
  content: "";
  position: absolute;
  width: 70%;
  height: 70%;
  background-image: url("/cdn/tiger.png");
  background-size: contain;
  background-position: center;
  background-repeat: no-repeat;
  opacity: 0.15;
  filter: grayscale(100%);
  transition: all 0.3s ease;
}

.tower-tile.active-tile {
  cursor: pointer;
  opacity: 1;
  background: rgba(255, 255, 255, 0.05);
}

.tower-tile.active-tile:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
  background: rgba(255, 255, 255, 0.1);
}

.tower-tile.revealed {
  cursor: default;
  transform: none;
  opacity: 1;
}

.tower-tile.revealed.gem::before {
  opacity: 0.6;
  filter: none;
  animation: gemReveal 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.tower-tile.revealed.mine {
  background: rgba(255, 59, 48, 0.1);
}

.tower-tile.revealed.mine i {
  color: #ff3b30;
  font-size: 42px;
  animation: mineReveal 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.tower-row-label {
  position: absolute;
  left: -30px;
  font-size: 12px;
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  height: 100%;
}

.difficulty-selector {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 1rem;
  background: rgba(255, 255, 255, 0.03);
  border-radius: 10px;
  padding: 0.5rem;
  z-index: 4;
}

.difficulty-option {
  padding: 0.5rem 1rem;
  border-radius: 4px;
  cursor: pointer;
  transition: all 0.2s ease;
  font-size: 14px;
  color: var(--text-secondary);
}

.difficulty-option:hover {
  background: rgba(255, 255, 255, 0.05);
}

.difficulty-option.active {
  background: var(--accent-color);
  color: #000;
}

@keyframes tileLoading {
  0% {
    opacity: 0.6;
  }
  50% {
    opacity: 1;
  }
  100% {
    opacity: 0.6;
  }
}

.tower-tile.loading {
  animation: tileLoading 0.8s ease-in-out infinite;
  background: rgba(255, 144, 0, 0.1);
  pointer-events: none;
}

@media screen and (max-width: 1024px) {
  .game-section {
    flex-direction: column;
  }
  .game-controls {
    width: 100% !important;
  }
  .towers-game {
    width: 100% !important;
  }
}
