/**
 * SkillBooks Dynamic Bundle Builder Styles
 */

/* ==========================================================================
   0. Full-Width Wide Desktop Layout Breakout
   ========================================================================== */

.sb-page:has([data-sb-bundle-builder]),
.sb-container:has([data-sb-bundle-builder]),
.sb-container.sb-bb-wide-container,
.sb-container--wide {
	max-width: 1480px !important;
	width: 100% !important;
}

.sb-page-content:has([data-sb-bundle-builder]),
.sb-page-content.sb-bb-wide-content,
.sb-prose:has([data-sb-bundle-builder]),
.sb-page-content--wide {
	max-width: 100% !important;
	width: 100% !important;
}

.sb-bb-wrapper {
	margin: 20px 0 60px;
	width: 100%;
	font-family: inherit;
}

/* ==========================================================================
   1. Interactive Tier Milestones Banner
   ========================================================================== */

.sb-bb-tiers-banner {
	background: linear-gradient(135deg, #1e1b4b 0%, #312e81 100%);
	border-radius: 16px;
	padding: 24px;
	color: #ffffff;
	margin-bottom: 24px;
	box-shadow: 0 10px 25px -5px rgba(49, 46, 129, 0.3);
}

.sb-bb-tiers-header {
	display: flex;
	justify-content: space-between;
	align-items: center;
	margin-bottom: 18px;
	flex-wrap: wrap;
	gap: 12px;
}

.sb-bb-tiers-title h3 {
	margin: 0;
	font-size: 20px;
	font-weight: 800;
	color: #ffffff;
	letter-spacing: -0.02em;
}

.sb-bb-tiers-title p {
	margin: 4px 0 0;
	font-size: 13px;
	color: #c7d2fe;
}

.sb-bb-prompt-box {
	background: rgba(255, 255, 255, 0.12);
	border: 1px solid rgba(255, 255, 255, 0.2);
	border-radius: 9999px;
	padding: 6px 16px;
	font-size: 13px;
	font-weight: 600;
	color: #e0e7ff;
	display: inline-flex;
	align-items: center;
	gap: 6px;
}

/* Milestones Track */
.sb-bb-track-wrapper {
	position: relative;
	margin: 16px 0 8px;
}

.sb-bb-milestones {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
	gap: 10px;
	position: relative;
	z-index: 2;
}

.sb-bb-milestone {
	background: rgba(255, 255, 255, 0.08);
	border: 1px solid rgba(255, 255, 255, 0.15);
	border-radius: 10px;
	padding: 10px 12px;
	text-align: center;
	transition: all 0.2s ease;
	position: relative;
}

.sb-bb-milestone.is-reached {
	background: #10b981;
	border-color: #34d399;
	box-shadow: 0 4px 14px rgba(16, 185, 129, 0.4);
}

.sb-bb-milestone.is-next {
	background: rgba(255, 255, 255, 0.2);
	border-color: #818cf8;
	transform: translateY(-2px);
}

.sb-bb-m-tag {
	position: absolute;
	top: -9px;
	left: 50%;
	transform: translateX(-50%);
	background: #f59e0b;
	color: #000000;
	font-size: 9px;
	font-weight: 800;
	text-transform: uppercase;
	padding: 1px 6px;
	border-radius: 9999px;
	letter-spacing: 0.05em;
	white-space: nowrap;
}

.sb-bb-m-tag.best {
	background: #ec4899;
	color: #ffffff;
}

.sb-bb-m-qty {
	display: block;
	font-size: 12px;
	font-weight: 700;
	color: #c7d2fe;
}

.sb-bb-milestone.is-reached .sb-bb-m-qty {
	color: #ffffff;
}

.sb-bb-m-price {
	display: block;
	font-size: 16px;
	font-weight: 800;
	color: #ffffff;
	margin-top: 2px;
}

.sb-bb-m-each {
	display: block;
	font-size: 10px;
	color: #a5b4fc;
	margin-top: 2px;
}

.sb-bb-milestone.is-reached .sb-bb-m-each {
	color: #d1fae5;
}


/* ==========================================================================
   2. Navigation & Instant Filter Bar
   ========================================================================== */

.sb-bb-toolbar {
	background: #ffffff;
	border: 1px solid #e2e8f0;
	border-radius: 14px;
	padding: 18px 20px;
	margin-bottom: 24px;
	box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
	display: flex;
	flex-direction: column;
	gap: 16px;
}

/* Row 1: Curation Quick Pills */
.sb-bb-curation-pills {
	display: flex;
	gap: 8px;
	flex-wrap: wrap;
	align-items: center;
	padding-bottom: 12px;
	border-bottom: 1px dashed #e2e8f0;
}

.sb-bb-curate-pill {
	background: #f8fafc;
	border: 1.5px solid #e2e8f0;
	border-radius: 8px;
	padding: 6px 14px;
	font-size: 12.5px;
	font-weight: 700;
	color: #475569;
	cursor: pointer;
	transition: all 0.15s ease;
	display: inline-flex;
	align-items: center;
	gap: 6px;
}

.sb-bb-curate-pill:hover {
	background: #f1f5f9;
	border-color: #cbd5e1;
	color: #0f172a;
}

.sb-bb-curate-pill.is-active {
	background: #1e1b4b;
	border-color: #1e1b4b;
	color: #ffffff;
	box-shadow: 0 2px 8px rgba(30, 27, 75, 0.3);
}

.sb-bb-curate-pill--selected {
	margin-left: auto;
	background: #ecfdf5;
	border-color: #a7f3d0;
	color: #065f46;
}

.sb-bb-curate-pill--selected.is-active {
	background: #10b981;
	border-color: #059669;
	color: #ffffff;
	box-shadow: 0 2px 8px rgba(16, 185, 129, 0.35);
}

/* Category Filter Chips */
.sb-bb-chips {
	display: flex;
	gap: 8px;
	flex-wrap: wrap;
	align-items: center;
}

.sb-bb-chip {
	background: #f1f5f9;
	border: 1px solid #e2e8f0;
	border-radius: 9999px;
	padding: 6px 14px;
	font-size: 12.5px;
	font-weight: 600;
	color: #334155;
	cursor: pointer;
	transition: all 0.15s ease;
	display: inline-flex;
	align-items: center;
	gap: 6px;
}

.sb-bb-chip:hover {
	background: #e2e8f0;
	color: #0f172a;
}

.sb-bb-chip.is-active {
	background: #4f46e5;
	border-color: #4f46e5;
	color: #ffffff;
	box-shadow: 0 2px 6px rgba(79, 70, 229, 0.25);
}

.sb-bb-chip-count {
	font-size: 11px;
	opacity: 0.85;
	background: rgba(0, 0, 0, 0.08);
	padding: 1px 7px;
	border-radius: 9999px;
}

.sb-bb-chip.is-active .sb-bb-chip-count {
	background: rgba(255, 255, 255, 0.25);
}

/* Row 3: Controls Row (Search, Sort, Per-Page) */
.sb-bb-controls-row {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 14px;
	flex-wrap: wrap;
	padding-top: 4px;
}

.sb-bb-search-box {
	position: relative;
	flex: 1;
	min-width: 240px;
	max-width: 440px;
}

.sb-bb-search-box input {
	width: 100%;
	padding: 10px 34px 10px 38px;
	border: 1.5px solid #cbd5e1;
	border-radius: 10px;
	font-size: 13.5px;
	outline: none;
	transition: border-color 0.15s, box-shadow 0.15s;
}

.sb-bb-search-box input:focus {
	border-color: #4f46e5;
	box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.15);
}

