/* filepath: website_sale_aplicoop/static/src/css/components/product-card.css */

/**
 * Product card component styles
 */

.product-card {
    background-color: white;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    padding: 0.5rem 0.5rem 0.5rem 0.5rem;
    height: 100%;
    overflow: hidden;
}

.product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.12);
}

.product-card:focus-within {
    outline: 3px solid var(--primary-color);
    outline-offset: 2px;
}

.product-card .product-image {
    height: 150px;
    object-fit: cover;
}

.product-img-cover {
    max-height: 160px;
    object-fit: cover;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(40, 39, 39, 0.9);
}

.product-card .card-body {
    display: flex;
    flex-direction: column;
    height: 100%;
    flex-grow: 1;
    padding: 0.75rem;
    position: relative;
    background: linear-gradient(135deg, rgba(0, 123, 255, 0.12) 0%, rgba(0, 123, 255, 0.08) 100%);
    transition: all 0.3s ease;
}

.product-card:hover .card-body {
    background: linear-gradient(
        135deg,
        rgba(108, 117, 125, 0.1) 0%,
        rgba(108, 117, 125, 0.08) 100%
    );
}

.product-card .card-title {
    flex-grow: 1;
    margin: 0;
    margin-bottom: 0.2rem;
    min-height: auto;
    display: block;
    word-wrap: break-word;
    overflow-wrap: break-word;
    font-size: 1.2rem !important;
    line-height: 1;
    text-align: center;
    font-weight: 600;
    color: #2d3748;
}

.product-card .card-text {
    margin-bottom: 0.15rem;
    text-align: center;
}

.product-card .card-text strong {
    display: block;
    margin-bottom: 0.15rem;
    font-size: 1.2rem;
    color: #667eea;
}

.product-card .product-supplier {
    text-align: center;
    color: #4a5568;
    font-weight: 400;
    margin-bottom: 0.15rem;
    font-size: 0.9rem !important;
}

.product-tags {
    text-align: center;
    display: flex;
    flex-wrap: wrap;
    gap: 0.2rem;
    justify-content: center;
    font-weight: 400;
    font-size: 1.4rem !important;
    margin: 0;
    padding: 0;
}

.badge-km {
    background-color: var(--primary-color) !important;
    color: white !important;
    font-weight: 600 !important;
    padding: 0.2rem !important;
    font-size: 0.6rem !important;
    border-radius: 0.2rem;
    display: inline-block;
    border: 1px solid;
    white-space: nowrap;
    margin-right: 0.1rem;
    margin-bottom: 0.1rem;
}

.card-body p.card-text {
    text-align: center;
    margin-bottom: 0.8rem;
    min-height: 2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: var(--primary-color);
    color: white;
}

.card-body p.card-text strong {
    display: inline;
    font-size: 1.4rem !important;
    color: var(--primary-color);
    margin-bottom: 0;
    white-space: nowrap;
}

.product-img-fixed {
    object-fit: cover;
    height: 100px;
}

.product-img-placeholder {
    height: 100px;
}
