/* ============================================================
   杨嘉乐个人网站 - styles.css
   Anime Night Sky × Star Particles × Soft Glow
   ============================================================ */

/* Cursor Glow Effect */
#cursorGlow {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 9998;
  mix-blend-mode: screen;
}

/* CSS Variables */
:root {
  /* Backgrounds - 夜空渐变 */
  --bg: #0a0a1a;
  --bg-2: #0f0f2a;
  --bg-gradient: linear-gradient(135deg, #0a0a1a 0%, #1a1035 50%, #0f0f2a 100%);
  --surface-1: rgba(255, 255, 255, 0.05);
  --surface-2: rgba(255, 255, 255, 0.08);
  --surface-3: rgba(255, 255, 255, 0.12);

  /* Borders */
  --border: rgba(255, 255, 255, 0.1);
  --border-strong: rgba(255, 255, 255, 0.2);
  --border-accent: rgba(255, 182, 193, 0.3);

  /* Text */
  --text-1: #FFFFFF;
  --text-2: #E0E0E0;
  --text-3: #B0B0C0;
  --text-4: #707090;

  /* Accent - 粉色系 */
  --accent-primary: #FF69B4;
  --accent-primary-hover: #FF85C1;
  --accent-secondary: #DA70D6;
  --accent-tertiary: #9370DB;
  --accent-gradient: linear-gradient(135deg, #FF69B4 0%, #DA70D6 50%, #9370DB 100%);
  --accent-soft: rgba(255, 105, 180, 0.15);
  --accent-glow: rgba(255, 105, 180, 0.4);

  /* Semantic */
  --success: #50FA7B;
  --warning: #FFD93D;
  --error: #FF6B6B;

  /* Typography */
  --font-sans: 'Inter', 'PingFang SC', 'Microsoft YaHei', sans-serif;
  --font-mono: 'JetBrains Mono', 'Fira Code', monospace;

  /* Spacing */
  --space-xs: 4px;
  --space-sm: 8px;
  --space-md: 16px;
  --space-lg: 24px;
  --space-xl: 32px;
  --space-2xl: 48px;
  --space-3xl: 64px;

  /* Radius */
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  --radius-full: 9999px;

  /* Shadows */
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.3);
  --shadow-md: 0 4px 20px rgba(0, 0, 0, 0.4);
  --shadow-lg: 0 10px 40px rgba(0, 0, 0, 0.5);
  --shadow-accent: 0 20px 60px rgba(255, 105, 180, 0.3);
}

/* Reset */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-sans);
  background: var(--bg);
  color: var(--text-1);
  line-height: 1.6;
  overflow-x: hidden;
}

a {
  color: inherit;
  text-decoration: none;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

button {
  font-family: inherit;
  cursor: pointer;
  border: none;
  background: none;
}

/* Navigation */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  padding: var(--space-md) var(--space-xl);
  transition: background 0.3s, backdrop-filter 0.3s;
}

.nav.is-scrolled {
  background: rgba(10, 10, 26, 0.9);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
}

.nav-links a {
  color: var(--text-3);
}

.nav-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  font-weight: 600;
  font-size: 18px;
}

.logo-mark {
  width: 32px;
  height: 32px;
  background: var(--accent-gradient);
  border-radius: var(--radius-sm);
  flex-shrink: 0;
  box-shadow: 0 2px 8px rgba(102, 126, 234, 0.4);
}

.nav-links {
  display: flex;
  gap: var(--space-xl);
}

.nav-links a {
  color: var(--text-3);
  font-size: 14px;
  font-weight: 500;
  transition: color 0.2s;
}

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

/* Hero Section */
.hero {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 80px var(--space-xl) var(--space-2xl);
  background: #0a0a1a;
  position: relative;
  overflow: hidden;
  gap: var(--space-xl);
}

/* Aurora Background Effect - Clean ethereal anime style */
.aurora-bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  z-index: 1;
  pointer-events: none;
  background: #0a0a1a;
}

/* Layered aurora gradients that blend softly */
.aurora-bg::before,
.aurora-bg::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border-radius: 0;
}

