
        /* 基础样式保持不变 */
        * {
            margin: 0;
            padding: 0;
            box-sizing: border-box;
        }
        
        body {
            font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
            background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);
            color: white;
            overflow: hidden;
            height: 100vh;
        }
        
        .learn-container {
            display: flex;
            height: 100vh;
            background-color: #1a1a1a;
            color: white;
            overflow: hidden;
            position: relative;
        }
        
        .video-section {
            flex: 1;
            display: flex;
            flex-direction: column;
            padding: 20px;
            transition: all 0.3s ease;
            width: 100%;
            position: relative;
        }
        
        .video-container {
            position: relative;
            width: 100%;
            flex: 1;
            border-radius: 12px;
            overflow: hidden;
            background-color: #000;
            min-height: 0;
            box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
        }
        
        #videoPlayer {
            width: 100%;
            height: 100%;
            outline: none;
            cursor: pointer;
        }
        
        /* 自定义控制条 - 优化后 */
        .custom-controls {
            position: absolute;
            bottom: 0;
            left: 0;
            right: 0;
            background: linear-gradient(transparent, rgba(0,0,0,0.9));
            padding: 10px 15px;
            display: flex;
            flex-direction: column;
            opacity: 0;
            transition: opacity 0.3s ease;
            pointer-events: none;
            z-index: 20;
        }
        
        .video-container:hover .custom-controls {
            opacity: 1;
            pointer-events: all;
        }
        
        .custom-progress {
            width: 100%;
            height: 6px;
            background: rgba(255,255,255,0.2);
            border-radius: 3px;
            margin-bottom: 10px;
            cursor: pointer;
            position: relative;
        }
        
        .custom-progress-filled {
            position: absolute;
            top: 0;
            left: 0;
            height: 100%;
            background: linear-gradient(90deg, #3498db, #2ecc71);
            border-radius: 3px;
            width: 0%;
            transition: width 0.1s linear;
        }
        
        .custom-controls-buttons {
            display: flex;
            justify-content: space-between;
            align-items: center;
            flex-wrap: wrap;
            gap: 10px;
        }
        
        .custom-controls-left, .custom-controls-right {
            display: flex;
            align-items: center;
            gap: 10px;
        }
        
        .custom-controls-btn {
            background: none;
            border: none;
            color: white;
            font-size: 1.2rem;
            cursor: pointer;
            padding: 5px;
            border-radius: 4px;
            transition: background 0.2s;
        }
        
        .custom-controls-btn:hover {
            background: rgba(255,255,255,0.2);
        }
        
        .custom-time {
            font-size: 0.9rem;
            color: white;
        }
        
        /* 控制按钮组样式 - 移动到控制条中 */
        .control-buttons {
            display: flex;
            flex-wrap: wrap;
            gap: 10px;
            justify-content: center;
            margin-top: 10px;
        }
        
        .control-group {
            display: flex;
            gap: 5px;
            align-items: center;
        }
        
        .checkbox-group {
            display: flex;
            align-items: center;
            gap: 5px;
            padding: 5px 10px;
            background: rgba(255,255,255,0.1);
            border-radius: 4px;
            font-size: 0.85rem;
        }
        
        .checkbox-group input[type="checkbox"] {
            width: 14px;
            height: 14px;
        }
        
        .repeat-count-group {
            display: none; /* 默认隐藏 */
            align-items: center;
            gap: 5px;
            padding: 5px 10px;
            background: rgba(255,255,255,0.1);
            border-radius: 4px;
            font-size: 0.85rem;
        }
        
        /* 当跟读模式激活时显示 */
        .repeat-after-active .repeat-count-group {
            display: flex;
        }
        
        .repeat-count-input {
            width: 40px;
            padding: 3px;
            border-radius: 4px;
            border: none;
            background: rgba(255,255,255,0.1);
            color: white;
            text-align: center;
            font-size: 0.85rem;
        }
        
        .repeat-progress {
            font-size: 0.8rem;
            color: #2ecc71;
            font-weight: bold;
            margin-left: 5px;
            min-width: 50px;
        }
        
        .btn {
            padding: 6px 8px;
            border: none;
            border-radius: 4px;
            cursor: pointer;
            font-weight: 500;
            transition: all 0.2s;
            display: flex;
            align-items: center;
            justify-content: center;
            font-size: 0.9rem;
            position: relative;
        }
        
        .btn * {
            pointer-events: none;
        }
        
        .btn-text {
            width: auto;
            padding: 6px 8px;
        }
        
        .btn-primary {
            background: #3498db;
            color: white;
        }
        
        .btn-secondary {
            background: #7f8c8d;
            color: white;
        }
        
        .btn-success {
            background: #2ecc71;
            color: white;
        }
        
        .btn-warning {
            background: #f39c12;
            color: white;
        }
        
        .btn-danger {
            background: #e74c3c;
            color: white;
        }
        
        .btn:hover {
            transform: translateY(-2px);
            box-shadow: 0 4px 8px rgba(0,0,0,0.2);
        }
        
        .btn.active {
            box-shadow: 0 0 0 2px white;
        }
        
        .speed-selector {
            display: flex;
            align-items: center;
            gap: 5px;
            background: rgba(255,255,255,0.1);
            padding: 5px 8px;
            border-radius: 4px;
            font-size: 0.85rem;
        }
        
        .speed-selector select {
            background: transparent;
            border: none;
            color: white;
            padding: 3px;
            border-radius: 4px;
            font-size: 0.85rem;
        }
        
        .speed-selector select option {
            background: #2c3e50;
            color: white;
        }
        
        .file-input-container {
            position: relative;
            display: inline-block;
        }
        
        .file-input {
            position: absolute;
            left: 0;
            top: 0;
            opacity: 0;
            width: 100%;
            height: 100%;
            cursor: pointer;
        }
        
        /* 漂浮提示窗口样式 - 修改底部提示 */
        .tooltip {
            position: relative;
            display: inline-block;
        }
        
        .tooltip .tooltiptext {
            visibility: hidden;
            width: 200px;
            background-color: rgba(0, 0, 0, 0.8);
            color: white;
            text-align: center;
            border-radius: 6px;
            padding: 8px;
            position: absolute;
            z-index: 1000;
            bottom: 125%;
            left: 50%;
            transform: translateX(-50%);
            opacity: 0;
            transition: opacity 0.3s;
            font-size: 0.8rem;
            line-height: 1.4;
            pointer-events: none;
        }
        
        /* 底部提示样式 */
        .tooltip.bottom .tooltiptext {
            bottom: auto;
            top: 125%;
        }
        
        .tooltip .tooltiptext::after {
            content: "";
            position: absolute;
            top: 100%;
            left: 50%;
            margin-left: -5px;
            border-width: 5px;
            border-style: solid;
            border-color: rgba(0, 0, 0, 0.8) transparent transparent transparent;
        }
        
        .tooltip.bottom .tooltiptext::after {
            top: auto;
            bottom: 100%;
            border-color: transparent transparent rgba(0, 0, 0, 0.8) transparent;
        }
        
        .tooltip:hover .tooltiptext {
            visibility: visible;
            opacity: 1;
        }
        
        /* 自定义字幕层 - 保持在最上层 */
        .custom-subtitles {
            position: absolute;
            bottom: 15%;
            left: 0;
            width: 100%;
            text-align: center;
            color: white;
            font-size: 2.8rem;
            text-shadow: 1px 1px 2px black;
            pointer-events: none;
            z-index: 15;
            display: flex;
            flex-direction: column;
            align-items: center;
            gap: 10px;
        }
        
        .custom-subtitle-line {
            margin: 0;
            padding: 8px 15px;
            background: rgba(0, 0, 0, 0.7);
            border-radius: 8px;
            display: block;
            width: auto;
            max-width: 80%;
            pointer-events: auto;
            line-height: 1.4;
            min-height: 60px;
            display: flex;
            align-items: center;
            justify-content: center;
        }
        
        .custom-subtitle-line.empty {
            background: transparent;
            padding: 0;
            min-height: 0;
        }
        
        .custom-subtitle-line .word-break {
            cursor: pointer;
            padding: 2px 4px;
            border-radius: 3px;
            transition: background 0.2s;
        }
        
        .custom-subtitle-line .word-break:hover {
            background: rgba(255,255,255,0.2);
        }
        
        /* 字幕遮罩层 - 深灰色毛玻璃效果 */
        .subtitle-mask {
            position: absolute;
            background: rgba(30, 30, 30, 0.85);
            backdrop-filter: blur(10px);
            -webkit-backdrop-filter: blur(10px);
            border: 2px solid rgba(255, 255, 255, 0.1);
            z-index: 10;
            cursor: move;
            overflow: hidden;
            min-width: 200px;
            min-height: 80px;
            display: none;
            border-radius: 8px;
            box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
        }
        
        .subtitle-mask.active {
            display: block;
        }
        
        /* 遮罩层边缘调整区域 */
        .mask-resize-handle {
            position: absolute;
            background: transparent;
            z-index: 11;
        }
        
        /* 顶部边缘 */
        .mask-resize-handle.top {
            top: 0;
            left: 0;
            width: 100%;
            height: 10px;
            cursor: n-resize;
        }
        
        /* 底部边缘 */
        .mask-resize-handle.bottom {
            bottom: 0;
            left: 0;
            width: 100%;
            height: 10px;
            cursor: s-resize;
        }
        
        /* 左侧边缘 */
        .mask-resize-handle.left {
            top: 0;
            left: 0;
            width: 10px;
            height: 100%;
            cursor: w-resize;
        }
        
        /* 右侧边缘 */
        .mask-resize-handle.right {
            top: 0;
            right: 0;
            width: 10px;
            height: 100%;
            cursor: e-resize;
        }
        
        /* 左上角 */
        .mask-resize-handle.top-left {
            top: 0;
            left: 0;
            width: 15px;
            height: 15px;
            cursor: nw-resize;
        }
        
        /* 右上角 */
        .mask-resize-handle.top-right {
            top: 0;
            right: 0;
            width: 15px;
            height: 15px;
            cursor: ne-resize;
        }
        
        /* 左下角 */
        .mask-resize-handle.bottom-left {
            bottom: 0;
            left: 0;
            width: 15px;
            height: 15px;
            cursor: sw-resize;
        }
        
        /* 右下角 */
        .mask-resize-handle.bottom-right {
            bottom: 0;
            right: 0;
            width: 15px;
            height: 15px;
            cursor: se-resize;
        }
        
        /* 单词释义容器 */
        .word-explanations-container {
            display: flex;
            flex-direction: column;
            gap: 15px;
            max-height: 400px;
            overflow-y: auto;
            padding-right: 5px;
        }
        
        .word-explanation {
            background: rgba(255,255,255,0.1);
            padding: 15px;
            border-radius: 8px;
            margin-top: 10px;
            min-height: 120px;
            flex-shrink: 0;
            max-height: 300px;
            overflow-y: auto;
            flex: 0 0 auto;
            position: relative;
            border-left: 4px solid #3498db;
        }
        
        .word-explanation .close-btns {
            position: absolute;
            top: 10px;
            right: 10px;
            display: flex;
            gap: 5px;
        }
        
        .word-explanation .close-btn {
            background: none;
            border: none;
            color: white;
            font-size: 1rem;
            cursor: pointer;
            width: 24px;
            height: 24px;
            display: flex;
            align-items: center;
            justify-content: center;
            border-radius: 50%;
            transition: background 0.2s;
        }
        
        .word-explanation .close-btn.small {
            font-size: 0.9rem;
        }
        
        .word-explanation .close-btn.large {
            font-size: 1.2rem;
            font-weight: bold;
        }
        
        .word-explanation .close-btn:hover {
            background: rgba(255,255,255,0.2);
        }
        
        .word-header {
            display: flex;
            align-items: center;
            gap: 15px;
            margin-bottom: 10px;
            padding-right: 60px;
        }
        
        .word-title {
            font-size: 1.5rem;
            font-weight: bold;
            color: #3498db;
        }
        
        .phonetics {
            display: flex;
            gap: 10px;
            align-items: center;
        }
        
        .phonetic {
            display: flex;
            align-items: center;
            gap: 5px;
        }
        
        .pronunciation-btn {
            background: none;
            border: none;
            color: white;
            cursor: pointer;
            font-size: 1.2rem;
        }
        
        .word-meaning {
            margin-bottom: 15px;
            line-height: 1.5;
        }
        
        .mnemonic-method {
            background: rgba(255,255,255,0.05);
            padding: 10px;
            border-radius: 4px;
            margin-bottom: 15px;
            font-style: italic;
            border-left: 2px solid #2ecc71;
        }
        
        /* 修改例句容器样式 */
        .example-sentence {
            display: flex;
            align-items: flex-start;
            gap: 10px;
            padding: 8px;
            background: rgba(255,255,255,0.05);
            border-radius: 4px;
            margin-bottom: 8px;
        }
        
        .sentence-content {
            flex: 1;
        }
        
        .english-sentence {
            display: flex;
            align-items: center;
            gap: 8px;
            margin-bottom: 5px;
        }
        
        .sentence-buttons {
            display: flex;
            gap: 5px;
            flex-shrink: 0;
        }
        
        .pronunciation-btn, .loop-btn {
            background: none;
            border: none;
            color: #95a5a6;
            cursor: pointer;
            font-size: 1rem;
            padding: 4px;
            border-radius: 4px;
            transition: all 0.2s;
            display: flex;
            align-items: center;
            justify-content: center;
        }
        
        .pronunciation-btn:hover, .loop-btn:hover {
            background: rgba(255,255,255,0.1);
            color: #3498db;
        }
        
        .loop-btn.looping {
            color: #e74c3c;
        }
        
        .loop-btn.looping svg path {
            fill: #e74c3c;
        }
        
        .example-translation {
            color: #95a5a6;
            font-size: 0.9rem;
            margin-left: 0;
        }
        
        .controls-section {
            padding: 15px 0;
            display: flex;
            flex-direction: column;
            gap: 15px;
            flex-shrink: 0;
            min-height: 0;
            flex: 0 0 auto;
        }
        
        /* 侧边栏样式 - 提高z-index确保在最上层 */
        .subtitles-section {
            width: 400px;
            display: flex; /* 修改：默认显示侧边栏 */
            flex-direction: column;
            background: #2c3e50;
            overflow: hidden;
            position: relative; /* 改为相对定位 */
            z-index: 25; /* 提高z-index确保在最上层 */
            box-shadow: -5px 0 15px rgba(0,0,0,0.3);
        }
        
        .subtitles-section.hide { /* 修改：添加隐藏类 */
            display: none;
        }
        
        .subtitles-header {
            padding: 15px;
            background: #34495e;
            border-bottom: 1px solid #4a6278;
            display: flex;
            justify-content: space-between;
            align-items: center;
        }
        
        .subtitles-header-left {
            display: flex;
            align-items: center;
            gap: 10px;
        }
        
        .repeat-count-container {
            display: none; /* 默认隐藏 */
            align-items: center;
            gap: 5px;
        }
        
        /* 当有多个字幕勾选时显示 */
        .repeat-count-container.multiple-selected {
            display: flex;
        }
        
        .subtitles-list {
            flex: 1;
            overflow-y: auto;
            padding: 10px;
            scroll-behavior: smooth;
            transition: scroll-behavior 0.3s;
        }
        
        .subtitle-item {
            display: flex;
            align-items: center;
            gap: 10px;
            padding: 10px;
            margin-bottom: 8px;
            border-radius: 4px;
            cursor: pointer;
            transition: all 0.3s ease;
            border-bottom: 2px solid transparent;
            opacity: 0.7;
            transform: scale(0.95);
        }
        
        .subtitle-item:hover {
            background: rgba(255,255,255,0.1);
        }
        
        .subtitle-item.current {
            background: rgba(52, 152, 219, 0.3);
            font-weight: bold;
            border-bottom: 2px solid #3498db;
            opacity: 1;
            transform: scale(1);
            box-shadow: 0 4px 12px rgba(52, 152, 219, 0.3);
        }
        
        .subtitle-item.upcoming {
            opacity: 0.9;
            transform: scale(0.98);
        }
        
        .subtitle-item.selected {
            background: rgba(46, 204, 113, 0.3);
        }
        
        .subtitle-checkbox {
            width: 18px;
            height: 18px;
        }
        
        .subtitle-content {
            flex: 1;
            font-size: 1.1rem;
        }
        
        .subtitle-time {
            font-size: 0.8rem;
            color: #bdc3c7;
            margin-top: 3px;
        }
        
        .favorite-icon {
            cursor: pointer;
            font-size: 1.2rem;
            transition: color 0.3s;
        }
        
        .favorite-icon.active {
            color: #f1c40f;
        }
        
        .favorite-icon.inactive {
            color: #7f8c8d;
        }
        
        .vocabulary-icon {
            color: #7f8c8d;
            cursor: pointer;
            font-size: 1.2rem;
            margin-left: 10px;
        }
        
        .vocabulary-icon.active {
            color: #f1c40f;
        }
        
        /* 右侧触发区域 - 修改：隐藏触发区域 */
        .sidebar-trigger {
            display: none; /* 修改：隐藏触发区域 */
            position: absolute;
            right: 0;
            top: 20px;
            width: 20px;
            height: calc(100% - 40px);
            background: rgba(52, 152, 219, 0.1);
            z-index: 5;
            transition: background 0.3s;
            display: flex;
            align-items: center;
            justify-content: center;
            cursor: pointer;
            border-radius: 4px 0 0 4px;
        }
        
        .sidebar-trigger:hover {
            background: rgba(52, 152, 219, 0.3);
        }
        
        .sidebar-trigger::after {
            content: "›";
            color: rgba(255, 255, 255, 0.5);
            font-size: 1.2rem;
            font-weight: bold;
            transition: all 0.3s;
            position: absolute;
            top: 50%;
            transform: translateY(-50%);
        }
        
        .sidebar-trigger:hover::after {
            color: rgba(255, 255, 255, 0.9);
            transform: translateY(-50%) scale(1.2);
        }
        
        /* 当侧边栏显示时，隐藏触发区域 */
        .learn-container.with-sidebar .sidebar-trigger {
            display: none;
        }
        
        /* 当侧边栏显示时，调整视频区域宽度 */
        .learn-container.with-sidebar .video-section {
            width: calc(100% - 400px);
            transition: width 0.3s ease;
        }
        
        /* 响应式设计 */
        @media (max-width: 1024px) {
            .subtitles-section {
                width: 350px;
            }
            
            .learn-container.with-sidebar .video-section {
                width: calc(100% - 350px);
            }
        }
        
        @media (max-width: 768px) {
            .learn-container {
                flex-direction: column;
            }
            
            .subtitles-section {
                width: 100%;
                height: 300px;
                position: relative;
                display: none;
            }
            
            .subtitles-section.show {
                display: flex;
            }
            
            .video-section {
                height: 60vh;
            }
            
            .sidebar-trigger {
                display: none;
            }
            
            .learn-container.with-sidebar .video-section {
                width: 100%;
            }
            
            .custom-controls-buttons {
                flex-direction: column;
                align-items: flex-start;
                gap: 15px;
            }
            
            .control-buttons {
                width: 100%;
                justify-content: flex-start;
            }
        }
        
        /* 全屏样式 */
        .learn-container.fullscreen {
            position: fixed;
            top: 0;
            left: 0;
            width: 100vw;
            height: 100vh;
            z-index: 9999;
        }
        
        .learn-container.fullscreen .subtitles-section {
            width: 400px;
        }
        
        /* 防止布局抖动 */
        .video-section > * {
            flex-shrink: 0;
        }

        .video-container:focus {
            outline: none;
        }

        .video-container {
            cursor: pointer;
        }
        
        /* 字幕列表按钮组 */
        .subtitles-buttons {
            display: flex;
            gap: 10px;
            margin-left: auto;
        }
        
        /* 隐藏默认控制条 */
        video::-webkit-media-controls {
            display: none !important;
        }
        
        video::-webkit-media-controls-enclosure {
            display: none !important;
        }
        
        video::-webkit-media-controls-panel {
            display: none !important;
        }
        
        video::-webkit-media-controls-play-button {
            display: none !important;
        }
        
        video::-webkit-media-controls-timeline {
            display: none !important;
        }
        
        video::-webkit-media-controls-current-time-display {
            display: none !important;
        }
        
        video::-webkit-media-controls-time-remaining-display {
            display: none !important;
        }
        
        video::-webkit-media-controls-timeline-container {
            display: none !important;
        }
        
        video::-webkit-media-controls-volume-slider-container {
            display: none !important;
        }
        
        video::-webkit-media-controls-volume-slider {
            display: none !important;
        }
        
        video::-webkit-media-controls-seek-back-button {
            display: none !important;
        }
        
        video::-webkit-media-controls-seek-forward-button {
            display: none !important;
        }
        
        video::-webkit-media-controls-fullscreen-button {
            display: none !important;
        }
        
        video::-webkit-media-controls-rewind-button {
            display: none !important;
        }
        
        video::-webkit-media-controls-return-to-realtime-button {
            display: none !important;
        }
        
        video::-webkit-media-controls-toggle-closed-captions-button {
            display: none !important;
        }
        
        /* 跟读状态指示器 */
        .repeat-status {
            position: absolute;
            top: 20px;
            right: 20px;
            background: rgba(0, 0, 0, 0.7);
            padding: 10px 15px;
            border-radius: 8px;
            font-size: 1.2rem;
            z-index: 10;
            display: none;
        }
        
        .repeat-status.active {
            display: block;
        }
        
        .repeat-status.normal {
            border-left: 4px solid #3498db;
        }
        
        .repeat-status.mute {
            border-left: 4px solid #e74c3c;
        }