:root {
    --bg-color: #ffffff;
    --gray-light: #f0f0f0;
    --container-max-width: 1600px;
    --side-padding: 24px;
}

body, html { margin: 0; padding: 0; background: var(--bg-color); font-family: sans-serif; }

/* 导航栏 */
.top-bar { position: fixed; top: 0; width: 100%; height: 80px; background: rgba(255,255,255,0.8); backdrop-filter: blur(20px); z-index: 100; display: flex; align-items: center; border-bottom: 1px solid #eee; }
.nav-container { width: 100%; max-width: var(--container-max-width); margin: 0 auto; padding: 0 var(--side-padding); display: flex; justify-content: space-between; align-items: center; }

/* 黑色滑块导航 */
.nav-left { position: relative; display: flex; gap: 8px; z-index: 1; }
#nav-slider { position: absolute; background: #000; border-radius: 25px; z-index: -1; transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1); pointer-events: none; }
.filter-btn { border: none; padding: 10px 22px; border-radius: 25px; cursor: pointer; font-size: 15px; font-weight: 600; background: transparent; color: #555; transition: color 0.3s; }
.filter-btn.active { color: #fff !important; }

.profile-right { display: flex; align-items: center; gap: 12px; font-weight: bold; }
.avatar { width: 40px; height: 40px; border-radius: 50%; object-fit: cover; }

/* 瀑布流布局 */
.waterfall { padding: 100px var(--side-padding) 50px; max-width: var(--container-max-width); margin: 0 auto; column-count: 2; column-gap: 20px; }
@media (min-width: 768px) { .waterfall { column-count: 3; } }
@media (min-width: 1200px) { .waterfall { column-count: 5; } }

/* 滑动加载卡片 */
.item { 
    break-inside: avoid; margin-bottom: 20px; border-radius: 16px; overflow: hidden; 
    cursor: zoom-in; background-color: #f7f7f7; min-height: 250px; /* 必须有高度，滑动加载才生效 */
    transition: transform 0.3s ease;
}
.item:hover { transform: scale(1.02); }

/* 图片初始透明，滑到后再淡入 */
.lazy-img { width: 100%; height: auto; display: block; opacity: 0; transition: opacity 0.8s ease; }
.lazy-img.loaded { opacity: 1; }

/* 背景模糊灯箱 */
#main-wrapper.blurred { filter: blur(25px); transition: 0.4s; }
#lightbox { position: fixed; inset: 0; background: rgba(255,255,255,0.7); z-index: 2000; display: none; flex-direction: column; align-items: center; justify-content: center; backdrop-filter: blur(15px); }
#lightbox.active { display: flex; }
.modal-content { max-width: 90%; max-height: 90%; display: flex; flex-direction: column; align-items: center; gap: 20px; }
#modal-img { max-width: 100%; max-height: 75vh; border-radius: 20px; box-shadow: 0 20px 50px rgba(0,0,0,0.1); }
.download-btn { background: #000; color: #fff; text-decoration: none; padding: 16px 45px; border-radius: 35px; font-weight: bold; }
.close-btn { position: absolute; top: 20px; right: 30px; font-size: 50px; cursor: pointer; }