body {
  margin: 0;
  padding: 0;
  background: #00000000;
}

.wrapper {
  width: 100%;
  max-width: 100%;
  margin: 0 auto;
  overflow-x: hidden;
}

img {
  display: block;
  width: 100%;
  height: auto;
  transition: opacity 0.3s ease;
}

/* 图片加载状态样式 */
img.loading {
  opacity: 0.5;
  background: linear-gradient(90deg, #f0f0f0 25%, transparent 37%, #f0f0f0 63%);
  background-size: 400% 100%;
  animation: shimmer 1.5s ease-in-out infinite;
}

img.error {
  opacity: 0.3;
  filter: grayscale(100%);
}

@keyframes shimmer {
  0% { background-position: 100% 50%; }
  100% { background-position: -100% 50%; }
}

/* 底部悬浮区域 */
.bottom-fixed {
  position: fixed;
  bottom: -5%;
  left: 0;
  width: 100%;
  display: flex;
  flex-direction: row;
  background: #00000000;
  z-index: 999;
}

/* 两张图横向拼接 */
.bottom-fixed img {
  width: 50%;
  max-width: 500px;
  height: auto;
  cursor: pointer;
}

/* === 弹窗样式 === */
.mask {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.55);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 10000;
  padding: 16px;
  box-sizing: border-box;
}

.modal {
  width: 100%;
  max-width: 380px;
  background: #0b0b0b;
  color: #fff;
  border-radius: 16px;
  padding: 20px 18px;
  position: relative;
  overflow: hidden;
  box-shadow: 0 8px 30px rgba(0,0,0,.5);
}

/* 渐变红蓝浅边框（左红右蓝） */
.modal::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 16px;
  padding: 2px;
  background: linear-gradient(135deg, #ff5252, #448aff);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
          mask-composite: exclude;
  pointer-events: none;
  box-shadow:
    0 0 16px rgba(255,82,82,.25),
    0 0 16px rgba(68,138,255,.25);
}

.modal h3 {
  margin: 0 0 8px;
  font-size: 18px;
  text-align: center;
}

.modal .desc {
  margin: 0 0 14px;
  font-size: 14px;
  opacity: .9;
  text-align: center;
}

.teams {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-bottom: 14px;
}

.team {
  padding: 12px 10px;
  background: #151515;
  border: 1px solid #2b2b2b;
  border-radius: 10px;
  text-align: center;
  user-select: none;
  transition: transform .12s ease, box-shadow .12s ease, border-color .12s ease;
}

#teamA { 
  border-color: rgba(255,100,100,.35); 
}

#teamB { 
  border-color: rgba(100,160,255,.35); 
}

.team.active#teamA {
  border-color: #ff5252;
  box-shadow: 0 0 12px rgba(255,82,82,.55);
  transform: translateY(-2px);
}

.team.active#teamB {
  border-color: #448aff;
  box-shadow: 0 0 12px rgba(68,138,255,.55);
  transform: translateY(-2px);
}

.actions { 
  display: flex; 
  gap: 10px; 
}

.btn {
  flex: 1;
  padding: 10px 12px;
  border-radius: 10px;
  border: none;
  font-size: 14px;
  cursor: pointer;
}

.btn-primary {
  background: linear-gradient(to right, #ff5252, #448aff);
  color: #fff;
  font-weight: 600;
}

.btn-ghost {
  background: #242424;
  color: #ddd;
}

/* 小 loading 点 */
.loading {
  display: inline-block;
  width: 6px; 
  height: 6px;
  border-radius: 50%;
  background: currentColor;
  margin-left: 6px;
  animation: pulse .9s infinite ease-in-out;
  vertical-align: middle;
}

@keyframes pulse {
  0%,100% { opacity:.25; transform: scale(.9); }
  50%     { opacity:1;    transform: scale(1.2); }
}

/* Toast 提示样式 */
.toast {
  position: fixed;
  top: 20px;
  left: 50%;
  transform: translateX(-50%);
  background: rgba(0, 0, 0, 0.8);
  color: white;
  padding: 12px 20px;
  border-radius: 8px;
  font-size: 14px;
  z-index: 10001;
  opacity: 0;
  transition: opacity 0.3s ease;
  max-width: 300px;
  text-align: center;
}

.toast.show {
  opacity: 1;
}

.toast.error {
  background: rgba(255, 82, 82, 0.9);
}

.toast.success {
  background: rgba(76, 175, 80, 0.9);
}

/* 响应式设计 */
@media (min-width: 768px) {
  .wrapper { 
    max-width: 420px; 
  }         
  
  .bottom-fixed {
    width: 420px;                           
    left: 50%;                                 
    transform: translateX(-50%);
    bottom: -5%;                               
  }
  
  .bottom-fixed img { 
    max-width: none;       
  }
}
