/* OVER-ALL CSS */
:root {
    font-size: 0.625vw;
    -moz-text-size-adjust: 100%;
    -webkit-text-size-adjust: 100%;
    text-size-adjust: none;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    text-decoration: none;
}

@font-face {
    font-family: "TX_khunchang";
    src: url(TX_khunchang.ttf);
}

.TX_khunchang {
    font-family: "TX_khunchang";
}

@font-face {
    font-family: "Zanily";
    size-adjust: 80%;
    src: url(Zanily.ttf);
}

.Zanily {
    font-family: "Zanily";
}

@font-face {
    font-family: "Yozai";
    size-adjust: 80%;
    src: url(Yozai-Medium.ttf);
}

.Yozai {
    font-family: "Yozai";
}

html {
    scroll-behavior: smooth;
    color: black;
    background: white;
    overflow: visible;
    scrollbar-width: none;
}

img {
    pointer-events: none;
}

.filter-invert {
    filter: invert();
}

section {
    height: 100dvh;
    transition: transform 0.8s ease-in-out;
    background: white;
}

p {
    font-size: 3rem;
}

@keyframes yuay-down {
    0% {
        transform: translateY(0);
    }
    
    50% {
        transform: translateY(20%);
    }
    
    100% {
        transform: translateY(0);
    }
}

.yuay-down {
    animation-name: yuay-down;
    animation-duration: 0.5s;
    animation-timing-function: ease-in-out;
}

@keyframes yuay-up {
    0% {
        transform: translateY(0);
    }
    
    50% {
        transform: translateY(-20%);
    }
    
    100% {
        transform: translateY(0);
    }
}

.yuay-up {
    animation-name: yuay-up;
    animation-duration: 0.5s;
    animation-timing-function: ease-in-out;
}

@keyframes fade-in {
    0% {
        opacity: 0%;
    }

    100% {
        opacity: 100%;
    }
}

.fade-in {
    animation-name: fade-in;
    animation-duration: 1.5s;
    animation-fill-mode: forwards;
    animation-timing-function: ease-out;
}
/* OVER-ALL CSS */


/* SIDE MENU CSS */
div.on-top-menu {
    position: fixed;
    top: 0;
    right: 0;

    display: flex;
    flex-direction: column;
    align-items: end;
    justify-content: space-between;
    height: 100dvh;
    z-index: 100;
    width: 20vw;

    pointer-events: none;
}

img.lwli-button {
    aspect-ratio: 311/231;
    width: 10rem;
}

div.menu-button {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 4rem;
    cursor: pointer;
    pointer-events: all;
}

p.menu {
    line-height: 1.75rem;
}

div.on-top-menu .sns {
    display: flex;
    flex-direction: column;
    align-items: center;

    width: 18rem;
    padding-inline: 6.5rem;
    margin-bottom: 2rem;
    pointer-events: all;
    margin-inline: 0 !important;
}

div.on-top-menu .sns img {
    aspect-ratio: 1/1;
    width: 100%;
}

.sns .sub-menu {
    aspect-ratio: 1/1;
    color: black;
    text-align: center;
    margin-bottom: 2rem;
    padding: 0.5rem;
    background: white;
    border-radius: 50%;
}

.sns .sub-menu:hover {
    border: 1px solid black;
}

@keyframes slide-from-right {
    0% {
        transform: translateX(100%);
    }

    100% {
        transform: translateX(0%);
    }
}

.slide-from-right {
    animation: slide-from-right;
    animation-duration: 0.5s;
    animation-timing-function: ease-in-out;
    animation-fill-mode: forwards;
}

@keyframes slide-from-left {
    0% {
        transform: translateX(0%);
    }

    100% {
        transform: translateX(100%);
    }
}

.slide-from-left {
    animation: slide-from-left;
    animation-duration: 0.5s;
    animation-timing-function: ease-in-out;
    animation-fill-mode: forwards;
}

