/* ReviewSL Branch Finder (v1.5.5)
 * Neutral colours that sit on light and dark themes. Override the variables
 * from your theme, e.g.  .rsl-bf-tools { --rsl-bf-accent: #f97316; }
 */
.rsl-bf-tools,
.rsl-bf-jump,
.rsl-bf-more,
.rsl-bf-card {
    --rsl-bf-accent: #f97316;
    --rsl-bf-accent-ink: #fff;
    --rsl-bf-line: rgba(128, 128, 128, .28);
    --rsl-bf-fill: rgba(128, 128, 128, .10);
    --rsl-bf-muted: rgba(128, 128, 128, .95);
}

.rsl-bf-tools {
    padding: 14px 16px 10px;
    border-bottom: 1px solid var(--rsl-bf-line);
    font-size: 14px;
}
.rsl-bf-row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
}
.rsl-bf-search {
    flex: 1 1 220px;
    display: flex;
    align-items: center;
    gap: 8px;
    min-width: 0;
    margin: 0;
    padding: 0 12px;
    height: 40px;
    border: 1px solid var(--rsl-bf-line);
    border-radius: 10px;
    background: var(--rsl-bf-fill);
    color: inherit;
    cursor: text;
}
.rsl-bf-search:focus-within {
    border-color: var(--rsl-bf-accent);
    box-shadow: 0 0 0 3px rgba(249, 115, 22, .18);
}
.rsl-bf-search svg { flex: none; opacity: .6; }
.rsl-bf-search input {
    flex: 1;
    min-width: 0;
    height: 100%;
    margin: 0;
    padding: 0;
    border: 0 !important;
    outline: 0;
    background: transparent !important;
    box-shadow: none !important;
    color: inherit;
    font: inherit;
}
.rsl-bf-search input::placeholder { color: inherit; opacity: .55; }

.rsl-bf-near,
.rsl-bf-sort {
    height: 40px;
    margin: 0;
    border: 1px solid var(--rsl-bf-line);
    border-radius: 10px;
    background: var(--rsl-bf-fill);
    color: inherit;
    font: inherit;
    font-size: 13px;
    font-weight: 600;
}
.rsl-bf-near {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 0 14px;
    cursor: pointer;
    white-space: nowrap;
}
.rsl-bf-near:hover { border-color: var(--rsl-bf-accent); }
.rsl-bf-near.is-on {
    background: var(--rsl-bf-accent);
    border-color: var(--rsl-bf-accent);
    color: var(--rsl-bf-accent-ink);
}
.rsl-bf-near.is-busy { opacity: .7; cursor: progress; }
.rsl-bf-sort { padding: 0 10px; cursor: pointer; max-width: 160px; }
.rsl-bf-sort option { color: #111; background: #fff; }

.rsl-bf-chips {
    display: flex;
    gap: 6px;
    margin: 10px -16px 0;
    padding: 0 16px 4px;
    overflow-x: auto;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
}
.rsl-bf-chips::-webkit-scrollbar { display: none; }
.rsl-bf-chip {
    flex: none;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    height: 30px;
    margin: 0;
    padding: 0 12px;
    border: 1px solid var(--rsl-bf-line);
    border-radius: 99px;
    background: transparent;
    color: inherit;
    font: inherit;
    font-size: 12.5px;
    font-weight: 600;
    cursor: pointer;
    white-space: nowrap;
}
.rsl-bf-chip b {
    font-size: 11px;
    font-weight: 700;
    opacity: .6;
}
.rsl-bf-chip:hover { border-color: var(--rsl-bf-accent); }
.rsl-bf-chip.is-on {
    background: var(--rsl-bf-accent);
    border-color: var(--rsl-bf-accent);
    color: var(--rsl-bf-accent-ink);
}
.rsl-bf-chip.is-on b { opacity: .85; }

.rsl-bf-status {
    margin-top: 8px;
    font-size: 12.5px;
    color: var(--rsl-bf-muted);
    line-height: 1.5;
}
.rsl-bf-status[hidden] { display: none; }
.rsl-bf-status b { color: inherit; }
.rsl-bf-status a { color: var(--rsl-bf-accent); font-weight: 600; }
.rsl-bf-clear {
    margin: 0 0 0 4px;
    padding: 0;
    border: 0;
    background: none;
    color: var(--rsl-bf-accent);
    font: inherit;
    font-weight: 600;
    text-decoration: underline;
    cursor: pointer;
}
.rsl-bf-note { opacity: .8; }
.rsl-bf-warn { color: #dc2626; }

/* cards */
.rsl-bf-hide { display: none !important; }
.rsl-bf-dist {
    display: inline-block;
    margin-top: 4px;
    padding: 1px 7px;
    border-radius: 99px;
    background: var(--rsl-bf-fill);
    font-size: 11px;
    font-weight: 600;
    line-height: 1.6;
}
.rsl-bf-is-nearest .rsl-bf-dist {
    background: var(--rsl-bf-accent);
    color: var(--rsl-bf-accent-ink);
}
.rsl-bf-is-nearest { box-shadow: inset 3px 0 0 var(--rsl-bf-accent); }

/* fluid columns: the old fixed 3-column grid cut long branch names off on the right */
.rsl-bf-on .rsl-branch-cards.rsl-bf-list { grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)) !important; }
.rsl-bf-list > * { min-width: 0; }

/* hiding cards breaks nth-child border tricks in the old grid, so draw dividers evenly */
.rsl-bf-on .rsl-branch-card { border-right: 0 !important; border-bottom: 1px solid var(--rsl-bf-line) !important; }

.rsl-bf-more {
    display: block;
    width: calc(100% - 32px);
    margin: 10px 16px 14px;
    height: 38px;
    border: 1px dashed var(--rsl-bf-line);
    border-radius: 10px;
    background: transparent;
    color: var(--rsl-bf-accent);
    font: inherit;
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
}
.rsl-bf-more[hidden] { display: none; }
.rsl-bf-more:hover { border-color: var(--rsl-bf-accent); }

/* "Find a branch · Near me" pill under the listing title */
.rsl-bf-jump {
    display: inline-flex;
    align-items: stretch;
    margin: 8px 0 4px;
    border: 1px solid var(--rsl-bf-line);
    border-radius: 99px;
    overflow: hidden;
    font-size: 13px;
    font-weight: 600;
    line-height: 1;
    vertical-align: middle;
}
.rsl-bf-jump a,
.rsl-bf-jump button {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin: 0;
    padding: 8px 13px;
    border: 0;
    background: transparent;
    color: inherit;
    font: inherit;
    text-decoration: none !important;
    cursor: pointer;
}
.rsl-bf-jump a b {
    padding: 2px 6px;
    border-radius: 99px;
    background: var(--rsl-bf-accent);
    color: var(--rsl-bf-accent-ink);
    font-size: 11px;
}
.rsl-bf-jump button { border-left: 1px solid var(--rsl-bf-line); color: var(--rsl-bf-accent); }
.rsl-bf-jump a:hover,
.rsl-bf-jump button:hover { background: var(--rsl-bf-fill); }
.rsl-bf-jump button.is-on { background: var(--rsl-bf-accent); color: var(--rsl-bf-accent-ink); }

@media (max-width: 540px) {
    .rsl-bf-tools { padding: 12px 12px 8px; }
    .rsl-bf-chips { margin: 10px -12px 0; padding: 0 12px 4px; }
    .rsl-bf-search { flex-basis: 100%; }
    .rsl-bf-near, .rsl-bf-sort { flex: 1 1 0; justify-content: center; max-width: none; }
}
