/* 中世纪风格赌坊游戏主样式 */

/* CSS 变量定义 */
:root {
  /* 颜色主题 */
  --primary-gold: #d4af37;
  --secondary-gold: #b8941f;
  --dark-gold: #9a7c1a;
  --bronze: #cd7f32;
  --dark-bronze: #8b4513;
  
  --bg-dark: #1a1a1a;
  --bg-darker: #0f0f0f;
  --bg-wood: #3e2723;
  --bg-wood-light: #5d4037;
  
  --text-light: #f5f5dc;
  --text-gold: #ffd700;
  --text-muted: #cccccc;
  --text-dark: #333333;

  --success-green: #4caf50;
  
  --border-gold: #d4af37;
  --border-dark: #444444;
  
  --shadow-gold: 0 0 20px rgba(212, 175, 55, 0.3);
  --shadow-dark: 0 4px 20px rgba(0, 0, 0, 0.5);
  
  /* 字体 */
  --font-title: 'Cinzel', serif;
  --font-body: 'Crimson Text', serif;
  
  /* 间距 */
  --spacing-xs: 0.15rem;
  --spacing-sm: 0.5rem;
  --spacing-md: 1rem;
  --spacing-lg: 1.5rem;
  --spacing-xl: 2rem;
  --spacing-xxl: 3rem;
  
  /* 边框圆角 */
  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 12px;
  
  /* 过渡动画 */
  --transition-fast: 0.2s ease;
  --transition-normal: 0.3s ease;
  --transition-slow: 0.5s ease;
}

/* 重置样式 */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-body);
  background: linear-gradient(135deg, var(--bg-darker) 0%, var(--bg-dark) 50%, var(--bg-wood) 100%);
  color: var(--text-light);
  line-height: 1.6;
  min-height: 100vh;
  position: relative;
  overflow-x: hidden;
}

/* 背景装饰 */
.background-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: 
    radial-gradient(circle at 20% 20%, rgba(212, 175, 55, 0.1) 0%, transparent 50%),
    radial-gradient(circle at 80% 80%, rgba(205, 127, 50, 0.1) 0%, transparent 50%),
    url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" width="100" height="100" viewBox="0 0 100 100"><defs><pattern id="wood" x="0" y="0" width="20" height="20" patternUnits="userSpaceOnUse"><rect width="20" height="20" fill="%23654321"/><path d="M0 0L20 20M20 0L0 20" stroke="%23543311" stroke-width="0.5" opacity="0.3"/></pattern></defs><rect width="100" height="100" fill="url(%23wood)"/></svg>');
  background-size: 200px 200px, 300px 300px, 100px 100px;
  opacity: 0.3;
  z-index: -2;
  pointer-events: none;
}

/* 烛光效果 */
.candle-light {
  position: fixed;
  width: 200px;
  height: 200px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 215, 0, 0.2) 0%, transparent 70%);
  z-index: -1;
  pointer-events: none;
  animation: flicker 3s ease-in-out infinite alternate;
}

.candle-1 {
  top: 10%;
  left: 10%;
  animation-delay: 0s;
}

.candle-2 {
  top: 20%;
  right: 15%;
  animation-delay: 1s;
}

.candle-3 {
  bottom: 30%;
  left: 20%;
  animation-delay: 2s;
}

@keyframes flicker {
  0%, 100% { opacity: 0.3; transform: scale(1); }
  50% { opacity: 0.5; transform: scale(1.1); }
}

/* 容器布局 */
.container {
  max-width: 1400px;
  margin: 0 auto;
  padding: var(--spacing-md);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* 头部样式 */
.header {
  background: linear-gradient(135deg, var(--bg-wood) 0%, var(--bg-wood-light) 100%);
  border: 2px solid var(--border-gold);
  border-radius: var(--radius-lg);
  padding: var(--spacing-lg);
  margin-bottom: var(--spacing-xl);
  box-shadow: var(--shadow-gold);
  position: relative;
}

.header::before {
  content: '';
  position: absolute;
  top: -2px;
  left: -2px;
  right: -2px;
  bottom: -2px;
  background: linear-gradient(45deg, var(--primary-gold), var(--bronze), var(--primary-gold));
  border-radius: var(--radius-lg);
  z-index: -1;
}

.header-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--spacing-md);
}

.title {
  text-align: center;
}

.title-main {
  display: block;
  font-family: var(--font-title);
  font-size: 2.5rem;
  font-weight: 700;
  color: var(--text-gold);
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
  letter-spacing: 2px;
}

.title-sub {
  display: block;
  font-size: 1.2rem;
  color: var(--text-muted);
  margin-top: var(--spacing-xs);
  font-weight: 400;
}

.user-info {
  display: flex;
  align-items: center;
  gap: var(--spacing-lg);
}

/* 快捷菜单样式 */
.quick-menu {
  position: relative;
}

.btn-icon-only {
  background: transparent;
  border: 2px solid var(--border-gold);
  color: var(--primary-gold);
  padding: var(--spacing-sm);
  border-radius: 50%;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition-normal);
  cursor: pointer;
}

