/* ===== C端页面增强样式补充 ===== */

/* 弹窗基础样式 */
.modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 9999;
  align-items: center;
  justify-content: center;
}

.modal.show {
  display: flex;
}

.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(5px);
  -webkit-backdrop-filter: blur(5px);
  z-index: 1;
}

.modal-content {
  position: relative;
  width: 90%;
  max-width: 600px;
  max-height: 85vh;
  background: var(--card-bg, #ffffff);
  border-radius: 24px;
  padding: 0;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
  z-index: 2;
  animation: modalSlideUp 0.3s ease;
  overflow: hidden;
}

@keyframes modalSlideUp {
  from {
    opacity: 0;
    transform: translateY(30px) scale(0.95);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 24px 24px 16px;
  border-bottom: 1px solid var(--border-color, rgba(0, 0, 0, 0.1));
}

.modal-title {
  font-size: 20px;
  font-weight: 700;
  color: var(--text-primary);
}

.btn-close {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: none;
  background: var(--gray-100, #f5f5f5);
  color: var(--text-secondary);
  font-size: 24px;
  line-height: 1;
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  justify-content: center;
}

.btn-close:hover {
  background: var(--gray-200, #e5e5e5);
  color: var(--text-primary);
  transform: rotate(90deg);
}

.modal-body {
  padding: 20px 24px 24px;
  overflow-y: auto;
  max-height: calc(85vh - 80px);
}

/* 新增：热度标签 */
.hot-tags {
  position: relative;
  margin: 16px 0 20px;
  padding: 2px 16px;
  overflow: hidden;
  -webkit-mask-image: linear-gradient(
    to right,
    transparent,
    #000 14px,
    #000 calc(100% - 14px),
    transparent
  );
  mask-image: linear-gradient(
    to right,
    transparent,
    #000 14px,
    #000 calc(100% - 14px),
    transparent
  );
}

.hot-tags-track {
  display: grid;
  grid-auto-flow: column;
  grid-template-rows: repeat(2, auto);
  grid-auto-columns: max-content;
  gap: 10px 12px;
  align-items: center;
  width: max-content;
  padding-right: 24px;
  animation: hotTagsMarquee 18s linear infinite;
  will-change: transform;
}

.hot-tag {
  display: inline-flex;
  align-items: center;
  padding: 6px 16px;
  font-size: 13px;
  font-weight: 600;
  border-radius: 24px;
  transition: all 0.3s ease;
  cursor: default;
  position: relative;
  overflow: hidden;
  white-space: nowrap;
  transform: translateX(var(--tag-shift, 0px));
}

.hot-tag:nth-child(even) {
  --tag-shift: 14px;
}

.hot-tag::before {
  content: '🔥';
  margin-right: 6px;
  font-size: 16px;
  animation: flicker 2s infinite;
}

.hot-tag:hover {
  transform: translateX(var(--tag-shift, 0px)) translateY(-2px) scale(1.05);
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.15) !important;
}

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

@keyframes hotTagsMarquee {
  0% {
    transform: translateX(0);
  }
  100% {
    transform: translateX(-50%);
  }
}

@media (prefers-reduced-motion: reduce) {
  .hot-tags-track {
    animation: none;
  }
}

/* 新增：盲盒特性标签 */
.box-features {
  display: flex;
  justify-content: center;
  gap: 16px;
  margin: 16px 0;
  flex-wrap: wrap;
}

.feature-item {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  background: rgba(102, 126, 234, 0.1);
  border-radius: 20px;
  font-size: 13px;
  font-weight: 500;
  color: var(--primary-color);
}

.feature-icon {
  font-weight: 700;
}

/* 新增：价格包装器 */
.box-price-wrapper {
  margin: 20px 0;
}

.box-price {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}

.price-main {
  display: flex;
  align-items: baseline;
  justify-content: center;
  gap: 8px;
}

.price-label {
  display: inline-block;
  padding: 4px 12px;
  background: var(--gradient-gold);
  border-radius: 12px;
  font-size: 12px;
  font-weight: 600;
  color: #ffffff;
  box-shadow: 0 2px 8px rgba(246, 211, 101, 0.4);
}

.price-content {
  display: flex;
  align-items: baseline;
  gap: 4px;
}

.price-original {
  font-size: 14px;
  color: var(--text-light);
  text-decoration: line-through;
}

/* 新增：参与人数 */
.participation-info {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px;
  background: rgba(102, 126, 234, 0.05);
  border-radius: 12px;
  margin: 20px 0;
  font-size: 14px;
  color: var(--text-secondary);
}

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

/* 新增：安全提示 */
.safety-tips {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin-top: 16px;
  font-size: 12px;
  color: var(--success-color);
}

.safety-icon {
  font-size: 14px;
}

/* 增强：按钮样式 */
.btn-draw {
  position: relative;
  width: 100%;
  padding: 18px 32px;
  background: var(--gradient-primary);
  border: none;
  border-radius: 16px;
  color: #ffffff;
  font-size: 18px;
  font-weight: 600;
  cursor: pointer;
  overflow: hidden;
  transition: all 0.3s ease;
  box-shadow: 0 8px 20px rgba(102, 126, 234, 0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.btn-glow {
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.3) 0%, transparent 70%);
  animation: pulse 2s infinite;
}

.btn-icon {
  font-size: 20px;
  animation: bounce 2s infinite;
}

.btn-arrow {
  margin-left: 4px;
  transition: transform 0.3s ease;
}

.btn-primary:hover .btn-arrow {
  transform: translateX(4px);
}

/* 新增：用户评价区 */
.reviews-section {
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  border-radius: 24px;
  padding: 30px;
  box-shadow: var(--shadow-lg);
}

.reviews-carousel {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.review-card {
  padding: 20px;
  background: var(--bg-secondary);
  border-radius: 16px;
  transition: all 0.3s ease;
}

.review-card:hover {
  background: #ffffff;
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.review-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
}

.review-avatar {
  width: 40px;
  height: 40px;
  background: var(--gradient-primary);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  flex-shrink: 0;
}

.review-user {
  flex: 1;
}

.review-name {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 2px;
}

.review-time {
  font-size: 12px;
  color: var(--text-light);
}

.review-stars {
  font-size: 14px;
  color: var(--warning-color);
}

.review-content {
  font-size: 14px;
  line-height: 1.6;
  color: var(--text-secondary);
}

/* 新增：FAQ区域 */
.faq-section {
  margin-top: 24px;
  padding-top: 24px;
  border-top: 1px solid var(--border-color);
}

.faq-title {
  font-size: 16px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 16px;
}

.faq-item {
  margin-bottom: 16px;
}

.faq-question {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 8px;
}

.faq-answer {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.6;
  padding-left: 16px;
}

/* 增强：规则卡片 */
.rule-item {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  padding: 20px;
  background: var(--bg-secondary);
  border-radius: 16px;
  transition: all 0.3s ease;
}

.rule-content {
  flex: 1;
}

.rule-sub {
  font-size: 12px;
  color: var(--text-light);
  margin-top: 4px;
}

/* 增强：页脚 */
.footer {
  text-align: center;
  padding: 40px 0;
  margin-top: 40px;
}

.footer-content {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.footer-text {
  font-size: 14px;
  color: rgba(255, 255, 255, 0.8);
  font-weight: 500;
}

.footer-slogan {
  font-size: 13px;
  color: rgba(255, 255, 255, 0.6);
  font-style: italic;
}

.footer-links {
  margin-top: 8px;
  text-align: center;
}

.footer-links-text {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.6);
  line-height: 1.6;
  margin: 0;
  padding: 0 16px;
}

.footer-link {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.7);
  text-decoration: none;
  transition: color 0.3s ease;
}

.footer-link:hover {
  color: rgba(255, 255, 255, 1);
  text-decoration: underline;
}

.footer-divider {
  color: rgba(255, 255, 255, 0.4);
}

/* 新增：返回顶部按钮 */
.back-to-top {
  position: fixed;
  bottom: 80px;
  right: 20px;
  width: 48px;
  height: 48px;
  background: var(--gradient-primary);
  border: none;
  border-radius: 50%;
  color: #ffffff;
  font-size: 20px;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
  transition: all 0.3s ease;
  opacity: 0;
  visibility: hidden;
  z-index: 999;
}

.back-to-top.show {
  opacity: 1;
  visibility: visible;
}

.back-to-top:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 16px rgba(102, 126, 234, 0.5);
}

.back-to-top:active {
  transform: translateY(0);
}

/* 增强：弹窗图标 */
.modal-icon {
  font-size: 48px;
  margin-bottom: 16px;
  animation: bounce 2s infinite;
}

/* 增强：输入框前缀 */
.modal .input-group {
  position: relative;
}

.input-prefix {
  position: absolute;
  left: 16px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 14px;
  color: var(--text-secondary);
  font-weight: 500;
  pointer-events: none;
}

.input-group .input-field {
  padding-left: 60px;
}

/* 增强：Modal提示 */
.modal-tips {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 12px;
  background: rgba(16, 185, 129, 0.1);
  border-radius: 8px;
  margin: 16px 0;
  font-size: 12px;
  color: var(--success-color);
}

.tips-icon {
  font-size: 14px;
}

/* 增强：抽奖动画 */
.draw-progress {
  width: 100%;
  height: 4px;
  background: rgba(102, 126, 234, 0.2);
  border-radius: 2px;
  margin-top: 20px;
  overflow: hidden;
}

.progress-bar {
  height: 100%;
  background: var(--gradient-primary);
  animation: progress 2s ease-in-out infinite;
}

@keyframes progress {
  0% {
    width: 0%;
  }
  50% {
    width: 70%;
  }
  100% {
    width: 100%;
  }
}

.box-light {
  position: absolute;
  width: 100%;
  height: 100%;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.5) 0%, transparent 70%);
  animation: pulse 1.5s infinite;
}

