/**
* Template Name: eNno
* Template URL: https://bootstrapmade.com/enno-free-simple-bootstrap-template/
* Updated: Aug 07 2024 with Bootstrap v5.3.3
* Author: BootstrapMade.com
* License: https://bootstrapmade.com/license/
*/

/*--------------------------------------------------------------
# Font & Color Variables
# Help: https://bootstrapmade.com/color-system/
--------------------------------------------------------------*/
/* Fonts */
:root {
  --default-font: "Roboto",  system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", "Liberation Sans", sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji";
  --heading-font: "Raleway",  sans-serif;
  --nav-font: "Ubuntu",  sans-serif;
}

/* Global Colors - The following color variables are used throughout the website. Updating them here will change the color scheme of the entire website */
:root { 
  --background-color: #ffffff; /* Background color for the entire website, including individual sections */
  --default-color: #444444; /* Default color used for the majority of the text content across the entire website */
  --heading-color: #5f687b; /* Color for headings, subheadings and title throughout the website */
  --accent-color: #10bc69; /* Accent color that represents your brand on the website. It's used for buttons, links, and other elements that need to stand out */
  --surface-color: #ffffff; /* The surface color is used as a background of boxed elements within sections, such as cards, icon boxes, or other elements that require a visual separation from the global background. */
  --contrast-color: #ffffff; /* Contrast color for text, ensuring readability against backgrounds of accent, heading, or default colors. */
}

/* Nav Menu Colors - The following color variables are used specifically for the navigation menu. They are separate from the global colors to allow for more customization options */
:root {
  --nav-color: #5f687b;  /* The default color of the main navmenu links */
  --nav-hover-color: #10bc69; /* Applied to main navmenu links when they are hovered over or active */
  --nav-mobile-background-color: #ffffff; /* Used as the background color for mobile navigation menu */
  --nav-dropdown-background-color: #ffffff; /* Used as the background color for dropdown items that appear when hovering over primary navigation items */
  --nav-dropdown-color: #5f687b; /* Used for navigation links of the dropdown items in the navigation menu. */
  --nav-dropdown-hover-color: #10bc69; /* Similar to --nav-hover-color, this color is applied to dropdown navigation links when they are hovered over. */
}

/* Color Presets - These classes override global colors when applied to any section or element, providing reuse of the sam color scheme. */

.light-background {
  --background-color: #f9f9f9;
  --surface-color: #ffffff;
}

.dark-background {
  --background-color: #060606;
  --default-color: #ffffff;
  --heading-color: #ffffff;
  --surface-color: #252525;
  --contrast-color: #ffffff;
}

.accent-background {
  --background-color: #10bc69;
  --default-color: #ffffff;
  --heading-color: #ffffff;
  --surface-color: #14eb83;
  --contrast-color: #ffffff;
}

/* Smooth scroll */
:root {
  scroll-behavior: smooth;
}

/*--------------------------------------------------------------
# General Styling & Shared Classes
--------------------------------------------------------------*/
body {
  color: var(--default-color);
  background-color: var(--background-color);
  font-family: var(--default-font);
}

a {
  color: var(--accent-color);
  text-decoration: none;
  transition: 0.3s;
}

a:hover {
  color: color-mix(in srgb, var(--accent-color), transparent 25%);
  text-decoration: none;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  color: var(--heading-color);
  font-family: var(--heading-font);
}

/* PHP Email Form Messages
------------------------------*/
.php-email-form .error-message {
  display: none;
  background: #df1529;
  color: #ffffff;
  text-align: left;
  padding: 15px;
  margin-bottom: 24px;
  font-weight: 600;
}

.php-email-form .sent-message {
  display: none;
  color: #ffffff;
  background: #059652;
  text-align: center;
  padding: 15px;
  margin-bottom: 24px;
  font-weight: 600;
}

.php-email-form .loading {
  display: none;
  background: var(--surface-color);
  text-align: center;
  padding: 15px;
  margin-bottom: 24px;
}

.php-email-form .loading:before {
  content: "";
  display: inline-block;
  border-radius: 50%;
  width: 24px;
  height: 24px;
  margin: 0 10px -6px 0;
  border: 3px solid var(--accent-color);
  border-top-color: var(--surface-color);
  animation: php-email-form-loading 1s linear infinite;
}

@keyframes php-email-form-loading {
  0% {
    transform: rotate(0deg);
  }

  100% {
    transform: rotate(360deg);
  }
}

/* Pulsating Play Button
------------------------------*/
.pulsating-play-btn {
  width: 94px;
  height: 94px;
  background: radial-gradient(var(--accent-color) 50%, color-mix(in srgb, var(--accent-color), transparent 75%) 52%);
  border-radius: 50%;
  display: block;
  position: relative;
  overflow: hidden;
}

.pulsating-play-btn:before {
  content: "";
  position: absolute;
  width: 120px;
  height: 120px;
  animation-delay: 0s;
  animation: pulsate-play-btn 2s;
  animation-direction: forwards;
  animation-iteration-count: infinite;
  animation-timing-function: steps;
  opacity: 1;
  border-radius: 50%;
  border: 5px solid color-mix(in srgb, var(--accent-color), transparent 30%);
  top: -15%;
  left: -15%;
  background: rgba(198, 16, 0, 0);
}

.pulsating-play-btn:after {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translateX(-40%) translateY(-50%);
  width: 0;
  height: 0;
  border-top: 10px solid transparent;
  border-bottom: 10px solid transparent;
  border-left: 15px solid #fff;
  z-index: 100;
  transition: all 400ms cubic-bezier(0.55, 0.055, 0.675, 0.19);
}

.pulsating-play-btn:hover:before {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translateX(-40%) translateY(-50%);
  width: 0;
  height: 0;
  border: none;
  border-top: 10px solid transparent;
  border-bottom: 10px solid transparent;
  border-left: 15px solid #fff;
  z-index: 200;
  animation: none;
  border-radius: 0;
}

