/* ===================================================
   HEADER LAYOUT
=================================================== */

.header-inner {
  max-width: 1300px;
  margin: auto;
  padding: 0 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 88px;
  transition: height 0.35s ease;
}
.site-header.is-sticky .header-inner {
  height: 88px;
}

.site-logo {
  position: relative;
  display: block;
  width: 90px;
  height: 82px;
  flex-shrink: 0;
}

.site-logo img {
  position: absolute;
  inset: 0;
  width: 9p0x;
  height: auto;
  transition: 0.35s;
}

.desktop-nav {
  flex: 1;
  display: flex;
  justify-content: center;
}

/* ===================================================
   MENU
=================================================== */

.nav-menu {
  display: flex;
  align-items: center;
  gap: 8px;
  list-style: none;
  margin: 0;
  padding: 0;
  flex-wrap: nowrap;
  white-space: nowrap;
}

/* ==========================================
   NAV ITEMS
========================================== */

.nav-menu > li {
  position: relative;
  list-style: none;
}

.nav-menu > li > a {
  display: flex;
  align-items: center;
  height: 88px;
  padding: 0 18px;
  font-size: 15px;
  font-weight: 650;
  color: #ffffff;
  text-decoration: none;
  transition:
    height 0.35s ease,
    color 0.25s ease,
    transform 0.25s ease;
  position: relative;
  will-change: transform;
}
.nav-menu > li > a::before {
  content: "";
  position: absolute;
  left: 18px;
  right: 18px;
  bottom: 22px;
  height: 3px;
  border-radius: 3px;
  background: var(--st-orange-hover);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.35s cubic-bezier(0.22, 0.61, 0.36, 1);
}
.nav-menu > li:hover > a::before {
  transform: scaleX(1);
}
.nav-menu > li:hover > a {
  color: var(--st-orange-hover);
  transform: translateY(-2px);
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.nav-menu > li.active > a {
  color: var(--st-orange-hover);
}

.nav-menu > li.active > a::before {
  transform: scaleX(1);
}

.site-header.is-sticky .nav-menu > li > a {
  color: #173d37;
  height: 88px;
}
/* ===================================================
   DROPDOWN
=================================================== */

.has-dropdown {
  position: relative;
}
.has-dropdown > a::after {
  content: "";
  width: 7px;
  height: 7px;
  display: inline-block;
  margin-left: 8px;
  opacity: 0.75;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(45deg) translateY(-2px);
  transition:
    transform 0.3s cubic-bezier(0.4, 0, 0.2, 1),
    color 0.25s;
}
.has-dropdown.open > a::after {
  transform: rotate(225deg) translateY(-2px);
}
/* ===================================================
   SUBMENU
=================================================== */
.submenu {
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 300px;
  margin: 0;
  padding: 12px 0;
  list-style: none;
  background: #fff;
  border-radius: 16px;
  overflow: hidden;
  will-change: transform, opacity;
  z-index: 500;
  display: block;
  width: 230px;
  box-shadow:
    0 50px 100px 0 rgba(64, 1, 4, 0.1),
    0 -6px 0 0 rgba(248, 99, 107, 0.004);
  opacity: 0;
  -webkit-transform: rotate3d(1, 0, 0, -90deg);
  transform: rotate3d(1, 0, 0, -90deg);
  -webkit-transform-origin: 0 0;
  transform-origin: 0 0;
  transition: all 0.6s ease;
}

.has-dropdown.open > .submenu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0) scale(1);
  transition-delay: 0s;
}

.submenu li {
  list-style: none;
}
.submenu li:not(:last-child) {
  border-bottom: 1px solid #edf1f3;
}
.submenu a {
  display: flex;
  align-items: center;
  gap: 10px;
  position: relative;
  padding: 16px 22px;
  color: #173d37;
  text-decoration: none;
  font-size: 15px;
  font-weight: 600;
  transition:
    background 0.25s,
    color 0.25s,
    transform 0.25s;
}

.submenu a:hover {
  background: #f7f8fa;
  color: var(--st-orange-hover);
  transform: translateX(6px);
}
.submenu a.active {
  color: var(--st-orange-hover);
  font-weight: 600;
  background: #fff8f2;
}
.submenu a i {
  width: 20px;
  text-align: center;
  font-size: 15px;
  color: #8d9997;
  opacity: 0.85;
  transition:
    color 0.25s ease,
    transform 0.25s ease,
    opacity 0.25s ease;
  flex-shrink: 0;
}
.submenu a:hover i,
.submenu a.active i {
  color: var(--st-orange-hover);
  opacity: 1;
  transform: scale(1.08);
}

/* ===================================================
   NESTED SUBMENU
   2. úroveň desktopového menu
=================================================== */

/* První dropdown musí umožnit
   vysunutí dalšího menu doprava */

.nav-menu > .has-dropdown > .submenu {
  overflow: visible;
}

/* Položka, která má další úroveň */

.submenu > .has-dropdown {
  position: relative;
}

/* Šipka u položek 2. úrovně */

.submenu > .has-dropdown > a::after {
  content: "";
  width: 7px;
  height: 7px;
  display: inline-block;
  margin-left: auto;
  opacity: 0.65;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(-45deg) translateY(1px);
  transition:
    transform 0.25s ease,
    color 0.25s ease;
}

/* Otočení šipky při otevření */

.submenu > .has-dropdown.open > a::after {
  transform: rotate(135deg) translateY(1px);
}

/* ===================================================
   VNOŘENÉ SUBMENU
=================================================== */

.submenu > .has-dropdown > .submenu {
  position: absolute;
  top: -12px;
  left: 100%;
  min-width: 240px;
  margin: 0;
  padding: 12px 0;
  background: #fff;
  border-radius: 16px;
  box-shadow:
    0 12px 35px rgba(0, 0, 0, 0.08),
    0 4px 12px rgba(0, 0, 0, 0.05);
  opacity: 0;
  visibility: hidden;
  transform: translateX(10px) scale(0.98);
  transform-origin: left center;
  transition:
    opacity 0.25s ease,
    transform 0.25s cubic-bezier(0.22, 0.61, 0.36, 1),
    visibility 0s linear 0.25s;
  z-index: 510;
}
/* Otevřené vnořené submenu */

.submenu > .has-dropdown.open > .submenu {
  opacity: 1;
  visibility: visible;
  transform: translateX(0) scale(1);
  transition-delay: 0s;
}

/* ===================================================
   ODKAZY VE 2. ÚROVNI
=================================================== */

.submenu > .has-dropdown > .submenu a {
  padding: 14px 20px;
  font-size: 14px;
  color: #52645f;
}

.submenu > .has-dropdown > .submenu .active {
  color: var(--st-orange-hover);
}

/* Hover */

.submenu > .has-dropdown > .submenu a:hover {
  background: #f7f8fa;
  color: var(--st-orange-hover);
  transform: translateX(4px);
}

/* ===================================================
   HOVER – VNOŘENÉ SUBMENU
=================================================== */

.submenu > .has-dropdown:hover > .submenu {
  opacity: 1;
  visibility: visible;
  transform: translateX(0) scale(1);
  transition-delay: 0s;
}
