/*
 * Wan-S2V Unified Styles
 * =================================
 * 
 * Combined and refactored styles from index.css and modern-styles.css
 * Features:
 * - Dark gradient background with animations
 * - Glassmorphism effects
 * - Neon glow effects
 * - Smooth animations and transitions
 * - Modern typography and layout
 * - Responsive design
 * - Magic wand animations
 * - Fixed scrolling performance issues
 */

/* ===== CSS Variables ===== */
:root {
  /* === Unified Color System === */
  /* Background Colors */
  --bg-primary: #0a0a0a;
  --bg-secondary: #1a1a1a;
  --bg-tertiary: #16213e;
  --bg-card: rgba(255, 255, 255, 0.05);
  --bg-card-hover: rgba(255, 255, 255, 0.1);
  --bg-table: rgba(255, 255, 255, 0.95);
  
  /* Text Colors - High Contrast */
  --text-primary: #ffffff;
  --text-secondary: #a1a1aa;
  --text-tertiary: #cbd5e1;
  --text-muted: #94a3b8;
  --text-inverse: #0f172a;
  
  /* Accent Colors */
  --accent-primary: #6366f1;
  --accent-secondary: #764ba2;
  --accent-tertiary: #f093fb;
  --accent-success: #43e97b;
  --accent-info: #4facfe;
  --accent-warning: #fbbf24;
  --accent-error: #f5576c;
  
  /* Magic Colors */
  --magic-yellow: #fbbf24;
  --magic-glow: #f59e0b;
  
  /* Gradient Colors */
  --gradient-primary: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  --gradient-secondary: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
  --gradient-accent: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
  --gradient-dark: linear-gradient(135deg, #1e3c72 0%, #2a5298 100%);
  --gradient-hero: radial-gradient(circle at 20% 50%, rgba(102, 126, 234, 0.15) 0%, transparent 50%),
                     radial-gradient(circle at 80% 20%, rgba(240, 147, 251, 0.15) 0%, transparent 50%),
                     radial-gradient(circle at 40% 80%, rgba(67, 233, 123, 0.15) 0%, transparent 50%);
  
  /* Glassmorphism */
  --glass-bg: rgba(255, 255, 255, 0.08);
  --glass-border: rgba(255, 255, 255, 0.12);
  --glass-bg-strong: rgba(255, 255, 255, 0.12);
  --glass-border-strong: rgba(255, 255, 255, 0.20);
  
  /* Shadows */
  --shadow-glass: 0 16px 64px rgba(0, 0, 0, 0.3);
  --shadow-glass-hover: 0 24px 96px rgba(102, 126, 234, 0.4);
  --shadow-neon: 0 0 20px rgba(102, 126, 234, 0.6);
  --shadow-card: 0 8px 32px rgba(0, 0, 0, 0.4);
  --shadow-glow: 0 0 20px rgba(99, 102, 241, 0.3);
  
  /* Spacing */
  --spacing-xs: 0.25rem;
  --spacing-sm: 0.5rem;
  --spacing-md: 1rem;
  --spacing-lg: 1.5rem;
  --spacing-xl: 2rem;
  --spacing-2xl: 3rem;
  --spacing-3xl: 4rem;
  
  /* Border Radius */
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 20px;
  --radius-xl: 24px;
  
  /* Legacy Variables */
  --primary-bg: var(--bg-primary);
  --secondary-bg: var(--bg-secondary);
  --accent-color: var(--accent-primary);
  --accent-glow: var(--accent-secondary);
  --border-color: #27272a;
  --card-bg: var(--bg-card);
  --card-hover: var(--bg-card-hover);
}

/* ===== Global Reset & Base Styles ===== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  /* Removed scroll-behavior: smooth to fix scrolling resistance issues */
  font-size: 16px;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background: #000000;
  color: var(--text-primary);
  line-height: 1.6;
  min-height: 100vh;
  overflow-x: hidden;
  /* Enable hardware acceleration for better scrolling performance */
  transform: translateZ(0);
  will-change: transform;
}

/* Removed background gradient effects for pure black background */

/* Force override Bulma and other framework styles */
body,
.content p,
.content li,
.box,
.table td,
.table th {
  color: var(--text-primary) !important;
}

/* Override Bulma background colors */
.section,
.hero,
.box {
  background-color: transparent !important;
}

/* ===== Animations ===== */
@keyframes gradientShift {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

@keyframes float {
  0%, 100% { transform: translateY(0px); }
  50% { transform: translateY(-20px); }
}

@keyframes slideUp {
  0% { transform: translateY(100px); opacity: 0; }
  100% { transform: translateY(0); opacity: 1; }
}

@keyframes fadeIn {
  0% { opacity: 0; }
  100% { opacity: 1; }
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.5; }
}

@keyframes slideInLeft {
  0% { transform: translateX(-100%); opacity: 0; }
  100% { transform: translateX(0); opacity: 1; }
}

@keyframes slideInRight {
  0% { transform: translateX(100%); opacity: 0; }
  100% { transform: translateX(0); opacity: 1; }
}

