/**
 * Alkhatt Art — Personalization (storefront)
 *
 * Replaces the v3.3 / v4.12 / v4.14 personalization blocks that were spread
 * across style.css. Logical properties throughout, so RTL needs no overrides.
 */

.alkhatt-pz {
	margin: 18px 0 20px;
	padding: 18px 18px 14px;
	border: 1px solid var(--alkhatt-border, #e7e1d8);
	border-radius: var(--alkhatt-radius, 18px);
	background: var(--alkhatt-cream, #f7f4ed);
}

.alkhatt-pz__heading {
	margin-bottom: 14px;
}

.alkhatt-pz__heading strong {
	display: block;
	font-size: 15px;
	color: var(--alkhatt-black, #111);
}

.alkhatt-pz__heading span {
	display: block;
	margin-top: 3px;
	font-size: 12.5px;
	line-height: 1.7;
	color: var(--alkhatt-muted, #6f6f6f);
}

/* ---------------------------------------------------------------- a field */

.alkhatt-pz-field {
	margin: 0 0 14px;
}

.alkhatt-pz-field[hidden] {
	display: none;
}

.alkhatt-pz-field__label {
	display: flex;
	flex-wrap: wrap;
	align-items: baseline;
	gap: 8px;
	margin-bottom: 6px;
	font-size: 13.5px;
	font-weight: 600;
	color: var(--alkhatt-black, #111);
}

/* The current limit, e.g. "1-2 digits". Always beside the label so the
   customer can see the rule that is in force before they type. */
.alkhatt-pz-field__limit {
	padding: 2px 8px;
	border-radius: 999px;
	background: var(--alkhatt-sand, #e7dfd0);
	font-size: 11.5px;
	font-weight: 600;
	letter-spacing: .01em;
	color: var(--alkhatt-olive-dark, #515245);
	unicode-bidi: isolate;
}

.alkhatt-pz-field__limit[hidden],
.alkhatt-pz-field__required[hidden],
.alkhatt-pz-field__optional[hidden],
.alkhatt-pz-field__error[hidden] {
	display: none;
}

.alkhatt-pz-field__required {
	color: #b3261e;
	font-weight: 700;
}

.alkhatt-pz-field__optional {
	font-size: 11.5px;
	font-weight: 400;
	color: var(--alkhatt-muted, #6f6f6f);
}

.alkhatt-pz-field input[type="text"],
.alkhatt-pz-field textarea {
	width: 100%;
	box-sizing: border-box;
	padding: 11px 13px;
	border: 1px solid var(--alkhatt-border, #e7e1d8);
	border-radius: 12px;
	background: var(--alkhatt-white, #fff);
	color: var(--alkhatt-black, #111);
	font: inherit;
	font-size: 14.5px;
	transition: border-color .15s ease, box-shadow .15s ease;
}

.alkhatt-pz-field textarea {
	min-height: 88px;
	resize: vertical;
}

.alkhatt-pz-field input[type="text"]:focus,
.alkhatt-pz-field textarea:focus {
	outline: none;
	border-color: var(--alkhatt-olive, #696a5b);
	box-shadow: 0 0 0 3px rgba(105, 106, 91, .14);
}

.alkhatt-pz-field.is-invalid input[type="text"],
.alkhatt-pz-field.is-invalid textarea {
	border-color: #b3261e;
	box-shadow: 0 0 0 3px rgba(179, 38, 30, .1);
}

/* ------------------------------------------------------- helper and counter */

.alkhatt-pz-field__meta {
	display: flex;
	align-items: flex-start;
	justify-content: space-between;
	gap: 14px;
	margin-top: 6px;
}

.alkhatt-pz-field__helper {
	flex: 1 1 auto;
	min-width: 0;
	font-size: 12px;
	line-height: 1.6;
	color: var(--alkhatt-muted, #6f6f6f);
}

.alkhatt-pz-field__count {
	flex: 0 0 auto;
	font-size: 12px;
	font-variant-numeric: tabular-nums;
	color: var(--alkhatt-muted, #6f6f6f);
}

.alkhatt-pz-field.is-invalid .alkhatt-pz-field__count {
	color: #b3261e;
	font-weight: 600;
}

.alkhatt-pz-field__error {
	display: block;
	margin-top: 6px;
	padding: 8px 11px;
	border-radius: 9px;
	border-inline-start: 3px solid #b3261e;
	background: rgba(179, 38, 30, .07);
	font-size: 12.5px;
	line-height: 1.65;
	color: #8c1d18;
}

/* ------------------------------------------------------- blocked add to cart */

.single_add_to_cart_button.alkhatt-pz-blocked {
	opacity: .45;
	cursor: not-allowed;
}

/* --------------------------------------------------------------- pill hints */

.alkhatt-pz-pill-hint {
	display: block;
	margin-top: 2px;
	font-size: 10px;
	line-height: 1.3;
	opacity: .72;
	unicode-bidi: isolate;
}

.alkhatt-variation-pill.is-active .alkhatt-pz-pill-hint {
	opacity: .9;
}

@media (max-width: 600px) {
	.alkhatt-pz {
		padding: 15px 14px 12px;
	}

	.alkhatt-pz-field__meta {
		flex-direction: column;
		gap: 4px;
	}

	.alkhatt-pz-pill-hint {
		display: none;
	}
}
