/* ===== 视频展示页专用样式 ===== */

/* 静态 Banner */
.page-banner {
    width: 100vw;
    position: relative;
    left: 50%;
    right: 50%;
    margin-left: -50vw;
    margin-right: -50vw;
    height: 250px;
    background-image: url('/assets/home/images/video-banner.jpg');
    background-size: cover;
    background-position: center;
    position: relative;
}

.page-banner::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, rgba(0, 142, 79, 0.8) 0%, rgba(0, 142, 79, 0.4) 100%);
}

.page-banner .container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 2rem;
    height: 100%;
    display: flex;
    align-items: center;
    position: relative;
    z-index: 2;
}

.page-banner h1 {
    color: white;
    font-size: 2.8rem;
    font-weight: 600;
    margin: 0;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.page-banner h1 span {
    font-weight: 300;
    color: rgba(255, 255, 255, 0.9);
}

/* 面包屑导航 */
.breadcrumb-wrapper {
    max-width: 1400px;
    margin: 1.5rem auto 0;
    padding: 0 2rem;
}

.breadcrumb {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9rem;
    color: #64748b;
    background: #f8fafc;
    padding: 0.8rem 1.5rem;
    border-radius: 40px;
    border: 1px solid #e2e8f0;
}

.breadcrumb a {
    color: #475569;
    text-decoration: none;
    transition: color 0.2s;
}

.breadcrumb a:hover {
    color: #008e4f;
}

.breadcrumb i {
    font-size: 0.7rem;
    color: #94a3b8;
}

.breadcrumb .current {
    color: #008e4f;
    font-weight: 500;
}

/* ===== 主体内容区域 ===== */
.video-page {
    max-width: 1400px;
    margin: 3rem auto 5rem;
    padding: 0 2rem;
}

/* ===== 右侧视频列表 ===== */
.video-main {
    width: 100%;
}

/* 列表头部 */
.video-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    flex-wrap: wrap;
    gap: 1rem;
}

.video-header h2 {
    font-size: 1.8rem;
    font-weight: 600;
    color: #1e293b;
}

.video-header p {
    color: #64748b;
    font-size: 0.95rem;
}

.video-sort {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: white;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 0.3rem 0.5rem;
}

.video-sort select {
    padding: 0.5rem 1rem;
    border: none;
    font-family: 'Poppins', sans-serif;
    font-size: 0.9rem;
    color: #334155;
    outline: none;
    cursor: pointer;
    background: transparent;
}

.video-sort i {
    color: #94a3b8;
    margin-right: 0.3rem;
}

/* 视频列表 - 网格布局 */
.video-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
    margin-bottom: 3rem;
}

/* 视频卡片 */
.video-card {
    background: white;
    border-radius: 16px;
    border: 1px solid #e2e8f0;
    overflow: hidden;
    transition: all 0.3s;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.03);
    cursor: pointer;
}

.video-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
    border-color: #008e4f;
}

/* 视频缩略图容器 */
.video-card__thumbnail {
    position: relative;
    height: 180px;
    background: #f8fafc;
    overflow: hidden;
}

.video-card__thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s;
}

.video-card:hover .video-card__thumbnail img {
    transform: scale(1.05);
}

/* 播放按钮覆盖层 */
.video-card__play {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 50px;
    height: 50px;
    background: rgba(0, 142, 79, 0.9);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.2rem;
    transition: all 0.3s;
    opacity: 0.9;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
}

.video-card:hover .video-card__play {
    background: #008e4f;
    transform: translate(-50%, -50%) scale(1.1);
    opacity: 1;
}

/* 视频时长 */
.video-card__duration {
    position: absolute;
    bottom: 10px;
    right: 10px;
    background: rgba(0, 0, 0, 0.7);
    color: white;
    padding: 0.2rem 0.6rem;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 500;
}

/* 视频信息 */
.video-card__content {
    padding: 1.2rem;
}

.video-card__title {
    font-size: 1rem;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 0.5rem;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    min-height: 2.8rem;
    transition: color 0.3s;
}