.pulsating-play-btn:hover:after {
  border-left: 15px solid var(--accent-color);
  transform: scale(20);
}

@keyframes pulsate-play-btn {
  0% {
    transform: scale(0.6, 0.6);
    opacity: 1;
  }

  100% {
    transform: scale(1, 1);
    opacity: 0;
  }
}

/*--------------------------------------------------------------
# Global Header
--------------------------------------------------------------*/
.header {
  color: var(--default-color);
  background-color: var(--background-color);
  padding: 15px 0;
  transition: all 0.5s;
  z-index: 997;
}

.header .logo {
  line-height: 1;
}

.header .logo img {
  max-height: 36px;
  margin-right: 8px;
}

.header .logo h1 {
  font-size: 30px;
  margin: 0;
  font-weight: 700;
  color: var(--heading-color);
}

.header .btn-getstarted,
.header .btn-getstarted:focus {
  color: var(--contrast-color);
  background: var(--accent-color);
  font-size: 14px;
  padding: 8px 25px;
  margin: 0 0 0 30px;
  border-radius: 50px;
  transition: 0.3s;
}

.header .btn-getstarted:hover,
.header .btn-getstarted:focus:hover {
  color: var(--contrast-color);
  background: color-mix(in srgb, var(--accent-color), transparent 15%);
}

@media (max-width: 1200px) {
  .header .logo {
    order: 1;
  }

  .header .btn-getstarted {
    order: 2;
    margin: 0 15px 0 0;
    padding: 6px 15px;
  }

  .header .navmenu {
    order: 3;
  }
}

.scrolled .header {
  box-shadow: 0px 0 18px rgba(0, 0, 0, 0.1);
}

/*--------------------------------------------------------------
# Navigation Menu
--------------------------------------------------------------*/
/* Navmenu - Desktop */
@media (min-width: 1200px) {
  .navmenu {
    padding: 0;
  }

  .navmenu ul {
    margin: 0;
    padding: 0;
    display: flex;
    list-style: none;
    align-items: center;
  }

  .navmenu li {
    position: relative;
  }

  .navmenu a,
  .navmenu a:focus {
    color: var(--nav-color);
    padding: 18px 15px;
    font-size: 16px;
    font-family: var(--nav-font);
    font-weight: 400;
    display: flex;
    align-items: center;
    justify-content: space-between;
    white-space: nowrap;
    transition: 0.3s;
  }

  .navmenu a i,
  .navmenu a:focus i {
    font-size: 12px;
    line-height: 0;
    margin-left: 5px;
    transition: 0.3s;
  }

  .navmenu li:last-child a {
    padding-right: 0;
  }

  .navmenu li:hover>a,
  .navmenu .active,
  .navmenu .active:focus {
    color: var(--nav-hover-color);
  }

  .navmenu .dropdown ul {
    margin: 0;
    padding: 10px 0;
    background: var(--nav-dropdown-background-color);
    display: block;
    position: absolute;
    visibility: hidden;
    left: 14px;
    top: 130%;
    opacity: 0;
    transition: 0.3s;
    border-radius: 4px;
    z-index: 99;
    box-shadow: 0px 0px 30px rgba(0, 0, 0, 0.1);
  }

  .navmenu .dropdown ul li {
    min-width: 200px;
  }

  .navmenu .dropdown ul a {
    padding: 10px 20px;
    font-size: 15px;
    text-transform: none;
    color: var(--nav-dropdown-color);
  }

  .navmenu .dropdown ul a i {
    font-size: 12px;
  }

  .navmenu .dropdown ul a:hover,
  .navmenu .dropdown ul .active:hover,
  .navmenu .dropdown ul li:hover>a {
    color: var(--nav-dropdown-hover-color);
  }

  .navmenu .dropdown:hover>ul {
    opacity: 1;
    top: 100%;
    visibility: visible;
  }

  .navmenu .dropdown .dropdown ul {
    top: 0;
    left: -90%;
    visibility: hidden;
  }

  .navmenu .dropdown .dropdown:hover>ul {
    opacity: 1;
    top: 0;
    left: -100%;
    visibility: visible;
  }
}

/* =========================================
   แก้ไขส่วน Header และ Mobile Menu ให้สมบูรณ์
   ========================================= */

