/* ============================================
   Shop Cards Page Styles
   ============================================ */

/* Dynamic Hero Carousel */
.shop-hero-carousel {
  position: relative;
  width: 100%;
  height: 300px;
  border-radius: 16px;
  overflow: hidden;
  margin-bottom: 40px;
  background: var(--bg-color);
  box-shadow: 0 10px 30px rgba(0,0,0,0.1);
}

.carousel-slides-container {
  width: 100%;
  height: 100%;
  position: relative;
}

.carousel-slide {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  transition: opacity 0.8s ease-in-out;
  pointer-events: none;
}

.carousel-slide.active {
  opacity: 1;
  pointer-events: auto;
}

.carousel-bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 75% center;
  z-index: 1;
}

.carousel-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  /* Netflix-style smooth multi-stop gradient */
  background:
    linear-gradient(to right,
      #000000 0%,
      #000000 25%,
      rgba(0,0,0,0.85) 40%,
      rgba(0,0,0,0.5) 55%,
      rgba(0,0,0,0.2) 70%,
      rgba(0,0,0,0.05) 85%,
      transparent 100%
    );
  z-index: 2;
}

.carousel-content {
  position: relative;
  z-index: 3;
  width: 100%;
  height: 100%;
  padding: 36px 48px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  max-width: 500px;
}

.carousel-tag {
  color: var(--gold);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  margin-bottom: 12px;
}

.carousel-title {
  font-family: 'Playfair Display', serif;
  font-size: 36px;
  color: var(--white);
  margin-bottom: 10px;
  line-height: 1.1;
}

.carousel-desc {
  font-size: 14px;
  color: rgba(255,255,255,0.75);
  line-height: 1.4;
  margin-bottom: 20px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.carousel-actions {
  display: flex;
  gap: 12px;
  margin-bottom: 16px;
}

.carousel-btn {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  border-radius: 8px;
  font-weight: 500;
  font-size: 13px;
  cursor: pointer;
  transition: all 0.2s;
  text-decoration: none;
}

.btn-carousel-preview {
  background: rgba(255, 255, 255, 0.08) !important;
  color: #FFFFFF !important;
  border: 1px solid rgba(255, 255, 255, 0.15) !important;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  transition: all 0.3s ease;
}

.btn-carousel-preview:hover {
  background: rgba(255, 255, 255, 0.18) !important;
  border-color: rgba(255, 255, 255, 0.3) !important;
  transform: translateY(-1px);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.15);
}

.btn-carousel-send {
  background: transparent !important;
  color: var(--gold) !important;
  border: 1px solid var(--gold) !important;
  transition: all 0.3s ease;
}

.btn-carousel-send:hover {
  background: rgba(197, 163, 104, 0.1) !important;
  transform: translateY(-1px);
}

.carousel-duration {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  background: rgba(0,0,0,0.4);
  backdrop-filter: blur(4px);
  border-radius: 6px;
  color: var(--white);
  font-size: 12px;
  font-weight: 500;
}

/* Carousel Controls */
.carousel-controls {
  position: absolute;
  bottom: 24px;
  right: 24px;
  display: flex;
  gap: 8px;
  z-index: 10;
}

.carousel-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: rgba(255,255,255,0.3);
  cursor: pointer;
  transition: background 0.2s;
  border: none;
}

.carousel-dot.active {
  background: var(--white);
}

/* Shop Content Area */
.shop-content {
  display: flex;
  gap: 40px;
  padding: 120px 60px 80px;
  align-items: flex-start;
  background: var(--bg-color); /* Midnight Navy background */
  width: 100%;
  max-width: 100vw;
  box-sizing: border-box;
}

/* ---- Filter Sidebar ---- */
.filter-sidebar {
  width: 260px;
  flex-shrink: 0;
  position: sticky;
  top: calc(var(--header-height, 88px) + 20px);
  max-height: calc(100vh - var(--header-height, 88px) - 40px);
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: rgba(0,0,0,0.15) transparent;
}

.filter-sidebar::-webkit-scrollbar {
  width: 4px;
}

.filter-sidebar::-webkit-scrollbar-thumb {
  background: rgba(0,0,0,0.15);
  border-radius: 4px;
}

.filter-panel {
  background: var(--bg-color);
  border-radius: 12px;
  padding: 24px;
  border: 1px solid var(--border-color);
}

