/* ======================= */
/*  BACKGROUND + THEME     */
/* ======================= */
.bg-overlay {
    min-height: 100vh;
    position: relative
}

.bg-overlay::before {
    content: "";
    position: fixed;
    inset: 0;
    background: #0b0e11 url('../img/stadium.jpg') center/cover no-repeat fixed;
    filter: brightness(.52) saturate(1.05);
    z-index: -2
}

.bg-overlay::after {
    content: "";
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, .35);
    z-index: -1
}

/* ======================= */
/*  GLASS PREMIUM          */
/* ======================= */
.glass-card {
    background: rgba(255, 255, 255, .16) !important;
    border: 1px solid rgba(255, 255, 255, .28) !important;
    border-radius: 14px;
    backdrop-filter: blur(8px);
    box-shadow: 0 10px 26px rgba(0, 0, 0, .28)
}

.glass-card-strong {
    background: rgba(255, 255, 255, .22) !important;
    border-color: rgba(255, 255, 255, .32) !important;
    box-shadow: 0 12px 30px rgba(0, 0, 0, .34)
}

/* ======================= */
/*  NAV / PILLS            */
/* ======================= */
.nav-username-pill {
    background: #28c76f;
    color: #fff;
    padding: 6px 14px;
    border-radius: 18px;
    font-size: .9rem;
    font-weight: 600;
    border: 1px solid rgba(255, 255, 255, .25)
}

/* ======================= */
/*  FORUM BUBBLES          */
/* ======================= */
.chat-row {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    margin-bottom: 18px
}

.chat-right {
    justify-content: flex-end
}

.chat-avatar {
    width: 42px;
    height: 42px;
    min-width: 42px;
    border-radius: 50%;
    background: rgba(255, 255, 255, .15);
    border: 1px solid rgba(255, 255, 255, .25);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700
}

.chat-col {
    display: flex;
    flex-direction: column;
    max-width: 75%
}

.chat-left .chat-col {
    align-items: flex-start
}

.chat-right .chat-col {
    align-items: flex-end
}

.chat-bubble {
    width: 100%;
    border-radius: 14px;
    padding: 10px 12px;
    color: #fff;
    background: rgba(255, 255, 255, .10);
    border: 1px solid rgba(255, 255, 255, .18);
    backdrop-filter: blur(6px)
}

.chat-right .chat-bubble {
    background: rgba(13, 110, 253, .25);
    border-color: rgba(13, 110, 253, .38)
}

.chat-author {
    font-weight: 600;
    margin-bottom: 4px;
    opacity: .95
}

.chat-text {
    line-height: 1.45;
    margin-bottom: 6px
}

/* ======================= */
/*  TENDANCES              */
/* ======================= */
.tendance-box-v2 {
    background: rgba(255, 255, 255, .08);
    border: 1px solid rgba(255, 255, 255, .12);
    padding: 12px;
    border-radius: 12px;
    backdrop-filter: blur(8px)
}

.tendance-values {
    display: flex;
    justify-content: space-between;
    font-size: .85rem;
    color: #fff;
    margin-bottom: 8px
}

.tendance-bar-v2 {
    display: flex;
    height: 8px;
    border-radius: 8px;
    overflow: hidden;
    background: rgba(255, 255, 255, .14)
}

.tendance-bar-v2>div {
    height: 100%;
    transition: width .4s ease
}

.home-fill {
    background: rgba(77, 184, 255, .9) !important
}

.draw-fill {
    background: rgba(220, 220, 220, .95) !important
}

.away-fill {
    background: rgba(255, 107, 107, .9) !important
}



/* ======================= */
/*  DASHBOARD options      */
/* ======================= */
.dashboard-opaque .glass-card {
    background: rgba(255, 255, 255, .20) !important;
    border-color: rgba(255, 255, 255, .30) !important;
    box-shadow: 0 12px 28px rgba(0, 0, 0, .32) !important
}

.dashboard-opaque-strong .glass-card {
    background: rgba(255, 255, 255, .26) !important;
    border-color: rgba(255, 255, 255, .34) !important;
    box-shadow: 0 14px 32px rgba(0, 0, 0, .36) !important
}

@media (max-width:576px) {
    .chat-col {
        max-width: 85%
    }
}

.dashboard-number {
    padding-left: 10px;
    padding-top: 10px;
}



/* Fond gris semi-transparent */
.popup-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.4);
    justify-content: center;
    align-items: center;
}

