/* =========================================================================
   麦浪少儿美育 · 青柠极光当代艺术馆设计系统 (Cyber Lime & Kids Art System)
   - 专为孩子、家长与美育设计：活力翡翠青柠绿（比荧光绿稍深、质感通透高阶）、温暖、童趣
   ========================================================================= */

@import url('https://fonts.googleapis.com/css2?family=JetBrains+Mono:wght@400;500;600&family=Plus+Jakarta+Sans:wght@400;500;600;700;800;900&display=swap');

:root {
  --bg-main: #F7FAF6; /* 带有微润植物淡草纸香的明亮底色 */
  --bg-card: #FFFFFF;
  --bg-card-hover: #FFFFFF;
  --border-subtle: #E8EFE5;
  --border-highlight: rgba(255, 255, 255, 1);
  --text-title: #19251B;
  --text-body: #4A5B4D;
  --text-muted: #889C8B;
  --accent-lime: #0AA858; /* 日间浅色模式下的高可读性深青柠翡翠绿 */
  --accent-neon: #10E57A; /* 活力电光青柠绿 */
  --accent-pink: #FF6B8B;
  --accent-blue: #0EA5E9;
  --ambient-glow-1: rgba(16, 229, 122, 0.12);
  --ambient-glow-2: rgba(14, 165, 233, 0.08);
}

html.dark {
  --bg-main: #0E1711; /* 稍作提亮、深邃纯净的当代少儿艺术森林墨绿展厅底色 */
  --bg-card: #15241B; /* 优雅温润的深翠翡翠展台色，与主题绿色高度统一 */
  --bg-card-hover: #1C3024;
  --border-subtle: rgba(16, 229, 122, 0.08);
  --border-highlight: rgba(16, 229, 122, 0.18);
  --text-title: #FFFFFF;
  --text-body: #D1E0D7;
  --text-muted: #8FA697;
  --accent-lime: #10E57A; /* 夜间模式下的高亮电光翡翠青柠绿 (通透活力) */
  --accent-neon: #00F580;
  --accent-pink: #FF85A1;
  --accent-blue: #38BDF8;
  --ambient-glow-1: rgba(16, 229, 122, 0.16);
  --ambient-glow-2: rgba(56, 189, 248, 0.12);
}

* {
  box-sizing: border-box;
}

body {
  background-color: var(--bg-main);
  color: var(--text-title);
  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, "SF Pro Rounded", "Comic Sans MS", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  letter-spacing: -0.01em;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
  position: relative;
  transition: background-color 0.4s ease, color 0.4s ease;
}

/* 🎨 漂浮青柠与极光背景氛围层 (Floating Aurora Starlight) */
.ambient-glow-layer {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
}

.ambient-orb-1 {
  position: absolute;
  top: -5vw;
  left: 15%;
  width: 50vw;
  height: 50vw;
  border-radius: 50%;
  background: radial-gradient(circle, var(--ambient-glow-1) 0%, rgba(0,0,0,0) 70%);
  filter: blur(85px);
  animation: orbFloat 20s ease-in-out infinite alternate;
}

.ambient-orb-2 {
  position: absolute;
  top: 45vh;
  right: -5vw;
  width: 45vw;
  height: 45vw;
  border-radius: 50%;
  background: radial-gradient(circle, var(--ambient-glow-2) 0%, rgba(0,0,0,0) 70%);
  filter: blur(90px);
  animation: orbFloat 25s ease-in-out infinite alternate-reverse;
}

@keyframes orbFloat {
  0% { transform: translate(0, 0) scale(1) rotate(0deg); }
  100% { transform: translate(30px, 40px) scale(1.08) rotate(15deg); }
}

/* 🌟 通栏固定全宽导航栏 (Full-Width Sticky Frosted Header) */
.site-header-fixed {
  position: sticky;
  top: 0;
  left: 0;
  right: 0;
  width: 100%;
  z-index: 50;
  background: rgba(247, 250, 246, 0.85);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(0, 0, 0, 0.05);
  transition: background-color 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}

