/* Site header: fixed 60px bar, wordmark left, nav right.
   Under 768px the nav collapses to a Menu button that opens a
   full-screen white menu. Colour tokens live in styles.css (:root). */

.sn-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 9000;
  height: 60px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 24px;
  background: #fff;
  color: var(--ink);
  /* filter: the blur while the contact overlay is open (contact.css) */
  transition: box-shadow 0.35s cubic-bezier(0.25, 0.46, 0.45, 0.94), filter 0.3s ease;
}

.sn-header.scrolled {
  box-shadow: 0 1px 0 var(--line);
}

.sn-logo {
  display: block;
  height: 15px;
  position: relative;
}

.sn-logo-img {
  display: block;
  height: 100%;
  width: auto;
}

.sn-nav ul {
  display: flex;
  gap: 0 24px;
  list-style: none;
  margin: 0;
  padding: 0;
  font-size: 16px;
  line-height: 20px;
}

.sn-nav a {
  color: var(--ink-2);
  text-decoration: none;
  white-space: nowrap;
  transition: color 0.2s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.sn-nav a:hover,
.sn-nav a[aria-current="page"] {
  color: var(--ink);
}

.sn-menu-btn {
  display: none;
  font: inherit;
  font-size: 16px;
  line-height: 20px;
  background: none;
  border: 0;
  padding: 0;
  cursor: pointer;
  color: var(--ink);
  -webkit-tap-highlight-color: transparent;
}

/* Homepage "Work" anchor lands just under the header */
#work {
  scroll-margin-top: 60px;
}

/* Pages with a banner above the header (body.has-banner): the banner
   sits in flow, the fixed header starts under it and rides up to the
   top as the banner scrolls away. The page's own script keeps --hdr-top
   at (banner height - scrollY); the page stylesheet sets its rest value. */
body.has-banner .sn-header {
  top: var(--hdr-top, 0px);
}

@media (max-width: 767px) {
  .sn-header {
    padding: 0 16px;
  }

  .sn-menu-btn {
    display: block;
  }

  .sn-nav ul {
    display: none;
  }

  .sn-header.menu-open .sn-nav ul {
    display: flex;
    flex-direction: column;
    gap: 24px;
    position: fixed;
    top: 60px;
    left: 0;
    right: 0;
    bottom: 0;
    background: #fff;
    padding: 40px 16px;
    font-size: 41px;
    line-height: 1.2;
    letter-spacing: -0.02em;
  }

  .sn-header.menu-open .sn-nav a {
    color: var(--ink);
  }

  /* Banner pages: the open menu follows the header down */
  body.has-banner .sn-header.menu-open .sn-nav ul {
    top: calc(60px + var(--hdr-top, 0px));
  }
}

/* No JavaScript: the Menu button can't open anything, so show the links
   inline instead (they wrap to a second line inside the bar if needed). */
@media (max-width: 767px) and (scripting: none) {
  .sn-menu-btn {
    display: none;
  }

  .sn-nav ul {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 2px 14px;
    font-size: 14px;
  }
}