/* Boîte de la pop-up */
.popup-box {
    background: white;
    padding: 20px 30px;
    border-radius: 10px;
    width: 300px;
    text-align: center;
    box-shadow: 0 0 15px rgba(0, 0, 0, 0.3);
}

.close-btn {
    margin-top: 15px;
    padding: 8px 20px;
    background: #d9534f;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
}

/* ===== Reactions (iPhone-like) ===== */
.react-trigger {
    position: absolute;
    right: 8px;
    top: 8px;
    opacity: .0;
    transition: opacity .2s ease;
    border: none;
    background: transparent;
    color: #fff;
    cursor: pointer;
    font-size: 14px;
    line-height: 1;
}

.chat-left .chat-bubble:hover .react-trigger {
    opacity: .8;
}

.reaction-picker {
    position: absolute;
    display: none;
    gap: 10px;
    padding: 8px 10px;
    border-radius: 20px;
    background: rgba(255, 255, 255, .18);
    border: 1px solid rgba(255, 255, 255, .28);
    backdrop-filter: blur(8px);
    box-shadow: 0 10px 26px rgba(0, 0, 0, .28);
    z-index: 9999;
    transform: scale(.96);
    transition: transform .12s ease, opacity .12s ease;
    opacity: 0;
}

.reaction-picker.show {
    transform: scale(1);
    opacity: 1;
}

.reaction-btn {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(255, 255, 255, .35);
    background: rgba(255, 255, 255, .22);
    color: #111;
    cursor: pointer;
    transition: transform .1s ease, background .2s ease;
}

.reaction-btn:hover {
    transform: translateY(-2px);
    background: rgba(255, 255, 255, .30);
}

.reaction-btn .emoji {
    font-size: 18px;
}

.reactions-bar {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-top: 6px;
}

.reaction-chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 8px;
    border-radius: 14px;
    background: rgba(255, 255, 255, .14);
    border: 1px solid rgba(255, 255, 255, .26);
    color: #fff;
    font-size: 12px;
}

.reaction-chip .emoji {
    font-size: 15px;
    line-height: 1;
}

.reaction-chip.active {
    background: rgba(13, 110, 253, .28);
    border-color: rgba(13, 110, 253, .42);
}

.reactions-bar .remove-my-reaction {
    margin-left: 4px;
    border: none;
    background: transparent;
    color: #fff;
    font-size: 14px;
    opacity: .7;
    cursor: pointer;
}

.reactions-bar .remove-my-reaction:hover {
    opacity: 1;
}

/* ancre les éléments positionnés (smiley / picker) par rapport à la bulle */
.chat-bubble {
    position: relative;
}

/* le bouton smiley doit être cliquable et visible au hover */
.react-trigger {
    position: absolute;
    right: 8px;
    top: 8px;
    opacity: .0;
    transition: opacity .2s ease;
    border: none;
    background: transparent;
    color: #fff;
    cursor: pointer;
    font-size: 14px;
    line-height: 1;
}

.chat-left .chat-bubble:hover .react-trigger {
    opacity: .85;
}

/* le picker doit passer au-dessus du contenu */
.reaction-picker {
    position: absolute;
    display: none;
    gap: 10px;
    padding: 8px 10px;
    border-radius: 20px;
    background: rgba(255, 255, 255, .18);
    border: 1px solid rgba(255, 255, 255, .28);
    backdrop-filter: blur(8px);
    box-shadow: 0 10px 26px rgba(0, 0, 0, .28);
    z-index: 9999;
    /* IMPORTANT */
    transform: scale(.96);
    transition: transform .12s ease, opacity .12s ease;
    opacity: 0;
}

.reaction-picker.show {
    transform: scale(1);
    opacity: 1;
}

.reaction-btn {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(255, 255, 255, .35);
    background: rgba(255, 255, 255, .22);
    color: #111;
    cursor: pointer;
    transition: transform .1s ease, background .2s ease;
}

.reaction-btn:hover {
    transform: translateY(-2px);
    background: rgba(255, 255, 255, .30);
}

.reaction-btn .emoji {
    font-size: 18px;
}

/* Barre Teams */
.teams-reaction-bar {
    display: flex;
    gap: 6px;
    position: absolute;
    top: -32px;
    left: 20px;
    background: rgba(255, 255, 255, 0.20);
    padding: 6px 8px;
    border-radius: 20px;
    backdrop-filter: blur(6px);
    border: 1px solid rgba(255, 255, 255, 0.30);
    opacity: 0;
    pointer-events: none;
    transition: opacity .15s ease;
}

