/* =============================================================
   products.css
   All product-related styles: card, index, filter, detail,
   cart, checkout, thank-you
   Load via: <link rel="stylesheet" href="{{ asset('front/assets/css/products.css') }}">
   ============================================================= */


/* ── 1. SHARED VARIABLES ────────────────────────────────────── */
:root {
  --p-purple: #7d2a8d;
  --p-purple-dark: #4e1278;
  --p-purple-light: #f0edf8;
  --p-border: #ece8f5;
  --p-star: #f5a623;
}


/* ── 2. PRODUCT CARD ────────────────────────────────────────── */
.prod-card {
  display: flex;
  flex-direction: column;
  width: 100%;
  border-radius: 12px;
  overflow: hidden;
  background: #fff;
  border: 1px solid var(--p-border);
  transition: box-shadow .22s, transform .22s;
  position: relative;
}

.prod-card:hover {
  box-shadow: 0 8px 28px rgba(125, 42, 141, .15);
  transform: translateY(-3px);
}

/* Card image */
.prod-card__img-wrap {
  position: relative;
  width: 100%;
  padding-top: 75%;
  background: var(--p-purple-light);
  overflow: hidden;
}

.prod-card__img-wrap img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .35s ease;
}

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

.prod-card__img-wrap .img-placeholder {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #c4b8e0;
  font-size: 3rem;
}

/* Wishlist heart */
.prod-card__wish {
  position: absolute;
  top: 10px;
  right: 10px;
  z-index: 10;
  width: 34px;
  height: 34px;
  border-radius: 3px;
  background: rgba(255, 255, 255, .92);
  border: 1.5px solid #e0d6f5;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background .2s, border-color .2s;
  text-decoration: none;
}

.prod-card__wish:hover {
  background: #f3eeff;
  border-color: var(--p-purple);
}

.prod-card__wish svg {
  width: 17px;
  height: 17px;
}

.prod-card__wish .heart-icon {
  stroke: var(--p-purple);
  fill: none;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.prod-card__wish .heart-icon.filled {
  stroke: #e53935;
  fill: #e53935;
}

/* Card body */
.prod-card__body {
  flex: 1;
  display: flex;
  flex-direction: column;
  padding: 14px 14px 16px;
  gap: 6px;
}

.prod-card__name {
  font-size: .95rem;
  font-weight: 600;
  color: #1a1a2e;
  margin: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  text-decoration: none;
}

.prod-card__name:hover {
  color: var(--p-purple);
}

.prod-card__rating {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: .8rem;
  color: #777;
}

.prod-card__rating svg {
  width: 13px;
  height: 13px;
  fill: var(--p-star);
  stroke: none;
}

.prod-card__price {
  display: flex;
  align-items: baseline;
  gap: 8px;
  margin-top: auto;
}

.prod-card__price .price-now {
  font-size: 1.1rem;
  font-weight: 700;
  color: #1a1a2e;
}

.prod-card__price .price-orig {
  font-size: .85rem;
  color: #aaa;
  text-decoration: line-through;
}

/* Card CTA button */
.prod-card__btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  width: 100%;
  padding: 9px 0;
  margin-top: 10px;
  border-radius: 3px;
  background: var(--p-purple);
  color: #fff;
  font-family: "Space Grotesk", -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: .875rem;
  font-weight: 600;
  letter-spacing: 2px;
  text-transform: uppercase;
  border: none;
  cursor: pointer;
  transition: background .2s, transform .15s;
  text-decoration: none;
}

.prod-card__btn:hover {
  background: var(--p-purple);
  color: #fff;
  transform: scale(1.02);
}

.prod-card__btn:active {
  transform: scale(.98);
}

.prod-card__btn:disabled {
  opacity: .65;
  cursor: not-allowed;
  transform: none;
}