/* ปรับแต่ง Header บนหน้าจอมือถือและแท็บเล็ต (ต่ำกว่า 1200px) */
@media (max-width: 1199px) {
  
  /* จัดเรียง Logo - ปุ่มเริ่มต้น - ปุ่มเมนู ให้อยู่บรรทัดเดียวกัน */
  .header .container-fluid,
  .header .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
  }

  /* 1. ส่วน Logo */
  .header .logo {
    order: 1;
    margin-right: auto; /* ดันส่วนอื่นไปขวาสุด */
  }

  /* 2. ส่วนปุ่มเริ่มต้น (Get Started) - ให้โชว์บนมือถือด้วย */
  .header .btn-getstarted {
    order: 2;
    display: inline-block !important; /* บังคับให้แสดง */
    margin: 0 15px 0 0; /* เว้นระยะห่างจากปุ่มเมนู */
    padding: 6px 18px;
    font-size: 13px; /* ลดขนาดตัวอักษรนิดหน่อยให้พอดีจอเล็ก */
    white-space: nowrap;
  }

  /* 3. ปุ่ม Hamburger (Icon 3 ขีด) */
  .mobile-nav-toggle {
    order: 3;
    display: block; /* แสดงปุ่มเมนู */
    color: var(--nav-color);
    font-size: 28px;
    line-height: 0;
    cursor: pointer;
    transition: 0.5s;
    z-index: 9999;
  }

  /* --- ส่วนของ Menu ที่กดแล้วเด้งออกมา --- */
  .navmenu {
    padding: 0;
    z-index: 9997;
  }

  .navmenu ul {
    display: none; /* ซ่อนไว้ก่อน */
    position: fixed;
    inset: 0 0 0 0; /* เต็มหน้าจอ */
    padding: 50px 20px 20px 20px;
    margin: 0;
    background: rgba(255, 255, 255, 0.95); /* พื้นหลังสีขาวโปร่งแสงนิดๆ */
    overflow-y: auto;
    transition: 0.3s;
    z-index: 9998;
    box-shadow: none;
    align-content: center; /* จัดเมนูให้อยู่กลางจอแนวตั้ง (ถ้าชอบ) */
  }

  /* เมื่อมีการกดเปิดเมนู (ต้องใช้ JS ร่วมด้วย) */
  .mobile-nav-active .navmenu ul {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
  }

  /* ลิงก์ในเมนูมือถือ */
  .navmenu a,
  .navmenu a:focus {
    color: var(--nav-color);
    padding: 15px 20px;
    font-family: var(--nav-font);
    font-size: 18px; /* เพิ่มขนาดตัวหนังสือให้อ่านง่ายบนมือถือ */
    font-weight: 500;
    justify-content: center;
  }

  .navmenu a:hover,
  .navmenu .active,
  .navmenu .active:focus {
    color: var(--accent-color);
  }

  /* ซ่อนปุ่ม Hamburger เมื่อเมนูเปิดอยู่ (แล้วเปลี่ยนเป็นกากบาทแทน ถ้ามี JS รองรับ) */
  .mobile-nav-active .mobile-nav-toggle {
    position: fixed;
    top: 20px;
    right: 20px;
    color: var(--nav-color);
  }
}

/* เพิ่มเติม: ปรับขนาดปุ่มเริ่มต้นสำหรับจอมือถือเล็กมาก (เช่น iPhone SE) */
@media (max-width: 400px) {
  .header .btn-getstarted {
    padding: 5px 12px;
    font-size: 12px;
    margin-right: 10px;
  }
  
  .header .logo h1 {
    font-size: 24px; /* ลดขนาดโลโก้ลงถ้ายาวไป */
  }
}

/*--------------------------------------------------------------
# Global Footer
--------------------------------------------------------------*/
.footer {
  color: var(--default-color);
  background-color: var(--background-color);
  font-size: 14px;
  position: relative;
}

.footer .footer-newsletter {
  background-color: color-mix(in srgb, var(--default-color), transparent 97%);
  padding: 50px 0;
}

.footer .footer-newsletter h4 {
  font-size: 24px;
}

.footer .footer-newsletter .newsletter-form {
  margin-top: 30px;
  margin-bottom: 15px;
  padding: 6px 8px;
  position: relative;
  border-radius: 4px;
  background-color: var(--surface-color);
  border: 1px solid color-mix(in srgb, var(--default-color), transparent 90%);
  box-shadow: 0px 2px 25px rgba(0, 0, 0, 0.1);
  display: flex;
  transition: 0.3s;
  border-radius: 50px;
}

.footer .footer-newsletter .newsletter-form:focus-within {
  border-color: var(--accent-color);
}

.footer .footer-newsletter .newsletter-form input[type=email] {
  border: 0;
  padding: 4px;
  width: 100%;
  background-color: var(--surface-color);
  color: var(--default-color);
}

.footer .footer-newsletter .newsletter-form input[type=email]:focus-visible {
  outline: none;
}

.footer .footer-newsletter .newsletter-form input[type=submit] {
  border: 0;
  font-size: 16px;
  padding: 0 20px;
  margin: -7px -8px -7px 0;
  background: var(--accent-color);
  color: var(--contrast-color);
  transition: 0.3s;
  border-radius: 50px;
}

.footer .footer-newsletter .newsletter-form input[type=submit]:hover {
  background: color-mix(in srgb, var(--accent-color), transparent 20%);
}

.footer .footer-top {
  padding-top: 50px;
}

.footer .social-links a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 1px solid color-mix(in srgb, var(--default-color), transparent 50%);
  font-size: 16px;
  color: color-mix(in srgb, var(--default-color), transparent 20%);
  margin-right: 10px;
  transition: 0.3s;
}

.footer .social-links a:hover {
  color: var(--accent-color);
  border-color: var(--accent-color);
}

.footer h4 {
  font-size: 16px;
  font-weight: bold;
  position: relative;
  padding-bottom: 12px;
}

.footer .footer-links {
  margin-bottom: 30px;
}

.footer .footer-links ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer .footer-links ul i {
  margin-right: 3px;
  font-size: 12px;
  line-height: 0;
  color: var(--accent-color);
}

.footer .footer-links ul li {
  padding: 10px 0;
  display: flex;
  align-items: center;
}

.footer .footer-links ul li:first-child {
  padding-top: 0;
}

.footer .footer-links ul a {
  display: inline-block;
  color: color-mix(in srgb, var(--default-color), transparent 20%);
  line-height: 1;
}

.footer .footer-links ul a:hover {
  color: var(--accent-color);
}

.footer .footer-about a {
  color: var(--heading-color);
  font-size: 26px;
  font-weight: 600;
  font-family: var(--heading-font);
}

.footer .footer-contact p {
  margin-bottom: 5px;
}

.footer .copyright {
  padding: 25px 0;
  border-top: 1px solid color-mix(in srgb, var(--default-color), transparent 90%);
}

.footer .copyright p {
  margin-bottom: 0;
}

.footer .credits {
  margin-top: 6px;
  font-size: 13px;
}

/*--------------------------------------------------------------
# Preloader
--------------------------------------------------------------*/
#preloader {
  position: fixed;
  inset: 0;
  z-index: 999999;
  overflow: hidden;
  background: var(--background-color);
  transition: all 0.6s ease-out;
}

