/* PRODUCTS PAGE - GLASSMORPHISM DESIGN */

/* Background with gradient blobs */
.products-page-bg {
  background-color: #f3f4f6;
  background-image: 
    radial-gradient(at 0% 0%, rgba(106, 27, 154, 0.15) 0px, transparent 50%),
    radial-gradient(at 100% 0%, rgba(154, 205, 50, 0.15) 0px, transparent 50%),
    radial-gradient(at 100% 100%, rgba(106, 27, 154, 0.1) 0px, transparent 50%),
    radial-gradient(at 0% 100%, rgba(154, 205, 50, 0.1) 0px, transparent 50%);
  background-attachment: fixed;
  min-height: 100vh;
}

/* Animated background blobs */
.bg-blob {
  position: fixed;
  border-radius: 50%;
  filter: blur(80px);
  mix-blend-mode: multiply;
  pointer-events: none;
  z-index: -1;
}

.bg-blob-1 {
  top: -10%;
  left: -10%;
  width: 500px;
  height: 500px;
  background: rgba(106, 27, 154, 0.2);
  animation: pulse-slow 8s ease-in-out infinite;
}

.bg-blob-2 {
  bottom: 10%;
  right: -5%;
  width: 400px;
  height: 400px;
  background: rgba(154, 205, 50, 0.2);
}

.bg-blob-3 {
  top: 40%;
  left: 30%;
  width: 300px;
  height: 300px;
  background: rgba(59, 130, 246, 0.15);
}

@keyframes pulse-slow {
  0%, 100% { opacity: 0.6; transform: scale(1); }
  50% { opacity: 0.8; transform: scale(1.05); }
}

/* Glass Panel */
.glass-panel {
  background: rgba(255, 255, 255, 0.4);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(255, 255, 255, 0.4);
  box-shadow: 0 8px 32px 0 rgba(31, 38, 135, 0.07);
  border-radius: 1rem;
}

/* Glass Card Overlay */
.glass-card-overlay {
  background: rgba(255, 255, 255, 0.75);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border-top: 1px solid rgba(255, 255, 255, 0.5);
}

/* Glass Button */
.glass-button {
  background: rgba(255, 255, 255, 0.3);
  backdrop-filter: blur(4px);
  border: 1px solid rgba(255, 255, 255, 0.4);
  transition: all 0.3s ease;
}

.glass-button:hover {
  background: rgba(106, 27, 154, 0.9);
  color: white;
  border-color: rgba(106, 27, 154, 1);
}

/* Products Section */
.products-section {
  padding: 3rem 0;
}

/* Sidebar */
.products-sidebar {
  position: sticky;
  top: 100px;
}

