/* === RESET === */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* === FOND KIKOOTCHAT === */
body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background-image: url('/images/fond2.jpg');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    background-repeat: no-repeat;
    color: #fff;
    overflow: hidden;
    height: 100vh;
}

body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: -1;
}

/* ========================================
   ⭐ NOUVEAU HEADER KIKOOT (SCREENSHOTS) ⭐
   ======================================== */
.chat-header-kikoot {
    height: 65px;
    background: rgba(15, 18, 35, 0.95);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 24px;
    position: relative;
    z-index: 10000;
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.4);
}

.header-left-kikoot {
    display: flex;
    align-items: center;
    gap: 24px;
}

.header-center-kikoot {
    display: flex;
    gap: 12px;
    align-items: center;
}

.header-right-kikoot {
    display: flex;
    gap: 12px;
    align-items: center;
}

.logo-kikoot {
    display: flex;
    align-items: center;
    gap: 12px;
}

.logo-icon-kikoot {
    width: 36px;
    height: 36px;
    background: linear-gradient(135deg, #e91e63 0%, #9c27b0 100%);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    box-shadow: 0 4px 16px rgba(233, 30, 99, 0.4);
}

.logo-text-kikoot {
    font-size: 22px;
    font-weight: 700;
    background: linear-gradient(135deg, #e91e63 0%, #9c27b0 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    letter-spacing: -0.5px;
}

.online-indicator-kikoot {
    display: flex;
    align-items: center;
    gap: 8px;
    background: rgba(76, 175, 80, 0.15);
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 500;
    border: 1px solid rgba(76, 175, 80, 0.3);
}

.pulse-dot-kikoot {
    width: 10px;
    height: 10px;
    background: #4caf50;
    border-radius: 50%;
    animation: pulse-kikoot 2s ease-in-out infinite;
    box-shadow: 0 0 12px rgba(76, 175, 80, 0.6);
}

@keyframes pulse-kikoot {
    0%, 100% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.2); opacity: 0.8; }
}

.header-right-kikoot {
    display: flex;
    gap: 12px;
}

/* Boutons Micro et Caméra comme screenshots */
.control-btn-kikoot {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    background: rgba(255, 255, 255, 0.05);
    border: 1.5px solid rgba(255, 255, 255, 0.15);
    border-radius: 12px;
    color: #fff;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    font-family: inherit;
    pointer-events: auto;
}

.control-btn-kikoot:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(233, 30, 99, 0.5);
    transform: translateY(-1px);
}

