/* Check-up request dialog and its Contact Form 7 form. From docs/mockups/home.html. */
.modal { position: fixed; inset: 0; z-index: 100; display: flex; align-items: center; justify-content: center; padding: max(1.5rem, env(safe-area-inset-top, 0px)) max(1rem, env(safe-area-inset-right, 0px)) max(1.5rem, env(safe-area-inset-bottom, 0px)) max(1rem, env(safe-area-inset-left, 0px)); background: #000000b3; -webkit-backdrop-filter: blur(0.5rem); backdrop-filter: blur(0.5rem); }
.modal[hidden] { display: none; }
.dlg { position: relative; box-sizing: border-box; width: 100%; max-width: 50rem; max-height: 100%; overflow: auto; padding: 2rem 2.5rem; border-color: var(--control-border); }
.dlg-close { position: absolute; top: 1rem; right: 1rem; }
.dlg-title { font-size: 2.25rem; margin: 0.5rem 3rem 0.75rem 0; }
.dlg-lede { margin: 0 0 1.25rem; }
.dlg-note { margin-bottom: 1.25rem; }
.xc-done { padding: 1rem 0; }
.xc-done[hidden], #xcFormState[hidden] { display: none; }
.xc-done .dlg-title { font-size: 2.75rem; margin: 1rem 0; }
.xc-done p { margin: 0 0 1.5rem; }
.xc-done .btn { border-color: var(--control-border); }
.form-msg { padding: 1rem 1.25rem; border: 1px solid var(--control-border); border-left: 3px solid var(--gold); border-radius: var(--radius-xs); background: var(--surface-200); font-size: 1rem; }
.form-msg[hidden] { display: none; }
.form-msg.cap { border-left-color: var(--ink-muted); }
.xc-admin-notice { margin: 0 0 1rem; }

/* Contact Form 7 markup (CF7 stylesheet is off; these are the styles) */
.xc-fields { display: flex; flex-direction: column; gap: 1.25rem; }
.xc-cols { display: flex; flex-wrap: wrap; gap: 1.25rem; }
.xc-cols > * { flex: 1 1 14rem; min-width: 0; }
.xc-field label, .other-wrap label { display: block; margin-bottom: 0.5rem; }
.xc-problems { margin: 0; padding: 0; border: 0; min-width: 0; }
.xc-problems legend { padding: 0; margin-bottom: 0.75rem; }
.other-wrap { margin-top: 0.75rem; }
.other-wrap[hidden] { display: none; }
.xc-hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.xc-form .wpcf7-form-control-wrap { display: block; }
.xc-form .wpcf7-checkbox { display: flex; flex-wrap: wrap; column-gap: 1.5rem; }
.xc-form .wpcf7-list-item { flex: 1 1 18rem; margin: 0; }
.xc-form .wpcf7-list-item label { display: flex; gap: 1rem; align-items: center; padding: 0.5rem 0; border-top: 1px solid var(--glass-border); cursor: pointer; margin: 0; }
.xc-form .wpcf7-list-item input { appearance: none; -webkit-appearance: none; width: 1.375rem; height: 1.375rem; flex: none; margin: 0; display: grid; place-content: center; border: 1px solid var(--control-border); border-radius: var(--radius-xs); background: var(--glass-fill); }
.xc-form .wpcf7-list-item input::after { content: ""; width: 0.75rem; height: 0.75rem; transform: scale(0); background: var(--on-gold); clip-path: polygon(14% 44%, 0 65%, 50% 100%, 100% 16%, 80% 0%, 43% 62%); transition: transform .12s ease; }
.xc-form .wpcf7-list-item input:checked { background: var(--gold); border-color: var(--gold); }
.xc-form .wpcf7-list-item input:checked::after { transform: scale(1); }
.xc-form .wpcf7-list-item input:focus-visible { outline: 2px solid var(--focus-ring); outline-offset: 2px; }
.xc-form .wpcf7-list-item-label { font-size: 1.125rem; line-height: 1.4; }
.xc-form .xc-fields > .btn { align-self: flex-start; }
/* Narrow dialogs: the uppercase tracked label is wider than the panel, so let it wrap inside the button instead of being clipped. Desktop is unchanged. */
@media (max-width: 30rem) { .dlg .xc-form .xc-fields > .btn { white-space: normal; max-width: 100%; padding: 0.75rem 1.5rem; } }
.xc-form .xc-terms-link { border-bottom: 1px solid var(--gold); }

/* Field errors: color from tokens, icon from the shared icon font */
.xc-form .wpcf7-not-valid-tip { display: flex; gap: 0.5rem; align-items: center; margin-top: 0.5rem; font-size: 1rem; line-height: 1.5; color: var(--err); }
.xc-form .wpcf7-not-valid-tip::before { content: "error"; flex: none; font-family: "Material Symbols Outlined"; font-size: 1.25rem; line-height: 1; font-feature-settings: "liga"; font-variation-settings: "FILL" 0, "wght" 200, "GRAD" 0, "opsz" 48; }
.xc-form :is(input, textarea).wpcf7-not-valid { border-color: var(--err); border-width: 2px; }

/* Form states: .sending, .failed, .spam, .sent are set by CF7 on the form */
.xc-form .wpcf7-response-output { margin: 1.25rem 0 0; padding: 1rem 1.25rem; border: 1px solid var(--control-border); border-left: 3px solid var(--gold); border-radius: var(--radius-xs); background: var(--surface-200); font-size: 1rem; }
.xc-form .wpcf7-response-output:empty, .xc-form form.sent .wpcf7-response-output, .xc-form form.invalid .wpcf7-response-output, .xc-form form.init .wpcf7-response-output { display: none; }
.xc-form form.failed .wpcf7-response-output, .xc-form form.spam .wpcf7-response-output, .xc-form form.unaccepted .wpcf7-response-output { border-left-color: var(--err); }
.xc-form .wpcf7-spinner { display: none; width: 0.9em; height: 0.9em; margin: 0 0 0 0.75rem; border: 2px solid currentColor; border-right-color: transparent; border-radius: 50%; background: none; animation: xcSpin .8s linear infinite; align-self: center; }
.xc-form form.submitting .wpcf7-spinner, .xc-form form.sending .wpcf7-spinner { display: inline-block; }
.xc-form form.submitting [type="submit"], .xc-form form.sending [type="submit"] { opacity: 0.8; cursor: progress; }
.xc-form .screen-reader-response { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0, 0, 0, 0); }
@keyframes xcSpin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .xc-form .wpcf7-spinner { animation-duration: 2.4s !important; animation-name: xcSpin !important; } }
@media (max-width: 48rem) { .dlg { padding: 1.5rem 1.25rem; } }
