/* MSN Messenger Window Styles */
#messenger-window {
    width: 400px;
    height: 500px;
    top: 100px;
    left: 200px;
}

.messenger-container {
    display: flex;
    flex-direction: column;
    height: 100%;
    background: #FAFAFA;
}

.messenger-header {
    background: linear-gradient(to bottom, #D8EAF9 0%, #C8E2F7 100%);
    border-bottom: 1px solid #A8C7E7;
    padding: 10px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.messenger-status {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 11px;
    color: #333;
    font-family: "Tahoma", sans-serif;
}

.status-indicator {
    width: 14px;
    height: 14px;
    border-radius: 3px;
    border: 1px solid #666;
    box-shadow: inset 0 0 2px rgba(255,255,255,0.8);
}

.status-indicator.online {
    background: radial-gradient(circle at 30% 30%, #A4E858 0%, #5D8F1A 100%);
    border-color: #3F6311;
}

.messenger-toolbar {
    display: flex;
    gap: 4px;
    margin-top: 5px;
    padding: 2px 5px;
    background: #EEF7FF;
    border-bottom: 1px solid #BCD6F1;
}

.messenger-toolbar button {
    background: transparent;
    border: 1px solid transparent;
    border-radius: 2px;
    padding: 2px 6px;
    font-size: 11px;
    cursor: pointer;
    min-width: 24px;
    height: 24px;
}

.messenger-toolbar button:hover {
    background: #FFE6A0;
    border: 1px solid #D2B466;
}

/* Chat Area */
.messenger-chat {
    flex: 1;
    background: white;
    border: 1px solid #8BA3C0;
    margin: 5px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    border-radius: 2px;
}

.chat-messages {
    flex: 1;
    padding: 8px;
    overflow-y: auto;
    font-family: "Trebuchet MS", "Arial", sans-serif;
    font-size: 12px;
    line-height: 1.4;
}

/* Chat Message Styles */
.chat-message {
    margin-bottom: 8px;
}

.chat-message .sender {
    font-weight: bold;
    color: #666;
    font-size: 11px;
    display: block;
    margin-bottom: 2px;
}

.chat-message .sender.other {
    color: #0066CC;
}

.chat-message .text {
    margin-left: 0;
    word-wrap: break-word;
}

/* MSN-specific font styles */
.msg-color-pink { color: #FF1493 !important; }
.msg-color-purple { color: #9932CC !important; }
.comic-sans { font-family: "Comic Sans MS", cursive !important; }

/* System messages and nudges */
.chat-nudge {
    text-align: center;
    color: #666;
    font-style: italic;
    margin: 8px 0;
    font-size: 11px;
    background: #FFFFCC;
    padding: 2px;
    border: 1px solid #EEDD88;
    border-radius: 2px;
}

/* Emoticons */
.chat-emoticon {
    display: inline-block;
    font-size: 16px;
    vertical-align: middle;
    margin: 0 2px;
}

/* Input Area */
.messenger-input {
    border-top: 1px solid #BCD6F1;
    background: #EEF7FF;
    padding: 8px;
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.input-toolbar {
    display: flex;
    gap: 2px;
}

.input-toolbar button {
    background: transparent;
    border: 1px solid transparent;
    border-radius: 2px;
    padding: 2px 6px;
    font-size: 11px;
    cursor: pointer;
}

.input-toolbar button:hover {
    background: #FFE6A0;
    border: 1px solid #D2B466;
}

#messenger-input-text {
    width: 100%;
    height: 50px;
    border: 1px solid #7F9DB9;
    padding: 4px;
    font-family: "Arial", sans-serif;
    font-size: 12px;
    resize: none;
    background: white;
}

#messenger-input-text:focus {
    outline: none;
    border-color: #0054E3;
}

.messenger-actions {
    display: flex;
    justify-content: flex-end;
    gap: 8px;
}

.send-button {
    background: #ECE9D8;
    border: 1px solid #003C74;
    border-radius: 3px;
    padding: 3px 15px;
    font-size: 11px;
    cursor: pointer;
    font-weight: normal;
}

.send-button:hover:not(:disabled) {
    background: linear-gradient(to bottom, #FFF 0%, #E3F4FF 100%);
    border-color: #0078D7;
}

.send-button:disabled {
    opacity: 0.6;
    cursor: default;
    color: #888;
}

/* Scrollbar styling for chat */
.chat-messages::-webkit-scrollbar { width: 14px; }
.chat-messages::-webkit-scrollbar-track {
    background: #FAFAFA;
    border-left: 1px solid #D4D0C8;
}
.chat-messages::-webkit-scrollbar-thumb {
    background: #C1D2EE;
    border: 1px solid #fff;
}
.chat-messages::-webkit-scrollbar-button {
    background: #E8F2FE;
    height: 14px;
}

/* Typing indicator */
#typing-indicator {
    color: #666;
    font-style: italic;
    font-size: 10px;
}
#typing-indicator::after {
    content: '...';
    display: inline-block;
    animation: typing 1.5s infinite;
}