.filter-panel-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 24px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--border-color);
}

.filter-panel-header h3 {
  font-family: 'Inter', sans-serif;
  font-size: 16px;
  font-weight: 700;
  color: var(--navy);
  letter-spacing: -0.01em;
}

.filter-clear-btn {
  background: none;
  border: none;
  color: var(--gold);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  padding: 4px 8px;
  border-radius: 4px;
  transition: background 0.2s;
}

.filter-clear-btn:hover {
  background: rgba(192,152,88,0.1);
}

/* Filter Group */
.filter-group {
  margin-bottom: 24px;
}

.filter-group:last-child {
  margin-bottom: 0;
}

.filter-group-title {
  font-family: 'Inter', sans-serif;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--text-light);
  margin-bottom: 12px;
}

/* Checkbox Filters */
.filter-option {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 0;
  cursor: pointer;
  transition: color 0.2s;
}

.filter-option:hover {
  color: var(--gold);
}

.filter-option input[type="checkbox"] {
  appearance: none;
  -webkit-appearance: none;
  width: 18px;
  height: 18px;
  border: 2px solid var(--border-color);
  border-radius: 4px;
  cursor: pointer;
  position: relative;
  flex-shrink: 0;
  transition: all 0.2s;
}

.filter-option input[type="checkbox"]:checked {
  background: var(--navy);
  border-color: var(--navy);
}

.filter-option input[type="checkbox"]:checked::after {
  content: '';
  position: absolute;
  top: 2px;
  left: 5px;
  width: 5px;
  height: 9px;
  border: solid var(--white);
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}

.filter-option-label {
  font-size: 14px;
  color: var(--text-main);
  flex: 1;
}

.filter-option-count {
  font-size: 12px;
  color: var(--text-light);
  background: var(--white);
  padding: 2px 8px;
  border-radius: 10px;
  font-weight: 500;
}

.mood-option svg {
  color: var(--text-light);
  transition: color 0.2s;
}

.mood-option:hover svg,
.mood-option:hover .filter-option-label {
  color: var(--gold);
}

/* Price Range Filter */
.price-range-inputs {
  display: flex;
  align-items: center;
  gap: 12px;
}

.price-input-wrap {
  flex: 1;
  display: flex;
  align-items: center;
  background: var(--white);
  border: 1px solid var(--border-color);
  border-radius: 6px;
  padding-left: 10px;
  transition: border-color 0.2s;
}

.price-input-wrap:focus-within {
  border-color: var(--gold);
}

.price-currency {
  font-size: 14px;
  color: var(--text-light);
  user-select: none;
  margin-right: 4px;
}

.price-input {
  flex: 1;
  width: 100%;
  padding: 10px 10px 10px 0;
  border: none;
  background: transparent;
  font-size: 14px;
  font-family: 'Inter', sans-serif;
  color: var(--text-main);
}

.price-input:focus {
  outline: none;
}

.price-separator {
  color: var(--text-light);
  font-size: 13px;
  font-weight: 500;
}

/* ---- Main Grid Area ---- */
.shop-main {
  flex: 1;
  min-width: 0;
  width: 100%;
  max-width: 100%;
}

/* Category Rows */
.category-row {
  margin-bottom: 48px;
  min-width: 0;
  max-width: 100%;
}

.category-header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 16px;
  border-bottom: 1px solid rgba(0,0,0,0.05);
  padding-bottom: 12px;
}

.category-header h2 {
  font-family: 'Playfair Display', serif;
  font-size: 24px;
  color: var(--navy);
}

