.app-chat-box {
    max-width: 900px;
    margin: 20px auto;
    padding: 20px;
    background: #fff;
    border-radius: 15px;
    box-shadow: 0 4px 12px rgba(0,0,0,.1);
}

.app-chat-dashboard {
    max-width: 1000px;
    margin: 20px auto;
    padding: 16px;
}

.app-chat-header-image {
    width: 100%;
    border-radius: 18px;
    display: block;
    margin-bottom: 22px;
}

.app-chat-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
    gap: 18px;
}

.app-chat-card {
    background: #fff;
    border-radius: 18px;
    padding: 24px;
    text-align: center;
    text-decoration: none;
    color: #222;
    box-shadow: 0 6px 18px rgba(0,0,0,0.1);
}

.app-chat-card:hover {
    transform: translateY(-2px);
    color: #222;
}

.app-chat-icon {
    font-size: 42px;
    margin-bottom: 10px;
}

.app-chat-card h3 {
    margin: 8px 0;
    font-size: 22px;
}

.app-chat-card p {
    margin: 0;
    color: #666;
}

.app-chat-disabled {
    opacity: 0.65;
}

.app-chat-login-btn {
    display: inline-block;
    margin-top: 12px;
    padding: 14px 18px;
    border-radius: 12px;
    background: #1f5f9f;
    color: #fff;
    text-decoration: none;
    font-weight: 700;
}

.app-chat-login-btn:hover {
    background: #174a7c;
    color: #fff;
}

.app-chat-btn {
    display: inline-block;
    padding: 11px 16px;
    border-radius: 12px;
    background: #1f5f9f;
    color: #fff;
    text-decoration: none;
    font-weight: 700;
}

.app-chat-btn:hover {
    background: #174a7c;
    color: #fff;
}

.app-chat-empty {
    padding: 18px;
    background: #f3f6fa;
    border-radius: 12px;
}

.app-chat-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.app-chat-list-item {
    display: flex;
    gap: 14px;
    align-items: center;
    padding: 14px;
    background: #f8fafc;
    border-radius: 14px;
    text-decoration: none;
    color: #222;
}

.app-chat-list-item:hover {
    background: #eef5ff;
    color: #222;
}

.app-chat-avatar {
    width: 46px;
    height: 46px;
    border-radius: 50%;
    background: #e3f0ff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    flex-shrink: 0;
}

.app-chat-list-content {
    flex: 1;
}

.app-chat-subject {
    font-size: 14px;
    color: #1f5f9f;
    margin-top: 3px;
}

.app-chat-preview {
    font-size: 14px;
    color: #666;
    margin-top: 4px;
}

.app-chat-time {
    font-size: 13px;
    color: #888;
}

.app-chat-thread-head {
    margin-bottom: 16px;
}

.app-chat-back {
    display: inline-block;
    margin-bottom: 10px;
    color: #1f5f9f;
    text-decoration: none;
    font-weight: 700;
}

.app-chat-thread-subject {
    color: #666;
    margin-top: -6px;
}

.app-chat-messages {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin: 18px 0;
}

.app-chat-message {
    max-width: 75%;
    padding: 12px 14px;
    border-radius: 16px;
}

.app-chat-message-own {
    align-self: flex-end;
    background: #1f5f9f;
    color: #fff;
    border-bottom-right-radius: 4px;
}

.app-chat-message-other {
    align-self: flex-start;
    background: #eef2f7;
    color: #222;
    border-bottom-left-radius: 4px;
}

.app-chat-message-text {
    font-size: 15px;
    line-height: 1.4;
}

.app-chat-message-time {
    font-size: 11px;
    opacity: 0.75;
    margin-top: 6px;
    text-align: right;
}

.app-chat-send-form {
    display: flex;
    gap: 10px;
    margin-top: 16px;
}

.app-chat-send-form textarea {
    flex: 1;
    min-height: 55px;
    padding: 12px;
    border-radius: 14px;
    border: 1px solid #ccc;
    resize: vertical;
    font-size: 15px;
}

.app-chat-send-form button {
    padding: 0 22px;
    border: none;
    border-radius: 14px;
    background: #1f5f9f;
    color: #fff;
    font-weight: 700;
}


