/* --- 全局和基础样式 --- */
:root {
    --bg-color: #121212;
    --card-color: rgba(26, 26, 26, 0.85);
    --text-color: #e0e0e0;
    --subtle-text-color: #a0a0a0;
    --glow-color: rgba(255, 255, 255, 0.1);
    --border-color: #333;
}

body {
    background-color: var(--bg-color);
    margin: 0;
    font-family: 'Noto Sans SC', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    color: var(--text-color);
    
    /* --- 精致化的脚印背景 --- */
    background-image:
        radial-gradient(ellipse 40% 60% at 30% 40%, #222 15%, transparent 15.5%),
        radial-gradient(circle at 20% 15%, #222 4%, transparent 4.5%),
        radial-gradient(circle at 28% 10%, #222 3%, transparent 3.5%),
        radial-gradient(circle at 38% 9%, #222 2.5%, transparent 3%),
        radial-gradient(circle at 48% 11%, #222 2%, transparent 2.5%),
        radial-gradient(circle at 56% 15%, #222 1.5%, transparent 2%),
        radial-gradient(ellipse 40% 60% at 80% 70%, #222 15%, transparent 15.5%),
        radial-gradient(circle at 90% 85%, #222 4%, transparent 4.5%),
        radial-gradient(circle at 82% 90%, #222 3%, transparent 3.5%),
        radial-gradient(circle at 72% 91%, #222 2.5%, transparent 3%),
        radial-gradient(circle at 62% 89%, #222 2%, transparent 2.5%),
        radial-gradient(circle at 54% 85%, #222 1.5%, transparent 2%);
    background-size: 500px 500px;
}

.container {
    max-width: 1600px;
    width: 90%;
    margin: 40px auto;
    padding: 20px;
    box-sizing: border-box;
}

/* --- 高级感标题 --- */
h1 {
    text-align: center;
    margin-bottom: 50px;
    font-family: "Yusei Magic", sans-serif;
    font-size: 4.5em;
    font-weight: 400;
    color: #fff;
    text-shadow: 0 0 10px rgba(255, 255, 255, 0.3), 0 0 20px rgba(255, 255, 255, 0.2);
}

/* --- 幻灯片样式 (暗黑主题) --- */
.slideshow-container {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 9;
    margin-bottom: 50px;
    border-radius: 12px;
    overflow: hidden;
    background-color: #000;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.5);
}

.slide-item {
    position: absolute; top: 0; left: 0; width: 100%; height: 100%;
    opacity: 0;
    transition: opacity 1s ease-in-out;
}

.slide-item img {
    width: 100%; height: 100%; object-fit: cover;
}

.slide-item.active {
    opacity: 1; z-index: 1;
}

.slide-arrow {
    position: absolute; top: 50%; transform: translateY(-50%);
    width: 45px; height: 45px;
    background-color: rgba(0, 0, 0, 0.4);
    color: #fff;
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    font-size: 22px; cursor: pointer; z-index: 10;
    transition: all 0.3s ease;
    display: flex; align-items: center; justify-content: center;
}
.slide-arrow:hover {
    background-color: rgba(0, 0, 0, 0.7);
    border-color: rgba(255, 255, 255, 0.5);
}
.prev-arrow { left: 20px; }
.next-arrow { right: 20px; }

.slide-dots {
    position: absolute; bottom: 20px; left: 50%;
    transform: translateX(-50%);
    display: flex; gap: 12px; z-index: 10;
}

.dot {
    width: 12px; height: 12px;
    background-color: rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border: none;
    cursor: pointer;
    transition: all 0.4s ease;
    padding: 0; /* Override text content styles */
    font-size: 0; /* Hide text number */
}
.dot:hover { background-color: rgba(255, 255, 255, 0.7); }
.dot.active { background-color: #fff; transform: scale(1.2); }


/* --- 网格与卡片布局 --- */
.item-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 40px;
    width: 100%;
}

/* --- "质感"与"诱惑"卡片 --- */
.item-card {
    background: var(--card-color);
    backdrop-filter: blur(10px); /* 毛玻璃效果 */
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid var(--border-color);
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.4);
    transition: all 0.4s cubic-bezier(0.2, 0.8, 0.2, 1);
    display: flex;
    flex-direction: column;
}

.item-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.6), 0 0 20px var(--glow-color);
    border-color: rgba(255, 255, 255, 0.2);
}

.image-link {
    display: block;
    text-decoration: none;
}

.item-image-wrapper {
    width: 100%;
    aspect-ratio: 16 / 9; /* <<< 修改：从竖向改为 16:9 宽屏 */
    overflow: hidden;
    position: relative;
    background-color: #000; /* <<< 新增：为可能出现的黑边区域添加背景色 */
}


.item-image {
    width: 100%;
    height: 100%;
    object-fit: contain; /* <<< 修改：从 cover 改为 contain，确保图片完整显示 */
    transition: transform 0.4s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.item-card:hover .item-image {
    transform: scale(1.05);
}

.item-content {
    padding: 20px;
    display: flex;
    flex-direction: column;
    flex-grow: 1; /* 让内容区填满剩余空间 */
}

.description-link {
    text-decoration: none;
    color: inherit;
    display: block;
    flex-grow: 1;
}

.item-description {
    font-size: 1rem;
    line-height: 1.6;
    color: var(--text-color);
    margin: 0 0 20px 0;
    font-weight: 300;
}

.item-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: auto; /* 将标签推到底部 */
}

.tag {
    font-size: 0.75rem;
    background: rgba(255, 255, 255, 0.05);
    padding: 6px 12px;
    border-radius: 20px;
    border: 1px solid var(--border-color);
    color: var(--subtle-text-color);
    text-decoration: none;
    transition: all 0.3s ease;
}

.tag:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    border-color: rgba(255, 255, 255, 0.3);
}

/* --- 返回顶部按钮 --- */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    background-color: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    color: white;
    width: 45px;
    height: 45px;
    text-align: center;
    line-height: 45px;
    border-radius: 50%;
    border: 1px solid rgba(255, 255, 255, 0.2);
    font-size: 20px;
    text-decoration: none;
    transition: all 0.3s ease;
}

.back-to-top:hover {
    background-color: rgba(255, 255, 255, 0.2);
    transform: scale(1.1);
}


/* 筛选容器样式 */
.filter-container {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 20px; /* <<< 增大了按钮之间的间距 */
    margin-bottom: 60px; /* <<< 增大了与下方卡片网格的间距 */
}

/* 筛选按钮基本样式 */
.filter-btn {
    font-family: 'Noto Sans SC', sans-serif;
    font-size: 1.1rem; /* <<< 字体已加大 */
    font-weight: 400; /* 给字体一点粗细度，更清晰 */
    color: var(--subtle-text-color);
    background-color: transparent;
    border: 1px solid var(--border-color);
    padding: 14px 28px; /* <<< 内边距已加大，使按钮整体变大 */
    border-radius: 30px; /* <<< 圆角已微调以适应新尺寸 */
    cursor: pointer;
    transition: all 0.3s ease;
    backdrop-filter: blur(5px);
}

/* 鼠标悬停在按钮上的效果 */
.filter-btn:hover {
    background-color: rgba(255, 255, 255, 0.05);
    color: #fff;
    border-color: rgba(255, 255, 255, 0.3);
}

/* 按钮被选中时的 "active" 状态样式 */
.filter-btn.active {
    background-color: var(--glow-color);
    color: #fff;
    border-color: rgba(255, 255, 255, 0.5);
    box-shadow: 0 0 15px rgba(255, 255, 255, 0.1);
}

/* --- 移动端优化 --- */
@media (max-width: 768px) {
    .container {
        width: 95%;
        margin: 20px auto;
    }
    h1 {
        font-size: 2.5em;
        margin-bottom: 30px;
    }
    .item-grid {
        grid-template-columns: 1fr;
        gap: 30px;
    }
}