.control-btn-kikoot.active {
    background: linear-gradient(135deg, #e91e63 0%, #9c27b0 100%);
    border-color: transparent;
    box-shadow: 0 4px 16px rgba(233, 30, 99, 0.4);
}

.icon-kikoot {
    font-size: 18px;
}

.label-kikoot {
    font-weight: 600;
}

/* Username et rôle badges */
.username-badge-kikoot {
    background: rgba(255, 255, 255, 0.1);
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 600;
    border: 1px solid rgba(255, 255, 255, 0.15);
}

.role-badge-kikoot {
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 700;
    color: white;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

/* Boutons header (Profil, Admin, Quitter) */
.btn-header-kikoot {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    background: rgba(255, 255, 255, 0.05);
    border: 1.5px solid rgba(255, 255, 255, 0.15);
    border-radius: 12px;
    color: #fff;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    font-family: inherit;
}

.btn-header-kikoot:hover {
    background: rgba(255, 255, 255, 0.1);
    transform: translateY(-1px);
}

.btn-header-kikoot.btn-profile:hover {
    border-color: rgba(59, 130, 246, 0.5);
    box-shadow: 0 4px 16px rgba(59, 130, 246, 0.3);
}

.btn-header-kikoot.btn-admin {
    border-color: rgba(239, 68, 68, 0.3);
}

.btn-header-kikoot.btn-admin:hover {
    background: rgba(239, 68, 68, 0.2);
    border-color: rgba(239, 68, 68, 0.5);
    box-shadow: 0 4px 16px rgba(239, 68, 68, 0.3);
}

.btn-header-kikoot.btn-logout {
    border-color: rgba(239, 68, 68, 0.3);
}

.btn-header-kikoot.btn-logout:hover {
    background: rgba(239, 68, 68, 0.2);
    border-color: rgba(239, 68, 68, 0.5);
    box-shadow: 0 4px 16px rgba(239, 68, 68, 0.3);
}

/* === CONTAINER PRINCIPAL === */
.container {
    display: grid;
    grid-template-columns: 280px 1fr 260px;
    height: calc(100vh - 65px);
    overflow: hidden;
}

/* === SIDEBAR === */
.sidebar {
    background: rgba(15, 18, 35, 0.6);
    backdrop-filter: blur(20px);
    display: flex;
    flex-direction: column;
    border-right: 1px solid rgba(255, 255, 255, 0.08);
    overflow: hidden;
}

.sidebar-left {
    border-right: 1px solid rgba(255, 255, 255, 0.08);
}

.sidebar-right {
    border-left: 1px solid rgba(255, 255, 255, 0.08);
}

.sidebar-header {
    padding: 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.sidebar-header h3 {
    font-size: 14px;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.9);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.count-badge {
    background: rgba(233, 30, 99, 0.2);
    color: #e91e63;
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 700;
}

.online-badge-sidebar {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.pulse-dot-small {
    width: 8px;
    height: 8px;
    background: #4caf50;
    border-radius: 50%;
    animation: pulse-kikoot 2s ease-in-out infinite;
    box-shadow: 0 0 8px rgba(76, 175, 80, 0.6);
}

.rooms-list {
    flex: 1;
    overflow-y: auto;
    padding: 10px;
}

.room-item {
    padding: 12px;
    margin-bottom: 8px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.2s;
    border: 1px solid transparent;
    display: flex;
    align-items: center;
    gap: 12px;
}

.room-item:hover {
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(255, 255, 255, 0.1);
    transform: translateX(3px);
}

.room-item.active {
    background: linear-gradient(135deg, rgba(233, 30, 99, 0.2) 0%, rgba(156, 39, 176, 0.2) 100%);
    border-color: rgba(233, 30, 99, 0.3);
}

.radio-player {
    padding: 15px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    background: rgba(0, 0, 0, 0.3);
}

.radio-header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 10px;
    align-items: center;
}

.volume-slider {
    width: 100%;
    height: 4px;
    border-radius: 2px;
    background: rgba(255, 255, 255, 0.1);
    outline: none;
}

.volume-slider::-webkit-slider-thumb {
    appearance: none;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: linear-gradient(135deg, #e91e63 0%, #9c27b0 100%);
    cursor: pointer;
}

.users-list {
    flex: 1;
    overflow-y: auto;
    padding: 10px;
}

.user-item {
    padding: 10px;
    margin-bottom: 8px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 10px;
    display: flex;
    align-items: center;
    gap: 12px;
    transition: all 0.2s;
    cursor: pointer;
}

.user-item:hover {
    background: rgba(255, 255, 255, 0.08);
    transform: translateX(3px);
}

.user-avatar {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    background: linear-gradient(135deg, #e91e63 0%, #9c27b0 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 16px;
    position: relative;
}

.user-avatar::after {
    content: '';
    width: 10px;
    height: 10px;
    background: #4caf50;
    border: 2px solid rgba(15, 18, 35, 1);
    border-radius: 50%;
    position: absolute;
    bottom: -2px;
    right: -2px;
}

.user-info {
    flex: 1;
}

.user-name {
    font-size: 14px;
    font-weight: 600;
    color: #fff;
    margin-bottom: 2px;
}

.user-status {
    font-size: 11px;
    color: rgba(76, 175, 80, 0.9);
}

/* === ZONE PRINCIPALE - CHAT === */
.main-content {
    display: flex;
    flex-direction: column;
    background: rgba(10, 14, 39, 0.4);
    overflow: hidden;
    position: relative;
}

.chat-zone {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    display: flex;
    flex-direction: column;
    overflow: visible;
}

.messages-container {
    flex: 1;
    overflow-y: auto;
    overflow-x: hidden;
    padding: 20px;
    padding-bottom: 10px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    scroll-behavior: smooth;
}

.message {
    padding: 12px 15px;
    background: rgba(255, 255, 255, 0.05);
    border-left: 3px solid #e91e63;
    border-radius: 10px;
    max-width: 70%;
    animation: slideIn 0.3s ease;
    transition: all 0.3s ease;
    align-self: flex-start;
}

@keyframes slideIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.message:hover {
    background: rgba(255, 255, 255, 0.08);
    transform: translateX(3px);
}

.message.system {
    align-self: center;
    background: rgba(255, 255, 255, 0.03);
    font-style: italic;
    text-align: center;
    border-left: none;
}

.message-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 5px;
}

.message-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: bold;
    font-size: 14px;
    background: linear-gradient(135deg, #e91e63, #9c27b0);
}

.message .username {
    color: #f472b6;
    font-weight: bold;
}

.message-time {
    font-size: 11px;
    color: rgba(255, 255, 255, 0.5);
    margin-left: 8px;
}

.message-text {
    padding-left: 42px;
    color: #ffffff;
}

/* Barre de saisie fixe en bas */
.message-input-zone {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 20px;
    background: rgba(15, 18, 35, 0.95);
    backdrop-filter: blur(20px);
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    display: flex;
    gap: 10px;
    align-items: center;
    z-index: 100;
    box-shadow: 0 -5px 20px rgba(0, 0, 0, 0.5);
}

#message-input {
    flex: 1;
    padding: 14px 20px;
    border: 1.5px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.05);
    color: #fff;
    font-size: 14px;
    transition: all 0.3s;
}

#message-input::placeholder {
    color: rgba(255, 255, 255, 0.4);
}

#message-input:focus {
    outline: none;
    border-color: rgba(233, 30, 99, 0.5);
    box-shadow: 0 0 0 3px rgba(233, 30, 99, 0.1);
    background: rgba(255, 255, 255, 0.08);
}

