/**
 * Style de la page connexion — Redesign Premium
 * @author Shawn Dutil
 */

/* ===========================
   LAYOUT
=========================== */
.container_contenu_NousJoindre {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 72px 32px;
    background: var(--creme);
    min-height: calc(100vh - var(--navbar-h));
    width: 100%;
}

/* ===========================
   CARTE CONNEXION
=========================== */
.sous_container_connexion {
    width: 100%;
    max-width: 440px;
    background: #fff;
    border-radius: 2px;
    border-top: 2px solid var(--or);
    box-shadow: 0 4px 40px rgba(0, 0, 0, 0.1);
    padding: 52px 48px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0;
    position: relative;
}

/* Fleur de lys décorative en filigrane */
.sous_container_connexion::before {
    content: '';
    position: absolute;
    top: 20px;
    right: 24px;
    width: 48px;
    height: 48px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 48 56' fill='none'%3E%3Cpath d='M24 2C20 8 12 10 12 18C12 26 20 28 24 34C28 28 36 26 36 18C36 10 28 8 24 2Z' stroke='%23c9a84c' stroke-width='1.2'/%3E%3Cpath d='M24 34C21 37 16 38 15 42L33 42C32 38 27 37 24 34Z' stroke='%23c9a84c' stroke-width='1.2'/%3E%3Ccircle cx='24' cy='18' r='3' stroke='%23c9a84c' stroke-width='1'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-size: contain;
    opacity: 0.1;
    pointer-events: none;
}

/* ===========================
   TITRE
=========================== */
.sous_container_connexion h2 {
    font-family: 'Playfair Display', serif;
    font-size: 1.8rem;
    font-weight: 400;
    font-style: italic;
    color: var(--vert-profond);
    text-align: center;
    margin: 0 0 8px 0;
    width: 100%;
}

.sous_container_connexion h2::after {
    content: '';
    display: block;
    width: 60px;
    height: 1px;
    background: linear-gradient(to right, transparent, var(--or), transparent);
    margin: 14px auto 0;
}

/* ===========================
   MESSAGES
=========================== */
.container_message {
    width: 100%;
    margin-top: 20px;
}

.message.erreur,
.message-erreur {
    font-family: 'Raleway', sans-serif;
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    background: #fdf0f0;
    color: #8b2020;
    border-left: 3px solid #e53935;
    padding: 12px 16px;
    border-radius: 2px;
    margin-top: 16px;
    width: 100%;
}

/* ===========================
   FORMULAIRE
=========================== */
.form_connexion {
    display: flex;
    flex-direction: column;
    gap: 0;
    width: 100%;
    margin-top: 28px;
}

.form_connexion label {
    font-family: 'Raleway', sans-serif;
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--vert-profond);
    margin-bottom: 6px;
    display: block;
}

.username-container,
.password-container {
    margin-bottom: 20px;
}

.form_connexion #username,
.form_connexion #courriel,
.form_connexion #password {
    font-family: 'Raleway', sans-serif;
    font-size: 0.9rem;
    font-weight: 400;
    color: var(--texte-sombre);
    background: var(--creme);
    border: 1px solid rgba(0, 0, 0, 0.12);
    border-radius: 2px;
    padding: 13px 16px;
    width: 100%;
    box-sizing: border-box;
    outline: none;
    transition: border-color 0.25s ease, box-shadow 0.25s ease, background 0.25s ease;
}

.form_connexion #username:focus,
.form_connexion #courriel:focus,
.form_connexion #password:focus {
    border-color: var(--or);
    background: #fff;
    box-shadow: 0 0 0 3px rgba(201, 168, 76, 0.15);
}

/* Erreurs champs */
.error-container { min-height: 16px; }

.error-message-connexion {
    font-family: 'Raleway', sans-serif;
    font-size: 0.7rem;
    font-weight: 600;
    color: #c0392b;
    letter-spacing: 0.04em;
}

/* Se souvenir */
.remember-checkbox {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 12px;
    cursor: pointer;
    user-select: none;
}

.remember-checkbox label {
    font-family: 'Raleway', sans-serif;
    font-size: 0.78rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    color: #666;
    cursor: pointer;
    margin: 0;
    text-transform: none;
}

.form_connexion #remember {
    width: 16px;
    height: 16px;
    accent-color: var(--or);
    cursor: pointer;
    flex-shrink: 0;
}

/* Lien mot de passe oublié */
.form_connexion > a {
    font-family: 'Raleway', sans-serif;
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    color: var(--vert-moyen);
    text-decoration: none;
    align-self: flex-end;
    margin-bottom: 24px;
    border-bottom: 1px solid rgba(58, 90, 58, 0.3);
    transition: color 0.2s ease, border-color 0.2s ease;
}

.form_connexion > a:hover {
    color: var(--or);
    border-bottom-color: var(--or);
}

/* Bouton Se connecter */
.bouton_connexion {
    color: var(--vert-profond);
    font-family: 'Raleway', sans-serif;
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    background: linear-gradient(135deg, var(--or) 0%, var(--or-clair) 100%);
    border: none;
    border-radius: 2px;
    padding: 16px;
    width: 100%;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    transition: transform 0.25s ease, box-shadow 0.25s ease;
    box-shadow: 0 4px 16px rgba(201, 168, 76, 0.35);
}

.bouton_connexion::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, var(--or-clair) 0%, var(--or) 100%);
    opacity: 0;
    transition: opacity 0.25s ease;
}

.bouton_connexion:hover {
    color: #fff;
    transform: translateY(-2px);
    box-shadow: 0 8px 28px rgba(201, 168, 76, 0.5);
}

.bouton_connexion:active { transform: translateY(0); }

/* ===========================
   RESPONSIVE
=========================== */
@media (max-width: 500px) {
    .sous_container_connexion { padding: 36px 24px; }
    .sous_container_connexion h2 { font-size: 1.5rem; }
}