@import url('https://fonts.googleapis.com/css2?family=Anton&display=swap');

* { 
  margin:0; 
  padding:0; 
  box-sizing:border-box; 
}

body { 
  font-family: 'Anton', sans-serif; 
  background-image: url(../img/backgroundhome1.1.png);
  background-size: cover;
  background-position: center; 
  background-repeat: no-repeat;
  position: relative;
  color: #fff; 
  line-height: 1.6; 
}

body, .overlay-text, .small-text {
  font-family: 'Anton', sans-serif !important;
}

a { 
  color: #fff; 
  text-decoration: none; 
}

.hero {
  position: relative;
  width: 100%;
  height: 100vh;
  overflow: hidden;
}

.hero img.hero-img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 1;
}

/* ข้อความหลัก */
.text-big {
  position: absolute;
  bottom: 80px;
  right: 120px;
  color: white;
  font-size: 5vw;
  text-shadow: 0 0 15px rgba(0,0,0,0.7);
  text-align: right;
  z-index: 10;
  text-decoration: none;
  cursor: pointer;
  text-transform: uppercase;
}

/* ข้อความรอง */
.text-small {
  position: absolute;
  bottom: 45px;
  right: 120px;
  color: rgba(255,255,255,0.8);
  font-size: 1.5vw;
  text-shadow: 0 0 10px rgba(0,0,0,0.5);
  z-index: 10;
  text-decoration: none;
  cursor: pointer;
}

/* ส่วนเนื้อหา */
.content {
  max-width: 1200px;
  margin: 50px auto;
  padding: 0 200px;
}

.content h2 {
  font-family: 'IBM Plex Sans Thai Looped', sans-serif;
  font-size: 1.3rem;
  margin-bottom: 10px;
}

.content p {
  font-family: 'IBM Plex Sans Thai Looped', sans-serif;
  font-size: 1vw;
  margin-bottom: 20px;
  color: #ccc;
}

/* ========================= */
/* Responsive Adjustments 📱 */
/* ========================= */

/* แท็บเล็ต (≤ 1024px) */
@media (max-width: 1024px) {

    body { 
    font-family: 'Anton', sans-serif; 
    background-image: url(../img/backgroundhomemoblie.png);
    background-size: cover;
    background-position: center; 
    background-repeat: no-repeat;
    position: relative;
    color: #fff; 
    line-height: 1.6; 
}

  .text-big {
    bottom: 60px;
    right: 80px;
    font-size: 6vw;
  }

  .text-small {
    bottom: 35px;
    right: 80px;
    font-size: 2vw;
  }

  .content {
    padding: 0 100px;
  }

  .content p {
    font-size: 1.2vw;
  }
}

/* มือถือแนวนอน (≤ 768px) */
@media (max-width: 768px) {
  .text-big {
    bottom: 50px;
    right: 40px;
    font-size: 7vw;
    text-align: right;
  }

  .text-small {
    bottom: 25px;
    right: 40px;
    font-size: 3vw;
  }

  .content {
    padding: 0 50px;
  }

  .content p {
    font-size: 2.5vw;
  }
}

/* มือถือแนวตั้ง (≤ 480px) */
@media (max-width: 480px) {
  .hero {
    height: 90vh;
  }

  .text-big {
    bottom: 40px;
    right: 20px;
    font-size: 9vw;
    text-align: right;
  }

  .text-small {
    bottom: 20px;
    right: 20px;
    font-size: 4vw;
  }

  .content {
    margin: 30px auto;
    padding: 0 20px;
  }

  .content h2 {
    font-size: 1.1rem;
  }

  .content p {
    font-size: 3.5vw;
  }
}



.latest-gallery-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    grid-auto-rows: 80px;
    gap: 8px;
    height: auto;
    margin-bottom: 80px;
    margin-top: 100px;
    padding: 0 150px;
}

.gallery-item {
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
    position: relative;
}

.gallery-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* layout เดิมเฉพาะ desktop */
.item-one   { grid-column: 1; grid-row: 1 / span 3; }
.item-two   { grid-column: 2; grid-row: 1 / span 3; }
.item-Three { grid-column: 3; grid-row: 1 / span 3; }

.item-Four  { grid-column: 1; grid-row: 4 / span 3; }
.item-Five  { grid-column: 2; grid-row: 4 / span 4; }
.item-Six   { grid-column: 3; grid-row: 4 / span 3; }

.item-Seven { grid-column: 1; grid-row: 7 / span 4; }
.item-Eight { grid-column: 2; grid-row: 8 / span 3; }
.item-Nine  { grid-column: 3; grid-row: 7 / span 4; }

