/* OZ Cotizador — Design pack "proinval" (admin: Proinval)
 * Cards de tienda: .ozc-product-card__* bajo .ozc-product-card--pack-proinval
 *
 * Look de referencia (captura tienda proinvalsafety.com):
 * - Card blanca, centrada, separadores verticales sutiles.
 * - Categoría en azul-gris apagado.
 * - Título en negrita, casi negro.
 * - Botón de acción rojo Proinval a ancho completo ("Agregar Pedido").
 *
 * El plugin controla QUÉ elementos se muestran (título, precio, categoría, etc.);
 * este pack solo define el ESTILO.
 */

.ozc-product-card--pack-proinval {
  --ozc-pack-red: #e2231a;
  --ozc-pack-red-hover: #c41c14;
  --ozc-pack-surface: #ffffff;
  --ozc-pack-border: #eceef1;
  --ozc-pack-divider: #e5e7eb;
  --ozc-pack-text: #1a1a1a;
  --ozc-pack-category: #5b7286;
  --ozc-pack-muted: #6b7280;
  --ozc-pack-radius: 10px;
  --ozc-pack-btn-radius: 6px;

  box-sizing: border-box;
  display: flex;
  flex-direction: column;
  background: var(--ozc-pack-surface);
  border: 1px solid var(--ozc-pack-border);
  border-radius: var(--ozc-pack-radius);
  box-shadow: 0 6px 20px rgba(15, 23, 42, 0.04);
  padding: 1rem 1rem 1.25rem;
  text-align: center;
  color: var(--ozc-pack-text);
  transition: border-color 0.24s ease, box-shadow 0.24s ease, transform 0.24s ease;
}

.ozc-product-card--pack-proinval:hover,
.ozc-product-card--pack-proinval:focus-within {
  border-color: #dfe3e8;
  box-shadow: 0 14px 28px rgba(15, 23, 42, 0.08);
  transform: translateY(-2px);
}

/* ---- Secciones (espaciado vertical uniforme) ---- */
.ozc-product-card--pack-proinval .ozc-product-card__section {
  padding-left: 0;
  padding-right: 0;
  margin-top: 0.45rem;
}

.ozc-product-card--pack-proinval .ozc-product-card__section:first-child {
  margin-top: 0;
}

.ozc-product-card--pack-proinval .ozc-product-card__media + .ozc-product-card__section {
  margin-top: 0.65rem;
  padding-top: 0;
  border-top: none;
}

/* ---- Imagen ---- */
.ozc-product-card--pack-proinval .ozc-product-card__media {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  position: relative;
  overflow: visible;
  aspect-ratio: unset;
  min-height: 0;
  padding: 0.25rem 0.35rem 0.5rem;
  margin: 0 -0.35rem;
  text-decoration: none;
  color: inherit;
}

.ozc-product-card--pack-proinval .ozc-product-card__media img {
  transition: transform 0.28s ease;
}

.ozc-product-card--pack-proinval:hover .ozc-product-card__media img,
.ozc-product-card--pack-proinval:focus-within .ozc-product-card__media img {
  transform: scale(1.03);
}

.ozc-product-card--pack-proinval .ozc-product-card__media img,
.ozc-product-card--pack-proinval .ozc-product-card__placeholder {
  width: 100%;
  max-width: 240px;
  height: auto;
  max-height: 220px;
  margin: 0 auto;
  object-fit: contain;
  display: block;
}

