/* 现代化影视模板样式 */

:root {
    --primary-color: #0d6efd;
    --secondary-color: #6c757d;
    --success-color: #198754;
    --danger-color: #dc3545;
    --warning-color: #ffc107;
    --info-color: #0dcaf0;
    --light-color: #f8f9fa;
    --dark-color: #212529;
    --border-radius: 8px;
    --box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    --transition: all 0.3s ease;
}

* {
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    background-color: #f5f5f5;
    color: #333;
    line-height: 1.6;
}

/* 导航栏样式 */
.navbar {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%) !important;
    padding: 1rem 0;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.navbar-brand {
    font-size: 1.5rem;
    font-weight: 700;
    color: #fff !important;
}

.nav-link {
    color: rgba(255, 255, 255, 0.9) !important;
    font-weight: 500;
    transition: var(--transition);
    padding: 0.5rem 1rem !important;
    border-radius: var(--border-radius);
    margin: 0 0.25rem;
}

.nav-link:hover {
    background-color: rgba(255, 255, 255, 0.1);
    color: #fff !important;
}

/* 搜索框样式 */
.search-form {
    margin-left: 1rem;
}

.search-form .form-control {
    border-radius: 25px;
    border: 1px solid rgba(255, 255, 255, 0.3);
    background-color: rgba(255, 255, 255, 0.1);
    color: #fff;
    padding: 0.5rem 1.25rem;
    min-width: 250px;
}

.search-form .form-control::placeholder {
    color: rgba(255, 255, 255, 0.7);
}

.search-form .form-control:focus {
    background-color: rgba(255, 255, 255, 0.2);
    border-color: rgba(255, 255, 255, 0.5);
    color: #fff;
    box-shadow: 0 0 0 0.2rem rgba(255, 255, 255, 0.25);
}

.search-form .btn {
    border-radius: 25px;
    padding: 0.5rem 1rem;
    border: 1px solid rgba(255, 255, 255, 0.3);
}

/* 主内容区域 */
.main-content {
    min-height: calc(100vh - 200px);
}

/* 卡片样式 */
.card {
    border: none;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    transition: var(--transition);
    overflow: hidden;
    background: #fff;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.15);
}

.card-img-top {
    border-radius: var(--border-radius) var(--border-radius) 0 0;
    transition: var(--transition);
    height: 280px;
    object-fit: cover;
}

.card:hover .card-img-top {
    transform: scale(1.05);
}

.card-body {
    padding: 1rem;
}

.card-title {
    font-size: 0.95rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    line-height: 1.4;
    height: 2.8em;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.card-title a {
    color: #333;
    text-decoration: none;
    transition: var(--transition);
}

.card-title a:hover {
    color: var(--primary-color);
}

/* 视频卡片网格 */
.video-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 1.5rem;
    margin-top: 1.5rem;
}

.video-item {
    position: relative;
    border-radius: var(--border-radius);
    overflow: hidden;
    background: #fff;
    box-shadow: var(--box-shadow);
    transition: var(--transition);
}

.video-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.15);
}

.video-item img {
    width: 100%;
    height: 250px;
    object-fit: cover;
    display: block;
}

.video-info {
    padding: 0.75rem;
}

.video-title {
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    line-height: 1.4;
    height: 2.8em;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.video-title a {
    color: #333;
    text-decoration: none;
}

.video-title a:hover {
    color: var(--primary-color);
}

.video-remarks {
    font-size: 0.75rem;
    color: var(--secondary-color);
}

/* 分类标题 */
.section-title {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    padding-bottom: 0.75rem;
    border-bottom: 3px solid var(--primary-color);
    display: inline-block;
}

.section-title a {
    color: #333;
    text-decoration: none;
}

.section-title a:hover {
    color: var(--primary-color);
}

/* 详情页样式 */
.detail-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #fff;
    padding: 2.5rem 0;
    margin-bottom: 2rem;
    border-radius: 0;
}

.detail-header .container {
    max-width: 1200px;
}

.detail-poster {
    border-radius: var(--border-radius);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.4);
    max-width: 100%;
    width: 100%;
    height: auto;
    max-height: 400px;
    object-fit: cover;
}

.detail-title {
    font-size: 2.2rem;
    font-weight: 700;
    margin-bottom: 0.75rem;
    color: #fff;
    line-height: 1.3;
}

.detail-subtitle {
    font-size: 1.1rem;
    opacity: 0.9;
    margin-bottom: 1rem;
    color: rgba(255, 255, 255, 0.9);
}

.detail-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-top: 1rem;
}

.meta-item {
    background: rgba(255, 255, 255, 0.25);
    backdrop-filter: blur(10px);
    padding: 0.5rem 1rem;
    border-radius: 25px;
    font-size: 0.9rem;
    border: 1px solid rgba(255, 255, 255, 0.3);
    transition: var(--transition);
}

