/* Product Details Page (MercadoLibre style) */
.prod-container {
  display: flex;
  max-width: 1200px;
  margin: 40px auto;
  background: #fff;
  padding: 20px;
  box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.1);
  border-radius: 4px;
  font-family:
    "Proxima Nova",
    -apple-system,
    sans-serif;
  color: #333;
}

.prod-gallery {
  display: flex;
  flex-direction: column;
  gap: 10px;
  width: 60px; /* Small thumbnails */
  margin-right: 20px;
}

.prod-thumb {
  width: 50px;
  height: 50px;
  border: 1px solid #ccc;
  border-radius: 4px;
  cursor: pointer;
  object-fit: contain;
  padding: 2px;
}

.prod-thumb:hover,
.prod-thumb.active {
  border-color: #3483fa;
  border-width: 2px;
}

.prod-main-image-container {
  flex: 2;
  display: flex;
  justify-content: center;
  align-items: flex-start; /* Align top */
  padding: 0 20px;
}

.prod-main-image {
  max-width: 100%;
  max-height: 500px;
  object-fit: contain;
}

.prod-info-panel {
  flex: 1;
  min-width: 300px;
  border: 1px solid #eee;
  padding: 16px;
  border-radius: 8px;
}

.prod-status {
  font-size: 14px;
  color: rgba(0, 0, 0, 0.55);
  margin-bottom: 8px;
}

.prod-title {
  font-size: 22px;
  font-weight: 600;
  line-height: 1.18;
  color: #333;
  margin-bottom: 12px;
}

.prod-price-container {
  margin-bottom: 24px;
}

.prod-price-original {
  font-size: 16px;
  color: #999;
  text-decoration: line-through;
}

.prod-price-current {
  font-size: 36px;
  font-weight: 300;
  color: #333;
  display: flex;
  align-items: center;
}

.prod-discount {
  font-size: 18px;
  color: #00a650;
  margin-left: 10px;
  font-weight: 400;
}

.prod-installments {
  font-size: 16px;
  color: #00a650;
  margin-top: 4px;
}

.prod-color-picker {
  margin-bottom: 24px;
}

.prod-stock-info {
  font-weight: 600;
  margin-bottom: 24px;
  font-size: 16px;
}

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

.btn-primary {
  background-color: #3483fa;
  color: white;
  border: none;
  padding: 12px 24px;
  font-size: 16px;
  font-weight: 600;
  border-radius: 6px;
  cursor: pointer;
  transition: background-color 0.2s;
  text-align: center;
}

.btn-primary:hover {
  background-color: #2968c8;
}

.btn-secondary {
  background-color: rgba(65, 137, 230, 0.15);
  color: #3483fa;
  border: none;
  padding: 12px 24px;
  font-size: 16px;
  font-weight: 600;
  border-radius: 6px;
  cursor: pointer;
  transition: background-color 0.2s;
  text-align: center;
}

.btn-secondary:hover {
  background-color: rgba(65, 137, 230, 0.2);
}

.seller-info {
  margin-top: 24px;
  padding-top: 24px;
  border-top: 1px solid #eee;
}

.seller-title {
  font-size: 14px;
  color: #333;
  margin-bottom: 10px;
}

.prod-description {
  margin-top: 40px;
  padding-top: 24px;
  border-top: 1px solid #ddd;
}

.desc-title {
  font-size: 24px;
  margin-bottom: 24px;
  color: #333;
}

.desc-content {
  font-size: 16px;
  color: #666;
  line-height: 1.5;
}

/* Category Page (Grid with Large Images) */
.cat-container {
  max-width: 1400px;
  margin: 20px auto;
  padding: 0 20px;
}

.cat-title {
  font-size: 28px;
  margin-bottom: 20px;
  color: #333;
}

.cat-grid {
  display: grid;
  grid-template-columns: repeat(
    auto-fit,
    minmax(300px, 1fr)
  ); /* auto-fit collapses empty tracks */
  gap: 30px;
  justify-content: center; /* Centers the tracks */
}

.cat-card {
  background: #fff;
  border-radius: 8px;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  overflow: hidden;
  transition: transform 0.2s;
  display: flex;
  flex-direction: column;
}

.cat-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 12px rgba(0, 0, 0, 0.15);
}

.cat-img-container {
  width: 100%;
  height: 350px; /* Large image area */
  background: #f8f8f8;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.cat-img {
  width: 100%;
  height: 100%;
  object-fit: cover; /* Fill the large area */
}

.cat-info {
  padding: 16px;
}

.cat-price {
  font-size: 24px;
  font-weight: 300;
  color: #333;
}

.cat-name {
  font-size: 16px;
  color: #666;
  margin-top: 8px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .prod-container {
    flex-direction: column;
  }
  .prod-gallery {
    flex-direction: row;
    width: 100%;
    margin-bottom: 20px;
    order: 2;
  }
  .prod-main-image-container {
    order: 1;
    margin-bottom: 20px;
  }
  .prod-info-panel {
    order: 3;
  }
}
