/* ===== Reset & Base ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  font-size: 16px; line-height: 1.7; color: #F5F5F5; background: #1A0A2E;
  -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale;
}
img, video, canvas { max-width: 100%; height: auto; display: block; }
a { color: #00C2FF; text-decoration: none; transition: color 0.25s; }
a:hover, a:focus-visible { color: #D4AF37; }
ul, ol { list-style: none; }
button { font: inherit; cursor: pointer; border: none; background: none; color: inherit; }
:focus-visible { outline: 2px solid #00C2FF; outline-offset: 2px; border-radius: 4px; }

/* ===== CSS Variables ===== */
:root {
  --color-bg-primary: #1A0A2E;
  --color-bg-secondary: #2D1B4E;
  --color-gold: #D4AF37;
  --color-gold-light: #FFD700;
  --color-neon: #00C2FF;
  --color-text: #F5F5F5;
  --color-text-muted: #B0A0C0;
  --color-border: #4A2D6E;
  --color-warning: #FF4444;
  --font-heading: 'Barlow Condensed', 'Impact', 'Arial Narrow', sans-serif;
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-accent: 'Dancing Script', 'Brush Script MT', cursive;
  --nav-height: 64px;
  --capsule-radius: 40px;
  --transition: 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  --max-width: 1200px;
}

/* ===== Skip Link ===== */
.skip-link {
  position: fixed; top: -100%; left: 16px; z-index: 10000;
  background: #D4AF37; color: #1A0A2E; padding: 10px 20px;
  border-radius: 8px; font-weight: 700; font-family: var(--font-heading);
  transition: top 0.25s; font-size: 1rem;
}
.skip-link:focus { top: 16px; }

