html {
  overflow-y: scroll;
  scrollbar-gutter: stable;
  scroll-behavior: smooth;
}

.top-nav {
  background: #ffffff;
  color: #000000;
  --nav-pad-y: 12px;
  --nav-pad-x: 24px;
  position: sticky;
  top: 0;
  z-index: 30;
  width: 100%;
  overflow: visible;
  box-shadow: 0 8px 24px rgba(0,0,0,0.08);
  border-bottom: 1px solid #d9eadf;
  font-family: "Segoe UI", Arial, sans-serif;
}

.nav-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: var(--nav-pad-y) var(--nav-pad-x);
  display: grid;
  grid-template-columns: 310px minmax(0, 1fr) max-content;
  align-items: center;
  gap: 18px;
  position: relative;
}

.brand {
  padding: 0;
  display: inline-flex;
  align-items: center;
  position: relative;
  overflow: visible;
}

.brand::before,
.brand::after {
  content: none;
}

.brand img {
  height: 58px;
  max-width: 300px;
  width: auto;
  display: block;
  object-fit: contain;
  transform: scale(1.28);
  transform-origin: left center;
}

.nav-links {
  display: flex;
  gap: 0;
  justify-content: space-between;
  width: 100%;
  min-width: 0;
}

.nav-links a {
  flex: 1 1 0;
  padding: 8px 10px;
  border-radius: 8px;
  color: #000000;
  font-size: 15px;
  font-weight: 600;
  line-height: normal;
  text-align: center;
  white-space: nowrap;
  text-decoration: none;
}

.nav-links a:hover {
  background: rgba(31,111,74,0.10);
  color: #0d1f18;
}

.nav-domain,
.mobile-nav-claim {
  display: none;
}

.phone {
  justify-self: end;
  padding: 14px 22px;
  border-radius: 14px;
  background: #0d1f18;
  border: 1px solid #0d1f18;
  color: #ffffff;
  font-size: 18px;
  font-weight: 800;
  line-height: normal;
  white-space: nowrap;
  text-decoration: none;
  box-shadow: 0 14px 28px rgba(13,31,24,0.16);
}

.phone:hover {
  background: #1f6f4a;
  border-color: #1f6f4a;
  color: #ffffff;
}

.nav-toggle {
  display: none;
  background: transparent;
  border: 0;
  cursor: pointer;
  padding: 8px;
  margin-left: auto;
}

.nav-toggle span {
  display: block;
  width: 26px;
  height: 3px;
  margin: 5px 0;
  background: #000000;
  border-radius: 8px;
  transition: transform .2s ease, opacity .2s ease, background .2s ease;
}

body.nav-open {
  overflow: hidden;
}

@media (max-width: 1180px) and (min-width: 981px) {
  .nav-inner {
    grid-template-columns: 250px minmax(0, 1fr) max-content;
    column-gap: 12px;
  }
  .brand img {
    height: 50px;
    max-width: 245px;
    transform: scale(1.2);
  }
  .nav-links a {
    font-size: 14px;
    padding-left: 6px;
    padding-right: 6px;
  }
}

@media (max-width: 980px) {
  body {
    padding-top: 0 !important;
  }

  .top-nav {
    position: sticky;
    top: 0;
    z-index: 30;
    margin: 0;
    background: transparent;
    border-bottom: none;
    box-shadow: none;
    overflow: visible;
  }

  .top-nav::before {
    content: "";
    position: absolute;
    inset: 0 0 auto 0;
    height: calc(100% - 38px);
    background: #ffffff;
    box-shadow: 0 8px 24px rgba(0,0,0,0.08);
    z-index: 0;
  }

  .nav-inner {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 0;
    row-gap: 10px;
    padding: 14px 16px 16px;
    position: relative;
    z-index: 1;
    max-width: 1200px;
  }

  .brand {
    order: 1;
    width: min(58vw, 360px);
    padding: 0;
    margin: 0;
    min-width: 0;
    overflow: visible;
  }

  .brand img {
    height: clamp(38px, 10vw, 52px);
    max-width: 100%;
    width: auto;
    transform: none;
  }

  .nav-toggle {
    order: 2;
    display: block;
    position: relative;
    z-index: 4;
    width: auto;
    height: auto;
    margin-left: auto;
    padding: 10px;
    border: 1.5px solid #000000;
    border-radius: 16px;
    background: #ffffff;
  }

  .nav-links {
    display: none;
    position: absolute;
    left: 12px;
    right: 12px;
    top: calc(100% + 8px);
    width: auto;
    max-height: calc(100vh - 132px);
    overflow-y: auto;
    padding: 10px;
    flex-direction: column;
    gap: 6px;
    background: #ffffff;
    border: 1px solid #d9eadf;
    border-radius: 22px;
    box-shadow: 0 18px 36px rgba(0,0,0,0.16);
    z-index: 9999;
  }

  .top-nav.open .nav-links {
    display: flex;
  }

  .nav-links a,
  .top-nav.open .nav-links a {
    display: block;
    flex: none;
    width: 100%;
    padding: 14px 16px;
    border-radius: 14px;
    color: #000000;
    background: #ffffff;
    text-align: left;
    text-shadow: none;
  }

  .nav-links a:hover,
  body.home-page .nav-links a[href="index.html"],
  body.products-page .nav-links a[href="produkty.html"],
  body.usage-page .nav-links a[href="uzytkowanie.html"],
  body.articles-page .nav-links a[href="artykuly.html"],
  body.samples-page .nav-links a[href="probki.html"],
  body.contact-page .nav-links a[href="kontakt.html"] {
    color: #0d1f18;
    background: #eaf7f0;
  }

  .phone {
    position: relative;
    z-index: 3;
    order: 3;
    display: block;
    width: 100%;
    max-width: none;
    margin: 2px 0 0;
    padding: 13px 16px;
    border-radius: 999px;
    background: #0d1f18;
    border-color: #0d1f18;
    color: #ffffff;
    font-size: 15px;
    line-height: normal;
    font-weight: 900;
    text-align: center;
    box-shadow: 0 14px 28px rgba(13,31,24,0.16);
  }

  .top-nav.open .nav-toggle {
    background: #ffffff;
    border-color: #000000;
  }

  .top-nav.open .nav-toggle span {
    background: #000000;
  }

  .top-nav.open .nav-toggle span:nth-child(1) {
    transform: translateY(8px) rotate(45deg);
  }

  .top-nav.open .nav-toggle span:nth-child(2) {
    opacity: 0;
  }

  .top-nav.open .nav-toggle span:nth-child(3) {
    transform: translateY(-8px) rotate(-45deg);
  }

  .top-nav + main.wrap,
  .top-nav + .wrap {
    padding-top: 18px;
    margin-top: 0;
  }
}

@media (max-width: 420px) {
  .brand {
    width: min(58vw, 260px);
  }
  .brand img {
    height: clamp(34px, 9.5vw, 44px);
  }
  .phone {
    padding: 12px 14px;
    font-size: 14px;
  }
}

body,
body *:not(img):not(svg):not(path) {
  -webkit-user-select: text;
  user-select: text;
}

::selection {
  background: #1f6f4a;
  color: #ffffff;
  -webkit-text-fill-color: #ffffff;
}

button,
.nav-toggle,
.cookie-btn,
.cookie-close,
.cookie-tab,
.cookie-manage-btn {
  -webkit-user-select: none;
  user-select: none;
}