/* ==========================================================================
   1. Top Navigation & SmartMenus Theme (Consolidated)
   ========================================================================== */

/* -------------------------------------------------------------------------
   Base & Mobile Layout (Mobile-first, collapsible mode)
   ------------------------------------------------------------------------- */
.sm-simple {
  list-style: none;
  margin: 0;
  padding: 0;
  background: transparent;
}

.sm-simple,
.sm-simple * {
  box-sizing: border-box;
}

.sm-simple a,
.sm-simple a:link,
.sm-simple a:visited,
.sm-simple a:hover,
.sm-simple a:focus,
.sm-simple a:active {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 18px;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.4;
  color: #2c1e10;
  text-decoration: none;
  position: relative;
  transition: background-color 0.15s ease, color 0.15s ease;
}

.sm-simple a:hover,
.sm-simple a:focus {
  background: rgba(255, 255, 255, 0.55);
  color: #6b1d2f;
}

.sm-simple a.disabled {
  color: #8c7660;
  cursor: default;
}

/* Sub-indicator: Clear, solid, high-contrast marker - NO movement */
.sm-simple a .sub-arrow {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 14px;
  height: 14px;
  margin-left: auto;
  flex: 0 0 14px;
  pointer-events: none;
}

.sm-simple a .sub-arrow::after {
  content: '';
  display: block;
  width: 0;
  height: 0;
  border-left: 5px solid transparent;
  border-right: 5px solid transparent;
  border-top: 6px solid #241608;
  transform: none !important;
  transition: none !important;
}

.sm-simple li {
  position: relative;
  border-top: 1px solid rgba(80, 50, 15, 0.08);
}

.sm-simple > li:first-child {
  border-top: 0;
}

.sm-simple ul {
  position: static;
  display: none;
  list-style: none;
  margin: 0;
  padding: 0;
  background: rgba(240, 228, 209, 0.55);
  border-top: 1px solid rgba(80, 50, 15, 0.08);
  border-bottom: 1px solid rgba(80, 50, 15, 0.08);
}

.sm-simple ul a,
.sm-simple ul a:link,
.sm-simple ul a:visited {
  padding: 10px 18px 10px 32px;
  font-size: 13.5px;
  font-weight: 500;
  color: #3b2b1a;
  border-left: 3px solid transparent;
}

.sm-simple ul a:hover,
.sm-simple ul a:focus {
  background: rgba(255, 255, 255, 0.65);
  color: #6b1d2f;
  border-left-color: #c5a059;
}

.sm-simple ul ul a {
  padding-left: 44px;
}

.sm-simple ul a img {
  margin-right: 8px;
  vertical-align: middle;
  border-radius: 2px;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.15);
}

.sm-simple .menu-globe-icon {
  width: 19px;
  height: 19px;
  vertical-align: middle;
  margin-right: 6px;
}

/* -------------------------------------------------------------------------
   Desktop Layout (min-width: 769px)
   STRICT: All items have IDENTICAL styling, zero width shift, zero movement
   ------------------------------------------------------------------------- */