html.dark .site-header-fixed {
  background: rgba(14, 23, 17, 0.88);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border-bottom: 1px solid rgba(16, 229, 122, 0.08);
}

/* 🎈 沉浸式内容流卡片 (Seamless Content-Stream Card) */
.contemporary-card {
  position: relative;
  background: var(--bg-card);
  border: none !important;
  border-radius: 24px;
  box-shadow: 
    0 4px 20px -2px rgba(0, 0, 0, 0.03),
    0 1px 3px rgba(0, 0, 0, 0.01);
  transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.4s ease, background-color 0.3s ease;
}

.contemporary-card:hover {
  background: var(--bg-card-hover);
  border: none !important;
  transform: translateY(-4px);
  box-shadow: 
    0 16px 32px -4px rgba(16, 229, 122, 0.12),
    0 4px 12px rgba(0, 0, 0, 0.03);
}

html.dark .contemporary-card {
  background: #15241B;
  border: 1px solid rgba(16, 229, 122, 0.08) !important;
  box-shadow: 
    0 6px 24px -2px rgba(0, 0, 0, 0.35),
    0 1px 3px rgba(0, 0, 0, 0.2);
}

html.dark .contemporary-card:hover {
  background: #1C3024;
  border: 1px solid rgba(16, 229, 122, 0.25) !important;
  box-shadow: 
    0 16px 36px -4px rgba(0, 0, 0, 0.45),
    0 0 24px rgba(16, 229, 122, 0.15);
}

/* 🖼️ 画作无缝圆角装裱 (Seamless Frame) */
.artwork-frame {
  position: relative;
  width: 100%;
  overflow: hidden;
  border-radius: 18px;
  background: #E8EFE5;
  border: none !important;
  box-shadow: none !important;
}

html.dark .artwork-frame {
  background: #0B140E;
  border: none !important;
  box-shadow: none !important;
}

.artwork-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.contemporary-card:hover .artwork-img {
  transform: scale(1.05);
}

/* 🏷️ 画作右上角材质标签 (纯净淡绿微透底 + 深绿字体，无显眼深绿线性外边框) */
.artwork-category-badge {
  position: absolute;
  top: 10px;
  right: 10px;
  z-index: 20;
  background-color: rgba(230, 248, 240, 0.95) !important;
  color: #047857 !important;
  font-size: 11px;
  font-weight: 800;
  line-height: 1;
  padding: 5px 11px;
  border-radius: 9999px;
  border: none !important;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.08);
  backdrop-filter: blur(8px);
  pointer-events: none;
  letter-spacing: 0.02em;
}

html.dark .artwork-category-badge {
  background-color: rgba(16, 185, 129, 0.22) !important;
  color: #6EE7B7 !important;
  border: none !important;
}

/* 👑 名人堂持续旋转青柠彩虹光环头像组件 (Zero-Gap Rainbow Ring Avatar) */
.avatar-spinner-wrap {
  position: relative;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  box-shadow: 0 6px 18px -4px rgba(0, 0, 0, 0.1);
}

