.btn-steam::before {
  inset: -3px;
  border-radius: 999px;
  background: linear-gradient(120deg,
      rgba(255, 77, 77, 0.95),
      rgba(255, 166, 77, 0.95),
      rgba(255, 255, 94, 0.95),
      rgba(108, 124, 255, 0.95),
      rgba(45, 245, 255, 0.95),
      rgba(255, 77, 77, 0.95));
  background-size: 320% 320%;
  animation: steamFlow 5s linear infinite;
  filter: blur(0.6px);
}
/* Base */
:root {
  --bg: #0b0c10;
  --card: #11131a;
  --elev: #171a22;
  --text: #e6e8ef;
  --muted: #aab0c0;
  --brand: #6c7cff;
  --brand-2: #6cf0ff;
  --accent: #ff5c9a;
  --radius: 14px;
}

* { box-sizing: border-box; }
html, body { height: 100%; }
body {
  margin: 0;
  font-family: ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Noto Sans, "Helvetica Neue", Arial, "Apple Color Emoji", "Segoe UI Emoji";
  color: var(--text);
  background: radial-gradient(1200px 800px at 80% -10%, #1b1f2b 0%, #0b0c10 60%, #07080c 100%);
  background-attachment: fixed;
  line-height: 1.6;
}

.container {
  width: min(1160px, 92%);
  margin: 0 auto;
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 30;
  backdrop-filter: blur(8px);
  background: color-mix(in oklab, #0b0c10 80%, transparent);
  border-bottom: 1px solid rgba(255,255,255,0.06);
}
.site-header .container { display: flex; align-items: center; justify-content: space-between; padding: 14px 0; }
.brand { display: inline-flex; align-items: center; gap: 10px; }
.brand-logo { height: 28px; width: 28px; border-radius: 8px; background: #fff; box-shadow: 0 1px 6px rgba(0,0,0,.25); }
.brand-lines { display: flex; flex-direction: column; line-height: 1.1; }
.brand-cn { font-weight: 800; letter-spacing: .4px; font-size: 16px; }
.brand-en { font-weight: 700; font-size: 11px; color: var(--muted); letter-spacing: 1.4px; }
.nav { display: flex; gap: 12px; align-items: center; }

/* Buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 10px 16px; border-radius: 999px; text-decoration: none; transition: .25s ease; border: 1px solid transparent; color: var(--text); position: relative; overflow: hidden; white-space: nowrap; }
.btn:hover { transform: translateY(-1px); }
.btn:active { transform: translateY(0); }
.btn-primary { background: linear-gradient(135deg, var(--brand), var(--brand-2)); box-shadow: 0 10px 30px rgba(108,124,255,.25), 0 0 0 0 rgba(108,240,255,.5); color: #0d0f15; font-weight: 700; }
.btn-primary:hover { box-shadow: 0 14px 34px rgba(108,124,255,.35), 0 0 30px 6px rgba(108,240,255,.22); }
.btn-primary::after { content: ""; position: absolute; inset: -2px; border-radius: 999px; background: radial-gradient(120px 40px at var(--x,50%) 100%, rgba(255,255,255,.35), transparent 60%); opacity: 0; transition: opacity .25s ease; pointer-events: none; }
.btn-primary:hover::after { opacity: 1; }
.btn-ghost { background: transparent; border-color: rgba(255,255,255,0.12); color: var(--text); }
.btn-ghost:hover { border-color: rgba(255,255,255,0.22); background: rgba(255,255,255,0.04); }
.btn-lg { padding: 14px 22px; font-size: 16px; }

.btn-steam {
  position: relative;
  border: none;
  background: transparent;
  z-index: 0;
  transition: transform .3s ease;
  border-radius: 999px;
}

.btn-steam::before,
.btn-steam::after {
  content: '';
  position: absolute;
  border-radius: inherit;
  pointer-events: none;
  z-index: -1;
}

.btn-steam::before {
  inset: -3px;
  border-radius: inherit;
  background: linear-gradient(120deg,
      rgba(255, 77, 77, 0.95),
      rgba(255, 166, 77, 0.95),
      rgba(255, 255, 94, 0.95),
      rgba(108, 124, 255, 0.95),
      rgba(45, 245, 255, 0.95),
      rgba(255, 77, 77, 0.95));
  background-size: 320% 320%;
  animation: steamFlow 5s linear infinite;
  filter: blur(0.6px);
}

.btn-steam::after {
  inset: 1px;
  background: rgba(18, 24, 40, 0.92);
  box-shadow: inset 0 0 18px rgba(8, 16, 32, 0.6);
  transition: background .35s ease, box-shadow .35s ease;
}

.btn-steam:hover {
  transform: translateY(-2px);
}

.btn-steam:hover::after {
  background: rgba(25, 36, 62, 0.96);
  box-shadow:
    inset 0 0 22px rgba(18, 28, 48, 0.75),
    0 0 24px rgba(90, 200, 255, 0.35);
}

@keyframes steamFlow {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

/* Hero */
.hero { position: relative; padding: 88px 0 48px; overflow: clip; }
.hero .container { position: relative; z-index: 2; }
.hero-title { font-size: clamp(44px, 6vw, 80px); line-height: 1.05; margin: 10px 0 8px; letter-spacing: .6px; }
.gradient-text { background: conic-gradient(from 180deg at 50% 50%, #7aa2ff, #2df5ff, #ff79c6, #7aa2ff); -webkit-background-clip: text; background-clip: text; color: transparent; filter: drop-shadow(0 6px 26px rgba(108,124,255,.26)); animation: hue 8s linear infinite; }
@keyframes hue { to { filter: hue-rotate(360deg) drop-shadow(0 10px 36px rgba(108,124,255,.32)); } }
.hero-subtitle { color: var(--muted); margin: 0 0 8px; }
.hero-meta { color: var(--muted); margin: 0 0 26px; }
.hero-actions { display: flex; gap: 12px; flex-wrap: wrap; }
.dev-badge { height: 24px; width: 24px; object-fit: contain; vertical-align: -6px; margin-right: 8px; border-radius: 6px; box-shadow: 0 2px 8px rgba(0,0,0,.35); background: #fff; }
.qr-card { margin-top: 14px; display: inline-flex; flex-direction: column; align-items: center; gap: 6px; padding: 10px; border-radius: var(--radius); background: linear-gradient(180deg, var(--elev), var(--card)); border: 1px solid rgba(255,255,255,0.08); box-shadow: 0 10px 26px rgba(0,0,0,.35); }
.qr-card img { width: 132px; height: 132px; object-fit: contain; background: #fff; border-radius: 12px; }
.qr-caption { font-size: 12px; color: var(--muted); }
.hero-bg { position: absolute; inset: -10% -10% auto -10%; height: 60vh; min-height: 360px; background:
  radial-gradient(600px 300px at 20% 50%, rgba(108,124,255,.25), transparent 70%),
  radial-gradient(700px 330px at 70% 30%, rgba(108,240,255,.18), transparent 70%),
  radial-gradient(600px 400px at 50% 20%, rgba(255,92,154,.12), transparent 70%);
  filter: blur(24px) saturate(115%);
  opacity: .9;
  animation: floaty 18s ease-in-out infinite alternate;
}
@keyframes floaty { 0% { transform: translateY(-10px) scale(1); } 100% { transform: translateY(14px) scale(1.04); } }

/* Hero effects */
.hero-effects { position: absolute; inset: 0; pointer-events: none; }
.hero-grid { position: absolute; inset: -20% -20% 0 -20%; background:
  linear-gradient(to right, rgba(255,255,255,.05) 1px, transparent 1px) 0 0 / 40px 40px,
  linear-gradient(to bottom, rgba(255,255,255,.05) 1px, transparent 1px) 0 0 / 40px 40px; 
  mask-image: radial-gradient(70% 70% at 50% 0%, black, transparent 70%);
  transform: translateZ(0);
  animation: gridFloat 22s ease-in-out infinite alternate;
}
@keyframes gridFloat { from { transform: translateY(-12px) skewY(-2deg); } to { transform: translateY(6px) skewY(2deg); } }

.orbs { position: absolute; inset: 0; filter: blur(18px) saturate(120%); }
.orb { position: absolute; border-radius: 50%; opacity: .55; mix-blend-mode: screen; }
.orb-a { width: 36vmin; height: 36vmin; left: 8%; top: 8%; background: radial-gradient(circle at 30% 30%, #6c7cff, transparent 60%); animation: orbA 16s ease-in-out infinite alternate; }
.orb-b { width: 40vmin; height: 40vmin; right: 12%; top: 10%; background: radial-gradient(circle at 70% 40%, #2df5ff, transparent 60%); animation: orbB 20s ease-in-out infinite alternate; }
.orb-c { width: 30vmin; height: 30vmin; left: 24%; bottom: 6%; background: radial-gradient(circle at 50% 60%, #ff79c6, transparent 60%); animation: orbC 18s ease-in-out infinite alternate; }
@keyframes orbA { from { transform: translateY(-12px); } to { transform: translateY(10px) translateX(6px); } }
@keyframes orbB { from { transform: translateY(6px); } to { transform: translateY(-8px) translateX(-8px); } }
@keyframes orbC { from { transform: translateX(-6px); } to { transform: translateX(8px) translateY(-6px); } }

/* Touch devices: tone down hover effects */
@media (hover: none) {
  .btn:hover { transform: none; }
  .btn-primary::after { display: none; }
}

/* Small screens: compact header */
@media (max-width: 560px) {
  .site-header .container { flex-wrap: nowrap; }
  .brand-en { display: none; }
  .nav { gap: 8px; }
  .nav .btn { padding: 8px 12px; font-size: 14px; }
  /* Hide secondary links on very small screens to避免拥挤变形 */
  .nav a[href="#about"],
  .nav a[href="#gallery"],
  .nav a[href*="store.steampowered.com"] { display: none; }
}

/* Gallery */
.about-section { padding: 26px 0 6px; }
.about-lead { color: var(--text); margin: 0 0 12px; font-size: 15px; letter-spacing: .1px; }
.features-list { margin: 0; padding-left: 18px; color: var(--muted); }
.features-list li { margin: 6px 0; }
.features-list li::marker { color: var(--brand-2); }
.features-list li:hover { color: var(--text); transition: color .2s ease; }
.features-list li { list-style: disc; }

.gallery-section { padding: 40px 0 80px; }
.section-title { font-size: 22px; letter-spacing: .3px; margin: 8px 0 18px; color: var(--muted); }
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 14px;
}
.card {
  margin: 0;
  padding: 10px;
  background: linear-gradient(180deg, var(--elev), var(--card));
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: var(--radius);
  box-shadow: 0 10px 30px rgba(0,0,0,.35);
  transition: transform .28s ease, box-shadow .28s ease, border-color .28s ease;
}
.card img { width: 100%; height: 100%; max-height: 360px; object-fit: cover; border-radius: calc(var(--radius) - 6px); display: block; }
.card figcaption { margin-top: 8px; color: var(--muted); font-size: 13px; }
.card:hover { transform: translateY(-4px) scale(1.01); border-color: rgba(255,255,255,0.16); box-shadow: 0 18px 46px rgba(0,0,0,.45); }

/* Responsive layout */
.gallery-grid > .card:nth-child(1) { grid-column: span 6; }
.gallery-grid > .card:nth-child(2) { grid-column: span 6; }
.gallery-grid > .card:nth-child(3) { grid-column: span 4; }
.gallery-grid > .card:nth-child(4) { grid-column: span 4; }
.gallery-grid > .card:nth-child(5) { grid-column: span 4; }
.gallery-grid > .card:nth-child(6) { grid-column: 1 / -1; }

@media (max-width: 900px) {
  .gallery-grid { grid-template-columns: repeat(6, 1fr); }
  .gallery-grid > .card:nth-child(n) { grid-column: span 6; }
}
@media (max-width: 560px) {
  .hero { padding-top: 68px; }
  .site-header .container { padding: 10px 0; }
}

/* Reveal animations */
.reveal { opacity: 0; transform: translateY(10px) scale(.995); animation: reveal .7s cubic-bezier(.2,.8,.2,1) forwards; animation-delay: var(--delay, 0s); }
@keyframes reveal { to { opacity: 1; transform: none; } }

/* Footer */
.site-footer { border-top: 1px solid rgba(255,255,255,0.06); padding: 24px 0 60px; color: var(--muted); }
.site-footer .container { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.site-footer a { color: var(--muted); text-decoration: none; }
.site-footer a:hover { color: var(--text); }

/* Page background and frosted overlay */
.page-bg { position: fixed; inset: 0; z-index: 0; pointer-events: none; background: url('../XC未标题-5.png') center/cover no-repeat fixed; filter: saturate(110%) contrast(102%); transform: translateZ(0); }
.page-tint { position: fixed; inset: 0; z-index: 1; pointer-events: none; backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); background: radial-gradient(1200px 800px at 80% -10%, rgba(11,12,16,.65) 0%, rgba(11,12,16,.75) 60%, rgba(7,8,12,.86) 100%); }

/* Elevate app content above background/overlay */
main, header, footer { position: relative; z-index: 3; }

/* ----- Game card: 不存在的世界 ----- */
.game-section { padding: 20px 0 60px; }
.game-card { display: flex; flex-direction: column; gap: 12px; }
.game-card-header { display: flex; align-items: center; gap: 10px; }
.game-logo { width: 42px; height: 42px; border-radius: 10px; object-fit: cover; background: #fff; box-shadow: 0 2px 10px rgba(0,0,0,.3); }
.game-title { font-size: 18px; font-weight: 800; letter-spacing: .3px; }
.game-card-body { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.game-actions { display: flex; gap: 10px; }

/* Align with hero when placed alongside */
.hero .game-actions { margin-top: 8px; }

/* Matrix rain canvas */
#matrix-canvas {
  position: fixed;
  inset: 0;
  width: 100vw;
  height: 100vh;
  pointer-events: none;
  z-index: 2;
  opacity: .75;
  mix-blend-mode: screen;
}