@keyframes scaleIn {
  from {
    opacity: 0;
    transform: scale(0.8);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

/* 魔法棒图标样式 */
.magic-wand-icon {
  position: relative;
  display: inline-block;
  animation: magicFloat 3s ease-in-out infinite;
}

.magic-wand-icon::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 100px;
  height: 100px;
  background: radial-gradient(circle, rgba(251, 191, 36, 0.3) 0%, transparent 70%);
  border-radius: 50%;
  transform: translate(-50%, -50%);
  animation: magicPulse 2s ease-in-out infinite;
}

.magic-wand-icon i {
  position: relative;
  z-index: 2;
  filter: drop-shadow(0 0 10px var(--magic-yellow));
  animation: magicSparkle 4s linear infinite;
}

@keyframes magicFloat {
  0%, 100% { transform: translateY(0px); }
  50% { transform: translateY(-10px); }
}

@keyframes magicPulse {
  0%, 100% { 
    transform: translate(-50%, -50%) scale(1);
    opacity: 0.3;
  }
  50% { 
    transform: translate(-50%, -50%) scale(1.2);
    opacity: 0.6;
  }
}

@keyframes magicSparkle {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* ===== Typography ===== */
.gradient-text {
  background: linear-gradient(135deg, #ffffff 0%, #f8fafc 50%, #e2e8f0 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  filter: brightness(1.1) contrast(1.05);
}

.text-shadow {
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
}

h1, h2, h3, h4, h5, h6 {
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.6);
  font-weight: 700;
  line-height: 1.2;
}

h1 { 
  font-size: 3.5rem; 
  font-weight: 800;
  color: #ffffff !important;
}

h2 { 
  font-size: 2.8rem; 
  font-weight: 700;
  color: #ffffff !important;
}

h3 { 
  font-size: 2.2rem; 
  font-weight: 600;
  color: #ffffff !important;
}

h4 { 
  font-size: 1.6rem; 
  font-weight: 600;
  color: #ffffff !important;
}

h5 { 
  font-size: 1.3rem; 
  font-weight: 600;
  color: #ffffff !important;
}

h6 { 
  font-size: 1rem; 
  font-weight: 600;
  color: #ffffff !important;
}

p {
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
  margin-bottom: 1rem;
}

/* Clean bright headings without dirty gradients */
.section h2,
.section h3,
.section .title.is-2,
.section .title.is-3 {
  color: #ffffff !important;
  font-weight: 700 !important;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.6) !important;
  background: none !important;
  -webkit-text-fill-color: #ffffff !important;
}

.section h2,
.section .title.is-2 {
  font-size: 2.8rem !important;
}

.section h3,
.section .title.is-3 {
  font-size: 2.2rem !important;
}

/* Alternative clean gradient for specific elements that need it */
.clean-gradient {
  background: linear-gradient(135deg, #ffffff 0%, #f1f5f9 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* Apple-style bright gradient title */
.apple-gradient {
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  filter: brightness(1.2) contrast(1.1);
  text-shadow: 0 0 30px rgba(102, 126, 234, 0.5);
}

/* Override any remaining gradient text in sections */
.section .gradient-text {
  background: none !important;
  -webkit-text-fill-color: #ffffff !important;
  color: #ffffff !important;
  filter: none !important;
}

/* Legacy title styles */
.title {
  color: var(--text-primary);
  font-weight: 600;
  margin-bottom: 1.5rem;
}

.title.is-1 {
  font-size: 3.5rem;
  background: linear-gradient(135deg, #ffffff 0%, #a1a1aa 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.title.is-2 {
  font-size: 2.5rem;
  color: var(--text-primary);
  text-align: center;
  margin-bottom: 2rem;
  text-shadow: 0 0 10px rgba(255, 255, 255, 0.3);
}

.title.is-3 {
  font-size: 2rem;
  color: #ffffff !important;
  text-align: center;
  margin-bottom: 1.5rem;
  font-weight: 700;
  letter-spacing: 0.05em;
}

/* 强制覆盖Bulma样式 */
h2.title.is-3,
.title.is-3 {
  color: #ffffff !important;
}

.title.is-4 {
  font-size: 1.5rem;
  color: var(--text-primary);
  text-align: center;
  margin-bottom: 1rem;
  text-shadow: 0 0 8px rgba(255, 255, 255, 0.3);
}

.title.is-5 {
  font-size: 1.2rem;
  color: var(--text-primary);
  margin-bottom: 1rem;
  text-shadow: 0 0 6px rgba(255, 255, 255, 0.3);
}

/* ===== Glassmorphism Effects ===== */
.glass-morphism {
  background: var(--glass-bg);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-xl);
}

.glass-card {
  background: var(--glass-bg-strong);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid var(--glass-border-strong);
  border-radius: var(--radius-lg);
  padding: var(--spacing-xl);
  margin: var(--spacing-md) 0;
  transition: all 0.3s ease;
}

/* Override Bulma box styles */
.box {
  background: var(--glass-bg-strong) !important;
  backdrop-filter: blur(10px) !important;
  -webkit-backdrop-filter: blur(10px) !important;
  border: 1px solid var(--glass-border-strong) !important;
  border-radius: var(--radius-lg) !important;
  color: var(--text-primary) !important;
  padding: 2rem;
  transition: all 0.3s ease;
  box-shadow: var(--shadow-card);
}

.box:hover {
  border-color: var(--accent-primary) !important;
  box-shadow: var(--shadow-glass-hover) !important;
  background: var(--card-hover) !important;
  transform: translateY(-5px);
}

.glass-card:hover {
  transform: translateY(-5px);
  border-color: rgba(102, 126, 234, 0.5);
  box-shadow: var(--shadow-glass-hover);
}

/* ===== Neon Effects ===== */
.neon-glow {
  box-shadow: 0 0 20px rgba(102, 126, 234, 0.5),
              0 0 40px rgba(102, 126, 234, 0.3),
              0 0 60px rgba(102, 126, 234, 0.1);
}

/* ===== Hover Effects ===== */
.hover-lift {
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.hover-lift:hover {
  transform: translateY(-8px) scale(1.02);
  box-shadow: 0 20px 40px rgba(102, 126, 234, 0.3);
}

/* ===== Buttons ===== */
.btn-primary {
  background: var(--gradient-primary);
  color: white;
  border: none;
  padding: 12px 24px;
  border-radius: var(--radius-md);
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

.btn-primary::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
  transition: left 0.5s ease;
}

.btn-primary:hover::before {
  left: 100%;
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 30px rgba(102, 126, 234, 0.4);
}

.btn-secondary {
  background: var(--glass-bg-strong);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid var(--glass-border-strong);
  color: white;
  padding: 12px 24px;
  border-radius: var(--radius-md);
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.2);
  transform: translateY(-2px);
  box-shadow: 0 10px 30px rgba(102, 126, 234, 0.3);
}

/* Legacy button styles */
.link-block .button {
  background: var(--card-bg);
  border: 2px solid var(--border-color);
  color: var(--text-primary);
  border-radius: 50px;
  padding: 0.75rem 2rem;
  font-weight: 500;
  transition: all 0.3s ease;
  backdrop-filter: blur(10px);
  position: relative;
  overflow: hidden;
}

.link-block .button::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.1), transparent);
  transition: left 0.5s;
}

