/* 全局样式重置 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* 基础样式 */
body {
    font-family: 'Microsoft YaHei', sans-serif;
    overflow-x: hidden;
    min-height: 200vh; /* 确保页面有足够的高度用于滚动 */
    position: relative;
}

/* 视差背景 */
.parallax-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background-image: url('images/小屋白天.png');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    z-index: -1;
    transition: transform 0.1s ease-out;
}

/* 主标题 */
.main-title {
    position: absolute;
    top: 20vh;
    left: 50%;
    transform: translateX(-50%);
    font-size: clamp(2.5rem, 8vw, 5rem);
    font-weight: bold;
    text-align: center;
    z-index: 10;
    opacity: 0;
    animation: fadeIn 3s ease-out forwards, breathe 4s ease-in-out infinite;
    /* 渐变文字 - 简化颜色，提高可读性 */
    background: linear-gradient(90deg, #667eea 0%, #764ba2 100%);
    background-size: 200% 200%;
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

/* 动画定义 */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateX(-50%) translateY(50px) scale(0.8);
    }
    to {
        opacity: 1;
        transform: translateX(-50%) translateY(0) scale(1);
    }
}

@keyframes breathe {
    0%, 100% {
        transform: translateX(-50%) scale(1);
    }
    50% {
        transform: translateX(-50%) scale(1.05);
    }
}

/* 响应式设计 */
@media (max-width: 768px) {
    .main-title {
        top: 25vh;
    }
}

@media (max-width: 480px) {
    .main-title {
        top: 30vh;
    }
}