/* =========================================================
   component1_6.css
   FULL-PAGE POSITIONING VERSION เฉพาะหน้า component1_6.php
   โหลดหลัง assets/css/index.css

   วิธีปรับ:
   1) กล่องข้อความ: .c16-card
   2) รูปทีละรูป: .c16-photo-1 ถึง .c16-photo-5
   3) ตำแหน่งภาพด้านใน: .c16-img-1 ถึง .c16-img-5
========================================================= */

/* =========================================================
   FULL PAGE BASE
========================================================= */

.c16-page {
  position: relative;
  width: 100%;
  height: 100%;
  min-height: 0;
  padding: 0 !important;
  overflow: hidden;
  isolation: isolate;
}

.c16-page > * {
  box-sizing: border-box;
}

/* =========================================================
   DECORATION
========================================================= */

.c16-decor {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  overflow: hidden;
}

.c16-orb {
  position: absolute;
  border-radius: 999px;
  opacity: .58;
  filter: blur(1px);
}

.c16-orb-1 {
  left: 8%;
  top: 18%;
  width: 150px;
  height: 150px;
  background: linear-gradient(135deg, rgba(245, 197, 66, .32), rgba(18, 136, 248, .12));
  animation: floatBubble 8s ease-in-out infinite alternate;
}

.c16-orb-2 {
  right: 8%;
  bottom: 16%;
  width: 210px;
  height: 210px;
  background: linear-gradient(135deg, rgba(18, 136, 248, .16), rgba(245, 197, 66, .18));
  animation: floatBubble 9s ease-in-out infinite alternate-reverse;
}

.c16-star {
  position: absolute;
  color: var(--gold);
  text-shadow: 0 8px 24px rgba(245, 197, 66, .35);
  animation: twinkle 2.5s ease-in-out infinite alternate;
}

.c16-star-1 {
  left: 17%;
  bottom: 27%;
  font-size: 42px;
}

.c16-star-2 {
  right: 12%;
  bottom: 31%;
  font-size: 34px;
  color: var(--blue);
  animation-delay: .8s;
}

/* =========================================================
   TEXT CARD
   ตำแหน่งข้อความล็อกไว้ตรงนี้
========================================================= */

.c16-card {
  position: absolute;

  /* ===== ปรับตำแหน่งกล่องข้อความตรงนี้ ===== */
  left: 24%;
  top: 112px;
  width: 990px;
  max-width: 64vw;
  min-height: 0;

  z-index: 50;
  padding: 26px 46px;
  border-radius: 42px;
  color: var(--dark);
  background:
    radial-gradient(circle at 12% 8%, rgba(245, 197, 66, .28), transparent 34%),
    radial-gradient(circle at 88% 92%, rgba(18, 136, 248, .18), transparent 40%),
    linear-gradient(135deg, rgba(255, 255, 255, .90), rgba(255, 255, 255, .62));
  border: 1px solid rgba(255, 255, 255, .78);
  box-shadow:
    0 28px 76px rgba(7, 35, 71, .16),
    inset 0 1px 0 rgba(255, 255, 255, .58);
  backdrop-filter: blur(26px);
  -webkit-backdrop-filter: blur(26px);
  transform: translateX(-50%);
  overflow: hidden;
}

.c16-card::before {
  content: "";
  position: absolute;
  inset: 16px;
  border-radius: 30px;
  border: 2px solid rgba(18, 136, 248, .18);
  pointer-events: none;
}

.c16-card::after {
  content: "";
  position: absolute;
  inset: -50%;
  z-index: -1;
  background: linear-gradient(115deg, transparent 42%, rgba(255, 255, 255, .34) 50%, transparent 58%);
  transform: translateX(-62%) rotate(8deg);
  animation: cardShine 7s ease-in-out infinite;
}

.c16-title-box {
  position: relative;
  z-index: 2;
  margin-bottom: 12px;
}