.chat-left .chat-bubble:hover+.teams-reaction-bar {
    opacity: 1;
    pointer-events: auto;
}

.teams-react {
    font-size: 20px;
    cursor: pointer;
    transition: transform .12s ease;
}

.teams-react:hover {
    transform: scale(1.25);
}

/* Résumé sous la bulle */
.teams-reaction-summary {
    margin-top: 5px;
    font-size: 18px;
    display: flex;
    gap: 4px;
}

/* Ancrage : le positionnement absolu se fera par rapport à .chat-col */
.chat-col {
    position: relative;
}

/* Barre Teams cachée par défaut */
.teams-reaction-bar {
    position: absolute;
    top: -32px;
    /* au-dessus de la bulle */
    left: 16px;
    display: flex;
    gap: 6px;
    padding: 6px 8px;
    border-radius: 20px;

    background: rgba(255, 255, 255, 0.20);
    border: 1px solid rgba(255, 255, 255, 0.30);
    backdrop-filter: blur(6px);
    box-shadow: 0 10px 26px rgba(0, 0, 0, 0.28);

    opacity: 0;
    pointer-events: none;
    /* pas cliquable tant qu’elle est cachée */
    transition: opacity .15s ease;
    z-index: 5;
    /* au-dessus de la bulle */
}

/* Affiche la barre au survol de la colonne (gauche uniquement) */
.chat-left .chat-col:hover .teams-reaction-bar {
    opacity: 1;
    pointer-events: auto;
    /* redevient cliquable */
}

.teams-react {
    font-size: 20px;
    cursor: pointer;
    transition: transform .12s ease;
}

.teams-react:hover {
    transform: scale(1.25);
}

/* Résumé sous la bulle */
.teams-reaction-summary {
    margin-top: 6px;
    font-size: 16px;
    display: flex;
    gap: 6px;
    color: #fff;
    /* ton thème est sur fond sombre */
}

/* IMPORTANT pour l’ancrage de boutons/éléments au sein de la bulle */
.chat-bubble {
    position: relative;
}

/* Chip actif (ta réaction) */
.reaction-chip.active {
    background: rgba(13, 110, 253, .28);
    border: 1px solid rgba(13, 110, 253, .45);
    box-shadow: 0 0 0 2px rgba(13, 110, 253, .15) inset;
}

.mobile-tooltip {
    position: absolute;
    bottom: 32px;
    left: 50%;
    transform: translateX(-50%);
    padding: 8px 12px;
    background: rgba(0, 0, 0, 0.85);
    color: #fff;
    font-size: 13px;
    border-radius: 8px;
    white-space: nowrap;
    z-index: 9999;
    opacity: 0;
    pointer-events: none;
    transition: opacity .15s ease;
}

.mobile-tooltip.show {
    opacity: 1;
}

/* Carte premium – liseré bleu dégradé (animation discrète) */
.ranking-card.is-me {
    position: relative;
    border-radius: 14px;
    /* même rayon que .glass-card */
    overflow: visible;
    /* pour voir le halo autour */
}

.ranking-card.is-me::before {
    content: "";
    position: absolute;
    inset: -2px;
    /* déborde légèrement de la carte */
    z-index: -1;
    /* derrière la carte */
    border-radius: 16px;
    /* un peu plus que la carte */
    background:
        conic-gradient(from 180deg,
            rgba(77, 184, 255, .85),
            rgba(142, 188, 255, .75),
            rgba(30, 144, 255, .85),
            rgba(77, 184, 255, .85));
    filter: blur(6px) saturate(1.1);
    opacity: .55;
    animation: rankGlow 6s linear infinite;
}

/* Bordure interne nette pour découper le glow */
.ranking-card.is-me::after {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: 14px;
    border: 1.5px solid rgba(77, 184, 255, .90);
    box-shadow: 0 0 0 1px rgba(255, 255, 255, .06) inset;
    pointer-events: none;
}

/* éviter que l’ancre soit cachée sous un header fixe */
#me {
    scroll-margin-top: 250px;
}

/* adapte 80px à la hauteur de ton header */
.ranking-card.is-me,
tr.is-me {
    scroll-margin-top: 250px;
}

/* Rendre visible l'icône "œil" du bouton mot de passe */
#togglePassword i.bi,
#togglePassword svg {
    color: #eaf2ff !important;
    /* couleur claire lisible sur fond dark */
    opacity: 1 !important;
    filter: none !important;
    mix-blend-mode: normal !important;
}