.meta-item:hover {
    background: rgba(255, 255, 255, 0.35);
    transform: translateY(-2px);
}

.detail-content {
    background: #fff;
    padding: 2rem;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    margin-bottom: 2rem;
    height: 100%;
}

.detail-sidebar {
    position: sticky;
    top: 20px;
}

/* 头部区域的详细信息侧边栏 */
.detail-info-sidebar {
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(10px);
    border-radius: var(--border-radius);
    padding: 1.5rem;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.detail-info-item-sidebar {
    margin-bottom: 1.25rem;
    padding-bottom: 1.25rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
}

.detail-info-item-sidebar:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
}

.detail-info-label-sidebar {
    font-weight: 600;
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 0.5rem;
    font-size: 0.95rem;
    display: flex;
    align-items: center;
}

.detail-info-label-sidebar i {
    color: rgba(255, 255, 255, 0.8);
    width: 20px;
}

.detail-info-value-sidebar {
    color: rgba(255, 255, 255, 0.85);
    line-height: 1.6;
    font-size: 0.9rem;
    word-break: break-word;
}

.detail-content-title {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    padding-bottom: 0.75rem;
    border-bottom: 2px solid #e9ecef;
    color: #333;
}

.detail-info-item {
    margin-bottom: 1.5rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid #f0f0f0;
}

.detail-info-item:last-child {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

.detail-info-label {
    font-weight: 600;
    color: #495057;
    margin-bottom: 0.5rem;
    font-size: 1rem;
    display: flex;
    align-items: center;
}

.detail-info-label i {
    color: var(--primary-color);
    width: 20px;
}

.detail-info-value {
    color: #6c757d;
    line-height: 1.8;
    font-size: 0.95rem;
    padding-left: 28px;
    word-break: break-word;
}

.detail-sidebar .detail-info-value {
    padding-left: 0;
    margin-top: 0.5rem;
}

.detail-description {
    color: #495057;
    line-height: 1.8;
    text-align: justify;
}

.detail-description-full {
    color: #495057;
    line-height: 2;
    font-size: 1rem;
    text-align: justify;
    padding: 1rem 0;
}

/* 播放器区域样式 */
.player-section {
    margin-bottom: 2rem;
}

.player-section .card {
    border: none;
    border-radius: var(--border-radius);
    overflow: hidden;
}

.player-section .card-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%) !important;
    border: none;
    padding: 1rem 1.5rem;
}

.player-section .card-body {
    background: #f8f9fa;
    padding: 1.5rem !important;
}

.player-wrapper {
    width: 100%;
    position: relative;
}

#artplayer-container {
    border-radius: 8px;
    overflow: hidden;
    min-height: 450px !important;
    width: 100% !important;
}

@media (min-width: 992px) {
    #artplayer-container {
        min-height: 550px !important;
    }
}

@media (min-width: 1200px) {
    #artplayer-container {
        min-height: 600px !important;
    }
}

.episode-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.episode-btn {
    transition: var(--transition);
}

.episode-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.episode-btn.active {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
    color: #fff;
}

/* 分页样式 */
.pagination {
    justify-content: center;
    margin-top: 2rem;
}

.page-link {
    border-radius: var(--border-radius);
    margin: 0 0.25rem;
    border: 1px solid #dee2e6;
    color: var(--primary-color);
    transition: var(--transition);
}

.page-link:hover {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
    color: #fff;
}

.page-item.active .page-link {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
}

/* 页脚样式 */
.footer {
    margin-top: 3rem;
    padding: 2rem 0;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .video-grid {
        grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
        gap: 1rem;
    }

    .video-item img {
        height: 200px;
    }

    .search-form {
        margin-left: 0;
        margin-top: 1rem;
        width: 100%;
    }

    .search-form .form-control {
        min-width: auto;
    }

    .detail-title {
        font-size: 1.5rem;
    }

    .detail-subtitle {
        font-size: 1rem;
    }

    .detail-header {
        padding: 1.5rem 0;
    }

    .detail-content {
        padding: 1.25rem;
    }

    .detail-info-value {
        padding-left: 0;
        margin-top: 0.5rem;
    }

    .detail-sidebar {
        position: static;
    }

    .detail-info-sidebar {
        margin-top: 1.5rem;
        background: rgba(255, 255, 255, 0.1);
    }

    .meta-item {
        font-size: 0.85rem;
        padding: 0.4rem 0.8rem;
    }

    #artplayer-container {
        min-height: 300px;
    }
}

/* 加载动画 */
.loading {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: #fff;
    animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* 空状态 */
.empty-state {
    text-align: center;
    padding: 3rem 1rem;
    color: var(--secondary-color);
}

.empty-state i {
    font-size: 4rem;
    margin-bottom: 1rem;
    opacity: 0.5;
}

