/* ============================================================
   FIXU shell — topbar, header, mobile drawer, footer (R1.1)
   Loaded only on body.fixu-shell pages.
   ============================================================ */

/* R25.6 — legacy styles.css applies `header { position:sticky; z-index:888 }` to every
   <header> tag, including page heroes (.fixu-atypicke-intro etc.), which then paint above
   the shell header (100) and mobile drawer (209). Keep only .fixu-site-header sticky. */
body.fixu-shell header:not(.fixu-site-header) {
  position: relative;
  top: auto;
  z-index: auto;
}

/* R25.6 — cap in-page sticky layers below global chrome (safety net) */
body.fixu-shell .fixu-listing-filters,
body.fixu-shell .fixu-checkout-summary-inner,
body.fixu-shell .fixu-cart-summary-inner,
body.fixu-shell .fixu-detail-canvas-card.tf-product-media-wrap {
  z-index: var(--fixu-z-sticky-page);
}
body.fixu-shell .tf-topbar,
body.fixu-shell #header.header-default,
body.fixu-shell .tf-toolbar-bottom,
body.fixu-shell #mobileMenu,
body.fixu-shell .footericon,
body.fixu-shell #footer.footer,
body.fixu-shell .preload,
body.fixu-shell #scroll-top,
body.fixu-shell .modal-newleter,
body.fixu-shell .auto-popup.modal-newleter,
body.fixu-shell #shoppingCart,
body.fixu-shell .modal-shopping-cart {
  display: none !important;
}

body.fixu-shell #wrapper {
  overflow-x: clip;
  position: relative;
  z-index: var(--fixu-z-content);
}

/* R25.6 — shell chrome stays above page content stacking contexts */
.fixu-topbar,
.fixu-topbar-mobile,
.fixu-site-header {
  position: relative;
  z-index: var(--fixu-z-header);
}

/* R1.1: hide ThemeForest placeholder alt if hero assets fail to load */
body.fixu-home .tf-slideshow .wrap-slider > img {
  font-size: 0;
  color: transparent;
  text-indent: -9999px;
}

/* ---------- Topbar ---------- */
.fixu-topbar {
  /* R14: cleaner FIXU navy-blue (less blackish than --fixu-navy) */
  background: #0D3B6E;
  color: rgba(255, 255, 255, 0.94);
  font-size: var(--fixu-fs-xs);
  line-height: 1.3;
}
.fixu-topbar-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--fixu-sp-4);
  min-height: var(--fixu-topbar-h);
  padding: 8px 0;
  box-sizing: border-box;
}
.fixu-topbar-usps,
.fixu-topbar-contact {
  display: flex;
  align-items: center;
  gap: 12px 22px;
  flex-wrap: nowrap;
  min-width: 0;
}
.fixu-topbar-usps span {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  white-space: nowrap;
  color: rgba(255, 255, 255, 0.96);
  font-weight: 500;
  font-size: 12.5px;
  letter-spacing: 0.01em;
}
.fixu-topbar-usps svg,
.fixu-topbar-icon {
  flex: 0 0 auto;
  width: 23px;
  height: 23px;
  display: block;
  object-fit: contain;
  opacity: 1;
}
.fixu-topbar-contact a {
  color: #fff;
  font-weight: 600;
  font-size: 12.5px;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  white-space: nowrap;
}
.fixu-topbar-contact a:hover {
  text-decoration: underline;
}
.fixu-topbar-contact svg {
  width: 14px;
  height: 14px;
  flex: 0 0 auto;
}
.fixu-topbar-sep {
  width: 1px;
  height: 14px;
  background: rgba(255, 255, 255, 0.28);
  display: inline-block;
  flex: 0 0 auto;
}

/* Mobile 2×2 benefit strip — static under header, never sticky */
.fixu-topbar-mobile {
  display: none;
  background: #0D3B6E;
  color: rgba(255, 255, 255, 0.96);
  position: static;
}

@media (max-width: 1100px) {
  .fixu-topbar-usps span:nth-child(n + 4) {
    display: none;
  }
}

@media (max-width: 900px) {
  .fixu-topbar {
    display: none;
  }

  .fixu-topbar-mobile {
    display: block;
  }

  .fixu-topbar-mobile-inner {
    display: grid;
    grid-template-columns: 1fr 1fr;
    grid-template-rows: auto auto;
    gap: 0;
    min-height: 0;
    padding: 5px 0;
    box-sizing: border-box;
  }

  .fixu-topbar-mobile-inner span {
    display: flex;
    align-items: center;
    gap: 6px;
    min-width: 0;
    padding: 3px 6px;
    color: rgba(255, 255, 255, 0.96);
    font-weight: 500;
    font-size: 11.5px;
    line-height: 1.2;
    letter-spacing: 0.01em;
  }

  .fixu-topbar-mobile-inner span:nth-child(odd) {
    border-right: 1px solid rgba(255, 255, 255, 0.14);
  }

  .fixu-topbar-mobile-inner span:nth-child(-n + 2) {
    border-bottom: 1px solid rgba(255, 255, 255, 0.14);
  }

  .fixu-topbar-mobile-inner .fixu-topbar-icon {
    width: 18px;
    height: 18px;
  }
}

