:root {
            --primary-color: #0f172a; /* Deep Slate Blue */
            --accent-color: #0ea5e9; /* Cyan Sea */
            --accent-gradient: linear-gradient(135deg, #0ea5e9 0%, #2563eb 100%);
            --light-bg: #ffffff;
        }

        body {
            font-family: 'Sarabun', sans-serif;
            background-color: var(--light-bg);
            color: #334155;
            overflow-x: hidden;
        }

        .sarabun-thin {
  font-family: "Sarabun", sans-serif;
  font-weight: 100;
  font-style: normal;
}

.sarabun-extralight {
  font-family: "Sarabun", sans-serif;
  font-weight: 200;
  font-style: normal;
}

.sarabun-light {
  font-family: "Sarabun", sans-serif;
  font-weight: 300;
  font-style: normal;
}

.sarabun-regular {
  font-family: "Sarabun", sans-serif;
  font-weight: 400;
  font-style: normal;
}

.sarabun-medium {
  font-family: "Sarabun", sans-serif;
  font-weight: 500;
  font-style: normal;
}

.sarabun-semibold {
  font-family: "Sarabun", sans-serif;
  font-weight: 600;
  font-style: normal;
}

.sarabun-bold {
  font-family: "Sarabun", sans-serif;
  font-weight: 700;
  font-style: normal;
}

.sarabun-extrabold {
  font-family: "Sarabun", sans-serif;
  font-weight: 800;
  font-style: normal;
}

.sarabun-thin-italic {
  font-family: "Sarabun", sans-serif;
  font-weight: 100;
  font-style: italic;
}

.sarabun-extralight-italic {
  font-family: "Sarabun", sans-serif;
  font-weight: 200;
  font-style: italic;
}

.sarabun-light-italic {
  font-family: "Sarabun", sans-serif;
  font-weight: 300;
  font-style: italic;
}

.sarabun-regular-italic {
  font-family: "Sarabun", sans-serif;
  font-weight: 400;
  font-style: italic;
}

.sarabun-medium-italic {
  font-family: "Sarabun", sans-serif;
  font-weight: 500;
  font-style: italic;
}

.sarabun-semibold-italic {
  font-family: "Sarabun", sans-serif;
  font-weight: 600;
  font-style: italic;
}

.sarabun-bold-italic {
  font-family: "Sarabun", sans-serif;
  font-weight: 700;
  font-style: italic;
}

.sarabun-extrabold-italic {
  font-family: "Sarabun", sans-serif;
  font-weight: 800;
  font-style: italic;
}


.maxwimg{
  max-width: 100%;
  margin: 0 auto;
}

.lazy-img-fade {
    opacity: 0;
    transition: opacity 0.5s ease-in-out;
    will-change: opacity;
}

/* เมื่อ Lozad ทำการโหลดภาพจริงเข้ามาเสร็จแล้ว มันจะใส่ attribute data-loaded="true" ให้โดยอัตโนมัติ */
.lazy-img-fade[data-loaded="true"] {
    opacity: 1;
}

.flex-item {
    flex: 0 0 50%;
}

.boxximg{
    width: 150px;
}

@media (min-width: 768px) {
    .flex-item {
        flex: 1; /* แบ่งพื้นที่แนวตั้งให้เท่ากันทุกบล็อกโดยอัตโนมัติ */
    }


}

/* เพิ่มระยะห่างให้ไอคอนกับข้อความนิดนึง */
.gap-1\.5 {
    gap: 0.35rem;
}

.subcountry-card {
        position: relative;
        overflow: hidden;
        border-radius: 18px;
        height: 220px; /* เพิ่มความสูงให้เห็นรูปภาพแบนเนอร์ชัดเจนขึ้น */
        box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
        transition: transform 0.3s ease, box-shadow 0.3s ease;
    }
    .subcountry-card:hover {
        transform: translateY(-6px);
        box-shadow: 0 12px 25px rgba(0, 0, 0, 0.15);
    }
    .subcountry-bg {
        position: absolute;
        top: 0; left: 0; width: 100%; height: 100%;
        background-size: cover;
        background-position: center;
        transition: transform 0.5s ease;
    }
    .subcountry-card:hover .subcountry-bg {
        transform: scale(1.08);
    }
    .subcountry-overlay {
        position: absolute;
        top: 0; left: 0; width: 100%; height: 100%;
        background: linear-gradient(to top, rgba(0,0,0,0.75) 0%, rgba(0,0,0,0.2) 60%, rgba(0,0,0,0.05) 100%);
        display: flex;
        align-items: flex-end;
        padding: 20px;
    }
    .subcountry-title {
        color: #ffffff;
        font-weight: 600;
        font-size: 1.2rem;
        margin: 0;
        text-shadow: 0 2px 4px rgba(0,0,0,0.4);
    }

    /* ─── 🚀 โครงสร้างระบบสไลด์เลื่อน (Carousel Wrapper) ─── */
    .carousel-container-wrapper {
        position: relative;
        display: flex;
        align-items: center;
    }
    .subcountry-slider {
        display: flex;
        overflow-x: auto;
        scroll-behavior: smooth;
        gap: 20px; /* ระยะห่างระหว่างการ์ด */
        padding: 10px 5px 20px 5px;
        scrollbar-width: none; /* ซ่อนแถบเลื่อนบน Firefox */
    }
    .subcountry-slider::-webkit-scrollbar {
        display: none; /* ซ่อนแถบเลื่อนบน Chrome, Safari */
    }
    .subcountry-slide-item {
        flex: 0 0 calc(25% - 15px); /* หน้าจอคอมพิวเตอร์แสดงแถวละ 4 กล่อง */
        min-width: 250px;
    }
    
    /* ปุ่มควบคุม ซ้าย - ขวา (โชว์เฉพาะหน้าจอคอม) */
    .slide-control-btn {
        position: absolute;
        width: 45px;
        height: 45px;
        background: #ffffff;
        border: 1px solid #e2e8f0;
        border-radius: 50%;
        display: flex;
        align-items: center;
        justify-content: center;
        font-size: 1.25rem;
        color: #1e293b;
        cursor: pointer;
        z-index: 10;
        box-shadow: 0 4px 12px rgba(0,0,0,0.1);
        transition: all 0.2s ease;
    }
    .slide-control-btn:hover {
        background: #1e3a8a;
        color: #ffffff;
        transform: scale(1.05);
    }
    .btn-prev { left: -22px; }
    .btn-next { right: -22px; }

    /* ปรับแต่งการตอบสนองตามขนาดหน้าจอ (Responsive) */
    @media (max-width: 991px) {
        .subcountry-slide-item { flex: 0 0 calc(33.333% - 14px); } /* แท็บเล็ตโชว์ 3 กล่อง */
    }
    @media (max-width: 767px) {
        .subcountry-slide-item { flex: 0 0 calc(50% - 10px); } /* มือถือจอใหญ่โชว์ 2 กล่อง */
        .slide-control-btn { display: none; } /* บนมือถือใช้นิ้วปัดเลื่อนแทน ซ่อนปุ่มเพื่อไม่ให้เกะกะ */
            .boxximg{
    width: 100%;
}
    }
    @media (max-width: 480px) {
        .subcountry-slide-item { flex: 0 0 75%; } /* มือถือจอเล็กโชว์การ์ดใหญ่ขึ้นและเยื้องเห็นใบถัดไป */
    }

.thankyou-card {
            max-width: 550px;
            width: 100%;
            border: none;
            border-radius: 24px;
            box-shadow: 0 10px 30px rgba(0, 0, 0, 0.04);
            background: #ffffff;
            padding: 2.5rem;
        }
        .success-icon-box {
            width: 80px;
            height: 80px;
            background-color: #e6f4ea;
            color: #137333;
            border-radius: 50%;
            display: flex;
            align-items: center;
            justify-content: center;
            margin: 0 auto 1.5rem auto;
            font-size: 2.5rem;
            animation-name: scaleUp;
animation-duration: 0.4s;
animation-timing-function: ease-out;
animation-fill-mode: forwards;
        }
        @keyframes scaleUp {
            0% { transform: scale(0.7); opacity: 0; }
            100% { transform: scale(1); opacity: 1; }
        }

.booking-card { border: none; border-radius: 16px; box-shadow: 0 4px 20px rgba(0,0,0,0.05); }
        /*.tour-header-box { background: linear-gradient(135deg, #1e3a8a, #2563eb); color: white; border-radius: 12px; }*/


        /* Nav custom transition */
     /*   .navbar {
            background-color: rgba(15, 23, 42, 0.95) !important;

        }*/

        /* Modern Card Styling */
        .tour-card {
            border: none;
            border-radius: 16px;
            overflow: hidden;
            background: #ffffff;
            box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
            transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
            height: 100%;
            display: flex;
            flex-direction: column;
        }

        .tour-card:hover {
            transform: translateY(-8px);
            box-shadow: 0 12px 30px rgba(14, 165, 233, 0.15);
        }

        .tour-image-container {
            position: relative;
            overflow: hidden;
    
        }

        .tour-image {
            position: absolute;
            top: 0;
            left: 0;
            width: 100%;
            height: 100%;
            object-fit: cover;
            transition: transform 0.6s ease;
        }

        .tour-card:hover .tour-image {
            transform: scale(1.08);
        }

        /* Badges */
        .badge-status {
            position: absolute;
            top: 10px;
            z-index: 10;
            font-weight: 500;
            padding: 6px 14px;
            border-radius: 30px;
            font-size: 0.8rem;
            /*box-shadow: 0 4px 10px rgba(0,0,0,0.15);*/
        }

        .badge-hot {
            background-color: #8B0000;
            color: #ffffff;
        }

        .badge-recommended {
            /*background-image: var(--accent-gradient);*/
            color: white;
        }

        .badge-new {
            background-color: #10b981;
            color: white;
        }

        /* Section Title Styling */
        .section-title {
            position: relative;
            font-weight: 700;
            color: var(--primary-color);
            margin-bottom: 1rem;
        }

        .section-title::after {
            content: '';
            position: absolute;
            bottom: -10px;
            left: 50%;
            transform: translateX(-50%);
            width: 80px;
            height: 4px;
            /*background: var(--accent-gradient);*/
            border-radius: 2px;
        }

        /* Profile booking section styling */
        .booking-agent-card {
            background: #ffffff;
            border-radius: 24px;
            box-shadow: 0 10px 40px rgba(0, 0, 0, 0.08);
            /*border-left: 6px solid #0ea5e9;*/
        }

        .agent-photo {
            width: 130px;
            height: 130px;
            object-fit: cover;
            border: 4px solid #fff;
            box-shadow: 0 8px 20px rgba(0,0,0,0.15);
        }

        /* Country card hover style */
       /* ─── 📦 ตัวการ์ดหลัก (เปลี่ยนให้ลอยขึ้นด้านบนขนานกับแกน Y แทนการซูมทั้งกล่อง) ─── */
.country-card {
    border-radius: 20px;
    overflow: hidden;
    position: relative;
    height: 220px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05); /* เงานุ่มๆ ตอนเริ่มต้น */
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border: none;
}

