/* GRABA IMAGEN — Cards de Productos */

.product-card {
  background: var(--color-white);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-card);
  transition: transform 0.35s cubic-bezier(0.34,1.56,0.64,1), box-shadow 0.35s ease;
  border: 1px solid var(--color-gray-light);
  position: relative;
  display: flex;
  flex-direction: column;
}

.product-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--color-primary-mid), var(--color-accent));
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.3s ease;
  z-index: 1;
}

.product-card:hover { transform: translateY(-8px) scale(1.02); box-shadow: var(--shadow-hover); }
.product-card:hover::before { transform: scaleX(1); }

.product-card-img {
  width: 100%;
  aspect-ratio: 4/3;
  object-fit: cover;
}

.product-card-body {
  padding: 20px 22px 24px;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.product-card-badge {
  display: inline-block;
  background: var(--color-accent-glow);
  color: var(--color-accent);
  font-family: var(--font-heading);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 4px 10px;
  border-radius: var(--radius-pill);
  margin-bottom: 10px;
}

.product-card h3 {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 1rem;
  color: var(--color-primary);
  margin-bottom: 8px;
}

.product-card p {
  font-size: 0.87rem;
  color: var(--color-gray-mid);
  flex: 1;
  margin-bottom: 16px;
  line-height: 1.5;
}

.product-card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.product-card-price {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.2rem;
  color: var(--color-primary-mid);
}

/* Category card (home grid) */
.cat-card {
  background: var(--color-white);
  border-radius: var(--radius-lg);
  padding: 32px 24px;
  text-align: center;
  box-shadow: var(--shadow-card);
  border: 1px solid var(--color-gray-light);
  text-decoration: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  transition: transform var(--transition-bounce), box-shadow var(--transition-base), border-color var(--transition-base);
  position: relative;
  overflow: hidden;
}

.cat-card::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  border: 2px solid transparent;
  background: linear-gradient(135deg, var(--color-primary-mid), var(--color-accent)) border-box;
  -webkit-mask: linear-gradient(#fff 0 0) padding-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: destination-out;
  mask-composite: exclude;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.cat-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-hover); }
.cat-card:hover::after { opacity: 1; }

.cat-icon {
  width: 64px; height: 64px;
  background: linear-gradient(135deg, rgba(27,79,216,0.1), rgba(0,194,255,0.15));
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.8rem;
  transition: transform var(--transition-bounce);
}

.cat-card:hover .cat-icon { transform: scale(1.15) rotate(-3deg); }

.cat-card h3 {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--color-primary);
}

.cat-card p { font-size: 0.82rem; color: var(--color-gray-mid); }

/* Team card */
.team-card {
  background: var(--color-white);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-card);
  border: 1px solid var(--color-gray-light);
  text-align: center;
  transition: transform var(--transition-bounce), box-shadow var(--transition-base);
}

.team-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-hover); }

.team-card img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
}

.team-card-body { padding: 20px; }

.team-card h4 {
  font-family: var(--font-heading);
  font-weight: 700;
  color: var(--color-primary);
  margin-bottom: 4px;
}

.team-card span { font-size: 0.82rem; color: var(--color-accent); font-weight: 600; }

/* Gallery card */
.gallery-item {
  border-radius: var(--radius-md);
  overflow: hidden;
  cursor: pointer;
  position: relative;
}

.gallery-item img { width: 100%; display: block; transition: transform 0.4s ease; }
.gallery-item:hover img { transform: scale(1.08); }

.gallery-item-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(6,21,57,0.85) 0%, transparent 60%);
  opacity: 0;
  transition: opacity 0.3s ease;
  display: flex;
  align-items: flex-end;
  padding: 16px;
}

.gallery-item:hover .gallery-item-overlay { opacity: 1; }

.gallery-item-overlay span {
  color: white;
  font-family: var(--font-heading);
  font-size: 0.85rem;
  font-weight: 600;
}

/* Lightbox */
.lightbox {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.9);
  z-index: 10000;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.lightbox.open { opacity: 1; pointer-events: all; }

.lightbox img {
  max-width: 90vw;
  max-height: 85vh;
  border-radius: var(--radius-md);
  box-shadow: 0 20px 80px rgba(0,0,0,0.5);
}

.lightbox-close {
  position: absolute;
  top: 20px; right: 24px;
  color: white;
  font-size: 2rem;
  cursor: pointer;
  background: none;
  border: none;
  line-height: 1;
  opacity: 0.8;
  transition: opacity 0.2s;
}

.lightbox-close:hover { opacity: 1; }