.aurora-bg::before {
  background:
    radial-gradient(ellipse 100% 60% at 20% 20%, rgba(255, 105, 180, 0.25) 0%, transparent 60%),
    radial-gradient(ellipse 80% 50% at 80% 30%, rgba(147, 112, 219, 0.2) 0%, transparent 55%),
    radial-gradient(ellipse 120% 40% at 50% 80%, rgba(218, 112, 214, 0.15) 0%, transparent 50%);
  animation: auroraBreath 10s ease-in-out infinite;
}

.aurora-bg::after {
  background:
    radial-gradient(ellipse 70% 80% at 70% 60%, rgba(255, 105, 180, 0.2) 0%, transparent 60%),
    radial-gradient(ellipse 90% 40% at 30% 70%, rgba(147, 112, 219, 0.18) 0%, transparent 50%);
  animation: auroraBreath 12s ease-in-out infinite reverse;
}

@keyframes auroraBreath {
  0%, 100% { opacity: 0.6; transform: scale(1) translateY(0); }
  50% { opacity: 1; transform: scale(1.08) translateY(-3%); }
}

/* Floating soft orbs */
.aurora-orb {
  position: absolute;
  border-radius: 50%;
  z-index: 2;
  filter: blur(40px);
  animation: orbDrift 20s ease-in-out infinite;
}

.aurora-orb:nth-child(4) {
  width: 350px;
  height: 350px;
  background: radial-gradient(circle, rgba(255, 105, 180, 0.35) 0%, transparent 70%);
  top: 10%;
  left: 5%;
  animation-duration: 18s;
}

.aurora-orb:nth-child(5) {
  width: 400px;
  height: 400px;
  background: radial-gradient(circle, rgba(147, 112, 219, 0.3) 0%, transparent 70%);
  top: 5%;
  right: 5%;
  animation-duration: 22s;
  animation-delay: -5s;
}

.aurora-orb:nth-child(6) {
  width: 300px;
  height: 300px;
  background: radial-gradient(circle, rgba(218, 112, 214, 0.3) 0%, transparent 70%);
  bottom: 15%;
  left: 35%;
  animation-duration: 16s;
  animation-delay: -10s;
}

@keyframes orbDrift {
  0%, 100% { transform: translate(0, 0); opacity: 0.6; }
  33% { transform: translate(30px, -20px); opacity: 0.9; }
  66% { transform: translate(-20px, 30px); opacity: 0.7; }
}

/* Hero Carousel */
.hero-carousel {
  position: relative;
  width: 100%;
  max-width: 900px;
  height: 380px;
  perspective: 1400px;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2;
}

.carousel-cards {
  position: relative;
  width: 100%;
  max-width: 700px;
  height: 270px;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2;
}

/* Navigation Buttons */
.carousel-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 48px;
  height: 48px;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 105, 180, 0.3);
  border-radius: 50%;
  font-size: 24px;
  color: #FF69B4;
  cursor: pointer;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 20px rgba(255, 105, 180, 0.2);
  transition: all 0.2s ease;
}

.carousel-nav:hover {
  background: rgba(255, 105, 180, 0.3);
  color: white;
  transform: translateY(-50%) scale(1.1);
  box-shadow: 0 0 30px rgba(255, 105, 180, 0.4);
}

.carousel-prev {
  left: 20px;
}

.carousel-next {
  right: 20px;
}

.video-card {
  position: absolute;
  width: 480px;
  height: 270px;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-accent);
  transition: transform 0.5s cubic-bezier(0.23, 1, 0.32, 1),
              box-shadow 0.3s ease,
              opacity 0.4s ease;
  transform-style: preserve-3d;
  opacity: 0.5;
}

.video-card.active {
  transform: translateX(0) rotateY(0deg) rotateX(0deg) scale(1);
  opacity: 1;
  z-index: 10;
  animation: breathe 3s ease-in-out infinite;
}

.video-card.left-card {
  transform: translateX(-200px) rotateY(10deg) rotateX(3deg) scale(0.8);
  opacity: 0.5;
  z-index: 5;
}

.video-card.right-card {
  transform: translateX(200px) rotateY(-10deg) rotateX(-3deg) scale(0.8);
  opacity: 0.5;
  z-index: 5;
}

/* Play button - 只在中心小区域响应点击 */
.card-play-btn {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 60px;
  height: 60px;
  background: rgba(255, 255, 255, 0.95);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.3s, transform 0.3s;
  box-shadow: 0 0 30px rgba(255, 105, 180, 0.5);
  cursor: pointer;
  z-index: 20;
  font-size: 18px;
}

