/* tire.ua — Home Tires Widget. 3 секции продуктов с карточкой по референс-дизайну. */
.tua-home-tires {
    display: flex; flex-direction: column; gap: 48px;
    max-width: 1320px;
    margin: 0 auto; /* Center inside full-width Journal slots */
    padding: 140px 24px 32px; /* 140px top чтобы первый заголовок не лез под sticky-header */
    position: relative;
    z-index: 1;
    clear: both;
}
@media (max-width: 1400px) { .tua-home-tires { max-width: calc(100% - 32px); } }
/* Для последующих секций нужен меньший зазор */
.tua-home-tires .tua-ht-section + .tua-ht-section { padding-top: 0; }

.tua-ht-section-header {
    display: flex; align-items: center; justify-content: space-between;
    margin-bottom: 20px; gap: 16px;
}
.tua-ht-section-title {
    font-size: 28px; font-weight: 700; margin: 0; color: #1a1a1a;
    border-bottom: 3px solid #FFAD00; padding-bottom: 8px; display: inline-block;
}
.tua-ht-section-link {
    color: #FFAD00 !important;
    text-decoration: underline;
    font-weight: 600;
    font-size: 14px;
    white-space: nowrap;
    display: inline-block;
    padding: 8px 12px;
    cursor: pointer;
    pointer-events: auto;
    position: relative;
    z-index: 5;
    flex-shrink: 0;
}
.tua-ht-section-link:hover { color: #d68f00 !important; }

.tua-ht-grid {
    display: grid; gap: 16px;
    grid-template-columns: repeat(4, 1fr);
}
@media (max-width: 1100px) { .tua-ht-grid { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 800px)  { .tua-ht-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 480px)  { .tua-ht-grid { grid-template-columns: 1fr; } }

.tua-ht-card {
    background: #fff; border: 1px solid #eaeaea; border-radius: 8px;
    padding: 16px; display: flex; flex-direction: column; gap: 12px;
    transition: box-shadow 0.2s, border-color 0.2s;
}
.tua-ht-card:hover { box-shadow: 0 4px 16px rgba(0,0,0,0.08); border-color: #FFAD00; }

.tua-ht-brand {
    align-self: flex-start;
    background: #f3f3f3; color: #555; padding: 4px 10px; border-radius: 4px;
    font-size: 12px; font-weight: 500; min-height: 22px;
}
.tua-ht-brand-empty { background: #f7f7f7; }

.tua-ht-name {
    font-size: 14px; font-weight: 500; margin: 0; line-height: 1.4; min-height: 38px;
}
.tua-ht-name a {
    color: #1a1a1a; text-decoration: underline; text-decoration-color: #d0d0d0;
}
.tua-ht-name a:hover { color: #FFAD00; text-decoration-color: #FFAD00; }

.tua-ht-meta { display: flex; justify-content: space-between; align-items: center; font-size: 12px; gap: 8px; }
.tua-ht-stars { display: flex; align-items: center; gap: 4px; color: #d0a017; }
.tua-ht-stars i { font-size: 14px; font-style: normal; line-height: 1; }
.tua-ht-stars i::before { content: '★'; }
.tua-ht-stars i.fa-star-o::before { content: '☆'; }
.tua-ht-stars i.empty { color: #cccccc; }
.tua-ht-reviews { color: #888; margin-left: 4px; text-decoration: underline; }
.tua-ht-stock { font-weight: 600; font-size: 13px; white-space: nowrap; }
.tua-ht-stock.in { color: #2eb15d; }
.tua-ht-stock.out { color: #c0392b; }

.tua-ht-image {
    display: flex; align-items: center; justify-content: center;
    aspect-ratio: 1 / 1; padding: 0; background: #fafafa; border-radius: 4px;
    overflow: hidden; /* sides clipped if image wider than card; top/bottom flush */
}
.tua-ht-image img {
    /* По высоте — strict 100% (без полей сверху/снизу).
     * По ширине — auto + max-width: none → если фото шире карточки, бока подрежутся overflow:hidden. */
    height: 100%;
    width: auto;
    max-width: none;
    object-fit: cover;
}

.tua-ht-price {
    font-size: 28px; font-weight: 700; font-style: italic; color: #1a1a1a; line-height: 1;
}
.tua-ht-price::after {
    content: " грн."; font-size: 14px; font-weight: 500; color: #888; font-style: normal;
}

.tua-ht-buy { display: flex; gap: 8px; align-items: stretch; }
.tua-ht-qty {
    width: 60px; padding: 8px; border: 1px solid #ddd; border-radius: 4px;
    text-align: center; font-size: 14px;
}
.tua-ht-cta {
    flex: 1; background: #FFAD00; color: #fff; border: 0; border-radius: 4px;
    padding: 8px 12px; font-weight: 700; font-size: 12px; text-transform: uppercase;
    cursor: pointer; display: flex; align-items: center; justify-content: center; gap: 8px;
    transition: background 0.15s;
}
.tua-ht-cta:hover { background: #FF8500; }
.tua-ht-cta i { font-size: 14px; }

.tua-ht-actions { display: flex; gap: 16px; padding-top: 8px; border-top: 1px solid #f0f0f0; }
.tua-ht-action {
    display: flex; align-items: center; gap: 6px;
    color: #FFAD00; font-size: 12px; text-decoration: none;
}
.tua-ht-action span { text-decoration: underline; text-decoration-color: #FFAD00; }
.tua-ht-action:hover { color: #d68f00; }
.tua-ht-action i { font-size: 14px; }

.tua-ht-empty { color: #888; padding: 32px; text-align: center; }
