.navbar-wrapper {
  width: 100%;
  height: 100px;
  background-color: #ffffff;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  transition: transform 0.3s ease;
}

.navbar-wrapper.navbar--hidden {
  transform: translateY(-100%);
}

/* Na wszystkich stronach z tym blokiem – treść nie nachodzi pod fixed header (fallback bez :has()) */
body.has-navbar {
  padding-top: 100px;
}
@media (max-width: 768px) {
  body.has-navbar {
    padding-top: 70px;
  }
}

body:has(.navbar-wrapper) {
  padding-top: 100px;
}

@media (max-width: 768px) {
  body:has(.navbar-wrapper) {
    padding-top: 70px;
  }
}

.navbar {
  max-width: 1920px;
  margin: 0 auto;
  padding-left: 70px;
  padding-right: 70px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100px;
}

.navbar-brand {
  display: flex;
  align-items: center;
  flex-shrink: 0;
  gap: 12px;
}

.navbar-logo-link {
  display: flex;
  align-items: center;
  text-decoration: none;
}

.navbar-logo {
  width: 191px;
  height: 32px;
  display: block;
  object-fit: contain;
}

.navbar-menu {
  display: flex;
  align-items: stretch;
  height: 100%;
  flex-shrink: 0;
  margin-right: 2rem;
}

.navbar-menu-list {
  display: flex;
  align-items: stretch;
  height: 100%;
  list-style: none;
  margin: 0;
  padding: 0;
}

.navbar-menu-item-wrapper {
  margin: 0;
  padding: 0;
  display: flex;
  align-items: stretch;
}

.navbar-menu-item {
  display: flex;
  align-items: center;
  height: 100%;
  padding: 0 1.125rem;
  font-family: type-36, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  font-size: 15px;
  font-weight: 400;
  color: rgb(131, 140, 149);
  text-decoration: none;
  cursor: pointer;
  transition: color 0.3s ease;
  white-space: nowrap;
  box-sizing: border-box;
}

.navbar-menu-item:hover {
  color: #23c767;
  text-decoration: none;
}

/* Aktywna strona – zielony pasek na pełnej wysokości */
.navbar-menu-item-wrapper.current-menu-item .navbar-menu-item {
  color: #333333;
  border-top: 4px solid #23c767;
  padding-top: 0;
  margin-top: 0;
}

.navbar-actions {
  display: flex;
  align-items: center;
  gap: 0;
  flex-shrink: 0;
}

.navbar-mobile-toggle {
  display: none;
  align-items: center;
  justify-content: center;
  width: 3.625rem;
  min-width: 3.625rem;
  height: 2.8125rem;
  border: solid #e1e6eb;
  border-width: 0 0.0625rem;
  background: none;
  cursor: pointer;
  color: #454a4f;
}

.navbar-toggle-icons {
  position: relative;
  display: block;
  width: 24px;
  height: 24px;
}

.navbar-toggle-icons .navbar-icon {
  position: absolute;
  left: 0;
  top: 0;
  width: 24px;
  height: 24px;
  fill: currentColor;
  transition: opacity 0.2s ease;
}

.navbar-toggle-icons .navbar-icon--open { opacity: 1; }
.navbar-toggle-icons .navbar-icon--close { opacity: 0; }

.navbar-mobile-toggle.is-open .navbar-icon--open { opacity: 0; }
.navbar-mobile-toggle.is-open .navbar-icon--close { opacity: 1; }

.navbar-mobile-backdrop {
  display: none !important;
}

.navbar-mobile-panel {
  position: fixed;
  left: 0;
  right: 0;
  /* Mobile panel ma pojawić się POD navbar */
  top: 70px;
  bottom: 0;
  width: 100%;
  max-width: none;
  background: #201B32;
  color: #fff;
  z-index: 999;
  display: none;
  overflow-y: auto;
  padding: 28px 40px 32px;
}

.navbar-mobile-panel.is-open {
  display: block;
}

.navbar-mobile-menu {
  list-style: none;
  margin: 0;
  padding: 0;
}

.navbar-mobile-item {
  margin: 0;
  padding: 0;
}

.navbar-mobile-link {
  display: block;
  padding: 10px 0;
  color: #fff;
  text-decoration: none;
  font-size: 14px;
  font-weight: 600;
}

.navbar-mobile-link:hover {
  opacity: 0.9;
}

.navbar-mobile-extras {
  margin-top: 28px;
  padding-top: 18px;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
}

.navbar-mobile-linkedin {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.08);
  margin-bottom: 14px;
}

.navbar-mobile-linkedin .navbar-linkedin-icon {
  filter: brightness(0) invert(1);
}

