@import url('https://fonts.googleapis.com/css2?family=Fredoka+One&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Libre+Baskerville:ital,wght@0,400;0,700;1,400&display=swap');


html,body{ height: 100%; }

body{   
    background: #ffc800c7;
    background-size: cover;
    background-position: center;
}


.features-text{ font-family: 'Fredoka One', cursive; }
.timeline{ transform-origin: bottom; }

.rect{
    position: absolute;
    width: 180px;
    height: 180px;
    margin: 10px;
    border-radius: 160px;
    font-size: 2rem;
    text-align: center;
    background: white;
    position: absolute;
    box-shadow: 0px 0 8px 0px rgba(0,0,0,30%)
}
    .rect .img-frame{ 
        width: 180px;
        height: 180px; 
        border-radius: 160px;
        overflow: hidden;
    }

    .rect .first-frame{
        position: absolute;
        left: -15%;
        width: 133%;
    }        

    .img-frame img{ width: 100%; }


@media screen and (max-width: 575.98px) {
    /*2nd place*/
    .rect.rect2{
        left: 169px;
        top: 70%;
        zoom: 0.7;
    }

    .rect.rect3{
        zoom: 0.7;
        top: 70%;
    }
}
 
.player-name{
    position: relative;
    left: 0;
    background: #7022F9;
    font-size: 1.8rem;
    color: white;
    padding: 6px;
    border-radius: 6px;
}


.progress.question-countdown{
    opacity: 1;
    height: 50px;
}


/*Progress Circle*/
.progressbar-circle{
    width: 200px;
    height: 200px;
    border-radius: 100%;
    position: relative;
}   

    .progressbar-circle::before, .progressbar-circle::after {
        box-sizing: inherit;
        content: "";
        position: absolute;
        width: 100%;
        height: 100%;
        border-radius: 100%;
    }
    .progressbar-circle:hover {
        color: yellow;
    }
    .progressbar-circle::before, .progressbar-circle::after {
        top: 0;
        left: 0;
    }
    .progressbar-circle::before {
        border: 10px dotted transparent;
    }
    .progressbar-circle:hover::before {
        border-top-color: yellow;
        border-right-color: yellow;
        border-bottom-color: yellow;
        transition: border-top-color 0.15s linear, border-right-color 0.15s linear 0.1s, border-bottom-color 0.15s linear 0.2s;
    }
    .progressbar-circle::after {
        border: 0 solid transparent;
    }
    .progressbar-circle:hover::after {
        border-top: 10px dotted yellow;
        border-left-width: 2px;
        border-right-width: 2px;
        transform: rotate(270deg);
        transition: transform 0.4s linear 0s, border-left-width 0s linear 0.35s;
    }
    
/*textarea*/
.textarea{
    position: relative;
    background: transparent;
    width: 100%;
    height: calc(100%*.8);
    display: block;
    overflow: hidden;
    color: white;
    border: none;
    background: rgb(255,255,255,.2);
    resize: none;
}

    .textarea .textarea-msg{
          position: absolute;
    }

/*Badge*/
.star-badge{
      background: #FFDC01;
      color: #F18213;
      width: 40px;
      height: 40px;
      position: relative;
      text-align: center;
      transform: rotate(20deg);
      border-radius: 6px;
}

    .star-badge:before {
      content: "";
      position: absolute;
      top: 0;
      left: 0;
      height: 40px;
      width: 40px;
      background: #FFDC01;
      transform: rotate(135deg);
      border-radius: 6px;
    }

/*Border*/
.border-dot{ border-style: dotted !important}

/*Confetti*/
#confetti-canvas{
    position: absolute;
    top: 0;
    display: none;
}

/*Bg Radial Line*/
.bg-radial-line{
    background: url('../img/bg-line.svg');
    background-repeat: no-repeat;
    width: 60vw;
    height: 60vw;
    left: 0; 
    right: 0;
    margin: auto;
    position: absolute;
}

@media (max-width: 575.98px) {
    .bg-radial-line{
        display: none;
    }
}