div.side-menu {
    position: fixed;
    top: 0;
    right: 0;

    display: grid;
    grid-template-rows: auto 1fr 10dvh 10dvh; 
    height: 100dvh;
    width: 20vw;
    background: black;
    background-image: url(mwlw-pic/path383-8.png);
    background-repeat: repeat-y;
    background-size: contain;
    transform: translateX(100%);
    z-index: 200;
}

div.menu {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-inline: 5rem;
}

div.grid-container {
    display: flex;
    justify-content: end;
}

div.close-button {
    filter: invert();
    cursor: pointer;

    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 4rem;
}

div.side-menu .web {
    flex-direction: column;
    align-items: center;
    justify-content: space-around;
}

.web .sub-menu {
    min-width: 15rem;
    border-bottom: 1px solid black;
}

div.side-menu .lang {
    margin-inline: 1rem;
    gap: 1rem;
}

div.side-menu .color .sub-menu {
    width: 5rem;
    height: 5rem;
    padding: 1rem;
    margin-inline: 1rem;
    background: white;
    border-radius: 50%;
}

div.side-menu .color img {
    height: 100%;
}

div.side-menu .color .sub-menu:hover {
    border: 1px solid white;
}

div.side-menu .color .light {
    filter: invert();
    border: 1px solid black;
}

p.sub-menu {
    text-align: center;
    cursor: pointer;
    color: white;
    min-width: 5rem;

    transition: 0.5s;
}

p.sub-menu:hover, p.sub-menu.active {
    border-bottom: 1px solid white;
    color: white;
}
/* SIDE MENU CSS */


/* LANDING SECTION CSS */
section.landing {
    position: relative;

    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.landing img.recline-logo {
    aspect-ratio: 557/301;
    width: 33%;
}

.landing h2#landing-slogan {
    font-size: 3rem;
}