.category-view-all {
  font-size: 14px;
  font-weight: 500;
  color: var(--navy);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.category-view-all:hover {
  text-decoration: underline;
}

.category-carousel-wrapper {
  position: relative;
  container-type: inline-size;
}

.category-carousel-wrapper > .carousel-scroll-btn {
  position: absolute;
  top: calc((100cqw - 48px) / 8); /* Center vertically relative to the dynamic card image height (4-column desktop layout) using container queries */
  transform: translateY(-50%);
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: #040712 !important;
  border: 1px solid rgba(255, 255, 255, 0.15);
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #FFFFFF !important;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
  z-index: 10;
  transition: background-color 0.2s, transform 0.2s, box-shadow 0.2s;
}

.category-carousel-wrapper > .carousel-scroll-btn:hover {
  background: var(--gold) !important;
  color: #FFFFFF !important;
  transform: translateY(-50%) scale(1.08);
  box-shadow: 0 6px 16px rgba(0,0,0,0.22);
}

.category-carousel-wrapper > .carousel-scroll-btn:active {
  transform: translateY(-50%) scale(0.96);
  box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.category-carousel-wrapper > .carousel-scroll-btn.btn-left {
  left: -20px;
}

.category-carousel-wrapper > .carousel-scroll-btn.btn-right {
  right: -20px;
}

.category-carousel {
  display: flex;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  gap: 16px;
  align-items: stretch;
  padding-bottom: 16px; /* Space for scrollbar or shadow */
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none; /* Firefox */
  width: 100%;
}

.category-carousel::-webkit-scrollbar {
  display: none; /* Safari and Chrome */
}

.category-carousel .card {
  flex: 0 0 calc((100% - (3 * 16px)) / 4); /* Base 4 cards on desktop (much larger) */
  scroll-snap-align: start;
}

@media (min-width: 601px) {
  /* Shop Widescreen Card Override */
  #shop-grid .card {
    flex-direction: column !important;
    min-height: 0;
    border: none;
    background: transparent;
    box-shadow: none;
  }

  #shop-grid .card-image-wrapper {
    width: 100% !important;
    padding-top: 100% !important; /* 1:1 Square Aspect Ratio */
    height: 0 !important;
    border-right: none !important;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
    margin-bottom: 10px;
  }

  #shop-grid .card-duration {
    position: absolute;
    bottom: 8px;
    right: 8px;
    background: rgba(0, 0, 0, 0.6);
    color: var(--white);
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 600;
    z-index: 2;
    letter-spacing: 0.5px;
  }

  #shop-grid .card-content {
    padding: 0 !important;
    background: transparent;
  }

  #shop-grid .card-title {
    font-family: 'Playfair Display', serif;
    font-size: 13px;
    color: var(--navy);
    margin-bottom: 2px;
    white-space: normal;
  }

  #shop-grid .card-tag {
    font-size: 10px;
    color: var(--text-light);
    letter-spacing: 1px;
    text-transform: uppercase;
  }

  #shop-grid .card-meta {
    margin-bottom: 0;
  }

  /* Shop Buttons Override */
  #shop-grid .card-actions {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-top: 10px;
  }

  #shop-grid .btn-card {
    width: 100%;
    padding: 9px;
    border-radius: 4px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    font-family: 'Inter', sans-serif;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
  }

  #shop-grid .btn-preview {
    background: #FFFFFF !important;
    color: #0A0E1A !important;
    border: none;
  }

  #shop-grid .btn-preview:hover {
    background: #1a3060 !important;
    color: #FFFFFF !important;
  }

  #shop-grid .btn-share {
    background: transparent !important;
    color: #FFFFFF !important;
    border: 1px solid rgba(255, 255, 255, 0.25) !important;
  }

  #shop-grid .btn-share:hover {
    background: rgba(255, 255, 255, 0.1) !important;
    border-color: rgba(255, 255, 255, 0.4) !important;
    color: #FFFFFF !important;
  }

  #shop-grid .btn-personalize {
    background: var(--gold) !important;
    color: #0A0E1A !important;
    border: none;
  }

  #shop-grid .btn-personalize:hover {
    background: #b8903a !important;
    color: #0A0E1A !important;
  }

  /* Related Cards Desktop Override */
  .related-grid .card {
    cursor: pointer;
    background: var(--white);
    border: 1px solid var(--border-color);
    border-radius: 6px;
    overflow: hidden;
    transition: transform 0.2s, box-shadow 0.2s;
  }
  
  .related-grid .card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(197, 163, 104, 0.2), 0 0 10px rgba(197, 163, 104, 0.08);
    border-color: rgba(197, 163, 104, 0.3) !important;
  }

  .related-grid .card-image-wrapper {
    position: relative;
    padding-top: 133% !important; /* Portrait aspect ratio */
    overflow: hidden;
    background: var(--bg-color);
    width: 100% !important;
    height: 0 !important;
    border-right: none !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    margin-bottom: 0 !important;
  }

  .related-grid .card-image-wrapper img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s;
  }

  .related-grid .card-content {
    padding: 20px !important;
    background: var(--white) !important;
    display: block !important;
  }

  .related-grid .card-title {
    font-family: 'Playfair Display', serif;
    font-size: 1.3em;
    color: var(--navy);
    margin-bottom: 6px;
    font-weight: 700;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .related-grid .card-tag {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    color: var(--gold);
    letter-spacing: 1px;
    display: block;
    margin-bottom: 8px;
  }

  .related-grid .card-price {
    font-size: 16px;
    font-weight: 600;
    color: var(--navy);
    margin-top: 10px;
  }

  .related-grid .card-actions {
    display: flex;
    gap: 8px;
    margin-top: 16px;
    flex-wrap: wrap;
    flex-direction: row;
  }

  .related-grid .btn-card {
    flex: 1;
    padding: 8px 0;
    border: none;
    border-radius: 4px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    font-size: 0.85em;
    font-family: 'Inter', sans-serif;
    display: flex;
    align-items: center;
    justify-content: center;
  }

  .related-grid .btn-preview {
    background: #FFFFFF !important;
    color: #0A0E1A !important;
  }

  .related-grid .btn-preview:hover {
    background: #E2E8F0 !important;
    color: #040712 !important;
  }

  .related-grid .btn-share {
    border: 1px solid rgba(255, 255, 255, 0.25) !important;
    background: transparent !important;
    color: #FFFFFF !important;
  }

  .related-grid .btn-share:hover {
    background: rgba(255, 255, 255, 0.1) !important;
    border-color: rgba(255, 255, 255, 0.4) !important;
    color: #FFFFFF !important;
  }

  .related-grid .btn-personalize {
    background: var(--gold) !important;
    color: #0A0E1A !important;
  }

  .related-grid .btn-personalize:hover {
    background: #b8903a !important;
    color: #0A0E1A !important;
  }
}