.shake {
  animation: shake 0.5s infinite;
}

@keyframes shake {
  0%, 100% {
    transform: translateX(0);
  }
  25% {
    transform: translateX(-5px) rotate(-3deg);
  }
  75% {
    transform: translateX(5px) rotate(3deg);
  }
}

/* 增强：中奖结果 */
.result-subtitle {
  font-size: 14px;
  color: var(--text-secondary);
  margin-top: 8px;
}

.prize-image-wrapper {
  position: relative;
  display: inline-block;
}

.prize-badge {
  position: absolute;
  top: -6px;
  right: -6px;
  padding: 2px 8px;
  min-height: 18px;
  background: var(--gradient-gold);
  border-radius: 10px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: 700;
  color: #ffffff;
  box-shadow: 0 6px 14px rgba(246, 211, 101, 0.35);
  animation: bounce 2s infinite;
}

/* ===== 移动端优化 ===== */
@media (max-width: 480px) {
  .container {
    padding: 12px;
  }

  .logo {
    font-size: 22px;
  }

  .logo-icon {
    font-size: 30px;
  }

  .logo-slogan {
    font-size: 11px;
  }

  .btn-orders {
    padding: 10px 12px;
  }

  .section-title {
    font-size: 20px;
  }

  .hot-tags {
    margin: 12px 0 16px;
    padding: 2px 12px;
  }

  .hot-tags-track {
    gap: 6px 8px;
    padding-right: 18px;
  }

  .hot-tag {
    padding: 4px 12px;
    font-size: 12px;
  }

  .hot-tag:nth-child(even) {
    --tag-shift: 10px;
  }

  .blind-box-card {
    padding: 16px 16px 18px;
  }

  .box-3d {
    width: 160px;
    height: 160px;
  }

  .box-icon {
    font-size: 60px;
  }

  .box-question {
    font-size: 48px;
  }

  .box-features {
    gap: 8px;
  }

  .feature-item {
    font-size: 12px;
    padding: 5px 10px;
  }

  .price-value {
    font-size: 40px;
  }

  .btn-draw {
    padding: 16px 24px;
    font-size: 16px;
  }

  .reviews-section,
  .prizes-section,
  .rules-section {
    padding: 20px;
  }

  .review-card {
    padding: 16px;
  }

  .modal-content {
    padding: 24px;
  }

  .back-to-top {
    bottom: 20px;
    right: 16px;
    width: 44px;
    height: 44px;
  }
}

