/*Video Category List*/
.video_list .item .thumb{
    position: relative;
    overflow: hidden;
    border-radius: 10px;
    -webkit-border-radius: 10px;
    height: 195px;
    cursor: pointer;
    transition: all .2s ease-in-out;
    display: flex;
    align-items: center;
    justify-content: center;
}
.video_list .item .thumb.small{
    height: 156px;
}
.video_list .item .thumb:before{
    content: "";
    background: radial-gradient(ellipse, rgba(0,0,0,0.5) 5%, transparent 60%);
    width: 120%;
    position: absolute;
    height: 40%;
    bottom: -20%;
    left: -40%;
    transform: rotate(20deg);
}
.video_list .item .thumb .tag{
    background: var(--warning_color);
    position: absolute;
    padding: 2px 3px 2px 3px;
    border-radius: 3px;
    -webkit-border-radius: 3px;
    top: 5px;
    left: 5px;
    color: #000;
    font-size: calc(var(--font_sm) - 2px);
    line-height: calc(var(--font_sm) - 2px);
    font-weight: 500;
}
.video_list .item .thumb img{
    width: 100%;
    min-height: 100%;
    object-fit: cover;
    transition: all 0.2s ease-in-out;
}
.video_list.hover .item .thumb:hover{
    border-radius: 2px;
    -webkit-border-radius: 2px;
}
.video_list .item .thumb:hover img{
    height: 105%;
}
.video_list .item:hover .tag:before {
    opacity: 1;
    left: 150%;
}
.video_list .item .thumb svg path{
    fill: var(--main_color);
}
.video_list .item .thumb .b_if{
    position: absolute;
    padding: 0px 5px 0px 5px;
    width: 100%;
    bottom: 5px;
}
.video_list .item .thumb .b_if .video_time{
    background: rgba(0,0,0,.7);
    font-size: var(--font_sm);
    line-height: var(--font_sm);
    padding: 0px 3px 0px 3px;
    text-overflow: ellipsis;
    color: #FFF;
    border-radius: 2px;
    -webkit-border-radius: 2px;
}
.video_list .item .thumb .video_box{
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0px;
    left: 0px;
    background: unset;
    backdrop-filter: blur(20px) brightness(0.8);
    -webkit-backdrop-filter: blur(20px) brightness(0.8);
    display: flex;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: all 0.5s ease-in-out;
}
body[device="pc"] .video_list .item .thumb:hover .video_box{
    opacity: 1;
    visibility: visible;
}
.video_list .item .thumb .video_box video{
    height: 100%;
    width: auto;
    max-width: 200%;            
}
.video_list .item .thumb .video_box .controls{
    position: absolute;
    width: 100%;
    bottom: 0px;
    left: 0px;
}

.video_list .item .thumb .video_box .controls{
    display: flex;
    justify-content: space-between;
}

.video_list .item .thumb .video_box .controls .v_pr{
    height: 3px;
    position: absolute;
    bottom: 1px;
    display: flex;
    align-items: center;
    width: 100%;
}
.video_list .item .thumb .video_box .controls .v_pr .v_pl{
    height: 2px;
    width: 100%;
    background: rgba(0, 0, 0, .5);
    position: relative;
}
.video_list .item .thumb .video_box .controls .v_pr .v_pl .v_pled{
    position: absolute;
    height: 100%;
    left: 0px;
    top: 0px;
    background: rgba(255, 255, 255, .5);
    transition: all .1s ease-out;
    width: 0%;
}

.video_list .item .thumb .video_box .controls .btn_play .time{
    font-size: var(--font_sm);
    line-height: var(--font_sm);
    font-weight: 500;
    color: #FFF;
}

.video_list .item .thumb [v_modal_sc] {
    position: absolute;
    top: 0px;
    width: 100%;
    height: calc(100% - 35px);
    left: 0px;
    z-index: 1;
}


