/* 全局样式 */
body {
    font-family: "Segoe UI Web (West European)", "Segoe UI", -apple-system, BlinkMacSystemFont, "Roboto", "Helvetica Neue", sans-serif;
    background-color: #f8f9fa;
    padding-bottom: 0;
    transition: padding-bottom 0.3s ease;
    -webkit-font-smoothing: antialiased;
}

.gray-500 {color:#adb5bd}
/* 播放器样式 */
#globalPlayer {
    /*position: relative;  改为相对定位，因为现在播放器在页面内容中 */
    background: #fff;
    border: 1px solid #dee2e6;
    border-radius: 0.5rem;
    box-shadow: 0 0.125rem 0.25rem rgba(0,0,0,0.075);
    z-index: 1000;
    display: block; /* 确保默认显示 */
    margin-bottom: 1rem;
}

.player-content {
    max-width: 100%;
    padding: 1rem;
    position: relative;
}

/* 移动端布局 - 第一行：时间轴 */
.player-progress-row {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
    width: 100%;
}

.player-progress-row .progress-container {
    flex: 1;
    min-width: 0;
}

.player-progress-row .progress-time {
    font-size: 0.75rem;
    color: #6c757d;
    min-width: 40px;
    text-align: center;
}

/* 移动端布局 - 第二行：标题和操作按钮 */
.player-controls-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    width: 100%;
}

.player-info-mobile {
flex: 1;
    min-width: 0;
    overflow: hidden;
}

.player-info-mobile .player-title {
    font-weight: 600;
    font-size: 0.9rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin: 0;
    line-height: 1.2;
}

.player-actions-mobile {
    display: flex;
    align-items: center;
    gap: 5px;
    flex-shrink: 0;
}

.player-actions-mobile .player-buttons {
    display: flex;
    gap: 2px;
}

.player-actions-mobile .btn {
    padding: 0.25rem 0.5rem;
    font-size: 0.75rem;
}

/* 内容分类按钮区域 */
.player-category-buttons {
    margin: 15px 0;
    padding: 10px 0;
}

.player-category-buttons .text-center {
    margin: 0 auto;
    max-width: 600px;
}

.player-category-buttons h5 {
    font-size: 0.9rem;
    margin-bottom: 10px;
    color: #6c757d;
}

.player-category-buttons .d-flex {
    gap: 8px;
}

.player-category-buttons .btn {
    font-size: 0.8rem;
    padding: 0.3rem 0.6rem;
    border-radius: 20px;
}

/* 桌面端布局 */
.player-controls-desktop {
    display: flex;
    align-items: center;
    gap: 15px;
    flex-wrap: wrap;
}

.player-controls-desktop .player-buttons {
    display: flex;
    gap: 5px;
}

.player-controls-desktop .player-info {
    flex: 1;
    min-width: 0;
}

.player-controls-desktop .player-title {
    font-weight: 600;
    margin-bottom: 5px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.player-controls-desktop .player-progress {
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 0;
}

.player-controls-desktop .progress-container {
    flex: 1;
    cursor: pointer;
    min-width: 100px;
}

.player-controls-desktop .progress-time {
    font-size: 0.875rem;
    color: #6c757d;
    min-width: 45px;
    text-align: center;
}

.player-volume {
    position: relative;
}

.volume-slider {
    position: absolute;
    bottom: 100%;
    right: 0;
    background: white;
    padding: 10px;
    border-radius: 4px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.2);
    display: none;
    width: 120px; /* 固定滑块容器宽度 */
}

/* 覆盖Bootstrap的form-range宽度设置 */
.volume-slider .form-range {
    width: 100px !important; /* 固定滑块宽度，覆盖Bootstrap的100% */
    margin: 0;
}

.player-volume:hover .volume-slider {
    display: block;
}

.player-playlist {
    position: relative;
}

/* 移动端播放列表 */
.mobile-playlist {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: white;
    border-radius: 8px 8px 0 0;
    box-shadow: 0 -2px 10px rgba(0,0,0,0.1);
    display: none;
z-index: 1001;
    max-height: 50vh;
    overflow: hidden;
    transform: translateY(100%);
    transition: transform 0.3s ease;
}

.mobile-playlist.show {
    display: block;
    transform: translateY(0);
}

.playlist-header {
    background: #f8f9fa;
    border-radius: 8px 8px 0 0;
    position: sticky;
    top: 0;
    z-index: 1;
}

.playlist-items {
max-height: calc(50vh - 60px);
    overflow-y: auto;
}

.playlist-items .list-group-item {
    border: none;
    border-bottom: 1px solid #dee2e6;
    padding: 10px 15px;
    font-size: 0.9rem;
}

