/* E-Wish Store style header */
.site-top.ewish-header {
  position: sticky;
  top: 0;
  z-index: 200;
  width: 100%;
}

.ewish-header .header {
  background: rgba(255, 255, 255, .98);
  backdrop-filter: blur(12px);
  box-shadow: 0 1px 0 rgba(0, 0, 0, .06);
}

.ewish-header .header-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 68px;
  gap: 16px;
}

.ewish-header .nav-toggle {
  display: none;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border: 1px solid rgba(18, 18, 18, .1);
  border-radius: 10px;
  background: #fff;
  cursor: pointer;
  font-size: 18px;
  color: #333;
  flex-shrink: 0;
  transition: border-color .2s, color .2s;
}

.ewish-header .nav-toggle:hover {
  border-color: rgba(199, 162, 84, .45);
  color: #c7a254;
}

.ewish-header .logo {
  display: inline-flex;
  align-items: center;
  font-size: 22px;
  font-weight: 800;
  color: #222;
  letter-spacing: -.5px;
  text-decoration: none;
  flex-shrink: 0;
}

.ewish-header .logo span {
  color: #c7a254;
}

.ewish-header .nav-links {
  display: flex;
  align-items: center;
  gap: 6px;
  list-style: none;
  margin: 0;
  padding: 0;
  flex: 1;
  justify-content: center;
  overflow: visible;
}

.ewish-header .nav-links a {
  position: relative;
  padding: 8px 12px 10px;
  font-size: 12px;
  font-weight: 700;
  color: #555;
  text-transform: uppercase;
  letter-spacing: .06em;
  transition: color .2s;
  text-decoration: none;
  white-space: nowrap;
}

.ewish-header .nav-links a:hover {
  color: #c7a254;
}

.ewish-header .nav-links a.is-active {
  color: #1a1a1a;
}

.ewish-header .nav-links a.is-active::after {
  content: '';
  position: absolute;
  left: 10px;
  right: 10px;
  bottom: 2px;
  height: 2px;
  background: #c7a254;
  border-radius: 1px;
}

.ewish-header .nav-links a.is-active:hover {
  color: #1a1a1a;
}

.ewish-header .header-right {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

/* Sign in link */
.ewish-header .header-account__login {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 40px;
  padding: 0 4px;
  color: #555;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .04em;
  text-transform: uppercase;
  text-decoration: none;
  transition: color .2s;
}

.ewish-header .header-account__login:hover {
  color: #c7a254;
}

.ewish-header .header-account__login-text {
  white-space: nowrap;
}

.ewish-header .header-account__icon {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

/* Logged-in account */
.ewish-header .header-account--logged {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 0;
  border: none;
  background: none;
  box-shadow: none;
}

.ewish-header .header-account__chip {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  text-decoration: none;
  color: inherit;
  transition: color .2s;
}

.ewish-header .header-account__chip:hover .header-account__name {
  color: #c7a254;
}

.ewish-header .header-account__chip.is-active .header-account__name {
  color: #1a1a1a;
}

.ewish-header .header-account__avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #c7a254 0%, #a8843f 100%);
  color: #fff;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .03em;
  flex-shrink: 0;
}

.ewish-header .header-account__name {
  max-width: 140px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .02em;
  color: #333;
  transition: color .2s;
}

.ewish-header .header-account__sep {
  width: 1px;
  height: 16px;
  background: rgba(18, 18, 18, .12);
  flex-shrink: 0;
}

.ewish-header .header-account__signout {
  padding: 0;
  border: none;
  background: none;
  color: rgba(18, 18, 18, .45);
  font: inherit;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: color .2s;
  white-space: nowrap;
  text-decoration: underline;
  text-decoration-color: rgba(18, 18, 18, .18);
  text-underline-offset: 3px;
}

.ewish-header .header-account__signout:hover {
  color: #971316;
  text-decoration-color: rgba(151, 19, 22, .35);
}

/* Cart button */
.ewish-header .header-cart {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 10px;
  border: 1px solid rgba(18, 18, 18, .1);
  background: #fff;
  color: #333;
  text-decoration: none;
  transition: border-color .2s, color .2s, background .2s, transform .2s;
}

.ewish-header .header-cart:hover {
  border-color: rgba(199, 162, 84, .45);
  color: #c7a254;
  background: rgba(199, 162, 84, .08);
  transform: translateY(-1px);
}

.ewish-header .header-cart.is-active {
  color: #1a1a1a;
}

.ewish-header .header-cart__icon {
  width: 20px;
  height: 20px;
}

.ewish-header .cart-badge {
  position: absolute;
  top: -5px;
  right: -5px;
  min-width: 18px;
  height: 18px;
  padding: 0 4px;
  border-radius: 999px;
  background: #c7a254;
  color: #fff;
  font-size: 10px;
  font-weight: 800;
  display: none;
  align-items: center;
  justify-content: center;
  border: 2px solid #fff;
  box-shadow: 0 2px 6px rgba(0, 0, 0, .12);
}

body.product-detail-page .site-top.ewish-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
}