.link-block .button:hover::before {
  left: 100%;
}

.link-block .button:hover {
  background: var(--accent-color);
  border-color: var(--accent-color);
  transform: translateY(-3px);
  box-shadow: var(--shadow-glow);
}

.link-block .button .icon {
  margin-right: 0.5rem;
}

/* ===== Navigation ===== */
.navbar {
  position: fixed;
  top: 0;
  width: 100%;
  z-index: 50;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(0, 0, 0, 0.1);
  padding: 1rem 0;
  box-shadow: 0 2px 20px rgba(0, 0, 0, 0.1);
}

/* Conventional header layout */
.header {
  background: rgba(255, 255, 255, 0.98);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(0, 0, 0, 0.1);
  box-shadow: 0 2px 20px rgba(0, 0, 0, 0.1);
}

.header .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem var(--spacing-md);
  max-width: 1200px;
  margin: 0 auto;
}

.header-logo {
  font-size: 1.4rem;
  font-weight: 700;
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.header-logo-img {
  height: 48px;
  width: 48px;
  object-fit: contain;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.1);
  padding: 3px;
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.header-nav {
  display: flex;
  gap: 2rem;
  align-items: center;
}

.header-nav a {
  color: var(--bg-secondary);
  text-decoration: none;
  font-weight: 500;
  transition: color 0.3s ease;
}

.header-nav a:hover {
  color: var(--accent-primary);
}

/* Legacy navbar styles */
.navbar {
  background: rgba(10, 10, 10, 0.95);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border-color);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

.navbar-brand, .navbar-menu {
  background: transparent;
}

.navbar-item {
  color: var(--text-primary) !important;
  transition: all 0.3s ease;
}

.navbar-item:hover {
  background: var(--card-hover) !important;
  color: var(--accent-color) !important;
  transform: translateY(-2px);
}

.navbar-dropdown {
  background: var(--secondary-bg);
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-card);
}

.navbar-dropdown .navbar-item:hover {
  background: var(--card-hover) !important;
}

/* Override Bulma navbar styles */
.navbar,
.navbar-brand,
.navbar-menu {
  background: transparent !important;
}

.navbar-item {
  color: var(--text-secondary) !important;
  background: transparent !important;
}

.navbar-item:hover {
  color: var(--text-primary) !important;
  background: var(--glass-bg-strong) !important;
}

.navbar-dropdown {
  background: var(--glass-bg-strong) !important;
  border: 1px solid var(--glass-border-strong) !important;
}

.navbar .container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 var(--spacing-md);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.navbar-brand {
  font-size: 1.5rem;
  font-weight: 700;
}

.navbar-menu {
  display: flex;
  gap: 2rem;
  align-items: center;
}

.nav-link {
  position: relative;
  transition: all 0.3s ease;
  text-decoration: none;
  color: var(--text-secondary);
  font-weight: 500;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--gradient-primary);
  transition: width 0.3s ease;
}

.nav-link:hover::after {
  width: 100%;
}

.nav-link:hover {
  color: var(--text-primary);
}

