/* ============================================================
   Cosmos T&S – Shop (Headless) – Usklađen sa cosmos.rs
   Primarna: #ff8d1e | Font: Montserrat | Body: #fff
   ============================================================ */

:root {
  --cosmos-orange:      #ff8d1e;
  --cosmos-orange-dark: #ff6600;
  --cosmos-dark:        #242424;
  --cosmos-text:        #333333;
  --cosmos-border:      #e8e8e8;
  --cosmos-bg:          #f7f7f7;
  --cosmos-white:       #ffffff;
  --cosmos-font:        'Montserrat', Arial, Helvetica, sans-serif;
}

/* ── Reset za shop ── */
.shop-page * { box-sizing: border-box; }
.shop-page { font-family: var(--cosmos-font); background: var(--cosmos-white); color: var(--cosmos-text); margin: 0; }

/* ════════════════════════════════════════════════════════════
   HEADER – identičan cosmos.rs
   ════════════════════════════════════════════════════════════ */

/* Override naš tamni navbar za shop stranicu */
.shop-page .navbar {
  position: sticky !important;
  top: 0;
  background: var(--cosmos-white) !important;
  box-shadow: none !important;
  backdrop-filter: none !important;
  z-index: 1000;
  transition: none;
}
.shop-page .navbar.scrolled {
  background: var(--cosmos-white) !important;
  box-shadow: 0 2px 8px rgba(0,0,0,0.08) !important;
}

/* Top bar – adresa i kontakt */
.shop-topbar {
  background: var(--cosmos-white);
  border-bottom: 1px solid var(--cosmos-border);
  height: 30px;
  display: flex;
  align-items: center;
}
.shop-topbar-inner {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 24px;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.shop-topbar-text {
  font-size: 12px;
  font-weight: 500;
  color: #555;
}
.shop-topbar-text a { color: #555; text-decoration: none; }
.shop-topbar-text a:hover { color: var(--cosmos-orange); }
.shop-topbar-social { display: flex; gap: 8px; }
.shop-topbar-social a { color: #999; font-size: 12px; transition: color 0.2s; }
.shop-topbar-social a:hover { color: var(--cosmos-orange); }

/* Header glavna linija – logo + search + cart */
.shop-header-main {
  background: var(--cosmos-white);
  border-bottom: 1px solid var(--cosmos-border);
  height: 91px;
  display: flex;
  align-items: center;
}
.shop-header-main-inner {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 24px;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}
.shop-header-logo img {
  height: 54px;
  width: auto;
  display: block;
}
.shop-header-search {
  flex: 1;
  max-width: 520px;
  display: flex;
  align-items: center;
  border: 2px solid var(--cosmos-border);
  border-radius: 4px;
  overflow: hidden;
  transition: border-color 0.2s;
}
.shop-header-search:focus-within { border-color: var(--cosmos-orange); }
.shop-header-search input {
  flex: 1;
  border: none;
  outline: none;
  padding: 10px 14px;
  font-size: 13px;
  font-family: var(--cosmos-font);
  color: var(--cosmos-dark);
  background: transparent;
}
.shop-header-search input::placeholder { color: #aaa; }
.shop-header-search button {
  background: var(--cosmos-orange);
  border: none;
  padding: 10px 18px;
  cursor: pointer;
  color: #fff;
  display: flex;
  align-items: center;
  transition: background 0.2s;
}
.shop-header-search button:hover { background: var(--cosmos-orange-dark); }
.shop-header-search button svg { width: 18px; height: 18px; }

.shop-header-actions { display: flex; align-items: center; gap: 16px; }
.shop-header-phone {
  font-size: 13px;
  font-weight: 600;
  color: var(--cosmos-dark);
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
}
.shop-header-phone:hover { color: var(--cosmos-orange); }
.shop-header-phone svg { width: 16px; height: 16px; color: var(--cosmos-orange); }

/* Nav bar – kategorije */
.shop-navbar {
  background: var(--cosmos-white);
  border-bottom: 1px solid var(--cosmos-border);
  height: 53px;
  position: sticky;
  top: 0;
  z-index: 999;
  display: flex;
  align-items: center;
}
.shop-navbar-inner {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 24px;
  width: 100%;
  display: flex;
  align-items: center;
  gap: 0;
}
.shop-nav-link {
  font-size: 14px;
  font-weight: 600;
  color: var(--cosmos-dark);
  text-decoration: none;
  padding: 0 14px;
  height: 53px;
  display: flex;
  align-items: center;
  gap: 5px;
  position: relative;
  transition: color 0.2s;
  white-space: nowrap;
}
.shop-nav-link:hover { color: var(--cosmos-orange); }
.shop-nav-link.active { color: var(--cosmos-orange); }
.shop-nav-link.active::after {
  content: '';
  position: absolute;
  bottom: 0; left: 14px; right: 14px;
  height: 2px;
  background: var(--cosmos-orange);
}
.shop-nav-link svg { width: 12px; height: 12px; transition: transform 0.2s; }

/* Mega menu dropdown */
.shop-nav-item { position: relative; }
.shop-nav-item:hover > .shop-mega { opacity: 1; visibility: visible; transform: translateY(0); }
.shop-mega {
  position: absolute;
  top: 100%;
  left: 0;
  background: var(--cosmos-white);
  border: 1px solid var(--cosmos-border);
  border-top: 3px solid var(--cosmos-orange);
  box-shadow: 0 8px 30px rgba(0,0,0,0.1);
  padding: 16px;
  min-width: 220px;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-6px);
  transition: opacity 0.2s, transform 0.2s, visibility 0.2s;
  z-index: 1000;
}
.shop-mega::before {
  content: '';
  position: absolute;
  top: -10px; left: 0; right: 0;
  height: 10px;
}
.shop-mega a {
  display: block;
  padding: 7px 10px;
  font-size: 13px;
  font-weight: 500;
  color: var(--cosmos-dark);
  text-decoration: none;
  border-radius: 4px;
  transition: background 0.15s, color 0.15s;
}
.shop-mega a:hover {
  background: rgba(255,141,30,0.08);
  color: var(--cosmos-orange);
}

/* Hamburger */
.shop-hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  padding: 8px;
  border: none;
  background: transparent;
}
.shop-hamburger span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--cosmos-dark);
  border-radius: 2px;
  transition: 0.2s;
}

