/* Renovate header polish — Astra Header Builder + mockup */

:root {
  --rn-navy: #154181;
  --rn-navy-dark: #0f3266;
  --rn-topbar-bg: #f3f4f6;
  --rn-text: #1a1a1a;
  --rn-muted: #6b7280;
}

/* Hide duplicate site title */
.ast-site-identity .site-title,
.ast-site-identity .site-description {
  display: none !important;
}

/* Logo — keep compact */
.ast-primary-header-bar .site-branding,
.ast-primary-header-bar .ast-site-identity {
  max-width: 200px;
}

.site-header .custom-logo-link,
.ast-primary-header-bar .custom-logo-link {
  display: inline-flex !important;
  align-items: center;
  max-width: 180px !important;
}

.site-header .custom-logo-link img,
.ast-header-break-point .custom-logo-link img,
.ast-primary-header-bar .custom-logo-link img,
.ast-primary-header-bar .site-logo-img img,
header .custom-logo-link img,
.custom-logo-link img.custom-logo,
.custom-logo-link img.rn-site-logo {
  max-height: 48px !important;
  max-width: 160px !important;
  width: auto !important;
  height: auto !important;
  object-fit: contain !important;
}

/* Above header */
.ast-above-header-bar {
  background-color: var(--rn-topbar-bg) !important;
  border-bottom: 1px solid #e5e7eb;
  font-size: 13px;
  color: var(--rn-muted);
}

.ast-above-header-bar a {
  color: var(--rn-muted);
  text-decoration: none;
  font-size: 13px;
}

.ast-above-header-bar a:hover {
  color: var(--rn-navy);
}

.rn-topbar-html {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  flex-wrap: wrap;
}

.rn-topbar-html .rn-item {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
}

.rn-topbar-html svg {
  width: 14px;
  height: 14px;
  flex-shrink: 0;
}

.rn-topbar-right {
  display: flex;
  align-items: center;
  gap: 1rem;
  justify-content: flex-end;
  flex-wrap: wrap;
}

.rn-topbar-right .rn-socials {
  display: inline-flex;
  gap: 0.5rem;
}

.rn-topbar-right .rn-socials a {
  display: inline-flex;
  width: 22px;
  height: 22px;
  align-items: center;
  justify-content: center;
}

/* Primary header row */
.ast-primary-header-bar {
  background: #fff !important;
  border-bottom: 1px solid #eee;
}

.ast-primary-header-bar .site-primary-header-wrap,
.ast-primary-header-bar .ast-builder-grid-row {
  align-items: center !important;
}

/*
 * Astra default is equal 3 columns (1fr 1fr 1fr) — that caps the search
 * at ~1/3 of the header. Give center the leftover space instead.
 */
.ast-primary-header-bar .ast-builder-grid-row.ast-grid-center-col-layout {
  grid-template-columns: auto minmax(480px, 1fr) auto !important;
  column-gap: 24px !important;
  width: 100% !important;
  max-width: 1200px;
}

.ast-primary-header-bar .site-header-primary-section-left,
.ast-primary-header-bar .site-header-primary-section-right {
  flex: 0 0 auto !important;
  width: auto !important;
  max-width: none !important;
}

.ast-primary-header-bar .site-header-primary-section-center {
  flex: 1 1 auto !important;
  width: 100% !important;
  max-width: none !important;
  min-width: 0 !important;
  justify-content: stretch !important;
  overflow: hidden !important; /* stop search from covering cart/account */
}

/* Keep cart + account above search so links stay clickable */
.ast-primary-header-bar .site-header-primary-section-right {
  position: relative !important;
  z-index: 20 !important;
}

/* ========== Search: always-visible box, button on RIGHT (desktop only) ========== */
#ast-desktop-header .ast-primary-header-bar .ast-header-search {
  flex: 1 1 auto !important;
  width: 100% !important;
  max-width: none !important;
  justify-content: stretch !important;
  display: flex !important;
}