.sb-bb-search-icon {
	position: absolute;
	left: 12px;
	top: 50%;
	transform: translateY(-50%);
	color: #94a3b8;
	font-size: 18px;
	pointer-events: none;
}

.sb-bb-search-clear {
	position: absolute;
	right: 10px;
	top: 50%;
	transform: translateY(-50%);
	background: none;
	border: none;
	color: #94a3b8;
	font-size: 14px;
	cursor: pointer;
	padding: 4px;
	display: none;
	line-height: 1;
}

.sb-bb-search-clear:hover {
	color: #ef4444;
}

.sb-bb-select-group {
	display: flex;
	align-items: center;
	gap: 12px;
	flex-wrap: wrap;
}

.sb-bb-select-wrap {
	display: flex;
	align-items: center;
	gap: 6px;
	font-size: 12.5px;
	color: #64748b;
	font-weight: 700;
}

.sb-bb-select {
	padding: 8px 30px 8px 12px;
	border: 1.5px solid #cbd5e1;
	border-radius: 8px;
	font-size: 13px;
	font-weight: 700;
	color: #1e293b;
	background: #ffffff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='%2364748b' viewBox='0 0 16 16'%3E%3Cpath d='M7.247 11.14 2.451 5.658C1.885 5.013 2.345 4 3.204 4h9.592a1 1 0 0 1 .753 1.659l-4.796 5.48a1 1 0 0 1-1.506 0z'/%3E%3C/svg%3E") no-repeat calc(100% - 10px) center;
	appearance: none;
	-webkit-appearance: none;
	cursor: pointer;
	outline: none;
	transition: border-color 0.15s;
}

.sb-bb-select:focus {
	border-color: #4f46e5;
}