.video-card:hover .card-play-btn {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1.1);
}

.card-play-btn::before {
  content: '';
  position: absolute;
  top: -10px;
  left: -10px;
  right: -10px;
  bottom: -10px;
}

.video-card:hover {
  box-shadow: 0 30px 80px rgba(102, 126, 234, 0.4);
}

.video-card:hover .card-inner {
  transform: scale(1.02);
}

@keyframes breathe {
  0%, 100% {
    box-shadow: 0 20px 60px rgba(255, 105, 180, 0.25);
  }
  50% {
    box-shadow: 0 25px 80px rgba(255, 105, 180, 0.5), 0 0 40px rgba(255, 105, 180, 0.3);
  }
}

.card-inner {
  width: 100%;
  height: 100%;
  transition: transform 0.3s ease;
}

.card-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: white;
  background: linear-gradient(135deg, #FF69B4 0%, #9370DB 100%);
}

.placeholder-icon {
  font-size: 48px;
  margin-bottom: var(--space-sm);
}

.card-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* 卡片内图片容器 */
.card-inner {
  width: 100%;
  height: 100%;
  overflow: hidden;
}

.card-inner .card-placeholder {
  width: 100%;
  height: 100%;
}

.placeholder-text {
  font-size: 14px;
  font-weight: 500;
}

.card-label {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: var(--space-md);
  background: linear-gradient(transparent, rgba(10, 10, 26, 0.9));
  color: white;
}

.label-title {
  display: block;
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 2px;
}

.label-views {
  font-size: 12px;
  opacity: 0.8;
}

/* Hero Info */
.hero-info {
  text-align: center;
  position: relative;
  z-index: 2;
  margin-top: var(--space-xl);
}

/* Avatar Wrapper with Ripple Effect */
.hero-avatar-wrapper {
  position: relative;
  width: 128px;
  height: 128px;
  margin: 0 auto var(--space-lg);
}

.hero-avatar {
  width: 128px;
  height: 128px;
  border-radius: 50%;
  overflow: hidden;
  border: 4px solid rgba(255, 105, 180, 0.5);
  box-shadow: 0 0 30px rgba(255, 105, 180, 0.4);
  cursor: pointer;
  transition: all 0.3s ease;
  position: relative;
  z-index: 2;
}

.hero-avatar:hover {
  transform: scale(1.05);
  box-shadow: 0 0 50px rgba(255, 105, 180, 0.6);
}

.hero-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Avatar Ripple Effect */
.avatar-ripple {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 128px;
  height: 128px;
  border-radius: 50%;
  border: 2px solid rgba(255, 105, 180, 0.5);
  opacity: 0;
  pointer-events: none;
}

.hero-avatar-wrapper:hover .avatar-ripple {
  animation: rippleEffect 2s ease-out infinite;
}

.avatar-ripple:nth-child(1) { animation-delay: 0s; }
.avatar-ripple:nth-child(2) { animation-delay: 0.6s; }
.avatar-ripple:nth-child(3) { animation-delay: 1.2s; }

@keyframes rippleEffect {
  0% {
    width: 128px;
    height: 128px;
    opacity: 0.6;
  }
  100% {
    width: 200px;
    height: 200px;
    opacity: 0;
  }
}

/* Music Icon on Avatar */
.avatar-music-icon {
  position: absolute;
  top: -10px;
  right: -10px;
  font-size: 20px;
  opacity: 0;
  transform: scale(0);
  transition: all 0.3s ease;
  z-index: 3;
  pointer-events: none;
  text-shadow: 0 0 10px rgba(255, 105, 180, 0.8);
}

.hero-avatar-wrapper:hover .avatar-music-icon {
  opacity: 1;
  transform: scale(1);
}

.avatar-music-icon.playing {
  opacity: 1;
  transform: scale(1);
  animation: pulse 1.5s ease-in-out infinite;
}

@keyframes pulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.15); }
}

/* Floating Music Notes */
.music-note {
  position: absolute;
  font-size: 20px;
  pointer-events: none;
  z-index: 100;
  animation: floatUp 1.5s ease-out forwards;
}

