/* =============================================
   烬城互通 · 怀旧魔域三端同服 - 全局样式
   游戏暗色金色主题
   ============================================= */

/* ---------- 基础重置 ---------- */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  --gold:       #e8b840;
  --gold-light: #f5d778;
  --gold-dark:  #b8892a;
  --bg-deep:    #0b0c10;
  --bg-card:    #12141a;
  --bg-card2:   #181c24;
  --border:     #2e3040;
  --border-gold:#3d3010;
  --text-main:  #d4c8a0;
  --text-sub:   #8a8070;
  --text-white: #f0ead6;
  --red:        #e04040;
  --green:      #3ecf78;
  --shadow-gold:0 0 18px rgba(232,184,64,.25);
  --radius:     6px;
  --nav-h:      60px;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: "Noto Sans SC", "Microsoft YaHei", "PingFang SC", sans-serif;
  background: var(--bg-deep);
  color: var(--text-main);
  min-height: 100vh;
  line-height: 1.7;
  overflow-x: hidden;
}

a {
  color: var(--gold);
  text-decoration: none;
  transition: color .2s;
}
a:hover { color: var(--gold-light); }

ul { list-style: none; }

img { display: block; max-width: 100%; }

/* ---------- 导航栏 ---------- */
.navbar {
  position: sticky;
  top: 0;
  z-index: 900;
  background: rgba(11, 12, 16, .98);
  border-bottom: 1px solid var(--border);
}