.btn-icon-only:hover {
  background: var(--primary-gold);
  color: var(--bg-dark);
  box-shadow: var(--shadow-gold);
  transform: scale(1.1);
}

.menu-icon {
  font-size: 18px;
  animation: sparkle 2s ease-in-out infinite;
}

@keyframes sparkle {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.1); }
}

.quick-menu-dropdown {
  position: absolute;
  top: calc(100% + var(--spacing-sm));
  right: 0;
  background: var(--bg-wood);
  border: 2px solid var(--border-gold);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-dark);
  min-width: 180px;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-10px);
  transition: all var(--transition-normal);
  z-index: 1000;
}

.quick-menu-dropdown.show {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.quick-menu-item {
  display: flex;
  align-items: center;
  gap: var(--spacing-sm);
  padding: var(--spacing-md);
  color: var(--text-light);
  cursor: pointer;
  transition: all var(--transition-fast);
  border-bottom: 1px solid rgba(212, 175, 55, 0.2);
}

.quick-menu-item:last-child {
  border-bottom: none;
}

.quick-menu-item:hover {
  background: rgba(212, 175, 55, 0.1);
  color: var(--primary-gold);
}

.menu-item-icon {
  font-size: 16px;
  width: 20px;
  text-align: center;
}

.menu-item-text {
  font-family: var(--font-title);
  font-weight: 600;
}

.balance-display {
  background: rgba(0, 0, 0, 0.3);
  padding: var(--spacing-sm) var(--spacing-md);
  border-radius: var(--radius-md);
  border: 1px solid var(--border-gold);
  display: flex;
  align-items: center;
  gap: var(--spacing-sm);
}

.balance-label {
  font-size: 0.9rem;
  color: var(--text-muted);
}

.balance-amount {
  font-size: 1.5rem;
  font-weight: 600;
  color: var(--text-gold);
  font-family: var(--font-title);
}

.balance-currency {
  font-size: 1.2rem;
  color: var(--primary-gold);
  font-weight: 600;
}

/* 主要内容区域 */
.main-content {
  display: grid;
  grid-template-columns: 1fr 350px;
  gap: var(--spacing-xl);
  flex: 1;
}

/* 游戏区域 */
.game-section {
  background: linear-gradient(135deg, var(--bg-wood) 0%, var(--bg-wood-light) 100%);
  border: 2px solid var(--border-gold);
  border-radius: var(--radius-lg);
  padding: var(--spacing-xl);
  box-shadow: var(--shadow-dark);
}

/* 顶部信息区 */
.game-info-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: var(--spacing-xl);
  padding: var(--spacing-lg);
  background: rgba(0, 0, 0, 0.2);
  border-radius: var(--radius-md);
  border: 1px solid var(--border-gold);
}

.round-info, .countdown-info {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.round-number {
  display: flex;
  align-items: baseline;
  justify-content: center;
  gap: var(--spacing-sm);
}

.round-label {
  font-size: 0.9rem;
  color: var(--text-muted);
  flex-shrink: 0;
}

.round-value {
  font-family: var(--font-title);
  font-size: 1.8rem;
  color: var(--text-gold);
  font-weight: 600;
  text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.5);
}

.section-title {
  font-family: var(--font-title);
  font-size: 2rem;
  color: var(--text-gold);
  text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.5);
}

.countdown-display {
  display: flex;
  align-items: baseline;
  justify-content: center;
  gap: var(--spacing-sm);
}

.countdown-label {
  font-size: 0.9rem;
  color: var(--text-muted);
  flex-shrink: 0;
}

.countdown-timer {
  font-family: var(--font-title);
  font-size: 2rem;
  color: var(--primary-gold);
  font-weight: 600;
  text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.5);
}

/* 数字选择区域 */
.number-selection {
  margin-bottom: var(--spacing-xl);
  position: relative;
}

.number-selection::before {
  content: '';
  position: absolute;
  top: -10px;
  left: -10px;
  right: -10px;
  bottom: -10px;
  background:
    linear-gradient(45deg, transparent 30%, rgba(212, 175, 55, 0.1) 50%, transparent 70%),
    radial-gradient(circle at center, rgba(205, 127, 50, 0.05) 0%, transparent 70%);
  border-radius: var(--radius-lg);
  z-index: -1;
  pointer-events: none;
}

.selection-title {
  font-size: 1.3rem;
  color: var(--text-light);
  margin-bottom: var(--spacing-lg);
  text-align: center;
}

/* 数字组布局 */
.number-groups {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--spacing-lg);
  margin-bottom: var(--spacing-lg);
}

.number-group {
  background: rgba(0, 0, 0, 0.2);
  border: 1px solid var(--border-dark);
  border-radius: var(--radius-md);
  padding: var(--spacing-md);
  transition: all var(--transition-normal);
}

.number-group:hover {
  border-color: var(--primary-gold);
  box-shadow: var(--shadow-gold);
}

.group-header {
  text-align: center;
  margin-bottom: var(--spacing-sm);
  padding-bottom: var(--spacing-xs);
  border-bottom: 1px solid var(--border-dark);
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: space-between;
  gap: var(--spacing-sm);
}

.group-name {
  font-family: var(--font-title);
  font-size: 1rem;
  color: var(--text-gold);
  font-weight: 600;
  flex-shrink: 0;
  text-align: left;
}

