/* =========================================================
   FMER Webmail - Page de connexion
   ========================================================= */

/* =========================================================
   FOND
   ========================================================= */

body.task-login {
    background: linear-gradient(
        135deg,
        #0f172a 0%,
        #1e3a5f 50%,
        #2563eb 100%
    );

    min-height: 100vh;
}

/* Supprime le fond éventuel d'Elastic */
body.task-login #layout {
    background: transparent;
}

/* =========================================================
   ZONE PRINCIPALE
   ========================================================= */

body.task-login #layout-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;

    width: 100%;
    min-height: 100vh;

    padding: 40px 20px;
    box-sizing: border-box;
}

/* =========================================================
   LOGO FMER
   ========================================================= */

/*
 * Elastic définit par défaut :
 *
 *     max-height: 100px;
 *
 * On l'annule ici avec !important.
 */

body.task-login #logo {
    display: block !important;

    position: static !important;

    width: 420px !important;
    height: auto !important;

    max-width: 90vw !important;
    max-height: none !important;

    margin: 0 auto 30px auto !important;
    padding: 0 !important;

    background: transparent !important;

    border: 0 !important;
    border-radius: 0 !important;

    box-shadow: none !important;

    object-fit: contain;
}

/* =========================================================
   FORMULAIRE DE CONNEXION
   ========================================================= */

body.task-login #login-form {
    position: static !important;

    width: 100%;
    max-width: 380px;

    margin: 0 auto;

    padding: 30px;

    box-sizing: border-box;

    background: rgba(255, 255, 255, 0.98);

    border-radius: 16px;

    box-shadow:
        0 20px 50px rgba(0, 0, 0, 0.30);
}

/* =========================================================
   CHAMPS
   ========================================================= */

body.task-login #login-form input[type="text"],
body.task-login #login-form input[type="email"],
body.task-login #login-form input[type="password"] {
    width: 100%;

    box-sizing: border-box;

    padding: 12px 14px;

    border: 1px solid #d1d5db;

    border-radius: 8px;

    font-size: 15px;

    transition:
        border-color 0.2s ease,
        box-shadow 0.2s ease;
}

/* Focus */

body.task-login #login-form input[type="text"]:focus,
body.task-login #login-form input[type="email"]:focus,
body.task-login #login-form input[type="password"]:focus {
    border-color: #2563eb;

    outline: none;

    box-shadow:
        0 0 0 3px rgba(37, 99, 235, 0.15);
}

/* =========================================================
   BOUTON CONNEXION
   ========================================================= */

body.task-login #rcmloginsubmit {
    width: 100%;

    padding: 12px 20px;

    border: 0;
    border-radius: 8px;

    background: #2563eb;

    color: #ffffff;

    font-size: 15px;
    font-weight: 600;

    cursor: pointer;

    transition:
        background 0.2s ease,
        transform 0.1s ease;
}

/* Hover */

body.task-login #rcmloginsubmit:hover {
    background: #1d4ed8;
}

/* Clic */

body.task-login #rcmloginsubmit:active {
    transform: translateY(1px);
}

/* =========================================================
   FOOTER DU FORMULAIRE
   ========================================================= */

/*
 * Attention :
 * #login-footer est DANS #login-form.
 *
 * Le formulaire étant blanc, le texte doit être sombre.
 */

body.task-login #login-footer {
    margin-top: 20px;

    color: #64748b;

    font-size: 12px;

    text-align: center;
}

body.task-login #login-footer a {
    color: #2563eb;

    text-decoration: none;
}

body.task-login #login-footer a:hover {
    text-decoration: underline;
}

/* =========================================================
   MOBILE
   ========================================================= */

@media (max-width: 480px) {

    body.task-login #layout-content {
        padding: 25px 15px;
    }

    body.task-login #logo {
        width: 260px !important;

        max-width: 85vw !important;

        margin-bottom: 20px !important;
    }

    body.task-login #login-form {
        max-width: 100%;

        padding: 22px;

        border-radius: 12px;
    }
}

/* =========================================================
   TRÈS PETITS ÉCRANS
   ========================================================= */

@media (max-width: 360px) {

    body.task-login #logo {
        width: 220px !important;
    }

    body.task-login #login-form {
        padding: 18px;
    }
}
