/* ===================================================================
   Bumper Karts — 充值页（与首页同一套青蓝底 + blob + 网格；表单区为高对比浅色卡片）
   依赖：先加载 css/index.css（设计令牌与 --font-display / --font-body）
   =================================================================== */

body.page-recharge {
  --rec-card: rgba(255, 255, 255, 0.96);
  --rec-card-border: rgba(120, 200, 255, 0.28);
  --rec-input: rgba(255, 255, 255, 0.99);
  --rec-soft: rgba(255, 255, 255, 0.2);
  --rec-text: #062a42;
  --rec-muted: rgba(6, 42, 66, 0.72);
  --jade: #00d4a8;
  --jade-dark: #00a67f;
  font-family: var(--font-body);
  font-optical-sizing: auto;
  background-color: #050a14;
  background-image: var(--bk-page-gradient);
  background-attachment: fixed;
  color: var(--bk-text);
  min-height: 100vh;
  overflow-x: hidden;
}

body.page-recharge * {
  box-sizing: border-box;
}

/* ---------- 顶栏：深色玻璃，与首页街机底一致 ---------- */
body.page-recharge #navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  padding: 0.85rem 2rem;
  background: rgba(6, 18, 40, 0.78);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.35);
  border-bottom: 1px solid var(--bk-border);
}

body.page-recharge .nav-container {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

body.page-recharge .nav-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
}

body.page-recharge .nav-logo img {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  object-fit: cover;
  box-shadow: 0 4px 14px rgba(0, 120, 180, 0.25);
}

body.page-recharge .nav-logo-text {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.25rem;
  letter-spacing: -0.02em;
  color: var(--bk-text);
  text-shadow: 0 0 28px rgba(0, 200, 255, 0.25);
}

body.page-recharge .nav-links {
  display: flex;
  gap: 1.5rem;
  list-style: none;
  align-items: center;
}

body.page-recharge .nav-links a {
  color: rgba(230, 245, 255, 0.88);
  text-decoration: none;
  font-weight: 700;
  font-size: 0.9rem;
  transition: color 0.2s ease;
  position: relative;
}

body.page-recharge .nav-links a::after {
  content: '';
  position: absolute;
  bottom: -3px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--bk-neon);
  border-radius: 2px;
  transition: width 0.25s ease;
}

body.page-recharge .nav-links a:hover {
  color: var(--bk-neon);
}
body.page-recharge .nav-links a:hover::after {
  width: 100%;
}

body.page-recharge .nav-active-badge {
  background: var(--gradient-warm);
  color: #2a1200;
  padding: 0.32rem 0.9rem;
  border-radius: 10px;
  font-weight: 800;
  font-size: 0.82rem;
  box-shadow: 0 3px 14px rgba(255, 100, 40, 0.35);
}

body.page-recharge .mobile-menu-btn {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 6px;
  flex-direction: column;
  gap: 5px;
}

body.page-recharge .mobile-menu-btn span {
  display: block;
  width: 26px;
  height: 3px;
  background: var(--bk-text);
  border-radius: 2px;
}

body.page-recharge .mobile-menu {
  display: none;
  position: fixed;
  top: 64px;
  left: 0;
  right: 0;
  background: rgba(4, 16, 36, 0.94);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.4);
  padding: 1rem 2rem;
  z-index: 999;
  border-bottom: 1px solid var(--bk-border);
}

body.page-recharge .mobile-menu.active {
  display: block;
}

body.page-recharge .mobile-menu a {
  display: block;
  color: var(--bk-text);
  text-decoration: none;
  font-weight: 700;
  padding: 0.75rem 0;
  border-bottom: 1px solid rgba(120, 200, 255, 0.15);
}

body.page-recharge .mobile-menu a:last-child {
  border-bottom: none;
}

/* ---------- 页头 ---------- */
body.page-recharge .page-header {
  position: relative;
  z-index: 2;
  padding: 6.5rem 2rem 2.75rem;
  text-align: center;
  background: linear-gradient(
    180deg,
    rgba(4, 14, 32, 0.45) 0%,
    rgba(6, 28, 52, 0.55) 100%
  );
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--bk-border);
}