.btn-icon {
    width: 48px;
    height: 48px;
    border: 1.5px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.05);
    color: #fff;
    cursor: pointer;
    font-size: 20px;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.btn-icon:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(233, 30, 99, 0.5);
    transform: scale(1.05);
}

.btn-send {
    width: 48px;
    height: 48px;
    border: none;
    border-radius: 12px;
    background: linear-gradient(135deg, #e91e63 0%, #9c27b0 100%);
    color: #fff;
    cursor: pointer;
    font-size: 20px;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 16px rgba(233, 30, 99, 0.3);
}

.btn-send:hover {
    transform: scale(1.05);
    box-shadow: 0 6px 20px rgba(233, 30, 99, 0.5);
}

/* ========================================
   ⭐ WEBCAMS FLOTTANTES ⭐
   ======================================== */
#floating-webcams-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    pointer-events: none;
    z-index: 9000;
}

.floating-webcam {
    position: fixed;
    width: 200px;
    background: rgba(15, 18, 35, 0.95);
    backdrop-filter: blur(20px);
    border: 1.5px solid rgba(233, 30, 99, 0.3);
    border-radius: 16px;
    box-shadow: 0 12px 48px rgba(0, 0, 0, 0.6),
                0 0 0 1px rgba(255, 255, 255, 0.05);
    overflow: hidden;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    animation: floatIn 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
    pointer-events: auto;
    cursor: move;
}

@keyframes floatIn {
    from {
        opacity: 0;
        transform: scale(0.8) translateY(20px);
    }
    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

.floating-webcam:hover {
    border-color: rgba(233, 30, 99, 0.5);
    box-shadow: 0 16px 56px rgba(233, 30, 99, 0.3),
                0 0 0 1px rgba(233, 30, 99, 0.2);
}

.floating-webcam.minimized {
    width: auto;
}

.webcam-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 14px;
    background: rgba(0, 0, 0, 0.3);
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    cursor: move;
}

.webcam-user {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    font-weight: 600;
    color: #fff;
}

.webcam-status-dot {
    width: 8px;
    height: 8px;
    background: #4caf50;
    border-radius: 50%;
    animation: pulse-kikoot 2s ease-in-out infinite;
    box-shadow: 0 0 8px rgba(76, 175, 80, 0.6);
}