/*Video Modal and Playing*/
.video_modal{   
    --video_sidebar_w: 0px;
    --video_frame_w: calc(100% - var(--video_sidebar_w));
    --item_h:130px;
    position: fixed;
    position: fixed;
    inset: 0px;
    z-index: 9999999;
    display: none;
}
.video_modal .video_sidebar{
    display: none;
    transition: all .3s ease-in-out;
}
.video_modal.sidebar_show{
    --video_sidebar_w: 400px;
}
.video_modal.sidebar_show .video_sidebar{
    display: block;
}

@media only screen and (max-width: 500px) {
    .video_modal.sidebar_show{
        --video_sidebar_w: 250px;
        --item_h:120px;
    }
}


body.video_modal_show .video_modal{
    display: inline-flex;
}
body.video_modal_show{
    overflow: hidden;
}
body.video_modal_show header,
body.video_modal_show main,
body.video_modal_show footer{
    display: none;
}



.video_frame{
    width: var(--video_frame_w);
    overflow: hidden;
    position: relative;
    transition: all .3s ease-in-out;
}
.video_frame svg path{
    fill: var(--icon_color);
}
.video_frame .btn_close{
    position: absolute;
    top: 20px;
    left: 20px;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    -webkit-border-radius: 50%;
    background: rgba(0,0,0,.18);
    border: .5px solid var(--icon_border_color);
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    z-index: 15;
}

.video_frame .btn_close:hover{
   background: var(--icon_bg_hover); 
}
.video_frame .btn_close:hover svg path{
   fill: var(--icon_hover); 
}
.video_frame .slide_box{
    position: relative;
    width: 100%;
    height: 100%;
}
.video_frame .video_box{
    position: absolute;
    background: unset;
    width: 100%;
    height: 100%;    
    justify-content: center;
    display: none;
}

.video_frame .video_box.active{
    display: flex;
}
.video_frame .video_box.active.next{
    animation: up .2s ease-in-out;
}
.video_frame .video_box.active.prev{
    animation: down .2s ease-in-out;
}

.video_frame .video_box video{
    height: calc(100% - 45px);
    width: 100%;
    z-index: 10;
}
.video_frame .video_box .thumb{
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0px;
    left: 0px;
    z-index: 5;
}

