/*
 * 비디오 플레이어 + 컨트롤러 전용 스타일.
 * 페이지 전체 레이아웃(video.css)에 얹는 오버레이 형태로 동작한다.
 * 기존 web 프로젝트의 video-page.css 에서 플레이어 영역만 추출.
 */

/* 새 디자인의 video-player-card 가 어두운 배경 + 단일 화면용으로 잡혀 있어
   기존 컨트롤러(컨트롤바 + quick-actions)와 어울리도록 오버라이드. */
.video-player-card {
    background: transparent;
    color: inherit;
    box-shadow: none;
}

.video-stage {
    position: relative;
    overflow: hidden;
    aspect-ratio: 16 / 7.75;
    background: #cfc0a1;
    border-radius: 18px;
}

.video-element {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    background: #cfc0a1;
}

.video-stage::after {
    content: "";
    position: absolute;
    inset: 0;
    background:
        linear-gradient(to bottom, transparent 55%, rgba(32, 25, 18, 0.72) 100%),
        radial-gradient(circle at 65% 42%, rgba(255, 245, 211, 0.18), transparent 30%);
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.25s ease;
}

.center-play-button {
    position: absolute;
    top: 50%;
    left: 50%;
    z-index: 2;
    width: 138px;
    height: 138px;
    display: flex;
    align-items: center;
    justify-content: center;
    transform: translate(-50%, -50%);
    border: 0;
    border-radius: 50%;
    background: rgba(255, 253, 247, 0.88);
    color: #3F563D;
    font-size: 4.9rem;
    box-shadow: 0 18px 42px rgba(44, 35, 25, 0.13);
    cursor: pointer;
    transition: opacity 0.2s ease, transform 0.2s ease, background 0.2s ease;
}

.center-play-button:hover,
.center-play-button:focus-visible {
    transform: translate(-50%, -50%) scale(1.04);
    background: #fffdf7;
    outline: 3px solid rgba(63, 86, 61, 0.28);
    outline-offset: 4px;
}

.center-play-button i { margin-left: 8px; }

.video-control-bar {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 3;
    height: 76px;
    display: flex;
    align-items: center;
    gap: 22px;
    padding: 0 28px;
    color: #fffdf7;
    background: linear-gradient(to top, rgba(38, 31, 23, 0.82), rgba(38, 31, 23, 0.54));
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s ease;
}

.video-stage:hover .video-control-bar,
.video-stage:focus-within .video-control-bar { opacity: 1; pointer-events: auto; }

.video-stage:hover::after,
.video-stage:focus-within::after { opacity: 1; }

@media (hover: none) {
    .video-control-bar { opacity: 1; pointer-events: auto; }
    .video-stage::after { opacity: 1; }
}

.video-control-bar .icon-button,
.video-control-bar .control-play-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: 0;
    padding: 0;
    color: inherit;
    cursor: pointer;
}

.control-play-icon {
    font-size: 2rem;
    line-height: 1;
}

.video-control-bar .video-time {
    flex: 0 0 auto;
    font-size: 1.05rem;
    font-weight: 600;
    color: #fffdf7;
    background: none;
    padding: 0;
    border: 0;
}

.progress-track {
    position: relative;
    height: 8px;
    flex: 1 1 auto;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.52);
    cursor: pointer;
}

.progress-fill {
    position: absolute;
    top: 0;
    left: 0;
    width: 0%;
    height: 100%;
    border-radius: inherit;
    background: #f5f0e4;
}

.progress-dot {
    position: absolute;
    top: 50%;
    left: 0%;
    width: 22px;
    height: 22px;
    transform: translate(-50%, -50%);
    border-radius: 50%;
    background: #fffdf7;
    box-shadow: 0 0 0 4px rgba(255, 255, 255, 0.24);
}

.control-icons {
    display: inline-flex;
    align-items: center;
    gap: 18px;
    font-size: 1.65rem;
}

/* 추가 quick-actions (다시보기, 음량) 영역 — 비디오 카드 아래 */
.video-quick-actions {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 22px;
    margin-top: 18px;
}

.volume-group {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 76px 76px;
    gap: 10px;
    min-width: 0;
}

.video-quick-actions .quick-button {
    min-height: 76px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    border: 1px solid rgba(129, 107, 76, 0.22);
    border-radius: 12px;
    background: rgba(255, 253, 247, 0.92);
    color: #3F2E1E;
    font-size: clamp(1.05rem, 1.4vw, 1.25rem);
    font-weight: 700;
    letter-spacing: -0.03em;
    box-shadow: 0 8px 18px rgba(80, 63, 42, 0.06);
    cursor: pointer;
    transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

.video-quick-actions .quick-button:hover,
.video-quick-actions .quick-button:focus-visible {
    transform: translateY(-2px);
    border-color: rgba(63, 86, 61, 0.42);
    outline: 3px solid rgba(63, 86, 61, 0.18);
    outline-offset: 3px;
    box-shadow: 0 14px 28px rgba(80, 63, 42, 0.11);
}

.video-quick-actions .quick-button i {
    color: #3F563D;
    font-size: 1.6rem;
}

.video-quick-actions .quick-button.is-active {
    border-color: rgba(63, 86, 61, 0.6);
    background: #fffdf7;
}

.volume-step {
    padding: 0;
    gap: 0;
}

.volume-step i { font-size: 2rem; }

@media (max-width: 860px) {
    .video-stage { aspect-ratio: 16 / 10; }
    .center-play-button { width: 100px; height: 100px; font-size: 3.65rem; }
    .video-control-bar { height: 64px; gap: 12px; padding: 0 16px; }
    .control-icons { gap: 10px; font-size: 1.3rem; }
    .video-control-bar .video-time { font-size: 0.92rem; }
    .video-quick-actions { grid-template-columns: 1fr; gap: 12px; }
    .video-quick-actions .quick-button { min-height: 64px; font-size: 1.05rem; }
}

@media (max-width: 560px) {
    .video-stage { aspect-ratio: 4 / 3; }
    .progress-track { display: none; }
    .control-icons i:nth-child(2) { display: none; }
}
