/* 视频布局专用样式 - 一排2个视频 */

.video-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-bottom: 30px;
    padding: 0 10px;
}

.video-item {
    background: #fff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
    position: relative;
}

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

.video-thumbnail {
    position: relative;
    width: 100%;
    padding-bottom: 56.25%; /* 16:9 宽高比 */
    overflow: hidden;
}

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

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

.video-duration {
    position: absolute;
    bottom: 8px;
    right: 8px;
    background: rgba(0,0,0,0.8);
    color: white;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: bold;
}

.play-icon {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 60px;
    height: 60px;
    background: rgba(255,255,255,0.9);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #e74c3c;
    font-size: 24px;
    opacity: 0;
    transition: opacity 0.3s ease;
    box-shadow: 0 4px 12px rgba(0,0,0,0.2);
}

.video-item:hover .play-icon {
    opacity: 1;
}

.video-info {
    padding: 15px;
}

.video-title {
    margin: 0 0 10px 0;
    font-size: 16px;
    line-height: 1.4;
    font-weight: 600;
    color: #2c3e50;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    min-height: 44px;
}

.video-title a {
    color: inherit;
    text-decoration: none;
    transition: color 0.3s ease;
}

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

.video-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 13px;
    color: #7f8c8d;
    margin-top: 8px;
}

.video-category {
    background: #ecf0f1;
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 12px;
}

.video-category a {
    color: #34495e;
    text-decoration: none;
    font-weight: 500;
}

.video-category a:hover {
    color: #e74c3c;
}

.video-date {
    font-size: 12px;
    color: #95a5a6;
}

/* 响应式设计 - 所有设备都保持一排2个 */
@media (max-width: 768px) {
    .video-grid {
        grid-template-columns: 1fr 1fr;
        gap: 12px;
        padding: 0 5px;
    }
    
    .video-title {
        font-size: 14px;
        min-height: 36px;
        -webkit-line-clamp: 2;
    }
    
    .video-info {
        padding: 10px;
    }
    
    .play-icon {
        width: 45px;
        height: 45px;
        font-size: 18px;
    }
    
    .video-meta {
        font-size: 11px;
    }
    
    .video-category {
        padding: 2px 6px;
        font-size: 10px;
    }
}

@media (max-width: 480px) {
    .video-grid {
        grid-template-columns: 1fr 1fr; /* 手机端也保持2列 */
        gap: 8px;
        padding: 0 3px;
    }
    
    .video-title {
        font-size: 12px;
        min-height: 32px;
        line-height: 1.3;
    }
    
    .video-info {
        padding: 8px;
    }
    
    .play-icon {
        width: 40px;
        height: 40px;
        font-size: 16px;
    }
    
    .video-meta {
        font-size: 10px;
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
    }
    
    .video-category {
        padding: 2px 4px;
        font-size: 9px;
    }
    
    .video-date {
        font-size: 9px;
    }
}

/* 加载动画 */
.video-item {
    animation: fadeInUp 0.6s ease forwards;
}

.video-item:nth-child(1) { animation-delay: 0.1s; }
.video-item:nth-child(2) { animation-delay: 0.2s; }
.video-item:nth-child(3) { animation-delay: 0.3s; }
.video-item:nth-child(4) { animation-delay: 0.4s; }
.video-item:nth-child(5) { animation-delay: 0.5s; }
.video-item:nth-child(6) { animation-delay: 0.6s; }

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
} 