/* ==================== 变量 ==================== */
:root {
  --primary: #111111;
  --bg-main: #ffffff;
  --bg-section: #f7f7f7;
  --bg-card: #ffffff;
  --bg-card-hover: #fafafa;
  --border: rgba(0, 0, 0, 0.06);
  --border-hover: rgba(0, 0, 0, 0.14);
  --text-primary: #111111;
  --text-secondary: #555555;
  --text-muted: #999999;
  --radius: 14px;
  --radius-sm: 10px;
  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.04), 0 1px 2px rgba(0, 0, 0, 0.03);
  --shadow: 0 4px 20px rgba(0, 0, 0, 0.06);
  --shadow-lg: 0 12px 40px rgba(0, 0, 0, 0.08);
  --container-width: 1200px;
  --font: 'Inter', -apple-system, BlinkMacSystemFont, 'Noto Sans SC', sans-serif;
}

body {
  font-family: var(--font);
  background: var(--bg-main);
  color: var(--text-primary);
  -webkit-font-smoothing: antialiased;
}

.container {
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 0 20px;
}

/* ==================== 导航栏 ==================== */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  padding: 16px 0;
  transition: all 0.3s;
}

.navbar.scrolled {
  background: rgba(255, 255, 255, 0.88);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  padding: 10px 0;
  border-bottom: 1px solid var(--border);
}

.navbar-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-logo {
  font-size: 18px;
  font-weight: 700;
  color: var(--text-primary);
  letter-spacing: -0.5px;
  transition: color 0.3s;
}

.nav-links {
  display: flex;
  gap: 32px;
}

.nav-links a {
  font-size: 14px;
  font-weight: 500;
  color: var(--text-muted);
  transition: color 0.2s;
}

.nav-links a:hover {
  color: var(--text-primary);
}