@media (min-width: 769px) {
  .topmenu-mobile-bar {
    display: none !important;
  }

  #layoutMenu {
    height: 32px !important;
    min-height: 32px !important;
    max-height: 32px !important;
  }

  #topmenu-nav {
    height: 32px;
  }

  #main-menu {
    display: block !important;
    height: 32px;
  }

  .sm-simple {
    display: flex;
    align-items: center;
    width: 100%;
    height: 32px;
  }

  .sm-simple > li {
    float: left;
    height: 32px;
    border-top: 0;
    border-left: 0;
  }

  .sm-simple > li.langglobe {
    margin-left: auto;
  }

  .sm-simple > li > a,
  .sm-simple > li > a:link,
  .sm-simple > li > a:visited {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: 32px;
    padding: 0 12px !important;
    font-size: 13px;
    font-weight: 600;
    line-height: 32px !important;
    white-space: nowrap;
    color: #2c1e10 !important;
    text-decoration: none;
    background: transparent;
    transition: background-color 0.15s ease, color 0.15s ease;
  }

  .sm-simple > li > a:hover,
  .sm-simple > li > a:focus,
  .sm-simple > li > a.highlighted {
    background: rgba(255, 255, 255, 0.35) !important;
    color: #1a1107 !important;
    font-size: 13px !important;
    font-weight: 600 !important;
    padding: 0 12px !important;
    height: 32px !important;
    line-height: 32px !important;
    transform: none !important;
  }

  .sm-simple > li > a.has-submenu {
    padding: 0 12px !important;
  }

  .sm-simple > li > a .sub-arrow {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 9px;
    height: 9px;
    margin-left: 6px;
    margin-right: 0;
    flex: 0 0 9px;
    position: static;
    border: none;
    background: transparent;
    pointer-events: none;
  }

  .sm-simple > li > a .sub-arrow::after {
    content: '';
    display: block;
    width: 0;
    height: 0;
    border-left: 4.5px solid transparent;
    border-right: 4.5px solid transparent;
    border-top: 5.5px solid #241608;
    opacity: 0.92;
    transform: none !important;
    transition: none !important;
  }

  .sm-simple > li > a:hover .sub-arrow::after,
  .sm-simple > li > a:focus .sub-arrow::after,
  .sm-simple > li > a.highlighted .sub-arrow::after {
    border-top-color: #1a0f05;
    opacity: 1;
    transform: none !important;
    transition: none !important;
  }

  /* Completely suppress legacy plus (+) / minus signs and any pseudoelement markers */
  .sm-simple a .sub-arrow::before,
  .sm-simple a.has-submenu::before,
  .sm-simple li a .sub-arrow::before {
    content: none !important;
    display: none !important;
  }


  .sm-simple ul {
    position: absolute;
    width: auto !important;
    min-width: 14em;
    max-width: 34em;
    white-space: nowrap;
    background: #ffffff;
    border: 1px solid rgba(80, 50, 15, 0.15);
    border-radius: 8px;
    box-shadow: 0 10px 25px -4px rgba(44, 33, 19, 0.18), 0 4px 8px -2px rgba(44, 33, 19, 0.08);
    padding: 5px 0;
    z-index: 1000;
  }

  .sm-simple ul li {
    float: none;
    border-top: 0;
    height: auto;
  }

  .sm-simple ul a,
  .sm-simple ul a:link,
  .sm-simple ul a:visited {
    display: flex;
    align-items: center;
    padding: 7px  18px;
    font-size: 13px;
    font-weight: 500;
    line-height: 1.4 !important;
    white-space:  nowrap !important;
    color: #2c1e10;
    border-left: 3px solid transparent;
    transition: background-color 0.15s ease, color 0.15s ease, border-color 0.15s ease;
  }

  .sm-simple ul a:hover,
  .sm-simple ul a:focus,
  .sm-simple ul a:active,
  .sm-simple ul a.highlighted {
    background: #fbf6ec;
    color: #6b1d2f;
    font-size: 13px !important;
    font-weight: 500 !important;
    padding: 7px  18px !important;\n    white-space: nowrap !important;
    border-left-color: #c5a059;
    transform: none !important;
  }

  .sm-simple ul a .sub-arrow {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 8px;
    height: 8px;
    margin-left: auto;
    flex: 0 0 8px;
    pointer-events: none;
  }

  .sm-simple ul a .sub-arrow::after {
    content: '';
    display: block;
    width: 0;
    height: 0;
    border-top: 4px solid transparent;
    border-bottom: 4px solid transparent;
    border-left: 5px solid #241608;
    transform: none !important;
    transition: none !important;
  }

  .sm-simple > li.langglobe > a {
    padding: 0 10px !important;
  }

  .sm-simple > li.langglobe > a .sub-arrow {
    display: none !important;
  }

  .sm-simple > li.langglobe .lang-menu-text {
    display: none;
  }

  .sm-simple > li.langglobe > ul {
    right: 0 !important;
    left: auto !important;
    min-width: 9.5em;
    width: auto;
  }

  .sm-simple > li.langglobe > ul a {
    white-space: nowrap;
    gap: 8px;
  }
}