.navbar-dropdown {
  position: absolute;
  top: 100%;
  right: 0;
  min-width: 280px;
  margin-top: 0.5rem;
  max-width: 350px;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-10px);
  transition: all 0.3s ease;
  z-index: 1000;
}

.navbar-item.has-dropdown.is-active .navbar-dropdown {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.navbar-dropdown .navbar-item {
  display: block;
  padding: 0.75rem 1.25rem;
  color: var(--bg-secondary);
  text-decoration: none;
  transition: all 0.3s ease;
  border: 2px solid transparent;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.navbar-dropdown .navbar-item:hover {
  background: rgba(102, 126, 234, 0.1);
  color: var(--accent-primary);
  border-color: rgba(102, 126, 234, 0.3);
  transform: translateX(-2px);
}

.navbar-dropdown .navbar-item:active {
  background: rgba(102, 126, 234, 0.2);
  border-color: rgba(102, 126, 234, 0.5);
}

/* Ensure dropdown stays visible when hovering over it (for better UX) */
.navbar-item.has-dropdown.is-active .navbar-dropdown:hover {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
  pointer-events: auto;
}

/* ===== Hero Section ===== */
.hero-gradient {
  background: var(--gradient-hero);
  padding: var(--spacing-3xl) 0;
  text-align: center;
}

.hero-content {
  max-width: 800px;
  margin: 0 auto;
}

.hero-content h1 {
  font-size: 3.5rem;
  margin-bottom: var(--spacing-lg);
  animation: slideUp 0.8s ease-out;
}

.hero-subtitle {
  font-size: 1.25rem;
  color: var(--text-secondary);
  margin-bottom: var(--spacing-xl);
  animation: fadeIn 1s ease-out 0.2s both;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.7);
}

.hero-affiliation {
  margin-bottom: var(--spacing-xl);
  animation: fadeIn 1s ease-out 0.4s both;
}

.hero-affiliation .glass-card {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1.5rem;
}

.affiliation-logo {
  height: 24px;
  width: auto;
}

.hero-links {
  display: flex;
  justify-content: center;
  gap: 1rem;
  flex-wrap: wrap;
  margin-bottom: var(--spacing-lg);
}

/* Legacy hero styles */
.hero {
  background: transparent;
  position: relative;
  padding: 4rem 0;
}

.hero::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(180deg, transparent 0%, rgba(99, 102, 241, 0.1) 100%);
  z-index: -1;
}

.hero-body {
  padding: 4rem 1.5rem;
}

.publication-title {
  font-size: 3.5rem;
  font-weight: 700;
  background: linear-gradient(135deg, #ffffff 0%, #a1a1aa 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  text-align: center;
  margin-bottom: 2rem;
  text-shadow: 0 0 30px rgba(255, 255, 255, 0.3);
  letter-spacing: -0.02em;
}

.publication-authors {
  font-size: 1.3rem;
  color: var(--text-secondary);
  text-align: center;
  margin-bottom: 2rem;
  font-weight: 300;
}

.author-block {
  display: inline-block;
  margin: 0 0.5rem;
  padding: 0.5rem 1rem;
  background: var(--card-bg);
  border-radius: 25px;
  border: 1px solid var(--border-color);
  transition: all 0.3s ease;
}

.author-block:hover {
  background: var(--card-hover);
  border-color: var(--accent-color);
  transform: translateY(-2px);
  box-shadow: var(--shadow-glow);
}

.publication-links {
  display: flex;
  justify-content: center;
  gap: 1rem;
  flex-wrap: wrap;
  margin-top: 2rem;
}

/* ===== Sections ===== */
.section {
  padding: var(--spacing-3xl) 0;
  position: relative;
}

.section.hero.is-light {
  background: var(--primary-bg);
  border-radius: 20px;
  margin: 2rem 1rem;
  box-shadow: var(--shadow-card);
  border: 1px solid var(--border-color);
}

.section.hero.is-small {
  background: transparent;
  padding: 2rem 0;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 var(--spacing-md);
}

/* ===== Content Styles ===== */
.content p {
  color: var(--text-primary);
  font-size: 1.1rem;
  line-height: 1.8;
  margin-bottom: 1rem;
}

.content.has-text-justified p {
  text-align: justify;
  color: var(--text-primary);
}

.content.has-text-centered p {
  text-align: center;
  color: var(--text-primary);
}

/* ===== Demo Grid ===== */
.demo-grid {
  display: grid;
  grid-template-columns: 1fr auto 1fr auto 1fr;
  gap: var(--spacing-md);
  align-items: center;
  margin-bottom: var(--spacing-xl);
}

.demo-item {
  text-align: center;
}

.demo-operator {
  font-size: 2rem;
  font-weight: bold;
  color: var(--text-secondary);
}

/* ===== Video & Audio Containers ===== */
.video-container {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-glass);
  transition: all 0.3s ease;
  margin-bottom: var(--spacing-md);
}

.video-container:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-glass-hover);
}

.video-container video,
.video-container img {
  border-radius: var(--radius-lg);
  width: 100%;
  height: auto;
  transition: all 0.3s ease;
}