/* Results Header Bar */
.sb-bb-results-bar {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 0 4px 14px;
	font-size: 13px;
	color: #475569;
	flex-wrap: wrap;
	gap: 8px;
}

.sb-bb-results-count strong {
	color: #0f172a;
}

.sb-bb-status-counter {
	display: flex;
	align-items: center;
	gap: 12px;
	font-size: 13px;
	color: #475569;
}

.sb-bb-btn-clear {
	background: none;
	border: none;
	color: #ef4444;
	font-size: 12px;
	font-weight: 700;
	cursor: pointer;
	text-decoration: underline;
	padding: 0;
}


/* ==========================================================================
   3. Main Builder Layout: 4:3 Grid + Sticky Dock
   ========================================================================== */

.sb-bb-layout {
	display: grid;
	grid-template-columns: 1fr 340px;
	gap: 28px;
	align-items: start;
}

@media (max-width: 992px) {
	.sb-bb-layout {
		grid-template-columns: 1fr;
	}
}

/* Cards Grid */
.sb-bb-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
	gap: 18px;
}

@media (max-width: 480px) {
	.sb-bb-grid {
		grid-template-columns: repeat(2, 1fr);
		gap: 12px;
	}
}

/* Individual Product Card */
.sb-card-pick {
	background: #ffffff;
	border: 2px solid #e2e8f0;
	border-radius: 12px;
	overflow: hidden;
	display: flex;
	flex-direction: column;
	transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
	cursor: pointer;
	position: relative;
	box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.sb-card-pick:hover {
	transform: translateY(-3px);
	border-color: #cbd5e1;
	box-shadow: 0 8px 18px rgba(0, 0, 0, 0.08);
}

.sb-card-pick.is-selected {
	border-color: #4f46e5;
	background: #fdfdfe;
	box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.2), 0 8px 20px rgba(79, 70, 229, 0.12);
}

/* 4:3 Cover Media Wrap */
.sb-card-pick__media {
	position: relative;
	width: 100%;
	aspect-ratio: 4 / 3;
	background: #f1f5f9;
	overflow: hidden;
}

.sb-card-pick__media img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
	transition: transform 0.3s ease;
}

.sb-card-pick:hover .sb-card-pick__media img {
	transform: scale(1.04);
}

.sb-card-pick__check-badge {
	position: absolute;
	top: 8px;
	right: 8px;
	width: 26px;
	height: 26px;
	border-radius: 50%;
	background: rgba(15, 23, 42, 0.5);
	border: 2px solid #ffffff;
	color: transparent;
	display: flex;
	align-items: center;
	justify-content: center;
	transition: all 0.15s ease;
	backdrop-filter: blur(2px);
}

.sb-card-pick.is-selected .sb-card-pick__check-badge {
	background: #10b981;
	border-color: #ffffff;
	color: #ffffff;
	box-shadow: 0 2px 6px rgba(16, 185, 129, 0.4);
}

.sb-card-pick__check-badge .dashicons {
	font-size: 16px;
	width: 16px;
	height: 16px;
}

.sb-card-pick__spec-pill {
	position: absolute;
	bottom: 8px;
	left: 8px;
	background: rgba(15, 23, 42, 0.75);
	backdrop-filter: blur(4px);
	color: #ffffff;
	font-size: 10px;
	font-weight: 700;
	padding: 2px 6px;
	border-radius: 4px;
	text-transform: uppercase;
	z-index: 2;
}

.sb-card-pick__quickview-trigger {
	position: absolute;
	top: 50%;
	left: 50%;
	transform: translate(-50%, -50%) scale(0.9);
	background: rgba(15, 23, 42, 0.88);
	backdrop-filter: blur(4px);
	border: 1px solid rgba(255, 255, 255, 0.25);
	color: #ffffff;
	border-radius: 9999px;
	padding: 7px 14px;
	font-size: 11.5px;
	font-weight: 700;
	cursor: pointer;
	display: inline-flex;
	align-items: center;
	gap: 6px;
	opacity: 0;
	pointer-events: none;
	transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
	box-shadow: 0 4px 14px rgba(0, 0, 0, 0.3);
	z-index: 4;
}

.sb-card-pick:hover .sb-card-pick__quickview-trigger {
	opacity: 1;
	pointer-events: auto;
	transform: translate(-50%, -50%) scale(1);
}

.sb-card-pick__quickview-trigger:hover {
	background: #4f46e5;
	border-color: #6366f1;
	transform: translate(-50%, -50%) scale(1.05);
}

/* Card Body */
.sb-card-pick__body {
	padding: 12px 14px;
	display: flex;
	flex-direction: column;
	flex: 1;
}

.sb-card-pick__cat {
	font-size: 11px;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.04em;
	color: #6366f1;
	margin-bottom: 4px;
}

