/* ขนาดที่ต้องการ */
:root {
  --banner-width: 150px;
  --banner-height: auto;
  /* หรือ fix เช่น 300px */
}

.skeleton-videos-card {
  background-color: #e2e2e2;
  border-radius: 4px;
  animation: pulse 1.4s infinite ease-in-out;
}

@keyframes pulse {
  0% {
    opacity: 1;
  }

  50% {
    opacity: 0.4;
  }

  100% {
    opacity: 1;
  }
}

.page-link {
  min-width: 55px;
  text-align: center;
  transition: 0.2s;
}

/* Banner 1 */
#popup-banner1 {
  position: fixed;
  bottom: 130px;
  right: 10px;
  z-index: 9999;
  background: transparent;
}

#popup-banner1 img {
  width: 130px;
  height: auto;
  cursor: pointer;
  transition: transform 0.2s ease;
}

#popup-banner1 img:hover {
  transform: scale(1.05);
}

#popup-close1 {
  position: absolute;
  right: 0px;
  top: -10px;
  background: red;
  color: white;
  font-weight: bold;
  border-radius: 50%;
  width: 20px;
  height: 20px;
  text-align: center;
  line-height: 20px;
  cursor: pointer;
  font-size: 14px;
}



/* Banner 2 - ขวา */
#sidebar-banner1 {
  position: fixed;
  top: 50%;
  right: 0;
  transform: translateY(-50%);
  z-index: 9999;
  background: transparent;
  text-align: center;
}

#sidebar-banner1 img {
  width: var(--banner-width);
  height: var(--banner-height);
  display: block;
  border-radius: 5px;
  box-shadow: 0 0 5px rgba(0, 0, 0, 0.3);
}




/* Banner 3 - ซ้าย */
#sidebar-banner2 {
  position: fixed;
  top: 50%;
  left: 0;
  transform: translateY(-50%);
  z-index: 9999;
  background: transparent;
  text-align: center;
}

#sidebar-banner2 img {
  width: var(--banner-width);
  height: var(--banner-height);
  display: block;
  border-radius: 5px;
  box-shadow: 0 0 5px rgba(0, 0, 0, 0.3);
}

#banner-close2 {
  background: black;
  color: white;
  font-weight: bold;
  font-size: 14px;
  padding: 2px 6px;
  cursor: pointer;
  border-radius: 0 0 5px 5px;
  margin-top: 5px;
}


#bottom-bannersss {
  position: fixed;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  display: none;
  /* default flex*/
  gap: 10px;
  z-index: 9999;
  padding: 5px;
  background: rgba(0, 0, 0, 0.05);
}

#banner-close1,
#banner-close2 {
  background: linear-gradient(to bottom, #ff6a00, #f44336);
  /* ไล่สีส้ม-แดง */
  color: white;
  font-weight: bold;
  font-size: 16px;
  /*padding: 6px 14px;*/
  width: 100%;
  cursor: pointer;
  border-radius: 6px;
  border: none;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.3);
  /*margin: 8px auto 0;*/
  display: inline-block;
  transition: transform 0.2s ease;
}

#banner-close1:hover,
#banner-close2:hover {
  transform: scale(1.05);
}

/* Main Banner on index  */

.fixed-banner-left {
  position: fixed;
  top: 80px;
  left: 0;
  z-index: 999;
}

.fixed-banner-right {
  position: fixed;
  top: 80px;
  right: 0;
  z-index: 999;
}

.dropdown-menu {
  z-index: 1001 !important; /* ต้องมากกว่า 999 */
}


/* ✅ Responsive สำหรับมือถือ */
@media (max-width: 768px) {
  #popup-banner1 {
    bottom: 15px;
  }

  /* ปิด banner ที่ 2 */
  #bottom-bannersss>div:nth-of-type(2) {
    display: none !important;
  }

  #bottom-close {
    position: absolute;
    right: 0;
    height: 100%;
    width: auto;
  }

  #popup-banner1 img,
  #sidebar-banner1 img,
  #sidebar-banner2 img {
    width: 80px;
  }
}

/* ❌ ซ่อน sidebar-banner1 และ 2 บน PC */
@media (min-width: 769px) {

  #sidebar-banner1,
  #sidebar-banner2 {
    display: none !important;
  }
}

/* 📱 บน mobile ให้กว้างเต็มจอ */
@media (max-width: 480px) {
  #bottom-bannersss {
    width: 100%;
    left: 0;
    transform: none;
    justify-content: center;
  }
}

@media (max-width: 767px) {
  #bottom-bannersss {
    display: none !important;
  }
}