@keyframes floatUp {
  0% {
    opacity: 1;
    transform: translateY(0) rotate(0deg);
  }
  100% {
    opacity: 0;
    transform: translateY(-100px) rotate(20deg);
  }
}

.hero-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-name {
  font-size: 36px;
  font-weight: 700;
  color: var(--text-1);
  margin-bottom: var(--space-sm);
}

.hero-title {
  font-size: 16px;
  background: var(--accent-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  font-weight: 500;
  margin-bottom: var(--space-lg);
}

.hero-desc {
  font-size: 15px;
  color: var(--text-3);
  line-height: 1.8;
  margin-bottom: var(--space-lg);
}

.hero-tags {
  display: flex;
  justify-content: center;
  gap: var(--space-sm);
  margin-bottom: var(--space-xl);
  flex-wrap: wrap;
}

.tag {
  padding: var(--space-xs) var(--space-md);
  background: rgba(255, 105, 180, 0.15);
  color: #FF69B4;
  border: 1px solid rgba(255, 105, 180, 0.3);
  border-radius: var(--radius-full);
  font-size: 13px;
  font-weight: 500;
}

.hero-links {
  display: flex;
  justify-content: center;
  gap: var(--space-md);
}

.hero-link {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  padding: var(--space-sm) var(--space-md);
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  font-size: 14px;
  font-weight: 500;
  transition: all 0.2s;
}

.hero-link:hover {
  background: rgba(255, 105, 180, 0.2);
  color: white;
  border-color: rgba(255, 105, 180, 0.5);
  transform: translateY(-2px);
  box-shadow: 0 0 20px rgba(255, 105, 180, 0.3);
}

/* Container */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 var(--space-xl);
  position: relative;
  z-index: 2;
}

/* Section */
.section {
  padding: var(--space-3xl) 0;
  position: relative;
}

.section-header {
  text-align: center;
  margin-bottom: var(--space-3xl);
}

.eyebrow {
  display: inline-block;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: #FF69B4;
  margin-bottom: var(--space-sm);
}

.section-header h2 {
  font-size: 36px;
  font-weight: 700;
  color: var(--text-1);
}

/* Reveal Animation */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.reveal.in-view {
  opacity: 1;
  transform: translateY(0);
}

/* About tags */
.about-tags {
  display: flex;
  gap: var(--space-sm);
  flex-wrap: wrap;
}

.about-text p {
  font-size: 16px;
  color: var(--text-2);
  line-height: 1.8;
  margin-bottom: var(--space-md);
}

/* About Section - Different Background */
.about {
  background: linear-gradient(180deg, rgba(10, 10, 26, 1) 0%, rgba(5, 5, 20, 1) 100%);
  position: relative;
  overflow: hidden;
}

/* Stardust particles for About section */
.stardust-bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  pointer-events: none;
  z-index: 1;
}

/* Twinkling stars */
.stardust-star {
  position: absolute;
  width: 3px;
  height: 3px;
  background: white;
  border-radius: 50%;
  box-shadow: 0 0 8px 3px rgba(255, 255, 255, 0.8);
  animation: starTwinkle 3s ease-in-out infinite;
  z-index: 1;
}

.stardust-star:nth-child(1) { top: 8%; left: 12%; animation-delay: 0s; }
.stardust-star:nth-child(2) { top: 15%; left: 45%; animation-delay: 0.5s; width: 2px; height: 2px; }
.stardust-star:nth-child(3) { top: 22%; left: 78%; animation-delay: 1s; }
.stardust-star:nth-child(4) { top: 35%; left: 25%; animation-delay: 1.5s; width: 4px; height: 4px; }
.stardust-star:nth-child(5) { top: 42%; left: 65%; animation-delay: 2s; }
.stardust-star:nth-child(6) { top: 55%; left: 8%; animation-delay: 0.3s; width: 2px; height: 2px; }
.stardust-star:nth-child(7) { top: 62%; left: 35%; animation-delay: 0.8s; }
.stardust-star:nth-child(8) { top: 70%; left: 85%; animation-delay: 1.3s; width: 4px; height: 4px; }
.stardust-star:nth-child(9) { top: 78%; left: 52%; animation-delay: 1.8s; }
.stardust-star:nth-child(10) { top: 88%; left: 18%; animation-delay: 2.3s; width: 2px; height: 2px; }
.stardust-star:nth-child(11) { top: 12%; left: 92%; animation-delay: 2.8s; }
.stardust-star:nth-child(12) { top: 48%; left: 92%; animation-delay: 0.2s; width: 3px; height: 3px; }
.stardust-star:nth-child(13) { top: 82%; left: 72%; animation-delay: 1.2s; }
.stardust-star:nth-child(14) { top: 28%; left: 55%; animation-delay: 1.7s; width: 2px; height: 2px; }
.stardust-star:nth-child(15) { top: 65%; left: 48%; animation-delay: 2.2s; }

