@import url('https://fonts.googleapis.com/css2?family=Cormorant+Infant:ital,wght@0,300;0,400;0,500;0,600;0,700;1,300;1,400;1,500;1,600;1,700&family=Sarabun:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,700;0,800;1,100;1,200;1,300;1,400;1,500;1,600;1,700;1,800&display=swap');

@import url('https://fonts.googleapis.com/css2?family=Montserrat:ital,wght@0,100..900;1,100..900&family=Open+Sans:ital,wght@0,300..800;1,300..800&display=swap');

body {
    z-index: 0;
    font-size: 16px;                  
    font-family: "Cormorant Infant", serif;
}

html, body {
    height: 100%;
}
body {
    display: flex;
    flex-direction: column;
}
main {
    flex: 1;
    padding-top: 70px !important;
}

.fs-testimonial {
    font-size: calc(1.275rem + .3vw) !important;
}

.fs-5-gallery_text {
    font-size: 1.25rem;
}

.fs-2 {
    font-size: calc(1.325rem + .7vw)!important;
}

@media (max-width:1097px) {
    .fs-1 {
        font-size: calc(1.375rem + .9vw) !important;
    }
    .fs-2 {
        font-size: calc(1.3rem + .6vw) !important;
    }
    .fs-5 {
        font-size: 1rem !important;
    }
    .fs-6 {
        font-size: 0.9rem !important;
    }
}

@media (max-width:992px) {
    .fs-2 {
        font-size: calc(1rem + .5vw) !important;
    }
}

@media (max-width:845px) {
    .fs-1 {
        font-size: calc(1.375rem + .9vw) !important;
    }
    .fs-5 {
        font-size: 0.9rem !important;
    }
    .fs-6 {
        font-size: 0.83rem !important;
    }
}

@media (max-width:767px) {
    .fs-2 {
        font-size: calc(1.25rem + .3vw) !important;
    }
}

.fs-small {
    font-size: 13px !important; /* 13px = 0.835rem */
}

.ff-thai {
    font-family: "Sarabun", serif;
    font-weight: 200;
    font-style: normal;
}

.ff-eng {
    font-family: "Cormorant Infant", serif;
}

/* View Height, View Width */
.vh-50 {
    height: 50vh !important;
}

.vh-74 {
    height: 74vh !important;
}

.vw-text-testimonial {
    width: 70% !important;
}

@media (max-width: 768px) {
    .vh-74 {
        height: 32vh !important;
    }
    .vw-text-testimonial {
        width: 90% !important;
    }
}

@media (max-width: 1499px) {
    .vw-text-testimonial {
        width: 100% !important;
    }
}

@media (min-height: 1500px) {
    .vh-74 {
        height: 65vh !important;
    }
    .vw-text-testimonial {
        width: 50% !important;
    }
}

.vh-75 {
    height: 75vh !important;
}

.vh-78 {
    height: 78vh !important;
}

.vh-82 {
    height: 82vh !important;
}

.vh-85 {
    height: 85vh !important;
}

.vw-92 {
    width: 92vw !important;
}

.testimonial-box {
  width: 100%;
}

/* Desktop: จำกัดความยาวบรรทัดให้อ่านง่าย */
@media (min-width: 992px) {
  .testimonial-box {
    max-width: 90%;
  }
}

/* Desktop ใหญ่มาก */
@media (min-width: 1400px) {
  .testimonial-box {
    max-width: 80%;
  }
}