/* 持续旋转的青柠极光彩虹外边框环 (紧密包裹) */
.avatar-spinner-ring {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: conic-gradient(from 0deg, #10E57A, #06B6D4, #3B82F6, #A855F7, #EC4899, #10E57A);
  animation: spinRainbow 4.5s linear infinite;
  transition: filter 0.4s ease;
  z-index: 1;
}

/* 🎵 背景音乐旋律律动动画 */
@keyframes musicPulse {
  0% { transform: scale(1) rotate(0deg); }
  50% { transform: scale(1.18) rotate(10deg); }
  100% { transform: scale(1) rotate(0deg); }
}

.music-icon-playing {
  animation: musicPulse 2.2s ease-in-out infinite;
  display: inline-block;
  transform-origin: center center;
}

@keyframes spinRainbow {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

/* 内部纯净孩子头像 (inset: 3.5px 紧密贴合，零空白缝隙) */
.avatar-inner-box {
  position: absolute;
  inset: 3.5px; /* 彩虹边框厚度，绝无留白 */
  border-radius: 50%;
  overflow: hidden;
  background: var(--bg-card);
  border: none !important; /* 彻底去除多余空隙 */
  z-index: 2;
}

.avatar-inner-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
}

/* 👑 皇冠小徽章动效 */
.avatar-crown-badge {
  position: absolute;
  bottom: 0px;
  right: 0px;
  z-index: 10;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

/* 🌟 鼠标移动到头像/卡片上的动效反馈 */
.contemporary-card:hover .avatar-spinner-ring {
  filter: drop-shadow(0 0 14px rgba(16, 229, 122, 0.85)) drop-shadow(0 0 8px rgba(6, 182, 212, 0.6));
  animation-duration: 2s;
}

.contemporary-card:hover .avatar-inner-img {
  transform: scale(1.12);
}

.contemporary-card:hover .avatar-crown-badge {
  transform: scale(1.25) rotate(15deg);
}

/* 焦点轮播幻灯片 (Cinematic Carousel) */
.carousel-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transform: scale(1.02);
  transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
  pointer-events: none;
}

.carousel-slide.active {
  opacity: 1;
  transform: scale(1);
  pointer-events: auto;
}

.carousel-indicator {
  height: 6px;
  border-radius: 9999px;
  transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.carousel-indicator.active {
  width: 32px;
  background-color: var(--accent-lime);
  box-shadow: 0 0 10px rgba(16, 229, 122, 0.9);
}

.carousel-indicator:not(.active) {
  width: 10px;
  background-color: rgba(255, 255, 255, 0.4);
}

/* 🎙️ 青柠律动音频波形 */
@keyframes cuteWave {
  0%, 100% { height: 4px; border-radius: 4px; }
  50% { height: 22px; border-radius: 6px; }
}

.modern-wave-bar {
  width: 3.5px;
  background-color: var(--accent-lime);
  border-radius: 4px;
  animation: cuteWave 0.8s ease-in-out infinite;
}

.modern-wave-bar:nth-child(1) { animation-delay: 0.1s; background-color: #10E57A; }
.modern-wave-bar:nth-child(2) { animation-delay: 0.3s; background-color: #06B6D4; }
.modern-wave-bar:nth-child(3) { animation-delay: 0.15s; background-color: #3B82F6; }
.modern-wave-bar:nth-child(4) { animation-delay: 0.4s; background-color: #A855F7; }
.modern-wave-bar:nth-child(5) { animation-delay: 0.25s; background-color: #10E57A; }
.modern-wave-bar:nth-child(6) { animation-delay: 0.35s; background-color: #06B6D4; }

.wave-paused .modern-wave-bar {
  animation-play-state: paused;
  height: 4px !important;
  opacity: 0.4 !important;
}

/* 原生 Dialog 弹窗动画 */
dialog {
  border: none;
  padding: 0;
  background: transparent;
  max-width: 94vw;
  width: 100%;
  opacity: 0;
  transform: scale(0.94) translateY(20px);
  transition-property: opacity, transform, display, overlay;
  transition-duration: 0.35s;
  transition-timing-function: cubic-bezier(0.34, 1.56, 0.64, 1);
  transition-behavior: allow-discrete;
}

dialog[open] {
  opacity: 1;
  transform: scale(1) translateY(0);

  @starting-style {
    opacity: 0;
    transform: scale(0.94) translateY(20px);
  }
}

dialog::backdrop {
  background-color: rgba(5, 12, 8, 0);
  backdrop-filter: blur(0px);
  transition:
    display 0.35s allow-discrete,
    overlay 0.35s allow-discrete,
    background-color 0.35s ease-out,
    backdrop-filter 0.35s ease-out;
}

dialog[open]::backdrop {
  background-color: rgba(7, 18, 12, 0.8);
  backdrop-filter: blur(12px);

  @starting-style {
    background-color: rgba(0, 0, 0, 0);
    backdrop-filter: blur(0px);
  }
}

/* 隐藏滚动条 */
.no-scrollbar::-webkit-scrollbar {
  display: none;
}
.no-scrollbar {
  -ms-overflow-style: none;
  scrollbar-width: none;
}