@keyframes starTwinkle {
  0%, 100% {
    opacity: 0.4;
    transform: scale(1);
    box-shadow: 0 0 6px 2px rgba(255, 255, 255, 0.6);
  }
  50% {
    opacity: 1;
    transform: scale(1.3);
    box-shadow: 0 0 12px 4px rgba(255, 255, 255, 0.9);
  }
}

/* Floating light orbs */
.stardust-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(30px);
  animation: orbFloat 8s ease-in-out infinite;
  z-index: 1;
}

.stardust-orb:nth-child(16) {
  width: 200px;
  height: 200px;
  background: radial-gradient(circle, rgba(255, 105, 180, 0.5) 0%, transparent 70%);
  top: 20%;
  left: 10%;
  animation-delay: 0s;
}

.stardust-orb:nth-child(17) {
  width: 180px;
  height: 180px;
  background: radial-gradient(circle, rgba(147, 112, 219, 0.45) 0%, transparent 70%);
  bottom: 30%;
  right: 15%;
  animation-delay: -3s;
}

.stardust-orb:nth-child(18) {
  width: 150px;
  height: 150px;
  background: radial-gradient(circle, rgba(218, 112, 214, 0.5) 0%, transparent 70%);
  top: 50%;
  left: 50%;
  animation-delay: -5s;
}

@keyframes orbFloat {
  0%, 100% {
    transform: translate(0, 0) scale(1);
    opacity: 0.3;
  }
  50% {
    transform: translate(20px, -20px) scale(1.1);
    opacity: 0.5;
  }
}

.about-content {
  display: flex;
  justify-content: center;
}

.about-mindmap {
  width: 100%;
  max-width: 900px;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.4);
}

.about-mindmap img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: var(--radius-lg);
}

.about-avatar {
  width: 200px;
  height: 200px;
  border-radius: 50%;
  overflow: hidden;
  border: 4px solid rgba(255, 105, 180, 0.4);
  box-shadow: 0 0 40px rgba(255, 105, 180, 0.3);
}

/* About Avatar Wrapper */
.about-avatar-wrapper {
  position: relative;
  width: 200px;
  height: 200px;
  cursor: pointer;
}

.about-avatar-wrapper .hero-avatar {
  width: 200px;
  height: 200px;
  cursor: pointer;
}

.about-avatar-wrapper .avatar-ripple {
  width: 200px;
  height: 200px;
}

.about-avatar-wrapper:hover .avatar-ripple {
  animation: rippleEffect 2s ease-out infinite;
}

.about-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.about-text p {
  font-size: 16px;
  color: var(--text-2);
  line-height: 1.8;
  margin-bottom: var(--space-md);
}

.about-tags {
  display: flex;
  gap: var(--space-sm);
  flex-wrap: wrap;
}

/* Portfolio Section */
.portfolio {
  background: rgba(10, 10, 26, 0.95);
  position: relative;
}

.portfolio-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-xl);
}

.portfolio-card {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}

.portfolio-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 0 40px rgba(255, 105, 180, 0.3);
  border-color: rgba(255, 105, 180, 0.4);
}

.card-cover {
  position: relative;
  aspect-ratio: 16 / 9;
  overflow: hidden;
}

.card-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.portfolio-card:hover .card-cover img {
  transform: scale(1.05);
}

.cover-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Bilibili thumb */
.bilibili-thumb {
  position: relative;
  aspect-ratio: 16 / 9;
  overflow: hidden;
}

