
.game-container {
  display: flex;
  flex-direction: column;
  max-width: 1200px;
  width: 100%;
  gap: 16px;
}

.game-panel {
  background-color: #1c1d2a;
  border-radius: 16px;
  padding: 20px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

/* Main Game Area */
.main-game-area {
  display: flex;
  gap: 16px;
  color: #ffffff;
}

.game-panel {
  flex: 1;
}

/* Game History */
.game-history {
  background-color: #1c1d2a;
  border-radius: 16px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
  overflow-x: auto;
  width: 100%;
  text-align: center;
  margin-bottom: 39px;
}

.history-header {
  display: grid;
  grid-template-columns: minmax(150px, 1fr) minmax(120px, 1fr) minmax(200px, 1.5fr) minmax(120px, 1fr) minmax(150px, 1fr) minmax(120px, 1fr);
  padding: 20px;
  background: rgba(40, 41, 53, 0.5);
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  position: sticky;
  top: 0;
  z-index: 1;
  min-width: 860px;
}

.header-cell {
  color: rgba(255, 255, 255, 0.7);
  font-size: 14px;
  font-weight: 500;
  text-transform: uppercase;
  padding: 0 10px;
}

.history-row {
  display: grid;
  grid-template-columns: minmax(150px, 1fr) minmax(120px, 1fr) minmax(200px, 1.5fr) minmax(120px, 1fr) minmax(150px, 1fr) minmax(120px, 1fr);
  padding: 15px 20px;
  transition: all 0.3s ease;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  align-items: center;
  min-width: 860px;
}

.history-row:hover {
  background: rgba(40, 41, 53, 0.5);
}

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

.history-cell {
  font-size: 14px;
  color: rgba(255, 255, 255, 0.9);
  padding: 0 10px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.history-cell:first-child {
  display: flex;
  align-items: center;
  justify-content:center;
  gap: 8px;
}

.history-cell:first-child::before {
  content: '';
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #4b6bfb;
  flex-shrink: 0;
}

.chance-bar {
  width: 100%;
  height: 6px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 3px;
  overflow: hidden;
}

.chance-fill {
  height: 100%;
  background: linear-gradient(to right, #4b6bfb, #3550cc);
  border-radius: 3px;
  transition: width 0.3s ease;
}

.win-amount {
  color: #FFFFFF;
  font-weight: 700;
}

.history-row.win .history-cell.win-sum {
  color: #71B760;
  font-weight:600;
}

.history-row.lose .history-cell.lose-sum {
  color: #f44336;
  font-weight:600;
}

.history-row.win .history-cell:first-child::before {
  background: #71B760;
}

.history-row.lose .history-cell:first-child::before {
  background: #ff5757;
}

/* Custom scrollbar for history */
.game-history::-webkit-scrollbar {
  height: 8px;
  width: 8px;
}

.game-history::-webkit-scrollbar-track {
  background: rgba(255, 255, 255, 0.05);
  border-radius: 4px;
}

.game-history::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.2);
  border-radius: 4px;
}

.game-history::-webkit-scrollbar-thumb:hover {
  background: rgba(255, 255, 255, 0.3);
}

/* Header Styles */
.game-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 30px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 24px;
}

.title-group {
  display: flex;
  align-items: center;
  gap: 15px;
}

.dice-icon {
  width: 32px;
  height: 32px;
  background-color: #4b6bfb;
  border-radius: 6px;
  position: relative;
}

.dice-icon:before, .dice-icon:after {
  content: '';
  position: absolute;
  width: 6px;
  height: 6px;
  background-color: white;
  border-radius: 50%;
}

.dice-icon:before {
  top: 8px;
  left: 8px;
}

.dice-icon:after {
  bottom: 8px;
  right: 8px;
}

.help-button {
  font-size: 14px;
  font-weight: 500;
  opacity: 0.7;
  cursor: pointer;
  transition: all 0.3s ease;
  padding: 8px 16px;
  border: 2px solid rgba(255, 255, 255, 0.7);
  border-radius: 20px;
  background-color: transparent;
}

.help-button:hover {
  opacity: 1;
  border-color: rgba(255, 255, 255, 0.9);
  background-color: rgba(255, 255, 255, 0.1);
}

/* Game Controls */
.game-controls {
  display: flex;
  gap: 15px;
  margin-bottom: 30px;
}

