/* Gift Delivery Options – product page. Uses logical properties so it mirrors automatically on RTL sites. */
.gdo-fields {
	--gdo-border: #d9d9e3;
	--gdo-focus: #1f4d2b;
	--gdo-bg: #fff;
	--gdo-muted: #6b6b76;
	--gdo-required: #e2401c;
	--gdo-radius: 4px;
	display: grid;
	gap: 22px;
	margin: 0 0 28px;
	width: 100%;
	text-align: start;
	clear: both;
}

.gdo-field { margin: 0; padding: 0; border: 0; min-width: 0; position: relative; }

.gdo-label {
	display: block;
	font-weight: 600;
	margin: 0 0 10px;
	padding: 0;
	line-height: 1.4;
}
/* Mixed English / Arabic labels: each paragraph takes its direction from its first strong character. */
.gdo-bidi { unicode-bidi: plaintext; }
.gdo-required { color: var(--gdo-required); text-decoration: none; border: 0; margin-inline-start: 2px; }

.gdo-fields textarea,
.gdo-fields input[type="text"],
.gdo-fields input[type="tel"],
.gdo-fields input[type="date"] {
	display: block;
	width: 100%;
	box-sizing: border-box;
	padding: 10px 12px;
	min-height: 44px;
	border: 1px solid var(--gdo-border);
	border-radius: var(--gdo-radius);
	background: var(--gdo-bg);
	font: inherit;
	color: inherit;
	text-align: start;
	unicode-bidi: plaintext;
}
.gdo-fields textarea { min-height: 120px; resize: vertical; background: #f4f4f4; }

/* Date field: whole field is clickable, and theme height/line-height rules can't crop the value. */
.gdo-fields input[type="date"] {
	position: relative;
	cursor: pointer;
	height: auto !important;
	min-height: 48px !important;
	padding: 11px 12px !important;
	line-height: 1.5 !important;
	font-size: 16px; /* also stops iOS zooming on focus */
	overflow: visible;
}
.gdo-fields input[type="date"]::-webkit-datetime-edit,
.gdo-fields input[type="date"]::-webkit-datetime-edit-fields-wrapper {
	padding: 0;
	line-height: 1.5;
}
.gdo-fields input[type="date"]::-webkit-date-and-time-value { /* iOS Safari */
	text-align: start;
	min-height: 1.5em;
	margin: 0;
}
.gdo-fields input[type="date"]::-webkit-calendar-picker-indicator {
	cursor: pointer;
	margin-inline-start: 8px;
}
.gdo-fields textarea:focus,
.gdo-fields input:focus { outline: 2px solid var(--gdo-focus); outline-offset: 1px; border-color: var(--gdo-focus); }

/* Phone numbers stay LTR, but align to the reading side on RTL sites. */
.gdo-fields .gdo-phone { direction: ltr; unicode-bidi: normal; text-align: left; }
.rtl .gdo-fields .gdo-phone, [dir="rtl"] .gdo-fields .gdo-phone { text-align: right; }

.gdo-counter {
	display: block;
	margin-top: 4px;
	font-size: 12px;
	color: var(--gdo-muted);
	text-align: end;
}

.gdo-sample-link {
	background: none;
	border: 0;
	padding: 0;
	margin-inline-start: 6px;
	font: inherit;
	font-weight: 600;
	color: inherit;
	text-decoration: underline;
	text-underline-offset: 2px;
	cursor: pointer;
}
.gdo-sample-link:hover, .gdo-sample-link:focus-visible { color: var(--gdo-focus); }

/* Time slots */
.gdo-slots {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 14px 16px;
}
@media (max-width: 480px) { .gdo-slots { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

.gdo-slot {
	display: flex;
	align-items: center;
	gap: 8px;
	margin: 0;
	cursor: pointer;
	color: var(--gdo-muted);
	line-height: 1.3;
}
.gdo-slot[hidden] { display: none !important; }
.gdo-slot input[type="radio"] {
	appearance: none;
	-webkit-appearance: none;
	flex: 0 0 18px;
	width: 18px;
	height: 18px;
	margin: 0;
	border: 1px solid #b9b9c3;
	border-radius: 50%;
	background: #fff;
	display: grid;
	place-content: center;
	cursor: pointer;
}
.gdo-slot input[type="radio"]::before {
	content: "";
	width: 10px;
	height: 10px;
	border-radius: 50%;
	transform: scale(0);
	transition: transform .12s ease-in-out;
	background: var(--gdo-focus);
}
.gdo-slot input[type="radio"]:checked { border-color: var(--gdo-focus); }
.gdo-slot input[type="radio"]:checked::before { transform: scale(1); }
.gdo-slot input[type="radio"]:checked + span { color: inherit; font-weight: 600; }
.gdo-slot input[type="radio"]:focus-visible { outline: 2px solid var(--gdo-focus); outline-offset: 2px; }

.gdo-no-slots {
	margin: 8px 0 0;
	padding: 10px 12px;
	background: #fff6e5;
	border-inline-start: 3px solid #e0a100;
	font-size: 14px;
}
.gdo-no-slots span { display: block; margin-top: 4px; }

.gdo-notice { font-size: 14px; color: #444; }
.gdo-notice p { margin: 0 0 8px; }

/* Sample card modal */
.gdo-modal[hidden] { display: none; }
.gdo-modal {
	position: fixed;
	inset: 0;
	z-index: 999999;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 20px;
}
.gdo-modal__backdrop { position: absolute; inset: 0; background: rgba(0, 0, 0, .65); }
.gdo-modal__dialog {
	position: relative;
	max-width: min(560px, 100%);
	max-height: 90vh;
	background: #fff;
	border-radius: 6px;
	padding: 12px;
	box-shadow: 0 20px 60px rgba(0, 0, 0, .35);
	animation: gdo-pop .18s ease-out;
}
.gdo-modal__dialog img { display: block; max-width: 100%; max-height: calc(90vh - 24px); height: auto; margin: 0 auto; border-radius: 3px; }
.gdo-modal__close {
	position: absolute;
	top: -14px;
	inset-inline-end: -14px;
	width: 34px;
	height: 34px;
	border-radius: 50%;
	border: 0;
	background: #fff;
	color: #111;
	font-size: 22px;
	line-height: 34px;
	padding: 0;
	cursor: pointer;
	box-shadow: 0 2px 8px rgba(0, 0, 0, .3);
}
html.gdo-modal-open { overflow: hidden; }
@keyframes gdo-pop { from { transform: scale(.96); opacity: 0; } to { transform: none; opacity: 1; } }
@media (prefers-reduced-motion: reduce) { .gdo-modal__dialog { animation: none; } }
