/* IV Form 9 — frontend. All colours come from inline CSS variables set per form. */

.ivf-wrap {
	--ivf-accent1: #3E37C9;
	--ivf-accent2: #5B54E0;
	--ivf-title: #1E1B4B;
	--ivf-label: #1E1B4B;
	--ivf-input-bg: #F5F6FB;
	--ivf-input-text: #1E1B4B;
	--ivf-input-border: #E4E6F1;
	--ivf-btn-text: #FFFFFF;
	--ivf-card-bg: #FFFFFF;
	--ivf-card-border: #ECEDF5;
	--ivf-radius: 14px;
	--ivf-gap: 20px;
	--ivf-maxw: 640px;
	max-width: var(--ivf-maxw);
	margin: 0 auto;
	font-family: inherit;
	box-sizing: border-box;
}
.ivf-wrap *, .ivf-wrap *::before, .ivf-wrap *::after { box-sizing: border-box; }

.ivf-form {
	background: var(--ivf-card-bg);
	border: 1px solid var(--ivf-card-border);
	border-radius: calc(var(--ivf-radius) + 8px);
	padding: 34px 34px 30px;
	box-shadow: 0 10px 40px rgba(30, 27, 75, .06);
}
.ivf-nocard .ivf-form {
	background: transparent;
	border: 0;
	box-shadow: none;
	padding: 0;
}

.ivf-title {
	color: var(--ivf-title);
	font-size: 30px;
	font-weight: 800;
	margin: 0 0 26px;
	letter-spacing: -0.01em;
}

.ivf-field { margin-bottom: var(--ivf-gap); }

/* top row: name / email / phone side by side */
.ivf-row { display: grid; gap: var(--ivf-gap); margin-bottom: var(--ivf-gap); }
.ivf-row--2 { grid-template-columns: 1fr 1fr; }
.ivf-row--3 { grid-template-columns: 1fr 1fr 1fr; }
.ivf-row .ivf-field { margin-bottom: 0; }
@media (max-width: 640px) {
	.ivf-row--2, .ivf-row--3 { grid-template-columns: 1fr; }
}

