/* Related-product presentation is limited to the guarded BFW product template. */
.bfw-product-view .bfw-related-products {
    padding:32px;
    border:1px solid #dfe9e4;
    border-radius:20px;
    background:#f4f8f6;
}
.bfw-related-products .bfw-related-header {
    display:flex;
    align-items:center;
    justify-content:space-between;
    flex-wrap:wrap;
    gap:20px;
    margin-bottom:26px;
}
.bfw-related-products .bfw-related-header h2 {
    margin:0 0 12px;
    color:#0c2943;
    font:700 clamp(22px,2vw,28px)/1.25 "Raleway",Arial,sans-serif;
    letter-spacing:-.025em;
    text-transform:none;
}
.bfw-related-products .bfw-related-header p {
    margin:0;
    color:#526b63;
    font-size:13px;
    line-height:1.6;
}
.bfw-related-products .bfw-related-select-all {
    flex:0 0 auto;
    display:inline-flex;
    align-items:center;
    justify-content:center;
    min-height:42px;
    padding:10px 18px;
    border:1px solid #bfd7c9;
    border-radius:8px;
    background:#fff;
    color:#087343;
    font-size:13px;
    font-weight:700;
    text-decoration:none;
    text-transform:none;
}
.bfw-related-products .bfw-related-grid {
    display:grid;
    grid-template-columns:repeat(2,minmax(0,1fr));
    gap:20px;
    margin:0;
    padding:0;
    list-style:none;
}
.bfw-related-products .bfw-related-card {
    display:grid;
    grid-template-columns:clamp(112px,11vw,168px) minmax(0,1fr);
    align-items:center;
    gap:24px;
    margin:0;
    padding:24px;
    border:1px solid #dce6e0;
    border-radius:14px;
    background:#fff;
    transition:border-color .15s ease,box-shadow .15s ease;
}
.bfw-related-products .bfw-related-card:has(.aw-related-checkbox:checked) {
    border-color:#129e63;
    box-shadow:0 0 0 1px #129e63;
}
.bfw-related-products .bfw-related-image,
.bfw-related-products .bfw-related-details { min-width:0; }
.bfw-related-products .bfw-related-image > a { display:block; }
.bfw-related-products .bfw-related-image img {
    display:block;
    width:100%;
    height:auto;
    aspect-ratio:1;
    object-fit:contain;
    border:0;
}
.bfw-related-products .bfw-product-image-note { margin:8px 0 0; font-size:9px; }
.bfw-related-products .bfw-related-details h3 {
    margin:0 0 14px;
    font:600 17px/1.5 "Raleway",Arial,sans-serif;
    text-transform:none;
    overflow-wrap:anywhere;
}
.bfw-related-products .bfw-related-details h3 a { color:#0c2943; text-decoration:none; }
.bfw-related-products .bfw-related-details h3 a:hover { color:#087343; text-decoration:underline; }
.bfw-related-products .price-box { margin:0 0 16px; }
.bfw-related-products .price-box .price { color:#0c2943; font-size:22px; line-height:1.4; font-weight:700; }
.bfw-related-products .price-box .old-price .price { color:#647789; font-size:14px; }
.bfw-related-products .price-box .price-label { font-size:12px; }
.bfw-related-products .price-box .minimal-price-link {
    display:flex;
    align-items:baseline;
    flex-wrap:wrap;
    gap:5px;
    margin-top:5px;
    color:#365d50;
    text-decoration:none;
    text-transform:none;
}
.bfw-related-products .price-box .minimal-price-link .label { color:#526b63; font-size:12px; }
.bfw-related-products .price-box .minimal-price-link .price { color:#087343; font-size:16px; }
.bfw-related-products .bfw-related-select {
    display:flex;
    align-items:center;
    gap:10px;
    min-height:44px;
    margin:0;
    padding:10px 12px;
    border-radius:8px;
    background:#edf5f0;
    color:#195c40;
    font-size:13px;
    line-height:1.5;
    font-weight:600;
    cursor:pointer;
}
.bfw-related-products .bfw-related-select .aw-related-checkbox {
    flex:0 0 18px;
    width:18px;
    height:18px;
    margin:0;
    accent-color:#129e63;
    cursor:pointer;
}
.bfw-related-products .bfw-related-select-all:hover,
.bfw-related-products .bfw-related-select:hover { background:#e1efe7; }
.bfw-related-products .bfw-related-details-link { color:#087343; font-size:13px; font-weight:700; }
.bfw-related-products .bfw-related-sr-only {
    position:absolute;
    width:1px;
    height:1px;
    padding:0;
    margin:-1px;
    overflow:hidden;
    clip:rect(0,0,0,0);
    white-space:nowrap;
    border:0;
}
@media (max-width:1050px) {
    .bfw-product-view .bfw-related-products { padding:24px; }
    .bfw-related-products .bfw-related-card { padding:18px; gap:18px; grid-template-columns:100px minmax(0,1fr); }
    .bfw-related-products .bfw-related-details h3 { font-size:15px; }
}
@media (max-width:760px) {
    .bfw-related-products .bfw-related-grid { grid-template-columns:minmax(0,1fr); gap:16px; }
    .bfw-related-products .bfw-related-card { grid-template-columns:120px minmax(0,1fr); }
}
@media (max-width:450px) {
    .bfw-product-view .bfw-related-products { padding:18px; border-radius:16px; }
    .bfw-related-products .bfw-related-card { padding:16px; gap:14px; grid-template-columns:88px minmax(0,1fr); }
    .bfw-related-products .bfw-related-header { gap:14px; margin-bottom:20px; }
    .bfw-related-products .bfw-related-select { padding:10px; font-size:12px; gap:8px; }
}
@media (max-width:360px) {
    .bfw-related-products .bfw-related-card { grid-template-columns:minmax(0,1fr); }
    .bfw-related-products .bfw-related-image { width:140px; margin:0 auto; }
}
