/* Bakery Branch Selection – frontend */

.bbs-modal-open { overflow: hidden; }

.bbs-modal[hidden] { display: none !important; }

.bbs-modal {
	position: fixed;
	inset: 0;
	z-index: 999999;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 16px;
}

.bbs-modal__overlay {
	position: absolute;
	inset: 0;
	background: rgba(0, 0, 0, .55);
}

.bbs-modal__dialog {
	position: relative;
	width: 100%;
	max-width: 560px;
	max-height: calc(100vh - 32px);
	overflow-y: auto;
	background: #fff;
	color: #222;
	border-radius: 12px;
	padding: 28px 24px 20px;
	box-shadow: 0 20px 60px rgba(0, 0, 0, .3);
}

.bbs-modal.is-loading .bbs-modal__dialog { opacity: .7; pointer-events: none; }

.bbs-modal__close {
	position: absolute;
	top: 8px;
	right: 10px;
	background: none;
	border: 0;
	font-size: 28px;
	line-height: 1;
	cursor: pointer;
	color: #666;
	padding: 4px 8px;
}

.bbs-modal__title { margin: 0 0 6px; font-size: 1.4em; }
.bbs-modal__text { margin: 0 0 16px; color: #555; }

.bbs-modal__error {
	margin: 0 0 12px;
	padding: 8px 12px;
	background: #fdecea;
	color: #b32d2e;
	border-radius: 6px;
}

.bbs-branch-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.bbs-branch-list li { margin: 0; }

.bbs-branch {
	display: flex;
	gap: 12px;
	align-items: flex-start;
	width: 100%;
	text-align: left;
	background: #fff;
	color: inherit;
	border: 2px solid #e5e5e5;
	border-radius: 10px;
	padding: 12px 14px;
	cursor: pointer;
	font: inherit;
	transition: border-color .15s, background-color .15s;
}

.bbs-branch:hover,
.bbs-branch:focus-visible { border-color: #c58b4e; background: #fdf8f3; outline: none; }
.bbs-branch.is-selected { border-color: #a0612b; background: #fbf1e6; }

.bbs-branch__img { width: 56px; height: 56px; object-fit: cover; border-radius: 8px; flex-shrink: 0; }
.bbs-branch__body { display: flex; flex-direction: column; gap: 2px; }
.bbs-branch__name { font-size: 1.05em; }
.bbs-branch__line { font-size: .9em; color: #555; }

.bbs-branch__map { display: inline-block; margin: 4px 0 0 4px; font-size: .85em; }

/* "Ordering from" bar */
.bbs-bar {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 6px 10px;
	margin: 0 0 20px;
	padding: 10px 14px;
	background: #fbf1e6;
	border: 1px solid #ecd6bf;
	border-radius: 8px;
	font-size: .95em;
}

.bbs-current-address { color: #666; font-size: .9em; }
.bbs-current-address:empty { display: none; }

.bbs-bar__change {
	margin-left: auto;
	background: none;
	border: 1px solid #a0612b;
	color: #a0612b;
	border-radius: 6px;
	padding: 4px 12px;
	cursor: pointer;
	font: inherit;
	font-size: .9em;
}

.bbs-bar__change:hover { background: #a0612b; color: #fff; }

.woocommerce-bbs-branch { margin-top: 2em; }