/* 快速选择按钮 */
.quick-select {
  display: flex !important;
  justify-content: flex-end;
  flex-wrap: nowrap;
  margin-top: 0;
  visibility: visible !important;
}

.quick-btn {
  width: 32px;
  height: 32px;
  padding: 0;
  font-size: 1 rem;
  background: linear-gradient(135deg, #ffffff 0%, #2a2a2a 100%);
  color: #4a4a4a;
  border: 1px solid #666;
  border-radius: 50%;
  cursor: pointer;
  transition: all 0.2s ease;
  font-family: var(--font-title);
  display: flex !important;
  align-items: center;
  justify-content: center;
  visibility: visible !important;
  opacity: 1 !important;
  font-weight: 600;
  line-height: 1;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
}

.quick-btn:hover {
  background: linear-gradient(135deg, var(--primary-gold) 0%, #b8860b 100%);
  color: var(--bg-dark);
  border-color: var(--text-gold);
  transform: scale(1.1);
  box-shadow: 0 2px 6px rgba(212, 175, 55, 0.4);
}

.quick-btn:active {
  transform: scale(0.9);
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
}

.quick-btn.active {
  background: linear-gradient(135deg, var(--primary-gold) 0%, #b8860b 100%);
  color: var(--bg-dark);
  border-color: var(--text-gold);
  box-shadow: 0 0 8px rgba(212, 175, 55, 0.6);
}

.group-numbers {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: var(--spacing-xs);
  justify-items: end; /* 每个单元格内容靠右 */
}

/* 数字圆圈样式 */
.number-circle {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: #dc3545;
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.9rem;
  font-weight: 600;
  font-family: var(--font-title);
  cursor: pointer;
  transition: all var(--transition-normal);
  border: 2px solid transparent;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.number-circle:hover {
  transform: scale(1.1);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.4);
  border-color: var(--primary-gold);
}

.number-circle.selected {
  background: var(--primary-gold);
  color: var(--bg-dark);
  border-color: var(--text-gold);
  transform: scale(1.15);
  box-shadow: var(--shadow-gold);
}

.number-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: var(--spacing-md);
  margin-bottom: var(--spacing-lg);
}

.number-btn {
  aspect-ratio: 1;
  background: linear-gradient(135deg, var(--bg-dark) 0%, var(--bg-darker) 100%);
  border: 2px solid var(--border-dark);
  border-radius: var(--radius-md);
  color: var(--text-light);
  font-size: 1.5rem;
  font-weight: 600;
  font-family: var(--font-title);
  cursor: pointer;
  transition: all var(--transition-normal);
  position: relative;
  overflow: hidden;
}

.number-btn::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
  transition: left var(--transition-normal);
}

.number-btn:hover {
  border-color: var(--primary-gold);
  box-shadow: var(--shadow-gold);
  transform: translateY(-2px);
}

.number-btn:hover::before {
  left: 100%;
}

.number-btn.selected {
  background: linear-gradient(135deg, var(--primary-gold) 0%, var(--dark-gold) 100%);
  border-color: var(--text-gold);
  color: var(--bg-dark);
  box-shadow: var(--shadow-gold);
  transform: scale(1.05);
}

.selected-display {
  text-align: center;
  padding: var(--spacing-md);
  background: rgba(0, 0, 0, 0.3);
  border-radius: var(--radius-md);
  border: 1px solid var(--border-dark);
}

.selected-label {
  color: var(--text-muted);
  margin-right: var(--spacing-sm);
}

.selected-numbers {
  color: var(--text-gold);
  font-weight: 600;
  font-family: var(--font-title);
}

/* 下注区域 */
.betting-section {
  background: rgba(0, 0, 0, 0.2);
  padding: var(--spacing-xl);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-gold);
}

/* 下注汇总区域 */
.bet-summary {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: var(--spacing-lg);
}

.bet-stats {
  display: flex;
  gap: var(--spacing-lg);
  flex: 1;
}

.stat-item {
  display: flex;
  align-items: center;
  gap: var(--spacing-sm);
}

.stat-label {
  color: var(--text-muted);
  font-size: 0.9rem;
}

.stat-value {
  color: var(--text-gold);
  font-weight: 600;
  font-family: var(--font-title);
  display: flex;
  align-items: center;
  gap: var(--spacing-xs);
}

/* 潜在赔付特殊样式 */
.potential-payout {
  color: var(--success-green);
  text-shadow: 0 0 8px rgba(76, 175, 80, 0.3);
  animation: pulse-glow 2s ease-in-out infinite;
}

@keyframes pulse-glow {
  0%, 100% {
    text-shadow: 0 0 8px rgba(76, 175, 80, 0.3);
    transform: scale(1);
  }
  50% {
    text-shadow: 0 0 12px rgba(76, 175, 80, 0.5);
    transform: scale(1.02);
  }
}

.bet-input-small {
  width: 80px;
  padding: var(--spacing-xs) var(--spacing-sm);
  background: var(--bg-dark);
  border: 1px solid var(--border-dark);
  border-radius: var(--radius-sm);
  color: var(--text-light);
  font-size: 0.9rem;
  text-align: center;
}