/* Active filters display */
.active-filters-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 20px;
}

.active-filter-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  background: rgba(15,28,52,0.06);
  border-radius: 20px;
  font-size: 13px;
  color: var(--navy);
  font-weight: 500;
  animation: fadeIn 0.2s ease;
}

.active-filter-tag button {
  background: none;
  border: none;
  color: var(--text-light);
  cursor: pointer;
  font-size: 16px;
  line-height: 1;
  padding: 0;
  transition: color 0.2s;
}

.active-filter-tag button:hover {
  color: #c0392b;
}

@keyframes fadeIn {
  from { opacity: 0; transform: scale(0.95); }
  to { opacity: 1; transform: scale(1); }
}

/* Shop Grid */
.shop-grid {
  display: block;
}

.shop-grid .card {
  cursor: pointer;
}

.shop-empty-state {
  grid-column: 1 / -1;
  text-align: center;
  padding: 80px 20px;
}

.shop-empty-state svg {
  width: 64px;
  height: 64px;
  stroke: var(--border-color);
  stroke-width: 1.5;
  fill: none;
  margin-bottom: 20px;
}

.shop-empty-state h3 {
  font-size: 22px;
  margin-bottom: 8px;
}

.shop-empty-state p {
  color: var(--text-light);
  font-size: 15px;
}

/* Mobile filter toggle */
.mobile-filter-toggle {
  display: none;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  padding: 12px;
  background: var(--bg-color);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  font-size: 14px;
  font-weight: 600;
  color: var(--navy);
  cursor: pointer;
  margin-bottom: 20px;
  transition: background 0.2s;
}

.mobile-filter-toggle svg {
  width: 18px;
  height: 18px;
  stroke: currentColor;
  stroke-width: 2;
  fill: none;
}

.mobile-filter-toggle:hover {
  background: var(--border-color);
}

/* ============================================
   Card Detail View
   ============================================ */
.card-detail-view {
  animation: fadeIn 0.3s ease;
}

.detail-back-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: none;
  border: none;
  color: var(--text-light);
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  padding: 8px 0;
  margin-bottom: 28px;
  transition: color 0.2s;
}

.detail-back-btn:hover {
  color: var(--gold);
}

.detail-back-btn svg {
  width: 18px;
  height: 18px;
  stroke: currentColor;
  stroke-width: 2;
  fill: none;
}

