/* Header Top */
.full-header-top {
  background: #1a1a1a;
  padding: 20px 0;
  color: #fff;
}
.inner-header-top {
  margin: 0 auto;
  padding: 0 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.header-logo img {
  height: 60px !important;
}
.header-search {
  flex: 1;
  max-width: 600px;
  margin: 0 40px;
}
.search-wrapper {
  display: flex;
  height: 40px;
}
.category-select {
  background: #fff;
  border: none;
  outline: none;
  padding: 0 20px;
  border-radius: 4px 0 0 4px;
  font-size: 16px;
  color: #666;
  width: 25%;
}
.search-input {
  flex: 1;
  padding: 0 15px;
  border: none;
  outline: none;
  font-size: 16px;
}
.search-button {
  background: #ffb700;
  border: none;
  outline: none;
  padding: 0 20px;
  font-weight: bold;
  font-size: 16px;
  color: #333;
  border-radius: 0 4px 4px 0;
  cursor: pointer;
}
.header-contact-links {
  display: flex;
  gap: 50px;
  align-items: center;
}
.header-contact-links a {
  color: #fff;
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 15px;
}
.header-contact-links i {
  font-size: 24px;
  color: #ffb700;
}

.underline {
  text-decoration: underline;
}

/* Header Main */
.full-header {
  background: #ffb700;
  z-index: 100;
}
.inner-header {
  display: flex;
  align-items: center;
  gap: 15px;
  width: 100%;
  position: relative;
}

/* Mega Menu */
.category-menu-wrapper {
  padding: 10px 0;
}
.category-menu-dropdown {
  background: #fff;
  color: #000;
  padding: 12px 30px;
  border-radius: 4px;
  font-weight: bold;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 10px;
}
.category-menu-wrapper.open .category-menu-dropdown {
  background-color: #000;
  color: #fff;
}
/* .category-menu-wrapper:hover .handmade-mega-menu {
  display: block;
} */
.handmade-mega-menu {
  display: none;
  position: absolute;
  top: 100%;
  width: 100%;
  min-height: 70vh;
  left: 0;
  z-index: 9999;
}

.category-menu-wrapper.open .handmade-mega-menu {
  display: block;
}

.mega-sub-panel {
  display: none;
  grid-template-columns: 1fr 30%;
  gap: 15px;
  align-items: stretch;
  min-height: 70vh;
}

.mega-sub-panel.active {
  display: grid;
}
.mega-container {
  display: flex;
  width: 100%;
  min-height: 70vh;
}
.mega-sidebar {
  width: 20%;
  background: #1a1a1a;
  padding: 20px;
}
.mega-parent-item {
  padding: 14px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}
.mega-parent-item a {
  color: #fff;
  text-decoration: none;
  font-weight: bold;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.mega-parent-item:hover a,
.mega-parent-item.active a {
  color: #ffc107;
}

.mega-content {
  display: none;
  flex: 1;
  padding-left: 30px;
  background: #fff;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
}
.mega-container.has-sub-content .mega-content {
  display: block; /* hoặc flex/grid tùy layout */
}
.mega-sub-panel {
  display: none;
  grid-template-columns: 1fr 0.4fr;
  gap: 15px;
  align-items: start;
}
.mega-sub-panel.active {
  display: grid;
}
.mega-left-section {
  width: 100%; /* Để chừa chỗ cho banner bên phải */
  padding-bottom: 20px;
}

.mega-sub-columns-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 40px;
}

.mega-sub-column-3 {
  display: flex;
  flex-direction: column;
}

.sub-cat-block {
  height: 100%;
  display: flex;
  flex-direction: column;
}

.sub-cat-title {
  margin-bottom: 10px;
}

.sub-cat-title img {
  width: 100%;
  height: auto;
  aspect-ratio: 4/3;
  object-fit: cover;
  border-radius: 6px;
}

.sub-cat-title h4 {
  margin: 0;
  font-size: 16px;
  font-weight: bold;
}

.sub-cat-title h4 a {
  color: #333;
  text-decoration: none;
}

.sub-cat-title h4 a:hover {
  color: #ffc107;
}

.sub-cat-products-grid h5 {
  color: #000;
  font-size: 13px;
  font-weight: 400;
  margin: 8px 0;
  line-height: 1.3;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}
.sub-cat-products-grid h5:hover {
  color: #ffb700;
}
.sub-cat-products-grid .price {
  color: #e91e63;
  font-weight: bold;
  font-size: 14px;
}

.sub-cat-view-all {
  margin-top: auto;
  font-size: 15px;
  font-weight: bold;
  color: #ffc107;
  text-decoration: none;
}

.sub-cat-view-all:hover {
  text-decoration: underline;
}
.mega-products-grid {
  padding: 20px;
}
.products-grid-3x5 {
  margin-top: 15px;
  display: grid;
  grid-template-columns: repeat(3, 1fr); /* 5 cột */
  gap: 15px;
}
.products-grid-3x5 .product-item {
  text-align: center;
  border: 1px solid #eee !important;
  padding: 10px;
  border-radius: 8px;
}
.products-grid-3x5 .product-item img {
  width: 100%;
  height: auto;
  object-fit: cover;
}
.products-grid-3x5 .product-item h5 {
  color: #000;
}
.products-grid-3x5 .product-item:hover h5 {
  color: #ffb700;
}
.view-all-products {
  display: block;
  text-align: center;
  margin-top: 20px;
  font-weight: bold;
  color: #e74c3c;
}
/* Banner */
.mega-banner {
  position: relative;
  height: 100%;
}
.mega-banner img {
  width: 100%;
  height: 100% !important;
  object-fit: contain;
  border-radius: 12px;
}
.banner-view-all {
  position: absolute;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  background: rgba(0, 0, 0, 0.7);
  color: #ffc107;
  padding: 10px;
  border-radius: 30px;
  font-weight: bold;
  font-size: 16px;
  text-decoration: none;
  transition: 0.3s;
}
.banner-view-all:hover {
  background: #ffc107;
  color: #333;
}

/* Main menu & icons */
.main-menu {
  flex: 1;
}
/* ====================== MAIN MENU MULTI-LEVEL ====================== */
.main-menu-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  align-items: center;
  gap: 20px;
  flex-wrap: wrap; /* An toàn nếu nhiều item */
}