/* Si tu utilises un <i class="bi ...">, assure sa taille */
#togglePassword i.bi {
    font-size: 1.1rem;
    line-height: 1;
}

/* Forcer le contraste sur un bouton outline sur fond sombre */
#togglePassword.btn.btn-outline-secondary {
    --bs-btn-color: #eaf2ff;
    --bs-btn-border-color: rgba(255, 255, 255, .45);
    --bs-btn-hover-bg: rgba(255, 255, 255, .12);
    --bs-btn-hover-border-color: rgba(255, 255, 255, .6);
}

/* 1) Le wrapper du champ doit être relatif pour l'absolu du bouton */
.input-group,
.password-wrapper,
.form-floating {
    position: relative;
}

/* 2) Rendre l'icône bien visible et au-dessus */
.toggle-password {
    z-index: 5;
    /* au-dessus de l'input */
}

.toggle-password svg {
    display: block;
    color: #000000;
    /* currentColor pour fill="currentColor" */
    opacity: 1;
    filter: none;
    mix-blend-mode: normal;
}

/* 3) Évite que l'icône chevauche le texte du champ */
input[type="password"],
input[type="text"].showing-password,
.form-control[type="password"] {
    padding-right: 2.5rem;
    /* laisse la place au bouton à droite */
}

/* 4) Si un parent coupe le contenu, on s'assure de voir l'œil */
.input-group,
.form-control,
.glass-card {
    overflow: visible;
    /* si tu avais overflow:hidden, il peut couper l'icône */
}

.group-card .card-header {
    background: rgba(255, 255, 255, .06);
    border-bottom: 1px solid rgba(255, 255, 255, .12);
}

.group-table th,
.group-table td {
    vertical-align: middle;
}

.table-success-lite {
    background: rgba(77, 184, 255, .08) !important;
}

.badge.bg-gradient-primary {
    background: linear-gradient(135deg, #4da6ff, #1e90ff);
    border: 1px solid rgba(255, 255, 255, .25);
}

/* drapeau */
.flag {
    width: 26px;
    height: 18px;
    object-fit: cover;
    border-radius: 3px;
    box-shadow: 0 0 6px rgba(0, 0, 0, .25);
    border: 1px solid rgba(255, 255, 255, .25);
}

/* si drapeau manquant */
.flag-placeholder {
    width: 26px;
    height: 18px;
    display: inline-block;
    background: rgba(255, 255, 255, .15);
    border-radius: 3px;
    border: 1px solid rgba(255, 255, 255, .25);
}

.bracket {
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: minmax(260px, 1fr);
    gap: 20px;
    overflow-x: auto;
    padding-bottom: 10px;
}

.bracket-column {
    min-width: 260px;
}

.bracket-title {
    font-weight: 700;
    color: #dfe7f3;
    margin-bottom: 12px;
    text-align: center;
}

.match-card {
    background: rgba(255, 255, 255, .08);
    border: 1px solid rgba(255, 255, 255, .15);
    border-radius: 14px;
    padding: 12px;
    margin-bottom: 16px;
    backdrop-filter: blur(6px);
}

.team-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 6px;
}

.team {
    display: flex;
    align-items: center;
    color: #fff;
}

.score {
    color: #fff;
    font-weight: 700;
    min-width: 24px;
    text-align: right;
}

.flag {
    width: 26px;
    height: 18px;
    border-radius: 3px;
    object-fit: cover;
    border: 1px solid rgba(255, 255, 255, .25);
    box-shadow: 0 0 6px rgba(0, 0, 0, .2);
}

.flag-placeholder {
    width: 26px;
    height: 18px;
    border-radius: 3px;
    background: rgba(255, 255, 255, .15);
    border: 1px solid rgba(255, 255, 255, .25);
}

/* Barre d’emojis (sous le textarea) */
.emoji-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    padding: 8px;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.14);
    border-radius: 12px;
    backdrop-filter: blur(6px);
}

.emoji-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    font-size: 20px;
    line-height: 1;
    color: #fff;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 8px;
    cursor: pointer;
    transition: transform .08s ease, background .12s ease;
}

.emoji-btn:hover {
    background: rgba(255, 255, 255, 0.16);
    transform: translateY(-1px);
}

.emoji-btn:active {
    transform: translateY(0);
}

.chat-row.removing {
    opacity: .35;
    transform: scale(.98);
    transition: opacity .15s ease, transform .15s ease;
}