#preloader:before {
  content: "";
  position: fixed;
  top: calc(50% - 30px);
  left: calc(50% - 30px);
  border: 6px solid #ffffff;
  border-color: var(--accent-color) transparent var(--accent-color) transparent;
  border-radius: 50%;
  width: 60px;
  height: 60px;
  animation: animate-preloader 1.5s linear infinite;
}

@keyframes animate-preloader {
  0% {
    transform: rotate(0deg);
  }

  100% {
    transform: rotate(360deg);
  }
}

/*--------------------------------------------------------------
# Scroll Top Button
--------------------------------------------------------------*/
.scroll-top {
  position: fixed;
  visibility: hidden;
  opacity: 0;
  right: 15px;
  bottom: -15px;
  z-index: 99999;
  background-color: var(--accent-color);
  width: 44px;
  height: 44px;
  border-radius: 50px;
  transition: all 0.4s;
}

.scroll-top i {
  font-size: 24px;
  color: var(--contrast-color);
  line-height: 0;
}

.scroll-top:hover {
  background-color: color-mix(in srgb, var(--accent-color), transparent 20%);
  color: var(--contrast-color);
}

.scroll-top.active {
  visibility: visible;
  opacity: 1;
  bottom: 15px;
}

/*--------------------------------------------------------------
# Disable aos animation delay on mobile devices
--------------------------------------------------------------*/
@media screen and (max-width: 768px) {
  [data-aos-delay] {
    transition-delay: 0 !important;
  }
}

/*--------------------------------------------------------------
# Global Page Titles & Breadcrumbs
--------------------------------------------------------------*/
.page-title {
  --background-color: color-mix(in srgb, var(--default-color), transparent 96%);
  color: var(--default-color);
  background-color: var(--background-color);
  padding: 25px 0;
  position: relative;
}

.page-title h1 {
  font-size: 24px;
  font-weight: 700;
}

.page-title .breadcrumbs ol {
  display: flex;
  flex-wrap: wrap;
  list-style: none;
  padding: 0;
  margin: 0;
  font-size: 14px;
  font-weight: 400;
}

.page-title .breadcrumbs ol li+li {
  padding-left: 10px;
}

.page-title .breadcrumbs ol li+li::before {
  content: "/";
  display: inline-block;
  padding-right: 10px;
  color: color-mix(in srgb, var(--default-color), transparent 70%);
}

/*--------------------------------------------------------------
# Global Sections
--------------------------------------------------------------*/
section,
.section {
  color: var(--default-color);
  background-color: var(--background-color);
  padding: 60px 0;
  scroll-margin-top: 100px;
  overflow: clip;
}

@media (max-width: 1199px) {

  section,
  .section {
    scroll-margin-top: 66px;
  }
}

/*--------------------------------------------------------------
# Global Section Titles
--------------------------------------------------------------*/
.section-title {
  text-align: center;
  padding: 30px 0;
  margin-bottom: 30px;
  position: relative;
}

.section-title h2 {
  font-size: 32px;
  font-weight: 700;
  text-transform: uppercase;
  margin-bottom: 20px;
  padding-bottom: 0;
  position: relative;
  z-index: 2;
}

.section-title span {
  position: absolute;
  top: 4px;
  color: color-mix(in srgb, var(--heading-color), transparent 95%);
  left: 0;
  right: 0;
  z-index: 1;
  font-weight: 700;
  font-size: 52px;
  text-transform: uppercase;
  line-height: 1;
}

.section-title p {
  margin-bottom: 0;
  position: relative;
  z-index: 2;
}

@media (max-width: 575px) {
  .section-title h2 {
    font-size: 28px;
    margin-bottom: 15px;
  }

  .section-title span {
    font-size: 38px;
  }
}


/*--------------------------------------------------------------
# Hero Section (Desktop)
--------------------------------------------------------------*/
.hero {
  width: 100%;
  height: 100vh; /* คอมพิวเตอร์: สูงเต็มจอปกติ */
  position: relative;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  
  /* ใส่ภาพพื้นหลัง */
  background: url("../img/home.png") center center no-repeat;
  background-size: cover;
  background-attachment: fixed; /* Parallax สำหรับคอมพิวเตอร์ */
  overflow: hidden;
}

/* แผ่นกรองสีดำ */
.hero::before {
  content: "";
  background: rgba(0, 0, 0, 0.5); 
  position: absolute;
  inset: 0;
  z-index: 1;
}

.hero .container {
  position: relative;
  z-index: 2;
  text-align: center;
}

.hero h1 {
  margin: 0;
  font-size: 56px;
  font-weight: 700;
  line-height: 64px;
  color: #ffffff;
  text-shadow: 2px 2px 10px rgba(0, 0, 0, 0.3);
}

.hero p {
  color: rgba(255, 255, 255, 0.9);
  margin: 20px auto 30px auto;
  font-size: 24px;
  font-weight: 400;
  max-width: 800px;
}

/* ปุ่มกด */
.hero .d-flex {
  justify-content: center;
  gap: 20px;
}

.hero .btn-get-started {
  color: var(--contrast-color);
  background: var(--accent-color);
  font-family: var(--heading-font);
  font-weight: 500;
  font-size: 16px;
  letter-spacing: 1px;
  display: inline-block;
  padding: 12px 32px;
  border-radius: 50px;
  transition: 0.5s;
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.2);
}

.hero .btn-get-started:hover {
  background: color-mix(in srgb, var(--accent-color), transparent 15%);
  transform: scale(1.05);
}

.hero .btn-watch-video {
  font-size: 18px;
  transition: 0.5s;
  color: #ffffff;
  font-weight: 600;
  text-decoration: none;
  display: flex;       /* เพิ่มเพื่อให้จัดไอคอนกับตัวหนังสือได้สวยขึ้น */
  align-items: center; /* จัดกึ่งกลางแนวตั้ง */
}

.hero .btn-watch-video i {
  color: var(--accent-color);
  font-size: 32px;     /* ปรับขนาดไอคอนให้พอดี */
  transition: 0.3s;
  line-height: 0;
  margin-right: 8px;
}

