/* 自定义视频播放器样式 - video-player.css */
:root {
    --vp-pink: #FB7299;
    --vp-blue: #00A1D6;
}

.video-player-container {
    position: relative;
    width: 100%;
    max-width: 800px;
    margin: 0 auto;
    border-radius: 16px;
    overflow: hidden;
    background: linear-gradient(135deg, #1a1a2e, #16213e);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
    font-family: 'MaokenAssortedSans', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

.video-player-container video {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 16px;
}

/* 海报层 */
.video-poster {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    cursor: pointer;
    z-index: 2;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #1a1a2e;
}

.video-poster img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 16px;
}

.video-poster.hidden {
    display: none;
}

/* 播放按钮 */
.play-button {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 70px;
    height: 70px;
    background: linear-gradient(135deg, var(--vp-pink), var(--vp-blue));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 8px 30px rgba(251, 114, 153, 0.5);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    z-index: 3;
}

.play-button:hover {
    transform: translate(-50%, -50%) scale(1.1);
    box-shadow: 0 12px 40px rgba(251, 114, 153, 0.6);
}

.play-button i {
    color: white;
    font-size: 1.8rem;
    margin-left: 4px;
}

/* 控制栏 */
.video-controls {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.9), transparent);
    padding: 40px 15px 15px;
    display: flex;
    align-items: center;
    gap: 10px;
    opacity: 0;
    transition: opacity 0.3s ease;
    z-index: 4;
}

.video-player-container:hover .video-controls,
.video-player-container.playing .video-controls,
.video-player-container.controls-visible .video-controls {
    opacity: 1;
}

/* 控制按钮 */
.vp-control-btn {
    background: none;
    border: none;
    color: white;
    font-size: 1rem;
    cursor: pointer;
    padding: 8px;
    border-radius: 6px;
    transition: background 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 36px;
    height: 36px;
}

.vp-control-btn:hover {
    background: rgba(255, 255, 255, 0.2);
}

/* 进度条 */
.vp-progress-container {
    flex: 1;
    height: 24px;
    display: flex;
    align-items: center;
    cursor: pointer;
    padding: 8px 0;
}

.vp-progress-bar {
    width: 100%;
    height: 6px;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 3px;
    position: relative;
    overflow: visible;
}

.vp-progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--vp-pink), var(--vp-blue));
    border-radius: 3px;
    width: 0%;
    transition: width 0.1s linear;
    position: relative;
}

.vp-progress-handle {
    position: absolute;
    top: 50%;
    left: 0%;
    transform: translate(-50%, -50%);
    width: 14px;
    height: 14px;
    background: white;
    border-radius: 50%;
    box-shadow: 0 2px 8px rgba(0,0,0,0.3);
    opacity: 0;
    transition: opacity 0.2s;
}

.vp-progress-container:hover .vp-progress-handle {
    opacity: 1;
}

/* 时间显示 */
.vp-time-display {
    color: white;
    font-size: 0.8rem;
    font-family: 'MaokenAssortedSans', 'Monaco', 'Menlo', monospace;
    min-width: 90px;
    text-align: center;
    white-space: nowrap;
}

/* 音量控制 */
.vp-volume-container {
    display: flex;
    align-items: center;
    gap: 6px;
}

.vp-volume-slider {
    width: 70px;
    height: 6px;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 3px;
    cursor: pointer;
    position: relative;
}

.vp-volume-fill {
    height: 100%;
    background: white;
    border-radius: 3px;
    width: 70%;
}

/* 加载指示器 */
.vp-loading {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 50px;
    height: 50px;
    border: 4px solid rgba(255,255,255,0.3);
    border-top-color: white;
    border-radius: 50%;
    animation: vp-spin 0.8s linear infinite;
    z-index: 5;
    display: none;
}

.video-player-container.loading .vp-loading {
    display: block;
}

/* 全屏样式 */
.video-player-container:fullscreen,
.video-player-container:-webkit-full-screen {
    border-radius: 0;
    max-width: 100%;
}

.video-player-container:fullscreen video,
.video-player-container:-webkit-full-screen video {
    border-radius: 0;
}

/* 键盘提示 */
.vp-keyboard-hint {
    position: absolute;
    bottom: 70px;
    right: 15px;
    background: rgba(0,0,0,0.7);
    color: white;
    padding: 8px 12px;
    border-radius: 8px;
    font-size: 0.75rem;
    opacity: 0;
    transition: opacity 0.3s;
    z-index: 10;
    pointer-events: none;
}

.video-player-container:hover .vp-keyboard-hint {
    opacity: 1;
}

@keyframes vp-spin {
    to { transform: translate(-50%, -50%) rotate(360deg); }
}

/* 断网提示覆盖层 */
.vp-network-disconnected {
    display: none;
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.75);
    color: #fff;
    align-items: center;
    justify-content: center;
    z-index: 20;
    font-size: 1rem;
    flex-direction: column;
    gap: 10px;
    pointer-events: none;
}

.vp-network-disconnected i {
    font-size: 2.5rem;
    color: #f59e0b;
    margin-bottom: 4px;
}
