/* Supplied Trades explorer, scoped to the existing native Trades route. */
#bs-trade-finder[hidden]{display:none!important}
#bs-trade-finder{--brand-teal:var(--by5-teal);--accent-cyan:var(--by5-teal);--text-dark:var(--by5-text-dark);--text-muted:var(--by5-text-muted);--border-gray:var(--by5-border);--bg-slate:var(--by5-bg-soft);position:relative;margin:0;padding:0;background:#fff;color:var(--by5-text-dark);font-family:Inter,Arial,sans-serif;overflow:visible}
#bs-trade-finder #bs-trade-title{position:absolute;width:1px;height:1px;margin:-1px;padding:0;overflow:hidden;clip-path:inset(50%);white-space:nowrap}
#bs-trade-finder .trades-explorer-section{box-sizing:border-box;position:static;display:grid;grid-template-columns:minmax(0,1fr);align-items:start;gap:24px;width:100%;max-width:none;min-height:0;margin:48px 0;padding:0 24px}
#bs-trade-finder .left-index-column{display:flex;flex-direction:column;gap:32px;min-width:0}
#bs-trade-finder .search-filter-row{display:grid;grid-template-columns:minmax(0,1fr);gap:16px;margin:0;padding:24px;border:1px solid var(--by5-border);border-radius:16px;background:var(--by5-bg-soft)}
#bs-trade-finder .form-element-wrap{min-width:0}
#bs-trade-finder .form-element-wrap label{display:block;margin:0 0 8px;color:var(--by5-text-dark);font:700 13.6px/1.5 Inter,Arial,sans-serif}
#bs-trade-finder .input-field-style{box-sizing:border-box;display:block;width:100%;min-width:0;min-height:46px;height:auto;margin:0;padding:12px 16px;border:1px solid var(--by5-border);border-radius:8px;background:#fff;color:var(--by5-text-dark);outline:none;font:400 14.4px/1.5 Inter,Arial,sans-serif}
#bs-trade-finder .input-field-style::placeholder{color:var(--by5-text-muted);opacity:1}
#bs-trade-finder option{background:#fff;color:var(--by5-text-dark)}
#bs-trade-finder .input-field-style:focus-visible,#bs-trade-finder .trade-chip-card:focus-visible{outline:3px solid var(--by5-teal);outline-offset:3px}
#bs-trade-finder .chips-grid-matrix{display:grid;grid-template-columns:minmax(0,1fr);gap:8px;margin:0;padding:0;list-style:none}
#bs-trade-finder .trade-chip-card{box-sizing:border-box;display:flex;align-items:center;gap:8px;min-width:0;min-height:44px;margin:0;padding:10px 12px;border:1px solid var(--by5-border);border-radius:10px;background:var(--by5-bg-soft);color:var(--by5-text-muted);font:500 13px/1.4 Inter,Arial,sans-serif;text-align:left;text-decoration:none;cursor:pointer;transition:background-color .2s ease,border-color .2s ease,color .2s ease,transform .2s ease}
#bs-trade-finder .trade-chip-card:hover,#bs-trade-finder .trade-chip-card:focus-visible,#bs-trade-finder .trade-chip-card[aria-pressed="true"]{background:rgba(0,140,168,.08);border-color:var(--by5-teal);color:var(--by5-teal);transform:translateY(-1px)}
#bs-trade-finder .trade-chip-icon{flex:0 0 20px;text-align:center}
#bs-trade-finder .trade-chip-label{min-width:0;overflow-wrap:break-word;text-transform:uppercase}
#bs-trade-finder .right-image-showcase-panel{box-sizing:border-box;position:relative;display:grid;grid-template-columns:minmax(0,1fr);grid-template-rows:auto auto;align-self:start;align-content:start;justify-content:start;min-width:0;min-height:0;height:auto;margin:0;border:1px solid var(--by5-border);border-radius:20px;overflow:hidden;box-shadow:0 4px 6px -1px rgba(0,0,0,.05);background:var(--by5-bg-cream)}
/* Only the active preview contributes height; hidden trades cannot stretch shorter cards. */
#bs-trade-finder .showcase-image-layer{position:relative;inset:auto;grid-area:1/1;display:none;flex-direction:column;justify-content:flex-start;align-items:stretch;align-self:start;min-width:0;min-height:0;width:100%;height:auto;margin:0;opacity:0;visibility:hidden;z-index:1;transition:opacity .3s ease;pointer-events:none}
#bs-trade-finder .showcase-image-layer.is-active{display:flex;opacity:1;visibility:visible;pointer-events:auto;z-index:2}
#bs-trade-finder .showcase-image-layer img{position:relative;inset:auto;display:block;flex:0 0 auto;width:100%;height:auto;aspect-ratio:3/2;max-width:100%;margin:0;object-fit:cover;object-position:center top}
/* Keep the Handyman face in view within the tall trade image frame. */
#bs-trade-finder .target-maintenance-img img{object-position:28% top}
#bs-trade-finder .image-caption-overlay{box-sizing:border-box;position:relative;z-index:1;flex:0 0 auto;justify-content:flex-start;width:100%;min-width:0;min-height:0;height:auto;margin:0;padding:24px;background:var(--by5-bg-cream);color:var(--by5-text-dark)}
#bs-trade-finder .caption-title{margin:0;color:var(--by5-text-dark);font:800 20px/1.3 Inter,Arial,sans-serif;letter-spacing:-.01em}
#bs-trade-finder .caption-sub{margin:2.4px 0 0;color:var(--by5-text-dark);font:400 12.8px/1.5 Inter,Arial,sans-serif}
#bs-trade-finder .bs-trade-status{margin:0;padding:0;color:var(--by5-text-muted);font:400 13px/1.5 Inter,Arial,sans-serif}
#bs-trade-finder .bs-trade-empty{grid-column:1/-1;margin:0;padding:16px;color:var(--by5-text-muted);font:400 14px/1.6 Inter,Arial,sans-serif}
@media(min-width:480px){#bs-trade-finder .chips-grid-matrix{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(min-width:640px){#bs-trade-finder .search-filter-row{grid-template-columns:minmax(0,1.5fr) minmax(0,1fr)}}
@media(min-width:768px){#bs-trade-finder .chips-grid-matrix{grid-template-columns:repeat(3,minmax(0,1fr))}}
@media(min-width:1024px){#bs-trade-finder .trades-explorer-section{grid-template-columns:minmax(0,.8fr) minmax(0,1.2fr)}#bs-trade-finder .chips-grid-matrix{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:479px){#bs-trade-finder .trades-explorer-section{margin-block:32px;padding-inline:20px;gap:32px}#bs-trade-finder .search-filter-row{padding:20px}}
@media(prefers-reduced-motion:reduce){#bs-trade-finder .trade-chip-card,#bs-trade-finder .showcase-image-layer{transition:none}#bs-trade-finder .trade-chip-card:hover,#bs-trade-finder .trade-chip-card:focus-visible,#bs-trade-finder .trade-chip-card[aria-pressed="true"]{transform:none}}

/* Shared trade cards use the Window & Door Fitters 3:2 photo and warm-grey information layout.
 * Each active trade keeps its own natural information height. */
#bs-trade-finder .window-weekly-overhead{margin:28px 0 0;padding:0;color:var(--by5-text-dark);font:400 14px/1.6 Inter,Arial,sans-serif}
#bs-trade-finder .window-weekly-overhead h4{margin:0 0 8px;color:var(--by5-text-dark);font:650 20px/1.3 Inter,Arial,sans-serif;letter-spacing:-.01em}
#bs-trade-finder .window-weekly-overhead p{margin:0 0 20px;color:var(--by5-text-dark);font:400 14px/1.6 Inter,Arial,sans-serif}
#bs-trade-finder .window-weekly-overhead .window-weekly-total{margin-bottom:20px;font-size:16px}
#bs-trade-finder .window-weekly-table{width:100%;margin:24px 0 0;border-collapse:collapse;table-layout:fixed;color:var(--by5-text-dark);font:400 13px/1.6 Inter,Arial,sans-serif;text-align:left}
#bs-trade-finder .window-weekly-table th,#bs-trade-finder .window-weekly-table td{padding:14px 10px 14px 0;border:0;border-bottom:1px solid rgba(37,43,39,.2);color:var(--by5-text-dark);vertical-align:top;overflow-wrap:break-word}
#bs-trade-finder .window-weekly-table thead th{font-weight:700}
#bs-trade-finder .window-weekly-table thead th:nth-child(1){width:26%}
#bs-trade-finder .window-weekly-table thead th:nth-child(2){width:23%}
#bs-trade-finder .window-weekly-table thead th:nth-child(3){width:51%}
#bs-trade-finder .window-weekly-table tbody th{font-weight:700}
#bs-trade-finder .window-weekly-table tr>*:last-child{padding-right:0}
#bs-trade-finder .window-weekly-table tbody tr:last-child>*{border-bottom:0}
@media(max-width:600px){
  #bs-trade-finder .window-weekly-table,#bs-trade-finder .window-weekly-table tbody,#bs-trade-finder .window-weekly-table tr,#bs-trade-finder .window-weekly-table tbody th,#bs-trade-finder .window-weekly-table td{display:block;width:auto}
  #bs-trade-finder .window-weekly-table thead{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap}
  #bs-trade-finder .window-weekly-table tbody tr{padding:16px 0;border-bottom:1px solid rgba(37,43,39,.2)}
  #bs-trade-finder .window-weekly-table tbody tr:last-child{border-bottom:0}
  #bs-trade-finder .window-weekly-table tbody th,#bs-trade-finder .window-weekly-table td{padding:4px 0;border:0}
  #bs-trade-finder .window-weekly-table td[data-label]::before{content:attr(data-label) ": ";font-weight:700}
}