.video-container:hover video,
.video-container:hover img {
  transform: scale(1.05);
}

.audio-container {
  display: flex;
  justify-content: center;
  align-items: center;
  padding: var(--spacing-lg);
}

.audio-container audio {
  width: 100%;
  max-width: 400px;
}

.video-caption {
  background: var(--glass-bg);
  backdrop-filter: blur(10px);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-md);
  padding: var(--spacing-md);
  color: var(--text-secondary);
  text-align: center;
  margin-top: var(--spacing-md);
}

.video-item {
  margin-bottom: var(--spacing-2xl);
}

.video-grid {
  display: grid;
  gap: var(--spacing-xl);
}

/* Legacy video styles */
.video-player {
  width: 100%;
  border-radius: 15px;
  box-shadow: var(--shadow-card);
  transition: all 0.3s ease;
}

.video-player:hover {
  transform: scale(1.02);
  box-shadow: var(--shadow-glow);
}

.caption {
  color: var(--text-secondary);
  font-size: 1rem;
  text-align: center;
  margin-top: 1rem;
  padding: 1rem;
  background: var(--card-bg);
  border-radius: 10px;
  border: 1px solid var(--border-color);
  text-shadow: 0 0 3px rgba(161, 161, 170, 0.2);
}

/* ===== Highlight Box ===== */
.highlight-box {
  background: var(--glass-bg);
  border: 1px solid rgba(102, 126, 234, 0.5);
  border-radius: var(--radius-lg);
  padding: var(--spacing-xl);
  position: relative;
  overflow: hidden;
}

.highlight-box::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--gradient-primary);
  opacity: 0.8;
}

.highlight-text {
  color: #fbbf24;
  font-weight: 600;
}

/* ===== Method Section ===== */
.method-overview,
.method-audio,
.method-data {
  text-align: center;
}

.method-image {
  display: flex;
  justify-content: center;
  align-items: center;
  margin-bottom: var(--spacing-lg);
}

.method-image img {
  max-width: 80%;
  height: auto;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-glass);
  background: rgba(255, 255, 255, 0.95) !important;
  padding: 15px !important;
  border: 1px solid rgba(255, 255, 255, 0.3) !important;
}

/* Method section container for better control */
.method-image-container {
  position: relative;
  display: inline-block;
  background: rgba(255, 255, 255, 0.98);
  padding: 15px;
  border-radius: var(--radius-lg);
  border: 1px solid rgba(255, 255, 255, 0.4);
  box-shadow: var(--shadow-glass);
  max-width: 70%;
  margin: 0 auto;
}

.method-image-container img {
  max-width: 100%;
  height: auto;
  background: transparent !important;
  border: none !important;
  padding: 0 !important;
  border-radius: 0 !important;
  display: block;
}

/* Ensure charts maintain their original colors while being readable */
.method-image img[src*="pipeline"],
.method-image img[src*="audio_pipeline"],
.method-image img[src*="sankey"] {
  filter: none !important;
  background: rgba(255, 255, 255, 0.98) !important;
  padding: 20px !important;
  border: 1px solid rgba(255, 255, 255, 0.4) !important;
  border-radius: var(--radius-lg) !important;
}

/* Legacy method styles */
/* Method部分图片对比度增强 */
section img[src*="pipeline"],
section img[src*="audio_pipeline"] {
  filter: contrast(1.3) brightness(1.1);
  border: 2px solid var(--border-color);
  background: #f8f9fa;
  padding: 15px;
  box-shadow: var(--shadow-card);
}

/* ===== Tables ===== */
.table-container {
  overflow-x: auto;
  margin-bottom: var(--spacing-lg);
  -webkit-overflow-scrolling: touch;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card);
}

.comparison-table {
  width: 100%;
  min-width: 800px;
  border-collapse: collapse;
  background: var(--bg-table);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-card);
  color: var(--text-inverse) !important;
}

.comparison-table th,
.comparison-table td {
  padding: var(--spacing-md);
  text-align: center;
  border-bottom: 1px solid rgba(15, 23, 42, 0.1);
  color: var(--text-inverse) !important;
  white-space: nowrap;
}

.comparison-table th {
  background: #8b5cf6;
  color: white !important;
  font-weight: 700;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  position: sticky;
  top: 0;
  z-index: 10;
}

.comparison-table td {
  background: rgba(255, 255, 255, 0.98);
  color: var(--text-inverse) !important;
  font-weight: 500;
  font-size: 0.9rem;
}

.comparison-table tr:hover td {
  background: rgba(102, 126, 234, 0.08);
  color: var(--text-inverse) !important;
}

.comparison-table tr:nth-child(even) td {
  background: rgba(248, 250, 252, 0.8);
}

.comparison-table tr:nth-child(even):hover td {
  background: rgba(102, 126, 234, 0.12);
}

.highlight-row {
  background: linear-gradient(135deg, rgba(102, 126, 234, 0.15) 0%, rgba(118, 75, 162, 0.15) 100%) !important;
}

.highlight-row td {
  color: var(--text-inverse) !important;
  font-weight: 700;
  background: transparent !important;
}

