/**
 * FilmDad 视频归档页样式 - 增强版
 * 支持：视频归档页、视频分类归档页、视频来源归档页
 */

/* 通用容器样式 - 适用于所有视频相关归档页 */
.post-type-archive-movie_video .filmdad-video-archive-container,
.tax-video_category .filmdad-video-archive-container,
.tax-video_source .filmdad-video-archive-container,
.filmdad-video-archive-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 20px;
}

/* 页面头部 - 增强版，支持分类和来源页面 */
.video-archive-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 40px 20px;
    border-radius: 15px;
    margin-bottom: 30px;
    text-align: center;
    position: relative;
    overflow: hidden;
}

/* 分类页面特殊样式 */
.tax-video_category .video-archive-header {
    background: linear-gradient(135deg, #3498db 0%, #2980b9 100%);
}

/* 来源页面特殊样式 */
.tax-video_source .video-archive-header {
    background: linear-gradient(135deg, #e74c3c 0%, #c0392b 100%);
}

.video-archive-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,0.1);
    z-index: 1;
}

.video-archive-header .header-content {
    position: relative;
    z-index: 2;
}

.video-archive-header .page-title {
    font-size: 2.5em;
    margin-bottom: 10px;
    font-weight: 700;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
}

.video-archive-header .page-description {
    font-size: 1.2em;
    opacity: 0.9;
    margin-bottom: 30px;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

/* 分类和来源页面的描述样式 */
.tax-video_category .page-description,
.tax-video_source .page-description {
    font-style: italic;
}

.archive-stats {
    display: flex;
    justify-content: center;
    gap: 40px;
    flex-wrap: wrap;
}

.stat-item {
    text-align: center;
    background: rgba(255,255,255,0.2);
    padding: 15px 25px;
    border-radius: 10px;
    backdrop-filter: blur(10px);
}

.stat-number {
    display: block;
    font-size: 2em;
    font-weight: bold;
    margin-bottom: 5px;
}

.stat-label {
    font-size: 0.9em;
    opacity: 0.8;
}

/* 布局和筛选器 */
.video-archive-layout {
    display: grid;
    grid-template-columns: 1fr 300px;
    gap: 30px;
}

.video-filters {
    background: white;
    padding: 20px;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    margin-bottom: 30px;
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    align-items: end;
}

.filter-group {
    display: flex;
    flex-direction: column;
    flex: 1;
    min-width: 150px;
}

.filter-group label {
    font-weight: 600;
    margin-bottom: 5px;
    color: #2c3e50;
    font-size: 0.9em;
}

.filter-select {
    padding: 10px 12px;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    background: white;
    font-size: 0.9em;
    transition: all 0.3s ease;
}

.filter-select:focus {
    outline: none;
    border-color: #3498db;
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.1);
}

.reset-filters-btn {
    background: #6c757d;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 0.9em;
}

.reset-filters-btn:hover {
    background: #5a6268;
    transform: translateY(-1px);
}

/* 视频网格布局 */
.videos-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 25px;
    margin-bottom: 40px;
}

.video-archive-card {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
    border: 1px solid #e9ecef;
}

.video-archive-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
}

.video-thumbnail {
    position: relative;
    aspect-ratio: 16/9;
    overflow: hidden;
}

.video-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.video-archive-card:hover .video-thumbnail img {
    transform: scale(1.05);
}

.video-thumbnail-placeholder {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 2em;
    position: relative;
}

.source-badge {
    position: absolute;
    bottom: 10px;
    right: 10px;
    background: rgba(0,0,0,0.8);
    color: white;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 0.7em;
}

.video-play-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.video-archive-card:hover .video-play-overlay {
    opacity: 1;
}

.play-icon {
    color: white;
    font-size: 2em;
}

.play-text {
    color: white;
    margin-left: 8px;
    font-weight: 600;
}

.video-source-indicator {
    position: absolute;
    top: 10px;
    right: 10px;
    background: rgba(0,0,0,0.8);
    color: white;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 0.7em;
}

.video-content {
    padding: 20px;
}

.video-title {
    margin: 0 0 12px 0;
    font-size: 1.1em;
    line-height: 1.4;
}

.video-title a {
    color: #2c3e50;
    text-decoration: none;
}

.video-title a:hover {
    color: #3498db;
}

.video-meta {
    margin-bottom: 15px;
}

.video-categories {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
    margin-bottom: 10px;
}

.category-tag {
    background: #e3f2fd;
    color: #1976d2;
    padding: 3px 8px;
    border-radius: 12px;
    font-size: 0.8em;
    text-decoration: none;
}

.video-stats {
    display: flex;
    justify-content: space-between;
    font-size: 0.85em;
    color: #6c757d;
}

.related-movie {
    margin-top: 10px;
    padding-top: 10px;
    border-top: 1px solid #e9ecef;
}

.related-label {
    font-weight: 600;
    color: #495057;
    font-size: 0.9em;
}

.movie-link {
    color: #3498db;
    text-decoration: none;
    font-size: 0.9em;
}

.movie-link:hover {
    text-decoration: underline;
}

.video-excerpt {
    margin-top: 10px;
    font-size: 0.9em;
    color: #6c757d;
    line-height: 1.5;
}

/* 侧边栏样式 */
.video-archive-sidebar {
    display: flex;
    flex-direction: column;
    gap: 25px;
}

