@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@400;500;600&display=swap');

body{
    background: #6665ee;
    text-align: center;
    padding: 0;
    border: 0;
    margin: 0;
    min-height: 100vh;
    font-family: 'Poppins', sans-serif;
    user-select: none;
}

::selection{
    color: #fff;
    background: #10003D;
}

:root {
    --dark: #34495E;
    --light: #ffffff;
    --success: #0ABF30;
    --error: #E24D4C;
    --warning: #E9BD0C;
    --info: #3498DB;
}

h1{
    color: #fff;
    font-size: 40px;
}

/* Game Player */
#game-canvas{
    width: 960px;
    height: 600px;
    background: #10003D;
    display: none;
}
#game-status{
    color: rgb(255, 150, 210);
    font-size: 30px;
    white-space: pre-wrap;
    margin: 70px;
}

/* Loading Spinner */
.lds-hourglass {
    display: inline-block;
    position: relative;
    width: 80px;
    height: 80px;
}
.lds-hourglass:after {
    content: " ";
    display: block;
    border-radius: 50%;
    width: 0;
    height: 0;
    margin: 8px;
    box-sizing: border-box;
    border: 32px solid #fff;
    border-color: #fff transparent #fff transparent;
    animation: lds-hourglass 1.2s infinite;
}
@keyframes lds-hourglass {
    0% {
        transform: rotate(0);
        animation-timing-function: cubic-bezier(0.55, 0.055, 0.675, 0.19);
    }
    50% {
        transform: rotate(900deg);
        animation-timing-function: cubic-bezier(0.215, 0.61, 0.355, 1);
    }
    100% {
        transform: rotate(1800deg);
    }
}

/* Poll System */
button {
    width: 30%;
    padding: 8px;
    font-size: 14px;
    cursor: pointer;
    border: none;
    border-radius: 5px;
    color: #fff;
    margin-bottom: 15px;
    transition: background-color 0.3s;
    display: block;
    margin-left: auto;
    margin-right: auto;
    transition: 0.5s;
}
#blue-btn{
    background-color: #007bff;
}
#blue-btn:hover{
    background-color: #0069d9;
}
#green-btn{
    background-color: #28a745;
}
#green-btn:hover{
    background-color: #218838;
}
.poll-bar-container {
    width: 100%;
    background-color: #e9ecef;
    border-radius: 5px;
    overflow: hidden;
    margin-bottom: 20px;
    position: relative;
    height: 30px;
    display: flex;
    align-items: center;
}
.poll-bar {
    height: 100%;
    line-height: 30px;
    color: #fff;
    transition: width 0.3s;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background-size: cover;
    position: absolute;
    top: 0;
}
#blueBar {
    background-image: url('https://cdn.discordapp.com/attachments/716863000723587144/1168102687980650566/ezgif.com-crop.gif');
    left: 0;
}
#greenBar {
    background-image: url('https://media.discordapp.net/attachments/716863000723587144/1168102687506706532/ezgif.com-crop_1.gif');
    right: 0;
}
.no-votes {
    text-align: center;
    line-height: 30px;
    width: 100%;
}
.percent {
    color: #10003D;
    margin-left: 5px;
    user-select: none;
}
.emoji {
    font-size: 20px;
    user-select: none;
}
#poll {
    display: none;
}
#loading-poll {
    font-size: 25px;
}
#winner-text {
    font-size: 25px;
    margin-bottom: 20px;
}

/* Toast Notifications */
#notifications {
    position: fixed;
    top: 30px;
    right: 20px;
}
#notifications :where(.toast, .column) {
    display: flex;
    align-items: center;
  }
#notifications .toast {
    width: 400px;
    position: relative;
    overflow: hidden;
    list-style: none;
    border-radius: 4px;
    padding: 16px 17px;
    margin-bottom: 10px;
    background: var(--light);
    justify-content: space-between;
    animation: show_toast 0.3s ease forwards;
  }
@keyframes show_toast {
    0% {
      transform: translateX(100%);
    }
    40% {
      transform: translateX(-5%);
    }
    80% {
      transform: translateX(0%);
    }
    100% {
      transform: translateX(-10px);
    }
}
#notifications .toast.hide {
    animation: hide_toast 0.3s ease forwards;
  }
  @keyframes hide_toast {
    0% {
      transform: translateX(-10px);
    }
    40% {
      transform: translateX(0%);
    }
    80% {
      transform: translateX(-5%);
    }
    100% {
      transform: translateX(calc(100% + 20px));
    }
}
.toast::before {
    position: absolute;
    content: "";
    height: 3px;
    width: 100%;
    bottom: 0px;
    left: 0px;
    animation: progress 5s linear forwards;
}
@keyframes progress {
    100% {
      width: 0%;
    }
}
.toast.success::before {
    background: var(--success);
}
.toast.error::before {
    background: var(--error);
}
.toast.warning::before {
    background: var(--warning);
}
.toast.info::before {
    background: var(--info);
}
.toast .column i {
    font-size: 1.75rem;
}
.toast.success .column i {
    color: var(--success);
}
.toast.error .column i {
    color: var(--error);
}
.toast.warning .column i {
    color: var(--warning);
}
.toast.info .column i {
    color: var(--info);
}
.toast .column span {
    font-size: 1.07rem;
    margin-left: 12px;
}
.toast i:last-child {
    color: #10003D;
    cursor: pointer;
}
.toast i:last-child:hover {
    color: var(--dark);
}
@media screen and (max-width: 530px) {
    #notifications {
      width: 95%;
    }
    #notifications .toast {
      width: 100%;
      font-size: 1rem;
      margin-left: 20px;
    }
}