/* Phase W2 - the shared product card (client's prototype): photo, variant dropdown, item code,
   title, price table, quantity with unit, Add to cart. Used on every product list. */
.product-card.hub-card {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 10px;
    height: 100%;
    box-sizing: border-box;
    padding: 16px;
    background: #fff;
    border: 1px solid #E6E8EF;
    border-radius: 8px;
    font-family: "Gilroy-Medium", sans-serif;
    color: #202020;
    text-align: left;
}
.hub-card .hub-card-photo {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 190px;
    background: #F4F5F8;
    border-radius: 6px;
    overflow: hidden;
    text-decoration: none;
}
.hub-card .hub-card-photo img {
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
    border-radius: 0;
}
.hub-card .hub-card-nophoto { color: #6B7080; font-size: 14px; }
.hub-card .hub-card-heart { position: absolute; top: 22px; right: 22px; z-index: 2; }

.hub-card .hub-card-info { display: flex; flex-direction: column; gap: 6px; flex: 1 1 auto; }
.hub-card .hub-card-variants {
    display: block;
    width: 100%;
    height: 40px;
    padding: 0 8px;
    border: 1px solid #C9CEDB;
    border-radius: 6px;
    background: #fff;
    color: #202020;
    font: inherit;
    font-size: 14px;
    cursor: pointer;
}
.hub-card .hub-card-variants:focus-visible { outline: 2px solid #29387D; outline-offset: 1px; }
.hub-card .hub-card-code { margin: 4px 0 0; font-size: 13px; color: #5A5F6E; letter-spacing: .3px; word-break: break-all; }
.hub-card .hub-card-title {
    margin: 0;
    font-family: "Gilroy-Bold", sans-serif;
    font-size: 16px;
    line-height: 1.35;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
    overflow: hidden;
}
.hub-card .hub-card-title a { color: #202020; text-decoration: none; }
.hub-card .hub-card-title a:hover { color: var(--primary-red, #EA2227); }

.hub-card .hub-card-buy { display: flex; flex-direction: column; gap: 10px; }
.hub-card .hub-card-tiers { width: 100%; border-collapse: collapse; font-size: 14px; }
.hub-card .hub-card-tiers th,
.hub-card .hub-card-tiers td { border: 1px solid #DDE1EA; padding: 7px 6px; text-align: center; color: #202020; }
.hub-card .hub-card-tiers th { background: #F6F7FB; font-family: "Gilroy-Bold", sans-serif; font-weight: normal; }

.hub-card .hub-card-qty {
    display: flex;
    align-items: center;
    gap: 6px;
    height: 42px;
    margin: 0;
    padding: 0 10px;
    border: 1px solid #C9CEDB;
    border-radius: 6px;
    background: #fff;
}
.hub-card .hub-card-qty input.qty_count {
    flex: 1 1 auto;
    min-width: 0;
    width: 100%;
    height: 100%;
    border: 0;
    padding: 0;
    text-align: right;
    font: inherit;
    font-size: 15px;
    color: #202020;
    background: transparent;
    outline: none;
}
.hub-card .hub-card-qty:focus-within { outline: 2px solid #29387D; outline-offset: 1px; }
.hub-card .hub-card-unit { color: #5A5F6E; font-size: 14px; white-space: nowrap; }
.hub-card .cart-btn.hub-card-add {
    width: 100%;
    min-height: 46px;
    padding: 10px 14px;
    border: 0;
    border-radius: 6px;
    background: var(--primary-red, #EA2227);
    color: #fff;
    font-family: "Gilroy-Bold", sans-serif;
    font-size: 16px;
    cursor: pointer;
}
.hub-card .cart-btn.hub-card-add:hover { background: #C81C21; border: 0; }
.hub-card .cart-btn.hub-card-add.is-out-of-stock { background: #29387D; }
.hub-card .oos-card-badge { align-self: flex-start; }

.hub-card .hub-card-sr {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* carousels (home lists, related products): equal-height cards */
.product_grid.owl-carousel .owl-stage { display: flex; }
.product_grid.owl-carousel .owl-item { display: flex; }
.product_grid.owl-carousel .owl-item > .product-card.hub-card { width: 100%; height: auto; }

/* product list "list view": photo left, details middle, buying right */
.product-listing-wrapper.list_view .product-card.hub-card {
    display: grid;
    grid-template-columns: 180px minmax(0, 1fr) minmax(220px, 280px);
    align-items: start;
    gap: 18px;
}
.product-listing-wrapper.list_view .hub-card .hub-card-photo { height: 150px; }
.product-listing-wrapper.list_view .hub-card .hub-card-heart { right: auto; left: 150px; }

@media (max-width: 767px) {
    .product-card.hub-card { padding: 12px; }
    .hub-card .hub-card-photo { height: 160px; }
    .product-listing-wrapper.list_view .product-card.hub-card { display: flex; }
    .product-listing-wrapper.list_view .hub-card .hub-card-heart { left: auto; right: 18px; }
}

/* ---- line attributes (cart, checkout, orders, invoices): "COLOR Red" chips ---- */
.hub-line-attrs { list-style: none; display: flex; flex-wrap: wrap; gap: 6px; margin: 6px 0 0; padding: 0; }
.hub-line-attrs li { display: inline-flex; align-items: baseline; gap: 5px; padding: 3px 9px; border: 1px solid #E3E6EF; border-radius: 6px; background: #F6F7FA; font-size: 12px; line-height: 1.4; }
.hub-la-k { color: #6B7080; font-weight: 500; text-transform: uppercase; letter-spacing: .02em; font-size: 11px; }
.hub-la-v { color: #1F2A5C; font-weight: 600; }
.hub-line-sku { display: block; margin-top: 2px; font-size: 12px; color: #6B7080; }