/* ---------- Site header ---------- */
.fixu-site-header {
  position: sticky;
  top: 0;
  z-index: var(--fixu-z-header);
  background: var(--fixu-bg);
  border-bottom: 1px solid var(--fixu-border);
}
body.fixu-shell.fixu-menu-open .fixu-site-header {
  z-index: var(--fixu-z-menu-drawer);
}
.fixu-header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--fixu-sp-5);
  min-height: var(--fixu-header-h);
  padding: 10px 0;
  box-sizing: border-box;
  position: relative;
}
.fixu-brand {
  display: inline-flex;
  align-items: center;
  flex: 0 0 auto;
  text-decoration: none;
  line-height: 0;
}
.fixu-brand-logo {
  display: block;
  height: 40px;
  width: auto;
  max-width: min(200px, 48vw);
  object-fit: contain;
  object-position: left center;
}

.fixu-main-nav {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px 26px;
  flex: 1 1 auto;
  min-width: 0;
}
.fixu-main-nav a {
  color: var(--fixu-navy);
  font-size: var(--fixu-fs-nav);
  font-weight: 600;
  letter-spacing: 0.005em;
  text-decoration: none;
  padding: 10px 2px;
  white-space: nowrap;
  border-bottom: 2px solid transparent;
  transition: color 0.15s ease, border-color 0.15s ease;
}
.fixu-main-nav a:hover {
  color: var(--fixu-red);
}
.fixu-main-nav a.is-active {
  color: var(--fixu-red);
  border-bottom-color: var(--fixu-red);
}

.fixu-header-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: 0 0 auto;
  min-width: 48px;
  justify-content: flex-end;
}

.fixu-cart-btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 46px;
  height: 46px;
  border-radius: var(--fixu-r-md);
  color: var(--fixu-navy);
  text-decoration: none;
  transition: background 0.15s ease;
  z-index: 1;
}
.fixu-cart-btn:hover {
  background: var(--fixu-bg-soft);
}
.fixu-cart-count {
  position: absolute;
  top: 4px;
  right: 2px;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: 999px;
  background: var(--fixu-red);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  line-height: 18px;
  text-align: center;
  z-index: 2;
}

.fixu-menu-toggle {
  display: none;
  width: 44px;
  height: 44px;
  border: 0;
  background: transparent;
  border-radius: var(--fixu-r-md);
  padding: 0;
  cursor: pointer;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
}
.fixu-menu-toggle span {
  display: block;
  width: 18px;
  height: 2px;
  background: var(--fixu-navy);
  border-radius: 2px;
  transition: transform 0.2s ease, opacity 0.2s ease;
}
.fixu-site-header.is-menu-open .fixu-menu-toggle span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}
.fixu-site-header.is-menu-open .fixu-menu-toggle span:nth-child(2) {
  opacity: 0;
}
.fixu-site-header.is-menu-open .fixu-menu-toggle span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

.fixu-nav-mobile-meta {
  display: none;
}

/* ---------- Mobile drawer ---------- */
@media (max-width: 900px) {
  .fixu-header-inner {
    display: grid;
    grid-template-columns: 44px 1fr 46px;
    align-items: center;
    min-height: 64px;
    padding: 8px 0;
    gap: var(--fixu-sp-3);
  }
  .fixu-menu-toggle {
    display: flex;
    grid-column: 1;
  }
  .fixu-brand {
    grid-column: 2;
    justify-self: center;
  }
  .fixu-brand-logo {
    height: 34px;
    max-width: min(168px, 52vw);
  }
  .fixu-header-actions {
    grid-column: 3;
    justify-self: end;
    min-width: 0;
  }
  .fixu-main-nav {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    position: fixed;
    left: 0;
    right: 0;
    top: var(--fixu-mobile-header-h, var(--fixu-header-h));
    bottom: 0;
    background: var(--fixu-bg);
    border-bottom: 1px solid var(--fixu-border);
    border-radius: 0;
    box-shadow: none;
    padding: 12px 0 max(20px, env(safe-area-inset-bottom));
    z-index: calc(var(--fixu-z-menu-drawer) - 1);
    max-height: none;
    height: auto;
    min-height: 0;
    overflow-y: auto;
    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
    visibility: hidden;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s ease, visibility 0.2s ease;
  }
  .fixu-main-nav.is-open {
    visibility: visible;
    opacity: 1;
    pointer-events: auto;
  }
  .fixu-main-nav.is-open > a {
    padding: 14px var(--fixu-container-pad-sm);
    border-bottom: 1px solid var(--fixu-border);
    font-size: 16px;
  }
  .fixu-main-nav.is-open > a.is-active {
    border-bottom-color: var(--fixu-border);
    background: rgba(227, 6, 19, 0.04);
  }
  .fixu-nav-mobile-meta {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 18px var(--fixu-container-pad-sm) 4px;
    border-top: 1px solid var(--fixu-border);
    margin-top: 8px;
  }
  .fixu-nav-mobile-meta a {
    color: var(--fixu-navy);
    font-weight: 600;
    text-decoration: none;
    font-size: 14.5px;
  }
  .fixu-nav-mobile-meta .fixu-nav-hours {
    color: var(--fixu-text-muted);
    font-size: 13.5px;
    font-weight: 500;
  }
}