.webcam-controls {
    display: flex;
    gap: 6px;
}

.webcam-btn {
    width: 26px;
    height: 26px;
    background: rgba(255, 255, 255, 0.1);
    border: none;
    border-radius: 6px;
    color: #fff;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
    pointer-events: auto;
}

.webcam-btn:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: scale(1.05);
}

.webcam-btn.close:hover {
    background: rgba(244, 67, 54, 0.8);
}

.webcam-video-container {
    width: 200px;
    height: 200px;
    background: #000;
    position: relative;
}

.webcam-video {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.webcam-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 12px;
    color: rgba(255, 255, 255, 0.5);
}

.webcam-placeholder svg {
    width: 32px;
    height: 32px;
}

.webcam-placeholder span {
    font-size: 13px;
    font-weight: 500;
}

/* === NOTIFICATIONS === */
#notifications {
    position: fixed;
    top: 80px;
    right: 20px;
    z-index: 10001;
    pointer-events: none;
}

.notification {
    padding: 15px 20px;
    background: rgba(15, 18, 35, 0.95);
    backdrop-filter: blur(20px);
    border-radius: 12px;
    margin-bottom: 10px;
    animation: slideInRight 0.3s ease;
    border: 1.5px solid rgba(233, 30, 99, 0.4);
    pointer-events: auto;
}

@keyframes slideInRight {
    from { transform: translateX(100px); opacity: 0; }
    to { transform: translateX(0); opacity: 1; }
}

.notification.success { border-left: 4px solid #10b981; }
.notification.error { border-left: 4px solid #ef4444; }
.notification.info { border-left: 4px solid #e91e63; }

/* === SCROLLBAR === */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.2);
}

::-webkit-scrollbar-thumb {
    background: rgba(233, 30, 99, 0.3);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: rgba(233, 30, 99, 0.5);
}

/* === RESPONSIVE === */
@media (max-width: 1200px) {
    .container {
        grid-template-columns: 220px 1fr 220px;
    }

    .chat-header-kikoot {
        flex-wrap: wrap;
        height: auto;
        gap: 12px;
        padding: 12px 16px;
    }

    .header-center-kikoot {
        order: 3;
        width: 100%;
        justify-content: center;
    }
}

@media (max-width: 768px) {
    .container {
        grid-template-columns: 1fr;
    }

    .sidebar {
        display: none;
    }

    .control-btn-kikoot .label-kikoot,
    .btn-header-kikoot .label-kikoot {
        display: none;
    }

    .username-badge-kikoot {
        display: none;
    }

    .chat-header-kikoot {
        padding: 10px;
    }
}

/* ========================================
   INDICATEURS WEBCAM/MICRO - LISTE USERS
   ======================================== */

.user-status-indicators {
    display: inline-flex;
    gap: 4px;
    margin-left: 8px;
}

.user-status-icon {
    font-size: 14px;
    opacity: 0.3;
    transition: all 0.3s ease;
}

.user-status-icon.active {
    opacity: 1;
    animation: pulse-icon 2s infinite;
}

.user-status-icon.cam-active {
    color: #10b981;
    filter: drop-shadow(0 0 4px rgba(16, 185, 129, 0.5));
}

.user-status-icon.mic-active {
    color: #3b82f6;
    filter: drop-shadow(0 0 4px rgba(59, 130, 246, 0.5));
}

@keyframes pulse-icon {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.1); }
}

/* ========================================
   SÉLECTEUR DE SMILEYS
   ======================================== */

