/* Bridge Road Sliders — matches the Trader page (warm neutrals, white cards, 30px radius). */

.brs {
	--brs-accent: #233D6E;
	--brs-heading: #1C1B18;
	--brs-card-bg: #FFFFFF;
	--brs-text: #1C1B18;
	--brs-muted: #5E5A52;
	--brs-border: #E2DCD1;
	--brs-tile: #E7E1D6;
	--brs-radius: 30px;
	--brs-gap: 24px;
	--brs-show: var(--brs-show-d, 3);       /* "Slides to show" (1–4); -d = shortcode desktop value */
	--brs-dim: var(--brs-dim-d, .7);        /* spotlight: opacity of side cards */
	--brs-shrink: var(--brs-shrink-d, .95); /* spotlight: scale of side cards */
	/* Spotlight centre card: sized so N cards fit with the neighbours peeking in */
	--brs-peek: .6;     /* how much of the side cards shows (smaller on phones) */
	--brs-spot-w: calc((100% - var(--brs-show) * var(--brs-gap)) / (var(--brs-show) + var(--brs-peek)));
	position: relative;
	width: 100%;
	min-width: 0;
	max-width: 100%;
	color: var(--brs-text);
	font-family: inherit;
}
.elementor-widget-bridgerd-slider { min-width: 0; max-width: 100%; }
.brs__viewport { min-width: 0; }

/* Defaults for the shortcode (Elementor's responsive controls override these). */
@media (max-width: 1024px) { .brs { --brs-show: 2; --brs-dim: .6; --brs-shrink: .93; } }
@media (max-width: 767px)  { .brs { --brs-show: 1; --brs-dim: .45; --brs-shrink: .9; --brs-gap: 16px; --brs-peek: .25; } }
.brs *, .brs *::before, .brs *::after { box-sizing: border-box; }
.brs .brs-icon { flex: none; }

/* ---------- Header ---------- */
.brs__head {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 10px 24px;
	margin: 0 0 20px;
}
.brs .brs__heading {
	margin: 0;
	color: var(--brs-heading);
	font-size: clamp(26px, 3vw, 36px);
	font-weight: 700;
	line-height: 1.1;
	letter-spacing: -0.01em;
}
.brs__head-actions { display: flex; align-items: center; gap: 16px; margin-left: var(--brs-actions-ml, auto); }
.brs .brs__all {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	color: var(--brs-accent);
	font-size: 15px;
	font-weight: 600;
	text-decoration: none;
	white-space: nowrap;
}
.brs .brs__all:hover { text-decoration: underline; text-underline-offset: 3px; }
.brs .brs__all .brs-icon { width: 16px; height: 16px; transition: transform .2s; }
.brs .brs__all:hover .brs-icon { transform: translateX(3px); }

