body {
    margin: 0;
    padding: 0;
    background: #000; /* 纯黑色背景 */
    overflow: hidden;
    height: 100vh;
}

.container {
    position: relative;
    width: 100%;
    height: 100%;
}

.poem {
    font-family: 'Courier New', Courier, monospace;
    font-size: 20px;
    color: #00ff00; /* Matrix绿色 */
    text-shadow: 0 0 5px #00ff00, 0 0 15px #00ff00; /* 微弱绿色光晕 */
    position: absolute;
    opacity: 0; /* 默认隐藏 */
    transition: opacity 2s ease; /* 减缓淡入淡出速度，2秒 */
    pointer-events: none; /* 避免干扰鼠标事件 */
    transform: translate(-50%, -50%); /* 文字以鼠标为中心 */
    letter-spacing: 2px; /* 增加字符间距，模仿Matrix效果 */
}

/* 隐藏音频控件 */
#background-music {
    display: none;
}
/* 将这些样式添加到你的styles.css文件中 */

/* 天气容器样式 */
#weather-container {
    position: fixed;
    bottom: 20px;
    left: 20px;
    z-index: 1000;
    color: #00ff00;
    font-family: 'Courier New', monospace;
    text-shadow: 0 0 5px #00ff00;
}

.weather-card {
    background: rgba(0, 0, 0, 0.7);
    border: 1px solid #00ff00;
    border-radius: 5px;
    padding: 10px;
    max-width: 250px;
}

.weather-location {
    font-size: 16px;
    margin-bottom: 5px;
}

.weather-temp {
    font-size: 24px;
    font-weight: bold;
    margin-bottom: 5px;
}

.weather-desc {
    text-transform: capitalize;
    margin-bottom: 5px;
}

.weather-aqi {
    font-size: 14px;
}

.weather-error {
    color: #ff0000;
    padding: 10px;
    background: rgba(0, 0, 0, 0.7);
    border-radius: 5px;
}

/* 天气背景 */
#weather-background {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: -1;
}

/* 天气状态背景 */
.clear-sky {
    background: linear-gradient(to bottom, rgba(0, 0, 40, 0.3), rgba(0, 0, 0, 0.1));
}

.few-clouds {
    background: linear-gradient(to bottom, rgba(0, 0, 40, 0.4), rgba(0, 0, 0, 0.2));
}

.cloudy {
    background: linear-gradient(to bottom, rgba(0, 0, 40, 0.6), rgba(0, 0, 0, 0.3));
}

.rainy {
    background: linear-gradient(to bottom, rgba(0, 0, 40, 0.7), rgba(0, 0, 0, 0.4));
}

.snowy {
    background: linear-gradient(to bottom, rgba(0, 0, 40, 0.5), rgba(0, 0, 0, 0.3));
}

.foggy {
    background: linear-gradient(to bottom, rgba(20, 20, 40, 0.6), rgba(0, 0, 0, 0.4));
}

.thunderstorm {
    background: linear-gradient(to bottom, rgba(0, 0, 30, 0.8), rgba(0, 0, 0, 0.5));
}

/* 天气元素 */
.sun {
    position: absolute;
    top: 10%;
    right: 15%;
    width: 80px;
    height: 80px;
    background: radial-gradient(circle, rgba(255, 255, 0, 0.8), rgba(255, 200, 0, 0.2));
    border-radius: 50%;
    box-shadow: 0 0 30px rgba(255, 255, 0, 0.8);
    animation: glow 8s infinite alternate;
}

.moon {
    position: absolute;
    top: 10%;
    right: 15%;
    width: 60px;
    height: 60px;
    background: radial-gradient(circle, rgba(200, 200, 255, 0.8), rgba(150, 150, 200, 0.2));
    border-radius: 50%;
    box-shadow: 0 0 20px rgba(200, 200, 255, 0.6);
    animation: glow 10s infinite alternate;
}

.cloud {
    position: absolute;
    width: 200px;
    height: 60px;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 50px;
    animation: float linear infinite;
}

.cloud:before, .cloud:after {
    content: '';
    position: absolute;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 50%;
}

.cloud:before {
    width: 80px;
    height: 80px;
    top: -40px;
    left: 30px;
}

.cloud:after {
    width: 100px;
    height: 100px;
    top: -50px;
    right: 30px;
}

.raindrop {
    position: absolute;
    width: 2px;
    height: 20px;
    background: linear-gradient(to bottom, rgba(100, 200, 255, 0), rgba(100, 200, 255, 0.5));
    animation: rain linear infinite;
}

.snowflake {
    position: absolute;
    width: 8px;
    height: 8px;
    background: rgba(255, 255, 255, 0.8);
    border-radius: 50%;
    animation: snow linear infinite;
}

.fog {
    position: absolute;
    width: 200%;
    height: 12.5%;
    background: rgba(200, 200, 220, 0.1);
    left: -50%;
    animation: fog linear infinite;
}

.lightning {
    position: absolute;
    top: 0;
    width: 3px;
    height: 150px;
    background: rgba(255, 255, 200, 0.9);
    box-shadow: 0 0 10px rgba(255, 255, 200, 1);
    animation: flash 0.2s ease-in;
}

/* 动画 */
@keyframes glow {
    0% { opacity: 0.8; }
    100% { opacity: 1; }
}

@keyframes float {
    from { transform: translateX(-200px); }
    to { transform: translateX(calc(100vw + 200px)); }
}

@keyframes rain {
    from { transform: translateY(-20px); }
    to { transform: translateY(calc(100vh + 20px)); }
}

@keyframes snow {
    from {
        transform: translateY(-10px) rotate(0deg);
    }
    to {
        transform: translateY(calc(100vh + 10px)) rotate(360deg);
    }
}

@keyframes fog {
    from { transform: translateX(-10%); }
    to { transform: translateX(10%); }
}

@keyframes flash {
    0% { opacity: 0; }
    50% { opacity: 1; }
    100% { opacity: 0; }
}
/* 添加到您现有的CSS文件中 */
.matrix-background {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    opacity: 0.3; /* Reduced brightness */
    transition: opacity 1.5s ease;
}

.matrix-background.faded {
    opacity: 0; /* Completely hidden when poem appears */
}

.poem-character {
    position: absolute;
    color: #00ff00;
    font-family: 'Courier New', monospace;
    font-size: 16px;
    text-shadow: 0 0 8px rgba(0, 255, 0, 0.8);
    user-select: none;
    pointer-events: none;
    transition: all 0.9s cubic-bezier(0.25, 0.1, 0.25, 1);
    z-index: 90;
}

/* 天气卡片透明度处理 */
.weather-card {
    /* 保持原有样式 */
    transition: opacity 0.5s ease, transform 0.3s ease, box-shadow 0.3s ease;
}

.weather-card.dimmed {
    opacity: 0.5; /* 50%不透明度 */
}