.emoji-picker {
    position: absolute;
    bottom: 60px;
    left: 120px;
    background: linear-gradient(135deg, #1e293b 0%, #0f172a 100%);
    border: 2px solid rgba(139, 92, 246, 0.3);
    border-radius: 12px;
    padding: 12px;
    max-width: 200px;
    max-height: 280px;
    overflow-y: auto;
    display: none;
    z-index: 1000;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
}

.emoji-picker.active {
    display: block;
    animation: slideUp 0.2s ease;
}

.emoji-grid {
    display: grid;
    grid-template-columns: repeat(8, 1fr);
    gap: 4px;
}

.emoji-item {
    font-size: 24px;
    padding: 6px;
    cursor: pointer;
    border-radius: 6px;
    transition: all 0.2s ease;
    text-align: center;
}

.emoji-item:hover {
    background: rgba(139, 92, 246, 0.2);
    transform: scale(1.2);
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ========================================
   BOUTON YOUTUBE
   ======================================== */

.youtube-input-container {
    position: absolute;
    bottom: 60px;
    right: 20px;
    background: linear-gradient(135deg, #1e293b 0%, #0f172a 100%);
    border: 2px solid rgba(239, 68, 68, 0.3);
    border-radius: 12px;
    padding: 16px;
    display: none;
    z-index: 1000;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
    min-width: 300px;
}

.youtube-input-container.active {
    display: block;
    animation: slideUp 0.2s ease;
}

.youtube-input-container input {
    width: 100%;
    padding: 10px 12px;
    background: rgba(15, 23, 42, 0.8);
    border: 1px solid rgba(139, 92, 246, 0.3);
    border-radius: 8px;
    color: #e2e8f0;
    font-size: 14px;
    margin-bottom: 10px;
}

.youtube-input-container button {
    width: 100%;
    padding: 10px;
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
    border: none;
    border-radius: 8px;
    color: white;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.youtube-input-container button:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(239, 68, 68, 0.4);
}


/* ========================================
   INDICATEURS WEBCAM/MICRO - LISTE USERS
   ======================================== */

.user-status-indicators {
    display: inline-flex;
    gap: 6px;
    margin-left: 10px;
    align-items: center;
}

.user-status-icon {
    font-size: 15px;
    opacity: 0.25;
    transition: all 0.3s ease;
    filter: grayscale(100%);
}

.user-status-icon.active {
    opacity: 1;
    filter: grayscale(0%);
    animation: pulse-icon 2s infinite ease-in-out;
}

.user-status-icon.cam-active {
    filter: drop-shadow(0 0 6px rgba(16, 185, 129, 0.8));
}

.user-status-icon.mic-active {
    filter: drop-shadow(0 0 6px rgba(59, 130, 246, 0.8));
}

@keyframes pulse-icon {
    0%, 100% { 
        transform: scale(1); 
        opacity: 1;
    }
    50% { 
        transform: scale(1.15); 
        opacity: 0.9;
    }
}

/* ========================================
   ✨ MENU ET POP-UP (MAGIC SCRIPT) ✨
   ======================================== */
.custom-menu {
    position: fixed;
    z-index: 10000;
    background: rgba(15, 18, 35, 0.95);
    backdrop-filter: blur(20px);
    border: 1.5px solid #ec4899;
    border-radius: 12px;
    padding: 8px;
    min-width: 220px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.8);
}

.menu-opt {
    padding: 10px 15px;
    cursor: pointer;
    color: #e2e8f0;
    font-size: 13px;
    font-weight: 500;
    border-radius: 8px;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    gap: 10px;
}

.menu-opt:hover {
    background: linear-gradient(135deg, #e91e63 0%, #9c27b0 100%);
    color: white;
    transform: translateX(5px);
}

.profile-modal-overlay {
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0, 0, 0, 0.7);
    z-index: 20000;
    display: flex;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(5px);
}

.profile-modal-content {
    background: rgba(15, 18, 35, 0.95);
    border: 2px solid #ec4899;
    width: 400px;
    padding: 25px;
    border-radius: 20px;
    position: relative;
    text-align: center;
    box-shadow: 0 0 50px rgba(233, 30, 99, 0.3);
}

.close-modal {
    position: absolute;
    top: 15px; right: 15px;
    cursor: pointer;
    font-size: 20px;
    color: #94a3b8;
}

/* SYSTÈME DE CADEAUX */
.gift-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 99999;
}

.gift-modal-content {
    background: #0b141a;
    border: 2px solid #ec4899;
    border-radius: 15px;
    padding: 20px;
    max-width: 500px;
    width: 90%;
}

.gift-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.gift-modal-header h3 {
    color: #ec4899;
    margin: 0;
}

.close-gift-modal {
    background: none;
    border: none;
    color: white;
    font-size: 30px;
    cursor: pointer;
}

.gifts-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 15px;
}

