/*
Theme Name: Cham Museum - Bảo tàng Điêu khắc Chăm Đà Nẵng
Theme URI: https://chammuseum.vn/
Author: Cham Museum Team
Author URI: https://chammuseum.vn/
Description: Theme WordPress chính thức cho Bảo tàng Điêu khắc Chăm Đà Nẵng.
Requires at least: 6.0
Tested up to: 6.7
Requires PHP: 7.4
Version: 1.0.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: chammuseum
*/

/* ==========================================================================
   0. TOPBAR CHÂN THỰC THEO PHƯƠNG ÁN A
   ========================================================================== */
.header-top-bar {
  background-color: var(--secondary-bg-color, #FEF5EE);
  border-bottom: 1px solid #EFE7DE;
  padding: 6px 0;
  font-size: 13px;
  color: #6B5B52;
  font-family: var(--font-body, 'Be Vietnam Pro', sans-serif);
}

.header-top-bar-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.header-top-bar-left {
  display: flex;
  align-items: center;
  gap: 20px;
  flex-wrap: wrap;
}

.topbar-item {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: #6B5B52;
  text-decoration: none;
  font-weight: 500;
  transition: color 0.2s ease;
}

.topbar-item:hover {
  color: var(--accent-color, #D29236);
}

.topbar-item svg {
  color: var(--accent-color, #D29236);
  flex-shrink: 0;
}

.header-top-bar-right {
  display: flex;
  align-items: center;
  gap: 16px;
}

.topbar-hours {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12.5px;
  color: #79716B;
}

.topbar-hours svg {
  color: var(--accent-color, #D29236);
  flex-shrink: 0;
}

@media (max-width: 768px) {
  .header-top-bar-right {
    display: none;
  }
  .header-top-bar-inner {
    justify-content: center;
  }
  .header-top-bar-left {
    justify-content: center;
    gap: 12px;
  }
}

/* ==========================================================================
   1. DESKTOP NAV - LEVEL 3 SUB-DROPDOWN MENU
   ========================================================================== */
.header-container nav ul > li.has-dropdown > a {
  cursor: pointer;
}

.nav-parent-no-link {
  cursor: pointer;
}

.dropdown-menu li {
  position: relative;
}

.dropdown-menu li.has-sub-dropdown > a {
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
}

.nav-sub-arrow-icon {
  margin-left: 8px;
  transition: transform 0.2s ease;
  flex-shrink: 0;
  color: #8C827A;
}

.dropdown-menu li.has-sub-dropdown:hover > a .nav-sub-arrow-icon {
  transform: translateX(3px);
  color: var(--accent-color, #D29236);
}

/* Level 3 Submenu (bay ngang sang phải) */
.dropdown-sub-menu {
  position: absolute;
  top: -8px;
  left: 100%;
  min-width: 230px;
  background-color: #FFFFFF;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.16);
  border-radius: 4px;
  padding: 8px 0;
  margin: 0;
  list-style: none;
  opacity: 0;
  visibility: hidden;
  transform: translateX(-8px);
  transition: opacity 0.25s ease, transform 0.25s ease, visibility 0.25s ease;
  z-index: 1010;
  pointer-events: none;
  border-top: 2px solid var(--accent-color, #D29236);
}

.dropdown-menu li.has-sub-dropdown:hover > .dropdown-sub-menu,
.dropdown-menu li.has-sub-dropdown:focus-within > .dropdown-sub-menu {
  opacity: 1;
  visibility: visible;
  transform: translateX(0);
  pointer-events: auto;
}

/* ==========================================================================
   2. MOBILE DRAWER - LEVEL 3 ACCORDION & TOGGLES
   ========================================================================== */
.mobile-nav-link.mobile-nav-link-toggle {
  cursor: pointer;
}

.mobile-sub-submenu {
  list-style: none;
  margin: 0;
  padding: 0;
  background-color: #F5EFE9;
  display: none;
  border-top: 1px solid #EAE3DC;
}

.mobile-sub-item.is-expanded > .mobile-sub-submenu {
  display: block;
}

.mobile-sub-submenu li a {
  display: block;
  padding: 10px 20px 10px 46px !important;
  color: #454141;
  font-size: 13.5px !important;
  font-weight: 500;
  text-decoration: none;
  border-bottom: 1px solid #ECE4DC;
  transition: all 0.2s ease;
}

.mobile-sub-submenu li a:hover {
  color: var(--accent-color, #D29236);
  background-color: #EEE4DA;
  padding-left: 50px !important;
}

/* Polylang switchers in mobile drawer */
.mobile-drawer-lang a.active {
  color: var(--accent-color, #D29236);
  font-weight: 700;
}
