/* Pay-Form Smart - front-end form. Colors come from CSS variables set in the backend. */
.ahpf-wrap {
	--ahpf-primary: #2563eb; --ahpf-primary-text: #fff; --ahpf-bg: #fff; --ahpf-text: #1f2937; --ahpf-muted: #6b7280;
	--ahpf-border: #d1d5db; --ahpf-input-bg: #fff; --ahpf-success: #15803d; --ahpf-error: #b91c1c; --ahpf-radius: 8px;
	font-family: inherit; color: var(--ahpf-text); max-width: 720px; margin: 0 auto; box-sizing: border-box;
}
.ahpf-wrap *, .ahpf-wrap *::before, .ahpf-wrap *::after { box-sizing: border-box; }
.ahpf-card {
	background: var(--ahpf-bg); border: 1px solid var(--ahpf-border); border-radius: calc(var(--ahpf-radius) * 1.5);
	padding: clamp(20px, 4vw, 36px); box-shadow: 0 1px 2px rgba(0,0,0,.04), 0 8px 24px rgba(0,0,0,.05);
	border-top: 5px solid var(--ahpf-primary);
}
.ahpf-head { margin-bottom: 24px; }
.ahpf-title { margin: 0 0 6px; font-size: 1.6em; line-height: 1.25; color: var(--ahpf-text); }
.ahpf-meta { margin: 0 0 12px; color: var(--ahpf-muted); font-size: .95em; display: flex; flex-wrap: wrap; gap: 4px 18px; }
.ahpf-meta-item::before { content: "\2022"; color: var(--ahpf-primary); margin-right: 8px; }
.ahpf-desc { color: var(--ahpf-text); line-height: 1.6; }
.ahpf-desc p { margin: 0 0 .8em; }
.ahpf-badge {
	display: inline-block; margin: 6px 0 0; padding: 4px 12px; border-radius: 999px; font-size: .85em; font-weight: 600;
	background: color-mix(in srgb, var(--ahpf-success) 12%, transparent); color: var(--ahpf-success);
}
.ahpf-badge-full { background: color-mix(in srgb, var(--ahpf-error) 12%, transparent); color: var(--ahpf-error); }

.ahpf-price { margin: 10px 0 0; color: var(--ahpf-text); font-size: 1.05em; }
.ahpf-price strong { color: var(--ahpf-primary); font-size: 1.2em; }
.ahpf-total {
	justify-content: flex-start; gap: 2px; padding: 10px 14px; border-radius: var(--ahpf-radius);
	background: color-mix(in srgb, var(--ahpf-primary) 7%, transparent); border: 1px solid color-mix(in srgb, var(--ahpf-primary) 20%, transparent);
}
.ahpf-total-label { font-weight: 600; font-size: .85em; color: var(--ahpf-muted); }
.ahpf-total-value { font-size: 1.35em; color: var(--ahpf-text); line-height: 1.2; font-variant-numeric: tabular-nums; }
.ahpf-total-lines { display: flex; flex-direction: column; gap: 1px; margin-top: 4px; }
.ahpf-total-lines:empty { display: none; }
.ahpf-line { display: flex; justify-content: space-between; gap: 12px; font-size: .8em; color: var(--ahpf-muted); font-variant-numeric: tabular-nums; }
.ahpf-line > span:last-child { white-space: nowrap; }
.ahpf-surcharge-note { margin: 2px 0 0; color: var(--ahpf-muted); font-size: .9em; }
.ahpf-extras { border: 0; margin: 0; padding: 0; min-width: 0; display: flex; flex-direction: column; gap: 8px; }
.ahpf-extras legend { font-weight: 600; font-size: .92em; margin-bottom: 8px; padding: 0; }
.ahpf-extra {
	display: flex; gap: 10px; align-items: flex-start; padding: 10px 12px; border: 1px solid var(--ahpf-border);
	border-radius: var(--ahpf-radius); background: var(--ahpf-input-bg); cursor: pointer;
}
.ahpf-extra:has(input:checked) { border-color: var(--ahpf-primary); background: color-mix(in srgb, var(--ahpf-primary) 6%, var(--ahpf-input-bg)); }
.ahpf-extra input { margin-top: 4px; accent-color: var(--ahpf-primary); }
.ahpf-extra-price { color: var(--ahpf-muted); white-space: nowrap; }
.ahpf-ref[hidden] { display: none; }
.ahpf-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px 18px; }
.ahpf-col-full { grid-column: 1 / -1; }
@media (max-width: 560px) { .ahpf-grid { grid-template-columns: 1fr; } }