/*Spotlight*/
.cur{
        width: 100%;
        height: 100%;
        position: absolute;
        background: #0000005c;
        z-index: 2;
        mix-blend-mode: hard-light;
        opacity: 0;

    }

    .spot{
        width: 350px;
        height: 350px;
        opacity: 0;
        border-radius: 100%;
        background: #ffffff;
        box-shadow: 1px 1px 20px 20px white;
        mix-blend-mode: overlay;
        position: absolute;
        left: 0; right:0;
        margin: auto;
    }

/*Quiz Logo*/
.quiz-logo{
    position: relative;
}

    .quiz-logo .quiz-logo-shape img{ width: 50px;}
    .quiz-logo .quiz-text{ 
        font-family: 'Fredoka One', cursive;
        color: #000;
        font-size: 10rem;
        transform: translateY(20px);
        position: absolute;
        bottom: 0;
    }

        .quiz-logo .quiz-text.quiz-text-sm{ 
            font-size: 2rem;
            bottom: 0;
    }


.quiz-logo-sm{
    width: 90px;
    height: 70px;
}

.quiz-logo-sm .quiz-logo-shape img:nth-child(1){
        position: absolute;
        left: -56px;
    }
.quiz-logo-sm .quiz-logo-shape img:nth-child(2){
    position: absolute;
    right: -55px;
}

.quiz-logo-sm .quiz-logo-shape img:nth-child(3){
    position: absolute;
    left: -36px;
}


.quiz-logo-shape{ 
    position: relative; 
    z-index: 1;
}
    .quiz-logo .quiz-logo-shape img:nth-child(1){
        position: absolute;
        left: -56px;
    }
    .quiz-logo .quiz-logo-shape img:nth-child(2){
        position: absolute;
        right: -55px;
    }

    .quiz-logo .quiz-logo-shape img:nth-child(3){
        position: absolute;
        left: -36px;
    }



/*Ranking*/
.ranking-list .player-img{ width: 45px; }
.ranking-list .self-player{
    background: #fff;
}

.ranking-list .player_position{
    font-family: 'Fredoka One';
    font-size: 2.5rem;
}
.ranking-list .ranking-player-name{
    font-family: 'Fredoka One';
    font-size: 2rem;
}


.ranking-list .player-total-score{
    font-family: 'Fredoka One';
    font-size: 2rem;
}

/*student-bubble-list*/
.student-bubble{ transform-origin: center;}

/*UI*/
.bg-line{
    background: url('../img/bg-line.svg');
    background-size: cover;
    background-position: center;
    opacity: .2;
    z-index: -100;
}

/*Score Label*/
.score-label{
    font-family: 'Fredoka One', cursive;
    font-size: 3rem;
    position: relative;
    font-weight: bold;
    background: #fff;
    color: #000;
    padding: 6px 10px;
    border-radius: 20px;
}

    @media (max-width: 575.98px) {
        .score-label{
            font-size: 2.3rem;
        }
    }
    .score-label .score-img{ 
        width: 40px;
    } 
    .score-label .score-text{
        padding: 0 45px;
    }

    @media (max-width: 575.98px) {
        .score-label .score-text{
            padding: 0 10px;
        }
    }  

.question-label-style{
    font-family: 'Fredoka One', cursive;
    font-size: 3rem;
    position: relative;
    font-weight: bold;
    background: #fff;
    color: #000;
    padding: 6px 10px;
    border-radius: 20px;
}



/*Question Counter*/
.question-counter{
    font-family: 'Fredoka One', cursive;
    font-size: 3rem;
    position: relative;
    font-weight: bold;
    background: #fff;
    color: #000;
    padding: 6px 10px;
    border-radius: 20px;
}

    .question-counter .counter-img{ 
        width: 40px;
    }
    .question-counter .counter-text{
        padding: 0 45px;
    }


.timer-label{
    width: auto;
    height: auto;
    background: #77BDEE;
    border: 3px solid #fff;
    border-radius: 20px;
    padding: 4px 30px;
    color: #fff;
    font-size: 25px;
}


.q-label{
    font-family: "Libre Baskerville", serif;
    font-weight: 700;
    font-size: 4.5rem;
    line-height: 1.3;
    background: #fff;
    padding: 20px;
    border-radius: 20px;
    border: 8px solid #6bbde3;
}

    @media (max-width: 575.98px) {
        .q-label{
            font-size: 3rem;
        }
    }



.student-bubble-list .student-bubble{}



/*Button*/
.btn-icon-text{
    display: flex;
    align-items: center;
}

