PluginProbe
FormLayer / trunk
FormLayer vtrunk
1.0.9 1.0.8 1.0.7 1.0.6 trunk 1.0.3 1.0.4 1.0.5
formlayer / assets / css / frontend.css

frontend.css in FormLayer trunk, at assets/css/frontend.css

562 lines 11.1 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 .formlayer-form label {
2 display: block;
3 margin-bottom: 8px;
4 font-weight: 600;
5 color: #1e293b;
6 font-size: 14px;
7 }
8
9 .formlayer-form input[type="text"],
10 .formlayer-form input[type="email"],
11 .formlayer-form input[type="number"],
12 .formlayer-form input[type="tel"],
13 .formlayer-form input[type="date"],
14 .formlayer-form input[type="password"],
15 .formlayer-form input[type="url"],
16 .formlayer-form textarea {
17 width: 100%;
18 padding: 12px 16px;
19 border: 1.5px solid #e2e8f0;
20 border-radius: 10px;
21 font-size: 15px;
22 color: #1d2327;
23 background: #fff;
24 transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
25 box-sizing: border-box;
26 box-shadow: 0 1px 2px rgba(0,0,0,0.02);
27 }
28
29 .formlayer-form select {
30 width: 100%;
31 height: 48px;
32 padding: 0 40px 0 16px;
33 border: 1.5px solid #e2e8f0;
34 border-radius: 10px;
35 font-size: 15px;
36 color: #1d2327;
37 background: #fff;
38 transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
39 box-sizing: border-box;
40 appearance: none;
41 background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%2364748b' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
42 background-repeat: no-repeat;
43 background-position: right 16px center;
44 background-size: 16px;
45 cursor: pointer;
46 box-shadow: 0 1px 2px rgba(0,0,0,0.02);
47 }
48
49 .formlayer-form input:focus,
50 .formlayer-form textarea:focus,
51 .formlayer-form select:focus {
52 outline: none;
53 border-color: #5525d6;
54 box-shadow: 0 0 0 4px rgba(85, 37, 214, 0.12);
55 transform: translateY(-1px);
56 }
57
58 .formlayer-form textarea {
59 min-height: 120px;
60 resize: vertical;
61 line-height: 1.6;
62 }
63
64 .formlayer-submit-btn {
65 display: inline-flex;
66 align-items: center;
67 justify-content: center;
68 text-align: center;
69 padding: 0 24px;
70 height: 46px;
71 background: #5525d6;
72 color: #fff;
73 border: none;
74 border-radius: 10px;
75 font-weight: 700;
76 font-size: 15px;
77 cursor: pointer;
78 transition: all 0.3s ease;
79 box-shadow: 0 4px 10px rgba(85, 37, 214, 0.2);
80 box-sizing: border-box;
81 text-decoration: none;
82 line-height: 1;
83 }
84
85 .formlayer-submit-btn:hover {
86 background: #441eb1;
87 transform: translateY(-1px);
88 box-shadow: 0 6px 15px rgba(85, 37, 214, 0.3);
89 }
90
91 /* Loading State */
92 .formlayer-submit-btn.loading {
93 color: transparent !important;
94 position: relative;
95 pointer-events: none;
96 opacity: 0.8;
97 }
98
99 .formlayer-submit-btn.loading::after {
100 content: "";
101 position: absolute;
102 width: 20px;
103 height: 20px;
104 top: 50%;
105 left: 50%;
106 margin: -10px 0 0 -10px;
107 border: 3px solid rgba(255, 255, 255, 0.3);
108 border-top-color: #fff;
109 border-radius: 50%;
110 animation: fl-button-spin 0.8s ease-in-out infinite;
111 }
112
113 @keyframes fl-button-spin {
114 to { transform: rotate(360deg); }
115 }
116
117 .formlayer-form .required-indicator {
118 color: #ef4444;
119 margin-left: 4px;
120 }
121
122 .formlayer-radio-group,
123 .formlayer-check-wrap {
124 display: flex;
125 flex-direction: column;
126 gap: 12px;
127 }
128
129 .formlayer-radio-group label,
130 .formlayer-check-wrap label {
131 display: flex;
132 align-items: center;
133 gap: 10px;
134 font-weight: 400;
135 cursor: pointer;
136 }
137
138 /* Label Placement */
139 .formlayer-field-wrap {
140 margin-bottom: 24px;
141 display: flex;
142 flex-direction: column;
143 }
144
145 .formlayer-field-wrap.label-top {
146 flex-direction: column;
147 }
148
149 .formlayer-field-wrap.label-left,
150 .formlayer-field-wrap.label-right {
151 flex-direction: row;
152 align-items: center;
153 gap: 20px;
154 flex-wrap: nowrap;
155 }
156
157 .formlayer-field-wrap.label-left .formlayer-label,
158 .formlayer-field-wrap.label-right .formlayer-label {
159 width: 30%;
160 min-width: 120px;
161 margin-bottom: 0;
162 padding-top: 0;
163 }
164
165 .formlayer-field-wrap.label-right .formlayer-label {
166 order: 2;
167 }
168
169 .formlayer-field-wrap.label-right .formlayer-input {
170 order: 1;
171 }
172
173 .formlayer-field-wrap.label-hidden .formlayer-label {
174 display: none;
175 }
176
177 .formlayer-help-text {
178 width: 100%;
179 font-size: 12px;
180 color: #94a3b8;
181 margin-top: 8px;
182 font-style: italic;
183 }
184
185 .formlayer-field-wrap.label-left .formlayer-help-text,
186 .formlayer-field-wrap.label-right .formlayer-help-text {
187 margin-left: calc(30% + 20px);
188 }
189
190 .formlayer-submit-wrap {
191 margin-top: 20px;
192 }
193
194 .formlayer-success-message {
195 background: #ffffff;
196 color: #1e293b;
197 padding: 20px 24px;
198 border-radius: 8px;
199 margin-bottom: 24px;
200 border: 1px solid #e2e8f0;
201 font-size: 16px;
202 font-weight: 400;
203 line-height: 1.6;
204 box-shadow: 0 1px 3px rgba(0, 0, 0, 0.02);
205 animation: flFadeInSlide 0.3s cubic-bezier(0.16, 1, 0.3, 1) forwards;
206 }
207
208 .formlayer-error-message {
209 background: #fef2f2;
210 color: #991b1b;
211 padding: 16px 20px;
212 border-radius: 10px;
213 margin-bottom: 24px;
214 border: 1px solid rgba(239, 68, 68, 0.2);
215 border-left: 4px solid #ef4444;
216 font-size: 14px;
217 font-weight: 500;
218 line-height: 1.5;
219 box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -2px rgba(0, 0, 0, 0.05);
220 animation: flFadeInSlide 0.3s cubic-bezier(0.16, 1, 0.3, 1) forwards;
221 }
222
223 .formlayer-error {
224 background: #fef2f2;
225 color: #991b1b;
226 padding: 18px 20px;
227 border-radius: 10px;
228 border: 1px solid rgba(239, 68, 68, 0.2);
229 border-left: 4px solid #ef4444;
230 margin: 24px 0;
231 text-align: left;
232 font-size: 14px;
233 font-weight: 500;
234 line-height: 1.5;
235 box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -2px rgba(0, 0, 0, 0.05);
236 animation: flFadeInSlide 0.3s cubic-bezier(0.16, 1, 0.3, 1) forwards;
237 }
238
239 @keyframes flFadeInSlide {
240 from {
241 opacity: 0;
242 transform: translateY(6px);
243 }
244 to {
245 opacity: 1;
246 transform: translateY(0);
247 }
248 }
249 /* Submit Button Customization */
250 .formlayer-submit-wrap.align-center {
251 display: flex;
252 justify-content: center;
253 }
254 .formlayer-submit-wrap.align-right {
255 display: flex;
256 justify-content: flex-end;
257 }
258 .formlayer-submit-wrap.align-full .formlayer-submit-btn {
259 width: 100%;
260 }
261
262 .formlayer-submit-btn.btn-sm {
263 height: 38px;
264 padding: 0 16px;
265 font-size: 13px;
266 }
267 .formlayer-submit-btn.btn-md {
268 height: 46px;
269 padding: 0 24px;
270 font-size: 15px;
271 }
272 .formlayer-submit-btn.btn-lg {
273 height: 56px;
274 padding: 0 32px;
275 font-size: 17px;
276 }
277
278
279 /* Force auto width for submit button by default */
280 .formlayer-submit-btn {
281 width: auto !important;
282 max-width: 100% !important;
283 display: inline-flex !important;
284 align-items: center !important;
285 justify-content: center !important;
286 }
287
288 .align-full .formlayer-submit-btn {
289 width: 100% !important;
290 display: flex !important;
291 }
292
293
294 /* Container Layouts Frontend */
295 .formlayer-container {
296 display: grid;
297 gap: 20px;
298 margin-bottom: 24px;
299 width: 100%;
300 }
301
302 .formlayer-container.grid-cols-1 { grid-template-columns: 1fr; }
303 .formlayer-container.grid-cols-2 { grid-template-columns: 1fr 1fr; }
304 .formlayer-container.grid-cols-3 { grid-template-columns: 1fr 1fr 1fr; }
305 .formlayer-container.grid-cols-4 { grid-template-columns: repeat(4, 1fr); }
306
307 @media (max-width: 768px) {
308 .formlayer-container.grid-cols-2,
309 .formlayer-container.grid-cols-3,
310 .formlayer-container.grid-cols-4 {
311 grid-template-columns: 1fr;
312 }
313 }
314
315 .formlayer-html-content {
316 margin-bottom: 24px;
317 }
318
319 /* Name fields layout - requested to be on separate lines */
320 .formlayer-name-fields-wrap {
321 display: flex;
322 flex-direction: column;
323 gap: 15px;
324 }
325
326 /* Grid & Multi-column Layouts */
327 .formlayer-grid {
328 display: grid;
329 gap: 20px;
330 width: 100%;
331 }
332
333 .formlayer-grid-2 { grid-template-columns: 1fr 1fr; }
334 .formlayer-grid-3 { grid-template-columns: 1fr 1fr 1fr; }
335
336 .formlayer-sub-field {
337 display: flex;
338 flex-direction: column;
339 }
340
341 .formlayer-sub-field.full-width {
342 grid-column: 1 / -1;
343 }
344
345 .formlayer-sub-label {
346 font-size: 11px;
347 color: #64748b;
348 margin-top: 4px;
349 text-transform: uppercase;
350 letter-spacing: 0.5px;
351 font-weight: 600;
352 }
353
354 /* Address Grid Improvements */
355 .formlayer-address-grid {
356 display: grid;
357 grid-template-columns: 1fr 1fr;
358 gap: 15px;
359 }
360
361 .formlayer-address-grid .full-width {
362 grid-column: 1 / -1;
363 margin-bottom: 5px;
364 }
365
366 .formlayer-address-grid .formlayer-sub-field:not(.full-width) {
367 margin-bottom: 5px;
368 }
369
370 /* Field items and spacing */
371 .formlayer-field-wrap {
372 margin-bottom: 28px;
373 }
374
375 /* Numeric and Date inputs */
376 .formlayer-form input[type="number"],
377 .formlayer-form input[type="date"],
378 .formlayer-form input[type="tel"] {
379 height: 48px;
380 }
381
382 .formlayer-date-wrap,
383 .formlayer-select-wrap {
384 position: relative;
385 width: 100%;
386 }
387
388 .formlayer-date-wrap .dashicons,
389 .formlayer-select-wrap .dashicons {
390 position: absolute;
391 left: 16px;
392 top: 50%;
393 transform: translateY(-50%);
394 color: #64748b;
395 pointer-events: none;
396 font-size: 18px;
397 z-index: 10;
398 }
399
400 .formlayer-form input[type="date"],
401 .formlayer-form select {
402 padding-left: 45px !important;
403 }
404
405 /* Options List */
406 .formlayer-options-list {
407 display: flex;
408 flex-direction: column;
409 gap: 10px;
410 }
411
412 .formlayer-option-label,
413 .formlayer-terms-wrap,
414 .formlayer-gdpr-wrap {
415 display: flex !important;
416 align-items: flex-start !important;
417 gap: 12px !important;
418 margin-bottom: 10px !important;
419 }
420
421 .formlayer-option-label input[type="radio"],
422 .formlayer-option-label input[type="checkbox"],
423 .formlayer-terms-wrap input[type="checkbox"],
424 .formlayer-gdpr-wrap input[type="checkbox"] {
425 width: 20px !important;
426 height: 20px !important;
427 margin: 2px 10px 0 0 !important;
428 cursor: pointer;
429 accent-color: #5525d6 !important;
430 flex-shrink: 0 !important;
431 vertical-align: middle !important;
432 display: inline-block !important;
433 opacity: 1 !important;
434 visibility: visible !important;
435 -webkit-appearance: auto !important;
436 -moz-appearance: auto !important;
437 appearance: auto !important;
438 }
439
440 .formlayer-option-label span,
441 .formlayer-terms-label,
442 .formlayer-gdpr-label,
443 .formlayer-gdpr-wrap .formlayer-gdpr-info span {
444 line-height: 1.5 !important;
445 display: inline-block !important;
446 font-size: 14px !important;
447 font-weight: 400 !important;
448 color: #334155;
449 }
450
451 /* Rating Field */
452 .formlayer-rating {
453 display: flex;
454 gap: 8px;
455 }
456
457 .formlayer-rating .dashicons {
458 font-size: 32px;
459 width: 32px;
460 height: 32px;
461 color: #e2e8f0;
462 cursor: pointer;
463 transition: color 0.2s;
464 }
465
466 .formlayer-rating .dashicons.active,
467 .formlayer-rating .dashicons:hover,
468 .formlayer-rating .dashicons:hover ~ .dashicons {
469 color: #f59e0b;
470 }
471
472 /* Section Break — matches admin builder preview */
473 .formlayer-section-break {
474 margin: 32px 0 20px 0;
475 padding-bottom: 10px;
476 border-bottom: 2px solid #e2e8f0;
477 }
478
479 .formlayer-section-break h3 {
480 margin: 0 0 5px 0 !important;
481 font-size: 18px !important;
482 color: #1e293b !important;
483 font-weight: 700 !important;
484 line-height: 1.3 !important;
485 padding: 0 !important;
486 border: none !important;
487 background: none !important;
488 }
489
490 .formlayer-section-break p {
491 margin: 5px 0 0 0 !important;
492 color: #64748b !important;
493 font-size: 13px !important;
494 font-weight: 400 !important;
495 }
496
497 /* Fluent Forms Style File Upload */
498 .formlayer-file-upload-box {
499 display: flex;
500 align-items: center;
501 gap: 15px;
502 background: #f8fafc;
503 border: 1.5px solid #e2e8f0;
504 border-radius: 10px;
505 padding: 10px 15px;
506 width: 100%;
507 box-sizing: border-box;
508 transition: all 0.2s;
509 }
510
511 .formlayer-file-upload-box:hover {
512 border-color: #5525d6;
513 background: #f1f5f9;
514 }
515
516 .formlayer-file-fake-btn {
517 background: #5525d6;
518 color: #fff;
519 padding: 8px 16px;
520 border-radius: 6px;
521 font-size: 14px;
522 font-weight: 600;
523 cursor: pointer;
524 transition: all 0.2s;
525 display: inline-block;
526 white-space: nowrap;
527 }
528
529 .formlayer-file-fake-btn:hover {
530 background: #441eb1;
531 }
532
533 .formlayer-file-chosen-name {
534 font-size: 14px;
535 color: #64748b;
536 overflow: hidden;
537 text-overflow: ellipsis;
538 white-space: nowrap;
539 }
540
541 @media (max-width: 600px) {
542 .formlayer-grid-2,
543 .formlayer-address-grid,
544 .formlayer-grid {
545 grid-template-columns: 1fr !important;
546 }
547 }
548
549 .formlayer-gdpr-info {
550 line-height: 1.4;
551 }
552 .formlayer-gdpr-label {
553 font-size: 14px;
554 color: #475569;
555 }
556 .formlayer-gdpr-desc {
557 font-size: 12px;
558 color: #64748b;
559 margin-top: 4px;
560 }
561
562