/* ============================================================
   SYHLA · 全局游戏科技风主题 V1 (cyber-theme.css)
   全站统一：深色背景 + 霓虹光效 + 玻璃拟态 + 网格线
   覆盖所有页面的旧样式，确保风格一致
   ============================================================ */

/* ---------- 全局重置 ---------- */
:root {
  --cyber-bg: #050510;
  --cyber-bg-2: #0a0a1a;
  --cyber-surface: rgba(255, 255, 255, 0.03);
  --cyber-surface-hover: rgba(255, 255, 255, 0.06);
  --cyber-border: rgba(255, 255, 255, 0.08);
  --cyber-border-hover: rgba(0, 240, 255, 0.3);
  --cyber-text: #e0e0f0;
  --cyber-text-dim: #8b8ba8;
  --cyber-text-muted: #555570;
  --cyber-cyan: #00f0ff;
  --cyber-purple: #a855f7;
  --cyber-pink: #ec4899;
  --cyber-gradient: linear-gradient(135deg, #00f0ff, #a855f7);
  --cyber-radius: 12px;
  --cyber-radius-sm: 8px;
}

/* ---------- 全局背景 ---------- */
html, body {
  background: var(--cyber-bg) !important;
  color: var(--cyber-text) !important;
  font-family: system-ui, -apple-system, 'Segoe UI', Roboto, 'PingFang SC', 'Microsoft YaHei', sans-serif !important;
}

body {
  background-image:
    linear-gradient(rgba(0, 240, 255, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0, 240, 255, 0.03) 1px, transparent 1px),
    radial-gradient(ellipse at 20% 0%, rgba(168, 85, 247, 0.08), transparent 50%),
    radial-gradient(ellipse at 80% 100%, rgba(0, 240, 255, 0.06), transparent 50%) !important;
  background-size: 60px 60px, 60px 60px, 100% 100%, 100% 100% !important;
  background-attachment: fixed !important;
  min-height: 100vh;
}

/* 扫描线动画 */
body::before {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, rgba(0, 240, 255, 0.4), transparent);
  animation: cyber-scan 8s linear infinite;
  z-index: 1;
  pointer-events: none;
}

@keyframes cyber-scan {
  0% { top: 0; opacity: 0; }
  10% { opacity: 1; }
  90% { opacity: 1; }
  100% { top: 100%; opacity: 0; }
}

/* ---------- 文字颜色覆盖 ---------- */
h1, h2, h3, h4, h5, h6 {
  color: #fff !important;
  font-weight: 700 !important;
  letter-spacing: 0.3px;
}

p, span, div, li, td, th, label {
  color: var(--cyber-text);
}

a {
  color: var(--cyber-cyan) !important;
  text-decoration: none;
  transition: all 0.2s;
}
a:hover {
  color: #fff !important;
  text-shadow: 0 0 12px rgba(0, 240, 255, 0.6);
}

/* ---------- 导航栏 ---------- */
nav, .nav, .navbar, header nav, .site-nav, .main-nav {
  background: rgba(10, 10, 26, 0.85) !important;
  backdrop-filter: blur(12px) !important;
  -webkit-backdrop-filter: blur(12px) !important;
  border-bottom: 1px solid var(--cyber-border) !important;
}

nav a, .nav a, .navbar a, nav button, .nav button {
  color: var(--cyber-text-dim) !important;
}
nav a:hover, .nav a:hover, .navbar a:hover {
  color: var(--cyber-cyan) !important;
}

/* ---------- 卡片 ---------- */
.card, .feature-card, .game-card, .team-card, .news-card, .service-card, .pricing-card,
[class*="card"], [class*="-card"] {
  background: var(--cyber-surface) !important;
  border: 1px solid var(--cyber-border) !important;
  border-radius: var(--cyber-radius) !important;
  backdrop-filter: blur(8px) !important;
  -webkit-backdrop-filter: blur(8px) !important;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
  overflow: hidden;
}

.card:hover, .feature-card:hover, .game-card:hover, .team-card:hover, .news-card:hover,
[class*="card"]:hover, [class*="-card"]:hover {
  border-color: var(--cyber-border-hover) !important;
  background: var(--cyber-surface-hover) !important;
  box-shadow: 0 8px 32px rgba(0, 240, 255, 0.08), 0 0 0 1px rgba(0, 240, 255, 0.1) !important;
  transform: translateY(-2px);
}

/* ---------- 按钮 ---------- */
button, .btn, .button, input[type="submit"], input[type="button"] {
  background: var(--cyber-surface) !important;
  border: 1px solid var(--cyber-border) !important;
  color: var(--cyber-text) !important;
  border-radius: var(--cyber-radius-sm) !important;
  font-weight: 600 !important;
  cursor: pointer !important;
  transition: all 0.2s !important;
}

button:hover, .btn:hover, .button:hover, input[type="submit"]:hover {
  background: rgba(0, 240, 255, 0.1) !important;
  border-color: rgba(0, 240, 255, 0.3) !important;
  color: var(--cyber-cyan) !important;
}

