/* 
=============================================================================
PROJET : Bénin Guest Houses
FICHIER : style/auth.css
DESCRIPTION : Design premium pour la connexion et l'inscription
=============================================================================
*/

.auth-section {
    min-height: calc(100vh - 90px);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 60px 20px;
    background: radial-gradient(circle at top left, rgba(0, 135, 81, 0.05) 0%, rgba(255, 180, 0, 0.05) 100%);
}

.auth-card {
    background: var(--white);
    width: 100%;
    max-width: 550px;
    padding: 60px;
    border-radius: 40px;
    box-shadow: 0 40px 100px rgba(0,0,0,0.08);
    animation: fadeInUp 0.8s cubic-bezier(0.19, 1, 0.22, 1);
    position: relative;
    overflow: hidden;
}

.auth-card::before {
    content: '';
    position: absolute;
    top: 0; left: 0; width: 100%; height: 6px;
    background: linear-gradient(90deg, var(--primary), var(--secondary), var(--accent));
}

.auth-header {
    text-align: center;
    margin-bottom: 40px;
}

.auth-header h2 {
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--dark);
    margin-bottom: 10px;
}

.auth-header p {
    color: var(--gray);
    font-size: 1.1rem;
}

.form-group {
    margin-bottom: 25px;
}

.form-group label {
    display: block;
    font-size: 0.8rem;
    font-weight: 800;
    color: var(--dark);
    margin-bottom: 10px;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.input-icon-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.input-icon-wrapper i {
    position: absolute;
    left: 20px;
    color: var(--gray);
    font-size: 1.1rem;
    transition: var(--transition);
}

.form-control {
    width: 100%;
    padding: 18px 25px;
    padding-left: 55px;
    border: 2px solid #f1f5f9;
    border-radius: 18px;
    font-size: 1rem;
    font-weight: 600;
    color: var(--dark);
    background: #f8fafc;
    transition: var(--transition);
    outline: none;
}

.form-control:focus {
    border-color: var(--primary);
    background: var(--white);
    box-shadow: 0 10px 30px rgba(0, 135, 81, 0.1);
}

.form-control:focus + i {
    color: var(--primary);
}

.grid-2-cols {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

/* --- Multi-step Registration --- */
.registration-step {
    display: none;
    animation: fadeInStep 0.5s ease forwards;
}

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

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

/* --- Stepper Registration --- */
.registration-stepper-container {
    margin-bottom: 40px;
}

.progress-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
}

.progress-header span {
    font-size: 0.9rem;
    font-weight: 800;
    color: var(--dark);
}

.progress-bar-bg {
    width: 100%;
    height: 8px;
    background: #f1f5f9;
    border-radius: 10px;
    margin-bottom: 30px;
    overflow: hidden;
}

.progress-bar-fill {
    width: 33%;
    height: 100%;
    background: var(--primary);
    border-radius: 10px;
    transition: width 0.5s cubic-bezier(0.19, 1, 0.22, 1);
}

.registration-stepper {
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: relative;
    padding: 0 20px;
}

.registration-stepper::before {
    content: '';
    position: absolute;
    top: 25px;
    left: 40px;
    right: 40px;
    height: 3px;
    background: #f1f5f9;
    z-index: 1;
}

.step-item {
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
}

.step-number {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: var(--white);
    border: 3px solid #f1f5f9;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    color: var(--gray);
    transition: var(--transition);
}

.step-label {
    font-size: 0.75rem;
    font-weight: 800;
    color: var(--gray);
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: var(--transition);
}

.step-item.active .step-number {
    border-color: var(--primary);
    color: var(--primary);
    box-shadow: 0 0 20px rgba(0, 135, 81, 0.2);
}

.step-item.active .step-label {
    color: var(--primary);
}

.step-item.completed .step-number {
    background: var(--primary);
    border-color: var(--primary);
    color: var(--white);
}

.step-item.completed .step-label {
    color: var(--primary);
}

.file-upload-wrapper {
    position: relative;
    margin-top: 5px;
}

.file-upload-label {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 30px;
    border: 2px dashed #cbd5e1;
    border-radius: 24px;
    cursor: pointer;
    transition: var(--transition);
    background: #f8fafc;
}

.file-upload-label:hover {
    border-color: var(--primary);
    background: rgba(0, 135, 81, 0.02);
}

.upload-content {
    display: flex;
    align-items: center;
    gap: 20px;
    text-align: left;
}

.upload-icon-container {
    flex-shrink: 0;
}

.file-upload-label i {
    font-size: 2.5rem;
    color: var(--primary);
    filter: drop-shadow(0 5px 15px rgba(0, 135, 81, 0.2));
}

.upload-preview {
    width: 60px;
    height: 60px;
    border-radius: 12px;
    object-fit: cover;
    border: 2px solid var(--white);
    box-shadow: 0 10px 20px rgba(0,0,0,0.1);
}

.upload-text {
    display: flex;
    flex-direction: column;
}

.file-upload-label .main-text {
    font-size: 1.1rem;
    font-weight: 800;
    color: var(--dark);
    word-break: break-all;
}

.file-upload-label .sub-text {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--gray);
    text-transform: uppercase;
    margin-top: 4px;
}