.landing .down-button {
    position: absolute;
    cursor: pointer;
    bottom: 1rem;
    left: 50%;
    transform: translateX(-50%);

    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.landing .down-button .text-down {
    line-height: 2rem;
}

.landing .down-button .arrow-down {
    width: 2rem;
}
/* LANDING SECTION CSS */

/* FIRST SECTION CSS */
.first {
    padding: 5rem;
}

.first .news {
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 1px solid black;
    width: 90%;
}

.first .lwli-news {
    display: flex;
    gap: 4rem;
}

.first .lwli-news a {
    font-size: 3rem;
    color: black;
    width: auto;
}

.first .lwli-news a:hover {
    text-decoration: underline;
}

.first .mwlw-bg {
    border: 1rem solid black;
    height: 70%;
    width: 90%;
    background-image: url(mwlw-pic/path1.png);
    background-position-x: center;
    background-position-y: 43%;
    background-repeat: no-repeat;
    background-size: 110% auto;

    border-radius: 1rem;
}

.first .mwlw-text {
    font-size: 4rem;
}

/* FIRST SECTION CSS */

/* SECOND SECTION CSS */
.second {
    display: flex;
}

.second .paper-box {
    display: grid;
    grid-template-columns: 55% auto;
    width: 100%;
}

.signature {
    position: relative;

    overflow: hidden;
    height: 100%;
    width: 100%;
}

.signature .rec-menu {
    position: absolute;

    top: -15%;
    height: 125%;
}

.signature .rec-menu-cat {
    position: absolute;

    top: 25%;
    left: 25%;
    height: 75%;
}

.choux-text {
    font-size: 7rem;
    padding: 4rem;
    padding-top: 15%;
}

.choux-head {
    text-shadow: 1px 1px 2px gray;
}
/* SECOND SECTION CSS */

/* THIRD SECTION CSS */
.third {
    display: flex;
}

.third .paper-bag {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 1rem;
    margin-inline-start: 10rem;
    margin-inline-end: 20rem;
    margin-block: 10rem;
    align-items: center;
}

.lung-kai {
    position: relative;
}

.paper-bag .drink {
    width: 100%;
    aspect-ratio: 1/1;
}

.paper-bag .drink-cat {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    aspect-ratio: 1/1;
}

.lung-kai .drink-name {
    font-size: 4rem;
    text-align: center;
    padding-inline: 1rem;
}

.text-shadow {
    text-shadow: 1px 1px 2px gray;
}
/* THIRD SECTION CSS */

/* ADDRESS SECTION CSS */
.contact {
    position: relative;
}

.contact .address-box {
    position: absolute;

    top: 50%;
    left: 5rem;
    width: 85%;
    height: 80%;
    transform: translateY(-50%);

    display: grid;
    grid-template-columns: 1fr 1fr;
}

.address-box .text {
    padding: 2.5rem;
    font-size: 2.5rem;

    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: start;

    border: 1px solid black;
}

.contact .text iframe {
    width: 100%;
    height: 75%;
}

.address-box .store-front-container {
    position: relative;
}

.store-front-container .store-front {
    position: relative;

    top: 10%;
    left: 20%;
    width: 60%;

    transform: rotate(5deg);
}

.store-front img.front {
    width: 100%;
    box-shadow: rgba(0, 0, 0, 0.35) 0px 5px 15px;
}

.store-front .tape-one {
    position: absolute;

    top: 0;
    left: -10%;
    width: 50%;
    transform: rotate(-25deg);
    z-index: 1;
}

.store-front .tape-two {
    position: absolute;
    
    bottom: 0;
    right: -10%;
    width: 50%;
    transform: rotate(160deg);
    z-index: 1;
}

/* ADDRESS SECTION CSS */

/* BOTTOM SECTION CSS */
.mini-game {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.mini-game h2 {
    font-size: 6rem;
    width: 100%;
    text-align: center;
    padding-left: 5rem;
    padding-right: 15rem;
}

.bottom {
    display: flex;
    justify-content: space-around;
    align-items: center;

    padding-left: 5rem;
    padding-right: 15rem;
    width: 100%;
}

.bottom .game-icon {
    width: 30rem;
    height: 22rem;

    display: flex;
    flex-direction: column;
    justify-content: space-between;
    align-items: center;
    color: black;
    padding: 2rem;
    border-radius: 2rem;
}

.bottom .game-icon:hover {
    border: 1px solid black;
}

.bottom .game-icon img {
    max-width: 75%;
    max-height: 75%;
    /* filter: invert(); */
}
/* BOTTOM SECTION CSS */

/* APPOINTMENT CSS */
.appointment {
    position: relative;

    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;

    transition: all 0.3s;
}

.img-container {
    display: flex;
    justify-content: center;
    margin-bottom: 15px;
}

.laew-room {
    max-width: 360px;
    border-radius: 5px;
}

.container {
    background-color: #fff;
    padding: 30px;
    border-radius: 8px;
    border: 1px solid black;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    width: 100%;
    max-width: 640px;
    font-size: 3rem;

    transition: all 0.3s;
}

.appointment h1, .appointment h2 {
    text-align: center;
    color: #333;
    /* margin-bottom: 20px; */
}

.date-selection {
    margin-bottom: 20px;
    text-align: center;
}

.date-selection label {
    font-size: 1.1em;
    margin-right: 10px;
}

.date-selection select {
    padding: 8px;
    border-radius: 4px;
    border: 1px solid #ccc;
    font-size: 1em;
    font-family: "TX_khunchang";
}

.time-slots {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(80px, 1fr));
    gap: 10px;
    margin-top: 20px;
}

.time-slot {
    background-color: white;
    border: 1px solid black;
    padding: 10px;
    text-align: center;
    border-radius: 5px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.time-slot.booked {
    background-color: black;
    cursor: not-allowed;
    color: #555;
}

.time-slot.selected {
    background-color: #81c784;
    border: 1px solid #4caf50;
    color: #fff;
}

.time-slot:not(.booked):hover {
    background-color: gray;
}

.booking-form-container {
    font-size: 3rem;
    /* margin-top: 30px; */
    padding: 20px;
    border: 1px solid black;
    border-radius: 8px;
    background-color: white;

    transition: all 0.3s;
}

.form-group {
    margin-bottom: 15px
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: bold;
    color: black;
}

.form-group input {
    width: calc(100% - 20px);
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 1em;
    font-family: "TX_khunchang"; 
}

.booking-form-container button {
    padding: 10px 20px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 1em;
    margin-right: 10px;
    transition: background-color 0.3s ease;
}

.booking-form-container button[type="submit"] {
    background-color: white;
    color: black;
    font-family: "TX_khunchang";
    border: 1px solid black;
}

.booking-form-container button[type="submit"]:hover {
    background-color: #45a049;
}

#cancelForm {
    background: black;
    color: white;
    font-family: "TX_khunchang";
}

#cancelForm:hover {
    background-color: #da190b;
}