.card-placeholder-card {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 48px;
  background: linear-gradient(135deg, #FF69B4 0%, #9370DB 100%);
}

.card-overlay {
  position: absolute;
  inset: 0;
  background: rgba(10, 10, 26, 0.6);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.portfolio-card:hover .card-overlay {
  opacity: 1;
}

.overlay-icon {
  width: 56px;
  height: 56px;
  background: rgba(255, 255, 255, 0.95);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  color: #FF69B4;
}

.card-content {
  padding: var(--space-lg);
}

.card-category {
  font-size: 12px;
  font-weight: 600;
  color: #FF69B4;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.card-content h3 {
  font-size: 18px;
  font-weight: 600;
  margin: var(--space-sm) 0;
  color: var(--text-1);
}

.card-content p {
  font-size: 14px;
  color: var(--text-3);
  margin-bottom: var(--space-md);
}

.card-link {
  font-size: 14px;
  font-weight: 600;
  color: #FF69B4;
  transition: color 0.2s;
}

.card-link:hover {
  color: #DA70D6;
}

/* Bilibili Section */
.bilibili {
  background: rgba(15, 15, 35, 0.95);
  position: relative;
}

.bilibili-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-xl);
}

.bilibili-card {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}

.bilibili-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 0 30px rgba(255, 105, 180, 0.25);
  border-color: rgba(255, 105, 180, 0.4);
}

.bilibili-thumb {
  position: relative;
  aspect-ratio: 16 / 9;
  overflow: hidden;
}

.thumb-bg {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  font-weight: 700;
  color: white;
  transition: transform 0.3s ease;
  background: linear-gradient(135deg, #FF69B4 0%, #9370DB 100%);
}

.bilibili-card:hover .thumb-bg {
  transform: scale(1.05);
}

.thumb-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.bilibili-card:hover .thumb-img {
  transform: scale(1.05);
}

.play-icon {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) scale(0.8);
  width: 48px;
  height: 48px;
  background: rgba(255, 255, 255, 0.95);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  color: #FF69B4;
  opacity: 0;
  transition: opacity 0.3s, transform 0.3s;
  box-shadow: 0 0 20px rgba(255, 105, 180, 0.4);
}

.bilibili-card:hover .play-icon {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1);
}

.bilibili-info {
  padding: var(--space-md);
}

.bilibili-info h4 {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-1);
  margin-bottom: var(--space-xs);
}

.bilibili-info span {
  font-size: 12px;
  color: var(--text-4);
}

/* Skills Section */
.skills {
  background: rgba(15, 15, 35, 0.95);
  position: relative;
}

.skills-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-xl);
}

.skill-group {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border);
  padding: var(--space-xl);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
}

.skill-group h3 {
  font-size: 16px;
  font-weight: 600;
  color: var(--text-1);
  margin-bottom: var(--space-md);
}

.skill-tags {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-sm);
}

.skill-tag {
  padding: var(--space-xs) var(--space-md);
  background: rgba(255, 105, 180, 0.1);
  color: var(--text-2);
  border: 1px solid rgba(255, 105, 180, 0.2);
  border-radius: var(--radius-sm);
  font-size: 13px;
  font-weight: 500;
  transition: all 0.2s;
}

.skill-tag:hover {
  background: rgba(255, 105, 180, 0.2);
  color: #FF69B4;
  border-color: rgba(255, 105, 180, 0.4);
}

/* Experience Section */
.experience {
  background: rgba(10, 10, 26, 0.95);
  position: relative;
}

.timeline {
  max-width: 600px;
  margin: 0 auto;
  position: relative;
}

.timeline::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 2px;
  background: linear-gradient(180deg, #FF69B4, #9370DB);
}

.timeline-item {
  position: relative;
  padding-left: var(--space-xl);
  padding-bottom: var(--space-xl);
}

.timeline-item:last-child {
  padding-bottom: 0;
}

.timeline-dot {
  position: absolute;
  left: -5px;
  top: 0;
  width: 12px;
  height: 12px;
  background: #FF69B4;
  border-radius: 50%;
  border: 3px solid var(--bg);
  box-shadow: 0 0 10px rgba(255, 105, 180, 0.5);
}

.timeline-content {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border);
  padding: var(--space-lg);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
}

.timeline-date {
  font-size: 12px;
  font-weight: 600;
  color: #FF69B4;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.timeline-content h3 {
  font-size: 18px;
  font-weight: 600;
  color: var(--text-1);
  margin: var(--space-sm) 0;
}

