/* ===== 全局重置 & 基础 ===== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
}

body {
  background: #f5f9fe;
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 100vh;
  padding: 2rem 1.5rem;
}

/* ===== 卡片容器 ===== */
.card-grid {
  max-width: 1320px;
  width: 100%;
  background: white;
  border-radius: 2.5rem;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.15);
  padding: 2.5rem 2rem;
  transition: all 0.2s ease;
  animation: cardGridIn 0.8s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

@keyframes cardGridIn {
  from { opacity: 0; transform: translateY(40px) scale(0.96); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

/* ===== 头部标题 ===== */
.title-section {
  margin-bottom: 2.5rem;
  text-align: left;
  animation: titleIn 0.7s cubic-bezier(0.22, 1, 0.36, 1) 0.1s both;
}

@keyframes titleIn {
  from { opacity: 0; transform: translateY(-20px); }
  to { opacity: 1; transform: translateY(0); }
}

.title-section h1 {
  font-size: 2rem;
  font-weight: 700;
  color: #0b1a33;
  letter-spacing: -0.02em;
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.title-section h1 small {
  font-size: 1rem;
  font-weight: 400;
  color: #3a5575;
  background: #eef4fb;
  padding: 0.3rem 1rem;
  border-radius: 40px;
  letter-spacing: 0.3px;
  margin-left: 0.25rem;
}

.subhead {
  margin-top: 0.35rem;
  color: #2e4b6b;
  font-weight: 400;
  font-size: 1.1rem;
  border-left: 4px solid #2e7df6;
  padding-left: 1rem;
  background: #f0f6ff;
  border-radius: 0 12px 12px 0;
  display: inline-block;
  padding: 0.4rem 1.2rem 0.4rem 1.2rem;
}

.subhead small { font-size: inherit; }

/* ===== 价格网格 ===== */
.pricing-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.8rem;
  margin-top: 1rem;
}

/* ===== 单个方案卡片 ===== */
.plan-card {
  background: #ffffff;
  border-radius: 1.8rem;
  padding: 1.8rem 1.2rem 1.8rem 1.2rem;
  box-shadow: 0 8px 20px rgba(0, 20, 50, 0.04);
  border: 1px solid #e9eff6;
  transition: all 0.4s cubic-bezier(0.22, 1, 0.36, 1);
  display: flex;
  flex-direction: column;
  position: relative;
  backdrop-filter: blur(2px);
  opacity: 0;
  transform: translateY(30px);
  animation: cardIn 0.6s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

.plan-card:nth-child(1) { animation-delay: 0.1s; }
.plan-card:nth-child(2) { animation-delay: 0.2s; }
.plan-card:nth-child(3) { animation-delay: 0.3s; }
.plan-card:nth-child(4) { animation-delay: 0.4s; }

@keyframes cardIn {
  from { opacity: 0; transform: translateY(30px) scale(0.95); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

.plan-card:hover {
  border-color: #b8d1f0;
  box-shadow: 0 12px 28px -8px rgba(30, 80, 180, 0.08);
  transform: translateY(-6px) scale(1.01);
}

.plan-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  border-radius: 1.8rem;
  background: radial-gradient(circle at 50% 0%, rgba(31, 106, 208, 0.06), transparent 70%);
  opacity: 0;
  transition: opacity 0.5s ease;
  pointer-events: none;
}

.plan-card:hover::before { opacity: 1; }

.plan-badge {
  display: inline-block;
  background: #eef4fb;
  color: #1d4a7c;
  font-weight: 600;
  font-size: 0.7rem;
  letter-spacing: 0.5px;
  padding: 0.2rem 0.8rem;
  border-radius: 30px;
  width: fit-content;
  margin-bottom: 0.75rem;
  border: 1px solid #d6e2f2;
  transition: all 0.3s ease;
}

.plan-card:hover .plan-badge {
  background: #dce8fc;
  border-color: #b0ccee;
  transform: scale(1.05);
}

.plan-name {
  font-size: 1.3rem;
  font-weight: 700;
  color: #0a1e38;
  margin-bottom: 0.3rem;
  letter-spacing: -0.3px;
  display: flex;
  align-items: center;
  gap: 6px;
  transition: color 0.3s ease;
}

.plan-card:hover .plan-name { color: #1f6ad0; }

.plan-name i {
  color: #2e7df6;
  font-size: 0.9rem;
  opacity: 0.7;
  transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.plan-card:hover .plan-name i {
  transform: rotate(-8deg) scale(1.1);
  opacity: 1;
}

.plan-tagline {
  font-size: 0.75rem;
  color: #4a6d92;
  background: #f0f6fe;
  padding: 0.15rem 0.6rem;
  border-radius: 20px;
  display: inline-block;
  margin: 0.2rem 0 0.8rem 0;
  font-weight: 500;
  letter-spacing: 0.2px;
  transition: all 0.3s ease;
}

.plan-card:hover .plan-tagline {
  background: #e3eefa;
  transform: translateX(4px);
}

/* ===== 价格区块 ===== */
.price-block {
  margin: 1rem 0 1.2rem 0;
  background: #f7faff;
  padding: 0.8rem 0.8rem 0.6rem 0.8rem;
  border-radius: 1.2rem;
  border: 1px dashed #cddef5;
  transition: all 0.4s cubic-bezier(0.22, 1, 0.36, 1);
}

.plan-card:hover .price-block {
  background: #eef6ff;
  border-color: #8db4e8;
  transform: scale(1.02);
}

.price-original {
  font-size: 0.9rem;
  color: #6f8aa8;
  text-decoration: line-through;
  letter-spacing: 0.2px;
  margin-bottom: 0.15rem;
  display: flex;
  align-items: center;
  gap: 6px;
}

.price-original i { font-size: 0.7rem; color: #8aa3c0; }

.price-sale {
  display: flex;
  align-items: baseline;
  gap: 6px;
  flex-wrap: wrap;
}

.price-sale .currency {
  font-size: 1rem;
  font-weight: 500;
  color: #0b2b50;
}

.price-sale .amount {
  font-size: 1.9rem;
  font-weight: 700;
  color: #00337a;
  letter-spacing: -0.5px;
  line-height: 1;
  transition: all 0.3s ease;
}

.plan-card:hover .price-sale .amount {
  color: #1f6ad0;
  transform: scale(1.02);
}

.price-sale .badge-hot {
  background: #dceaff;
  color: #0047a0;
  font-size: 0.6rem;
  font-weight: 600;
  padding: 0.1rem 0.6rem;
  border-radius: 30px;
  margin-left: 4px;
  border: 1px solid #b7cef0;
  transition: all 0.3s ease;
}

.plan-card:hover .price-sale .badge-hot {
  background: #1f6ad0;
  color: white;
  border-color: #1f6ad0;
  transform: scale(1.08);
}

.price-sale .unit {
  font-size: 0.8rem;
  color: #39628b;
  margin-left: 2px;
}

/* ===== 功能列表 ===== */
.feature-list {
  list-style: none;
  margin: 0.5rem 0 0.8rem 0;
  padding: 0;
  flex: 1;
}

.feature-list li {
  padding: 0.35rem 0 0.35rem 1.6rem;
  position: relative;
  font-size: 0.85rem;
  color: #1d3b5e;
  line-height: 1.4;
  border-bottom: 1px solid #f0f4fc;
  transition: all 0.3s ease;
  transform-origin: left center;
}

.plan-card:hover .feature-list li { color: #0a1e38; }

.feature-list li:last-child { border-bottom: none; }

.feature-list li i {
  position: absolute;
  left: 0;
  top: 0.4rem;
  color: #2e7df6;
  font-size: 0.75rem;
  width: 1.2rem;
  text-align: center;
  transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.plan-card:hover .feature-list li i {
  color: #1f6ad0;
  transform: scale(1.2) rotate(-8deg);
}

/* ===== 底部标签 ===== */
.footer-features {
  margin-top: 0.6rem;
  border-top: 1px solid #eaf1fa;
  padding-top: 0.6rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem 0.8rem;
  min-height: 0.5rem;
}

.footer-features span {
  font-size: 0.7rem;
  color: #31639b;
  background: #f1f7ff;
  padding: 0.15rem 0.6rem;
  border-radius: 20px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  transition: all 0.3s ease;
}

.plan-card:hover .footer-features span {
  background: #e3eefa;
  transform: translateY(-2px);
}

.footer-features span i { font-size: 0.6rem; color: #3a7ad8; }

/* ===== 立即购买按钮 ===== */
.buy-btn {
  margin-top: 0.8rem;
  padding: 0.6rem 1rem;
  background: #1f6ad0;
  color: white;
  border: none;
  border-radius: 40px;
  font-weight: 600;
  font-size: 0.9rem;
  cursor: pointer;
  transition: all 0.35s cubic-bezier(0.22, 1, 0.36, 1);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  box-shadow: 0 4px 12px rgba(31, 106, 208, 0.25);
  position: relative;
  overflow: hidden;
}

.buy-btn::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(255,255,255,0.15), transparent 50%);
  opacity: 0;
  transition: opacity 0.4s ease;
  border-radius: 40px;
}

.buy-btn:hover::after { opacity: 1; }

.buy-btn:hover {
  background: #0f4faa;
  transform: translateY(-3px) scale(1.02);
  box-shadow: 0 8px 25px rgba(31, 106, 208, 0.4);
}

.buy-btn:active {
  transform: translateY(0) scale(0.97);
  box-shadow: 0 4px 12px rgba(31, 106, 208, 0.2);
}

.buy-btn i {
  transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.buy-btn:hover i { transform: translateX(-4px) scale(1.1); }

/* ============================================================
   弹窗 (Modal)
   ============================================================ */
.modal {
  display: none;
  position: fixed;
  z-index: 999;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(10, 25, 50, 0.55);
  backdrop-filter: blur(4px);
  justify-content: center;
  align-items: center;
  animation: modalFadeIn 0.3s ease;
}

.modal.show { display: flex; }

@keyframes modalFadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

.modal-content {
  background: white;
  padding: 2rem 1.8rem 1.8rem;
  border-radius: 2rem;
  max-width: 400px;
  width: 92%;
  box-shadow: 0 30px 60px rgba(0, 10, 30, 0.3);
  position: relative;
  animation: modalSlideUp 0.4s cubic-bezier(0.22, 1, 0.36, 1);
  max-height: 95vh;
  overflow-y: auto;
}

@keyframes modalSlideUp {
  from { opacity: 0; transform: translateY(40px) scale(0.92); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

.close-btn {
  position: absolute;
  right: 1rem;
  top: 0.6rem;
  font-size: 2rem;
  font-weight: 300;
  color: #8aa3c0;
  cursor: pointer;
  transition: all 0.3s ease;
  line-height: 1;
  background: none;
  border: none;
  padding: 0.2rem 0.5rem;
  border-radius: 50%;
}

.close-btn:hover {
  color: #1d3b5e;
  background: #f0f4fc;
  transform: rotate(90deg) scale(1.1);
}

.modal-content h2 {
  color: #0b1a33;
  font-size: 1.4rem;
  margin-bottom: 0.2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
}

.modal-content p {
  color: #3a5f82;
  font-size: 0.9rem;
  text-align: center;
  margin-bottom: 1rem;
}

/* ============================================================
   弹窗 - 电话 + 微信卡片样式
   ============================================================ */
.contact-options {
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
  width: 100%;
}

.contact-card {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  background: #f0f7ff;
  border-radius: 14px;
  padding: 0.9rem 1rem;
  border: 1.5px solid #d6e8ff;
  transition: all 0.3s ease;
  width: 100%;
  box-sizing: border-box;
  cursor: pointer;
}

.contact-card-phone {
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.contact-card-phone:hover {
  background: #e6f0ff;
  border-color: #1f6ad0;
}

.contact-card-phone:active {
  transform: scale(0.98);
  background: #dce8fc;
}

.contact-card-wechat {
  cursor: default;
  flex-wrap: wrap;
}

.contact-card-wechat:hover {
  background: #e6f0ff;
  border-color: #1f6ad0;
}

.contact-icon {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.contact-icon i {
  color: white;
  font-size: 1rem;
}

.contact-info {
  flex: 1;
  min-width: 0;
  overflow: hidden;
}

.contact-label {
  font-size: 0.7rem;
  color: #6f8aa8;
}

.contact-value {
  font-size: 1.05rem;
  font-weight: 700;
  color: #0b2b5c;
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.wechat-id {
  color: #1f6ad0;
}

.contact-arrow {
  color: #1f6ad0;
  font-size: 0.7rem;
  flex-shrink: 0;
}

.copy-btn {
  background: #1f6ad0;
  color: white;
  border: none;
  border-radius: 20px;
  padding: 1px 10px;
  font-size: 0.6rem;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 3px;
  transition: all 0.2s;
  white-space: nowrap;
  line-height: 1.6;
}

.copy-btn:hover { background: #0f4faa; }

.qr-wrapper {
  display: flex;
  align-items: center;
  gap: 4px;
  cursor: pointer;
  flex-shrink: 0;
}

#wechatQr {
  width: 64px;
  height: 64px;
  border-radius: 8px;
  border: 2px solid #d6e8ff;
  object-fit: cover;
  transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

#wechatQr:hover {
  transform: scale(1.08);
  border-color: #1f6ad0;
  box-shadow: 0 4px 16px rgba(31, 106, 208, 0.2);
}

/* ============================================================
   二维码放大浮层
   ============================================================ */
#qrOverlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.85);
  z-index: 9999;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  cursor: pointer;
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  animation: overlayFadeIn 0.3s ease;
}

@keyframes overlayFadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

#qrOverlay img {
  max-width: 85%;
  max-height: 75%;
  width: auto;
  height: auto;
  border-radius: 16px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.6);
  object-fit: contain;
  animation: qrZoomIn 0.4s cubic-bezier(0.22, 1, 0.36, 1);
}

@keyframes qrZoomIn {
  from { opacity: 0; transform: scale(0.8); }
  to { opacity: 1; transform: scale(1); }
}

#qrOverlay .hint {
  text-align: center;
  margin-top: 20px;
  color: rgba(255, 255, 255, 0.7);
  font-size: 0.9rem;
  animation: hintFadeIn 0.5s ease 0.2s both;
}

@keyframes hintFadeIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

#qrOverlay .hint strong { color: #fff; font-size: 1.1rem; }
#qrOverlay .hint .sub {
  margin-top: 6px;
  font-size: 0.75rem;
  color: rgba(255, 255, 255, 0.4);
}

/* ===== 复制提示动画 ===== */
@keyframes fadeInOut {
  0% { opacity: 0; transform: translate(-50%, -50%) scale(0.9); }
  15% { opacity: 1; transform: translate(-50%, -50%) scale(1); }
  85% { opacity: 1; transform: translate(-50%, -50%) scale(1); }
  100% { opacity: 0; transform: translate(-50%, -50%) scale(0.9); }
}

/* ============================================================
   响应式 - 平板端
   ============================================================ */
@media screen and (max-width: 992px) {
  .pricing-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
  }
  .card-grid { padding: 1.8rem 1.2rem; }
  .plan-card { animation-delay: 0s !important; }
  .plan-card:nth-child(2) { animation-delay: 0.05s !important; }
  .plan-card:nth-child(3) { animation-delay: 0.10s !important; }
  .plan-card:nth-child(4) { animation-delay: 0.15s !important; }
}

/* ============================================================
   响应式 - 手机端
   ============================================================ */
@media screen and (max-width: 600px) {
  .pricing-grid {
    grid-template-columns: 1fr;
    gap: 1.2rem;
  }
  .card-grid { padding: 1.5rem 1rem; }

  .title-section h1 {
    font-size: 1.4rem;
    flex-direction: column;
    align-items: flex-start;
  }
  .title-section h1 small {
    margin-left: 0;
    font-size: 0.85rem;
  }
  .subhead { font-size: 0.85rem; padding: 0.3rem 1rem; }

  .plan-card { animation-delay: 0s !important; }
  .plan-card:nth-child(2) { animation-delay: 0.06s !important; }
  .plan-card:nth-child(3) { animation-delay: 0.12s !important; }
  .plan-card:nth-child(4) { animation-delay: 0.18s !important; }

  /* ===== 弹窗手机优化 ===== */
  .modal-content {
    max-width: 94% !important;
    width: 94% !important;
    padding: 1.2rem 0.8rem 1rem !important;
    border-radius: 1.2rem !important;
    margin: 0.5rem !important;
    max-height: 90vh;
    overflow-y: auto;
  }

  .modal-content h2 {
    font-size: 1.1rem !important;
    text-align: center;
  }

  .modal-content p {
    font-size: 0.8rem !important;
    text-align: center;
    margin-bottom: 0.8rem !important;
  }

  /* ===== 卡片统一宽度 ===== */
  .contact-options {
    gap: 0.7rem !important;
    width: 100% !important;
  }

  .contact-card {
    padding: 0.7rem 0.8rem !important;
    gap: 0.6rem !important;
    border-radius: 12px !important;
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
    flex-shrink: 0 !important;
  }

  .contact-icon {
    width: 34px !important;
    height: 34px !important;
    flex-shrink: 0 !important;
  }

  .contact-icon i {
    font-size: 0.85rem !important;
  }

  .contact-info {
    flex: 1 !important;
    min-width: 0 !important;
    overflow: hidden !important;
  }

  .contact-value {
    font-size: 0.85rem !important;
    gap: 4px !important;
    flex-wrap: wrap !important;
  }

  .contact-label {
    font-size: 0.65rem !important;
  }

  .contact-arrow {
    font-size: 0.6rem !important;
    flex-shrink: 0 !important;
  }

  /* ===== 二维码在手机端 ===== */
  .qr-wrapper {
    flex-shrink: 0 !important;
  }

  #wechatQr {
    width: 50px !important;
    height: 50px !important;
  }

  /* ===== 复制按钮 ===== */
  .copy-btn {
    font-size: 0.55rem !important;
    padding: 1px 8px !important;
  }

  /* ===== 关闭按钮 ===== */
  .close-btn {
    right: 0.6rem !important;
    top: 0.4rem !important;
    font-size: 1.6rem !important;
  }

  /* 移动端卡片悬浮效果改为点击反馈 */
  .plan-card:active {
    transform: scale(0.98) !important;
    border-color: #b8d1f0;
  }
  .plan-card:hover { transform: none !important; }
  .buy-btn:active { transform: scale(0.96) !important; }
  .contact-card-phone:hover { transform: none !important; }

    /* ===== 底部说明手机端：每行2个，完全对齐 ===== */
  .card-grid > div:last-of-type {
    display: grid !important;
    grid-template-columns: 1fr 1fr !important;
    gap: 0.4rem 0.8rem !important;
    text-align: left !important;
    padding: 0 !important;
    border-top: 1px solid #dfeaf7;
    padding-top: 1.2rem !important;
    margin-top: 1.5rem !important;
  }

  .card-grid > div:last-of-type span {
    margin-left: 0 !important;
    padding: 0.15rem 0 !important;
    font-size: 0.7rem !important;
    display: flex !important;
    align-items: center !important;
    gap: 4px !important;
    background: transparent !important;
    border: none !important;
    white-space: normal !important;
    word-break: break-word !important;
    line-height: 1.3 !important;
  }

  .card-grid > div:last-of-type span i {
    font-size: 0.7rem !important;
    width: 1.2rem !important;
    min-width: 1.2rem !important;
    text-align: center !important;
    flex-shrink: 0 !important;
    color: #2670e0 !important;
  }

  /* 日期：居中 */
  .card-grid > div:last-child {
    text-align: center !important;
    margin-top: 0.5rem !important;
  }
}

/* 超小屏手机（宽度 < 380px） */
@media screen and (max-width: 380px) {
  .card-grid { padding: 0.8rem 0.6rem; }
  .plan-card { padding: 1rem 0.8rem; }
  .modal-content { padding: 1rem 0.6rem 0.8rem !important; border-radius: 1rem !important; }
  .modal-content h2 { font-size: 1rem !important; }
  .contact-card { padding: 0.6rem 0.6rem !important; gap: 0.5rem !important; }
  .contact-icon { width: 30px !important; height: 30px !important; }
  .contact-icon i { font-size: 0.75rem !important; }
  .contact-value { font-size: 0.78rem !important; }
  #wechatQr { width: 44px !important; height: 44px !important; }
  .price-sale .amount { font-size: 1.3rem; }
}

/* ===== 滚动条美化 ===== */
.modal-content::-webkit-scrollbar { width: 4px; }
.modal-content::-webkit-scrollbar-track { background: #f0f4fc; border-radius: 4px; }
.modal-content::-webkit-scrollbar-thumb { background: #b8cce0; border-radius: 4px; }
.modal-content::-webkit-scrollbar-thumb:hover { background: #8aaac8; }