.detail-layout {
  display: flex;
  gap: 60px;
  align-items: flex-start;
}

.detail-media {
  flex: 1;
  max-width: 280px;
  position: sticky;
  top: calc(var(--header-height, 88px) + 20px);
}

.detail-cover-wrap {
  position: relative;
  width: 100%;
  padding-top: 177.77%;
  overflow: hidden;
  border-radius: 12px;
  background: #f0f0f0;
  box-shadow: 0 20px 50px rgba(0,0,0,0.12);
  cursor: pointer;
  transition: transform 0.3s;
}

.detail-cover-wrap:hover {
  transform: scale(1.01);
}

.detail-cover-wrap img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.detail-cover-wrap .play-button {
  width: 64px !important;
  height: 64px !important;
  background: rgba(255, 255, 255, 0.15) !important;
  backdrop-filter: blur(8px) !important;
  -webkit-backdrop-filter: blur(8px) !important;
  border: 2px solid rgba(255, 255, 255, 0.7) !important;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.4) !important;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
}

.detail-cover-wrap:hover .play-button {
  transform: translate(-50%, -50%) scale(1.1) !important;
  background: #C5A368 !important;
  border-color: #C5A368 !important;
  box-shadow: 0 6px 20px rgba(197, 163, 104, 0.5) !important;
}

.detail-cover-wrap .play-icon {
  border-top: 10px solid transparent !important;
  border-bottom: 10px solid transparent !important;
  border-left: 16px solid #FFFFFF !important;
  margin-left: 5px !important;
  transition: border-left-color 0.3s ease !important;
}

.detail-cover-wrap:hover .play-icon {
  border-left-color: #040712 !important;
}

.detail-info {
  flex: 1;
  min-width: 0;
}

.detail-occasion {
  display: inline-block;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--gold);
  margin-bottom: 12px;
  padding: 4px 12px;
  background: rgba(192,152,88,0.1);
  border-radius: 20px;
}

.detail-name {
  font-family: 'Playfair Display', serif;
  font-size: 36px;
  color: var(--navy);
  margin-bottom: 16px;
  line-height: 1.2;
}

.detail-description {
  font-size: 15px;
  color: var(--text-light);
  line-height: 1.7;
  margin-bottom: 24px;
}

.detail-meta-row {
  display: flex;
  gap: 24px;
  margin-bottom: 28px;
  padding: 16px 0;
  border-top: 1px solid var(--border-color);
  border-bottom: 1px solid var(--border-color);
}

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

.detail-meta-item svg {
  width: 18px;
  height: 18px;
  stroke: var(--gold);
  stroke-width: 2;
  fill: none;
}

.detail-meta-item strong {
  color: var(--navy);
  font-weight: 600;
}

.detail-price {
  font-size: 32px;
  font-weight: 700;
  color: var(--navy);
  margin-bottom: 28px;
}

.detail-price .price-label {
  font-size: 13px;
  font-weight: 400;
  color: var(--text-light);
  display: block;
  margin-bottom: 4px;
}

.detail-actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.detail-actions .btn-card {
  padding: 14px;
  font-size: 15px;
  border-radius: 8px;
}

.detail-actions .btn-preview {
  background: #FFFFFF !important;
  color: #0A0E1A !important;
  border: none !important;
}

.detail-actions .btn-preview:hover {
  background: #E2E8F0 !important;
  color: #0A0E1A !important;
}

.detail-actions .btn-share {
  background: transparent !important;
  color: #FFFFFF !important;
  border: 1px solid rgba(255, 255, 255, 0.25) !important;
}

.detail-actions .btn-share:hover {
  background: rgba(255, 255, 255, 0.1) !important;
  border-color: rgba(255, 255, 255, 0.4) !important;
  color: #FFFFFF !important;
}

.detail-actions .btn-personalize {
  background: var(--gold) !important;
  color: #0A0E1A !important;
  border: none !important;
}

.detail-actions .btn-personalize:hover {
  background: #b8903a !important;
  color: #0A0E1A !important;
}

/* ---- Related Cards Section ---- */
.related-section {
  margin-top: 60px;
  padding-top: 40px;
  border-top: 1px solid var(--border-color);
}

.related-section h2 {
  font-family: 'Playfair Display', serif;
  font-size: 28px;
  color: var(--navy);
  margin-bottom: 8px;
}