/* ---------- Arrows ---------- */
.brs__nav { display: flex; gap: 8px; }
.brs .brs__btn {
	width: 48px;
	height: 48px;
	margin: 0;
	padding: 0;
	border: 1px solid var(--brs-border);
	border-radius: 999px;
	background: var(--brs-card-bg);
	color: var(--brs-text);
	display: inline-flex;
	align-items: center;
	justify-content: center;
	cursor: pointer;
	box-shadow: none;
	transition: background-color .2s, color .2s, border-color .2s, opacity .2s, transform .2s;
}
.brs .brs__btn:hover { background: var(--brs-accent); border-color: var(--brs-accent); color: #fff; }
.brs .brs__btn:focus-visible { outline: 3px solid var(--brs-accent); outline-offset: 2px; }
.brs .brs__btn:disabled { opacity: .35; cursor: default; pointer-events: none; }
.brs--static .brs__nav,
.brs--static .brs__dots,
.brs--static .brs__progress { display: none; }

/* ---------- Track ---------- */
.brs__viewport { position: relative; }
.brs .brs__track {
	position: relative;
	list-style: none;
	margin: 0;
	padding: 6px 0 28px;
	display: flex;
	gap: var(--brs-gap);
	overflow-x: auto;
	overflow-y: hidden;
	scroll-snap-type: x mandatory;
	scroll-behavior: smooth;
	scrollbar-width: none;
	overscroll-behavior-x: contain;
	-webkit-overflow-scrolling: touch;
}
.brs .brs__track::-webkit-scrollbar { display: none; }
.brs .brs__track:focus-visible { outline: 3px solid var(--brs-accent); outline-offset: 4px; border-radius: 12px; }
.brs .brs__slide {
	flex: 0 0 calc((100% - (var(--brs-show) - 1) * var(--brs-gap)) / var(--brs-show));
	display: flex;
	margin: 0;
	padding: 0;
	scroll-snap-align: start;
}
.brs .brs__slide::before { content: none; } /* themes that add list bullets */

/* ---------- Spotlight layout ---------- */
.brs--spotlight .brs__slide {
	flex-basis: var(--brs-spot-w);
	scroll-snap-align: center;
	opacity: var(--brs-dim);
	transform: scale(var(--brs-shrink));
	transition: opacity .45s ease, transform .45s ease;
	cursor: pointer;
}
.brs--spotlight .brs__slide.is-active { opacity: 1; transform: none; cursor: auto; }
.brs--spotlight .brs__slide { transform-origin: center center; }
.brs--spotlight .brs__slide:first-child { transform-origin: left center; }  /* stays flush with the left edge */
.brs--spotlight .brs__slide:last-child { transform-origin: right center; }  /* and the right edge */
/* First slide starts on the left edge, last ends on the right; snapping is done in JS. */
.brs--spotlight .brs__track { scroll-snap-type: none; }
/* Everything fits: no dimming, nothing to scroll */
.brs--static.brs--spotlight .brs__slide { opacity: 1; transform: none; cursor: auto; }
.brs--spotlight .brs__nav {
	position: absolute;
	inset: 0 0 28px;
	pointer-events: none;
	z-index: 3;
}
.brs--spotlight .brs__btn {
	position: absolute;
	top: 34%;
	width: 52px;
	height: 52px;
	transform: translateY(-50%);
	pointer-events: auto;
	border-color: transparent;
	box-shadow: 0 2px 6px rgba(28, 27, 24, .12), 0 10px 24px rgba(28, 27, 24, .12);
}
.brs--spotlight .brs__btn--prev { left: 14px; }
.brs--spotlight .brs__btn--next { right: 14px; }
.brs--spotlight .brs__btn:hover { transform: translateY(-50%) scale(1.06); }
.brs--spotlight .brs__btn:disabled { opacity: 0; } /* nothing further that way: hide it */

.brs__dots { display: flex; justify-content: center; gap: 2px; margin-top: -6px; }
.brs .brs__dot {
	width: 24px;
	height: 24px;
	margin: 0;
	padding: 0;
	border: 0;
	background: transparent;
	cursor: pointer;
	display: inline-flex;
	align-items: center;
	justify-content: center;
}
.brs .brs__dot::before {
	content: "";
	width: 8px;
	height: 8px;
	border-radius: 999px;
	background: var(--brs-border);
	transition: width .3s, background-color .3s;
	filter: brightness(.85);
}
.brs .brs__dot[aria-current="true"]::before { width: 24px; background: var(--brs-accent); filter: none; }
.brs .brs__dot:focus-visible { outline: 2px solid var(--brs-accent); outline-offset: 1px; border-radius: 999px; }

/* ---------- Row progress ---------- */
.brs__progress {
	position: relative;
	height: 4px;
	max-width: 220px;
	margin: -4px auto 0;
	border-radius: 999px;
	background: var(--brs-border);
	overflow: hidden;
}
.brs__progress span {
	position: absolute;
	inset: 0 auto 0 0;
	width: 30%;
	border-radius: 999px;
	background: var(--brs-accent);
	transition: transform .15s linear;
}

/* ---------- Grid layout (no slider) ---------- */
.brs .brs__grid {
	list-style: none;
	margin: 0;
	padding: 0;
	display: grid;
	grid-template-columns: repeat(var(--brs-show), minmax(0, 1fr));
	gap: var(--brs-gap);
}
.brs .brs__item { display: flex; margin: 0; padding: 0; min-width: 0; }
.brs .brs__item::before { content: none; }
.brs--grid .brs-card:hover { transform: translateY(-4px); box-shadow: 0 2px 4px rgba(28, 27, 24, .06), 0 16px 32px rgba(28, 27, 24, .1); }

/* Featured first card: full width, image beside the text */
.brs--featured .brs__item:first-child { grid-column: 1 / -1; }
.brs--featured .brs__item:first-child .brs-card { flex-direction: row; }
.brs--featured .brs__item:first-child .brs-card__media { flex: 0 0 48%; aspect-ratio: 16 / 9; } /* ~550px: keeps 500px images sharp */
.brs--featured .brs__item:first-child .brs-card__body { justify-content: center; gap: 12px; padding: 36px 40px; }
.brs--featured .brs__item:first-child .brs-card__title { font-size: clamp(22px, 2.4vw, 30px); }
.brs--featured .brs__item:first-child .brs-card__text { -webkit-line-clamp: 5; font-size: 16px; }
.brs--featured .brs__item:first-child .brs-card__cta { margin-top: 8px; }

/* ---------- Cards ---------- */
.brs-card {
	position: relative;
	display: flex;
	flex-direction: column;
	width: 100%;
	background: var(--brs-card-bg);
	color: var(--brs-text);
	border-radius: var(--brs-radius);
	overflow: hidden;
	box-shadow: 0 1px 2px rgba(28, 27, 24, .05), 0 8px 24px rgba(28, 27, 24, .06);
	transition: transform .25s ease, box-shadow .25s ease;
}
.brs--row .brs-card:hover { transform: translateY(-4px); box-shadow: 0 2px 4px rgba(28, 27, 24, .06), 0 16px 32px rgba(28, 27, 24, .1); }
.brs-card:focus-within { outline: 3px solid var(--brs-accent); outline-offset: 3px; }

.brs-card__media {
	position: relative;
	aspect-ratio: 16 / 10;
	background: var(--brs-tile);
	overflow: hidden;
}
.brs-card--offer .brs-card__media { aspect-ratio: 16 / 9; }
.brs .brs-card__img {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	max-width: none;
	object-fit: cover;
	border-radius: 0;
	transition: transform .6s ease;
}
.brs-card:hover .brs-card__img { transform: scale(1.04); }
.brs-card__fallback {
	position: absolute;
	inset: 0;
	display: flex;
	align-items: center;
	justify-content: center;
	background: var(--brs-tile);
	color: var(--brs-accent);
	font-size: clamp(56px, 7vw, 96px);
	font-weight: 700;
	line-height: 1;
}

/* Date tile (Trader Events) */
.brs-card__date {
	position: absolute;
	top: 16px;
	left: 16px;
	z-index: 2;
	min-width: 62px;
	padding: 9px 10px 8px;
	border-radius: 16px;
	background: #fff;
	color: var(--brs-text);
	text-align: center;
	display: flex;
	flex-direction: column;
	line-height: 1;
	box-shadow: 0 4px 14px rgba(28, 27, 24, .14);
}
.brs-card__day { font-size: 26px; font-weight: 700; }
.brs-card__month {
	margin-top: 4px;
	color: var(--brs-accent);
	font-size: 12px;
	font-weight: 600;
	letter-spacing: .08em;
	text-transform: uppercase;
}

/* Ends badge (Offers) */
.brs-card__badge {
	position: absolute;
	top: 14px;
	right: 14px;
	z-index: 2;
	padding: 7px 12px;
	border-radius: 999px;
	background: #fff;
	color: var(--brs-text);
	font-size: 13px;
	font-weight: 600;
	line-height: 1;
	box-shadow: 0 4px 14px rgba(28, 27, 24, .14);
}
.brs-card__badge.is-urgent { background: var(--brs-accent); color: #fff; }

/* Body */
.brs-card__body {
	display: flex;
	flex-direction: column;
	gap: 10px;
	flex: 1;
	padding: 22px 24px 24px;
}
.brs .brs-card__eyebrow {
	margin: 0;
	color: var(--brs-accent);
	font-size: 12px;
	font-weight: 600;
	letter-spacing: .08em;
	text-transform: uppercase;
}
.brs .brs-card__title {
	margin: 0;
	color: var(--brs-title, var(--brs-text));
	font-size: 20px;
	font-weight: 700;
	line-height: 1.25;
}
.brs--spotlight .brs-card__title { font-size: clamp(20px, 2vw, 26px); }
.brs .brs-card__title a { color: inherit; text-decoration: none; outline: none; }
.brs .brs-card__title a::after { content: ""; position: absolute; inset: 0; z-index: 1; } /* whole card clickable */
.brs-card:hover .brs-card__title a { text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 4px; }

.brs .brs-card__meta {
	list-style: none;
	margin: 0;
	padding: 0;
	display: flex;
	flex-wrap: wrap;
	gap: 6px 18px;
	color: var(--brs-muted);
	font-size: 15px;
	font-weight: 400;
	line-height: 1.4;
}
.brs .brs-card__meta li { display: inline-flex; align-items: center; gap: 7px; margin: 0; padding: 0; }
.brs .brs-card__meta li::before { content: none; }
.brs .brs-card__meta .brs-icon { width: 17px; height: 17px; color: var(--brs-accent); }

.brs .brs-card__trader {
	position: relative;
	z-index: 2;
	margin: auto 0 0;
	padding-top: 4px;
	color: var(--brs-muted);
	font-size: 14px;
}
.brs .brs-card__trader a { color: var(--brs-accent); font-weight: 600; text-decoration: none; }
.brs .brs-card__trader a:hover { text-decoration: underline; }

.brs .brs-card__text {
	margin: 0;
	color: var(--brs-muted);
	font-size: 15px;
	line-height: 1.55;
	display: -webkit-box;
	-webkit-line-clamp: 3;
	-webkit-box-orient: vertical;
	overflow: hidden;
}
.brs-card__cta {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	margin-top: auto;
	padding-top: 6px;
	color: var(--brs-accent);
	font-size: 15px;
	font-weight: 600;
}
.brs-card__cta .brs-icon { width: 16px; height: 16px; transition: transform .2s; }
.brs-card:hover .brs-card__cta .brs-icon { transform: translateX(4px); }

/* ---------- Empty + editor ---------- */
.brs__empty { margin: 0; color: var(--brs-muted); }
.brs-editor-note {
	padding: 20px 24px;
	border: 1px dashed #CFC7B8;
	border-radius: 16px;
	background: #FBF9F5;
	color: #5E5A52;
	font-size: 14px;
	line-height: 1.5;
}

/* ---------- Small screens ---------- */
@media (max-width: 767px) {
	.brs__head { margin-bottom: 14px; }
	.brs--featured .brs__item:first-child .brs-card { flex-direction: column; }
	.brs--featured .brs__item:first-child .brs-card__media { flex-basis: auto; }
	.brs--featured .brs__item:first-child .brs-card__body { padding: 18px 20px 20px; }
	.brs--featured .brs__item:first-child .brs-card__text { -webkit-line-clamp: 3; font-size: 15px; }
	.brs .brs__btn { width: 44px; height: 44px; }
	.brs--row .brs__nav { display: none; }       /* swipe instead */
	.brs--spotlight .brs__nav { display: none; } /* swipe + dots instead */
	.brs-card__body { padding: 18px 20px 20px; }
}

@media (prefers-reduced-motion: reduce) {
	.brs .brs__track { scroll-behavior: auto; }
	.brs *, .brs *::before, .brs *::after { transition: none !important; }
}