.btn-fonts-family{
    font-family: 'Fredoka One';
}

/* 闪烁按钮 */
.flashing-button {
  animation: flash 1s infinite alternate;
}

@keyframes flash {
  from {
    opacity: 1;
  }
  to {
    opacity: 0;
  }
}

/* 悬停时停止动画 */
.flashing-button:hover {
  animation-play-state: paused;
}

/*Answer Button*/
.answer-btn-gp.pointer-event-none{
    pointer-events: none;
}

.answer-btn-gp{
    position: relative;
    z-index: 1;
}

.answer-btn-gp .card{ 
    cursor: pointer;
    overflow: auto;
    max-height: 170px;
    min-height: 130px;
    display: flex;
    flex-direction: row;
    align-items: center;
}

    /* 所有手機版 */
    @media (max-width: 575.98px) {
        .answer-btn-gp .card{
            min-height: 45px;
        }
        .answer-btn-gp .card .card-body .card-text{
            font-size: 1.5rem;
            margin: 0;
        }
    }

    .answer-btn-gp .answer-btn.card-dim{
        filter: brightness(.6);
    }

    .answer-btn-gp .answer-btn.red{
        background: #F52425;
        color: #fff;
        box-shadow: 0px 0px 0px 7px white;
    }

    .answer-btn-gp .answer-btn.yellow{
        background: #ffa400;
        color: #fff;
        box-shadow: 0px 0px 0px 7px white;
    }

    .answer-btn-gp .answer-btn.green{
        background: #00af80;
        color: #fff;
        box-shadow: 0px 0px 0px 7px white;
    }

    .answer-btn-gp .answer-btn.blue{
        background: #2F8CD3;
        color: #fff;
        box-shadow: 0px 0px 0px 7px white;
    }
 
    .answer-btn-gp .correct-sign{
        position: absolute;
        width: 65px;
        height: 100%;
        right: 3%;
        top: 0;
    }

    .answer-btn-gp .answer-col:hover .card {
        animation: rotateX360 0.5s ease-in-out;
        transform-style: preserve-3d;
        backface-visibility: visible;
    }
    @keyframes rotateX360 {
    from {
        transform: rotateX(0deg);
    }
    to {
        transform: rotateX(360deg);
    }
    }



/*Prize Ledder*/
.prize-ledder .ledder{
    width: 200px;
}

    .prize-ledder .prize-badge{}



/*Countdown Number*/
.countdown-circle{
    font-family: 'Fredoka One', cursive;
    color: #FFC21A;
    background: rgb(255 255 255 / 20%);
    width: 300px;
    height: 300px;
    border-radius: 100%;
}

    .countdown-circle .num{
        font-size: 150px;
    }


.dance-player{
  display: inline-block;
  animation: dance 1s linear infinite;
  transform-origin: bottom center;
}

@keyframes dance {
  0%  { transform: translate(0%,0%) rotateZ(0deg) }
  25% { transform: translate(0%,10%) rotateZ(20deg) }
  50% { transform: translate(0%,0%) rotateZ(0deg)}
  75% { transform: translate(0%,10%) rotateZ(-20deg) }
  100% { transform: translate(0%,0%) rotateZ(0deg)}
}


/*Timer Animation*/
/* The animation code */
@keyframes timer-rotate {
  0%   {transform: rotate(0deg);}
  33%   {transform: rotate(180deg);}
  100% {transform: rotate(360deg);}
}

/* The element to apply the animation to */
.timer-animation{
  animation-name:  timer-rotate;
  animation-duration: 3s;
  animation-iteration-count: infinite;
}


/*Card*/
.card-text{ 
    font-size: 3.2rem;
    font-family: 'Fredoka One';
}



#teacher-control-menu{
    width: 200px;
    height: 100vh;
    z-index: 10;
    background: #00000087;
    transform: translateX(-200px);
    display: none;

}



#teacher-control-menu-button{
    display: block;
    cursor: pointer;
    position: absolute;
    z-index: 10;
    left: 10px;
    top: 6px;
}

#close-teacher-control-menu-button{
    display: block;
}

@media (min-width: 767.98px) {
    #teacher-control-menu{
        display: block;
        background: #00000087;
        transform: translateX(0) !important;
        display: block !important;
    }

    #teacher-control-menu-button{
        display: none;
    }

    #close-teacher-control-menu-button{
        display: none;
    }

}

