.livekit-app {
   
}

#join-livestream {
    position: absolute;
    top: 50%;
    left: 50%;
    z-index: 1;
    transform: translate(-50%, -50%);
}

.single-videos .version-v1 #remote-video-container .videos_player {
    margin-bottom: 0;
}

#remote-video-container > .video-js {
	    padding-top: 56.25%;
}

#remote-video-container {
    position: relative;
}

.live-wabcam {
    margin-block-end: 20px;
}

.host-wapper {

    margin-bottom: 20px; 
}

.video-viewer-holder .vjs-loading-spinner h6 {
    position: absolute;
    width: 200px;
    text-align: center;
    bottom: -48px;
    left: 18px;
    margin-left: -100px;  
}

#stop-webcam-live {
    display: none;
}

#get_stream_key {
    margin-bottom: 20px;
}

.webcam-player {
    position: relative;
}

.webcam-player.open #livekit-video {
    min-height: 400px;
    display: block;
    padding: 20px;
}

.webcam-player.open .webcam-player-inner {
    margin: 5% auto 0;
    position: relative;
} 

.webcam-player-inner #emoji-reactions-total , .webcam-player-inner #chat-messages{
    display: none;
}

.webcam-player.open .webcam-player-inner #emoji-reactions-total , .webcam-player.open .webcam-player-inner #chat-messages {
    display: block;
}

#stream-app {
    position: relative;
}

.player-action {
    position: absolute;
    top: 10px;
    z-index: 1;
    right: 10px;
    display: flex;
    align-items: center;
    gap: 10px;
}

#toggle-audio {
    display: none;
}

.player-action button {
    background: var(--main);
    border-radius: 100%;
    color: #ffffff;
    border: 0;
    width: 30px;
    height: 30px;
    line-height: 30px;
      display: flex;
    align-items: center;
    justify-content: center;
}

.webcam-action {
    display: none;  
    gap: 10px;
    margin-block-end: 20px;
    position: absolute;
    right: 10px;
    top: 10px;
    align-items: center;
}

.action_inner_videos {
    display: none;
}

#videos_player .action_inner_videos {
    display: block;
}



#videos_player .action_inner_videos #chat-container {
    bottom: 30px;
}

#videos_player .action_inner_videos #chat-container #chat-messages {
    display: block;
}

.video-js .vjs-big-play-button {
    z-index: 999;
}

.video-mini .jws_player .action_inner_videos {
    display: none !important;
}

@media (max-width: 767px) {
    #videos_player  #emoji-reactions-total button img {
        width: 17px;
    }
    #videos_player #emoji-reactions-total {
        top:10px;
        left: 10px;
    }
    #videos_player #chat-messages {
        width: 140px;
        margin-bottom: 0;
    }
    #videos_player  #chat-container {
       padding-bottom: 0;
        padding-right: 0; 
    }
}

.webcam-action button {
    background: var(--main);
    border-radius: 100%;
    color: #ffffff;
    border: 0;
    width: 30px;
    height: 30px;
    line-height: 30px;
    position: relative;
    text-align: center;
    display: flex;
    align-items: center;
    justify-content: center;
}

.webcam-action button.disabled:after {
    content: "";
    position: absolute;
    width: 18px;
    height: 1px;
    background: currentColor;
    transform: rotate(-45deg);
    top: 15px;
    left: 7px;
}



.webcam-action button svg {
    font-size: 20px;
    fill: #ffffff;
    width: 1em;
    height: 1em;
    display: block;
}

.player-action #toggle-audio.muted i:before  {
         content: '\f5a6';
}

.webcam-player.open .webcam-action  {
      display: flex;
}



/* Chat */

#livestream-container {
    width: 800px;
    max-width: 100%;
    background: white;
    padding: 10px;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
    display: flex;
    flex-direction: column;
}

#livekit-video {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    background-color: var(--background-item);
    margin-bottom: 20px;
    border-radius: 10px;
    display: none;
}

#chat-container {

    position: absolute;
    padding: 20px;
    border-radius: 10px;
    width: 100%;
    bottom: 0;
}

#stream-app.open #chat-input {
  display: flex;
}

#end-room-btn {
    display: none;
}

#stream-app.open + #end-room-btn {
    display: block;
}

#chat-messages {
  overflow: auto;
  scrollbar-width: none; /* Firefox */
  -ms-overflow-style: none;  /* Internet Explorer 10+ */
}

#chat-messages::-webkit-scrollbar {
  display: none; /* Chrome, Safari, Opera */
}


#chat-messages {
    flex: 1;
    overflow-y: auto;
    width: 250px;
    animation: fadeInUp 0.4s both;
    display: none;
    max-height: 200px;
    margin-bottom: 10px;
    backdrop-filter: blur(1px);
    margin-left: auto;
}

