/* ═══════════════════════════════════════════════════════════════════════════
   shop.css — Ürün kataloğu, filtreler, sıralama
   ═══════════════════════════════════════════════════════════════════════════ */

/* ── Mağaza Başlık Alanı ─────────────────────────────────────────────────── */

.shop-header {
  background: var(--wd-gray-100);
  padding: 30px 0;
  margin-bottom: 40px;
  border-bottom: 1px solid var(--wd-border-color-light);
}

.shop-header h1 {
  font-size: 1.8rem;
  margin-bottom: 6px;
}

.shop-header__desc {
  font-size: 14px;
  color: var(--wd-text-light);
  max-width: 600px;
  line-height: 1.6;
}

.shop-header__banner {
  width: 100%;
  max-height: 200px;
  object-fit: cover;
  display: block;
}

/* ── Araç Çubuğu ─────────────────────────────────────────────────────────── */

.shop-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 24px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--wd-border-color-light);
  flex-wrap: wrap;
}

.shop-toolbar__count {
  font-size: 13px;
  color: var(--wd-text-light);
}

.shop-toolbar__count strong {
  color: var(--wd-text-color);
}

.shop-toolbar__right {
  display: flex;
  align-items: center;
  gap: 16px;
}

/* Sıralama */
.shop-sort {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
}

.shop-sort label {
  margin-bottom: 0;
  color: var(--wd-text-light);
  white-space: nowrap;
}

.shop-sort select {
  width: auto;
  height: 36px;
  font-size: 13px;
  padding: 0 30px 0 10px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6'%3E%3Cpath d='M0 0l5 6 5-6z' fill='%23666'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 10px center;
  cursor: pointer;
}

/* Grid / Liste görünüm */
.view-mode {
  display: flex;
  gap: 4px;
}

.view-mode-btn {
  width: 34px;
  height: 34px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  color: var(--wd-gray-400);
  border: 1px solid var(--wd-border-color);
  border-radius: var(--wd-border-radius);
  transition: var(--wd-transition);
  cursor: pointer;
}

.view-mode-btn.active,
.view-mode-btn:hover {
  background: var(--wd-primary-color);
  color: #fff;
  border-color: var(--wd-primary-color);
}

/* ── Filtre Paneli ───────────────────────────────────────────────────────── */

.filter-panel {
  border: 1px solid var(--wd-border-color-light);
  background: #fff;
  margin-bottom: 20px;
}

.filter-group {
  border-bottom: 1px solid var(--wd-border-color-light);
}

.filter-group:last-child {
  border-bottom: none;
}

.filter-group__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 16px;
  cursor: pointer;
  user-select: none;
}

.filter-group__title {
  font-size: 13px;
  font-weight: 600;
  color: var(--wd-heading-color);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.filter-group__arrow {
  font-size: 10px;
  color: var(--wd-gray-400);
  transition: transform 0.25s ease;
}

.filter-group.open .filter-group__arrow {
  transform: rotate(180deg);
}

.filter-group__body {
  padding: 6px 16px 14px;
  display: none;
}

.filter-group.open .filter-group__body {
  display: block;
}

/* Onay Kutusu Filtreler */
.filter-checkbox-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.filter-checkbox {
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  font-size: 13px;
  color: var(--wd-gray-700);
}

.filter-checkbox input[type="checkbox"] {
  width: 15px;
  height: 15px;
  cursor: pointer;
  flex-shrink: 0;
}

.filter-checkbox .count {
  margin-left: auto;
  font-size: 11px;
  color: var(--wd-text-light);
  background: var(--wd-gray-200);
  padding: 1px 6px;
  border-radius: 10px;
}

/* Fiyat Aralığı */
.price-range-inputs {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 8px;
}

.price-range-inputs input {
  height: 34px;
  font-size: 13px;
  text-align: center;
  padding: 0 8px;
}

.price-range-inputs span {
  color: var(--wd-text-light);
  font-size: 12px;
  flex-shrink: 0;
}

.price-range-apply {
  margin-top: 10px;
  width: 100%;
  height: 34px;
  font-size: 12px;
}

/* Aktif Filtreler */
.active-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 16px;
}

.active-filter-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  background: var(--wd-primary-color);
  color: #fff;
  font-size: 12px;
  border-radius: 3px;
}

.active-filter-tag .remove {
  font-size: 14px;
  cursor: pointer;
  opacity: 0.8;
  transition: opacity 0.2s ease;
  background: none;
  border: none;
  color: inherit;
  line-height: 1;
  padding: 0;
}

.active-filter-tag .remove:hover {
  opacity: 1;
}

.clear-all-filters {
  font-size: 12px;
  color: var(--wd-danger);
  text-decoration: underline;
  align-self: center;
}

/* ── Ürün Grid / Liste ───────────────────────────────────────────────────── */

.shop-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.shop-grid.cols-2 {
  grid-template-columns: repeat(2, 1fr);
}

.shop-grid.cols-4 {
  grid-template-columns: repeat(4, 1fr);
}

/* Liste Görünümü */
.shop-list .product-card {
  display: flex;
  flex-direction: row;
}

.shop-list .product-card__image {
  width: 220px;
  flex-shrink: 0;
  aspect-ratio: auto;
  height: 180px;
}

.shop-list .product-card__info {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.shop-list .product-card__overlay {
  display: none;
}

/* Boş durum */
.shop-empty {
  grid-column: 1 / -1;
  text-align: center;
  padding: 60px 20px;
}

.shop-empty__icon {
  font-size: 48px;
  color: var(--wd-gray-300);
  margin-bottom: 16px;
}

.shop-empty h3 {
  font-size: 1.1rem;
  margin-bottom: 8px;
}

.shop-empty p {
  color: var(--wd-text-light);
  font-size: 14px;
  margin-bottom: 20px;
}

/* ── Kategori Başlık Alanı ───────────────────────────────────────────────── */

.category-banner {
  position: relative;
  overflow: hidden;
  margin-bottom: 30px;
  background: var(--wd-gray-900);
  min-height: 160px;
  display: flex;
  align-items: center;
}

.category-banner img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.5;
}

.category-banner__content {
  position: relative;
  z-index: 1;
  padding: 30px;
  color: #fff;
}

.category-banner__content h1 {
  color: #fff;
  font-size: 2rem;
  margin-bottom: 6px;
}

.category-banner__content p {
  font-size: 14px;
  opacity: 0.85;
}

/* ── Responsive ──────────────────────────────────────────────────────────── */

@media (max-width: 992px) {
  .shop-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .shop-grid.cols-4 {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 768px) {
  .shop-toolbar {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
  }

  .shop-list .product-card {
    flex-direction: column;
  }

  .shop-list .product-card__image {
    width: 100%;
    height: 200px;
  }
}

@media (max-width: 480px) {
  .shop-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
  }

  .shop-grid.cols-2 {
    grid-template-columns: 1fr;
  }
}
