/* Gift Cards — сторінка товару, поле для коду, баланс. Кольори й шрифти успадковуються від теми. */

.zgc-fields {
	margin: 0 0 1.5em;
}
.zgc-fields fieldset {
	margin: 0 0 1em;
	padding: 0;
	border: 0;
}
.zgc-fields legend,
.zgc-fields label,
.zgc-redeem label,
.zgc-balance-form label {
	display: block;
	margin-bottom: .35em;
	font-weight: 600;
}
.zgc-amounts .zgc-pill {
	position: relative;
	display: inline-block;
	margin: 0 .4em .4em 0;
	font-weight: 400;
	cursor: pointer;
}
.zgc-pill input {
	position: absolute;
	opacity: 0;
	pointer-events: none;
}
.zgc-pill span {
	display: inline-block;
	padding: .5em 1em;
	border: 1px solid currentColor;
	border-radius: 4px;
	opacity: .7;
}
.zgc-pill input:checked + span {
	background: #000;
	border-color: #000;
	color: #fff;
	opacity: 1;
}
.zgc-pill input:focus-visible + span {
	outline: 2px solid #000;
	outline-offset: 2px;
}
.zgc-field,
.zgc-custom {
	margin: 0 0 1em;
}
.zgc-field input,
.zgc-field textarea,
.zgc-custom input {
	width: 100%;
	max-width: 420px;
	box-sizing: border-box;
}
/* Теми часто звужують числові поля у формі товару (під поле кількості) — повертаємо повну ширину. */
form.cart .zgc-fields .zgc-custom input[type="number"] {
	display: block;
	width: 100% !important;
	max-width: 420px !important;
	min-width: 200px;
}
/* Обводка полів: світло-сіра, під час введення — чорна. Селектори конкретніші за стилі теми. */
form.cart .zgc-fields input:not([type="radio"]),
form.cart .zgc-fields textarea,
.zgc-redeem input.zgc-code,
.zgc-balance-form input[type="text"] {
	border: 1px solid #dddddd !important;
	border-radius: 4px;
	box-shadow: none !important;
	transition: border-color .15s ease;
}
form.cart .zgc-fields input:not([type="radio"]):focus,
form.cart .zgc-fields textarea:focus,
.zgc-redeem input.zgc-code:focus,
.zgc-balance-form input[type="text"]:focus {
	border-color: #000000 !important;
	outline: none;
}
/* Дата надсилання: поле ДД.ММ.РРРР з великою кнопкою календаря. */
.zgc-date-field {
	display: flex;
	gap: .4em;
	max-width: 420px;
}
form.cart .zgc-fields .zgc-date-field input.zgc-date {
	flex: 1 1 auto;
	width: auto !important;
	min-width: 0;
	max-width: none !important;
	height: auto;
	min-height: 3em;
	padding-top: .6em;
	padding-bottom: .6em;
	line-height: 1.5;
	font-variant-numeric: tabular-nums;
}
form.cart .zgc-fields .zgc-date-button {
	display: inline-flex;
	flex: 0 0 auto;
	align-items: center;
	justify-content: center;
	width: 3.2em;
	min-height: 3em;
	margin: 0;
	padding: 0;
	background: #fff;
	color: #000;
	border: 1px solid #dddddd;
	border-radius: 4px;
	box-shadow: none;
	cursor: pointer;
}
form.cart .zgc-fields .zgc-date-button:hover,
form.cart .zgc-fields .zgc-date-button:focus-visible {
	background: #fff;
	color: #000;
	border-color: #000;
	outline: none;
}
form.cart .zgc-fields .zgc-date-button svg {
	display: block;
	width: 26px;
	height: 26px;
}