#chat-messages > div {
 display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 5px;
    font-size: 14px;
    line-height: 18px;
    position: relative;
    background: rgba(0, 0, 0, 0.2);
    color: #ffffff;
    padding: 5px;
    border-radius: 15px;
}

#chat-messages > div.host-message:before  {
    background-color: #25bb25;
    color: #ffffff;
    font-size: 10px;
    width: 15px;
    height: 15px;
    border-radius: 100%;
    font-family: "jws_icon";
    text-align: center;
    line-height: 15px;
    position: absolute;
    z-index: 1;
    left: 20px;
    content: '\e837';
}

#chat-messages img {
    width: 30px;
    height: 30px;
    border-radius: 100%;   
}
#chat-messages > div > div {
        flex: 1;
}
#chat-messages strong {
    display: block;
}

#chat-input {
    display: flex;
    width: 100%;
    z-index: 1;
    display: none;
}

.chat-input {
    flex: 1;
    position: relative;
}

#chat-message {
    background: rgba(0, 0, 0, 0.4);
    border-radius: 30px;
    border: 1px solid #b1b1b1;
    color: #fff;
    backdrop-filter: blur(1px);
    padding-right: 50px;
}

#send-message {
    background: var(--main);
    color: var(--main);
    border: 1px solid;
    padding: 5px 7px;
    cursor: pointer;
    border-radius: 100%;
    width: 35px;
    height: 35px;
    line-height: 35px;
    position: absolute;
    right: 7px;
    top: 6.5px;

}

#send-message svg {
 fill: #ffffff;
    font-size: 23px;
    width: 1em;
    height: 1em;
}

#emoji-picker {
    display: flex;
    gap: 5px;
    margin-left: 10px;
}

.emoji {
    background: none;
    border: none;
    font-size: 20px;
    cursor: pointer;
}

#emoji-floating-container {
    position: absolute;
    bottom: 60px;
    right: 0;
    pointer-events: none;
    z-index: 9999;
    width: 300px;
}

.emoji-float {
    position: absolute;
    bottom: 0;
    font-size: 32px;
    opacity: 1;
    animation: floatUp 1.5s ease-out forwards;
    width: 30px;
    height: 30px;
}

button.emoji-btn img {
    width: 35px;
}
.emoji-reactions-wap {
    position: relative;
    padding-left: 10px;
}
.emoji-reactions-wap > button {
    background-color: var(--main);
    border: 1px solid var(--main);
    border-radius: 100%;
    width: 48px;
    height: 48px;
    font-size: 22px;
    position: relative;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
}

.emoji-reactions-wap:hover #emoji-reactions {
    opacity: 1;
    pointer-events: auto;
    transform: translateY(0px);
}

#emoji-reactions-total  {
    position: absolute;
    left: 20px;
    top: 50px;
    z-index: 1;
}
#emoji-reactions-total button {
    display: flex;
    background: transparent;
    border: 0;
    text-align: center;
    flex-direction: column;
    align-items: center;
    gap: 2px;
}

#emoji-reactions-total button img {
    width: 40px;
}

#emoji-reactions-total button .count {
   text-align: center;
}

#emoji-reactions {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-direction: column;
    position: absolute;
    bottom: 100%;
    left: 16px;
    padding-bottom: 4px;
    transition: 0.3s all;
    opacity: 0;
    pointer-events: none;
    transform: translateY(10px);
}

#emoji-reactions button {
    background: transparent;
    border: 0;
    padding: 0;
}

@keyframes floatUp {
    0% {
        transform: translateY(0) scale(1);
        opacity: 1;
    }
    50% {
        transform: translateY(-100px) scale(1.2);
        opacity: 0.8;
    }
    100% {
        transform: translateY(-200px) scale(1);
        opacity: 0;
    }
}



@media(max-width:767px) {
    
   #remote-video-container > .video-js {
       height: 80vh;
       padding: 0;
   } 
   
   #chat-messages {
    max-height: 100px;
   }
   #chat-messages > div {
        gap: 6px;
        margin-bottom: 10px;
        font-size: 12px;
        line-height: 15px;
   }
   #chat-messages strong {
    margin-top: 0;
   }
   #emoji-reactions-total button img {
    width: 30px;
   }
   #emoji-reactions-total button {
     font-size: 12px;
   }
   button.emoji-btn img {
        width: 27px;
   }
   #emoji-reactions {
    gap: 5px;
   }
   
   #chat-message {
        min-height: 40px;
   }
   #send-message {
        top: 4.5px;
        width: 30px;
        height: 30px;
        line-height: 30px;
   }
   #send-message svg {
    font-size: 19px;
   }
   .emoji-reactions-wap > button {
        width: 40px;
        height: 40px;
   }
   
}