.header-wrapper {
  background: rgba(26, 26, 26, 0.8);
  position: fixed; /* chuyển từ absolute → fixed */
  top: 0;
  left: 0;
  width: 100%;
  z-index: 12;
  color: white;
  backdrop-filter: blur(10px); /* tuỳ chọn: tạo hiệu ứng mờ khi scroll */
}

/* Container website in laptop/d */
.container-layout {
  padding: 5px 100px;
}

.topbar-inner,
.header-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
}

.topbar-item {
  font-family:  Montserrat, sans-serif;
  font-weight: 700;
  font-size: 16px;
}

.search-box {
  display: flex;
  align-items: center;
  gap: 10px;
  background: rgba(26, 26, 26, 0.8);
  padding: 3px 4px 3px 10px;
  border-radius: 9999px;
}

.search-box input {
  border: none;
  background: transparent;
  color: white;
  font-family:  Montserrat, sans-serif;
  font-size: 14px;
  outline: none;
  width: 150px;
  
}

.search-btn {
  width: 24px;
  height: 24px;
  background: white;
  border: none;
  cursor: pointer;
  border-radius: 50%;
}

.icon {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  margin-left: 10px;
}

.icon-red {
  background-color: #d80027;
}

.icon-yellow {
  width: 12px;
  height: 12px;
  background-color: #ffda44;
}

.logo img {
  height: 24px;
}

.main-nav .menu-list {
  display: flex;
  gap: 24px;
}

.menu-list li {
  list-style: none;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  align-items: center;
  position: relative; /* ✅ thêm dòng này */
}

.menu-list li:hover::after {
  content: "";
  position: absolute;
  top: 100%; /* nằm ngay bên dưới mục cha */
  left: 0;
  width: 100%;
  height: 20px; /* 👈 tùy chỉnh vùng đệm đủ để chuột di chuyển qua */
}

.menu-list li a {
  color: white;
  font-size: 18px;
  font-family: Montserrat, sans-serif;
  text-decoration: none;
}



/* Slider-main */
.slider-wrapper {
  display: flex;
  gap: 20px;
  overflow-x: auto;
  padding: 20px;
}

.slide img {
  width: 300px;
  height: auto;
  border-radius: 8px;
  box-shadow: 0 2px 10px rgba(0,0,0,0.2);
}


/* Submenu ẩn ban đầu */
.menu-list li ul {
  display: none;
  position: absolute;
  top: 120%;
  left: 0;
  background-color: rgba(26, 26, 26, 0.95);
  min-width: 240px;
  padding: 6px;
  z-index: 10000;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
  border-radius: 4px;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.2s ease, top 0.2s ease;
  
}

/* Khi có class .open → hiện submenu */
.menu-list li:hover > ul {
  display: block;
  opacity: 1;
  visibility: visible;
}

/* Style cho item trong submenu */
.menu-list li ul li {
  padding: 0;
  text-align: left;
  padding: 0 6px; /* 👈 giảm padding top-bottom từ 8px xuống 6px */
  margin-bottom: 6px;
}

.menu-list li ul li a {
  display: block;
  padding: 6px 6px; /* 👈 giảm padding top-bottom từ 8px xuống 6px */
  font-size: 16px;
  color: white;
  white-space: nowrap;
  width: 100%
}


.menu-list li ul li a:hover {
  background-color: #444;
  border-radius: 4px;
}

.menu-list li ul li.current-menu-item a {
  border-left: 3px solid white;
  background-color: #333;
}




/* Submenu chỉ hiện khi hover hoặc đang là trang con */
.menu-list li:hover > ul {
  display: block;
  opacity: 1;
  visibility: visible;
}

/* Highlight submenu đang active */
.menu-list li ul li.current-menu-item a {
  border-left: 3px solid white;
  background-color: #333;
}

/* Highlight mục cha khi có submenu active */
/* Áp dụng cho menu chính (không có submenu) */
.menu-list > li.current-menu-item > a {
  font-weight: 700;
  border-bottom: 2px solid white;
}

/* Áp dụng cho submenu */
.menu-list li ul li.current-menu-item > a {
  border-left: 3px solid white;
  background-color: #333;
  border-bottom: none; /* <- chắc chắn bỏ border-bottom nếu bị thừa */
}


/* Mục cha được active nếu có submenu active */
.menu-list > li.current-menu-ancestor > a {
  font-weight: 700;
  border-bottom: 2px solid white;
}


.menu-list li.current-menu-item > a {
  font-weight: 700;
  border-bottom: 2px solid white;
}


/* LOADING */

