@import url('https://fonts.googleapis.com/css2?family=Baloo+Bhaijaan+2:wght@400..800&family=Candal&family=Coiny&family=Exo+2:ital,wght@0,100..900;1,100..900&family=Fredoka:wght@300..700&family=Noto+Sans+JP:wght@100..900&family=Noto+Sans+Thai:wght@100..900&display=swap');

* {
    padding: 0;
    margin: 0;
    box-sizing: border-box;
    scroll-behavior: smooth;
    list-style: none;
    text-decoration: none;
}

a {
    list-style: none;
    text-decoration: none;
}

.loading {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    z-index: 10000;
    background: #1f242d;
    width: 100%;
    position: fixed;
}


.loading h2 {
    position: relative;
    font-size: 10vw;
    color: #1f242d;
    -webkit-text-stroke: 0.3vw #7e69f1;
    text-transform: uppercase;
}

.loading h2::before {
    content: attr(data-text);
    position: absolute;
    top: 0;
    left: 0;
    width: 0;
    height: 100%;
    color: #7e69f1;
    -webkit-text-stroke: 0vw #7e69f1;
    border-right: 2px solid #7e69f1;
    overflow: hidden;
    animation: animate 4s linear infinite;
}

.loading img {
    width: 200px;
    height: 200px;
    margin-right: 10px;
}

@keyframes animate {

    0%,
    10%,
    100% {
        width: 0;
    }

    70%,
    90% {
        width: 100%;
    }
}

.warning {
    display: none;
}