.bet-input-small:focus {
  outline: none;
  border-color: var(--primary-gold);
  box-shadow: 0 0 0 2px rgba(212, 175, 55, 0.2);
}

.currency {
  color: var(--primary-gold);
  font-size: 0.9rem;
}

.bet-actions {
  display: flex;
  gap: var(--spacing-md);
  align-items: center;
}

.bet-input-group {
  margin-bottom: var(--spacing-lg);
}

.bet-label {
  display: block;
  color: var(--text-light);
  margin-bottom: var(--spacing-sm);
  font-weight: 600;
}

.bet-input-wrapper {
  position: relative;
  display: flex;
  align-items: center;
}

.bet-input {
  flex: 1;
  padding: var(--spacing-md);
  background: var(--bg-dark);
  border: 2px solid var(--border-dark);
  border-radius: var(--radius-md);
  color: var(--text-light);
  font-size: 1.2rem;
  font-family: var(--font-title);
  transition: border-color var(--transition-normal);
}

.bet-input:focus {
  outline: none;
  border-color: var(--primary-gold);
  box-shadow: var(--shadow-gold);
}

.bet-currency {
  position: absolute;
  right: var(--spacing-md);
  color: var(--primary-gold);
  font-weight: 600;
  pointer-events: none;
}

.bet-info {
  display: flex;
  justify-content: space-between;
  margin-bottom: var(--spacing-lg);
  padding: var(--spacing-md);
  background: rgba(0, 0, 0, 0.3);
  border-radius: var(--radius-md);
}

.bet-info-item {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.info-label {
  font-size: 0.9rem;
  color: var(--text-muted);
  margin-bottom: var(--spacing-xs);
}

.info-value {
  font-size: 1.2rem;
  color: var(--text-gold);
  font-weight: 600;
  font-family: var(--font-title);
}

/* 按钮样式 */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--spacing-sm);
  padding: var(--spacing-sm) var(--spacing-md);
  border: none;
  border-radius: var(--radius-md);
  font-family: var(--font-body);
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  transition: all var(--transition-normal);
  position: relative;
  overflow: hidden;
}

.btn::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
  transition: left var(--transition-normal);
}

.btn:hover::before {
  left: 100%;
}

.btn-primary {
  background: linear-gradient(135deg, var(--primary-gold) 0%, var(--dark-gold) 100%);
  color: var(--bg-dark);
  border: 2px solid var(--text-gold);
}

.btn-primary:hover {
  background: linear-gradient(135deg, var(--text-gold) 0%, var(--primary-gold) 100%);
  box-shadow: var(--shadow-gold);
  transform: translateY(-2px);
}

.btn-secondary {
  background: linear-gradient(135deg, var(--bg-dark) 0%, var(--bg-darker) 100%);
  color: var(--text-light);
  border: 2px solid var(--border-dark);
}

.btn-secondary:hover {
  border-color: var(--primary-gold);
  box-shadow: var(--shadow-gold);
}

.btn-outline {
  background: transparent;
  color: var(--text-light);
  border: 2px solid var(--border-gold);
}

.btn-outline:hover {
  background: var(--primary-gold);
  color: var(--bg-dark);
}

.btn-large {
  padding: var(--spacing-md) var(--spacing-xl);
  font-size: 1.2rem;
}

.btn-full {
  width: 100%;
}

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

.btn:disabled:hover {
  box-shadow: none;
}

.btn-text {
  flex: 1;
}

.btn-icon {
  font-size: 1.2em;
}

/* 更多按钮样式 */
.btn-more {
  background: transparent;
  border: none;
  color: var(--text-muted);
  padding: var(--spacing-xs);
  margin-left: var(--spacing-sm);
  border-radius: 50%;
  width: 24px;
  height: 24px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition-fast);
  cursor: pointer;
}

.btn-more:hover {
  background: rgba(212, 175, 55, 0.1);
  color: var(--primary-gold);
  transform: scale(1.1);
}

.more-dots {
  font-size: 16px;
  font-weight: bold;
  line-height: 1;
  letter-spacing: 1px;
}

/* 侧边栏标题样式优化 */
.sidebar-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: var(--spacing-md);
}

/* 侧边栏样式 */
.sidebar {
  display: flex;
  flex-direction: column;
  gap: var(--spacing-xl);
}

.sidebar section {
  background: linear-gradient(135deg, var(--bg-wood) 0%, var(--bg-wood-light) 100%);
  border: 2px solid var(--border-gold);
  border-radius: var(--radius-lg);
  padding: var(--spacing-lg);
  box-shadow: var(--shadow-dark);
}

.sidebar-title {
  font-family: var(--font-title);
  font-size: 1.3rem;
  color: var(--text-gold);
  margin-bottom: var(--spacing-md);
  text-align: center;
  border-bottom: 1px solid var(--border-gold);
  padding-bottom: var(--spacing-sm);
}

/* 最新开奖样式 */
.results-list {
  max-height: 250px;
  overflow-y: auto;
  margin-bottom: var(--spacing-sm);
}