/* ════════════════════════════════════════════════════════════
   SHOP LAYOUT
   ════════════════════════════════════════════════════════════ */
.shop-wrap {
  display: grid;
  grid-template-columns: 280px 1fr;
  max-width: 1280px;
  margin: 0 auto;
  padding: 24px;
  gap: 24px;
  min-height: calc(100vh - 174px);
}

/* ── SIDEBAR ── */
.shop-sidebar {
  position: sticky;
  top: 53px;
  height: calc(100vh - 77px);
  overflow-y: auto;
  padding-right: 4px;
}
.shop-sidebar::-webkit-scrollbar { width: 3px; }
.shop-sidebar::-webkit-scrollbar-thumb { background: #ddd; border-radius: 2px; }

.sidebar-section { margin-bottom: 28px; }

.sidebar-title {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #999;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--cosmos-border);
  margin-bottom: 8px;
}

/* Category tree */
.cat-tree-link {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 6px 10px;
  font-size: 13px;
  font-weight: 500;
  color: var(--cosmos-text);
  text-decoration: none;
  cursor: pointer;
  border-left: 3px solid transparent;
  transition: background 0.15s, color 0.15s, border-color 0.15s;
  border-radius: 0 4px 4px 0;
}
.cat-tree-link:hover {
  color: var(--cosmos-orange);
  background: rgba(255,141,30,0.06);
}
.cat-tree-link.active {
  color: var(--cosmos-orange);
  background: rgba(255,141,30,0.08);
  border-left-color: var(--cosmos-orange);
  font-weight: 600;
}
.cat-tree-link .cat-icon { font-size: 0.9rem; flex-shrink: 0; }
.cat-tree-link .cat-name { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cat-tree-link .cat-count { font-size: 11px; color: #bbb; flex-shrink: 0; }
.cat-tree-link .cat-arrow { width: 10px; height: 10px; flex-shrink: 0; color: #ccc; transition: transform 0.2s; }
.cat-tree-link.open .cat-arrow { transform: rotate(90deg); }

.cat-depth-1 .cat-tree-link { padding-left: 24px; font-size: 13px; }
.cat-depth-2 .cat-tree-link { padding-left: 38px; font-size: 12px; font-weight: 400; }

.cat-children { overflow: hidden; max-height: 0; transition: max-height 0.3s ease; }
.cat-children.open { max-height: 2000px; }

/* Filteri */
.filter-group { padding: 10px 0 0; }
.filter-label { display: block; font-size: 11px; font-weight: 700; color: #999; text-transform: uppercase; letter-spacing: 0.08em; margin-bottom: 8px; }
.filter-check { display: flex; align-items: center; gap: 8px; font-size: 13px; color: #444; cursor: pointer; }
.filter-check input { accent-color: var(--cosmos-orange); }
.filter-select {
  width: 100%; padding: 8px 10px;
  border: 1px solid var(--cosmos-border);
  border-radius: 4px;
  font-size: 13px;
  color: var(--cosmos-dark);
  background: var(--cosmos-white);
  font-family: var(--cosmos-font);
  cursor: pointer;
}
.filter-select:focus { outline: none; border-color: var(--cosmos-orange); }
.btn-outline { background: transparent; border: 1px solid var(--cosmos-border); border-radius: 4px; padding: 8px; font-size: 12px; cursor: pointer; font-family: var(--cosmos-font); color: #666; width: 100%; margin-top: 8px; transition: border-color 0.2s, color 0.2s; }
.btn-outline:hover { border-color: var(--cosmos-orange); color: var(--cosmos-orange); }

/* ── MAIN CONTENT ── */
.shop-main { min-width: 0; }

/* Breadcrumb */
.shop-breadcrumb {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  color: #999;
  margin-bottom: 16px;
  flex-wrap: wrap;
}
.shop-breadcrumb a { color: #999; text-decoration: none; transition: color 0.2s; }
.shop-breadcrumb a:hover { color: var(--cosmos-orange); }
.shop-breadcrumb .bc-sep { color: #ccc; font-size: 11px; }
.shop-breadcrumb .bc-current { color: var(--cosmos-dark); font-weight: 500; }

/* Category header */
.shop-cat-header {
  margin-bottom: 20px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--cosmos-border);
}
.shop-cat-header h1 {
  font-size: 22px;
  font-weight: 700;
  color: var(--cosmos-dark);
  margin: 0 0 4px;
}
.shop-cat-count { font-size: 13px; color: #999; margin: 0; }

/* Subcategory grid */
.subcat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 10px;
  margin-bottom: 24px;
}
.subcat-card {
  background: var(--cosmos-white);
  border: 1px solid var(--cosmos-border);
  border-radius: 4px;
  padding: 14px 10px;
  text-align: center;
  cursor: pointer;
  text-decoration: none;
  display: block;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.subcat-card:hover { border-color: var(--cosmos-orange); box-shadow: 0 2px 12px rgba(0,0,0,0.06); }
.subcat-card .sc-icon { font-size: 1.6rem; display: block; margin-bottom: 6px; }
.subcat-card .sc-name { font-size: 12px; font-weight: 600; color: var(--cosmos-dark); line-height: 1.3; }
.subcat-card .sc-count { font-size: 11px; color: #aaa; margin-top: 3px; }

/* Toolbar */
.shop-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
  padding: 10px 14px;
  background: var(--cosmos-bg);
  border: 1px solid var(--cosmos-border);
  border-radius: 4px;
}
.toolbar-count { font-size: 13px; color: #666; }
.toolbar-right { display: flex; align-items: center; gap: 6px; }
.view-btn {
  padding: 6px;
  border: 1px solid var(--cosmos-border);
  border-radius: 4px;
  background: var(--cosmos-white);
  cursor: pointer;
  color: #aaa;
  display: flex;
  align-items: center;
  transition: border-color 0.15s, color 0.15s;
}
.view-btn svg { width: 15px; height: 15px; }
.view-btn.active, .view-btn:hover { border-color: var(--cosmos-orange); color: var(--cosmos-orange); }

/* ── PRODUCT GRID – identičan cosmos.rs ── */
.products-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
  gap: 1px;
  background: var(--cosmos-border);
  border: 1px solid var(--cosmos-border);
}
.products-grid.list-view { grid-template-columns: 1fr; }

/* Product card – woodmart stil */
.product-card {
  background: var(--cosmos-white);
  padding: 15px;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  transition: box-shadow 0.2s;
  position: relative;
}
.product-card:hover {
  box-shadow: 0 4px 20px rgba(0,0,0,0.1);
  z-index: 1;
}

/* Image area */
.product-card-img {
  position: relative;
  aspect-ratio: 1;
  overflow: hidden;
  background: var(--cosmos-white);
  margin-bottom: 10px;
}
.product-card-img img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  transition: transform 0.3s;
}
.product-card:hover .product-card-img img { transform: scale(1.05); }

/* Badge */
.product-card-badge {
  position: absolute;
  top: 8px;
  left: 8px;
  background: var(--cosmos-orange);
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  padding: 2px 6px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  z-index: 2;
}
.product-card-badge.sale { background: #e74c3c; }

/* Body */
.product-card-body { flex: 1; display: flex; flex-direction: column; }
.product-card-brand {
  font-size: 11px;
  font-weight: 700;
  color: var(--cosmos-orange);
  text-transform: uppercase;
  letter-spacing: 0.07em;
  margin-bottom: 4px;
}
.product-card-name {
  font-size: 14px;
  font-weight: 500;
  color: #333;
  line-height: 1.4;
  margin-bottom: 6px;
  flex: 1;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.product-card-sku { font-size: 11px; color: #bbb; margin-bottom: 6px; font-family: monospace; }

/* Stock */
.stock-badge {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  font-size: 11px;
  font-weight: 600;
  margin-bottom: 6px;
}
.stock-badge.in-stock { color: #5a9a5a; }
.stock-badge.out-stock { color: #c0392b; }

/* Footer kartice */
.product-card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-top: auto;
  padding-top: 10px;
  border-top: 1px solid var(--cosmos-border);
}

/* Price – woodmart stil */
.product-card-price { font-size: 16px; font-weight: 700; color: var(--cosmos-dark); }
.product-card-price.has-sale { color: #e74c3c; }
.product-card-price .old-price {
  display: block;
  font-size: 12px;
  font-weight: 400;
  color: #aaa;
  text-decoration: line-through;
}
.product-card-price.no-price { font-size: 12px; color: #999; font-weight: 400; }

/* Button – identičan cosmos.rs add to cart */
.product-card-btn {
  flex-shrink: 0;
  background: var(--cosmos-orange);
  color: #fff;
  border: none;
  padding: 8px 14px;
  font-size: 13px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  cursor: pointer;
  font-family: var(--cosmos-font);
  transition: background 0.2s;
  white-space: nowrap;
  border-radius: 0;
}
.product-card-btn:hover { background: var(--cosmos-orange-dark); }

/* List view */
.products-grid.list-view .product-card { flex-direction: row; gap: 16px; padding: 12px; }
.products-grid.list-view .product-card-img { width: 120px; flex-shrink: 0; aspect-ratio: 1; margin-bottom: 0; }
.products-grid.list-view .product-card-body { padding: 0; }

/* ── Loading & Empty ── */
.shop-loading { text-align: center; padding: 60px 20px; color: #999; }
.loading-spinner {
  width: 36px; height: 36px;
  border: 3px solid #f0f0f0;
  border-top-color: var(--cosmos-orange);
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
  margin: 0 auto 14px;
}
@keyframes spin { to { transform: rotate(360deg); } }

.shop-empty { text-align: center; padding: 60px 20px; color: #999; }
.shop-empty .empty-icon { font-size: 2.5rem; margin-bottom: 12px; }
.shop-empty h3 { color: #555; font-size: 16px; margin-bottom: 6px; }

/* ── Pagination – woodmart stil ── */
.shop-pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin-top: 32px;
  flex-wrap: wrap;
}
.page-btn {
  min-width: 36px; height: 36px;
  padding: 0 10px;
  border: 1px solid var(--cosmos-border);
  background: var(--cosmos-white);
  color: #555;
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.15s;
  font-family: var(--cosmos-font);
  border-radius: 4px;
}
.page-btn:hover { border-color: var(--cosmos-orange); color: var(--cosmos-orange); }
.page-btn.active { background: var(--cosmos-orange); border-color: var(--cosmos-orange); color: #fff; font-weight: 700; }
.page-btn:disabled { opacity: 0.4; cursor: not-allowed; }

/* ── Welcome / Top kategorije ── */
.shop-welcome { padding: 8px 0; }
.welcome-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 10px;
}
.welcome-cat-card {
  background: var(--cosmos-white);
  border: 1px solid var(--cosmos-border);
  border-radius: 4px;
  padding: 20px 16px;
  text-align: center;
  cursor: pointer;
  text-decoration: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.welcome-cat-card:hover { border-color: var(--cosmos-orange); box-shadow: 0 3px 14px rgba(0,0,0,0.07); }
.welcome-cat-icon { font-size: 2rem; line-height: 1; }
.welcome-cat-name { font-size: 13px; font-weight: 700; color: var(--cosmos-dark); text-transform: uppercase; letter-spacing: 0.04em; }
.welcome-cat-count { font-size: 12px; color: #aaa; }

/* ── Product modal ── */
.product-modal-overlay {
  position: fixed; inset: 0;
  background: rgba(0,0,0,0.55);
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}
.product-modal {
  background: var(--cosmos-white);
  max-width: 820px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  position: relative;
  border-radius: 4px;
}
.modal-close {
  position: absolute; top: 14px; right: 14px;
  width: 32px; height: 32px;
  border: 1px solid var(--cosmos-border);
  background: var(--cosmos-white);
  border-radius: 4px;
  font-size: 1.1rem; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  color: #555; z-index: 10; transition: border-color 0.2s;
}
.modal-close:hover { border-color: var(--cosmos-orange); color: var(--cosmos-orange); }
.modal-body { display: grid; grid-template-columns: 1fr 1fr; }
.modal-img-col {
  background: var(--cosmos-bg);
  padding: 24px;
  display: flex; align-items: center; justify-content: center;
  min-height: 300px;
}
.modal-img-col img { width: 100%; max-height: 320px; object-fit: contain; }
.modal-info-col { padding: 28px; display: flex; flex-direction: column; gap: 10px; }
.modal-brand { font-size: 11px; font-weight: 700; color: var(--cosmos-orange); text-transform: uppercase; letter-spacing: 0.1em; }
.modal-title { font-size: 18px; font-weight: 700; color: var(--cosmos-dark); line-height: 1.35; }
.modal-sku { font-size: 12px; color: #bbb; font-family: monospace; }
.modal-price { font-size: 22px; font-weight: 800; color: var(--cosmos-dark); }
.modal-price.has-sale { color: #e74c3c; }
.modal-price .old-price { font-size: 14px; color: #bbb; text-decoration: line-through; font-weight: 400; margin-left: 8px; }
.modal-desc { font-size: 13px; color: #555; line-height: 1.6; border-top: 1px solid var(--cosmos-border); padding-top: 10px; max-height: 160px; overflow-y: auto; }
.modal-actions { display: flex; gap: 10px; margin-top: auto; padding-top: 14px; border-top: 1px solid var(--cosmos-border); }
.modal-btn-primary {
  flex: 1; padding: 12px;
  background: var(--cosmos-orange); color: #fff; border: none;
  font-size: 13px; font-weight: 700; text-transform: uppercase;
  letter-spacing: 0.04em; cursor: pointer; font-family: var(--cosmos-font);
  transition: background 0.2s; border-radius: 0;
}
.modal-btn-primary:hover { background: var(--cosmos-orange-dark); }
.modal-btn-outline {
  padding: 12px 16px;
  border: 1px solid var(--cosmos-border); background: transparent;
  font-size: 13px; font-weight: 600; cursor: pointer;
  font-family: var(--cosmos-font); color: #555; border-radius: 0;
  transition: border-color 0.2s, color 0.2s;
}
.modal-btn-outline:hover { border-color: var(--cosmos-orange); color: var(--cosmos-orange); }

/* Mobile nav drawer */
.mobile-nav {
  position: fixed; inset: 0;
  background: var(--cosmos-dark);
  z-index: 2000;
  padding: 70px 24px 40px;
  transform: translateX(100%);
  transition: transform 0.3s cubic-bezier(.4,0,.2,1);
  overflow-y: auto;
}
.mobile-nav.open { transform: translateX(0); }
.mobile-nav a {
  display: block;
  color: rgba(255,255,255,0.85);
  font-size: 15px;
  font-weight: 500;
  padding: 13px 0;
  border-bottom: 1px solid rgba(255,255,255,0.07);
  text-decoration: none;
  transition: color 0.2s;
}
.mobile-nav a:hover { color: var(--cosmos-orange); }
.mobile-nav-sep {
  padding: 16px 0 6px;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.3);
}

/* Nav search u header-u */
.nav-search { display: none; }

/* Back to top */
#back-to-top {
  position: fixed; bottom: 24px; right: 24px;
  width: 40px; height: 40px;
  background: var(--cosmos-orange); color: #fff;
  border: none; border-radius: 4px;
  cursor: pointer; display: none;
  align-items: center; justify-content: center;
  box-shadow: 0 2px 8px rgba(0,0,0,0.2);
  transition: background 0.2s;
  z-index: 500;
}
#back-to-top.visible { display: flex; }
#back-to-top:hover { background: var(--cosmos-orange-dark); }
#back-to-top svg { width: 18px; height: 18px; }

/* ── RESPONSIVE ── */
@media (max-width: 1024px) {
  .shop-wrap { grid-template-columns: 240px 1fr; }
}
@media (max-width: 900px) {
  .shop-wrap { grid-template-columns: 1fr; padding: 16px; }
  .shop-sidebar { display: none; position: fixed; z-index: 500; width: 280px; height: 100vh; top: 0; left: -280px; background: var(--cosmos-white); transition: left 0.3s; padding: 20px; border-right: 1px solid var(--cosmos-border); }
  .shop-sidebar.open { left: 0; display: block; }
  .products-grid { grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); }
  .shop-header-main-inner { gap: 12px; }
  .shop-header-phone { display: none; }
  .shop-hamburger { display: flex; }
  .modal-body { grid-template-columns: 1fr; }
  .modal-img-col { min-height: 200px; }
}
@media (max-width: 600px) {
  .products-grid { grid-template-columns: 1fr 1fr; gap: 1px; }
  .subcat-grid { grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); }
  .welcome-grid { grid-template-columns: 1fr 1fr; }
  .shop-header-search { display: none; }
  .shop-header-logo img { height: 40px; }
}

/* ── Modal galerija thumbs ── */
.modal-main-img {
  width: 100%;
  max-height: 340px;
  object-fit: contain;
  transition: opacity 0.2s;
}
.modal-thumbs {
  display: flex;
  gap: 8px;
  margin-top: 12px;
  flex-wrap: wrap;
  justify-content: center;
}
.modal-thumb {
  width: 60px;
  height: 60px;
  object-fit: contain;
  border: 2px solid var(--cosmos-border);
  border-radius: 3px;
  cursor: pointer;
  transition: border-color 0.15s;
  background: var(--cosmos-bg);
  padding: 3px;
}
.modal-thumb:hover { border-color: var(--cosmos-orange); }
.modal-thumb.active { border-color: var(--cosmos-orange); }

/* ── Modal meta (sku + stock u jednoj liniji) ── */
.modal-meta {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}
.modal-sku {
  font-size: 12px;
  color: #aaa;
  font-family: monospace;
}

/* ── Modal atributi tabela ── */
.modal-attrs {
  width: 100%;
  border-collapse: collapse;
  font-size: 12px;
  margin-top: 2px;
}
.modal-attrs tr:nth-child(odd) { background: var(--cosmos-bg); }
.modal-attr-name {
  padding: 5px 10px 5px 0;
  color: #888;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  font-size: 10px;
  width: 45%;
  vertical-align: top;
}
.modal-attr-val {
  padding: 5px 0;
  color: var(--cosmos-dark);
  font-weight: 500;
}
