:root {
  --site-header-height: 72px;
}

.site-header {
  position: relative;
  z-index: 10040;
  width: 100%;
  height: var(--site-header-height);
  background: #fff;
  color: #1f1f1f;
  box-shadow: 1px 1px 3px 0 rgba(0, 0, 0, .1);
}

.site-header,
.site-header * {
  box-sizing: border-box;
}

.site-header__inner {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  gap: 34px;
  padding: 40px;
}

.site-header__logo {
  background-color: #1d1d1b;
  -webkit-mask: url('../images/kitchenlab-logo.png') center / contain no-repeat;
  mask: url('../images/kitchenlab-logo.png') center / contain no-repeat;
  display: inline-flex;
  align-items: center;
  text-decoration: none;
}

.site-header__logo-image {
  display: block;
  width: auto;
  height: 32px;
  opacity: 0;
}

.site-header__nav {
  /* Behåll länkarna i DOM men dölj dem tills headernavigationen ska aktiveras igen. */
  display: none;
  align-items: center;
  gap: 30px;
  min-width: 0;
}

.site-header__nav-link {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  color: #2a2826;
  font-family: Aptos, Manrope, sans-serif;
  font-size: 16px;
  font-weight: 100;
  line-height: 1;
  text-decoration: none;
  white-space: nowrap;
  transition: color 140ms ease;
}

.site-header__nav-link:hover,
.site-header__nav-link:focus-visible {
  color: var(--ballingslov-brown-400);
}

.site-header__nav-link:focus-visible {
  outline: 2px solid var(--ballingslov-brown-400);
  outline-offset: 5px;
  border-radius: 4px;
}

body.has-site-header .wrap {
  height: calc(100vh - var(--site-header-height));
  min-height: 0;
}

body.has-site-header .stage {
  height: 100%;
  min-height: 0;
}

@supports (height: 100dvh) {
  body.has-site-header .wrap {
    height: calc(100dvh - var(--site-header-height));
  }
}

@media (max-width: 768px) {
  :root {
    --site-header-height: 62px;
  }

  .site-header__inner {
    gap: 22px;
    padding: 0 18px;
  }

  .site-header__logo {
  background-color: #1d1d1b;
  -webkit-mask: url('../images/kitchenlab-logo.png') center / contain no-repeat;
  mask: url('../images/kitchenlab-logo.png') center / contain no-repeat;
    flex: 0 0 auto;
  }

  .site-header__nav {
    gap: 18px;
    overflow-x: auto;
    scrollbar-width: none;
  }

  .site-header__nav::-webkit-scrollbar {
    display: none;
  }

  .site-header__nav-link {
    min-height: 36px;
    font-size: 15px;
  }
}

/* Short landscape phone viewports give the full height to the scene. */
@media (orientation: landscape) and (max-width: 1000px) and (max-height: 500px) {
  body.has-site-header:has(#stage) {
    --site-header-height: 0px;
  }

  body.has-site-header:has(#stage) .site-header {
    display: none;
  }
}

@media (max-width: 420px) {
  .site-header__inner {
    gap: 14px;
    padding: 0 14px;
  }

  .site-header__nav {
    gap: 14px;
  }
}
