/* Catalog products — genetics theme + rich animations */
.catalog-page {
  position: relative;
  padding: 0 0 4rem;
  overflow: hidden;
}

/* ── Hero ── */
.catalog-hero-wrap {
  position: relative;
  margin: -0.5rem -1rem 2.5rem;
  padding: 3rem 1.5rem 3.5rem;
  border-radius: 0 0 32px 32px;
  overflow: hidden;
  min-height: 280px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.catalog-hero-bg {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 80% 60% at 20% 30%, rgba(0, 229, 255, 0.12), transparent 60%),
    radial-gradient(ellipse 70% 50% at 80% 70%, rgba(139, 92, 246, 0.1), transparent 55%),
    linear-gradient(180deg, rgba(5, 8, 22, 0.2) 0%, var(--bg-deep, #050816) 100%);
  animation: catalog-bg-shift 12s ease-in-out infinite alternate;
}

@keyframes catalog-bg-shift {
  0% { filter: hue-rotate(0deg); transform: scale(1); }
  100% { filter: hue-rotate(12deg); transform: scale(1.03); }
}

#catalogHeroCanvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0.7;
  pointer-events: none;
}

.catalog-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(40px);
  pointer-events: none;
  animation: catalog-float 8s ease-in-out infinite;
}

.catalog-orb-1 {
  width: 180px;
  height: 180px;
  background: rgba(0, 229, 255, 0.15);
  top: 10%;
  right: 8%;
  animation-delay: 0s;
}

.catalog-orb-2 {
  width: 140px;
  height: 140px;
  background: rgba(139, 92, 246, 0.12);
  bottom: 15%;
  left: 5%;
  animation-delay: -3s;
}

.catalog-orb-3 {
  width: 100px;
  height: 100px;
  background: rgba(37, 99, 235, 0.15);
  top: 50%;
  left: 40%;
  animation-delay: -5s;
}

@keyframes catalog-float {
  0%, 100% { transform: translate(0, 0) scale(1); }
  33% { transform: translate(12px, -18px) scale(1.05); }
  66% { transform: translate(-10px, 10px) scale(0.95); }
}

.catalog-hero-dna {
  position: absolute;
  left: 4%;
  top: 50%;
  transform: translateY(-50%);
  width: 60px;
  opacity: 0.15;
  animation: catalog-dna-spin 20s linear infinite;
}

.catalog-hero-dna-right {
  left: auto;
  right: 4%;
  animation-direction: reverse;
}

@keyframes catalog-dna-spin {
  from { transform: translateY(-50%) rotate(0deg); }
  to { transform: translateY(-50%) rotate(360deg); }
}

.catalog-hero {
  position: relative;
  z-index: 2;
  text-align: center;
  max-width: 680px;
}

.catalog-hero .section-label {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.85rem;
  animation: catalog-fade-down 0.7s ease both;
}

.catalog-hero .section-label::before {
  content: '';
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: linear-gradient(135deg, #00E5FF, #8B5CF6);
  animation: catalog-pulse-dot 2s ease-in-out infinite;
}

@keyframes catalog-pulse-dot {
  0%, 100% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.4); opacity: 0.6; }
}