.sb-card-pick__title {
	font-size: 13.5px;
	font-weight: 700;
	color: #0f172a;
	line-height: 1.35;
	margin: 0 0 8px;
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
	height: 36px;
	cursor: pointer;
	transition: color 0.15s ease;
}

.sb-card-pick__title:hover {
	color: #4f46e5;
}

.sb-card-pick__footer {
	margin-top: auto;
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding-top: 8px;
	border-top: 1px solid #f1f5f9;
	gap: 6px;
}

.sb-card-pick__price {
	font-size: 14px;
	font-weight: 800;
	color: #0f172a;
	white-space: nowrap;
}

.sb-card-pick__actions {
	display: flex;
	align-items: center;
	gap: 6px;
}

.sb-card-pick__view-btn {
	background: #f8fafc;
	border: 1.5px solid #cbd5e1;
	border-radius: 6px;
	width: 28px;
	height: 28px;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	color: #64748b;
	cursor: pointer;
	transition: all 0.15s ease;
	padding: 0;
	flex-shrink: 0;
}

.sb-card-pick__view-btn .dashicons {
	font-size: 15px;
	width: 15px;
	height: 15px;
}

.sb-card-pick__view-btn:hover {
	background: #4f46e5;
	border-color: #4f46e5;
	color: #ffffff;
}

.sb-card-pick__btn {
	background: #f8fafc;
	border: 1.5px solid #cbd5e1;
	border-radius: 6px;
	padding: 5px 10px;
	font-size: 11.5px;
	font-weight: 700;
	color: #334155;
	cursor: pointer;
	display: inline-flex;
	align-items: center;
	gap: 4px;
	transition: all 0.15s ease;
	white-space: nowrap;
}

.sb-card-pick:hover .sb-card-pick__btn {
	border-color: #94a3b8;
	background: #f1f5f9;
}

.sb-card-pick.is-selected .sb-card-pick__btn {
	background: #10b981;
	border-color: #059669;
	color: #ffffff;
}

.sb-card-pick__btn .dashicons {
	font-size: 14px;
	width: 14px;
	height: 14px;
}

/* Card badges & rating */
.sb-card-pick__curation-badge {
	position: absolute;
	top: 8px;
	left: 8px;
	background: linear-gradient(135deg, #f59e0b, #d97706);
	color: #ffffff;
	font-size: 9.5px;
	font-weight: 800;
	padding: 2.5px 8px;
	border-radius: 4px;
	text-transform: uppercase;
	letter-spacing: 0.04em;
	box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
	z-index: 2;
}

.sb-card-pick__meta-row {
	display: flex;
	align-items: center;
	justify-content: space-between;
	margin-bottom: 4px;
	gap: 8px;
}

.sb-card-pick__rating {
	font-size: 11.5px;
	font-weight: 800;
	color: #d97706;
	display: inline-flex;
	align-items: center;
	gap: 2px;
}

/* ==========================================================================
   3.1 Pagination & Empty Search State
   ========================================================================== */

.sb-bb-pagination-wrap {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 12px;
	margin-top: 28px;
	padding-top: 24px;
	border-top: 1px solid #e2e8f0;
}

.sb-bb-pagination {
	display: flex;
	align-items: center;
	gap: 6px;
	flex-wrap: wrap;
	justify-content: center;
}

.sb-bb-page-btn {
	background: #ffffff;
	border: 1.5px solid #cbd5e1;
	border-radius: 8px;
	min-width: 38px;
	height: 38px;
	padding: 0 10px;
	font-size: 13px;
	font-weight: 700;
	color: #334155;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	cursor: pointer;
	transition: all 0.15s ease;
}

.sb-bb-page-btn:hover:not(:disabled):not(.is-active) {
	background: #f1f5f9;
	border-color: #94a3b8;
	color: #0f172a;
}

.sb-bb-page-btn.is-active {
	background: #4f46e5;
	border-color: #4f46e5;
	color: #ffffff;
	box-shadow: 0 2px 8px rgba(79, 70, 229, 0.3);
	cursor: default;
}

.sb-bb-page-btn:disabled {
	opacity: 0.4;
	cursor: not-allowed;
	border-color: #e2e8f0;
}

.sb-bb-page-ellipsis {
	padding: 0 6px;
	color: #94a3b8;
	font-weight: 700;
	font-size: 14px;
}

/* Empty Search State */
.sb-bb-empty-search {
	text-align: center;
	padding: 48px 24px;
	background: #ffffff;
	border: 2px dashed #cbd5e1;
	border-radius: 16px;
	color: #64748b;
	margin: 20px 0;
}

.sb-bb-empty-search-icon {
	font-size: 40px;
	margin-bottom: 12px;
	line-height: 1;
}

.sb-bb-empty-search h4 {
	font-size: 18px;
	font-weight: 800;
	color: #1e293b;
	margin: 0 0 6px;
}

.sb-bb-empty-search p {
	font-size: 13.5px;
	margin: 0 0 16px;
	color: #64748b;
}

.sb-bb-empty-reset-btn {
	background: #4f46e5;
	border: none;
	border-radius: 8px;
	padding: 9px 20px;
	font-size: 13px;
	font-weight: 700;
	color: #ffffff;
	cursor: pointer;
	transition: background 0.15s;
}

.sb-bb-empty-reset-btn:hover {
	background: #4338ca;
}


/* ==========================================================================
   4. Live Sticky Summary Dock
   ========================================================================== */

.sb-bb-dock {
	background: #ffffff;
	border: 1px solid #e2e8f0;
	border-radius: 16px;
	box-shadow: 0 4px 16px rgba(0, 0, 0, 0.06);
	padding: 22px;
	position: sticky;
	top: 80px;
	display: flex;
	flex-direction: column;
	gap: 16px;
}

.sb-bb-dock-header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding-bottom: 12px;
	border-bottom: 1px solid #f1f5f9;
}

