/* HETCO Forms — front end. Inherits the theme font; colours come from --hf-primary / --hf-accent. */
.hf-form {
	--hf-primary: #2563EB;
	--hf-accent: #0EA5E9;
	--hf-text: #1e293b;
	--hf-muted: #64748b;
	--hf-border: #e2e8f0;
	--hf-border-hover: #cbd5e1;
	--hf-bg: #fff;
	--hf-soft: #f8fafc;
	--hf-error: #dc2626;
	--hf-success: #16a34a;
	--hf-radius: 10px;
	--hf-primary-dark: color-mix(in srgb, var(--hf-primary) 82%, #000);
	--hf-ring: color-mix(in srgb, var(--hf-primary) 18%, transparent);
	position: relative;
	color: var(--hf-text);
	font-family: inherit;
	font-size: 15px;
	line-height: 1.55;
	max-width: 100%;
	-webkit-font-smoothing: antialiased;
}
.hf-form *, .hf-form *::before, .hf-form *::after { box-sizing: border-box; }

.hf-fields { display: flex; flex-wrap: wrap; gap: 22px 20px; }
.hf-field { flex: 0 0 100%; min-width: 0; margin: 0; }
.hf-w-half { flex-basis: calc(50% - 10px); }
.hf-w-third { flex-basis: calc(33.333% - 13.34px); }
@media (max-width: 640px) {
	.hf-w-half, .hf-w-third { flex-basis: 100%; }
}

/* Labels & help */
.hf-label {
	display: block;
	margin: 0 0 8px;
	font-size: 14px;
	font-weight: 500;
	line-height: 1.4;
	color: var(--hf-text);
}
.hf-star { color: var(--hf-error); margin-left: 3px; font-weight: 400; }
.hf-help { margin-top: 7px; font-size: 13px; line-height: 1.45; color: var(--hf-muted); }
.hf-section-title { margin: 10px 0 2px; font-size: 1.2em; font-weight: 600; color: var(--hf-text); letter-spacing: -.01em; }
.hf-section-desc { margin: 0; color: var(--hf-muted); font-size: 14px; }
.hf-type-section { padding-top: 6px; border-top: 1px solid var(--hf-border); }
.hf-fields > .hf-type-section:first-child { border-top: 0; padding-top: 0; }

/* Inputs */
.hf-form input[type="text"],
.hf-form input[type="email"],
.hf-form input[type="tel"],
.hf-form input[type="number"],
.hf-form input[type="url"],
.hf-form input[type="date"],
.hf-form input[type="time"],
.hf-form input[type="password"],
.hf-form select,
.hf-form textarea {
	display: block;
	width: 100%;
	min-height: 48px;
	margin: 0;
	padding: 11px 14px;
	font: inherit;
	font-size: 15px;
	line-height: 1.4;
	color: var(--hf-text);
	background: var(--hf-bg);
	border: 1px solid var(--hf-border);
	border-radius: var(--hf-radius);
	box-shadow: 0 1px 2px rgba(15, 23, 42, .04);
	outline: none;
	transition: border-color .15s ease, box-shadow .15s ease, background-color .15s ease;
	-webkit-appearance: none;
	appearance: none;
}
.hf-form textarea { min-height: 128px; resize: vertical; }
.hf-form input::placeholder,
.hf-form textarea::placeholder { color: #94a3b8; opacity: 1; }
.hf-form input:hover,
.hf-form select:hover,
.hf-form textarea:hover { border-color: var(--hf-border-hover); }
.hf-form input:focus,
.hf-form select:focus,
.hf-form textarea:focus {
	border-color: var(--hf-primary);
	box-shadow: 0 0 0 4px var(--hf-ring);
}
.hf-form input:disabled, .hf-form select:disabled, .hf-form textarea:disabled { background: var(--hf-soft); color: var(--hf-muted); cursor: not-allowed; }
/* Phones: 16px stops iOS from zooming into fields. */
@media (max-width: 640px) {
	.hf-form input, .hf-form select, .hf-form textarea { font-size: 16px !important; }
}

/* Valid state (set by JS after the visitor leaves a correct field) */
.hf-valid input[type="text"], .hf-valid input[type="email"], .hf-valid input[type="tel"], .hf-valid input[type="url"], .hf-valid input[type="number"] {
	padding-right: 40px;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='%2316a34a'%3E%3Cpath fill-rule='evenodd' d='M16.7 5.3a1 1 0 0 1 0 1.4l-8 8a1 1 0 0 1-1.4 0l-4-4a1 1 0 1 1 1.4-1.4L8 12.6l7.3-7.3a1 1 0 0 1 1.4 0z'/%3E%3C/svg%3E");
	background-repeat: no-repeat;
	background-position: right 14px center;
	background-size: 16px;
}
.hf-form[dir="rtl"] .hf-valid input { padding-right: 14px; padding-left: 40px; background-position: left 14px center; }

.hf-select-wrap { position: relative; }
.hf-select-wrap::after {
	content: "";
	position: absolute;
	right: 17px;
	top: 50%;
	width: 7px;
	height: 7px;
	border-right: 1.5px solid var(--hf-muted);
	border-bottom: 1.5px solid var(--hf-muted);
	transform: translateY(-70%) rotate(45deg);
	pointer-events: none;
}
.hf-form select { padding-right: 42px; cursor: pointer; }

/* Radio / checkbox */
.hf-choices { display: flex; flex-wrap: wrap; gap: 10px 22px; padding-top: 2px; }
.hf-choice {
	position: relative;
	display: inline-flex;
	align-items: flex-start;
	gap: 10px;
	cursor: pointer;
	font-size: 15px;
	line-height: 1.45;
	margin: 0;
	padding: 2px 0;
}
.hf-choice input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.hf-choice-mark {
	flex: 0 0 20px;
	width: 20px;
	height: 20px;
	margin-top: 1px;
	border: 1.5px solid #cbd5e1;
	border-radius: 6px;
	background: #fff;
	transition: background-color .15s, border-color .15s, box-shadow .15s;
	position: relative;
}
.hf-choice:hover .hf-choice-mark { border-color: var(--hf-primary); }
.hf-type-radio .hf-choice-mark { border-radius: 50%; }
.hf-choice input:checked + .hf-choice-mark { background: var(--hf-primary); border-color: var(--hf-primary); }
.hf-choice input:checked + .hf-choice-mark::after {
	content: "";
	position: absolute;
	left: 6px; top: 2px;
	width: 5px; height: 10px;
	border: solid #fff;
	border-width: 0 2px 2px 0;
	transform: rotate(45deg);
}
.hf-type-radio .hf-choice input:checked + .hf-choice-mark::after {
	left: 5px; top: 5px; width: 7px; height: 7px;
	border: 0; border-radius: 50%; background: #fff; transform: none;
}
.hf-choice input:focus-visible + .hf-choice-mark { box-shadow: 0 0 0 4px var(--hf-ring); }
.hf-consent .hf-choice-text { font-size: 14px; color: var(--hf-muted); }
.hf-consent a { color: var(--hf-primary); }

/* Errors */
.hf-error { display: none; align-items: center; gap: 6px; margin-top: 7px; font-size: 13px; color: var(--hf-error); }
.hf-error::before {
	content: "!";
	display: inline-grid; place-items: center;
	flex: 0 0 15px; width: 15px; height: 15px;
	border-radius: 50%;
	background: var(--hf-error); color: #fff;
	font-size: 10px; font-weight: 700; line-height: 1;
}
.hf-has-error .hf-error { display: flex; animation: hf-shake .32s ease; }
.hf-has-error input,
.hf-has-error select,
.hf-has-error textarea { border-color: var(--hf-error) !important; box-shadow: 0 0 0 4px color-mix(in srgb, var(--hf-error) 12%, transparent) !important; }
.hf-has-error .hf-choice-mark { border-color: var(--hf-error); }
@keyframes hf-shake { 0%, 100% { transform: none; } 25% { transform: translateX(-3px); } 75% { transform: translateX(3px); } }

/* Character counter */
.hf-counter { margin-top: 6px; font-size: 12px; color: var(--hf-muted); text-align: right; font-variant-numeric: tabular-nums; }
.hf-counter.is-near { color: #b45309; }

/* Submit */
.hf-submit-row { margin-top: 28px; display: flex; }
.hf-btn-center .hf-submit-row { justify-content: center; }
.hf-btn-right .hf-submit-row { justify-content: flex-end; }
.hf-btn-full .hf-submit { width: 100%; }
.hf-submit {
	position: relative;
	overflow: hidden;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 10px;
	min-height: 50px;
	padding: 0 30px;
	font: inherit;
	font-size: 15px;
	font-weight: 600;
	letter-spacing: .01em;
	color: #fff;
	background: var(--hf-primary);
	border: 0;
	border-radius: var(--hf-radius);
	cursor: pointer;
	isolation: isolate;
	box-shadow: 0 1px 2px rgba(15, 23, 42, .08), 0 6px 16px -8px color-mix(in srgb, var(--hf-primary) 60%, transparent);
	transition: transform .15s ease, box-shadow .2s ease, background-color .2s ease;
}
.hf-submit::before {
	content: "";
	position: absolute;
	inset: 0;
	z-index: -1;
	background: var(--hf-primary-dark);
	transform: translateX(-101%);
	transition: transform .4s cubic-bezier(.7, 0, .2, 1);
}
.hf-submit:hover::before,
.hf-submit:focus-visible::before { transform: translateX(0); }
.hf-submit:hover { transform: translateY(-1px); box-shadow: 0 2px 4px rgba(15, 23, 42, .08), 0 12px 24px -10px color-mix(in srgb, var(--hf-primary) 70%, transparent); }
.hf-submit:active { transform: translateY(0); }
.hf-submit:focus-visible { outline: 2px solid var(--hf-primary); outline-offset: 3px; }
.hf-submit[disabled] { opacity: .8; cursor: wait; transform: none; }
.hf-loading .hf-submit.hf-final::after {
	content: "";
	width: 16px; height: 16px;
	border: 2px solid rgba(255, 255, 255, .45);
	border-top-color: #fff;
	border-radius: 50%;
	animation: hf-spin .7s linear infinite;
}
@keyframes hf-spin { to { transform: rotate(360deg); } }

/* Messages */
.hf-message:empty { display: none; }
.hf-message {
	position: relative;
	margin-top: 18px;
	padding: 14px 18px 14px 50px;
	border-radius: var(--hf-radius);
	font-size: 15px;
	line-height: 1.55;
	animation: hf-up .3s ease both;
}
.hf-message::before {
	content: "";
	position: absolute;
	left: 16px; top: 15px;
	width: 22px; height: 22px;
	border-radius: 50%;
	background-repeat: no-repeat; background-position: center; background-size: 12px;
}
.hf-message.hf-ok { background: #f0fdf4; border: 1px solid #bbf7d0; color: #14532d; }
.hf-message.hf-ok::before { background-color: var(--hf-success); background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='%23fff'%3E%3Cpath fill-rule='evenodd' d='M16.7 5.3a1 1 0 0 1 0 1.4l-8 8a1 1 0 0 1-1.4 0l-4-4a1 1 0 1 1 1.4-1.4L8 12.6l7.3-7.3a1 1 0 0 1 1.4 0z'/%3E%3C/svg%3E"); }
.hf-message.hf-bad { background: #fef2f2; border: 1px solid #fecaca; color: #991b1b; }
.hf-message.hf-bad::before { content: "!"; display: grid; place-items: center; background-color: var(--hf-error); color: #fff; font-size: 13px; font-weight: 700; }
.hf-form[dir="rtl"] .hf-message { padding: 14px 50px 14px 18px; }
.hf-form[dir="rtl"] .hf-message::before { left: auto; right: 16px; }
@keyframes hf-up { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
.hf-done .hf-fields,
.hf-done .hf-submit-row { display: none; }
.hf-done .hf-message { margin-top: 0; padding-top: 22px; padding-bottom: 22px; font-size: 16px; }

/* Honeypot */
.hf-hp { position: absolute !important; left: -9999px !important; width: 1px; height: 1px; overflow: hidden; }

/* Dark backgrounds: [hetco_form id="1" class="hf-on-dark"] */
.hf-on-dark { --hf-text: #f1f5f9; --hf-muted: #94a3b8; --hf-border: rgba(241, 245, 249, .18); --hf-border-hover: rgba(241, 245, 249, .32); --hf-bg: rgba(255, 255, 255, .05); --hf-soft: rgba(255, 255, 255, .04); }
.hf-on-dark .hf-choice-mark { background: transparent; border-color: rgba(241, 245, 249, .4); }
.hf-on-dark .hf-submit { background: #fff; color: var(--hf-primary); }
.hf-on-dark .hf-submit::before { background: color-mix(in srgb, var(--hf-primary) 10%, #fff); }
.hf-on-dark select option { color: #1e293b; }
.hf-on-dark .hf-message.hf-ok { background: rgba(22, 163, 74, .12); border-color: rgba(22, 163, 74, .35); color: #dcfce7; }

@media (prefers-reduced-motion: reduce) {
	.hf-form *, .hf-form *::before, .hf-form *::after { transition: none !important; animation: none !important; }
}

/* ================= v1.1 ================= */
.hf-logic-hidden, .hf-form [hidden], .hf-modal [hidden] { display: none !important; }
.hf-type-hidden { display: none; }

/* Steps + progress */
.hf-step-title { margin: 0 0 18px; font-size: 1.2em; color: var(--hf-primary); }
.hf-progress { margin-bottom: 26px; }
.hf-progress-label { font-size: 12px; letter-spacing: .08em; text-transform: uppercase; color: var(--hf-muted); margin-bottom: 8px; }
.hf-progress-track { height: 4px; background: var(--hf-border); border-radius: 99px; overflow: hidden; }
.hf-progress-fill { height: 100%; width: 0; background: var(--hf-accent); border-radius: 99px; transition: width .45s cubic-bezier(.7,0,.2,1); }
.hf-progress-steps { display: flex; gap: 8px; list-style: none; margin: 0; padding: 0; counter-reset: none; }
.hf-progress-steps li { flex: 1; display: flex; align-items: center; gap: 8px; font-size: 13px; color: var(--hf-muted); position: relative; padding-bottom: 10px; border-bottom: 2px solid var(--hf-border); transition: border-color .3s, color .3s; }
.hf-progress-steps li span { display: inline-grid; place-items: center; width: 24px; height: 24px; border-radius: 50%; border: 1.5px solid var(--hf-border); font-size: 12px; flex: 0 0 24px; transition: all .3s; }
.hf-progress-steps li em { font-style: normal; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hf-progress-steps li.is-active { color: var(--hf-text); border-color: var(--hf-accent); }
.hf-progress-steps li.is-active span { border-color: var(--hf-accent); color: var(--hf-accent); }
.hf-progress-steps li.is-done { border-color: var(--hf-primary); }
.hf-progress-steps li.is-done span { background: var(--hf-primary); border-color: var(--hf-primary); color: #fff; }
@media (max-width: 560px) { .hf-progress-steps li em { display: none; } }
.hf-step.is-active { animation: hf-in .35s ease both; }
@keyframes hf-in { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
.hf-prev { background: none; border: 0; font: inherit; font-size: 15px; color: var(--hf-muted); cursor: pointer; padding: 0 18px; min-height: 52px; }
.hf-prev:hover { color: var(--hf-primary); }
.hf-multi .hf-submit-row { gap: 6px; align-items: center; }
.hf-multi.hf-btn-left .hf-submit-row, .hf-multi.hf-btn-full .hf-submit-row { justify-content: space-between; }
.hf-multi .hf-prev[hidden] + .hf-next, .hf-multi .hf-prev[hidden] ~ .hf-final { margin-left: auto; }

/* Phone with country code */
.hf-phone { display: flex; gap: 8px; }
.hf-phone .hf-cc { flex: 0 0 118px; }
.hf-phone .hf-cc select { padding-right: 34px; }
.hf-phone input { flex: 1; min-width: 0; }

/* File upload */
.hf-file { position: relative; display: block; cursor: pointer; }
.hf-file input[type=file] { position: absolute; inset: 0; opacity: 0; cursor: pointer; width: 100%; }
.hf-file-ui { display: flex; align-items: center; gap: 12px; min-height: 56px; padding: 10px 14px; border: 1.5px dashed var(--hf-border); border-radius: var(--hf-radius); background: var(--hf-bg); transition: border-color .2s, background .2s; }
.hf-file:hover .hf-file-ui, .hf-file input:focus-visible + .hf-file-ui { border-color: var(--hf-accent); }
.hf-file.has-file .hf-file-ui { border-style: solid; border-color: var(--hf-accent); }
.hf-file-btn { flex: 0 0 auto; padding: 7px 14px; border-radius: 99px; background: color-mix(in srgb, var(--hf-primary) 8%, transparent); color: var(--hf-primary); font-size: 13px; font-weight: 500; }
.hf-file-names { font-size: 13px; color: var(--hf-muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* Calculation */
.hf-calc { display: flex; align-items: baseline; gap: 6px; padding: 14px 18px; border-radius: var(--hf-radius); background: color-mix(in srgb, var(--hf-accent) 9%, transparent); }
.hf-calc-value { font-size: 1.6em; font-weight: 600; color: var(--hf-primary); font-variant-numeric: tabular-nums; }
.hf-calc-prefix, .hf-calc-suffix { color: var(--hf-muted); }

/* Payment */
.hf-pay { display: grid; gap: 14px; }
.hf-pay-total { font-size: 14px; color: var(--hf-muted); }
.hf-pay-amount { color: var(--hf-primary); }
.hf-pay-amount b { font-size: 1.5em; font-variant-numeric: tabular-nums; }
.hf-pay-methods .hf-choice { padding: 12px 16px; border: 1px solid var(--hf-border); border-radius: var(--hf-radius); align-items: center; }
.hf-pay-methods .hf-choice:has(input:checked) { border-color: var(--hf-primary); box-shadow: inset 0 0 0 1px var(--hf-primary); }
.hf-pay-details { padding: 14px 16px; border-radius: var(--hf-radius); background: color-mix(in srgb, var(--hf-accent) 9%, transparent); font-size: 14px; line-height: 1.7; white-space: normal; }
.hf-pay-fields { display: grid; gap: 8px; }
.hf-pay-fields .hf-label { margin: 6px 0 0; }

/* Turnstile */
.hf-turnstile { margin-top: 20px; min-height: 65px; }

/* Closed */
.hf-closed .hf-message { margin: 0; }

/* ----- Style: underline (minimal) ----- */
.hf-style-underline input[type="text"], .hf-style-underline input[type="email"], .hf-style-underline input[type="tel"],
.hf-style-underline input[type="number"], .hf-style-underline input[type="url"], .hf-style-underline input[type="date"],
.hf-style-underline select, .hf-style-underline textarea {
	border-width: 0 0 1.5px; border-radius: 0; background: transparent; padding-left: 0; padding-right: 0;
}
.hf-style-underline select { padding-right: 30px; }
.hf-style-underline .hf-select-wrap::after { right: 6px; }
.hf-style-underline input:focus, .hf-style-underline select:focus, .hf-style-underline textarea:focus { box-shadow: 0 1.5px 0 0 var(--hf-accent); }
.hf-style-underline textarea { min-height: 90px; }
.hf-style-underline .hf-label { font-size: 12px; letter-spacing: .08em; text-transform: uppercase; color: var(--hf-muted); }
.hf-style-underline .hf-fields { gap: 28px 24px; }

/* ----- Style: boxed (cards) ----- */
.hf-style-boxed .hf-field:not(.hf-type-section):not(.hf-type-html):not(.hf-type-hidden) {
	padding: 16px 18px 18px; background: var(--hf-bg); border: 1px solid var(--hf-border); border-radius: calc(var(--hf-radius) + 4px);
	transition: border-color .2s, box-shadow .2s;
}
.hf-style-boxed .hf-field:focus-within { border-color: var(--hf-accent); box-shadow: 0 8px 24px -18px color-mix(in srgb, var(--hf-primary) 60%, transparent); }
.hf-style-boxed .hf-field input[type="text"], .hf-style-boxed .hf-field input[type="email"], .hf-style-boxed .hf-field input[type="tel"],
.hf-style-boxed .hf-field input[type="number"], .hf-style-boxed .hf-field input[type="url"], .hf-style-boxed .hf-field input[type="date"],
.hf-style-boxed .hf-field select, .hf-style-boxed .hf-field textarea { border-color: transparent; background: color-mix(in srgb, var(--hf-border) 35%, transparent); }
.hf-style-boxed .hf-field input:focus, .hf-style-boxed .hf-field select:focus, .hf-style-boxed .hf-field textarea:focus { background: var(--hf-bg); }
.hf-style-boxed .hf-fields { gap: 14px; }
.hf-style-boxed .hf-w-half { flex-basis: calc(50% - 7px); }
.hf-style-boxed .hf-w-third { flex-basis: calc(33.333% - 9.34px); }

/* ----- RTL (Urdu) ----- */
.hf-form[dir="rtl"] { text-align: right; }
.hf-form[dir="rtl"] .hf-star { margin-left: 0; margin-right: 3px; }
.hf-form[dir="rtl"] .hf-select-wrap::after { right: auto; left: 18px; }
.hf-form[dir="rtl"] select { padding-right: 16px; padding-left: 44px; }
.hf-form[dir="rtl"] .hf-choice input:checked + .hf-choice-mark::after { left: auto; right: 6px; }
.hf-form[dir="rtl"] .hf-type-radio .hf-choice input:checked + .hf-choice-mark::after { right: 5px; }
.hf-form[dir="rtl"] .hf-submit::before { transform: translateX(101%); }
.hf-form[dir="rtl"] .hf-submit:hover::before { transform: translateX(0); }
.hf-form[dir="rtl"] .hf-btn-left .hf-submit-row, .hf-form[dir="rtl"].hf-btn-left .hf-submit-row { justify-content: flex-start; }
.hf-form[dir="rtl"] .hf-phone { direction: ltr; } /* numbers read left to right */
.hf-form[dir="rtl"] .hf-phone input { text-align: left; }
.hf-form[dir="rtl"] input[type="email"], .hf-form[dir="rtl"] input[type="url"], .hf-form[dir="rtl"] input[type="number"] { direction: ltr; text-align: right; }
.hf-form[dir="rtl"] .hf-multi .hf-prev[hidden] + .hf-next, .hf-form[dir="rtl"].hf-multi .hf-prev[hidden] + .hf-next,
.hf-form[dir="rtl"].hf-multi .hf-prev[hidden] ~ .hf-final { margin-left: 0; margin-right: auto; }
.hf-form[dir="rtl"] .hf-style-underline .hf-select-wrap::after, .hf-form[dir="rtl"].hf-style-underline .hf-select-wrap::after { left: 6px; }

/* ================= v1.2 ================= */
.screen-reader-text { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(1px,1px,1px,1px); white-space: nowrap; }
.hf-hide-calc { display: none !important; }
.hf-choice.hf-sold { opacity: .45; cursor: not-allowed; }

/* Address */
.hf-address { display: flex; flex-wrap: wrap; gap: 10px; }
.hf-addr { flex: 0 0 100%; min-width: 0; }
.hf-addr.hf-w-half { flex-basis: calc(50% - 5px); }
@media (max-width: 560px) { .hf-addr.hf-w-half { flex-basis: 100%; } }

/* Password */
.hf-password { position: relative; }
.hf-password input { padding-right: 70px !important; }
.hf-pw-toggle { position: absolute; right: 8px; top: 50%; transform: translateY(-50%); border: 0; background: none; color: var(--hf-muted); font: inherit; font-size: 13px; cursor: pointer; padding: 6px 8px; }
.hf-form[dir="rtl"] .hf-password input { padding-right: 16px !important; padding-left: 70px !important; }
.hf-form[dir="rtl"] .hf-pw-toggle { right: auto; left: 8px; }

/* Rating (stars; inputs are reversed so :checked ~ label fills) */
.hf-rating { display: inline-flex; flex-direction: row-reverse; gap: 4px; }
.hf-rating input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.hf-rating label { cursor: pointer; line-height: 0; }
.hf-rating svg { width: 32px; height: 32px; fill: transparent; stroke: #cbd5e1; stroke-width: 1.5; transition: fill .15s, stroke .15s, transform .15s; }
.hf-rating label:hover svg, .hf-rating label:hover ~ label svg, .hf-rating input:checked ~ label svg { fill: var(--hf-accent); stroke: var(--hf-accent); }
.hf-rating label:hover svg { transform: scale(1.1); }
.hf-rating input:focus-visible + label svg { outline: 2px solid var(--hf-accent); outline-offset: 2px; border-radius: 4px; }
.hf-form[dir="rtl"] .hf-rating { flex-direction: row; }

/* NPS */
.hf-nps-row { display: grid; grid-template-columns: repeat(11, 1fr); gap: 4px; }
.hf-nps label { cursor: pointer; }
.hf-nps input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.hf-nps span { display: grid; place-items: center; height: 42px; border: 1px solid var(--hf-border); border-radius: 8px; font-size: 14px; background: var(--hf-bg); transition: all .15s; }
.hf-nps label:hover span { border-color: var(--hf-accent); }
.hf-nps input:checked + span { background: var(--hf-primary); border-color: var(--hf-primary); color: #fff; }
.hf-nps input:focus-visible + span { box-shadow: 0 0 0 3px color-mix(in srgb, var(--hf-accent) 30%, transparent); }
.hf-nps-legend { display: flex; justify-content: space-between; font-size: 12px; color: var(--hf-muted); margin-top: 6px; }
@media (max-width: 480px) { .hf-nps span { height: 34px; font-size: 12px; } }

/* Range */
.hf-range { display: flex; align-items: center; gap: 16px; }
.hf-range input[type=range] { flex: 1; accent-color: var(--hf-primary); height: 30px; }
.hf-range-out { min-width: 64px; text-align: center; font-weight: 600; color: var(--hf-primary); padding: 6px 10px; border-radius: 8px; background: color-mix(in srgb, var(--hf-accent) 10%, transparent); font-variant-numeric: tabular-nums; }

/* Colour */
.hf-color { width: 64px; height: 44px; padding: 3px; border: 1px solid var(--hf-border); border-radius: var(--hf-radius); background: var(--hf-bg); cursor: pointer; }

/* Grid */
.hf-grid-wrap { overflow-x: auto; }
.hf-grid { width: 100%; border-collapse: separate; border-spacing: 0; font-size: 14px; }
.hf-grid th, .hf-grid td { padding: 10px 8px; text-align: center; border-bottom: 1px solid var(--hf-border); }
.hf-grid thead th { font-weight: 500; font-size: 13px; color: var(--hf-muted); }
.hf-grid tbody th { text-align: left; font-weight: 500; }
.hf-grid .hf-choice { justify-content: center; }
.hf-grid td .hf-choice-mark { margin: 0; }
.hf-type-grid .hf-grid input[type=radio] + .hf-choice-mark { border-radius: 50%; }
.hf-type-grid .hf-grid input[type=radio]:checked + .hf-choice-mark::after { left: 5px; top: 5px; width: 7px; height: 7px; border: 0; border-radius: 50%; background: #fff; transform: none; }
.hf-form[dir="rtl"] .hf-grid tbody th { text-align: right; }

/* Repeater */
.hf-rep-head, .hf-rep-row { display: grid; grid-template-columns: var(--hf-rep-cols, minmax(0, 1fr) 36px); gap: 8px; align-items: center; }
.hf-rep-head { font-size: 12px; color: var(--hf-muted); margin-bottom: 6px; }
.hf-rep-row + .hf-rep-row { margin-top: 8px; }
.hf-rep-del { border: 0; background: none; font-size: 22px; line-height: 1; color: var(--hf-muted); cursor: pointer; height: 44px; }
.hf-rep-del:hover { color: var(--hf-error); }
.hf-rep-add { margin-top: 10px; border: 1px dashed var(--hf-border); background: none; color: var(--hf-primary); padding: 9px 16px; border-radius: 99px; font: inherit; font-size: 14px; cursor: pointer; }
.hf-rep-add:hover { border-color: var(--hf-accent); }

/* Coupon */
.hf-coupon { display: flex; gap: 8px; }
.hf-coupon input { flex: 1; text-transform: uppercase; letter-spacing: .06em; }
.hf-coupon-apply { flex: 0 0 auto; border: 1px solid var(--hf-primary); color: var(--hf-primary); background: none; border-radius: var(--hf-radius); padding: 0 20px; font: inherit; font-size: 14px; cursor: pointer; }
.hf-coupon-apply:hover { background: var(--hf-primary); color: #fff; }
.hf-coupon-msg { font-size: 13px; margin-top: 6px; }
.hf-coupon-msg.is-ok { color: #2e7d32; }
.hf-coupon-msg.is-bad { color: var(--hf-error); }
.hf-pay-amount s { opacity: .5; font-weight: 400; font-size: .75em; margin-right: 4px; }

/* Save & resume */
.hf-resume-row { margin-top: 14px; }
.hf-save-later { border: 0; background: none; padding: 0; font: inherit; font-size: 14px; color: var(--hf-muted); text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.hf-save-later:hover { color: var(--hf-primary); }
.hf-resume-box { margin-top: 10px; padding: 14px 16px; border-radius: var(--hf-radius); background: color-mix(in srgb, var(--hf-accent) 9%, transparent); font-size: 14px; }
.hf-resume-box p { margin: 0 0 8px; }
.hf-resume-link { display: flex; gap: 6px; }
.hf-resume-link input { flex: 1; min-height: 40px !important; font-size: 13px !important; }
.hf-copy-link { border: 0; background: var(--hf-primary); color: #fff; border-radius: 8px; padding: 0 16px; cursor: pointer; font: inherit; font-size: 13px; }
.hf-done .hf-resume-row { display: none; }

/* Popup */
.hf-popup-btn { display: inline-flex; align-items: center; justify-content: center; min-height: 50px; padding: 0 30px; border: 0; border-radius: 10px; background: var(--hf-primary, #2563EB); color: #fff; font: inherit; font-size: 15px; font-weight: 600; letter-spacing: .01em; cursor: pointer; transition: transform .2s, box-shadow .2s; }
.hf-popup-btn:hover { transform: translateY(-1px); box-shadow: 0 10px 24px -12px rgba(37, 99, 235,.6); }
dialog.hf-modal { border: 0; padding: 0; border-radius: 18px; width: min(680px, calc(100vw - 24px)); max-height: calc(100vh - 32px); overflow: auto; box-shadow: 0 30px 80px -20px rgba(0,0,0,.4); }
dialog.hf-modal::backdrop { background: rgba(15, 23, 42, .55); backdrop-filter: blur(3px); }
dialog.hf-modal[open] { animation: hf-pop .28s cubic-bezier(.2,.8,.2,1); }
@keyframes hf-pop { from { opacity: 0; transform: translateY(14px) scale(.98); } to { opacity: 1; transform: none; } }
.hf-modal-inner { position: relative; padding: clamp(22px, 5vw, 40px); }
.hf-modal-title { margin: 0 40px 20px 0; font-size: 1.35em; font-weight: 600; color: #0f172a; letter-spacing: -.01em; }
.hf-modal-close { position: absolute; top: 14px; right: 14px; width: 36px; height: 36px; border: 0; border-radius: 50%; background: #f1f5f9; font-size: 22px; line-height: 1; cursor: pointer; color: #475569; }
.hf-modal-close:hover { background: #e2e8f0; }
.hf-pay-methods .hf-choice-mark { border-radius: 50%; }
.hf-pay-methods .hf-choice input:checked + .hf-choice-mark::after { left: 5px; top: 5px; width: 7px; height: 7px; border: 0; border-radius: 50%; background: #fff; transform: none; }
.hf-done .hf-progress { display: none; }
.hf-hcaptcha { margin-top: 20px; min-height: 78px; }
.hf-recaptcha-note { font-size: 11.5px; color: var(--hf-muted); margin: 14px 0 0; }
.hf-recaptcha-note a { color: inherit; }
.grecaptcha-badge { visibility: hidden; }
.hf-progress { margin-bottom: 30px; }
.hf-progress-steps li { padding-bottom: 12px; }

/* ================= Phone flag picker (intl-tel-input) ================= */
.hf-form .iti, .hf-iti { --iti-border-color: var(--hf-border); --iti-hover-color: rgba(37, 99, 235, .06); --iti-icon-color: var(--hf-muted); --iti-dropdown-bg: #fff; --iti-arrow-color: var(--hf-muted); width: 100%; display: block; }
.hf-phone .iti { flex: 1; min-width: 0; }
.hf-form .iti__country-container { padding: 3px; }
.hf-form .iti__selected-country { border-radius: calc(var(--hf-radius) - 3px); padding: 0 6px 0 10px; transition: background-color .15s; }
.hf-form .iti__selected-country:hover, .hf-form .iti__selected-country:focus-visible { background: var(--hf-soft); }
.hf-form .iti__selected-dial-code { color: var(--hf-text); font-size: 15px; margin-left: 6px; }
.hf-form .iti__flag { border-radius: 2px; box-shadow: 0 0 0 1px rgba(15, 23, 42, .08); }
.hf-form .iti__dropdown-content {
	border: 1px solid var(--hf-border);
	border-radius: var(--hf-radius);
	box-shadow: 0 16px 40px -12px rgba(15, 23, 42, .25);
	margin-top: 6px;
	overflow: hidden;
	color: var(--hf-text);
	z-index: 50;
}
.hf-form .iti__search-input {
	min-height: 42px !important;
	border: 0 !important;
	border-bottom: 1px solid var(--hf-border) !important;
	border-radius: 0 !important;
	box-shadow: none !important;
	font-size: 14px !important;
}
.hf-form .iti__country { padding: 9px 12px; font-size: 14px; }
.hf-form .iti__country.iti__highlight { background: #eff6ff; }
.hf-form .iti__dial-code { color: var(--hf-muted); }
.hf-form .iti input[type="tel"] { width: 100%; }
.hf-on-dark .iti__dropdown-content { color: #1e293b; }
.hf-on-dark .iti__selected-dial-code { color: var(--hf-text); }
/* The library places the dial code on the left; keep it LTR inside RTL (Urdu) forms. */
.hf-form[dir="rtl"] .iti { direction: ltr; }
.hf-form .iti__search-input { padding-left: 38px !important; padding-right: 36px !important; }
.hf-form[dir="rtl"] .iti__search-input { text-align: left; }

/* ================= v1.5 expert UX pass ================= */
.hf-sr { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(1px,1px,1px,1px); white-space: nowrap; }

/* Required/optional: when most fields are required, label the optional ones instead */
.hf-mark-optional .hf-star { display: none; }
.hf-optional { margin-left: 8px; font-size: 12px; font-weight: 400; color: var(--hf-muted); }
.hf-form[dir="rtl"] .hf-optional { margin-left: 0; margin-right: 8px; }

/* Empty select reads as a placeholder */
.hf-form select:has(option[value=""]:checked) { color: #94a3b8; }
.hf-form select option { color: var(--hf-text); }

/* Choice layouts */
.hf-layout-stack { flex-direction: column; gap: 4px; }
.hf-layout-stack .hf-choice { width: 100%; padding: 9px 12px; margin: 0 -12px; width: calc(100% + 24px); border-radius: 8px; transition: background-color .15s; }
.hf-layout-stack .hf-choice:hover { background: var(--hf-soft); }
.hf-layout-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 10px; }
.hf-layout-cards .hf-choice {
	align-items: center;
	padding: 14px 16px;
	min-height: 52px;
	border: 1px solid var(--hf-border);
	border-radius: var(--hf-radius);
	background: var(--hf-bg);
	transition: border-color .15s, box-shadow .15s, background-color .15s;
}
.hf-layout-cards .hf-choice:hover { border-color: var(--hf-border-hover); }
.hf-layout-cards .hf-choice:has(input:checked) { border-color: var(--hf-primary); box-shadow: 0 0 0 1px var(--hf-primary); background: color-mix(in srgb, var(--hf-primary) 4%, var(--hf-bg)); }
.hf-layout-cards .hf-choice:has(input:focus-visible) { box-shadow: 0 0 0 4px var(--hf-ring); }
.hf-layout-cards .hf-choice-mark { margin-top: 0; }
@media (max-width: 640px) {
	.hf-choices.hf-layout-inline { flex-direction: column; gap: 6px; }
	.hf-choice { min-height: 32px; }
}

/* Steps: direction-aware transitions, clickable completed steps */
.hf-step.hf-in-fwd { animation: hf-in-fwd .32s cubic-bezier(.2,.8,.2,1) both; }
.hf-step.hf-in-back { animation: hf-in-back .32s cubic-bezier(.2,.8,.2,1) both; }
@keyframes hf-in-fwd { from { opacity: 0; transform: translateX(18px); } to { opacity: 1; transform: none; } }
@keyframes hf-in-back { from { opacity: 0; transform: translateX(-18px); } to { opacity: 1; transform: none; } }
.hf-progress-steps li.is-done { cursor: pointer; }
.hf-progress-steps li.is-done:hover em { color: var(--hf-primary); }
.hf-progress-label { font-weight: 500; letter-spacing: .04em; }

/* Submit: sent state */
.hf-submit.is-sent { background: var(--hf-success) !important; }
.hf-submit.is-sent::before { display: none; }
.hf-submit.is-sent .hf-submit-text { font-size: 0; }
.hf-submit.is-sent .hf-submit-text::after { content: "✓  " attr(data-sent); font-size: 15px; }
.hf-submit.is-sent .hf-submit-text::before { content: ""; }

/* File dropzone */
.hf-dropzone .hf-file-ui { min-height: 76px; padding: 14px 16px; gap: 14px; border-style: dashed; border-width: 1.5px; background: var(--hf-soft); }
.hf-dropzone:hover .hf-file-ui, .hf-dropzone.is-drag .hf-file-ui { border-color: var(--hf-primary); background: color-mix(in srgb, var(--hf-primary) 5%, var(--hf-bg)); }
.hf-dropzone.is-drag .hf-file-ui { box-shadow: 0 0 0 4px var(--hf-ring); }
.hf-file-icon { flex: 0 0 38px; width: 38px; height: 38px; border-radius: 10px; background: color-mix(in srgb, var(--hf-primary) 10%, transparent) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%232563EB' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M12 16V4M7 9l5-5 5 5M4 16v3a1 1 0 0 0 1 1h14a1 1 0 0 0 1-1v-3'/%3E%3C/svg%3E") center / 20px no-repeat; }
.hf-file-text { display: flex; flex-direction: column; gap: 2px; min-width: 0; flex: 1; }
.hf-dropzone .hf-file-btn { padding: 0; background: none; color: var(--hf-text); font-weight: 500; font-size: 14px; border-radius: 0; }
.hf-dropzone.has-file .hf-file-btn { color: var(--hf-success); }
.hf-dropzone .hf-file-names { white-space: normal; font-size: 12.5px; }
.hf-file-thumbs { display: flex; align-items: center; gap: 6px; position: relative; z-index: 2; }
.hf-file-thumbs img { width: 40px; height: 40px; object-fit: cover; border-radius: 8px; box-shadow: 0 0 0 1px var(--hf-border); }
.hf-file-clear { width: 28px; height: 28px; border: 0; border-radius: 50%; background: var(--hf-bg); box-shadow: 0 0 0 1px var(--hf-border); color: var(--hf-muted); font-size: 18px; line-height: 1; cursor: pointer; }
.hf-file-clear:hover { color: var(--hf-error); }
.hf-dropzone input[type=file] { z-index: 1; }

/* Textareas grow with content */
.hf-form textarea { overflow-y: hidden; transition: border-color .15s ease, box-shadow .15s ease, height .1s ease; }

/* Tap targets & rhythm */
.hf-form .hf-choice-mark { flex-basis: 20px; }
.hf-type-consent .hf-choice { align-items: flex-start; }
.hf-step-title { font-size: 1.15em; font-weight: 600; color: var(--hf-text); letter-spacing: -.01em; margin-bottom: 20px; }