/* -------------------------------------------------------------------------
   Mobile Specific Layout (max-width: 768px)
   ------------------------------------------------------------------------- */
@media (max-width: 768px) {
  #layoutMenu {
    position: relative;
    height: auto !important;
    min-height: 42px !important;
    background: linear-gradient(180deg, #f0dfb8 0%, #d8b875 100%);
    border-bottom: 1px solid rgba(80, 50, 15, 0.2);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.55), 0 2px 4px rgba(0, 0, 0, 0.04);
    z-index: 1000;
  }

  .topmenu-mobile-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 42px;
    padding: 0 10px;
    box-sizing: border-box;
  }

  .main-menu-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    height: 32px;
    padding: 0 11px;
    background: rgba(255, 255, 255, 0.4);
    border: 1px solid rgba(80, 50, 15, 0.22);
    border-radius: 6px;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    font-size: 13px;
    font-weight: 700;
    color: #2c1e10;
    cursor: pointer;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
    transition: background 0.15s ease, border-color 0.15s ease, transform 0.1s ease;
  }

  .main-menu-btn:active {
    transform: scale(0.97);
  }

  .main-menu-btn:hover {
    background: rgba(255, 255, 255, 0.6);
  }

  .main-menu-btn-icon {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    width: 15px;
    height: 12px;
  }

  .main-menu-btn-icon .bar {
    display: block;
    width: 100%;
    height: 2px;
    background: #2c1e10;
    border-radius: 1px;
    transition: transform 0.25s ease, opacity 0.2s ease;
  }

  #layoutMenu.menu-open .main-menu-btn-icon .bar-1 {
    transform: translateY(5px) rotate(45deg);
  }

  #layoutMenu.menu-open .main-menu-btn-icon .bar-2 {
    opacity: 0;
  }

  #layoutMenu.menu-open .main-menu-btn-icon .bar-3 {
    transform: translateY(-5px) rotate(-45deg);
  }

  .mobile-quick-lang {
    display: inline-flex;
    align-items: center;
    gap: 4px;
  }

  .mobile-quick-lang .m-lang-btn {
    display: inline-flex;
    align-items: center;
    gap: 3px;
    padding: 3px 6px;
    border-radius: 4px;
    background: rgba(255, 255, 255, 0.35);
    border: 1px solid rgba(80, 50, 15, 0.18);
    font-family: 'Inter', sans-serif;
    font-size: 11px;
    font-weight: 700;
    color: #2c1e10;
    text-decoration: none;
    transition: all 0.15s ease;
  }

  .mobile-quick-lang .m-lang-btn:hover {
    background: rgba(255, 255, 255, 0.6);
  }

  .mobile-quick-lang .m-lang-btn.is-active {
    background: #6b1d2f;
    border-color: #6b1d2f;
    color: #ffffff;
    box-shadow: 0 1px 3px rgba(107, 29, 47, 0.3);
  }

  .mobile-quick-lang .m-lang-btn img {
    border-radius: 1px;
  }

  #main-menu {
    display: none;
    position: absolute;
    top: 42px;
    left: 0;
    right: 0;
    width: 100%;
    background: linear-gradient(180deg, #fdfbf7 0%, #f6ede0 100%);
    border-bottom: 3px solid #c5a059;
    box-shadow: 0 16px 32px rgba(44, 33, 19, 0.22);
    z-index: 9999;
    max-height: 80vh;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    padding-bottom: 12px;
  }

  #main-menu.is-open {
    display: block;
  }

  .sm-simple a {
    padding: 12px 18px;
    font-size: 14px;
  }

  .sm-simple > li {
    float: none;
    width: 100%;
    border-top: 1px solid rgba(80, 50, 15, 0.08);
  }

  .sm-simple > li:first-child {
    border-top: 0;
  }

  .sm-simple > li.langglobe {
    display: none !important;
  }

  .sm-simple .lang-menu-text {
    display: inline;
  }
}