.sb-bb-dock-heading {
	font-size: 17px;
	font-weight: 800;
	color: #0f172a;
	margin: 0;
}

.sb-bb-dock-badge {
	background: #e0e7ff;
	color: #3730a3;
	font-size: 11px;
	font-weight: 800;
	padding: 2px 8px;
	border-radius: 9999px;
}

/* Selected Items Drawer */
.sb-bb-dock-items {
	max-height: 280px;
	overflow-y: auto;
	display: flex;
	flex-direction: column;
	gap: 8px;
	padding-right: 4px;
}

.sb-bb-dock-empty {
	text-align: center;
	padding: 24px 12px;
	color: #64748b;
	font-size: 13px;
	background: #f8fafc;
	border-radius: 10px;
	border: 1px dashed #cbd5e1;
}

.sb-bb-dock-item {
	display: flex;
	align-items: center;
	gap: 10px;
	background: #f8fafc;
	border: 1px solid #e2e8f0;
	border-radius: 8px;
	padding: 6px 10px;
	font-size: 12.5px;
}

.sb-bb-dock-item-thumb {
	width: 32px;
	aspect-ratio: 4 / 3;
	border-radius: 4px;
	overflow: hidden;
	flex-shrink: 0;
	background: #e2e8f0;
}

.sb-bb-dock-item-thumb img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