button:active, .btn:active {
  transform: scale(0.97);
}

/* 主按钮 */
.btn-primary, .button-primary, [class*="primary"] {
  background: var(--cyber-gradient) !important;
  border: none !important;
  color: #050510 !important;
  font-weight: 700 !important;
}
.btn-primary:hover, .button-primary:hover {
  color: #050510 !important;
  box-shadow: 0 4px 24px rgba(0, 240, 255, 0.3) !important;
}

/* ---------- 输入框 ---------- */
input, textarea, select {
  background: rgba(255, 255, 255, 0.04) !important;
  border: 1px solid var(--cyber-border) !important;
  color: var(--cyber-text) !important;
  border-radius: var(--cyber-radius-sm) !important;
  padding: 10px 14px !important;
  transition: all 0.2s !important;
}

input:focus, textarea:focus, select:focus {
  outline: none !important;
  border-color: rgba(0, 240, 255, 0.4) !important;
  box-shadow: 0 0 0 3px rgba(0, 240, 255, 0.1) !important;
}

input::placeholder, textarea::placeholder {
  color: var(--cyber-text-muted) !important;
}

/* ---------- 标题装饰 ---------- */
.section-title, .page-title, h1.page-title, h2.section-title {
  position: relative;
  display: inline-block;
}

.section-title::after, .page-title::after {
  content: '';
  position: absolute;
  bottom: -8px;
  left: 0;
  width: 60%;
  height: 2px;
  background: var(--cyber-gradient);
  border-radius: 2px;
}

/* ---------- 徽章/标签 ---------- */
.badge, .tag, .label, [class*="badge"], [class*="tag"] {
  background: rgba(0, 240, 255, 0.1) !important;
  border: 1px solid rgba(0, 240, 255, 0.2) !important;
  color: var(--cyber-cyan) !important;
  border-radius: 20px !important;
  font-size: 11px !important;
  font-weight: 600 !important;
  padding: 3px 10px !important;
}

/* ---------- 表格 ---------- */
table {
  border-collapse: collapse !important;
  width: 100%;
}

th, td {
  border: 1px solid var(--cyber-border) !important;
  padding: 10px 14px !important;
  text-align: left;
}

th {
  background: rgba(0, 240, 255, 0.05) !important;
  color: var(--cyber-cyan) !important;
  font-weight: 700 !important;
}

tr:hover td {
  background: rgba(255, 255, 255, 0.02) !important;
}

/* ---------- 页脚 ---------- */
footer, .footer, .site-footer {
  background: rgba(5, 5, 16, 0.9) !important;
  border-top: 1px solid var(--cyber-border) !important;
  color: var(--cyber-text-dim) !important;
}

footer a, .footer a {
  color: var(--cyber-text-dim) !important;
}
footer a:hover, .footer a:hover {
  color: var(--cyber-cyan) !important;
}

/* ---------- 模态框/弹窗 ---------- */
.modal, .overlay, .popup, [class*="modal"], [class*="overlay"] {
  background: rgba(5, 5, 16, 0.92) !important;
  backdrop-filter: blur(8px) !important;
  -webkit-backdrop-filter: blur(8px) !important;
}

.modal-content, .popup-content, [class*="modal-content"] {
  background: var(--cyber-bg-2) !important;
  border: 1px solid var(--cyber-border) !important;
  border-radius: var(--cyber-radius) !important;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5) !important;
}

/* ---------- 代码块 ---------- */
code, pre, .code {
  background: rgba(0, 0, 0, 0.4) !important;
  border: 1px solid var(--cyber-border) !important;
  border-radius: var(--cyber-radius-sm) !important;
  color: var(--cyber-cyan) !important;
  font-family: 'Consolas', 'Monaco', monospace !important;
}

pre {
  padding: 16px !important;
  overflow-x: auto;
}

code {
  padding: 2px 6px !important;
  font-size: 0.9em;
}

/* ---------- 分隔线 ---------- */
hr, .divider, [class*="divider"] {
  border: none !important;
  height: 1px !important;
  background: linear-gradient(90deg, transparent, var(--cyber-border), transparent) !important;
  margin: 32px 0 !important;
}

/* ---------- 滚动条 ---------- */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}
::-webkit-scrollbar-track {
  background: var(--cyber-bg);
}
::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.1);
  border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
  background: rgba(0, 240, 255, 0.3);
}

/* ---------- 选中文字 ---------- */
::selection {
  background: rgba(0, 240, 255, 0.3);
  color: #fff;
}

/* ---------- 减少动效 ---------- */
@media (prefers-reduced-motion: reduce) {
  body::before {
    animation: none;
    display: none;
  }
  * {
    transition: none !important;
    animation: none !important;
  }
}

/* ---------- 响应式 ---------- */
@media (max-width: 768px) {
  body::before {
    display: none;
  }
}
