/* =============================================
   ESTILOS DE AUTENTICAÇÃO - NOVE DE JULHO
   =============================================
   Arquivo: assets/css/auth.css
   Descrição: Estilos para páginas de login e cadastro
   Data: 2024
*/

/* Auth Container */
.auth-container {
    min-height: calc(100vh - 200px);
    display: flex;
    align-items: center;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    padding: 40px 0;
}

.auth-card {
    background: white;
    border-radius: 20px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.1);
    padding: 3rem;
    max-width: 500px;
    width: 100%;
    margin: 0 auto;
    position: relative;
    overflow: hidden;
}

.auth-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 5px;
    background: linear-gradient(90deg, #667eea 0%, #764ba2 100%);
}

/* Auth Header */
.auth-header {
    text-align: center;
    margin-bottom: 2rem;
}

.auth-title {
    font-size: 2rem;
    font-weight: 700;
    color: #333;
    margin-bottom: 0.5rem;
}

.auth-subtitle {
    color: #666;
    font-size: 1rem;
    margin-bottom: 0;
}

/* Progress Steps */
.progress-steps {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 2rem;
    position: relative;
}

.step {
    display: flex;
    flex-direction: column;
    align-items: center;
    opacity: 0.5;
    transition: all 0.3s ease;
}

.step.active {
    opacity: 1;
}

.step-number {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: #e9ecef;
    color: #666;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    margin-bottom: 0.5rem;
    transition: all 0.3s ease;
}