.ahpf-field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.ahpf-field > label { font-weight: 600; font-size: .92em; color: var(--ahpf-text); }
.ahpf-req { color: var(--ahpf-error); }
.ahpf-field input[type=text], .ahpf-field input[type=email], .ahpf-field input[type=tel], .ahpf-field input[type=number], .ahpf-field input[type=date], .ahpf-field select, .ahpf-field textarea {
	width: 100%; padding: 11px 13px; font: inherit; font-size: 1em; color: var(--ahpf-text); background: var(--ahpf-input-bg);
	border: 1px solid var(--ahpf-border); border-radius: var(--ahpf-radius); transition: border-color .15s, box-shadow .15s; margin: 0;
	-webkit-appearance: none; appearance: none; line-height: 1.4;
}
.ahpf-field select {
	background-image: linear-gradient(45deg, transparent 50%, var(--ahpf-muted) 50%), linear-gradient(135deg, var(--ahpf-muted) 50%, transparent 50%);
	background-position: calc(100% - 18px) 50%, calc(100% - 13px) 50%; background-size: 5px 5px; background-repeat: no-repeat; padding-right: 36px;
}
.ahpf-field textarea { resize: vertical; min-height: 100px; }
.ahpf-field input:focus, .ahpf-field select:focus, .ahpf-field textarea:focus {
	outline: none; border-color: var(--ahpf-primary); box-shadow: 0 0 0 3px color-mix(in srgb, var(--ahpf-primary) 22%, transparent);
}
.ahpf-field.ahpf-has-error input, .ahpf-field.ahpf-has-error select, .ahpf-field.ahpf-has-error textarea { border-color: var(--ahpf-error); }
.ahpf-field-error { color: var(--ahpf-error); font-size: .85em; min-height: 0; }
.ahpf-field-error:empty { display: none; }
.ahpf-check label { display: flex; gap: 10px; align-items: flex-start; font-weight: 400; }
.ahpf-check input { margin-top: 4px; accent-color: var(--ahpf-primary); }
.ahpf-check a { color: var(--ahpf-primary); }

.ahpf-hp { position: absolute !important; left: -9999px !important; width: 1px; height: 1px; overflow: hidden; }

.ahpf-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 20px; margin-top: 22px; }
.ahpf-button {
	appearance: none; border: 0; cursor: pointer; font: inherit; font-weight: 600; font-size: 1em;
	background: var(--ahpf-primary); color: var(--ahpf-primary-text); padding: 13px 28px; border-radius: var(--ahpf-radius);
	transition: filter .15s, transform .05s;
}
.ahpf-button:hover { filter: brightness(1.08); }
.ahpf-button:active { transform: translateY(1px); }
.ahpf-button[disabled] { opacity: .65; cursor: wait; }
.ahpf-required-note { color: var(--ahpf-muted); font-size: .85em; }
.ahpf-recaptcha-note { color: var(--ahpf-muted); font-size: .75em; margin: 14px 0 0; }

