/* ==========================================================================
   SESSAIA STUDIO | Product Card & Grid Styles (Museum Double-Frame Edition)
   ========================================================================== */

.catalog-section {
  background-color: var(--color-chalk);
  position: relative;
}

/* Category Filter Bar */
.catalog-header {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-bottom: var(--space-2xl);
  text-align: center;
}

.catalog-subtitle {
  font-family: var(--font-sans);
  font-size: 0.74rem;
  font-weight: 500;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--color-aegean-blue);
  margin-bottom: 0.85rem; /* Increased breathing room above title */
}

.catalog-title {
  font-family: var(--font-serif-brand);
  font-size: clamp(1.28rem, 2.56vw, 1.84rem); /* Scaled down by 20% */
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-weight: 400;
  margin-bottom: var(--space-lg);
}

.category-tabs {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-xs);
  flex-wrap: wrap;
  background-color: transparent;
  padding: 0;
  border: none;
  box-shadow: none;
}

.category-tab {
  padding: 0.55rem 1.4rem;
  font-family: var(--font-sans);
  font-size: 0.74rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--color-slate-ink-60);
  border-radius: var(--radius-sm);
  transition: all var(--duration-normal) var(--ease-atelier);
  border: 1px solid transparent;
}

.category-tab:hover {
  color: var(--color-aegean-blue);
  background-color: rgba(243, 239, 230, 0.6);
  border-color: var(--color-pebble-grey);
}

.category-tab.active {
  background-color: var(--color-aegean-blue);
  color: var(--color-chalk);
  font-weight: 500;
  box-shadow: 0 3px 10px rgba(74, 93, 110, 0.25);
  border-color: var(--color-aegean-blue);
}

/* Product Grid */
.products-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: clamp(1.5rem, 3vw, 2.5rem);
  margin-bottom: var(--space-2xl);
}

/* Product Card — Clean Borderless Gallery Layout */
.product-card {
  background-color: transparent;
  border-radius: 0;
  display: flex;
  flex-direction: column;
  position: relative;
  transition: transform var(--duration-normal) var(--ease-atelier);
  cursor: pointer;
  border: none;
  padding: 0;
  box-shadow: none;
}

.product-card:hover {
  transform: translateY(-4px);
}

/* Image Container */
.product-image-frame {
  position: relative;
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background-color: var(--color-chalk);
  border-radius: 0;
  border: none;
  margin-bottom: 0;
}

.product-image-wrapper {
  position: relative;
  width: 100%; /* Full width to match description text width */
  aspect-ratio: 4 / 5;
  background-color: var(--color-chalk);
  overflow: hidden;
  border-radius: 0;
  border: none;
  display: flex;
  align-items: center;
  justify-content: center;
}

.product-primary-img,
.product-hover-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  border-radius: 0;
  padding: 0;
  transition: opacity var(--duration-slow) var(--ease-atelier), transform 0.8s var(--ease-atelier);
}

.product-hover-img {
  opacity: 0;
}

.product-card:hover .product-primary-img {
  transform: scale(1.03);
}

.product-card:hover .product-hover-img {
  opacity: 1;
  transform: scale(1.03);
}

/* Provenance Tag / Badge (Removed per design) */
.product-card-badge {
  display: none !important;
}

/* View Piece Button — Hover-Only, Halfway Over Bottom Edge, Slightly Rounded Corners (Width reduced by 30%) */
.product-card-quick-actions {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  width: 62%; /* Reduced by 30% */
  margin: 0 auto;
  z-index: 10;
  transform: translateY(calc(50% + 4px));
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--duration-normal) var(--ease-atelier), transform var(--duration-normal) var(--ease-atelier);
}

.product-card:hover .product-card-quick-actions {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(50%);
}

.quick-view-btn {
  width: 100%;
  height: 38px;
  background-color: var(--color-deep-mole);
  color: var(--color-chalk);
  border: 1px solid var(--color-deep-mole);
  padding: 0 1rem;
  font-family: var(--font-serif-brand);
  font-size: 0.74rem;
  font-weight: 400;
  line-height: 1;
  letter-spacing: 0.2em;
  text-indent: 0.2em; /* Offsets trailing letter-spacing for true horizontal centering */
  text-transform: uppercase;
  border-radius: var(--radius-sm); /* Slightly rounded corners matching Explore CTA */
  box-shadow: 0 4px 14px rgba(74, 63, 55, 0.28);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  box-sizing: border-box;
  vertical-align: middle;
  transition: background-color var(--duration-fast), border-color var(--duration-fast), box-shadow var(--duration-fast), transform var(--duration-fast);
}

.quick-view-btn .btn-label,
.quick-view-btn > span {
  display: inline-block;
  line-height: 1;
  transform: translateY(2.5px); /* Balanced optical cap-height centering */
}

.quick-view-btn:hover {
  background-color: var(--color-aegean-blue);
  border-color: var(--color-aegean-blue);
  color: var(--color-chalk);
  box-shadow: 0 6px 18px rgba(74, 93, 110, 0.35);
}

/* Product Info Section — Line of Space Below Overlapping Button */
.product-info {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  padding: 1.75rem 0 0.25rem 0; /* Generous space above product title, 0 horizontal padding to align flush with photo */
  width: 100%;
}

.product-title-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: var(--space-sm);
}

.product-card-title {
  font-family: var(--font-serif-brand);
  font-size: 1.1rem;
  color: var(--color-slate-ink);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-weight: 400;
  line-height: 1.3;
}

.product-card-price {
  font-family: var(--font-sans);
  font-size: 1.05rem;
  color: var(--color-deep-mole);
  font-weight: 400;
  white-space: nowrap;
  margin-top: 2px;
}

.product-card-materials {
  font-size: 0.8rem;
  color: var(--color-slate-ink-60);
  line-height: 1.45;
  display: -webkit-box;
  -webkit-line-clamp: 1;
  line-clamp: 1;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.product-card-note {
  font-size: 0.72rem;
  color: #7E7D7A;
  font-family: var(--font-sans);
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-top: 0.15rem;
}

/* Empty State / Curation Note */
.empty-category-note {
  text-align: center;
  padding: var(--space-3xl) var(--space-md);
  background-color: var(--color-chalk);
  border-radius: var(--radius-sm);
  max-width: 680px;
  margin: 0 auto;
  border: 1px dashed var(--color-pebble-grey);
}

.empty-category-note h4 {
  font-family: var(--font-serif-brand);
  font-size: 1.3rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  font-weight: 400;
  margin-bottom: var(--space-xs);
  color: var(--color-slate-ink);
}

.empty-category-note p {
  color: var(--color-slate-ink-60);
  font-size: 0.9rem;
  margin-bottom: var(--space-md);
}

@media (max-width: 640px) {
  .products-grid {
    grid-template-columns: 1fr;
  }
  .product-card-quick-actions {
    opacity: 1;
    transform: translateY(0);
    position: static;
    margin-top: var(--space-sm);
  }
}