.sb-bb-dock-item-title {
	flex: 1;
	font-weight: 600;
	color: #1e293b;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

.sb-bb-dock-item-del {
	background: none;
	border: none;
	color: #94a3b8;
	font-size: 16px;
	line-height: 1;
	cursor: pointer;
	padding: 2px;
	transition: color 0.15s;
}

.sb-bb-dock-item-del:hover {
	color: #ef4444;
}

/* Dock Pricing Breakdown */
.sb-bb-dock-totals {
	background: #f8fafc;
	border: 1px solid #e2e8f0;
	border-radius: 12px;
	padding: 14px;
	display: flex;
	flex-direction: column;
	gap: 8px;
}

.sb-bb-total-row {
	display: flex;
	justify-content: space-between;
	align-items: baseline;
	font-size: 13px;
	color: #64748b;
}

.sb-bb-total-row--final {
	font-size: 15px;
	font-weight: 700;
	color: #0f172a;
	padding-top: 6px;
	border-top: 1px solid #e2e8f0;
}

.sb-bb-total-price {
	font-size: 24px;
	font-weight: 900;
	color: #4f46e5;
}

.sb-bb-savings-pill {
	display: inline-flex;
	align-items: center;
	background: #ecfdf5;
	border: 1px solid #a7f3d0;
	color: #065f46;
	font-weight: 800;
	font-size: 11px;
	padding: 2px 8px;
	border-radius: 9999px;
}

/* CTA Checkout Button */
.sb-bb-submit-btn {
	background: #4f46e5 !important;
	border-color: #4338ca !important;
	color: #ffffff !important;
	font-size: 15px !important;
	font-weight: 800 !important;
	padding: 14px 20px !important;
	border-radius: 10px !important;
	display: flex !important;
	align-items: center !important;
	justify-content: center !important;
	gap: 8px !important;
	box-shadow: 0 4px 14px rgba(79, 70, 229, 0.35) !important;
	transition: all 0.2s ease !important;
	cursor: pointer;
}

.sb-bb-submit-btn:hover:not(:disabled) {
	background: #4338ca !important;
	transform: translateY(-1px);
	box-shadow: 0 6px 20px rgba(79, 70, 229, 0.45) !important;
}

.sb-bb-submit-btn:disabled {
	opacity: 0.55 !important;
	cursor: not-allowed !important;
	box-shadow: none !important;
}

.sb-bb-guarantee-note {
	font-size: 11.5px;
	color: #64748b;
	text-align: center;
	margin: 0;
	line-height: 1.4;
}


/* ==========================================================================
   5. Mobile Sticky Bottom Dock
   ========================================================================== */

/* Desktop defaults for mobile dock elements */
.sb-bb-dock-mobile-bar {
	display: none !important;
}

.sb-bb-dock-collapse-btn {
	display: none !important;
}

.sb-bb-dock-backdrop {
	display: none !important;
}

@media (max-width: 992px) {
	/* Extra bottom padding on the main grid so content isn't covered by the 62px bottom bar */
	.sb-bb-layout {
		padding-bottom: 90px;
	}

	/* The Dock container on Mobile */
	.sb-bb-dock {
		position: fixed;
		bottom: 0;
		left: 0;
		right: 0;
		top: auto;
		width: 100%;
		z-index: 99998;
		background: #ffffff;
		border-radius: 16px 16px 0 0;
		box-shadow: 0 -4px 25px rgba(15, 23, 42, 0.18);
		border-top: 1px solid #e2e8f0;
		border-left: none;
		border-right: none;
		border-bottom: none;
		padding: 0;
		transform: translateY(105%);
		transition: transform 0.28s cubic-bezier(0.16, 1, 0.3, 1);
	}

	/* When items are selected, show the compact bar */
	.sb-bb-dock.has-items {
		transform: translateY(0);
	}

	/* Compact Mobile Bar (height ~62px) */
	.sb-bb-dock-mobile-bar {
		display: flex !important;
		align-items: center;
		justify-content: space-between;
		padding: 10px 16px;
		background: #ffffff;
		border-radius: 16px 16px 0 0;
		cursor: pointer;
		min-height: 62px;
		gap: 12px;
	}

	.sb-bb-dmb-info {
		display: flex;
		flex-direction: column;
		gap: 2px;
		flex: 1;
		min-width: 0;
	}

	.sb-bb-dmb-top {
		display: flex;
		align-items: baseline;
		gap: 8px;
		flex-wrap: wrap;
	}

	.sb-bb-dmb-count {
		font-size: 13px;
		font-weight: 700;
		color: #475569;
	}

	.sb-bb-dmb-price {
		font-size: 18px;
		font-weight: 900;
		color: #1e1b4b;
	}

	.sb-bb-dmb-savings {
		font-size: 11px;
		font-weight: 700;
		color: #065f46;
		background: #ecfdf5;
		border: 1px solid #a7f3d0;
		padding: 1px 6px;
		border-radius: 9999px;
	}

	.sb-bb-dmb-toggle-btn {
		background: none;
		border: none;
		padding: 0;
		color: #4f46e5;
		font-size: 11.5px;
		font-weight: 700;
		display: inline-flex;
		align-items: center;
		gap: 4px;
		cursor: pointer;
		text-align: left;
	}

	.sb-bb-dmb-chevron {
		font-size: 14px;
		width: 14px;
		height: 14px;
		transition: transform 0.2s ease;
	}

	/* Direct Checkout Button on the mobile bar */
	.sb-bb-dmb-checkout-btn {
		background: #4f46e5;
		border: none;
		color: #ffffff;
		font-size: 13.5px;
		font-weight: 800;
		padding: 10px 16px;
		border-radius: 10px;
		cursor: pointer;
		white-space: nowrap;
		box-shadow: 0 4px 12px rgba(79, 70, 229, 0.35);
		transition: all 0.15s ease;
		display: inline-flex;
		align-items: center;
		justify-content: center;
	}

	.sb-bb-dmb-checkout-btn:hover {
		background: #4338ca;
	}

	.sb-bb-dmb-checkout-btn:disabled {
		opacity: 0.5;
		pointer-events: none;
	}

	/* The Expandable Drawer */
	.sb-bb-dock-drawer {
		max-height: 0;
		overflow: hidden;
		transition: max-height 0.3s cubic-bezier(0.16, 1, 0.3, 1), padding 0.3s ease;
		padding: 0 16px;
	}

	.sb-bb-dock.is-expanded .sb-bb-dock-drawer {
		max-height: 72vh;
		overflow-y: auto;
		padding: 6px 16px 20px;
		border-top: 1px solid #f1f5f9;
	}

	.sb-bb-dock-header {
		display: flex;
		align-items: center;
		justify-content: space-between;
		padding-bottom: 10px;
		margin-bottom: 10px;
		border-bottom: 1px solid #f1f5f9;
	}

	.sb-bb-dock-header-right {
		display: flex;
		align-items: center;
		gap: 10px;
	}

	.sb-bb-dock-collapse-btn {
		display: inline-flex !important;
		align-items: center;
		justify-content: center;
		width: 26px;
		height: 26px;
		border-radius: 50%;
		border: 1px solid #cbd5e1;
		background: #f8fafc;
		color: #64748b;
		font-size: 13px;
		cursor: pointer;
	}

	.sb-bb-dock-items {
		max-height: 180px;
		overflow-y: auto;
		margin-bottom: 12px;
	}

	.sb-bb-dock-totals {
		padding: 10px 12px;
		margin-bottom: 12px;
	}

	.sb-bb-guarantee-note {
		font-size: 11px;
		margin-top: 8px;
	}

	/* Dark backdrop when expanded */
	.sb-bb-dock-backdrop {
		display: block;
		position: fixed;
		top: 0;
		left: 0;
		right: 0;
		bottom: 0;
		background: rgba(15, 23, 42, 0.55);
		backdrop-filter: blur(2px);
		z-index: 99995;
	}
}

/* ==========================================================================
   Quick View Modal
   ========================================================================== */
.sb-bb-modal-overlay {
	position: fixed;
	top: 0;
	left: 0;
	right: 0;
	bottom: 0;
	z-index: 999999;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 20px;
	animation: sbFadeIn 0.2s ease-out;
}

.sb-bb-modal-backdrop {
	position: absolute;
	top: 0;
	left: 0;
	right: 0;
	bottom: 0;
	background: rgba(15, 23, 42, 0.72);
	backdrop-filter: blur(5px);
}

.sb-bb-modal-dialog {
	position: relative;
	background: #ffffff;
	border-radius: 16px;
	max-width: 860px;
	width: 100%;
	max-height: 90vh;
	overflow-y: auto;
	box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.4);
	padding: 28px;
	z-index: 2;
	animation: sbModalScale 0.22s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes sbFadeIn {
	from { opacity: 0; }
	to { opacity: 1; }
}

@keyframes sbModalScale {
	from { opacity: 0; transform: scale(0.95); }
	to { opacity: 1; transform: scale(1); }
}

.sb-bb-modal-close {
	position: absolute;
	top: 14px;
	right: 14px;
	width: 32px;
	height: 32px;
	border-radius: 50%;
	border: 1px solid #e2e8f0;
	background: #f8fafc;
	color: #64748b;
	font-size: 16px;
	display: flex;
	align-items: center;
	justify-content: center;
	cursor: pointer;
	transition: all 0.15s ease;
	z-index: 5;
}

.sb-bb-modal-close:hover {
	background: #ef4444;
	border-color: #ef4444;
	color: #ffffff;
}

.sb-bb-modal-loading {
	text-align: center;
	padding: 60px 20px;
	color: #64748b;
}

.sb-bb-modal-loading .dashicons {
	font-size: 32px;
	width: 32px;
	height: 32px;
	color: #4f46e5;
	margin-bottom: 12px;
}

/* Modal Content Grid */
.sb-bb-modal-grid {
	display: grid;
	grid-template-columns: 320px 1fr;
	gap: 28px;
}

@media (max-width: 768px) {
	.sb-bb-modal-dialog {
		padding: 20px 16px;
	}
	.sb-bb-modal-grid {
		grid-template-columns: 1fr;
		gap: 20px;
	}
}

/* Modal Gallery (Left Column) */
.sb-bb-modal-gallery {
	display: flex;
	flex-direction: column;
	gap: 12px;
}

.sb-bb-modal-main-img-wrap {
	width: 100%;
	aspect-ratio: 4 / 3;
	border-radius: 10px;
	overflow: hidden;
	background: #f1f5f9;
	border: 1px solid #e2e8f0;
}

.sb-bb-modal-main-img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
	transition: opacity 0.15s ease;
}