body.page-recharge .page-header h1 {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(1.85rem, 4.5vw, 2.75rem);
  color: #ffffff;
  text-shadow: 0 0 40px rgba(0, 200, 255, 0.2), 0 2px 20px rgba(0, 0, 0, 0.45);
  margin-bottom: 0.65rem;
  letter-spacing: -0.02em;
}

body.page-recharge .page-header p {
  font-size: 1.02rem;
  color: var(--bk-muted);
  max-width: 520px;
  margin: 0 auto;
  line-height: 1.65;
}

/* ---------- 主内容 ---------- */
body.page-recharge .main-content {
  position: relative;
  z-index: 2;
  max-width: 1100px;
  margin: 0 auto;
  padding: 2.5rem 2rem 4rem;
}

/* ---------- 卡片 ---------- */
body.page-recharge .card {
  background: var(--rec-card);
  border-radius: 22px;
  padding: 2rem 2rem 2.4rem;
  margin-bottom: 1.75rem;
  box-shadow:
    0 16px 48px rgba(0, 0, 0, 0.35),
    0 0 0 1px rgba(255, 255, 255, 0.06);
  border: 1px solid var(--rec-card-border);
  position: relative;
  overflow: hidden;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

body.page-recharge .card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(
    90deg,
    #2ee8ff,
    #00b8d4,
    var(--accent),
    var(--bk-neon),
    #00a8c6
  );
}

body.page-recharge .card-header {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1.6rem;
}

body.page-recharge .card-icon {
  width: 50px;
  height: 50px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.35rem;
  flex-shrink: 0;
}

body.page-recharge .card-icon.user {
  background: var(--gradient-pill);
  color: #fff;
}
body.page-recharge .card-icon.package {
  background: var(--gradient-warm);
  color: #fff;
}
body.page-recharge .card-icon.payment {
  background: linear-gradient(135deg, var(--jade), var(--jade-dark));
  color: #fff;
}
body.page-recharge .card-icon.summary {
  background: linear-gradient(135deg, var(--primary-light), var(--primary-dark));
  color: #fff;
}

body.page-recharge .card-title {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.25rem;
  background: var(--gradient-pill);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* ---------- 表单 ---------- */
body.page-recharge .input-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.35rem;
}

body.page-recharge .input-group {
  display: flex;
  flex-direction: column;
}

body.page-recharge .input-label {
  font-size: 0.86rem;
  font-weight: 700;
  color: var(--rec-muted);
  margin-bottom: 0.45rem;
  display: flex;
  align-items: center;
  gap: 5px;
}

body.page-recharge .input-label i {
  color: var(--primary-dark);
}

body.page-recharge .input-field {
  width: 100%;
  padding: 0.92rem 1.05rem;
  background: var(--rec-input);
  border: 2px solid rgba(0, 160, 210, 0.22);
  border-radius: 12px;
  color: var(--rec-text);
  font-size: 0.95rem;
  font-family: inherit;
  font-weight: 600;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
  outline: none;
}

body.page-recharge .input-field::placeholder {
  color: rgba(6, 42, 66, 0.45);
}

body.page-recharge .input-field:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 4px rgba(0, 210, 255, 0.22);
}

body.page-recharge .verify-status {
  margin-top: 0.35rem;
  font-size: 0.78rem;
  font-weight: 600;
  min-height: 1.1rem;
  display: flex;
  align-items: center;
  gap: 0.3rem;
  transition: color 0.2s ease;
}

body.page-recharge .verify-status.idle {
  color: transparent;
}
body.page-recharge .verify-status.checking {
  color: var(--rec-muted);
}
body.page-recharge .verify-status.success {
  color: var(--jade-dark);
}
body.page-recharge .verify-status.error {
  color: #c0392b;
}
body.page-recharge .verify-status.hint {
  color: var(--rec-muted);
}

/* ---------- 套餐 ---------- */
body.page-recharge .package-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 0.8rem;
}

body.page-recharge .package-card {
  background: rgba(255, 255, 255, 0.55);
  border: 2px solid rgba(0, 170, 220, 0.2);
  border-radius: 16px;
  padding: 0.75rem 0.55rem;
  text-align: center;
  cursor: pointer;
  transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
  position: relative;
  overflow: hidden;
  min-width: 0;
}