.ozc-product-card--pack-proinval .ozc-product-card__placeholder {
  aspect-ratio: 1;
  border-radius: 6px;
  background: linear-gradient(145deg, #f6f6f6 0%, #ececec 100%);
}

/* Marca como texto, no como badge sobre la imagen */
.ozc-product-card--pack-proinval .ozc-product-card__media .ozc-product-card__badge {
  display: none;
}

/* ---- Categoría (roja, igual que el botón, sobre el título) ---- */
.ozc-product-card--pack-proinval .ozc-product-card__category {
  width: 100%;
  margin-top: 0.55rem;
  font-size: 0.9rem;
  font-weight: 400;
  line-height: 1.3;
  color: var(--ozc-pack-red);
}

/* ---- Título (negrita, casi negro) ---- */
.ozc-product-card--pack-proinval .ozc-product-card__title {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
  font-size: 0.95rem;
  font-weight: 700;
  line-height: 1.32;
  margin: 0;
  margin-top: 0.15rem;
  color: var(--ozc-pack-text);
  min-height: 0;
  overflow: hidden;
  word-break: break-word;
}

.ozc-product-card--pack-proinval .ozc-product-card__title a {
  color: inherit;
  text-decoration: none;
}

.ozc-product-card--pack-proinval .ozc-product-card__title a:hover,
.ozc-product-card--pack-proinval .ozc-product-card__title a:focus-visible {
  color: var(--ozc-pack-red);
}

/* ---- Marca ---- */
.ozc-product-card--pack-proinval .ozc-product-card__brand {
  display: block;
  width: 100%;
  margin-top: 0.35rem;
  font-size: 0.8rem;
  line-height: 1.35;
  color: var(--ozc-pack-muted);
}

/* ---- Extracto ---- */
.ozc-product-card--pack-proinval .ozc-product-card__excerpt {
  font-size: 0.8125rem;
  line-height: 1.4;
  color: var(--ozc-pack-muted);
}

/* ---- Precio ---- */
.ozc-product-card--pack-proinval .ozc-product-card__price {
  font-size: 1rem;
  font-weight: 700;
  color: var(--ozc-pack-text);
}

.ozc-product-card--pack-proinval .ozc-product-card__price .woocommerce-Price-amount {
  font-weight: inherit;
}

/* ---- Acciones: botón rojo "Agregar Pedido" (+ cantidad si se muestra) ---- */
.ozc-product-card--pack-proinval .ozc-product-card__actions {
  display: flex;
  flex-direction: row;
  flex-wrap: nowrap;
  align-items: stretch;
  justify-content: center;
  gap: 0.4rem;
  width: 100%;
  margin-top: 0.9rem;
}

/* Botón "Agregar Pedido": 160×34, padding 10px 32px, fuente 14px, fondo rojo.
 * Se usan !important en las propiedades clave para ganar a los estilos de
 * botón del tema/WooCommerce (a.button.add_to_cart_button, etc.). */
.ozc-product-card--pack-proinval .ozc-product-card__actions .ozc-product-card__btn--primary {
  order: 1;
  flex: 0 1 auto;
  width: auto;
  min-width: 0;
  max-width: 100%;
  min-height: 34px !important;
  height: auto;
  padding: 10px 32px !important;
  border: none !important;
  border-radius: var(--ozc-pack-btn-radius) !important;
  background: var(--ozc-pack-red) !important;
  color: #ffffff !important;
  font-size: 14px !important;
  font-weight: 600 !important;
  line-height: 1 !important;
  letter-spacing: 0.01em;
  text-transform: none !important;
  text-decoration: none !important;
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  box-shadow: none;
  cursor: pointer;
  transition: background-color 0.24s ease, box-shadow 0.24s ease, transform 0.24s ease;
}

.ozc-product-card--pack-proinval .ozc-product-card__actions .ozc-product-card__btn--primary::after {
  display: none !important;
  content: none !important;
}

.ozc-product-card--pack-proinval .ozc-product-card__actions .ozc-product-card__btn--primary:hover {
  background: var(--ozc-pack-red-hover) !important;
  color: #ffffff !important;
  box-shadow: 0 10px 20px rgba(226, 35, 26, 0.24);
  transform: translateY(-1px);
}

.ozc-product-card--pack-proinval .ozc-product-card__actions .ozc-product-card__btn--primary:focus-visible {
  outline: none;
  box-shadow: 0 0 0 3px rgba(226, 35, 26, 0.28);
}

.ozc-product-card--pack-proinval .ozc-product-card__actions .ozc-product-card__btn--primary:focus:not(:focus-visible) {
  background: var(--ozc-pack-red) !important;
  color: #ffffff !important;
}

.ozc-product-card--pack-proinval .ozc-product-card__btn--primary.ozc-product-card__btn--added::before {
  margin-right: 0.35rem;
}

/* Selector de cantidad (opcional, si el plugin lo muestra) */
.ozc-product-card--pack-proinval .ozc-product-card__qty {
  order: 2;
  flex: 0 0 auto;
  display: inline-flex;
  align-self: stretch;
  align-items: stretch;
  margin: 0;
  height: auto;
  min-height: 2.5rem;
  border: 1px solid var(--ozc-pack-divider);
  border-radius: var(--ozc-pack-btn-radius);
  background: #f8fafc;
  color: var(--ozc-pack-text);
  overflow: hidden;
}

.ozc-product-card--pack-proinval .ozc-product-card__qty-btn {
  width: 1.9rem;
  min-height: 100%;
  height: auto;
  color: var(--ozc-pack-text);
  background: transparent;
  font-size: 0.95rem;
  transition: background-color 0.24s ease;
}

.ozc-product-card--pack-proinval .ozc-product-card__qty-btn:hover,
.ozc-product-card--pack-proinval .ozc-product-card__qty-btn:focus-visible {
  background: rgba(15, 23, 42, 0.06);
}

.ozc-product-card--pack-proinval .ozc-product-card__qty-input {
  min-width: 1.9rem;
  width: 2rem;
  height: auto;
  min-height: 100%;
  padding: 0 0.2rem;
  color: var(--ozc-pack-text);
  font-size: 0.85rem;
  font-weight: 700;
  background: transparent;
  text-align: center;
}

.ozc-product-card--pack-proinval .ozc-product-card__qty-input:focus {
  outline: none;
}

/* ---- Botón WhatsApp (opcional) ---- */
.ozc-product-card--pack-proinval .ozc-product-card__wa {
  width: 100%;
}

.ozc-product-card--pack-proinval .ozc-product-card__wa-btn {
  width: 100%;
  min-height: 2.4rem;
  padding: 0.4rem 0.7rem;
  border: 1px solid var(--ozc-pack-border);
  border-radius: var(--ozc-pack-btn-radius);
  background: var(--ozc-pack-surface);
  color: var(--ozc-pack-text);
  font-size: 0.8rem;
  font-weight: 700;
  line-height: 1.15;
  text-transform: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: border-color 0.24s ease, background-color 0.24s ease, color 0.24s ease, box-shadow 0.24s ease, transform 0.24s ease;
}

.ozc-product-card--pack-proinval .ozc-product-card__wa-btn:hover,
.ozc-product-card--pack-proinval .ozc-product-card__wa-btn:focus-visible {
  border-color: #b6e3c9;
  background: #f0faf4;
  color: #1f7a4f;
  box-shadow: 0 10px 22px rgba(15, 23, 42, 0.06);
  transform: translateY(-1px);
}

.ozc-product-card--pack-proinval .ozc-product-card__wa-btn:focus-visible {
  outline: none;
  box-shadow: 0 0 0 3px rgba(31, 122, 79, 0.14);
}

.ozc-product-card--pack-proinval .ozc-product-card__wa-btn::after {
  content: '';
  display: inline-block;
  width: 1.125rem;
  height: 1.125rem;
  margin-left: 0.5rem;
  flex-shrink: 0;
  background-color: currentColor;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='%23000' d='M17.472 14.382c-.297-.149-1.758-.867-2.03-.967-.273-.099-.471-.148-.67.15-.197.297-.767.966-.94 1.164-.173.199-.347.223-.644.075-.297-.15-1.255-.463-2.39-1.475-.883-.788-1.48-1.761-1.653-2.059-.173-.297-.018-.458.13-.606.134-.133.298-.347.446-.52.149-.174.198-.298.298-.497.099-.198.05-.371-.025-.52-.075-.149-.669-1.612-.916-2.207-.242-.579-.487-.5-.669-.51-.173-.008-.371-.01-.57-.01-.198 0-.52.074-.792.372-.272.297-1.04 1.016-1.04 2.479 0 1.462 1.065 2.875 1.213 3.074.149.198 2.096 3.2 5.077 4.487.709.306 1.262.489 1.694.625.712.227 1.36.195 1.871.118.571-.085 1.758-.719 2.006-1.413.248-.694.248-1.289.173-1.413-.074-.124-.272-.198-.57-.347m-5.421 7.403h-.004a9.87 9.87 0 01-5.031-1.378l-.361-.214-3.741.982.998-3.648-.235-.374a9.86 9.86 0 01-1.51-5.26c.001-5.45 4.436-9.884 9.888-9.884 2.64 0 5.122 1.03 6.988 2.898a9.825 9.825 0 012.893 6.994c-.003 5.45-4.435 9.884-9.885 9.884m8.413-18.297A11.815 11.815 0 0012.05 0C5.495 0 .16 5.335.157 11.892c0 2.096.547 4.142 1.588 5.945L.057 24l6.305-1.654a11.882 11.882 0 005.683 1.448h.005c6.554 0 11.89-5.335 11.893-11.893a11.821 11.821 0 00-3.48-8.413z'/%3E%3C/svg%3E") center / contain no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='%23000' d='M17.472 14.382c-.297-.149-1.758-.867-2.03-.967-.273-.099-.471-.148-.67.15-.197.297-.767.966-.94 1.164-.173.199-.347.223-.644.075-.297-.15-1.255-.463-2.39-1.475-.883-.788-1.48-1.761-1.653-2.059-.173-.297-.018-.458.13-.606.134-.133.298-.347.446-.52.149-.174.198-.298.298-.497.099-.198.05-.371-.025-.52-.075-.149-.669-1.612-.916-2.207-.242-.579-.487-.5-.669-.51-.173-.008-.371-.01-.57-.01-.198 0-.52.074-.792.372-.272.297-1.04 1.016-1.04 2.479 0 1.462 1.065 2.875 1.213 3.074.149.198 2.096 3.2 5.077 4.487.709.306 1.262.489 1.694.625.712.227 1.36.195 1.871.118.571-.085 1.758-.719 2.006-1.413.248-.694.248-1.289.173-1.413-.074-.124-.272-.198-.57-.347m-5.421 7.403h-.004a9.87 9.87 0 01-5.031-1.378l-.361-.214-3.741.982.998-3.648-.235-.374a9.86 9.86 0 01-1.51-5.26c.001-5.45 4.436-9.884 9.888-9.884 2.64 0 5.122 1.03 6.988 2.898a9.825 9.825 0 012.893 6.994c-.003 5.45-4.435 9.884-9.885 9.884m8.413-18.297A11.815 11.815 0 0012.05 0C5.495 0 .16 5.335.157 11.892c0 2.096.547 4.142 1.588 5.945L.057 24l6.305-1.654a11.882 11.882 0 005.683 1.448h.005c6.554 0 11.89-5.335 11.893-11.893a11.821 11.821 0 00-3.48-8.413z'/%3E%3C/svg%3E") center / contain no-repeat;
}