.app-chat-right {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 6px;
}

.app-chat-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 24px;
    height: 24px;
    padding: 0 7px;
    border-radius: 999px;
    background: #d60000;
    color: #fff;
    font-size: 13px;
    font-weight: 700;
}

.app-chat-actions {
    display: flex;
    gap: 8px;
    margin-top: 10px;
    flex-wrap: wrap;
}

.app-chat-btn-small {
    padding: 6px 12px;
    font-size: 13px;
}

.app-chat-btn-danger {
    background: #c62828;
}

.app-chat-btn-danger:hover {
    background: #9f1f1f;
}
.app-chat-form label{display:block;font-weight:700;margin:14px 0 6px}.app-chat-form input,.app-chat-form select,.app-chat-form textarea{width:100%;padding:12px;border:1px solid #ccd3dd;border-radius:12px;font-size:15px;box-sizing:border-box}.app-chat-form button{margin-top:16px;padding:12px 18px;border:0;border-radius:12px;background:#1f5f9f;color:#fff;font-weight:700}.app-chat-fehler{padding:12px;background:#ffe8e8;border-radius:12px;margin-bottom:12px}.app-chat-groups{display:grid;grid-template-columns:repeat(auto-fit,minmax(220px,1fr));gap:14px}.app-chat-group-card{display:flex;align-items:center;gap:12px;background:#f8fafc;border-radius:16px;padding:16px;text-decoration:none;color:#222;box-shadow:0 3px 10px rgba(0,0,0,.07)}.app-chat-message-sender{font-size:12px;font-weight:700;margin-bottom:5px;opacity:.75}
.app-chat-admin-wrap{max-width:1250px}.app-chat-admin-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(190px,1fr));gap:16px;margin:20px 0}.app-chat-admin-card{background:#fff;border-radius:14px;padding:20px;box-shadow:0 2px 10px rgba(0,0,0,.08);border:1px solid #e5e7eb}.app-chat-admin-number{font-size:34px;font-weight:800;color:#1f5f9f}.app-chat-admin-label{margin-top:6px;color:#555;font-weight:600}.app-chat-admin-actions{display:flex;flex-wrap:wrap;gap:10px;margin:18px 0 24px}.app-chat-admin-form{background:#fff;border:1px solid #e5e7eb;border-radius:14px;padding:16px;margin:18px 0}.app-chat-admin-wrap .widefat{margin-top:12px}.app-chat-admin-wrap textarea.large-text{max-width:760px}

.app-chat-box {
    max-width: 900px;
    margin: 20px auto;
    padding: 20px;
    background: #fff;
    border-radius: 15px;
    box-shadow: 0 4px 12px rgba(0,0,0,.1);
}

.app-chat-dashboard {
    max-width: 1000px;
    margin: 20px auto;
    padding: 16px;
}

.app-chat-header-image {
    width: 100%;
    border-radius: 18px;
    display: block;
    margin-bottom: 22px;
}

.app-chat-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
    gap: 18px;
}

.app-chat-card {
    background: #fff;
    border-radius: 18px;
    padding: 24px;
    text-align: center;
    text-decoration: none;
    color: #222;
    box-shadow: 0 6px 18px rgba(0,0,0,0.1);
}

.app-chat-card:hover {
    transform: translateY(-2px);
    color: #222;
}

.app-chat-icon {
    font-size: 42px;
    margin-bottom: 10px;
}

.app-chat-card h3 {
    margin: 8px 0;
    font-size: 22px;
}

.app-chat-card p {
    margin: 0;
    color: #666;
}

.app-chat-disabled {
    opacity: 0.65;
}

.app-chat-login-btn {
    display: inline-block;
    margin-top: 12px;
    padding: 14px 18px;
    border-radius: 12px;
    background: #1f5f9f;
    color: #fff;
    text-decoration: none;
    font-weight: 700;
}

.app-chat-login-btn:hover {
    background: #174a7c;
    color: #fff;
}

.app-chat-btn {
    display: inline-block;
    padding: 11px 16px;
    border-radius: 12px;
    background: #1f5f9f;
    color: #fff;
    text-decoration: none;
    font-weight: 700;
}