.hero .btn-watch-video:hover {
  color: var(--accent-color);
}

/* กำหนดความสูงให้ Hero Section เต็มหน้าจอ */
#hero {
  width: 100%;
  height: 100vh; /* vh คือความสูงตามขนาดหน้าจอของผู้ใช้ */
  position: relative;
  padding: 0;
  display: flex;
  align-items: center; /* จัดเนื้อหาให้อยู่กึ่งกลางแนวตั้ง */
  overflow: hidden;
}

/* ปรับแต่งรูปภาพให้ขยายเต็มพื้นที่โดยไม่เสียสัดส่วน */
#hero img {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover; /* หัวใจหลักที่ทำให้ภาพเต็มและไม่เบี้ยว */
  z-index: 1;
}

/* จัดระเบียบเนื้อหาให้อยู่บนรูปภาพ */
#hero .container {
  position: relative;
  z-index: 3; /* ให้ข้อความอยู่เหนือรูปภาพ */
}

/* เพิ่ม Overlay สีเข้มเพื่อให้ข้อความอ่านง่ายขึ้น (ถ้าต้องการ) */
#hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.5); /* ปรับความเข้มที่ 0.5 */
  z-index: 2;
}

/*--------------------------------------------------------------
# Responsive สำหรับมือถือ (จุดที่แก้ไขสำคัญ)
--------------------------------------------------------------*/
@media (max-width: 768px) {
  
  .hero {
    /* 1. ลดความสูงลงเหลือ 60-70% ของจอ เพื่อให้ภาพพื้นหลังไม่ต้องซูมมากเกินไป */
    height: 70vh; 
    
    /* 2. ปิด Parallax ในมือถือ เพราะ iPhone ส่วนใหญ่จะแสดงผลเพี้ยน */
    background-attachment: scroll; 
    
    /* 3. บังคับรูปให้อยู่ตรงกลางเสมอ */
    background-position: center center;
  }

  .hero h1 {
    font-size: 28px; /* ลดขนาดตัวอักษรลงอีกนิดเพื่อไม่ให้บังหน้าคน */
    line-height: 36px;
  }

  .hero p {
    font-size: 16px;
    line-height: 24px;
    margin-bottom: 20px; /* ลดระยะห่าง */
  }

  /* ปุ่มกดในมือถือ */
  .hero .d-flex {
    flex-direction: column; /* เรียงปุ่มลงมาแนวตั้ง */
    align-items: center;    /* จัดปุ่มให้อยู่ตรงกลาง */
    gap: 15px;
  }
  
  .hero .btn-watch-video {
    margin-left: 0;
  }
}
/*--------------------------------------------------------------
# Featured Services Section
--------------------------------------------------------------*/
.featured-services {
  --surface-color: color-mix(in srgb, var(--default-color), transparent 96%);
  padding-top: 0;
}

.featured-services .service-item {
  background-color: var(--surface-color);
  padding: 50px 30px;
  transition: all ease-in-out 0.4s;
  height: 100%;
}

.featured-services .service-item .icon {
  margin-bottom: 10px;
}

.featured-services .service-item .icon i {
  color: var(--accent-color);
  font-size: 36px;
  transition: 0.3s;
}

.featured-services .service-item h4 {
  font-weight: 700;
  margin-bottom: 15px;
  font-size: 20px;
}

.featured-services .service-item h4 a {
  color: var(--heading-color);
  transition: ease-in-out 0.3s;
}

.featured-services .service-item p {
  line-height: 24px;
  font-size: 14px;
  margin-bottom: 0;
}

.featured-services .service-item:hover {
  transform: translateY(-10px);
}

.featured-services .service-item:hover h4 a {
  color: var(--accent-color);
}

/*--------------------------------------------------------------
# About Section
--------------------------------------------------------------*/
.about .content h3 {
  font-size: 1.75rem;
  font-weight: 700;
}

.about .content ul {
  list-style: none;
  padding: 0;
}

.about .content ul li {
  padding: 10px 0 0 0;
  display: flex;
}

.about .content ul i {
  color: var(--accent-color);
  margin-right: 0.5rem;
  line-height: 1.2;
  font-size: 1.25rem;
}

.about .content p:last-child {
  margin-bottom: 0;
}

.about .pulsating-play-btn {
  position: absolute;
  left: calc(50% - 47px);
  top: calc(50% - 47px);
}

/*--------------------------------------------------------------
# Stats Section
--------------------------------------------------------------*/
.stats {
  padding-top: 0;
}

.stats .stats-item {
  padding: 30px;
  width: 100%;
}

.stats .stats-item span {
  font-size: 48px;
  display: block;
  color: var(--accent-color);
  font-weight: 700;
}

.stats .stats-item p {
  color: color-mix(in srgb, var(--default-color), transparent 40%);
  padding: 0;
  margin: 0;
  font-family: var(--heading-font);
  font-size: 15px;
  font-weight: 600;
}

/*--------------------------------------------------------------
# Services Section
--------------------------------------------------------------*/
/* .services .service-item {
  background-color: var(--surface-color);
  text-align: center;
  border: 1px solid color-mix(in srgb, var(--default-color), transparent 85%);
  padding: 80px 20px;
  transition: border ease-in-out 0.3s;
  height: 100%;
}

.services .service-item .icon {
  margin: 0 auto;
  width: 64px;
  height: 64px;
  background: var(--accent-color);
  border-radius: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
  transition: 0.3s;
}

.services .service-item .icon i {
  color: var(--contrast-color);
  font-size: 28px;
  transition: ease-in-out 0.3s;
}

.services .service-item h3 {
  font-weight: 700;
  margin: 10px 0 15px 0;
  font-size: 22px;
  transition: 0.3s;
}

.services .service-item p {
  line-height: 24px;
  font-size: 14px;
  margin-bottom: 0;
}

.services .service-item:hover {
  border-color: var(--accent-color);
}

.services .service-item:hover h3 {
  color: var(--accent-color);
}

.service-main-img {
  width: 100%;       
  height: 250px;     
  object-fit: cover; 
  display: block;
  border-radius: 8px; 
} */


