/* 基础重置 */
body {
    margin: 0; /* 消除默认边距 */
    overflow-x: hidden; /* 隐藏横向滚动条 */
    background: linear-gradient(45deg, #0f0f1a, #1a1a2f); /* 45度渐变背景 */
    color: white; /* 全局文字颜色 */
    cursor: none; /* 隐藏默认鼠标指针 */
    min-height: 100vh;
}

/* Canvas 样式 */
#mouse-trail {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 9999;
}

/* 导航按钮容器 */
.nav-buttons {
    display: flex;
    gap: 20px;
    justify-content: center;
    margin-top: 40px;
}

/* 导航按钮样式 */
.nav-button {
    position: relative;
    padding: 15px 30px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    color: white;
    text-decoration: none;
    font-size: 1.2em;
    overflow: hidden;
    transition: all 0.3s ease;
    backdrop-filter: blur(5px);
}

.nav-button:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 255, 255, 0.3);
}

.button-text {
    position: relative;
    z-index: 1;
}

.button-glow {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(45deg, #00ffff, #ff00ff);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.nav-button:hover .button-glow {
    opacity: 0.2;
}

/* 单个拖尾点样式 */
.trail-point {
    position: absolute; /* 绝对定位跟随鼠标 */
    width: 8px;
    height: 8px;
    background: linear-gradient(45deg, #00ffff, #ff00ff);
    border-radius: 50%; /* 圆形效果 */
    mix-blend-mode: screen; /* 颜色混合模式 */
    transition: 0.3s ease-out; /* 平滑过渡动画 */
    box-shadow: 0 0 10px rgba(0, 255, 255, 0.5);
    animation: pulse 1s infinite;
}

/* 脉冲动画 */
@keyframes pulse {
    0% {
        box-shadow: 0 0 10px rgba(0, 255, 255, 0.5);
    }
    50% {
        box-shadow: 0 0 20px rgba(255, 0, 255, 0.5);
    }
    100% {
        box-shadow: 0 0 10px rgba(0, 255, 255, 0.5);
    }
}

/* 故障文字动画 */
.glitch-text {
    position: relative; /* 为伪元素定位提供基准 */
    font-size: 3em;
    font-weight: bold;
    text-align: center;
    margin-top: 20vh;
    animation: glitch 3s infinite; /* 应用关键帧动画 */
}

/* 关键帧动画定义 */
@keyframes glitch {
    0% { 
        text-shadow: none; /* 初始状态无阴影 */
    }
    2% {
        /* 使用裁剪路径制造错位效果 */
        clip-path: inset(20% 0 30% 0);
        transform: translate(-2px, 2px);
        text-shadow: 2px 0 #ff00ff, -2px 0 #00ffff;
    }
    4% {
        clip-path: inset(10% 0 40% 0);
        transform: translate(3px, -1px);
        text-shadow: -2px 0 #ff00ff, 2px 0 #00ffff;
    }
    6% {
        clip-path: inset(30% 0 20% 0);
        transform: translate(-1px, 3px);
        text-shadow: 2px 0 #ff00ff, -2px 0 #00ffff;
    }
    8% {
        clip-path: none;
        transform: none;
        text-shadow: none;
    }
    100% {
        text-shadow: none;
    }
}