/* เอฟเฟกต์ตอน Hover: ตัวการ์ดจะขยับยกตัวลอยขึ้น 6px และเงาจะกระจายหนาขึ้น */
.country-card:hover {
    transform: translateY(-6px); 
    box-shadow: 0 12px 25px rgba(0, 0, 0, 0.15);
}

/* ─── 🖼️ ภาพพื้นหลัง (เพิ่มส่วนนี้เพื่อให้ภาพซูมได้แบบไม่ล้นขอบกล่อง) ─── */
.country-bg {
    position: absolute;
    top: 0; 
    left: 0; 
    width: 100%; 
    height: 100%;
    background-size: cover;
    background-position: center;
    transition: transform 0.6s ease; /* ปรับตรงนี้ให้ภาพซูมนุ่มขึ้น */
}
/* เอฟเฟกต์ตอน Hover: สั่งให้ภาพซูมใหญ่ขึ้น 8% */
.country-card:hover .country-bg {
    transform: scale(1.12);
}

/* ─── 🖤 แผ่นฟิล์มสีดำไล่เฉด (ให้อยู่คงที่ ไม่ยืดขึ้นเต็มหน้าจอแล้ว) ─── */
.country-overlay {
    position: absolute;
    top: 0; 
    left: 0; 
    width: 100%; 
    height: 100%;
    /* ปรับเป็นไล่เฉดนุ่มๆ จากล่างขึ้นบน */
    background: linear-gradient(to top, rgba(0,0,0,0.75) 0%, rgba(0,0,0,0.2) 60%, rgba(0,0,0,0.05) 100%);
    display: flex;
    align-items: flex-end;
    padding: 1.5rem;
    color: white;
    z-index: 2;
}
        /* Back to top button */
        #back-to-top {
            position: fixed;
            bottom: 30px;
            right: 30px;
            display: none;
            z-index: 99;
            border-radius: 50%;
            width: 50px;
            height: 50px;
            box-shadow: 0 4px 15px rgba(0,0,0,0.2);
        }

        .fs14{
            font-size: 14px;
        }

        .fs16{
            font-size: 16px;
        }

        .fs12{
            font-size: 12px;
        }

        .fs18{
            font-size: 18px;
        }

        .icwv{
    width: 42px;
    max-width: 42px;
}