body {
    background-image: linear-gradient(120deg, #f0e7fa 0%, #e5f0fa 100%);
}

.my-container {
    width: 100%;
    height: 100vh;
}

.header {
    width: 100%;
    height: 12%;
    display: flex;
    /* background-color: red; */
    justify-content: space-around;
    align-items: center;
    background-color: #1f242d;
    color: #fff;
}

.header .logo {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 25%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: start;
    /* background-color: lightcoral; */
    padding: 0 1rem;
}

.logo h1 {
    font-family: 'Poppins', sans-serif;
    font-size: 3rem;
}

.logo img {
    width: 100px;
    height: 100px;
}

.header .mode-name {
    width: 50%;
    height: 100%;
    background: radial-gradient(circle at 10% 20%, #e2f1ed 40%, #e0eaf5 75.5%);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 5rem;
    color: #1f242d;
    font-family: "Baloo Bhaijaan 2", sans-serif;
    font-optical-sizing: auto;
    font-weight: 700;
    font-style: normal;
}

:root {
    --bg-color: #e6f2f5;
    --text-color: #221314;
    --second-color: #5a7184;
    --main-color: #7e69f1;
    --sec-color: #84bee6;
    --nav-color: #1f242d;
    --second-bg-color: rgb(168, 231, 231);
    --big-font: 8rem;
    --h2-font: 4rem;
    --h3-font: 2.2rem;
    --p-font: 1.7rem;
}

.header .contact {
    width: 25%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: end;
    padding: 0 2rem;
}

.contact .contact-text {
    text-align: center;
    color: var(--bg-color);
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: end;
}

.contact .contact-text h3 {
    font-size: 3rem;
    font-family: "Exo 2", sans-serif;
    font-optical-sizing: auto;
    font-weight: 700;
}

.contact .social-media {
    width: 100%;
    height: 100%;
    display: flex;
    margin: auto;
    justify-content: center;
    align-items: center;
}

.social-media a {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    width: 4rem;
    height: 4rem;
    background: transparent;
    border: .2rem solid var(--main-color);
    border-radius: 50%;
    margin: 0 .5rem;
    font-size: 2rem;
    color: var(--main-color);
    transition: .5s ease;
}

.social-media a:hover {
    background: var(--main-color);
    box-shadow: 0 0 1rem var(--main-color);
}

.main {
    width: 100%;
    height: 80%;
    display: flex;
    flex-direction: column;
    padding: 0 1rem;
}

.number,
.ans {
    font-family: "Exo 2", sans-serif;
    font-optical-sizing: auto;
    font-weight: 800;
}

.ans {
    color: #14366b;
}

.main .question-button {
    width: 100%;
    height: 12%;
    display: flex;
    align-items: center;
    justify-content: start;
    /* background-color: lightgreen; */
    padding: 1rem 0;
}

.question-button button {
    margin: 0 1rem;
    width: 20%;
    height: 100%;
    font-size: 2.5rem;
    border-radius: 7px;
    background-image: linear-gradient(45deg, #557cdf, #9c80ea, #c088f3, #f8f2f5);
    font-family: "Baloo Bhaijaan 2", sans-serif;
    font-optical-sizing: auto;
    font-size: 800;
    transition: all .1s ease-in-out;
    color: #000;
}

.question-button button:hover {
    cursor: pointer;
    background-image: linear-gradient(45deg, #3767e0, #8560ec, #a15be4, #ecccdc);
    scale: 0.97;
}

.main .question-part {
    width: 100%;
    height: 45%;
    display: flex;
    align-items: center;
    justify-content: space-around;
    /* background-color: lightgoldenrodyellow; */
}

.question-part .number {
    font-size: 17rem;
    border: .1rem solid #000;
    box-shadow: 0 6px 10px rgba(0, 0, 0, .7);
    padding: 0 5rem;
    border-radius: 1rem;
}

.main .answertime-part {
    width: 100%;
    height: 45%;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.answertime-part .answer-part {
    width: 50%;
    height: 100%;
    /* background-color: lightsalmon; */
    display: flex;
    align-items: center;
    justify-content: center;
}

.answer-part .ans {
    font-size: 18rem;
}

.answertime-part .timenum-part {
    width: 50%;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    font-size: 2.5rem;
    padding: 2rem;
    font-family: "Baloo Bhaijaan 2", sans-serif;
    font-optical-sizing: auto;
    font-size: 800;
    color: #14366b;
}

.timenum-part .qnum-part {
    width: 100%;
    height: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 4.5rem;
    border: .2rem solid #14366b;
    border-radius: 20px;
    border-end-end-radius: 0px;
    border-end-start-radius: 0px;
}

.qnum-part .qnum-button {
    width: 10%;
    display: flex;
    flex-direction: column;
    height: 100%;
    justify-content: center;
}

.qnum-button button {
    height: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    border: none;
    background-image: linear-gradient(120deg, #f0e7fa 0%, #e5f0fa 100%);
}

.qnum-button svg {
    width: 80%;
    height: 80%;
    color: #557cdf;
}

.timenum-part .time-part {
    width: 100%;
    height: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 6rem;
    border: .2rem solid #14366b;
    border-top: none;
    border-radius: 20px;
    border-start-start-radius: 0px;
    border-start-end-radius: 0px;
}

.time-part .time {
    color: #537ed6;
}

.buttontime {
    display: none;
}

.footer {
    width: 100%;
    height: 8%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 1.4rem;
}

.footer .settings-part {
    display: flex;
    width: 20%;
    height: 100%;
    align-items: center;
    justify-content: start;
    gap: 1.5rem;
    padding: 0 1rem;
    font-family: "Baloo Bhaijaan 2", sans-serif;
    font-optical-sizing: auto;
    font-weight: 500;
}

.settings-part .filter-item,
#explain {
    font-size: 1.75rem;
    cursor: pointer;
    font-family: "Noto Sans Thai", sans-serif;
    font-optical-sizing: auto;
}

.footer .copyright {
    display: flex;
    align-items: center;
    justify-content: end;
    padding: 0 1rem;
    text-align: right;
}

.radio-list {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
}


.radio-item {
    position: relative;
    height: 11rem;
    width: 11rem;
    margin: 0.5rem;
}

.advance-mode-setting {
    display: flex;
    gap: 2rem;
}

.radio-item input[type="radio"] {
    position: absolute;
    height: 100%;
    width: 100%;
    margin: 0;
    cursor: pointer;
    z-index: 2;
    opacity: 0;
}

.radio-list .radio-tile {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    height: 100%;
    border: 2px solid #A770EF;
    border-radius: 12px;
    transition: all .4s ease;
}

.radio-tile img,
.radio-tile box-icon {
    width: 72px;
    height: 72px;
    border-radius: 8px;
}

.radio-item label {
    font-size: 1.2rem;
    text-wrap: wrap;
    font-weight: 500;
    letter-spacing: 1px;
    text-transform: uppercase;
}

input[type="radio"]:checked+.radio-tile {
    background-image: linear-gradient(#a770ef 0%, rgba(255, 255, 255, .1) 70%);
    box-shadow: 0 0 12px #A770EF;
}

input[type="radio"]:hover+.radio-tile {
    background-color: #A770EF;
    box-shadow: 0 0 12px #A770EF;
}

.radio-tile input[type="number"] {
    z-index: 5;
}

.modal-content button {
    font-size: 1.5rem;
}

.modal-body {
    font-size: 2rem;
    padding: 1rem 2rem;
}

.modal-body h3 {
    font-size: 2.5rem;
    font-style: italic;
    text-decoration: underline;
}

.modal-header {
    background: radial-gradient(circle at 10% 20%, #e2f1ed 40%, #e0eaf5 75.5%);
    padding: 1rem 2rem;
}

.modal-header h2 {
    font-size: 3rem;
}

.modal-body .general-set {
    display: flex;
    width: 100%;
    flex-direction: column;
    justify-content: center;
    gap: 1.5rem;
}

.general-set .setting {
    display: flex;
    width: 100%;
    align-items: center;
    margin: .5rem 0;
}

.setting #n5but {
    margin: 0 2rem;
}

.setting button {
    width: 50%;
    padding: 1rem 2rem;
    border-radius: 12px;
    transition: .2s all ease-in-out;
    border: 1px solid #626364;
}

.setting button:hover {
    scale: 0.95;
    background-color: #A770EF;
}

.setting .active-fil {
    background-image: linear-gradient(#a770ef 0%, rgba(255, 255, 255, .1) 70%);
    border: none;
    transition: .2s all ease-in-out;
}

.time-setting input {
    width: 15%;
    height: 100%;
    text-align: end;
}

.reset-set {
    width: 100%;
    height: 100%;
    margin: .5rem 0;
}

.custom-set {
    width: 100%;
    height: 100%;
    margin: .5rem 0;
}

.custom-set button {
    width: 20%;
    height: 100%;
    border-radius: 10px;
}

.custom-set .cnumber {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
    margin: .5rem 0;
}


.custom-set .testbut {
    margin: .5rem 0;
}

.modal-body .fullran-set {
    width: 100%;
    height: 100%;
    margin: 1rem 0;
}

.fullran-set input {
    width: 20%;
    height: 100%;
    text-align: end;
}

.modes-set button {
    width: 25%;
    height: 100%;
    font-size: 1.5rem;
}

#hmode {
    width: 20%;
    height: 100%;
    font-size: 1.8rem;
    background: #A770EF;
    /* fallback for old browsers */
    background: linear-gradient(to right, #FDB99B, #CF8BF3, #A770EF);
    border: none;
    border-radius: 10px;
    color: #1f242d;
}

.collapse#modehistory {
    transition: all 0.5s ease-in-out;
}

#history {
    font-family: 'Ruwudu', serif;
    font-size: 2.6rem;
    margin-top: .5rem;
}

.history-show {
    transition: all .5s ease;
    display: flex;
    justify-content: left;
    align-items: center;
    padding: 50px 0 10px 10px;
    border-radius: 18px;
    margin-top: -32px;
}

@media only screen and (max-width:1440px) {
    .logo h1 {
        font-size: 2rem;
    }

    .logo img {
        width: 70px;
        height: 70px;
    }

    .header .mode-name {
        font-size: 3.5rem;
    }

    .contact .contact-text h3 {
        font-size: 1.5rem;
    }

    .social-media a {
        width: 2.5rem;
        height: 2.5rem;
        margin: 0 .2rem;
    }

    .main .question-button {
        height: 16%;
    }

    .main .question-part,
    .main .answertime-part {
        height: 42%;
    }

    .question-button button {
        font-size: 1.8rem;
        height: 80%;
    }

    .question-part .number {
        font-size: 11.5rem;
        padding: .5rem 4.5rem;
    }

    .answer-part .ans {
        font-size: 13rem;
    }

    .answertime-part .qnum-part {
        font-size: 3rem;
    }

    .answertime-part .time-part {
        font-size: 4rem;
    }

    .footer {
        font-size: 1rem;
    }

    .modal-body {
        font-size: 1.5rem;
        padding: 1rem 2rem;
    }

    .modal-body button {
        border: 1px solid #1f242d;
    }

    .modal-body h3 {
        font-size: 2rem;
        font-style: italic;
        text-decoration: underline;
    }

    .modal-header h2 {
        font-size: 2.3rem;
    }

}

@media only screen and (max-width:1200px) {
    .question-part .number {
        font-size: 12rem;
        padding: .1rem 3rem;
    }
}

@media only screen and (max-width:1024px) {
    .logo h1 {
        font-size: 1.7rem;
    }

    .logo img {
        width: 50px;
        height: 50px;
    }

    .header .mode-name {
        font-size: 3.2rem;
    }

    .contact .contact-text h3 {
        font-size: 1rem;
    }

    .social-media a {
        width: 2.5rem;
        height: 2.5rem;
    }

    .main .question-button {
        height: 16%;
    }

    .main .question-part,
    .main .answertime-part {
        height: 42%;
    }

    .question-button button {
        font-size: 1.3rem;
        height: 80%;
    }

    .question-part .number {
        font-size: 11rem;
        padding: .6rem 2rem;
    }

    .answer-part .ans {
        font-size: 13rem;
    }

    .answertime-part .qnum-part {
        font-size: 2.5rem;
    }

    .answertime-part .time-part {
        font-size: 4rem;
    }

    .footer {
        font-size: 1rem;
    }

    .modal-body {
        font-size: 1.5rem;
        padding: 1rem 2rem;
    }

    .modal-body button {
        border: 1px solid #1f242d;
    }

    .modal-body h3 {
        font-size: 2rem;
        font-style: italic;
        text-decoration: underline;
    }

    .modal-header h2 {
        font-size: 2.3rem;
    }
}

@media only screen and (max-width:800px) {
    .logo h1 {
        font-size: 1.3rem;
    }

    .logo img {
        width: 30px;
        height: 30px;
    }

    .header .mode-name {
        font-size: 2.2rem;
    }

    .contact .contact-text h3 {
        display: none;
    }

    .main .question-button {
        height: 20%;
    }

    .main .question-part,
    .main .answertime-part {
        height: 40%;
    }

    .question-button button {
        font-size: 1rem;
        height: 100%;
    }

    .question-part .number {
        font-size: 4.5rem;
        padding: .5rem 2.8rem;
    }

    .answer-part .ans {
        font-size: 6rem;
    }

    .answertime-part .qnum-part {
        font-size: 1.3rem;
    }

    .answertime-part .time-part {
        font-size: 1.8rem;
    }

    .footer {
        font-size: .5rem;
    }

    .divbut svg {
        height: 70%;
        width: 70%;
    }



    .modal-body {
        font-size: 1rem;
    }

    .modal-body h3 {
        font-size: 1.3rem;
    }

    .modal-body button {
        font-size: 1rem;
    }

    .modal-header {
        padding: .5rem 1rem;
    }

    .modal-header h2 {
        font-size: 1.7rem;
    }

    .filter-item {
        font-size: .5rem;
    }

    #explain{
        font-size: 1.2rem;
    }

    a{
        width: 50%;
    }

    a span{
        font-size: 1rem;
    }

    #history{
        font-size: 1.8rem;
    }
}

@media only screen and (max-width:500px){

    .my-container{
        display: none;
    }

    .warning{
        display: flex;
        flex-direction: column;
        position: relative;
        height: 100vh;
        width: 100%;
        justify-content: center;
        align-items: center;
        z-index: 9999;
        background-color: #fc7676;
        padding: 0 1rem;
        text-align: center;
    }

    .warning svg{
        width: 200px;
        height: 200px;
    }
}

@media only screen and (min-height:1081px){

    .my-container{
        display: none;
    }

    .warning{
        display: flex;
        flex-direction: column;
        position:  relative;
        height: 100vh;
        width: 100%;
        justify-content: center;
        align-items: center;
        z-index: 9999;
        background-color: #fc7676;
        padding: 0 1rem;
        text-align: center;
        font-size: 1.5rem;
    }

    .warntext p{
        font-size: 1.8rem;
    }

    .warntext h2{
        font-size: 3rem;
        font-weight: bold;
    }

    .warning svg{
        width: 200px;
        height: 200px;
    }
}