/* Popup Styles */
.popup {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.6);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;

    font-size: 3rem;
}

.popup-content {
    background-color: #fff;
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    text-align: center;
    max-width: 640px;
    width: 90%;
}

.popup-content p {
    font-size: 1.2em;
    margin-bottom: 20px;
    color: #333;
}

.popup-content button {
    padding: 10px 20px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 1em;
    margin: 0 10px;
    transition: background-color 0.3s ease;
}

#confirmBookingBtn {
    background-color: white;
    color: black;
    font-family: "TX_khunchang";
    border: 1px solid black;
}

#confirmBookingBtn:hover {
    background-color: #45a049;
}

#cancelBookingBtn {
    background: black;
    color: white;
    font-family: "TX_khunchang";
}

#cancelBookingBtn:hover {
    background-color: #da190b;
}

/* style.css */

/* CSS สำหรับ Loading Popup */
#loadingPopup.popup {
    display: flex; /* ใช้ flex เพื่อจัดกึ่งกลาง */
    justify-content: center;
    align-items: center;
    background-color: rgba(0, 0, 0, 0.7); /* พื้นหลังทึบขึ้นเล็กน้อย */
}

#loadingPopup .popup-content {
    background-color: #fff;
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
    text-align: center;
    max-width: 480px;
}

#loadingPopup h2 {
    color: black;
    margin-bottom: 15px;
}

#loadingPopup p {
    color: black;
    margin-bottom: 25px;
}

/* CSS สำหรับ Loader (Spinning Circle) */
.loader {
    border: 5px solid #f3f3f3; /* Light grey */
    border-top: 5px solid black; /* Blue */
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
    margin: 0 auto; /* จัดกึ่งกลาง */
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}
/* APPOINTMENT CSS */


