/**
 * Product listing – new card/grid design
 * Fonts: Cormorant Garamond (headings) + Outfit (body).
 * Scoped under .category-products for card styles.
 */

/* Hero: sub pages only (40vh) — homepage keeps hero.css defaults */
.page-hero--sub {
  height: 40vh;
}

.page-hero--sub .page-hero__media {
  height: 100%;
  max-height: none;
  aspect-ratio: auto;
  min-height: 0;
}

/* Intro */
.intro {
  max-width: 720px;
  margin: 70px auto;
  text-align: center;
  border: none;
}

.intro h2 {
  font-family: 'Cormorant Garamond', serif;
  font-size: 32px;
  margin-bottom: 15px;
  color: #1a1a1a;
}

.intro p {
  font-family: 'Outfit', sans-serif;
  font-size: 18px;
  color: #666;
  line-height: 1.6;
}

/* ── Grid ── */
.category-products .grid {
  width: 100%;
  margin: 0 auto;
  padding: 0 0 80px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  column-gap: 2px;
  row-gap: 60px;
  list-style: none;
}

/* ── Card ── */
.category-products .card {
  background: #f0efed;
  border-radius: 0;
  position: relative;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  cursor: pointer;
  transition: box-shadow 0.35s ease;
}

.category-products .card:hover {
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.09);
}

/* Card image */
.category-products .card-image {
  position: relative;
  background: #ededeb;
  aspect-ratio: 3 / 4;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  width: 100%;
  text-decoration: none;
}

.category-products .card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.65s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.category-products .card:hover .card-image img {
  transform: scale(1.05);
}

/* Loader inside card-image (AddToChart loading) */
.category-products .card-image .loader-container {
  position: absolute;
  inset: 0;
  z-index: 2;
  background: rgba(255, 255, 255, 0.6);
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Badge */
.category-products .badge {
  position: absolute;
  top: 18px;
  left: 20px;
  font-family: 'Outfit', sans-serif;
  font-size: 11px;
  letter-spacing: 1.8px;
  text-transform: uppercase;
  color: #2d2d2d;
  z-index: 1;
}

/* Card footer */
.category-products .card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px 18px;
  background: #f0efed;
  border-top: 1px solid #dedad5;
}

.category-products .product-title {
  font-family: 'Cormorant Garamond', serif;
  font-size: 14px;
  font-weight: 400;
  letter-spacing: 0.3px;
  margin-bottom: 3px;
  color: #1a1a1a;
}

.category-products .product-title a {
  color: inherit;
  text-decoration: none;
}

.category-products .product-title a:hover {
  text-decoration: underline;
}

.category-products .product-desc {
  font-family: 'Outfit', sans-serif;
  font-size: 11.5px;
  color: #888;
  letter-spacing: 0.3px;
}

.category-products .price {
  font-family: 'Outfit', sans-serif;
  font-size: 12.5px;
  color: #444;
  letter-spacing: 0.3px;
  margin-top: 5px;
  font-weight: 400;
}

/* Sepete Ekle button (icon + text) */
.category-products .btn-sepete-ekle,
.category-products .card-footer .addtocart {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  border: 1px solid #b8b5b0;
  background: transparent;
  font-family: 'Outfit', sans-serif;
  font-size: 12px;
  color: #2d2d2d;
  text-decoration: none;
  cursor: pointer;
  flex-shrink: 0;
  white-space: nowrap;
  transition: background 0.25s, border-color 0.25s, color 0.25s;
}

.category-products .btn-sepete-ekle:hover,
.category-products .card-footer .addtocart:hover {
  background: #1a1a1a;
  border-color: #1a1a1a;
  color: #fff;
}

.category-products .btn-sepete-ekle i,
.category-products .card-footer .addtocart i {
  font-size: 14px;
  line-height: 1;
}

.category-products .btn-disabled {
  opacity: 0.5;
  cursor: default;
  pointer-events: none;
}

/* ── Story section ── */
.story {
  margin: 80px 0 100px;
  background: #ede8e1;
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
}

.story img {
  width: 100%;
  height: 420px;
  object-fit: cover;
}

.story-text {
  padding: 60px;
}

.story-text h3 {
  font-family: 'Cormorant Garamond', serif;
  font-size: 30px;
  margin-bottom: 15px;
  color: #1a1a1a;
}

.story-text p {
  font-family: 'Outfit', sans-serif;
  color: #666;
  line-height: 1.7;
}

/* ── Filter Bar (all.aspx) ── */
.filter-bar {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  padding: 40px 0 36px;
  text-align: center;
}

.filter-bar__label {
  font-family: 'Cormorant Garamond', serif;
  font-size: 16px;
  font-weight: 600;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: #1a1a1a;
}

.filter-bar__buttons {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: center;
}

.filter-btn {
  padding: 9px 22px;
  border: 1px solid #c8c5c0;
  border-radius: 0;
  background: transparent;
  font-family: 'Outfit', sans-serif;
  font-size: 13px;
  letter-spacing: 0.5px;
  color: #555;
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.25s ease;
}

.filter-btn:hover {
  border-color: #1a1a1a;
  color: #1a1a1a;
}

.filter-btn.active {
  background: #1a1a1a;
  border-color: #1a1a1a;
  color: #fff;
}

/* Filter group animation */
.filter-group {
  display: none;
}

.filter-group.filter-active {
  display: block;
  animation: filterSlideIn 0.45s ease forwards;
}

@keyframes filterSlideIn {
  from {
    transform: translateX(50px);
    opacity: 0;
  }
  to {
    transform: translateX(0);
    opacity: 1;
  }
}

#filteredProducts {
  overflow: hidden;
}

/* ── Responsive ── */
/* iPad mini, smaller tablets */
@media (max-width: 800px) {
  .category-products .grid {
    grid-template-columns: 1fr 1fr;
  }

  .story {
    grid-template-columns: 1fr;
  }

  .filter-bar {
    padding: 30px 16px 28px;
  }

  .filter-bar__buttons {
    gap: 6px;
    overflow-x: auto;
    flex-wrap: nowrap;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }

  .filter-bar__buttons::-webkit-scrollbar {
    display: none;
  }

  .filter-btn {
    padding: 7px 14px;
    font-size: 12px;
    flex-shrink: 0;
  }
}

/* Mobile */
@media (max-width: 480px) {
  .category-products .grid {
    grid-template-columns: 1fr;
  }

  .story-text {
    padding: 40px 24px;
  }

  .intro {
    margin: 40px auto;
  }

  .intro h2 {
    font-size: 26px;
  }

  .intro p {
    font-size: 16px;
  }

  .filter-bar {
    padding: 24px 0 20px;
  }

  .filter-bar__buttons {
    width: 100%;
    overflow-x: auto;
    flex-wrap: nowrap;
    -webkit-overflow-scrolling: touch;
    gap: 6px;
    padding: 0 16px 6px;
    scrollbar-width: none;
  }

  .filter-bar__buttons::-webkit-scrollbar {
    display: none;
  }

  .filter-btn {
    padding: 7px 12px;
    font-size: 11.5px;
    flex-shrink: 0;
  }
}
