/* Reset some default browser styles */
body {
    margin: 0;
    font-family: 'Prompt', sans-serif;
    background-color: #f9f9f9;
    color: #333;
    
}

/* General layout centering */
main {
    max-width: 1200px; /* กำหนดความกว้างสูงสุดสำหรับแต่ละ Block */
    margin: 20px auto; /* จัดให้อยู่กึ่งกลาง */
    background: white; /* พื้นหลังสีขาวสำหรับแยก Block */
    border-radius: 10px; /* ขอบโค้งมน */
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1); /* เพิ่มเงาเพื่อแยก Block */
    overflow: hidden;
    background-size: cover; /* ปรับให้รูปเต็มหน้าจอ */
    background: url('img/a3c264084104d80c.png') no-repeat center center fixed; /* ใช้รูปพื้นหลัง */
    background-size: 100% 100%; /* ปรับขนาดตามความกว้างและความสูง */
}

/* Adjust Ads section */
.ads img {
    width: 100%; /* ความกว้างของรูปอยู่ใน Block */
    height: auto;
}
.content p {
    color: #279eff;
    font-size: 1rem;
    margin-bottom: 20px;
}
.content .two {
    color: #ff2727;
    font-size: 1rem;
    margin-bottom: 20px;
}

/* Main Navbar */
.navbar {
    padding: 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    background-color: #efefef;
}

.navbar ul {
    list-style: none;
    display: flex;
    gap: 15px;
}

.navbar ul li a {
    text-decoration: none;
    font-weight: 500;
    color: #555;
}

/* Buttons Section */
.actions {
    padding: 20px;
    text-align: center;
}

/* Minimal Buttons */
.btn {
    border: none;
    border-radius: 25px;
    font-size: 16px;
    padding: 10px 30px;
    cursor: pointer;
    margin: 10px;
    transition: background-color 0.3s, color 0.3s;
}

.btn.minimal {
    background-color: transparent;
    border: 2px solid;
    color: inherit;
    text-decoration: none;
}

.btn.red {
    border-color: #ff6b6b;
    color: #ff6b6b;
}

.btn.green {
    border-color: #4caf50;
    color: #4caf50;
}

.btn:hover {
    color: white;
}

.btn.red:hover {
    background-color: #ff6b6b;
}

.btn.green:hover {
    background-color: #4caf50;
}

/* Section Content */
.content {
    padding: 20px;
    text-align: center;
}

.content h2 {
    font-size: 1.5rem;
    margin-bottom: 10px;
}

/* Grid Section */

.grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 10px;
    padding: 20px;
}

.grid-item {
    position: relative;
    width: 100%;
    aspect-ratio: 4 / 3;
    border-radius: 5px;
    overflow: hidden;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s;
}

.grid-item:hover {
    transform: scale(1.05);
}

.grid-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Popup Overlay */
.popup {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    justify-content: center;
    align-items: center;
    z-index: 9999;
}

.popup-content {
    max-width: 80%;
    max-height: 80%;
    border-radius: 10px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
}

.close-btn {
    position: absolute;
    top: 20px;
    right: 30px;
    font-size: 2rem;
    color: white;
    cursor: pointer;
}
/* Animation */
@keyframes scaleIn {
    from {
        transform: scale(0.5);
        opacity: 0;
    }
    to {
        transform: scale(1);
        opacity: 1;
    }
}

.details-section {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 40px;
    background-color: #f9f9f9; /* สีพื้นหลัง */
    border-radius: 10px; /* ขอบโค้งมน */
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1); /* เงา */
    margin: 20px auto; /* เว้นระยะ */
    max-width: 1200px; /* ความกว้างสูงสุด */
}

/* ส่วนข้อความ */
.details-text {
    flex: 1;
    margin-right: 20px; /* เว้นขวา */
    color: #333;
}

.details-text a {
    text-decoration: none;
    
}

.details-text h3 {
    font-size: 1.8rem;
    color: #003399;
    margin-bottom: 10px;
}

.details-text .info {
    font-size: 1rem;
    margin-bottom: 15px;
    color: #333;
}

.details-text .info.red {
    color: #e60000; /* สีแดง */
}
@media (max-width: 768px) {
    .details-section {
      flex-direction: column;
      align-items: center;
      text-align: center;
    }
  
    .details-text {
      max-width: 100%;
    }
  
    .details-image {
      margin-bottom: 20px;
    }
  }

.info-list {
    list-style: none; /* ซ่อน bullet ปกติ */
    padding: 0;
}

.info-list li {
    margin: 8px 0;
    font-size: 1rem;
    color: #333;
    display: flex;
    align-items: center;
    gap: 10px; /* ช่องว่างระหว่างไอคอนกับข้อความ */
}

.info-list li span {
    color: #003399; /* สีของ bullet */
    font-weight: bold;
}



/* ส่วนภาพ */
.details-image {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center;
}

.image-box {
    width: 350px;
    height: 300px;
    background-color: #e6e6e6;
    border-radius: 20px;
    overflow: hidden; /* ซ่อนส่วนของภาพที่เกินออกมา */
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s, box-shadow 0.3s; /* เพิ่มแอนิเมชัน */
}

.image-box img {
    width: 100%; /* ให้รูปขยายเต็มพื้นที่แนวนอน */
    height: 100%; /* ให้รูปขยายเต็มพื้นที่แนวตั้ง */
    object-fit: cover; /* ปรับให้รูปอยู่ในกรอบโดยไม่เสียสัดส่วน */
    border-radius: 20px; /* โค้งมนตาม container */
    transition: transform 0.3s; /* เพิ่มแอนิเมชันเมื่อ hover */
}

.image-box:hover {
    transform: scale(1.1); /* ขยายรูปเล็กน้อยเมื่อ hover */
}