.c16-component {
  display: inline-flex;
  margin-bottom: 7px;
  padding: 7px 17px;
  border-radius: 999px;
  color: #0b2347;
  background: linear-gradient(135deg, var(--gold), #fff2ad);
  font-weight: 900;
  box-shadow: 0 12px 28px rgba(245, 197, 66, .18);
}

.c16-title-box h1 {
  margin: 0;
  color: transparent;
  font-family: "Chonburi", "Noto Sans Thai", serif;
  font-size: clamp(1.85rem, 2.45vw, 3rem);
  line-height: 1.14;
  letter-spacing: -.8px;
  background: linear-gradient(100deg, #071f4b 10%, #0b2347 38%, #126bd6 58%, #071f4b 90%);
  background-size: 240% auto;
  -webkit-background-clip: text;
  background-clip: text;
  animation: titleLight 5.5s ease-in-out infinite;
}

.c16-title-box h1 small {
  display: block;
  margin-bottom: 3px;
  color: var(--blue-dark);
  font-family: "Noto Sans Thai", sans-serif;
  font-size: clamp(1rem, 1.18vw, 1.35rem);
  font-weight: 900;
}

.c16-text {
  position: relative;
  z-index: 2;
  display: grid;
  gap: 10px;
}

.c16-text p {
  margin: 0;
  color: rgba(11, 35, 71, .88);
  font-size: clamp(.86rem, .9vw, .98rem);
  font-weight: 700;
  line-height: 1.52;
  text-indent: 2.1em;
  text-align: justify;
}

/* =========================================================
   PHOTO BASE
   ไม่มีกรอบ + object-fit: contain
   รูปทั้งหมดอยู่หลังข้อความเสมอ
========================================================= */

.c16-photo-layer {
  position: absolute;
  inset: 0;
  z-index: 20;
  pointer-events: none;
}

.c16-photo {
  position: absolute;
  z-index: 20;
  margin: 0;
  overflow: visible;
  background: none;
  border: 0;
  border-radius: 0;
  box-shadow: none;
  opacity: 1;
}

.c16-img,
.c16-photo-fallback {
  width: 100%;
  height: 100%;
}

.c16-img {
  display: block;
  object-fit: contain;
  object-position: center center;
  background: transparent;
  border: 0;
  box-shadow: none;
  filter: drop-shadow(0 18px 34px rgba(7, 35, 71, .24));
}

.c16-img.is-missing {
  display: none;
}

.c16-photo-fallback {
  display: none;
  place-items: center;
  color: var(--blue-dark);
  font-weight: 900;
  text-align: center;
  border-radius: 28px;
  background: rgba(255, 255, 255, .62);
  border: 1px solid rgba(255, 255, 255, .70);
  box-shadow: 0 18px 34px rgba(7, 35, 71, .12);
}

.c16-photo-fallback.show {
  display: grid;
}

.c16-photo span {
  display: none;
}

/* =========================================================
   PHOTO 1
   ปรับเฉพาะรูปที่ 1 ตรงนี้
========================================================= */

.c16-photo-1 {
  left: 3%;
  top: 155px;
  width: 340px;
  height: 212px;
  transform: rotate(-2deg);
}

.c16-img-1 {
  object-position: center center;
}

/* =========================================================
   PHOTO 2
   ปรับเฉพาะรูปที่ 2 ตรงนี้
========================================================= */

.c16-photo-2 {
  left: 9%;
  bottom: 44px;
  width: 300px;
  height: 188px;
  transform: rotate(2deg);
}

.c16-img-2 {
  object-position: center center;
}

/* =========================================================
   PHOTO 3
   ปรับเฉพาะรูปที่ 3 ตรงนี้
========================================================= */

.c16-photo-3 {
  left: 50%;
  top: 12px;
  width: 310px;
  height: 194px;
  transform: translateX(-50%);
}

.c16-img-3 {
  object-position: center center;
}

/* =========================================================
   PHOTO 4
   ปรับเฉพาะรูปที่ 4 ตรงนี้
========================================================= */

.c16-photo-4 {
  right: 3%;
  top: 150px;
  width: 370px;
  height: 232px;
  transform: rotate(2deg);
}

.c16-img-4 {
  object-position: center center;
}

/* =========================================================
   PHOTO 5
   ปรับเฉพาะรูปที่ 5 ตรงนี้
========================================================= */

.c16-photo-5 {
  right: 8%;
  bottom: 42px;
  width: 320px;
  height: 200px;
  transform: rotate(-2deg);
}

.c16-img-5 {
  object-position: center center;
}

/* =========================================================
   1366px NOTEBOOK
========================================================= */

@media (max-width: 1366px) {
  .c16-card {
    left: 24%;
    top: 112px;
    width: 990px;
    max-width: 64vw;
    padding: 26px 46px;
  }

  .c16-title-box h1 {
    font-size: clamp(1.64rem, 2.25vw, 2.55rem);
  }

  .c16-text p {
    font-size: clamp(.8rem, .84vw, .92rem);
    line-height: 1.43;
  }

  .c16-photo-1 {
    left: 2%;
    top: 145px;
    width: 300px;
    height: 188px;
  }

  .c16-photo-2 {
    left: 8%;
    bottom: 38px;
    width: 250px;
    height: 156px;
  }

  .c16-photo-3 {
    left: 50%;
    top: 8px;
    width: 250px;
    height: 156px;
  }

  .c16-photo-4 {
    right: 2%;
    top: 142px;
    width: 320px;
    height: 200px;
  }

  .c16-photo-5 {
    right: 7%;
    bottom: 38px;
    width: 270px;
    height: 169px;
  }
}

/* =========================================================
   TABLET / MOBILE
========================================================= */

@media (max-width: 1180px) {
  .c16-page {
    min-height: 100vh;
    overflow: visible;
    padding: 112px clamp(22px, 5vw, 48px) 86px !important;
  }

  .c16-card,
  .c16-photo-layer,
  .c16-photo {
    position: relative;
    left: auto;
    right: auto;
    top: auto;
    bottom: auto;
    width: 100%;
    height: auto;
    transform: none;
  }

  .c16-card {
    max-width: 100%;
    border-radius: 32px;
  }

  .c16-card::before {
    border-radius: 24px;
  }

  .c16-photo-layer {
    display: grid;
    gap: 16px;
    margin-top: 16px;
  }

  .c16-photo {
    aspect-ratio: 16 / 9;
  }
}

/* =========================================================
   FOOTER CONTROLS
========================================================= */

.slide-controls a.btn-main,
.slide-controls a.btn-outline {
  width: 42px;
  height: 42px;
  padding: 0;
  display: grid;
  place-items: center;
  font-size: 1.45rem;
  line-height: 1;
}
