PluginProbe
Yatra – Travel Booking & Tour Operator Software / 3.0.3
Yatra – Travel Booking & Tour Operator Software v3.0.3
3.0.15 3.0.14 3.0.14.1 3.0.14.2 3.0.12 3.0.13 3.0.11 3.0.10 3.0.9 3.0.8 3.0.7 3.0.6 3.0.5 3.0.5.1 3.0.4 3.0.3 3.0.2.9 3.0.2.7 3.0.2.8 3.0.2.6 trunk 1.0.0 2.0.0 2.0.1 2.0.10 All 83 releases
yatra / assets / css / shortcodes / login-shortcode.css

login-shortcode.css in Yatra – Travel Booking & Tour Operator Software 3.0.3, at assets/css/shortcodes/login-shortcode.css

443 lines 9.7 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 /**
2 * Login Shortcode CSS
3 *
4 * Production-optimized styles for the login form shortcode
5 *
6 * @package Yatra
7 */
8
9 /* CSS Custom Properties for better maintainability */
10 :root {
11 --yatra-login-primary: var(--yatra-primary, #3b82f6);
12 --yatra-login-primary-hover: var(--yatra-primary-dark, #2563eb);
13 --yatra-login-primary-light: color-mix(in srgb, var(--yatra-primary, #3b82f6) 12%, transparent);
14 --yatra-login-text: #1f2937;
15 --yatra-login-text-muted: #6b7280;
16 --yatra-login-border: #d1d5db;
17 --yatra-login-border-hover: #9ca3af;
18 --yatra-login-background: #ffffff;
19 --yatra-login-background-secondary: #f9fafb;
20 --yatra-login-error: #dc2626;
21 --yatra-login-error-bg: #fef2f2;
22 --yatra-login-error-border: #fecaca;
23 --yatra-login-success: #10b981;
24 --yatra-login-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
25 --yatra-login-shadow-hover: 0 2px 8px color-mix(in srgb, var(--yatra-primary, #3b82f6) 28%, transparent);
26 --yatra-login-border-radius: 12px;
27 --yatra-login-border-radius-sm: 8px;
28 --yatra-login-border-radius-xs: 6px;
29 --yatra-login-transition: all 0.2s ease;
30 --yatra-login-transition-fast: all 0.15s ease;
31 }
32
33 /* Main container with hardware acceleration */
34 .yatra-login-shortcode {
35 max-width: 500px;
36 margin: 30px auto;
37 will-change: transform;
38 transform: translateZ(0); /* Hardware acceleration */
39 }
40
41 .yatra-login-container {
42 background: var(--yatra-login-background);
43 border: 1px solid #e5e7eb;
44 border-radius: var(--yatra-login-border-radius);
45 overflow: hidden;
46 box-shadow: var(--yatra-login-shadow);
47 will-change: transform;
48 transform: translateZ(0); /* Hardware acceleration */
49 }
50
51 .yatra-login-header {
52 padding: 30px 30px 20px;
53 text-align: center;
54 background: var(--yatra-login-background-secondary);
55 border-bottom: 1px solid #e5e7eb;
56 }
57
58 .yatra-login-title {
59 margin: 0 0 10px 0;
60 color: var(--yatra-login-text);
61 font-size: 1.875rem;
62 font-weight: 600;
63 line-height: 1.2;
64 }
65
66 .yatra-login-subtitle {
67 margin: 0;
68 color: var(--yatra-login-text-muted);
69 font-size: 0.875rem;
70 line-height: 1.4;
71 }
72
73 .yatra-login-form-container {
74 padding: 30px;
75 }
76
77 .yatra-form-group {
78 margin-bottom: 20px;
79 }
80
81 .yatra-form-label {
82 display: block;
83 margin-bottom: 8px;
84 font-weight: 500;
85 color: var(--yatra-login-text);
86 font-size: 0.875rem;
87 line-height: 1.4;
88 }
89
90 .yatra-form-input {
91 width: 100%;
92 padding: 12px 16px;
93 border: 1px solid var(--yatra-login-border);
94 border-radius: var(--yatra-login-border-radius-sm);
95 font-size: 1rem;
96 font-family: inherit;
97 line-height: 1.5;
98 transition: var(--yatra-login-transition);
99 -webkit-appearance: none;
100 -moz-appearance: none;
101 appearance: none;
102 }
103
104 .yatra-form-input:focus {
105 outline: none;
106 border-color: var(--yatra-login-primary);
107 box-shadow: 0 0 0 3px var(--yatra-login-primary-light);
108 }
109
110 .yatra-password-input-group {
111 position: relative;
112 }
113
114 .yatra-password-toggle {
115 position: absolute;
116 right: 12px;
117 top: 50%;
118 transform: translateY(-50%);
119 background: none;
120 border: none;
121 cursor: pointer;
122 padding: 4px;
123 border-radius: var(--yatra-login-border-radius-xs);
124 display: flex;
125 align-items: center;
126 justify-content: center;
127 color: var(--yatra-login-text-muted);
128 transition: var(--yatra-login-transition);
129 will-change: color;
130 }
131
132 .yatra-password-toggle:hover {
133 color: var(--yatra-login-primary);
134 }
135
136 .yatra-password-toggle:focus {
137 outline: 2px solid var(--yatra-login-primary-light);
138 outline-offset: 2px;
139 }
140
141 .yatra-eye-icon,
142 .yatra-eye-off-icon {
143 width: 20px;
144 height: 20px;
145 pointer-events: none; /* Prevent clicking on SVG */
146 }
147
148 .yatra-eye-off-icon {
149 display: none;
150 }
151
152 .yatra-form-checkbox {
153 margin-bottom: 20px;
154 }
155
156 .yatra-checkbox-wrapper {
157 display: flex;
158 align-items: center;
159 }
160
161 .yatra-checkbox-label {
162 display: flex;
163 align-items: center;
164 cursor: pointer;
165 font-size: 0.875rem;
166 color: #374151;
167 transition: all 0.2s ease;
168 padding: 4px;
169 border-radius: 8px;
170 margin: -4px;
171 }
172
173 .yatra-checkbox-label:hover {
174 color: #1f2937;
175 background-color: #f9fafb;
176 }
177
178 .yatra-checkbox-label:active {
179 transform: scale(0.98);
180 }
181
182 .yatra-checkbox-label input[type="checkbox"] {
183 display: none;
184 }
185
186 .yatra-checkbox-custom {
187 width: 20px;
188 height: 20px;
189 border: 2px solid #d1d5db;
190 border-radius: 6px;
191 margin-right: 12px;
192 display: flex;
193 align-items: center;
194 justify-content: center;
195 transition: all 0.2s ease;
196 background: #ffffff;
197 position: relative;
198 flex-shrink: 0;
199 box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
200 }
201
202 .yatra-checkbox-label:hover .yatra-checkbox-custom {
203 border-color: #9ca3af;
204 }
205
206 .yatra-checkbox-label input[type="checkbox"]:checked + .yatra-checkbox-custom {
207 background: linear-gradient(135deg, var(--yatra-login-primary) 0%, var(--yatra-login-primary-hover) 100%);
208 border-color: var(--yatra-login-primary-hover);
209 box-shadow: var(--yatra-login-shadow-hover), 0 0 0 3px var(--yatra-login-primary-light);
210 }
211
212 .yatra-check-icon {
213 width: 16px;
214 height: 16px;
215 color: #ffffff;
216 opacity: 0;
217 transform: scale(0.8);
218 transition: all 0.2s ease;
219 position: absolute;
220 top: 50%;
221 left: 50%;
222 transform: translate(-50%, -50%) scale(0.8);
223 }
224
225 .yatra-checkbox-label input[type="checkbox"]:checked + .yatra-checkbox-custom .yatra-check-icon {
226 opacity: 1;
227 transform: translate(-50%, -50%) scale(1);
228 }
229
230 /* Fallback for when SVG doesn't load */
231 .yatra-checkbox-custom::after {
232 content: '';
233 position: absolute;
234 top: 50%;
235 left: 50%;
236 transform: translate(-50%, -50%) scale(0);
237 width: 6px;
238 height: 10px;
239 border: solid white;
240 border-width: 0 2px 2px 0;
241 opacity: 0;
242 transition: all 0.2s ease;
243 }
244
245 .yatra-checkbox-label input[type="checkbox"]:checked + .yatra-checkbox-custom::after {
246 opacity: 1;
247 transform: translate(-50%, -50%) scale(1) rotate(45deg);
248 }
249
250 /* Hide fallback when SVG is present */
251 .yatra-check-icon:not(:empty) + .yatra-checkbox-custom::after {
252 display: none;
253 }
254
255 .yatra-checkbox-text {
256 font-weight: 500;
257 user-select: none;
258 flex: none !important;
259 }
260
261 /* Override listing.css flex rule for login checkbox */
262 .yatra-login-shortcode .yatra-checkbox-label span:not(.yatra-filter-count) {
263 flex: none !important;
264 }
265
266 .yatra-login-shortcode .yatra-checkbox-label .yatra-checkbox-custom {
267 flex: none !important;
268 }
269
270 .yatra-login-shortcode .yatra-checkbox-label .yatra-check-icon {
271 flex: none !important;
272 }
273
274 .yatra-form-actions {
275 margin-bottom: 20px;
276 }
277
278 .yatra-btn-full {
279 width: 100%;
280 padding: 12px 24px;
281 }
282
283 /* Production-optimized anti-flicker styles */
284 .yatra-login-form[data-ajax="true"] {
285 transition: none;
286 contain: layout style paint; /* CSS containment for performance */
287 }
288
289 .yatra-login-form[data-ajax="true"] .yatra-btn-primary:disabled {
290 opacity: 0.7;
291 cursor: not-allowed;
292 transition: var(--yatra-login-transition);
293 will-change: opacity, transform;
294 }
295
296 .yatra-login-form[data-ajax="true"] .yatra-btn-primary {
297 transition: var(--yatra-login-transition);
298 will-change: transform, opacity;
299 }
300
301 .yatra-login-form[data-ajax="true"] .yatra-btn-primary:disabled {
302 transform: scale(0.98);
303 }
304
305 /* Optimized error styles */
306 .yatra-form-error {
307 color: var(--yatra-login-error);
308 background-color: var(--yatra-login-error-bg);
309 border: 1px solid var(--yatra-login-error-border);
310 border-radius: var(--yatra-login-border-radius-sm);
311 padding: 12px 16px;
312 margin-bottom: 20px;
313 font-weight: 500;
314 font-size: 0.875rem;
315 line-height: 1.4;
316 will-change: opacity;
317 }
318
319 /* Performance optimizations */
320 .yatra-login-shortcode * {
321 box-sizing: border-box;
322 }
323
324 /* Reduce paint operations */
325 .yatra-login-container,
326 .yatra-login-form-container {
327 contain: layout style paint;
328 }
329
330 /* Optimize animations */
331 @media (prefers-reduced-motion: reduce) {
332 .yatra-login-shortcode * {
333 transition: none !important;
334 animation: none !important;
335 }
336 }
337
338 .yatra-forgot-password {
339 text-align: center;
340 margin-bottom: 20px;
341 }
342
343 .yatra-link {
344 color: var(--yatra-primary, #3b82f6);
345 text-decoration: none;
346 font-size: 0.875rem;
347 transition: color 0.3s ease;
348 }
349
350 .yatra-link:hover {
351 color: var(--yatra-primary-dark, #2563eb);
352 }
353
354 .yatra-link-bold {
355 font-weight: 600;
356 }
357
358 .yatra-register-prompt {
359 text-align: center;
360 padding-top: 20px;
361 border-top: 1px solid #f3f4f6;
362 }
363
364 .yatra-register-prompt p {
365 margin: 0;
366 color: #6b7280;
367 font-size: 0.875rem;
368 }
369
370 .yatra-login-footer {
371 padding: 20px 30px;
372 background: #f9fafb;
373 border-top: 1px solid #e5e7eb;
374 }
375
376 .yatra-login-security {
377 display: flex;
378 align-items: center;
379 gap: 12px;
380 justify-content: center;
381 }
382
383 .yatra-security-icon-svg {
384 width: 20px;
385 height: 20px;
386 color: #10b981;
387 }
388
389 .yatra-security-text {
390 margin: 0;
391 color: #6b7280;
392 font-size: 0.75rem;
393 }
394
395 .yatra-login-logged-in {
396 background: white;
397 border: 1px solid #e5e7eb;
398 border-radius: 12px;
399 padding: 40px 30px;
400 text-align: center;
401 box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
402 }
403
404 .yatra-logged-in-icon-svg {
405 width: 60px;
406 height: 60px;
407 color: #10b981;
408 margin-bottom: 20px;
409 }
410
411 .yatra-logged-in-content h3 {
412 margin: 0 0 10px 0;
413 color: #1f2937;
414 }
415
416 .yatra-logged-in-content p {
417 margin: 0 0 20px 0;
418 color: #6b7280;
419 }
420
421 .yatra-logged-in-actions {
422 display: flex;
423 gap: 12px;
424 justify-content: center;
425 }
426
427 /* Responsive Design */
428 @media (max-width: 480px) {
429 .yatra-login-shortcode {
430 margin: 20px;
431 }
432
433 .yatra-login-header,
434 .yatra-login-form-container,
435 .yatra-login-footer {
436 padding: 20px;
437 }
438
439 .yatra-logged-in-actions {
440 flex-direction: column;
441 }
442 }
443