/* Katalog: grid kategori, filter chip, pencarian, kartu produk,
   paginasi, produk spesial, dan marquee brand. */
.cat-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.cat-card {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  aspect-ratio: 4 / 3;
  display: block;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.cat-card:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.cat-card img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.4s ease; }
.cat-card:hover img { transform: scale(1.06); }
.cat-card .cat-shade {
  position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(15, 17, 20, 0) 30%, rgba(15, 17, 20, 0.88) 100%);
}
.cat-card .cat-body {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  padding: 20px;
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
}
.cat-card .cat-name {
  color: #fff;
  font-family: var(--font-head);
  font-size: 17px;
  font-weight: 600;
  line-height: 1.25;
}
.cat-card .cat-arrow {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px; height: 38px;
  border-radius: 50%;
  background: var(--accent);
  color: var(--dark);
  transition: transform 0.2s ease;
}
.cat-card:hover .cat-arrow { transform: translateX(4px); }
.cat-arrow svg { width: 18px; height: 18px; }

/* ---------- Products ---------- */
.products-toolbar { display: flex; flex-wrap: wrap; gap: 18px; justify-content: space-between; align-items: center; margin-bottom: 24px; }
.filter-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  padding: 9px 18px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--bg);
  font-size: 13.5px;
  font-weight: 600;
  color: var(--muted);
  cursor: pointer;
  transition: all 0.15s ease;
}
.chip:hover { border-color: var(--accent); color: var(--accent-dark); }
.chip.active { background: var(--dark); color: #fff; border-color: var(--dark); }
.search-box {
  display: flex;
  align-items: center;
  gap: 10px;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 0 16px;
  min-width: 300px;
  background: var(--bg-soft);
}
.search-box svg { width: 18px; height: 18px; color: var(--muted); flex-shrink: 0; }
.search-box input {
  border: none; outline: none; background: transparent;
  padding: 13px 0; font-size: 14.5px; width: 100%;
  color: var(--ink); font-family: inherit;
}
.result-count { color: var(--muted); font-size: 13.5px; margin-bottom: 18px; }
.product-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  scroll-margin-top: calc(var(--nav-h) + 16px);
}
.product-card {
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.product-card:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.product-media { aspect-ratio: 1 / 1; overflow: hidden; background: var(--bg-soft); }
.product-media img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.4s ease; }
.product-card:hover .product-media img { transform: scale(1.04); }
.product-body { padding: 12px 14px 14px; display: flex; flex-direction: column; flex: 1; gap: 4px; }
.product-cat {
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent-dark);
}
.product-body h3 { font-size: 14px; font-weight: 600; color: var(--dark); line-height: 1.35; }
.product-body .spec { font-size: 12px; color: var(--muted); }
.product-order {
  margin-top: 10px;
  align-self: flex-start;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 7px 14px;
  border-radius: 8px;
  background: var(--dark);
  color: #fff;
  font-size: 12.5px;
  font-weight: 600;
  transition: all 0.15s ease;
}
.product-order svg { width: 13px; height: 13px; }
.product-order:hover { background: var(--accent); color: var(--dark); }

/* ---------- Empty state ---------- */
.empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  text-align: center;
  color: var(--muted);
  padding: 56px 0;
}
.empty-state svg { width: 44px; height: 44px; opacity: 0.45; }
.empty-reset {
  padding: 9px 20px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--bg);
  font-family: inherit;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--accent-dark);
  cursor: pointer;
  transition: all 0.15s ease;
}
.empty-reset:hover { border-color: var(--accent); background: var(--accent-soft); }

/* ---------- Pagination ---------- */
.pagination { display: flex; justify-content: center; align-items: center; gap: 6px; margin-top: 32px; flex-wrap: wrap; }
.page-btn {
  min-width: 38px;
  height: 38px;
  padding: 0 6px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--line);
  background: var(--bg);
  color: var(--muted);
  font-family: var(--font-head);
  font-size: 14.5px;
  font-weight: 600;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s ease;
}
.page-btn:hover:not(:disabled):not(.active) { border-color: var(--accent); color: var(--accent-dark); }
.page-btn.active { background: var(--dark); color: #fff; border-color: var(--dark); }
.page-btn:disabled { opacity: 0.4; cursor: not-allowed; }
.page-nav { font-size: 22px; line-height: 1; }
.page-dots { padding: 0 4px; color: var(--muted); font-size: 15px; }

/* ---------- Special ---------- */
.special { background: var(--bg-soft); }
.special-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-bottom: 36px; }
.special-card {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--bg);
  border: 1px solid var(--line);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.special-card:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.special-media { aspect-ratio: 1 / 1; overflow: hidden; }
.special-media img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.4s ease; }
.special-card:hover .special-media img { transform: scale(1.04); }
.special-body { padding: 14px; display: flex; flex-direction: column; gap: 5px; }
.special-body .badge-special {
  align-self: flex-start;
  background: var(--accent-soft);
  color: var(--accent-dark);
  font-size: 10.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 3px 9px;
  border-radius: 999px;
}
.special-body h3 { font-size: 14.5px; font-weight: 600; color: var(--dark); }
.special-body .spec { font-size: 12px; color: var(--muted); }
.special-body .order-now {
  margin-top: 8px;
  align-self: flex-start;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 7px 14px;
  border-radius: 8px;
  background: var(--dark);
  color: #fff;
  font-size: 12.5px;
  font-weight: 600;
  transition: all 0.15s ease;
}
.special-body .order-now svg { width: 13px; height: 13px; }
.special-body .order-now:hover { background: var(--accent); color: var(--dark); }

/* ---------- Brands marquee ---------- */
.brands { overflow: hidden; }
.brand-marquee {
  position: relative;
  overflow: hidden;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
}
.brand-track { display: flex; gap: 16px; width: max-content; animation: marquee 36s linear infinite; }
.brand-track:hover { animation-play-state: paused; }
.brand-tile {
  width: 132px;
  height: 88px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--bg);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 14px;
  flex-shrink: 0;
  transition: border-color 0.15s ease, transform 0.15s ease;
}
.brand-tile:hover { border-color: var(--accent); transform: translateY(-3px); }
.brand-tile img {
  width: 100%; height: 100%;
  object-fit: contain;
  filter: grayscale(1); opacity: 0.75;
  transition: filter 0.2s ease, opacity 0.2s ease;
}
.brand-tile:hover img { filter: grayscale(0); opacity: 1; }
@keyframes marquee { from { transform: translateX(0); } to { transform: translateX(-50%); } }

/* ---------- Responsive ---------- */
@media (max-width: 1024px) {
  .cat-grid, .product-grid, .special-grid { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 768px) {
  .cat-grid, .product-grid, .special-grid { grid-template-columns: repeat(2, 1fr); }
  .products-toolbar { flex-direction: column; align-items: stretch; }
  .search-box { min-width: 0; width: 100%; }
}

@media (max-width: 480px) {
  .cat-grid, .product-grid, .special-grid { grid-template-columns: 1fr; }
}