.sb-bb-modal-thumbs {
	display: flex;
	gap: 8px;
	overflow-x: auto;
	padding-bottom: 4px;
}

.sb-bb-modal-thumb-btn {
	width: 60px;
	height: 45px;
	border-radius: 6px;
	border: 2px solid transparent;
	padding: 0;
	background: #f1f5f9;
	cursor: pointer;
	overflow: hidden;
	flex-shrink: 0;
	transition: all 0.15s ease;
}

.sb-bb-modal-thumb-btn img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

.sb-bb-modal-thumb-btn:hover {
	border-color: #cbd5e1;
}

.sb-bb-modal-thumb-btn.is-active {
	border-color: #4f46e5;
	box-shadow: 0 0 0 2px rgba(79, 70, 229, 0.25);
}

/* Modal Details (Right Column) */
.sb-bb-modal-details {
	display: flex;
	flex-direction: column;
}

.sb-bb-modal-meta-top {
	display: flex;
	align-items: center;
	justify-content: space-between;
	margin-bottom: 6px;
}

.sb-bb-modal-cat {
	font-size: 11.5px;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.05em;
	color: #4f46e5;
}

.sb-bb-modal-rating {
	font-size: 13px;
	font-weight: 700;
	color: #f59e0b;
}

.sb-bb-modal-title {
	font-size: 20px;
	font-weight: 800;
	color: #0f172a;
	line-height: 1.3;
	margin: 0 0 6px;
}