/* 导航栏自适应深色 Hero */
.navbar.navbar--dark:not(.scrolled) .nav-logo { color: #f0f0f0; }
.navbar.navbar--dark:not(.scrolled) .nav-toggle span { background: #f0f0f0; }
.navbar.navbar--dark:not(.scrolled) .nav-links a { color: rgba(255,255,255,0.5); }
.navbar.navbar--dark:not(.scrolled) .nav-links a:hover { color: #fff; }

.navbar.navbar--dark.scrolled {
  background: rgba(10, 10, 10, 0.92);
  border-bottom-color: rgba(255,255,255,0.08);
}
.navbar.navbar--dark.scrolled .nav-logo { color: #f0f0f0; }
.navbar.navbar--dark.scrolled .nav-links a { color: rgba(255,255,255,0.5); }
.navbar.navbar--dark.scrolled .nav-links a:hover { color: #fff; }
.navbar.navbar--dark.scrolled .nav-toggle span { background: #f0f0f0; }

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
}

.nav-toggle span {
  width: 24px;
  height: 2px;
  background: var(--text-primary);
  transition: all 0.3s;
}

/* ==================== Hero ==================== */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  overflow: hidden;
}

.hero-bg {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse at 30% 20%, rgba(0, 0, 0, 0.015) 0%, transparent 60%),
    radial-gradient(ellipse at 70% 80%, rgba(0, 0, 0, 0.01) 0%, transparent 60%),
    var(--bg-main);
  z-index: 0;
  transition: background 0.6s ease;
}

.hero-content {
  position: relative;
  z-index: 1;
}

.hero {
  --hero-text: var(--text-primary);
  --hero-text-sub: var(--text-secondary);
  --hero-text-muted: var(--text-muted);
  --hero-divider: var(--border);
  --hero-addr-bg: var(--bg-section);
  --hero-addr-border: var(--border);
  --hero-btn-bg: var(--text-primary);
  --hero-btn-color: #fff;
}

.hero-title {
  font-size: 56px;
  font-weight: 800;
  letter-spacing: -2px;
  margin-bottom: 16px;
  color: var(--hero-text);
}

.hero-motd-wrap {
  margin-bottom: 40px;
  display: flex;
  justify-content: center;
}

.hero--dark .hero-motd {
  background: rgba(255,255,255,0.1);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.hero-motd {
  display: inline-block;
  background: #1a1a1a;
  color: #aaaaaa;
  font-family: 'JetBrains Mono', monospace;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  font-size: 14px;
  letter-spacing: 0.02em;
  padding: 10px 24px;
  border-radius: 8px;
  max-width: 700px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.hero-stats {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 48px;
  margin-bottom: 48px;
}

.hero-stat {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.hero-stat-value {
  font-size: 36px;
  font-weight: 700;
  color: var(--hero-text);
}

.hero-stat-label {
  font-size: 12px;
  color: var(--hero-text-muted);
  margin-top: 4px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.hero-stat-divider {
  width: 1px;
  height: 40px;
  background: var(--hero-divider);
}

.status-dot {
  display: inline-block;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--text-muted);
  transition: background 0.3s;
}

.hero-address {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  background: var(--hero-addr-bg);
  border: 1px solid var(--hero-addr-border);
  border-radius: 50px;
  padding: 12px 12px 12px 24px;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.address-label {
  font-size: 13px;
  color: var(--hero-text-muted);
}

.address-value {
  font-size: 15px;
  font-weight: 500;
  color: var(--hero-text);
  font-family: 'JetBrains Mono', monospace;
  letter-spacing: 0.03em;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

.copy-btn {
  padding: 8px 18px;
  border-radius: 20px;
  background: var(--hero-btn-bg);
  color: var(--hero-btn-color);
  font-size: 13px;
  font-weight: 600;
  transition: opacity 0.2s;
  display: inline-flex;
  align-items: center;
}

.copy-btn:hover {
  opacity: 0.8;
}

/* ==================== Section ==================== */
.section {
  padding: 100px 0;
}

.section-dark {
  background: var(--bg-section);
}

.section-title {
  font-size: 30px;
  font-weight: 700;
  text-align: center;
  margin-bottom: 48px;
  letter-spacing: -0.5px;
  color: var(--text-primary);
}

/* ==================== 状态卡片 ==================== */
.status-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-bottom: 48px;
}

.status-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px 24px;
  text-align: center;
  transition: all 0.25s;
  box-shadow: var(--shadow-sm);
}

.status-card:hover {
  border-color: var(--border-hover);
  transform: translateY(-3px);
  box-shadow: var(--shadow);
}

.status-card-icon {
  margin-bottom: 16px;
  color: var(--text-muted);
}

.status-card-icon svg {
  width: 26px;
  height: 26px;
  stroke-width: 1.5;
}

.status-card-value {
  font-size: 24px;
  font-weight: 700;
  margin-bottom: 6px;
  color: var(--text-primary);
}

.status-card-label {
  font-size: 11px;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 500;
}

/* ==================== 玩家列表 ==================== */
.player-list-section {
  margin-bottom: 48px;
}

.player-list-section h3 {
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 16px;
  color: var(--text-secondary);
}

.player-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.player-tag {
  padding: 6px 14px;
  background: var(--bg-section);
  border: 1px solid var(--border);
  border-radius: 20px;
  font-size: 13px;
  color: var(--text-secondary);
  font-weight: 500;
}

/* ==================== 图表 ==================== */
.chart-section h3 {
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 16px;
  color: var(--text-secondary);
}

/* ==================== 图集 ==================== */
.gallery-categories,
.news-categories {
  display: flex;
  justify-content: center;
  gap: 10px;
  margin-bottom: 32px;
  flex-wrap: wrap;
}

.cat-btn {
  padding: 8px 20px;
  border-radius: 20px;
  font-size: 14px;
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text-muted);
  cursor: pointer;
  transition: all 0.2s;
  font-weight: 500;
}

.cat-btn:hover {
  border-color: var(--border-hover);
  color: var(--text-primary);
}

.cat-btn.active {
  background: var(--text-primary);
  border-color: var(--text-primary);
  color: #fff;
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 16px;
}

.gallery-item {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  cursor: pointer;
  aspect-ratio: 16 / 10;
  background: var(--bg-section);
}

.gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s;
}

.gallery-item:hover img {
  transform: scale(1.05);
}

.gallery-item-title {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 24px 16px 14px;
  background: linear-gradient(transparent, rgba(0, 0, 0, 0.7));
  font-size: 14px;
  font-weight: 500;
  color: #fff;
}

/* ==================== 动态 ==================== */
.news-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.news-card {
  display: flex;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  cursor: pointer;
  transition: all 0.25s;
  box-shadow: var(--shadow-sm);
}

.news-card:hover {
  border-color: var(--border-hover);
  transform: translateY(-3px);
  box-shadow: var(--shadow);
}

.news-cover {
  width: 240px;
  min-height: 160px;
  flex-shrink: 0;
}

.news-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.news-body {
  padding: 20px 24px;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.news-title {
  font-size: 18px;
  font-weight: 600;
  margin-bottom: 8px;
  color: var(--text-primary);
}

.pin-tag {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 4px;
  background: var(--text-primary);
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  margin-right: 8px;
  vertical-align: middle;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.news-summary {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.7;
  flex: 1;
}

.news-meta {
  display: flex;
  gap: 16px;
  font-size: 13px;
  color: var(--text-muted);
  margin-top: 12px;
}

.empty-text {
  text-align: center;
  color: var(--text-muted);
  padding: 40px 0;
}

/* ==================== 弹窗 ==================== */
.modal {
  position: fixed;
  inset: 0;
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
  visibility: hidden;
}

.modal.modal--visible {
  pointer-events: auto;
  visibility: visible;
}

.modal-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.3);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  opacity: 0;
  transition: opacity 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

.modal.modal--visible .modal-overlay {
  opacity: 1;
}

.modal.modal--closing .modal-overlay {
  opacity: 0;
}

.modal-content {
  position: relative;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 0;
  max-width: 800px;
  width: 90%;
  max-height: 80vh;
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  opacity: 0;
  transform: translateY(32px) scale(0.96);
  transition: opacity 0.35s cubic-bezier(0.4, 0, 0.2, 1),
              transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

.modal.modal--visible .modal-content {
  opacity: 1;
  transform: translateY(0) scale(1);
}

.modal.modal--closing .modal-content {
  opacity: 0;
  transform: translateY(18px) scale(0.97);
  transition: opacity 0.25s cubic-bezier(0.4, 0, 0.2, 1),
              transform 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

.modal-content--post {
  display: flex;
  flex-direction: column;
}

.modal-scroll {
  padding: 36px;
  overflow-y: auto;
  flex: 1;
}

.modal-scroll::-webkit-scrollbar {
  width: 6px;
}

.modal-scroll::-webkit-scrollbar-track {
  background: transparent;
  margin: 12px 0;
}

.modal-scroll::-webkit-scrollbar-thumb {
  background: rgba(0, 0, 0, 0.12);
  border-radius: 3px;
}

.modal-scroll::-webkit-scrollbar-thumb:hover {
  background: rgba(0, 0, 0, 0.22);
}

.modal-close {
  position: absolute;
  top: 12px;
  right: 14px;
  font-size: 20px;
  color: var(--text-muted);
  background: var(--bg-card);
  border: 1px solid var(--border);
  cursor: pointer;
  transition: color 0.2s, border-color 0.2s, background 0.2s;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  z-index: 10;
}

.modal-close:hover {
  color: var(--text-primary);
  border-color: var(--border-hover);
}

.post-meta {
  font-size: 13px;
  color: var(--text-muted);
  margin: 12px 0 24px;
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.post-cat-tag {
  display: inline-block;
  padding: 2px 10px;
  border-radius: 4px;
  background: var(--bg-section);
  border: 1px solid var(--border);
  font-size: 12px;
  font-weight: 500;
  color: var(--text-secondary);
}

.post-body {
  line-height: 1.8;
  color: var(--text-secondary);
}

.post-body img {
  border-radius: var(--radius-sm);
  margin: 16px 0;
}

/* ==================== 留言 ==================== */
.comment-form-wrap {
  max-width: 640px;
  margin: 0 auto 48px;
}

.comment-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.form-row {
  display: flex;
  gap: 12px;
}

.comment-form input,
.comment-form textarea,
.whitelist-form input,
.whitelist-form textarea,
.whitelist-form select,
.whitelist-check input {
  width: 100%;
  padding: 12px 16px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text-primary);
  font-size: 14px;
  transition: border-color 0.2s;
  box-shadow: var(--shadow-sm);
}

.comment-form input:focus,
.comment-form textarea:focus,
.whitelist-form input:focus,
.whitelist-form textarea:focus,
.whitelist-check input:focus {
  border-color: var(--text-primary);
  outline: none;
  box-shadow: 0 0 0 3px rgba(0, 0, 0, 0.04);
}

.comment-form textarea,
.whitelist-form textarea {
  resize: vertical;
}

.whitelist-form select {
  cursor: pointer;
  appearance: auto;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 28px;
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-weight: 600;
  transition: all 0.2s;
  cursor: pointer;
  border: none;
}

.btn-primary {
  background: var(--text-primary);
  color: #fff;
}

.btn-primary:hover {
  opacity: 0.8;
}

.btn-outline {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text-secondary);
}

.btn-outline:hover {
  border-color: var(--text-primary);
  color: var(--text-primary);
}

/* 留言横向滚动 */
.comment-marquee {
  width: 100%;
  overflow: hidden;
  mask-image: linear-gradient(to right, transparent, #000 60px, #000 calc(100% - 60px), transparent);
  -webkit-mask-image: linear-gradient(to right, transparent, #000 60px, #000 calc(100% - 60px), transparent);
  padding: 8px 0;
}

.comment-scroll-track {
  display: flex;
  gap: 20px;
  width: max-content;
  animation: comment-scroll 40s linear infinite;
}

.comment-marquee:hover .comment-scroll-track {
  animation-play-state: paused;
}

@keyframes comment-scroll {
  0% { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

.comment-item {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 20px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  width: 320px;
  min-width: 320px;
  flex-shrink: 0;
  transition: border-color 0.25s, box-shadow 0.25s;
}

.comment-item:hover {
  border-color: var(--border-hover);
  box-shadow: var(--shadow);
}

.comment-item-top {
  display: flex;
  align-items: center;
  gap: 12px;
}

.comment-avatar {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: var(--text-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  font-weight: 700;
  color: #fff;
  flex-shrink: 0;
}

.comment-meta {
  flex: 1;
  min-width: 0;
}

.comment-name {
  font-weight: 600;
  font-size: 14px;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.comment-time {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 2px;
}

.comment-text {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.6;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.comment-reply {
  margin-top: auto;
  padding: 10px 14px;
  background: var(--bg-section);
  border-left: 2px solid var(--text-muted);
  border-radius: 4px;
  font-size: 13px;
  color: var(--text-secondary);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* ==================== 白名单 ==================== */
.whitelist-wrap {
  max-width: 640px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 48px;
}

.whitelist-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.whitelist-check h3 {
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 16px;
  color: var(--text-secondary);
}

.wl-check-row {
  display: flex;
  gap: 10px;
  align-items: stretch;
}

.wl-check-row input {
  flex: 1;
  min-width: 0;
}

.wl-check-row .btn {
  white-space: nowrap;
  flex-shrink: 0;
  padding: 12px 24px;
}

.check-result {
  margin-top: 12px;
  padding: 16px;
  border-radius: var(--radius-sm);
  font-size: 14px;
}

.check-result p {
  margin-top: 8px;
  color: var(--text-secondary);
}

.status-pending {
  background: var(--bg-section);
  border: 1px solid var(--border-hover);
  color: var(--text-secondary);
}

.status-approved {
  background: var(--bg-section);
  border: 1px solid var(--text-primary);
  color: var(--text-primary);
}

.status-rejected {
  background: var(--bg-section);
  border: 1px solid var(--border);
  color: var(--text-muted);
}

.status-notfound {
  background: var(--bg-section);
  border: 1px solid var(--border);
  color: var(--text-muted);
}

/* ==================== 加载更多 ==================== */
.load-more {
  text-align: center;
  margin-top: 32px;
}

/* ==================== 页脚 ==================== */
.footer {
  padding: 48px 0 40px;
  border-top: 1px solid var(--border);
}

.footer-main {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 48px;
}

.footer-left {
  flex-shrink: 0;
}

.footer-brand {
  font-size: 16px;
  font-weight: 700;
  color: var(--text-primary);
  margin: 0 0 8px;
}

.footer-copyright {
  font-size: 13px;
  color: var(--text-muted);
  margin: 0;
}

.footer-icp {
  font-size: 13px;
  color: var(--text-muted);
  margin: 4px 0 0;
}

.footer-right {
  display: flex;
  gap: 48px;
}

.footer-col:empty {
  display: none;
}

.footer-col-title {
  font-size: 12px;
  font-weight: 700;
  color: var(--text-primary);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 14px;
}

.footer-col-links {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.footer-col-link {
  font-size: 13px;
  color: var(--text-muted);
  transition: color 0.2s;
  white-space: nowrap;
}

.footer-col-link:hover {
  color: var(--text-primary);
}