.sidebar-title {
  font-family: 'Playfair Display', serif;
  font-size: 1.25rem;
  font-weight: 700;
  color: #1f2937;
  margin-bottom: 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* Category Navigation */
.category-nav {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

/* Category Row */
.category-row {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.category-link {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem 1rem;
  border-radius: 0.75rem;
  color: #4b5563;
  text-decoration: none;
  font-size: 0.875rem;
  font-weight: 500;
  transition: all 0.3s ease;
  flex: 1;
}

.category-link:hover {
  background: rgba(255, 255, 255, 0.4);
  color: #6A1B9A;
}

.category-link.active {
  background: rgba(255, 255, 255, 0.4);
  border: 1px solid rgba(255, 255, 255, 0.4);
  box-shadow: 0 2px 8px rgba(0,0,0,0.05);
  color: #6A1B9A;
  font-weight: 600;
}

.category-link .material-symbols-outlined {
  font-size: 1.125rem;
  color: #9ca3af;
  transition: color 0.3s;
}

.category-link:hover .material-symbols-outlined,
.category-link.active .material-symbols-outlined {
  color: #6A1B9A;
}

/* Category Toggle Button */
.category-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border: none;
  background: rgba(255, 255, 255, 0.3);
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.3s ease;
  color: #6b7280;
}

.category-toggle:hover {
  background: rgba(106, 27, 154, 0.1);
  color: #6A1B9A;
}

.category-toggle .material-symbols-outlined {
  transition: transform 0.3s ease;
}

.category-item.open .category-toggle .material-symbols-outlined {
  transform: rotate(90deg);
}

.category-item.open .category-toggle {
  background: rgba(106, 27, 154, 0.1);
  color: #6A1B9A;
}

/* Subcategory */
.subcategory-list {
  padding-left: 1rem;
  margin-left: 1rem;
  border-left: 2px solid rgba(106, 27, 154, 0.2);
  margin-top: 0.5rem;
  margin-bottom: 0.5rem;
  display: none;
}

.category-item.open .subcategory-list {
  display: block;
}

.subcategory-link {
  display: block;
  padding: 0.5rem 1rem;
  font-size: 0.875rem;
  color: #6b7280;
  border-radius: 0.5rem;
  transition: all 0.2s;
  text-decoration: none;
}

.subcategory-link:hover,
.subcategory-link.active {
  background: rgba(106, 27, 154, 0.05);
  color: #6A1B9A;
}

/* Section Header */
.section-header {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin-bottom: 2rem;
  padding: 1rem;
}

@media (min-width: 768px) {
  .section-header {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
  }
}

.section-title {
  font-family: 'Playfair Display', serif;
  font-size: 1.5rem;
  font-weight: 700;
  color: #1f2937;
  margin: 0;
}

.product-count {
  font-size: 0.875rem;
  color: #6b7280;
}

.product-count span {
  color: #6A1B9A;
  font-weight: 700;
}

/* Products Grid */
.products-grid {
  display: grid;
  grid-template-columns: repeat(1, 1fr);
  gap: 1.5rem;
}

@media (min-width: 640px) {
  .products-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1024px) {
  .products-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* Product Card */
.product-card {
  position: relative;
  border-radius: 1rem;
  overflow: hidden;
  height: 380px;
  transition: all 0.5s ease;
}

.product-card:hover {
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.15);
  transform: translateY(-4px);
}

.product-card-bg {
  position: absolute;
  inset: 0;
  background: white;
  opacity: 0.4;
}

.product-image-wrapper {
  position: absolute;
  inset: 0;
  bottom: 80px;
  z-index: 10;
  overflow: hidden;
}

.product-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.7s ease;
}

.product-card:hover .product-image {
  transform: scale(1.08);
}

/* Product Overlay */
.product-overlay {
  position: absolute;
  inset: 0;
  background: rgba(106, 27, 154, 0.1);
  backdrop-filter: blur(2px);
  opacity: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  z-index: 20;
  transition: opacity 0.3s ease;
  pointer-events: none;
}

.product-card:hover .product-overlay {
  opacity: 1;
  pointer-events: auto;
}

.overlay-btn {
  background: white;
  color: #1f2937;
  padding: 0.75rem;
  border-radius: 50%;
  box-shadow: 0 10px 25px rgba(0,0,0,0.1);
  transition: all 0.3s ease;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
}

.overlay-btn:hover {
  transform: scale(1.1);
}

.overlay-btn.primary {
  background: #6A1B9A;
  color: white;
}

.overlay-btn.primary:hover {
  background: #4a148c;
}

/* Product Info */
.product-info {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 1.25rem;
  border-radius: 0 0 1rem 1rem;
  z-index: 25;
  transition: transform 0.3s ease;
  background: linear-gradient(0deg, rgba(255,255,255,0.95) 0%, rgba(255,255,255,0.9) 100%);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-top: 1px solid rgba(106, 27, 154, 0.1);
}

.product-card:hover .product-info {
  transform: translateY(-4px);
  background: linear-gradient(0deg, rgba(255,255,255,1) 0%, rgba(255,255,255,0.95) 100%);
  box-shadow: 0 -10px 30px rgba(0,0,0,0.1);
}

/* Make entire card clickable */
.product-card-link {
  position: absolute;
  inset: 0;
  z-index: 5;
}

.product-category-tag {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: #6A1B9A;
  font-weight: 700;
  margin-bottom: 0.5rem;
  display: inline-block;
  background: rgba(106, 27, 154, 0.1);
  padding: 0.25rem 0.75rem;
  border-radius: 1rem;
}

.product-title {
  font-family: 'Playfair Display', serif;
  font-size: 1.15rem;
  font-weight: 700;
  color: #1f2937;
  line-height: 1.4;
  margin: 0;
}

.product-card:hover .product-title {
  color: #6A1B9A;
}

.product-title a {
  color: inherit;
  text-decoration: none;
}

.product-code {
  font-size: 0.75rem;
  color: #6b7280;
  margin-top: 0.25rem;
}

/* Pagination */
.modern-pagination {
  display: inline-flex;
  padding: 0.5rem;
  gap: 0.5rem;
  margin-top: 4rem;
}

.pagination-btn {
  width: 2.5rem;
  height: 2.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 0.5rem;
  font-weight: 500;
  text-decoration: none;
  transition: all 0.3s ease;
}

.pagination-btn:hover {
  transform: scale(1.05);
}

.pagination-btn.active {
  background: #6A1B9A;
  color: white;
  box-shadow: 0 4px 15px rgba(106, 27, 154, 0.3);
  transform: scale(1.05);
}

/* No Products */
.no-products {
  text-align: center;
  padding: 4rem 2rem;
}

.no-products .material-symbols-outlined {
  font-size: 4rem;
  color: #d1d5db;
  margin-bottom: 1rem;
}

.no-products h3 {
  color: #4b5563;
  margin-bottom: 0.5rem;
}

.no-products p {
  color: #9ca3af;
}

/* Filter Badge */
.filter-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: linear-gradient(135deg, #6A1B9A 0%, #9c27b0 100%);
  color: white;
  padding: 0.5rem 1rem;
  border-radius: 2rem;
  font-size: 0.875rem;
  margin-bottom: 1.5rem;
}

.filter-badge a {
  color: white;
  opacity: 0.8;
  margin-left: 0.5rem;
}

.filter-badge a:hover {
  opacity: 1;
}

/* Responsive */
@media (max-width: 1023px) {
  .products-sidebar {
    position: static;
    margin-bottom: 2rem;
  }
}
