/* L2C — Site Header module (site chrome, full-width) */
.l2c-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  width: 100%;
  background: color-mix(in srgb, var(--l2c-black) 85%, transparent);
  color: var(--l2c-bone);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  font-family: var(--l2c-font-sans);
}

/* Fallback for browsers without color-mix: paint solid black. */
@supports not (background: color-mix(in srgb, black, white)) {
  .l2c-header { background: var(--l2c-black); }
}

/* --- Top bar -------------------------------------------------------------- */
.l2c-header__bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  width: 100%;
  padding: 14px clamp(20px, 4vw, 64px);
}

/* --- Brand ---------------------------------------------------------------- */
.l2c-header__brand {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  flex: none;
  text-decoration: none;
  color: var(--l2c-white);
}
.l2c-header__logo {
  height: 28px;
  width: auto;
  display: block;
}
.l2c-header__wordmark {
  font-family: var(--l2c-font-sans);
  font-weight: 700;
  font-size: 14px;
  letter-spacing: -0.01em;
  color: var(--l2c-white);
  white-space: nowrap;
}

/* --- Primary nav ---------------------------------------------------------- */
.l2c-header__nav-list {
  display: flex;
  align-items: center;
  gap: 28px;
  list-style: none;
  margin: 0;
  padding: 0;
}
.l2c-header__nav-item {
  position: static;
}
.l2c-header__nav-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: var(--l2c-font-sans);
  font-weight: 400;
  font-size: 12px;
  line-height: 1.4;
  color: var(--l2c-white);
  text-decoration: none;
  background: none;
  border: 0;
  padding: 0;
  margin: 0;
  cursor: pointer;
  transition: opacity 0.15s ease;
}
.l2c-header__nav-link:hover {
  opacity: 0.8;
}
.l2c-header__nav-link:focus-visible {
  outline: 2px solid var(--l2c-cyan);
  outline-offset: 4px;
  border-radius: 2px;
}

/* Caret glyph used on mega-menu triggers */
.l2c-header__caret {
  width: 6px;
  height: 6px;
  border-right: 1.5px solid currentColor;
  border-bottom: 1.5px solid currentColor;
  transform: rotate(45deg);
  transform-origin: center;
  margin-top: -3px;
  transition: transform 0.2s ease;
}
.l2c-header__mega-trigger[aria-expanded="true"] .l2c-header__caret {
  transform: rotate(-135deg);
  margin-top: 2px;
}

/* --- Actions (CTA + burger) ---------------------------------------------- */
.l2c-header__actions {
  display: flex;
  align-items: center;
  gap: 12px;
  flex: none;
}
.l2c-header__cta.l2c-btn {
  font-size: 12px;
  padding: 7px 18px;
}

.l2c-header__burger {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 40px;
  height: 40px;
  padding: 8px;
  background: none;
  border: 0;
  cursor: pointer;
}
.l2c-header__burger span {
  display: block;
  width: 22px;
  height: 2px;
  border-radius: 2px;
  background: var(--l2c-bone);
  transition: transform 0.2s ease, opacity 0.2s ease;
}
.l2c-header__burger:focus-visible {
  outline: 2px solid var(--l2c-cyan);
  outline-offset: 2px;
  border-radius: 4px;
}
.l2c-header.is-drawer-open .l2c-header__burger span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}
.l2c-header.is-drawer-open .l2c-header__burger span:nth-child(2) {
  opacity: 0;
}
.l2c-header.is-drawer-open .l2c-header__burger span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* --- Mega-menu panel ------------------------------------------------------ */
.l2c-header__mega {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background: var(--l2c-bone);
  color: #1A1A1A;
  padding: 40px clamp(20px, 4vw, 64px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-6px);
  pointer-events: none;
  transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s ease;
}
.l2c-header__mega.is-open {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
  pointer-events: auto;
}
.l2c-header__mega-inner {
  max-width: 1080px;
  margin: 0 auto;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 48px;
}
.l2c-header__mega-main {
  flex: 1 1 auto;
  min-width: 0;
}
.l2c-header__mega-heading {
  font-family: var(--l2c-font-sans);
  font-weight: 700;
  font-size: 15px;
  line-height: 1.3;
  color: var(--l2c-navy);
  margin: 0 0 20px;
}
.l2c-header__mega-cols {
  display: flex;
}
.l2c-header__mega-col {
  padding: 0 32px;
}
.l2c-header__mega-col:first-child {
  padding-left: 0;
}
.l2c-header__mega-col + .l2c-header__mega-col {
  border-left: 1px solid color-mix(in srgb, var(--l2c-black) 20%, transparent);
}
.l2c-header__mega-col-title {
  color: var(--l2c-violet);
  font-size: 10px;
  margin: 0 0 12px;
}
.l2c-header__mega-links {
  list-style: none;
  margin: 0;
  padding: 0;
}
.l2c-header__mega-links a {
  display: inline-block;
  font-family: var(--l2c-font-sans);
  font-weight: 400;
  font-size: 12px;
  line-height: 24px;
  color: var(--l2c-navy);
  text-decoration: none;
  transition: color 0.15s ease;
}
.l2c-header__mega-links a:hover {
  color: var(--l2c-violet);
}
.l2c-header__mega-links a:focus-visible {
  outline: 2px solid var(--l2c-violet);
  outline-offset: 2px;
  border-radius: 2px;
}