#ast-desktop-header .ast-primary-header-bar .ast-header-search .ast-search-menu-icon.slide-search {
  display: block !important;
  width: 100% !important;
  max-width: none !important;
  position: relative !important;
  line-height: normal !important;
}

/* Hide the extra slide-search toggle icon (stray magnifier) */
#ast-desktop-header .ast-primary-header-bar .ast-header-search .ast-search-icon,
#ast-desktop-header .ast-primary-header-bar .ast-header-search .ast-search-menu-icon > .ast-search-icon,
#ast-desktop-header .ast-primary-header-bar .ast-header-search a.slide-search.astra-search-icon {
  display: none !important;
  visibility: hidden !important;
  width: 0 !important;
  height: 0 !important;
  overflow: hidden !important;
  pointer-events: none !important;
}

#ast-desktop-header .ast-primary-header-bar .ast-header-search .search-form {
  visibility: visible !important;
  opacity: 1 !important;
  position: relative !important;
  right: auto !important;
  top: auto !important;
  left: auto !important;
  transform: none !important;
  display: flex !important;
  width: 100% !important;
  max-width: none !important;
  margin: 0 !important;
  padding: 0 !important;
  border: 1px solid #d1d5db !important;
  border-radius: 10px !important;
  background: #fff !important;
  overflow: hidden;
  -webkit-backface-visibility: visible !important;
  backface-visibility: visible !important;
}

#ast-desktop-header .ast-primary-header-bar .ast-header-search .search-form label {
  display: flex !important;
  align-items: stretch !important;
  width: 100% !important;
  margin: 0 !important;
  flex-direction: row !important;
}

#ast-desktop-header .ast-primary-header-bar .ast-header-search .search-field,
#ast-desktop-header .ast-primary-header-bar .ast-header-search form.search-form .search-field,
#ast-desktop-header .ast-primary-header-bar .ast-header-search .ast-search-menu-icon.slide-search input.search-field {
  order: 1;
  flex: 1 1 auto !important;
  width: 100% !important;
  max-width: none !important;
  min-width: 0 !important;
  min-height: 48px !important;
  height: 48px !important;
  border: none !important;
  background: transparent !important;
  padding: 0 18px !important;
  margin: 0 !important;
  font-size: 15px !important;
  line-height: 48px !important;
  color: var(--rn-text) !important;
  border-radius: 0 !important;
  box-shadow: none !important;
}

#ast-desktop-header .ast-primary-header-bar .ast-header-search .search-submit,
#ast-desktop-header .ast-primary-header-bar .ast-header-search button.ast-search-submit {
  order: 2;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  position: relative !important;
  top: auto !important;
  right: auto !important;
  width: 52px !important;
  min-width: 52px !important;
  height: 48px !important;
  min-height: 48px !important;
  margin: 0 !important;
  padding: 0 !important;
  background: var(--rn-navy) !important;
  border: none !important;
  border-radius: 0 !important;
  color: #fff !important;
  cursor: pointer;
  flex: 0 0 52px !important;
  box-shadow: none !important;
}

#ast-desktop-header .ast-primary-header-bar .ast-header-search .search-submit .ast-icon,
#ast-desktop-header .ast-primary-header-bar .ast-header-search .search-submit svg {
  width: 18px !important;
  height: 18px !important;
  fill: #fff !important;
  color: #fff !important;
}

#ast-desktop-header .ast-primary-header-bar .ast-header-search .search-submit:hover {
  background: var(--rn-navy-dark) !important;
}

/* Cart / Account — Astra default outline cart; navy count visible */
.ast-header-woo-cart,
.ast-header-account-wrap,
.ast-header-account-link {
  color: var(--rn-text) !important;
  font-weight: 500;
  font-size: 14px;
}

.ast-site-header-cart .cart-container {
  display: inline-flex !important;
  flex-direction: row !important;
  flex-wrap: nowrap !important;
  align-items: center !important;
  gap: 8px !important;
  white-space: nowrap !important;
}

