* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;

  font-family: "Poppins", sans-serif;
}

body {
  font-family: "Poppins", sans-serif;
  background: #fafafa;
}

/* ==========================
PRODUCTS PAGE
========================== */

.products-page {
  max-width: 1400px;
  margin: 40px auto;
  padding: 0 20px;
}

/* ==========================
SIDEBAR
========================== */

.filters-sidebar {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.filter-box {
  background: #fff;
  border: 1px solid #e8e8e8;
  border-radius: 12px;
  padding: 20px;
}

.filter-box h3 {
  margin-bottom: 15px;
  font-size: 18px;
  color: #1d1464;
}

.filter-box label {
  display: block;
  margin-bottom: 12px;
  font-size: 14px;
  cursor: pointer;
}

.filter-box input[type="number"] {
  width: 100%;
  padding: 10px;
  margin-bottom: 10px;

  border: 1px solid #ddd;
  border-radius: 8px;
}

/* ==========================
CONTENT
========================== */

.products-content {
  width: 100%;
}
.products-layout {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 30px;
  align-items: start;
}

.breadcrumb {
  margin-bottom: 25px;

  font-size: 14px;
  color: #777;

  width: 100%;
}

/* ==========================
TOOLBAR
========================== */

.products-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;

  margin-bottom: 30px;
}

.products-toolbar h2 {
  font-size: 32px;
  color: #1d1464;
}

.products-toolbar select {
  padding: 12px 16px;

  border: 1px solid #ddd;
  border-radius: 8px;

  cursor: pointer;
}

/* ==========================
GRID
========================== */

.products-grid {
  display: grid;

  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));

  gap: 25px;
}

/* ==========================
PRODUCT CARD
========================== */

.product-card {
  background: #fff;

  border: 1px solid #ececec;
  border-radius: 14px;

  overflow: hidden;

  position: relative;

  display: flex;
  flex-direction: column;

  min-height: 370px;

  transition: 0.3s ease;
}

.product-card:hover {
  transform: translateY(-8px);

  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.08);
}

.product-image {
  width: 100%;
  height: 250px;

  object-fit: contain;

  padding: 15px;

  background: white;
}

.product-info {
  padding: 14px;

  display: flex;
  flex-direction: column;

  flex-grow: 1;
}

.brand {
  color: #ff7a00;
  font-weight: 700;
  font-size: 13px;

  margin-bottom: 8px;
}

.product-name {
  font-size: 14px;
  line-height: 1.45;
  font-weight: 600;

  color: #222;

  height: 44px;

  overflow: hidden;

  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;

  margin-bottom: 10px;
}

.price {
  color: #ff4b9b;
  font-size: 28px;
  font-weight: 700;

  margin-bottom: 15px;
}

.view-btn {
  display: block;

  text-align: center;
  text-decoration: none;

  background: #24135f;
  color: #fff;

  padding: 12px;
  border-radius: 12px;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.3px;

  margin-top: auto;
}

.view-btn:hover {
  background: #ff7a00;
}

/* ==========================
PAGINATION
========================== */

.pagination {
  display: flex;
  justify-content: center;
  gap: 10px;

  margin-top: 40px;
}

.pagination button {
  width: 42px;
  height: 42px;

  border: none;
  border-radius: 8px;

  cursor: pointer;

  background: #f2f2f2;
}

.pagination button:first-child {
  background: #1d1464;
  color: #fff;
}

/* ==========================
WISHLIST
========================== */

.wishlist-btn {
  position: absolute;
  top: 15px;
  right: 15px;

  width: 38px;
  height: 38px;

  border: none;
  border-radius: 50%;

  background: white;

  cursor: pointer;

  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);

  z-index: 5;
}

.wishlist-btn i {
  color: #1d1464;
  font-size: 16px;
}

.wishlist-btn:hover {
  transform: scale(1.05);
}

/* ==========================
BADGE
========================== */

.product-badge {
  position: absolute;

  top: 15px;
  left: 15px;

  background: #ff7a00;

  color: white;

  font-size: 11px;
  font-weight: 700;

  padding: 6px 10px;

  border-radius: 20px;

  z-index: 5;
}

