/*
 * Rubroo — cabeçalho editorial responsivo.
 * Usa apenas rotas reais da loja e não altera produtos ou taxonomias.
 */
:root {
  --rubroo-header-ink: #0b0b0b;
  --rubroo-header-red: #b31831;
  --rubroo-header-paper: #f7f5f1;
  --rubroo-header-line: #dedbd4;
  --rubroo-header-muted: #6d6962;
}

header.elementor-location-header {
  display: none !important;
}

.rubroo-header-root,
.rubroo-header-root * {
  box-sizing: border-box;
}

.rubroo-header-root {
  position: relative;
  z-index: 9990;
  color: var(--rubroo-header-ink);
  font-family: inherit;
}

.rubroo-announcement {
  min-height: 34px;
  overflow: hidden;
  background: var(--rubroo-header-ink);
  color: #fff;
}

.rubroo-announcement-inner {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 34px;
  padding: 8px 20px;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: .12em;
  line-height: 1.5;
  text-align: center;
  text-transform: uppercase;
}

.rubroo-announcement b {
  color: #ef6a7e;
  font-weight: 900;
}

.rubroo-header-shell {
  position: sticky;
  top: 0;
  z-index: 9991;
  border-bottom: 1px solid var(--rubroo-header-ink);
  background: rgba(255, 255, 255, .96);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
}

body.admin-bar .rubroo-header-shell {
  top: 32px;
}

.rubroo-header-main {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  align-items: center;
  gap: 28px;
  width: min(100% - 48px, 1440px);
  min-height: 70px;
  margin: 0 auto;
}

.rubroo-header-primary,
.rubroo-header-actions,
.rubroo-category-nav-inner {
  display: flex;
  align-items: center;
}

.rubroo-header-primary {
  gap: 28px;
}

.rubroo-header-actions {
  justify-content: flex-end;
  gap: 22px;
}

.rubroo-header-link,
.rubroo-header-action,
.rubroo-category-link {
  color: var(--rubroo-header-ink);
  font-size: 10px;
  font-weight: 900;
  letter-spacing: .12em;
  text-decoration: none;
  text-transform: uppercase;
  white-space: nowrap;
}

.rubroo-header-link,
.rubroo-category-link {
  position: relative;
}

.rubroo-header-link::after,
.rubroo-category-link::after {
  position: absolute;
  right: 0;
  bottom: -6px;
  left: 0;
  height: 1px;
  background: currentColor;
  content: "";
  transform: scaleX(0);
  transform-origin: right;
  transition: transform .2s ease;
}

.rubroo-header-link:hover::after,
.rubroo-header-link:focus-visible::after,
.rubroo-category-link:hover::after,
.rubroo-category-link:focus-visible::after {
  transform: scaleX(1);
  transform-origin: left;
}

.rubroo-header-brand {
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 180px;
}

.rubroo-header-brand .custom-logo-link,
.rubroo-header-brand > a {
  display: flex;
  align-items: center;
  justify-content: center;
}

.rubroo-header-brand img {
  display: block;
  width: auto !important;
  max-width: 190px !important;
  height: 34px !important;
  object-fit: contain;
}

.rubroo-header-wordmark {
  color: var(--rubroo-header-ink);
  font-size: 28px;
  font-weight: 900;
  letter-spacing: -.05em;
  text-decoration: none;
  text-transform: uppercase;
}

.rubroo-header-action {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 8px 0;
  border: 0;
  background: transparent;
  cursor: pointer;
}

.rubroo-header-action svg,
.rubroo-mobile-trigger svg,
.rubroo-mobile-cart svg,
.rubroo-drawer-search svg,
.rubroo-drawer-icon svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: square;
  stroke-linejoin: miter;
  stroke-width: 1.6;
}

.rubroo-header-action:hover,
.rubroo-header-action:focus-visible {
  color: var(--rubroo-header-red);
}

.rubroo-cart-action {
  position: relative;
}

.rubroo-cart-count {
  display: inline-grid;
  place-items: center;
  min-width: 18px;
  height: 18px;
  padding: 0 4px;
  border-radius: 99px;
  background: var(--rubroo-header-ink);
  color: #fff;
  font-size: 9px;
  font-weight: 900;
  line-height: 1;
}

.rubroo-category-nav {
  border-top: 1px solid var(--rubroo-header-line);
  background: #fff;
}

.rubroo-category-nav-inner {
  justify-content: center;
  gap: clamp(20px, 2.35vw, 38px);
  width: min(100% - 48px, 1440px);
  min-height: 42px;
  margin: 0 auto;
  overflow-x: auto;
  scrollbar-width: none;
}

.rubroo-category-nav-inner::-webkit-scrollbar {
  display: none;
}

.rubroo-category-link {
  flex: 0 0 auto;
  font-size: 9px;
}

.rubroo-category-link.is-featured {
  color: var(--rubroo-header-red);
}

.rubroo-header-search-panel {
  border-top: 1px solid var(--rubroo-header-line);
  background: var(--rubroo-header-paper);
}

.rubroo-header-search-panel[hidden] {
  display: none;
}

