/* Chat Modals Styles - Based on Login Requirement Modal */
/* Common styles for chat modals */
.chat-modal {
    display: none;
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: linear-gradient(135deg, #1a1a2e, #16213e, #0f3460);
    border: 1px solid rgba(78, 204, 255, 0.3);
    border-radius: 20px;
    color: #fff;
    padding: 20px;
    text-align: center;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.7), 0 0 20px rgba(78, 204, 255, 0.2);
    z-index: 1001;
    box-sizing: border-box;
    transition: all 0.3s ease;
}

.chat-modal.active {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    animation: chatModalFadeIn 0.4s ease;
}

@keyframes chatModalFadeIn {
    from {
        opacity: 0;
        transform: translate(-50%, -60%);
    }
    to {
        opacity: 1;
        transform: translate(-50%, -50%);
    }
}

.chat-modal-icon {
    margin-bottom: 15px;
    position: relative;
    width: 60px;
    height: 60px;
    display: flex;
    justify-content: center;
    align-items: center;
}

.chat-modal-icon svg {
    filter: drop-shadow(0 0 8px rgba(78, 204, 255, 0.5));
    animation: chatIconPulse 2s infinite ease-in-out;
}

@keyframes chatIconPulse {
    0% {
        transform: scale(1);
        filter: drop-shadow(0 0 8px rgba(78, 204, 255, 0.5));
    }
    50% {
        transform: scale(1.05);
        filter: drop-shadow(0 0 12px rgba(78, 204, 255, 0.7));
    }
    100% {
        transform: scale(1);
        filter: drop-shadow(0 0 8px rgba(78, 204, 255, 0.5));
    }
}

.chat-modal-icon:after {
    content: '';
    position: absolute;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(78, 204, 255, 0.15) 0%, rgba(192, 84, 255, 0.05) 50%, rgba(0, 0, 0, 0) 70%);
    z-index: -1;
}

.chat-modal h2 {
    background: linear-gradient(to right, #4eceff, #c054ff);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    text-shadow: none;
    font-weight: 600;
    margin: 10px 0;
    letter-spacing: 1px;
    font-size: 22px;
}

.chat-modal p {
    margin-bottom: 20px;
    font-size: 16px;
    line-height: 1.5;
    color: rgba(255, 255, 255, 0.9);
}

.chat-modal .buttons {
    display: flex;
    gap: 15px;
    justify-content: center;
    margin-top: 10px;
    width: 100%;
}

.chat-modal .buttons button {
    flex: 1;
    max-width: 130px;
    background: linear-gradient(135deg, #4eceff, #c054ff);
    border-radius: 12px;
    border: none;
    padding: 10px 18px;
    color: #fff;
    font-size: 15px;
    font-weight: 500;
    letter-spacing: 0.5px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    position: relative;
    overflow: hidden;
    cursor: pointer;
}

.chat-modal .buttons button:last-child {
    background: linear-gradient(135deg, #4a4a6b, #2d325a);
}

.chat-modal .buttons button:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.3);
}

.chat-modal .buttons button:active {
    transform: translateY(1px);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

/* Button hover effect */
.chat-modal .buttons button::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: 0.5s;
}

.chat-modal .buttons button:hover::after {
    left: 100%;
}

/* Rename modal specific styles */
.chat-modal-rename {
    width: 90%;
    max-width: 350px;
}

.chat-modal-rename input[type="text"] {
    width: 100%;
    padding: 10px 15px;
    margin: 5px 0 20px;
    border: 1px solid rgba(78, 204, 255, 0.4);
    background: rgba(16, 23, 41, 0.8);
    border-radius: 10px;
    color: #fff;
    font-size: 15px;
    transition: all 0.3s ease;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.2) inset;
}

.chat-modal-rename input[type="text"]:focus {
    outline: none;
    border-color: rgba(78, 204, 255, 0.8);
    box-shadow: 0 0 15px rgba(78, 204, 255, 0.2);
}

/* Delete modal specific styles */
.chat-modal-delete {
    width: 90%;
    max-width: 350px;
    min-height: auto;
}

/* Mobile optimization */
@media (max-width: 768px) {
    .chat-modal {
        padding: 18px;
        width: 80%;
        max-width: 290px;
        box-sizing: border-box;
    }
    
    .chat-modal h2 {
        font-size: 18px;
        margin: 6px 0 8px 0;
    }
    
    .chat-modal p {
        font-size: 14px;
        margin-bottom: 16px;
        max-width: 95%;
    }
    
    .chat-modal .buttons {
        gap: 12px;
        max-width: 250px;
    }
    
    .chat-modal .buttons button {
        padding: 8px 14px;
        font-size: 13px;
        max-width: 100px;
    }
    
    .chat-modal-icon {
        margin-bottom: 10px;
        width: 40px;
        height: 40px;
    }
    
    .chat-modal-icon svg {
        width: 24px;
        height: 24px;
    }
    
    .chat-modal-icon:after {
        width: 40px;
        height: 40px;
    }
    
    .chat-modal-rename input[type="text"] {
        padding: 8px 12px;
        font-size: 14px;
        margin-bottom: 15px;
    }
}

/* Chat tab menu styles */
.chat-tab-menu-new {
    position: absolute;
    top: calc(100% + 5px);
    right: 0px;
    background: rgba(16, 23, 41, 0.95);
    border: 1px solid rgba(78, 204, 255, 0.3);
    border-radius: 10px;
    padding: 5px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.5), 0 0 15px rgba(78, 204, 255, 0.1);
    z-index: 101;
    display: none;
}

.chat-tab-menu-new.active {
    display: block;
    animation: menuFadeIn 0.2s ease;
}

@keyframes menuFadeIn {
    from {
        opacity: 0;
        transform: translateY(-5px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.chat-tab-menu-new ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.chat-tab-menu-new li {
    padding: 8px 12px;
    color: #fff;
    cursor: pointer;
    white-space: nowrap;
    border-bottom: 1px solid rgba(78, 204, 255, 0.1);
    transition: all 0.2s ease;
}

.chat-tab-menu-new li:last-child {
    border-bottom: none;
}

.chat-tab-menu-new li:hover {
    background: rgba(78, 204, 255, 0.15);
}

.chat-tab-menu-button-new {
    width: 24px;
    height: 24px;
    background: transparent;
    border: none;
    color: #fff;
    cursor: pointer;
    font-size: 16px;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}

.chat-tab-menu-button-new:hover {
    color: rgba(78, 204, 255, 0.8);
}

.sidebar.collapsed .chat-tab-menu-button-new {
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="white" width="24px" height="24px"><path d="M20 2H4c-1.1 0-2 .9-2 2v18l4-4h14c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2z"/></svg>') no-repeat center center;
    background-size: contain;
    pointer-events: none;
}

.sidebar:not(.collapsed) .chat-tab-menu-button-new svg {
    width: 20px;
    height: 20px;
    fill: #fff;
} 