:root {
  --bp-header-text: #20282e;
  --bp-header-muted: #6d7479;
  --bp-header-accent: #bd5718;
  --bp-header-accent-soft: #fbf5ef;
  --bp-header-line: #ece8e2;
  --bp-header-bg: #ffffff;
  --bp-header-width: 1280px;
  --bp-header-height: 74px;
}

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

.bp-site-header {
  position: relative;
  z-index: 9990;
  width: 100%;
  max-width: none;
  margin: 0;
  background: var(--bp-header-bg);
  border-bottom: 1px solid rgba(32, 40, 46, .08);
  color: var(--bp-header-text);
  font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

.bp-site-header a,
.bp-site-header button,
.bp-site-header input {
  font-family: inherit;
}

.bp-header-inner {
  width: min(calc(100% - 40px), var(--bp-header-width));
  min-height: var(--bp-header-height);
  margin: 0 auto;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 30px;
}

.bp-brand,
.bp-drawer-brand {
  display: inline-flex;
  align-items: center;
  text-decoration: none;
}

.bp-brand img,
.bp-drawer-brand img {
  display: block;
  width: auto;
  object-fit: contain;
}

.bp-brand img {
  height: 50px;
  max-width: 185px;
}

.bp-drawer-brand img {
  height: 46px;
  max-width: 155px;
}

.bp-brand span,
.bp-drawer-brand span {
  color: var(--bp-header-text);
  font-weight: 700;
  font-size: 22px;
}

.bp-brand strong,
.bp-drawer-brand strong {
  color: var(--bp-header-accent);
}

.bp-nav ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

.bp-desktop-menu-wrap {
  min-width: 0;
  justify-self: end;
}

.bp-desktop-menu {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 28px;
}

.bp-desktop-menu > li {
  position: relative;
  margin: 0;
  padding: 0;
}

.bp-desktop-menu a {
  color: var(--bp-header-text);
  text-decoration: none;
  font-size: 15px;
  line-height: 1.25;
  font-weight: 600;
  white-space: nowrap;
  transition: color .18s ease, background .18s ease;
}

.bp-desktop-menu > li > a {
  position: relative;
  display: flex;
  align-items: center;
  min-height: var(--bp-header-height);
}

.bp-desktop-menu > li > a::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 2px;
  border-radius: 2px 2px 0 0;
  background: var(--bp-header-accent);
  transform: scaleX(0);
  transform-origin: center;
  transition: transform .18s ease;
}

.bp-desktop-menu > li:hover > a,
.bp-desktop-menu > li:focus-within > a,
.bp-desktop-menu > .current-menu-item > a,
.bp-desktop-menu > .current-menu-ancestor > a {
  color: var(--bp-header-accent);
}

.bp-desktop-menu > li:hover > a::before,
.bp-desktop-menu > li:focus-within > a::before,
.bp-desktop-menu > .current-menu-item > a::before,
.bp-desktop-menu > .current-menu-ancestor > a::before {
  transform: scaleX(1);
}

.bp-desktop-menu .menu-item-has-children > a::after {
  content: "";
  width: 7px;
  height: 7px;
  margin-left: 8px;
  border-right: 1.5px solid currentColor;
  border-bottom: 1.5px solid currentColor;
  transform: rotate(45deg) translateY(-2px);
}

.bp-desktop-menu .sub-menu {
  position: absolute;
  top: calc(100% - 6px);
  left: -18px;
  min-width: 238px;
  padding: 10px;
  background: #fff;
  border: 1px solid var(--bp-header-line);
  border-radius: 14px;
  box-shadow: 0 18px 46px rgba(18, 25, 30, .12);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateY(8px);
  transition: opacity .16s ease, transform .16s ease, visibility .16s ease;
}

.bp-desktop-menu li:hover > .sub-menu,
.bp-desktop-menu li:focus-within > .sub-menu {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateY(0);
}

.bp-desktop-menu .sub-menu li {
  position: relative;
}