.main-menu-list > li {
  position: relative;
}

.main-menu-list > li > a {
  color: #333;
  text-decoration: none;
  font-weight: bold;
  font-size: 16px;
  padding: 5px;
  display: block;
  transition: color 0.3s;
  position: relative;
  width: 100%;
}

.main-menu-list > li > a:hover::after,
.main-menu-list > li.current-menu-item > a::after {
  content: "";
  position: absolute;
  display: block;
  width: 100%;
  height: 2px;
  background-color: #000;
  bottom: 0;
  left: 0;
}

/* Submenu chung (từ cấp 2 trở đi) */
.main-menu-list ul {
  list-style: none;
  margin: 0;
  padding: 10px 0;
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 220px;
  background: #fff;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
  border-radius: 8px;
  opacity: 0;
  visibility: hidden;
  transform: translateY(15px);
  transition: all 0.3s ease;
  z-index: 999;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
}

/* Cấp 3+ mở sang phải */
.main-menu-list ul ul {
  left: 100%;
  transform: translateX(15px);
}

.main-menu-list ul li {
  position: relative;
  border-bottom: 1px solid #eee;
}

.main-menu-list ul li:last-child {
  border-bottom: none;
}

.main-menu-list ul a {
  display: block;
  padding: 12px 20px;
  color: #333;
  font-size: 15px;
  font-weight: 500;
  white-space: nowrap;
  transition: all 0.3s;
}

.main-menu-list ul a:hover {
  background: #ffb700;
  color: #fff;
  padding-left: 25px;
}

/* New badge */
.new-badge-item {
  margin-left: 10px;
}
.new-badge {
  background: #fff;
  color: #333;
  padding: 4px 10px;
  border-radius: 4px;
  font-size: 12px;
  font-weight: bold;
}

/* ====================== DESKTOP: HOVER ====================== */
@media (min-width: 901px) {
  .main-menu-list li:hover > ul {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
  }
  .main-menu-list ul li:hover > ul {
    opacity: 1;
    visibility: visible;
    transform: translateX(0);
  }
}

/* ====================== MOBILE: CLICK ACCORDION ====================== */
@media screen and (min-width: 900px) and (max-width: 1024px) {
}

