/* 疯狂水果 - 前端样式 */
.cf-container {
  max-width: 500px;
  margin: 0 auto;
  padding: 10px;
  background: linear-gradient(135deg, #4a148c 0%, #6a1b9a 50%, #880e4f 100%);
  border-radius: 12px;
  min-height: 600px;
}

.cf-header { margin-bottom: 10px; }

.cf-info-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
  padding: 8px 12px;
  background: rgba(0,0,0,0.3);
  border-radius: 8px;
  font-size: 13px;
  color: #fff;
}

.cf-machine {
  background: rgba(0,0,0,0.5);
  border-radius: 12px;
  padding: 15px;
  margin-bottom: 10px;
  position: relative;
}

.cf-reels {
  display: flex;
  gap: 8px;
  justify-content: center;
}

.cf-reel {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.cf-reel.spinning .cf-cell {
  animation: cfSpin 0.1s linear infinite;
}

@keyframes cfSpin {
  0% { transform: translateY(-30px); opacity: 0.5; }
  100% { transform: translateY(0); opacity: 1; }
}

.cf-cell {
  width: 80px;
  height: 80px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 40px;
  border-radius: 8px;
  border: 2px solid rgba(255,255,255,0.2);
  box-shadow: inset 0 2px 8px rgba(0,0,0,0.3);
}

.cf-win-display {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-size: 32px;
  font-weight: bold;
  color: #FFD700;
  text-shadow: 0 0 10px #FF6F00, 0 2px 4px rgba(0,0,0,0.8);
  opacity: 0;
  transition: opacity 0.3s;
  pointer-events: none;
}

.cf-win-display.show {
  opacity: 1;
  animation: cfWinPulse 0.5s ease;
}

@keyframes cfWinPulse {
  0% { transform: translate(-50%, -50%) scale(0.5); }
  50% { transform: translate(-50%, -50%) scale(1.2); }
  100% { transform: translate(-50%, -50%) scale(1); }
}

.cf-bet-panel {
  background: rgba(0,0,0,0.3);
  border-radius: 8px;
  padding: 10px;
}

.cf-bet-lines {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  margin-bottom: 10px;
}

.cf-bet-line {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 12px;
  color: #fff;
}

.cf-line-label {
  min-width: 50px;
}

.cf-line-btn {
  padding: 4px 8px;
  font-size: 12px;
  color: #fff;
  background: rgba(255,255,255,0.15);
  border: 1px solid rgba(255,255,255,0.2);
  border-radius: 4px;
  cursor: pointer;
}

.cf-line-btn.active {
  background: #FF6F00;
  border-color: #FF8F00;
  font-weight: bold;
}

.cf-bet-actions {
  display: flex;
  gap: 10px;
  justify-content: center;
}

.cf-action-btn {
  padding: 12px 24px;
  font-size: 16px;
  font-weight: bold;
  color: #fff;
  border: none;
  border-radius: 8px;
  cursor: pointer;
}

.cf-betmax {
  background: linear-gradient(135deg, #1565C0, #1976D2);
}

.cf-spin {
  background: linear-gradient(135deg, #FF6F00, #FF8F00);
  font-size: 20px;
}

.cf-action-btn:hover { transform: scale(1.05); }
.cf-action-btn:active { transform: scale(0.95); }

.cf-bonus-panel {
  text-align: center;
  padding: 20px;
  color: #fff;
}

.cf-bonus-grid {
  display: grid;
  grid-template-columns: repeat(3, 70px);
  gap: 10px;
  justify-content: center;
  margin: 15px 0;
}

.cf-bonus-item {
  width: 70px;
  height: 70px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 32px;
  background: radial-gradient(circle, #FF6F00, #BF360C);
  border-radius: 50%;
  cursor: pointer;
  color: #fff;
}

.cf-bonus-item:hover {
  transform: scale(1.1);
  box-shadow: 0 0 12px #FF6F00;
}

.cf-bonus-reward {
  display: inline-block;
  margin: 2px 4px;
  padding: 4px 10px;
  background: #4CAF50;
  border-radius: 12px;
  font-weight: bold;
}

.cf-result-panel {
  text-align: center;
  padding: 20px;
}

.cf-result-box {
  background: rgba(255,255,255,0.1);
  border-radius: 12px;
  padding: 20px;
  color: #fff;
}

.cf-net.positive { color: #66BB6A; font-weight: bold; font-size: 20px; }
.cf-net.negative { color: #EF5350; font-weight: bold; font-size: 20px; }

.cf-notification {
  position: absolute;
  top: 60px;
  left: 50%;
  transform: translateX(-50%);
  background: rgba(0,0,0,0.8);
  color: #fff;
  padding: 8px 20px;
  border-radius: 20px;
  border: 2px solid #4CAF50;
  font-size: 14px;
  font-weight: bold;
  z-index: 100;
  animation: cfFadeIn 0.3s ease;
}

@keyframes cfFadeIn {
  from { opacity: 0; transform: translateX(-50%) translateY(-10px); }
  to { opacity: 1; transform: translateX(-50%) translateY(0); }
}

@media (max-width: 520px) {
  .cf-cell { width: 60px; height: 60px; font-size: 30px; }
  .cf-info-bar { font-size: 11px; gap: 4px; }
  .cf-bet-lines { grid-template-columns: 1fr; }
  .cf-bonus-grid { grid-template-columns: repeat(3, 56px); }
  .cf-bonus-item { width: 56px; height: 56px; font-size: 24px; }
}