/* Promo card */
.l2c-header__promo {
  flex: none;
  width: 360px;
  background: var(--l2c-orange);
  border-radius: 8px;
  padding: 24px;
  color: var(--l2c-bone);
}
.l2c-header__promo-img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 6px;
  margin: 0 0 16px;
}
.l2c-header__promo-title {
  font-family: var(--l2c-font-sans);
  font-weight: 700;
  font-size: 15px;
  line-height: 1.3;
  color: var(--l2c-bone);
  margin: 0 0 8px;
}
.l2c-header__promo-body {
  font-family: var(--l2c-font-sans);
  font-size: 12px;
  line-height: 1.6;
  color: var(--l2c-bone);
  margin: 0 0 16px;
}
.l2c-header__promo-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: var(--l2c-font-sans);
  font-weight: 700;
  font-size: 12px;
  color: var(--l2c-bone);
  text-decoration: underline;
  text-underline-offset: 3px;
  transition: gap 0.15s ease;
}
.l2c-header__promo-link:hover {
  gap: 10px;
}
.l2c-header__promo-link:focus-visible {
  outline: 2px solid var(--l2c-bone);
  outline-offset: 3px;
  border-radius: 2px;
}

/* --- Mobile drawer -------------------------------------------------------- */
.l2c-header__drawer {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background: var(--l2c-black);
  padding: 8px clamp(20px, 4vw, 64px) 32px;
  max-height: calc(100vh - 60px);
  overflow-y: auto;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}
.l2c-header__drawer-list {
  list-style: none;
  margin: 0;
  padding: 0;
}
.l2c-header__drawer-item {
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}
.l2c-header__drawer-link,
.l2c-header__drawer-toggle {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 16px 0;
  font-family: var(--l2c-font-sans);
  font-weight: 500;
  font-size: 20px;
  line-height: 1.3;
  color: var(--l2c-bone);
  text-decoration: none;
  text-align: left;
  background: none;
  border: 0;
  cursor: pointer;
}
.l2c-header__drawer-toggle .l2c-header__caret {
  width: 8px;
  height: 8px;
}
.l2c-header__drawer-toggle[aria-expanded="true"] .l2c-header__caret {
  transform: rotate(-135deg);
  margin-top: 4px;
}
.l2c-header__drawer-sub {
  display: none;
  padding: 0 0 16px;
}
.l2c-header__drawer-toggle[aria-expanded="true"] + .l2c-header__drawer-sub {
  display: block;
}
.l2c-header__drawer-sub-title {
  font-family: var(--l2c-font-mono);
  font-weight: 700;
  font-size: 10px;
  letter-spacing: var(--l2c-ls-label);
  text-transform: uppercase;
  color: var(--l2c-heliotrope);
  margin: 12px 0 6px;
}
.l2c-header__drawer-sub-list {
  list-style: none;
  margin: 0 0 8px;
  padding: 0;
}
.l2c-header__drawer-sub-list a {
  display: block;
  padding: 6px 0;
  font-family: var(--l2c-font-sans);
  font-size: 15px;
  color: color-mix(in srgb, var(--l2c-bone) 80%, transparent);
  text-decoration: none;
}
.l2c-header__drawer-sub-list a:hover {
  color: var(--l2c-bone);
}
.l2c-header__drawer-cta.l2c-btn {
  display: flex;
  width: 100%;
  margin-top: 24px;
}

/* --- Responsive: collapse to drawer at <= 900px --------------------------- */
@media (max-width: 900px) {
  .l2c-header__nav,
  .l2c-header__cta,
  .l2c-header__mega {
    display: none;
  }
  .l2c-header__burger {
    display: inline-flex;
  }
  .l2c-header.is-drawer-open .l2c-header__drawer {
    display: block;
  }
}

/* --- Reduced motion ------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  .l2c-header__mega,
  .l2c-header__caret,
  .l2c-header__burger span,
  .l2c-header__nav-link,
  .l2c-header__promo-link,
  .l2c-header__mega-links a {
    transition: none;
  }
}
