* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Microsoft YaHei', sans-serif;
}

body {
    background-color: #1a2b4c;
    color: #f0f0f0;
    min-height: 100vh;
    line-height: 1.6;
}

.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 20px;
}

header {
    text-align: center;
    padding: 30px 0;
    margin-bottom: 30px;
}

h1 {
    font-size: 2.5rem;
    margin-bottom: 10px;
    color: #ffb6c1;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.3);
}

.subtitle {
    font-size: 1.1rem;
    color: #b0c4de;
}

.photo-stream {
    columns: 4 250px;
    column-gap: 15px;
    padding: 20px 0;
}

.photo-item {
    break-inside: avoid;
    margin-bottom: 15px;
    border-radius: 8px;
    overflow: hidden;
    background: #2a3b5c;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.2);
    transition: transform 0.3s;
    cursor: pointer;
}

.photo-item:hover {
    transform: translateY(-5px);
}

.photo-item img {
    width: 100%;
    height: auto;
    display: block;
    transition: transform 0.5s;
}

.photo-info {
    padding: 10px;
    font-size: 0.9rem;
    color: #b0c4de;
}

/* 灯箱样式 */
.lightbox {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    backdrop-filter: blur(10px);
    z-index: 1000;
    align-items: center;
    justify-content: center;
}

.lightbox.active {
    display: flex;
}

.lightbox-content {
    position: relative;
    max-width: 90%;
    max-height: 90%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
}

.lightbox-img-container {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

.lightbox-img {
    max-width: 100%;
    max-height: 80vh;
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    transition: opacity 0.3s;
}

.lightbox-img.loading {
    opacity: 0.7;
}

.lightbox-description {
    margin-top: 15px;
    text-align: center;
    max-width: 600px;
    padding: 0 20px;
    font-size: 1.1rem;
    line-height: 1.6;
    color: #e0e0e0;
}

.lightbox-close {
    position: absolute;
    top: 20px;
    right: 30px;
    font-size: 2.5rem;
    color: white;
    cursor: pointer;
    background: rgba(0, 0, 0, 0.5);
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.3s;
    z-index: 1001;
}

.lightbox-close:hover {
    background: rgba(0, 0, 0, 0.8);
}

.lightbox-nav {
    position: fixed; /* 改为fixed定位，固定在视口 */
    top: 50%;
    transform: translateY(-50%);
    width: 60px;
    height: 60px;
    background: rgba(0, 0, 0, 0.5);
    border: none;
    color: white;
    font-size: 2rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: background 0.3s;
    z-index: 1001;
}

.lightbox-prev {
    left: 30px; /* 距离左侧固定距离 */
}

.lightbox-next {
    right: 30px; /* 距离右侧固定距离 */
}

/* 响应式设计调整 */
@media (max-width: 768px) {
    .lightbox-nav {
        width: 50px;
        height: 50px;
        font-size: 1.5rem;
    }
    
    .lightbox-prev {
        left: 10px; /* 移动端调整距离 */
    }
    
    .lightbox-next {
        right: 10px; /* 移动端调整距离 */
    }
}

.lightbox-counter {
    position: absolute;
    top: 20px;
    left: 0;
    right: 0;
    text-align: center;
    color: white;
    font-size: 1.2rem;
}

footer {
    text-align: center;
    padding: 30px 0;
    margin-top: 40px;
    color: #b0c4de;
    font-size: 0.9rem;
}

.back-btn {
    display: inline-block;
    background: #ffb6c1;
    color: #1a2b4c;
    padding: 10px 20px;
    border-radius: 30px;
    text-decoration: none;
    font-weight: bold;
    margin-top: 20px;
    transition: all 0.3s;
}

.back-btn:hover {
    background: #ff9eb5;
    transform: translateY(-2px);
}

/* 响应式设计 */
@media (max-width: 768px) {
    .photo-stream {
        columns: 2 150px;
    }
    
    .lightbox-nav {
        width: 50px;
        height: 50px;
        font-size: 1.5rem;
    }
    
    .lightbox-prev {
        left: 10px;
    }
    
    .lightbox-next {
        right: 10px;
    }
    
    h1 {
        font-size: 2rem;
    }
    
    .lightbox-description {
        font-size: 1rem;
        padding: 0 10px;
    }
}

/* 图片压缩样式 - 控制预览图尺寸 */
.compressed-img {
    max-width: 100%;
    height: auto;
    filter: blur(5px);
    transition: filter 0.5s;
}

.compressed-img.loaded {
    filter: blur(0);
}