.new-badge-item {
  margin-left: 10px;
}
.new-badge {
  background: #fff;
  padding: 4px 10px;
  border-radius: 4px;
  font-size: 12px;
}
.header-right-icons {
  display: flex;
  align-items: center;
  gap: 15px;
}
.header-right-icons a {
  color: #333;
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 8px;
  position: relative;
}
.cart-count {
  color: #000;
  font-size: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* MOBILE HEADER */
.full-header-mobile {
  display: none;
  background: #ffb700;
  padding: 12px 0;
  position: relative;
  z-index: 1000;
}
.inner-header-mobile {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.mobile-logo img {
  height: 40px;
}
.mobile-actions {
  display: flex;
  align-items: center;
  gap: 20px;
}
.mobile-actions i {
  font-size: 24px;
  color: #333;
}

/* MOBILE MENU OVERLAY */
.mobile-menu-overlay {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.9);
  z-index: 9999;
  overflow-y: auto;
}
.mobile-menu-overlay.open {
  display: block;
}

/* TABS */
.mobile-tabs {
  display: flex;
  background: #ffb700;
}
.mobile-tab {
  flex: 1;
  text-align: center;
  padding: 16px 0;
  font-weight: bold;
  font-size: 16px;
  color: #333;
  border-bottom: 4px solid transparent;
  cursor: pointer;
}
.mobile-tab.active {
  color: #000;
  border-bottom-color: #000;
}

/* PANELS */
.mobile-panel {
  display: none;
  background: #111;
  min-height: 100vh;
  padding: 20px 0;
}
.mobile-panel.active {
  display: block;
}

/* MENU PANEL */
.mobile-main-menu {
  list-style: none;
  margin: 0;
  padding: 0;
}
.mobile-main-menu > li > a {
  display: block;
  padding: 16px 30px;
  color: #fff;
  font-weight: bold;
  font-size: 16px;
  border-bottom: 1px solid #333;
}

/* SHOP PANEL */
.mobile-shop-categories {
  list-style: none;
  margin: 0;
  padding: 0;
}
.mobile-shop-categories .cat-item > a {
  display: block;
  padding: 16px 30px;
  color: #fff;
  font-size: 16px;
  font-weight: bold;
  position: relative;
  border-bottom: 1px solid #222;
}
.mobile-shop-categories .toggle-icon {
  position: absolute;
  right: 30px;
  top: 50%;
  transform: translateY(-50%);
  transition: transform 0.3s;
}
.mobile-shop-categories .has-children.open .toggle-icon {
  transform: translateY(-50%) rotate(180deg);
}
.mobile-shop-categories .sub-cats {
  display: none;
  background: #222;
}
.mobile-shop-categories .has-children.open .sub-cats {
  display: block;
}
.mobile-shop-categories .sub-cats a {
  padding: 14px 50px;
  font-weight: normal;
  font-size: 15px;
  color: #ccc;
  border-bottom: none;
}

/* CLOSE BUTTON */
.mobile-menu-close {
  position: absolute;
  bottom: 30px;
  left: 50%;
  transform: translateX(-50%);
  width: 50px;
  height: 50px;
  background: #333;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 10000;
}
.mobile-menu-close i {
  font-size: 28px;
  color: #fff;
}

/* RESPONSIVE */
@media (max-width: 900px) {
  .full-header {
    display: none;
  } /* Ẩn header desktop */
  .full-header-top {
    display: none;
  } /* Ẩn header top nếu muốn gọn */
  .full-header-mobile {
    display: block;
  }
  .main-menu-list > li.current-menu-item > a::after {
    display: none;
  }
}

.mobile-main-menu {
  list-style: none;
  margin: 0;
  padding: 0;
}

.mobile-main-menu > li {
  width: 100%;
  border-bottom: 1px solid #444;
  position: relative;
}

.mobile-main-menu > li > a {
  display: block;
  padding: 16px 30px;
  color: #fff;
  font-weight: bold;
  font-size: 17px;
  text-decoration: none;
  position: relative;
}

/* Mũi tên cho item có submenu */
.mobile-main-menu .menu-item-has-children > a::after {
  content: "\f078";
  font-family: "Font Awesome 5 Free";
  font-weight: 900;
  position: absolute;
  right: 30px;
  top: 50%;
  transform: translateY(-50%);
  transition: transform 0.3s;
}

.mobile-main-menu .menu-item-has-children.open > a::after {
  transform: translateY(-50%) rotate(180deg);
}

/* Submenu */
.mobile-main-menu .sub-menu {
  display: none;
  background: #222;
}

.mobile-main-menu .menu-item-has-children.open > .sub-menu {
  display: block;
}

.mobile-main-menu .sub-menu a {
  display: block;
  padding: 14px 50px;
  color: #ccc;
  font-size: 16px;
}

.mobile-main-menu .sub-menu .sub-menu a {
  padding-left: 70px;
}

.mobile-main-menu .sub-menu .sub-menu .sub-menu a {
  padding-left: 90px;
}

/* Ẩn badge New trên mobile */
.mobile-main-menu .new-badge-item {
  display: none;
}
/* Mobile Search Popup */
.mobile-search-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.6);
  z-index: 9998;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s ease;
}