.rubroo-header-search-form {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 16px;
  width: min(100% - 48px, 1120px);
  min-height: 76px;
  margin: 0 auto;
}

.rubroo-header-search-form > span {
  color: var(--rubroo-header-red);
  font-size: 10px;
  font-weight: 900;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.rubroo-header-search-form input[type="search"] {
  width: 100%;
  min-height: 46px;
  padding: 0 2px;
  border: 0;
  border-bottom: 1px solid var(--rubroo-header-ink);
  border-radius: 0 !important;
  outline: 0;
  background: transparent;
  color: var(--rubroo-header-ink);
  font: inherit;
  font-size: 18px;
}

.rubroo-header-search-form button {
  min-height: 44px;
  padding: 0 20px;
  border: 1px solid var(--rubroo-header-ink);
  border-radius: 0 !important;
  background: var(--rubroo-header-ink);
  color: #fff;
  font-size: 10px;
  font-weight: 900;
  letter-spacing: .1em;
  text-transform: uppercase;
  cursor: pointer;
}

.rubroo-mobile-trigger,
.rubroo-mobile-cart {
  display: none;
}

.rubroo-menu-overlay {
  position: fixed;
  inset: 0;
  z-index: 10010;
  visibility: hidden;
  border: 0;
  background: rgba(0, 0, 0, .46);
  opacity: 0;
  cursor: pointer;
  transition: opacity .25s ease, visibility .25s ease;
}

.rubroo-mobile-drawer {
  position: fixed;
  top: 0;
  bottom: 0;
  left: 0;
  z-index: 10020;
  display: flex;
  flex-direction: column;
  width: min(88vw, 420px);
  max-width: 100%;
  background: #fff;
  box-shadow: 24px 0 60px rgba(0, 0, 0, .2);
  transform: translateX(-104%);
  transition: transform .3s ease;
}

.rubroo-header-root.is-menu-open .rubroo-menu-overlay {
  visibility: visible;
  opacity: 1;
}

.rubroo-header-root.is-menu-open .rubroo-mobile-drawer {
  transform: translateX(0);
}

body.rubroo-menu-locked {
  overflow: hidden;
}

.rubroo-drawer-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 70px;
  padding: 0 22px;
  border-bottom: 1px solid var(--rubroo-header-line);
}

.rubroo-drawer-eyebrow {
  color: var(--rubroo-header-red);
  font-size: 10px;
  font-weight: 900;
  letter-spacing: .14em;
  text-transform: uppercase;
}

.rubroo-drawer-close {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  padding: 0;
  border: 1px solid var(--rubroo-header-ink);
  border-radius: 0;
  background: #fff;
  color: var(--rubroo-header-ink);
  font-size: 25px;
  line-height: 1;
  cursor: pointer;
}

.rubroo-drawer-search {
  padding: 20px 22px;
  border-bottom: 1px solid var(--rubroo-header-line);
  background: var(--rubroo-header-paper);
}

.rubroo-drawer-search form {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  border-bottom: 1px solid var(--rubroo-header-ink);
}

.rubroo-drawer-search input {
  min-width: 0;
  min-height: 46px;
  padding: 0;
  border: 0;
  border-radius: 0 !important;
  outline: 0;
  background: transparent;
  font: inherit;
  font-size: 16px;
}

.rubroo-drawer-search button {
  width: 42px;
  height: 42px;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--rubroo-header-ink);
  cursor: pointer;
}

.rubroo-drawer-nav {
  flex: 1;
  overflow-y: auto;
  padding: 8px 22px 26px;
}

.rubroo-drawer-nav a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 52px;
  border-bottom: 1px solid var(--rubroo-header-line);
  color: var(--rubroo-header-ink);
  font-size: 16px;
  font-weight: 800;
  letter-spacing: -.01em;
  text-decoration: none;
}

.rubroo-drawer-nav a::after {
  color: var(--rubroo-header-red);
  content: "↗";
  font-size: 14px;
}

.rubroo-drawer-nav a.is-featured {
  color: var(--rubroo-header-red);
}

.rubroo-drawer-utilities {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border-top: 1px solid var(--rubroo-header-ink);
  background: var(--rubroo-header-ink);
}

.rubroo-drawer-utilities a {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-height: 76px;
  border-right: 1px solid rgba(255, 255, 255, .2);
  color: #fff;
  font-size: 9px;
  font-weight: 900;
  letter-spacing: .08em;
  text-decoration: none;
  text-transform: uppercase;
}

.rubroo-drawer-utilities a:last-child {
  border-right: 0;
}

@media (max-width: 1120px) {
  .rubroo-header-main,
  .rubroo-category-nav-inner {
    width: min(100% - 32px, 1440px);
  }

  .rubroo-header-primary {
    gap: 18px;
  }

  .rubroo-header-actions {
    gap: 15px;
  }

  .rubroo-header-action span:not(.rubroo-cart-count) {
    display: none;
  }

  .rubroo-category-nav-inner {
    justify-content: flex-start;
  }
}