.file-upload-input {
    display: none;
}

.btn-secondary {
    background: transparent;
    border: 2px solid var(--primary);
    color: var(--primary);
    padding: 15px 30px;
    border-radius: 12px;
    font-weight: 700;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.btn-secondary:hover {
    background: rgba(0, 135, 81, 0.05);
    transform: translateY(-2px);
}

.profile-selector {
    border: 2px solid var(--primary) !important;
    border-radius: 25px !important;
    height: 70px !important;
    font-size: 1.2rem !important;
    text-align: center;
    text-align-last: center;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='%23008751' viewBox='0 0 16 16'%3E%3Cpath d='M7.247 11.14 2.451 5.658C1.885 5.013 2.345 4 3.204 4h9.592a1 1 0 0 1 .753 1.659l-4.796 5.48a1 1 0 0 1-1.506 0z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 25px center;
}

/* --- Auth Components --- */
.auth-icon-badge {
    width: 80px;
    height: 80px;
    background: rgba(0, 135, 81, 0.08);
    color: var(--primary);
    border-radius: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.2rem;
    margin: 0 auto 25px;
    border: 1px solid rgba(0, 135, 81, 0.1);
}

.auth-alert {
    background: #fff5f5;
    color: #c53030;
    padding: 15px 20px;
    border-radius: 12px;
    font-size: 0.9rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 25px;
    border: 1px solid #fed7d7;
    animation: shake 0.5s cubic-bezier(.36,.07,.19,.97) both;
}

.auth-alert.success {
    background: #f0fff4;
    color: #276749;
    border-color: #c6f6d5;
}

@keyframes shake {
    10%, 90% { transform: translate3d(-1px, 0, 0); }
    20%, 80% { transform: translate3d(2px, 0, 0); }
    30%, 50%, 70% { transform: translate3d(-4px, 0, 0); }
    40%, 60% { transform: translate3d(4px, 0, 0); }
}

/* Responsive */
/* Tablettes (768px - 992px) */
@media (max-width: 992px) {
    .auth-card {
        padding: 50px 40px;
        max-width: 500px;
    }

    .auth-header h2 {
        font-size: 2.2rem;
    }

    .auth-header p {
        font-size: 1rem;
    }
}

/* Mobiles (max 768px) */
@media (max-width: 768px) {
    .auth-card {
        padding: 40px 30px;
        max-width: 100%;
        border-radius: 30px;
    }

    .auth-header h2 {
        font-size: 2rem;
    }

    .auth-header p {
        font-size: 0.95rem;
    }

    .grid-2-cols {
        grid-template-columns: 1fr;
        gap: 15px;
    }

    .form-control {
        padding: 15px 20px;
        padding-left: 50px;
    }

    .input-icon-wrapper i {
        left: 18px;
        font-size: 1rem;
    }

    .registration-stepper {
        padding: 0 10px;
    }

    .registration-stepper::before {
        left: 30px;
        right: 30px;
    }

    .step-number {
        width: 45px;
        height: 45px;
        font-size: 0.9rem;
    }

    .step-label {
        font-size: 0.65rem;
    }
}

/* Petits mobiles (max 576px) */
@media (max-width: 576px) {
    .auth-card {
        padding: 35px 25px;
        border-radius: 25px;
    }

    .auth-header h2 {
        font-size: 1.8rem;
    }

    .auth-header p {
        font-size: 0.9rem;
    }

    .auth-icon-badge {
        width: 60px;
        height: 60px;
        font-size: 1.8rem;
    }

    .form-group {
        margin-bottom: 20px;
    }

    .form-control {
        padding: 12px 18px;
        padding-left: 45px;
        font-size: 0.95rem;
    }

    .input-icon-wrapper i {
        left: 15px;
        font-size: 0.95rem;
    }

    .btn-secondary {
        padding: 12px 25px;
        font-size: 0.95rem;
    }

    .file-upload-label {
        padding: 20px;
    }

    .file-upload-label i {
        font-size: 2rem;
    }

    .file-upload-label .main-text {
        font-size: 1rem;
    }

    .file-upload-label .sub-text {
        font-size: 0.75rem;
    }
}