.playlist-items .list-group-item:last-child {
    border-bottom: none;
}

.playlist-items .list-group-item.active {
    background-color: #0d6efd;
    border-color: #0d6efd;
    color: white;
}


/* 播放器样式 */
#globalPlayer {

    bottom: 0;
    left: 0;
right: 0;
    background: #fff;
    border-top: 1px solid #dee2e6;
    box-shadow: 0px -3px 20px 2px rgb(0 0 0 / 25%);
    z-index: 1000;
    display: none;
}

.player-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 15px;
position: relative;
}

/* 其他样式保持不变... */

.playlist-items .list-group-item:last-child {
    border-bottom: none;
}

.playlist-items .list-group-item.active {
    background-color: #0d6efd;
    border-color: #0d6efd;
    color: white;
}

/* 桌面端播放列表弹出层 */
.playlist-popup {
    box-shadow: 0 -2px 10px rgba(0,0,0,0.1);
    display: none;
    position: absolute;
    bottom: 100%;
    right: 0;
    width: 300px;
    z-index: 1001;
    background: white;
    border-radius: 8px;
}

.playlist-popup .list-group-item {
    border: none;
    border-bottom: 1px solid #dee2e6;
    padding: 10px 15px;
}

.playlist-popup .list-group-item:last-child {
    border-bottom: none;
}

.playlist-popup .list-group-item.active {
    background-color: #eaeaea;
    color: #333;
}

/* 字幕显示区域 - 修改为flex布局 */
.subtitles-display {
    background: rgba(0,0,0,0.8);
    color: white;
    padding: 15px;
    border-radius: 8px;
    margin-top: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    min-height: 170px;
}

/* 字幕内容包装器 */
.subtitles-content-wrapper {
    display: flex;
    align-items: center;
    gap: 15px;
    max-width: 100%;
}

/* 封面图样式 */
.cover-image {
    width: 100px;
    height: 100px;
    object-fit: cover;
    border-radius: 8px;
    flex-shrink: 0;
    opacity: 0.6;
}

/* 字幕文本容器 */
.subtitles-text-container {
    flex: 1;
    text-align: center;
    min-width: 0;
}

.subtitle-prev, .subtitle-next {
    color: rgba(255,255,255,0.6);
    font-size: 0.9em;
    margin: 3px 0;
    min-height: 1.2em;
    line-height: 1.3;
    transition: all 0.3s ease;
}

.subtitle-current {
    font-size: 1.1em;
    margin: 8px 0;
    color: #fff;
    min-height: 1.4em;
    line-height: 1.4;
    transition: all 0.3s ease;
}

/* 移动端适配 */
@media (max-width: 768px) {
    .subtitles-content-wrapper {
        flex-direction: row;
        gap: 10px;
        align-items: center;
    }
    
    .cover-image {
        width: 80px;
        height: 80px;
    }
    
    .subtitles-text-container {
        width: 100%;
    }
}

/* 桌面端适配 */
@media (min-width: 769px) {
    .cover-image {
        width: 120px;
        height: 120px;
    }
}

/* 字幕动画效果 */
.fade-in {
    animation: fadeInUp 0.3s ease-out forwards;
}

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

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

/* 字幕状态样式 */
.subtitle-loading {
    color: #ffc107;
    animation: pulse 1.5s infinite;
}

.subtitle-error {
    color: #dc3545;
}

.subtitle-empty {
    color: #6c757d;
    font-style: italic;
}

@keyframes pulse {
    0% {
        opacity: 0.6;
    }
    50% {
        opacity: 1;
    }
    100% {
        opacity: 0.6;
    }
}

/* 字幕过渡效果 */
.subtitle-transition {
    animation: subtitleTransition 0.5s ease-out;
}

