.bss-wrap {
	margin: 1.5em 0;
}

.bss-button {
	display: inline-flex;
	align-items: center;
	gap: .5em;
	padding: .75em 1.25em;
	border: 0;
	border-radius: 999px;
	background: linear-gradient(45deg, #f58529, #dd2a7b 50%, #8134af);
	color: #fff;
	font: inherit;
	font-weight: 600;
	line-height: 1.2;
	cursor: pointer;
	transition: transform .15s ease, box-shadow .15s ease;
}

.bss-button:hover {
	transform: translateY(-1px);
	box-shadow: 0 6px 18px rgba(221, 42, 123, .35);
}

.bss-button:focus-visible,
.bss-btn:focus-visible,
.bss-close:focus-visible {
	outline: 3px solid #4f8cff;
	outline-offset: 2px;
}

.bss-no-scroll {
	overflow: hidden;
}

.bss-overlay {
	position: fixed;
	inset: 0;
	z-index: 2147483000;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 16px;
	background: rgba(0, 0, 0, .7);
}

.bss-dialog {
	box-sizing: border-box;
	width: 100%;
	max-width: 420px;
	max-height: calc(100vh - 32px);
	max-height: calc(100dvh - 32px);
	overflow-y: auto;
	padding: 20px;
	border-radius: 16px;
	background: #fff;
	color: #111;
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
	box-shadow: 0 20px 60px rgba(0, 0, 0, .4);
}

.bss-header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	margin-bottom: 12px;
}

.bss-overlay .bss-dialog .bss-title {
	margin: 0;
	color: inherit;
	font-family: inherit;
	letter-spacing: normal;
	text-transform: none;
	font-size: 1.15rem;
	line-height: 1.3;
}

.bss-close {
	width: 40px;
	height: 40px;
	border: 0;
	border-radius: 50%;
	background: #f1f1f1;
	color: #111;
	font-size: 26px;
	line-height: 1;
	cursor: pointer;
}

.bss-preview {
	display: flex;
	align-items: center;
	justify-content: center;
	aspect-ratio: 9 / 16;
	max-height: 55vh;
	margin: 0 auto;
	border-radius: 12px;
	background: #f3f4f6;
	overflow: hidden;
}

.bss-image {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: contain;
}

.bss-loading {
	margin: 0;
	color: #555;
}

.bss-howto {
	margin: 14px 0;
	font-size: .9rem;
	line-height: 1.45;
	color: #444;
}

.bss-actions {
	display: grid;
	gap: 8px;
}

.bss-btn {
	padding: .8em 1em;
	border: 1px solid #d1d5db;
	border-radius: 10px;
	background: #fff;
	color: #111;
	font: inherit;
	font-weight: 600;
	cursor: pointer;
}

.bss-btn[disabled] {
	opacity: .5;
	cursor: not-allowed;
}

.bss-btn[hidden] {
	display: none;
}

.bss-btn-primary {
	border-color: transparent;
	background: linear-gradient(45deg, #f58529, #dd2a7b 50%, #8134af);
	color: #fff;
}

.bss-live {
	min-height: 1.2em;
	margin: 10px 0 0;
	font-size: .9rem;
	text-align: center;
	color: #0a7a3d;
	word-break: break-all;
}

@media (prefers-color-scheme: dark) {
	.bss-dialog { background: #1f2023; color: #f3f3f3; }
	.bss-close { background: #2d2f33; color: #f3f3f3; }
	.bss-preview { background: #2a2b2f; }
	.bss-howto, .bss-loading { color: #c8c8c8; }
	.bss-btn { background: #2a2b2f; color: #f3f3f3; border-color: #3d3f44; }
	.bss-live { color: #5fd38d; }
}

@media (prefers-reduced-motion: reduce) {
	.bss-button { transition: none; }
}