/*Divider*/
.divider-text{
    font-weight: 800;
    font-family: 'Fredoka One';
    font-size: 1.6rem;
    position: relative;
}

.divider-text:before {
    content: "";
    width: 13px;
    background: black;
    height: 4px;
    position: absolute;
    left: 0;
    bottom: 0;
    top: 50%;
    transform: translateX(-130%);
}

.divider-text:after {
    content: "";
    width: 13px;
    background: black;
    height: 4px;
    position: absolute;
    right: 0;
    bottom: 0;
    top: 50%;
    transform: translateX(130%);
}


/*Teacher Input*/
textarea.choicetext{
    font-size: 1.8rem;
}


.studentcountofchoice1,.studentcountofchoice2,.studentcountofchoice3,.studentcountofchoice4{
    font-size: 1.6rem;
}


.currentquestion_index,.totalquestion,.q-count-slash{
    font-size: 3.5rem;
    font-weight: bold;
    font-family: 'Fredoka One',sans-serif;
}

@media (max-width: 575.98px) {
    .currentquestion_index,.totalquestion,.q-count-slash{
        font-size: 2.3rem;
    }
}

.client-count-div{
    font-size: 3.5rem;
}
@media (max-width: 575.98px) {
    .client-count-div{
        font-size: 2.3rem;
    }
}

#question.textarea{
    font-size: 2.5rem;
}


/*New Background Color*/
.bg-success-subtle {
    background-color: #d1e7dd !important;
}

.text-success-emphasis {
    color: #0a3622 !important;
}


/*Student List of Choice*/
.student-list-of-choice{
    position: relative;
    display: none;
    margin-bottom: 10px;
    width: 160px;
    height: 150px;
    overflow: auto;
    padding: 3px 6px;
    align-items: center;
    font-size: 0.95rem;
    background: white;
    border-radius: 10px;
    margin-right: 1rem;
}


    /* .student-list-of-choice:before{
        content: "";
        position: absolute;
        background: url('../img/student-icon.svg');
        background-repeat: no-repeat;
        width: 30px;
        height: 30px;
        left: 0;
    } */

    .student-list-of-choice>span{
        border-radius: 3px;
        margin: 2px;
        width: 100%;
        padding: 0px 6px;
        color: #000;
        background: #ffbe00;
    }


#youarecorrectorwrongdiv {
    font-size: 3rem;
    color: green;
    font-weight: bold;
    text-align: center;
    margin: 10px 0;
}

@media (max-width: 575.98px) {
    #youarecorrectorwrongdiv {
        font-size: 2rem;
    }
}

#youarecorrectorwrongdiv span {
    display: inline-block;
    margin: 0;
}

.your-choice-text-label{
    display: flex;
    align-items: center;
    animation: flash 0.5s ease-in-out 3; 
}

@keyframes flash {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0;
    }
} 
 
    @media (max-width: 575.98px) {
        .your-choice-text-label {
            position: relative;
            font-size: 1rem;
            margin: auto;
        }
    }

    .your-choice-text-label span{
        font-size: 1.3rem;
        background: #fff;
        color: #3c3c3c;
        padding: 1px 6px;
        border-radius: 8px;
        border: 4px solid #d9d9d9;
        font-family: 'Fredoka One';
    }



/*Leaderboard*/
.leaderboard-list{
    border: 6px solid #fff;
}

    .leaderboard-list ul li{
        font-size: 1.3rem;
        font-family: 'Fredoka One';
        border-bottom: 2px solid #c3ab62;
    }


/*Summary Question Text*/
.summary-question-card .card{
    min-height: 150px;
}

.summary-question-card  .answer-btn-gp .card{
   flex-direction: column;
}

.summary_questionno{
    font-size: 1.3rem;
}


/*Card Style*/
.card-style-shadow{
        box-shadow: inset 0 0 0px 7px #e9c43e, 6px 13px 0px 3px #0000009c;
    border: none;  
}


/*Score Particles*/
@keyframes flyToScore {
  0% {
    transform: translate(0, 0) scale(1);
    opacity: 1;
  }
  100% {
    transform: translate(var(--tx), var(--ty)) scale(0);
    opacity: 0;
  }
}