.mobile-search-overlay.open {
  opacity: 1;
  visibility: visible;
}

.mobile-search-popup {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  background: rgba(0, 0, 0, 0.4);
  padding: 20px;
  transform: translateY(-100%);
  transition: transform 0.4s cubic-bezier(0.25, 0.8, 0.25, 1);
}

.mobile-search-overlay.open .mobile-search-popup {
  transform: translateY(0);
}

.search-close {
  position: absolute;
  top: 15px;
  right: 20px;
  font-size: 24px;
  color: #999;
  cursor: pointer;
  z-index: 10;
}
.mobile-search-form {
  margin-top: 30px;
}
.mobile-search-form .search-wrapper {
  display: flex;
  align-items: center;
  height: auto;
  border-radius: 50px;
  overflow: hidden;
}

.mobile-search-form .category-select {
  padding: 15px 20px;
  border: none;
  font-size: 16px;
  color: #333;
  min-width: 140px;
  border-right: 1px solid #eee;
  background-color: #fff;
}
.mobile-search-form .search-input {
  flex: 1;
  width: 100%;
  height: 40px;
  padding: 10px;
  border: none;
  background: transparent;
  font-size: 16px;
  outline: none;
  background-color: #fff;
}

.mobile-search-form .search-button {
  cursor: pointer;
  margin-right: 5px;
  transition: all 0.3s;
  height: 40px;
  width: 100%;
}

.mobile-search-form .search-button:hover {
  background: #e65c00;
  transform: scale(1.1);
}

.flag-language-switch {
  position: relative;
  display: inline-block;
  font-family: sans-serif;
}

.flag-selected {
  cursor: pointer;
  display: flex;
  align-items: stretch;
  gap: 6px;
  background-color: transparent;
  color: #fff;
  border-radius: 5px;
  padding: 5px 10px;
  transition: background 0.3s;
}
.current-flag {
  border-radius: 50%;
  height: 25px;
  width: 25px;
  object-fit: cover;
}
.flag-text {
  display: flex;
  align-items: center;
  gap: 2px;
}
.current-lang-code {
  width: calc(100% - 25px);
  font-weight: 600;
  text-transform: uppercase;
  font-size: 14px;
  color: #000;
}

.arrow-down {
  transition: transform 0.2s ease;
  width: 20px;
  stroke: #000;
}

.flag-selected.active .arrow-down {
  transform: rotate(180deg);
}

.flag-dropdown {
  position: absolute;
  top: 38px;
  left: 50%;
  transform: translateX(-50%);
  background: #fff;
  border-radius: 5px;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.15);
  z-index: 9999;
  display: none;
  min-width: auto;
  padding: 10px 20px;
}

.flag-item {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 8px 12px;
  cursor: pointer;
  transition: background 0.2s;
}

.flag-item:hover {
  background: #f5f5f5;
}
/* Ẩn popup đánh giá bản dịch và tooltip phản hồi */
.goog-tooltip,
.goog-tooltip:hover,
.goog-tooltip::after,
.goog-tooltip::before,
.goog-te-balloon-frame,
.goog-te-banner-frame,
#goog-gt-tt {
  display: none !important;
  visibility: hidden !important;
  opacity: 0 !important;
  pointer-events: none !important;
}
/* Responsive điều chỉnh */
@media (max-width: 900px) {
  .mobile-search-form .search-wrapper {
    flex-direction: column;
    gap: 15px;
    border-radius: 12px;
  }

  .mobile-search-form .category-select {
    width: 100%;
    border-right: none;
    border-radius: none;
  }

  .mobile-search-form .search-button {
    margin: 0 !important;
  }
  .current-lang-code {
    color: #fff;
  }
  .arrow-down {
    stroke: #fff;
  }
}