.mobile-menu {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 300;
  background: #fff;
  padding: 72px 24px 24px;
  overflow-y: auto;
  transform: translateX(-100%);
  transition: transform .3s ease;
}

.mobile-menu.is-open {
  display: block;
  transform: translateX(0);
}

.mobile-menu__close {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 44px;
  height: 44px;
  font-size: 28px;
  line-height: 1;
  border: 0;
  background: transparent;
  cursor: pointer;
  color: #333;
}

@media (max-width: 768px) {
  .mobile-menu {
    display: block;
  }
}

/* Mobile menu account panel */
.mobile-menu__account {
  margin-top: 24px;
  padding-top: 20px;
  border-top: 1px solid rgba(18, 18, 18, .08);
}

.mobile-menu__account--logged {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.mobile-menu__account-link {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 4px 0;
  text-decoration: none;
  color: inherit;
}

.mobile-menu__avatar {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #c7a254 0%, #a8843f 100%);
  color: #fff;
  font-size: 13px;
  font-weight: 800;
  flex-shrink: 0;
}

.mobile-menu__account-info {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-width: 0;
  gap: 2px;
}

.mobile-menu__account-name {
  font-size: 15px;
  font-weight: 700;
  color: #1a1a1a;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.mobile-menu__account-email {
  font-size: 13px;
  color: rgba(18, 18, 18, .55);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.mobile-menu__signout {
  align-self: flex-start;
  padding: 0;
  border: none;
  background: none;
  color: rgba(18, 18, 18, .45);
  font: inherit;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  text-decoration: underline;
  text-decoration-color: rgba(18, 18, 18, .18);
  text-underline-offset: 3px;
}

.mobile-menu__signout:hover {
  color: #971316;
  text-decoration-color: rgba(151, 19, 22, .35);
}

.mobile-menu__login {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 4px 0;
  color: #555;
  font-size: 14px;
  font-weight: 700;
  text-decoration: none;
  transition: color .2s;
}

.mobile-menu__login:hover {
  color: #c7a254;
}

.mobile-menu__login .header-account__icon {
  width: 20px;
  height: 20px;
}

.mobile-menu__nav a {
  display: block;
  padding: 14px 0;
  font-size: 15px;
  font-weight: 700;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: #333;
  text-decoration: none;
  border-bottom: 1px solid rgba(18, 18, 18, .06);
  transition: color .2s, padding-left .2s;
}

.mobile-menu__nav a:hover {
  color: #c7a254;
  padding-left: 6px;
}

.mobile-menu__nav a.is-active {
  color: #1a1a1a;
  box-shadow: inset 0 -2px 0 #c7a254;
}

@media (max-width: 768px) {
  .ewish-header .nav-links {
    display: none;
  }

  .ewish-header .nav-toggle {
    display: inline-flex;
  }

  .ewish-header .header-inner {
    display: grid;
    grid-template-columns: auto 1fr auto;
    height: 64px;
  }

  .ewish-header .logo {
    justify-self: center;
    font-size: 20px;
  }

  .ewish-header .header-right {
    justify-self: end;
    gap: 8px;
  }

  .ewish-header .header-account--logged {
    padding: 0;
    gap: 0;
  }

  .ewish-header .header-account__name,
  .ewish-header .header-account__sep,
  .ewish-header .header-account__signout {
    display: none;
  }

  .ewish-header .header-account__chip {
    padding: 0;
  }

  .ewish-header .header-account__login-text {
    display: none;
  }

  .ewish-header .header-account__login {
    width: 40px;
    height: 40px;
    padding: 0;
    justify-content: center;
    border: 1px solid rgba(18, 18, 18, .1);
    border-radius: 10px;
  }
}

@media (max-width: 480px) {
  .ewish-header .header-account__name {
    max-width: 88px;
  }
}