/* ===== Rule Banner ===== */
.rule-banner {
  background: linear-gradient(135deg, #D4AF37 0%, #FFD700 50%, #D4AF37 100%);
  color: #1A0A2E; text-align: center; padding: 8px 16px;
  font-size: 0.85rem; font-weight: 700; letter-spacing: 0.05em;
  font-family: var(--font-heading); text-transform: uppercase;
  position: relative; z-index: 1001;
}

/* ===== Nav Capsule ===== */
[data-nav-capsule] {
  position: sticky; top: 0; z-index: 1000;
  display: flex; align-items: center; justify-content: space-between;
  max-width: var(--max-width); margin: 0 auto;
  padding: 0 24px; height: var(--nav-height);
  background: rgba(26, 10, 46, 0.88);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(212, 175, 55, 0.25);
  border-radius: var(--capsule-radius);
  box-shadow: 0 8px 32px rgba(0,0,0,0.5);
  transition: background var(--transition);
}
[data-nav-capsule] .brand-logo {
  font-family: var(--font-heading); font-size: 1.6rem; font-weight: 900;
  color: #D4AF37; letter-spacing: 0.04em; text-transform: uppercase;
  flex-shrink: 0; line-height: 1.2;
}
[data-nav-capsule] .brand-logo:hover { color: #FFD700; }

/* Navigation list */
[data-nav] ul { display: flex; gap: 4px; align-items: center; }
[data-nav] a {
  font-family: var(--font-heading); font-size: 0.95rem; font-weight: 600;
  color: #F5F5F5; padding: 6px 16px; border-radius: 20px;
  letter-spacing: 0.04em; transition: all var(--transition);
  position: relative; white-space: nowrap;
}
[data-nav] a:hover { color: #D4AF37; background: rgba(212, 175, 55, 0.10); }
[data-nav] a[aria-current="page"] {
  color: #00C2FF; background: rgba(0, 194, 255, 0.08);
  box-shadow: inset 0 -2px 0 #00C2FF;
}

/* Hamburger */
[data-nav-toggle] {
  display: none; flex-direction: column; justify-content: center;
  gap: 5px; width: 36px; height: 36px; padding: 4px;
  border-radius: 8px; background: rgba(212, 175, 55, 0.12);
  transition: background var(--transition);
}
[data-nav-toggle]:hover { background: rgba(212, 175, 55, 0.25); }
.hamburger-line {
  display: block; width: 24px; height: 2px; background: #D4AF37;
  border-radius: 2px; transition: all var(--transition);
  transform-origin: center;
}

/* ===== Mobile Nav ===== */
@media (max-width: 900px) {
  [data-nav-toggle] { display: inline-flex; }
  [data-nav] {
    position: fixed; top: calc(var(--nav-height) + 56px); left: 16px; right: 16px;
    background: rgba(26, 10, 46, 0.96); backdrop-filter: blur(16px);
    border: 1px solid rgba(212, 175, 55, 0.2); border-radius: 20px;
    padding: 16px 8px; opacity: 0; visibility: hidden;
    transform: translateY(-12px) scale(0.96);
    transition: all 0.35s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    box-shadow: 0 20px 48px rgba(0,0,0,0.6);
    max-height: 70vh; overflow-y: auto; z-index: 999;
  }
  [data-nav][data-open] {
    opacity: 1; visibility: visible; transform: translateY(0) scale(1);
  }
  [data-nav] ul { flex-direction: column; gap: 2px; width: 100%; }
  [data-nav] a {
    display: block; width: 100%; text-align: center; padding: 12px 16px;
    font-size: 1.05rem; border-radius: 12px;
  }
  [data-nav] a[aria-current="page"] {
    background: rgba(0, 194, 255, 0.12);
    box-shadow: inset 0 0 0 1px rgba(0, 194, 255, 0.3);
  }
  /* 胶囊导航在移动端缩小边距 */
  [data-nav-capsule] {
    padding: 0 16px; border-radius: 28px; margin: 0 8px;
  }
}
@media (min-width: 901px) {
  [data-nav] { display: flex !important; position: static !important; background: none !important; border: none !important; backdrop-filter: none !important; box-shadow: none !important; padding: 0 !important; transform: none !important; opacity: 1 !important; visibility: visible !important; }
}

/* ===== Footer ===== */
.site-footer {
  background: #1A0A2E; border-top: 2px solid rgba(212, 175, 55, 0.2);
  padding: 48px 16px 32px; margin-top: 80px;
  font-family: var(--font-body); color: #B0A0C0;
}
.footer-inner { display: flex; flex-direction: column; gap: 24px; }
.footer-brand-area { text-align: center; }
.footer-brand {
  font-family: var(--font-accent); font-size: 2.4rem; color: #D4AF37;
  letter-spacing: 0.06em; line-height: 1.2;
}
.footer-tagline {
  font-family: var(--font-heading); font-size: 0.9rem; color: #4A2D6E;
  letter-spacing: 0.2em; text-transform: uppercase; margin-top: 4px;
}
.footer-links {
  display: flex; justify-content: center; gap: 32px; flex-wrap: wrap;
}
.footer-links a {
  font-family: var(--font-heading); font-size: 0.95rem; font-weight: 600;
  color: #B0A0C0; letter-spacing: 0.06em; transition: color var(--transition);
  position: relative;
}
.footer-links a::after {
  content: ''; position: absolute; bottom: -2px; left: 0; width: 0; height: 1px;
  background: #D4AF37; transition: width var(--transition);
}
.footer-links a:hover { color: #D4AF37; }
.footer-links a:hover::after { width: 100%; }
.footer-contact {
  display: flex; justify-content: center; gap: 24px; flex-wrap: wrap;
  font-size: 0.85rem; color: #8A7A9A; text-align: center;
}
.footer-contact a { color: #00C2FF; }
.footer-contact a:hover { color: #D4AF37; }
.footer-icp {
  text-align: center; font-size: 0.75rem; color: #4A2D6E;
  font-family: var(--font-heading); letter-spacing: 0.08em;
}
.footer-trust {
  text-align: center; font-size: 0.78rem; color: #4A2D6E;
  max-width: 600px; margin: 0 auto; line-height: 1.5;
}

@media (max-width: 600px) {
  .site-footer { padding: 32px 12px 24px; }
  .footer-contact { flex-direction: column; gap: 8px; }
  .footer-links { gap: 20px; }
}

/* ===== Container ===== */
.container { max-width: var(--max-width); margin: 0 auto; padding: 0 20px; }
@media (max-width: 600px) { .container { padding: 0 12px; } }

/* ===== Buttons ===== */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  font-family: var(--font-heading); font-weight: 700; font-size: 1rem;
  padding: 12px 32px; border-radius: 30px; letter-spacing: 0.04em;
  background: linear-gradient(135deg, #D4AF37 0%, #FFD700 100%);
  color: #1A0A2E; border: none; transition: all var(--transition);
  box-shadow: 0 4px 16px rgba(212, 175, 55, 0.2);
  text-decoration: none; line-height: 1;
}
.btn:hover { background: linear-gradient(135deg, #FFD700 0%, #D4AF37 100%); box-shadow: 0 4px 24px rgba(212, 175, 55, 0.4); transform: translateY(-2px); color: #1A0A2E; }
.btn:focus-visible { outline: 2px solid #00C2FF; outline-offset: 3px; }
.btn--secondary { background: transparent; border: 2px solid #D4AF37; color: #D4AF37; box-shadow: none; }
.btn--secondary:hover { background: rgba(212, 175, 55, 0.12); border-color: #FFD700; color: #FFD700; box-shadow: none; }

/* ===== Badge ===== */
.badge {
  display: inline-block; font-family: var(--font-heading); font-weight: 600;
  font-size: 0.7rem; letter-spacing: 0.12em; text-transform: uppercase;
  padding: 4px 12px; border-radius: 20px; background: rgba(212, 175, 55, 0.15);
  color: #D4AF37; border: 1px solid rgba(212, 175, 55, 0.2);
}

/* ===== Section ===== */
.section { padding: 64px 0; }
@media (max-width: 600px) { .section { padding: 40px 0; } }

/* ===== Grid ===== */
.grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
@media (max-width: 900px) { .grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 600px) { .grid { grid-template-columns: 1fr; } }

/* ===== Card ===== */
.card {
  background: #2D1B4E; border-radius: 16px; padding: 24px;
  border: 1px solid rgba(212, 175, 55, 0.08);
  transition: all var(--transition);
  clip-path: polygon(0 0, 100% 0, 100% calc(100% - 8px), calc(100% - 8px) 100%, 0 100%);
}
.card:hover { border-color: rgba(212, 175, 55, 0.2); transform: translateY(-4px); box-shadow: 0 12px 32px rgba(0,0,0,0.3); }
.card-title { font-family: var(--font-heading); font-size: 1.3rem; font-weight: 800; color: #D4AF37; margin-bottom: 8px; }
.card-text { font-size: 0.9rem; color: #B0A0C0; line-height: 1.6; }

/* ===== Breadcrumb ===== */
.breadcrumb {
  display: flex; flex-wrap: wrap; gap: 8px; align-items: center;
  font-family: var(--font-heading); font-size: 0.85rem; color: #4A2D6E;
  padding: 12px 0; margin-bottom: 16px;
}
.breadcrumb a { color: #B0A0C0; font-weight: 600; }
.breadcrumb a:hover { color: #D4AF37; }
.breadcrumb span { color: #4A2D6E; }
.breadcrumb span::before { content: '/'; margin-right: 8px; color: #4A2D6E; }

/* ===== Image Placeholder ===== */
.img-holder {
  background: linear-gradient(135deg, #2D1B4E 0%, #1A0A2E 100%);
  border-radius: 12px; min-height: 200px; width: 100%;
  display: flex; align-items: center; justify-content: center;
  color: #4A2D6E; font-family: var(--font-heading); font-size: 0.85rem;
  border: 1px dashed rgba(212, 175, 55, 0.12);
  overflow: hidden; position: relative;
}
.img-holder::after {
  content: ''; position: absolute; top: 0; left: 0; right: 0; bottom: 0;
  background: linear-gradient(135deg, transparent 0%, rgba(212, 175, 55, 0.03) 100%);
  pointer-events: none;
}

/* ===== Scroll Progress ===== */
.scroll-progress {
  position: fixed; top: 0; left: 0; height: 3px;
  background: linear-gradient(90deg, #D4AF37, #00C2FF, #D4AF37);
  width: 0%; z-index: 9999; pointer-events: none;
  transition: width 0.1s linear;
}

/* ===== Responsive Typography ===== */
h1, h2, h3, h4, h5, h6 { font-family: var(--font-heading); font-weight: 800; color: #D4AF37; line-height: 1.1; letter-spacing: 0.02em; }
h1 { font-size: 3.2rem; }
h2 { font-size: 2.4rem; }
h3 { font-size: 1.8rem; }
h4 { font-size: 1.4rem; }
p { margin-bottom: 1rem; color: #B0A0C0; }
@media (max-width: 600px) {
  h1 { font-size: 2.2rem; }
  h2 { font-size: 1.8rem; }
  h3 { font-size: 1.4rem; }
}

/* ===== Reduced Motion ===== */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
  .scroll-progress { display: none; }
  [data-nav] { transition: none !important; }
}

/* ===== Utility ===== */
.text-gold { color: #D4AF37; }
.text-neon { color: #00C2FF; }
.text-muted { color: #4A2D6E; }
.bg-secondary { background: #2D1B4E; }
.text-center { text-align: center; }
.mt-16 { margin-top: 16px; }
.mt-32 { margin-top: 32px; }
.mb-16 { margin-bottom: 16px; }
.mb-32 { margin-bottom: 32px; }