.prod-card__btn svg {
  width: 16px;
  height: 16px;
  fill: none;
  stroke: #fff;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* Grid helpers */
.product__all .row {
  display: flex;
  flex-wrap: wrap;
}

.product__all .col-xl-4,
.product__all .col-lg-4,
.product__all .col-md-6 {
  display: flex;
}


/* ── 3. PAGINATION ──────────────────────────────────────────── */
.pagination .page-link {
  border-radius: 50px;
  font-size: .875rem;
  padding: 6px 14px;
  transition: background .2s, color .2s, border-color .2s;
}

.pagination .page-link:hover,
.pagination .page-item.active .page-link {
  background: var(--p-purple) !important;
  border-color: var(--p-purple) !important;
  color: #fff !important;
}

.pagination .page-item.disabled .page-link {
  color: #ccc;
}


/* ── 4. FILTER SIDEBAR ──────────────────────────────────────── */

/* Outer sticky wrapper */
.filter-sidebar-wrap {
  position: sticky;
  top: 90px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

/* Scrollable filter sections — explicit max-height, no flex tricks */
.product__sidebar {
  display: flex;
  flex-direction: column;
  gap: 12px;
  max-height: calc(100vh - 310px);
  overflow-y: auto;
  overflow-x: hidden;
  padding-right: 4px;
  scrollbar-width: thin;
  scrollbar-color: var(--p-border) transparent;
}

.product__sidebar::-webkit-scrollbar {
  width: 4px;
}

.product__sidebar::-webkit-scrollbar-track {
  background: transparent;
}

.product__sidebar::-webkit-scrollbar-thumb {
  background: var(--p-border);
  border-radius: 4px;
}

/* Card panel for each sidebar section */
.product__sidebar-single {
  background: #fff;
  border: 1px solid var(--p-border);
  border-radius: 3px;
  padding: 16px 18px;
  flex-shrink: 0;
}

/* Section title */
.product__sidebar-title {
  font-family: var(--font-heading) !important;
  font-size: 11px !important;
  font-weight: 700 !important;
  letter-spacing: .07em !important;
  text-transform: uppercase !important;
  color: #999 !important;
  margin: 0 0 12px !important;
  padding-bottom: 8px !important;
  border-bottom: 1px solid var(--p-border) !important;
  line-height: 1.2 !important;
}

/* Strip double-card from shop.css sub-blocks */
.shop-category,
.shop-color-option {
  background: transparent !important;
  padding: 0 !important;
  border-radius: 0 !important;
}

.shop-category .product__sidebar-title,
.shop-color-option .product__sidebar-title {
  margin-left: 0 !important;
}

.shop-category ul li {
  font-size: inherit;
  margin-bottom: 0;
  line-height: inherit;
}

/* Checkbox / radio list */
.filter-checklist {
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.filter-checklist li {
  margin-bottom: 0;
}

.filter-check-label {
  display: flex;
  align-items: center;
  gap: 9px;
  cursor: pointer;
  font-size: 13px;
  color: #444;
  user-select: none;
  padding: 3px 0;
  border-radius: 6px;
  transition: color .15s;
}

.filter-check-label:hover {
  color: var(--p-purple);
}

/* Hide both checkbox and radio — replaced by custom box */
.filter-check-label input[type="checkbox"],
.filter-check-label input[type="radio"] {
  display: none;
}

.filter-check-box {
  width: 18px;
  height: 18px;
  border: 1.5px solid #ccc;
  border-radius: 4px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background .15s, border-color .15s;
}

/* Radio gets a pill shape */
.filter-check-label input[type="radio"] + .filter-check-box {
  border-radius: 50%;
}

.filter-check-label input:checked + .filter-check-box {
  background: var(--p-purple);
  border-color: var(--p-purple);
}

/* Checkbox tick */
.filter-check-label input[type="checkbox"]:checked + .filter-check-box::after {
  content: '';
  width: 10px;
  height: 6px;
  border-left: 2px solid #fff;
  border-bottom: 2px solid #fff;
  transform: rotate(-45deg) translateY(-1px);
  display: block;
}

/* Radio dot */
.filter-check-label input[type="radio"]:checked + .filter-check-box::after {
  content: '';
  width: 8px;
  height: 8px;
  background: #fff;
  border-radius: 50%;
  display: block;
}

.filter-check-label:hover .filter-check-box {
  border-color: var(--p-purple);
}

.filter-stars {
  display: inline-flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 1px;
}

/* Sidebar search input */
.sidebar-search {
  position: relative;
}

.sidebar-search input {
  width: 100%;
  height: 38px;
  border: 1.5px solid var(--p-border);
  border-radius: 20px;
  padding: 0 12px 0 34px;
  font-size: 13px;
  color: #333;
  background: var(--p-purple-light);
  outline: none;
  transition: border-color .2s, background .2s;
}

.sidebar-search input:focus {
  border-color: var(--p-purple);
  background: #fff;
}

.sidebar-search .si-icon {
  position: absolute;
  left: 11px;
  top: 50%;
  transform: translateY(-50%);
  color: #aaa;
  font-size: 12px;
  pointer-events: none;
}

/* Color swatches */
.filter-color-swatches {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.color-swatch {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  border: 2.5px solid transparent;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: border-color .18s, transform .15s;
  padding: 0;
  outline: none;
}

.color-swatch:hover {
  transform: scale(1.15);
}

.color-swatch.active {
  border-color: var(--p-purple);
  transform: scale(1.1);
}

.color-swatch svg {
  width: 14px;
  height: 14px;
  pointer-events: none;
}

/* Recent products in sidebar */
.recent-product-list {
  margin: 0;
  padding: 0;
}

.recent-product-list li {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  margin-bottom: 10px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--p-border);
}

.recent-product-list li:last-child {
  margin-bottom: 0;
  padding-bottom: 0;
  border-bottom: none;
}

.recent-product-img {
  flex-shrink: 0;
}

.recent-product-img img {
  width: 54px;
  height: 54px;
  object-fit: cover;
  border-radius: 8px;
  display: block;
}

.recent-product-list .content h5 {
  font-size: 13px;
  font-weight: 600;
  margin: 0 0 3px;
}

.recent-product-list .content .price {
  font-size: 13px;
  color: var(--p-purple);
  font-weight: 600;
  margin: 0 0 3px;
}

.recent-product-list .content .review .fa-star {
  font-size: 11px;
  color: var(--p-star);
}

.recent-product-list .content .review .fa-star.color {
  color: #ddd;
}

/* Apply / Reset buttons — side by side inside the pinned bar */
.filter-actions-bar {
  display: flex;
  flex-direction: row;
  gap: 8px;
  margin-right: 4px;
}

.filter-apply-btn,
.filter-reset-btn {
  flex: 1;
  height: 38px;
  border-radius: 3px;
  font-family: "Space Grotesk", -apple-system, BlinkMacSystemFont, sans-serif !important;
  font-size: 15px;
  font-weight: 500 !important;
  letter-spacing: 2px;
  text-transform: uppercase !important;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  cursor: pointer;
  transition: background .2s, color .2s, border-color .2s;
  text-decoration: none;
  white-space: nowrap;
}

/* Matches header's Register button (.main-menu__btn-box-2 .thm-btn) */
.filter-apply-btn {
  background: var(--p-purple) !important;
  color: #fff !important;
  border: none;
}

.filter-apply-btn:hover {
  background: var(--p-purple) !important;
}

/* Matches header's Login button (.main-menu__btn-box-1 .thm-btn) — outline style */
.filter-reset-btn {
  background: transparent !important;
  border: 1px solid var(--fistudy-bdr-color) !important;
  color: var(--fistudy-black) !important;
}

.filter-reset-btn:hover {
  background: transparent !important;
  border-color: var(--fistudy-bdr-color) !important;
  color: var(--fistudy-black) !important;
}

/* Price ranger labels */
.ranger-labels {
  display: flex;
  justify-content: space-between;
  margin-bottom: 10px;
}

.ranger-val {
  display: inline-block;
  padding: 3px 10px;
  border: 1.5px solid var(--p-border);
  border-radius: 3px;
  background: var(--p-purple-light);
  font-size: 12px;
  font-weight: 700;
  color: var(--p-purple);
}


/* ── 5. DETAIL PAGE ─────────────────────────────────────────── */
/* Image slider */
.img-slider {
  position: relative;
  border-radius: 14px;
  overflow: hidden;
  background: var(--p-purple-light);
  user-select: none;
}

.img-slider__track {
  display: flex;
  transition: transform .38s cubic-bezier(.4, 0, .2, 1);
  will-change: transform;
}

.img-slider__slide {
  flex: 0 0 100%;
  width: 100%;
}

.img-slider__slide img,
.img-slider__slide video {
  width: 100%;
  height: 480px;
  object-fit: cover;
  object-position: center;
  display: block;
  background: #000;
}

.img-slider__arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 10;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: rgba(255, 255, 255, .88);
  border: 1.5px solid #e0d6f5;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background .18s, border-color .18s, opacity .18s;
  box-shadow: 0 2px 8px rgba(0, 0, 0, .1);
  opacity: .85;
  color: var(--p-purple);
}

.img-slider__arrow:hover {
  background: var(--p-purple);
  border-color: var(--p-purple);
  color: #fff;
  opacity: 1;
}

.img-slider__arrow svg {
  width: 18px;
  height: 18px;
  stroke: currentColor;
  fill: none;
  stroke-width: 2.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.img-slider__prev {
  left: 12px;
}

.img-slider__next {
  right: 12px;
}

.img-slider__dots {
  position: absolute;
  bottom: 12px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 6px;
}

.img-slider__dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: rgba(255, 255, 255, .55);
  border: 1.5px solid rgba(255, 255, 255, .8);
  cursor: pointer;
  transition: background .18s, transform .18s;
}

.img-slider__dot.active {
  background: #fff;
  transform: scale(1.25);
}

/* Thumbnail strip */
.thumb-strip {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 12px;
}

.thumb-item {
  position: relative;
  width: 68px;
  height: 68px;
  border-radius: 8px;
  overflow: hidden;
  cursor: pointer;
  border: 2px solid transparent;
  transition: border-color .18s, opacity .18s;
  opacity: .7;
  flex-shrink: 0;
  background: #000;
}

.thumb-item img,
.thumb-item video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  pointer-events: none;
}

.thumb-item.active {
  border-color: var(--p-purple);
  opacity: 1;
}

.thumb-item:hover {
  opacity: 1;
}

.thumb-play-icon {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
  background: rgba(0, 0, 0, .15);
}

.thumb-play-icon svg {
  width: 20px;
  height: 20px;
  filter: drop-shadow(0 1px 3px rgba(0, 0, 0, .7));
}


/* ── 6. CART PAGE ───────────────────────────────────────────── */
.cart-item .product-img {
  width: 100%;
  height: 120px;
  object-fit: cover;
  border-radius: 6px;
}


/* ── 7. THANK-YOU PAGE ──────────────────────────────────────── */
.success-circle {
  width: 90px;
  height: 90px;
  background: #dff5e8;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: auto;
}

.success-circle i {
  font-size: 36px;
  color: #22c55e;
}

/* Item card */
.cart-item {
  background: #fff;
  border: 1px solid #ede9f6;
  border-radius: 14px;
  padding: 18px 20px;
  margin-bottom: 14px;
  transition: box-shadow .2s;
}

.cart-item:hover {
  box-shadow: 0 4px 18px rgba(125, 42, 141, .08);
}

/* Product image */
.cart-item__img {
  width: 100px;
  height: 100px;
  object-fit: cover;
  border-radius: 10px;
  flex-shrink: 0;
}

/* Category label */
.cart-item__category {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: #7d2a8d;
  margin-bottom: 3px;
}

/* Product name */
.cart-item__name {
  font-size: 15px;
  font-weight: 600;
  color: #1a1a2e;
  text-decoration: none;
  line-height: 1.35;
  display: block;
  margin-bottom: 4px;
}

.cart-item__name:hover {
  color: #7d2a8d;
}

/* SKU */
.cart-item__sku {
  font-size: 11px;
  color: #aaa;
  margin-bottom: 6px;
}

/* Attribute pill */
.cart-item__badge {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  font-size: 11px;
  font-weight: 500;
  color: #555;
  background: #f4f0fb;
  border: 1px solid #e2d9f3;
  border-radius: 20px;
  padding: 2px 10px;
}

/* Qty stepper */
.cart-qty {
  display: inline-flex;
  align-items: center;
  border: 1.5px solid #e2d9f3;
  border-radius: 3px;
  overflow: hidden;
  height: 34px;
}

.cart-qty__btn {
  width: 32px;
  height: 32px;
  background: #f8f5ff;
  border: none;
  font-size: 14px;
  cursor: pointer;
  color: #7d2a8d;
  font-weight: 600;
  transition: background .15s;
  display: flex;
  align-items: center;
  justify-content: center;
}

.cart-qty__btn:hover {
  background: #ede5ff;
}

.cart-qty__input {
  width: 40px;
  height: 32px;
  border: none;
  border-left: 1px solid #e2d9f3;
  border-right: 1px solid #e2d9f3;
  text-align: center;
  font-size: 13px;
  font-weight: 600;
  color: #1a1a2e;
  background: #fff;
  -moz-appearance: textfield;
}

.cart-qty__input::-webkit-inner-spin-button,
.cart-qty__input::-webkit-outer-spin-button {
  -webkit-appearance: none;
}

/* Price block */
.cart-item__price-now {
  font-size: 16px;
  font-weight: 700;
  color: #1a1a2e;
}

.cart-item__price-orig {
  font-size: 13px;
  color: #b0b0b0;
  text-decoration: line-through;
  margin-left: 6px;
}

.cart-item__price-save {
  font-size: 12px;
  color: #16a34a;
  font-weight: 600;
  margin-left: 6px;
}

/* Remove button */
.cart-item__remove {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: #fff5f5;
  border: 1px solid #ffd5d5;
  color: #e53935;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background .15s;
  font-size: 13px;
  flex-shrink: 0;
}

.cart-item__remove:hover {
  background: #fee2e2;
}

/* Delivery tag */
.cart-item__delivery {
  font-size: 12px;
  color: #16a34a;
  display: flex;
  align-items: center;
  gap: 4px;
  margin-top: 8px;
}

/* ── Order Summary card ─────────────────────────────────────── */
.order-summary {
  background: #fff;
  border: 1px solid #ede9f6;
  border-radius: 14px;
  padding: 24px;
  position: sticky;
  top: 90px;
}

.order-summary__title {
  font-size: 16px;
  font-weight: 700;
  color: #1a1a2e;
  margin-bottom: 18px;
  padding-bottom: 12px;
  border-bottom: 1px solid #f0edf8;
}

.summary-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 13.5px;
  color: #555;
  padding: 7px 0;
}

