:root {
  --primary: #F0B90B;
  --primary-hover: #FCD535;
  --bg-dark: #0B0E11;
  --glass: rgba(22, 26, 30, 0.65);
  --glass-highlight: rgba(255, 255, 255, 0.05);
  --glass-border: rgba(255, 255, 255, 0.08);
  --text-main: #EAECEF;
  --text-sub: #848E9C;
  --green: #0ECB81;
}

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { height: 100%; margin: 0; padding: 0; font-family: -apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif; }

body {
  background-color: var(--bg-dark);
  color: var(--text-main);
  display: flex; flex-direction: column; align-items: center;
  overflow-x: hidden;
  position: relative;
  width: 100vw;
  max-width: 100%;
}

/* 动态背景 */
body::before {
  content: ''; position: fixed; top: -50%; left: -50%; width: 200%; height: 200%;
  background: 
    radial-gradient(circle at 50% 50%, rgba(240, 185, 11, 0.08), transparent 50%),
    radial-gradient(circle at 80% 20%, rgba(14, 203, 129, 0.05), transparent 30%),
    radial-gradient(circle at 20% 80%, rgba(37, 99, 235, 0.08), transparent 40%);
  animation: bgShift 20s ease-in-out infinite alternate;
  z-index: -2;
}

.bg-grid {
  position: fixed; top: 0; left: 0; width: 100%; height: 100%; z-index: -1;
  background-size: 60px 60px;
  background-image: 
    linear-gradient(to right, rgba(255,255,255,0.03) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(255,255,255,0.03) 1px, transparent 1px);
  mask-image: radial-gradient(circle at center, black 30%, transparent 80%);
}

.wrapper {
  width: 100%; max-width: 1200px; padding: 20px;
  flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center;
}

/* Main Card */
.main-card {
  width: 100%; max-width: 460px;
  background: var(--glass);
  backdrop-filter: blur(40px); -webkit-backdrop-filter: blur(40px);
  border: 1px solid var(--glass-border);
  border-radius: 32px; 
  padding: 48px 32px;
  box-shadow: 
    0 40px 80px -12px rgba(0, 0, 0, 0.6),
    inset 0 0 0 1px rgba(255,255,255,0.05);
  position: relative; overflow: hidden;
  animation: slideUp 0.8s cubic-bezier(0.2, 0.8, 0.2, 1);
  transform: translateY(0);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.main-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 50px 100px -12px rgba(0, 0, 0, 0.7);
}

/* 顶部高光条 */
.main-card::after {
  content: ''; position: absolute; top: 0; left: 0; right: 0; height: 1px;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
}

.logo-area { margin-bottom: 32px; text-align: center; }
.logo-icon { 
  width: 72px; height: 72px; 
  background: var(--primary); 
  border-radius: 24px; 
  display: inline-flex; align-items: center; justify-content: center; 
  box-shadow: 0 12px 32px rgba(240, 185, 11, 0.25); 
  margin-bottom: 20px;
  transform: rotate(-3deg);
  transition: transform 0.3s ease;
}
.main-card:hover .logo-icon { transform: rotate(0deg) scale(1.05); }
.logo-svg { width: 40px; height: 40px; fill: #1E2329; }

h1 { 
  margin: 0 0 12px; 
  font-size: 32px; 
  font-weight: 800; 
  color: #fff; 
  letter-spacing: -0.5px; 
  text-align: center;
  background: linear-gradient(135deg, #fff 0%, #EAECEF 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.subtitle { margin: 0 0 40px; color: var(--text-sub); font-size: 16px; text-align: center; line-height: 1.6; font-weight: 400; }

.btn-group { display: flex; flex-direction: column; gap: 16px; width: 100%; }

.btn {
  display: flex; align-items: center; justify-content: center; gap: 12px;
  width: 100%; height: 60px; border-radius: 20px;
  text-decoration: none; font-weight: 600; font-size: 17px;
  transition: all 0.3s cubic-bezier(0.2, 0.8, 0.2, 1); 
  cursor: pointer; position: relative; overflow: hidden;
  letter-spacing: 0.5px;
}

/* Primary Button */
.btn-primary { 
  background: linear-gradient(135deg, var(--primary) 0%, #E5B00A 100%);
  color: #1E2329; 
  box-shadow: 0 8px 24px rgba(240, 185, 11, 0.25); 
  border: none; 
}
.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 32px rgba(240, 185, 11, 0.4);
  background: linear-gradient(135deg, #FCD535 0%, #F0B90B 100%);
}
.btn-primary:active { transform: translateY(0) scale(0.98); }

/* Shine Effect */
.btn-primary::before {
  content: ''; position: absolute; top: 0; left: -100%; width: 50%; height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.4), transparent);
  transform: skewX(-25deg);
  transition: 0.5s;
  animation: shineBtn 3s infinite;
}

/* Secondary Button */
.btn-secondary { 
  background: rgba(255, 255, 255, 0.03); 
  border: 1px solid var(--glass-border); 
  color: var(--text-main); 
  backdrop-filter: blur(10px);
}
.btn-secondary:hover { 
  background: rgba(255, 255, 255, 0.08); 
  border-color: rgba(255, 255, 255, 0.2);
  transform: translateY(-2px);
}
.btn-secondary:active { transform: translateY(0) scale(0.98); }

/* Trust Badges */
.trust-badges {
  margin-top: 32px; padding-top: 24px; 
  border-top: 1px solid var(--glass-border);
  display: flex; justify-content: center; gap: 12px;
}
.badge { 
  display: flex; align-items: center; gap: 8px; 
  padding: 8px 16px;
  background: rgba(255,255,255,0.03);
  border-radius: 12px;
  border: 1px solid transparent;
  color: var(--text-sub); font-size: 12px; font-weight: 500;
  transition: all 0.3s;
}
.badge:hover {
  background: rgba(255,255,255,0.06);
  border-color: var(--glass-border);
  color: var(--text-main);
}
.badge svg { width: 16px; height: 16px; color: var(--green); }

/* Animations */
@keyframes slideUp { from { opacity: 0; transform: translateY(40px); } to { opacity: 1; transform: translateY(0); } }
@keyframes shineBtn { 
  0% { left: -100%; } 
  20% { left: 200%; } 
  100% { left: 200%; } 
}
@keyframes bgShift { from { transform: translate(0, 0); } to { transform: translate(-5%, -5%); } }

/* Debug Console */
#debug-console { display: none; position: fixed; bottom: 0; left: 0; right: 0; height: 150px; background: #000; color: #0f0; font-family: monospace; font-size: 12px; padding: 10px; z-index: 9999; overflow-y: auto; user-select: text; -webkit-user-select: text; }

/* Anti-Copy */
body { user-select: none; -webkit-user-select: none; }
img { user-select: none; -webkit-user-drag: none; pointer-events: none; }
a, button { user-select: none; }

/* Mobile Tweaks */
@media (max-width: 480px) {
  .main-card { padding: 32px 24px; border-radius: 24px; }
  h1 { font-size: 28px; }
  .btn { height: 52px; font-size: 16px; }
  .trust-badges { flex-wrap: wrap; }
}

/* Ticker Optimization */
.animate-marquee {
  display: flex;
  min-width: 100%;
  will-change: transform;
  animation: marquee 25s linear infinite;
}

@keyframes marquee {
  0% { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

/* Prevent CLS on Ticker items */
#btcTop, #ethTop, #btcTop2 {
  display: inline-block;
  min-width: 5em;
  text-align: right;
  font-feature-settings: "tnum";
  font-variant-numeric: tabular-nums;
}
