/* Square gift card on the block checkout. Falls back to neutral values outside the sdc theme. */

.sdc-sgc__entry {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	align-items: flex-start;
}

.sdc-sgc__field {
	flex: 1 1 240px;
	min-width: 0;
}

.sdc-sgc__apply,
.sdc-sgc__remove {
	min-height: 48px;
	padding: 0 18px;
	border: 1px solid var(--ink, #111);
	border-radius: var(--radius, 4px);
	background: transparent;
	color: var(--ink, #111);
	font: inherit;
	cursor: pointer;
}

.sdc-sgc__apply:disabled,
.sdc-sgc__remove:disabled {
	opacity: 0.5;
	cursor: default;
}

.sdc-sgc__remove {
	min-height: 0;
	padding: 6px 12px;
	font-size: 0.875em;
}

.sdc-sgc__hint {
	flex-basis: 100%;
	margin: 0;
}

.sdc-sgc__hint + .sdc-sgc__hint {
	color: var(--ink-60, rgba(0, 0, 0, 0.6));
	font-size: 0.875em;
}

.sdc-sgc__error {
	flex-basis: 100%;
	margin: 0;
	color: #b3261e;
}

.sdc-sgc__applied p {
	margin: 0 0 8px;
}

.sdc-sgc-summary {
	padding: 12px 16px;
	border-top: 1px solid var(--ink-12, rgba(0, 0, 0, 0.12));
}

.sdc-sgc-summary__row {
	display: flex;
	justify-content: space-between;
	gap: 12px;
	margin-bottom: 6px;
}

.sdc-sgc-note {
	margin: 0;
	border-top: 1px solid var(--ink-12, rgba(0, 0, 0, 0.12));
	color: var(--ink-60, rgba(0, 0, 0, 0.6));
	font-size: 0.875em;
}

/*
 * WooCommerce pads order-meta content 16px 0, which beats the padding above.
 * The cart's totals run flush, so that's right there; the checkout summary is
 * a boxed panel whose rows are inset 16px, so match them.
 */
.wp-block-woocommerce-checkout .wc-block-components-order-meta .sdc-sgc-note,
.wp-block-woocommerce-checkout .wc-block-components-order-meta .sdc-sgc-summary {
	padding-left: 16px;
	padding-right: 16px;
}