.app-chat-btn:hover {
    background: #174a7c;
    color: #fff;
}

.app-chat-empty {
    padding: 18px;
    background: #f3f6fa;
    border-radius: 12px;
}

.app-chat-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.app-chat-list-item {
    display: flex;
    gap: 14px;
    align-items: center;
    padding: 14px;
    background: #f8fafc;
    border-radius: 14px;
    text-decoration: none;
    color: #222;
}

.app-chat-list-item:hover {
    background: #eef5ff;
    color: #222;
}

.app-chat-avatar {
    width: 46px;
    height: 46px;
    border-radius: 50%;
    background: #e3f0ff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    flex-shrink: 0;
}

.app-chat-list-content {
    flex: 1;
}

.app-chat-subject {
    font-size: 14px;
    color: #1f5f9f;
    margin-top: 3px;
}

.app-chat-preview {
    font-size: 14px;
    color: #666;
    margin-top: 4px;
}

.app-chat-time {
    font-size: 13px;
    color: #888;
}

.app-chat-thread-head {
    margin-bottom: 16px;
}

.app-chat-back {
    display: inline-block;
    margin-bottom: 10px;
    color: #1f5f9f;
    text-decoration: none;
    font-weight: 700;
}

.app-chat-thread-subject {
    color: #666;
    margin-top: -6px;
}

.app-chat-messages {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin: 18px 0;
}

.app-chat-message {
    max-width: 75%;
    padding: 12px 14px;
    border-radius: 16px;
}

.app-chat-message-own {
    align-self: flex-end;
    background: #1f5f9f;
    color: #fff;
    border-bottom-right-radius: 4px;
}

.app-chat-message-other {
    align-self: flex-start;
    background: #eef2f7;
    color: #222;
    border-bottom-left-radius: 4px;
}

.app-chat-message-text {
    font-size: 15px;
    line-height: 1.4;
}

.app-chat-message-time {
    font-size: 11px;
    opacity: 0.75;
    margin-top: 6px;
    text-align: right;
}

.app-chat-send-form {
    display: flex;
    gap: 10px;
    margin-top: 16px;
}

.app-chat-send-form textarea {
    flex: 1;
    min-height: 55px;
    padding: 12px;
    border-radius: 14px;
    border: 1px solid #ccc;
    resize: vertical;
    font-size: 15px;
}

.app-chat-send-form button {
    padding: 0 22px;
    border: none;
    border-radius: 14px;
    background: #1f5f9f;
    color: #fff;
    font-weight: 700;
}


.app-chat-right {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 6px;
}

.app-chat-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 24px;
    height: 24px;
    padding: 0 7px;
    border-radius: 999px;
    background: #d60000;
    color: #fff;
    font-size: 13px;
    font-weight: 700;
}

.app-chat-actions {
    display: flex;
    gap: 8px;
    margin-top: 10px;
    flex-wrap: wrap;
}

.app-chat-btn-small {
    padding: 6px 12px;
    font-size: 13px;
}

.app-chat-btn-danger {
    background: #c62828;
}

.app-chat-btn-danger:hover {
    background: #9f1f1f;
}
.app-chat-read-status {
    display: inline-block;
    margin-left: 8px;
    font-size: 11px;
    opacity: 0.9;
}

.app-mitglieder-card-chat {
    position: relative;
}

.app-mitglieder-card-chat .app-chat-badge {
    margin-left: 8px;
    vertical-align: middle;
}

.app-chat-preview-own{
    display:block;
    color:#1f5f9f;
    font-weight:700;
    margin-bottom:2px;
}

.app-chat-preview-other{
    display:block;
    color:#222;
    font-weight:700;
    margin-bottom:2px;
}

.app-chat-preview-text{
    display:block;
    color:#666;
    font-weight:400;
}

.app-chat-preview-unread .app-chat-preview-text{
    color:#222;
    font-weight:700;
}
.app-chat-preview-text{
    color:#666;
    font-weight:400;
}

.app-chat-preview-unread .app-chat-preview-text{
    color:#222;
    font-weight:700;
}