/* Table strong/bold text */
.comparison-table strong,
.comparison-table td strong {
  color: var(--accent-primary) !important;
  font-weight: 700;
}

/* Mobile table improvements */
@media (max-width: 768px) {
  .comparison-table {
    min-width: 600px;
  }
  
  .comparison-table th,
  .comparison-table td {
    padding: var(--spacing-sm);
    font-size: 0.8rem;
  }
}

@media (max-width: 480px) {
  .comparison-table {
    min-width: 500px;
  }
  
  .comparison-table th,
  .comparison-table td {
    padding: 0.5rem;
    font-size: 0.75rem;
  }
}

/* Legacy table styles */
.table {
  background: var(--card-bg);
  border-radius: 15px;
  overflow: hidden;
  box-shadow: var(--shadow-card);
  border: 1px solid var(--border-color);
}

.table th {
  background: #ffffff;
  color: #000000;
  border-color: var(--border-color);
  font-weight: 700;
  font-size: 1.1em;
}

.table td {
  color: #000000;
  border-color: var(--border-color);
  background: #ffffff;
}

.table tbody tr:hover {
  background: #f8f9fa;
}

.table tbody tr:nth-child(even) {
  background: #ffffff;
}

/* ===== Images ===== */
img {
  border-radius: 15px;
  transition: all 0.3s ease;
}

img:hover {
  transform: scale(1.02);
  box-shadow: var(--shadow-glow);
}

/* ===== Columns ===== */
.columns {
  margin: 0;
}

.column {
  padding: 1rem;
}

/* ===== Citation Section ===== */
.citation-box {
  background: rgba(0, 0, 0, 0.3);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-md);
  padding: var(--spacing-xl);
  overflow-x: auto;
}

.citation-box code {
  font-family: 'Courier New', monospace;
  font-size: 0.9rem;
  line-height: 1.6;
  color: var(--text-secondary);
}

/* ===== Scroll Progress ===== */
.scroll-indicator {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 4px;
  background: rgba(255, 255, 255, 0.1);
  z-index: 1000;
}

.scroll-progress {
  height: 100%;
  background: var(--gradient-primary);
  width: 0%;
  transition: width 0.3s ease;
}

/* Legacy progress bar */
.progress-bar {
  position: fixed;
  top: 0;
  left: 0;
  width: 0%;
  height: 3px;
  background: linear-gradient(90deg, var(--accent-color), var(--accent-glow));
  z-index: 9999;
  transition: width 0.3s ease;
  box-shadow: 0 0 10px var(--accent-color);
}

/* ===== Back to Top Button ===== */
.back-to-top {
  position: fixed;
  bottom: 30px;
  right: 30px;
  width: 50px;
  height: 50px;
  background: var(--gradient-primary);
  color: white;
  border: none;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  z-index: 1000;
  opacity: 0;
  visibility: hidden;
  transform: translateY(20px);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4);
}

.back-to-top.visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.back-to-top:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 20px rgba(102, 126, 234, 0.6);
  background: var(--gradient-secondary);
}

/* ===== Custom Scrollbar ===== */
.custom-scrollbar::-webkit-scrollbar {
  width: 8px;
}

.custom-scrollbar::-webkit-scrollbar-track {
  background: rgba(255, 255, 255, 0.1);
  border-radius: 4px;
}

.custom-scrollbar::-webkit-scrollbar-thumb {
  background: var(--gradient-primary);
  border-radius: 4px;
}

.custom-scrollbar::-webkit-scrollbar-thumb:hover {
  background: var(--gradient-secondary);
}

/* Legacy scrollbar styles */
::-webkit-scrollbar {
  width: 8px;
}

::-webkit-scrollbar-track {
  background: var(--secondary-bg);
}

::-webkit-scrollbar-thumb {
  background: var(--accent-color);
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--accent-glow);
}

/* ===== Footer ===== */
.footer {
  background: linear-gradient(135deg, #0f172a 0%, #1e293b 50%, #334155 100%);
  border-top: 1px solid rgba(59, 130, 246, 0.3);
  padding: 2rem 0;
  margin-top: 4rem;
  position: relative;
  overflow: hidden;
}

.footer::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(59, 130, 246, 0.5), transparent);
}

.footer .content p {
  color: var(--text-secondary);
  text-align: center;
}

.footer a {
  color: var(--accent-color);
  text-decoration: none;
}

.footer a:hover {
  color: var(--accent-glow);
  text-decoration: underline;
}

/* ===== Utility Classes ===== */
.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }

.purple-text {
  color: #8b5cf6 !important;
  font-weight: 700;
}

.mt-1 { margin-top: var(--spacing-xs); }
.mt-2 { margin-top: var(--spacing-sm); }
.mt-3 { margin-top: var(--spacing-md); }
.mt-4 { margin-top: var(--spacing-lg); }
.mt-6 { margin-top: var(--spacing-xl); }
.mt-8 { margin-top: var(--spacing-2xl); }
.mt-12 { margin-top: var(--spacing-3xl); }
.mt-16 { margin-top: 4rem; }

