/*!
    
 =========================================================
 * WebEngine CMS - Authentication Forms Styling
 * https://webenginecms.org/
 =========================================================
 
 * Modern, compact styling for authentication pages
 * Maintains dark theme with improved UX
 
 * Licensed under the MIT license
 * http://opensource.org/licenses/MIT
 
 =========================================================
 
*/

/* Authentication Form Container */
.auth-form-container {
    max-width: 500px;
    margin: 20px auto;
    padding: 35px 40px;
    background: rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(5px);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 4px;
    box-shadow: 0 0 15px rgba(0,0,0,0.7);
}

/* Smaller container for single-field forms */
.auth-form-container.auth-form-small {
    max-width: 450px;
    padding: 30px 35px;
}

/* Larger container for multi-field forms */
.auth-form-container.auth-form-large {
    max-width: 540px;
}

/* Form Styling */
.auth-form {
    width: 100%;
}

.auth-form .form-group {
    margin-bottom: 20px;
}

.auth-form .form-group:last-of-type {
    margin-bottom: 0;
}

/* Label Styling - Stacked on top */
.auth-form .control-label {
    display: block;
    width: 100%;
    font-weight: 500;
    margin-bottom: 8px;
    color: #CCCCCC;
    font-size: 14px;
    text-align: left !important;
    padding: 0;
}

/* Input Field Styling */
.auth-form .form-control {
    width: 100%;
    height: 44px;
    padding: 11px 14px;
    font-size: 14px;
    background: #2A2A2A;
    border: 1px solid #444444;
    border-radius: 3px;
    color: #FFFFFF;
    transition: all 0.2s ease;
    box-sizing: border-box;
}

.auth-form .form-control:focus {
    border-color: #00CC99;
    background: #2F2F2F;
    box-shadow: 0 0 0 3px rgba(0, 204, 153, 0.1);
    outline: none;
}

.auth-form .form-control:hover:not(:focus) {
    border-color: #555555;
}

/* Placeholder Styling */
.auth-form .form-control::placeholder {
    color: #777777;
    opacity: 1;
}

.auth-form .form-control::-webkit-input-placeholder {
    color: #777777;
}

.auth-form .form-control::-moz-placeholder {
    color: #777777;
}

.auth-form .form-control:-ms-input-placeholder {
    color: #777777;
}

/* Help Block Styling */
.auth-form .help-block {
    display: block;
    font-size: 12px;
    color: #999999;
    margin-top: 6px;
    margin-bottom: 0;
    line-height: 1.4;
}

.auth-form .help-block a {
    color: #00CC99;
    text-decoration: none;
    transition: color 0.2s ease;
}

.auth-form .help-block a:hover {
    color: #00FFBB;
    text-decoration: underline;
}

/* Button Container */
.auth-form .form-group.auth-form-actions {
    margin-top: 25px;
    margin-bottom: 0;
    text-align: left;
}

/* Button Styling */
.auth-form .btn-primary {
    height: 44px;
    padding: 11px 28px;
    font-size: 14px;
    font-weight: 600;
    min-width: 140px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #FF9900;
    background-color: transparent;
    border: 2px solid #FF9900;
    border-radius: 3px;
    cursor: pointer;
    transition: all 0.2s ease;
    display: inline-block;
    text-align: center;
}

.auth-form .btn-primary:hover {
    color: #1A1A1A !important;
    background-color: #FF9900 !important;
    border-color: #FF9900 !important;
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(255, 153, 0, 0.35);
}

.auth-form .btn-primary:active {
    transform: translateY(0);
    box-shadow: 0 2px 8px rgba(255, 153, 0, 0.3);
}

.auth-form .btn-primary:focus {
    outline: none;
    box-shadow: 0 0 0 3px rgba(255, 153, 0, 0.2);
}

/* reCAPTCHA Container */
.auth-form .recaptcha-container {
    margin: 20px 0;
}

.auth-form .g-recaptcha {
    display: inline-block;
}

/* Terms of Service Text */
.auth-form .tos-text {
    font-size: 12px;
    color: #AAAAAA;
    line-height: 1.5;
    margin-bottom: 20px;
}

.auth-form .tos-text a {
    color: #00CC99;
    text-decoration: none;
}

.auth-form .tos-text a:hover {
    color: #00FFBB;
    text-decoration: underline;
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    .auth-form-container {
        margin: 15px;
        padding: 25px 20px;
    }
    
    .auth-form-container.auth-form-small,
    .auth-form-container.auth-form-large {
        max-width: 100%;
        padding: 25px 20px;
    }
    
    .auth-form .btn-primary {
        width: 100%;
        min-width: auto;
    }
}

@media (max-width: 480px) {
    .auth-form-container {
        margin: 10px;
        padding: 20px 15px;
    }
    
    .auth-form .form-control {
        height: 42px;
        font-size: 16px; /* Prevents zoom on iOS */
    }
    
    .auth-form .btn-primary {
        height: 42px;
        font-size: 13px;
    }
}

/* Page Title Adjustments for Auth Pages */
.page-title + .auth-form-container {
    margin-top: 25px;
}

/* Loading State (optional - for future enhancement) */
.auth-form .btn-primary.loading {
    position: relative;
    color: transparent !important;
    pointer-events: none;
}

.auth-form .btn-primary.loading::after {
    content: "";
    position: absolute;
    width: 16px;
    height: 16px;
    top: 50%;
    left: 50%;
    margin-left: -8px;
    margin-top: -8px;
    border: 2px solid #FF9900;
    border-radius: 50%;
    border-top-color: transparent;
    animation: spinner 0.6s linear infinite;
}

@keyframes spinner {
    to { transform: rotate(360deg); }
}

/* Error/Success States (for future enhancement) */
.auth-form .form-group.has-error .form-control {
    border-color: #E74C3C;
}

.auth-form .form-group.has-error .form-control:focus {
    border-color: #E74C3C;
    box-shadow: 0 0 0 3px rgba(231, 76, 60, 0.1);
}

.auth-form .form-group.has-success .form-control {
    border-color: #00CC99;
}

.auth-form .form-group.has-success .form-control:focus {
    border-color: #00CC99;
    box-shadow: 0 0 0 3px rgba(0, 204, 153, 0.1);
}

/* Autofill Styling */
.auth-form .form-control:-webkit-autofill,
.auth-form .form-control:-webkit-autofill:hover,
.auth-form .form-control:-webkit-autofill:focus {
    -webkit-text-fill-color: #FFFFFF;
    -webkit-box-shadow: 0 0 0px 1000px #2A2A2A inset;
    transition: background-color 5000s ease-in-out 0s;
}