/* ==========================
PRODUCT BOTTOM
========================== */

.product-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;

  margin-bottom: 15px;
}

.cart-btn {
  width: 42px;
  height: 42px;

  border: none;
  border-radius: 10px;

  background: #1d1464;
  color: white;

  cursor: pointer;

  transition: 0.3s;
}

.cart-btn:hover {
  background: #ff7a00;
}

.product-rating {
  color: #ffb400;
  font-size: 14px;
  margin-bottom: 12px;
}

.product-rating span {
  color: #888;
  font-size: 12px;
}
.filter-chips {
  display: flex;
  gap: 12px;

  margin: 25px 0 30px;

  flex-wrap: wrap;
}

.chip {
  border: none;

  background: #f4f2f9;

  color: #24135f;

  padding: 10px 18px;

  border-radius: 999px;

  font-size: 14px;
  font-weight: 600;

  cursor: pointer;

  transition: 0.3s;
}

.chip:hover {
  background: #24135f;
  color: white;
}

.chip.active {
  background: #24135f;
  color: white;
}

.filter-box input[type="checkbox"] {
  width: 18px;
  height: 18px;

  accent-color: #24135f;

  cursor: pointer;
}
.filter-box label {
  display: flex;
  align-items: center;
  gap: 12px;

  margin-bottom: 16px;

  font-size: 15px;

  cursor: pointer;
}

.filter-box {
  background: white;

  border-radius: 20px;

  padding: 24px;

  margin-bottom: 20px;

  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.05);
}

.show-all-btn {
  border: none;
  background: none;

  color: #24135f;

  font-weight: 600;

  margin-top: 8px;

  cursor: pointer;
}
.brand-search-wrapper {
  position: relative;

  margin-bottom: 18px;
}

.brand-search-wrapper input {
  width: 100%;
  height: 42px;

  border: 1px solid #e5e5e5;
  border-radius: 10px;

  padding: 0 40px 0 14px;

  font-size: 14px;

  outline: none;
}

.brand-search-wrapper i {
  position: absolute;

  right: 14px;
  top: 50%;

  transform: translateY(-50%);

  color: #999;
}

.filter-box input[type="number"] {
  width: 100%;

  height: 45px;

  padding: 0 14px;

  border: 1px solid #e5e5e5;

  border-radius: 10px;

  margin-bottom: 12px;

  font-size: 14px;
}

.apply-btn {
  width: 100%;

  height: 46px;

  border: none;

  border-radius: 10px;

  background: #ff7a00;

  color: white;

  font-weight: 600;

  cursor: pointer;
}

.products-toolbar {
  display: flex;

  justify-content: space-between;
  align-items: center;

  margin-bottom: 30px;
}

.toolbar-right {
  display: flex;

  align-items: center;

  gap: 24px;
}

.toolbar-group {
  display: flex;

  align-items: center;

  gap: 10px;
}

.toolbar-group span {
  font-size: 14px;

  font-weight: 500;

  color: #444;
}

.toolbar-group select {
  height: 44px;

  padding: 0 16px;

  border: 1px solid #e5e5e5;

  border-radius: 10px;

  background: white;

  font-family: Poppins;
}

.view-toggle {
  display: flex;
  gap: 10px;
}

.view-btn {
  border: none;

  background: transparent;

  font-size: 18px;

  color: #cfcfcf;

  cursor: pointer;
}

.view-btn.active {
  color: #ff7a00;
}

.toast {
  position: fixed;
  top: 100px;
  right: 30px;

  background: #24135f;
  color: white;

  padding: 14px 20px;
  border-radius: 12px;

  z-index: 99999;

  opacity: 0;
  visibility: hidden;

  transform: translateY(-20px);

  transition: all 0.3s ease;
}

