/**
 * Authentication Pages Styles
 * EII Theme Branding
 */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background: linear-gradient(135deg, #faf8f3 0%, #f5f3ed 50%, #fff3e0 100%);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.auth-container {
    width: 100%;
    max-width: 480px;
    margin: 0 auto;
}

.auth-box {
    background: white;
    border-radius: 16px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
    padding: 40px;
    animation: slideUp 0.4s ease-out;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.auth-header {
    text-align: center;
    margin-bottom: 35px;
}

.auth-logo {
    height: 60px;
    width: auto;
    margin-bottom: 20px;
    object-fit: contain;
}

.auth-header h1 {
    font-size: 28px;
    font-weight: 700;
    color: #1a1a1a;
    margin-bottom: 8px;
}

.auth-header p {
    font-size: 15px;
    color: #666;
}

/* Alerts */
.alert {
    padding: 14px 18px;
    border-radius: 8px;
    margin-bottom: 24px;
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 14px;
    line-height: 1.5;
}

.alert::before {
    font-family: 'Bootstrap Icons';
    font-size: 18px;
}

.alert-error {
    background: #fee2e2;
    color: #991b1b;
    border: 1px solid #fca5a5;
}

.alert-error::before {
    content: '\f33a';
}

.alert-success {
    background: #d1fae5;
    color: #065f46;
    border: 1px solid #6ee7b7;
}

.alert-success::before {
    content: '\f26b';
}

.alert-info {
    background: #dbeafe;
    color: #1e40af;
    border: 1px solid #93c5fd;
}

.alert-info::before {
    content: '\f431';
}

/* Form Styles */
.auth-form {
    margin-bottom: 24px;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    font-weight: 600;
    color: #333;
    margin-bottom: 8px;
    font-size: 14px;
}

.form-group input[type="text"],
.form-group input[type="email"],
.form-group input[type="password"] {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid #e5e7eb;
    border-radius: 8px;
    font-size: 15px;
    transition: all 0.3s;
    background: white;
}

.form-group input:focus {
    outline: none;
    border-color: #f78500;
    box-shadow: 0 0 0 3px rgba(247, 133, 0, 0.1);
}

.form-group input::placeholder {
    color: #9ca3af;
}

.form-text {
    display: block;
    margin-top: 6px;
    font-size: 13px;
    color: #6b7280;
}

/* Checkbox */
.checkbox {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    font-weight: 400;
    cursor: pointer;
    font-size: 14px;
    color: #4b5563;
}

.checkbox input[type="checkbox"] {
    margin-top: 3px;
    width: 18px;
    height: 18px;
    cursor: pointer;
    accent-color: #f78500;
}

.checkbox a {
    color: #f78500;
    text-decoration: none;
    font-weight: 600;
}

.checkbox a:hover {
    text-decoration: underline;
}

/* Form Actions */
.form-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
}

.form-actions .link {
    color: #f78500;
    text-decoration: none;
    font-size: 14px;
    font-weight: 600;
}

.form-actions .link:hover {
    text-decoration: underline;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 14px 24px;
    border: none;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    text-decoration: none;
    font-family: inherit;
}

.btn-block {
    width: 100%;
}

.btn-primary {
    background: linear-gradient(135deg, #f78500 0%, #ff9500 100%);
    color: white;
    box-shadow: 0 4px 12px rgba(247, 133, 0, 0.3);
}

.btn-primary:hover {
    background: linear-gradient(135deg, #e67700 0%, #f78500 100%);
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(247, 133, 0, 0.4);
}

.btn-primary:active {
    transform: translateY(0);
}

.btn-google {
    background: white;
    color: #333;
    border: 2px solid #e5e7eb;
    font-weight: 600;
}

.btn-google:hover {
    background: #f9fafb;
    border-color: #d1d5db;
}

.btn-google img {
    width: 20px;
    height: 20px;
}

/* Divider */
.auth-divider {
    display: flex;
    align-items: center;
    text-align: center;
    margin: 28px 0;
    color: #9ca3af;
    font-size: 13px;
    font-weight: 600;
}

.auth-divider::before,
.auth-divider::after {
    content: '';
    flex: 1;
    border-bottom: 1px solid #e5e7eb;
}

.auth-divider span {
    padding: 0 16px;
}

/* Footer */
.auth-footer {
    text-align: center;
    margin-top: 24px;
    padding-top: 24px;
    border-top: 1px solid #e5e7eb;
}

.auth-footer p {
    color: #6b7280;
    font-size: 14px;
}

.auth-footer a {
    color: #f78500;
    text-decoration: none;
    font-weight: 600;
}

.auth-footer a:hover {
    text-decoration: underline;
}

/* Password Strength Indicator */
.password-strength {
    margin-top: 8px;
    height: 4px;
    background: #e5e7eb;
    border-radius: 2px;
    overflow: hidden;
}

.password-strength-bar {
    height: 100%;
    transition: all 0.3s;
    border-radius: 2px;
}

.password-strength-bar.weak {
    width: 33%;
    background: #ef4444;
}

.password-strength-bar.medium {
    width: 66%;
    background: #f59e0b;
}

.password-strength-bar.strong {
    width: 100%;
    background: #10b981;
}

.password-strength-text {
    margin-top: 4px;
    font-size: 12px;
    font-weight: 600;
}

.password-strength-text.weak {
    color: #ef4444;
}

.password-strength-text.medium {
    color: #f59e0b;
}

.password-strength-text.strong {
    color: #10b981;
}

/* Loading State */
.btn.loading {
    position: relative;
    color: transparent;
    pointer-events: none;
}

.btn.loading::after {
    content: '';
    position: absolute;
    width: 20px;
    height: 20px;
    top: 50%;
    left: 50%;
    margin-left: -10px;
    margin-top: -10px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: white;
    animation: spin 0.6s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* Responsive */
@media (max-width: 640px) {
    .auth-box {
        padding: 30px 24px;
    }
    
    .auth-header h1 {
        font-size: 24px;
    }
    
    .form-actions {
        flex-direction: column;
        align-items: flex-start;
    }
}

/* Back Link */
.back-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: #6b7280;
    text-decoration: none;
    font-size: 14px;
    margin-bottom: 20px;
    transition: color 0.2s;
}

.back-link:hover {
    color: #f78500;
}

.back-link i {
    font-size: 16px;
}