.ast-site-header-cart .ast-woo-header-cart-info-wrap {
  display: inline-block !important;
  width: auto !important;
  max-width: none !important;
  white-space: nowrap !important;
  writing-mode: horizontal-tb !important;
  color: var(--rn-text) !important;
  font-size: 14px !important;
  font-weight: 500 !important;
  line-height: 1.2 !important;
}

.ast-header-account-text {
  color: var(--rn-text) !important;
  font-size: 14px;
  font-weight: 500;
}

.ast-site-header-cart .ast-cart-menu-wrap .count {
  color: #154181 !important;
  border-color: #154181 !important;
  background-color: transparent !important;
  font-weight: 700 !important;
  visibility: visible !important;
  opacity: 1 !important;
}

.ast-site-header-cart .ast-cart-menu-wrap .count .ast-count-text {
  color: #154181 !important;
  font-weight: 700 !important;
  visibility: visible !important;
  opacity: 1 !important;
}

.ast-site-header-cart .ast-cart-menu-wrap .count::before,
.ast-site-header-cart .ast-cart-menu-wrap .count::after {
  border-color: #154181 !important;
  color: #154181 !important;
}

.ast-primary-header-bar .site-header-primary-section-right {
  display: flex !important;
  gap: 18px;
  align-items: center !important;
  flex-wrap: nowrap;
  position: relative !important;
  z-index: 20 !important;
}

.ast-primary-header-bar .ast-header-account-link {
  display: inline-flex !important;
  align-items: center;
  gap: 6px;
  position: relative !important;
  z-index: 21 !important;
  pointer-events: auto !important;
  cursor: pointer !important;
  text-decoration: none !important;
}

.ast-primary-header-bar .ast-header-account-wrap {
  position: relative !important;
  z-index: 21 !important;
  pointer-events: auto !important;
}

/* Below header / nav */
.ast-below-header-bar {
  background: #fff !important;
  border-bottom: 1px solid #e5e7eb;
}

.ast-below-header-bar .main-header-menu > .menu-item > .menu-link {
  font-size: 14px;
  font-weight: 500;
  color: var(--rn-text);
  padding: 14px 12px;
}

.ast-below-header-bar .main-header-menu > .menu-item > .menu-link:hover {
  color: var(--rn-navy);
}

/* Shop by Category button — hamburger + single-line label */
.ast-header-button-1 .ast-custom-button,
.ast-builder-button-wrap .ast-custom-button {
  background: var(--rn-navy) !important;
  border-color: var(--rn-navy) !important;
  color: #fff !important;
  border-radius: 8px !important;
  padding: 10px 18px !important;
  font-weight: 600 !important;
  font-size: 14px !important;
  text-transform: none !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 10px !important;
  white-space: nowrap !important;
  width: auto !important;
  max-width: none !important;
  line-height: 1.2 !important;
  box-sizing: border-box !important;
}

/* Astra prints a second plain .menu-link next to the button — hide it */
.ast-header-button-1 a.menu-link,
.ast-builder-button-wrap > a.menu-link {
  display: none !important;
}

.ast-below-header-bar .site-header-below-section-left {
  flex: 0 0 auto !important;
  width: auto !important;
  max-width: none !important;
}

.ast-header-button-1,
.ast-header-button-1 .ast-builder-button-wrap {
  flex: 0 0 auto !important;
  width: auto !important;
  max-width: none !important;
}

.ast-header-button-1 .ast-custom-button-link {
  display: inline-flex !important;
  width: auto !important;
  max-width: none !important;
  white-space: nowrap !important;
  text-decoration: none !important;
}

