/*
 * Bundle card. Layout only: fonts, colours and buttons come from the theme
 * (WooCommerce classes), so the card looks like the rest of the shop.
 */

.nfb-bundle {
	margin: 1.5em 0;
	padding: 1.25em;
	border: 1px solid rgba(0, 0, 0, 0.12);
	border-radius: 6px;
}

.nfb-bundle__title {
	margin: 0 0 0.75em;
	font-size: 1.15em;
}

.nfb-bundle__items {
	margin: 0 0 1em;
	padding: 0;
	list-style: none;
}

.nfb-bundle__item {
	margin: 0;
	padding: 0.4em 0;
	border-bottom: 1px solid rgba(0, 0, 0, 0.06);
}

.nfb-bundle__label {
	display: grid;
	grid-template-columns: auto auto 1fr auto auto;
	gap: 0.75em;
	align-items: center;
	margin: 0;
	cursor: default;
}

.nfb-bundle--frequently-bought-together .nfb-bundle__label {
	cursor: pointer;
}

.nfb-bundle__thumb img {
	display: block;
	width: 48px;
	height: 48px;
	object-fit: cover;
}

.nfb-bundle__name small {
	display: block;
	opacity: 0.7;
}

.nfb-bundle__qty {
	white-space: nowrap;
	opacity: 0.8;
}

.nfb-bundle__line {
	white-space: nowrap;
	text-align: right;
}

.nfb-bundle__item.is-unavailable {
	opacity: 0.55;
}

.nfb-bundle__totals {
	display: grid;
	grid-template-columns: 1fr auto;
	gap: 0.25em 1em;
	margin: 0 0 1em;
}

.nfb-bundle__totals dt,
.nfb-bundle__totals dd {
	margin: 0;
}

.nfb-bundle__totals dd {
	text-align: right;
}

.nfb-bundle__buy {
	display: flex;
	flex-wrap: wrap;
	gap: 0.75em;
	align-items: center;
}

.nfb-bundle__buy .quantity {
	margin: 0;
}

.nfb-bundle__hint {
	margin: 0.5em 0 0;
	font-size: 0.9em;
}

.nfb-offers__title {
	margin-top: 1em;
}

.nfb-embed-note {
	padding: 0.75em 1em;
	border-left: 4px solid #dba617;
	background: #fcf9e8;
}

@media (max-width: 480px) {
	.nfb-bundle__label {
		grid-template-columns: auto auto 1fr auto;
	}

	.nfb-bundle__qty {
		display: none;
	}
}

/* Radio choice on a product page: just this product, or a bundle. */
.nfb-choice { margin: 0 0 1.25em; border: 1px solid rgba(0, 0, 0, .12); border-radius: 6px; }
.nfb-choice__title { margin: 0; padding: .75em 1em; font-weight: 600; border-bottom: 1px solid rgba(0, 0, 0, .08); }
.nfb-choice__option { border-bottom: 1px solid rgba(0, 0, 0, .08); }
.nfb-choice__option:last-child { border-bottom: 0; }
.nfb-choice__option > label { display: flex; align-items: center; gap: .6em; padding: .75em 1em; cursor: pointer; margin: 0; }
.nfb-choice__name { flex: 1; }
.nfb-choice__price { white-space: nowrap; }
.nfb-choice__option.is-open { background: rgba(0, 0, 0, .025); }
.nfb-choice__panel { padding: 0 1em 1em; }
.nfb-choice__panel .nfb-bundle { margin: 0; border: 0; padding: 0; box-shadow: none; }
/* With JavaScript: only the chosen bundle's card, and the page's one button. */
.nfb-choice--js .nfb-choice__option:not(.is-open) .nfb-choice__panel { display: none; }
.nfb-choice--js .nfb-choice__panel .nfb-bundle__buy { display: none; }
/* A variable product's own options do not apply to a bundle. */
form.cart.nfb-choice-bundle .variations,
form.cart.nfb-choice-bundle .single_variation_wrap .woocommerce-variation { display: none; }
form.cart.nfb-choice-bundle .single_add_to_cart_button.disabled { opacity: 1; cursor: pointer; }