body.page-recharge .package-card:hover {
  transform: translateY(-4px);
  border-color: var(--primary-light);
  box-shadow: 0 12px 28px rgba(0, 120, 180, 0.2);
  background: rgba(255, 255, 255, 0.88);
}

body.page-recharge .package-card.selected {
  border-color: rgba(255, 220, 60, 0.95);
  background: rgba(255, 248, 200, 0.95);
  box-shadow:
    0 0 0 3px rgba(255, 210, 60, 0.35),
    0 8px 24px rgba(0, 80, 130, 0.15);
}

body.page-recharge .package-card img {
  width: 100%;
  height: auto;
  border-radius: 10px;
  margin-bottom: 0.55rem;
  display: block;
}

body.page-recharge .package-amount {
  position: absolute;
  bottom: 50px;
  right: 5px;
  background: var(--gradient-pill);
  color: #fff;
  font-size: 0.62rem;
  font-weight: 800;
  padding: 3px 7px;
  border-radius: 20px;
  box-shadow: 0 2px 10px rgba(0, 160, 210, 0.4);
}

body.page-recharge .package-price {
  font-size: 0.98rem;
  font-weight: 900;
  color: var(--primary-dark);
  margin-bottom: 0.15rem;
}

body.page-recharge .package-label {
  font-size: 0.68rem;
  color: var(--rec-muted);
  font-weight: 600;
}

body.page-recharge .package-check {
  position: absolute;
  top: 6px;
  right: 6px;
  width: 22px;
  height: 22px;
  background: linear-gradient(135deg, var(--jade), var(--jade-dark));
  border-radius: 50%;
  display: none;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 8px rgba(0, 200, 150, 0.4);
  animation: recPopIn 0.3s ease;
}

body.page-recharge .package-card.selected .package-check {
  display: flex;
}

@keyframes recPopIn {
  0% {
    transform: scale(0);
  }
  70% {
    transform: scale(1.15);
  }
  100% {
    transform: scale(1);
  }
}

/* ---------- 支付方式 ---------- */
body.page-recharge .payment-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.1rem;
}

body.page-recharge .payment-card {
  background: rgba(255, 255, 255, 0.55);
  border: 2px solid rgba(0, 170, 220, 0.2);
  border-radius: 18px;
  padding: 1.45rem 1.1rem;
  text-align: center;
  cursor: pointer;
  transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
  position: relative;
}

body.page-recharge .payment-card:hover {
  transform: translateY(-4px);
  border-color: var(--primary-light);
  box-shadow: 0 12px 28px rgba(0, 120, 180, 0.2);
  background: rgba(255, 255, 255, 0.9);
}

body.page-recharge .payment-card.selected {
  border-color: rgba(255, 220, 60, 0.95);
  background: rgba(255, 248, 200, 0.95);
  box-shadow:
    0 0 0 3px rgba(255, 210, 60, 0.35),
    0 8px 24px rgba(0, 80, 130, 0.12);
}

body.page-recharge .payment-icon {
  width: 54px;
  height: 54px;
  margin: 0 auto 0.75rem;
  background: #fff;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 12px rgba(0, 60, 100, 0.1);
}

body.page-recharge .payment-icon img {
  width: 32px;
  height: 32px;
  object-fit: contain;
}

body.page-recharge .payment-name {
  font-weight: 800;
  font-size: 0.92rem;
  color: var(--rec-text);
}

body.page-recharge .payment-check {
  position: absolute;
  top: 9px;
  right: 9px;
  width: 24px;
  height: 24px;
  background: linear-gradient(135deg, var(--jade), var(--jade-dark));
  border-radius: 50%;
  display: none;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 8px rgba(0, 200, 150, 0.4);
  animation: recPopIn 0.3s ease;
}

body.page-recharge .payment-card.selected .payment-check {
  display: flex;
}

/* ---------- 订单摘要 ---------- */
body.page-recharge .summary-box {
  background: rgba(0, 40, 70, 0.06);
  border-radius: 16px;
  padding: 1.4rem;
  margin-bottom: 1.35rem;
  border: 1px solid rgba(0, 160, 210, 0.18);
}

body.page-recharge .summary-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.65rem 0;
  border-bottom: 1px solid rgba(0, 150, 200, 0.12);
}