/* ล็อคขนาดการ์ดแนวนอน */
.service-horizontal-card {
    background: #fff;
    display: flex;
    align-items: flex-start; /* จัดให้ข้อความเริ่มจากด้านบน */
    padding: 12px;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.08);
    height: 100%; /* ให้ทุกอันในแถวสูงเท่ากัน */
    border: 1px solid transparent;
    transition: all 0.3s ease;
}

.service-horizontal-card:hover {
    border-color: #28a745;
    transform: translateY(-3px);
}

/* ล็อคขนาดรูปภาพให้เป็นสี่เหลี่ยมจัตุรัสเล็กๆ */
.service-horizontal-card .img-container {
    width: 70px;  /* ขนาดความกว้างรูป */
    height: 70px; /* ขนาดความสูงรูป */
    flex-shrink: 0; /* ป้องกันรูปโดนบีบ */
    overflow: hidden;
    border-radius: 8px;
}

.service-horizontal-card .img-container img {
    width: 100%;
    height: 100%;
    object-fit: cover; /* รูปไม่เบี้ยวแน่นอน */
}

/* จัดการส่วนข้อความด้านขวา */
.service-horizontal-card .text-container {
    padding-left: 15px;
}

.service-horizontal-card .text-container h4 {
    font-size: 16px;
    font-weight: 700;
    color: #10600c;
    margin-bottom: 6px;
    line-height: 1.2;
}

.service-horizontal-card .text-container p {
    font-size: 13px;
    color: #666;
    margin-bottom: 0;
    line-height: 1.5;
    /* ตัดคำอัตโนมัติถ้าเกิน 3 บรรทัด เพื่อให้การ์ดไม่ยาวพุ่งลงมา */
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* ล็อคขนาดรูปในกิจกรรมให้เท่ากันทุกรูป */
.activity-img {
    width: 100%;
    height: 250px; /* กำหนดความสูงที่ต้องการ (ปรับตัวเลขได้ตามความเหมาะสม) */
    overflow: hidden; /* ซ่อนส่วนเกิน */
}

.activity-img img {
    width: 100%;
    height: 100%;
    object-fit: cover; /* หัวใจสำคัญ! ช่วยให้รูปเต็มกรอบโดยสัดส่วนไม่เพี้ยน (ตัดส่วนเกินออก) */
    object-position: center; /* จัดให้รูปอยู่กึ่งกลาง */
}

.activity-item:hover {
    transform: translateY(-10px); /* ลอยขึ้นเมื่อ hover */
    box-shadow: 0 15px 45px rgba(0,0,0,0.12);
}

/* ส่วนของเนื้อหา (Title + Description) */
.activity-content {
    display: flex;
    flex-direction: column;
    flex-grow: 1; 
    padding: 20px; /* เว้นระยะห่างภายในกล่องเนื้อหา */
}

/* คำอธิบายเนื้อหา */
.activity-content .description {
    flex-grow: 1; /* ยืดพื้นที่เพื่อดันปุ่มลงไปด้านล่างสุด */
    margin-bottom: 20px;
}

/* ปรับปรุงส่วนของปุ่มให้อยู่ด้านซ้าย */
.activity-content a.btn {
    align-self: flex-start; /* บังคับให้ปุ่มชิดซ้าย */
    margin-top: auto;      /* ดันปุ่มลงล่างสุดของ Card */
    width: fit-content;    /* ขนาดปุ่มกว้างตามเนื้อหาข้อความ */
}



/*** Activity Design Custom ***/


/* =========================================
   1. ส่วนจัดการรูปภาพและ Slider (หัวใจสำคัญ)
   ========================================= */

/* กล่องควบคุมสัดส่วน 16:9 */
.activity-media-box {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 9; /* บังคับสัดส่วนแนวนอน */
    overflow: hidden;
    background-color: #000; /* พื้นหลังดำกันภาพโหลดไม่ทัน */
    border-radius: 10px;
}

/* ตั้งค่าให้ Swiper เต็มพื้นที่กล่อง */
.activity-media-box .swiper {
    width: 100%;
    height: 100%;
}

/* --- จุดแก้ไขสำคัญ (ห้ามแก้) --- */
/* ปล่อยให้ Slide มีขนาดตามที่ Swiper คำนวณ แต่บังคับความสูง */
.activity-media-box .swiper-slide {
    height: 100%; 
    display: flex;
    justify-content: center;
    align-items: center;
    /* ห้ามใส่ width: 100% !important ตรงนี้ เพราะจะทำให้รูป 2-10 หาย */
}

/* บังคับรูปภาพและวิดีโอให้เต็มกรอบและตัดส่วนเกิน (Crop) */
.activity-media-box img,
.activity-media-box video,
.activity-media-box .swiper-slide img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover; /* ตัดส่วนเกินของภาพแนวตั้งทิ้ง */
    object-position: center 20%; /* เลื่อนจุดโฟกัสขึ้นบนเล็กน้อย (เผื่อหัวคน) */
}

/* ปรับแต่งปุ่มลูกศร */
.activity-media-box .swiper-button-prev,
.activity-media-box .swiper-button-next {
    color: #fff;
    background: rgba(0,0,0,0.3);
    width: 40px;
    height: 40px;
    border-radius: 50%;
    transition: 0.3s;
}
.activity-media-box .swiper-button-prev:after,
.activity-media-box .swiper-button-next:after {
    font-size: 18px;
    font-weight: bold;
}
.activity-media-box .swiper-button-prev:hover,
.activity-media-box .swiper-button-next:hover {
    background: #28a745;
}

