/* ============================================================
   Ticket shop showcase — Figma «Витрина магазина» (501:642)
   Overrides the plugin's structural .tpt- styles for the
   direction-grouped layout. Background per direction: --dir-bg
   (solid colour or gradient, built in PHP from the term settings)
   ============================================================ */

.tpt-shop {
	/* Break out of the (narrow) page content column so blocks can reach 1051px */
	width: auto;
	max-width: none;
	margin-left: calc(50% - 50vw);
	margin-right: calc(50% - 50vw);
	padding-inline: 20px;
	display: flex;
	flex-direction: column;
	align-items: center;               /* center the fixed-width direction blocks */
	gap: clamp(1.5rem, 3vw, 2.5rem);
	overflow-x: clip;                  /* guard against horizontal scroll from 50vw */
}

/* --- Date filter (only when sessioned tickets exist) ------ */
.tpt-shop__filter {
	display: flex;
	align-items: center;
	gap: 12px;
	flex-wrap: wrap;
	font-size: .9375rem;
	color: var(--color-text, #1a2340);
}
.tpt-shop__filter input[type="date"] {
	padding: 8px 12px;
	border: 1px solid rgba(0, 26, 86, .15);
	border-radius: 12px;
	font: inherit;
}
.tpt-shop__filter-btn {
	padding: 9px 20px;
	border-radius: 44px;
	background: var(--gradient-btn, linear-gradient(90deg,#00b8db,#155dfc));
	color: #fff;
	font-weight: 700;
	cursor: pointer;
	border: none;
}
.tpt-shop__filter-reset { color: var(--color-text-muted, #6b7a99); text-decoration: underline; }

.tpt-shop__empty {
	text-align: center;
	padding: 3rem 1rem;
	color: var(--color-text-muted, #6b7a99);
}

/* ============================================================
   Direction block
   ============================================================ */
.tpt-shop__dir {
	position: relative;
	width: 1051px;
	max-width: 100%;
	margin-inline: auto;
	border-radius: 32px;
	/* --dir-bg is built in PHP: a solid colour becomes a soft gradient,
	   a gradient chosen in the term settings is used as-is. */
	background: var(--dir-bg, #4aa3e8);
	box-shadow: 0 12px 40px rgba(0, 26, 86, .12);
	padding: clamp(1.75rem, 4vw, 3rem) clamp(1.5rem, 4vw, 3.5rem);
	margin-top: 52px; /* room for the larger overlapping icon */
}

/* Round icon overlapping the top-left corner */
.tpt-shop__dir-icon {
	position: absolute;
	top: -38px;
	left: clamp(1.25rem, 3vw, 2.25rem);
	width: 187px;
	height: 187px;
	border-radius: 50%;
	background: transparent;
	display: flex;
	align-items: center;
	justify-content: center;
	overflow: hidden;
	border: none;
	box-shadow: none;
}
.tpt-shop__dir-icon img { width: 100%; height: 100%; object-fit: cover; }

.tpt-shop__dir-title {
	font-family: 'Golos Text', var(--font-base, sans-serif);
	text-align: center;
	color: #fff;
	font-size: clamp(1.25rem, 2.6vw, 1.75rem);
	font-weight: 700;
	letter-spacing: .05em;
	margin: 0 0 clamp(1.25rem, 3vw, 2rem);
	text-shadow: 0 2px 8px rgba(0, 0, 0, .12);
}

/* ============================================================
   Ticket cards
   ============================================================ */
.tpt-shop__cards {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 24px;
	margin-inline: auto;
}
/* Single-card blocks: don't stretch a lone card across the whole row */
.tpt-shop__cards--few:has(.tpt-shop__card:only-child) {
	grid-template-columns: minmax(0, 460px);
	justify-content: center;
}

.tpt-shop__card {
	min-width: 0;                 /* allow the card to shrink inside the grid track */
	background: #fff;
	border-radius: 18px;
	padding: 24px 20px;
	text-align: center;
	box-shadow: 0 8px 24px rgba(0, 26, 86, .12);
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 10px;
}

.tpt-shop__card-name {
	font-weight: 700;
	font-size: 1.0625rem;
	color: var(--color-primary, #001a56);
	margin: 0;
}
.tpt-shop__card-sub {
	font-size: .8125rem;
	color: var(--color-text-muted, #6b7a99);
	margin: -4px 0 0;
}
.tpt-shop__card-price {
	font-family: 'Golos Text', var(--font-base, sans-serif);
	font-size: clamp(1.5rem, 3vw, 2rem);
	font-weight: 700;
	color: var(--color-accent, #00b8db);
	line-height: 1.1;
	margin: 6px 0;
}

.tpt-shop__buy { width: 100%; min-width: 0; display: flex; flex-direction: column; gap: 10px; }
/* `.tpt-shop` ancestor raises specificity above the plugin's .tpt-session-select */
.tpt-shop .tpt-shop__select {
	display: block;
	width: 100%;
	max-width: 100%;
	min-width: 0;
	box-sizing: border-box;
	padding: 9px 12px;
	border: 1px solid rgba(0, 26, 86, .15);
	border-radius: 12px;
	font: inherit;
	background: #fff;
}
.tpt-shop__btn {
	width: 100%;
	padding: 10px 16px;
	border: 1.5px solid rgba(0, 26, 86, .18);
	border-radius: 44px;
	background: #fff;
	color: var(--color-primary, #001a56);
	font-weight: 600;
	font-size: .9375rem;
	cursor: pointer;
	transition: background .2s ease, color .2s ease, border-color .2s ease;
}
.tpt-shop__btn:hover {
	background: var(--color-primary, #001a56);
	color: #fff;
	border-color: var(--color-primary, #001a56);
}

/* ============================================================
   Responsive
   ============================================================ */
@media (max-width: 600px) {
	.tpt-shop__dir { border-radius: 24px; padding-top: 2.5rem; }
	.tpt-shop__cards { grid-template-columns: 1fr; }
}