body.page-recharge .summary-row:last-child {
  border-bottom: none;
}

body.page-recharge .summary-total {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 1.15rem;
  background: linear-gradient(135deg, rgba(0, 210, 255, 0.15), rgba(255, 200, 60, 0.2));
  border-radius: 12px;
  margin-top: 0.75rem;
  border: 1px solid rgba(0, 180, 230, 0.35);
}

body.page-recharge .summary-label {
  color: var(--rec-muted);
  font-size: 0.88rem;
  font-weight: 600;
}

body.page-recharge .summary-total .summary-label {
  font-weight: 800;
  font-size: 0.98rem;
  color: var(--primary-dark);
}

body.page-recharge .summary-value {
  font-weight: 700;
  color: var(--rec-text);
  font-size: 0.9rem;
}

body.page-recharge .summary-total .summary-value {
  font-weight: 900;
  font-size: 1.35rem;
  color: var(--primary-dark);
}

/* ---------- 确认按钮 ---------- */
body.page-recharge .confirm-btn {
  width: 100%;
  padding: 1.1rem;
  background: var(--gradient-pill);
  color: #fff;
  border: none;
  border-radius: 14px;
  font-size: 1.02rem;
  font-weight: 800;
  font-family: var(--font-display);
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease, filter 0.2s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  box-shadow: 0 10px 28px rgba(0, 180, 230, 0.35);
}

body.page-recharge .confirm-btn:not(:disabled):hover {
  transform: translateY(-3px);
  box-shadow: 0 16px 36px rgba(0, 200, 255, 0.45);
  filter: brightness(1.06);
}

