/* DENVAS mobile context 1.1.0 — mobile navigation and compact category chooser. */

/* Generated labels must never alter the approved desktop presentation. */
html body.denvas-theme .denvas-mobile-context__standalone,
html body.denvas-theme .denvas-mobile-context__generated {
	display: none;
}

/* The generated chooser is mobile-only; desktop keeps the approved category grid. */
html body.denvas-theme .denvas-mobile-types__toggle {
	display: none;
}

@media (max-width: 767px) {
	/* Keep the useful shop message complete without increasing header height. */
	html body.denvas-theme .denvas-announcement {
		justify-content: center !important;
		gap: 0 !important;
		min-height: 36px;
		padding-right: 12px !important;
		padding-left: 12px !important;
		overflow: hidden !important;
		background: #080706 !important;
		box-shadow: inset 0 -1px 0 rgba(196, 148, 87, .6);
	}

	html body.denvas-theme .denvas-announcement > span:first-child,
	html body.denvas-theme .denvas-announcement > .denvas-announcement__dot {
		display: none !important;
	}

	html body.denvas-theme .denvas-announcement > span:last-child {
		display: flex !important;
		align-items: center;
		justify-content: center;
		flex: 0 1 auto !important;
		gap: 8px;
		min-width: 0;
		max-width: 100% !important;
		overflow: visible !important;
		color: #f6f0e8 !important;
		font-size: clamp(10.5px, 2.75vw, 11.5px) !important;
		font-weight: 650 !important;
		line-height: 1.2 !important;
		letter-spacing: .025em !important;
		text-align: center;
		text-overflow: clip !important;
		white-space: nowrap !important;
	}

	html body.denvas-theme .denvas-announcement > span:last-child::before,
	html body.denvas-theme .denvas-announcement > span:last-child::after {
		flex: 0 0 14px;
		height: 1px;
		background: #c49457;
		box-shadow: 0 0 7px rgba(196, 148, 87, .45);
		content: "";
	}

	html body.denvas-theme.denvas-mobile-context-ready .denvas-back-row.denvas-mobile-context {
		display: flex !important;
		align-items: center !important;
		flex-wrap: nowrap !important;
		gap: 12px !important;
		min-width: 0;
		min-height: 48px !important;
		margin-bottom: 12px !important;
	}

	html body.denvas-theme.denvas-mobile-context-ready .denvas-back-row.denvas-mobile-context > .denvas-back-nav {
		flex: 0 0 auto !important;
		width: auto !important;
		margin: 0 !important;
	}

	html body.denvas-theme.denvas-mobile-context-ready .denvas-mobile-context__back .denvas-back-nav__button {
		gap: 7px;
		min-height: 44px;
		padding: 0 !important;
		font-size: 13px;
		line-height: 1.3;
	}

	html body.denvas-theme.denvas-mobile-context-ready .denvas-mobile-context__back .denvas-back-nav__button svg {
		flex-basis: 16px;
		width: 16px;
		height: 16px;
	}

	html body.denvas-theme.denvas-mobile-context-ready .denvas-back-row.denvas-mobile-context > .denvas-mobile-context__trail {
		display: flex !important;
		align-items: center !important;
		justify-content: flex-end;
		flex: 1 1 auto !important;
		flex-wrap: nowrap !important;
		gap: 6px !important;
		min-width: 0;
		min-height: 44px;
		margin: 0 !important;
		padding: 0 !important;
		overflow: hidden;
		color: #5f5a53;
		font: 500 11.5px/1.35 var(--denvas-sans, "Manrope", Arial, sans-serif) !important;
		letter-spacing: .01em !important;
		text-align: right;
		text-transform: none !important;
		white-space: nowrap;
	}

	html body.denvas-theme.denvas-mobile-context-ready .denvas-mobile-context__trail > * {
		display: none !important;
	}

	/* Last two breadcrumb items and their separator only. */
	html body.denvas-theme.denvas-mobile-context-ready .denvas-mobile-context__trail > :nth-last-child(-n + 3) {
		display: block !important;
		min-width: 0;
		max-width: 100%;
		margin: 0;
		padding: 0;
		border: 0;
		background: transparent;
		font: inherit !important;
		letter-spacing: inherit !important;
		line-height: inherit !important;
		text-transform: none !important;
		white-space: nowrap;
	}

	html body.denvas-theme.denvas-mobile-context-ready .denvas-mobile-context__trail > :nth-last-child(3) {
		flex: 0 1 42%;
		overflow: hidden;
		color: inherit !important;
		text-overflow: ellipsis;
		opacity: .72;
	}

	html body.denvas-theme.denvas-mobile-context-ready .denvas-mobile-context__trail > :nth-last-child(2) {
		flex: 0 0 auto;
		color: inherit !important;
		opacity: .48;
	}

	html body.denvas-theme.denvas-mobile-context-ready .denvas-mobile-context__trail > :last-child {
		flex: 0 1 58%;
		overflow: hidden;
		color: var(--denvas-category-accent, #171512) !important;
		font-weight: 600 !important;
		text-overflow: ellipsis;
		opacity: 1;
	}

	html body.denvas-theme.denvas-mobile-context-ready .denvas-mobile-context__trail > a:is(:hover, :focus-visible) {
		color: var(--denvas-category-accent, #171512) !important;
		opacity: 1;
	}

	/* Pages without breadcrumbs use the same one-row component. */
	html body.denvas-theme.denvas-mobile-context-ready .denvas-back-nav.denvas-mobile-context--standalone {
		display: flex !important;
		align-items: center;
		gap: 12px;
		min-height: 48px;
		margin-top: 8px;
		margin-bottom: 12px;
	}

	html body.denvas-theme.denvas-mobile-context-ready .denvas-mobile-context__standalone {
		display: block;
		flex: 1 1 auto;
		min-width: 0;
		overflow: hidden;
		color: var(--denvas-category-accent, #171512);
		font: 600 11.5px/1.35 var(--denvas-sans, "Manrope", Arial, sans-serif);
		letter-spacing: .01em;
		text-align: right;
		text-overflow: ellipsis;
		text-transform: none;
		white-space: nowrap;
	}

	/* Maintain legibility inside the black-and-gold storefront world. */
	html body.denvas-theme:is(.denvas-world-palette-dark, .denvas-world-zdrowie).denvas-mobile-context-ready .denvas-mobile-context__trail {
		color: #bdb3a6 !important;
	}

	html body.denvas-theme:is(.denvas-world-palette-dark, .denvas-world-zdrowie).denvas-mobile-context-ready :is(
		.denvas-mobile-context__trail > :last-child,
		.denvas-mobile-context__standalone
	) {
		color: var(--denvas-category-accent, #c49457) !important;
	}

	/* Collapse the tall third-level category grid into one compact control. */
	html body.denvas-theme.denvas-mobile-context-ready .denvas-category-types.denvas-mobile-types {
		--denvas-mobile-types-background: #fff;
		--denvas-mobile-types-border: rgba(23, 21, 18, .16);
		--denvas-mobile-types-text: #171512;
		--denvas-mobile-types-muted: #746d63;
		display: block !important;
		width: 100%;
		margin-top: 10px !important;
		margin-bottom: 16px !important;
	}

	html body.denvas-theme.denvas-mobile-context-ready .denvas-category-types.denvas-mobile-types > .denvas-category-types__label {
		display: none !important;
	}

	html body.denvas-theme.denvas-mobile-context-ready .denvas-mobile-types__toggle {
		position: relative;
		display: grid !important;
		grid-template-columns: minmax(0, 1fr) auto;
		align-items: center;
		width: 100%;
		min-height: 56px;
		margin: 0;
		padding: 9px 44px 9px 12px;
		border: 1px solid var(--denvas-mobile-types-border) !important;
		border-radius: 10px;
		background: var(--denvas-mobile-types-background) !important;
		box-shadow: 0 5px 14px rgba(23, 21, 18, .055);
		color: var(--denvas-mobile-types-text) !important;
		font-family: var(--denvas-sans, "Manrope", Arial, sans-serif) !important;
		text-align: left;
		-webkit-tap-highlight-color: transparent;
		appearance: none;
		cursor: pointer;
	}

	html body.denvas-theme.denvas-mobile-context-ready .denvas-mobile-types__toggle::after {
		position: absolute;
		top: 50%;
		right: 17px;
		width: 8px;
		height: 8px;
		border-right: 1.5px solid currentColor;
		border-bottom: 1.5px solid currentColor;
		content: "";
		transform: translateY(-68%) rotate(45deg);
		transition: transform .2s ease;
	}

	html body.denvas-theme.denvas-mobile-context-ready .denvas-category-types.denvas-mobile-types.is-open > .denvas-mobile-types__toggle::after {
		transform: translateY(-30%) rotate(225deg);
	}

	html body.denvas-theme.denvas-mobile-context-ready .denvas-mobile-types__toggle:is(:hover, :focus-visible) {
		border-color: var(--denvas-category-accent, #7e654c) !important;
		box-shadow: 0 7px 18px rgba(23, 21, 18, .08);
	}

	html body.denvas-theme.denvas-mobile-context-ready .denvas-mobile-types__toggle:focus-visible {
		outline: 2px solid var(--denvas-category-accent, #7e654c);
		outline-offset: 2px;
	}

	html body.denvas-theme.denvas-mobile-context-ready .denvas-mobile-types__copy {
		display: flex;
		flex-direction: column;
		gap: 3px;
		min-width: 0;
	}

	html body.denvas-theme.denvas-mobile-context-ready .denvas-mobile-types__eyebrow {
		color: var(--denvas-category-accent, #7e654c);
		font-size: 9.5px;
		font-weight: 700;
		line-height: 1.2;
		letter-spacing: .11em;
		text-transform: uppercase;
	}

	html body.denvas-theme.denvas-mobile-context-ready .denvas-mobile-types__selection {
		display: flex;
		align-items: baseline;
		gap: 7px;
		min-width: 0;
		font-size: 13px;
		line-height: 1.3;
	}

	html body.denvas-theme.denvas-mobile-context-ready .denvas-mobile-types__name {
		min-width: 0;
		overflow: hidden;
		font-weight: 650;
		text-overflow: ellipsis;
		white-space: nowrap;
	}

	html body.denvas-theme.denvas-mobile-context-ready .denvas-mobile-types__count {
		flex: 0 0 auto;
		color: var(--denvas-mobile-types-muted);
		font-size: 11px;
		font-weight: 500;
		white-space: nowrap;
	}

	html body.denvas-theme.denvas-mobile-context-ready .denvas-mobile-types__count:not(:empty)::before {
		margin-right: 7px;
		content: "\2022";
		opacity: .55;
	}

	html body.denvas-theme.denvas-mobile-context-ready .denvas-category-types.denvas-mobile-types:not(.is-open) > .denvas-category-types__links {
		display: none !important;
	}

	html body.denvas-theme.denvas-mobile-context-ready .denvas-category-types.denvas-mobile-types.is-open > .denvas-category-types__links {
		display: grid !important;
		margin-top: 8px !important;
	}

	html body.denvas-theme:is(.denvas-world-palette-dark, .denvas-world-zdrowie).denvas-mobile-context-ready .denvas-category-types.denvas-mobile-types {
		--denvas-mobile-types-background: #171715;
		--denvas-mobile-types-border: rgba(196, 148, 87, .34);
		--denvas-mobile-types-text: #f4efe7;
		--denvas-mobile-types-muted: #bdb3a6;
	}

	html body.denvas-theme:is(.denvas-world-palette-dark, .denvas-world-zdrowie).denvas-mobile-context-ready .denvas-mobile-types__toggle {
		box-shadow: 0 7px 18px rgba(0, 0, 0, .22);
	}
}

/* Balance every two-column third-level category grid, including tablets. */
@media (max-width: 1099px) {
	html body.denvas-theme .denvas-category-types__links > .denvas-category-types__link:last-child:nth-child(odd) {
		grid-column: 1 / -1;
	}
}

@media print {
	html body.denvas-theme .denvas-mobile-context__standalone,
	html body.denvas-theme .denvas-mobile-context__generated {
		display: none !important;
	}
}