.bp-desktop-menu .sub-menu a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 44px;
  padding: 10px 12px;
  border-radius: 9px;
  font-size: 14px;
}

.bp-desktop-menu .sub-menu a:hover,
.bp-desktop-menu .sub-menu a:focus-visible,
.bp-desktop-menu .sub-menu .current-menu-item > a {
  color: var(--bp-header-accent);
  background: var(--bp-header-accent-soft);
}

.bp-desktop-menu .sub-menu .sub-menu {
  top: -10px;
  left: calc(100% + 8px);
}

.bp-header-utilities,
.bp-header-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
}

.bp-header-utilities {
  gap: 8px;
}

.bp-header-actions {
  gap: 4px;
}

.bp-account-link {
  min-height: 42px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 0 8px;
  color: var(--bp-header-text);
  text-decoration: none;
  font-size: 14px;
  font-weight: 600;
  white-space: nowrap;
  border-radius: 10px;
  transition: color .18s ease, background .18s ease;
}

.bp-account-link:hover,
.bp-account-link:focus-visible {
  color: var(--bp-header-accent);
  background: var(--bp-header-accent-soft);
  outline: none;
}

.bp-account-icon,
.bp-utility-icon,
.bp-search-close-icon {
  width: 20px;
  height: 20px;
  display: inline-flex;
  flex: 0 0 auto;
}