.ahpf-message { margin-top: 18px; padding: 12px 14px; border-radius: var(--ahpf-radius); font-size: .95em; }
.ahpf-message-error, .ahpf-message[data-type=error] {
	background: color-mix(in srgb, var(--ahpf-error) 9%, transparent); color: var(--ahpf-error); border: 1px solid color-mix(in srgb, var(--ahpf-error) 30%, transparent);
}
.ahpf-notice {
	padding: 16px; border-radius: var(--ahpf-radius); background: color-mix(in srgb, var(--ahpf-muted) 10%, transparent);
	color: var(--ahpf-text); font-weight: 600; text-align: center;
}
.ahpf-success { text-align: center; padding: 12px 0 4px; }
.ahpf-success[hidden], .ahpf-message[hidden] { display: none; }
.ahpf-success-icon {
	width: 56px; height: 56px; margin: 0 auto 12px; border-radius: 50%; display: grid; place-items: center; font-size: 28px;
	background: color-mix(in srgb, var(--ahpf-success) 14%, transparent); color: var(--ahpf-success);
}
.ahpf-success h3 { margin: 0 0 6px; color: var(--ahpf-text); }
.ahpf-success p { margin: 4px 0; color: var(--ahpf-muted); }
.ahpf-pay { margin-top: 18px; }
.ahpf-home { margin: 18px 0 0; }
.ahpf-notice-home { text-align: center; }
.ahpf-button-secondary {
	display: inline-block; text-decoration: none; background: transparent !important; color: var(--ahpf-primary) !important;
	box-shadow: inset 0 0 0 2px var(--ahpf-primary); padding: 11px 24px;
}
.ahpf-button-secondary:hover { background: color-mix(in srgb, var(--ahpf-primary) 8%, transparent) !important; filter: none; }
.ahpf-icon-error { background: color-mix(in srgb, var(--ahpf-error) 14%, transparent) !important; color: var(--ahpf-error) !important; font-weight: 700; }
.ahpf-topbar { max-width: 720px; margin: -12px auto 16px; }
.ahpf-topbar a { color: var(--ahpf-primary); text-decoration: none; font-weight: 600; font-size: .95em; }
.ahpf-topbar a:hover { text-decoration: underline; }
.ahpf-redirect-note { font-size: .85em; color: var(--ahpf-muted); }
.ahpf-result-error .ahpf-success-icon { background: color-mix(in srgb, var(--ahpf-error) 14%, transparent); color: var(--ahpf-error); font-weight: 700; }
.ahpf-result-info .ahpf-success-icon { background: color-mix(in srgb, var(--ahpf-primary) 14%, transparent); color: var(--ahpf-primary); font-weight: 700; font-style: italic; font-family: Georgia, serif; }
.ahpf-result .ahpf-button { display: inline-block; text-decoration: none; }
.ahpf-pay[hidden], .ahpf-pay a[hidden] { display: none; }
.ahpf-pay .ahpf-button { display: inline-block; text-decoration: none; margin-top: 4px; }
.ahpf-ref strong { color: var(--ahpf-text); letter-spacing: .03em; }