.mb-1 { margin-bottom: var(--spacing-xs); }
.mb-2 { margin-bottom: var(--spacing-sm); }
.mb-3 { margin-bottom: var(--spacing-md); }
.mb-4 { margin-bottom: var(--spacing-lg); }
.mb-6 { margin-bottom: var(--spacing-xl); }
.mb-8 { margin-bottom: var(--spacing-2xl); }
.mb-12 { margin-bottom: var(--spacing-3xl); }
.mb-16 { margin-bottom: 4rem; }

.p-4 { padding: var(--spacing-md); }
.p-6 { padding: var(--spacing-lg); }
.p-8 { padding: var(--spacing-xl); }
.p-12 { padding: var(--spacing-2xl); }

/* Legacy utility classes */
.container.is-max-desktop {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1rem;
}

.link-block {
  display: inline-block;
  margin: 0.5rem;
}

.external-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 120px;
}

.icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

/* ===== Special Effects ===== */
.fade-in-up {
  animation: fadeInUp 0.8s ease-out;
}

.slide-in-left {
  animation: slideInLeft 0.8s ease-out;
}

.slide-in-right {
  animation: slideInRight 0.8s ease-out;
}

.scale-in {
  animation: scaleIn 0.8s ease-out;
}

/* 滚动显示动画 */
.scroll-animate {
  opacity: 1;
  transform: translateY(0);
  transition: all 0.8s ease-out;
}

.scroll-animate.animate {
  opacity: 1;
  transform: translateY(0);
}

/* 增强的悬停效果 */
.video-item:hover .video-player {
  transform: scale(1.02);
  box-shadow: var(--shadow-glow);
}

.video-item:hover .caption {
  border-color: var(--accent-color);
  background: var(--card-hover);
}

/* 渐变背景卡片 */
.gradient-card {
  background: linear-gradient(135deg, var(--card-bg) 0%, rgba(99, 102, 241, 0.1) 100%);
  border: 1px solid var(--border-color);
  border-radius: 20px;
  padding: 2rem;
  transition: all 0.3s ease;
}

.gradient-card:hover {
  background: linear-gradient(135deg, var(--card-hover) 0%, rgba(99, 102, 241, 0.2) 100%);
  border-color: var(--accent-color);
  transform: translateY(-5px);
  box-shadow: var(--shadow-glow);
}

/* ===== Responsive Design ===== */
@media (max-width: 768px) {
  h1 { font-size: 2.5rem; }
  h2 { font-size: 2rem; }
  h3 { font-size: 1.5rem; }
  
  .hero-content h1 {
    font-size: 2.5rem;
  }
  
  .publication-title {
    font-size: 2.5rem;
  }
  
  .title.is-1 {
    font-size: 2.5rem;
  }
  
  .title.is-2 {
    font-size: 2rem;
  }
  
  .hero-body {
    padding: 2rem 1rem;
  }
  
  .section {
    padding: var(--spacing-2xl) 0;
  }
  
  .publication-links {
    flex-direction: column;
    align-items: center;
  }
  
  .link-block .button {
    width: 100%;
    max-width: 300px;
  }
  
  .magic-wand-icon {
    font-size: 2.5rem !important;
  }
  
  .demo-grid {
    grid-template-columns: 1fr;
    gap: var(--spacing-lg);
  }
  
  .demo-operator {
    display: none;
  }
  
  .hero-links {
    flex-direction: column;
    align-items: center;
  }
  
  .btn-primary,
  .btn-secondary {
    width: 100%;
    max-width: 300px;
    justify-content: center;
  }
  
  .navbar-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--glass-bg);
    backdrop-filter: blur(20px);
    border-top: 1px solid var(--glass-border);
    flex-direction: column;
    padding: var(--spacing-md);
  }
  
  .navbar-menu.active {
    display: flex;
  }
  
  .navbar-dropdown {
    position: static;
    margin-top: 0;
  }
  
  .video-grid.grid-2 {
    grid-template-columns: 1fr;
  }
  
  .columns.is-multiline {
    margin: 0;
  }
  
  .column.is-half {
    width: 100% !important;
  }
  
  .column.is-4 {
    width: 100% !important;
    margin-bottom: 2rem;
  }
  
  /* Responsive method chart sizing */
  .method-image-container {
    max-width: 85%;
    padding: 12px;
  }
  
  .method-image img {
    max-width: 85%;
  }
}

@media (max-width: 480px) {
  .container {
    padding: 0 var(--spacing-sm);
  }
  
  .glass-card {
    padding: var(--spacing-lg);
  }
  
  .hero-content h1 {
    font-size: 2rem;
  }
  
  h1 { font-size: 2rem; }
  h2 { font-size: 1.5rem; }
  
  /* Further reduce method chart size for mobile */
  .method-image-container {
    max-width: 95%;
    padding: 10px;
  }
  
  .method-image img {
    max-width: 95%;
    padding: 10px !important;
  }
}

/* Large screens - method charts should be even smaller */
@media (min-width: 1200px) {
  .method-image-container {
    max-width: 60%;
  }
}

/* Medium-large screens */
@media (min-width: 992px) and (max-width: 1199px) {
  .method-image-container {
    max-width: 65%;
  }
}

