* {
    box-sizing: border-box;
}

html,
body {
    margin: 0;
    width: 100%;
    min-height: 100%;
}

body {
    background: #000000;
    color: #dddddd;
    font-family: Arial, sans-serif;
    font-size: 14px;
}

button,
input {
    font: inherit;
}

.hidden {
    display: none !important;
}



#page {
    width: 100%;
    max-width: 900px;
    margin: 40px auto;
}



button {
    color: #eeeeee;
    background: #4b2b5d;

    border: 2px solid;
    border-top-color: #825f94;
    border-left-color: #825f94;
    border-right-color: #24142c;
    border-bottom-color: #24142c;

    padding: 5px 10px;

    cursor: pointer;
}

button:active {
    border-top-color: #24142c;
    border-left-color: #24142c;
    border-right-color: #825f94;
    border-bottom-color: #825f94;

    padding-top: 6px;
    padding-left: 11px;
    padding-right: 9px;
    padding-bottom: 4px;
}

input {
    color: #eeeeee;
    background: #1d1024;

    border: 2px solid;
    border-top-color: #190d1e;
    border-left-color: #190d1e;
    border-right-color: #684778;
    border-bottom-color: #684778;

    padding: 5px;
}

input:focus {
    outline: none;
    background: #26142f;
}


#auth {
    width: 370px;
    margin: 100px auto;
    padding: 14px;

    background: #321a40;

    border: 3px solid;
    border-top-color: #704d80;
    border-left-color: #704d80;
    border-right-color: #160b1c;
    border-bottom-color: #160b1c;
}

#auth form {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.form-row {
    display: grid;
    grid-template-columns: 55px 1fr;
    align-items: center;
    gap: 6px;
}

.form-row label {
    text-align: right;
}

.form-row input {
    width: 100%;
}

.button-row {
    display: flex;
    justify-content: flex-end;
    gap: 6px;
    margin-top: 4px;
}

#auth-message {
    margin-top: 10px;
    min-height: 1em;
    color: #e1b9ef;
}

#chat {
    height: 80vh;

    background: #563665;

    border: 3px solid;
    border-top-color: #9573a3;
    border-left-color: #9573a3;
    border-right-color: #281730;
    border-bottom-color: #281730;

    display: flex;
    flex-direction: column;
}

#chat-header {
    padding: 7px;

    background: #321a40;

    border-bottom: 3px solid;
    border-bottom-color: #1c0e23;

    display: flex;
    justify-content: space-between;
    align-items: center;
}


#messages {
    flex: 1;

    padding: 10px;

    overflow-y: auto;

    background: #5d3b6d;

    border: 3px solid;
    border-top-color: #2b1933;
    border-left-color: #2b1933;
    border-right-color: #8d6b9b;
    border-bottom-color: #8d6b9b;

    margin: 8px;
}

.message {
    padding: 2px 0;
    overflow-wrap: anywhere;
}

.message-time {
    color: #bba8c3;
    margin-right: 6px;
}

.message-user {
    color: #ffffff;
    font-weight: bold;
    margin-right: 6px;
}

.message-text {
    color: #eeeeee;
    white-space: pre-wrap;
}

#message-form {
    padding: 8px;

    background: #321a40;

    display: flex;
    gap: 7px;
}

#message-input {
    flex: 1;
}