.step.active .step-number {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.step-text {
    font-size: 0.875rem;
    color: #666;
    font-weight: 500;
}

.step-line {
    width: 60px;
    height: 2px;
    background: #e9ecef;
    margin: 0 1rem;
    position: relative;
    top: -20px;
}

/* Form Steps */
.form-step {
    display: none;
    animation: fadeIn 0.3s ease-in-out;
}

.form-step.active {
    display: block;
}

.step-title {
    font-size: 1.5rem;
    font-weight: 600;
    color: #333;
    margin-bottom: 1.5rem;
    text-align: center;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Form Controls */
.form-label {
    font-weight: 500;
    color: #333;
    margin-bottom: 0.5rem;
}

.form-control {
    border: 2px solid #e9ecef;
    border-radius: 10px;
    padding: 0.75rem 1rem;
    font-size: 1rem;
    transition: all 0.3s ease;
    background: #f8f9fa;
}

.form-control:focus {
    border-color: #667eea;
    background: white;
    box-shadow: 0 0 0 0.2rem rgba(102, 126, 234, 0.25);
}

.form-control:hover {
    border-color: #667eea;
}

.form-select {
    border: 2px solid #e9ecef;
    border-radius: 10px;
    padding: 0.75rem 1rem;
    font-size: 1rem;
    transition: all 0.3s ease;
    background: #f8f9fa;
}

.form-select:focus {
    border-color: #667eea;
    background: white;
    box-shadow: 0 0 0 0.2rem rgba(102, 126, 234, 0.25);
}

/* Input Group */
.input-group-text {
    border: 2px solid #e9ecef;
    border-right: none;
    background: #f8f9fa;
    border-radius: 10px 0 0 10px;
    color: #666;
}

.input-group .form-control {
    border-left: none;
    border-radius: 0 10px 10px 0;
}

.input-group .form-control:focus + .input-group-text,
.input-group .input-group-text:has(+ .form-control:focus) {
    border-color: #667eea;
    background: white;
}

/* Terms Section */
.terms-section {
    background: #f8f9fa;
    padding: 1.5rem;
    border-radius: 10px;
    margin-bottom: 1rem;
}

.form-check-input:checked {
    background-color: #667eea;
    border-color: #667eea;
}

.form-check-label {
    font-size: 0.9rem;
    line-height: 1.4;
}

.form-check-label a {
    color: #667eea;
    text-decoration: none;
}

.form-check-label a:hover {
    text-decoration: underline;
}

/* Alert Styles */
.alert {
    border-radius: 10px;
    border: none;
    margin-bottom: 1.5rem;
}

.alert-info {
    background: linear-gradient(135deg, #d1ecf1 0%, #bee5eb 100%);
    color: #0c5460;
}

.alert-info i {
    color: #0c5460;
}

/* Buttons */
.btn {
    border-radius: 10px;
    font-weight: 600;
    padding: 0.75rem 1.5rem;
    transition: all 0.3s ease;
    border: none;
}

.btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.btn-primary:hover {
    background: linear-gradient(135deg, #5a6fd8 0%, #6a4190 100%);
    transform: translateY(-1px);
    box-shadow: 0 5px 15px rgba(102, 126, 234, 0.4);
}

.btn-outline-secondary {
    border: 2px solid #6c757d;
    color: #6c757d;
    background: transparent;
}

.btn-outline-secondary:hover {
    background: #6c757d;
    border-color: #6c757d;
    color: white;
    transform: translateY(-1px);
}

.btn-success {
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
    color: white;
}

.btn-success:hover {
    background: linear-gradient(135deg, #218838 0%, #1dd1a1 100%);
    transform: translateY(-1px);
    box-shadow: 0 5px 15px rgba(40, 167, 69, 0.4);
}

/* Social Login */
.social-login {
    margin-top: 2rem;
}

.social-login .btn {
    margin-bottom: 0.75rem;
    font-weight: 500;
}

.social-login .btn i {
    font-size: 1.1rem;
}

/* Divider */
.divider {
    text-align: center;
    margin: 2rem 0;
    position: relative;
    color: #666;
}

.divider::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    height: 1px;
    background: #e9ecef;
}

.divider span {
    background: white;
    padding: 0 1rem;
    position: relative;
    z-index: 1;
}

/* Auth Footer */
.auth-footer {
    margin-top: 2rem;
    padding-top: 2rem;
    border-top: 1px solid #e9ecef;
}

.auth-footer p {
    color: #666;
    font-size: 0.9rem;
}

/* Password Toggle */
#togglePassword {
    border: 2px solid #e9ecef;
    border-left: none;
    background: #f8f9fa;
    border-radius: 0 10px 10px 0;
    color: #666;
}

#togglePassword:hover {
    background: #e9ecef;
    color: #333;
}

/* Form Text */
.form-text {
    font-size: 0.875rem;
    color: #666;
    margin-top: 0.25rem;
}

/* Responsive Design */
@media (max-width: 768px) {
    .auth-container {
        padding: 20px 0;
    }

    .auth-card {
        padding: 2rem 1.5rem;
        margin: 0 1rem;
    }

    .auth-title {
        font-size: 1.75rem;
    }

    .progress-steps {
        flex-wrap: wrap;
    }

    .step-line {
        width: 30px;
        margin: 0 0.5rem;
        top: -15px;
    }

    .step-text {
        font-size: 0.75rem;
    }

    .btn {
        width: 100%;
        margin-bottom: 0.5rem;
    }

    .d-flex.justify-content-between .btn {
        width: calc(50% - 0.25rem);
    }
}

@media (max-width: 576px) {
    .auth-card {
        padding: 1.5rem 1rem;
    }

    .step-number {
        width: 35px;
        height: 35px;
        font-size: 0.875rem;
    }

    .step-text {
        font-size: 0.7rem;
    }

    .step-line {
        display: none;
    }

    .progress-steps {
        justify-content: space-around;
    }
}

/* Loading States */
.btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.btn:disabled:hover {
    transform: none;
    box-shadow: none;
}

/* Error States */
.form-control.is-invalid {
    border-color: #dc3545;
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='none' stroke='%23dc3545' viewBox='0 0 12 12'%3e%3ccircle cx='6' cy='6' r='4.5'/%3e%3cpath d='M5.8 3.6h.4L6 6.5z'/%3e%3ccircle cx='6' cy='8.2' r='.6' fill='%23dc3545' stroke='none'/%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right calc(0.375em + 0.1875rem) center;
    background-size: calc(0.75em + 0.375rem) calc(0.75em + 0.375rem);
}

.invalid-feedback {
    display: block;
    color: #dc3545;
    font-size: 0.875rem;
    margin-top: 0.25rem;
}

/* Success States */
.form-control.is-valid {
    border-color: #28a745;
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' width='8' height='8' viewBox='0 0 8 8'%3e%3cpath fill='%2328a745' d='M2.3 6.73L.6 4.53c-.4-1.04.46-1.4 1.1-.8l1.1 1.4 3.4-3.8c.6-.63 1.6-.27 1.2.7l-4 4.6c-.43.5-.8.4-1.1.1z'/%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right calc(0.375em + 0.1875rem) center;
    background-size: calc(0.75em + 0.375rem) calc(0.75em + 0.375rem);
}

.valid-feedback {
    display: block;
    color: #28a745;
    font-size: 0.875rem;
    margin-top: 0.25rem;
}

/* Animation Classes */
.slide-in-left {
    animation: slideInLeft 0.3s ease-out;
}

@keyframes slideInLeft {
    from {
        transform: translateX(-100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

.slide-in-right {
    animation: slideInRight 0.3s ease-out;
}

@keyframes slideInRight {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

/* Print Styles */
@media print {
    .auth-container {
        background: white !important;
    }

    .auth-card {
        box-shadow: none !important;
        border: 1px solid #ddd !important;
    }

    .btn {
        display: none !important;
    }
}