.timeline-content p {
  font-size: 14px;
  color: var(--text-3);
  line-height: 1.6;
}

/* Contact Section */
.contact {
  background: linear-gradient(180deg, rgba(10, 10, 26, 0.95) 0%, rgba(15, 15, 40, 1) 100%);
  text-align: center;
  position: relative;
}

.contact-content {
  max-width: 500px;
  margin: 0 auto;
}

.contact-content h2 {
  font-size: 36px;
  font-weight: 700;
  color: var(--text-1);
  margin-bottom: var(--space-md);
}

.contact-content p {
  font-size: 16px;
  color: var(--text-3);
  margin-bottom: var(--space-xl);
}

.cta-button {
  display: inline-flex;
  align-items: center;
  gap: var(--space-sm);
  padding: var(--space-md) var(--space-xl);
  background: var(--accent-gradient);
  color: white;
  border-radius: var(--radius-md);
  font-size: 16px;
  font-weight: 600;
  transition: transform 0.2s, box-shadow 0.2s;
}

.cta-button:hover {
  transform: translateY(-2px);
  box-shadow: 0 0 40px rgba(255, 105, 180, 0.5);
}

.contact-links {
  display: flex;
  justify-content: center;
  gap: var(--space-xl);
  margin-top: var(--space-xl);
}

.contact-links a {
  color: var(--text-3);
  font-size: 14px;
  font-weight: 500;
  transition: color 0.2s;
}

.contact-links a:hover {
  color: #FF69B4;
}

/* Footer */
.footer {
  padding: var(--space-xl) 0;
  background: rgba(10, 10, 26, 0.8);
  border-top: 1px solid var(--border);
  text-align: center;
}

.footer p {
  font-size: 14px;
  color: var(--text-4);
}

/* Responsive */
@media (max-width: 1024px) {
  .hero-container {
    grid-template-columns: 1fr;
    gap: var(--space-xl);
  }

  .hero-info {
    order: -1;
  }

  .hero-carousel {
    height: 340px;
  }

  .carousel-cards {
    max-width: 500px;
    height: 220px;
  }

  .video-card {
    width: 340px;
    height: 191px;
  }

  .video-card.left-card {
    transform: translateX(-120px) rotateY(8deg) rotateX(2deg) scale(0.78);
  }

  .video-card.right-card {
    transform: translateX(120px) rotateY(-8deg) rotateX(-2deg) scale(0.78);
  }

  .carousel-nav {
    width: 40px;
    height: 40px;
    font-size: 20px;
  }

  .carousel-prev {
    left: 10px;
  }

  .carousel-next {
    right: 10px;
  }

  .portfolio-grid,
  .bilibili-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .skills-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .nav-links {
    display: none;
  }

  .hero-name {
    font-size: 28px;
  }

  .section-header h2 {
    font-size: 28px;
  }

  .about-content {
    justify-content: center;
  }

  .about-avatar {
    margin: 0 auto;
  }

  .about-tags {
    justify-content: center;
  }

  .portfolio-grid,
  .bilibili-grid {
    grid-template-columns: 1fr;
  }

  .video-card {
    width: 260px;
    height: 146px;
  }

  .video-card.left-card {
    transform: translateX(-80px) rotateY(6deg) rotateX(2deg) scale(0.75);
  }

  .video-card.right-card {
    transform: translateX(80px) rotateY(-6deg) rotateX(-2deg) scale(0.75);
  }

  .carousel-nav {
    width: 36px;
    height: 36px;
    font-size: 18px;
  }

  .carousel-prev {
    left: 5px;
  }

  .carousel-next {
    right: 5px;
  }
}

/* Sound indicator */
.sound-indicator {
  position: fixed;
  bottom: var(--space-xl);
  right: var(--space-xl);
  width: 40px;
  height: 40px;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid var(--border);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  cursor: pointer;
  opacity: 0.6;
  transition: all 0.2s;
  z-index: 100;
}

.sound-indicator:hover {
  opacity: 1;
  background: rgba(255, 105, 180, 0.2);
  border-color: rgba(255, 105, 180, 0.4);
}

.sound-indicator.muted {
  opacity: 0.3;
}