.ast-header-button-1 .ast-custom-button::before {
  content: "";
  display: inline-block;
  flex: 0 0 auto;
  width: 16px;
  height: 12px;
  background:
    linear-gradient(#fff, #fff) 0 0 / 100% 2px no-repeat,
    linear-gradient(#fff, #fff) 0 5px / 100% 2px no-repeat,
    linear-gradient(#fff, #fff) 0 10px / 100% 2px no-repeat;
}

.ast-header-button-1 .ast-custom-button:hover {
  background: var(--rn-navy-dark) !important;
}

/* Keep below-header nav on one row */
.ast-below-header-bar .ast-builder-grid-row.ast-grid-center-col-layout {
  grid-template-columns: auto minmax(0, 1fr) !important;
  align-items: center !important;
}

.ast-below-header-bar .main-header-menu {
  flex-wrap: nowrap !important;
}

/* Shortcode grid helpers */
.company_logos .container,
.celebrity_section .container,
.our_offer .container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 15px;
}

.company_logos .row,
.celebrity_section .row,
.our_offer .row {
  display: flex;
  flex-wrap: wrap;
  margin: 0 -10px;
}

.company_logos [class*="col-"],
.celebrity_section [class*="col-"],
.our_offer [class*="col-"] {
  padding: 0 10px;
  box-sizing: border-box;
}

.col-md-12 { width: 100%; }
.col-md-4, .col-6 { width: 50%; }
.col-md-3 { width: 50%; }
.col-md-2 { width: 33.333%; }

@media (min-width: 768px) {
  .col-md-4 { width: 33.333%; }
  .col-md-3 { width: 25%; }
  .col-md-2 { width: 16.666%; }
}

@media (max-width: 921px) {
  /* Hide desktop header rows — all pages */
  .ast-above-header-bar,
  .ast-below-header-bar,
  #ast-desktop-header {
    display: none !important;
  }

  body {
    padding-bottom: 72px;
  }

  /* Mobile header — mockup: menu | logo | search + cart + account */
  #ast-mobile-header .ast-main-header-wrap,
  #ast-mobile-header .ast-primary-header-bar {
    background: #fff !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
  }

  #ast-mobile-header .ast-primary-header-bar {
    border-bottom: 1px solid #e8ecf1 !important;
    box-shadow: none !important;
  }

  #ast-mobile-header .ast-primary-header-bar .ast-builder-grid-row.ast-grid-center-col-layout {
    display: grid !important;
    grid-template-columns: 40px minmax(0, 1fr) 114px !important;
    align-items: center !important;
    column-gap: 6px !important;
    row-gap: 0 !important;
    min-height: 58px !important;
    padding: 8px 10px !important;
    width: 100% !important;
    box-sizing: border-box !important;
  }

  #ast-mobile-header .site-header-primary-section-left {
    grid-column: 1 !important;
    grid-row: 1 !important;
    justify-self: start !important;
    width: 40px !important;
    min-width: 40px !important;
    max-width: 40px !important;
    z-index: 3 !important;
  }

  #ast-mobile-header .site-header-primary-section-center {
    grid-column: 2 !important;
    grid-row: 1 !important;
    justify-self: center !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    overflow: hidden !important;
    z-index: 1 !important;
  }

  #ast-mobile-header .site-header-primary-section-center .site-branding,
  #ast-mobile-header .site-header-primary-section-center .custom-logo-link {
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    max-width: 100% !important;
    width: 100% !important;
    margin: 0 !important;
    overflow: hidden !important;
  }

  #ast-mobile-header .site-header-primary-section-right {
    grid-column: 3 !important;
    grid-row: 1 !important;
    justify-self: end !important;
    width: 114px !important;
    min-width: 114px !important;
    max-width: 114px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: flex-end !important;
    gap: 6px !important;
    flex-wrap: nowrap !important;
    z-index: 3 !important;
    overflow: visible !important;
  }

  #ast-mobile-header .site-header-primary-section-left-center,
  #ast-mobile-header .site-header-primary-section-right-center {
    display: none !important;
  }

  #ast-mobile-header .ast-mobile-menu-trigger,
  #ast-mobile-header .ast-header-search .ast-search-icon,
  #ast-mobile-header .ast-header-search a.astra-search-icon,
  #ast-mobile-header .ast-site-header-cart .cart-container,
  #ast-mobile-header .ast-header-account-link {
    width: 34px !important;
    height: 34px !important;
    min-width: 34px !important;
    min-height: 34px !important;
    padding: 0 !important;
    margin: 0 !important;
    border: 0 !important;
    border-radius: 0 !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    flex: 0 0 32px !important;
    color: #154181 !important;
    background: transparent !important;
  }

  #ast-mobile-header .custom-logo,
  #ast-mobile-header .rn-site-logo {
    max-height: 32px !important;
    max-width: 100% !important;
    width: auto !important;
    height: auto !important;
    object-fit: contain !important;
  }

  #ast-mobile-header .ast-woo-header-cart-info-wrap,
  #ast-mobile-header .ast-header-account-text {
    display: none !important;
  }

  #ast-mobile-header .ast-header-search,
  #ast-mobile-header .ast-header-woo-cart,
  #ast-mobile-header .ast-header-account-wrap {
    display: flex !important;
    visibility: visible !important;
    opacity: 1 !important;
    flex: 0 0 34px !important;
    width: 34px !important;
    max-width: 34px !important;
    min-width: 34px !important;
    overflow: visible !important;
  }

  #ast-mobile-header .ast-header-search .ast-search-menu-icon,
  #ast-mobile-header .ast-header-search .ast-search-menu-icon.slide-search {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 34px !important;
    height: 34px !important;
    min-width: 34px !important;
    max-width: 34px !important;
    flex: 0 0 34px !important;
    overflow: visible !important;
    position: relative !important;
    line-height: 1 !important;
  }

  /* Magnifier icon — restored on mobile (desktop filter removes the toggle). */
  #ast-mobile-header .ast-header-search .ast-search-icon,
  #ast-mobile-header .ast-header-search a.astra-search-icon {
    display: inline-flex !important;
    visibility: visible !important;
    opacity: 1 !important;
    align-items: center !important;
    justify-content: center !important;
    width: 34px !important;
    height: 34px !important;
    min-width: 34px !important;
    min-height: 34px !important;
    padding: 0 !important;
    margin: 0 !important;
    color: #154181 !important;
    background: transparent !important;
    position: relative !important;
    z-index: 2 !important;
  }

  #ast-mobile-header .ast-header-search .ast-search-icon .ast-icon,
  #ast-mobile-header .ast-header-search .ast-search-icon svg,
  #ast-mobile-header .ast-header-search a.astra-search-icon svg {
    display: block !important;
    visibility: visible !important;
    width: 20px !important;
    height: 20px !important;
    fill: #154181 !important;
    color: #154181 !important;
  }

  /* Slide-out search box opens on icon tap. */
  #ast-mobile-header .ast-header-search .search-form {
    visibility: hidden !important;
    opacity: 0 !important;
    position: absolute !important;
    right: 0 !important;
    top: 100% !important;
    left: auto !important;
    transform: none !important;
    width: min(280px, calc(100vw - 24px)) !important;
    min-width: 200px !important;
    margin-top: 6px !important;
    z-index: 50 !important;
    border: 1px solid #d1d5db !important;
    border-radius: 8px !important;
    background: #fff !important;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08) !important;
    padding: 0 !important;
    display: flex !important;
  }

  #ast-mobile-header .ast-header-search .ast-search-menu-icon.ast-dropdown-active .search-form {
    visibility: visible !important;
    opacity: 1 !important;
  }

  #ast-mobile-header .ast-header-search .search-form label {
    display: flex !important;
    align-items: center !important;
    width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
  }

  #ast-mobile-header .ast-header-search .search-field {
    position: static !important;
    width: 100% !important;
    height: 40px !important;
    min-height: 40px !important;
    opacity: 1 !important;
    pointer-events: auto !important;
    padding: 0 12px !important;
    margin: 0 !important;
    border: 0 !important;
    font-size: 14px !important;
    overflow: visible !important;
  }

  #ast-mobile-header .ast-header-search .search-submit,
  #ast-mobile-header .ast-header-search button.ast-search-submit {
    display: none !important;
  }

  #ast-mobile-header .ast-site-header-cart .cart-container {
    position: relative !important;
    padding: 0 !important;
    gap: 0 !important;
    display: inline-flex !important;
    visibility: visible !important;
  }

  #ast-mobile-header .ast-site-header-cart .ast-cart-menu-wrap {
    position: relative !important;
    width: 34px !important;
    height: 34px !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    visibility: visible !important;
  }

  #ast-mobile-header .ast-site-header-cart .ast-cart-menu-wrap .count {
    position: relative !important;
    top: auto !important;
    right: auto !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    min-width: 22px !important;
    width: 22px !important;
    height: 22px !important;
    padding: 0 !important;
    background: transparent !important;
    color: #154181 !important;
    border-color: #154181 !important;
    border-radius: 0 !important;
    font-size: 10px !important;
    font-weight: 700 !important;
    line-height: 1 !important;
    visibility: visible !important;
    opacity: 1 !important;
  }

  #ast-mobile-header .ast-site-header-cart .ast-cart-menu-wrap .count .ast-count-text {
    color: #154181 !important;
    font-size: 10px !important;
    font-weight: 700 !important;
    line-height: 1 !important;
    visibility: visible !important;
    opacity: 1 !important;
  }

  #ast-mobile-header .ast-site-header-cart .ast-cart-menu-wrap .count::before,
  #ast-mobile-header .ast-site-header-cart .ast-cart-menu-wrap .count::after {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    border-color: #154181 !important;
    color: #154181 !important;
  }

  #ast-mobile-header .ast-header-account-link svg,
  #ast-mobile-header .ast-mobile-menu-trigger svg {
    width: 20px !important;
    height: 20px !important;
  }

  /* Open menu drawer: hide duplicate search / cart / account (keep header bar icons). */
  #ast-mobile-popup .ast-header-search,
  #ast-mobile-popup .ast-header-woo-cart,
  #ast-mobile-popup .ast-header-account,
  #ast-mobile-popup .ast-header-account-wrap,
  #ast-mobile-popup [data-section="section-header-search"],
  #ast-mobile-popup [data-section="section-header-woo-cart"],
  #ast-mobile-popup [data-section="section-header-account"],
  .ast-mobile-header-content .ast-header-search,
  .ast-mobile-header-content .ast-header-woo-cart,
  .ast-mobile-header-content .ast-header-account,
  .ast-mobile-header-content .ast-header-account-wrap,
  .ast-mobile-header-content [data-section="section-header-search"],
  .ast-mobile-header-content [data-section="section-header-woo-cart"],
  .ast-mobile-header-content [data-section="section-header-account"] {
    display: none !important;
  }

  /* Shop by Category — full-width under open mobile menu links */
  .ast-mobile-header-content .ast-header-button-1,
  #ast-mobile-popup .ast-header-button-1 {
    display: block !important;
    width: 100% !important;
    padding: 12px 16px 16px !important;
    box-sizing: border-box !important;
  }

  .ast-mobile-header-content .ast-header-button-1 .ast-builder-button-wrap,
  .ast-mobile-header-content .ast-header-button-1 .ast-custom-button-link,
  #ast-mobile-popup .ast-header-button-1 .ast-builder-button-wrap,
  #ast-mobile-popup .ast-header-button-1 .ast-custom-button-link {
    display: block !important;
    width: 100% !important;
  }

  .ast-mobile-header-content .ast-header-button-1 .ast-custom-button,
  #ast-mobile-popup .ast-header-button-1 .ast-custom-button {
    display: flex !important;
    width: 100% !important;
    justify-content: center !important;
  }
}