.catalog-hero h1 {
  font-size: clamp(1.85rem, 4.5vw, 2.75rem);
  font-weight: 800;
  color: var(--white, #ffffff);
  margin-bottom: 0.65rem;
  animation: catalog-fade-down 0.7s ease 0.1s both;
}

.catalog-hero h1 .gradient-text {
  background: linear-gradient(135deg, #00E5FF 0%, #8B5CF6 50%, #3B82F6 100%);
  background-size: 200% auto;
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  animation: catalog-gradient-flow 4s ease infinite;
}

@keyframes catalog-gradient-flow {
  0%, 100% { background-position: 0% center; }
  50% { background-position: 100% center; }
}

.catalog-hero-desc {
  color: var(--text-muted, #94a3b8);
  max-width: 480px;
  margin: 0 auto;
  font-size: 0.95rem;
  line-height: 1.7;
  animation: catalog-fade-down 0.7s ease 0.2s both;
}

.catalog-stats-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin-top: 1.25rem;
  padding: 0.45rem 1.1rem;
  border-radius: 100px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--glass-border, rgba(255, 255, 255, 0.08));
  backdrop-filter: blur(12px);
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--text-light, #e2e8f0);
  animation: catalog-fade-down 0.7s ease 0.3s both;
  box-shadow: var(--glass-shadow, 0 4px 24px rgba(0, 0, 0, 0.35));
}

.catalog-stats-pill strong {
  color: var(--cyan, #00E5FF);
  font-size: 1rem;
}

.catalog-breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  margin-top: 1.5rem;
  font-size: 0.875rem;
  animation: catalog-fade-down 0.7s ease 0.35s both;
}

.catalog-breadcrumb a {
  color: var(--cyan, #00E5FF);
  text-decoration: none;
  font-weight: 600;
  transition: color 0.2s, transform 0.2s;
}

.catalog-breadcrumb a:hover {
  color: var(--purple, #8B5CF6);
  transform: translateY(-1px);
}

.catalog-breadcrumb .sep {
  color: var(--text-muted, #64748b);
}

.catalog-breadcrumb .current {
  color: var(--text-light, #e2e8f0);
}

@keyframes catalog-fade-down {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ── Reveal cards ── */
.catalog-reveal {
  opacity: 0;
  transform: translateY(28px) scale(0.97);
  transition: opacity 0.55s cubic-bezier(0.22, 1, 0.36, 1),
              transform 0.55s cubic-bezier(0.22, 1, 0.36, 1);
}

.catalog-reveal.visible {
  opacity: 1;
  transform: translateY(0) scale(1);
}

.catalog-reveal-delay-1 { transition-delay: 0.06s; }
.catalog-reveal-delay-2 { transition-delay: 0.12s; }
.catalog-reveal-delay-3 { transition-delay: 0.18s; }
.catalog-reveal-delay-4 { transition-delay: 0.24s; }
.catalog-reveal-delay-5 { transition-delay: 0.30s; }
.catalog-reveal-delay-6 { transition-delay: 0.36s; }

/* ── Grid & cards ── */
.catalog-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.75rem;
  position: relative;
  z-index: 1;
}

@media (min-width: 992px) {
  .catalog-grid {
    grid-template-columns: repeat(3, 1fr);
    max-width: 1140px;
    margin-left: auto;
    margin-right: auto;
  }
}

@media (max-width: 479px) {
  .catalog-grid {
    grid-template-columns: 1fr;
  }
}

.catalog-card {
  display: flex;
  flex-direction: column;
  text-decoration: none !important;
  color: var(--text-light, #e2e8f0);
  border-radius: 22px;
  overflow: hidden;
  background: var(--glass-bg, rgba(255, 255, 255, 0.03));
  border: 1px solid var(--glass-border, rgba(255, 255, 255, 0.08));
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  transition: box-shadow 0.4s ease, border-color 0.4s ease;
  position: relative;
  height: 100%;
  transform-style: preserve-3d;
  will-change: transform;
}

.catalog-card::before {
  content: '';
  position: absolute;
  inset: -1px;
  border-radius: 23px;
  padding: 1px;
  background: linear-gradient(135deg, transparent, rgba(0, 229, 255, 0.35), rgba(139, 92, 246, 0.35), transparent);
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  opacity: 0;
  transition: opacity 0.4s;
  pointer-events: none;
  z-index: 3;
}

.catalog-card::after {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 60%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(0, 229, 255, 0.12), transparent);
  transform: skewX(-20deg);
  transition: left 0.6s ease;
  pointer-events: none;
  z-index: 4;
}

.catalog-card:hover {
  box-shadow: 0 24px 48px rgba(0, 0, 0, 0.35), 0 0 30px rgba(0, 229, 255, 0.1);
  border-color: rgba(0, 229, 255, 0.35);
}

.catalog-card:hover::before { opacity: 1; }
.catalog-card:hover::after { left: 140%; }

.catalog-card-image-link {
  display: block;
  width: 100%;
  text-decoration: none;
}

.catalog-card-image {
  position: relative;
  width: 100%;
  aspect-ratio: 4 / 3;
  display: flex;
  align-items: stretch;
  justify-content: center;
  background: linear-gradient(160deg, rgba(0, 229, 255, 0.06) 0%, rgba(139, 92, 246, 0.04) 100%);
  padding: 0.65rem;
  overflow: hidden;
  box-sizing: border-box;
}

.catalog-card-image img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center;
  transition: transform 0.5s cubic-bezier(0.22, 1, 0.36, 1);
  position: relative;
  z-index: 1;
  border-radius: 12px;
  background: rgba(5, 8, 22, 0.55);
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.25);
  box-sizing: border-box;
}

svg.catalog-card-placeholder {
  width: 56px !important;
  height: 56px !important;
  margin: auto;
  border-radius: 12px;
  background: rgba(0, 229, 255, 0.08);
  padding: 0.75rem;
  box-sizing: content-box;
}

.catalog-card:hover .catalog-card-image img {
  transform: scale(1.08) translateY(-4px);
}

.catalog-card-soldout {
  position: absolute;
  inset: 0.65rem;
  border-radius: 12px;
  background: rgba(5, 8, 22, 0.75);
  backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2;
}

.catalog-card-soldout img {
  max-height: 80px;
  opacity: 0.9;
  animation: catalog-pulse 2s ease-in-out infinite;
}

@keyframes catalog-pulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.04); }
}