.gift-item {
    background: #1f2937;
    border: 2px solid #374151;
    border-radius: 10px;
    padding: 15px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s;
}

.gift-item:hover {
    border-color: #ec4899;
    transform: scale(1.05);
}

.gift-icon {
    font-size: 40px;
    margin-bottom: 5px;
}

.gift-name {
    color: white;
    font-size: 12px;
    margin-bottom: 5px;
}

.gift-price {
    color: #fbbf24;
    font-size: 11px;
    font-weight: bold;
}

.gift-animation {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 999999;
    animation: giftFly 3s ease-out;
}

@keyframes giftFly {
    0% {
        opacity: 0;
        transform: translate(-50%, 100%) scale(0.5);
    }
    50% {
        opacity: 1;
        transform: translate(-50%, -50%) scale(1.2);
    }
    100% {
        opacity: 0;
        transform: translate(-50%, -100%) scale(0.8);
    }
}

.gift-fly {
    background: linear-gradient(135deg, #ec4899, #f43f5e);
    border-radius: 20px;
    padding: 30px;
    text-align: center;
    box-shadow: 0 10px 40px rgba(236, 72, 153, 0.5);
}

.gift-icon-big {
    font-size: 80px;
    margin-bottom: 10px;
}

.gift-text {
    color: white;
    font-size: 20px;
    font-weight: bold;
}

.gift-message {
    background: linear-gradient(90deg, #ec4899, #f43f5e) !important;
    border-left: 4px solid #fbbf24 !important;
    padding: 15px !important;
}

.gift-message .gift-icon {
    font-size: 24px;
    margin-right: 10px;
}

/* DEVICE SELECTOR MODAL */
.device-selector-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 999999;
}

.device-selector-content {
    background: #1a1a2e;
    border: 2px solid #ec4899;
    border-radius: 15px;
    padding: 20px;
    max-width: 500px;
    width: 90%;
}

.device-selector-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.device-selector-header h3 {
    color: white;
    margin: 0;
}

.close-device-selector {
    background: none;
    border: none;
    color: white;
    font-size: 30px;
    cursor: pointer;
}

.device-selector-body {
    margin-bottom: 20px;
}

.device-selector-body label {
    display: block;
    color: #ec4899;
    font-weight: bold;
    margin: 10px 0 5px;
}

.device-selector-body select {
    width: 100%;
    padding: 10px;
    background: #0f1419;
    border: 1px solid #374151;
    border-radius: 8px;
    color: white;
    font-size: 14px;
}

.device-selector-footer {
    display: flex;
    gap: 10px;
}

.device-selector-footer button {
    flex: 1;
    padding: 12px;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    cursor: pointer;
    font-weight: bold;
}

.btn-choose {
    background: #22c55e;
    color: white;
}

.btn-close {
    background: #ef4444;
    color: white;
}

/* ========================================
   MOBILE NAV FIX COMPLET
   ======================================== */
@media (max-width: 768px) {
    .container {
        display: flex !important;
        flex-direction: column !important;
        height: calc(100vh - 120px) !important;
        overflow: hidden !important;
    }
    .sidebar {
        display: none !important;
    }
    .sidebar.mobile-show {
        display: flex !important;
        flex-direction: row !important;
        width: 100% !important;
        height: 110px !important;
        overflow-x: auto !important;
        padding: 5px !important;
    }
    .rooms-list, .users-list {
        display: flex !important;
        flex-direction: row !important;
        gap: 8px !important;
        overflow-x: auto !important;
    }
    .main-content {
        flex: 1 !important;
        width: 100% !important;
    }
    .messages-container {
        height: calc(100vh - 280px) !important;
    }
    .radio-player { display: none !important; }
    .message-input-zone {
        position: fixed !important;
        bottom: 55px !important;
        left: 0 !important;
        width: 100% !important;
        padding: 5px !important;
        background: rgba(15,15,25,0.98) !important;
        z-index: 999 !important;
    }
    .message-input-zone input {
        font-size: 16px !important;
        width: 100% !important;
    }
    .kikoot-toolbar {
        position: fixed !important;
        bottom: 95px !important;
        left: 0 !important;
        width: 100% !important;
        background: rgba(15,15,25,0.98) !important;
        z-index: 998 !important;
        padding: 3px 5px !important;
    }
    .mobile-nav {
        display: flex !important;
        position: fixed !important;
        bottom: 0 !important;
        left: 0 !important;
        width: 100% !important;
        background: rgba(15,15,25,0.98) !important;
        border-top: 2px solid rgba(236,72,153,0.5) !important;
        z-index: 9999 !important;
        height: 55px !important;
    }
    .mobile-nav-btn {
        flex: 1 !important;
        background: none !important;
        border: none !important;
        color: white !important;
        font-size: 22px !important;
        cursor: pointer !important;
    }
    .mobile-nav-btn.active {
        color: #ec4899 !important;
        border-top: 3px solid #ec4899 !important;
    }
}
.mobile-nav { display: none; }

@media (max-width: 768px) {
    .kikoot-toolbar {
        display: flex !important;
        position: fixed !important;
        bottom: 55px !important;
        left: 0 !important;
        width: 100% !important;
        z-index: 998 !important;
        padding: 4px 5px !important;
        flex-wrap: wrap !important;
        gap: 4px !important;
        background: rgba(15,15,25,0.98) !important;
        border-top: 1px solid rgba(236,72,153,0.3) !important;
        box-sizing: border-box !important;
    }
}

@media (max-width: 768px) {
    .header-center-kikoot {
        position: fixed !important;
        bottom: 60px !important;
        right: 10px !important;
        z-index: 9998 !important;
        display: flex !important;
        gap: 5px !important;
    }
    .control-btn-kikoot {
        padding: 8px !important;
        font-size: 12px !important;
        border-radius: 50% !important;
        width: 45px !important;
        height: 45px !important;
    }
}

/* Ajustement spécial pour l'application */
@media all and (display-mode: standalone) {
    body {
        height: 100vh;
        overscroll-behavior: none;
    }
    
    /* On remonte la barre de saisie pour ne pas qu'elle soit cachée */
    .message-input-container, .footer-controls {
        padding-bottom: env(safe-area-inset-bottom, 20px) !important;
        margin-bottom: 5px !important;
    }

    /* On s'assure que le contenu ne passe pas sous la barre */
    #messages-container {
        padding-bottom: 80px;
    }
}

