/* --- 全局样式与暗色主题 --- */
@import url('https://fonts.googleapis.com/css2?family=Noto+Sans+SC:wght@300;400;700&display=swap');

:root {
    --bg-color: #1a1a2e; /* 深蓝紫色背景 */
    --text-color: #e0e0e0; /* 柔和的白色文字 */
    --title-glow-color: rgba(138, 43, 226, 0.8); /* 标题辉光颜色（紫罗兰色） */
    --star-color: #ffffff;
    --character-glow-color: rgba(173, 216, 230, 0.5); /* 角色辉光（淡蓝色） */
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background-color: var(--bg-color);
    color: var(--text-color);
    font-family: 'Noto Sans SC', sans-serif;
    overflow: hidden;
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100vh;
}

/* --- 背景图片轮播 --- */
#slideshow-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -2;
}

.slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    opacity: 0;
    transition: opacity 1.5s ease-in-out;
    z-index: 1;
}

.slide.active {
    opacity: 0.6; /* 降低背景图透明度，突出角色 */
    z-index: 2;
}

#slideshow-container::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(ellipse at center, rgba(26, 26, 46, 0.1) 0%, rgba(26, 26, 46, 0.8) 100%);
    z-index: 3;
}

/* --- 装饰元素：漂浮的星星 --- */
#decorations {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    pointer-events: none;
}

.star {
    position: absolute;
    background-color: var(--star-color);
    border-radius: 50%;
    box-shadow: 0 0 8px #fff, 0 0 12px #fff, 0 0 16px #fff;
    animation: float 20s infinite ease-in-out;
}

/* --- 主要内容容器 --- */
.main-container {
    position: relative;
    z-index: 10;
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    max-width: 1200px;
    padding: 2rem;
}

/* --- 标题区域 --- */
.title-section {
    text-align: center;
    flex: 1;
}

header h1 {
    font-size: 3.5rem;
    font-weight: 700;
    color: #fff;
    text-shadow: 0 0 10px #fff, 0 0 20px var(--title-glow-color), 0 0 35px var(--title-glow-color);
    animation: title-flicker 5s infinite alternate;
    margin-bottom: 1rem;
}

header p {
    font-size: 1.2rem;
    font-weight: 300;
    color: var(--text-color);
    letter-spacing: 1px;
}

/* --- 角色展示区域 --- */
.character-section {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center;
}

.character-image {
    max-width: 80%;
    height: auto;
    /* 使用 filter 实现辉光效果 */
    filter: drop-shadow(0 0 15px var(--character-glow-color)) drop-shadow(0 0 30px var(--character-glow-color));
    animation: character-breath 6s infinite ease-in-out;
}

/* --- 动画定义 --- */
@keyframes float {
    0% { transform: translateY(0) scale(1); opacity: 0.8; }
    50% { transform: translateY(-80px) scale(1.1); opacity: 1; }
    100% { transform: translateY(0) scale(1); opacity: 0.8; }
}

@keyframes title-flicker {
    0%, 100% { text-shadow: 0 0 10px #fff, 0 0 20px var(--title-glow-color), 0 0 35px var(--title-glow-color); opacity: 1; }
    50% { text-shadow: 0 0 8px #fff, 0 0 15px var(--title-glow-color); opacity: 0.9; }
}

@keyframes character-breath {
    0% { transform: scale(1); filter: drop-shadow(0 0 15px var(--character-glow-color)); }
    50% { transform: scale(1.03); filter: drop-shadow(0 0 25px var(--character-glow-color)); }
    100% { transform: scale(1); filter: drop-shadow(0 0 15px var(--character-glow-color)); }
}