/* radio / checkbox choices */
.ivf-choices { display: flex; flex-wrap: wrap; gap: 10px 18px; padding: 4px 0; }
.ivf-choice { display: inline-flex; align-items: center; gap: 7px; cursor: pointer; color: var(--ivf-input-text); font-size: 14.5px; }
.ivf-choice input { width: 17px; height: 17px; accent-color: var(--ivf-accent1); margin: 0; }
.ivf-field label {
	display: block;
	color: var(--ivf-label);
	font-weight: 700;
	font-size: 14.5px;
	margin-bottom: 8px;
}
.ivf-req { color: #E5484D; }
.ivf-opt { color: #9A98B5; font-weight: 500; }

.ivf-field input,
.ivf-field select,
.ivf-field textarea {
	width: 100%;
	background: var(--ivf-input-bg);
	color: var(--ivf-input-text);
	border: 1px solid var(--ivf-input-border);
	border-radius: var(--ivf-radius);
	padding: 14px 16px;
	font-size: 15px;
	font-family: inherit;
	transition: border-color .18s, box-shadow .18s;
	-webkit-appearance: none;
	appearance: none;
}
.ivf-field textarea { resize: vertical; min-height: 130px; }

.ivf-field input::placeholder,
.ivf-field textarea::placeholder { color: #9A98B5; }

.ivf-field input:focus,
.ivf-field select:focus,
.ivf-field textarea:focus {
	outline: none;
	border-color: var(--ivf-accent1);
	box-shadow: 0 0 0 3px color-mix(in srgb, var(--ivf-accent1) 18%, transparent);
}

/* custom dropdown chevron */
.ivf-field select {
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='none' stroke='%236B7280' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");
	background-repeat: no-repeat;
	background-position: right 16px center;
	padding-right: 44px;
	cursor: pointer;
}

.ivf-btn {
	width: 100%;
	border: 0;
	border-radius: 999px;
	padding: 16px 24px;
	margin-top: 6px;
	font-size: 16px;
	font-weight: 700;
	color: var(--ivf-btn-text);
	background: linear-gradient(90deg, var(--ivf-accent1), var(--ivf-accent2));
	cursor: pointer;
	transition: transform .15s, box-shadow .2s, opacity .2s;
	box-shadow: 0 8px 22px color-mix(in srgb, var(--ivf-accent1) 35%, transparent);
}
.ivf-btn:hover { transform: translateY(-1px); box-shadow: 0 12px 28px color-mix(in srgb, var(--ivf-accent1) 45%, transparent); }
.ivf-btn:disabled { opacity: .65; cursor: default; transform: none; }

.ivf-note {
	margin-top: 16px;
	padding: 13px 16px;
	border-radius: var(--ivf-radius);
	font-size: 14.5px;
	font-weight: 600;
}
.ivf-note--success { background: #E7F7EE; color: #14804A; border: 1px solid #B8E8CC; }
.ivf-note--error   { background: #FDECEC; color: #C0392B; border: 1px solid #F5C6C6; }

/* honeypot hidden from humans */
.ivf-hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

@media (max-width: 600px) {
	.ivf-form { padding: 24px 20px; }
	.ivf-title { font-size: 25px; }
}

@media (prefers-reduced-motion: reduce) {
	.ivf-btn { transition: none; }
	.ivf-btn:hover { transform: none; }
}

/* ============================ Choose Accordingly booking ============= */

.ivf-booking-trigger {
	width: 100%;
	display: flex;
	align-items: center;
	gap: 10px;
	background: var(--ivf-input-bg);
	color: var(--ivf-input-text);
	border: 1px solid var(--ivf-input-border);
	border-radius: var(--ivf-radius);
	padding: 14px 16px;
	font-size: 15px;
	font-family: inherit;
	cursor: pointer;
	text-align: left;
	transition: border-color .18s, box-shadow .18s;
}
.ivf-booking-trigger:hover { border-color: var(--ivf-accent1); }
.ivf-booking-trigger.has-value { border-color: var(--ivf-accent1); font-weight: 600; }
.ivf-booking-trigger__icon { display: flex; color: var(--ivf-accent1); flex-shrink: 0; }
.ivf-booking-trigger__icon svg { width: 20px; height: 20px; }
.ivf-booking-trigger__text { flex: 1; }
.ivf-booking-trigger:not(.has-value) .ivf-booking-trigger__text { color: #9A98B5; }
.ivf-booking-trigger__chevron { color: #9A98B5; font-size: 20px; }

.ivf-gcal-link {
	display: inline-block;
	margin-top: 8px;
	color: var(--ivf-accent1);
	font-weight: 700;
	text-decoration: underline;
}
.ivf-gcal-btn {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	margin-top: 12px;
	padding: 11px 20px;
	background: linear-gradient(90deg, var(--ivf-accent1), var(--ivf-accent2));
	color: #fff !important;
	font-weight: 700;
	font-size: 14px;
	text-decoration: none;
	border-radius: 999px;
	transition: transform .15s, box-shadow .2s;
	box-shadow: 0 6px 18px color-mix(in srgb, var(--ivf-accent1) 30%, transparent);
}
.ivf-gcal-btn::before {
	content: '';
	width: 16px; height: 16px; flex-shrink: 0;
	background: no-repeat center/contain url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23ffffff' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='4' width='18' height='18' rx='2'/%3E%3Cline x1='16' y1='2' x2='16' y2='6'/%3E%3Cline x1='8' y1='2' x2='8' y2='6'/%3E%3Cline x1='3' y1='10' x2='21' y2='10'/%3E%3C/svg%3E");
}
.ivf-gcal-btn:hover { transform: translateY(-1px); box-shadow: 0 10px 24px color-mix(in srgb, var(--ivf-accent1) 40%, transparent); }

/* popup */
.ivf-bkmodal {
	position: fixed;
	inset: 0;
	z-index: 100000;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 18px;
}
.ivf-bkmodal[hidden] { display: none; }
.ivf-bkmodal__backdrop { position: absolute; inset: 0; background: rgba(30,27,75,.32); }
.ivf-bkmodal__box {
	position: relative;
	z-index: 1;
	background: #fff;
	border-radius: 20px;
	width: 100%;
	max-width: 640px;
	max-height: 88vh;
	overflow-y: auto;
	padding: 26px 28px 22px;
	box-shadow: 0 24px 70px rgba(30,27,75,.35);
	animation: ivf-pop .2s ease;
	margin: auto;
}
@keyframes ivf-pop { from { transform: scale(.95); opacity: 0; } to { transform: scale(1); opacity: 1; } }
.ivf-bkmodal__close {
	position: absolute; top: 12px; right: 14px;
	width: 34px; height: 34px; border: 0; border-radius: 50%;
	background: #F2F3F9; color: #1E1B4B; font-size: 22px; line-height: 1; cursor: pointer;
}
.ivf-bkmodal__close:hover { background: #E6E7F2; }
.ivf-bkmodal__title { margin: 0 0 4px; color: #1E1B4B; font-size: 20px; font-weight: 800; }
.ivf-bkmodal__tz { margin: 0 0 14px; color: #7B7997; font-size: 13px; }

.ivf-bkmodal__grid { display: grid; grid-template-columns: 1.2fr 1fr; gap: 22px; margin-top: 12px; }

/* calendar */
.ivf-cal__nav { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.ivf-cal__title { font-weight: 700; color: #1E1B4B; font-size: 15px; }
.ivf-cal__navbtn {
	width: 34px; height: 34px; border: 1px solid var(--ivf-input-border);
	background: #fff; border-radius: 9px; cursor: pointer; font-size: 18px; color: #1E1B4B;
}
.ivf-cal__navbtn:hover { border-color: var(--ivf-accent1); color: var(--ivf-accent1); }
.ivf-cal__weekdays { display: grid; grid-template-columns: repeat(7,1fr); gap: 4px; margin-bottom: 6px; }
.ivf-cal__weekdays span { text-align: center; font-size: 11px; color: #9A98B5; font-weight: 600; text-transform: uppercase; }
.ivf-cal__days { display: grid; grid-template-columns: repeat(7,1fr); gap: 4px; }
.ivf-cal__day {
	aspect-ratio: 1;
	border: 0;
	background: #F5F6FB;
	border-radius: 9px;
	color: #1E1B4B;
	font-size: 14px;
	cursor: pointer;
	transition: background .15s, color .15s;
}
.ivf-cal__day:hover:not(:disabled) { background: color-mix(in srgb, var(--ivf-accent1) 15%, #fff); }
.ivf-cal__day.is-empty { background: transparent; cursor: default; }
.ivf-cal__day.is-disabled { color: #C7C9D9; background: transparent; cursor: not-allowed; }
.ivf-cal__day.is-selected { background: var(--ivf-accent1); color: #fff; font-weight: 700; }

/* time column */
.ivf-time { display: flex; flex-direction: column; }
.ivf-time__label { font-weight: 700; color: #1E1B4B; font-size: 14px; margin-bottom: 10px; }
.ivf-time__empty { color: #9A98B5; font-size: 14px; }

/* iPhone-style wheel */
.ivf-wheel {
	position: relative;
	height: 200px;   /* 5 items * 40px */
	overflow: hidden;
	-webkit-mask-image: linear-gradient(to bottom, transparent, #000 22%, #000 78%, transparent);
	        mask-image: linear-gradient(to bottom, transparent, #000 22%, #000 78%, transparent);
	cursor: grab;
	user-select: none;
	touch-action: none;
}
.ivf-wheel:active { cursor: grabbing; }
.ivf-wheel__highlight {
	position: absolute;
	left: 0; right: 0;
	top: 80px;      /* (200-40)/2 */
	height: 40px;
	border-top: 1px solid var(--ivf-input-border);
	border-bottom: 1px solid var(--ivf-input-border);
	background: color-mix(in srgb, var(--ivf-accent1) 8%, transparent);
	border-radius: 8px;
	pointer-events: none;
}
.ivf-wheel__list {
	list-style: none;
	margin: 0;
	padding: 80px 0 0;   /* push first item to the highlight line */
	transition: transform .18s cubic-bezier(.22,.61,.36,1);
}
.ivf-wheel__item {
	height: 40px;
	line-height: 40px;
	text-align: center;
	font-size: 17px;
	color: #1E1B4B;
	transition: opacity .15s, transform .15s;
}
.ivf-wheel__item.is-active { font-weight: 700; color: var(--ivf-accent1); transform: scale(1.06); }

/* footer */
.ivf-bkmodal__foot {
	display: flex; align-items: center; justify-content: space-between; gap: 14px;
	margin-top: 20px; padding-top: 16px; border-top: 1px solid #ECEDF5;
}
.ivf-bkmodal__chosen { color: #1E1B4B; font-weight: 700; font-size: 14px; }
.ivf-bkmodal__confirm {
	border: 0;
	border-radius: 999px;
	padding: 12px 30px;
	font-size: 15px;
	font-weight: 700;
	color: var(--ivf-btn-text);
	background: linear-gradient(90deg, var(--ivf-accent1), var(--ivf-accent2));
	cursor: pointer;
	transition: opacity .2s;
}
.ivf-bkmodal__confirm:disabled { opacity: .45; cursor: default; }

@media (max-width: 560px) {
	.ivf-bkmodal { padding: 10px; align-items: flex-end; }
	.ivf-bkmodal__box {
		padding: 20px 16px 16px;
		max-height: 92vh;
		border-radius: 18px;
	}
	.ivf-bkmodal__grid { grid-template-columns: 1fr; gap: 14px; }
	/* keep the footer (with Confirm) visible at the bottom */
	.ivf-bkmodal__foot {
		position: sticky;
		bottom: 0;
		background: #fff;
		flex-direction: column;
		align-items: stretch;
		gap: 10px;
		margin-top: 14px;
		padding-top: 14px;
		z-index: 2;
	}
	.ivf-bkmodal__chosen { text-align: center; }
	.ivf-bkmodal__confirm { width: 100%; padding: 14px; }
	/* time wheel a bit shorter so both calendar + wheel + confirm fit */
	.ivf-wheel { height: 160px; }
	.ivf-wheel__highlight { top: 60px; }
	.ivf-wheel__list { padding-top: 60px; }
}

/* ============================ UPI Payment popup ===================== */

.ivf-pay {
	position: fixed;
	inset: 0;
	z-index: 100001;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 18px;
}
.ivf-pay[hidden] { display: none; }
.ivf-pay__backdrop { position: absolute; inset: 0; background: rgba(30,27,75,.4); }
.ivf-pay__box {
	position: relative;
	z-index: 1;
	background: #fff;
	border-radius: 20px;
	width: 100%;
	max-width: 360px;
	max-height: 94vh;
	overflow-y: auto;
	padding: 20px 22px 18px;
	margin: auto;
	box-shadow: 0 24px 70px rgba(30,27,75,.4);
	animation: ivf-pop .2s ease;
	text-align: center;
}
.ivf-pay__close {
	position: absolute; top: 10px; right: 12px;
	width: 30px; height: 30px; border: 0; border-radius: 50%;
	background: #F2F3F9; color: #1E1B4B; font-size: 20px; line-height: 1; cursor: pointer;
}
.ivf-pay__close:hover { background: #E6E7F2; }
.ivf-pay__title { margin: 0 0 12px; color: #1E1B4B; font-size: 17px; font-weight: 800; }

.ivf-pay__amountline {
	display: flex; align-items: center; justify-content: space-between;
	background: #F5F6FB; border-radius: 10px; padding: 9px 14px; margin-bottom: 10px;
}
.ivf-pay__amountline span { color: #7B7997; font-weight: 600; font-size: 12.5px; }
.ivf-pay__amount { color: #1E1B4B; font-size: 19px; font-weight: 800; }

.ivf-pay__editamt { text-align: left; margin-bottom: 10px; }
.ivf-pay__editamt label { display: block; font-weight: 600; color: #1E1B4B; font-size: 12.5px; margin-bottom: 5px; }
.ivf-pay__editamt input {
	width: 100%; box-sizing: border-box; border: 1px solid var(--ivf-input-border);
	border-radius: 9px; padding: 9px 12px; font-size: 14px;
}

.ivf-pay__timer {
	display: inline-flex; align-items: center; gap: 6px;
	background: #EEF0FE; color: var(--ivf-accent1);
	padding: 5px 14px; border-radius: 999px; font-weight: 700; font-size: 14px;
	margin-bottom: 10px;
}
.ivf-pay__timer svg { width: 15px; height: 15px; }
.ivf-pay__timer.is-up { background: #FDECEC; color: #C0392B; animation: ivf-pulse 1s infinite; }
@keyframes ivf-pulse { 0%,100% { opacity: 1; } 50% { opacity: .55; } }

.ivf-pay__qrwrap { margin-bottom: 8px; }
.ivf-pay__qr {
	display: inline-block; padding: 9px; background: #fff;
	border: 1px solid #ECEDF5; border-radius: 13px; box-shadow: 0 4px 14px rgba(30,27,75,.08);
	line-height: 0;
}
.ivf-pay__qr img, .ivf-pay__qr canvas { display: block; border-radius: 5px; }
.ivf-pay__scan { color: #7B7997; font-size: 12px; margin: 7px 0 0; }

.ivf-pay__apps { display: flex; justify-content: center; gap: 18px; margin: 10px 0; }
.ivf-pay__app { display: flex; flex-direction: column; align-items: center; gap: 3px; }
.ivf-pay__app svg { width: 26px; height: 26px; }
.ivf-pay__app em { font-style: normal; font-size: 10.5px; color: #7B7997; font-weight: 600; }

.ivf-pay__openapp {
	display: none; /* shown only on touch devices via media query */
	width: 100%; box-sizing: border-box;
	background: linear-gradient(90deg, var(--ivf-accent1), var(--ivf-accent2));
	color: #fff; text-decoration: none; text-align: center;
	padding: 11px; border-radius: 999px; font-weight: 700; margin-bottom: 10px; font-size: 14px;
}

.ivf-pay__txn { text-align: left; margin-bottom: 10px; }
.ivf-pay__txn label { display: block; font-weight: 600; color: #1E1B4B; font-size: 12.5px; margin-bottom: 5px; line-height: 1.35; }
.ivf-pay__txn input {
	width: 100%; box-sizing: border-box; border: 1px solid var(--ivf-input-border);
	border-radius: 9px; padding: 9px 12px; font-size: 14px;
}
.ivf-pay__txn input.is-error { border-color: #E5484D; box-shadow: 0 0 0 3px rgba(229,72,77,.15); }

.ivf-pay__confirm {
	width: 100%; border: 0; border-radius: 999px;
	padding: 12px; font-size: 15px; font-weight: 700; color: #fff; cursor: pointer;
	background: linear-gradient(90deg, var(--ivf-accent1), var(--ivf-accent2));
	transition: transform .15s, box-shadow .2s;
	box-shadow: 0 6px 18px color-mix(in srgb, var(--ivf-accent1) 35%, transparent);
}
.ivf-pay__confirm:hover { transform: translateY(-1px); box-shadow: 0 10px 24px color-mix(in srgb, var(--ivf-accent1) 45%, transparent); }
.ivf-pay__hint { color: #9A98B5; font-size: 11.5px; margin: 9px 0 0; }

/* On phones, show the "open UPI app" button (deep link works there). */
@media (hover: none) and (pointer: coarse) {
	.ivf-pay__openapp { display: block; }
}

@media (max-width: 560px) {
	.ivf-pay { padding: 10px; align-items: center; }
	.ivf-pay__box {
		padding: 16px 16px 14px;
		max-height: 96vh;
		border-radius: 18px;
	}
	.ivf-pay__title { font-size: 16px; margin-bottom: 10px; }
	.ivf-pay__amountline { padding: 8px 12px; margin-bottom: 8px; }
	.ivf-pay__amount { font-size: 18px; }
	.ivf-pay__timer { margin-bottom: 8px; padding: 4px 12px; font-size: 13px; }
	.ivf-pay__qrwrap { margin-bottom: 6px; }
	.ivf-pay__qr { padding: 7px; }
	/* shrink the QR on small screens so the whole popup fits one screen */
	.ivf-pay__qr img, .ivf-pay__qr canvas { width: 132px !important; height: 132px !important; }
	.ivf-pay__scan { font-size: 11px; margin-top: 5px; }
	.ivf-pay__apps { gap: 14px; margin: 8px 0; }
	.ivf-pay__app svg { width: 24px; height: 24px; }
	.ivf-pay__txn { margin-bottom: 8px; }
	.ivf-pay__txn label { font-size: 12px; }
	.ivf-pay__confirm { padding: 11px; font-size: 14px; }
	.ivf-pay__hint { font-size: 11px; margin-top: 7px; }
}

@media (max-width: 400px) {
	.ivf-pay__box { padding: 14px 14px 12px; }
	.ivf-pay__apps { gap: 12px; }
}
