/* The site's own forms (D11 T01 §4), printed by the rizonetech-forms plugin ([rz_contact_form], D13 T01 §4).
   Copied from the approved form prototype (docs/design/prototype/pages/forms.html, "Form pages"), unscoped from its
   .pg-forms wrapper: labels sit above fields, focus is a red ring, errors are in the attack red. The contact page's
   layout classes, which Elementor elements carry, are in components.css (D11 T01 §5); its side panel is here. The
   long intake and agreement forms belong to D13 T01. */

/* A link to #enquiry lands with the form clear of the sticky header (header.css), not under it. */
.rz-form { scroll-margin-top: 96px; }
.fm-body { display: grid; gap: 22px; min-width: 0; }
.fm-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 22px 16px; }
.fm-full { grid-column: 1 / -1; }
.fm-field { display: grid; gap: 8px; align-content: start; min-width: 0; }
.fm-field > label, .fm-q { font-weight: 500; font-size: 15px; line-height: 1.3; }
.fm-opt { font-weight: 400; color: var(--ink-3); margin-left: 6px; font-size: 14px; }
.fm-help { font-size: 13px; line-height: 1.45; color: var(--ink-3); }
.fm-input { width: 100%; min-height: 48px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 8px; background: var(--paper); color: var(--ink); font: 400 16px/1.4 var(--face); transition: border-color 0.2s, box-shadow 0.2s; }
textarea.fm-input { min-height: 132px; resize: vertical; }
.fm-input::placeholder { color: var(--ink-3); }
.fm-input:hover { border-color: var(--ink-3); }
.fm-input:focus { outline: 2px solid var(--signal); outline-offset: 1px; border-color: var(--signal); border-radius: 8px; }
.fm-input[readonly] { background: var(--soft); color: var(--ink-2); }
.fm-affix { display: flex; align-items: stretch; border: 1px solid var(--line); border-radius: 8px; background: var(--paper); transition: border-color 0.2s; }
.fm-affix:hover { border-color: var(--ink-3); }
.fm-affix:focus-within { outline: 2px solid var(--signal); outline-offset: 1px; border-color: var(--signal); }
.fm-affix .fm-input { border: 0; min-width: 0; }
.fm-affix .fm-input:focus { outline: none; }
.fm-affix span { display: grid; place-items: center; padding: 0 14px; border-left: 1px solid var(--line); background: var(--soft); border-radius: 0 8px 8px 0; font: 14px/1 var(--mono); color: var(--ink-2); white-space: nowrap; }
.fm-err { display: none; align-items: flex-start; gap: 6px; font-size: 14px; line-height: 1.4; color: var(--attack); }
.fm-err svg { width: 16px; height: 16px; flex: none; margin-top: 1px; }
.is-bad .fm-err { display: flex; }
.is-bad .fm-input, .is-bad .fm-affix { border-color: var(--attack); box-shadow: 0 0 0 1px var(--attack); }
.is-bad .fm-chip span { border-color: var(--attack); }

