/* ---------------- Reset & Fonts ---------------- */

body {
  background-color: #f8f9fa;  /* nền riêng cho trang product */
  color: var(--ph-navy);
  padding-top: 120px;          /* chừa chỗ cho header fixed nếu cần */
}


/* ---------------- Product Layout ---------------- */
.product-archive {
  padding: 20px 0;
}


/* ---------------- Horizontal Filter Bar ---------------- */

/* ============================
   FILTER BAR – PHOTHESENSE
   ============================ */

/* Thanh filter bám trên cùng, nền kem brand, căn giữa */
.filter-bar {
  position: sticky;
  top: 135px; /* chỉnh theo chiều cao header của bạn */
  z-index: 950;
  background: #FFFCEE;
  border-bottom: 1px solid rgba(28, 66, 120, 0.08);
  display: flex;
  justify-content: center;
  padding: 10px 0;
}

/* Container chứa các chip + sort – căn giữa, max-width để không quá dài */
.filter-scroll-container {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  max-width: 1240px;
  width: 100%;
  padding: 0 16px;
  margin: 0 auto;

  overflow-x: auto;
  scroll-behavior: smooth;
  white-space: nowrap; /* giúp các chip nằm trên 1 hàng, có thể scroll ngang trên mobile */
}

.filter-scroll-container::-webkit-scrollbar {
  display: none;
}

/* Nhóm Location / Experience */
.filter-group {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
}

.filter-label {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  opacity: 0.8;
  color: #1C4278;
}

/* ---------- Filter Chip ---------- */
.filter-chip {
  background: #f3f3f3;
  border: 1px solid transparent;
  border-radius: 999px;
  padding: 7px 18px;
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.03em;
  color: var(--ph-navy);
  cursor: pointer;
  white-space: nowrap;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: background-color 0.25s ease,
              color 0.25s ease,
              box-shadow 0.25s ease,
              transform 0.15s ease,
              border-color 0.25s ease;
  flex-shrink: 0;
}

.filter-chip.with-icon i {
  font-size: 14px;
  color: var(--ph-navy);
}

/* Hover + Active */
.filter-chip:hover,
.filter-chip.active {
  background: var(--ph-navy);
  color: var(--ph-text-light);
}

.filter-chip:hover i,
.filter-chip.active i {
  color: var(--ph-text-light);
}

/* Focus cho accessibility */
.filter-chip:focus-visible {
  outline: 2px solid var(--ph-primary);
  outline-offset: 2px;
}


/* ============================
   SORT TRONG FILTER BAR
   ============================ */

.sort-in-bar {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-left: auto; /* đẩy về phía bên phải trong container cuộn */
  flex-shrink: 0;
}

.sort-label {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  opacity: 0.8;
  color: #1C4278;
}

/* Wrapper để vẽ arrow custom */
.sort-dropdown {
  position: relative;
}

/* Arrow Font Awesome tự vẽ */
.sort-dropdown::after {
  content: "\f107"; /* chevron-down */
  font-family: "Font Awesome 5 Free";
  font-weight: 900;
  position: absolute;
  right: 14px;
  top: 50%;
  transform: translateY(-50%);
  pointer-events: none;
  font-size: 13px;
  color: #1C4278;
  opacity: 0.8;
}

/* Select style */
.sort-select {
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;

  background: #FFFCEE;
  border: 1px solid rgba(28, 66, 120, 0.25);
  border-radius: 999px;

  padding: 7px 32px 7px 12px;
  font-size: 13px;
  font-weight: 500;
  color: #1C4278;

  cursor: pointer;
  transition: border-color 0.2s ease,
              box-shadow 0.2s ease,
              background-color 0.2s ease;
  box-shadow: 0 2px 6px rgba(0,0,0,0.04);
}

/* Hover */
.sort-select:hover {
  border-color: #1C4278;
  box-shadow: 0 3px 10px rgba(28, 66, 120, 0.14);
}

/* Focus */
.sort-select:focus {
  outline: none;
  border-color: #FBDC47;
  box-shadow: 0 0 0 2px rgba(251, 220, 71, 0.4);
}

/* ---------- Filter Arrow Buttons ---------- */
.filter-arrow {
  border: none;
  background: #FFFCEE;
  color: #1C4278;
  width: 28px;
  height: 28px;
  border-radius: 999px;
  display: none; /* mặc định ẩn trên desktop */
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 6px rgba(0,0,0,0.12);
  cursor: pointer;
  flex-shrink: 0;
  z-index: 960;
}

.filter-arrow i {
  font-size: 14px;
}

/* class hidden để JS bật/tắt */
.filter-arrow.hidden {
  display: none !important;
}

/* ---------------- Product Cards ---------------- */

/* Product Cards */
.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
  margin-bottom: 20px;
}

.product-card {
  display: block;
  background: white;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 4px 12px rgba(0,0,0,0.1);
  transition: transform 0.3s, box-shadow 0.3s;
  text-decoration: none;
  color: inherit;
}

.product-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 20px rgba(0,0,0,0.15);
}

.product-image {
  width: 100%;
  height: 200px;
  background-size: cover;
  background-position: center;
}

.product-info {
  padding: 15px;
  position: static;
}

.rating {
  position: absolute;
  top: 10px;
  right: 10px;
  background: #1C4278;
  color: white;
  padding: 4px 8px;
  border-radius: 15px;
  font-size: 12px;
}

.product-info h3 {
  font-size: 16px;
  margin-bottom: 5px;
  color: #1C4278;
  font-family: 'Roboto Slab', serif;
}

.product-info p {
  font-size: 14px;
  color: #666;
  margin-bottom: 10px;
}

.duration, .reviews {
  font-size: 12px;
  color: #1C4278;
  margin-bottom: 5px;
}

.free-cancel {
  display: block;
  font-size: 12px;
  color: #28a745;
  margin-bottom: 10px;
}

.price {
  font-size: 18px;
  font-weight: bold;
  color: #1C4278;
}

.price span {
  font-size: 12px;
  font-weight: normal;
}

.heart {
  position: absolute;
  top: 10px;
  left: 10px;
  color: #ff6b6b;
  font-size: 18px;
}





/* Mobile tweaks */
@media (max-width: 768px) {

    .filter-bar {
    position: static;    /* không sticky trên mobile */
    padding: 6px 0;
    display: flex;
    align-items: center;
  }

  .filter-arrow {
    display: flex;
  }

  .filter-scroll-container {
    gap: 8px;
    padding: 0 12px;
     flex: 1; 
    justify-content: flex-start;
  }

  .filter-chip {
    font-size: 12px;
    padding: 6px 14px;
  }

  .sort-label {
    display: none; /* cho gọn trên mobile, chỉ giữ dropdown */
  }

  .sort-select {
    font-size: 12px;
    padding: 6px 28px 6px 10px;
  }
}