@keyframes subtitleTransition {
    0% {
        opacity: 0;
        transform: translateY(5px);
    }
    50% {
opacity: 0.5;
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

.subtitle-prev.fade-out {
    animation: fadeOutDown 0.3s ease forwards;
}

.subtitle-current.fade-in {
    animation: fadeInUp 0.3s ease forwards;
}

.subtitle-next.fade-in {
    animation: fadeInUp 0.3s ease forwards;
}

/* Loading状态样式 */
.subtitle-loading {
    color: #ffa800 !important;
    animation: pulse 1.5s infinite;
}

.subtitle-error {
    color: #dc3545 !important;
}

.subtitle-empty {
    color: #6c757d !important;
}


/*内容页面 start*/
        .subtitles-container {
            max-height: 400px;
            overflow-y: auto;
            border: 1px solid #dee2e6;
            border-radius: 0.375rem;
            padding: 1rem;
            background-color: #f8f9fa;
        }
        
        .subtitle-item {
            padding: 0.5rem;
            margin-bottom: 0.25rem;
            border-radius: 0.25rem;
            transition: all 0.3s ease;
        }
        
        .subtitle-item.active {
            background-color: #fff3cd;
            border-left: 4px solid #ffc107;
            font-size: 1.1em;
            font-weight: bold;
            transform: scale(1.02);
        }
        
        .subtitle-time {
            color: #6c757d;
            font-size: 0.85em;
            margin-bottom: 0.25rem;
        }
        
        .subtitle-text {
            margin: 0;
        }
        
        .player-section {
            margin-top: 2rem;
        }
        
        
        .player-controls {
            display: flex;
            align-items: center;
            gap: 1rem;
            flex-wrap: wrap;
        }
        
        .player-progress {
            flex: 1;
            min-width: 200px;
        }
        
        .progress-container {
            width: 100%;
            height: 6px;
            background-color: #e9ecef;
            border-radius: 3px;
            overflow: hidden;
            cursor: pointer;
            margin: 0.5rem 0;
        }
        
        .progress-bar {
            height: 100%;
            background-color: #0d6efd;
            width: 0%;
            transition: width 0.1s linear;
        }
        
        .time-display {
            display: flex;
            justify-content: space-between;
            font-size: 0.85rem;
            color: #6c757d;
        }
        
        /* 音量控制相关样式 */
        .volume-control-wrapper {
            position: relative;
            display: flex;
            align-items: center;
        }
        
        .volume-btn {
            cursor: pointer;
            padding: 0.25rem;
        }
        
        .volume-slider-container {
            position: absolute;
            bottom: 100%;
            left: 50%;
            transform: translateX(-50%);
            background: white;
            border: 1px solid #ddd;
            border-radius: 0.375rem;
            padding: 0.5rem;
            box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
            z-index: 1000;
            display: none;
        }
        
        .volume-slider-vertical {
            width: 6px;
            height: 100px;
            -webkit-appearance: slider-vertical;
            appearance: slider-vertical;
            writing-mode: bt-lr; /* IE */
            -webkit-writing-mode: vertical-lr; /* Safari */
            direction: rtl; /* RTL */
        }
        
        .volume-slider-container.show {
            display: block;
        }
        
        /* 移动端隐藏音量控制 */
        @media (max-width: 768px) {
            .volume-control-wrapper {
                display: none;
            }
            
            .player-controls {
                flex-direction: column;
                align-items: stretch;
            }
            
            .player-progress {
                min-width: 100%;
            }
        }
/*内容页面 end */

/* 响应式调整 */
@media (max-width: 767px) {
    #globalPlayer {
        display: block !important; /* 确保移动端播放器默认显示 */
        /* 移除固定高度，改为通过JavaScript控制 */
        overflow: hidden; /* 防止内容溢出 */
    }
    
    .player-content {
        padding: 10px;
        height: 100%; /* 内容区域占满播放器高度 */
        display: flex;
        flex-direction: column;
    }
    
    /* 新的移动端播放按钮和时间轴布局 */
    .player-progress-controls-mobile {
        display: flex !important;
        align-items: center;
        gap: 10px;
        margin-bottom: 10px;
    }
    
    .player-progress-controls-mobile .btn {
        padding: 0.3rem 0.5rem;
        font-size: 0.8rem;
        flex-shrink: 0;
    }
    
    .progress-container-mobile {
        flex-grow: 1;
        cursor: pointer;
        padding: 8px 0;
    }
    
    .progress-container-mobile .progress {
        height: 6px;
        margin: 0;
        cursor: pointer;
    }
    
    .progress-container-mobile .progress-bar {
        z-index: 1;
        position: relative;
    }
    
    .player-progress-controls-mobile .progress-time {
        font-size: 0.7rem;
        color: #6c757d;
        flex-shrink: 0;
        min-width: 40px;
        text-align: right;
    }
    
    /* 隐藏原来的时间显示 */
    .player-progress-row {
        display: none !important;
    }
    
    .player-controls-row {
        display: flex !important;
    }
    
    .player-controls-desktop {
        display: none !important;
    }
    
    .player-actions-mobile .btn {
        padding: 0.2rem 0.4rem;
        font-size: 0.7rem;
    }
    
    .player-info-mobile .player-title {
        font-size: 0.8rem;
    }
    
    .mobile-playlist {
        max-height: 50vh;
    }
    
    /* 字幕显示区域在移动端自适应 */
    .subtitles-display {
        margin-bottom: 10px;
        padding: 8px;
        max-height: 250px; /* 限制字幕区域高度 */
        overflow-y: auto;   /*字幕过多时可滚动 */
        order: -1; /* 确保字幕区域在移动端布局中显示在最前面 */
        min-height: 125px;
    }
}

@media (min-width: 768px) {
    #globalPlayer {
        height: auto; /* 桌面端保持自适应高度 */
    }
    
    /* 桌面端隐藏移动端布局 */
    .player-progress-controls-mobile {
        display: none !important;
    }
    
    .player-progress-row {
        display: none !important;
    }
    
    .player-controls-row {
        display: none !important;
    }
    
    .player-controls-desktop {
        display: flex !important;
    }
    
    .mobile-playlist {
        display: none !important;
    }
}

