/* Layout only: preserve the existing light/dark header colours. */
@media (min-width: 992px) {
 body .site-header > .container { max-width: 1440px; width: 100%; padding-left: 24px; padding-right: 24px; }
 body .site-header .header-container { display: grid; grid-template-columns: 200px minmax(0,1fr) auto; align-items: center; gap: 12px; padding: 12px 0; }
 body .site-header .header-logo { width: 200px; min-width: 200px; flex: none; grid-column: 1; grid-row: 1; box-sizing: border-box; }
 body .site-header .header-logo img, body .site-header .header-logo .site-logo { width: 100%; max-width: 100%; height: auto; max-height: 56px; object-fit: contain; }
 body .site-header .header-nav { grid-column: 2; grid-row: 1; order: initial; flex-basis: auto; display: flex; flex-wrap: wrap; justify-content: center; gap: 2px; }
 body .site-header .header-nav .nav-link { font-size: 16px; padding: 8px 6px; }
 body .site-header .header-actions { grid-column: 3; grid-row: 1; justify-self: end; }
}
@media (min-width: 1200px) {
 body .site-header .header-container { grid-template-columns: 240px minmax(0,1fr) auto; }
 body .site-header .header-logo { width: 240px; min-width: 240px; }
}
/* Dark cart panels must not retain the light-only shop-unified backgrounds. */
body.dark-mode .cart-page-wrapper { background: #0d1117; }
body.dark-mode .cart-page-wrapper .empty-cart-container,
body.dark-mode .cart-page-wrapper .card { background: #161b22; border-color: #30363d; }
body.dark-mode .cart-page-wrapper .empty-cart-title { color: #f3f4f6; }
body.dark-mode .cart-page-wrapper .empty-cart-text { color: #cbd5e1; }
body.dark-mode .cart-page-wrapper .card h1.h4 { color: #f3f4f6 !important; }
body.dark-mode .cart-page-wrapper .breadcrumb-modern { background: #161b22; }
body.dark-mode .cart-page-wrapper .breadcrumb-modern .breadcrumb { background: transparent; margin-bottom: 0; }
body.dark-mode .cart-page-wrapper .breadcrumb-modern a,
body.dark-mode .cart-page-wrapper .breadcrumb-item.active { color: #cbd5e1; }
body.dark-mode .cart-page-wrapper .btn-continue-shopping { color: #fca5a5; }

/* Identical desktop geometry in both themes: reserve logo padding in light mode too. */
@media (min-width: 992px) {
 body .site-header .header-container { min-height: 80px; box-sizing: border-box; }
 body .site-header .header-logo,
 body.dark-mode .site-header .header-logo {
  display: flex; align-items: center; justify-content: center;
  height: 56px; padding: 6px; box-sizing: border-box;
 }
 body .site-header .header-logo .site-logo,
 body.dark-mode .site-header .header-logo .site-logo {
  display: block; width: 100%; height: auto; max-height: 44px; object-fit: contain;
 }
}
body.dark-mode .site-header .header-nav .nav-link { color: #e2e8f0; }
body.dark-mode .site-header .header-nav .nav-link:hover,
body.dark-mode .site-header .header-nav .nav-link.active { color: #ff929a; }
/* Bootstrap bg-white uses !important; override it only inside the dark cart. */
body.dark-mode .cart-page-wrapper .breadcrumb-modern .breadcrumb.bg-white {
 background-color: transparent !important; box-shadow: none !important;
}
body.dark-mode .cart-page-wrapper .breadcrumb-modern .breadcrumb-item::before { color: #94a3b8; }

/* Bootstrap text-muted is important: preserve readable dark-cart navigation. */
body.dark-mode .cart-page-wrapper .breadcrumb-modern a.text-muted,
body.dark-mode .cart-page-wrapper .breadcrumb-modern a.text-muted .bi {
 color: #cbd5e1 !important;
}
body.dark-mode .cart-page-wrapper .breadcrumb-modern a.text-muted:hover,
body.dark-mode .cart-page-wrapper .breadcrumb-modern a.text-muted:focus-visible {
 color: #ffffff !important;
}

/* Keep the cart home link readable in every interaction state. */
body.dark-mode .cart-page-wrapper .breadcrumb-modern .breadcrumb-item a.text-muted,
body.dark-mode .cart-page-wrapper .breadcrumb-modern .breadcrumb-item a.text-muted:visited,
body.dark-mode .cart-page-wrapper .breadcrumb-modern .breadcrumb-item a.text-muted .bi {
 color: #e2e8f0 !important; opacity: 1;
}