.history-item {
  background: rgba(0, 0, 0, 0.3);
  padding: 10px 12px;
  border-radius: var(--radius-md);
  margin-bottom: 8px;
  border: 1px solid var(--border-dark);
  transition: all var(--transition-normal);
}

.history-item:hover {
  border-color: var(--primary-gold);
  box-shadow: var(--shadow-gold);
}

.round-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 6px;
}

.round-number {
  font-weight: 600;
  color: var(--text-gold);
  font-size: 14px;
}

.round-time {
  font-size: 11px;
  color: var(--text-muted);
  opacity: 0.8;
}

.winning-numbers {
  display: block;
  font-family: var(--font-title);
  color: var(--text-light);
}

/* 快捷操作样式 */
.action-buttons {
  display: flex;
  flex-direction: column;
  gap: var(--spacing-sm);
}

/* 模态框样式 */
.modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.8);
  z-index: 1000;
  backdrop-filter: blur(5px);
}

.modal.active {
  display: flex;
  align-items: center;
  justify-content: center;
  animation: fadeIn var(--transition-normal);
}

.modal-content {
  background: linear-gradient(135deg, var(--bg-wood) 0%, var(--bg-wood-light) 100%);
  border: 2px solid var(--border-gold);
  border-radius: var(--radius-lg);
  max-width: 500px;
  width: 90%;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: var(--shadow-gold);
  animation: slideIn var(--transition-normal);
}

.modal-large {
  max-width: 800px;
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: var(--spacing-lg);
  border-bottom: 1px solid var(--border-gold);
}

.modal-title {
  font-family: var(--font-title);
  font-size: 1.5rem;
  color: var(--text-gold);
}

.modal-close {
  background: none;
  border: none;
  color: var(--text-light);
  font-size: 2rem;
  cursor: pointer;
  padding: 0;
  width: 30px;
  height: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  transition: all var(--transition-normal);
}

.modal-close:hover {
  background: var(--primary-gold);
  color: var(--bg-dark);
}

.modal-body {
  padding: var(--spacing-lg);
}

.modal-footer {
  display: flex;
  justify-content: flex-end;
  gap: var(--spacing-md);
  padding: var(--spacing-lg);
  border-top: 1px solid var(--border-gold);
}

/* 表单样式 */
.form-group {
  margin-bottom: var(--spacing-lg);
}

.form-label {
  display: block;
  color: var(--text-light);
  margin-bottom: var(--spacing-sm);
  font-weight: 600;
}

.form-input {
  width: 100%;
  padding: var(--spacing-md);
  background: var(--bg-dark);
  border: 2px solid var(--border-dark);
  border-radius: var(--radius-md);
  color: var(--text-light);
  font-size: 1rem;
  transition: border-color var(--transition-normal);
}

.form-input:focus {
  outline: none;
  border-color: var(--primary-gold);
  box-shadow: var(--shadow-gold);
}

/* 选项卡样式 */
.tabs {
  display: flex;
  border-bottom: 1px solid var(--border-gold);
  margin-bottom: var(--spacing-lg);
}

.tab-btn {
  flex: 1;
  padding: var(--spacing-md);
  background: transparent;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  transition: all var(--transition-normal);
  border-bottom: 2px solid transparent;
}

.tab-btn.active,
.tab-btn:hover {
  color: var(--text-gold);
  border-bottom-color: var(--primary-gold);
}

.tab-content {
  min-height: 200px;
}

.tab-pane {
  display: none;
}

.tab-pane.active {
  display: block;
}

/* 消息提示样式 */
.toast-container {
  position: fixed;
  top: var(--spacing-lg);
  right: var(--spacing-lg);
  z-index: 2000;
  display: flex;
  flex-direction: column;
  gap: var(--spacing-sm);
}

.toast {
  background: var(--bg-wood);
  border: 2px solid var(--border-gold);
  border-radius: var(--radius-md);
  padding: var(--spacing-md);
  color: var(--text-light);
  box-shadow: var(--shadow-dark);
  animation: slideInRight var(--transition-normal);
  max-width: 300px;
}

