/* ============================================
   KATUISCIA — Product Page Styles
   ============================================ */

.product-page {
  padding-top: calc(var(--header-height) + var(--space-2xl));
  padding-bottom: var(--space-4xl);
}

/* ==== PRODUCT DETAIL SECTION ==== */
.product-detail {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: var(--space-4xl);
  max-width: var(--max-width-narrow);
  margin: 0 auto;
  padding: 0 var(--space-xl);
}

/* -- Gallery -- */
.product-gallery {
  display: flex;
  flex-direction: column;
  gap: var(--space-md);
}

.product-gallery__main {
  position: relative;
  width: 100%;
  aspect-ratio: 4 / 5;
  background: linear-gradient(145deg, #4A1A1A, #1A0A0A); /* Dark red/black background from mockup */
  border-radius: var(--radius-2xl);
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--space-2xl);
}

.product-gallery__main img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  filter: drop-shadow(0 20px 40px rgba(0,0,0,0.5));
}

.product-gallery__badge {
  position: absolute;
  top: var(--space-lg);
  left: var(--space-lg);
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(4px);
  color: var(--color-dark);
  font-size: 0.65rem;
  font-weight: var(--weight-bold);
  letter-spacing: var(--tracking-wider);
  text-transform: uppercase;
  padding: 6px 14px;
  border-radius: var(--radius-full);
  z-index: 2;
}

.product-gallery__thumbnails {
  display: flex;
  gap: var(--space-md);
}

.product-gallery__thumb {
  width: 80px;
  height: 80px;
  border-radius: var(--radius-md);
  border: 2px solid transparent;
  background: var(--color-gray);
  overflow: hidden;
  cursor: pointer;
  transition: all var(--duration-fast) var(--ease-out);
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.product-gallery__thumb img {
  width: 80%;
  height: 80%;
  object-fit: contain;
}

/* Colors for specific thumbs to match mockup */
.product-gallery__thumb:nth-child(1) { background: linear-gradient(145deg, #4A1A1A, #1A0A0A); }
.product-gallery__thumb:nth-child(2) { background: #7AC0BA; } /* Minty */
.product-gallery__thumb:nth-child(3) { background: #333333; } /* Dark */

.product-gallery__thumb:hover {
  opacity: 0.8;
}

.product-gallery__thumb--active {
  border-color: var(--color-dark);
  opacity: 1;
}

/* -- Info Column -- */
.product-info {
  display: flex;
  flex-direction: column;
  padding-top: var(--space-lg);
}

.breadcrumb {
  margin-bottom: var(--space-md);
}

.breadcrumb ol {
  list-style: none;
  display: flex;
  gap: 8px;
  padding: 0;
  margin: 0;
  font-size: 0.65rem;
  letter-spacing: var(--tracking-widest);
  text-transform: uppercase;
  color: var(--color-text-muted);
}

.breadcrumb a {
  color: inherit;
  text-decoration: none;
  transition: color var(--duration-fast);
}

.breadcrumb a:hover {
  color: var(--color-dark);
}

.breadcrumb li:not(:last-child)::after {
  content: '/';
  margin-left: 8px;
  color: var(--color-border);
}

.product-info__title {
  font-family: var(--font-heading);
  font-size: var(--text-4xl);
  font-weight: var(--weight-medium);
  line-height: 1.1;
  color: var(--color-dark);
  margin-bottom: var(--space-md);
}

.product-info__pricing {
  display: flex;
  align-items: baseline;
  gap: var(--space-md);
  margin-bottom: var(--space-lg);
}

.product-info__price-current {
  font-size: var(--text-xl);
  font-weight: var(--weight-medium);
  color: var(--color-dark);
}

.product-info__price-old {
  font-size: var(--text-md);
  color: var(--color-text-muted);
  text-decoration: line-through;
}

/* -- Countdown Timer -- */
.product-countdown {
  background: #F2EFEA; /* Light grey/beige from mockup */
  border-radius: var(--radius-lg);
  padding: var(--space-lg);
  margin-bottom: var(--space-xl);
  position: relative;
  overflow: hidden;
}

.product-countdown::after {
  content: '';
  position: absolute;
  top: -20px; right: -20px;
  width: 100px; height: 100px;
  background: rgba(0,0,0,0.03);
  border-radius: 50%;
}

.product-countdown__header {
  font-size: var(--text-xs);
  color: var(--color-text-light);
  margin-bottom: var(--space-md);
}

.product-countdown__timer {
  display: flex;
  gap: var(--space-sm);
}

.countdown-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
}

.countdown-value {
  background: var(--color-white);
  color: var(--color-dark);
  font-size: var(--text-md);
  font-weight: var(--weight-semibold);
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
}

.countdown-label {
  font-size: 0.55rem;
  letter-spacing: var(--tracking-wider);
  color: var(--color-text-muted);
  text-transform: uppercase;
}

/* -- Description -- */
.product-info__description {
  font-size: var(--text-sm);
  line-height: var(--leading-relaxed);
  color: var(--color-text-light);
  margin-bottom: var(--space-2xl);
}

/* -- Actions (Qty + Buttons) -- */
.product-actions {
  display: flex;
  flex-direction: column;
  gap: var(--space-lg);
  margin-bottom: var(--space-xl);
}

.product-actions__quantity {
  display: flex;
  align-items: center;
  gap: var(--space-md);
}

.quantity-label {
  font-size: var(--text-xs);
  font-weight: var(--weight-semibold);
  letter-spacing: var(--tracking-wide);
  color: var(--color-dark);
}

.quantity-selector {
  display: flex;
  align-items: center;
  background: var(--color-white);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-full);
  padding: 4px 12px;
}

.quantity-btn {
  background: transparent;
  border: none;
  font-size: var(--text-md);
  color: var(--color-dark);
  cursor: pointer;
  padding: 0 8px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.quantity-selector input {
  width: 30px;
  text-align: center;
  border: none;
  background: transparent;
  font-size: var(--text-sm);
  font-weight: var(--weight-medium);
  color: var(--color-dark);
  -moz-appearance: textfield;
}

.quantity-selector input::-webkit-outer-spin-button,
.quantity-selector input::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

.product-actions__buttons {
  display: flex;
  flex-direction: column;
  gap: var(--space-md);
}

.btn--light {
  background: var(--color-gray-medium);
  color: var(--color-dark);
}
.btn--light:hover {
  background: #DFDCD7;
}
.btn--light svg {
  margin-right: 8px;
}

/* -- Features -- */
.product-features {
  display: flex;
  gap: var(--space-xl);
  margin-bottom: var(--space-2xl);
  padding-bottom: var(--space-xl);
  border-bottom: 1px solid var(--color-border);
}

.feature-item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: var(--text-xs);
  color: var(--color-text-light);
}

/* -- Accordion -- */
.product-accordion {
  display: flex;
  flex-direction: column;
}

.accordion-item {
  border-bottom: 1px solid var(--color-border);
}

.accordion-header {
  padding: var(--space-md) 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  cursor: pointer;
  list-style: none; /* Hide default arrow */
  font-family: var(--font-heading);
  font-size: var(--text-md);
  color: var(--color-dark);
}

.accordion-header::-webkit-details-marker {
  display: none;
}

.accordion-icon {
  transition: transform var(--duration-fast);
  color: var(--color-text-muted);
}

.accordion-item[open] .accordion-icon {
  transform: rotate(180deg);
}

.accordion-content {
  padding-bottom: var(--space-md);
  font-size: var(--text-sm);
  color: var(--color-text-light);
  line-height: var(--leading-relaxed);
}

/* ==== UPSELL SECTION (Complétez Votre Rituel) ==== */
.upsell {
  background: var(--color-cream);
  padding: var(--space-4xl) 0;
  margin-top: var(--space-4xl);
}

.upsell .section-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  text-align: left;
  max-width: var(--max-width-narrow);
  margin: 0 auto var(--space-2xl);
  padding: 0 var(--space-xl);
}

.upsell .section-header__title {
  margin-bottom: 0;
  font-size: var(--text-3xl);
}

.upsell__link {
  font-size: var(--text-xs);
  font-weight: var(--weight-semibold);
  letter-spacing: var(--tracking-wider);
  text-transform: uppercase;
  color: var(--color-text-light);
  text-decoration: none;
  border-bottom: 1px solid var(--color-border);
  padding-bottom: 2px;
  transition: color var(--duration-fast);
}

.upsell__link:hover {
  color: var(--color-dark);
  border-color: var(--color-dark);
}

.upsell__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-xl);
  max-width: var(--max-width-narrow);
  margin: 0 auto;
  padding: 0 var(--space-xl);
}