/* Backdrop when menu open — fixed viewport layer under header, above page content */
.fixu-menu-backdrop {
  display: block;
  position: fixed;
  inset: 0;
  background: rgba(11, 31, 58, 0.35);
  z-index: var(--fixu-z-menu-backdrop);
  border: 0;
  border-radius: 0;
  padding: 0;
  margin: 0;
  cursor: pointer;
  /* R25.7 — neutralize legacy styles.css global `button { border-radius:99px; transition:all }` */
  min-width: 0;
  min-height: 0;
  width: auto;
  height: auto;
  box-shadow: none;
  color: transparent;
  font-size: 0;
  line-height: 0;
  gap: 0;
  align-items: stretch;
  justify-content: flex-start;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.2s ease, visibility 0.2s ease;
  -webkit-transition: opacity 0.2s ease, visibility 0.2s ease;
}
body.fixu-shell.fixu-menu-open .fixu-menu-backdrop {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}
body.fixu-shell.fixu-menu-open .fixu-topbar-mobile {
  visibility: hidden;
  pointer-events: none;
}

@media (prefers-reduced-motion: reduce) {
  .fixu-menu-backdrop,
  .fixu-main-nav {
    transition: none;
  }
}

/* ---------- Footer (light canonical) ---------- */
.fixu-site-footer {
  background: var(--fixu-bg-soft);
  color: var(--fixu-text);
  margin-top: 0;
  border-top: 1px solid var(--fixu-border);
  font-size: var(--fixu-fs-md);
}
.fixu-footer-main {
  padding: 56px 0 48px;
}
.fixu-footer-grid {
  display: grid;
  grid-template-columns: 1.4fr repeat(4, minmax(0, 1fr));
  gap: 40px 36px;
  align-items: start;
}
.fixu-footer-brand .fixu-brand-logo {
  height: 38px;
  max-width: 190px;
  margin-bottom: 18px;
}
.fixu-footer-brand p {
  margin: 0 0 18px;
  color: var(--fixu-text-soft);
  font-size: 14.5px;
  line-height: 1.6;
  max-width: 34ch;
}
.fixu-footer-socials {
  display: flex;
  gap: 10px;
  list-style: none;
  padding: 0;
  margin: 0;
}
.fixu-footer-socials a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: 999px;
  background: var(--fixu-navy);
  color: #fff;
  text-decoration: none;
  transition: background 0.15s ease;
}
.fixu-footer-socials a:hover {
  background: var(--fixu-red);
}
.fixu-footer-col h4 {
  margin: 0 0 16px;
  font-size: 15px;
  font-weight: 700;
  color: var(--fixu-navy);
  letter-spacing: 0.01em;
  line-height: 1.3;
}
.fixu-footer-col a {
  display: block;
  color: var(--fixu-text-soft);
  text-decoration: none;
  font-size: 14.5px;
  line-height: 1.45;
  padding: 6px 0;
}
.fixu-footer-col a:hover {
  color: var(--fixu-red);
}
.fixu-footer-contact-line {
  display: block;
  color: var(--fixu-text-soft);
  font-size: 14.5px;
  line-height: 1.5;
  padding: 5px 0;
}
.fixu-footer-contact-line a {
  display: inline;
  padding: 0;
  color: var(--fixu-navy);
  font-weight: 600;
}
.fixu-footer-contact-line a:hover {
  color: var(--fixu-red);
}
.fixu-footer-bottom {
  border-top: 1px solid var(--fixu-border);
  padding: 18px 0 22px;
}
.fixu-footer-bottom-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--fixu-sp-5);
  flex-wrap: wrap;
}
.fixu-footer-bottom span,
.fixu-footer-bottom p {
  margin: 0;
  color: var(--fixu-text-muted);
  font-size: 13.5px;
  line-height: 1.4;
}
.fixu-footer-payments img {
  display: block;
  max-height: 30px;
  width: auto;
  max-width: min(280px, 100%);
}

@media (max-width: 1024px) {
  .fixu-footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 32px 28px;
  }
  .fixu-footer-brand {
    grid-column: 1 / -1;
  }
}

@media (max-width: 640px) {
  .fixu-footer-main {
    padding: 40px 0 32px;
  }
  .fixu-footer-grid {
    grid-template-columns: 1fr;
    gap: 28px;
  }
  .fixu-footer-bottom-inner {
    flex-direction: column;
    align-items: flex-start;
  }
}

/* Prevent horizontal overflow on shell pages */
body.fixu-shell,
body.fixu-shell #wrapper {
  max-width: 100%;
}
