/* B2B header — menu používá stejné třídy jako secondary (styly z style.css) */

body.dg-b2b-page #breadcrumbs {
	display: none !important;
}

/* Můj účet v B2B layoutu — bez boční navigace WC */
body.dg-b2b-page.woocommerce-account .woocommerce-MyAccount-navigation {
	display: none;
}

body.dg-b2b-page.woocommerce-account .woocommerce-MyAccount-content {
	width: 100%;
	float: none;
	max-width: 40rem;
}

.site-header--b2b .header-top--b2b {
	padding-bottom: 0;
}

.site-header--b2b .header-bottom--b2b {
	display: flex;
	justify-content: flex-end;
	width: 100%;
	padding-top: 0;
}

.site-header--b2b .header-bottom--b2b .header-navigation-wrapper {
	justify-content: flex-end;
	width: 100%;
}

.site-header--b2b .b2b-menu.secondary-menu {
	display: flex;
	align-items: center;
	flex-wrap: wrap;
	justify-content: flex-end;
	gap: 0 1.25rem;
	margin: 0;
	padding: 0;
	list-style: none;
}

.site-header--b2b .b2b-menu > li {
	position: relative;
	margin: 0;
	white-space: nowrap;
}

/* Language / currency — collapsible dropdown (stejné chování jako secondary v B2C) */
.site-header--b2b .dg-language-switcher,
.site-header--b2b .dgc-currency-switcher,
.site-header--b2b .menu-item-language-wrapper {
	position: relative;
	display: inline-block;
}

.site-header--b2b .dg-language-switcher__list.sub-menu,
.site-header--b2b .dgc-currency-switcher__list.sub-menu {
	display: flex;
	flex-direction: column;
	position: absolute;
	left: 50%;
	top: 100%;
	transform: translateX(-50%);
	z-index: 40;
	margin: 0;
	padding: 12px;
	min-width: 100%;
	width: max-content;
	box-sizing: border-box;
	background-color: #fff;
	border: 2px solid #f5f5f5;
	border-radius: 8px;
	box-shadow: 0 24px 48px rgba(49, 49, 49, 0.25);
	opacity: 0;
	visibility: hidden;
	pointer-events: none;
}

.site-header--b2b .b2b-menu > li:hover > .dg-language-switcher__list.sub-menu,
.site-header--b2b .b2b-menu > li:hover > .dgc-currency-switcher .dgc-currency-switcher__list.sub-menu,
.site-header--b2b .b2b-menu > li:hover .dg-language-switcher__list.sub-menu,
.site-header--b2b .b2b-menu > li:hover .dgc-currency-switcher__list.sub-menu,
.site-header--b2b .b2b-menu > li:focus-within .dg-language-switcher__list.sub-menu,
.site-header--b2b .b2b-menu > li:focus-within .dgc-currency-switcher__list.sub-menu {
	opacity: 1;
	visibility: visible;
	pointer-events: auto;
}

.site-header--b2b .dg-language-switcher .is-active,
.site-header--b2b .dgc-currency-switcher .is-active {
	display: none;
}

.site-header--b2b .dg-language-switcher__label,
.site-header--b2b .dgc-currency-switcher__label,
.site-header--b2b .menu-item-currency > a {
	cursor: pointer;
}

.site-header--b2b .dg-language-switcher__item,
.site-header--b2b .dgc-currency-switcher__item {
	white-space: nowrap;
}

.dg-b2b-main {
	max-width: 1200px;
	margin: 0 auto;
	padding: 1.5rem 1rem 3rem;
}

.dg-b2b-filters {
	display: flex;
	flex-wrap: wrap;
	gap: 1rem;
	align-items: flex-end;
	margin-bottom: 1.5rem;
}

.dg-b2b-filters label {
	display: flex;
	flex-direction: column;
	gap: 0.35rem;
	font-size: 0.9rem;
}

.dg-b2b-filters input[type="search"],
.dg-b2b-filters select {
	min-width: 12rem;
	padding: 0.4rem 0.6rem;
}

.dg-b2b-table {
	width: 100%;
	margin-bottom: 1.5rem;
}

.dg-b2b-table__head,
.dg-b2b-group__main,
.dg-b2b-row--variation {
	display: grid;
	grid-template-columns: minmax(0, 1fr) minmax(9.5rem, 12rem) minmax(6.5rem, 7.5rem);
	gap: 1rem 1.5rem;
	align-items: center;
}