/* MEDIA QUERY */
@media (max-width: 540px) {
    :root {
        font-size: 1.875vw;
    }
    section {
        height: 100dvh;
        width: 100vw;
        overflow: hidden;
    }

    /* PT SIDE MENU */
    div.on-top-menu {
        width: auto;
    }

    img.lwli-button {
        aspect-ratio: 311/231;
        width: 10rem;
    }
    
    div.menu-button {
        padding: 2.5rem;
    }

    div.close-button {
        padding: 2.5rem;
    }

    div.on-top-menu .sns {
        width: 9rem;
        padding: 2.5rem;
        margin-bottom: 0;
    }

    div.on-top-menu .sns img {
        aspect-ratio: 1/1;
        width: 100%;
    }

    .sns .sub-menu {
        margin-bottom: 0.5rem;
        padding: 0.25rem;
    }

    div.side-menu {
        width: 75vw;
    }
    /* PT SIDE MENU */

    /* PT LANDING SECTION CSS */

    .landing img.recline-logo {
        width: 75%;
    }

    .landing h2#landing-slogan {
        font-size: 2.5rem;
    }

    .landing .down-button {
        bottom: 2rem;
    }

    .landing .down-button .arrow-down {
        width: 3rem;
    }
    /* PT LANDING SECTION CSS */

    /* PT FIRST SECTION CSS */
    .first {
        padding: 5rem;
    }

    .first .mwlw-bg {
        height: 55%;
        width: 90%;
        background-image: url(mwlw-pic/path48-9.png);
    }

    .first .mwlw-text {
        padding-right: 8rem;
        font-size: 4rem;
    }

    .first .lwli-news {
        display: block;
    }
    /* FIRST SECTION CSS */

    /* SECOND SECTION CSS */
    .second {
        display: flex;
    }

    .second .paper-box {
        display: grid;
        grid-template-columns: auto;
        width: 100%;
    }

    .signature {
        position: relative;
        height: 44dvh;
        overflow: visible;
        width: 100%;
    }

    .signature .rec-menu {
        position: absolute;

        top: 0%;
        height: 125%;
        border-bottom: 1px solid black;
    }

    .signature .rec-menu-cat {
        top: 40%;
        left: 25%;
    }
    /* SECOND SECTION CSS */

    /* THIRD SECTION CSS */
    .third {
        display: flex;
    }

    .third .paper-bag {
        display: grid;
        grid-template-columns: auto;
        margin-inline-start: 0rem;
        margin-inline-end: 12rem;
        margin-block: 5rem;
    }

    .lung-kai {
        display: flex;
        align-items: center;
        border-left: none;
        border-right: none;
    }

    .paper-bag .drink {
        width: 57%;
    }

    .paper-bag .drink-cat {
        width: 57%;
    }

    .lung-kai .drink-name {
        padding-inline: 0rem;
    }
    /* THIRD SECTION CSS */

    /* ADDRESS SECTION CSS */
    .contact {
        position: relative;
    }

    .contact .address-box {
        position: absolute;

        top: 0;
        left: 0;
        width: 100vw;
        height: 100dvh;
        transform: translateY(0);
        padding-inline-start: 5rem;
        padding-inline-end: 10rem;
        padding-block: 5rem;
        grid-template-columns: auto;
    }

    .address-box .text {
        height: calc(50dvh - 5rem);
    }

    .contact .text iframe {
        width: 100%;
        height: auto;
    }

    .store-front-container {
        height: calc(45dvh - 5rem);
    }

    .store-front-container .store-front {
        top: 10%;
        left: 15%;
        width: 70%;
    }

    .address-br {
        display: none;
    }
    /* ADDRESS SECTION CSS */

    /* BOTTOM SECTION CSS */
    .bottom {
        display: grid;
        grid-template-columns: auto;

        padding: 0;
        padding-right: 5rem;

    }

    .mini-game h2 {
        padding-left: 0;
        padding-right: 5rem;
        /* padding: 2rem; */
    }

    .bottom .game-icon {
        width: 22rem;
        height: 22rem;

        padding: 2rem;
        border-radius: 10%;
    }
    /* BOTTOM SECTION CSS */

    /* APPOINTMENT SECTION CSS */
    .booking-form-container {
        position: absolute;
        top: 50%;
        left: 50%;
        transform: translateX(-50%) translateY(-50%);
        width: 75%;
    }
    /* APPOINTMENT SECTION CSS */
}


/* MEDIA QUERY */


@keyframes laiii {
    0% {
        transform: translateY(0%);
    }
    
    25% {
        transform: translateY(100%);
    }
    
    50% {
        transform: translateY(50%);
    }
    
    75% {
        transform: translateY(-10%);
    }

    100% {
        transform: translateY(0%);
    }
}

.laiii {
    animation-name: laiii;
    animation-duration: 5s;
    animation-timing-function: ease-in-out;
    animation-iteration-count: infinite;
}

@keyframes slideee {
    0% {
        transform: translateX(0%);
    }
    
    25% {
        transform: translateX(30%);
    }
    
    50% {
        transform: translateX(15%);
    }
    
    75% {
        transform: translateX(-25%);
    }

    100% {
        transform: translateX(0%);
    }
}

.slideee {
    animation-name: slideee;
    animation-duration: 5s;
    animation-timing-function: linear;
    animation-iteration-count: infinite;
}

@keyframes tiwww {
    0% {
        transform: rotate(0deg);
    }
     
    50% {
        transform: rotate(360deg);
    }

    100% {
        transform: rotate(0deg);
    }
}

.tiwww {
    animation-name: tiwww;
    animation-duration: 10s;
    animation-timing-function: ease-in-out;
    animation-iteration-count: infinite;
}