.tour-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 8px;
}

.tour-badge {
    padding: 4px 12px;
    font-size: 14px;
    font-weight: 600;
    border-radius: 999px;
    white-space: nowrap;
}

/* สีไม่ซ้ำ */
.badge-blue {
    background: #e8f1ff;
    color: #1a4fd8;
}

.badge-green {
    background: #e9f8f0;
    color: #0f7b4f;
}

.badge-pink {
    background: #ffe5f2;
    color: #e100af;
}

.badge-purple {
    background: #f3eaff;
    color: #6b3fd6;
}


.bargrid{
  grid-template-columns: 1fr 1fr 1fr 1fr;
  display: grid;
    width: 100%;
    align-items: center;
    gap: 0.8rem;
}

.boxflex{
  display: flex;
  flex-direction: row;
}

 @keyframes blink {
    0% { background-color: #AA1D1D; color: white; }
    50% { background-color: transparent; color: transparent; }
    100% { background-color: #AA1D1D; color: white; }
  }
  .blink {
    animation: blink 1s infinite;
  }

.blink-img {
  animation: blinker 0.8s linear infinite;
}

/* ตั้งค่าการทำงานของการกระพริบ (จางหาย-โผล่มา) */
@keyframes blinker {
  50% {
    opacity: 0; /* ทำให้โปร่งแสงจนมองไม่เห็น ณ ครึ่งทางของแอนิเมชัน */
  }
}


        /* ===== PURPLE ===== */
.btn-purple{
  background:#6f42c1!important;
  border-color:#6f42c1!important;
  color:#fff!important;
}
.btn-purple:hover{
  background:#5a34a1!important;
  border-color:#5a34a1!important;
  color:#fff!important;
}

/* ===== PINK ===== */
.btn-pink{
  background:#d63384!important;
  border-color:#d63384!important;
  color:#fff!important;
}
.btn-pink:hover{
  background:#b82b6f!important;
  border-color:#b82b6f!important;
}

/* ===== ORANGE ===== */
.btn-orange{
  background:#ff5722!important;
  border-color:#ff5722!important;
  color:#fff!important;
}
.btn-orange:hover{
  background:#e96b05!important;
  border-color:#e96b05!important;
}

/* ===== TEAL ===== */
.btn-teal{
  background:#20c997!important;
  border-color:#20c997!important;
  color:#fff!important;
}
.btn-teal:hover{
  background:#1aa179!important;
  border-color:#1aa179!important;
}

/* ===== INDIGO ===== */
.btn-indigo{
  background:#6610f2!important;
  border-color:#6610f2!important;
  color:#fff!important;
}
.btn-indigo:hover{
  background:#520dc2!important;
  border-color:#520dc2!important;
}

/* ===== BROWN ===== */
.btn-brown{
  background:#795548!important;
  border-color:#795548!important;
  color:#fff!important;
}
.btn-brown:hover{
  background:#5d4037!important;
  border-color:#5d4037!important;
}

/* ===== LIME ===== */
.btn-lime{
  background:#cddc39!important;
  border-color:#cddc39!important;
  color:#000!important;
}
.btn-lime:hover{
  background:#b0c225!important;
  border-color:#b0c225!important;
  color:#000!important;
}

/* ===== EMERALD ===== */
.btn-emerald{
  background:#2ecc71!important;
  border-color:#2ecc71!important;
  color:#fff!important;
}
.btn-emerald:hover{
  background:#27ae60!important;
  border-color:#27ae60!important;
}

/* ===== SKY ===== */
.btn-sky{
  background:#0ea5e9!important;
  border-color:#0ea5e9!important;
  color:#fff!important;
}
.btn-sky:hover{
  background:#0284c7!important;
  border-color:#0284c7!important;
}

/* ===== MAROON ===== */
.btn-maroon{
  background:#800000!important;
  border-color:#800000!important;
  color:#fff!important;
}
.btn-maroon:hover{
  background:#660000!important;
  border-color:#660000!important;
}

/* ===== SLATE ===== */
.btn-slate{
  background:#64748b!important;
  border-color:#64748b!important;
  color:#fff!important;
}
.btn-slate:hover{
  background:#475569!important;
  border-color:#475569!important;
}

/* ===== OLIVE ===== */
.btn-olive{
  background:#6b8e23!important;
  border-color:#6b8e23!important;
  color:#fff!important;
}
.btn-olive:hover{
  background:#556b1a!important;
  border-color:#556b1a!important;
}

.btn-red{
  background:#FF0000!important;
  border-color:#FF0000!important;
  color:#fff!important;
}
.btn-red:hover{
  background:#dd0b0b!important;
  border-color:#dd0b0b!important;
}



/* ===== PURPLE ===== */
.bg-purple {
  background-color: #6f42c1 !important;
  color: #fff !important;
}

/* ===== PINK ===== */
.bg-pink {
  background-color: #d63384 !important;
  color: #fff !important;
}

/* ===== ORANGE ===== */
.bg-orange {
  background-color: #ff5722 !important;
  color: #fff !important;
}

/* ===== TEAL ===== */
.bg-teal {
  background-color: #20c997 !important;
  color: #fff !important;
}

/* ===== INDIGO ===== */
.bg-indigo {
  background-color: #6610f2 !important;
  color: #fff !important;
}

/* ===== BROWN ===== */
.bg-brown {
  background-color: #795548 !important;
  color: #fff !important;
}

/* ===== LIME ===== */
.bg-lime {
  background-color: #cddc39 !important;
  color: #000 !important; /* สีสว่าง ใช้ตัวหนังสือดำ */
}

/* ===== EMERALD ===== */
.bg-emerald {
  background-color: #2ecc71 !important;
  color: #fff !important;
}

/* ===== SKY ===== */
.bg-sky {
  background-color: #0ea5e9 !important;
  color: #fff !important;
}

/* ===== MAROON ===== */
.bg-maroon {
  background-color: #800000 !important;
  color: #fff !important;
}

/* ===== SLATE ===== */
.bg-slate {
  background-color: #64748b !important;
  color: #fff !important;
}

/* ===== OLIVE ===== */
.bg-olive {
  background-color: #6b8e23 !important;
  color: #fff !important;
}

/* ===== RED ===== */
.bg-red {
  background-color: #FF0000 !important;
  color: #fff !important;
}