.bp-account-icon svg,
.bp-utility-icon svg,
.bp-search-close-icon svg {
  width: 100%;
  height: 100%;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.75;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.bp-icon-button,
.bp-cart-link {
  position: relative;
  width: 42px;
  height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  color: var(--bp-header-text);
  background: transparent;
  border: 0;
  border-radius: 50%;
  text-decoration: none;
  cursor: pointer;
  transition: background .18s ease, color .18s ease;
}

.bp-icon-button:hover,
.bp-icon-button:focus-visible,
.bp-cart-link:hover,
.bp-cart-link:focus-visible {
  color: var(--bp-header-accent);
  background: var(--bp-header-accent-soft);
  outline: none;
}

.bp-header-icon,
.bp-search-field-icon {
  display: inline-flex;
}

.bp-header-icon {
  width: 23px;
  height: 23px;
}

.bp-header-icon svg,
.bp-search-field-icon svg {
  width: 100%;
  height: 100%;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.bp-cart-badge {
  position: absolute;
  top: 0;
  right: -1px;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 2px solid #fff;
  border-radius: 999px;
  background: var(--bp-header-accent);
  color: #fff;
  font-size: 10px;
  line-height: 1;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
  box-shadow: 0 2px 6px rgba(189, 87, 24, .18);
}

.bp-cart-badge.is-empty {
  display: none;
}

.bp-menu-toggle {
  display: none;
}

.bp-search-panel {
  position: absolute;
  left: 0;
  right: 0;
  top: 100%;
  z-index: 9992;
  padding: 14px 20px 18px;
  background: #fff;
  border-top: 1px solid var(--bp-header-line);
  border-bottom: 1px solid var(--bp-header-line);
  box-shadow: 0 14px 34px rgba(18, 25, 30, .08);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateY(-8px);
  transition: opacity .18s ease, transform .18s ease, visibility .18s ease;
}

.bp-site-header.bp-search-open .bp-search-panel {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateY(0);
}

.bp-search-inner {
  width: min(100%, 760px);
  margin: 0 auto;
}

.bp-product-search-form {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto auto;
  align-items: center;
  gap: 10px;
  min-height: 54px;
  padding: 5px 6px 5px 16px;
  border: 1px solid #dcd7d0;
  border-radius: 14px;
  background: #fff;
}

.bp-search-field-icon {
  width: 20px;
  height: 20px;
  color: var(--bp-header-muted);
}

.bp-product-search-form input[type="search"] {
  min-width: 0;
  height: 40px;
  padding: 0;
  border: 0 !important;
  outline: 0 !important;
  box-shadow: none !important;
  background: transparent !important;
  color: var(--bp-header-text) !important;
  font: inherit;
  font-size: 16px;
}

.bp-search-submit {
  min-height: 40px;
  padding: 0 18px;
  border: 0;
  border-radius: 10px;
  background: var(--bp-header-accent);
  color: #fff;
  font: inherit;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
}

.bp-search-close {
  width: 40px;
  height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: var(--bp-header-muted);
  cursor: pointer;
}

.bp-search-close:hover,
.bp-search-close:focus-visible {
  color: var(--bp-header-text);
  background: #f7f5f2;
  outline: none;
}

.bp-mobile-overlay {
  position: fixed;
  inset: 0;
  z-index: 10020;
  background: rgba(15, 20, 24, .48);
  backdrop-filter: blur(2px);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity .22s ease, visibility .22s ease;
}

.bp-mobile-drawer {
  position: fixed;
  top: 0;
  right: 0;
  z-index: 10030;
  width: min(88vw, 380px);
  height: 100vh;
  height: 100dvh;
  display: flex;
  flex-direction: column;
  padding: 0;
  background: #fff;
  box-shadow: -24px 0 60px rgba(13, 19, 23, .18);
  transform: translateX(102%);
  opacity: .98;
  visibility: hidden;
  pointer-events: none;
  overflow: hidden;
  transition: transform .28s cubic-bezier(.22,.61,.36,1), visibility .28s ease;
}

.bp-site-header.bp-menu-open .bp-mobile-overlay {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

.bp-site-header.bp-menu-open .bp-mobile-drawer {
  transform: translateX(0);
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

body.bp-nav-open {
  overflow: hidden;
}

.bp-drawer-head {
  position: sticky;
  top: 0;
  z-index: 2;
  min-height: 82px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 22px;
  background: rgba(255,255,255,.97);
  border-bottom: 1px solid var(--bp-header-line);
}

.bp-menu-close {
  width: 44px;
  height: 44px;
}

.bp-drawer-body {
  flex: 1 1 auto;
  min-height: 0;
  display: flex;
  flex-direction: column;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 8px 22px 26px;
}

.bp-drawer-nav {
  flex: 0 0 auto;
  padding-top: 4px;
}

.bp-mobile-menu > li {
  position: relative;
  border-bottom: 1px solid var(--bp-header-line);
}

.bp-mobile-menu > li:last-child {
  border-bottom: 0;
}

.bp-mobile-menu li {
  margin: 0;
  padding: 0;
}

.bp-mobile-menu a {
  display: flex;
  align-items: center;
  min-height: 58px;
  padding: 14px 48px 14px 4px;
  color: var(--bp-header-text);
  text-decoration: none;
  font-size: 17px;
  line-height: 1.3;
  font-weight: 600;
}

.bp-mobile-menu a:hover,
.bp-mobile-menu a:focus-visible,
.bp-mobile-menu .current-menu-item > a,
.bp-mobile-menu .current-menu-ancestor > a {
  color: var(--bp-header-accent);
}

.bp-submenu-toggle {
  position: absolute;
  top: 7px;
  right: -4px;
  width: 44px;
  height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: var(--bp-header-text);
  cursor: pointer;
}

.bp-submenu-toggle:hover,
.bp-submenu-toggle:focus-visible {
  color: var(--bp-header-accent);
  background: var(--bp-header-accent-soft);
  outline: none;
}

.bp-submenu-toggle::before {
  content: "";
  width: 8px;
  height: 8px;
  border-right: 1.6px solid currentColor;
  border-bottom: 1.6px solid currentColor;
  transform: rotate(45deg) translate(-2px, -2px);
  transition: transform .18s ease;
}

.bp-submenu-toggle[aria-expanded="true"]::before {
  transform: rotate(225deg) translate(-1px, -1px);
}

.bp-mobile-menu .sub-menu {
  display: none;
  margin: 0 0 8px;
  padding: 2px 0 6px 14px;
  border-left: 2px solid #f0ebe5;
}

.bp-mobile-menu .bp-submenu-open > .sub-menu {
  display: block;
}

.bp-mobile-menu .sub-menu li {
  position: relative;
}

.bp-mobile-menu .sub-menu a {
  min-height: 48px;
  padding-top: 10px;
  padding-bottom: 10px;
  font-size: 15px;
  font-weight: 500;
}

.bp-drawer-utilities {
  margin-top: auto;
  padding-top: 22px;
  border-top: 1px solid var(--bp-header-line);
}

.bp-drawer-utilities-title {
  margin-bottom: 8px;
  color: var(--bp-header-muted);
  font-size: 12px;
  line-height: 1.3;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.bp-drawer-utility {
  min-height: 50px;
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--bp-header-text);
  text-decoration: none;
  font-size: 15px;
  font-weight: 600;
  border-radius: 10px;
}

.bp-drawer-utility:hover,
.bp-drawer-utility:focus-visible {
  color: var(--bp-header-accent);
  outline: none;
}

.bp-utility-icon {
  color: var(--bp-header-muted);
}

.bp-drawer-utility:hover .bp-utility-icon,
.bp-drawer-utility:focus-visible .bp-utility-icon {
  color: var(--bp-header-accent);
}

/* WordPress admin bar: keep the drawer below it while testing logged in. */
body.admin-bar .bp-mobile-overlay {
  top: 32px;
}

body.admin-bar .bp-mobile-drawer {
  top: 32px;
  height: calc(100vh - 32px);
  height: calc(100dvh - 32px);
}

@media (max-width: 1180px) {
  .bp-header-inner {
    width: min(calc(100% - 30px), var(--bp-header-width));
    min-height: 70px;
    grid-template-columns: auto 1fr;
    gap: 16px;
  }

  .bp-desktop-menu-wrap,
  .bp-account-link {
    display: none;
  }

  .bp-header-utilities {
    justify-self: end;
  }

  .bp-header-actions {
    gap: 2px;
  }

  .bp-menu-toggle {
    display: inline-flex;
  }

  .bp-brand img {
    height: 44px;
    max-width: 145px;
  }

  .bp-icon-button,
  .bp-cart-link {
    width: 40px;
    height: 40px;
  }

  .bp-header-icon {
    width: 22px;
    height: 22px;
  }

  .bp-search-panel {
    padding-left: 14px;
    padding-right: 14px;
  }
}

@media (max-width: 782px) {
  body.admin-bar .bp-mobile-overlay {
    top: 46px;
  }

  body.admin-bar .bp-mobile-drawer {
    top: 46px;
    height: calc(100vh - 46px);
    height: calc(100dvh - 46px);
  }
}

@media (max-width: 520px) {
  .bp-product-search-form {
    grid-template-columns: auto minmax(0, 1fr) auto;
  }

  .bp-search-submit {
    display: none;
  }

  .bp-search-close {
    grid-column: 3;
  }

  .bp-mobile-drawer {
    width: min(90vw, 380px);
  }
}

@media (max-width: 359px) {
  .bp-header-inner {
    width: calc(100% - 18px);
    gap: 8px;
  }

  .bp-brand img {
    height: 39px;
    max-width: 116px;
  }

  .bp-header-actions {
    gap: 0;
  }

  .bp-icon-button,
  .bp-cart-link {
    width: 37px;
    height: 37px;
  }

  .bp-mobile-drawer {
    width: 94vw;
  }

  .bp-drawer-head {
    padding-left: 18px;
    padding-right: 18px;
  }

  .bp-drawer-body {
    padding-left: 18px;
    padding-right: 18px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .bp-site-header *,
  .bp-site-header *::before,
  .bp-site-header *::after {
    scroll-behavior: auto !important;
    transition-duration: .01ms !important;
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
  }
}
