@import url('https://fonts.googleapis.com/css2?family=Geist+Mono:wght@100..900&display=swap');

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: 'Geist Mono', monospace;
}

body {
  background: #000;
  color: #fff;
  overflow-x: hidden;
}

.products-page {
  min-height: 100vh;
  position: relative;
  padding: 120px 20px 80px;
  overflow: hidden;
}

/* Grid animado de fondo */
.products-page::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: linear-gradient(
      rgba(161, 1, 255, 0.05) 1px,
      transparent 1px
    ),
    linear-gradient(90deg, rgba(161, 1, 255, 0.05) 1px, transparent 1px);
  background-size: 80px 80px;
  animation: gridMove 25s linear infinite;
  z-index: 1;
}

@keyframes gridMove {
  0% {
    transform: translate(0, 0);
  }
  25% {
    transform: translate(30px, 30px);
  }
  50% {
    transform: translate(60px, 0);
  }
  75% {
    transform: translate(30px, -30px);
  }
  100% {
    transform: translate(0, 0);
  }
}

/* Efectos de luz de fondo */
.products-page::after {
  content: '';
  position: absolute;
  top: 20%;
  right: 10%;
  width: 600px;
  height: 600px;
  background: radial-gradient(
    circle,
    rgba(161, 1, 255, 0.15) 0%,
    transparent 70%
  );
  border-radius: 50%;
  filter: blur(100px);
  animation: float 12s ease-in-out infinite;
  z-index: 1;
}

.gradient-orb {
  position: absolute;
  top: 60%;
  left: 5%;
  width: 500px;
  height: 500px;
  background: radial-gradient(
    circle,
    rgba(161, 1, 255, 0.12) 0%,
    transparent 70%
  );
  border-radius: 50%;
  filter: blur(80px);
  animation: float 15s ease-in-out infinite reverse;
  z-index: 1;
}

@keyframes float {
  0%,
  100% {
    transform: translate(0, 0) scale(1);
  }
  25% {
    transform: translate(50px, -30px) scale(1.1);
  }
  50% {
    transform: translate(0, -50px) scale(1.2);
  }
  75% {
    transform: translate(-50px, -30px) scale(1.1);
  }
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
  position: relative;
  z-index: 2;
}

.products-header {
  text-align: center;
  margin-bottom: 60px;
}

.products-badge {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: rgba(161, 1, 255, 0.15);
  border: 1px solid rgba(161, 1, 255, 0.4);
  padding: 10px 25px;
  border-radius: 50px;
  font-size: 0.85rem;
  font-weight: 700;
  color: #a101ff;
  margin-bottom: 20px;
  backdrop-filter: blur(10px);
  text-transform: uppercase;
  letter-spacing: 1.2px;
}

.products-badge i {
  animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
  0%,
  100% {
    opacity: 1;
    transform: scale(1);
  }
  50% {
    opacity: 0.7;
    transform: scale(1.1);
  }
}

.products-header h1 {
  font-size: 3.5rem;
  font-weight: 900;
  line-height: 1.1;
  margin-bottom: 15px;
  background: linear-gradient(135deg, #fff 0%, #a101ff 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  letter-spacing: -2px;
}

.products-header p {
  font-size: 1rem;
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.6);
  max-width: 600px;
  margin: 0 auto;
}

.search-form {
  display: flex;
  gap: 15px;
  margin-bottom: 50px;
  max-width: 700px;
  margin-left: auto;
  margin-right: auto;
}

.search-form input {
  flex: 1;
  padding: 16px 24px;
  border: 1px solid rgba(161, 1, 255, 0.3);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.02);
  color: #fff;
  font-size: 0.95rem;
  backdrop-filter: blur(10px);
  transition: all 0.3s ease;
  font-family: 'Geist Mono', monospace;
}

.search-form input:focus {
  outline: none;
  border-color: #a101ff;
  background: rgba(255, 255, 255, 0.05);
  box-shadow: 0 0 20px rgba(161, 1, 255, 0.2);
}

.search-form input::placeholder {
  color: rgba(255, 255, 255, 0.4);
}

.search-form button {
  padding: 16px 35px;
  background: #a101ff;
  border: none;
  border-radius: 8px;
  color: white;
  font-weight: 700;
  font-size: 0.95rem;
  cursor: pointer;
  transition: all 0.3s ease;
  white-space: nowrap;
  font-family: 'Geist Mono', monospace;
}

.search-form button:hover {
  background: #8200cc;
  transform: translateY(-2px);
  box-shadow: 0 10px 30px rgba(161, 1, 255, 0.4);
}

.search-results {
  text-align: center;
  margin-bottom: 30px;
  color: rgba(255, 255, 255, 0.7);
  font-size: 0.95rem;
}