.video-card:hover .video-card__title {
    color: #008e4f;
}

.video-card__meta {
    display: flex;
    justify-content: space-between;
    color: #94a3b8;
    font-size: 0.8rem;
}

.video-card__date {
    display: flex;
    align-items: center;
    gap: 0.3rem;
}

.video-card__date i {
    color: #008e4f;
    font-size: 0.75rem;
}

.video-card__views {
    display: flex;
    align-items: center;
    gap: 0.3rem;
}

.video-card__views i {
    color: #008e4f;
    font-size: 0.75rem;
}

/* 分页 */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.5rem;
    margin-top: 3rem;
}

.page-item {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 0.5rem;
    background: white;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    color: #475569;
    text-decoration: none;
    font-size: 0.9rem;
    transition: all 0.2s;
}

.page-item:hover {
    border-color: #008e4f;
    color: #008e4f;
    background: #f8fafc;
}

.page-item.active {
    background: #008e4f;
    border-color: #008e4f;
    color: white;
}

.page-item.disabled {
    opacity: 0.5;
    pointer-events: none;
    background: #f1f5f9;
}

.page-dots {
    color: #94a3b8;
    padding: 0 0.3rem;
}

/* ===== 视频弹窗 ===== */
.video-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    z-index: 9999;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(5px);
}

.video-modal.active {
    display: flex;
}

.video-modal__container {
    width: 90%;
    max-width: 900px;
    background: #1e293b;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.5);
    animation: modalFadeIn 0.3s ease;
}

@keyframes modalFadeIn {
    from {
        opacity: 0;
        transform: translateY(-30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.video-modal__header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 1.5rem;
    background: #0f172a;
    border-bottom: 1px solid #334155;
}

.video-modal__title {
    color: white;
    font-size: 1.1rem;
    font-weight: 500;
    margin: 0;
}

.video-modal__close {
    background: transparent;
    border: none;
    color: #94a3b8;
    font-size: 1.5rem;
    cursor: pointer;
    transition: color 0.2s;
    line-height: 1;
    padding: 0;
}

.video-modal__close:hover {
    color: #008e4f;
}

.video-modal__body {
    padding: 1.5rem;
}

.video-modal__player {
    position: relative;
    padding-bottom: 56.25%; /* 16:9 比例 */
    height: 0;
    overflow: hidden;
    background: #000;
    border-radius: 8px;
}

.video-modal__player iframe,
.video-modal__player video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: none;
}

.video-modal__footer {
    padding: 1rem 1.5rem;
    background: #0f172a;
    border-top: 1px solid #334155;
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: #94a3b8;
    font-size: 0.9rem;
}

.video-modal__info i {
    color: #008e4f;
    margin-right: 0.3rem;
}

.video-modal__share {
    display: flex;
    gap: 0.5rem;
}

.video-modal__share-btn {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: #334155;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    transition: all 0.2s;
}

.video-modal__share-btn:hover {
    background: #008e4f;
    transform: translateY(-2px);
}

/* ===== 响应式 ===== */
@media screen and (max-width: 1200px) {
    .video-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media screen and (max-width: 768px) {
    .page-banner {
        height: 180px;
    }

    .page-banner h1 {
        font-size: 2rem;
    }

    .video-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .video-sort {
        width: 100%;
    }

    .video-sort select {
        width: 100%;
    }

    .video-grid {
        grid-template-columns: 1fr;
    }

    .pagination {
        flex-wrap: wrap;
    }

    .video-modal__footer {
        flex-direction: column;
        gap: 1rem;
        align-items: flex-start;
    }
}

@media screen and (max-width: 480px) {
    .breadcrumb-wrapper {
        padding: 0 1rem;
    }

    .breadcrumb {
        font-size: 0.8rem;
        padding: 0.6rem 1rem;
    }

    .video-page {
        padding: 0 1rem;
    }

    .video-card__thumbnail {
        height: 160px;
    }
}