* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html,
body {
  width: 100%;
  min-height: 100%;
}

.bg-page {
  min-height: 100dvh;
  overflow-x: hidden;
  overflow-y: auto;
  background: #130000;
  padding-bottom: calc(96px + env(safe-area-inset-bottom));
}

.bg-image {
  display: block;
  width: 100%;
  height: auto;
}

.float-bar {
  position: fixed;
  left: 0;
  bottom: calc(32px + env(safe-area-inset-bottom));
  transform: none;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 16px;
  border: none;
  border-radius: 0;
  background: linear-gradient(135deg, #fff9d0 0%, #ffe680 100%);
  box-shadow: none;
  z-index: 20;
}

.text-wrapper {
  display: flex;
  flex-direction: column;
  gap: 4px;
  flex-shrink: 1;
  min-width: 0;
  align-items: center;
}

.free-text-line1 {
  color: #f14b2d;
  font-size: clamp(1.8rem, 6.5vw, 2.8rem);
  font-weight: 900;
  line-height: 1;
  white-space: nowrap;
  text-align: center;
  letter-spacing: 0.1em;
}

.free-text-line2 {
  color: #f14b2d;
  font-size: clamp(1.6rem, 5.5vw, 2.2rem);
  font-weight: 900;
  line-height: 1;
  white-space: nowrap;
  display: flex;
  align-items: center;
  justify-content: center;
}

.free-text-line2 em {
  font-style: normal;
  font-size: 2.5em;
  margin: 0 4px;
  display: inline-block;
  text-shadow: 2px 2px 4px rgba(255, 255, 255, 0.8), 0 0 15px rgba(241, 75, 45, 0.5);
  animation: bounce 0.2s ease-in-out infinite, textGlow 0.25s ease-in-out infinite;
}

@keyframes textGlow {
  0%,
  100% {
    text-shadow: 2px 2px 4px rgba(255, 255, 255, 0.8), 0 0 15px rgba(241, 75, 45, 0.5);
    transform: scale(1);
  }
  50% {
    text-shadow: 4px 4px 12px rgba(255, 255, 255, 1), 0 0 40px rgba(241, 75, 45, 1), 0 0 60px rgba(255, 215, 0, 1);
    transform: scale(1.15);
  }
}

@keyframes bounce {
  0%,
  100% {
    transform: translateY(0) scale(1);
  }
  50% {
    transform: translateY(-8px) scale(1.2);
  }
}

.signup-btn {
  border: none;
  border-radius: 30px;
  background: linear-gradient(135deg, #ff5722 0%, #f14b2d 50%, #d32f2f 100%);
  color: #fff;
  font-size: clamp(1.8rem, 7vw, 2.8rem);
  font-weight: 900;
  padding: 16px 28px;
  line-height: 1;
  white-space: nowrap;
  cursor: pointer;
  box-shadow: 0 4px 15px rgba(241, 75, 45, 0.5);
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
  animation: btnShine 0.25s ease-in-out infinite;
  flex-shrink: 1;
  min-width: 0;
}

.signup-btn::before {
  content: "";
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: linear-gradient(45deg, transparent, rgba(255, 255, 255, 0.3), transparent);
  transform: rotate(45deg);
  animation: shine 3s ease-in-out infinite;
}

@keyframes shine {
  0% {
    left: -100%;
  }
  40%,
  100% {
    left: 100%;
  }
}

@keyframes btnShine {
  0%,
  100% {
    box-shadow: 0 4px 15px rgba(241, 75, 45, 0.6);
    transform: scale(1);
  }
  50% {
    box-shadow: 0 12px 45px rgba(241, 75, 45, 1), 0 0 30px rgba(255, 215, 0, 0.8);
    transform: scale(1.1);
  }
}

.signup-btn:hover {
  transform: scale(1.05);
  box-shadow: 0 6px 20px rgba(241, 75, 45, 0.7), inset 0 1px 0 rgba(255, 255, 255, 0.4);
}

.signup-btn:active {
  transform: scale(0.98);
}


.agreement-bar {
  position: fixed;
  left: 0;
  bottom: env(safe-area-inset-bottom);
  width: 100%;
  padding: 8px 16px;
  background: #fff;
  z-index: 19;
}

.agreement-label {
  display: flex;
  align-items: center;
  gap: 6px;
  cursor: pointer;
}

.agreement-checkbox {
  width: 16px;
  height: 16px;
  cursor: pointer;
  flex-shrink: 0;
}

.agreement-text {
  color: #666;
  font-size: 12px;
  line-height: 1.2;
  white-space: nowrap;
}

.agreement-link {
  color: #4a90e2;
  text-decoration: none;
}

.agreement-link:hover {
  text-decoration: underline;
}

/* 客服按钮 */
.customer-service-btn {
  position: fixed;
  right: 0;
  bottom: calc(230px + env(safe-area-inset-bottom));
  width: 77px;
  height: 64px;
  border: none;
  background: transparent;
  cursor: pointer;
  z-index: 100;
  padding: 0;
  transition: transform 0.3s ease;
  overflow: hidden;
}

.customer-service-btn img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: contain;
  object-position: center;
}

.customer-service-btn:hover {
  transform: scale(1.1);
}

.customer-service-btn:active {
  transform: scale(0.95);
}

/* 弹窗样式 */
.modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  z-index: 1000;
  overflow: auto;
}

.modal.active {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
}

.modal-content {
  position: relative;
  background: #fff;
  border-radius: 0;
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  box-shadow: none;
}

.modal-close {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 32px;
  height: 32px;
  border: none;
  background: #f0f0f0;
  color: #999;
  font-size: 24px;
  line-height: 1;
  cursor: pointer;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1;
}

.modal-close:hover {
  background: #e0e0e0;
  color: #666;
}

.modal-title {
  padding: 20px 20px 16px;
  margin: 0;
  font-size: 18px;
  font-weight: 700;
  text-align: center;
  color: #333;
  border-bottom: 1px solid #eee;
}

.modal-body {
  flex: 1;
  overflow-y: auto;
  padding: 20px;
}

.modal-body img {
  width: 100%;
  height: auto;
  display: block;
}

.modal-btn {
  margin: 0 20px 20px;
  padding: 14px;
  border: none;
  border-radius: 25px;
  background: linear-gradient(135deg, #ff5722 0%, #f14b2d 50%, #d32f2f 100%);
  color: #fff;
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.3s ease;
}

.modal-btn:hover {
  transform: scale(1.02);
  box-shadow: 0 4px 12px rgba(241, 75, 45, 0.4);
}

.modal-btn:active {
  transform: scale(0.98);
}