.navbar-mobile-langs {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.navbar-mobile-lang {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 34px;
  height: 28px;
  padding: 0 10px;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
  text-decoration: none;
  font-size: 12px;
  font-weight: 700;
}

.navbar-mobile-lang.is-active,
.navbar-mobile-lang:hover {
  background: #23c767;
  color: #0e0620;
}

.navbar-right {
  display: flex;
  align-items: stretch;
  height: 100%;
  flex-shrink: 0;
  margin-left: auto;
}

.navbar-linkedin {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 3.625rem;
  min-width: 3.625rem;
  height: 2.8125rem;
  padding: 0.625rem 1.25rem;
  border: solid #e1e6eb;
  border-width: 0 0.0625rem;
  box-sizing: border-box;
  font-family: type-36, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  font-size: 1.5rem;
  font-weight: 600;
  line-height: 1.6rem;
  color: #454a4f;
  text-decoration: none;
  transition: color 0.2s ease, border-color 0.2s ease;
}

.navbar-linkedin:hover {
  color: #0077b5;
  text-decoration: none;
}

.navbar-linkedin-icon {
  display: block;
  width: 1rem;
  height: 1rem;
  object-fit: contain;
  opacity: .4;
}

.navbar-linkedin:hover .navbar-linkedin-icon {
  opacity: 1;
}

.navbar-language {
  font-family: type-36, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  font-size: 16px;
  font-weight: 400;
  color: #999999;
  text-decoration: none;
  transition: color 0.3s ease;
  margin: 0 0.3125rem;
}

.navbar-language:hover {
  color: #333333;
  text-decoration: none;
}

.navbar-language--active {
  color: #333333;
  font-weight: 600;
}

/* Przełącznik języków Polylang – dropdown */
.navbar-lang-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 58px;
  min-width: 58px;
  height: 2.8125rem;
  padding: 0.625rem 0.25rem;
  border: solid #e1e6eb;
  border-width: 0 0.0625rem;
  box-sizing: border-box;
  position: relative;
  font-family: type-36, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  font-size: 16px;
  font-weight: 400;
  color: #999999;
  cursor: pointer;
  user-select: none;
  margin: 0;
  background: none;
  text-align: center;
}

.navbar-lang-toggle:hover {
  color: #333333;
}

.navbar-lang-toggle.is-open {
  color: #333333;
  font-weight: 600;
}

.navbar-lang-current {
  font-weight: 600;
  font-size: 0.9375rem;
  padding: 0;
  margin: 0;
  text-align: center;
  color: #838c95;
}

.navbar-lang-toggle:hover .navbar-lang-current,
.navbar-lang-toggle.is-open .navbar-lang-current {
  color: #333333;
}

.navbar-lang-dropdown {
  position: absolute;
  top: 100%;
  right: 0;
  margin: 0;
  margin-top: 0.25rem;
  padding: 18px 0;
  list-style: none;
  background: #23c767;
  border: none;
  border-radius: 4px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  width: 3.625rem;
  min-width: 3.625rem;
  box-sizing: border-box;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-4px);
  transition: opacity 0.2s, visibility 0.2s, transform 0.2s;
  z-index: 100;
}

.navbar-lang-dropdown::before {
  content: '';
  position: absolute;
  bottom: 100%;
  left: 50%;
  border-width: 0 7.5px 7px;
  border-style: solid;
  border-color: transparent transparent #23c767;
  transform: translateX(-50%);
  margin-bottom: -1px;
}

.navbar-lang-toggle.is-open .navbar-lang-dropdown {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.navbar-lang-dropdown li {
  margin: 0;
}

.navbar-lang-dropdown a {
  display: block;
  padding: 0.0625rem 0.5rem;
  font-size: 14px;
  font-weight: 500;
  color: #fff;
  text-decoration: none;
}

.navbar-lang-dropdown a:hover {
  background: none;
  text-decoration: underline;
}

/* Responsive */
@media (max-width: 1024px) {
  .navbar-menu {
    gap: 0.9375rem;
  }
  
  .navbar-menu-item {
    font-size: 14px;
  }
}

@media (max-width: 1200px) {
  .navbar-menu {
    display: none;
  }

  .navbar-desktop-only {
    display: none !important;
  }

  .navbar-mobile-toggle {
    display: inline-flex;
  }
}

@media (max-width: 768px) {
  .navbar-wrapper {
    height: 70px;
  }

  .navbar {
    padding: 0 0.625rem;
    height: 70px;
  }
  
  .navbar-logo {
    width: 150px;
  }
  
  .navbar-actions {
    gap: 0.1563rem;
  }
  
  .navbar-linkedin {
    font-size: 14px;
  }

  .navbar-mobile-toggle {
    width: 3rem;
    min-width: 3rem;
    height: 2.5rem;
  }

  .navbar-toggle-icons,
  .navbar-toggle-icons .navbar-icon {
    width: 20px;
    height: 20px;
  }
}