.search-results .highlight {
  color: #a101ff;
  font-weight: 700;
}

.products-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 350px));
  gap: 30px;
  margin-top: 30px;
  justify-content: center;
}

.product-card {
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(161, 1, 255, 0.2);
  border-radius: 12px;
  overflow: hidden;
  transition: all 0.3s ease;
  backdrop-filter: blur(10px);
  position: relative;
  height: 420px;
  display: flex;
  flex-direction: column;
  animation: fadeInUp 0.6s ease forwards;
  opacity: 0;
}

@keyframes fadeInUp {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.product-card:hover {
  transform: translateY(-10px);
  border-color: rgba(161, 1, 255, 0.6);
  box-shadow: 0 20px 40px rgba(161, 1, 255, 0.2);
}

.product-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, #a101ff, #c04fff);
  transform: scaleX(0);
  transition: transform 0.3s ease;
}

.product-card:hover::before {
  transform: scaleX(1);
}

.product-badge {
  position: absolute;
  top: 15px;
  right: 15px;
  background: linear-gradient(135deg, #a101ff, #c04fff);
  color: white;
  padding: 6px 14px;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 700;
  z-index: 2;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.product-image {
  height: 200px;
  overflow: hidden;
  position: relative;
  flex-shrink: 0;
}

.product-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.product-card:hover .product-image img {
  transform: scale(1.1);
}

.product-content {
  padding: 25px;
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.product-content h3 {
  font-size: 1.3rem;
  font-weight: 700;
  color: #fff;
  margin-bottom: 15px;
  line-height: 1.3;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.product-price {
  font-size: 1.8rem;
  font-weight: 900;
  color: #a101ff;
  margin-bottom: 20px;
  text-shadow: 0 0 20px rgba(161, 1, 255, 0.3);
}

.product-actions {
  display: flex;
  gap: 12px;
  margin-top: auto;
}

.btn {
  flex: 1;
  padding: 12px 20px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 700;
  font-size: 0.85rem;
  text-align: center;
  transition: all 0.3s ease;
  border: 2px solid transparent;
  white-space: nowrap;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  cursor: pointer;
  font-family: 'Geist Mono', monospace;
}

.btn-details {
  background: transparent;
  color: #a101ff;
  border-color: rgba(161, 1, 255, 0.4);
}

.btn-details:hover {
  background: rgba(161, 1, 255, 0.1);
  border-color: #a101ff;
  transform: translateY(-2px);
}

.btn-buy {
  background: #a101ff;
  color: white;
  border-color: #a101ff;
}

.btn-buy:hover {
  background: #8200cc;
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(161, 1, 255, 0.4);
}

.no-products {
  text-align: center;
  padding: 80px 20px;
  grid-column: 1 / -1;
}

.no-products i {
  font-size: 4rem;
  color: rgba(161, 1, 255, 0.3);
  margin-bottom: 20px;
  animation: pulse 2s ease-in-out infinite;
}

.no-products h3 {
  font-size: 1.8rem;
  color: rgba(255, 255, 255, 0.8);
  margin-bottom: 10px;
  font-weight: 700;
}

.no-products p {
  color: rgba(255, 255, 255, 0.5);
  font-size: 1rem;
}

/* Responsive */
@media (max-width: 1200px) {
  .products-header h1 {
    font-size: 3rem;
  }
}

@media (max-width: 968px) {
  .products-page {
    padding: 100px 20px 60px;
  }

  .products-header h1 {
    font-size: 2.5rem;
  }

  .products-grid {
    grid-template-columns: repeat(auto-fit, minmax(280px, 320px));
    gap: 25px;
  }

  .search-form {
    flex-direction: column;
  }

  .product-card {
    height: 400px;
  }
}

@media (max-width: 640px) {
  .products-page {
    padding: 90px 15px 50px;
  }

  .products-header h1 {
    font-size: 2rem;
    letter-spacing: -1px;
  }

  .products-header p {
    font-size: 0.9rem;
  }

  .products-badge {
    font-size: 0.75rem;
    padding: 8px 20px;
  }

  .products-grid {
    grid-template-columns: 1fr;
    max-width: 350px;
    margin-left: auto;
    margin-right: auto;
  }

  .product-card {
    max-width: none;
    height: 380px;
  }

  .product-actions {
    flex-direction: column;
  }

  .product-content {
    padding: 20px;
  }

  .product-image {
    height: 180px;
  }
}

@media (max-width: 480px) {
  .products-header h1 {
    font-size: 1.8rem;
  }

  .product-content h3 {
    font-size: 1.1rem;
  }

  .product-price {
    font-size: 1.6rem;
  }
}