.sb-bb-modal-subtitle {
	font-size: 13.5px;
	color: #64748b;
	line-height: 1.45;
	margin: 0 0 14px;
}

.sb-bb-modal-price-row {
	display: flex;
	align-items: baseline;
	gap: 10px;
	padding-bottom: 14px;
	margin-bottom: 14px;
	border-bottom: 1px solid #f1f5f9;
}

.sb-bb-modal-price {
	font-size: 22px;
	font-weight: 800;
	color: #0f172a;
}

.sb-bb-modal-bundle-hint {
	font-size: 12px;
	font-weight: 600;
	color: #059669;
	background: #ecfdf5;
	padding: 3px 8px;
	border-radius: 9999px;
}

/* Specs Badges */
.sb-bb-modal-specs {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	margin-bottom: 16px;
}

.sb-bb-modal-spec-chip {
	font-size: 11.5px;
	font-weight: 600;
	color: #475569;
	background: #f8fafc;
	border: 1px solid #e2e8f0;
	padding: 4px 10px;
	border-radius: 6px;
	display: inline-flex;
	align-items: center;
	gap: 4px;
}

/* Deliverables Checklist */
.sb-bb-modal-included {
	margin-bottom: 18px;
	background: #f8fafc;
	border-radius: 8px;
	padding: 12px 14px;
	border: 1px dashed #cbd5e1;
}

.sb-bb-modal-included-title {
	font-size: 12px;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.04em;
	color: #475569;
	margin: 0 0 8px;
}

.sb-bb-modal-checklist {
	list-style: none;
	padding: 0;
	margin: 0;
	display: flex;
	flex-direction: column;
	gap: 5px;
}

.sb-bb-modal-checklist li {
	font-size: 12.5px;
	color: #334155;
	display: flex;
	align-items: flex-start;
	gap: 6px;
	line-height: 1.35;
}

.sb-bb-modal-checklist li .dashicons {
	color: #10b981;
	font-size: 16px;
	width: 16px;
	height: 16px;
	flex-shrink: 0;
	margin-top: 1px;
}

/* Actions in Modal */
.sb-bb-modal-actions {
	display: flex;
	flex-direction: column;
	gap: 10px;
	margin-top: auto;
	padding-top: 14px;
	border-top: 1px solid #f1f5f9;
}

.sb-bb-modal-btn-row {
	display: flex;
	gap: 10px;
	flex-wrap: wrap;
}

.sb-bb-modal-add-btn {
	flex: 1;
	min-width: 180px;
	background: #4f46e5;
	border: 2px solid #4f46e5;
	color: #ffffff;
	font-size: 13.5px;
	font-weight: 700;
	padding: 10px 18px;
	border-radius: 8px;
	cursor: pointer;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 6px;
	transition: all 0.15s ease;
	box-shadow: 0 4px 10px rgba(79, 70, 229, 0.25);
}

.sb-bb-modal-add-btn:hover {
	background: #4338ca;
	border-color: #4338ca;
}

.sb-bb-modal-add-btn.is-selected {
	background: #10b981;
	border-color: #059669;
	box-shadow: 0 4px 10px rgba(16, 185, 129, 0.3);
}

.sb-bb-modal-sample-btn {
	background: #ffffff;
	border: 1.5px solid #2563eb;
	color: #2563eb;
	font-size: 13px;
	font-weight: 700;
	padding: 10px 16px;
	border-radius: 8px;
	text-decoration: none;
	display: inline-flex;
	align-items: center;
	gap: 6px;
	transition: all 0.15s ease;
}

.sb-bb-modal-sample-btn:hover {
	background: #eff6ff;
	color: #1d4ed8;
	text-decoration: none;
}

.sb-bb-modal-ext-link {
	font-size: 12.5px;
	font-weight: 600;
	color: #64748b;
	text-decoration: none;
	display: inline-flex;
	align-items: center;
	gap: 4px;
	margin-top: 4px;
	align-self: flex-start;
	transition: color 0.15s ease;
}

.sb-bb-modal-ext-link:hover {
	color: #4f46e5;
	text-decoration: underline;
}

body.sb-modal-open {
	overflow: hidden;
}