.video_frame .video_box .thumb img{
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.video_frame .video_box .thumb:before{
    content:"";
    width:100%;
    height:100%;
    position:absolute;
    top:0px;
    left:0px;
    backdrop-filter: blur(25px) brightness(0.35);
    -webkit-backdrop-filter: blur(25px) brightness(0.35);
}

.video_frame .video_box .controls{
    position: absolute;
    width: 100%;
    bottom: 0px;
    left: 0px;
    background: rgba(0, 0, 0, .4);
    display: flex;
    justify-content: space-between;
    height: 45px;
    align-items: center;
    box-shadow: 0px 0px 10px #000;
    backdrop-filter: blur(20px) brightness(0.5);
    -webkit-backdrop-filter: blur(20px) brightness(0.5);
    z-index: 15;
}
.video_frame .video_box .controls svg path,
.video_frame .video_box .controls svg rect{
    fill: #FFF !important;
}

.video_frame .video_box .controls .v_pr{
    --pl_h:8px;
    height: 10px;
    position: absolute;
    top: -6px;
    display: flex;
    align-items: center;
    width: 100%;
    opacity: 0.5;
    transition: all .2s ease-in-out;
}
.video_frame .video_box .controls .v_pr .v_pl{
    height: calc(var(--pl_h) / 2);
    width: 100%;
    background: rgba(255, 255, 255, .3);
    position: relative;
}
.video_frame .video_box .controls .v_pr:hover:hover{
    opacity: 1;
}
.video_frame .video_box .controls .v_pr:hover .v_pl{
    height: var(--pl_h);
}            
.video_frame .video_box .controls .v_pr .v_pl .v_pled:after{
    --o_w:6px;
    background: #FFF;
}
.video_frame .video_box .controls .v_pr .v_pl .v_pled:before{
    --o_w:12px;
    background: rgba(255, 255, 255, .3);
}
.video_frame .video_box .controls .v_pr .v_pl .v_pled:before,
.video_frame .video_box .controls .v_pr .v_pl .v_pled:after{
    --c_w:calc(var(--pl_h) + var(--o_w));
    content: "";
    display: none;
    position: absolute;
    width: var(--c_w);
    height: var(--c_w);
    border-radius: 50%;
    -webkit-border-radius: 50%;
    top: calc(var(--o_w) / -2);
    right: calc(var(--c_w) / -2);                 
}
.video_frame .video_box .controls .v_pr:hover .v_pled:before,
.video_frame .video_box .controls .v_pr:hover .v_pled:after{
    content: "";
    display: block;
}

.video_frame .video_box .controls .v_pr .v_pl .v_pled{
    position: absolute;
    height: 100%;
    left: 0px;
    top: 0px;
    background: rgba(255, 255, 255, .5);
    transition: all .1s ease-out;
    width: 0%;
    z-index: 15;
}
.video_frame .video_box .controls .right{
    display: flex;
    cursor: pointer;
}
.video_frame .video_box .controls .right:hover svg path{
    fill: rgba(255, 255, 255, .8);
}

.video_frame .video_box .controls .btn_play .time{
    font-size: var(--font_sm);
    line-height: var(--font_sm);
    font-weight: 500;
    color: #FFF;
}
.video_frame .video_box .content{
    position: absolute;
    padding: 0px 10px 10px 10px;
    bottom: 45px;
    left: 0px;
    z-index: 15;
}

.video_frame .video_box .content .post{
    display: inline-flex;
    margin-bottom: 8px;
    background: rgba(0,0,0,.18);
    padding: 5px;
    border-radius: 5px;
    margin-left: -5px;
    align-items: center;
    max-width: 95%;
}
.video_frame .video_box .content .post svg{
    width: 18px;
    height: 18px;
}
.video_frame .video_box .content .post svg path{
    fill: #FFF;
}
.video_frame .video_box .content .post .icon{
    width: 24px;
    height: 24px;
    background: var(--gold_color);
    display: flex;
    justify-content: center;
    align-items: center;
    border-radius: 5px;
    margin-right: 5px;
}

.video_frame .video_box .content .post .p_hf{
    display: inline-flex;
    width: calc(100% - 30px);
}

.video_frame .video_box .content .post a{
    color: #fff;
    font-size: var(--font_sm);
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 1;
    -webkit-box-orient: vertical;
}

.video_frame .video_box .btn_plays{
    position: absolute;
    top: 50%;
    left: 50%;
    width: 8%;
    transform: translateX(-50%) translateY(-50%);
    transition: all .2s ease-in-out;
    cursor: pointer;
    opacity: 0.7;
    visibility: visible;
    min-width: 100px;
    z-index: 12;
}
.video_frame .video_box .btn_plays:hover{
    opacity: 0.9;
}
.video_frame .video_box .btn_plays svg path{
    fill: #FFF;
}
.video_frame .video_box .btn_plays svg{
    width: 100%;
    height: auto;
}

.video_frame .video_box .f_bar{
    position: absolute;
    top: 35%;
    right: 10px;
    display: flex;
    flex-direction: column;
    align-items: center;
    z-index: 15;
}

.video_frame .video_box .playswitch{
    background-color: unset;
    -webkit-backdrop-filter: blur(5px);
    backdrop-filter: blur(5px);
    background: rgba(0,0,0,.18);
    border: 2px solid var(--icon_border_color);
    display: flex;
    flex-direction: column;
    width: 39px;
    height: 90px;
    border-radius: 20px;
    -webkit-border-radius: 20px;
    align-items: center;
    justify-content: space-around;
    overflow: hidden;
}

.video_frame .video_box .playswitch .prev,
.video_frame .video_box .playswitch .next{
    cursor: pointer;
    width: 100%;
    height: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}
.video_frame .video_box .playswitch .prev:hover,
.video_frame .video_box .playswitch .next:hover{
    background: var(--icon_bg_hover);
}
.video_frame .video_box .playswitch .prev:hover svg path,
.video_frame .video_box .playswitch .next:hover svg path{
    fill: var(--icon_hover);
}
.video_frame .video_box .v_sta [action_api]{
    cursor: pointer;
}
.video_frame .video_box .v_sta{
    color: #FFF;
    margin-top: 20px;
    display: flex;
    flex-direction: column;
}
.video_frame .video_box .v_sta > div{
    display: flex;
    align-items: center;
    flex-direction: column;
    margin-top: 20px;
    opacity: 0.8;
    transition: all .2 ease-in-out;
}
.video_frame .video_box .v_sta svg path{
    fill: #FFF;
}
.video_frame .video_box .v_sta > div:hover {
    opacity: 1;
}
.video_frame .video_box .show_list{
    position: relative;
    margin-top: 20px;
    height: 30px;
}
.video_frame .video_box .show_list .btn_show_list{
    position: absolute;
    background: rgba(0, 0, 0, .3);
    -webkit-backdrop-filter: blur(5px);
    backdrop-filter: blur(5px);
    border: solid 1px var(--icon_border_color);
    border-radius: 30px 0px 0px 30px;
    -webkit-border-radius: 30px 0px 0px 30px;
    cursor: pointer;
    width: 55px;
    left: -20px;
    transition: left 1.1s ease-in-out, background .2s ease-in-out;
}
.video_frame .video_box .show_list .btn_show_list:hover{
   background: var(--icon_bg_hover);
}
.video_frame .video_box .show_list .btn_show_list:hover svg path{
    fill: var(--icon_hover);
}
.video_modal.sidebar_show .show_list .btn_show_list{
    left: 50px;
}
.video_sidebar{
    width: var(--video_sidebar_w);
    overflow: hidden;
    border-left: solid 2px rgba(255, 255, 255, .3);
    padding: 10px;
    color: #FFF;
}
.video_sidebar .main{
    position: relative;
    display: flex;
    flex-direction: column;
    height: 100%;
}
.video_sidebar .btn_close{
    position: absolute;
    top: 0px;
    right: 0px;
    cursor: pointer;
    z-index: 1;
}
.video_sidebar .btn_close svg path{
    fill: var(--red_color) !important;
}
.video_sidebar .btn_close svg path{
    fill: rgba(255, 255, 255, 0.6);
}
.video_sidebar .btn_close:hover svg path{
    fill: rgba(255, 255, 255, 1);
}

.video_sidebar .topic{
    border: unset;
}
.video_sidebar .topic:before{
    height: 1px;
    background: var(--main_color);
    top: unset;
    bottom: -1px;
    transform:unset;
}
.video_sidebar .topic span{
    background: unset;
    padding: 2px 10px 2px 0px;
    border-bottom: solid 2px rgba(255, 255, 255, .3);
    color: var(--text_color);
}
.video_sidebar .video_list{
    --col:3;
    --m_r:12px;
    --m_b:12px;
    --sc_x:6;
    --sc_y:19;    
    display: flex;
    flex-wrap: wrap;
    margin-left: calc(var(--m_r) * -1);
    margin-right: -5px;
    padding-right: 5px;                
    max-height: calc(100% - 30px);
    overflow: hidden;
    overflow-y: scroll;
}
.video_sidebar .video_list::-webkit-scrollbar {
  width: 5px;
  cursor: pointer;
}

.video_sidebar .video_list::-webkit-scrollbar-track {
  background: transparent; 
}
 
.video_sidebar .video_list::-webkit-scrollbar-thumb {
    border-radius: 10px;
    -webkit-border-radius: 10px;
    background: rgba(255, 255, 255, .6);
}

.video_sidebar .video_list::-webkit-scrollbar-thumb:hover {
    background: transparent;
}

.video_sidebar .relate_video{
    height: 100%;
}
.video_sidebar .video_list .item{
    width: calc((100% / var(--col)) - var(--m_r));
    height: var(--item_h);
    margin-left: var(--m_r);
    margin-bottom: var(--m_b);
}
.video_sidebar .video_list .item .thumb{
    width: 100%;
    height: 100%;
    font-size: calc(var(--font_sm) - 2px);
    line-height: 18px;
    border: solid 1px rgba(255, 255, 255, .2);
    overflow: hidden;
}
.video_sidebar .video_list .item.active .thumb:after {
    background: unset;
    content: "";
    opacity: 0;
    width: 24px;
    height: 24px;
    background-image: url("../img/playing_effect.png");
    background-size: 24px;
    font-size: 0;
    animation: 2s steps(95,start) .5s infinite p_ying;
    position: absolute;
    top: calc(50% - 24px);
    left: calc(50%);
    transform: translateX(-50%);

}
.video_sidebar .video_list .item.active .thumb:before{
    transform:unset;
    background: unset;
    content: "Đang Phát";
    font-size: calc(var(--font_sm) - 2px);
    backdrop-filter: blur(5px) brightness(0.4);
    -webkit-backdrop-filter: blur(5px) brightness(0.4);
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0px;
    left: 0px;
    display: flex;
    justify-content: center;
    align-items: center;
    padding-top: 20px;
    border-radius: 10px;
}

/*When video action*/
.video_box .controls {
    display: flex;
}

.video_box .controls .btn_play{
    display: flex;
    align-items:center;
}
.video_box .controls .btn_play .icon{
    cursor: pointer;
}
.video_box .controls .btn_play .icon svg,
.video_box .controls .btn_muted svg
{
    display: none;
}

.video_box .controls .btn_play .icon svg:first-child,
.video_box .controls .btn_muted svg:first-child
{
    display: block;
}

.video_box video[playing] ~ .btn_plays{
    opacity: 0;
    visibility: hidden;
}

.video_box video[playing] ~ .controls .btn_play .icon svg:first-child,
.video_box video[playing] ~ .controls .btn_play .icon svg:first-child,
.video_box video[muted] ~ .controls .btn_muted svg:first-child
{
    display: none;
}

.video_box video[playing] ~ .controls .btn_play .icon svg:last-child,
.video_box video[playing] ~ .controls .btn_play .icon svg:last-child,
.video_box video[muted] ~ .controls .btn_muted svg:last-child
{
    display: block;
}

/*Reposive*/
/*col-sm*/
@media only screen and (max-width: 576px) {
    body[device="mobile"] .video_modal .playswitch{
        display: none;
    }
    .video_frame .video_box .controls{
        height: 35px;
    }
    .video_frame .video_box video{
        height: calc(100% - 35px);
    }
    .video_frame .video_box .content{
        bottom: 35px;
    }
}

@keyframes p_ying {
    0% {
        opacity: 1;
    }
    100% {
        opacity: 1;
        background-position-y: -2280px;
    }

}


@keyframes up {
    0% {
        top: 45%;
    }
    100% {
        top:0px;
    }

}

@keyframes down {
    0% {
        top: -45%;
    }
    100% {
        top:0px;
    }

}

/* Nút chia sẻ trong trình phát video: nút + menu (Facebook, Messenger, Sao chép liên kết) mở sang trái nút. */
.video_frame .video_box .v_sta > .v_share_wrap{position:relative;opacity:1}
.video_frame .video_box .v_sta .share{display:flex;flex-direction:column;align-items:center;gap:2px;padding:4px;border:0;background:none;color:#FFF;font:inherit;cursor:pointer;opacity:.8;transition:opacity .2s ease-in-out}
.video_frame .video_box .v_sta .share:hover,.video_frame .video_box .v_sta .share[aria-expanded="true"]{opacity:1}
.video_frame .video_box .v_sta .share:focus-visible{outline:2px solid #FFF;outline-offset:2px;border-radius:6px}
.video_frame .video_box .v_share_menu{position:absolute;right:calc(100% + 8px);top:50%;transform:translateY(-50%);z-index:5;min-width:200px;padding:6px;border-radius:10px;background:rgba(20,20,20,.94);box-shadow:0 8px 24px rgba(0,0,0,.4)}
.video_frame .video_box .v_share_menu[hidden]{display:none}
.video_frame .video_box .v_share_menu button{display:flex;align-items:center;gap:10px;width:100%;min-height:40px;padding:0 12px;border:0;border-radius:6px;background:none;color:#FFF;font-size:14px;text-align:left;white-space:nowrap;cursor:pointer}
.video_frame .video_box .v_share_menu button:hover,.video_frame .video_box .v_share_menu button:focus-visible{background:rgba(255,255,255,.12);outline:none}
.video_frame .video_box .v_share_menu svg path{fill:#FFF}
