* {
    margin: 0;
    padding: 0;
}

.container {
    width: 90%;
    max-width: 1400px;
    margin: 30px auto;
}

.title {
    font-size: 24px;
    font-weight: bold;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid #2c3e50;
    color: #2c3e50;
}

.tabs {
    display: flex;
    justify-content: flex-start;
    flex-wrap: wrap;
    margin-bottom: 25px;
    gap: 10px;
}

.tab {
    padding: 10px 20px;
    cursor: pointer;
    font-size: 16px;
    border: 1px solid #ddd;
    border-radius: 4px;
    background: #fff;
    transition: all 0.3s ease;
}

.tab:hover {
    border-color: #3498db;
}

.tab.active {
    background: #3498db;
    color: #fff;
    border-color: #3498db;
    font-weight: 500;
}

.media-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 25px;
    margin-bottom: 30px;
}

.media-item {
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
    cursor: pointer;
    /* 添加鼠标指针样式 */
}

.media-item:hover {
    transform: translateY(-5px);
}

.media-item img,
.media-item video {
    width: 100%;
    height: 200px;
    object-fit: cover;
    display: block;
}

.media-info {
    padding: 15px;
    background: #fff;
}

.media-title {
    font-size: 16px;
    color: #2c3e50;
    margin-bottom: 8px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.media-meta {
    font-size: 12px;
    color: #7f8c8d;
    display: flex;
    justify-content: space-between;
}

.loading {
    text-align: center;
    padding: 50px 0;
    color: #7f8c8d;
    font-size: 16px;
}

.view-more {
    display: block;
    margin: 0 auto 50px;
    padding: 12px 30px;
    border: none;
    font-size: 16px;
    cursor: pointer;
    transition: background 0.3s ease;
    border: 1px solid #e0e0e0;
    border-radius: 6px;
    background-color: #fff;
    color: #333;
}

.view-more:disabled {
    cursor: not-allowed;
    opacity: 0.6;
    box-shadow: none;
    border-color: #e0e0e0;
}

.view-more:hover:not(:disabled) {
    border-color: #999;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

/* 弹窗样式 - 增强放大效果 */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.95);
    /* 加深遮罩，突出媒体内容 */
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    padding: 20px;
    /* 留出边距，避免贴边 */
}

.modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.modal-content {
    position: relative;
    width: 100%;
    height: 100%;
    max-width: 60vw;
    /* 占满60%视口宽度 */
    max-height: 60vh;
    /* 占满60视口高度 */
}

.modal-close {
    position: absolute;
    top: -50px;
    /* 上移，避免遮挡媒体 */
    right: 0;
    color: white;
    background: rgba(0, 0, 0, 0.5);
    border: none;
    font-size: 32px;
    /* 增大关闭按钮 */
    cursor: pointer;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: background 0.3s ease;
    z-index: 1001;
}

.modal-close:hover {
    background: rgba(0, 0, 0, 0.8);
}

/* 图片放大样式 - 最大化显示，保持比例 */
.modal-image {
    width: 100%;
    height: 100%;
    object-fit: contain;
    /* 保持宽高比，完全显示 */
    max-width: none;
    /* 取消最大宽度限制 */
    max-height: none;
    /* 取消最大高度限制 */
    border-radius: 4px;
    box-shadow: 0 0 50px rgba(255, 255, 255, 0.1);
    /* 添加光晕效果，突出图片 */
}

/* 视频放大样式 - 占满弹窗 */
.modal-video {
    width: 100%;
    height: 100%;
    max-width: 60vw;
    max-height: 60vw;
    object-fit: contain;
    border-radius: 4px;
    background: #000;
}

/* 媒体信息展示 - 新增底部信息栏 */
.modal-meta {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 15px 20px;
    background: linear-gradient(transparent, rgba(0, 0, 0, 0.8));
    color: #fff;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.modal-content:hover .modal-meta {
    opacity: 1;
}

.modal-meta-title {
    font-size: 18px;
    font-weight: 500;
    margin-bottom: 5px;
}

.modal-meta-details {
    font-size: 14px;
    color: #eee;
    display: flex;
    gap: 20px;
}