/* Choices as chips: one radio or checkbox each, the whole chip clickable. */
.fm-chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 0; padding: 0; border: 0; min-width: 0; }
.fm-chips legend { padding: 0; margin-bottom: 10px; font-weight: 500; font-size: 15px; float: left; width: 100%; }
.fm-chip { position: relative; }
.fm-chip input { position: absolute; inset: 0; opacity: 0; margin: 0; cursor: pointer; }
.fm-chip span { display: inline-flex; align-items: center; gap: 8px; min-height: 40px; padding: 9px 16px; border: 1px solid var(--line); border-radius: 999px; background: var(--paper); font: 500 14px/1.2 var(--face); color: var(--ink); transition: background-color 0.2s, border-color 0.2s, color 0.2s; }
.fm-chip input[type="checkbox"] + span::before { content: ""; width: 12px; height: 12px; border: 1.5px solid currentColor; border-radius: 3px; opacity: 0.5; }
.fm-chip input[type="checkbox"]:checked + span::before { opacity: 1; background: #fff; box-shadow: inset 0 0 0 2px var(--signal); border-color: #fff; }
/* Elementor sizes every ::before inside its content by the border box, which made the intake form's tick 3px smaller
   than the prototype's (D13 T01 §9); the prototype draws it by the content box. */
.fm-chip input[type="checkbox"] + span::before { box-sizing: content-box; }
.fm-chip:hover span { border-color: var(--ink); }
.fm-chip input:checked + span { background: var(--signal-fill); border-color: var(--signal-fill); color: #fff; }
.fm-chip input:focus-visible + span { outline: 2px solid var(--signal); outline-offset: 2px; }
.fm-check { display: grid; grid-template-columns: 22px 1fr; gap: 10px; align-items: start; font-size: 15px; line-height: 1.5; color: var(--ink-2); cursor: pointer; }
.fm-check input { width: 18px; height: 18px; margin: 2px 0 0; accent-color: var(--signal); cursor: pointer; }
.fm-check input:focus-visible { outline: 2px solid var(--signal); outline-offset: 2px; }
.fm-check strong { color: var(--ink); font-weight: 500; }
.fm-check a, .fm-note a { color: var(--ink); text-underline-offset: 3px; text-decoration-color: var(--signal); }
/* Elementor's `.elementor a { text-decoration: none }` loads later at the same weight and took the underline off these
   links on the contact and intake pages; the prototype underlines them (found in D13 T01 §9's parity run). */
.rz-form .fm-check a, .rz-form .fm-note a { text-decoration: underline var(--signal); }
/* The Turnstile widget (D13 T01 §6) has no height until Cloudflare asks a visitor to tick it, but as an item of the
   form body's grid it still took a row and its 22px gap, so the contact form grew. It stays out of the flow until
   Cloudflare's before-interactive callback marks it asking (assets/forms.js), then takes its place like a field. */
.rz-form .cf-turnstile { position: absolute; }
.rz-form .cf-turnstile.is-asking { position: static; }
.fm-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 18px; padding-top: 4px; }
.fm-actions .btn { min-height: 48px; padding-inline: 24px; }
.fm-note { font-size: 13px; line-height: 1.5; color: var(--ink-3); }
.rz-form .btn[disabled] { cursor: default; opacity: 0.85; }
.rz-form .btn .spin { border-color: rgba(255, 255, 255, 0.4); border-top-color: #fff; }
.fm-hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* The outcome: sent, or failed with the reason and a way round. */
.fm-done { display: grid; gap: 10px; justify-items: start; padding: 28px; border-radius: 10px; background: var(--tint); }
.fm-done[hidden] { display: none; }
.fm-done .fm-mark { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%; background: var(--signal); color: #fff; }
.fm-done .fm-mark svg { width: 20px; height: 20px; }
.fm-done h3 { font-size: 22px; justify-self: stretch; text-wrap: pretty; }
.fm-done p { color: var(--ink-2); max-width: 52ch; justify-self: stretch; }
.fm-fail { display: grid; gap: 8px; padding: 16px 18px; border-radius: 10px; background: var(--attack-tint); border-left: 3px solid var(--attack); }
.fm-fail[hidden] { display: none; }
.fm-fail strong { color: var(--attack); font-weight: 600; }
.fm-fail p { color: var(--ink-2); font-size: 15px; }
.fm-body > .fm-fail { margin-bottom: 16px; }

/* The contact page's side panel ([rz_contact_aside], D11 T01 §5; prototype lines 91-102, 176, 188). Elementor wraps a
   shortcode in two divs; they step aside so the panel itself is the grid's second column and fills its height. */
.fm-contact > .elementor-widget-shortcode, .fm-contact > .elementor-widget-shortcode > .elementor-shortcode { display: contents; }
.fm-aside { padding: 48px 32px; border-left: 1px dashed var(--line); background: var(--soft); display: grid; gap: 28px; align-content: start; }
.fm-aside h2 { font: 500 13px/1 var(--mono); letter-spacing: 0.06em; text-transform: uppercase; color: var(--ink-3); margin-bottom: 12px; }
.fm-phone { display: block; font: 600 26px/1.1 var(--mono); letter-spacing: 0.01em; color: var(--ink); text-decoration: none; }
.fm-phone:hover { color: var(--signal-ink); }
.fm-aside .fm-row { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }
.fm-aside p { color: var(--ink-2); font-size: 15px; }
.fm-place { display: flex; gap: 12px; align-items: flex-start; }
.fm-place svg { width: 22px; height: 22px; flex: none; color: var(--signal); margin-top: 2px; }
.fm-place strong { display: block; font-weight: 500; font-size: 17px; color: var(--ink); }
.fm-urgent { padding: 16px 18px; border-radius: 10px; background: var(--attack-tint); }
.fm-urgent p { margin-bottom: 8px; }
.fm-urgent .attack { padding: 0; }
@media (max-width: 960px) { .fm-aside { border-left: 0; border-top: 1px dashed var(--line); } }

@media (max-width: 600px) {
	.fm-aside { padding: 32px 16px; }
	.fm-grid { grid-template-columns: 1fr; }
	.fm-actions .btn { width: 100%; justify-content: center; }
	.fm-done { padding: 22px 18px; }
}

/* The long forms (D13 T01 §9 the client intake, §11 the Microsoft 365 agreement), from the same prototype: numbered
   groups with their heads beside the fields, the closing row, the password note and the fields a choice reveals. */
.fm-long { display: grid; gap: 0; border-top: 1px solid var(--line); }
.fm-long .fm-body { gap: 0; }
.fm-long > .fm-done { margin: 32px 40px 48px; }
.fm-long-end .fm-fail { margin-bottom: 16px; }
.fm-group { display: grid; grid-template-columns: 300px 1fr; gap: 40px; padding: 36px 40px; margin: 0; border: 0; border-bottom: 1px dashed var(--line); min-width: 0; }
.fm-group > .fm-gh { display: grid; grid-template-columns: 34px 1fr; align-content: start; }
.fm-gh b { font: 500 13px/1.75 var(--mono); color: var(--signal-ink); }
.fm-gh h2 { font-size: 20px; letter-spacing: -0.01em; line-height: 1.3; }
.fm-gh p { grid-column: 2; color: var(--ink-2); font-size: 14px; line-height: 1.5; margin-top: 6px; }
.fm-long-end { padding: 32px 40px 48px; display: grid; gap: 20px; }
.fm-long-end .fm-actions { justify-content: space-between; }
.fm-warn { display: flex; gap: 10px; align-items: flex-start; padding: 12px 14px; border-radius: 8px; background: var(--soft); border: 1px solid var(--line); font-size: 14px; line-height: 1.5; color: var(--ink-2); }
.fm-warn svg { width: 18px; height: 18px; flex: none; color: var(--signal); margin-top: 1px; }
.fm-warn strong { color: var(--ink); font-weight: 500; }
.fm-reveal[hidden] { display: none; }
@media (max-width: 960px) { .fm-group { grid-template-columns: 1fr; gap: 20px; } }

/* The Microsoft 365 agreement page (D13 T01 §11), from the same prototype: the four points, the agreement panel and
   the signature pad. */
.fm-points { display: grid; grid-template-columns: repeat(4, 1fr); border-top: 1px solid var(--line); }
.fm-points > div { padding: 28px 28px 32px; border-right: 1px solid var(--line); }
.fm-points > div:last-child { border-right: 0; }
.fm-points b { display: block; font: 500 13px/1 var(--mono); color: var(--signal-ink); margin-bottom: 14px; }
.fm-points h3 { font-size: 17px; letter-spacing: -0.01em; margin-bottom: 6px; }
.fm-points p { color: var(--ink-2); font-size: 15px; }
.fm-doc-wrap { padding: 40px; border-top: 1px solid var(--line); }
.fm-doc { position: relative; border: 1px solid var(--line); border-radius: 10px; background: var(--paper); }
.fm-doc::before, .fm-doc::after { content: ""; position: absolute; width: 7px; height: 7px; border: 1px solid var(--line); background: var(--paper); }
.fm-doc::before { top: -4px; left: -4px; } .fm-doc::after { right: -4px; bottom: -4px; }
.fm-doc-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 16px; padding: 14px 20px; border-bottom: 1px solid var(--line); font: 13px/1.3 var(--mono); color: var(--ink-3); }
.fm-doc-title { display: inline-flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; }
.fm-doc-head strong { font-weight: 500; color: var(--ink); }
.fm-ver { display: inline-flex; align-items: center; gap: 8px; padding: 5px 10px; border-radius: 999px; background: var(--tint); color: var(--signal-ink); font-weight: 500; }
.fm-doc-text { max-height: 380px; overflow-y: auto; padding: 24px 28px; font-size: 15px; line-height: 1.7; color: var(--ink-2); overscroll-behavior: contain; }
.fm-doc-text:focus-visible { outline: 2px solid var(--signal); outline-offset: -2px; border-radius: 0; }
.fm-doc-text h3 { font-size: 16px; color: var(--ink); letter-spacing: -0.01em; margin: 22px 0 6px; display: grid; grid-template-columns: 36px 1fr; }
.fm-doc-text h3:first-child { margin-top: 0; }
.fm-doc-text h3 span { font: 500 13px/1.6 var(--mono); color: var(--ink-3); }
.fm-doc-text p { padding-left: 36px; }
.fm-doc-text p + p { margin-top: 8px; }
.fm-doc-text a { color: var(--ink); text-underline-offset: 3px; text-decoration-color: var(--signal); }
.fm-doc-foot { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 16px; padding: 12px 20px; border-top: 1px solid var(--line); background: var(--soft); border-radius: 0 0 10px 10px; font-size: 13px; color: var(--ink-3); }
.is-bad .fm-sig { border-color: var(--attack); box-shadow: 0 0 0 1px var(--attack); }
.fm-sig { position: relative; height: 190px; border: 1px solid var(--line); border-radius: 10px; background: var(--paper); overflow: hidden; touch-action: none; transition: border-color 0.2s; }
.fm-sig:hover { border-color: var(--ink-3); }
.fm-sig:focus-within { outline: 2px solid var(--signal); outline-offset: 1px; }
.fm-sig canvas { position: absolute; inset: 0; width: 100%; height: 100%; cursor: crosshair; touch-action: none; }
.fm-sig canvas:focus { outline: none; }
.fm-sig-line { position: absolute; left: 24px; right: 24px; bottom: 44px; border-top: 1px dashed var(--ink-3); opacity: 0.6; pointer-events: none; }
.fm-sig-x { position: absolute; left: 24px; bottom: 50px; font: 500 18px/1 var(--mono); color: var(--ink-3); pointer-events: none; }
.fm-sig-hint { position: absolute; left: 0; right: 0; bottom: 16px; text-align: center; font-size: 13px; color: var(--ink-3); pointer-events: none; }
.fm-sig.signed .fm-sig-hint { visibility: hidden; }
.fm-sig-bar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px; }
.fm-sig-state { display: inline-flex; align-items: center; gap: 8px; font: 13px/1 var(--mono); color: var(--ink-3); }
.fm-sig-state::before { content: ""; width: 8px; height: 8px; border-radius: 50%; border: 1.5px solid currentColor; }
.fm-sig-state.on { color: var(--signal-ink); }
.fm-sig-state.on::before { background: currentColor; }
.fm-sig-bar .btn { min-height: 34px; padding: 6px 14px; font-size: 14px; }
/* Elementor makes every ::before and ::after border-box, which shrinks the panel's corner marks and the pad's state dot
   by their borders; the prototype draws them content-box. (Two classes, to outrank Elementor's later rule.) */
.fm-doc-wrap .fm-doc::before, .fm-doc-wrap .fm-doc::after, .fm-sig-bar .fm-sig-state::before { box-sizing: content-box; }
.fm-accept { padding: 18px; border-radius: 10px; border: 1px solid var(--line); background: var(--soft); }
@media (max-width: 960px) {
	.fm-points { grid-template-columns: 1fr 1fr; }
	.fm-points > div:nth-child(2) { border-right: 0; }
	.fm-points > div:nth-child(-n+2) { border-bottom: 1px solid var(--line); }
}
@media (max-width: 600px) {
	.fm-points { grid-template-columns: 1fr; }
	.fm-points > div { border-right: 0; border-bottom: 1px solid var(--line); padding: 22px 16px; }
	.fm-points > div:last-child { border-bottom: 0; }
	.fm-doc-wrap { padding: 24px 16px; }
	.fm-doc-text { padding: 18px 16px; max-height: 340px; }
	.fm-doc-text h3 { grid-template-columns: 30px 1fr; }
	.fm-doc-text p { padding-left: 30px; }
	.fm-sig { height: 170px; }
}
@media (max-width: 600px) {
	.fm-group { padding: 28px 16px; }
	.fm-long-end { padding: 24px 16px 40px; }
	.fm-long-end .fm-actions { flex-direction: column-reverse; align-items: stretch; }
	.fm-long > .fm-done { margin: 24px 16px 40px; }
}