.related-section .related-subtitle {
  color: var(--text-light);
  font-size: 14px;
  margin-bottom: 28px;
}


.related-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}

.related-grid .card {
  cursor: pointer;
}

/* ============================================
   Responsive
   ============================================ */
@media (max-width: 1200px) {
  .category-carousel-wrapper > .carousel-scroll-btn {
    top: calc((100cqw - 32px) / 6.4); /* Center vertically relative to 3.2-column card images using container queries */
  }
  .category-carousel .card {
    flex: 0 0 calc((100% - (2 * 16px)) / 3.2); /* 3.2 cards visible (50% larger) */
  }
  .related-grid {
    grid-template-columns: repeat(3, 1fr);
  }
  .detail-layout {
    gap: 40px;
  }
}

@media (max-width: 900px) {
  .shop-content {
    flex-direction: column;
    padding: 84px 20px 20px;
  }

  .shop-hero-carousel {
    height: 220px;
    margin-bottom: 24px;
    border-radius: 12px;
  }

  .carousel-content {
    padding: 24px 28px;
    max-width: 55%;
  }

  .carousel-tag {
    font-size: 10px;
    margin-bottom: 8px;
  }

  .carousel-title {
    font-size: 24px;
    margin-bottom: 8px;
  }

  .carousel-desc {
    font-size: 12px;
    margin-bottom: 14px;
    -webkit-line-clamp: 2;
  }

  .carousel-actions {
    gap: 10px;
    margin-bottom: 10px;
  }

  .carousel-btn {
    padding: 8px 14px;
    font-size: 12px;
  }

  .carousel-duration {
    font-size: 11px;
    padding: 4px 10px;
  }

  .carousel-controls {
    bottom: 16px;
    right: 16px;
  }

  .category-carousel-wrapper > .carousel-scroll-btn {
    display: none !important;
  }

  .filter-sidebar {
    width: 100%;
    position: static;
    max-height: none;
    display: none;
  }

  .filter-sidebar.mobile-visible {
    display: block;
  }

  .mobile-filter-toggle {
    display: flex;
  }

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

  .category-carousel .card {
    flex: 0 0 calc((100% - (1 * 16px)) / 2.2); /* 2.2 cards visible (50% larger) */
  }

  .detail-layout {
    flex-direction: column;
    gap: 30px;
  }

  .detail-media {
    max-width: 320px;
    margin: 0 auto;
    position: static;
  }

  .detail-name {
    font-size: 28px;
  }

  .related-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 600px) {
  .shop-content {
    padding: 76px 12px 12px;
  }

  .shop-hero-carousel {
    height: 200px;
    border-radius: 10px;
    margin-bottom: 20px;
  }

  .carousel-content {
    padding: 16px;
    max-width: 55%;
  }

  .carousel-tag {
    font-size: 8px;
    letter-spacing: 1.5px;
    margin-bottom: 4px;
  }

  .carousel-title {
    font-size: 16px;
    margin-bottom: 4px;
    line-height: 1.2;
  }

  .carousel-desc {
    font-size: 10px;
    margin-bottom: 8px;
    -webkit-line-clamp: 2;
    line-height: 1.3;
  }

  .carousel-actions {
    gap: 6px;
    margin-bottom: 6px;
    flex-wrap: nowrap;
  }

  .carousel-btn {
    padding: 4px 10px;
    font-size: 10px;
    border-radius: 5px;
    white-space: nowrap;
  }

  .carousel-duration {
    font-size: 9px;
    padding: 2px 6px;
  }

  .carousel-controls {
    bottom: 8px;
    right: 8px;
    gap: 5px;
  }

  .carousel-dot {
    width: 6px;
    height: 6px;
  }
  
  .category-carousel .card {
    flex: 0 0 calc((100% - 16px) / 1.2);
  }

  .category-carousel-wrapper > .carousel-scroll-btn {
    display: none !important;
  }

  /* Cards: horizontal scroll on mobile */
  .category-carousel {
    gap: 16px;
    padding-bottom: 24px;
  }
  .category-carousel .card {
    flex: 0 0 85%; /* 1 full card and a peek of the next */
  }

  .category-row-header h2 {
    font-size: 20px;
  }

  .related-grid {
    grid-template-columns: 1fr;
  }

  .detail-meta-row {
    flex-direction: column;
    gap: 12px;
  }
}