/* ===== Slider/Carousel Styles ===== */
.slider {
  position: relative;
  width: 100%;
  overflow: hidden;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-glass);
}

.slider-container {
  display: flex;
  flex-wrap: nowrap;
  flex-direction: row;
  overflow: hidden;
  -webkit-transform: translate3d(0, 0, 0);
  transform: translate3d(0, 0, 0);
  min-height: 100%;
}

.slider-container.is-vertical {
  flex-direction: column;
}

.slider-container .slider-item {
  flex: none;
  position: relative;
}

.slider-container .slider-item .image.is-covered img {
  object-fit: cover;
  object-position: center center;
  height: 100%;
  width: 100%;
}

.slider-container .slider-item .video-container {
  height: 0;
  padding-bottom: 0;
  padding-top: 56.25%;
  margin: 0;
  position: relative;
}

.slider-container .slider-item .video-container.is-1by1,
.slider-container .slider-item .video-container.is-square {
  padding-top: 100%;
}

.slider-container .slider-item .video-container.is-4by3 {
  padding-top: 75%;
}

.slider-container .slider-item .video-container.is-21by9 {
  padding-top: 42.857143%;
}

.slider-container .slider-item .video-container embed,
.slider-container .slider-item .video-container iframe,
.slider-container .slider-item .video-container object {
  position: absolute;
  top: 0;
  left: 0;
  width: 100% !important;
  height: 100% !important;
}

.slider-navigation-next,
.slider-navigation-previous {
  display: flex;
  justify-content: center;
  align-items: center;
  position: absolute;
  width: 42px;
  height: 42px;
  background: rgba(255, 255, 255, 0.9) center center no-repeat;
  background-size: 20px 20px;
  border: 1px solid rgba(255, 255, 255, 0.9);
  border-radius: 50%;
  box-shadow: 0 2px 5px rgba(50, 50, 50, 0.1);
  top: 50%;
  margin-top: -20px;
  left: 0;
  cursor: pointer;
  transition: opacity 0.3s, transform 0.3s;
  z-index: 10;
}

.slider-navigation-next:hover,
.slider-navigation-previous:hover {
  transform: scale(1.2);
  background: rgba(255, 255, 255, 1);
  box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4);
}

.slider-navigation-next.is-hidden,
.slider-navigation-previous.is-hidden {
  display: none;
  opacity: 0;
}

.slider-navigation-next svg,
.slider-navigation-previous svg {
  width: 25%;
  height: 25%;
  fill: var(--bg-secondary);
}

.slider-navigation-next {
  left: auto;
  right: 0;
  background: rgba(255, 255, 255, 0.9) center center no-repeat;
  background-size: 20px 20px;
}

.slider-pagination {
  display: none;
  justify-content: center;
  align-items: center;
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 0.5rem 1rem;
  text-align: center;
  z-index: 10;
}

.slider-pagination .slider-page {
  background: rgba(255, 255, 255, 0.7);
  width: 10px;
  height: 10px;
  border-radius: 50%;
  display: inline-block;
  margin: 0 3px;
  box-shadow: 0 2px 5px rgba(50, 50, 50, 0.1);
  transition: transform 0.3s;
  cursor: pointer;
}

.slider-pagination .slider-page.is-active,
.slider-pagination .slider-page:hover {
  transform: scale(1.4);
  background: rgba(255, 255, 255, 1);
  box-shadow: 0 2px 8px rgba(102, 126, 234, 0.4);
}

@media screen and (min-width: 800px) {
  .slider-pagination {
    display: flex;
  }
}

.hero.has-carousel {
  position: relative;
}

.hero.has-carousel + .hero-body,
.hero.has-carousel + .hero-footer,
.hero.has-carousel + .hero-head {
  z-index: 10;
  overflow: hidden;
}

.hero.has-carousel .hero-carousel {
  position: absolute;
  top: 0;
  left: 0;
  bottom: 0;
  right: 0;
  height: auto;
  border: none;
  margin: auto;
  padding: 0;
  z-index: 0;
}

.hero.has-carousel .hero-carousel .slider {
  width: 100%;
  max-width: 100%;
  overflow: hidden;
  height: 100% !important;
  max-height: 100%;
  z-index: 0;
}

.hero.has-carousel .hero-carousel .slider .has-background {
  max-height: 100%;
}

.hero.has-carousel .hero-carousel .slider .has-background .is-background {
  object-fit: cover;
  object-position: center center;
  height: 100%;
  width: 100%;
}

.hero.has-carousel .hero-body {
  margin: 0 3rem;
  z-index: 10;
}

/* ===== Accessibility ===== */
@media (prefers-reduced-motion: reduce) {
  * {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* Focus styles for better accessibility */
a:focus,
button:focus,
input:focus,
textarea:focus {
  outline: 2px solid var(--gradient-primary);
  outline-offset: 2px;
}

/* Skip to main content link for screen readers */
.skip-to-content {
  position: absolute;
  top: -40px;
  left: 0;
  background: var(--gradient-primary);
  color: white;
  padding: 8px;
  text-decoration: none;
  border-radius: 0 0 4px 0;
  z-index: 100;
}

.skip-to-content:focus {
  top: 0;
}