/* Календар jQuery UI: чорне на білому. */
.zgc-datepicker.ui-datepicker {
	z-index: 100100 !important;
	display: none;
	width: 290px;
	max-width: calc(100vw - 20px);
	padding: 10px;
	box-sizing: border-box;
	background: #fff;
	color: #000;
	border: 1px solid #dddddd;
	border-radius: 4px;
	box-shadow: 0 6px 20px rgba(0, 0, 0, .15);
	font-size: 14px;
	line-height: 1.2;
}
.zgc-datepicker .ui-datepicker-header {
	position: relative;
	display: flex;
	align-items: center;
	justify-content: center;
	min-height: 34px;
	margin-bottom: 6px;
}
.zgc-datepicker .ui-datepicker-title {
	font-weight: 600;
}
.zgc-datepicker .ui-datepicker-prev,
.zgc-datepicker .ui-datepicker-next {
	position: absolute;
	top: 0;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 34px;
	height: 34px;
	color: #000;
	text-decoration: none;
	cursor: pointer;
	border-radius: 4px;
}
.zgc-datepicker .ui-datepicker-prev { left: 0; }
.zgc-datepicker .ui-datepicker-next { right: 0; }
.zgc-datepicker .ui-datepicker-prev:hover,
.zgc-datepicker .ui-datepicker-next:hover {
	background: #f0f0f0;
}
.zgc-datepicker .ui-datepicker-prev span,
.zgc-datepicker .ui-datepicker-next span {
	display: none;
}
.zgc-datepicker .ui-datepicker-prev::before,
.zgc-datepicker .ui-datepicker-next::before {
	font-size: 24px;
	line-height: 1;
	content: "‹";
}
.zgc-datepicker .ui-datepicker-next::before {
	content: "›";
}
.zgc-datepicker .ui-datepicker-prev.ui-state-disabled,
.zgc-datepicker .ui-datepicker-next.ui-state-disabled {
	opacity: .3;
	cursor: default;
}
.zgc-datepicker table {
	width: 100%;
	margin: 0;
	border: 0;
	border-collapse: collapse;
}
.zgc-datepicker th,
.zgc-datepicker td {
	padding: 1px;
	border: 0;
	background: none;
	text-align: center;
}
.zgc-datepicker th {
	padding: 4px 0;
	font-weight: 600;
	color: #555;
}
.zgc-datepicker td a,
.zgc-datepicker td span {
	display: block;
	padding: 7px 0;
	color: #000;
	text-decoration: none;
	border-radius: 4px;
}
.zgc-datepicker td a:hover {
	background: #f0f0f0;
}
.zgc-datepicker .ui-state-disabled span,
.zgc-datepicker .ui-datepicker-other-month a {
	color: #bbb;
}
.zgc-datepicker .ui-datepicker-today a {
	box-shadow: inset 0 0 0 1px #000;
}
.zgc-datepicker .ui-datepicker-current-day a,
.zgc-datepicker td a.ui-state-active {
	background: #000;
	color: #fff;
}
.zgc-field small,
.zgc-custom small {
	display: block;
	margin-top: .25em;
	opacity: .7;
}

.zgc-redeem {
	margin: 0 0 1em;
}
.zgc-redeem-row {
	display: flex;
	gap: .5em;
}
.zgc-redeem-row input {
	flex: 1 1 auto;
	min-width: 0;
	text-transform: uppercase;
}
.zgc-redeem-row input::placeholder {
	text-transform: none;
}
.zgc-redeem-message,
.zgc-error {
	margin: .5em 0 0;
	color: #b32d2e;
}
.zgc-checkout-box {
	max-width: 480px;
	margin-bottom: 2em;
}
.zgc-applied .zgc-remove {
	margin-left: .5em;
	font-size: .9em;
	white-space: nowrap;
}

.zgc-balance-form {
	max-width: 480px;
	margin: 0 0 2em;
}
.zgc-balance-result {
	margin-top: 1em;
	padding: 1em;
	border: 1px solid #ddd;
	border-radius: 4px;
}
.zgc-balance-result p {
	margin: 0 0 .35em;
}
.zgc-balance-result p:last-child {
	margin-bottom: 0;
}