/* Standalone page (hyperlink) and iframe embed */
body.ahpf-standalone {
	margin: 0; padding: 32px 16px; background: color-mix(in srgb, var(--ahpf-primary) 6%, #f5f6f8);
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif; font-size: 16px;
}
body.ahpf-embedded { padding: 2px; background: transparent; }
body.ahpf-embedded .ahpf-wrap { max-width: none; }
.ahpf-standalone-logo { text-align: center; margin-bottom: 20px; }
.ahpf-standalone-logo img { max-height: 70px; max-width: 240px; }

/* Description image and builder fields. */
.ahpf-image { margin: 14px 0 16px; padding: 0; }
.ahpf-image img { display: block; width: 100%; height: auto; max-height: 420px; object-fit: cover; border-radius: var(--ahpf-radius); }
.ahpf-desc img { max-width: 100%; height: auto; border-radius: var(--ahpf-radius); }
.ahpf-section { margin: 10px 0 0; padding-bottom: 6px; font-size: 1.1em; border-bottom: 1px solid var(--ahpf-border); color: var(--ahpf-text); }
.ahpf-text-block { color: var(--ahpf-muted); line-height: 1.55; }
.ahpf-text-block p { margin: 0 0 .6em; }
.ahpf-text-block strong { color: var(--ahpf-text); }
.ahpf-help { color: var(--ahpf-muted); font-size: .85em; }
.ahpf-choices { border: 0; margin: 0; padding: 0; min-width: 0; display: flex; flex-direction: column; gap: 6px; }
.ahpf-choices legend { font-weight: 600; font-size: .92em; margin-bottom: 6px; padding: 0; color: var(--ahpf-text); }
.ahpf-choice { display: flex; gap: 10px; align-items: flex-start; font-weight: 400; cursor: pointer; }
.ahpf-choice input { margin-top: 4px; accent-color: var(--ahpf-primary); }
.ahpf-field.ahpf-has-error .ahpf-choices legend { color: var(--ahpf-error); }

/* Calendar (Pro). */
.ahpf-cal { border: 0; margin: 0; padding: 0; min-width: 0; }
.ahpf-cal legend { font-weight: 600; font-size: .92em; margin-bottom: 6px; padding: 0; color: var(--ahpf-text); }
.ahpf-cal-nav { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin: 4px 0 8px; }
.ahpf-cal-nav[hidden] { display: none; }
.ahpf-cal-nav button { border: 1px solid var(--ahpf-border); background: transparent; color: var(--ahpf-text); border-radius: var(--ahpf-radius); width: 36px; height: 32px; font-size: 20px; line-height: 1; cursor: pointer; }
.ahpf-cal-nav button:disabled { opacity: .35; cursor: default; }
.ahpf-cal-title { font-weight: 600; text-transform: capitalize; }
.ahpf-cal.is-paged .ahpf-cal-mtitle { display: none; }
.ahpf-cal-mtitle { font-weight: 600; margin: 10px 0 6px; text-transform: capitalize; }
.ahpf-cal-month[hidden] { display: none; }
.ahpf-cal-grid { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 4px; }
.ahpf-cal-wd { font-size: .72em; text-align: center; color: var(--ahpf-muted); text-transform: uppercase; padding-bottom: 2px; }
.ahpf-cal-day { position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; min-height: 48px; padding: 4px 2px; border: 1px solid var(--ahpf-border); border-radius: var(--ahpf-radius); font-weight: 400; cursor: pointer; text-align: center; }
.ahpf-cal-day input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.ahpf-cal-num { font-weight: 600; line-height: 1.2; }
.ahpf-cal-left { font-size: .68em; color: var(--ahpf-muted); line-height: 1.2; }
.ahpf-cal-day:hover { border-color: var(--ahpf-primary); }
.ahpf-cal-day:focus-within { outline: 2px solid var(--ahpf-primary); outline-offset: 1px; }
.ahpf-cal-day.is-checked, .ahpf-cal-day:has(input:checked) { background: var(--ahpf-primary); border-color: var(--ahpf-primary); color: var(--ahpf-primary-text); }
.ahpf-cal-day.is-checked .ahpf-cal-left, .ahpf-cal-day:has(input:checked) .ahpf-cal-left { color: inherit; opacity: .85; }
.ahpf-cal-day.is-closed { border-style: dashed; opacity: .35; cursor: default; }
.ahpf-cal-day.is-full { opacity: .45; cursor: not-allowed; text-decoration: line-through; }
.ahpf-cal-day.is-full:hover { border-color: var(--ahpf-border); }
.ahpf-cal-summary { margin: 8px 0 0; font-size: .9em; color: var(--ahpf-muted); }
.ahpf-cal-empty { color: var(--ahpf-muted); }
.ahpf-cal .screen-reader-text { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
@media (max-width: 420px) { .ahpf-cal-left { display: none; } .ahpf-cal-day { min-height: 38px; } }

/* Products / mini shop (Pro). */
.ahpf-products { border: 0; margin: 0; padding: 0; min-width: 0; }
.ahpf-products legend { font-weight: 600; font-size: .92em; margin-bottom: 6px; padding: 0; color: var(--ahpf-text); }
.ahpf-prod-table { width: 100%; border-collapse: collapse; font-size: .95em; }
.ahpf-prod-table th { text-align: left; font-size: .78em; text-transform: uppercase; letter-spacing: .02em; color: var(--ahpf-muted); font-weight: 600; padding: 6px 8px; border-bottom: 1px solid var(--ahpf-border); }
.ahpf-prod-table td { padding: 8px; border-bottom: 1px solid var(--ahpf-border); vertical-align: middle; color: var(--ahpf-text); }
.ahpf-prod-table .ahpf-prod-num { text-align: right; white-space: nowrap; }
.ahpf-prod-table .ahpf-prod-qty { width: 84px; padding-left: 0; }
.ahpf-field .ahpf-prod-table input[type=number] { width: 72px; padding: 7px 8px; }
.ahpf-prod-stock { display: block; font-size: .78em; color: var(--ahpf-muted); }
.ahpf-prod-stock.is-out { color: var(--ahpf-error); font-weight: 600; }
.ahpf-prod-table tr.is-sold-out td { opacity: .55; }
@media (max-width: 480px) { .ahpf-prod-table th:nth-child(3), .ahpf-prod-table td:nth-child(3) { display: none; } }
