@font-face {
    font-family: 'Fixedsys';
    src: local('Fixedsys'), local('Fixedsys Excelsior'), local('Courier New');
}

body {
    background-color: #c0c0c0;
    /* Windows Classic Gray */
    font-family: 'MS Sans Serif', 'Segoe UI', sans-serif;
    font-size: 11px;
    margin: 0;
    display: flex;
    flex-direction: column;
    height: 100vh;
    overflow: hidden;
}

.window-frame {
    display: flex;
    flex-direction: column;
    height: 100vh;
    border: 2px outset #ffffff;
    box-sizing: border-box;
    padding: 2px;
}

.title-bar {
    background: linear-gradient(90deg, #000080, #1084d0);
    color: white;
    padding: 3px 5px;
    font-weight: bold;
    font-size: 13px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 18px;
    font-family: 'Tahoma', sans-serif;
}

.title-bar-icon {
    width: 16px;
    height: 16px;
    background: url('https://raw.githubusercontent.com/microsoft/vscode-icons/master/icons/dark/console.svg') no-repeat center center;
    background-size: contain;
    margin-right: 5px;
}

.title-bar-controls button {
    width: 16px;
    height: 14px;
    background-color: #c0c0c0;
    border: 1px outset #ffffff;
    font-size: 9px;
    line-height: 10px;
    margin-left: 2px;
    cursor: default;
}

.toolbar {
    display: flex;
    padding: 4px;
    border-bottom: 2px groove #ffffff;
    margin-bottom: 2px;
}

.toolbar-btn {
    width: 24px;
    height: 24px;
    margin-right: 2px;
    border: 1px outset #ffffff;
    background: #c0c0c0;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.workspace {
    background-color: #808080;
    /* MDI Workspace Dark Gray */
    flex: 1;
    padding: 5px;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
}

/* Internal Chat Window */
.chat-window {
    background-color: #c0c0c0;
    border: 2px outset #ffffff;
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    box-shadow: 2px 2px 5px rgba(0, 0, 0, 0.5);
}

.chat-container {
    display: flex;
    flex: 1;
    overflow: hidden;
    padding: 2px;
}

.log-area {
    flex: 1;
    background-color: white;
    border: 2px inset #ffffff;
    padding: 4px;
    overflow-y: scroll;
    font-family: 'Fixedsys', 'Consolas', monospace;
    font-size: 14px;
    line-height: 1.2;
    color: black;
}

.user-list {
    width: 140px;
    background-color: white;
    border: 2px inset #ffffff;
    margin-left: 2px;
    padding: 2px;
    overflow-y: auto;
    font-family: 'Fixedsys', 'Consolas', monospace;
    font-size: 14px;
}

.user-list ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.user-list li::before {
    content: "@";
    /* Op Icon */
    color: #c0c0c0;
    margin-right: 2px;
}

.input-area {
    margin-top: 2px;
    display: flex;
}

.input-field {
    flex: 1;
    border: 2px inset #ffffff;
    padding: 2px 4px;
    font-family: 'Fixedsys', monospace;
    font-size: 14px;
}

/* Message Styles */
.msg {
    margin-bottom: 0px;
}

.timestamp {
    color: #000000;
    margin-right: 5px;
}

.msg-system {
    color: #000080;
}

/* Blue for system */
.msg-join {
    color: #008000;
}

/* Green for join */
.msg-part {
    color: #000080;
}

/* Navy for part */
.msg-public {
    color: #000000;
}

/* Black for chat */
.msg-private {
    color: #ff00ff;
}

.msg-action {
    color: #800080;
    font-style: italic;
}

.nick {
    font-weight: normal;
    color: #000000;
}

.nick::before {
    content: "<";
}

.nick::after {
    content: ">";
}

/* Channel Tabs */
.channel-bar {
    background-color: #c0c0c0;
    border-bottom: 1px solid #808080;
    padding: 2px 2px 0 2px;
    display: flex;
    gap: 2px;
}

.channel-tab {
    background-color: #c0c0c0;
    border: 2px outset #ffffff;
    border-bottom: none;
    padding: 2px 8px;
    font-family: 'MS Sans Serif', 'Segoe UI', sans-serif;
    font-size: 11px;
    cursor: pointer;
    user-select: none;
}

.channel-tab.active {
    background-color: #ffffff;
    border-bottom: 2px solid #ffffff;
    font-weight: bold;
    position: relative;
    top: 2px;
    z-index: 10;
}

.channel-tab.alert {
    color: red;
}