.upsell-card {
  display: flex;
  flex-direction: column;
  gap: var(--space-md);
  text-decoration: none;
  transition: transform var(--duration-normal);
}

.upsell-card:hover {
  transform: translateY(-8px);
}

.upsell-card__img {
  width: 100%;
  aspect-ratio: 1;
  border-radius: var(--radius-xl);
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}

.upsell-card__img img {
  width: 80%;
  height: 80%;
  object-fit: contain;
  transition: transform var(--duration-slow);
}

.upsell-card:hover .upsell-card__img img {
  transform: scale(1.05);
}

.upsell-card__info {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 4px;
}

.upsell-card__title {
  font-family: var(--font-heading);
  font-size: var(--text-lg);
  color: var(--color-dark);
}

.upsell-card__desc {
  font-size: var(--text-xs);
  color: var(--color-text-light);
}

.upsell-card__price {
  font-size: var(--text-sm);
  font-weight: var(--weight-semibold);
  color: var(--color-dark);
  margin-top: 4px;
}


/* ========== RESPONSIVE ========== */
@media (max-width: 1024px) {
  .product-detail {
    grid-template-columns: 1fr;
    gap: var(--space-2xl);
  }

  .product-gallery__main {
    aspect-ratio: 16 / 9;
  }
}

@media (max-width: 768px) {
  .product-gallery__main {
    aspect-ratio: 1;
  }
  
  .upsell .section-header {
    flex-direction: column;
    align-items: flex-start;
    gap: var(--space-md);
  }

  .upsell__grid {
    grid-template-columns: 1fr;
    gap: var(--space-2xl);
  }
}
