/* ==========================================================================
   HEADER IMPROVEMENTS — swiezopalona.pl  |  v4.0
   ========================================================================== */

/* 1. UTILITY BAR */
.top-menu-contact{display:flex;align-items:center;gap:8px;font-size:12px;margin:0;list-style:none;white-space:nowrap}
.top-contact-link{display:inline-flex;align-items:center;gap:4px;color:#555;text-decoration:none;transition:color .2s;font-size:12px;text-transform:none}
.top-contact-link:hover{color:#157F38;text-decoration:none}
.top-contact-link svg{flex-shrink:0;display:block}
.top-contact-sep{color:#ddd;margin:0 2px;user-select:none}
.top-contact-hours{color:#888;font-size:11px}
@media(max-width:1024px){.top-menu-contact{display:none}}
@media(min-width:1025px) and (max-width:1300px){.top-menu-contact{font-size:11px;gap:5px}.top-contact-hours{display:none}}

/* 2. TRUST BAR */
.trust-bar{background:#f9faf9;border-top:1px solid #f0f0f0;border-bottom:1px solid #eaeaea;padding:6px 0}
.trust-bar-inner{display:flex;align-items:center;justify-content:center;gap:8px;font-size:12px;color:#555;font-family:-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Inter",sans-serif;white-space:nowrap;flex-wrap:wrap}
.trust-item{display:inline-flex;align-items:center;gap:4px;color:#444;text-decoration:none}
a.trust-item:hover{color:#157F38}
.trust-count{color:#888}
.trust-divider{color:#ccc;margin:0 4px;user-select:none}
@media(max-width:768px){.trust-bar{padding:5px 15px}.trust-bar-inner{font-size:11px;gap:4px}.trust-divider{margin:0 2px}}
@media(max-width:450px){.trust-bar-inner{font-size:10px}}

/* 3. STICKY NAVBAR */
.sticky-search-li,.sticky-cart-li{display:none!important}
@media(min-width:992px){
  .main-navbar.is-sticky .sticky-search-li,.main-navbar.is-sticky .sticky-cart-li{display:flex!important;align-items:center}
  .main-navbar ul.level-1-desktop>li.sticky-search-li,.main-navbar ul.level-1-desktop>li.sticky-cart-li{flex-grow:0;flex-shrink:0}
  .sticky-search-btn{display:flex;align-items:center;justify-content:center;width:42px;height:42px;background:none;border:1px solid #495057;border-radius:5px;cursor:pointer;padding:0;transition:background .2s;margin:0 4px}
  .sticky-search-btn svg{display:block}
  .sticky-search-btn:hover{background:#495057}
  .sticky-search-btn:hover svg{stroke:#fff}
  .sticky-cart-link{display:flex;align-items:center;gap:6px;padding:6px 14px!important;margin:0 4px;background:#cf0a2c!important;border-radius:5px;color:#fff!important;text-decoration:none;font-size:13px!important;font-weight:600;white-space:nowrap;transition:background .2s;border-right:none!important}
  .sticky-cart-link:hover{background:#e76f51!important;color:#fff!important}
  .sticky-cart-link svg{flex-shrink:0;display:block}
  .sticky-cart-amount{font-weight:700}
}

/* ==========================================================================
   4. MINI PODGLĄD KOSZYKA
   ========================================================================== */

#column-cart {
  position: relative;
}

.cart-mini-preview {
  display: none;
  position: absolute;
  top: 100%;
  right: 0;
  width: 310px;
  background: #fff;
  border-radius: 10px;
  box-shadow: 0 8px 30px rgba(0,0,0,0.15);
  border: 1px solid #e5e7eb;
  z-index: 9999;
  padding: 0;
  overflow: hidden;
  margin-top: 4px;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Inter", sans-serif;
}

@media (min-width: 992px) {
  #column-cart:hover .cart-mini-preview {
    display: block;
  }
}

/* Strzałka */
.cmp-arrow {
  position: absolute;
  top: -6px;
  right: 28px;
  width: 12px;
  height: 12px;
  background: #fff;
  border-left: 1px solid #e5e7eb;
  border-top: 1px solid #e5e7eb;
  transform: rotate(45deg);
  z-index: 1;
}

/* --- Produkty --- */
.cmp-products {
  padding: 12px 14px 4px;
  max-height: 200px;
  overflow-y: auto;
}

.cmp-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 7px 0;
  border-bottom: 1px solid #f0f0f0;
}

.cmp-item:last-child {
  border-bottom: none;
}

.cmp-item img {
  width: 44px !important;
  height: 44px !important;
  border-radius: 6px;
  object-fit: cover !important;
  flex-shrink: 0;
  background: #f0ece6;
  display: block !important;
}

.cmp-item-info {
  flex: 1;
  min-width: 0;
}

.cmp-item-name {
  display: block;
  font-size: 12px;
  font-weight: 500;
  color: #333;
  line-height: 1.3;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.cmp-item-meta {
  display: block;
  font-size: 11px;
  color: #888;
  margin-top: 1px;
}

.cmp-more {
  font-size: 11px;
  color: #888;
  text-align: center;
  padding: 4px 0;
}

/* Fallback */
.cmp-summary {
  padding: 14px;
  text-align: center;
}

.cmp-summary-text {
  font-size: 13px;
  font-weight: 600;
  color: #333;
}

/* --- Pasek dostawy (kopia stylu z modal-delivery-bar) --- */
.cmp-delivery {
  background: #f5f5f5;
  border-radius: 10px;
  padding: 12px 14px;
  margin: 0 10px;
  border-top: none;
}

.cmp-delivery-text {
  font-size: 13px;
  color: #333;
  margin: 0 0 8px 0;
  line-height: 1.4;
}

.cmp-delivery-text strong {
  color: #111;
}

.cmp-delivery-text a {
  color: #e07b39;
  font-weight: 600;
  text-decoration: none;
}

.cmp-delivery-text a:hover {
  text-decoration: underline;
}

.cmp-bar-track {
  background: #ddd;
  border-radius: 99px;
  height: 7px;
  overflow: hidden;
  margin-bottom: 5px;
}

.cmp-bar-fill {
  background: linear-gradient(90deg, #5a9e4b, #8bc34a);
  height: 100%;
  border-radius: 99px;
  transition: width 0.3s ease;
}

.cmp-bar-labels {
  display: flex;
  justify-content: space-between;
  font-size: 11px;
  color: #999;
}

/* Darmowa dostawa OK */
.cmp-delivery-ok {
  background: #4caf50;
  color: #fff;
  font-size: 13px;
  font-weight: 600;
  padding: 10px 14px;
  text-align: center;
  border-top: 1px solid #f0f0f0;
}

/* --- Wartość koszyka (wzorowana na modal-cart-total) --- */
.cmp-total {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 14px;
  border-top: 1px solid #f0f0f0;
  border-bottom: 1px solid #f0f0f0;
  font-size: 13px;
  color: #555;
}

.cmp-total strong {
  font-size: 16px;
  font-weight: 700;
  color: #111;
}

/* --- Przycisk --- */
.cmp-footer {
  padding: 10px 14px 12px;
}

.cmp-btn {
  display: block;
  text-align: center;
  padding: 10px;
  background: #2e7d32;
  color: #fff !important;
  border-radius: 8px;
  font-weight: 700;
  font-size: 13px;
  text-decoration: none !important;
  transition: background 0.2s;
}

.cmp-btn:hover {
  background: #1b5e20;
  color: #fff !important;
}

/* Mobile — nigdy */
@media (max-width: 991px) {
  .cart-mini-preview {
    display: none !important;
  }
}

/* ==========================================================================
   BOTTOM MOBILE NAV — NOWE STYLE (5 elementów)
   Dodaj na końcu header-improvements.css
   ========================================================================== */

/* Badge koszyka */
.cart-badge {
  display: none;
  position: absolute;
  top: -4px;
  right: -8px;
  min-width: 18px;
  height: 18px;
  padding: 0 4px;
  font-size: 10px;
  font-weight: 700;
  line-height: 18px;
  text-align: center;
  color: #fff;
  background: #cf0a2c;
  border-radius: 99px;
  box-sizing: border-box;
  align-items: center;
  justify-content: center;
}

.bottom-nav-cart .icon {
  position: relative;
}

/* Promocje — wyróżniona ikona */
.bottom-nav-promo .icon svg {
  fill: #cf0a2c !important;
}

.bottom-nav-promo .label {
  color: #cf0a2c !important;
  font-weight: 700;
}

/* Szukaj trigger — cursor pointer */
#mobile-search-trigger {
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}