/* Form motion, shared by every form page. Opacity and transform only, so nothing shifts; all of it off under prefers-reduced-motion.
   Patterns: staggered reveal while you scroll in, a hairline that draws under the field in focus, a short shake on a field that fails, a thin progress line for the required fields, a drawn check on success.
   Notes: UXPin "Ultimate Guide to Microinteractions in Forms" (feedback per field), animation-principles (100-200 ms, ease-out, reduced-motion variant). */
:root { --fm-ease: cubic-bezier(.16, 1, .3, 1); }

/* reveal: only elements that script marked as waiting are hidden, so without script everything is simply there */
.fm-pre { opacity: 0; transform: translate3d(0, 14px, 0); }
.fm-pre, .fm-pre.fm-go { transition: opacity .6s var(--fm-ease), transform .7s var(--fm-ease); }
.fm-pre.fm-go { opacity: 1; transform: none; }

/* focus: the label brightens and a hairline draws from the left under the field */
.field, label.f { position: relative; }
.field:not(.needs)::after, label.f::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 2px; background: var(--paper, #ebe7e0); transform: scaleX(0); transform-origin: 0 50%; transition: transform .45s var(--fm-ease); pointer-events: none; border-radius: 1px; }
.field:not(.needs):focus-within::after, label.f:focus-within::after { transform: scaleX(1); }
.field label, label.f .lab { transition: color .25s ease, letter-spacing .35s var(--fm-ease); }
.field:focus-within > label, label.f:focus-within .lab { color: #fff; }

/* a field that fails: one short shake, then it rests (the red border is the site's own) */
.bad { animation: fm-shake .38s cubic-bezier(.36, .07, .19, .97) 1; }
@keyframes fm-shake { 15% { transform: translate3d(-5px, 0, 0); } 35% { transform: translate3d(4px, 0, 0); } 55% { transform: translate3d(-3px, 0, 0); } 75% { transform: translate3d(2px, 0, 0); } }
.msg.err, .form-err:not(:empty) { animation: fm-rise .32s var(--fm-ease) both; }
@keyframes fm-rise { from { opacity: 0; transform: translate3d(0, 8px, 0); } to { opacity: 1; transform: none; } }

/* choices: a small press and a pop when they switch on */
.chip span, label.chip { transition: background-color .25s ease, color .25s ease, border-color .25s ease, transform .2s var(--fm-ease); }
.chip:active span, label.chip:active { transform: scale(.96); }
.chip input:checked + span { animation: fm-pop .32s var(--fm-ease); }
@keyframes fm-pop { 40% { transform: scale(1.05); } }

/* sending: the button breathes while it waits */
.submit:disabled, #send:disabled { animation: fm-breathe 1.1s ease-in-out infinite; cursor: progress; }
@keyframes fm-breathe { 50% { opacity: .55; } }

/* progress: a thin line along the top, filling as the required fields are filled */
.fm-progress { position: fixed; left: 0; right: 0; top: 0; height: 2px; z-index: 250; pointer-events: none; opacity: 0; transition: opacity .4s ease; }
.fm-progress.on { opacity: 1; }
.fm-progress i { display: block; height: 100%; background: var(--paper, #ebe7e0); transform: scaleX(var(--fm-p, 0)); transform-origin: 0 50%; transition: transform .5s var(--fm-ease); }

/* success: the check draws itself */
.fm-check { display: block; width: 44px; height: 44px; margin: 0 0 14px; }
.fm-check circle { fill: none; stroke: var(--paper, #ebe7e0); stroke-width: 2; opacity: .35; }
.fm-check path { fill: none; stroke: #6fe3a1; stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 40; stroke-dashoffset: 40; animation: fm-draw .6s .15s var(--fm-ease) forwards; }
@keyframes fm-draw { to { stroke-dashoffset: 0; } }

@media (prefers-reduced-motion: reduce) {
  .fm-pre, .fm-pre.fm-go { opacity: 1; transform: none; transition: none; }
  .field:not(.needs)::after, label.f::after { transition: none; }
  .bad, .msg.err, .form-err:not(:empty), .chip input:checked + span, .submit:disabled, #send:disabled { animation: none; }
  .fm-progress i, .fm-progress { transition: none; }
  .fm-check path { animation: none; stroke-dashoffset: 0; }
}

/* Links: no underline that jumps in on hover. Plain links brighten softly; links that are underlined anyway keep their line and it fills in colour. */
html a:hover, html .menub:hover, html .pn:hover b, html .wjob:hover .wjt { text-decoration: none; }
a, .menub { transition: color .3s ease, opacity .3s ease; }
.menub:hover { opacity: .72; }
.pg-text a, .pg-q a, .pg-msg a, .prose-s a, .found a, .policy a, .form-err a, .ccredit a.cjobs, .cjobs, main .lead a:not(.btn), main .pg-lead a:not(.btn), main p > a:not(.btn):not(.go):not(.pg-pick):not(.mc) {
  text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: .22em; text-decoration-color: rgba(235, 231, 224, .38); transition: text-decoration-color .35s ease, color .3s ease; }
html .pg-text a:hover, html .pg-q a:hover, html .pg-msg a:hover, html .prose-s a:hover, html .found a:hover, html .policy a:hover, html .form-err a:hover, html .cjobs:hover, html main .lead a:not(.btn):hover, html main .pg-lead a:not(.btn):hover, html main p > a:not(.btn):not(.go):not(.pg-pick):not(.mc):hover { text-decoration: underline; text-decoration-color: currentColor; color: #fff; }
@media (prefers-reduced-motion: reduce) { a, .menub, .pg-text a, .pg-q a, .pg-msg a, .prose-s a, .found a, .policy a, .form-err a, .cjobs { transition: none; } }
.seelink { color: inherit; text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: .25em; text-decoration-color: rgba(235, 231, 224, .38); transition: text-decoration-color .35s ease, color .3s ease; }
html .seelink:hover { text-decoration: underline; text-decoration-color: currentColor; color: #fff; }
@media (prefers-reduced-motion: reduce) { .seelink { transition: none; } }

/* the request pages already show the start of the form on the first screen: no scroll cue there (it fell over the text) */
body[data-type] .scue { display: none; }