/* Correction spéciale Application et Clavier */
@media all and (display-mode: standalone) {
    :root {
        --safe-bottom: env(safe-area-inset-bottom, 20px);
    }
    
    body {
        height: 100vh;
        overflow: hidden; /* Évite les rebonds bizarres */
    }

    /* On cible la barre de message (souvent .message-input-container ou .chat-input-area) */
    .message-input-container, footer, [class*="input-container"] {
        bottom: var(--safe-bottom) !important;
        position: sticky;
        z-index: 1000;
    }
}

/* ========================================
   TOOLBAR DESKTOP FIX
   ======================================== */
@media (min-width: 769px) {
    .kikoot-toolbar {
        position: fixed !important;
        bottom: 50px !important;
        left: 280px !important;
        right: 280px !important;
        width: auto !important;
        background: linear-gradient(135deg, rgba(30,41,59,0.98), rgba(15,23,42,0.98)) !important;
        border: 2px solid rgba(236,72,153,0.3) !important;
        z-index: 500 !important;
        display: flex !important;
        align-items: center !important;
        justify-content: space-between !important;
        padding: 6px 10px !important;
        border-radius: 8px 8px 0 0 !important;
    }
    .message-input-zone {
        position: fixed !important;
        bottom: 5px !important;
        left: 280px !important;
        right: 280px !important;
        width: auto !important;
        z-index: 500 !important;
        background: rgba(15,23,42,0.98) !important;
        padding: 5px !important;
        border-radius: 0 0 8px 8px !important;
    }
    .messages-container {
        padding-bottom: 120px !important;
    }
}
