﻿/* Reset */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary: #009688;
    --primary-dark: #00796B;
    --gold: #FFD54F;
    --text: #ffffff;
    --muted: #d6d6d6;
    --glass: rgba(255, 255, 255, .12);
    --border: rgba(255, 255, 255, .18);
    --shadow: 0 20px 45px rgba(0, 0, 0, .45);
}

html,
body {
    width: 100%;
    min-height: 100vh;
    font-family: "Inter", sans-serif;
    overflow-x: hidden;
}

/* ================= ARRIÈRE-PLAN VIDÉO & OVERLAY ================= */

.bg-video {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    object-fit: cover;
    object-position: center;

    /* Étape 1 : Placé tout au fond */
    z-index: -2;
}

.video-overlay {
    position: fixed;
    /* Raccourci moderne pour top:0, left:0, right:0, bottom:0 */
    inset: 0;
    background: linear-gradient(rgba(0, 0, 0, 0.35), rgba(0, 0, 0, 0.65));

    /* Étape 2 : Placé JUSTE AU-DESSUS de la vidéo pour appliquer le filtre sombre */
    z-index: -1;

    /* Empêche ce calque invisible d'intercepter les clics de la souris ou du doigt */
    pointer-events: none;
}

/* Layout centering */
.login-container {
    width: 100%;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 30px;
}

/* Card */
.login-card {
    width: 100%;
    max-width: 430px;
    padding: 45px;
    border-radius: 30px;
    background: var(--glass);
    border: 1px solid var(--border);
    backdrop-filter: blur(22px);
    -webkit-backdrop-filter: blur(22px);
    box-shadow: var(--shadow);
    animation: fade .8s ease;
}

/* Logo */
.logo {
    text-align: center;
    margin-bottom: 35px;
}

.logo-circle {
    width: 95px;
    height: 95px;
    margin: auto;
    border-radius: 50%;
    background: transparent;
    display: flex;
    justify-content: center;
    align-items: center;
    box-shadow: 0 15px 35px rgba(0, 0, 0, .3);
    overflow: hidden;
}

.logo-circle img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    border-radius: 50%;
}

.logo h1 {
    margin-top: 20px;
    color: white;
    font-size: 34px;
    font-weight: 700;
}

.logo p {
    margin-top: 15px;
    color: var(--muted);
    line-height: 1.6;
    font-size: 15px;
}

/* Form */
.input-group {
    display: flex;
    align-items: center;
    gap: 15px;
    background: rgba(255, 255, 255, .12);
    border-radius: 15px;
    padding: 16px;
    margin-bottom: 18px;
    transition: .3s;
}

.input-group:hover {
    background: rgba(255, 255, 255, .18);
}

.input-group:focus-within {
    border: 1px solid var(--primary);
    box-shadow: 0 0 0 4px rgba(0, 150, 136, .25);
}

.input-group i {
    color: white;
    font-size: 18px;
}

.input-group input {
    flex: 1;
    border: none;
    outline: none;
    background: none;
    color: white;
    font-size: 15px;
}

.input-group input::placeholder {
    color: #dddddd;
}

/* Options */
.options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
    font-size: 14px;
    color: white;
}

.options label {
    display: flex;
    gap: 8px;
    align-items: center;
}

.options a {
    color: var(--gold);
    text-decoration: none;
}

/* Submit button */
button[type="submit"] {
    width: 100%;
    border: none;
    border-radius: 15px;
    padding: 16px;
    font-size: 16px;
    font-weight: 700;
    color: white;
    background: linear-gradient(135deg, #009688, #00796B);
    cursor: pointer;
    transition: .35s;
}

button[type="submit"]:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 35px rgba(0, 150, 136, .45);
}

/* Separator */
.separator {
    display: flex;
    align-items: center;
    margin: 30px 0;
    color: white;
}

.separator::before,
.separator::after {
    content: "";
    flex: 1;
    height: 1px;
    background: rgba(255, 255, 255, .25);
}

.separator span {
    margin: 0 15px;
}

/* Social buttons */
.social-buttons {
    display: flex;
    justify-content: center;
    gap: 18px;
}

.social {
    width: 55px;
    height: 55px;
    border: none;
    border-radius: 50%;
    background: rgba(255, 255, 255, .12);
    color: white;
    font-size: 20px;
    transition: .3s;
}

.social:hover {
    background: var(--primary);
    transform: translateY(-5px);
}

/* Register */
.register {
    margin-top: 30px;
    text-align: center;
    color: white;
}

.register a {
    color: var(--gold);
    text-decoration: none;
    font-weight: 700;
}

/* Error / success messages */
.error-message {
    margin-bottom: 18px;
    padding: 14px;
    border-radius: 12px;
    background: #ffdddd;
    color: #9b0000;
}

.success-message {
    margin-bottom: 18px;
    padding: 14px;
    border-radius: 12px;
    background: #ddffdd;
    color: #0a6b0a;
}

.success-message a {
    color: #0a6b0a;
    font-weight: 700;
    text-decoration: underline;
}