.dg-b2b-table__head {
	padding: 0 20px 0.75rem;
	font-size: 0.85rem;
	text-transform: uppercase;
	letter-spacing: 0.02em;
	font-weight: 600;
	color: #3b3c3f;
}

.dg-b2b-table__col--price,
.dg-b2b-table__col--qty,
.dg-b2b-cell-price,
.dg-b2b-cell-qty {
	text-align: right;
	padding-inline: 0.35rem;
}

.dg-b2b-cell-price {
	white-space: nowrap;
}

.dg-b2b-cell-qty {
	display: flex;
	justify-content: flex-end;
	align-items: center;
}

.dg-b2b-groups {
	display: flex;
	flex-direction: column;
	gap: 15px;
}

.dg-b2b-group {
	border: 1px solid #d5d7d7;
	border-radius: 8px;
	background: #fff;
	padding: 20px;
	box-sizing: border-box;
	transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.dg-b2b-group:hover {
	border: 2px solid #000;
	padding: 19px;
}

.dg-b2b-group.is-expanded {
	border: 2px solid #3c7ac2;
	box-shadow: 0 0 0 1px rgba(60, 122, 194, 0.15);
	padding: 19px;
}

.dg-b2b-group.is-expanded:hover {
	border-color: #3c7ac2;
}

.dg-b2b-qty,
.dg-b2b-qty-master {
	width: 6.5rem;
	min-width: 6.5rem;
	padding: 0.5rem 0.65rem;
	box-sizing: border-box;
	text-align: center;
}

.dg-b2b-cell-product {
	display: flex;
	align-items: center;
	gap: 12px;
	min-width: 0;
}

.dg-b2b-cell-product__meta {
	display: flex;
	flex-wrap: wrap;
	align-items: baseline;
	gap: 0.25rem 0.5rem;
	min-width: 0;
}

.dg-b2b-thumb {
	display: block;
	width: 48px;
	height: 48px;
	object-fit: cover;
	flex-shrink: 0;
	border-radius: 4px;
}

.dg-b2b-master-name {
	display: inline;
	margin: 0;
	padding: 0;
	border: 0;
	background: none;
	font: inherit;
	font-size: 16px;
	font-weight: 500;
	line-height: 1.3;
	color: #3b3c3f;
	text-align: left;
	cursor: pointer;
	text-decoration: none;
	transition: color 0.15s ease, text-decoration-color 0.15s ease;
}

.dg-b2b-master-name:hover,
.dg-b2b-master-name:focus-visible {
	color: #3c7ac2;
	text-decoration: underline;
	outline: none;
}

.dg-b2b-master-name[aria-expanded="true"] {
	color: #3c7ac2;
}

.dg-b2b-var-count {
	font-weight: 400;
	font-size: 0.85em;
	opacity: 0.75;
}

.dg-b2b-cell-product__name {
	font-size: 16px;
	font-weight: 500;
	color: #3b3c3f;
}

.dg-b2b-cell-price {
	font-size: 16px;
	font-weight: 600;
	line-height: 1.2;
	color: #3b3c3f;
	white-space: nowrap;
}

.dg-b2b-group__vars {
	display: none;
	flex-direction: column;
	gap: 0.75rem;
	margin-top: 1rem;
	padding-top: 1rem;
	border-top: 1px solid #e8e9e9;
}

.dg-b2b-group.is-expanded .dg-b2b-group__vars {
	display: flex;
}

.dg-b2b-row--variation .dg-b2b-cell-product {
	padding-left: calc(48px + 12px + 1.25rem);
}

.dg-b2b-qty-master {
	border-color: #999;
}

.dg-b2b-submit {
	margin-top: 0.5rem;
}

.dg-b2b-totals {
	margin: 1.25rem 0 0.75rem;
	padding: 1rem 1.15rem;
	border: 1px solid #d5d7d7;
	border-radius: 8px;
	background: #f8f8f8;
	display: flex;
	flex-direction: column;
	gap: 0.5rem;
	max-width: 28rem;
}

.dg-b2b-totals__row {
	display: flex;
	justify-content: space-between;
	align-items: baseline;
	gap: 1rem;
	font-size: 1rem;
	color: #3b3c3f;
}

.dg-b2b-totals__row strong {
	font-size: 1.05rem;
	font-weight: 700;
	white-space: nowrap;
}

.dg-b2b-tax-note,
.dg-b2b-notice {
	font-size: 0.9rem;
	opacity: 0.85;
}

.dg-b2b-table-meta {
	margin: 0.75rem 0;
	font-size: 0.9rem;
	opacity: 0.85;
}

.dg-b2b-order-wrap.is-loading .dg-b2b-table {
	opacity: 0.55;
	pointer-events: none;
}

.dg-b2b-row--loading,
.dg-b2b-empty {
	text-align: center;
	padding: 1.5rem 0.75rem;
	opacity: 0.75;
	font-style: italic;
	border: 1px solid #d5d7d7;
	border-radius: 8px;
	background: #fff;
}

@media (max-width: 782px) {
	.dg-b2b-table__head {
		display: none;
	}

	.dg-b2b-group__main,
	.dg-b2b-row--variation {
		grid-template-columns: minmax(0, 1fr) auto;
		grid-template-areas:
			"product product"
			"excl qty";
		gap: 0.5rem 12px;
	}

	.dg-b2b-cell-product {
		grid-area: product;
	}

	.dg-b2b-cell-price--excl {
		grid-area: excl;
		text-align: left;
	}

	.dg-b2b-cell-qty {
		grid-area: qty;
		align-self: center;
	}

	.dg-b2b-row--variation .dg-b2b-cell-product {
		padding-left: 1.25rem;
	}
}

.dg-b2b-pagination {
	margin: 1rem 0 1.5rem;
}

.dg-b2b-pagination .page-numbers {
	display: flex;
	flex-wrap: wrap;
	gap: 0.35rem;
	list-style: none;
	margin: 0;
	padding: 0;
}

.dg-b2b-pagination .page-numbers li {
	margin: 0;
}

.dg-b2b-pagination .page-numbers a,
.dg-b2b-pagination .page-numbers span {
	display: inline-block;
	min-width: 2rem;
	padding: 0.35rem 0.55rem;
	text-align: center;
	border: 1px solid #ddd;
	text-decoration: none;
}

.dg-b2b-pagination .page-numbers .current {
	font-weight: 700;
	border-color: #111;
}

.dg-b2b-quote-summary table {
	width: 100%;
	margin: 1rem 0 1rem;
}

.dg-b2b-quote-summary .dg-b2b-totals {
	margin-top: 0;
	margin-bottom: 1.5rem;
}

.dg-b2b-totals__row--grand {
	font-size: 1.05em;
	margin-top: 0.35rem;
	padding-top: 0.35rem;
	border-top: 1px solid #d5d7d7;
}

.dg-b2b-review[hidden],
.dg-b2b-b2c-dialog[hidden] {
	display: none !important;
}

.dg-b2b-review,
.dg-b2b-b2c-dialog {
	position: fixed;
	inset: 0;
	z-index: 100000;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 1rem;
}

.dg-b2b-review__backdrop,
.dg-b2b-b2c-dialog__backdrop {
	position: absolute;
	inset: 0;
	background: rgba(17, 17, 17, 0.45);
}

.dg-b2b-review__panel,
.dg-b2b-b2c-dialog__panel {
	position: relative;
	z-index: 1;
	width: min(40rem, 100%);
	max-height: min(90vh, 40rem);
	overflow: auto;
	background: #fff;
	border-radius: 8px;
	padding: 1.25rem 1.5rem;
	box-shadow: 0 12px 40px rgba(0, 0, 0, 0.18);
}

.dg-b2b-review__title,
.dg-b2b-b2c-dialog__title {
	margin: 0 0 0.75rem;
	font-size: 1.25rem;
}

.dg-b2b-review__body table {
	width: 100%;
	border-collapse: collapse;
	margin: 0.75rem 0;
}

.dg-b2b-review__body th,
.dg-b2b-review__body td {
	border-bottom: 1px solid #e5e5e5;
	padding: 0.4rem 0.35rem;
	text-align: left;
	font-size: 0.95rem;
}

.dg-b2b-review__body th:nth-child(2),
.dg-b2b-review__body td:nth-child(2),
.dg-b2b-review__body th:nth-child(3),
.dg-b2b-review__body td:nth-child(3) {
	text-align: right;
}

.dg-b2b-review__actions,
.dg-b2b-b2c-dialog__actions {
	display: flex;
	flex-wrap: wrap;
	gap: 0.5rem;
	justify-content: flex-end;
	margin-top: 1rem;
}

body.dg-b2b-dialog-open {
	overflow: hidden;
}