/* Custom Tooltip */
.card-desc-container {
  position: relative;
}
.custom-tooltip {
  visibility: hidden;
  opacity: 0;
  position: absolute;
  bottom: 100%;
  left: 50%;
  transform: translateX(-50%);
  background-color: rgba(30, 30, 30, 0.95);
  color: #fff;
  text-align: left;
  padding: 10px 14px;
  border-radius: 6px;
  z-index: 100;
  width: max-content;
  max-width: 250px;
  font-size: 13px;
  line-height: 1.4;
  box-shadow: 0 4px 12px rgba(0,0,0,0.2);
  transition: opacity 0.2s, visibility 0.2s;
  pointer-events: none;
  margin-bottom: 8px;
}
.custom-tooltip::after {
  content: "";
  position: absolute;
  top: 100%;
  left: 50%;
  margin-left: -6px;
  border-width: 6px;
  border-style: solid;
  border-color: rgba(30, 30, 30, 0.95) transparent transparent transparent;
}
.card-desc-container:hover .custom-tooltip {
  visibility: visible;
  opacity: 1;
}
.mobile-more-link {
  display: none;
}
.btn-info-details {
  display: none !important;
}


@media (max-width: 600px) {
  .card-actions {
    display: flex !important;
    flex-direction: row !important;
    gap: 8px !important;
    width: 100% !important;
    margin-top: 8px !important;
  }
  .card-actions .btn-preview,
  .card-actions .btn-share,
  .card-actions .btn-view-product {
    display: none !important; /* Trim extra buttons */
  }
  .card-actions .btn-info-details {
    display: flex !important;
    align-items: center;
    justify-content: center;
    background: #f4f2ee !important;
    color: #0A0E1A !important;
    border: 1px solid #E2DDD2 !important;
    padding: 6px 12px !important;
    font-size: 12px !important;
    border-radius: 4px !important;
    font-weight: 600 !important;
    cursor: pointer !important;
    flex: 1 !important;
    text-align: center;
    height: auto !important;
    font-family: 'Inter', sans-serif !important;
  }
  .card-actions .btn-personalize {
    display: flex !important;
    align-items: center;
    justify-content: center;
    background: rgba(192, 152, 88, 0.1) !important;
    color: var(--gold) !important;
    border: 1px solid rgba(192, 152, 88, 0.2) !important;
    padding: 6px 12px !important;
    font-size: 12px !important;
    border-radius: 4px !important;
    font-weight: 600 !important;
    cursor: pointer !important;
    flex: 1 !important;
    text-align: center;
    width: auto !important;
    height: auto !important;
    font-family: 'Inter', sans-serif !important;
  }
}

/* Card Image Golden Glow Hover States */
.card-image-wrapper, .card-media {
  transition: all 0.3s ease-in-out !important;
  position: relative;
}

.card:hover .card-image-wrapper,
.portal-card:hover .card-media,
.related-grid .card:hover .card-image-wrapper {
  box-shadow: 0 0 30px rgba(197, 163, 104, 0.65), 0 0 15px rgba(197, 163, 104, 0.3) !important;
  border-color: rgba(197, 163, 104, 0.75) !important;
  z-index: 2;
}

.card:hover, .portal-card:hover, .related-grid .card:hover {
  transform: translateY(-4px) !important;
  box-shadow: none !important; /* Remove shadow from the entire block as requested */
  border-color: rgba(197, 163, 104, 0.35) !important;
}

/* Home Page Collections Card Golden Glow Hover States */
.collection-image-wrapper {
  transition: all 0.3s ease-in-out !important;
  border: 1px solid rgba(197, 163, 104, 0.15) !important;
  position: relative;
}

#collections a.group:hover .collection-image-wrapper {
  box-shadow: 0 0 30px rgba(197, 163, 104, 0.65), 0 0 15px rgba(197, 163, 104, 0.3) !important;
  border-color: rgba(197, 163, 104, 0.75) !important;
  z-index: 2;
}

#collections a.group {
  transition: all 0.3s ease-in-out !important;
}

#collections a.group:hover {
  transform: translateY(-4px) !important;
  box-shadow: none !important; /* Ensure the block container itself has no shadow */
}