/* 按钮样式增强 */
.btn {
    border-radius: 6px;
    transition: all 0.2s ease;
}

.btn:hover {
    transform: translateY(-1px);
}

/*.btn-primary {*/
/*    background: linear-gradient(45deg, #fd0d0d, #ee1010);*/
/*    border: none;*/
/*}*/

/*.btn-outline-primary {*/
/*    border-color: #0d6efd;*/
/*    color: #0d6efd;*/
/*}*/

/*.btn-outline-primary:hover {*/
/*    background-color: #0d6efd;*/
/*    border-color: #0d6efd;*/
/*}*/

/*.btn-outline-secondary {*/
/*    border-color: #6c757d;*/
/*    color: #6c757d;*/
/*}*/

/*.btn-outline-secondary:hover {*/
/*    background-color: #6c757d;*/
/*    border-color: #6c757d;*/
/*    color: white;*/
/*}*/

/* Bootstrap图标修复 */
.bi::before {
    display: inline-block;
    font-family: bootstrap-icons !important;
    font-style: normal;
    font-weight: normal !important;
    font-variant: normal;
    text-transform: none;
    line-height: 1;
    vertical-align: -.125em;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

.card {
    border: none;
    border-radius: 12px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    transition: transform 0.2s ease;
    margin-bottom: 1.5rem;
}

.card:hover {
    transform: translateY(-2px);
}

.card-header {
    background: #fff;
    border-bottom: 1px solid #e9ecef;
    border-radius: 12px 12px 0 0 !important;
    padding: 1rem 1.25rem;
}

.card-body {
    padding: 1.25rem;
}

/* 导航样式 */
.navbar {
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.navbar-brand {
    font-size: 1.5rem;
    color: #0d6efd !important;
}

/* 标签样式 */
.badge {
    border-radius: 20px;
    padding: 0.5em 0.8em;
    font-weight: 500;
}

/* 字幕内容样式 */
.subtitles-area {
    max-height: 400px;
    overflow-y: auto;
}

.subtitle-content {
    white-space: pre-wrap;
/* 呼吸灯效果 */
.breathing-btn {
    animation: breathing 2s ease-in-out infinite;
    position: relative;
    z-index: 1;
    box-shadow: 0 4px 15px rgba(13, 110, 253, 0.4);
}

@keyframes breathing {
    0% {
        transform: scale(1);
        box-shadow: 0 4px 15px rgba(13, 110, 253, 0.4);
    }
    50% {
        transform: scale(1.05);
        box-shadow: 0 6px 20px rgba(13, 110, 253, 0.6);
    }
    100% {
        transform: scale(1);
        box-shadow: 0 4px 15px rgba(13, 110, 253, 0.4);
    }
}

/* 分类导航宣传语样式 */
.card-body .text-center h2 {
    font-size: 2rem;
    font-weight: 600;
    background: linear-gradient(135deg, #0d6efd 0%, #6610f2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.card-body .text-center .lead {
    font-size: 1.1rem;
    font-weight: 300;
}

/* 突出播放按钮样式 */
.breathing-btn {
    font-size: 1.2rem;
    font-weight: 600;
    padding: 0.75rem 2rem;
    border-radius: 30px;
    border: none;
    background: linear-gradient(135deg, #0d6efd 0%, #6610f2 100%);
    transition: all 0.3s ease;
}

.breathing-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(13, 110, 253, 0.5);
    animation: none;
}

.breathing-btn:active {
    transform: translateY(0);
}

/* 分类导航整体样式优化 */
.card-body {
    padding: 2rem;
}

.card-body .text-center h5 {
    font-weight: 500;
    color: #495057;
    margin-bottom: 1rem;
}

/* 响应式调整 */
@media (max-width: 768px) {
    .card-body .text-center h2 {
        font-size: 1.5rem;
    }
    
    .card-body .text-center .lead {
        font-size: 1rem;
    }
    
    .breathing-btn {
        font-size: 1rem;
        padding: 0.6rem 1.5rem;
    }
    
    .card-body {
        padding: 1.5rem;
    }
}
    font-family: 'Courier New', monospace;
    line-height: 1.6;
    background: #f8f9fa;
    padding: 15px;
    border-radius: 8px;
    border: 1px solid #dee2e6;
    margin: 0;
}

/* 分页样式 */
.pagination {
    margin-bottom: 0;
}

.pagination .page-item.active .page-link {
    background-color: #0d6efd;
    border-color: #0d6efd;
}

.pagination .page-link {
    color: #0d6efd;
    border: 1px solid #dee2e6;
}

.pagination .page-link:hover {
    color: #0a58ca;
    background-color: #e9ecef;
    border-color: #dee2e6;
}

/* 分类按钮样式 */
.play-category-btn {
    font-weight: 400;
    text-decoration: none;
    border-radius: 20px;
    transition: all 0.3s ease;
    font-size: small;
}

.play-category-btn:hover {
    transform: translateY(-1px);
    text-decoration: none;
}

.play-category-btn.active {
    background-color: #0d6efd !important;
    border-color: #0d6efd !important;
    color: white !important;
    transform: scale(1.05);
}

/* 播放全部按钮 */
.play-all-btn {
    font-weight: 500;
    text-decoration: none;
    border-radius: 24px;
}

.play-all-btn:hover {
    transform: translateY(-2px);
    text-decoration: none;
}

/* 底部间距调整 */
footer {
    margin-top: auto;
}

/* 容器内边距调整 */
.container {
    padding-bottom: 20px;
}

/* 列表组样式调整 */
.list-group {
    border-radius: 8px;
    overflow: hidden;
}

.list-group-item {
    border-radius: 0;
}

.list-group-item:first-child {
    border-top-left-radius: 8px;
    border-top-right-radius: 8px;
}

.list-group-item:last-child {
    border-bottom-left-radius: 8px;
    border-bottom-right-radius: 8px;
}

/* 播放按钮样式 */
.btn-play {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    color: #de4d4d;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    transition: all 0.3s ease;
    flex-shrink: 0;
    box-shadow: 0px 0px 12px 0px rgb(106 106 106 / 30%);
}

.btn-play:hover {
    transform: scale(1.1);
    color: #ea0000;
}

.btn-play .bi {
    font-size: 1.2rem;
    line-height: 1;
}

/* 内容列表项样式 */
.content-item {
    cursor: pointer;
    transition: all 0.2s ease;
    border: 1px solid transparent;
}

.content-item:hover {
    background-color: #f8f9fa;
    border-color: #dee2e6;
}

/*.content-item .d-flex {*/
/*    min-height: 60px;*/
/*}*/

/* 播放按钮在列表项中的布局 */
.list-group-item .d-flex.align-items-center {
    padding: 0;
}

/* 响应式调整 */
@media (max-width: 576px) {
    .btn-play {
        width: 30px;
        height: 30px;
        margin-right: 0.75rem !important;
    }
    
    .btn-play .bi {
        font-size: 0.9rem;
    }
    
    .content-item .d-flex {
        min-height: 50px;
    }
    
    /* 移动端布局：只显示播放按钮和标题 */
    .content-item .d-flex.align-items-center {
        padding: 0.5rem 0;
    }
    
    /* 移动端标题样式 */
    .content-item .d-md-none h6 {
        font-size: 0.9rem;
        line-height: 1.3;
        margin-bottom: 0;
        flex: 1;
        min-width: 0;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }
    
    /* 确保移动端布局正确显示 */
    .content-item .d-md-none {
        display: flex !important;
        align-items: center;
        width: 100%;
        min-height: 40px;
    }
    
    /* 隐藏桌面端布局 */
    .content-item .d-md-block {
        display: none !important;
    }
    
    /* 列表项内边距调整 */
    .content-item {
        padding: 0.75rem 1rem;
    }
    
    /* 播放按钮在移动端的间距调整 */
    .content-item .btn-play {
        margin-right: 0.75rem !important;
    }
}

/* 移动端中等屏幕适配 */
@media (max-width: 768px) {
    .content-item .d-md-none {
        display: flex !important;
    }
    
    .content-item .d-md-block {
        display: none !important;
    }
}

/* 桌面端显示桌面布局 */
@media (min-width: 769px) {
    .content-item .d-md-none {
        display: none !important;
    }
    
    .content-item .d-md-block {
        display: block !important;
    }
}