@keyframes scoreFlash {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.2); }
}

.score-particle {
  position: fixed;
  width: 10px;
  height: 10px;
  background-color: gold;
  border-radius: 50%;
  pointer-events: none;
}

.score-flash {
  animation: scoreFlash 0.3s ease-in-out;
}

/*Join Success Message*/
.join-success-message{
    text-align: center;
    font-family: 'Fredoka One';
    font-size: 2rem;
    color: #e91e63;
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.5s ease-out, transform 0.5s ease-out;

}

.join-success-message.show {
    opacity: 1;
    transform: translateY(0);
}



@keyframes correct-answer-glow {
    0% { scale: 1;  }
    50% { scale: .95; }
    100% { scale: 1; }
}

.correct-answer-glow {
    animation: correct-answer-glow 1s infinite;
}


/*Animations Collection*/
@keyframes flipIn {
  from {
    transform: perspective(400px) rotateX(90deg);
    opacity: 0;
  }
  to {
    transform: perspective(400px) rotateX(0deg);
    opacity: 1;
  }
}

 
/*Ranking Marquee*/
.ranking-marquee-container {
    position: relative;
    width: 100%;
    height: 30vh;
    min-height: 300px;
    overflow: hidden;
}

.ranking-marquee-container .ranking-item {
    display: flex;
    align-items: center;
    position: absolute;
    white-space: nowrap;
    background: #a5a5a540;
    width: auto;
    height: auto;
    transition: opacity 0.3s ease;
    z-index: 1000; /* 確保顯示在其他元素上方 */
    padding: 0;
    border-radius: 10px;
    font-size: 1.2rem !important;
}

.ranking-item:hover {
    transform: scale(1.1);
    z-index: 10000;
}

.ranking-item>.player-name {
    font-weight: normal;
    color: #000;
    text-shadow: 0 0 5px rgba(255, 215, 0, 0.5);
    background: transparent;
    font-size: 1.2rem;
}

.ranking-item .player-score {
    font-family: 'Fredoka One';
    font-size: 1.6rem;
    color: #000;
    font-weight: normal;
}

.ranking-item .score-change {
    font-family: 'Fredoka One';
    font-size: 1.6rem;
    color: #000;
    font-weight: normal;
}


.white-space-nowrap{
    white-space: nowrap;
}

.hide-teacher-control-menu-btn{
    display: block;
    width: 100%;
    background: #46424200;
    color: #ffffff;
    font-weight: bold;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 6px;
    border-radius: 6px;
    font-size: 1rem;
    border: 1px solid white;
}


@media (min-width: 767.98px) {
    .hide-teacher-control-menu-btn{
        display: none;
    }
} 

.game-ended-div{
    display: none;
    background: #6400ffcf;
    color: #fff;
    text-align: center;
    font-size: 1.3rem;
    font-weight: bold;
    position: absolute;
    padding: .2em; 
    width: 500px;
    top: 0;
    left: 0;
    right: 0;
    margin: auto;
    z-index: -1;
    border-radius: 0px 0px 30px 30px;
    animation: slide-down 1s ease-in-out;
    animation-delay: 1s;
    animation-fill-mode: forwards;
    transform: translateY(-100px);
}

@media screen and (max-width: 575.98px) {
    .game-ended-div{
        width: 100%;
        border-radius: 0px;
        top: auto;
        bottom: 0dvh;
    }
}

.thisismychoice-text-label{
    color: #000;
} 

@keyframes slide-down {
    0% { opacity: 0; transform: translateY(-100%); }
    100% { opacity: 1; transform: translateY(0); }
}

@media screen and (max-width: 575.98px) {
    #award_container .prize-ledder{
        display: none !important;
    }
}

.summary-questionpanel{
   overflow: auto;
}

    .summary-questionpanel .summary-questionpanel-item{
        border: 1px solid transparent;
        width: 40px;
        display: flex;
        flex-direction: column;
        align-items: center;
        background: #583fdb;
        border-radius: 6px;
    } 

    .summary-questionpanel .summary-questionpanel-button.active{
        border-radius: 6px;
        padding: 3px 0px;
        background: #2196F3;
    }


.waiting-message{
    transform: translateY(100px);
}

#newjoinplayername{
    display: none;
}