/* Animations */
@keyframes fade {
    from {
        opacity: 0;
        transform: translateY(40px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}


/* ==========================================
   LANGUAGE SWITCHER
========================================== */

.language-switcher {
    position: fixed;
    top: 25px;
    right: 25px;
    display: flex;
    gap: 4px;
    padding: 5px;
    background: rgba(255, 255, 255, .12);
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
    border: 1px solid rgba(255, 255, 255, .18);
    border-radius: 50px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, .25);
    z-index: 999;
}

.lang-pill {
    border: none;
    background: transparent;
    color: white;
    font-size: 14px;
    font-weight: 600;
    padding: 8px 16px;
    border-radius: 50px;
    cursor: pointer;
    transition: .25s;
}

.lang-pill:hover {
    background: rgba(255, 255, 255, .15);
}

/* Classe ajoutée automatiquement par i18n.js sur la langue active */
.lang-pill.is-active {
    background: var(--gold);
    color: #1b1b1b;
    box-shadow: 0 4px 12px rgba(255, 213, 79, .4);
}



.input-group.password-group {
    position: relative;
}

.input-group.password-group input {
    padding-right: 40px;
    /* laisse la place au bouton, sans chevaucher le texte */
}

.password-toggle-btn {
    position: absolute;
    top: 50%;
    right: 12px;
    transform: translateY(-50%);
    width: 26px;
    height: 26px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: none;
    background: transparent;
    color: inherit;
    opacity: 0.6;
    cursor: pointer;
    border-radius: 6px;
    transition: opacity .2s ease, background .2s ease;
}

.password-toggle-btn:hover {
    opacity: 1;
    background: rgba(0, 0, 0, 0.05);
}



@media(max-width:768px) {
    .language-switcher {
        top: 15px;
        right: 15px;
    }
}

.lang-btn:hover {
    background: rgba(255, 255, 255, .15);
}

/* Effet visuel de l'onglet actif */
.lang-btn.active {
    background: var(--gold);
    color: #1b1b1b;
    box-shadow: 0 4px 12px rgba(255, 213, 79, .4);
}

/* Tablet */
@media(max-width:900px) {
    .login-card {
        max-width: 480px;
    }
}

/* Mobile */
@media(max-width:768px) {
    .login-container {
        padding: 20px;
    }

    .login-card {
        padding: 30px;
        border-radius: 22px;
    }

    .logo h1 {
        font-size: 28px;
    }

    .logo-circle {
        width: 75px;
        height: 75px;
    }

    .language-toggle {
        top: 15px;
        right: 15px;
    }
}

/* Small phones */
@media(max-width:480px) {
    .login-card {
        padding: 22px;
    }

    .options {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }

    .social-buttons {
        gap: 12px;
    }

    .social {
        width: 48px;
        height: 48px;
    }

    .logo h1 {
        font-size: 24px;
    }

    .logo p {
        font-size: 14px;
    }
}


/*============= popup login google================*/

/* Container centré */
.google-suggest-popup {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 99999;
    pointer-events: none;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

/* Animation de descente depuis le haut */
.google-suggest-popup:not([hidden]) .google-suggest-content {
    animation: popFromTop 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards;
}

@keyframes popFromTop {
    0% {
        opacity: 0;
        transform: translateY(-120px) scale(0.9);
    }

    100% {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.google-suggest-popup[hidden] {
    display: none;
}

/* Carte principale */
.google-suggest-content {
    background: #ffffff;
    border-radius: 20px;
    padding: 32px 28px;
    max-width: 360px;
    width: 90%;
    text-align: center;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.15);
    position: relative;
    pointer-events: auto;
}

/* Bouton Fermer */
.google-suggest-close {
    position: absolute;
    top: 14px;
    right: 14px;
    background: transparent;
    border: none;
    font-size: 20px;
    color: #9aa0a6;
    cursor: pointer;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s, color 0.2s;
}

.google-suggest-close:hover {
    background: #f1f3f4;
    color: #202124;
}

/* Zone Mascotte Émoji */
.emoji-mascot {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-size: 48px;
    margin-bottom: 8px;
    user-select: none;
    transition: transform 0.25s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.emoji-face,
.emoji-hand {
    display: inline-block;
    transition: transform 0.2s ease;
}

/* Effet d'excitation au survol proche du bouton */
.emoji-mascot.love {
    transform: scale(1.15);
}

.emoji-mascot.love .emoji-face {
    animation: heartBeat 0.6s infinite alternate ease-in-out;
}

@keyframes heartBeat {
    0% {
        transform: scale(1);
    }

    100% {
        transform: scale(1.1);
    }
}

/* Texte */
.google-suggest-content p {
    font-size: 15px;
    font-weight: 500;
    color: #3c4043;
    margin: 12px 0 24px;
    line-height: 1.4;
}

/* Bouton CTA */
.google-suggest-cta {
    background: #1a73e8;
    color: #ffffff;
    border: none;
    padding: 12px 20px;
    font-size: 14px;
    font-weight: 600;
    border-radius: 10px;
    cursor: pointer;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    box-shadow: 0 2px 6px rgba(26, 115, 232, 0.25);
    transition: background 0.2s, transform 0.1s, box-shadow 0.2s;
}

.google-suggest-cta:hover {
    background: #1557b0;
    box-shadow: 0 4px 12px rgba(26, 115, 232, 0.35);
}

.google-suggest-cta:active {
    transform: scale(0.98);
}




/* ================= GESTION FOND MOBILE / DESKTOP ================= */
@media (max-width: 768px) {

    /* 1. Masque l'élément vidéo sur smartphone pour économiser la batterie et les données */
    .bg-video {
        display: none;
    }

    /* 2. Applique l'image de fond sur le body */
    body {
        background-image: url("https://encrypted-tbn0.gstatic.com/images?q=tbn:ANd9GcSs-sHfI5buCZPqYJ0xKVcscTFobqZQkJFvgV9algfYAOJ7fJbrIiu4F_Q&s=10");
        background-size: cover;
        background-position: center;
        background-repeat: no-repeat;
        background-attachment: fixed;
    }
}