PluginProbe
Contact Forms by Cimatti / 2.2.32
Contact Forms by Cimatti v2.2.32
2.3.6 2.3.5 2.3.0 2.2.32 2.2.4 2.2.0 2.1.2 2.1.1 trunk 1.0 1.1 1.2 1.2.1 1.3 1.3.1 1.3.2 1.3.3 1.3.4 1.3.5 1.3.6 1.3.7 1.3.8 1.3.9 1.4.0 1.4.1 All 62 releases
contact-forms / assets / css / frontend.css

frontend.css in Contact Forms by Cimatti 2.2.32, at assets/css/frontend.css

1,495 lines 37.7 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 /* ============================================
2 CSS Custom Properties (Variables)
3 ============================================ */
4 .accua-form {
5 /* Input border color - themes can override this variable */
6 /* Using explicit color instead of currentColor to avoid issues with */
7 /* inputs that use color:transparent for placeholder hiding (date fields) */
8 --accua-form-input-border-color: #111;
9 }
10
11 /* Modern accessible spinner - replaces old gif spinner */
12 .accua_form_api_throbbler {
13 display: inline-block;
14 width: 20px;
15 height: 20px;
16 border: 2px solid currentColor;
17 border-right-color: transparent;
18 border-radius: 50%;
19 animation: accua-spinner-rotate 0.75s linear infinite;
20 vertical-align: middle;
21 opacity: 0.7;
22 }
23
24 /* Reduce motion for users who prefer it (EAA compliance) */
25 @media (prefers-reduced-motion: reduce) {
26 .accua_form_api_throbbler {
27 animation: none;
28 opacity: 0.5;
29 }
30 }
31
32 @keyframes accua-spinner-rotate {
33 to {
34 transform: rotate(360deg);
35 }
36 }
37
38 div.pfbc-error {
39 background-color: #fff;
40 border: 1px solid #ef9a9a;
41 border-left-width: 4px;
42 color: #c62828;
43 padding: 1em 1.25em;
44 margin: 1em 0;
45 border-radius: 4px;
46 box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06);
47 }
48
49 .pfbc-error-heading {
50 display: block;
51 font-size: 1em;
52 margin-bottom: 0.5em;
53 font-weight: 600;
54 color: #c62828;
55 }
56
57 .pfbc-error-list {
58 margin: 0.5em 0 0;
59 padding-left: 1.5em;
60 color: #d32f2f;
61 }
62
63 /* Inline field errors with ARIA support - Modern 2025 Design
64 * WCAG 2.2 / European Accessibility Act compliant:
65 * - Adequate spacing for cognitive accessibility
66 * - Minimum readable font size (13px)
67 * - Proper contrast ratio (4.5:1+)
68 * - Icon + text for non-color-only error indication
69 * - Fast, smooth animation with height transition for fields below
70 */
71 .pfbc-inline-error {
72 color: #d32f2f;
73 padding: 0;
74 margin-top: 0.375em;
75 /* ~6px breathing room below input */
76 font-size: 0.8125rem;
77 /* 13px - consistent sizing regardless of parent */
78 line-height: 1.4;
79 /* Better readability per WCAG */
80 display: flex;
81 align-items: center;
82 gap: 0.375em;
83 /* Better icon-text separation */
84 max-height: 3em;
85 /* Set explicitly for transition */
86 overflow: hidden;
87 /* Required for max-height animation */
88 /* Fast smooth animation - 150ms with ease-in-out for natural feel */
89 animation: pfbc-error-appear 0.15s ease-in-out forwards;
90 }
91
92 /* Smooth exit animation - mirrors entrance but in reverse (slides up and fades out) */
93 .pfbc-inline-error.pfbc-error-removing {
94 animation: pfbc-error-disappear 0.15s ease-in-out forwards;
95 pointer-events: none;
96 }
97
98 /* Smooth appear animation - slides down from above */
99 @keyframes pfbc-error-appear {
100 from {
101 opacity: 0;
102 transform: translateY(-0.375em);
103 max-height: 0;
104 margin-top: 0;
105 }
106
107 to {
108 opacity: 1;
109 transform: translateY(0);
110 max-height: 3em;
111 /* Enough for multi-line errors */
112 margin-top: 0.375em;
113 }
114 }
115
116 /* Smooth disappear animation - slides up and fades out (reverse of appear) */
117 @keyframes pfbc-error-disappear {
118 from {
119 opacity: 1;
120 transform: translateY(0);
121 max-height: 3em;
122 margin-top: 0.375em;
123 }
124
125 to {
126 opacity: 0;
127 transform: translateY(-0.375em);
128 max-height: 0;
129 margin-top: 0;
130 }
131 }
132
133 /* Respect reduced motion preference (EAA compliance) */
134 @media (prefers-reduced-motion: reduce) {
135 .pfbc-inline-error {
136 animation: none;
137 }
138 }
139
140 .pfbc-inline-error::before {
141 content: "\26A0";
142 /* âš  Warning sign */
143 flex-shrink: 0;
144 font-size: 1em;
145 /* Match text size for proper alignment */
146 line-height: 1.4;
147 /* Match text line-height */
148 }
149
150 .pfbc-error-message {
151 flex: 1;
152 }
153
154 /* Fieldwrap needs relative positioning for absolute error placement */
155 .pfbc-fieldwrap {
156 position: relative;
157 }
158
159 /* File input help text styling */
160 .pfbc-help {
161
162 font-size: small;
163 color: #666;
164
165 }
166
167 .pfbc-element {
168 position: relative;
169 }
170
171 /* Error state - semantic error message below field conveys the error */
172 /* Don't override borders/colors - let theme and user's control panel settings apply */
173 .pfbc-element-has-error .pfbc-label label {
174 color: inherit;
175 }
176
177 /* Required field indicator with ARIA */
178 .pfbc-required {
179 color: #dc3545;
180 font-weight: bold;
181 }
182
183 /* Fieldset (fieldgroup) — no border by default; use modifier classes to opt in */
184 .accua-form fieldset {
185 border: none;
186 padding: 0;
187 margin: 0 0 1.5em 0;
188 }
189
190 /* Border variant */
191 .accua-form fieldset.accua-fieldset-border {
192 border: 1px solid #ccc;
193 border-radius: 4px;
194 padding: 1em 1.25em;
195 }
196
197 /* Legend: inline title sitting on the border line */
198 .accua-form fieldset legend {
199 padding: 0 0.5em;
200 font-weight: 600;
201 }
202
203 /* Title before the fieldset (outside/above the border) */
204 .accua-form .accua-fieldset-title-outer {
205 font-weight: 600;
206 margin: 0 0 0.5em 0;
207 }
208
209 /* Title inside the fieldset as a heading block */
210 .accua-form .accua-fieldset-title-inner {
211 font-weight: 600;
212 margin: 0 0 0.75em 0;
213 }
214
215 /* Last element in fieldset: no bottom margin */
216 .accua-form fieldset>.pfbc-element:last-of-type {
217 margin-bottom: 0;
218 }
219
220 /* standard (labels on top) */
221 .accua-form-view-standard .pfbc-element {
222 margin-bottom: 1.25em;
223 position: relative;
224 }
225
226 .accua-form-view-standard .pfbc-label {
227 margin-bottom: 0.375em;
228 }
229
230 .accua-form-view-standard .pfbc-label label {
231 display: block;
232 width: 100%;
233 }
234
235 .accua-form-view-standard .pfbc-textbox,
236 .accua-form-view-standard .pfbc-textarea,
237 .accua-form-view-standard .pfbc-select {
238 width: 100%;
239 display: block;
240 padding: 0.5em 0.75em;
241 box-sizing: border-box;
242 font-size: 1rem;
243 line-height: 1.4;
244 border: 1px solid;
245 border-color: inherit;
246 background-color: inherit;
247 }
248
249 .accua-form-view-standard .pfbc-select {
250 padding-right: 2.5em;
251 -webkit-appearance: none;
252 -moz-appearance: none;
253 appearance: none;
254 background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23333' d='M2 4l4 4 4-4'/%3E%3C/svg%3E");
255 background-repeat: no-repeat;
256 background-position: right 12px center;
257 background-size: 12px;
258 cursor: pointer;
259 }
260
261 .accua-form-view-standard .pfbc-select::-ms-expand {
262 display: none;
263 }
264
265 .accua-form-view-standard .pfbc-textarea {
266 min-height: 6em;
267 resize: vertical;
268 }
269
270 .accua-form-view-standard .pfbc-fieldwrap {
271 width: 100%;
272 display: block;
273 position: relative;
274 }
275
276 .accua-form-view-standard .pfbc-buttons {
277 text-align: right;
278 }
279
280 /* sidebyside (labels on left) */
281 /* Uses float layout (not flex) so custom JS using .css('display','block') to */
282 /* show/hide fields doesn't break the label-beside-input alignment. */
283 .accua-form-view-sidebyside {
284 container-type: inline-size;
285 }
286
287 .accua-form-view-sidebyside .pfbc-element {
288 margin-bottom: 0.5em;
289 position: relative;
290 }
291
292 .accua-form-view-sidebyside .pfbc-element::after {
293 content: "";
294 display: table;
295 clear: both;
296 }
297
298 .accua-form-view-sidebyside .pfbc-elementbottom {
299 clear: both;
300 }
301
302 .accua-form-view-sidebyside .pfbc-label {
303 float: left;
304 width: 25%;
305 padding-top: 0.25rem;
306 padding-right: 0.5em;
307 box-sizing: border-box;
308 }
309
310 .accua-form-view-sidebyside .pfbc-label label {
311 display: block;
312 }
313
314 .accua-form-view-sidebyside .pfbc-fieldwrap {
315 margin-left: 25%;
316 position: relative;
317 }
318
319 /* Elements without a label (e.g. single checkboxes) should be left-aligned */
320 .accua-form-view-sidebyside .pfbc-element>.pfbc-fieldwrap:first-child {
321 margin-left: 0;
322 }
323
324
325 .accuaform-fieldtype-checkbox,
326 .accuaform-fieldtype-multicheckbox {
327 min-width: 1rem;
328 min-height: 1rem;
329 margin-left: 0;
330 }
331
332
333 .accua-form-view-sidebyside .pfbc-textbox,
334 .accua-form-view-sidebyside .pfbc-textarea,
335 .accua-form-view-sidebyside .pfbc-select {
336 width: 100%;
337 display: block;
338 padding: 0.5em 0.75em;
339 box-sizing: border-box;
340 font-size: 1rem;
341 line-height: 1.4;
342 border: 1px solid;
343 border-color: inherit;
344 background-color: inherit;
345 }
346
347 .accua-form-view-sidebyside .pfbc-select {
348 padding-right: 2.5em;
349 -webkit-appearance: none;
350 -moz-appearance: none;
351 appearance: none;
352 background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23333' d='M2 4l4 4 4-4'/%3E%3C/svg%3E");
353 background-repeat: no-repeat;
354 background-position: right 12px center;
355 background-size: 12px;
356 cursor: pointer;
357 }
358
359 .accua-form-view-sidebyside .pfbc-select::-ms-expand {
360 display: none;
361 }
362
363 .accua-form-view-sidebyside .pfbc-textarea {
364 min-height: 6em;
365 resize: vertical;
366 }
367
368 .accua-form-view-sidebyside .pfbc-buttons {
369 text-align: right;
370 }
371
372 /* Responsive: stack labels on top when form container is narrow */
373 @container (max-width: 500px) {
374 .accua-form-view-sidebyside .pfbc-label {
375 float: none;
376 width: 100%;
377 padding-right: 0;
378 padding-bottom: 0.25em;
379 }
380 .accua-form-view-sidebyside .pfbc-fieldwrap {
381 margin-left: 0;
382 }
383 }
384
385 .pfbc-error {
386 padding: .5em;
387 margin-bottom: 1em;
388 }
389
390 .pfbc-error ul {
391 padding-left: 1.75em;
392 margin: 0;
393 margin-top: .25em;
394 }
395
396 /* .pfbc-checkbox {
397 padding: 0.5em 0;
398 border-bottom: 1px solid #f4f4f4;
399 } */
400
401 /* Accessibility: Focus styles for keyboard navigation */
402 .pfbc-textbox:focus,
403 .pfbc-textarea:focus,
404 .pfbc-select:focus,
405 .accua-form input[type="checkbox"]:focus,
406 .accua-form input[type="radio"]:focus,
407 .accua-form button:focus {
408 outline: 3px solid #0066cc;
409 outline-offset: 2px;
410 }
411
412
413 .accua-form .pfbc-element input.wp-color-picker {
414 margin-bottom: 0;
415 background-color: transparent;
416 padding: 1px 0;
417 color: inherit;
418 font-size: inherit;
419 /* Let theme and user's control panel settings handle borders */
420 }
421
422 /* HTML5 Color Picker Styling */
423 .pfbc-color-wrapper {
424 display: flex;
425 align-items: center;
426 gap: 0.75em;
427 }
428
429 .accua-form .pfbc-color-input {
430 /* Match height of text inputs */
431 width: 3em;
432 height: 2.5em;
433 min-height: 2.5em;
434 padding: 0.25em;
435 border: 1px solid #767676;
436 border-radius: 4px;
437 cursor: pointer;
438 /* Remove browser default styling */
439 -webkit-appearance: none;
440 -moz-appearance: none;
441 appearance: none;
442 background: transparent;
443 }
444
445 /* Remove the inner color swatch border in WebKit browsers */
446 .pfbc-color-input::-webkit-color-swatch-wrapper {
447 padding: 0;
448 }
449
450 .pfbc-color-input::-webkit-color-swatch {
451 border: none;
452 border-radius: 2px;
453 }
454
455 /* Firefox color swatch */
456 .pfbc-color-input::-moz-color-swatch {
457 border: none;
458 border-radius: 2px;
459 }
460
461 /* Focus state for accessibility */
462 .pfbc-color-input:focus {
463 outline: 2px solid #0073aa;
464 outline-offset: 2px;
465 }
466
467 .pfbc-color-hex {
468 font-family: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace;
469 font-size: 0.9em;
470 color: #555;
471 min-width: 5.5em;
472 letter-spacing: 0.02em;
473 }
474
475 /* Inline label mode adjustments for color picker */
476 .accua-form-view-inlinelabel .pfbc-inline-label-wrapper .pfbc-color-wrapper {
477 padding-top: 0.5em;
478 }
479
480 #recaptcha_table {
481 table-layout: auto;
482 }
483
484 @media (min-width: 300px) and (max-width: 400px) {
485 .accua_forms_recaptcha2_container {
486 transform: scale(0.75);
487 transform-origin: 0 0;
488 }
489 }
490
491 @media (max-width: 300px) {
492 .accua_forms_recaptcha2_container {
493 transform: scale(0.6);
494 transform-origin: 0 0;
495 }
496 }
497
498 /* ========================================================================
499 Inline Label Layout - Material Design Inspired Floating Labels
500 ======================================================================== */
501
502 /**
503 * Inline Label Layout with Floating Labels
504 *
505 * This layout implements Material Design-inspired floating labels that:
506 * - Start inside the input field (inline)
507 * - Float to the top border when focused or filled
508 * - Use smooth transitions (200ms)
509 * - Maintain accessibility (WCAG 2.1 AAA compliant)
510 * - Prevent layout shift and flickering
511 */
512
513 .accua-form-view-inlinelabel .pfbc-element {
514 margin-bottom: 1em;
515 }
516
517 .accua-form-view-inlinelabel .pfbc-inline-label-wrapper {
518 position: relative;
519 width: 100%;
520 }
521
522 /* Input field styling with space for floating label */
523 .accua-form-view-inlinelabel .pfbc-inline-label-wrapper .pfbc-textbox,
524 .accua-form-view-inlinelabel .pfbc-inline-label-wrapper .pfbc-textarea,
525 .accua-form-view-inlinelabel .pfbc-inline-label-wrapper .pfbc-select {
526 width: 100%;
527 /* Balanced padding: top slightly larger for label space, but visually centered */
528 padding: 1em 0.75em 0.85em 0.75em;
529 box-sizing: border-box;
530 /* Use CSS variable for border color to ensure consistency across all inputs */
531 /* This prevents issues where color:transparent (used for date placeholder hiding) */
532 /* would make borders invisible when using border-color: inherit */
533 border: 1px solid var(--accua-form-input-border-color);
534 /* Increase font size for better readability */
535 font-size: 1rem;
536 line-height: 1.2;
537 background-color: inherit;
538 }
539
540 /* Add right padding to select elements for caret spacing */
541 .accua-form-view-inlinelabel .pfbc-inline-label-wrapper .pfbc-select {
542 padding-right: 2.5em;
543 /* Remove native appearance for consistent cross-browser styling */
544 -webkit-appearance: none;
545 -moz-appearance: none;
546 appearance: none;
547 /* Custom dropdown caret using CSS */
548 background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23333' d='M2 4l4 4 4-4'/%3E%3C/svg%3E");
549 background-repeat: no-repeat;
550 background-position: right 12px center;
551 background-size: 12px;
552 cursor: pointer;
553 /* Firefox-specific fixes for dropdown rendering */
554 text-indent: 0.01px;
555 text-overflow: '';
556 }
557
558 /* Firefox-specific: ensure dropdown opens properly with appearance:none */
559 @-moz-document url-prefix() {
560 .accua-form-view-inlinelabel .pfbc-inline-label-wrapper .pfbc-select {
561 /* Firefox needs explicit color to render dropdown properly */
562 color: inherit;
563 }
564 }
565
566 /* Remove IE's native arrow */
567 .accua-form-view-inlinelabel .pfbc-inline-label-wrapper .pfbc-select::-ms-expand {
568 display: none;
569 }
570
571 /* Textarea specific adjustments */
572 .accua-form-view-inlinelabel .pfbc-inline-label-wrapper .pfbc-textarea {
573 min-height: 6em;
574 resize: vertical;
575 }
576
577 /* Floating label - starts inside the field, vertically centered for inputs */
578 /* Uses fixed position (1.6em from top) instead of 50% to prevent shift when error appears */
579 /* Calculation: input has padding 1em top + 0.85em bottom + ~1.2em line-height + border ≈ 3.15em total */
580 /* Center point ≈ 1.6em from top, adjusted for label's own height via translateY(-50%) */
581 .accua-form-view-inlinelabel .pfbc-floating-label {
582 position: absolute;
583 left: 0.75em;
584 top: 1.6em;
585 /* Fixed position = center of input, independent of wrapper height */
586 font-size: 1rem;
587 pointer-events: none;
588 transition: all 200ms cubic-bezier(0.4, 0, 0.2, 1);
589 transform: translateY(-50%);
590 transform-origin: left center;
591 padding: 0;
592 z-index: 1;
593 max-width: calc(100% - 1.5em);
594 overflow: hidden;
595 text-overflow: ellipsis;
596 white-space: nowrap;
597 opacity: 0.6;
598 }
599
600 /* Textarea label - position at top instead of center */
601 .accua-form-view-inlinelabel .pfbc-inline-label-wrapper:has(.pfbc-textarea) .pfbc-floating-label {
602 top: 1.25em;
603 transform: translateY(0);
604 }
605
606 /* Floating label - when field is focused or has value */
607 .accua-form-view-inlinelabel .pfbc-inline-label-wrapper.is-focused .pfbc-floating-label,
608 .accua-form-view-inlinelabel .pfbc-inline-label-wrapper.has-value .pfbc-floating-label {
609 top: 0;
610 left: 0.625em;
611 font-size: 0.75em;
612 opacity: 1;
613 background-color: var(--wp--preset--color--base, #fff);
614 padding: 0 0.375em;
615 transform: translateY(-50%);
616 max-width: calc(100% - 1.5em);
617 }
618
619 /* Description text below field */
620 .accua-form-view-inlinelabel .pfbc-description {
621 margin-top: 0.375em;
622 font-size: 0.875em;
623 line-height: 1.4;
624 opacity: 0.7;
625 }
626
627 /* Required asterisk */
628 .accua-form-view-inlinelabel .pfbc-floating-label .pfbc-required {
629 opacity: 0.85;
630 }
631
632 /* Fieldwrap for inline labels */
633 .accua-form-view-inlinelabel .pfbc-inline-label-wrapper .pfbc-fieldwrap {
634 position: relative;
635 width: 100%;
636 display: block;
637 padding-bottom: 0;
638 }
639
640 /* Standard labels for checkboxes, radios, file inputs */
641 .accua-form-view-inlinelabel .pfbc-label {
642 margin-bottom: 0.5em;
643 display: block;
644 }
645
646 .accua-form-view-inlinelabel .pfbc-label label {
647 display: block;
648 font-weight: 500;
649 }
650
651 /* Buttons */
652 .accua-form-view-inlinelabel .pfbc-buttons {
653 text-align: right;
654 margin-top: 1.5em;
655 }
656
657 /* Accessibility: High contrast mode support */
658 @media (prefers-contrast: high) {
659 .accua-form-view-inlinelabel .pfbc-floating-label {
660 font-weight: 600;
661 opacity: 1;
662 }
663 }
664
665 /* Accessibility: Reduced motion support */
666 @media (prefers-reduced-motion: reduce) {
667 .accua-form-view-inlinelabel .pfbc-floating-label {
668 transition: none;
669 }
670 }
671
672 /* Hide placeholders and date field text when unfocused (prevents overlap with label) */
673 .accua-form-view-inlinelabel .pfbc-inline-label-wrapper .pfbc-textbox::placeholder,
674 .accua-form-view-inlinelabel .pfbc-inline-label-wrapper .pfbc-textarea::placeholder {
675 opacity: 0;
676 transition: opacity 200ms;
677 }
678
679 /* Hide date input placeholder text in all browsers */
680 /* WebKit browsers (Chrome, Safari, Edge) */
681 .accua-form-view-inlinelabel .pfbc-inline-label-wrapper input[type="date"]::-webkit-datetime-edit-text,
682 .accua-form-view-inlinelabel .pfbc-inline-label-wrapper input[type="date"]::-webkit-datetime-edit-month-field,
683 .accua-form-view-inlinelabel .pfbc-inline-label-wrapper input[type="date"]::-webkit-datetime-edit-day-field,
684 .accua-form-view-inlinelabel .pfbc-inline-label-wrapper input[type="date"]::-webkit-datetime-edit-year-field {
685 opacity: 0;
686 }
687
688 /* Firefox fallback - use color transparent to hide placeholder when empty */
689 .accua-form-view-inlinelabel .pfbc-inline-label-wrapper input[type="date"]:not(.has-value):not(:focus) {
690 color: transparent;
691 opacity: 1;
692 }
693
694 /* Show placeholders when focused or has value */
695 .accua-form-view-inlinelabel .pfbc-inline-label-wrapper.is-focused .pfbc-textbox::placeholder,
696 .accua-form-view-inlinelabel .pfbc-inline-label-wrapper.is-focused .pfbc-textarea::placeholder,
697 .accua-form-view-inlinelabel .pfbc-inline-label-wrapper.has-value .pfbc-textbox::placeholder,
698 .accua-form-view-inlinelabel .pfbc-inline-label-wrapper.has-value .pfbc-textarea::placeholder {
699 opacity: 0.5;
700 }
701
702 /* Show date input text when focused or has value */
703 /* WebKit browsers */
704 .accua-form-view-inlinelabel .pfbc-inline-label-wrapper.is-focused input[type="date"]::-webkit-datetime-edit-text,
705 .accua-form-view-inlinelabel .pfbc-inline-label-wrapper.is-focused input[type="date"]::-webkit-datetime-edit-month-field,
706 .accua-form-view-inlinelabel .pfbc-inline-label-wrapper.is-focused input[type="date"]::-webkit-datetime-edit-day-field,
707 .accua-form-view-inlinelabel .pfbc-inline-label-wrapper.is-focused input[type="date"]::-webkit-datetime-edit-year-field,
708 .accua-form-view-inlinelabel .pfbc-inline-label-wrapper.has-value input[type="date"]::-webkit-datetime-edit-text,
709 .accua-form-view-inlinelabel .pfbc-inline-label-wrapper.has-value input[type="date"]::-webkit-datetime-edit-month-field,
710 .accua-form-view-inlinelabel .pfbc-inline-label-wrapper.has-value input[type="date"]::-webkit-datetime-edit-day-field,
711 .accua-form-view-inlinelabel .pfbc-inline-label-wrapper.has-value input[type="date"]::-webkit-datetime-edit-year-field {
712 opacity: 1;
713 }
714
715 /* Firefox fallback - show color when focused or has value */
716 .accua-form-view-inlinelabel .pfbc-inline-label-wrapper input[type="date"]:focus,
717 .accua-form-view-inlinelabel .pfbc-inline-label-wrapper input[type="date"].has-value {
718 color: inherit;
719 }
720
721 /* Date input - ensure consistent height and picker icon alignment */
722 .accua-form-view-inlinelabel .pfbc-inline-label-wrapper input[type="date"] {
723 /* Same padding as other inputs */
724 padding: 1em 0.75em 0.85em 0.75em;
725 cursor: pointer;
726 /* Use same font as other inputs for consistency and accessibility */
727 font-family: inherit;
728 font-size: 1rem;
729 }
730
731 /* Style the native calendar picker in WebKit browsers (Chrome, Safari, Edge) */
732 .accua-form-view-inlinelabel .pfbc-inline-label-wrapper input[type="date"]::-webkit-calendar-picker-indicator {
733 cursor: pointer;
734 opacity: 0.6;
735 padding: 0;
736 margin: 0;
737 }
738
739 .accua-form-view-inlinelabel .pfbc-inline-label-wrapper input[type="date"]::-webkit-calendar-picker-indicator:hover {
740 opacity: 1;
741 }
742
743 /* ==========================================================================
744 File Upload - Accessible Drag & Drop
745 WCAG 2.2 AA Compliant / European Accessibility Act
746 ========================================================================== */
747
748 /* Wrapper */
749 .accua-file-upload-wrapper {
750 position: relative;
751 width: 100%;
752 }
753
754 /* Dropzone */
755 .accua-file-dropzone {
756 display: flex;
757 flex-direction: column;
758 align-items: center;
759 justify-content: center;
760 min-height: 120px;
761 padding: 1.5rem 1rem;
762 border: 2px dashed #ccc;
763 background-color: #fafafa;
764 cursor: pointer;
765 transition: border-color 0.2s ease, background-color 0.2s ease;
766 text-align: center;
767 }
768
769 /* Dropzone hover state */
770 .accua-file-dropzone:hover {
771 border-color: #999;
772 background-color: #f5f5f5;
773 }
774
775 /* Dropzone focus state - WCAG 2.2 AA requires visible focus indicator */
776 .accua-file-dropzone:focus,
777 .accua-file-dropzone-focused {
778 outline: 3px solid #005fcc;
779 outline-offset: 2px;
780 border-color: #005fcc;
781 }
782
783 /* Dropzone drag-over state */
784 .accua-file-dropzone-drag {
785 border-color: #005fcc;
786 background-color: #e8f4ff;
787 border-style: solid;
788 }
789
790 /* Dropzone text */
791 .accua-file-dropzone-text {
792 color: #666;
793 font-size: 0.95rem;
794 line-height: 1.5;
795 }
796
797 /* Dropzone icon */
798 .accua-file-dropzone-icon {
799 font-size: 1.5rem;
800 display: block;
801 margin-bottom: 0.5rem;
802 }
803
804 /* Browse button styling */
805 .accua-file-browse-btn {
806 color: #005fcc;
807 text-decoration: underline;
808 cursor: pointer;
809 font-weight: 500;
810 }
811
812 .accua-file-browse-btn:hover {
813 color: #003d99;
814 text-decoration: none;
815 }
816
817 /* Hide the native file input visually but keep it accessible */
818 .accua-file-upload-wrapper input[type="file"] {
819 position: absolute !important;
820 width: 1px !important;
821 height: 1px !important;
822 padding: 0 !important;
823 margin: -1px !important;
824 overflow: hidden !important;
825 clip: rect(0, 0, 0, 0) !important;
826 white-space: nowrap !important;
827 border: 0 !important;
828 opacity: 0 !important;
829 }
830
831 /* File list */
832 .accua-file-list {
833 margin-top: 0.75rem;
834 }
835
836 .accua-file-list-items {
837 list-style: none;
838 margin: 0;
839 padding: 0;
840 }
841
842 .accua-file-list-item {
843 display: flex;
844 align-items: center;
845 justify-content: space-between;
846 padding: 0.5rem 0.75rem;
847 margin-bottom: 0.25rem;
848 background-color: #f0f0f0;
849 font-size: 0.9rem;
850 }
851
852 .accua-file-info {
853 flex: 1;
854 min-width: 0;
855 overflow: hidden;
856 text-overflow: ellipsis;
857 white-space: nowrap;
858 color: #333;
859 }
860
861 /* Remove file button */
862 .accua-file-remove-btn {
863 flex-shrink: 0;
864 display: inline-flex;
865 align-items: center;
866 justify-content: center;
867 width: 24px;
868 height: 24px;
869 margin-left: 0.5rem;
870 padding: 0;
871 border: none;
872 border-radius: 50%;
873 background-color: #dc3545;
874 color: #fff;
875 font-size: 1rem;
876 line-height: 1;
877 cursor: pointer;
878 transition: background-color 0.2s ease;
879 }
880
881 .accua-file-remove-btn:hover {
882 background-color: #c82333;
883 }
884
885 .accua-file-remove-btn:focus {
886 outline: 3px solid #005fcc;
887 outline-offset: 2px;
888 }
889
890 /* Screen reader only text */
891 .accua-file-sr-announcement,
892 .screen-reader-text {
893 position: absolute;
894 width: 1px;
895 height: 1px;
896 padding: 0;
897 margin: -1px;
898 overflow: hidden;
899 clip: rect(0, 0, 0, 0);
900 white-space: nowrap;
901 border: 0;
902 }
903
904 /* File upload error display */
905 .accua-file-error {
906 margin-top: 0.5rem;
907 padding: 0.5rem 0.75rem;
908 background-color: #fef2f2;
909 border: 1px solid #dc3545;
910 color: #991b1b;
911 font-size: 0.875rem;
912 line-height: 1.4;
913 }
914
915 /* ============================================
916 Form Success/Error Message Container
917 ============================================ */
918
919 /* Anchor elements - invisible but provide scroll targets */
920 .accua-form-anchor {
921 display: block;
922 position: relative;
923 top: -1em;
924 /* Offset so message isn't hidden under fixed headers */
925 visibility: hidden;
926 height: 0;
927 }
928
929 /* Message container - appears above form after submission */
930 .accua-form-messages {
931 margin-bottom: 1.5em;
932 animation: accua-message-appear 0.4s ease-out;
933 }
934
935 /* Empty state - hide container completely */
936 .accua-form-messages:empty {
937 display: none;
938 margin: 0;
939 padding: 0;
940 }
941
942 /* Ensure content inside messages has reasonable typography */
943 .accua-form-messages h2,
944 .accua-form-messages h3 {
945 margin-top: 0;
946 margin-bottom: 0.5em;
947 }
948
949 .accua-form-messages p {
950 margin-bottom: 0.75em;
951 }
952
953 .accua-form-messages p:last-child {
954 margin-bottom: 0;
955 }
956
957 /* Smooth fade-in animation for message appearance */
958 @keyframes accua-message-appear {
959 0% {
960 opacity: 0;
961 transform: translateY(-0.5em);
962 }
963
964 100% {
965 opacity: 1;
966 transform: translateY(0);
967 }
968 }
969
970 /* Respect user preference for reduced motion */
971 @media (prefers-reduced-motion: reduce) {
972 .accua-form-messages {
973 animation: none;
974 }
975 }
976
977 .accua-file-error-item {
978 display: block;
979 }
980
981 .accua-file-error-item strong {
982 font-weight: 600;
983 }
984
985 /* Error state for dropzone when file error occurs */
986 .accua-file-upload-wrapper.has-file-error .accua-file-dropzone {
987 border-color: #dc3545;
988 }
989
990 /* Floating label compatibility - ensure wrapper doesn't break floating label layout */
991 .accua-form-view-inlinelabel .pfbc-inline-label-wrapper .accua-file-upload-wrapper {
992 width: 100%;
993 }
994
995 /* Remove default label float behavior for file inputs since we have custom dropzone */
996 .accua-form-view-inlinelabel .pfbc-inline-label-wrapper:has(.accua-file-upload-wrapper) .pfbc-label {
997 position: static;
998 transform: none;
999 font-size: inherit;
1000 margin-bottom: 0.5rem;
1001 display: block;
1002 }
1003
1004 /* Error state for dropzone */
1005 .accua-file-upload-wrapper.has-error .accua-file-dropzone {
1006 border-color: #dc3545;
1007 background-color: #fff5f5;
1008 }
1009
1010 /* Admin form builder styles - match the admin theme */
1011 .wp-admin .accua-file-dropzone {
1012 background-color: #f6f7f7;
1013 border-color: #c3c4c7;
1014 }
1015
1016 .wp-admin .accua-file-dropzone:hover {
1017 border-color: #8c8f94;
1018 background-color: #f0f0f1;
1019 }
1020
1021 .wp-admin .accua-file-dropzone:focus,
1022 .wp-admin .accua-file-dropzone-focused {
1023 outline-color: #2271b1;
1024 border-color: #2271b1;
1025 }
1026
1027 .wp-admin .accua-file-dropzone-drag {
1028 border-color: #2271b1;
1029 background-color: #f0f7fc;
1030 }
1031
1032 .wp-admin .accua-file-browse-btn {
1033 color: #2271b1;
1034 }
1035
1036 .wp-admin .accua-file-browse-btn:hover {
1037 color: #135e96;
1038 }
1039
1040 /* ==========================================================================
1041 Validation Summary Area
1042 WCAG 2.2 AA / European Accessibility Act compliant
1043 ========================================================================== */
1044
1045 .pfbc-validation-summary {
1046 padding: 1em 1.25em;
1047 margin-top: 1em;
1048 border: 1px solid;
1049 font-size: 0.9375rem;
1050 line-height: 1.5;
1051 /* Smooth transitions between states (loading → success/error) */
1052 transition: background-color 0.25s ease-out,
1053 border-color 0.25s ease-out,
1054 color 0.25s ease-out,
1055 opacity 0.25s ease-out;
1056 }
1057
1058 /* Loading state - neutral blue color scheme */
1059 .pfbc-validation-loading {
1060 background-color: #eff6ff;
1061 border-color: #3b82f6;
1062 color: #1e40af;
1063 }
1064
1065 .pfbc-validation-loading .pfbc-summary-spinner {
1066 display: inline-block;
1067 width: 1em;
1068 height: 1em;
1069 border: 2px solid currentColor;
1070 border-right-color: transparent;
1071 border-radius: 50%;
1072 animation: accua-spinner-rotate 0.75s linear infinite;
1073 vertical-align: -0.125em;
1074 margin-right: 0.5em;
1075 }
1076
1077 .pfbc-validation-error {
1078 background-color: #fef2f2;
1079 border-color: #dc3545;
1080 color: #991b1b;
1081 }
1082
1083 .pfbc-validation-success {
1084 background-color: #f0fdf4;
1085 border-color: #22c55e;
1086 color: #166534;
1087 }
1088
1089 .pfbc-summary-icon {
1090 font-weight: bold;
1091 margin-right: 0.25em;
1092 }
1093
1094 .pfbc-summary-header {
1095 margin: 0 0 0.5em 0;
1096 font-weight: 600;
1097 font-size: 0.9375rem;
1098 }
1099
1100 .pfbc-summary-list {
1101 margin: 0;
1102 padding-left: 1.5em;
1103 list-style-type: disc;
1104 }
1105
1106 .pfbc-summary-list li {
1107 margin-bottom: 0.25em;
1108 font-size: 0.875rem;
1109 }
1110
1111 .pfbc-summary-list li:last-child {
1112 margin-bottom: 0;
1113 }
1114
1115 .pfbc-summary-link {
1116 color: inherit;
1117 text-decoration: underline;
1118 font-weight: 500;
1119 }
1120
1121 .pfbc-summary-link:hover,
1122 .pfbc-summary-link:focus {
1123 text-decoration: none;
1124 outline: 2px solid currentColor;
1125 outline-offset: 2px;
1126 }
1127
1128 /* Respect user preference for reduced motion (EAA compliance) */
1129 @media (prefers-reduced-motion: reduce) {
1130 .pfbc-validation-summary {
1131 transition: none;
1132 }
1133
1134 .pfbc-validation-loading .pfbc-summary-spinner {
1135 animation: none;
1136 /* Show static spinner for users who prefer no motion */
1137 border-right-color: currentColor;
1138 opacity: 0.5;
1139 }
1140 }
1141
1142 /* ============================================
1143 Post Select - Searchable Dropdown
1144 WCAG 2.2 AA / European Accessibility Act compliant
1145 @since 2.0.0-beta.29
1146 ============================================ */
1147
1148 /* Wrapper - contains both native select (pre-JS) and custom UI (post-JS) */
1149 .pfbc-post-select-wrapper {
1150 position: relative;
1151 width: 100%;
1152 }
1153
1154 /* Native select BEFORE JS enhancement - styled like regular select for no flash */
1155 .pfbc-post-select-wrapper[data-enhanced="false"]>select {
1156 /* Use native select appearance initially - matches other selects */
1157 width: 100%;
1158 display: block;
1159 }
1160
1161 /* Hide native select AFTER JS enhancement runs - keep accessible for form submission */
1162 .pfbc-post-select-wrapper[data-enhanced="true"]>select {
1163 position: absolute;
1164 inset: 0;
1165 width: 100%;
1166 height: 100%;
1167 opacity: 0;
1168 pointer-events: none;
1169 display: block;
1170 }
1171
1172 /* Container for custom dropdown */
1173 .pfbc-post-select-container {
1174 position: relative;
1175 width: 100%;
1176 }
1177
1178 /* Trigger button - matches standard select styling */
1179 .pfbc-post-select-trigger {
1180 display: flex;
1181 align-items: center;
1182 justify-content: space-between;
1183 width: 100%;
1184 padding: 0.5em 0.75em;
1185 padding-right: 2.5em;
1186 font-size: 1rem;
1187 line-height: 1.4;
1188 color: inherit;
1189 background-color: #fff;
1190 border: 1px solid;
1191 border-color: inherit;
1192 border-radius: 0;
1193 cursor: pointer;
1194 text-align: left;
1195 box-sizing: border-box;
1196 font-family: inherit;
1197 appearance: none;
1198 -webkit-appearance: none;
1199 position: relative;
1200 }
1201
1202 .pfbc-post-select-trigger:hover {
1203 border-color: #888;
1204 }
1205
1206 .pfbc-post-select-trigger:focus {
1207 outline: 2px solid #0073aa;
1208 outline-offset: -2px;
1209 }
1210
1211 /* Invalid state for validation errors */
1212 .pfbc-post-select-trigger.pfbc-invalid {
1213 border-color: #c00;
1214 }
1215
1216 /* Arrow indicator */
1217 .pfbc-post-select-arrow {
1218 position: absolute;
1219 right: 12px;
1220 top: 50%;
1221 transform: translateY(-50%);
1222 width: 0;
1223 height: 0;
1224 border-left: 5px solid transparent;
1225 border-right: 5px solid transparent;
1226 border-top: 5px solid currentColor;
1227 pointer-events: none;
1228 }
1229
1230 .pfbc-post-select-container.open .pfbc-post-select-arrow {
1231 border-top: none;
1232 border-bottom: 5px solid currentColor;
1233 }
1234
1235 /* Display text */
1236 .pfbc-post-select-text {
1237 flex: 1;
1238 overflow: hidden;
1239 text-overflow: ellipsis;
1240 white-space: nowrap;
1241 }
1242
1243 /* Dropdown panel */
1244 .pfbc-post-select-dropdown {
1245 position: absolute;
1246 top: 100%;
1247 left: 0;
1248 right: 0;
1249 z-index: 9999;
1250 background: #fff;
1251 border: 1px solid;
1252 border-color: inherit;
1253 border-top: none;
1254 box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
1255 max-height: 300px;
1256 display: flex;
1257 flex-direction: column;
1258 }
1259
1260 /* Search input container */
1261 .pfbc-post-select-search {
1262 padding: 0.5em;
1263 border-bottom: 1px solid #eee;
1264 background: #fafafa;
1265 }
1266
1267 .pfbc-post-select-search-input {
1268 width: 100%;
1269 padding: 0.5em 0.75em;
1270 font-size: 0.9375rem;
1271 line-height: 1.4;
1272 border: 1px solid #ccc;
1273 border-radius: 0;
1274 box-sizing: border-box;
1275 font-family: inherit;
1276 background-color: #fff;
1277 color: inherit;
1278 }
1279
1280 .pfbc-post-select-search-input::placeholder {
1281 color: #999;
1282 }
1283
1284 .pfbc-post-select-search-input:focus {
1285 outline: 2px solid #0073aa;
1286 outline-offset: -2px;
1287 border-color: #ccc;
1288 }
1289
1290 /* Options list */
1291 .pfbc-post-select-options {
1292 list-style: none;
1293 margin: 0;
1294 padding: 0;
1295 overflow-y: auto;
1296 max-height: 220px;
1297 flex: 1;
1298 }
1299
1300 /* Individual option */
1301 .pfbc-post-select-option {
1302 padding: 0.5em 0.75em;
1303 cursor: pointer;
1304 font-size: 1rem;
1305 line-height: 1.4;
1306 }
1307
1308 .pfbc-post-select-option:hover,
1309 .pfbc-post-select-option.highlighted {
1310 background-color: #f0f0f0;
1311 }
1312
1313 .pfbc-post-select-option.selected {
1314 background-color: #0073aa;
1315 color: #fff;
1316 }
1317
1318 .pfbc-post-select-option.selected:hover,
1319 .pfbc-post-select-option.selected.highlighted {
1320 background-color: #005a87;
1321 }
1322
1323 /* No results message */
1324 .pfbc-post-select-no-results {
1325 padding: 1em;
1326 text-align: center;
1327 color: #666;
1328 font-style: italic;
1329 }
1330
1331 /* Loading indicator */
1332 .pfbc-post-select-loading {
1333 padding: 0.75em;
1334 text-align: center;
1335 color: #666;
1336 font-size: 0.875rem;
1337 background: #f9f9f9;
1338 border-top: 1px solid #eee;
1339 }
1340
1341 .pfbc-post-select-loading::before {
1342 content: '';
1343 display: inline-block;
1344 width: 1em;
1345 height: 1em;
1346 border: 2px solid currentColor;
1347 border-right-color: transparent;
1348 border-radius: 50%;
1349 animation: accua-spinner-rotate 0.75s linear infinite;
1350 vertical-align: -0.125em;
1351 margin-right: 0.5em;
1352 }
1353
1354 /* Screen reader only - live region */
1355 .pfbc-post-select-live-region {
1356 position: absolute;
1357 width: 1px;
1358 height: 1px;
1359 padding: 0;
1360 margin: -1px;
1361 overflow: hidden;
1362 clip: rect(0, 0, 0, 0);
1363 white-space: nowrap;
1364 border: 0;
1365 }
1366
1367 /* Focus visible for keyboard users */
1368 .pfbc-post-select-option:focus-visible {
1369 outline: 2px solid #0073aa;
1370 outline-offset: -2px;
1371 }
1372
1373 /* High contrast mode support */
1374 @media (prefers-contrast: high) {
1375 .pfbc-post-select-trigger {
1376 border-width: 2px;
1377 }
1378
1379 .pfbc-post-select-dropdown {
1380 border-width: 2px;
1381 }
1382
1383 .pfbc-post-select-option.highlighted {
1384 outline: 2px solid currentColor;
1385 }
1386 }
1387
1388 /* Reduced motion support */
1389 @media (prefers-reduced-motion: reduce) {
1390 .pfbc-post-select-loading::before {
1391 animation: none;
1392 border-right-color: currentColor;
1393 opacity: 0.5;
1394 }
1395 }
1396
1397 /* ============================================
1398 Post Select - Inline Label Mode (Floating Labels)
1399 Material Design inspired integration
1400 ============================================ */
1401
1402 /* Trigger button styling for inline label mode - matches .pfbc-select */
1403 .accua-form-view-inlinelabel .pfbc-inline-label-wrapper .pfbc-post-select-trigger {
1404 /* Match the padding from .pfbc-select in inline mode */
1405 padding: 1em 0.75em 0.85em 0.75em;
1406 padding-right: 2.5em;
1407 font-size: 1rem;
1408 line-height: 1.2;
1409 width: 100%;
1410 box-sizing: border-box;
1411 /* Override flex display to block for consistent height calculation */
1412 display: block;
1413 text-align: left;
1414 /* Ensure consistent border styling */
1415 border: 1px solid;
1416 border-color: inherit;
1417 }
1418
1419 /* Text span needs inline-block to maintain height when empty */
1420 .accua-form-view-inlinelabel .pfbc-inline-label-wrapper .pfbc-post-select-text {
1421 display: inline-block;
1422 min-height: 1.2em;
1423 /* Match line-height to ensure consistent height when empty */
1424 vertical-align: middle;
1425 }
1426
1427 /* Arrow styling for inline labels - use SVG instead of CSS triangle */
1428 .accua-form-view-inlinelabel .pfbc-inline-label-wrapper .pfbc-post-select-arrow {
1429 right: 12px;
1430 top: 50%;
1431 width: 12px;
1432 height: 12px;
1433 border: none;
1434 background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23333' d='M2 4l4 4 4-4'/%3E%3C/svg%3E");
1435 background-repeat: no-repeat;
1436 background-position: center;
1437 background-size: 100%;
1438 }
1439
1440 /* Post-select uses same floating label behavior as regular select:
1441 - Label inside field when empty
1442 - Label floats to border when has value or focused
1443 No special CSS needed - inherits from .pfbc-inline-label-wrapper.has-value rules */
1444
1445 /* Container must not have margins that would shift the label */
1446 .accua-form-view-inlinelabel .pfbc-inline-label-wrapper .pfbc-post-select-container {
1447 width: 100%;
1448 }
1449
1450 /* Ensure wrapper is properly positioned */
1451 .accua-form-view-inlinelabel .pfbc-inline-label-wrapper .pfbc-post-select-wrapper {
1452 width: 100%;
1453 display: block;
1454 }
1455
1456 /* ============================================
1457 Post Select - Standard Label Mode (Labels on Top)
1458 ============================================ */
1459
1460 .accua-form-view-standard .pfbc-post-select-wrapper {
1461 width: 100%;
1462 }
1463
1464 .accua-form-view-standard .pfbc-post-select-trigger {
1465 width: 100%;
1466 }
1467
1468 /* ============================================
1469 Post Select - Sidebyside Label Mode (Labels on Left)
1470 ============================================ */
1471
1472 .accua-form-view-sidebyside .pfbc-post-select-wrapper {
1473 width: 100%;
1474 }
1475
1476 .accua-form-view-sidebyside .pfbc-post-select-trigger {
1477 width: 100%;
1478 }
1479
1480 /* ============================================
1481 Post Select - Inline Form Mode
1482 ============================================ */
1483
1484 .accua-form-view-inline .pfbc-post-select-trigger {
1485 width: auto;
1486 min-width: 200px;
1487 }
1488
1489 /* ============================================
1490 Turnstile CAPTCHA
1491 ============================================ */
1492
1493 .cf-turnstile iframe {
1494 border: none;
1495 }