.inbox-wrapper {
    max-width: 800px;
    margin: 0 auto;
    padding: 20px;
    background: linear-gradient(to right, #f3f3f3, #eae9e2);
    font-family: 'Segoe UI', sans-serif;
    border-radius: 10px;
}

.inbox-header {
    text-align: center;
    margin-bottom: 20px;
}

.chat-thread {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.chat-message {
    background: #ffffff;
    border-left: 5px solid #3f704d;
    padding: 15px;
    border-radius: 10px;
    box-shadow: 0 3px 6px rgba(0,0,0,0.1);
    transition: background 0.3s ease;
}

.chat-message.unread {
    background: #eef7f2;
    border-left-color: #1d6a40;
}

.chat-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
}

.sender-name {
    color: #0d6b4c;
    font-weight: bold;
    text-decoration: none;
}

.chat-status {
    font-size: 0.85em;
    color: #777;
    background: #d2e7d9;
    padding: 2px 8px;
    border-radius: 15px;
}

.chat-content {
    margin-bottom: 10px;
}

.chat-subject {
    font-weight: bold;
    color: #333;
    margin-bottom: 5px;
}

.chat-text {
    white-space: pre-wrap;
    color: #444;
}

.chat-actions {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
}

.reply-link,
.delete-link {
    text-decoration: none;
    color: #1e5c3d;
    padding: 5px 10px;
    background: #dfeee4;
    border-radius: 5px;
    font-size: 0.9em;
}

.reply-link:hover,
.delete-link:hover {
    background: #cce7d5;
}

.pagination {
    margin-top: 20px;
    text-align: center;
}

.pagenumber-link {
    text-decoration: none;
    margin: 0 5px;
    padding: 5px 10px;
    background: #e1f0e4;
    color: #1a4732;
    border-radius: 5px;
}

.pagenumber-link.active {
    background: #1a4732;
    color: white;
}

.new-message-button {
    text-align: center;
    margin-top: 30px;
}

.new-message-btn {
    background: #3f704d;
    color: white;
    padding: 10px 20px;
    border-radius: 25px;
    text-decoration: none;
    font-weight: bold;
}

.new-message-btn:hover {
    background: #2e5b3c;
}

.message-form-wrapper {
    max-width: 600px;
    margin: 40px auto;
    padding: 20px;
    background: #f9fafc;
    border-radius: 10px;
    box-shadow: 0 0 15px rgba(0,0,0,0.05);
    font-family: 'Segoe UI', sans-serif;
}

.message-form-wrapper h2 {
    text-align: center;
    margin-bottom: 20px;
    color: #333;
}

.message-form {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.message-form label {
    font-weight: bold;
    color: #444;
}

.message-form input[type="text"],
.message-form textarea {
    padding: 12px;
    border: 1px solid #ccc;
    border-radius: 6px;
    font-size: 16px;
    width: 100%;
    box-sizing: border-box;
    transition: border-color 0.2s;
}

.message-form input:focus,
.message-form textarea:focus {
    border-color: #0077cc;
    outline: none;
}

.message-form textarea {
    min-height: 150px;
    resize: vertical;
}

.message-form button {
    padding: 12px;
    background: #0077cc;
    color: white;
    border: none;
    border-radius: 6px;
    font-size: 16px;
    cursor: pointer;
    transition: background 0.3s;
}

.message-form button:hover {
    background: #005fa3;
}

/* Mobilvenlig */
@media (max-width: 600px) {
    .chat-meta, .chat-actions {
        flex-direction: column;
        align-items: flex-start;
    }

    .reply-link,
    .delete-link {
        width: 100%;
        margin-top: 5px;
    }

    .chat-message {
        padding: 10px;
    }
}