#page-loader {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(255, 255, 255, 0.95); /* nền mờ */
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  opacity: 1;
  visibility: visible;
  transition: opacity 0.4s ease, visibility 0.4s ease;
}

#page-loader.hide {
  opacity: 0;
  visibility: hidden;
}

.loader-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.loader-inner img {
  width: 160px; /* 👈 chỉnh logo to lên */
  height: auto;
  margin-bottom: 20px;
  animation: pulse 1.5s infinite ease-in-out;
}

.spinner {
  width: 48px;
  height: 48px;
  border: 5px solid #ccc;
  border-top-color: #333;
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

@keyframes pulse {
  0%, 100% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.05); opacity: 0.75; }
}


footer ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

footer ul li a {
  color: #ccc; /* màu xám sáng */
  text-decoration: none;
  transition: color 0.3s ease;
}

footer ul li a:hover {
  color: #fff; /* màu trắng khi hover */
  font-weight: 700;
}

/* Header mobile */

/* Tailwind đã có breakpoint sẵn */
@media (min-width: 1024px) {
  #mobileMenu {
    display: none !important;
  }
}

/* Ẩn menu chính trên mobile, chỉ hiện trên >= 890px */
.main-nav {
  display: none;
}

@media (min-width: 1024px) {
  .main-nav {
    display: block;
  }
  .mobile-menu-toggle,
  .mobile-menu-wrapper {
    display: none !important;
  }
}

/* Nút ☰ không nền */
.mobile-menu-toggle {
  font-size: 28px;
  background: none;
  border: none;
  color: white;
  cursor: pointer;
  position: relative;
  z-index: 10001;
}

/* Mobile menu wrapper */
.mobile-menu-wrapper {
  position: fixed;
  top: 0;
  left: 0;
  width: 60%;
  max-width: 300px;
  height: 100%;
  background: rgba(0, 0, 0, 0.842);
  color: white;
  z-index: 12;
  box-shadow: 2px 0 8px rgba(0, 0, 0, 0.3);
  overflow-y: auto;
  transform: translateX(-100%);
  transition: transform 0.3s ease;
}

/* Hiện menu khi mở */
.mobile-menu-wrapper.open {
  transform: translateX(0);
}

/* Header bên trong mobile menu */
.mobile-menu-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px;
  border-bottom: 1px solid #444;
}

.menu-title {
  font-size: 18px;
  font-weight: bold;
}

.close-btn {
  font-size: 32px;
  background: none;
  border: none;
  color: white;
  cursor: pointer;
}

/* Danh sách menu */
.mobile-menu-list {
  display: flex;
  flex-direction: column;
  padding: 16px;
  gap: 12px;
}

.mobile-menu-list li {
  list-style: none;
  margin-bottom: 6px;
}

.mobile-menu-list li a {
  color: white;
  text-decoration: none;
  font-size: 16px;
  padding: 6px 0;
  display: block;
  border-bottom: 1px solid #333;
}

.mobile-menu-list li a:hover {
  color: #ddd;
}


.mobile-menu-list li.current-menu-item > a {
  background-color: rgba(255, 255, 255, 0.1); /* trắng đục mờ */
  border-left: 4px solid white;
  padding-left: 1rem;
  color: white; /* hoặc màu nổi bật hơn nếu muốn */
}

/* Mặc định: desktop */
.desktop-only {
  display: flex;
}
.mobile-only {
  display: none;
}

/* Khi ở mobile */
@media screen and (max-width: 768px) {
  .desktop-only {
    display: none !important;
  }
  .mobile-only {
    display: flex !important;
  }
}

.search-button {
  background: transparent;
  border: none;
  padding: 0;
  margin: 0;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  margin-right: 10px;
}


/* dropdown lang */
.lang-switcher {
  position: relative;
  display: inline-block;
  width: auto;
}

.lang-switcher #langToggle {
  width: 40px;
  height: auto;
  cursor: pointer;
  display: block;
  border-radius: 3px;
}


/* Dropdown box */
#langDropdown {
  position: absolute;
  top: 100%;
  left: 0;
  background: white;
  border-radius: 4px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  display: none;
  z-index: 9999;
  min-width: 140px;
  padding: 6px 0;
}

@media (max-width: 1024px) {
#langDropdown {
  left: auto;
  right: 0;
}
}

#langDropdown a {
  display: flex;
  align-items: center;
  padding: 6px 12px;
  text-decoration: none;
  color: #333;
  font-size: 14px;
}

#langDropdown a:hover {
  background-color: #f2f2f2;
}

#langDropdown img {
  width: 24px;
  height: auto;
  margin-right: 8px;
}

.lang-switcher:hover #langDropdown {
  display: block;
}