/* =====================================================================
 * RESPONSIVE — que la card se vea bien en cualquier vista.
 * El botón mantiene su alto (34px) pero nunca desborda la card.
 * ===================================================================== */

/* Tablet / pantallas medianas */
@media (max-width: 782px) {
  .ozc-product-card--pack-proinval {
    padding: 0.9rem 0.9rem 1.1rem;
  }

  .ozc-product-card--pack-proinval .ozc-product-card__media img,
  .ozc-product-card--pack-proinval .ozc-product-card__placeholder {
    max-width: 220px;
    max-height: 200px;
  }
}

/* Móvil */
@media (max-width: 480px) {
  .ozc-product-card--pack-proinval {
    padding: 0.8rem 0.8rem 1rem;
    border-radius: 8px;
  }

  .ozc-product-card--pack-proinval .ozc-product-card__media img,
  .ozc-product-card--pack-proinval .ozc-product-card__placeholder {
    max-width: 180px;
    max-height: 170px;
  }

  .ozc-product-card--pack-proinval .ozc-product-card__category {
    font-size: 0.85rem;
  }

  .ozc-product-card--pack-proinval .ozc-product-card__title {
    font-size: 0.9rem;
  }

  /* El botón conserva 34px de alto; solo se reduce el padding lateral
     para que no se corte en cards angostas (grids de 2 columnas en móvil). */
  .ozc-product-card--pack-proinval .ozc-product-card__actions .ozc-product-card__btn--primary {
    padding: 10px 22px !important;
  }
}

/* Cards muy angostas: el botón se adapta al ancho disponible sin desbordar. */
@media (max-width: 360px) {
  .ozc-product-card--pack-proinval .ozc-product-card__actions .ozc-product-card__btn--primary {
    flex: 1 1 auto;
    width: 100%;
    padding: 10px 16px !important;
  }
}