.catalog-card-badge {
  position: absolute;
  top: 0.85rem;
  right: 0.85rem;
  background: linear-gradient(135deg, #7C3AED, #2563EB);
  color: #fff;
  font-size: 0.72rem;
  font-weight: 700;
  padding: 0.3rem 0.7rem;
  border-radius: 100px;
  z-index: 2;
  box-shadow: 0 4px 12px rgba(124, 58, 237, 0.35);
  animation: catalog-badge-pulse 2.5s ease-in-out infinite;
}

@keyframes catalog-badge-pulse {
  0%, 100% { box-shadow: 0 4px 12px rgba(124, 58, 237, 0.35); }
  50% { box-shadow: 0 4px 20px rgba(124, 58, 237, 0.55); transform: scale(1.03); }
}

.catalog-card-body {
  padding: 1.2rem 1.3rem 1.35rem;
  display: flex;
  flex-direction: column;
  flex: 1;
  position: relative;
  z-index: 1;
}

.catalog-card-title {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--white, #ffffff);
  line-height: 1.55;
  margin-bottom: 0.45rem;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  transition: color 0.25s;
  text-decoration: none;
}

.catalog-card-title:hover {
  color: var(--cyan, #00E5FF);
}

.catalog-card-meta {
  font-size: 0.8rem;
  color: var(--text-muted, #94a3b8);
  margin-bottom: 0.65rem;
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.catalog-card-meta::before {
  content: '';
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #22C55E;
  animation: catalog-pulse-dot 2s ease-in-out infinite;
}

.catalog-card-price {
  margin-top: auto;
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--cyan, #00E5FF);
}

.catalog-card-price strike {
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--text-muted, #64748b);
  margin-right: 0.35rem;
}

.catalog-card-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  margin-top: 0.85rem;
  padding: 0.6rem 1.25rem;
  border-radius: 100px;
  background: linear-gradient(135deg, #ff6e03, #f97316);
  color: #fff !important;
  font-size: 0.875rem;
  font-weight: 700;
  font-family: inherit;
  text-decoration: none !important;
  border: none;
  cursor: pointer;
  transition: transform 0.25s ease, box-shadow 0.25s ease, background 0.25s ease;
  width: 100%;
  text-align: center;
}

.catalog-card-btn:hover {
  transform: translateY(-2px);
  background: linear-gradient(135deg, #ea580c, #ff6e03);
  box-shadow: 0 10px 24px rgba(255, 110, 3, 0.4);
  color: #fff !important;
}

.catalog-card-btn::after {
  content: '←';
  font-size: 0.9em;
}

/* ── Empty state ── */
.catalog-empty {
  text-align: center;
  padding: 4rem 1.5rem;
  border-radius: 24px;
  background: var(--glass-bg, rgba(255, 255, 255, 0.03));
  border: 1px dashed rgba(0, 229, 255, 0.25);
  position: relative;
  overflow: hidden;
}

.catalog-empty::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 50% 0%, rgba(0, 229, 255, 0.08), transparent 60%);
  animation: catalog-bg-shift 8s ease infinite alternate;
}

.catalog-empty-icon {
  width: 72px;
  height: 72px;
  margin: 0 auto 1.25rem;
  color: var(--cyan, #00E5FF);
  opacity: 0.6;
  animation: catalog-float 4s ease-in-out infinite;
}

.catalog-empty h3 {
  font-weight: 800;
  margin-bottom: 0.5rem;
  position: relative;
  color: var(--white, #ffffff);
}

.catalog-empty p {
  color: var(--text-muted, #94a3b8);
  margin-bottom: 1.5rem;
  position: relative;
}

/* ── Pagination ── */
.catalog-pagination {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.5rem;
  margin-top: 3rem;
}

.catalog-pagination button {
  min-width: 44px;
  height: 44px;
  border-radius: 14px;
  border: 1px solid var(--glass-border, rgba(255, 255, 255, 0.08));
  background: rgba(255, 255, 255, 0.04);
  color: var(--text-light, #e2e8f0);
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  transition: all 0.25s cubic-bezier(0.22, 1, 0.36, 1);
}

.catalog-pagination button:hover {
  border-color: var(--cyan, #00E5FF);
  color: var(--cyan, #00E5FF);
  transform: translateY(-3px);
  box-shadow: 0 8px 20px rgba(0, 229, 255, 0.15);
}

.catalog-pagination button.active {
  background: linear-gradient(135deg, var(--cyan, #00E5FF), #3B82F6);
  border-color: transparent;
  color: var(--bg-deep, #050816);
  box-shadow: 0 8px 24px rgba(0, 229, 255, 0.3);
  transform: translateY(-2px);
}

/* ── Loading ── */
.catalog-loading {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(5, 8, 22, 0.88);
  backdrop-filter: blur(6px);
  z-index: 2000;
  text-align: center;
  padding-top: 35vh;
}

.catalog-loading img {
  width: 100px;
  animation: catalog-float 1.5s ease-in-out infinite;
}

@media (max-width: 768px) {
  .catalog-hero-wrap {
    margin: -0.5rem -0.5rem 2rem;
    padding: 2.5rem 1rem 3rem;
    min-height: 240px;
  }

  .catalog-hero-dna { display: none; }

  .catalog-grid {
    gap: 1.1rem;
  }

  .catalog-card-image {
    aspect-ratio: 1 / 1;
    padding: 0.5rem;
  }

  .catalog-card-soldout {
    inset: 0.5rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .catalog-reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }

  .catalog-hero-bg,
  .catalog-orb,
  .catalog-card-badge,
  .catalog-card-soldout img {
    animation: none;
  }
}