.summary-row+.summary-row {
  border-top: 1px solid #f8f5ff;
}

.summary-row__label {}

.summary-row__val {
  font-weight: 500;
  color: #1a1a2e;
}

.summary-row--save .summary-row__val {
  color: #16a34a;
  font-weight: 600;
}

.summary-row--credits .summary-row__val {
  color: #7d2a8d;
  font-weight: 600;
}

.summary-row--total {
  border-top: 2px solid #ede9f6 !important;
  margin-top: 6px;
  padding-top: 14px;
}

.summary-row--total .summary-row__label {
  font-size: 15px;
  font-weight: 700;
  color: #1a1a2e;
}

.summary-row--total .summary-row__val {
  font-size: 18px;
  font-weight: 800;
  color: #7d2a8d;
}

/* Credits box */
.credits-box {
  background: #f8f0ff;
  border: 1px solid #e0c8ff;
  border-radius: 10px;
  padding: 12px 14px;
  margin-bottom: 16px;
}

.credits-box__label {
  font-size: 12px;
  font-weight: 700;
  color: #7d2a8d;
  margin-bottom: 8px;
}

.credits-box__balance {
  font-size: 11px;
  color: #888;
}

/* Checkout button */
.checkout-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  padding: 13px;
  border-radius: 3px;
  background: #7d2a8d;
  color: #fff;
  font-family: "Space Grotesk", -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  border: none;
  cursor: pointer;
  text-decoration: none;
  transition: background .2s, transform .15s;
  margin-top: 18px;
}

.checkout-btn:hover {
  background: #7d2a8d;
  color: #fff;
  transform: translateY(-1px);
}

/* Secure badge */
.secure-badge {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  font-size: 11px;
  color: #aaa;
  margin-top: 10px;
}

