/******************************************************************************************************************************/
/*                                                                                                                            */
/*                                                              sec-user section                                              */
/*                                                                                                                            */
/******************************************************************************************************************************/

.img-warning-message,
.img-error-message {
    display: inline;
    padding-right: 5px;
    height: 25px;
    width: auto;
    position: absolute;
    top: 5px;
    left: 5px;
}

.div-error-message-extended {
    position: relative;
    visibility: visible;
    margin: 0 1rem;
    height: auto;
    text-align: left;
    font-size: 85%;
    background-color: rgba(255, 255, 0, 0.3);
    padding: 0rem 1rem 0 2rem;
    max-height: 200px;
    /* hauteur suffisante pour afficher le message */
    opacity: 1;
    transition: all 0.3s ease;
    border-radius: 10px;
    border: 1px solid var(--rc-color-red);
    animation: fadeInLoop 2s infinite alternate;
}

.card-actions {
    display: flex;
    justify-content: space-evenly;
    align-items: center;
    flex-direction: row;
    margin: auto;
    width: 100%;
}

@keyframes fadeInLoop {
    0% {
        box-shadow: 2px 2px 1px var(--rc-color-red);
    }

    50% {
        box-shadow: 2px 2px 10px var(--rc-color-red);
    }

    100% {
        box-shadow: 2px 2px 1px var(--rc-color-red);
    }
}

.error-texts {
    display: inline-block;
    vertical-align: middle;
    color: var(--rc-color-red);
    margin: 10px;
}

.error-texts p {
    margin: 0;
    font-size: 1.1em;
    line-height: 1.4em;
}

.error-texts p:first-of-type {
    font-weight: bold;
}

.div-error-message-extended img {
    margin: .2rem;
}

.div-error-message-collapsed {
    visibility: collapse;
    height: 0;
    max-height: 0;
    opacity: 0;
    overflow: hidden;
    transition: all 0.3s ease;
}


/************ LOGIN BOX ***************/
#login-logo {
    position: relative;
    z-index: 3;
    display: block;
    font-family: var(--font-title);
    font-size: calc(var(--header-height)/6);
    line-height: var(--header-height)/6;
    width: 100%;
    margin-bottom: -1px;
}

#login-logo::before {
    content: "Recherche de connexion...";
    position: absolute;
    height: 40px;
    text-align: center;
    left: 0;
    right: 0px;
    bottom: -40px;
    font-size: 16px;
    font-family: var(--font-title);
    color: var(--primary-color);
    width: 35%;
    margin: auto;
    background-color: white;
    border-radius: 0 0 40px 40px;
    min-width: 350px;
    max-width: 500px;
    line-height: 30px;
}

#login-box {
    display: block;
    font-family: var(--font-title);
    font-size: calc(var(--header-height)/6);
    line-height: var(--header-height)/6;
    z-index: 5;
    width: 100%;
    margin-top: -1px;
}

#login-container {
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    border-radius: 0 0 1rem 1rem;
    margin: auto;
    width: 35%;
    background-color: #fff;
    font-family: var(--font-title);
    font-size: calc(var(--header-height)/6);
    line-height: var(--header-height)/6;
    min-width: 350px;
    max-width: 500px;
}

img.atdx-logo {
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    margin: auto;
    width: 35%;
    font-family: var(--font-title);
    font-size: calc(var(--header-height)/6);
    line-height: var(--header-height)/6;
    min-width: 350px;
    max-width: 500px;
}


#login-container>fieldset {
    padding: 1rem;
    margin: 1rem;
    border: 1px solid var(--primary-color);
    border-radius: 10px;
    padding: 1rem;
    box-shadow: 2px 2px 5px rgba(0, 0, 0, 0.1);
}

#login-container>fieldset>div:not(:first-of-type) {
    display: flex;
    flex-wrap: nowrap;
    margin: 0.5rem 0;
    width: 100%;
    flex-direction: column;
}

#login-container>fieldset>div label {
    text-align: left;
    width: 35%;
    white-space: nowrap;
    line-height: 30px;
    padding: 5px 10px 0px 10px;
    height: 20px;
}

#login-container>fieldset>div input {
    width: calc(100% - 10px);
    border-radius: 5px;
    transition: all 0.3s ease;
    border: 1px solid var(--primary-color);
    box-shadow: 2px 2px 0 var(--primary-color);
    height: 30px;
    padding: 0;
    padding-left: 10px;
    font-size: 0.7rem;
    display: block;
    font-family: var(--font-title);
    min-height: 30px;
    background-color: white;
}

#login-container>fieldset>div input:focus-visible {
    box-shadow: 4px 4px 0 var(--secondary-color);
    border-radius: 10px;
    border-color: var(--secondary-color);
    outline: 2px solid var(--secondary-color);
    outline-offset: -2px;
}

#main-content fieldset#user-card {
    border: 1px solid var(--primary-color);
    border-radius: 10px;
    padding: 1rem;
    box-shadow: 2px 2px 5px rgba(0, 0, 0, 0.1);
    display: flex;
}

.password-container {
    position: relative;
}

.password-container input {
    height: 100%;
}

.toggle-password {
    position: absolute;
    right: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
    top: 5px;
}

.toggle-password:focus {
    outline: none;
}

.toggle-password i {
    height: 20px;
    width: 20px;
    display: flex;
    justify-content: center;
    align-items: center;
    border-radius: 10px;
    background-color: rgba(0, 0, 0, 0.1);
}

.toggle-password i:hover {
    color: var(--accent-color);
    background-color: rgba(0, 0, 0, 0.2);
}

.toggle-password i.fa.fa-eye {
    color: var(--primary-color);
}

.toggle-password i.fa.fa-eye-slash {
    color: var(--secondary-color);
}