@media (max-width: 900px) {
  .rubroo-announcement-inner {
    justify-content: flex-start;
    overflow: hidden;
    white-space: nowrap;
  }

  .rubroo-header-main {
    grid-template-columns: 48px minmax(0, 1fr) 48px;
    gap: 8px;
    width: 100%;
    min-height: 60px;
    padding: 0 12px;
  }

  .rubroo-header-primary,
  .rubroo-header-actions,
  .rubroo-category-nav,
  .rubroo-header-search-panel {
    display: none !important;
  }

  .rubroo-mobile-trigger,
  .rubroo-mobile-cart {
    display: inline-flex;
  }

  .rubroo-mobile-trigger {
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    padding: 0;
    border: 0;
    background: transparent;
    color: var(--rubroo-header-ink);
    cursor: pointer;
  }

  .rubroo-mobile-cart {
    position: relative;
    align-items: center;
    justify-content: center;
    justify-self: end;
    width: 44px;
    height: 44px;
    color: var(--rubroo-header-ink);
    text-decoration: none;
  }

  .rubroo-mobile-cart .rubroo-cart-count {
    position: absolute;
    top: 4px;
    right: 0;
  }

  .rubroo-header-brand {
    min-width: 0;
  }

  .rubroo-header-brand img {
    max-width: 150px !important;
    height: 28px !important;
  }

  .rubroo-header-wordmark {
    font-size: 24px;
  }
}

@media (max-width: 782px) {
  body.admin-bar .rubroo-header-shell {
    top: 46px;
  }
}

@media (max-width: 480px) {
  .rubroo-announcement-inner {
    padding-inline: 14px;
    font-size: 9px;
  }

  .rubroo-mobile-drawer {
    width: min(92vw, 390px);
  }
}

@media (prefers-reduced-motion: reduce) {
  .rubroo-menu-overlay,
  .rubroo-mobile-drawer,
  .rubroo-header-link::after,
  .rubroo-category-link::after {
    transition: none;
  }
}

/* =========================================================
   CORREÇÃO DO MENU MOBILE
   Neutraliza estilos globais de botões e estabiliza o drawer.
========================================================= */
@media (max-width: 900px) {
  html body .rubroo-header-root button.rubroo-mobile-trigger,
  html body .rubroo-header-root button.rubroo-drawer-close,
  html body .rubroo-header-root .rubroo-drawer-search button {
    -webkit-appearance: none !important;
    appearance: none !important;
    box-sizing: border-box !important;
    flex: 0 0 auto !important;
    margin: 0 !important;
    box-shadow: none !important;
    transform: none !important;
    line-height: 1 !important;
  }

  html body .rubroo-header-root button.rubroo-mobile-trigger {
    width: 44px !important;
    min-width: 44px !important;
    max-width: 44px !important;
    height: 44px !important;
    min-height: 44px !important;
    max-height: 44px !important;
    padding: 0 !important;
    border: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    color: var(--rubroo-header-ink) !important;
  }

  html body .rubroo-header-root button.rubroo-mobile-trigger svg {
    display: block !important;
    width: 22px !important;
    min-width: 22px !important;
    height: 22px !important;
  }

  html body .rubroo-header-root button.rubroo-drawer-close {
    width: 42px !important;
    min-width: 42px !important;
    max-width: 42px !important;
    height: 42px !important;
    min-height: 42px !important;
    max-height: 42px !important;
    padding: 0 !important;
    border: 1px solid var(--rubroo-header-ink) !important;
    border-radius: 0 !important;
    background: #fff !important;
    color: var(--rubroo-header-ink) !important;
    font-size: 25px !important;
  }

  html body .rubroo-header-root .rubroo-drawer-search button {
    width: 42px !important;
    min-width: 42px !important;
    max-width: 42px !important;
    height: 42px !important;
    min-height: 42px !important;
    max-height: 42px !important;
    padding: 0 !important;
    border: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    color: var(--rubroo-header-ink) !important;
  }

  html body button.rubroo-menu-overlay {
    width: auto !important;
    min-width: 0 !important;
    max-width: none !important;
    height: auto !important;
    min-height: 0 !important;
    max-height: none !important;
    margin: 0 !important;
    padding: 0 !important;
    border: 0 !important;
    border-radius: 0 !important;
    background: rgba(0, 0, 0, .46) !important;
    box-shadow: none !important;
  }

  html body .rubroo-mobile-drawer {
    width: min(88vw, 420px) !important;
    max-width: calc(100vw - 24px) !important;
    height: 100vh !important;
    height: 100dvh !important;
    max-height: 100vh !important;
    max-height: 100dvh !important;
    overflow: hidden !important;
    overscroll-behavior: contain;
  }

  .rubroo-drawer-head,
  .rubroo-drawer-search,
  .rubroo-drawer-utilities {
    flex: 0 0 auto;
  }

  .rubroo-drawer-nav {
    flex: 1 1 auto;
    min-height: 0;
    overscroll-behavior: contain;
  }

  .rubroo-drawer-utilities {
    padding-bottom: env(safe-area-inset-bottom);
  }
}

@media (max-width: 480px) {
  html body .rubroo-mobile-drawer {
    width: calc(100vw - 20px) !important;
    max-width: calc(100vw - 20px) !important;
  }
}