.control-group {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.control-group label {
  font-size: 14px;
  opacity: 0.7;
}

.value-control {
  background-color: #282935;
  border-radius: 8px;
  height: 50px;
  display: flex;
  align-items: center;
  padding: 0 15px;
}

.value-control input {
  width: 100%;
  background: transparent;
  border: none;
  color: white;
  font-size: 18px;
  font-weight: 700;
  text-align: center;
}

.value-control input:focus {
  outline: none;
}

.button-group {
  display: flex;
  gap: 5px;
}

.control-button {
  flex: 1;
  background-color: #282935;
  border: none;
  border-radius: 6px;
  color: white;
  padding: 8px 0;
  font-size: 12px;
  cursor: pointer;
  transition: all 0.3s ease;
}

.control-button:hover {
  background-color: #3a3b4a;
}

.win-display, .bonus-display {
  background-color: #282935;
  border-radius: 8px;
  height: 50px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: relative;
  padding: 0 15px;
}

.win-amount, .bonus-amount {
  font-size: 24px;
  font-weight: 700;
}

.arrow-left, .arrow-right {
  width: 0;
  height: 0;
  border-top: 6px solid transparent;
  border-bottom: 6px solid transparent;
  cursor: pointer;
  transition: opacity 0.3s ease;
}

.arrow-left {
  border-left: 8px solid #4b6bfb;
}

.arrow-right {
  border-right: 8px solid #4b6bfb;
}

.arrow-left.yellow {
  border-left-color: #f7b500;
}

.arrow-right.yellow {
  border-right-color: #f7b500;
}

.arrow-left:hover, .arrow-right:hover {
  opacity: 0.7;
}

/* Game Buttons */
.game-buttons {
  display: flex;
  gap: 15px;
  margin-bottom: 30px;
}

.game-button {
  flex: 1;
  height: 80px;
  padding: 10px;
  border-radius: 10px;
  border: none;
  color: white;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-weight: 700;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.game-button span {
  font-size: 18px;
  margin-bottom: 5px;
  position: relative;
  z-index: 2;
}

.game-button .range {
  font-size: 14px;
  opacity: 0.7;
  position: relative;
  z-index: 2;
}

.game-button.less {
  background: linear-gradient(135deg, #4b6bfb, #3550cc);
  box-shadow: 0 4px 15px rgba(75, 107, 251, 0.3);
}

.game-button.more {
  background: linear-gradient(135deg, #f7b500, #e69b00);
  box-shadow: 0 4px 15px rgba(247, 181, 0, 0.3);
}

.game-button:after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(255, 255, 255, 0.1);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.game-button:hover:after {
  opacity: 1;
}

.game-button:active {
  transform: translateY(2px);
}

/* Hash Section */
.hash-section {
  background-color: #282935;
  border-radius: 8px;
  padding: 15px;
  margin-bottom: 3px;
}

.hash-label {
  font-size: 14px;
  opacity: 0.7;
  margin-bottom: 10px;
}

.hash-value {
  font-size: 12px;
  opacity: 0.5;
  word-break: break-all;
  transition: all 0.3s ease;
}

.hash-value.blurred {
  filter: blur(3px);
  opacity: 0.3;
}

/* Bonus History */
.bonus-history {
  background-color: #282935;
  border-radius: 12px;
  padding: 20px;
  margin-top: 30px;
  margin-bottom: 3px;
  max-height: 400px;
  overflow-y: auto;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.bonus-history::-webkit-scrollbar {
  width: 8px;
}

.bonus-history::-webkit-scrollbar-track {
  background: #1c1d2a;
  border-radius: 4px;
}

.bonus-history::-webkit-scrollbar-thumb {
  background: #3a3b4a;
  border-radius: 4px;
}

.bonus-history-title {
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 20px;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  padding-bottom: 15px;
  border-bottom: 3px solid rgba(255, 255, 255, 0.05);
}

.bonus-stats {
  display: flex;
  gap: 12px;
}

.stat {
  font-size: 14px;
  padding: 6px 12px;
  border-radius: 20px;
  display: flex;
  align-items: center;
  gap: 6px;
  font-weight: 500;
  transition: all 0.3s ease;
  white-space: nowrap;
}

.stat:hover {
  transform: translateY(-2px);
}

.stat.wins {
  background: linear-gradient(135deg, #29671a, #71B760);
  box-shadow: 0 4px 12px rgba(41, 103, 26, 0.2);
}

.stat.losses {
  background: linear-gradient(135deg, #671a1a, #ff5757);
  box-shadow: 0 4px 12px rgba(103, 26, 26, 0.2);
}

.stat.scatters {
  background: linear-gradient(135deg, #b5860f, #ffd700);
  box-shadow: 0 4px 12px rgba(181, 134, 15, 0.2);
}

.history-entry {
  background: linear-gradient(135deg, #1c1d2a, #282935);
  border-radius: 10px;
  padding: 15px;
  margin-bottom: 15px;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  font-size: 14px;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.history-entry:last-child {
  margin-bottom: 0;
}

.history-entry:hover {
  transform: translateY(-2px);
}

.history-entry.win {
  border: 1px solid rgba(113, 183, 96, 0.3);
}

.history-entry.win::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 4px;
  height: 100%;
  background: linear-gradient(to bottom, #29671a, #71B760);
}

.history-entry.lose {
  border: 1px solid rgba(255, 87, 87, 0.3);
}

.history-entry.lose::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 4px;
  height: 100%;
  background: linear-gradient(to bottom, #671a1a, #ff5757);
}

.entry-details {
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex: 1;
}

.entry-amount {
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.entry-amount .multiplier {
  background: linear-gradient(135deg, #4b6bfb, #3550cc);
  padding: 2px 8px;
  border-radius: 12px;
  font-size: 12px;
}

.entry-amount .scatter-badge {
  background: linear-gradient(135deg, #b5860f, #ffd700);
  padding: 2px 8px;
  border-radius: 12px;
  font-size: 12px;
  display: flex;
  align-items: center;
  gap: 4px;
}

.entry-result {
  opacity: 0.7;
  font-size: 13px;
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.entry-result .choice-badge {
  padding: 2px 8px;
  border-radius: 12px;
  font-size: 12px;
  background: #3a3b4a;
}

.entry-win {
  font-weight: 700;
  font-size: 18px;
  padding: 8px 15px;
  border-radius: 8px;
  margin-left: 15px;
  display: flex;
  align-items: center;
  gap: 4px;
  white-space: nowrap;
}

.entry-win.positive {
  background: linear-gradient(135deg, #29671a, #71B760);
  box-shadow: 0 4px 12px rgba(41, 103, 26, 0.2);
}

.entry-win.negative {
  background: linear-gradient(135deg, #671a1a, #ff5757);
  box-shadow: 0 4px 12px rgba(103, 26, 26, 0.2);
}

/* Bonus Section */
.bonus-section {
  background-color: #1c1d2a;
  border-radius: 16px;
  width: 350px;
  padding: 20px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
  display: flex;
  flex-direction: column;
  height: fit-content;
}

.bonus-controls {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 20px;
  margin-bottom: 30px;
}

.amount-control {
  width: 40px;
  height: 40px;
  border-radius: 8px;
  background-color: #282935;
  border: none;
  color: white;
  font-size: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.3s ease;
}

.amount-control:hover {
  background-color: #3a3b4a;
}

.amount-display {
  font-size: 28px;
  font-weight: 700;
}

.bonus-options {
  display: flex;
  flex-direction: column;
  gap: 20px;
  margin-bottom: 3px;
}

.bonus-option {
  background-color: #282935;
  border-radius: 10px;
  padding: 15px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  transition: all 0.3s ease;
}

.bonus-option:hover {
  background-color: #3a3b4a;
}

.bonus-price {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 700;
  font-size: 16px;
}

.cart-icon {
  width: 20px;
  height: 20px;
  background: url('/static/images/dice/icons/buy-icon.png') center/contain no-repeat;
  border-radius: 4px;
  top: -2px;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}

.cart-icon:after {
  content: none;
}

.bonus-gems {
  display: flex;
  gap: 8px;
}

.gem {
  width: 15px;
  height: 15px;
  border-radius: 4px; 
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

.gem img {
  width: 25px;
  height: 25px;
}

.bonus-spins {
  display: flex;
  flex-direction: column;
  align-items: center; 
  font-weight: 700;
}

.bonus-spins span {
  font-size: 24px;
}

.bonus-spins div {
  font-size: 12px;
  opacity: 0.7;
}

/* Bonus Win Modal */
.bonus-win-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(13, 14, 23, 0.95);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s ease;
  backdrop-filter: blur(8px);
}

.bonus-win-modal.show {
  opacity: 1;
  visibility: visible;
}

.bonus-win-content {
  background: linear-gradient(145deg, #1c1d2a, #282935);
  border-radius: 24px;
  padding: 30px;
  text-align: center;
  max-width: 400px;
  width: 90%;
  position: relative;
  transform: translateY(20px);
  transition: all 0.3s ease;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4),
              inset 0 0 0 1px rgba(255, 255, 255, 0.1);
  overflow: hidden;
}

.bonus-win-content::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: url('/static/images/dice/dice-bg.jpg') center/cover no-repeat;
  opacity: 0.35;
  z-index: 0;
}

.bonus-win-modal.show .bonus-win-content {
  transform: translateY(0);
}

.bonus-win-header {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 15px;
  margin-bottom: 30px;
  position: relative;
  z-index: 1;
}

.win-icon {
  width: 60px;
  height: 60px;
  background: linear-gradient(135deg, #71B760, #29671A);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  margin-bottom: 10px;
  box-shadow: 0 10px 20px rgba(41, 103, 26, 0.3);
}

.win-icon::before {
  content: '✓';
  font-size: 30px;
  color: white;
}

.bonus-win-title {
  font-size: 22px;
  font-weight: 800;
  background: linear-gradient(135deg, #ffffff, #71B760);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  text-shadow: 0 2px 10px rgba(41, 103, 26, 0.3);
  position: relative;
}

.bonus-win-stats {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 15px;
  margin-bottom: 30px;
  position: relative;
  z-index: 1;
}

.bonus-win-stats > :last-child {
  grid-column: 1 / -1;
}

.stat-item {
  background: rgba(40, 41, 53, 0.5);
  padding: 15px 10px;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  transition: all 0.3s ease;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
}

.stat-item:hover {
  transform: translateY(-2px);
  border-color: rgba(113, 183, 96, 0.3);
  box-shadow: 0 8px 20px rgba(41, 103, 26, 0.1);
}

.stat-item.highlight {
  background: linear-gradient(145deg, rgba(113, 183, 96, 0.2), rgba(41, 103, 26, 0.2));
  border-color: rgba(113, 183, 96, 0.3);
}

.stat-icon {
  width: 32px;
  height: 32px;
  border-radius: 10px;
  background: linear-gradient(135deg, #383a41, #474c5b);
  display: flex;
  align-items: center;
  justify-content: center;
}

.stat-icon img {
  height: 20px;
  width: 20px;
}

.stat-info {
  text-align: center;
  position: relative;
  z-index: 1;
}

.stat-label {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.7);
  margin-bottom: 4px;
}

.stat-value {
  font-size: 18px;
  font-weight: 700;
  background: linear-gradient(135deg, #ffffff, #e0e0e0);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.bonus-win-result {
  background: linear-gradient(145deg, rgba(113, 183, 96, 0.2), rgba(41, 103, 26, 0.2));
  border-radius: 16px;
  padding: 20px;
  margin-bottom: 25px;
  border: 1px solid rgba(113, 183, 96, 0.3);
  box-shadow: 0 10px 20px rgba(41, 103, 26, 0.1);
  position: relative;
  z-index: 1;
}

.result-label {
  font-size: 14px;
  color: rgba(255, 255, 255, 0.7);
  margin-bottom: 8px;
}

.result-amount {
  font-size: 28px;
  font-weight: 800;
  background: linear-gradient(135deg, #71B760, #29671A);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  text-shadow: 0 2px 10px rgba(41, 103, 26, 0.3);
}

.bonus-win-close {
  background: linear-gradient(135deg, #71B760, #29671A);
  border: none;
  color: white;
  padding: 12px 30px;
  border-radius: 12px;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 8px 20px rgba(41, 103, 26, 0.2);
  position: relative;
  z-index: 1;
  overflow: hidden;
}

.bonus-win-close:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 25px rgba(41, 103, 26, 0.3);
}

.bonus-win-close:active {
  transform: translateY(1px);
}

.bonus-win-close::after {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: linear-gradient(
    to bottom right,
    rgba(255, 255, 255, 0) 0%,
    rgba(255, 255, 255, 0.1) 50%,
    rgba(255, 255, 255, 0) 100%
  );
  transform: rotate(30deg);
  animation: shine 3s infinite;
}

/* Mobile Optimizations */
@media (max-width: 1024px) {
  .main-game-area {
    flex-direction: column;
  }
  
  .bonus-section {
    width: 100%;
  }
}

@media (max-width: 768px) {
  .game-controls {
    flex-wrap: wrap;
  }
  
  .control-group {
    min-width: calc(50% - 10px);
  }
  
  .game-header {
    flex-direction: column;
    gap: 15px;
  }
  
  .bonus-stats {
    flex-wrap: wrap;
  }
  
  .stat {
    flex: 1;
    justify-content: center;
    padding: 8px 12px;
  }

  .history-header,
  .history-row {
    grid-template-columns: 0.7fr 1fr 1fr 1fr 1fr;
  }

  .header-cell:nth-child(3),
  .history-cell:nth-child(3) {
    display: none;
  }
}

@media (max-width: 480px) {
  .control-group {
    min-width: 100%;
  }
  
  .game-buttons {
    flex-direction: column;
  }
  
  .history-entry {
    flex-direction: column;
    gap: 10px;
  }
  
  .entry-win {
    width: 100%;
    justify-content: center;
    margin-left: 0;
  }

  .history-cell {
    font-size: 12px;
  }

  .logo {
    font-size: 18px;
  }

  .title-group {
    gap: 6px;
    flex-direction: column;
  }

  .help-button {
    font-size: 11px;
    font-weight: 600;
  }

  .dice-icon {
    width: 25px;
    height: 25px;
  }

  .dice-icon:before, .dice-icon:after {
    width: 4px;
    height: 4px;
  }
}












































































                                               