/* ========================= */
/* 📱 Responsive Adjustments */
/* ========================= */

/* แท็บเล็ต (≤ 1024px) */
@media (max-width: 1024px) {
    .latest-gallery-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    grid-auto-rows: 80px;
    gap: 8px;
    height: auto;
    margin-bottom: 30px;
    margin-top: 100px;
    padding: 0 150px;
}

.gallery-item {
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
    position: relative;
}

.gallery-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* layout เดิมเฉพาะ desktop */
.item-one   { grid-column: 1; grid-row: 1 / span 3; }
.item-two   { grid-column: 2; grid-row: 1 / span 3; }
.item-Three { grid-column: 3; grid-row: 1 / span 3; }

.item-Four  { grid-column: 1; grid-row: 4 / span 3; }
.item-Five  { grid-column: 2; grid-row: 4 / span 4; }
.item-Six   { grid-column: 3; grid-row: 4 / span 3; }

.item-Seven { grid-column: 1; grid-row: 7 / span 4; }
.item-Eight { grid-column: 2; grid-row: 8 / span 3; }
.item-Nine  { grid-column: 3; grid-row: 7 / span 4; }
}

/* มือถือ (≤ 768px) */
@media (max-width: 768px) {
    .latest-gallery-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    grid-auto-rows: 40px;
    gap: 4px;
    height: auto;
    margin-bottom: 0px;
    margin-top: 100px;
    padding: 0 0px;
}

.gallery-item {
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
    position: relative;
}

.gallery-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.item-one   { grid-column: 1; grid-row: 1 / span 3; }
.item-two   { grid-column: 2; grid-row: 1 / span 3; }
.item-Three { grid-column: 3; grid-row: 1 / span 3; }

.item-Four  { grid-column: 1; grid-row: 4 / span 3; }
.item-Five  { grid-column: 2; grid-row: 4 / span 4; }
.item-Six   { grid-column: 3; grid-row: 4 / span 3; }

.item-Seven { grid-column: 1; grid-row: 7 / span 4; }
.item-Eight { grid-column: 2; grid-row: 8 / span 3; }
.item-Nine  { grid-column: 3; grid-row: 7 / span 4; }
    
}



.hrtop {
    width: 80%;
    margin: 40px auto;
    border: none;
    border-top: 2px solid #ccc;
    border-radius: 2px;
}

.related-projects-section {
    padding: 100px 40px;
    color: #fff;
    display: flex;
    justify-content: center;
}

.container {
    max-width: 1200px;
    width: 100%;
    display: flex;
    justify-content: center;
}

.related-row {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 60px;
}

.related-title {
    flex: 0 0 auto;
}

.related-title h2 {
    font-size: 2.3rem;
    line-height: 1.2;
    margin: 0;
}

.slider-area {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    max-width: 800px;
}

.slider-viewport {
    overflow: hidden;
    width: 780px; /* แสดง 4 รูป (4×180 + margin) */
}

.image-gallery {
    display: flex;
    transition: transform 0.4s ease;
}

.image-gallery img {
    width: 180px;
    height: 200px;
    object-fit: cover;
    margin-right: 15px;
    cursor: pointer;
    border-radius: 8px;
}

.arrow {
    font-size: 2rem;
    cursor: pointer;
    user-select: none;
    color: #fff;
    border-radius: 50%;
    padding: 10px 14px;
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 5;
    transition: background 0.3s;
}

.arrow:hover {
    background: rgba(255,255,255,0.2);
}

.arrow.left { left: -50px; }
.arrow.right { right: -50px; }

/* --- Video Section --- */
.video-section {
  padding: 20px 0; /* เว้นระยะห่างบนล่างของส่วนวิดีโอ */
  /* background-color: #fff; */
}

.video-container {
  position: relative;
  width: 100%;
  max-width: 1200px;
  margin: 80px auto;
  text-align: center;
}

.video-container video,
.video-container iframe {
  width: 100%;
  height: auto;
  border-radius: 12px;
  box-shadow: 0 0 25px rgba(0,0,0,0.3);
  display: block;
  margin: 0 auto;
  background-color: #000;
}


.hrbutton {
    width: 80%;
    margin: 20px auto;
    border: none;
    border-top: 2px solid #ccc;
    border-radius: 2px;
}

.footer-text {
    color: #ccc;
    font-size: 0.9rem;
    margin: 0 10% 25px;
    text-align: center;
}


