/* ── Top Bar ─────────────────────────────────────────────────────────── */
.trw-top-bar {
  background-color: var(--primary-color);
  border-bottom: 2px solid #000;
  padding: 8px 0;
  font-size: 13px;
  color: #000;
  position: relative;
}

.trw-top-bar .trw-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.trw-top-bar__left,
.trw-top-bar__right {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

.trw-top-bar__item {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  line-height: 1;
}

/* ══════════════════════════════════════════════════════════════════════
   UNIFIED HOVER SYSTEM
   Rule: border-bottom 2px solid #FDB71B + color #000 on all interactive
   ══════════════════════════════════════════════════════════════════════ */

/* Top bar links */
.trw-top-bar__item a { border-bottom: 2px solid transparent; transition: border-color var(--transition); }
.trw-top-bar__item a:hover { border-bottom-color: #000; }

/* Nav links */
.trw-nav-menu > li > a.nav-link {
  border-bottom: 2px solid transparent;
  border-radius: 0;
  transition: border-color var(--transition), color var(--transition);
}
.trw-nav-menu > li > a.nav-link:hover { border-bottom-color: var(--primary-color); color: #000; }
.trw-nav-menu > li > a.nav-link:hover::after { display: none; } /* remove pseudo-element duplicate */
.trw-nav-menu > li.current-menu-item > a.nav-link { border-bottom-color: #000; color: #000; background: transparent; font-weight: 700; }

/* Icon buttons (search, cart, account) */
.trw-icon-btn { border-bottom: 2px solid transparent; border-top: none; border-left: none; border-right: none; border-radius: 0; transition: border-color var(--transition), filter var(--transition); }
.trw-icon-btn:hover { border-bottom-color: var(--primary-color); background: transparent; }
.trw-icon-btn:hover img { filter: brightness(0); }
.trw-icon-btn:hover svg { fill: #000; }

/* Account btn */
.trw-account-btn { border-bottom: 2px solid transparent; border-top: none; border-left: none; border-right: none; }
.trw-account-btn:hover { border-bottom-color: var(--primary-color); background: transparent; }
.trw-account-btn:hover .trw-account-label { color: #000; }
.trw-account-btn:hover .trw-account-icon { filter: brightness(0); }

/* Hamburger */
.trw-hamburger { border: none; }
.trw-hamburger:hover { color: #000; background: transparent; }

/* Lang link */
.trw-lang-link { border: 1px solid rgba(0,0,0,.3); }
.trw-lang-link:hover { background: #000; color: var(--primary-color); border-color: #000; }
.trw-lang-switcher .wpml-ls-link { border-bottom: 2px solid transparent; }
.trw-lang-switcher .wpml-ls-link:hover { border-bottom-color: #000; }
.trw-lang-switcher .wpml-ls-current-language .wpml-ls-link { border-bottom-color: #000; font-weight: 700; }

.trw-top-bar__item span {
  color: #000;
  font-weight: 500;
}

.trw-top-bar__item i,
.trw-top-bar__item svg {
  font-size: 13px;
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  line-height: 1;
  vertical-align: middle;
}

.trw-top-bar__item .elementor-icon {
  font-size: inherit;
  width: auto;
  height: auto;
  line-height: 1;
}

.trw-top-bar__item img {
  display: inline-flex;
  align-items: center;
  width: 14px;
  height: 14px;
  flex-shrink: 0;
  object-fit: contain;
  vertical-align: middle;
}

.trw-top-bar__hours {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-weight: 500;
}

.trw-lang-switcher {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.trw-lang-link {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  color: #000;
  text-decoration: none;
  font-size: 12px;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: 3px;
  cursor: pointer;
  transition: var(--transition);
  border: 1px solid rgba(0,0,0,.3);
}

.trw-lang-link:hover {
  background: #000;
  color: var(--primary-color);
  border-color: #000;
}

/* WPML native widget styling */
.trw-lang-switcher .wpml-ls-statics-shortcode_actions {
  margin: 0;
}

.trw-lang-switcher .wpml-ls-statics-shortcode_actions ul {
  display: flex;
  list-style: none;
  margin: 0;
  padding: 0;
  gap: 6px;
}

.trw-lang-switcher .wpml-ls-item {
  margin: 0;
}

.trw-lang-switcher .wpml-ls-link {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 6px;
  color: var(--text-primary) !important;
  text-decoration: none !important;
  font-size: 12px;
  border-radius: 3px;
  border: 1px solid transparent;
  transition: var(--transition);
}

.trw-lang-switcher .wpml-ls-link:hover {
  border-color: rgba(0,0,0,.25);
}

.trw-lang-switcher .wpml-ls-current-language .wpml-ls-link {
  border-color: rgba(0,0,0,.35);
  background: rgba(0,0,0,.08);
}

.trw-lang-switcher .wpml-ls-display {
  display: none !important;
}

/* ── Main Header ─────────────────────────────────────────────────────── */
.trw-main-header {
  background-color: #fff;
  padding: 14px 0;
  box-shadow: var(--shadow);
  position: relative;
  z-index: 100;
}

.trw-main-header .trw-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.trw-main-header__left {
  display: flex;
  align-items: center;
  gap: 12px;
  flex: 1;
}

.trw-main-header__center {
  flex: 0 0 auto;
}

.trw-main-header__right {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: 1;
  justify-content: flex-end;
}

/* Language switcher in main header (position: menu) */
.trw-main-header__right .trw-lang-switcher {
  margin-right: 8px;
}

.trw-lang-switcher--icon img {
  display: block;
  width: 18px;
  height: 18px;
}

/* Logo */
.trw-logo {
  display: block;
  line-height: 0;
}

.trw-logo img {
  display: block;
  width: 160px;
  max-width: 100%;
  height: auto;
  transition: opacity var(--transition);
}

.trw-logo:hover img {
  opacity: .85;
}

/* Desktop Nav — hidden by default, shown on desktop */
.trw-nav {
  display: none;
}

.trw-nav-menu {
  display: flex;
  list-style: none;
  margin: 0;
  padding: 0;
  gap: 4px;
}

.trw-nav-menu > li {
  position: relative;
}

.trw-nav-menu > li > a.nav-link {
  display: block;
  padding: 8px 14px;
  color: var(--text-primary);
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
  transition: var(--transition);
  white-space: nowrap;
  position: relative;
}

.trw-caret {
  font-size: 10px;
  margin-left: 4px;
  color: var(--primary-color);
}

/* Dropdown */
.sub-menu.dropdown-menu {
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 200px;
  background: #fff;
  border-top: 3px solid var(--primary-color);
  border-left: 1px solid #000;
  border-right: 1px solid #000;
  border-bottom: 1px solid #000;
  border-radius: 0 0 6px 6px;
  box-shadow: 0 4px 12px rgba(0,0,0,.15);
  list-style: none;
  margin: 4px 0 0;
  padding: 6px 0;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-6px);
  transition: opacity var(--transition), transform var(--transition), visibility var(--transition);
  z-index: 200;
}

.has-dropdown:hover > .sub-menu.dropdown-menu,
.has-dropdown:focus-within > .sub-menu.dropdown-menu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.sub-menu.dropdown-menu a.nav-link {
  padding: 9px 16px;
  font-size: 13px;
  display: block;
  color: var(--text-secondary);
  text-decoration: none;
  border-left: 3px solid transparent;
}

.sub-menu.dropdown-menu a.nav-link:hover {
  background: var(--primary-color);
  color: #000;
  border-left-color: #000;
}

.trw-icon-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  cursor: pointer;
  padding: 8px;
  color: var(--text-primary);
  text-decoration: none;
  position: relative;
  transition: var(--transition);
  gap: 8px;
}

.trw-icon-btn img { display: block; width: 22px; height: 22px; }
.trw-icon-btn svg { width: 22px; height: 22px; fill: var(--text-primary); transition: fill var(--transition); }
.trw-search-toggle img { transition: transform var(--transition); }
.trw-search-toggle.is-active img { transform: rotate(90deg); }

.trw-account-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 12px;
  white-space: nowrap;
  background: transparent;
  cursor: pointer;
  text-decoration: none;
}

.trw-account-btn .trw-account-icon { display: block; width: 22px; height: 22px; flex-shrink: 0; transition: filter var(--transition); }
.trw-account-btn .trw-account-label { font-size: 14px; font-weight: 500; color: var(--text-primary); }

/* Cart badge */
.trw-cart-badge {
  position: absolute;
  top: -2px;
  right: -2px;
  background: #000;
  color: var(--primary-color);
  font-size: 10px;
  font-weight: 700;
  min-width: 18px;
  height: 18px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid var(--primary-color);
  line-height: 1;
  padding: 2px;
}

.trw-cart-badge--hidden {
  display: none;
}

/* Hamburger — SVG inline, black, no background ever */
.trw-hamburger {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  background: transparent !important;
  border: none !important;
  cursor: pointer;
  padding: 4px;
  flex-shrink: 0;
  color: #000;
  transition: color var(--transition);
}

.trw-hamburger svg {
  display: block;
  width: 22px;
  height: 22px;
  flex-shrink: 0;
}

.trw-hamburger:hover { color: #000; background: transparent !important; }
.trw-hamburger.is-open { color: #000; background: transparent !important; }

/* ── Cart Modal — compact ────────────────────────────────────────────── */
.trw-cart-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.45);
  z-index: 9998;
  opacity: 0;
  visibility: hidden;
  transition: var(--transition);
}

.trw-cart-overlay.is-open {
  opacity: 1;
  visibility: visible;
}

.trw-cart-modal {
  position: fixed;
  top: 0;
  right: -340px;
  width: 320px;
  max-width: 88vw;
  height: 100%;
  background: #fff;
  z-index: 9999;
  box-shadow: -2px 0 16px rgba(0,0,0,.18);
  transition: right .28s ease;
  display: flex;
  flex-direction: column;
  border-left: 3px solid var(--primary-color);
}

.trw-cart-modal.is-open {
  right: 0;
}

.trw-cart-modal[hidden] {
  display: flex;
}

.trw-cart-modal__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 14px;
  border-bottom: 2px solid #000;
  background: var(--primary-color);
  flex-shrink: 0;
}

.trw-cart-modal__title {
  font-size: 14px;
  font-weight: 700;
  margin: 0;
  color: #000;
  display: flex;
  align-items: center;
  gap: 4px;
}

.trw-cart-modal__count {
  font-weight: 500;
  font-size: 13px;
}

/* Close button — border only, red, small */
.trw-cart-modal__close {
  background: transparent;
  border: 1px solid #dc3545;
  cursor: pointer;
  color: #dc3545;
  padding: 3px 7px;
  border-radius: 3px;
  font-size: 11px;
  line-height: 1;
  transition: var(--transition);
  display: flex;
  align-items: center;
  justify-content: center;
}

.trw-cart-modal__close:hover {
  background: #dc3545;
  color: #fff;
}

.trw-cart-modal__body {
  flex: 1;
  overflow-y: auto;
  padding: 10px 14px;
}

/* ── Sticky Header ────────────────────────────────────────────────── */
.trw-header--sticky-enabled.is-sticky {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  animation: trw-slide-down 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

@keyframes trw-slide-down {
  from { transform: translateY(-100%); }
  to { transform: translateY(0); }
}

.trw-header--sticky-enabled.is-sticky .trw-top-bar {
  display: none;
}

.trw-header--sticky-enabled.is-sticky .trw-search-toggle,
.trw-header--sticky-enabled.is-sticky .trw-search-bar {
  display: none !important;
}

.trw-header--sticky-enabled.is-sticky .trw-main-header {
  padding: 6px 0;
  border-bottom: 2px solid var(--primary-color);
}

.trw-header--sticky-enabled.is-sticky .trw-logo img {
  width: 130px;
}

.trw-header--sticky-enabled.is-sticky .trw-nav-menu > li > a.nav-link {
  padding-top: 4px;
  padding-bottom: 4px;
}

@media (max-width: 1024px) {
  .trw-header--sticky-enabled.is-sticky .trw-main-header {
    padding: 10px 0;
  }
}

.trw-cart-modal__empty {
  text-align: center;
  padding: 30px 16px;
  color: var(--text-secondary);
  font-size: 13px;
}

.trw-cart-modal__items {
  list-style: none;
  margin: 0;
  padding: 0;
}

.trw-cart-modal__item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 0;
  border-bottom: 1px solid #e8e8e8;
}

.trw-cart-modal__item:last-child {
  border-bottom: none;
}

.trw-cart-modal__item-img {
  flex-shrink: 0;
  width: 48px;
  height: 48px;
  display: block;
  border-radius: 3px;
  overflow: hidden;
  border: 1px solid #ddd;
}

.trw-cart-modal__item-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.trw-cart-modal__item-info {
  flex: 1;
  min-width: 0;
}

.trw-cart-modal__item-name {
  display: block;
  font-size: 12px;
  font-weight: 600;
  color: #000;
  text-decoration: none;
  margin-bottom: 2px;
  line-height: 1.3;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.trw-cart-modal__item-name:hover {
  color: var(--primary-hover);
}

.trw-cart-modal__item-meta {
  font-size: 11px;
  color: var(--text-secondary);
}

/* Remove button — border only, red, small */
.trw-cart-modal__item-remove {
  background: transparent;
  border: 1px solid #dc3545;
  cursor: pointer;
  color: #dc3545;
  padding: 3px 6px;
  font-size: 10px;
  border-radius: 3px;
  transition: var(--transition);
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
}

.trw-cart-modal__item-remove:hover {
  background: #dc3545;
  color: #fff;
}

.trw-cart-modal__footer {
  border-top: 2px solid #000;
  padding: 10px 14px;
  background: #fafafa;
  flex-shrink: 0;
}

.trw-cart-modal__subtotal {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
  font-size: 13px;
}

.trw-cart-modal__subtotal strong {
  color: #000;
  font-weight: 700;
}

.trw-cart-modal__actions {
  display: flex;
  gap: 6px;
}

.trw-cart-modal__btn {
  flex: 1;
  padding: 8px 10px;
  text-align: center;
  text-decoration: none;
  border-radius: 3px;
  font-size: 12px;
  font-weight: 600;
  transition: var(--transition);
  display: block;
  border: 2px solid transparent;
}

.trw-cart-modal__btn--primary {
  background: #000;
  color: var(--primary-color);
  border-color: #000;
}

.trw-cart-modal__btn--primary:hover {
  background: var(--primary-color);
  color: #000;
  border-color: var(--primary-color);
}

.trw-cart-modal__btn--secondary {
  background: transparent;
  color: #000;
  border-color: #000;
}

.trw-cart-modal__btn--secondary:hover {
  background: #000;
  color: var(--primary-color);
}

/* ── Mobile overlay + drawer ─────────────────────────────────────────── */
.trw-mobile-menu {
  position: fixed;
  top: 0;
  left: -300px;
  width: 280px;
  max-width: 85vw;
  height: 100%;
  background: #fff;
  z-index: 9001;
  box-shadow: 2px 0 12px rgba(0,0,0,.2);
  transition: left .3s ease;
  overflow-y: auto;
  padding: 0;
  border-right: 3px solid var(--primary-color);
}

.trw-mobile-menu.is-open {
  left: 0;
}

.trw-mobile-menu[hidden] {
  display: block;
}

.trw-mobile-menu__close {
  position: absolute;
  top: 10px;
  right: 10px;
  background: transparent;
  border: 1px solid #dc3545;
  cursor: pointer;
  color: #dc3545;
  padding: 3px 7px;
  border-radius: 3px;
  font-size: 11px;
  line-height: 1;
  transition: var(--transition);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10;
}

.trw-mobile-menu__close:hover {
  background: #dc3545;
  color: #fff;
}

.trw-mobile-menu__nav .trw-nav-menu {
  flex-direction: column;
  gap: 0;
  border-top: 2px solid #000;
}

.trw-mobile-menu__nav .trw-nav-menu > li {
  border-bottom: 1px solid #e0e0e0;
  border-left: 3px solid transparent;
  transition: var(--transition);
}

.trw-mobile-menu__nav .trw-nav-menu > li:hover {
  border-left-color: var(--primary-color);
}

.trw-mobile-menu__nav .trw-nav-menu > li > a.nav-link {
  padding: 14px 20px;
  border-radius: 0;
  font-size: 15px;
  font-weight: 500;
}

.trw-mobile-menu__nav .trw-nav-menu > li > a.nav-link:hover {
  background: var(--primary-color);
  color: #000;
}

.trw-mobile-menu__nav .sub-menu.dropdown-menu {
  position: static;
  opacity: 1;
  visibility: visible;
  transform: none;
  box-shadow: none;
  border: none;
  border-radius: 0;
  border-left: 2px solid var(--primary-color);
  padding: 0 0 0 16px;
  display: none;
  background: #fafafa;
}

.trw-mobile-menu__nav .has-dropdown.is-open > .sub-menu.dropdown-menu {
  display: block;
}

.trw-mobile-menu__cart {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 20px;
  color: #000;
  text-decoration: none;
  font-size: 15px;
  font-weight: 600;
  border-top: 2px solid #000;
  background: var(--primary-color);
  margin-top: 8px;
  transition: var(--transition);
}

.trw-mobile-menu__cart:hover {
  background: var(--primary-hover);
}

.trw-mobile-menu__cart img {
  width: 22px;
  height: 22px;
  display: block;
  flex-shrink: 0;
  filter: brightness(0);
}

/* ── Responsive ──────────────────────────────────────────────────────── */
@media (min-width: 1025px) {
  .trw-nav { display: flex !important; }
  .trw-hamburger { display: none !important; }
  .trw-logo img { width: 220px; }
}

/* ── MOBILE — app-like compact layout ───────────────────────────────── */
@media (max-width: 1024px) {
  .trw-account-btn .trw-account-label { display: none; }
  .trw-account-btn { padding: 6px; }
}

@media (max-width: 768px) {

  /* Top bar: icons only, single row, no text */
  .trw-top-bar { padding: 6px 0; border-bottom: 1px solid rgba(0,0,0,.15); }
  .trw-top-bar .trw-container {
    flex-direction: row; align-items: center; justify-content: space-between;
    gap: 0; flex-wrap: nowrap; overflow: visible;
  }
  .trw-top-bar__left { gap: 10px; flex-shrink: 0; }
  .trw-top-bar__right { gap: 8px; flex-shrink: 0; }

  /* Hide text, show only icons in top bar on mobile */
  .trw-top-bar__text { display: none; }
  .trw-top-bar__item--hide-mobile { display: none !important; }
  .trw-top-bar__item a { gap: 4px; }
  .trw-top-bar__item { gap: 4px; }
  .trw-top-bar__item img { width: 16px; height: 16px; }
  .trw-top-bar__item i, .trw-top-bar__item svg { font-size: 15px !important; }

  /* WPML lang: show only flag/code, no full name */
  .trw-lang-link { padding: 2px 5px; font-size: 10px; }
  .trw-lang-switcher .wpml-ls-native { font-size: 10px; }
  .trw-lang-switcher .wpml-ls-link { padding: 2px 4px; font-size: 10px; }

  /* Main header: compact, 44px total height */
  .trw-main-header { padding: 5px 0; }
  .trw-main-header .trw-container { gap: 6px; }
  .trw-main-header__left { flex: 0 0 auto; gap: 4px; }
  .trw-main-header__center { flex: 1; display: flex; justify-content: center; }
  .trw-main-header__right { flex: 0 0 auto; gap: 4px; }

  .trw-logo img { width: 110px; }

  /* Icons: smaller, no padding waste */
  .trw-icon-btn { padding: 5px; border-bottom: none; }
  .trw-icon-btn img { width: 20px; height: 20px; }
  .trw-account-btn { padding: 5px; }
  .trw-account-btn .trw-account-label { display: none; }
  .trw-account-btn .trw-account-icon { width: 20px; height: 20px; }

  .trw-hamburger { width: 30px; height: 30px; }
  .trw-hamburger svg { width: 20px; height: 20px; }

  .trw-cart-badge {
    min-width: 15px; height: 15px; font-size: 9px;
    top: 0; right: 0; border-width: 1px;
  }
}

@media (max-width: 480px) {
  .trw-container { padding: 0 10px; }
  .trw-logo img { width: 90px; }
  .trw-main-header { padding: 5px 0; }
  .trw-icon-btn img { width: 18px; height: 18px; }
  .trw-hamburger svg { width: 18px; height: 18px; }
}