.toast.success {
  border-color: #4caf50;
  background: linear-gradient(135deg, #2e7d32 0%, #388e3c 100%);
}

.toast.error {
  border-color: #f44336;
  background: linear-gradient(135deg, #c62828 0%, #d32f2f 100%);
}

.toast.warning {
  border-color: #ff9800;
  background: linear-gradient(135deg, #ef6c00 0%, #f57c00 100%);
}

/* 动画 */
@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

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

@keyframes slideInRight {
  from { transform: translateX(100%); opacity: 0; }
  to { transform: translateX(0); opacity: 1; }
}

/* 响应式设计 */
@media (max-width: 1200px) {
  .main-content {
    grid-template-columns: 1fr;
    gap: var(--spacing-lg);
  }

  .sidebar {
    order: -1;
  }

  .number-groups {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .container {
    padding: var(--spacing-sm);
  }

  .header-content {
    flex-direction: column;
    text-align: center;
  }

  /* 快捷菜单移动端优化 */
  .user-info {
    gap: var(--spacing-md);
  }

  .quick-menu-dropdown {
    right: -10px;
    min-width: 160px;
  }

  .btn-icon-only {
    width: 36px;
    height: 36px;
  }

  .menu-icon {
    font-size: 16px;
  }

  .game-info-header {
    flex-direction: column;
    gap: var(--spacing-md);
  }

  .title-main {
    font-size: 2rem;
  }

  .number-groups {
    grid-template-columns: 1fr;
    gap: var(--spacing-md);
  }

  .group-numbers {
    grid-template-columns: repeat(5, 1fr);
    gap: var(--spacing-xs);
  }

  .number-circle {
    width: 28px;
    height: 28px;
    font-size: 0.8rem;
  }

  .bet-summary {
    flex-direction: column;
    gap: var(--spacing-md);
  }

  .bet-stats {
    flex-direction: column;
    gap: var(--spacing-sm);
  }

  .bet-actions {
    justify-content: center;
  }

  .modal-content {
    width: 95%;
    margin: var(--spacing-sm);
  }
}

@media (max-width: 480px) {
  .title-main {
    font-size: 1.5rem;
  }

  .round-value {
    font-size: 1.4rem;
  }

  .round-number {
    gap: var(--spacing-xs);
  }

  .round-label {
    font-size: 0.8rem;
  }

  .countdown-timer {
    font-size: 1.6rem;
  }

  .countdown-display {
    gap: var(--spacing-xs);
  }

  .countdown-label {
    font-size: 0.8rem;
  }

  .group-numbers {
    grid-template-columns: repeat(5, 1fr);
  }

  .number-circle {
    width: 24px;
    height: 24px;
    font-size: 0.7rem;
  }

  .quick-btn {
    width: 16px;
    height: 16px;
    font-size: 0.6rem;
  }

  .quick-select {
    gap: 2px;
  }

  .group-header {
    gap: var(--spacing-xs);
  }

  .group-name {
    font-size: 0.9rem;
  }

  .bet-actions {
    flex-direction: column;
    width: 100%;
  }

  .btn-large {
    width: 100%;
  }
}

/* 投注详情按钮样式 */
.detail-btn {
  background: linear-gradient(45deg, var(--primary-gold), var(--secondary-gold));
  color: var(--text-dark);
  border: none;
  padding: 6px 12px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  font-size: 12px;
  font-weight: bold;
  transition: var(--transition-normal);
  display: inline-flex;
  align-items: center;
  gap: 4px;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.detail-btn:hover {
  background: linear-gradient(45deg, var(--secondary-gold), var(--dark-gold));
  transform: translateY(-1px);
  box-shadow: var(--shadow-gold);
}

.detail-btn:active {
  transform: translateY(0);
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
}

/* 响应式调整 */
@media (max-width: 768px) {
  .detail-btn {
    padding: 4px 8px;
    font-size: 11px;
  }
}

/* 投注记录详情样式 */
.bet-history-container {
  position: relative;
  min-height: 400px;
}

.bet-list-section,
.bet-detail-section {
  width: 100%;
}

.detail-header {
  display: flex;
  align-items: center;
  gap: 15px;
  margin-bottom: 20px;
  padding-bottom: 15px;
  border-bottom: 2px solid var(--border-dark);
}

.back-to-list-btn {
  background: linear-gradient(45deg, var(--bronze), var(--dark-bronze));
  color: var(--text-light);
  border: none;
  padding: 8px 16px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  font-size: 14px;
  font-weight: bold;
  transition: var(--transition-normal);
  display: flex;
  align-items: center;
  gap: 5px;
}

.back-to-list-btn:hover {
  background: linear-gradient(45deg, var(--dark-bronze), var(--bronze));
  transform: translateY(-1px);
  box-shadow: var(--shadow-dark);
}

.detail-title {
  color: var(--text-gold);
  font-size: 20px;
  margin: 0;
  font-family: var(--font-title);
}

.bet-detail-card {
  background: rgba(255, 255, 255, 0.05);
  border-radius: var(--radius-lg);
  padding: 20px;
  border: 1px solid var(--border-dark);
}

.detail-section {
  margin-bottom: 25px;
  padding: 15px;
  background: rgba(0, 0, 0, 0.2);
  border-radius: var(--radius-md);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.detail-section:last-child {
  margin-bottom: 0;
}

.section-title {
  color: var(--text-gold);
  font-size: 16px;
  margin-bottom: 15px;
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: bold;
}

.section-icon {
  font-size: 18px;
}

.detail-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 12px;
}

.detail-item {
  background: rgba(255, 255, 255, 0.05);
  padding: 12px;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.detail-label {
  color: var(--text-muted);
  font-size: 12px;
  margin-bottom: 4px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.detail-value {
  color: var(--text-light);
  font-size: 14px;
  font-weight: bold;
}

/* 实际赔付高亮样式 */
.detail-value.payout-highlight {
  color: var(--primary-gold);
  background: linear-gradient(135deg, rgba(255, 215, 0, 0.1), rgba(255, 215, 0, 0.2));
  border: 1px solid var(--primary-gold);
  border-radius: 6px;
  padding: 8px 12px;
  font-size: 16px;
  font-weight: 700;
  text-shadow: 0 0 8px rgba(255, 215, 0, 0.3);
  box-shadow: 0 0 15px rgba(255, 215, 0, 0.2);
  animation: payout-glow 2s ease-in-out infinite;
  position: relative;
  overflow: hidden;
}

.detail-value.payout-highlight::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: linear-gradient(45deg, transparent, rgba(255, 255, 255, 0.1), transparent);
  transform: rotate(45deg);
  animation: shimmer 3s ease-in-out infinite;
}

@keyframes payout-glow {
  0%, 100% {
    box-shadow: 0 0 15px rgba(255, 215, 0, 0.2);
    text-shadow: 0 0 8px rgba(255, 215, 0, 0.3);
  }
  50% {
    box-shadow: 0 0 25px rgba(255, 215, 0, 0.4);
    text-shadow: 0 0 12px rgba(255, 215, 0, 0.5);
  }
}

@keyframes shimmer {
  0% {
    transform: translateX(-100%) translateY(-100%) rotate(45deg);
  }
  50% {
    transform: translateX(100%) translateY(100%) rotate(45deg);
  }
  100% {
    transform: translateX(-100%) translateY(-100%) rotate(45deg);
  }
}

.detail-value.positive {
  color: #4caf50;
}

.detail-value.negative {
  color: #f44336;
}

.detail-value.neutral {
  color: #ffc107;
}

.winner-badge {
  background: linear-gradient(45deg, var(--primary-gold), var(--secondary-gold));
  color: var(--text-dark);
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: bold;
  margin-left: 10px;
}

.bet-numbers-display {
  margin-bottom: 10px;
}

.bet-description {
  color: var(--text-muted);
  font-size: 14px;
  line-height: 1.4;
  padding: 10px;
  background: rgba(0, 0, 0, 0.2);
  border-radius: var(--radius-sm);
  border-left: 3px solid var(--primary-gold);
}

.winning-numbers-display {
  margin-bottom: 10px;
}

.draw-time {
  color: var(--text-muted);
  font-size: 13px;
  text-align: center;
  padding: 8px;
  background: rgba(0, 0, 0, 0.2);
  border-radius: var(--radius-sm);
}

.bet-analysis,
.financial-analysis {
  background: rgba(0, 0, 0, 0.3);
  padding: 12px;
  border-radius: var(--radius-sm);
  margin-top: 15px;
}

.analysis-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 6px;
  color: var(--text-light);
  font-size: 13px;
}

.analysis-item:last-child {
  margin-bottom: 0;
}

.analysis-item span:first-child {
  color: var(--text-muted);
}

.analysis-item span:last-child {
  font-weight: bold;
}

.loading-state,
.error-state {
  text-align: center;
  padding: 40px 20px;
  color: var(--text-light);
}

.loading-spinner {
  width: 40px;
  height: 40px;
  border: 4px solid rgba(255, 255, 255, 0.1);
  border-left: 4px solid var(--primary-gold);
  border-radius: 50%;
  animation: spin 1s linear infinite;
  margin: 0 auto 15px;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

.retry-btn {
  background: linear-gradient(45deg, var(--primary-gold), var(--secondary-gold));
  color: var(--text-dark);
  border: none;
  padding: 8px 16px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  font-size: 14px;
  font-weight: bold;
  margin-top: 10px;
  transition: var(--transition-normal);
}

.retry-btn:hover {
  background: linear-gradient(45deg, var(--secondary-gold), var(--dark-gold));
  transform: translateY(-1px);
}

/* 紧凑版投注详情样式 */
.bet-detail-card-compact {
  background: rgba(255, 255, 255, 0.05);
  border-radius: var(--radius-lg);
  padding: 15px;
  border: 1px solid var(--border-dark);
}

.detail-header-compact {
  margin-bottom: 15px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--border-dark);
}

.detail-title-compact {
  color: var(--text-gold);
  font-size: 18px;
  margin: 0 0 5px 0;
  font-family: var(--font-title);
}

.detail-meta {
  color: var(--text-muted);
  font-size: 12px;
  line-height: 1.4;
}

.winner-badge-small {
  background: linear-gradient(45deg, var(--primary-gold), var(--secondary-gold));
  color: var(--text-dark);
  padding: 2px 8px;
  border-radius: 12px;
  font-size: 10px;
  font-weight: bold;
  margin-left: 8px;
}

.detail-section-compact {
  margin-bottom: 15px;
  padding: 10px;
  background: rgba(0, 0, 0, 0.2);
  border-radius: var(--radius-md);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.section-title-compact {
  color: var(--text-gold);
  font-size: 14px;
  margin-bottom: 8px;
  font-weight: bold;
}

.draw-time-compact {
  color: var(--text-muted);
  font-size: 12px;
  text-align: center;
  padding: 5px;
  background: rgba(0, 0, 0, 0.2);
  border-radius: var(--radius-sm);
  margin-top: 8px;
}

/* 紧凑版中奖统计 */
.winning-stats-compact {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 8px;
  padding: 10px;
  margin: 10px 0;
}

.winning-stats-compact.has-winnings {
  background: rgba(76, 175, 80, 0.1);
  border-color: rgba(76, 175, 80, 0.3);
}

.stats-row {
  display: flex;
  flex-wrap: wrap;
  gap: 15px;
  justify-content: space-between;
}

.stats-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 60px;
}

.stats-label {
  font-size: 11px;
  color: var(--text-muted);
  margin-bottom: 2px;
}

.stats-value {
  font-size: 14px;
  font-weight: bold;
  color: var(--text-light);
}

.stats-value.success {
  color: #4CAF50;
}

.stats-value.highlight {
  color: var(--primary-gold);
}

.winning-groups {
  margin-top: 8px;
  font-size: 12px;
  color: rgba(255, 255, 255, 0.8);
  text-align: center;
  padding-top: 8px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

/* 紧凑版财务信息 */
.financial-row {
  display: flex;
  flex-wrap: wrap;
  gap: 15px;
  justify-content: space-between;
}

.financial-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 80px;
}

.financial-label {
  font-size: 11px;
  color: var(--text-muted);
  margin-bottom: 2px;
}

.financial-value {
  font-size: 14px;
  font-weight: bold;
  color: var(--text-light);
}

.financial-value.success {
  color: #4CAF50;
}

.financial-value.positive {
  color: #4CAF50;
}

.financial-value.negative {
  color: #f44336;
}

.financial-value.highlight {
  color: var(--primary-gold);
}

/* 简洁版实际赔付 */
.payout-simple {
  background: linear-gradient(135deg, #4CAF50, #45a049);
  color: white;
  padding: 12px 20px;
  border-radius: 8px;
  text-align: center;
  margin: 10px 0;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
}

.payout-label {
  font-size: 14px;
  font-weight: normal;
}

.payout-amount {
  font-size: 18px;
  font-weight: bold;
}

/* 响应式调整 */
@media (max-width: 768px) {
  .detail-grid {
    grid-template-columns: 1fr;
  }

  .detail-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
  }

  .bet-detail-card {
    padding: 15px;
  }

  .detail-section {
    padding: 12px;
  }

  .stats-row,
  .financial-row {
    flex-direction: column;
    gap: 8px;
  }

  .stats-item,
  .financial-item {
    flex-direction: row;
    justify-content: space-between;
    min-width: auto;
    width: 100%;
  }
}

/* 投注记录表格样式 */
.data-table {
  width: 100%;
  border-collapse: collapse;
  background: rgba(255, 255, 255, 0.05);
  border-radius: var(--radius-md);
  overflow: hidden;
  border: 1px solid var(--border-dark);
}

.data-table th,
.data-table td {
  padding: 12px 15px;
  text-align: left;
  border-bottom: 1px solid var(--border-dark);
}

.data-table th {
  background: rgba(0, 0, 0, 0.3);
  color: var(--text-gold);
  font-weight: bold;
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.data-table td {
  color: var(--text-light);
  font-size: 14px;
}

.data-table tr:hover {
  background: rgba(255, 255, 255, 0.1);
}

/* 中奖记录高亮样式 */
.data-table tr.winner {
  background: linear-gradient(90deg, rgba(76, 175, 80, 0.15), rgba(139, 195, 74, 0.1));
  border-left: 4px solid #4caf50;
  box-shadow: inset 0 0 20px rgba(76, 175, 80, 0.1);
  position: relative;
  animation: winnerGlow 2s ease-in-out infinite alternate;
}

/* 移除奖杯图标显示 */
.data-table tr.winner::before {
  display: none;
}

.data-table tr.winner td:first-child {
  padding-left: 15px;
}

.data-table tr.winner:hover {
  background: linear-gradient(90deg, rgba(76, 175, 80, 0.25), rgba(139, 195, 74, 0.15));
  box-shadow: inset 0 0 30px rgba(76, 175, 80, 0.2);
}

/* 中奖状态标签样式 */
.data-table .status {
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: bold;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  display: inline-block;
}

.data-table tr.winner .status.settled {
  background: linear-gradient(45deg, #4caf50, #45a049);
  color: white;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
  box-shadow: 0 2px 8px rgba(76, 175, 80, 0.3);
}

.data-table tr:not(.winner) .status.settled {
  background: linear-gradient(45deg, #757575, #616161);
  color: white;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

.data-table .status.pending {
  background: linear-gradient(45deg, #ff9800, #f57c00);
  color: white;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

/* 收益金额高亮 */
.data-table tr.winner .positive {
  color: #4caf50;
  font-weight: bold;
  text-shadow: 0 0 10px rgba(76, 175, 80, 0.5);
  font-size: 15px;
}

.data-table tr.winner .positive::before {
  content: '💰 ';
  margin-right: 4px;
}

/* 动画效果 */
@keyframes winnerGlow {
  0% {
    box-shadow: inset 0 0 20px rgba(76, 175, 80, 0.1);
  }
  100% {
    box-shadow: inset 0 0 30px rgba(76, 175, 80, 0.2);
  }
}

/* 奖杯弹跳动画已移除 */

/* 表格容器 */
.table-container {
  overflow-x: auto;
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-dark);
}

/* 响应式调整 */
@media (max-width: 768px) {
  .data-table th,
  .data-table td {
    padding: 8px 10px;
    font-size: 12px;
  }

  .data-table tr.winner td:first-child {
    padding-left: 10px;
  }
}