.nav-wrap {
  max-width: 1200px;
  margin: 0 auto;
  height: var(--nav-h);
  padding: 0 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* Logo */
.logo {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.logo-img {
  height: 36px;
  width: auto;
  object-fit: contain;
}

.logo-text {
  font-family: "Noto Serif SC", serif;
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--gold);
  letter-spacing: 2px;
  white-space: nowrap;
}

.nav-left {
  display: flex;
  align-items: center;
  gap: 24px;
}

.nav-right {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

/* 移动端汉堡按钮 */
.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 38px;
  height: 38px;
  padding: 8px;
  background: transparent;
  border: 1px solid var(--border-gold);
  border-radius: var(--radius);
  cursor: pointer;
  flex-shrink: 0;
}

.nav-toggle span {
  display: block;
  width: 100%;
  height: 2px;
  background: var(--gold);
  border-radius: 2px;
  transition: transform .25s, opacity .25s;
}

.nav-toggle.active span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.nav-toggle.active span:nth-child(2) {
  opacity: 0;
}

.nav-toggle.active span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* 导航菜单 */
.nav-menu {
  display: flex;
  gap: 4px;
}

.nav-menu li a {
  display: block;
  padding: 6px 12px;
  font-size: .875rem;
  font-weight: 500;
  color: var(--text-main);
  border-radius: var(--radius);
  transition: background .2s, color .2s;
}

.nav-menu li a:hover,
.nav-menu li a.active {
  background: rgba(232,184,64,.12);
  color: var(--gold);
}

/* 注册按钮 */
.btn-register-nav {
  padding: 7px 18px;
  font-size: .875rem;
  font-weight: 600;
  border: 1px solid var(--gold-dark);
  border-radius: var(--radius);
  background: linear-gradient(135deg, #2a1e00 0%, #3d2d00 100%);
  color: var(--gold);
  cursor: pointer;
  letter-spacing: 1px;
  transition: all .2s;
  white-space: nowrap;
}

/* 手机端排行榜入口（桌面端隐藏） */
.btn-rank-nav {
  padding: 7px 14px;
  font-size: .875rem;
  font-weight: 600;
  border: 1px solid var(--gold-dark);
  border-radius: var(--radius);
  background: linear-gradient(135deg, #1a3000 0%, #2a4a00 100%);
  color: var(--gold);
  cursor: pointer;
  letter-spacing: 1px;
  transition: all .2s;
  white-space: nowrap;
  display: none;
}

.btn-rank-nav:hover {
  background: linear-gradient(135deg, #243a00 0%, #3a5a00 100%);
  color: #fff5d0;
}

.mobile-only {
  display: none;
}

.btn-register-nav:hover {
  background: linear-gradient(135deg, #3d2d00 0%, #5a4200 100%);
  border-color: var(--gold);
  box-shadow: var(--shadow-gold);
  color: var(--gold-light);
}

/* ---------- Hero 区域 ---------- */
.hero {
  min-height: 420px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 80px 24px 60px;
  background:
    radial-gradient(ellipse 80% 50% at 50% 40%, rgba(232,184,64,.08) 0%, transparent 70%),
    linear-gradient(180deg, rgba(15,16,24,.82) 0%, rgba(11,12,16,.88) 100%),
    url('./images/zhuye.png') center center / cover no-repeat;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    repeating-linear-gradient(0deg, transparent, transparent 39px, rgba(232,184,64,.04) 40px),
    repeating-linear-gradient(90deg, transparent, transparent 39px, rgba(232,184,64,.04) 40px);
  pointer-events: none;
}

.hero-title {
  font-family: "Noto Serif SC", serif;
  font-size: clamp(1.6rem, 4vw, 2.8rem);
  font-weight: 900;
  color: var(--gold);
  text-shadow: 0 0 30px rgba(232,184,64,.5), 0 2px 0 rgba(0,0,0,.6);
  letter-spacing: 4px;
  line-height: 1.3;
  margin-bottom: 16px;
  position: relative;
}

.hero-subtitle {
  font-size: clamp(.875rem, 2vw, 1.05rem);
  color: var(--text-sub);
  max-width: 560px;
  margin-bottom: 36px;
  position: relative;
}

.hero-actions {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  justify-content: center;
  position: relative;
}

.btn-hero {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 28px;
  font-size: 1rem;
  font-weight: 600;
  border-radius: var(--radius);
  cursor: pointer;
  transition: all .25s;
  letter-spacing: 1px;
  border: 1px solid var(--gold-dark);
  background: linear-gradient(135deg, #2a1e00 0%, #3d2d00 100%);
  color: var(--gold);
}

.btn-hero:hover {
  background: linear-gradient(135deg, #3d2d00 0%, #5a4200 100%);
  border-color: var(--gold);
  box-shadow: var(--shadow-gold);
  color: var(--gold-light);
  transform: translateY(-1px);
}

.btn-hero svg {
  flex-shrink: 0;
}

.btn-hero-outline {
  background: transparent;
  color: var(--gold);
}

.btn-hero-outline:hover {
  background: rgba(232,184,64,.1);
}

/* ---------- 通用 Frame 装饰卡片 ---------- */
.frame {
  position: relative;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
  overflow: hidden;
  transition: border-color .2s, box-shadow .2s;
}

.frame:hover {
  border-color: var(--border-gold);
  box-shadow: var(--shadow-gold);
}

/* 角落装饰 */
.corner-bl,
.corner-br {
  position: absolute;
  width: 12px;
  height: 12px;
  border-color: var(--gold-dark);
  border-style: solid;
  opacity: .7;
}
.corner-bl {
  bottom: 6px; left: 6px;
  border-width: 0 0 1px 1px;
}
.corner-br {
  bottom: 6px; right: 6px;
  border-width: 0 1px 1px 0;
}

/* ---------- 主内容区 ---------- */
.content {
  max-width: 1200px;
  margin: 40px auto 0;
  padding: 0 20px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}

/* 公告卡片 */
.notice-card {
  cursor: pointer;
}

.notice-card h3 {
  font-family: "Noto Serif SC", serif;
  font-size: 1.05rem;
  color: var(--gold);
  font-weight: 700;
  letter-spacing: 2px;
  margin-bottom: 16px;
}

.notice-card h3 span {
  color: var(--gold-dark);
  margin-right: 4px;
}

.notice-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.notice-list li {
  padding-left: 14px;
  position: relative;
  font-size: .9rem;
  color: var(--text-main);
  line-height: 1.6;
}

.notice-list li::before {
  content: '▸';
  position: absolute;
  left: 0;
  color: var(--gold-dark);
}

/* 福利卡片 */
.welfare-card {
  cursor: pointer;
}

.welfare-tabs {
  display: flex;
  gap: 0;
  margin-bottom: 20px;
  border-bottom: 1px solid var(--border);
}

.welfare-tabs span {
  padding: 8px 18px;
  font-size: .875rem;
  color: var(--text-sub);
  cursor: pointer;
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
  transition: color .2s, border-color .2s;
}

.welfare-tabs span.active {
  color: var(--gold);
  border-bottom-color: var(--gold);
}

.welfare-tabs span:hover {
  color: var(--gold-light);
}

.welfare-flow {
  display: flex;
  align-items: center;
  justify-content: space-around;
  flex-wrap: wrap;
  gap: 12px;
  padding-top: 8px;
}

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

.welfare-icon {
  width: 54px;
  height: 54px;
  background: rgba(232,184,64,.08);
  border: 1px solid var(--border-gold);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
}

.welfare-label {
  font-size: .8rem;
  color: var(--text-sub);
  text-align: center;
}

.welfare-arrow {
  font-size: .75rem;
  color: var(--gold-dark);
  letter-spacing: 1px;
}

.vip-preview-bar {
  margin-top: 20px;
  padding: 14px 18px;
  background: rgba(232,184,64,.06);
  border: 1px solid var(--border-gold);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}

.vip-preview-bar span {
  color: var(--text-sub);
  font-size: .9rem;
}

.btn-vip-view {
  background: linear-gradient(135deg, var(--gold-dark), var(--gold));
  color: #0b0c10;
  padding: 8px 18px;
  border-radius: 20px;
  text-decoration: none;
  font-size: .85rem;
  font-weight: 600;
  transition: opacity .2s;
}

.btn-vip-view:hover {
  opacity: .85;
}

/* ---------- 特色区域 ---------- */
.features {
  max-width: 1200px;
  margin: 24px auto 40px;
  padding: 0 20px;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}

.feature-card {
  cursor: pointer;
  text-align: center;
  padding: 28px 16px;
}

.feature-card h4 {
  font-family: "Noto Serif SC", serif;
  font-size: 1rem;
  font-weight: 700;
  color: var(--gold);
  letter-spacing: 1px;
  margin-bottom: 10px;
}

.feature-card p {
  font-size: .825rem;
  color: var(--text-sub);
  line-height: 1.6;
}

.channel-info {
  background: rgba(255,255,255,.04);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
  margin: 16px 0;
  font-size: .9rem;
}
.channel-info p {
  margin-bottom: 8px;
  color: var(--text-sub);
}
.channel-info p:last-child {
  margin-bottom: 0;
}
.channel-info a {
  color: var(--gold);
  text-decoration: underline;
}
.channel-info a:hover {
  color: var(--gold-light);
}

/* ---------- 游戏介绍弹窗 ---------- */
.game-intro-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.game-intro-list li {
  padding: 12px 14px;
  background: rgba(232,184,64,.05);
  border: 1px solid var(--border-gold);
  border-radius: var(--radius);
  color: var(--text-main);
  line-height: 1.6;
}

.game-intro-pager {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  margin-top: 20px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
}

.game-intro-pager .btn-sm {
  padding: 8px 18px;
  font-size: .85rem;
}

.game-intro-pager .btn-sm:disabled {
  opacity: .45;
  cursor: not-allowed;
}

.game-intro-page-num {
  color: var(--gold);
  font-weight: 600;
  min-width: 60px;
  text-align: center;
}

/* ---------- 页脚 ---------- */
.footer {
  background: var(--bg-card);
  border-top: 1px solid var(--border);
  text-align: center;
  padding: 32px 24px 24px;
  color: var(--text-sub);
  font-size: .8rem;
  line-height: 1.8;
  position: relative;
}

.footer p { margin-bottom: 4px; }

.legal-tip {
  max-width: 720px;
  margin: 12px auto 0;
  font-size: .75rem;
  color: #5a5548;
  line-height: 1.7;
}

.watermark {
  display: inline-block;
  margin-top: 16px;
  padding: 2px 10px;
  font-size: .7rem;
  color: #443e30;
  border: 1px solid #2e2a1e;
  border-radius: 20px;
}

/* ---------- 弹窗 ---------- */
.modal-backdrop {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 1000;
  background: rgba(5, 6, 10, .75);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.modal-backdrop.open {
  display: flex;
  animation: backdropIn .2s ease;
}

@keyframes backdropIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}

.modal {
  background: var(--bg-card2);
  border: 1px solid var(--border-gold);
  border-radius: var(--radius);
  width: 100%;
  max-width: 480px;
  max-height: 90vh;
  overflow-y: auto;
  padding: 32px 28px 28px;
  position: relative;
  box-shadow: 0 8px 40px rgba(0,0,0,.7), var(--shadow-gold);
  animation: modalIn .22s ease;
}

/* 排行榜弹窗加宽 */
.modal.modal-rank {
  max-width: 900px;
  padding: 28px 20px 20px;
}

/* ---- 排行榜内嵌样式 ---- */
.rank-wrap { width: 100%; }

.rank-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 14px;
}

.rank-tab-btn {
  padding: 6px 16px;
  border-radius: 20px;
  border: 1px solid var(--border);
  background: var(--bg-card);
  color: var(--text-main);
  font-size: .82rem;
  cursor: pointer;
  transition: all .2s;
}
.rank-tab-btn:hover {
  border-color: var(--gold-dark);
  background: rgba(42,30,0,.8);
}
.rank-tab-btn.active {
  background: linear-gradient(135deg, #2a1e00, #5a4200);
  border-color: var(--gold);
  color: var(--gold-light);
  font-weight: 600;
}

.rank-server-info {
  font-size: .78rem;
  color: var(--text-sub);
  margin-bottom: 10px;
}

/* 区服选择行 */
.rank-server-row {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 14px;
}
.rank-server-label {
  font-size: .85rem;
  color: var(--gold);
  white-space: nowrap;
}
.rank-server-select {
  background: var(--bg-card);
  border: 1px solid var(--border-gold);
  border-radius: 6px;
  color: var(--text-main);
  padding: 6px 28px 6px 12px;
  font-size: .85rem;
  cursor: pointer;
  appearance: none;
  -webkit-appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6'%3E%3Cpath d='M0 0l5 6 5-6z' fill='%23e8b840'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 10px center;
  transition: border-color .2s;
}
.rank-server-select:hover,
.rank-server-select:focus {
  border-color: var(--gold);
  outline: none;
  box-shadow: 0 0 0 2px rgba(232,184,64,.2);
}

/* 刷新按钮 */
.rank-refresh-btn {
  margin-left: auto;
  background: transparent;
  border: 1px solid var(--border-gold);
  border-radius: 6px;
  color: var(--gold);
  padding: 6px 14px;
  font-size: .82rem;
  cursor: pointer;
  transition: background .2s, color .2s;
}
.rank-refresh-btn:hover {
  background: var(--gold);
  color: #1a1505;
}

/* 状态提示（服务器未开放/关闭排名/冷却等） */
.rank-status {
  padding: 40px 20px;
  text-align: center;
  color: var(--text-sub);
  font-size: .9rem;
}
.rank-cooldown {
  padding: 36px 20px;
  text-align: center;
  color: var(--gold);
  font-size: 1rem;
  line-height: 1.8;
}
.rank-cooldown .fa-clock { margin-right: 6px; }
.rank-cd-hint {
  font-size: .75rem;
  color: var(--text-sub);
  margin-top: 6px;
}

/* 前三名高亮 */
.rank-table tbody tr.rank-top1 td:first-child { color: #ffd700; font-weight: 700; }
.rank-table tbody tr.rank-top2 td:first-child { color: #c0c0c0; font-weight: 700; }
.rank-table tbody tr.rank-top3 td:first-child { color: #cd7f32; font-weight: 700; }
.rank-table tbody tr.rank-top1 { background: rgba(255,215,0,.06); }
.rank-table tbody tr.rank-top2 { background: rgba(192,192,192,.05); }
.rank-table tbody tr.rank-top3 { background: rgba(205,127,50,.05); }

.rank-table-box {
  overflow-x: auto;
  border: 1px solid var(--border-gold);
  border-radius: var(--radius);
  background: var(--bg-card);
  min-height: 120px;
}

.rank-table {
  width: 100%;
  border-collapse: collapse;
  font-size: .85rem;
  min-width: 520px;
}
.rank-table th {
  background: linear-gradient(90deg, #2a1e00, #5a4200);
  color: var(--gold-light);
  padding: 10px 12px;
  text-align: left;
  font-weight: 600;
  white-space: nowrap;
}
.rank-table td {
  padding: 9px 12px;
  border-bottom: 1px solid rgba(61,48,16,.35);
  color: var(--text-main);
}
.rank-table tr:hover td { background: rgba(42,30,0,.35); }
.rank-table td:first-child { color: var(--gold); font-weight: 700; text-align: center; width: 50px; }
.rank-table tr:nth-child(1) td { background: rgba(255,215,0,.07); }
.rank-table tr:nth-child(2) td { background: rgba(192,192,192,.05); }
.rank-table tr:nth-child(3) td { background: rgba(205,127,50,.07); }

.rank-loading, .rank-empty {
  text-align: center;
  padding: 36px 20px;
  color: var(--text-sub);
  font-size: .9rem;
}

.rank-update-time {
  text-align: right;
  font-size: .75rem;
  color: var(--text-sub);
  margin-top: 8px;
}

@keyframes modalIn {
  from { opacity: 0; transform: translateY(-12px) scale(.97); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}

.modal::-webkit-scrollbar { width: 4px; }
.modal::-webkit-scrollbar-track { background: transparent; }
.modal::-webkit-scrollbar-thumb { background: var(--border-gold); border-radius: 4px; }

.modal-close {
  position: absolute;
  top: 14px; right: 16px;
  font-size: 1.4rem;
  line-height: 1;
  background: none;
  border: none;
  color: var(--text-sub);
  cursor: pointer;
  padding: 4px 6px;
  border-radius: 4px;
  transition: color .2s, background .2s;
}
.modal-close:hover {
  color: var(--text-white);
  background: rgba(255,255,255,.07);
}

.modal-title {
  font-family: "Noto Serif SC", serif;
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--gold);
  letter-spacing: 2px;
  margin-bottom: 20px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border);
}

.modal-body {
  font-size: .9rem;
  color: var(--text-main);
  line-height: 1.7;
}

.modal-body p { margin-bottom: 10px; }

.modal-body .text-center { text-align: center; }

/* ---------- 下载弹窗 ---------- */
.download-grid {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 10px;
  margin: 14px 0;
}

.download-latest {
  background: rgba(232,184,64,.04);
  border: 1px solid var(--border-gold);
  border-radius: var(--radius);
  padding: 16px;
  margin-bottom: 14px;
}

.download-version-badge {
  display: inline-block;
  padding: 4px 14px;
  background: linear-gradient(135deg, #2a1e00, #5a4200);
  border: 1px solid var(--gold);
  border-radius: 20px;
  color: var(--gold-light);
  font-weight: 700;
  letter-spacing: 1px;
  margin-bottom: 10px;
}

.download-size {
  font-size: .82rem;
  color: var(--text-sub);
  margin-bottom: 8px;
}

.download-desc {
  font-size: .85rem;
  color: var(--text-main);
  line-height: 1.7;
  margin-bottom: 12px;
}

.download-history {
  border-top: 1px solid var(--border);
  padding-top: 12px;
}

.download-history h4 {
  font-family: "Noto Serif SC", serif;
  color: var(--gold);
  font-size: .95rem;
  margin-bottom: 10px;
}

.download-history-item {
  padding: 10px;
  background: rgba(255,255,255,.02);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  margin-bottom: 8px;
}

.download-version {
  display: inline-block;
  font-weight: 700;
  color: var(--gold);
  margin-right: 8px;
}

.download-meta {
  font-size: .78rem;
  color: var(--text-sub);
}

.download-history-link {
  display: inline-block;
  margin-top: 6px;
  margin-right: 8px;
  font-size: .8rem;
  color: var(--gold-dark);
  text-decoration: underline;
  text-underline-offset: 2px;
}

/* ---------- 通用按钮 ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 20px;
  font-size: .875rem;
  font-weight: 600;
  border-radius: var(--radius);
  cursor: pointer;
  transition: all .2s;
  border: 1px solid transparent;
  letter-spacing: .5px;
}

.btn-primary {
  background: linear-gradient(135deg, #2a1e00 0%, #3d2d00 100%);
  border-color: var(--gold-dark);
  color: var(--gold);
}
.btn-primary:hover {
  background: linear-gradient(135deg, #3d2d00 0%, #5a4200 100%);
  border-color: var(--gold);
  color: var(--gold-light);
  box-shadow: var(--shadow-gold);
}

.btn:disabled {
  opacity: .5;
  cursor: not-allowed;
  pointer-events: none;
}

/* ---------- 注册 / 修改密码模式切换 ---------- */
.auth-mode-tabs {
  display: flex;
  gap: 8px;
  margin-bottom: 16px;
  border-bottom: 1px solid var(--border);
  padding-bottom: 12px;
}
.auth-mode-btn {
  flex: 1;
  padding: 8px 12px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--text-sub);
  font-size: .85rem;
  font-weight: 500;
  cursor: pointer;
  transition: all .2s;
  letter-spacing: .5px;
}
.auth-mode-btn:hover {
  border-color: var(--gold-dark);
  color: var(--gold);
}
.auth-mode-btn.active {
  background: linear-gradient(135deg, #2a1e00, #5a4200);
  border-color: var(--gold);
  color: var(--gold-light);
  font-weight: 600;
}

/* ---------- 注册表单 ---------- */
.form-group {
  margin-bottom: 16px;
}

.form-group label {
  display: block;
  font-size: .8rem;
  color: var(--text-sub);
  margin-bottom: 6px;
  letter-spacing: .5px;
}

.form-input {
  width: 100%;
  padding: 10px 12px;
  background: rgba(255,255,255,.04);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--text-white);
  font-size: .9rem;
  outline: none;
  transition: border-color .2s, box-shadow .2s;
}

.form-input::placeholder { color: #4a4640; }

.form-input:focus {
  border-color: var(--gold-dark);
  box-shadow: 0 0 0 2px rgba(232,184,64,.1);
}

.code-row,
.captcha-row {
  display: flex;
  gap: 10px;
}

.code-row .form-input,
.captcha-row .form-input {
  flex: 1;
}

.phone-input-wrap,
.input-feedback-row {
  display: flex;
  align-items: center;
  gap: 10px;
}

.phone-input-wrap .form-input,
.input-feedback-row .form-input {
  flex: 1;
  min-width: 0;
}

.phone-error,
.field-feedback {
  flex-shrink: 0;
  max-width: 120px;
  font-size: .75rem;
  line-height: 1.3;
  opacity: 0;
  transition: opacity .2s;
}

.phone-error {
  color: #ff8080;
}

.field-feedback.valid {
  opacity: 1;
  color: #3ecf78;
}

.field-feedback.invalid {
  opacity: 1;
  color: #ff8080;
}

.field-feedback.captcha-feedback,
.field-feedback.code-feedback,
.field-feedback.agree-feedback {
  display: block;
  max-width: 100%;
  margin-top: 4px;
}

.required {
  color: #ff8080;
  margin-left: 2px;
}

.captcha-img {
  flex-shrink: 0;
  width: 100px;
  height: 42px;
  border: 1px solid var(--gold-dark);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, .05);
  cursor: pointer;
  object-fit: cover;
}

.btn-code {
  flex-shrink: 0;
  padding: 0 14px;
  height: 42px;
  font-size: .8rem;
  font-weight: 600;
  border: 1px solid var(--gold-dark);
  border-radius: var(--radius);
  background: linear-gradient(135deg, #1e1600 0%, #2a1e00 100%);
  color: var(--gold);
  cursor: pointer;
  white-space: nowrap;
  transition: all .2s;
}
.btn-code:hover:not(:disabled) {
  background: linear-gradient(135deg, #2a1e00 0%, #3d2d00 100%);
  border-color: var(--gold);
}
.btn-code:disabled {
  opacity: .5;
  cursor: not-allowed;
}

/* 协议勾选 */
.agreement {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 16px;
  font-size: .8rem;
  color: var(--text-sub);
}

.agreement input[type="checkbox"] {
  width: 15px;
  height: 15px;
  accent-color: var(--gold);
  cursor: pointer;
  flex-shrink: 0;
}

.agreement a {
  color: var(--gold-dark);
  text-decoration: underline;
  text-underline-offset: 2px;
}

/* 消息提示 */
.msg-tip {
  margin-top: 12px;
  font-size: .825rem;
  min-height: 20px;
  transition: color .2s;
}
.msg-error { color: var(--red); }
.msg-success { color: var(--green); }

.form-hint {
  font-size: .775rem;
  color: var(--text-sub);
  margin-top: 8px;
  padding: 6px 10px;
  background: rgba(255,255,255,.03);
  border-left: 2px solid var(--border-gold);
  border-radius: 0 var(--radius) var(--radius) 0;
}

/* ---------- 会员详情预览 ---------- */
.vip-mini-list {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin: 14px 0;
}

.vip-mini-card {
  background: rgba(232,184,64,.06);
  border: 1px solid var(--border-gold);
  border-radius: var(--radius);
  padding: 10px;
  display: flex;
  align-items: center;
  gap: 10px;
  transition: background .2s;
}

.vip-mini-card:hover {
  background: rgba(232,184,64,.12);
}

.vip-mini-icon {
  font-size: 1.6rem;
  flex-shrink: 0;
}

.vip-mini-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.vip-mini-info strong {
  color: var(--gold-light);
  font-size: .85rem;
}

.vip-mini-info span {
  color: var(--text-sub);
  font-size: .75rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.vip-more-line {
  text-align: center;
  margin: 16px 0 6px;
}

/* ---------- 会员卡片网格（main.js applyVip） ---------- */
#vipGrid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 16px;
}

.vip-card {
  background: linear-gradient(135deg, #1a1610, #0f1014);
  border: 1px solid var(--border-gold);
  border-radius: var(--radius);
  padding: 18px 14px;
  text-align: center;
  cursor: pointer;
  transition: transform .25s, border-color .25s;
}

.vip-card:hover {
  transform: translateY(-3px);
  border-color: var(--gold);
}

.vip-card-icon {
  font-size: 2.2rem;
  margin-bottom: 6px;
}

.vip-card-level {
  color: var(--gold-dark);
  font-size: .7rem;
  letter-spacing: 2px;
}

.vip-card-name {
  color: var(--gold-light);
  font-size: 1.05rem;
  margin: 4px 0 8px;
}

.vip-card-desc {
  color: var(--text-sub);
  font-size: .8rem;
  line-height: 1.4;
  margin-bottom: 10px;
}

.vip-card-benefits {
  list-style: none;
  text-align: left;
}

.vip-card-benefits li {
  color: #c8bca0;
  font-size: .78rem;
  padding: 4px 0 4px 14px;
  position: relative;
}

.vip-card-benefits li::before {
  content: '✔';
  position: absolute;
  left: 0;
  color: var(--success, #3ecf78);
  font-size: .7rem;
}

.vip-card-benefits .vip-more {
  color: var(--gold);
  text-align: center;
  padding-left: 0;
}

.vip-empty {
  text-align: center;
  color: var(--text-sub);
  padding: 30px;
}

/* ---------- 公告弹窗列表 ---------- */
.notice-list-modal {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.notice-list-modal li {
  padding: 10px 12px 10px 28px;
  position: relative;
  background: rgba(232,184,64,.04);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-size: .875rem;
  line-height: 1.6;
}

.notice-list-modal li::before {
  content: '◆';
  position: absolute;
  left: 10px;
  top: 11px;
  font-size: .6rem;
  color: var(--gold-dark);
}

/* ---------- 福利奖励弹窗列表 ---------- */
.reward-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 8px;
}

.reward-list li {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 12px;
  background: rgba(232,184,64,.04);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

.reward-step {
  width: 26px;
  height: 26px;
  background: linear-gradient(135deg, #2a1e00, #3d2d00);
  border: 1px solid var(--gold-dark);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: .8rem;
  font-weight: 700;
  color: var(--gold);
  flex-shrink: 0;
  margin-top: 2px;
}

.reward-title {
  font-size: .9rem;
  font-weight: 600;
  color: var(--gold-light);
  margin-bottom: 2px;
}

.reward-desc {
  font-size: .8rem;
  color: var(--text-sub);
}

/* ---------- 排行榜弹窗 ---------- */
.rank-table {
  width: 100%;
  border-collapse: collapse;
  font-size: .825rem;
  margin: 12px 0 8px;
}

.rank-table th,
.rank-table td {
  padding: 8px 10px;
  text-align: center;
  border: 1px solid var(--border);
}

.rank-table th {
  background: rgba(232,184,64,.08);
  color: var(--gold);
  font-weight: 600;
  font-size: .775rem;
  letter-spacing: .5px;
}

.rank-table td { color: var(--text-main); }

.rank-table tr:nth-child(even) td {
  background: rgba(255,255,255,.02);
}

.rank-table tr:hover td {
  background: rgba(232,184,64,.05);
}

.rank-table tr:nth-child(2) td:first-child { color: #ffd700; font-weight: 700; }
.rank-table tr:nth-child(3) td:first-child { color: #c0c0c0; font-weight: 700; }
.rank-table tr:nth-child(4) td:first-child { color: #cd7f32; font-weight: 700; }

/* ---------- Toast 提示 ---------- */
.toast {
  position: fixed;
  top: 80px;
  left: 50%;
  transform: translateX(-50%) translateY(-16px);
  z-index: 1100;
  background: rgba(20, 22, 30, .95);
  border: 1px solid var(--border-gold);
  color: var(--gold-light);
  padding: 10px 24px;
  border-radius: 24px;
  font-size: .875rem;
  font-weight: 500;
  letter-spacing: .5px;
  pointer-events: none;
  opacity: 0;
  transition: opacity .3s, transform .3s;
  box-shadow: 0 4px 20px rgba(0,0,0,.6);
  white-space: nowrap;
}

.toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

/* ---------- 响应式 ---------- */
@media (max-width: 900px) {
  .features {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 768px) {
  .nav-menu {
    position: fixed;
    top: var(--nav-h);
    left: 0;
    width: 100vw;
    height: calc(100dvh - var(--nav-h));
    background: rgba(11, 12, 16, .98);
    border-top: 1px solid var(--border-gold);
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    padding-top: 24px;
    gap: 8px;
    z-index: 899;
    transform: translateX(100%);
    transition: transform .3s ease;
    display: flex;
    box-sizing: border-box;
  }

  .nav-menu.open {
    transform: translateX(0);
  }

  .nav-menu li {
    width: 100%;
    max-width: 400px;
    text-align: center;
  }

  .nav-menu li a {
    padding: 14px 20px;
    font-size: 1rem;
    display: block;
  }

  .nav-toggle {
    display: flex;
  }

  .mobile-only,
  .btn-rank-nav {
    display: inline-flex;
    align-items: center;
  }

  .nav-wrap {
    padding: 0 12px;
  }

  .btn-register-nav {
    padding: 7px 12px;
    font-size: .8rem;
  }

  .btn-rank-nav {
    padding: 7px 10px;
    font-size: .8rem;
  }

  .logo-text {
    font-size: .95rem;
    letter-spacing: 1px;
  }

  .hero {
    padding: 60px 16px 40px;
    min-height: 320px;
  }

  .hero-title {
    letter-spacing: 2px;
  }

  .content {
    grid-template-columns: 1fr;
    margin-top: 24px;
    padding: 0 16px;
  }

  .features {
    grid-template-columns: 1fr 1fr;
    padding: 0 16px;
    margin-bottom: 24px;
  }

  .welfare-flow {
    gap: 8px;
  }

  .download-grid {
    grid-template-columns: 1fr;
  }

  .modal {
    padding: 24px 20px 20px;
  }

  .vip-mini-list {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 480px) {
  .logo-img {
    height: 28px;
  }

  .btn-rank-nav,
  .btn-register-nav {
    padding: 6px 8px;
    font-size: .75rem;
    letter-spacing: 0;
  }

  .nav-wrap {
    gap: 8px;
  }

  .features {
    grid-template-columns: 1fr;
  }

  .hero-actions {
    flex-direction: column;
    align-items: stretch;
  }

  .btn-hero {
    justify-content: center;
  }

  .rank-table {
    font-size: .75rem;
  }

  .rank-table th,
  .rank-table td {
    padding: 6px 6px;
  }
}

/* ===== 社群弹窗样式 ===== */
.community-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin: 0 auto;
  max-width: 480px;
}
@media (max-width: 480px) {
  .community-grid { grid-template-columns: 1fr; max-width: 260px; }
}
.community-card {
  background: rgba(255,255,255,.04);
  border: 1px solid var(--border-gold);
  border-radius: 12px;
  padding: 20px 16px;
  text-align: center;
  transition: box-shadow .2s, border-color .2s;
}
.community-card:hover {
  box-shadow: 0 0 16px rgba(200,169,110,.25);
  border-color: var(--gold);
}
.community-card-icon {
  font-size: 1.8rem;
  margin-bottom: 6px;
}
.community-card-name {
  font-size: .95rem;
  color: var(--gold);
  margin: 0 0 12px;
  font-weight: 600;
}
.community-qr-wrap {
  width: 140px;
  height: 140px;
  margin: 0 auto 10px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.community-qr-img {
  width: 140px;
  height: 140px;
  object-fit: contain;
  border-radius: 8px;
  border: 2px solid var(--border-gold);
  background: #fff;
  cursor: pointer;
  transition: transform .15s;
}
.community-qr-img:hover { transform: scale(1.04); }
.community-qr-link { display: block; }
.community-qr-placeholder {
  width: 140px;
  height: 140px;
  border: 2px dashed var(--border-gold);
  border-radius: 8px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  color: #8a8070;
  font-size: 2rem;
}
.community-qr-placeholder span {
  font-size: .75rem;
  line-height: 1.4;
  text-align: center;
}
.community-card-desc {
  font-size: .8rem;
  color: #a09080;
  margin: 0 0 12px;
  line-height: 1.4;
}
.community-join-btn {
  display: inline-block;
  padding: 6px 20px;
  font-size: .85rem;
  text-decoration: none;
  border-radius: 6px;
}