.toast.show {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.breadcrumb a:hover {
  color: #2d1b69;
}
.products-page {
  max-width: 1400px;
  margin: 0 auto;
  padding: 20px 40px;
}

.breadcrumb {
  margin-bottom: 24px;
  font-size: 14px;
  color: #777;
}

.breadcrumb a {
  text-decoration: none;
  color: #777;
  transition: 0.3s;
}

/* ==========================
RESPONSIVE
========================== */

@media (max-width: 1200px) {
  .products-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 900px) {
  .products-page {
    grid-template-columns: 1fr;
  }

  .products-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 600px) {
  .products-grid {
    grid-template-columns: 1fr;
  }
}

/* ==========================
SQUARESPACE-STYLE CATALOG POLISH
========================== */

:root {
  --catalog-ink: #171717;
  --catalog-muted: #6f6a63;
  --catalog-line: #e8e2d8;
  --catalog-paper: #fffefa;
  --catalog-soft: #f6f1e9;
  --catalog-accent: #8b5d33;
  --catalog-accent-dark: #3f2a1b;
}

body {
  background: var(--catalog-paper);
  color: var(--catalog-ink);
}

.products-page {
  max-width: 1480px;
  padding: 36px 48px 72px;
}

.breadcrumb {
  color: var(--catalog-muted);
  font-size: 12px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.products-layout {
  grid-template-columns: 260px minmax(0, 1fr);
  gap: 44px;
}

.filters-sidebar {
  position: sticky;
  top: 24px;
  gap: 14px;
}

.filter-box {
  background: transparent;
  border: 0;
  border-top: 1px solid var(--catalog-line);
  border-radius: 0;
  box-shadow: none;
  margin: 0;
  padding: 22px 0;
}

.filter-box h3 {
  color: var(--catalog-ink);
  font-size: 12px;
  letter-spacing: 0.14em;
  margin-bottom: 18px;
  text-transform: uppercase;
}

.filter-box label {
  color: var(--catalog-muted);
  font-size: 14px;
  gap: 10px;
  margin-bottom: 13px;
}

.filter-box input[type="checkbox"] {
  accent-color: var(--catalog-accent-dark);
}

.brand-search-wrapper input,
.filter-box input[type="number"],
.toolbar-group select {
  background: #fff;
  border: 1px solid var(--catalog-line);
  border-radius: 4px;
  color: var(--catalog-ink);
}

.apply-btn {
  background: var(--catalog-ink);
  border-radius: 4px;
  height: 44px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.show-all-btn {
  color: var(--catalog-accent-dark);
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.products-toolbar {
  align-items: flex-start;
  border-bottom: 1px solid var(--catalog-line);
  gap: 24px;
  margin-bottom: 22px;
  padding-bottom: 24px;
}

.products-toolbar h2 {
  color: var(--catalog-ink);
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(34px, 4vw, 58px);
  font-weight: 400;
  letter-spacing: 0;
  line-height: 1;
}

.products-count {
  color: var(--catalog-muted);
  font-size: 14px;
  margin-top: 10px;
}

.toolbar-right {
  gap: 14px;
}

.toolbar-group span {
  color: var(--catalog-muted);
  font-size: 12px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.view-toggle .view-btn {
  align-items: center;
  background: #fff;
  border: 1px solid var(--catalog-line);
  border-radius: 4px;
  color: var(--catalog-muted);
  display: inline-flex;
  height: 44px;
  justify-content: center;
  margin: 0;
  padding: 0;
  width: 44px;
}

.view-toggle .view-btn.active {
  background: var(--catalog-ink);
  color: #fff;
}

.filter-chips {
  gap: 8px;
  margin: 0 0 28px;
}

.chip {
  background: transparent;
  border: 1px solid var(--catalog-line);
  border-radius: 999px;
  color: var(--catalog-muted);
  font-size: 12px;
  letter-spacing: 0.08em;
  padding: 10px 16px;
  text-transform: uppercase;
}

.chip:hover,
.chip.active {
  background: var(--catalog-ink);
  border-color: var(--catalog-ink);
  color: #fff;
}

.products-grid {
  gap: 34px 24px;
  grid-template-columns: repeat(auto-fill, minmax(235px, 1fr));
}

.product-card {
  background: transparent;
  border: 0;
  border-radius: 0;
  min-height: 0;
  overflow: visible;
}

.product-card:hover {
  box-shadow: none;
  transform: none;
}

.product-card::before {
  background: var(--catalog-soft);
  content: "";
  display: block;
  inset: 0;
  position: absolute;
  z-index: -1;
}

.product-image {
  aspect-ratio: 4 / 5;
  background: var(--catalog-soft);
  height: auto;
  margin-bottom: 16px;
  object-fit: contain;
  padding: 28px;
  transition: transform 0.35s ease;
}

.product-card:hover .product-image {
  transform: scale(1.025);
}

.product-info {
  padding: 0;
}

.brand {
  color: var(--catalog-muted);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.16em;
  margin-bottom: 8px;
  text-transform: uppercase;
}

.product-name {
  color: var(--catalog-ink);
  font-family: Georgia, "Times New Roman", serif;
  font-size: 18px;
  font-weight: 400;
  height: auto;
  line-height: 1.25;
  margin-bottom: 8px;
  min-height: 46px;
}

.product-desc {
  color: var(--catalog-muted);
  display: -webkit-box;
  font-size: 13px;
  line-height: 1.55;
  margin-bottom: 14px;
  min-height: 40px;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.product-rating {
  display: none;
}

.product-bottom {
  align-items: center;
  border-top: 1px solid var(--catalog-line);
  margin-bottom: 12px;
  padding-top: 14px;
}

.price {
  color: var(--catalog-ink);
  font-size: 16px;
  font-weight: 500;
  margin: 0;
}

.cart-btn {
  background: transparent;
  border: 1px solid var(--catalog-ink);
  border-radius: 50%;
  color: var(--catalog-ink);
  height: 40px;
  width: 40px;
}

.cart-btn:hover {
  background: var(--catalog-ink);
  color: #fff;
}

.view-btn {
  background: transparent;
  border: 1px solid var(--catalog-ink);
  border-radius: 4px;
  color: var(--catalog-ink);
  font-size: 12px;
  letter-spacing: 0.12em;
  padding: 12px;
  text-transform: uppercase;
}

.view-btn:hover {
  background: var(--catalog-ink);
  color: #fff;
}

.wishlist-btn {
  background: rgba(255, 255, 255, 0.86);
  border: 1px solid var(--catalog-line);
  box-shadow: none;
  right: 12px;
  top: 12px;
}

.wishlist-btn i {
  color: var(--catalog-ink);
}

.product-badge {
  background: var(--catalog-ink);
  border-radius: 999px;
  font-size: 10px;
  letter-spacing: 0.12em;
  left: 12px;
  padding: 7px 10px;
  text-transform: uppercase;
  top: 12px;
}

.empty-products {
  border: 1px solid var(--catalog-line);
  grid-column: 1 / -1;
  padding: 54px 24px;
  text-align: center;
}

.empty-products p {
  color: var(--catalog-ink);
  font-family: Georgia, "Times New Roman", serif;
  font-size: 28px;
  margin-bottom: 8px;
}

.empty-products span {
  color: var(--catalog-muted);
}

.pagination {
  display: none;
}

@media (max-width: 1100px) {
  .products-layout {
    grid-template-columns: 1fr;
  }

  .filters-sidebar {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    position: static;
  }
}

@media (max-width: 760px) {
  .products-page {
    padding: 24px 18px 56px;
  }

  .products-toolbar {
    flex-direction: column;
  }

  .toolbar-right,
  .toolbar-group {
    align-items: stretch;
    flex-direction: column;
    width: 100%;
  }

  .filters-sidebar {
    grid-template-columns: 1fr;
  }

  .products-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 28px 14px;
  }

  .product-image {
    padding: 18px;
  }

  .product-name {
    font-size: 16px;
  }
}


/* CODEX STABILITY PATCH */
.product-card {
  isolation: isolate;
  overflow: hidden;
}

.product-card::before {
  inset: 0;
}

.product-image {
  transform-origin: center center;
  will-change: transform;
}

.product-card:hover .product-image {
  transform: scale(1.08);
}

.product-info .view-btn {
  align-items: center;
  display: flex;
  justify-content: center;
  line-height: 1.2;
  min-height: 46px;
  overflow-wrap: anywhere;
  text-align: center;
  white-space: normal;
  width: 100%;
}

.product-info {
  min-height: 190px;
}

.product-bottom {
  gap: 12px;
}

@media (max-width: 420px) {
  .product-info .view-btn {
    font-size: 11px;
    padding-inline: 8px;
  }
}
