.kbo-form, .kbo-price, .kbo-bar {
	--kbo-accent: #f4581f;
	--kbo-soft: #fdeee7;
	--kbo-line: #e4e4e0;
}
.kbo-form {
	clear: both;
	width: 100%;
	margin: 0 0 20px;
}
.kbo-form [hidden] { display: none !important; }
.kbo-card {
	background: #f6f6f2;
	border: 1px solid var(--kbo-line);
	border-radius: 10px;
	padding: 14px;
	margin-bottom: 12px;
}
.kbo-head { display: flex; justify-content: space-between; align-items: center; gap: 10px; margin-bottom: 12px; }
.kbo-title { font-weight: 600; color: #111; }
.kbo-current, .kbo-selected-badge, .kbo-total-badge {
	display: inline-block;
	background: #fff;
	border: 1px solid var(--kbo-line);
	border-radius: 6px;
	padding: 2px 10px;
	font-size: 12px;
	font-weight: 600;
}
.kbo-total-badge { background: var(--kbo-accent); border-color: var(--kbo-accent); color: #fff; }

.kbo-form button.kbo-option,
.kbo-form button.kbo-tier,
.kbo-form .kbo-stepper button {
	margin: 0;
	min-width: 0;
	min-height: 0;
	height: auto;
	box-shadow: none;
	text-transform: none;
	letter-spacing: 0;
	line-height: 1.3;
	color: #222;
	cursor: pointer;
}

.kbo-colors { display: grid; grid-template-columns: repeat(auto-fill, minmax(62px, 1fr)); gap: 8px; }
.kbo-form .kbo-colors button.kbo-option {
	position: relative;
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 4px;
	background: transparent;
	border: 0;
	padding: 0;
	font-size: 11px;
	font-weight: 400;
}
.kbo-thumb {
	position: relative;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 56px;
	height: 56px;
	background: #fff;
	border: 2px solid var(--kbo-line);
	border-radius: 10px;
}
.kbo-thumb img { width: 100%; height: 100%; object-fit: cover; border-radius: 8px; }
.kbo-colors .is-selected .kbo-thumb { border-color: var(--kbo-accent); }
.kbo-colors .is-selected .kbo-name { font-weight: 700; }
.kbo-colors .is-selected .kbo-thumb::after {
	content: "\2713";
	position: absolute;
	top: -5px;
	inset-inline-end: 0;
	width: 18px;
	height: 18px;
	border-radius: 50%;
	background: var(--kbo-accent);
	color: #fff;
	font-size: 11px;
	line-height: 18px;
	text-align: center;
}

.kbo-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.kbo-form .kbo-chips button.kbo-option {
	position: relative;
	background: #fff;
	border: 2px solid var(--kbo-line);
	border-radius: 8px;
	padding: 6px 14px;
}
.kbo-form .kbo-chips button.kbo-option.is-selected { border-color: var(--kbo-accent); }

.kbo-quantity-row { display: flex; flex-wrap: wrap; align-items: center; gap: 14px; }
.kbo-target { display: flex; align-items: stretch; height: 48px; background: #fff; border: 1px solid var(--kbo-line); border-radius: 10px; overflow: hidden; }
.kbo-form .kbo-target button { width: 46px; height: auto; margin: 0; padding: 0; min-width: 0; background: #e9e9e4; border: 0; border-radius: 0; box-shadow: none; color: #111; font-size: 20px; cursor: pointer; }
.kbo-form .kbo-target button:disabled { opacity: .35; cursor: default; }
.kbo-form .kbo-target input.kbo-target-input { width: 62px; height: auto; margin: 0; padding: 0; border: 0; background: #fff; text-align: center; font-size: 18px; font-weight: 700; -moz-appearance: textfield; appearance: textfield; }
.kbo-unit { font-size: 22px; font-weight: 700; color: #111; }
.kbo-unit-label { font-size: 13px; color: #666; }
.kbo-total { font-weight: 600; color: #111; }
.kbo-form.is-loading .kbo-card, .kbo-form.is-loading .kbo-upload, .kbo-form.is-loading .kbo-add-box { opacity: .6; pointer-events: none; }
.kbo-notice { margin-bottom: 12px; padding: 10px 12px; background: #fff6e5; border: 1px solid #f1dcae; border-radius: 8px; color: #6b4a00; font-size: 13px; }
.kbo-voice-saved { display: flex; justify-content: space-between; align-items: center; gap: 10px; margin-top: 10px; padding: 8px 12px; background: #ecf7ef; border-radius: 8px; font-size: 13px; }
.kbo-chart-row { display: flex; justify-content: flex-end; margin-bottom: 6px; }
.kbo-box-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 10px; padding-bottom: 8px; border-bottom: 1px solid var(--kbo-line); font-weight: 700; color: var(--kbo-accent); }
.kbo-form button.kbo-box-remove { height: auto; min-height: 0; margin: 0; padding: 2px 8px; background: transparent; border: 0; box-shadow: none; color: #b00020; text-transform: none; text-decoration: underline; }
.kbo-selector { margin-bottom: 14px; }
.kbo-sizes-title { margin-bottom: 8px; }
.kbo-form button.kbo-option:disabled { opacity: .3; cursor: not-allowed; }
.kbo-form button.kbo-add-box { display: block; width: 100%; height: auto; margin: 0 0 12px; padding: 11px; background: #fff; border: 2px dashed var(--kbo-accent); border-radius: 10px; box-shadow: none; color: var(--kbo-accent); font-weight: 700; text-transform: none; cursor: pointer; }
.kbo-form button.kbo-add-box:disabled { opacity: .4; cursor: default; }
.kbo-allocation { margin-bottom: 12px; }
.kbo-allocation .kbo-progress { margin-top: 8px; }
.kbo-subtitle { margin: 12px 0 8px; font-size: 11px; font-weight: 700; text-transform: uppercase; color: #777; }
.kbo-tiers { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 8px; }
.kbo-tier-range { font-weight: 600; }
.kbo-tier strong { font-size: 16px; line-height: 1.4; color: #111; }
.kbo-tier-note { display: block; margin-top: 8px; font-size: 12px; color: #777; }
.kbo-form button.kbo-tier {
	display: flex;
	flex-direction: column;
	align-items: center;
	background: #fff;
	border: 2px solid var(--kbo-line);
	border-radius: 8px;
	padding: 7px 4px;
	font-size: 12px;
}
.kbo-form button.kbo-tier.is-active { border-color: var(--kbo-accent); background: var(--kbo-soft); }
.kbo-tier small { color: #23834a; font-weight: 600; }
.kbo-tier small.is-base { color: #999; }
.kbo-nudge {
	display: flex;
	justify-content: space-between;
	align-items: center;
	gap: 10px;
	margin-top: 12px;
	padding: 10px 12px;
	background: #ecf7ef;
	border: 1px solid #cfe8d6;
	border-radius: 8px;
	color: #1d5c37;
	font-size: 13px;
}
.kbo-form button.kbo-nudge-button { flex-shrink: 0; margin: 0; background: #2e8b57; border: 0; border-radius: 8px; color: #fff; }

.kbo-upload { margin-bottom: 12px; }
.kbo-form label.kbo-drop { position: relative; display: block; margin: 0; padding: 12px; background: var(--kbo-upload-bg, #fff); border: 1px solid var(--kbo-line); border-radius: 10px; text-align: center; cursor: pointer; }
.kbo-drop strong { display: block; color: var(--kbo-upload-text, #14224a); font-size: 15px; }
.kbo-drop small { display: block; color: var(--kbo-upload-text, #777); }
.kbo-drop:hover, .kbo-drop.is-over, .kbo-drop:focus-within { border-color: var(--kbo-accent) !important; }
.kbo-drop.is-over { background: var(--kbo-soft) !important; }
/* The highlight is light, so a light custom text colour would not be readable on it. */
.kbo-drop.is-over strong { color: #14224a; }
.kbo-drop.is-over small { color: #777; }
.kbo-drop:focus-within { outline: 2px solid var(--kbo-accent); outline-offset: 1px; }
.kbo-form .kbo-drop input[type="file"] { position: absolute; width: 1px; height: 1px; opacity: 0; overflow: hidden; }
.kbo-file { display: flex; justify-content: space-between; align-items: center; gap: 10px; margin-top: 6px; padding: 8px 12px; background: #ecf7ef; border-radius: 8px; font-size: 13px; }
.kbo-file-name { overflow-wrap: anywhere; }
.kbo-form button.kbo-file-remove, .kbo-form button.kbo-voice-delete { flex-shrink: 0; height: auto; min-height: 0; margin: 0; padding: 2px 8px; background: transparent; border: 0; box-shadow: none; color: #b00020; text-transform: none; text-decoration: underline; }

.kbo-form .kbo-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(110px, 1fr)); gap: 10px; margin: 0; }
.kbo-cell { background: #fff; border: 1px solid var(--kbo-line); border-radius: 10px; padding: 10px 6px; text-align: center; }
.kbo-cell.is-selected { border-color: var(--kbo-accent); background: var(--kbo-soft); }
.kbo-cell.is-unavailable { opacity: .5; }
.kbo-cell-image { display: block; width: 48px; height: 48px; margin: 0 auto 6px; border-radius: 8px; object-fit: cover; }
.kbo-cell-label { margin-bottom: 8px; }
.kbo-cell-label span { color: #777; }
.kbo-stepper { display: flex; align-items: center; justify-content: center; gap: 2px; }
.kbo-form .kbo-stepper button { width: 30px; height: 30px; padding: 0; background: #eeeeea; border: 0; border-radius: 7px; font-size: 18px; }
.kbo-form .kbo-stepper button:disabled { opacity: .35; cursor: default; }
.kbo-form .kbo-stepper input.kbo-qty {
	width: 38px;
	height: 30px;
	padding: 0;
	border: 0;
	background: transparent;
	text-align: center;
	font-weight: 600;
	-moz-appearance: textfield;
	appearance: textfield;
}
.kbo-qty::-webkit-inner-spin-button, .kbo-qty::-webkit-outer-spin-button { -webkit-appearance: none; margin: 0; }
.kbo-stock { display: block; min-height: 16px; font-size: 11px; color: #a15c00; }
.kbo-size-chart { font-size: 13px; font-weight: 600; text-decoration: underline; }

.kbo-selected-badge.is-complete { background: #e3f4e8; border-color: #bfe3ca; color: #1d6b3a; }
.kbo-progress { height: 5px; margin-top: 12px; background: #e6e6e1; border-radius: 3px; overflow: hidden; }
.kbo-progress span { display: block; width: 0; height: 100%; background: var(--kbo-accent); transition: width .2s, background-color .2s; }
.kbo-progress.is-complete span { background: #2e8b57; }
.kbo-progress-text { margin-top: 6px; font-size: 13px; font-weight: 600; color: var(--kbo-accent); }
.kbo-progress-text.is-complete { color: #23834a; }
.kbo-warning { margin-bottom: 12px; padding: 10px 12px; background: var(--kbo-soft); border: 1px solid var(--kbo-accent); border-radius: 8px; color: #a8360c; font-size: 13px; font-weight: 600; }
.kbo-optional { display: inline-block; margin-inline-start: 6px; padding: 0 8px; background: #e9e9e4; border-radius: 10px; font-size: 11px; color: #666; }
.kbo-form textarea.kbo-note { width: 100%; min-height: 0; margin: 8px 0 0; padding: 8px 10px; background: #fff; border: 1px solid var(--kbo-line); border-radius: 8px; resize: vertical; }
.kbo-voice-row { display: flex; align-items: center; gap: 12px; }
.kbo-voice-row small { display: block; color: #777; }
.kbo-form button.kbo-record { flex-shrink: 0; display: flex; align-items: center; justify-content: center; width: 44px; height: 44px; min-width: 0; margin: 0; padding: 0; background: var(--kbo-accent); border: 0; border-radius: 50%; box-shadow: none; cursor: pointer; }
.kbo-record span { width: 14px; height: 14px; border-radius: 50%; background: #fff; }
.kbo-form button.kbo-record.is-recording { background: #b00020; animation: kbo-pulse 1.2s infinite; }
.kbo-record.is-recording span { border-radius: 2px; }
@keyframes kbo-pulse { 50% { box-shadow: 0 0 0 7px rgba(176, 0, 32, .18); } }
.kbo-voice-result { display: flex; align-items: center; gap: 8px; margin-top: 10px; }
.kbo-voice-result audio { flex: 1; min-width: 0; height: 36px; }
.kbo-form ul.kbo-info { margin: 0 0 12px; padding: 12px 14px; list-style: none; background: #fff6e5; border: 1px solid #f1dcae; border-radius: 10px; color: #6b4a00; font-size: 13px; }
.kbo-info li { position: relative; margin: 0; padding-inline-start: 20px; }
.kbo-info li + li { margin-top: 6px; }
.kbo-info li::before { content: "\2713"; position: absolute; inset-inline-start: 0; font-weight: 700; }

.kbo-error { margin-bottom: 12px; padding: 12px 14px; background: #fdecee; border: 2px solid #c8102e; border-radius: 8px; color: #a00d25; font-weight: 700; }
.kbo-upload .kbo-error { margin: 8px 0 0; }
.kbo-message { margin-bottom: 8px; font-size: 13px; }
.kbo-message.is-error { color: #b00020; }
.kbo-message.is-success { color: #23834a; }
/* !important beats the theme's colour options for product page buttons. */
.kbo-form button.kbo-add { width: 100%; background: #111 !important; border-color: #111 !important; color: #fff !important; border-radius: 8px; }
.kbo-form button.kbo-add:hover:not(:disabled) { background: var(--kbo-accent) !important; border-color: var(--kbo-accent) !important; }
.kbo-form button.kbo-add:disabled { opacity: .6; cursor: progress; }

.kbo-price { display: flex; flex-wrap: wrap; align-items: center; column-gap: 12px; margin-bottom: 14px; }
.kbo-price [hidden] { display: none !important; }
.kbo-price-now { font-size: 30px; font-weight: 700; color: #111; }
.kbo-price-was { font-size: 18px; color: #888; }
.kbo-price-save { padding: 3px 9px; background: var(--kbo-accent); border-radius: 4px; color: #fff; font-size: 12px; font-weight: 700; text-transform: uppercase; }
.kbo-price-tax { flex-basis: 100%; color: #777; }

@media (max-width: 575px) {
	.kbo-tiers { grid-template-columns: repeat(3, minmax(0, 1fr)); }
	.kbo-nudge { flex-direction: column; align-items: stretch; text-align: center; }
}
@media (max-width: 991px) {
	/* The theme pins this button to the bottom of the screen; the summary bar is there instead. */
	.single-product.has-mobile-bottom-navbar-single-page div.product .kbo-form button.single_add_to_cart_button.kbo-add {
		position: static !important;
		width: 100%;
		margin: 0;
		border-radius: 8px;
		box-shadow: none;
	}
}

/* Summary bar. */
.kbo-bar { position: fixed; left: 0; right: 0; bottom: var(--kbo-bar-offset, 0px); z-index: 99; background: #fff; border-top: 1px solid var(--kbo-line); box-shadow: 0 -2px 10px rgba(0, 0, 0, .08); }
.kbo-bar[hidden], .kbo-bar [hidden] { display: none !important; }
.kbo-bar-message { padding: 5px 15px; background: #f6f6f2; border-bottom: 1px solid var(--kbo-line); color: #333; font-size: 13px; text-align: center; }
.kbo-bar-message.is-error { background: #fdecee; color: #a00d25; font-weight: 600; }
.kbo-bar-message.is-success { background: #ecf7ef; color: #1c6b3b; font-weight: 600; }
.kbo-bar-inner { display: flex; align-items: center; gap: 28px; max-width: 1200px; margin: 0 auto; padding: 10px 15px; padding-bottom: calc(10px + env(safe-area-inset-bottom, 0px)); }
.kbo-bar-product { display: flex; flex: 1; align-items: center; gap: 12px; min-width: 0; }
.kbo-bar-product img { width: 52px; height: 52px; object-fit: cover; border-radius: 6px; }
.kbo-bar-title { overflow: hidden; color: #111; font-size: 15px; font-weight: 600; text-overflow: ellipsis; white-space: nowrap; }
.kbo-bar-stats { display: flex; gap: 28px; }
.kbo-bar-stats > div { display: flex; flex-direction: column; line-height: 1.25; white-space: nowrap; }
.kbo-bar-label { color: #777; font-size: 11px; font-weight: 600; text-transform: uppercase; }
.kbo-bar-stats strong { color: #111; font-size: 18px; }
.kbo-bar-selected strong { color: var(--kbo-accent); }
.kbo-bar-selected.is-complete strong { color: #23834a; }
.kbo-bar-stats small { color: #666; font-size: 12px; }
/* !important beats the theme's button colours, as for the button in the form. */
.kbo-bar button.kbo-bar-button { flex-shrink: 0; min-width: 190px; height: 46px; margin: 0; padding: 0 22px; background: #111 !important; border: 0; border-radius: 8px; box-shadow: none; color: #fff !important; font-weight: 700; cursor: pointer; }
.kbo-bar button.kbo-bar-button:hover:not(:disabled) { background: var(--kbo-accent) !important; }
.kbo-bar button.kbo-bar-button:disabled { opacity: .6; cursor: progress; }
body.kbo-has-bar { padding-bottom: var(--kbo-bar-space, 90px) !important; }
/* The room the theme leaves for its own bar. */
body.kbo-has-bar.has-sticky-add-to-cart .site-footer { padding-bottom: 0; }
body.kbo-has-bar .kapee-back-to-top { bottom: calc(var(--kbo-bar-space, 90px) + 12px) !important; }
@media (max-width: 991px) {
	.kbo-bar-inner { gap: 18px; }
	.kbo-bar-stats { gap: 18px; }
	.kbo-bar-title { display: none; }
}
@media (max-width: 767px) {
	.kbo-bar-inner { flex-direction: column; align-items: stretch; gap: 6px; padding: 8px 12px; padding-bottom: calc(8px + env(safe-area-inset-bottom, 0px)); }
	.kbo-bar-product { display: none; }
	.kbo-bar-stats { justify-content: space-between; gap: 10px; }
	.kbo-bar-stats strong { font-size: 16px; }
	.kbo-bar-amount { text-align: end; }
	.kbo-bar button.kbo-bar-button { width: 100%; height: 42px; }
}

/* Warning popup shown when the total cannot be lowered. */
.kbo-form dialog.kbo-popup { box-sizing: border-box; width: calc(100% - 32px); max-width: 420px; max-height: calc(100% - 32px); margin: auto; padding: 0; overflow: auto; background: #fff; border: 0; border-top: 8px solid #ffb300; border-radius: 12px; box-shadow: 0 12px 40px rgba(0, 0, 0, .35); color: #333; text-align: center; }
.kbo-popup::backdrop { background: rgba(0, 0, 0, .65); }
.kbo-popup[open] { animation: kbo-warn .45s ease-out; }
@keyframes kbo-warn { 0% { transform: scale(.9); } 40% { transform: translateX(-8px); } 60% { transform: translateX(7px); } 80% { transform: translateX(-3px); } 100% { transform: none; } }
@media (prefers-reduced-motion: reduce) {
	.kbo-popup[open] { animation: none; }
}
.kbo-popup-body { padding: 20px; }
.kbo-popup-icon { display: block; margin: 0 auto 10px; }
.kbo-popup-title { margin-bottom: 12px; color: #a00d25; font-size: 20px; font-weight: 700; line-height: 1.3; }
.kbo-popup-message { margin-bottom: 18px; padding: 12px 14px; background: #fff4d6; border: 1px solid #ffcf5c; border-radius: 8px; color: #4a3000; font-weight: 600; white-space: pre-line; } /* Keeps the line breaks of a custom message. */
.kbo-popup-buttons { display: flex; flex-wrap: wrap; gap: 10px; }
/* !important beats the theme's button colours. */
.kbo-form .kbo-popup-buttons button { flex: 1 1 150px; height: auto; min-height: 46px; margin: 0; padding: 10px 14px; border: 2px solid transparent; border-radius: 8px; box-shadow: none; font-weight: 700; line-height: 1.3; text-transform: none; cursor: pointer; }
.kbo-form .kbo-popup-buttons button.kbo-popup-keep { background: #fff !important; border-color: #555 !important; color: #222 !important; }
.kbo-form .kbo-popup-buttons button.kbo-popup-keep:hover { background: #f2f2f2 !important; }
.kbo-form .kbo-popup-buttons button.kbo-popup-clear { background: #c8102e !important; border-color: #c8102e !important; color: #fff !important; }
.kbo-form .kbo-popup-buttons button.kbo-popup-clear:hover { background: #9d0c24 !important; border-color: #9d0c24 !important; }
.kbo-form .kbo-popup-buttons button:focus-visible { outline: 3px solid #ffb300; outline-offset: 2px; }