/* Icons, in the style chosen in Settings › Design. */
.nfb-icon { display: inline-flex; align-items: center; justify-content: center; vertical-align: -0.15em; margin-right: .35em; line-height: 1; }
.nfb-icon svg { display: block; }
.nfb-icon--solid { padding: .2em; border-radius: 50%; background: currentColor; }
.nfb-icon--solid svg { stroke: #fff; width: .8em; height: .8em; }
.nfb-icon--dashicons { width: 1em; height: 1em; font-size: 1em; }
.nfb-bundle__savings .nfb-icon { opacity: .8; }
/* One bundle on the page starts open: its products and images in view. */
.nfb-choice__option.is-open > label { font-weight: 600; }

/* A bundle's own page: a column in the theme's content area. */
.nfb-landing { box-sizing: border-box; width: 100%; max-width: 720px; margin: 0 auto; padding: 2.5em 0; }
.nfb-landing--wide { max-width: 1200px; }
.nfb-landing__title { margin: 0 0 .75em; }
.nfb-landing__banner { display: block; margin: 0 0 1.5em; }
.nfb-landing__banner img { display: block; width: 100%; height: auto; border-radius: 6px; }
.nfb-landing__text { margin: 0 0 1.5em; }
.nfb-landing .nfb-bundle { margin-top: 0; }
/* Some block themes leave WooCommerce's quantity box unstyled here. */
.nfb-landing .nfb-bundle__buy .qty { min-width: 3.5em; min-height: 2.5em; text-align: center; }
@media (max-width: 600px) {
	.nfb-landing { padding: 1.5em 0; }
}
/*
 * A bundle's look (set per bundle; old bundles stay a list with a dropdown).
 * Products as boxes: side by side, photo on top, name and price below.
 */
.nfb-bundle--grid .nfb-bundle__items { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 12px; }
.nfb-bundle--grid .nfb-bundle__item { position: relative; display: flex; flex-direction: column; margin: 0; padding: 10px; background: #fff; border: 1px solid #e5e7eb; border-radius: 10px; transition: border-color .15s ease, box-shadow .15s ease; }
.nfb-bundle--grid .nfb-bundle__item:hover { border-color: #d1d5db; box-shadow: 0 2px 10px rgba(17, 24, 39, .06); }
.nfb-bundle--grid .nfb-bundle__label { display: flex; flex-direction: column; align-items: center; gap: 4px; text-align: center; }
.nfb-bundle--grid .nfb-bundle__label > input[type="checkbox"] { position: absolute; top: 16px; left: 16px; z-index: 1; margin: 0; }
.nfb-bundle--grid .nfb-bundle__thumb { display: flex; justify-content: center; width: 100%; margin-bottom: 6px; }
/* The whole photo on a light tile (never cropped), no theme shadow; the box keeps its size. */
.nfb-bundle--grid .nfb-bundle__thumb img { display: block; width: 100%; max-width: 160px; height: auto; aspect-ratio: 1 / 1; margin: 0 auto; padding: 0; object-fit: contain; background: #f6f6f7; border: 0; border-radius: 8px; box-shadow: none; }
.nfb-bundle--grid .nfb-bundle__name { font-size: .95em; font-weight: 500; line-height: 1.3; }
.nfb-bundle--grid .nfb-bundle__name small { margin-top: 2px; font-size: .8em; font-weight: 400; }
.nfb-bundle--grid .nfb-bundle__qty { font-size: .85em; }
.nfb-bundle--grid .nfb-bundle__item[data-qty="1"] .nfb-bundle__qty { display: none; }
.nfb-bundle--grid .nfb-bundle__line { font-size: .95em; font-weight: 600; text-align: center; }
/*
 * A product's option list (size, colour): one compact size on every theme,
 * clear of the photo above it. Themes style selects large (48px, 18px text).
 */
.nfb-bundle select.nfb-bundle__choice { display: block; box-sizing: border-box; width: 100%; max-width: 100%; height: 36px; min-height: 0; margin: 8px 0 4px; padding: 0 30px 0 10px; font-family: inherit; font-size: 14px; line-height: 34px; color: #111827; background-color: #fff; border: 1px solid #d1d5db; border-radius: 6px; box-shadow: none; text-overflow: ellipsis; white-space: nowrap; overflow: hidden; }
.nfb-bundle select.nfb-bundle__choice:focus { border-color: #111827; outline: none; box-shadow: 0 0 0 1px #111827; }
.nfb-bundle--grid select.nfb-bundle__choice { height: 34px; font-size: 13px; line-height: 32px; }
.nfb-bundle--grid .nfb-bundle__boxes { margin-top: 8px; }
.nfb-bundle--grid .nfb-bundle__opt { justify-content: center; }
.nfb-bundle--grid .nfb-bundle__savings { color: #15803d; font-weight: 600; }
/* The chosen bundle's panel stays white around its boxes. */
.nfb-choice__option.is-open:has(.nfb-bundle--grid) { background: #fff; }
/* Sizes and colours as boxes; the option list stays in the card, hidden, for the cart. */
.nfb-bundle .nfb-bundle__choice--boxed { position: absolute !important; width: 1px !important; height: 1px !important; margin: -1px !important; padding: 0 !important; overflow: hidden !important; clip: rect(0, 0, 0, 0) !important; border: 0 !important; }
.nfb-bundle__boxes { display: flex; flex-direction: column; gap: 6px; margin-top: .5em; }
.nfb-bundle__opt { display: flex; flex-wrap: wrap; gap: 6px; }
.nfb-bundle .nfb-bundle__pill { display: inline-flex; align-items: center; justify-content: center; width: auto; min-width: 40px; max-width: 100%; height: 34px; min-height: 0; margin: 0; padding: 0 10px; font: inherit; font-size: .85em; font-weight: 500; line-height: 1; color: #111827; background: #fff; border: 1px solid #d1d5db; border-radius: 6px; box-shadow: none; text-transform: none; letter-spacing: normal; text-decoration: none; cursor: pointer; transition: border-color .15s ease, background-color .15s ease, color .15s ease; }
.nfb-bundle .nfb-bundle__pill:hover { background: #fff; color: #111827; border-color: #111827; }
.nfb-bundle .nfb-bundle__pill[aria-checked="true"],
.nfb-bundle .nfb-bundle__pill[aria-checked="true"]:hover { background: #111827; border-color: #111827; color: #fff; }
.nfb-bundle .nfb-bundle__pill--na { border-style: dashed; color: #6b7280; }
.nfb-bundle .nfb-bundle__pill[disabled],
.nfb-bundle .nfb-bundle__pill[disabled]:hover { background: #f9fafb; border-color: #e5e7eb; color: #9ca3af; text-decoration: line-through; cursor: not-allowed; }
.nfb-bundle .nfb-bundle__pill:focus-visible { outline: 2px solid #111827; outline-offset: 2px; }
/*
 * Product quick view: a product's photo in a bundle card
 * opens a window with its pictures and description. Any card style.
 * Buttons are reset one class stronger than common theme button rules.
 */
.nfb-bundle .nfb-bundle__qv { display: block; width: auto; min-width: 0; height: auto; min-height: 0; margin: 0; padding: 0; border: 0; border-radius: 6px; background: none; box-shadow: none; line-height: 0; cursor: zoom-in; }
.nfb-bundle .nfb-bundle__qv:focus-visible { outline: 2px solid currentColor; outline-offset: 2px; }
.nfb-qv-open { overflow: hidden; }
.nfb-qv { position: fixed; inset: 0; z-index: 2147483000; display: flex; align-items: center; justify-content: center; padding: 16px; background: rgba(0, 0, 0, .55); }
.nfb-qv[hidden] { display: none; }
.nfb-qv, .nfb-qv * { box-sizing: border-box; }
.nfb-qv__box { position: relative; width: 100%; max-width: 520px; max-height: min(90vh, 760px); overflow: auto; background: #fff; color: #111; border-radius: 14px; box-shadow: 0 20px 60px rgba(0, 0, 0, .3); text-align: left; }
.nfb-qv .nfb-qv__close,
.nfb-qv .nfb-qv__nav { position: absolute; z-index: 2; display: flex; align-items: center; justify-content: center; width: 40px; height: 40px; min-width: 0; min-height: 0; margin: 0; padding: 0; border: 0; border-radius: 50%; background: rgba(255, 255, 255, .92); color: #111; font-size: 26px; line-height: 1; cursor: pointer; box-shadow: 0 1px 4px rgba(0, 0, 0, .2); text-transform: none; }
.nfb-qv .nfb-qv__close { top: 8px; right: 8px; }
.nfb-qv .nfb-qv__nav { top: 50%; transform: translateY(-50%); font-size: 28px; }
.nfb-qv .nfb-qv__nav--prev { left: 8px; }
.nfb-qv .nfb-qv__nav--next { right: 8px; }
.nfb-qv--single .nfb-qv__nav { display: none !important; }
.nfb-qv__media { position: relative; background: #f6f6f6; }
.nfb-qv__media[hidden] { display: none; }
.nfb-qv .nfb-qv__img { display: block; width: 100%; max-width: none; height: auto; aspect-ratio: 1 / 1; margin: 0; object-fit: contain; }
.nfb-qv__count { position: absolute; bottom: 8px; right: 10px; padding: 2px 8px; font-size: .8em; background: rgba(0, 0, 0, .55); color: #fff; border-radius: 999px; }
.nfb-qv__count:empty { display: none; }
.nfb-qv__body { padding: 16px 20px 20px; }
.nfb-qv .nfb-qv__title { margin: 0 0 8px; font-size: 1.15em; line-height: 1.3; color: inherit; }
.nfb-qv__variant { margin: -4px 0 8px; font-size: .9em; opacity: .7; }
.nfb-qv__variant:empty,
.nfb-qv__desc:empty { display: none; }
.nfb-qv__desc { margin: 0; font-size: .95em; line-height: 1.55; opacity: .85; }
.nfb-qv .nfb-qv__close:focus-visible,
.nfb-qv .nfb-qv__nav:focus-visible { outline: 2px solid #111; outline-offset: 2px; }
@media (max-width: 640px) {
	.nfb-qv { align-items: flex-end; padding: 0; }
	.nfb-qv__box { max-width: none; max-height: 92vh; border-radius: 16px 16px 0 0; }
}

/* Read by screen readers and search engines, not shown. */
.nfb-sr { position: absolute !important; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