body.page-recharge .confirm-btn:disabled {
  background: linear-gradient(135deg, #9aa8b0, #b8c4cc);
  cursor: not-allowed;
  box-shadow: none;
  opacity: 0.88;
}

body.page-recharge .confirm-btn i {
  font-size: 1.15rem;
}

/* ---------- 虚拟点数说明卡 ---------- */
body.page-recharge .coin-info-card {
  background: linear-gradient(
    135deg,
    rgba(255, 240, 200, 0.95) 0%,
    rgba(255, 255, 255, 0.92) 45%,
    rgba(200, 245, 255, 0.9) 100%
  );
  border: 1px solid rgba(255, 200, 80, 0.45);
  border-radius: 20px;
  padding: 1.6rem 1.75rem;
  margin-bottom: 1.5rem;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  box-shadow: 0 10px 32px rgba(0, 60, 100, 0.12);
}

body.page-recharge .coin-info-header {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 1rem;
}

body.page-recharge .coin-info-icon i {
  color: #fff;
  font-size: 1.35rem;
  line-height: 1;
}

body.page-recharge .coin-info-title {
  font-size: 1.02rem;
  font-weight: 800;
  color: var(--rec-text);
}

body.page-recharge .coin-info-subtitle {
  font-size: 0.76rem;
  color: var(--rec-muted);
  margin-top: 2px;
}

body.page-recharge .coin-features {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.7rem;
  margin-bottom: 1.2rem;
}

body.page-recharge .coin-feature-item {
  display: flex;
  align-items: flex-start;
  gap: 0.55rem;
  background: rgba(255, 255, 255, 0.75);
  border-radius: 12px;
  padding: 0.7rem 0.85rem;
  border: 1px solid rgba(0, 180, 220, 0.15);
}

body.page-recharge .coin-feature-emoji {
  font-size: 1.3rem;
  line-height: 1;
  flex-shrink: 0;
  margin-top: 1px;
}

body.page-recharge .coin-feature-text h4 {
  font-size: 0.82rem;
  font-weight: 800;
  color: var(--rec-text);
  margin-bottom: 2px;
}

body.page-recharge .coin-feature-text p {
  font-size: 0.74rem;
  color: var(--rec-muted);
  line-height: 1.5;
}

body.page-recharge .coin-notices {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

body.page-recharge .coin-notice-item {
  display: flex;
  align-items: flex-start;
  gap: 0.45rem;
  font-size: 0.75rem;
  color: var(--rec-muted);
  line-height: 1.5;
}

body.page-recharge .coin-notice-item::before {
  content: '⚠';
  font-size: 0.72rem;
  color: var(--accent);
  flex-shrink: 0;
  margin-top: 2px;
}

body.page-recharge .coin-notice-item a {
  color: var(--primary-dark);
  font-weight: 700;
  text-decoration: none;
}

body.page-recharge .coin-notice-item a:hover {
  text-decoration: underline;
}

/* ---------- 政策勾选 ---------- */
body.page-recharge .policy-agree {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  margin: 1.1rem 0 0.95rem;
  padding: 1rem 1.05rem;
  background: rgba(0, 50, 80, 0.06);
  border: 1px solid rgba(0, 170, 220, 0.22);
  border-radius: 12px;
  cursor: pointer;
  transition: border-color 0.2s ease, background 0.2s ease;
}

body.page-recharge .policy-agree:has(#policyCheckbox:checked) {
  border-color: var(--jade);
  background: rgba(0, 210, 170, 0.12);
}

body.page-recharge .policy-agree input[type='checkbox'] {
  appearance: none;
  -webkit-appearance: none;
  width: 20px;
  height: 20px;
  min-width: 20px;
  border: 2px solid var(--primary-light);
  border-radius: 6px;
  background: #fff;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
  margin-top: 1px;
}

body.page-recharge .policy-agree input[type='checkbox']:checked {
  background: linear-gradient(135deg, var(--jade), var(--jade-dark));
  border-color: var(--jade);
}

body.page-recharge .policy-agree input[type='checkbox']:checked::after {
  content: '✓';
  color: white;
  font-size: 13px;
  font-weight: 800;
  line-height: 1;
  display: block;
  text-align: center;
}

body.page-recharge .policy-agree-text {
  font-size: 0.84rem;
  color: var(--rec-muted);
  line-height: 1.55;
}

body.page-recharge .policy-agree-text a {
  color: var(--primary-dark);
  font-weight: 700;
  text-decoration: none;
}

body.page-recharge .policy-agree-text a:hover {
  text-decoration: underline;
}

/* ---------- 卡品牌 ---------- */
body.page-recharge .card-brands {
  margin-top: 1.1rem;
  text-align: center;
}

body.page-recharge .card-brands-label {
  font-size: 0.74rem;
  color: var(--rec-muted);
  font-weight: 700;
  margin-bottom: 0.55rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

body.page-recharge .card-brands-row {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 0.45rem;
  flex-wrap: wrap;
}

body.page-recharge .card-brand-logo {
  height: 26px;
  border-radius: 5px;
  box-shadow: 0 1px 4px rgba(0, 40, 80, 0.12);
  display: block;
}

/* ---------- 页脚法务行 ---------- */
body.page-recharge .recharge-legal {
  text-align: center;
  padding: 1.5rem 1rem 0.5rem;
  font-size: 0.8rem;
  color: rgba(255, 255, 255, 0.88);
  line-height: 1.65;
}

body.page-recharge .recharge-legal a {
  color: #fff566;
  font-weight: 700;
  text-decoration: none;
}

body.page-recharge .recharge-legal a:hover {
  text-decoration: underline;
}

body.page-recharge .recharge-legal-sep {
  margin: 0 0.35rem;
  opacity: 0.45;
}

/* ---------- 滚动条 ---------- */
body.page-recharge ::-webkit-scrollbar {
  width: 8px;
}
body.page-recharge ::-webkit-scrollbar-track {
  background: rgba(0, 40, 70, 0.25);
}
body.page-recharge ::-webkit-scrollbar-thumb {
  background: rgba(0, 210, 255, 0.45);
  border-radius: 4px;
}
body.page-recharge ::-webkit-scrollbar-thumb:hover {
  background: rgba(0, 230, 255, 0.65);
}

/* ---------- 响应式 ---------- */
@media (max-width: 1024px) {
  body.page-recharge .package-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

@media (max-width: 768px) {
  body.page-recharge .nav-links {
    display: none;
  }
  body.page-recharge .mobile-menu-btn {
    display: flex;
  }
  body.page-recharge .input-grid {
    grid-template-columns: 1fr;
  }
  body.page-recharge .package-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  body.page-recharge .payment-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 480px) {
  body.page-recharge .package-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  body.page-recharge .coin-features {
    grid-template-columns: 1fr;
  }
}
