/* =====================================================
   Pizzeria Menu — style frontendu
   Używa zmiennych z pizzabalon.css jeśli dostępne,
   w przeciwnym razie stosuje własne wartości domyślne.
===================================================== */

.pm-menu {
	/* Zmienne — pobierają wartości z motywu lub używają wartości domyślnych */
	--pm-dark:    var( --clr-dark,            #1D1D1D );
	--pm-light:   var( --clr-light,           #F2F2F2 );
	--pm-bg:      var( --clr-background,      #ffffff );
	--pm-accent:  var( --clr-actent,          #D72127 );
	--pm-border:  var( --pb-body-border-size, 1px );
	--pm-radius:  var( --pb-body-border-radius, 0px );

	font-family: inherit;
	color: var( --pm-dark );
}

/* =====================================================
   Zakładki nawigacyjne
===================================================== */

.pm-tabs-nav {
	background-color: var( --pm-bg );
	border-bottom: calc( var( --pm-border ) * 2 ) solid var( --pm-dark );
}

.pm-tabs-list {
	list-style: none;
	margin: 0;
	padding: 0;
	display: flex;
	flex-wrap: wrap;
	align-items: stretch;
	gap: .15em;
}

.pm-tab-btn {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	background: var( --pm-bg );
	color: var( --pm-dark );
	border: calc( var( --pm-border ) * 2 ) solid var( --pm-dark );
	padding: .55em 1.1em;
	cursor: pointer;
	font-family: 'Khand', sans-serif;
	font-weight: 700;
	font-size: 1em;
	text-transform: uppercase;
	letter-spacing: .04em;
	transition: background-color .18s, color .18s;
	line-height: 1.2;
	white-space: nowrap;
}

.pm-tab-btn:hover {
	background-color: var( --pm-dark );
	color: var( --pm-bg );
}

.pm-tab-btn.active,
.pm-tab-btn[aria-selected="true"] {
	background-color: var( --pm-dark );
	color: var( --pm-bg );
}

/* Ikona zakładki */
.pm-tab-icon {
	width: 28px;
	height: 28px;
	object-fit: contain;
	flex-shrink: 0;
	transition: filter .18s;
}

.pm-tab-btn.active .pm-tab-icon,
.pm-tab-btn:hover .pm-tab-icon {
	/* Inwersja do białego — pasuje do ciemnego tła */
	filter: invert(99%) sepia(2%) saturate(493%) hue-rotate(227deg) brightness(118%) contrast(100%);
}

/* =====================================================
   Panele
===================================================== */

.pm-panel            { display: none; }
.pm-panel--visible   { display: block; }

.pm-single-cat-title {
	font-family: 'Khand', sans-serif;
	font-weight: 700;
	font-size: 1.65em;
	text-transform: uppercase;
	margin: .6em 0;
	padding-bottom: .3em;
	border-bottom: calc( var( --pm-border ) * 3 ) solid var( --pm-accent );
}

/* =====================================================
   Siatka pozycji
===================================================== */

.pm-grid {
	display: grid;
	grid-template-columns: 1fr;
}

.pm-grid--2col {
	grid-template-columns: 1fr 1fr;
}

@media ( max-width: 700px ) {
	.pm-grid--2col {
		grid-template-columns: 1fr;
	}
}

/* =====================================================
   Karta pozycji — zgodna z .custom-menu-item
   z pizzabalon.css
===================================================== */

.pm-menu .custom-menu-item {
	padding: 1.6em 2em;
	border: 3px solid transparent;
	border-bottom: 3px solid var( --pm-light );
	position: relative;
	transition: border-color .25s;
}

.pm-menu .custom-menu-item:nth-child( 2n ) {
	background-color: var( --pm-light );
}

.pm-menu .custom-menu-item:hover {
	border-color: var( --pm-accent );
}

/* Przycisk linku (prawy górny róg) */
.pm-menu .custom-menu-item .order-link {
	position: absolute;
	top: -20px;
	right: 0;
	opacity: .45;
	transition: opacity .25s, top .25s;
}

.pm-menu .custom-menu-item:hover .order-link {
	opacity: 1;
	top: 0;
}

.pm-menu .custom-menu-item .order-link a {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 40px;
	height: 40px;
	background-color: var( --pm-accent );
	color: var( --pm-bg );
	text-decoration: none;
	font-size: 1.3em;
	transition: background-color .2s, transform .2s;
}

.pm-menu .custom-menu-item .order-link a:hover {
	background-color: var( --pm-dark );
}

.pm-order-icon {
	display: inline-block;
	transition: transform .25s;
}

.pm-menu .custom-menu-item .order-link a:hover .pm-order-icon {
	transform: rotate( 45deg );
}

/* Wiersz: tytuł + separator + cena */
.pm-menu .custom-menu-item .item-name {
	display: flex;
	align-items: baseline;
	flex-wrap: nowrap;
	gap: 0;
	margin-bottom: .4em;
}

.pm-menu .custom-menu-item .item-name .title {
	font-family: 'Khand', sans-serif;
	font-weight: 700;
	font-size: 1.35em;
	text-transform: uppercase;
	white-space: nowrap;
	padding-right: .4em;
	line-height: 1.2;
	color: var( --pm-dark );
}

.pm-menu .custom-menu-item .item-name .separator {
	flex-grow: 1;
	align-self: flex-end;
	border-bottom: 2px solid var( --pm-dark );
	margin: 0 .4em .25em;
	min-width: 8px;
}

.pm-menu .custom-menu-item .item-name .item-price {
	display: flex;
	flex-wrap: wrap;
	gap: .4em;
	align-items: flex-end;
	flex-shrink: 0;
}

/* Pojedyncza cena / wariant */
.pm-menu .custom-menu-item .item-price > span {
	display: inline-block;
	position: relative;
	padding: 1.3em .8em .45em;
	border: 1px solid var( --pm-dark );
	font-family: 'Khand', sans-serif;
	font-weight: 700;
	font-size: 1em;
	line-height: 1;
	white-space: nowrap;
}

/* Etykieta nad ceną — domyślnie "cena" */
.pm-menu .custom-menu-item .item-price > span::before {
	content: "cena";
	position: absolute;
	top: 4px;
	left: 5px;
	font-size: .6em;
	font-weight: 400;
	font-family: inherit;
	text-transform: uppercase;
	letter-spacing: .06em;
	color: #888;
	white-space: nowrap;
}

/* Niestandardowa etykieta z atrybutu data-label */
.pm-menu .custom-menu-item .item-price > span[data-label]::before {
	content: attr( data-label );
}

/* Opis */
.pm-menu .custom-menu-item .item-desc {
	font-size: .9em;
	color: #555;
	margin: .3em 0 0;
	line-height: 1.55;
}

/* =====================================================
   Responsywność
===================================================== */

@media ( max-width: 700px ) {
	.pm-menu .custom-menu-item {
		padding: 1.2em 1.2em;
	}

	.pm-menu .custom-menu-item .item-name {
		flex-wrap: wrap;
	}

	.pm-menu .custom-menu-item .item-name .title {
		width: 100%;
		white-space: normal;
	}

	.pm-menu .custom-menu-item .item-name .separator {
		display: none;
	}

	.pm-menu .custom-menu-item .item-name .item-price {
		width: 100%;
		margin-top: .4em;
	}

	.pm-tab-btn {
		font-size: .9em;
		padding: .5em .8em;
	}

	.pm-tab-icon {
		width: 22px;
		height: 22px;
	}
}

/* Brak menu */
.pm-empty {
	color: #999;
	font-style: italic;
}