.sidebar-widget {
    background: white;
    padding: 20px;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}

.widget-title {
    font-size: 1.2em;
    margin: 0 0 15px 0;
    color: #2c3e50;
    border-bottom: 2px solid #3498db;
    padding-bottom: 8px;
}

/* 热门视频样式 */
.popular-videos-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.popular-video-item {
    display: flex;
    gap: 12px;
    padding: 10px;
    border-radius: 8px;
    transition: background 0.3s ease;
}

.popular-video-item:hover {
    background: #f8f9fa;
}

.video-thumbnail-small {
    flex-shrink: 0;
    width: 80px;
    height: 60px;
    border-radius: 6px;
    overflow: hidden;
}

.video-thumbnail-small img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.thumbnail-placeholder-small {
    width: 100%;
    height: 100%;
    background: #e9ecef;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #6c757d;
}

.video-info-small h4 {
    margin: 0 0 5px 0;
    font-size: 0.9em;
    line-height: 1.3;
}

.video-info-small h4 a {
    color: #2c3e50;
    text-decoration: none;
}

.video-info-small h4 a:hover {
    color: #3498db;
}

.video-views-small {
    font-size: 0.8em;
    color: #6c757d;
}

/* 分类云样式 */
.categories-cloud {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.category-cloud-item {
    background: #f8f9fa;
    color: #495057;
    padding: 6px 12px;
    border-radius: 20px;
    text-decoration: none;
    font-size: 0.85em;
    border: 1px solid #e9ecef;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 5px;
}

.category-cloud-item:hover {
    background: #3498db;
    color: white;
    border-color: #3498db;
    transform: translateY(-1px);
}

.category-count {
    background: rgba(255,255,255,0.2);
    padding: 1px 6px;
    border-radius: 10px;
    font-size: 0.8em;
}

/* 来源列表样式 */
.sources-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.source-tag {
    background: #f8f9fa;
    color: #495057;
    padding: 6px 12px;
    border-radius: 20px;
    text-decoration: none;
    font-size: 0.85em;
    border: 1px solid #e9ecef;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 5px;
}

.source-tag:hover {
    background: #3498db;
    color: white;
    border-color: #3498db;
    transform: translateY(-1px);
}

.source-count {
    background: rgba(255,255,255,0.2);
    padding: 1px 6px;
    border-radius: 10px;
    font-size: 0.8em;
}

/* 提交CTA样式 */
.submission-cta {
    text-align: center;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.submission-cta .widget-title {
    color: white;
    border-bottom-color: rgba(255,255,255,0.3);
}

.submission-cta p {
    margin-bottom: 15px;
    opacity: 0.9;
}

.cta-button {
    display: inline-block;
    background: white;
    color: #667eea;
    padding: 10px 20px;
    border-radius: 25px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
}

.cta-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
}

/* 分页样式 */
.video-pagination {
    display: flex;
    justify-content: center;
    margin-top: 40px;
}

.video-pagination .nav-links {
    display: flex;
    gap: 10px;
    align-items: center;
}

.video-pagination .page-numbers {
    padding: 8px 16px;
    border: 2px solid #e9ecef;
    border-radius: 6px;
    text-decoration: none;
    color: #495057;
    transition: all 0.3s ease;
}

.video-pagination .page-numbers.current {
    background: #3498db;
    color: white;
    border-color: #3498db;
}

.video-pagination .page-numbers:hover:not(.current) {
    background: #f8f9fa;
    border-color: #3498db;
}

/* 无视频状态 */
.no-videos-found {
    text-align: center;
    padding: 60px 20px;
    background: white;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}

.no-videos-icon {
    font-size: 4em;
    margin-bottom: 20px;
}

.no-videos-found h3 {
    color: #2c3e50;
    margin-bottom: 10px;
}

.no-videos-found p {
    color: #6c757d;
    margin-bottom: 30px;
}

.submit-video-btn {
    display: inline-block;
    background: linear-gradient(135deg, #3498db, #2980b9);
    color: white;
    padding: 12px 30px;
    border-radius: 25px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
}

.submit-video-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(52, 152, 219, 0.4);
}

/* 分类和来源页面的特殊侧边栏调整 */
.tax-video_category .video-archive-sidebar .video-categories-widget,
.tax-video_source .video-archive-sidebar .video-sources-widget {
    display: none; /* 在当前分类/来源页面隐藏对应的分类/来源小部件 */
}

/* 响应式设计 */
@media (max-width: 1024px) {
    .video-archive-layout {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .videos-grid {
        grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    }
}

@media (max-width: 768px) {
    .filmdad-video-archive-container {
        padding: 15px;
    }
    
    .video-archive-header {
        padding: 30px 15px;
    }
    
    .video-archive-header .page-title {
        font-size: 2em;
    }
    
    .archive-stats {
        gap: 20px;
    }
    
    .video-filters {
        flex-direction: column;
        align-items: stretch;
    }
    
    .filter-group {
        min-width: auto;
    }
    
    .videos-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
}

@media (max-width: 480px) {
    .video-archive-header .page-title {
        font-size: 1.8em;
    }
    
    .stat-number {
        font-size: 1.5em;
    }
    
    .video-content {
        padding: 15px;
    }
    
    .archive-stats {
        flex-direction: column;
        gap: 15px;
    }
    
    .stat-item {
        padding: 10px 15px;
    }
}