/* 超小屏幕优化 */
@media (max-width: 360px) {
  .logo {
    font-size: 20px;
  }

  .logo-icon {
    font-size: 28px;
  }

  .box-3d {
    width: 140px;
    height: 140px;
  }

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

/* 平板横屏优化 */
@media (min-width: 768px) {
  .reviews-carousel {
    flex-direction: row;
    gap: 20px;
  }

  .review-card {
    flex: 1;
  }
}

/* 中奖记录弹窗样式 */
.winnings-list {
  max-height: 500px;
  overflow-y: auto;
  padding: 10px 0;
}

.winning-item {
  display: flex;
  align-items: center;
  gap: 15px;
  padding: 15px;
  background: var(--card-bg, rgba(255, 255, 255, 0.05));
  border-radius: 12px;
  margin-bottom: 10px;
  transition: all 0.3s ease;
  animation: fadeInUp 0.4s ease forwards;
  opacity: 0;
}

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

.winning-item:hover {
  transform: translateX(5px);
  background: var(--card-bg-hover, rgba(255, 255, 255, 0.1));
}

.winning-index {
  flex-shrink: 0;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, var(--primary-color, #ff6b6b) 0%, var(--secondary-color, #ee5a6f) 100%);
  color: white;
  border-radius: 50%;
  font-weight: bold;
  font-size: 14px;
}

.winning-info {
  flex: 1;
  min-width: 0;
}

.winning-phone {
  font-size: 15px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.winning-prize {
  font-size: 13px;
  color: var(--text-secondary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.winning-time {
  flex-shrink: 0;
  font-size: 12px;
  color: var(--text-tertiary);
}

/* 滚动条样式 */
.winnings-list::-webkit-scrollbar {
  width: 6px;
}

.winnings-list::-webkit-scrollbar-track {
  background: rgba(0, 0, 0, 0.1);
  border-radius: 3px;
}

.winnings-list::-webkit-scrollbar-thumb {
  background: var(--primary-color, #ff6b6b);
  border-radius: 3px;
}

.winnings-list::-webkit-scrollbar-thumb:hover {
  background: var(--secondary-color, #ee5a6f);
}
