| 1 |
/** |
| 2 |
* Two-Factor Authentication Login Styles |
| 3 |
* |
| 4 |
* Styles for the 2FA verification form on WordPress login page |
| 5 |
* |
| 6 |
* @package Vigilante |
| 7 |
*/ |
| 8 |
|
| 9 |
/* Container */ |
| 10 |
.vigilante-2fa-container { |
| 11 |
margin-bottom: 16px; |
| 12 |
} |
| 13 |
|
| 14 |
/* Message box */ |
| 15 |
.vigilante-2fa-message { |
| 16 |
background: #f0f6fc; |
| 17 |
border-left: 4px solid #2271b1; |
| 18 |
padding: 12px 16px; |
| 19 |
margin-bottom: 16px; |
| 20 |
border-radius: 0 4px 4px 0; |
| 21 |
} |
| 22 |
|
| 23 |
.vigilante-2fa-message p { |
| 24 |
margin: 0 0 8px 0; |
| 25 |
color: #1d2327; |
| 26 |
} |
| 27 |
|
| 28 |
.vigilante-2fa-message p:last-child { |
| 29 |
margin-bottom: 0; |
| 30 |
} |
| 31 |
|
| 32 |
.vigilante-2fa-expiry { |
| 33 |
font-size: 13px; |
| 34 |
color: #50575e; |
| 35 |
} |
| 36 |
|
| 37 |
/* Error message */ |
| 38 |
.vigilante-2fa-error { |
| 39 |
background: #fcf0f1; |
| 40 |
border-left: 4px solid #d63638; |
| 41 |
padding: 12px 16px; |
| 42 |
margin-bottom: 16px; |
| 43 |
border-radius: 0 4px 4px 0; |
| 44 |
color: #d63638; |
| 45 |
} |
| 46 |
|
| 47 |
/* Form fields */ |
| 48 |
.vigilante-2fa-field { |
| 49 |
margin-bottom: 16px !important; |
| 50 |
} |
| 51 |
|
| 52 |
.vigilante-2fa-field label { |
| 53 |
display: block; |
| 54 |
margin-bottom: 8px; |
| 55 |
font-weight: 600; |
| 56 |
color: #1d2327; |
| 57 |
} |
| 58 |
|
| 59 |
.vigilante-2fa-field input[type="text"] { |
| 60 |
width: 100%; |
| 61 |
font-size: 24px; |
| 62 |
letter-spacing: 8px; |
| 63 |
text-align: center; |
| 64 |
padding: 12px 16px; |
| 65 |
font-family: monospace; |
| 66 |
} |
| 67 |
|
| 68 |
/* Remember device checkbox */ |
| 69 |
.vigilante-2fa-remember { |
| 70 |
margin-top: 16px !important; |
| 71 |
} |
| 72 |
|
| 73 |
.vigilante-2fa-remember label { |
| 74 |
display: flex; |
| 75 |
align-items: center; |
| 76 |
gap: 8px; |
| 77 |
font-weight: normal; |
| 78 |
cursor: pointer; |
| 79 |
} |
| 80 |
|
| 81 |
.vigilante-2fa-remember input[type="checkbox"] { |
| 82 |
margin: 0; |
| 83 |
} |
| 84 |
|
| 85 |
/* Submit button */ |
| 86 |
.vigilante-2fa-field.submit { |
| 87 |
margin-top: 24px !important; |
| 88 |
} |
| 89 |
|
| 90 |
.vigilante-2fa-field.submit input[type="submit"] { |
| 91 |
width: 100%; |
| 92 |
height: auto; |
| 93 |
padding: 12px 24px; |
| 94 |
font-size: 16px; |
| 95 |
} |
| 96 |
|
| 97 |
/* Resend code link */ |
| 98 |
.vigilante-2fa-resend { |
| 99 |
text-align: center; |
| 100 |
margin-top: 16px; |
| 101 |
font-size: 13px; |
| 102 |
} |
| 103 |
|
| 104 |
.vigilante-2fa-resend a { |
| 105 |
color: #2271b1; |
| 106 |
text-decoration: none; |
| 107 |
} |
| 108 |
|
| 109 |
.vigilante-2fa-resend a:hover { |
| 110 |
color: #135e96; |
| 111 |
text-decoration: underline; |
| 112 |
} |
| 113 |
|
| 114 |
.vigilante-2fa-resend-status { |
| 115 |
display: block; |
| 116 |
margin-top: 8px; |
| 117 |
font-style: italic; |
| 118 |
} |
| 119 |
|
| 120 |
.vigilante-2fa-resend-status:empty { |
| 121 |
display: none; |
| 122 |
} |
| 123 |
|
| 124 |
.vigilante-2fa-resend-status.success { |
| 125 |
color: #00a32a; |
| 126 |
} |
| 127 |
|
| 128 |
.vigilante-2fa-resend-status.error { |
| 129 |
color: #d63638; |
| 130 |
} |
| 131 |
|
| 132 |
/* Hide elements when 2FA form is shown */ |
| 133 |
#login form .user-pass-wrap, |
| 134 |
#login form > p:not(.vigilante-2fa-field):not(.vigilante-2fa-resend), |
| 135 |
#login form .forgetmenot { |
| 136 |
/* Controlled via inline styles in PHP for specificity */ |
| 137 |
} |
| 138 |
|
| 139 |
/* Responsive adjustments */ |
| 140 |
@media screen and (max-width: 480px) { |
| 141 |
.vigilante-2fa-field input[type="text"] { |
| 142 |
font-size: 20px; |
| 143 |
letter-spacing: 6px; |
| 144 |
padding: 10px 12px; |
| 145 |
} |
| 146 |
} |
| 147 |
|
| 148 |
/* TOTP-specific login styles */ |
| 149 |
.vigilante-2fa-totp .vigilante-2fa-totp-icon { |
| 150 |
text-align: center; |
| 151 |
margin: 0 0 12px; |
| 152 |
} |
| 153 |
|
| 154 |
.vigilante-2fa-totp .vigilante-2fa-totp-icon .dashicons { |
| 155 |
font-size: 32px; |
| 156 |
width: 32px; |
| 157 |
height: 32px; |
| 158 |
color: #2271b1; |
| 159 |
} |
| 160 |
|
| 161 |
.vigilante-2fa-backup-hint { |
| 162 |
font-size: 12px; |
| 163 |
color: #646970; |
| 164 |
font-style: italic; |
| 165 |
} |