/* Modal Video Player - Frontend Styles */

/* Thumbnail container */
.mvideo-thumbnail {
    position: relative;
    display: inline-block;
    cursor: pointer;
    max-width: 100%;
    line-height: 0;
    border-radius: 6px;
    overflow: hidden;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.mvideo-thumbnail:hover {
    transform: scale(1.02);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

.mvideo-thumbnail img {
    display: block;
    max-width: 100%;
    height: auto;
}

/* Play overlay */
.mvideo-play-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(3, 39, 54, 0.35);
    transition: background 0.2s ease;
}

.mvideo-thumbnail:hover .mvideo-play-overlay {
    background: rgba(3, 39, 54, 0.5);
}

.mvideo-play-btn {
    width: 68px;
    height: 68px;
    background: rgba(0, 155, 224, 0.9);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s ease, transform 0.2s ease;
}

.mvideo-thumbnail:hover .mvideo-play-btn {
    background: #009be0;
    transform: scale(1.1);
}

.mvideo-play-btn svg {
    width: 28px;
    height: 28px;
    fill: #ffffff;
    margin-left: 4px;
}

/* Modal overlay */
.mvideo-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(3, 39, 54, 0.92);
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.mvideo-modal-overlay.mvideo-active {
    opacity: 1;
    visibility: visible;
}

/* Modal container */
.mvideo-modal {
    position: relative;
    width: 90%;
    max-width: 900px;
    background: #032736;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    transform: scale(0.9);
    transition: transform 0.3s ease;
}

.mvideo-modal-overlay.mvideo-active .mvideo-modal {
    transform: scale(1);
}

/* Close button */
.mvideo-close {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 36px;
    height: 36px;
    background: rgba(255, 255, 255, 0.1);
    border: none;
    border-radius: 50%;
    color: #ffffff;
    font-size: 20px;
    cursor: pointer;
    z-index: 10;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s ease;
    line-height: 1;
    padding: 0;
}

.mvideo-close:hover {
    background: rgba(255, 255, 255, 0.25);
}

/* Video element */
.mvideo-modal video {
    display: block;
    width: 100%;
    background: #000;
}

/* Custom controls */
.mvideo-controls {
    display: flex;
    align-items: center;
    padding: 10px 14px;
    background: #032736;
    gap: 10px;
}

/* Play/Pause button */
.mvideo-ctrl-btn {
    background: none;
    border: none;
    color: #ffffff;
    cursor: pointer;
    padding: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 4px;
    transition: background 0.15s ease;
}

.mvideo-ctrl-btn:hover {
    background: rgba(255, 255, 255, 0.1);
}

.mvideo-ctrl-btn svg {
    width: 20px;
    height: 20px;
    fill: #ffffff;
}

/* Progress bar */
.mvideo-progress-wrap {
    flex: 1;
    height: 6px;
    background: rgba(255, 255, 255, 0.15);
    border-radius: 3px;
    cursor: pointer;
    position: relative;
    transition: height 0.15s ease;
}

.mvideo-progress-wrap:hover {
    height: 10px;
}

.mvideo-progress-bar {
    height: 100%;
    background: #009be0;
    border-radius: 3px;
    width: 0%;
    position: relative;
    transition: none;
}

.mvideo-progress-bar::after {
    content: '';
    position: absolute;
    right: -6px;
    top: 50%;
    transform: translateY(-50%);
    width: 12px;
    height: 12px;
    background: #009be0;
    border-radius: 50%;
    opacity: 0;
    transition: opacity 0.15s ease;
}

.mvideo-progress-wrap:hover .mvideo-progress-bar::after {
    opacity: 1;
}

/* Time display */
.mvideo-time {
    color: rgba(255, 255, 255, 0.7);
    font-size: 12px;
    font-family: monospace;
    white-space: nowrap;
    min-width: 90px;
    text-align: center;
}

/* Volume control */
.mvideo-volume-wrap {
    display: flex;
    align-items: center;
    gap: 4px;
}

.mvideo-volume-slider {
    width: 70px;
    height: 4px;
    background: rgba(255, 255, 255, 0.15);
    border-radius: 2px;
    cursor: pointer;
    position: relative;
}

.mvideo-volume-bar {
    height: 100%;
    background: #009be0;
    border-radius: 2px;
    width: 100%;
}

/* Responsive */
@media (max-width: 600px) {
    .mvideo-modal {
        width: 96%;
    }

    .mvideo-controls {
        padding: 8px 10px;
        gap: 6px;
    }

    .mvideo-time {
        font-size: 11px;
        min-width: 70px;
    }

    .mvideo-volume-slider {
        width: 50px;
    }

    .mvideo-play-btn {
        width: 52px;
        height: 52px;
    }

    .mvideo-play-btn svg {
        width: 22px;
        height: 22px;
    }
}