/* =========================================
   2. ส่วนการ์ดและเนื้อหา (Design)
   ========================================= */

/* ฟอนต์หัวข้อ */
.activity-content .title { 
    font-family: 'Sarabun', sans-serif; 
    font-weight: 700;
    color: #10600c; 
    font-size: 1.25rem; 
    margin-bottom: 10px;
    transition: 0.5s; 
}

/* กล่องการ์ดหลัก */
.activity-item {
    position: relative;
    border-radius: 10px;
    overflow: hidden;
    transition: 0.5s;
    background: #f0f5fb;
    height: 100%; 
    display: flex;
    flex-direction: column;
}

.activity-content {
    padding: 20px;
    flex-grow: 1; 
    display: flex;
    flex-direction: column;
}

.activity-content .description {
    color: #666;
    transition: 0.5s;
    margin-bottom: 15px;
    flex-grow: 1; 
}

/* ปุ่มกด */
.btn-custom {
    background: #28a745;
    color: #fff;
    border: 2px solid #28a745;
    padding: 8px 20px;
    border-radius: 30px;
    transition: 0.5s;
    font-family: 'Sarabun', sans-serif;
    width: fit-content; 
    text-decoration: none;
    display: inline-block;
}

/* ไอคอนมุมขวาล่าง */
.activity-icon {
    position: absolute;
    bottom: -50px; 
    right: 20px;
    width: 50px;
    height: 50px;
    background: #f0f5fb;
    color: #28a745;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    z-index: 10;
    transition: 0.5s;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}

/* =========================================
   3. Hover Effects (เอฟเฟกต์ตอนชี้)
   ========================================= */

.activity-item:hover {
    background: #28a745; 
    transform: translateY(-5px); 
    box-shadow: 0 10px 20px rgba(0,0,0,0.15);
}

/* ซูมภาพเมื่อชี้ */
.activity-item:hover .activity-media-box img,
.activity-item:hover .activity-media-box video {
    transform: scale(1.1); 
    transition: transform 0.8s ease;
}

.activity-item:hover .activity-content .title,
.activity-item:hover .activity-content .description,
.activity-item:hover .activity-content i,
.activity-item:hover .activity-content span,
.activity-item:hover .activity-content h6,
.activity-item:hover .activity-content p,
.activity-item:hover .activity-content li {
    color: #fff !important; 
}

/* ยกเว้น Badge วันที่ให้คงสีเดิมไว้ หรือปรับตามชอบ */
.activity-item:hover .badge {
    background-color: rgba(255,255,255,0.9) !important;
    color: #000 !important;
}

.activity-item:hover .btn-custom {
    background: #fff;
    color: #28a745;
    border-color: #fff;
}

.activity-item:hover .activity-icon {
    bottom: 20px; 
    background: #fff;
    color: #28a745;
}

/* =========================================
   4. Mobile Responsive (มือถือ)
   ========================================= */

@media (max-width: 768px) {
    /* ย้ำสัดส่วน 16:9 ในมือถือ */
    .activity-media-box {
        aspect-ratio: 16 / 9;
        height: auto;
    }
    
    .activity-content {
        padding: 15px;
    }

    .activity-content .title {
        font-size: 1.1rem;
    }
    
    .activity-content .description {
        font-size: 0.9rem;
    }

    .activity-item:hover {
        transform: translateY(-2px);
    }
    
    .btn-custom {
        padding: 6px 15px;
        font-size: 0.9rem;
    }
}
/*--------------------------------------------------------------
# Call To Action Section
--------------------------------------------------------------*/
.call-to-action {
  padding: 80px 0;
  position: relative;
  clip-path: inset(0);
}

.call-to-action img {
  position: fixed;
  top: 0;
  left: 0;
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 1;
}

.call-to-action:before {
  content: "";
  background: color-mix(in srgb, var(--background-color), transparent 50%);
  position: absolute;
  inset: 0;
  z-index: 2;
}

.call-to-action .container {
  position: relative;
  z-index: 3;
}

.call-to-action h3 {
  font-size: 28px;
  font-weight: 700;
  color: var(--default-color);
}

.call-to-action p {
  color: var(--default-color);
}

.call-to-action .cta-btn {
  font-family: var(--heading-font);
  font-weight: 500;
  font-size: 16px;
  letter-spacing: 1px;
  display: inline-block;
  padding: 12px 40px;
  border-radius: 50px;
  transition: 0.5s;
  margin: 10px;
  border: 2px solid var(--contrast-color);
  color: var(--contrast-color);
}

.call-to-action .cta-btn:hover {
  background: color-mix(in srgb, var(--accent-color) 90%, white 15%);
}




