.popup {
      display: none;
      position: fixed;
      top: 0;
      left: 0;
      width: 100%;
      height: 100%;
      background: rgba(0, 0, 0, 0.8); /* สีพื้นหลังของป๊อปอัพ */
    }

    .popup img {
      display: block;
      margin: auto;
      position: absolute;
      top: 50%;
      left: 50%;
      transform: translate(-50%, -50%);
      max-width: 80%; /* ขนาดสูงสุดของรูปในป๊อปอัพ */
      max-height: 80vh; /* ความสูงสูงสุดของรูปในป๊อปอัพ */
    }

    /* เซ็ตสไตล์ของปุ่มปิดป๊อปอัพ */
    .close-btn {
    position: absolute;
    top: -1vw;
    right: 2vw;
    color: #fff;
    font-size: 4vw;
    cursor: pointer;
}

    /* เซ็ตสไตล์ของปุ่มเปลี่ยนรูปภาพ */
    .nav-btn {
      position: absolute;
      top: 50%;
      width: 30px;
      height: 30px;
      background-color: rgba(255, 255, 255, 0.5);
      border: none;
      cursor: pointer;
    }

    /* เซ็ตสไตล์ของปุ่มเปลี่ยนรูปภาพทางซ้าย */
    .prev-btn {
      left: 5vw;
      transform: translate(0, -50%);
    }

    /* เซ็ตสไตล์ของปุ่มเปลี่ยนรูปภาพทางขวา */
    .next-btn {
      right: 5vw;
      transform: translate(0, -50%);
    }
    
    .popup-2 {
            display: none;
            position: fixed;
            top: 0;
            left: 0;
            width: 100%;
            height: 100%;
            background: rgba(0, 0, 0, 0.8); /* สีพื้นหลังของป๊อปอัพ */
            overflow-y: scroll; /* เพิ่ม scrollbar แนวตั้ง */
        }

        .popup-2 img {
            display: block;
            margin: auto;
        
            top: 50%;
            left: 50%;
            
            max-width: 80%; /* ขนาดสูงสุดของรูปในป๊อปอัพ */
            max-height: 80vh; /* ความสูงสูงสุดของรูปในป๊อปอัพ */
        }
        .p-popup-2{
                    padding-top: 1%;
    padding-left: 10%;
    padding-right: 10%;
    
}
.grid {
  display: grid;
  grid-template-rows: 
    repeat(4, 180px);
  grid-template-columns: 
    repeat(3, 1fr);
  grid-gap: 5px;
}

.item:nth-child(1) {
  grid-column: 1;
  grid-row: 1 / 3;
}

.item:nth-child(2) {
  grid-column: 2;
  grid-row: 1 / 3;
}

.item:nth-child(3) {
 grid-column: 3;
  grid-row: 1 / 3;
}

.grid {
  margin:20px auto;
 /*  max-width:1000px; */
}

.grid > .item {
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
}

.grid-container {
  display: grid;
  grid-template-columns: auto auto auto;
  
  grid-gap: 5px;
}
.grid-item {
  background-repeat: no-repeat;
    padding: 48%;
    text-align: center;
    background-size: cover;
    background-position: center;
}
.grid-container-2{
  display: grid;
  grid-template-columns: auto auto;
      margin-block-end: 7px;
  grid-gap: 5px;
}
.grid-item-2 {
  background-repeat: no-repeat;
    padding: 20%;
    text-align: center;
    background-size: cover;
    background-position: center;
}
