/* Style global pour l'application Gellies B2B */

/* Police Nunito */
@import url('https://fonts.googleapis.com/css2?family=Nunito:wght@300;400;600;700;900&display=swap');

/* Variables de couleurs */
:root {
    --primary-blue: #74BDEE;
    --dark-blue: #2E496A;
    --secondary-blue: #334f77; /* Couleur utilisée pour le sélecteur de langue */
    --light-gray: #f8f9fa;
    --white: #ffffff;
    --danger: #d32f2f;
    --danger-light: #ffe5e5;
    --success-green: #61C977;
}

/* Reset et base */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Nunito', sans-serif;
}

body {
    background-color: var(--primary-blue);
    min-height: 100vh;
}

/* Page de connexion */
.login-page {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
}

.login-container {
    max-width: 500px;
    width: 90%;
    padding: 40px;
    background-color: var(--white);
    border-radius: 10px;
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.1);
    text-align: center;
}

/* Logo et en-tête */
.logo {
    margin-bottom: 30px;
}

.logo img {
    max-width: 120px;
    height: auto;
}

h1 {
    color: var(--dark-blue);
    font-size: 2.5rem;
    margin-bottom: 10px;
    font-weight: 700;
}

.subtitle {
    color: var(--dark-blue);
    margin-bottom: 30px;
    font-size: 1rem;
}

/* Formulaires */
.form-group {
    position: relative;
    margin-bottom: 20px;
    text-align: left;
}

.form-group .icon {
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--primary-blue);
}

.form-control {
    width: 100%;
    padding: 15px 15px 15px 45px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-size: 1rem;
    transition: border-color 0.3s;
    outline: none;
}

.form-control:focus {
    border-color: var(--primary-blue);
}

/* Boutons */
.btn-primary {
    width: 100%;
    padding: 15px;
    background-color: var(--dark-blue);
    color: var(--white);
    border: none;
    border-radius: 5px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.btn-primary:hover {
    background-color: #1c3049;
}

.btn-secondary {
    width: 100%;
    padding: 15px;
    background-color: transparent;
    color: var(--primary-blue);
    border: 1px solid var(--primary-blue);
    border-radius: 5px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    margin-top: 10px;
    transition: background-color 0.3s;
}

.btn-secondary:hover {
    background-color: #f0f8ff;
}

/* Messages d'alerte */
.alert-danger {
    background-color: var(--danger-light);
    color: var(--danger);
    padding: 10px;
    border-radius: 5px;
    margin-bottom: 20px;
    font-size: 0.9rem;
}

/* Chargement */
.loading {
    display: none;
    text-align: center;
    margin-top: 10px;
}

/* Texte d'aide */
.help-text {
    margin-top: 20px;
    color: #888;
    font-size: 0.9rem;
}

.help-text a {
    color: var(--primary-blue);
    text-decoration: none;
}

.help-text a:hover {
    text-decoration: underline;
}

/* Emoji vague */
.wave-emoji {
    font-size: 1.5rem;
    margin-left: 5px;
}

/* Navigation principale */
.navbar {
    background-color: var(--dark-blue);
    padding: 15px 0;
}

.navbar-brand {
    color: var(--white);
    font-weight: 700;
    font-size: 1.5rem;
}

.navbar-text {
    color: rgba(255, 255, 255, 0.8);
}

/* Dashboard */
.dashboard-container {
    padding: 30px 15px;
}

.card {
    border-radius: 10px;
    box-shadow: 0 0 15px rgba(0, 0, 0, 0.1);
    margin-bottom: 20px;
}

.card-header {
    background-color: var(--dark-blue);
    color: var(--white);
    font-weight: 600;
    padding: 15px 20px;
    border-radius: 10px 10px 0 0;
}

.card-body {
    padding: 20px;
}

/* Adaptation mobile */
@media (max-width: 768px) {
    .login-container {
        width: 95%;
        padding: 30px 20px;
    }
    
    h1 {
        font-size: 2rem;
    }
}

/* Styles pour les modals */
.modal-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 1000;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(2px);
    animation: fadeIn 0.2s;
}