/*--------------------------------------------------------------
# Contact Section
--------------------------------------------------------------*/
.contact .info-wrap {
  padding: 30px;
  background: var(--surface-color, #ffffff);
  box-shadow: 0px 0px 20px rgba(0, 0, 0, 0.1);
  border-radius: 10px;
}

@media (max-width: 575px) {
  .contact .info-wrap {
    padding: 20px;
  }
}

.contact .info-item {
  margin-bottom: 40px;
}

.contact .info-item i {
  font-size: 20px;
  color: var(--accent-color);
  background: color-mix(in srgb, var(--accent-color), transparent 92%);
  width: 66px;
  height: 66px;
  display: flex;
  justify-content: center;
  align-items: center;
  border-radius: 50px;
  transition: all 0.3s ease-in-out;
  margin-right: 15px;
}

.contact .info-item h3 {
  padding: 0;
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 5px;
}

.contact .info-item p {
  padding: 0;
  margin-bottom: 0;
  font-size: 14px;
}

.contact .info-item:hover i {
  background: var(--accent-color);
  color: var(--contrast-color);
}

.contact .php-email-form {
  background-color: var(--surface-color);
  height: 100%;
  padding: 30px;
  box-shadow: 0px 0px 20px rgba(0, 0, 0, 0.1);
}

@media (max-width: 575px) {
  .contact .php-email-form {
    padding: 20px;
  }
}

.contact .php-email-form input[type=text],
.contact .php-email-form input[type=email],
.contact .php-email-form textarea {
  font-size: 14px;
  padding: 10px 15px;
  box-shadow: none;
  border-radius: 0;
  color: var(--default-color);
  background-color: var(--surface-color);
  border-color: color-mix(in srgb, var(--default-color), transparent 80%);
}

.contact .php-email-form input[type=text]:focus,
.contact .php-email-form input[type=email]:focus,
.contact .php-email-form textarea:focus {
  border-color: var(--accent-color);
}

.contact .php-email-form input[type=text]::placeholder,
.contact .php-email-form input[type=email]::placeholder,
.contact .php-email-form textarea::placeholder {
  color: color-mix(in srgb, var(--default-color), transparent 70%);
}

.contact .php-email-form button[type=submit] {
  color: var(--contrast-color);
  background: var(--accent-color);
  border: 0;
  padding: 10px 30px;
  transition: 0.4s;
  border-radius: 50px;
}

.contact .php-email-form button[type=submit]:hover {
  background: color-mix(in srgb, var(--accent-color), transparent 25%);
}

/*--------------------------------------------------------------
# Portfolio Details Section
--------------------------------------------------------------*/
/* --- ส่วนปรับแต่งหน้า Portfolio Details ให้กว้างเต็มจอ --- */

/* ปรับระยะห่างของ Section หลัก */
.portfolio-details {
  padding: 60px 0;
}

/* ปรับแต่งรูปภาพฝั่งซ้าย */
.portfolio-details .portfolio-details-slider img {
  width: 100%;
  border-radius: 15px; /* มุมมนตามรูปตัวอย่าง */
  box-shadow: 0px 10px 30px rgba(0, 0, 0, 0.1);
  transition: 0.3s;
}

/* ปรับแต่งกล่องข้อมูลฝั่งขวา */
.portfolio-details .portfolio-info {
  background-color: #f8fbf8; /* สีเขียวอ่อนๆ ตามโทนใหม่ */
  padding: 30px;
  box-shadow: 0px 2px 20px rgba(0, 0, 0, 0.05);
  border-radius: 10px;
  border-left: 5px solid #28a745; /* เพิ่มแถบสีเขียวด้านซ้าย */
}

.portfolio-details .portfolio-info h3 {
  font-size: 22px;
  font-weight: 700;
  margin-bottom: 20px;
  padding-bottom: 10px;
  border-bottom: 1px solid #eee;
  color: #2c3e50;
}

.portfolio-details .portfolio-info ul {
  list-style: none;
  padding: 0;
}

.portfolio-details .portfolio-info ul li {
  display: flex;
  justify-content: space-between; /* จัดหัวข้อซ้าย ข้อมูลขวา */
  padding: 10px 0;
  border-bottom: 1px dashed #e2e2e2;
}

.portfolio-details .portfolio-info ul li:last-child {
  border-bottom: none;
}

.portfolio-details .portfolio-info ul li strong {
  color: #28a745;
  text-transform: uppercase;
  font-size: 14px;
}

/* รายละเอียด Description */
.portfolio-details .portfolio-description {
  padding-top: 30px;
}

.portfolio-details .portfolio-description h2 {
  font-size: 26px;
  font-weight: 700;
  margin-bottom: 15px;
  color: #28a745; /* หัวข้อสีเขียว */
}

.portfolio-details .portfolio-description p {
  font-size: 16px;
  line-height: 1.8;
  color: #444;
  text-align: justify;
}

/* เมื่อดูในมือถือ ให้รูปอยู่บน ข้อความอยู่ล่างตามปกติ */
@media (max-width: 991px) {
  .portfolio-details .portfolio-info {
    margin-top: 30px;
  }
}

/* ปรับแต่งส่วนเนื้อหาเพิ่มเติม */
.activity-details .activity-date-title {
      font-family: 'Sarabun', sans-serif;
      font-weight: 700;
      color: #28a745;
      border-left: 5px solid #28a745;
      padding-left: 15px;
      margin-bottom: 20px;
}

.activity-details .activity-description h4 {
      font-family: 'Sarabun', sans-serif;
      font-weight: 700;
      line-height: 1.5;
}

.activity-details .content-text p {
      font-family: 'Sarabun', sans-serif;
      font-size: 16px;
      line-height: 1.8;
      color: #444;
      text-align: justify;
}

.activity-details-slider img {
      width: 100%;
      border-radius: 15px;
      box-shadow: 0px 10px 30px rgba(0, 0, 0, 0.1);
}

    /* สไตล์ Swiper ให้เลื่อนทีละภาพ */
.activity-details-slider .swiper-slide {
      background-size: cover;
      background-position: center;
}

/* ควบคุมวิดีโอใน Slider */
.video-container {
    position: relative;
    width: 100%;
    background: #000; /* พื้นหลังสีดำกันขอบวิดีโอไม่เต็ม */
    border-radius: 15px;
    overflow: hidden;
    line-height: 0; /* แก้ไขช่องว่างใต้ video */
}

.video-container video {
    max-height: 450px; /* กำหนดความสูงสูงสุดเพื่อให้ดูสวยงาม */
    object-fit: contain; /* ให้วิดีโอคงสัดส่วนเดิม */
}

/* ปรับสีปุ่ม Navigation ของ Swiper ให้เห็นชัดขึ้นบนวิดีโอ */
.swiper-button-next, .swiper-button-prev {
    color: #28a745 !important;
}

.activity-details-slider .swiper-pagination-bullet-active {
    background-color: #28a745 !important;
}



/*--------------------------------------------------------------
# Starter Section Section
--------------------------------------------------------------*/
.starter-section {
  /* Add your styles here */
}

ul {
  list-style: none;
  padding: 0;
  margin: 0;
}