.testimonial-clamp {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* Mobile: 3 lines */
.testimonial-clamp {
  -webkit-line-clamp: 3;
}

/* Tablet: 4 lines */
@media (min-width: 768px) {
  .testimonial-clamp {
    -webkit-line-clamp: 4;
  }
}

/* Desktop: 5-9 lines */
@media (min-width: 1200px) {
  .testimonial-clamp {
    -webkit-line-clamp: 5;
  }
}
@media (min-width: 1500px) {
  .testimonial-clamp {
    -webkit-line-clamp: 7;
  }
}
@media (min-width: 2000px) {
  .testimonial-clamp {
    -webkit-line-clamp: 9;
  }
}

.ratio-gallery {
    aspect-ratio: 16/9;
}

.ratio-testimonial {
    aspect-ratio: 3/4;
}

.ratio-text {
    aspect-ratio: 2/3;
}

@media (max-width: 769px) {
    .ratio-gallery {
        aspect-ratio: 3/4;
    }
    .ratio-testimonial,
    .ratio-text {
        aspect-ratio: 0;
    }
}

/* Text & Background */
.main-text-color {
    color: #154859 !important;
}

a.main-text-color:hover {
    color: #154859cc !important;
}

.main-bg-color {
    background-color: #F7F4F0 !important;
}

.second-text-color {
    color: #666 !important;
}

.bg-gray{
    background-color: #b1aeab86 !important;
}

.footer {
    color: #2a292a !important;
    font-size: 12px !important;
}

/* Carousel */
.carousel-item {
    transition: transform 2s ease-in-out;
}

.carousel-fade .active.carousel-item-start,
.carousel-fade .active.carousel-item-end {
    transition: opacity 0s 2s;
}

/* Navbar */
.navbar-toggler {
    width: 30px;
    height: 30px;
    position: relative;
    transition: all .5s ease-in-out;
    margin-right: 1rem !important;
}

.navbar-toggler,
.navbar-toggler:focus,
.navbar-toggler:active,
.navbar-toggle-icon:focus {
    outline: none;
    box-shadow: none;
    border: 0;
}

.navbar-toggler span {
    margin: 0;
    padding: 0;
}

@media (max-width: 991.98px) {
    .margin-mw992 {
        margin-top: 0.5rem;
        margin-bottom: 0.5rem;
    }
}

/* Navbar Hamberger to X */
.toggler-icon {
    display: block;
    position: absolute;
    height: 2.5px;
    width: 100%;
    /* background: #daa520; */
    background: #154859;
    border-radius: 1px;
    opacity: 1;
    left: 0;
    transform: rotate(0deg);
    transition: all .7s ease-in-out;
}

.middle-bar {
    margin-top: 0;
}

/* State Wwhen navigation is clicked */
.navbar-toggler .top-bar {
    margin-top: 0;
    transform: rotate(135deg);
}

.navbar-toggler .middle-bar {
    opacity: 0;
    filter: alpha(opacity=0);
    transition: .7s ease-in-out;
    width: 5px;
    height: 5px;
    border-radius: 50%;
}

.navbar-toggler .bottom-bar {
    margin-top: 0px;
    transform: rotate(-135deg);
}

/* State when the navbar is collapsed */
.navbar-toggler.collapsed .top-bar {
    margin-top: -18px;
    transform: rotate(0deg);
    width: 28px;
    height: 2.5px;
    /* border-radius: 50%; */
    /* background: #daa520; */
    background: #2a292a;
}
.navbar-toggler.collapsed:hover .top-bar {
    width: 8px;
}

.navbar-toggler.collapsed .middle-bar {
    opacity: 1;
    filter: alpha(opacity=100);
    transition: .5s ease-in-out;
    width: 18px;
    height: 2.5px;
    /* border-radius: 50%; */
    /* background: #154859; */
    background: #2a292a;
}

.navbar-toggler.collapsed .bottom-bar {
    margin-top: 18px;
    transform: rotate(0deg);
    width: 8px;
    height: 2.5px;
    /* border-radius: 50%; */
    /* background: #666666; */
    background: #2a292a;
}
.navbar-toggler.collapsed:hover .bottom-bar {
    width: 28px;
}
/* //End Navbar Hamberger to X */

@media (min-width:992px) {
    .main-border-color {
        border: solid 1px #154859cc !important;
    }
}

.navbar-collapse {
    margin-left: 2rem;
    transition: all .8s ease-in-out;
}

.nav-link {
    /* margin-left: 1rem !important; */
    /* color: #154859; */
    color: #2a292a;
    display: inline-block;
}

.nav-link:focus {
  outline: none;
  box-shadow: none;
  border: 0;
}

.nav-link:hover:after,
.nav-link.active:after {
    transform: scaleX(1);
}

.nav-link:after {
    display:block;
    content: '';
    border-bottom: solid 2px #154859;  
    border-radius: 5%;
    transform-origin: 0% 50%;
    transform: scaleX(0);
    transition: transform .6s ease-in-out;
}

.nav-link:hover {
    color: #154859;
}

.navbar-nav .nav-link.active, 
.navbar-nav .nav-link.show {
    /* color:#cb9d52 ; */
    /* font-weight: 900; */
    color: #154859;
    padding-bottom: 0px;
    margin-bottom: 0.5rem;
    margin-left: 2rem;
    transition: all .6s ease-in-out;
}

.dropdown-item.active,
.dropdown-item:hover {
    color: #154859;
    background-color: transparent;
}

.animate-dropdown {
  opacity: 0;
  transform: translateY(-10px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.animate-dropdown.dropdown-animate-show {
  opacity: 1;
  transform: translateY(0);
}

.animate-dropdown li {
  opacity: 0;
  transform: translateY(-10px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.animate-dropdown.dropdown-animate-show li:nth-child(1) {
  opacity: 1;
  transform: translateY(0);
  transition-delay: 0.1s;
}

.animate-dropdown.dropdown-animate-show li:nth-child(2) {
  opacity: 1;
  transform: translateY(0);
  transition-delay: 0.2s;
}

/* Zoom Hover */
.gallery_block {
    position: relative;
}

.gallery_image {
    opacity: 1;
    display: block;
    transition: .8s ease-in-out;
    backface-visibility: hidden;
}

.gallery_text {
    opacity: 1;
}

.gallery_block:hover .gallery_image {
    color: #8a5e06;
    transition: .5s ease-in-out;
}

.gallery_block:hover .gallery_text {
    opacity: 1;
}

/* Slide Section */
.box_slide_section {
    overflow-y: scroll;
    scroll-snap-type: y mandatory;
    position: relative;
    top: 0px;
}
.slide_section {
    scroll-snap-align: start;
}

/* Form */
.form-control:focus {
    color: #154859;
    border-color: #15485940;
    box-shadow: 0 0 0 .1rem #15485940;
}

/* Reset styles for non-required fields */
.was-validated .form-control:not(:required) {
    border-color: #ced4da;
    background-color: #ffffff;
    background-image: none;
    border-color: #15485940 !important;
    box-shadow: 0 0 0 .1rem #15485940 !important;
    padding-right: calc(0em + .75rem) !important;
}

.btn-submit {
    color: #ffffff;
    background-color: #154859;
}

.btn-submit:hover,
.btn-submit:active,
.btn:first-child:active {
    color: #154859;
    background-color: #C9F2E9;
    border-color: #a6c8c1;
}

#loading {
    display: none; /* Initially hidden */
    font-size: 16px;
    color: #154859;
    /* background-color: #C9F2E9;
    border-color: #a6c8c1; */
    animation: fadeInOut 2s ease-in-out infinite;
}
@keyframes fadeInOut {
    0%, 100% {
      opacity: 0;
    }
    50% {
      opacity: 1;
    }
  }

.lazy-img {
    opacity: 0;
    transform: translateY(0px);
    transition: opacity 1s ease-out, transform 1s ease-out;
    /* will-change: opacity, transform; */
}

.lazy-img.visible {
    opacity: 1;
    transform: translatY(0);
}

.smooth-transition {
    transition: all 1s ease;
}

#backToTop {
    position: fixed;
    display: flex;
    align-items: center;
    flex-direction: column;
    bottom: 30px;
    right: 15px;
    border: none;
    padding: 6px;
    border-radius: 20px;
    cursor: pointer;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.1s ease;
    z-index: 1000;
    font-size: 0.8rem;
    gap:8;
    background-color: #F7F4F0;
}

#backToTop.show {
    opacity: 0.6;
    pointer-events: auto;
}

#backToTop:active {
    opacity: 0.9;
    transform: scale(0.96);
}

@media (hover: hover) and (pointer: fine) {
    #backToTop:hover {
        opacity: 1;
        color: #154859;
        transform: translateY(-2px);
        box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
    }
}