/* ===== Marketplace header: logo + search + actions / quick links / departments + nav ===== */

.site-header{position:relative;z-index:100;background:var(--card);border-bottom:1px solid var(--border)}
.hdr-wrap{max-width:var(--page-max,1280px);margin:0 auto;padding:0 var(--page-pad,16px);display:flex;align-items:center;gap:16px}

/* ---------- Row 1 ---------- */
.hdr-main .hdr-wrap{min-height:84px;gap:22px}
.site-logo{display:flex;align-items:center;gap:10px;flex-shrink:0;color:var(--foreground);text-decoration:none;transition:opacity .2s}
.site-logo:hover{opacity:.85}
.site-logo img{max-width:170px;max-height:52px;width:auto;height:auto;object-fit:contain;display:block}
.site-brand-text{font-size:22px;font-weight:700;letter-spacing:-.02em;line-height:1}

/* Search */
/* Capped and auto-margined so it sits centred in the space between the logo
   and the actions, instead of stretching across the whole bar. */
.hdr-search{
  flex:1;min-width:0;max-width:540px;margin:0 auto;
  display:flex;align-items:stretch;height:44px;
  border:2px solid var(--primary);border-radius:8px;overflow:hidden;background:var(--card)
}
.hdr-search-cat{position:relative;flex-shrink:0;display:flex;align-items:center;border-right:1px solid var(--border)}
.hdr-search-cat select{
  appearance:none;-webkit-appearance:none;border:0;background:transparent;font-family:inherit;
  font-size:13.5px;color:var(--foreground);height:100%;padding:0 28px 0 14px;cursor:pointer;max-width:150px
}
.hdr-search-cat select:focus{outline:none}
.hdr-search-cat svg{position:absolute;right:10px;pointer-events:none;color:var(--muted-foreground)}
.hdr-search-input{flex:1;min-width:0;border:0;padding:0 14px;font-family:inherit;font-size:14px;color:var(--foreground);background:transparent}
.hdr-search-input::placeholder{color:var(--muted-foreground)}
.hdr-search-input:focus{outline:none}
.hdr-search-btn{flex-shrink:0;width:56px;border:0;background:var(--primary);color:var(--primary-foreground,#fff);display:flex;align-items:center;justify-content:center;cursor:pointer;transition:background .2s}
.hdr-search-btn:hover{background:var(--primary-hover)}

/* Actions */
.hdr-actions{display:flex;align-items:center;gap:6px;flex-shrink:0}
/* Icon-only buttons; the label lives in the tooltip below. */
.hdr-action{
  position:relative;display:flex;align-items:center;justify-content:center;
  width:44px;height:44px;border-radius:50%;
  color:var(--foreground);text-decoration:none;
  transition:color .2s ease,background .2s ease
}
.hdr-action:hover{color:var(--primary);background:color-mix(in srgb,var(--primary) 9%,transparent)}
.hdr-action:focus-visible{outline:2px solid var(--primary);outline-offset:2px}
/* Full-strength colour: without a text label beside it, a muted icon reads as disabled. */
.hdr-action-ico{position:relative;display:flex;align-items:center;justify-content:center;color:var(--foreground);transition:color .2s}
.hdr-action:hover .hdr-action-ico{color:var(--primary)}

/* Tooltip — CSS rather than title="", which lags ~1s before appearing. */
.hdr-action::after{
  content:attr(data-tip);
  position:absolute;top:calc(100% + 8px);left:50%;
  transform:translateX(-50%) translateY(-4px);
  padding:6px 11px;border-radius:6px;
  background:var(--foreground);color:#fff;
  font-size:11.5px;font-weight:600;letter-spacing:.02em;white-space:nowrap;
  opacity:0;pointer-events:none;z-index:90;
  transition:opacity .18s ease,transform .18s ease
}
.hdr-action::before{
  content:"";position:absolute;top:calc(100% + 3px);left:50%;
  transform:translateX(-50%) translateY(-4px);
  border:5px solid transparent;border-bottom-color:var(--foreground);
  opacity:0;pointer-events:none;z-index:90;
  transition:opacity .18s ease,transform .18s ease
}
.hdr-action:hover::after,.hdr-action:hover::before,
.hdr-action:focus-visible::after,.hdr-action:focus-visible::before{
  opacity:1;transform:translateX(-50%) translateY(0)
}
@media (hover:none){ .hdr-action::after,.hdr-action::before{display:none} }
.hdr-action-count{
  position:absolute;top:-6px;right:-8px;min-width:18px;height:18px;padding:0 5px;
  display:flex;align-items:center;justify-content:center;
  background:var(--accent);color:var(--accent-foreground,#fff);
  font-size:10.5px;font-weight:700;border-radius:999px;line-height:1
}
.hdr-action-count.is-empty{display:none}

/* ---------- Row 0 — top bar: contact + socials ---------- */
.hdr-top{background:var(--foreground);color:rgba(255,255,255,.78)}
.hdr-top .hdr-wrap{justify-content:space-between;min-height:40px;gap:20px}
.hdr-top-contact{display:flex;align-items:center;gap:22px;min-width:0;flex-wrap:wrap}
.hdr-top-contact a{
  display:inline-flex;align-items:center;gap:7px;min-width:0;
  color:rgba(255,255,255,.78);font-size:12.5px;font-weight:500;text-decoration:none;transition:color .2s
}
.hdr-top-contact a:hover{color:#fff}
.hdr-top-contact svg{flex-shrink:0;opacity:.8}
.hdr-top-contact span{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.hdr-top-addr span{max-width:46ch}

.hdr-top-social{display:flex;align-items:center;gap:6px;flex-shrink:0}
.hdr-top-social-label{margin-right:4px;font-size:11.5px;font-weight:700;letter-spacing:.06em;text-transform:uppercase;color:rgba(255,255,255,.55)}
.hdr-social{
  display:inline-flex;align-items:center;justify-content:center;width:28px;height:28px;
  border-radius:50%;background:rgba(255,255,255,.1);color:rgba(255,255,255,.85);
  text-decoration:none;transition:background .2s,color .2s,transform .2s
}
.hdr-social:hover{color:#fff;transform:translateY(-2px)}
/* Placeholder icons: same shape, slightly muted, no pointer affordance. */
.hdr-social.is-empty{color:rgba(255,255,255,.5);cursor:default}
.hdr-social.is-empty:hover{background:rgba(255,255,255,.1);color:rgba(255,255,255,.5);transform:none}
.hdr-social-facebook:hover{background:#1877f2}
.hdr-social-instagram:hover{background:linear-gradient(45deg,#f09433,#dc2743,#bc1888)}
.hdr-social-tiktok:hover{background:#000}
.hdr-social-youtube:hover{background:#ff0000}
.hdr-social-whatsapp:hover{background:#25d366}

/* ---------- Row 3 — primary nav ---------- */
.hdr-bar{background:var(--foreground)}
.hdr-bar .hdr-wrap{gap:0;align-items:stretch;min-height:52px}

.hdr-nav{display:none;align-items:center;gap:4px;padding-left:14px;min-width:0;flex:1}
.hdr-nav a{
  position:relative;display:inline-flex;align-items:center;height:40px;padding:0 18px;
  color:rgba(255,255,255,.86);font-size:14px;font-weight:600;letter-spacing:.03em;
  text-transform:uppercase;text-decoration:none;border-radius:6px;
  transition:background .2s,color .2s;white-space:nowrap
}
.hdr-nav a:hover{color:#fff;background:rgba(255,255,255,.1)}
.hdr-nav a.current-menu-item,
.hdr-nav li.current-menu-item > a{background:var(--primary);color:var(--primary-foreground,#fff)}
@media (min-width:1024px){ .hdr-nav{display:flex} }

/* ---------- Mobile ---------- */
.menu-toggle{
  display:inline-flex;align-items:center;justify-content:center;flex-shrink:0;
  width:42px;height:42px;padding:0;border:0;background:var(--muted);border-radius:8px;
  color:var(--foreground);transition:background .2s,transform .2s
}
.menu-toggle:hover{background:var(--border);transform:scale(1.05)}
@media (min-width:1024px){ .menu-toggle{display:none} }

@media (max-width:1023px){
  .hdr-main .hdr-wrap{min-height:64px;flex-wrap:wrap;gap:12px;padding-top:10px;padding-bottom:10px}
  .site-logo{order:1}
  .menu-toggle{order:2;margin-left:auto}
  .hdr-actions{order:3;gap:2px}
  .hdr-search{order:4;flex-basis:100%;max-width:none;margin:0;height:42px}
  .hdr-search-cat{display:none}
  .hdr-search-btn{width:52px}
  /* Top bar keeps the phone only — email and the full address are too long
     for a phone-width strip and push the socials off screen. */
  .hdr-top .hdr-wrap{min-height:36px;gap:12px}
  .hdr-top-contact a:not(:first-child){display:none}
  .hdr-top-social-label{display:none}
  .hdr-bar .hdr-wrap{padding-left:0;padding-right:0}
}

/* ---------- Mobile drawer ---------- */
.drawer{position:fixed;inset:0;z-index:200;display:none}
.drawer.open{display:block}
.drawer-overlay{position:absolute;inset:0;background:rgba(0,0,0,.45);backdrop-filter:blur(4px)}
.drawer-panel{
  position:absolute;top:0;left:0;bottom:0;width:284px;
  background:var(--background);padding:24px;overflow-y:auto;
  box-shadow:var(--shadow-lg);animation:slideIn .28s cubic-bezier(.4,0,.2,1)
}
@keyframes slideIn{from{transform:translateX(-100%)}to{transform:translateX(0)}}
.drawer h3{margin:0 0 18px;padding-bottom:12px;font-size:18px;font-weight:700;border-bottom:1px solid var(--border)}
.drawer a{display:block;padding:11px 14px;border-radius:8px;font-size:15px;font-weight:500;transition:background .2s,color .2s,transform .2s}
.drawer a:hover{background:var(--muted);color:var(--primary);transform:translateX(4px)}
.drawer .section-label{padding:18px 14px 6px;font-size:12px;font-weight:700;letter-spacing:.05em;text-transform:uppercase;color:var(--muted-foreground)}