.modal {
    background-color: white;
    border-radius: 8px;
    max-width: 500px;
    width: 90%;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
    overflow: hidden;
    animation: slideIn 0.3s;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes slideIn {
    from { transform: translateY(-20px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

.modal-header {
    background-color: var(--dark-blue);
    color: white;
    padding: 15px 20px;
    font-weight: 600;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h3 {
    margin: 0;
    font-size: 1.2rem;
}

.modal-body {
    padding: 20px;
}

.close-btn {
    background: none;
    border: none;
    color: white;
    font-size: 1.5rem;
    cursor: pointer;
    opacity: 0.8;
    transition: opacity 0.2s;
}

.close-btn:hover {
    opacity: 1;
}

/* Styles pour les alertes */
.alert {
    padding: 12px 15px;
    border-radius: 5px;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
}

.alert::before {
    margin-right: 10px;
    font-size: 1.2rem;
}

.alert-success {
    background-color: #d4edda;
    border: 1px solid #c3e6cb;
    color: #155724;
}

.alert-success::before {
    content: "✅";
}

.alert-danger {
    background-color: #f8d7da;
    border: 1px solid #f5c6cb;
    color: #721c24;
}

.alert-danger::before {
    content: "❌";
}

.alert-warning {
    background-color: #fff3cd;
    border: 1px solid #ffeeba;
    color: #856404;
}

.alert-warning::before {
    content: "⚠️";
}

.alert-info {
    background-color: #d1ecf1;
    border: 1px solid #bee5eb;
    color: #0c5460;
}

.alert-info::before {
    content: "ℹ️";
}

/* Styles pour la vérification de force du mot de passe */
.password-strength {
    margin-top: 15px;
    padding: 15px;
    background-color: #f9fafb;
    border: 1px solid #e3e3e3;
    border-radius: 6px;
    font-size: 0.9rem;
}

.password-strength p {
    font-weight: 600;
    margin-bottom: 8px;
    color: var(--dark-blue);
}

.password-strength li {
    padding: 4px 0;
    display: flex;
    align-items: center;
    gap: 6px;
}

.password-strength li::before {
    content: "\2022";
    font-size: 1rem;
    line-height: 1;
}

.password-strength li.valid::before {
    content: "\2714"; /* ✓ */
    color: #28a745;
}

.password-strength li.valid {
    color: #28a745;
}

/* Utilitaires */
.mt-3 {
    margin-top: 15px;
}

.text-center {
    text-align: center;
}

.form-links {
    margin-top: 15px;
    text-align: center;
    font-size: 0.9rem;
}

.form-links a {
    color: #666;
    text-decoration: none;
    transition: color 0.2s;
}

.form-links a:hover {
    color: var(--primary-blue);
    text-decoration: underline;
}

/* Styles pour l'input du code d'authentification */
input[name="code"] {
    letter-spacing: 0.5em;
    font-size: 1.2em;
    text-align: center;
    font-weight: 600;
}

.mb-3 {
    margin-bottom: 15px;
}

/* Sélecteur de langue */
.lang-selector {
    position: absolute !important;
    top: 20px !important;
    right: 20px !important;
    display: flex !important;
    gap: 2px !important;
    z-index: 10 !important;
    background-color: rgba(240, 240, 240, 0.8) !important;
    border-radius: 6px !important;
    padding: 2px !important;
   
}

.lang-btn {
    font-size: 12px !important;
    font-weight: 600 !important;
    color: #333 !important;
    text-decoration: none !important;
    padding: 4px 8px !important;
    border-radius: 4px !important;
    transition: all 0.2s ease !important;
    border: none !important;
    letter-spacing: 0.5px !important;
}

.lang-btn:hover {
    background-color: #e9e9e9 !important;
    color: var(--secondary-blue) !important;
}

.lang-btn.active {
    background-color: var(--secondary-blue) !important;
    color: white !important;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1) !important;
}

@media (max-width: 768px) {
    .lang-selector {
        top: 10px !important;
        right: 10px !important;
    }
    .lang-btn {
        font-size: 11px !important;
        padding: 3px 6px !important;
    }
}

/* Styles pour le footer */
footer {
    background-color: #f8f9fa;
    padding: 40px 0 0 0;
    margin-top: 60px;
    border-top: 1px solid #e0e0e0;
}

.footer-container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 30px;
    position: relative;
}

.footer-contact {
    margin-bottom: 30px;
}

.footer-contact p {
    font-size: 16px;
    line-height: 1.6;
    color: #333;
}

.footer-legal {
    font-size: 14px;
    color: #666;
    line-height: 1.6;
}

.footer-links {
    margin: 20px 0;
}

.footer-links a {
    color: #2E496A;
    text-decoration: none;
}

.footer-links a:hover {
    text-decoration: underline;
}

.copyright {
    margin-top: 20px;
    font-size: 12px;
    color: #999;
    margin-bottom: 30px;
}

@media (max-width: 768px) {
    footer {
        padding: 30px 0 0 0;
        margin-top: 30px;
    }
    
    .footer-container {
        padding: 0 20px;
    }
    
    .footer-contact p,
    .footer-legal {
        font-size: 14px;
    }
    
    .footer-links {
        margin: 15px 0;
    }
    
    .copyright {
        margin-top: 15px;
        margin-bottom: 20px;
    }
}

/* Styles pour le sélecteur de langue du footer */
#language-selector {
    background-color: #f8f9fa;
    text-align: center;
    padding: 12px 0;
    border-top: 1px solid #e0e0e0;
    box-shadow: 0 -2px 10px rgba(0,0,0,0.05);
}

#language-selector > div {
    max-width: 1280px;
    margin: 0 auto;
    display: flex;
    justify-content: center;
    gap: 10px;
}

#language-selector a {
    color: #666;
    text-decoration: none;
    padding: 8px 15px;
    font-size: 14px;
    border-radius: 4px;
    transition: all 0.2s ease;
    background-color: #f0f0f0;
}

#language-selector a.active {
    font-weight: bold;
    color: white;
    background-color: #2E496A;
}

@media (max-width: 768px) {
    #language-selector {
        padding: 10px 0;
        position: static;
        width: 100%;
        display: block;
    }
    
    #language-selector a {
        padding: 6px 12px;
        font-size: 13px;
        display: inline-block;
    }
}