.seller-chat-layout {
    display: grid;
    grid-template-columns: 320px 1fr;
    gap: 16px;
    height: calc(100vh - 125px);
    min-height: 600px;
}

.seller-chat-panel {
    background: #fff;
    border-radius: 16px;
    border: 1px solid rgba(0, 0, 0, .05);
    box-shadow: 0 2px 12px rgba(0, 0, 0, .05);
    overflow: hidden;
}

.seller-chat-list-panel {
    display: flex;
    flex-direction: column;
    min-height: 0;
}

.seller-chat-heading {
    padding: 18px;
    border-bottom: 1px solid #edf1ed;
}

.seller-chat-heading h3 {
    color: #1b5e20;
    margin-bottom: 4px;
}

.seller-chat-heading p {
    font-size: .8rem;
    color: #888;
}

.seller-chat-search {
    margin: 12px;
    padding: 10px 12px;
    border: 1px solid #dce5dc;
    border-radius: 10px;
    font-family: 'Sarabun', sans-serif;
}

.seller-conversation-list {
    overflow: auto;
    flex: 1;
}

.seller-conversation-item {
    display: flex;
    gap: 10px;
    padding: 13px;
    border-top: 1px solid #f0f2f0;
    cursor: pointer;
}

.seller-conversation-item:hover,
.seller-conversation-item.active {
    background: #eef8ee;
}

.seller-chat-avatar {
    width: 45px;
    height: 45px;
    border-radius: 50%;
    overflow: hidden;
    border: 2px solid #2d8b46;
    background: #e8f5e9;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.seller-chat-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.seller-conversation-body {
    min-width: 0;
    flex: 1;
}

.seller-conversation-name {
    font-weight: 700;
    color: #1b5e20;
}

.seller-conversation-last {
    font-size: .78rem;
    color: #777;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.seller-chat-room {
    display: flex;
    flex-direction: column;
    min-height: 0;
}

.seller-chat-room-head {
    display: flex;
    gap: 12px;
    align-items: center;
    padding: 13px 17px;
    border-bottom: 1px solid #e8eee8;
}

.seller-chat-customer-name {
    font-weight: 700;
    color: #1b5e20;
}

.seller-chat-status {
    font-size: .77rem;
    color: #888;
}

.seller-chat-messages {
    flex: 1;
    overflow: auto;
    padding: 20px;
    background: linear-gradient(#f8fbf8, #f1f6f1);
}

.seller-chat-empty {
    height: 100%;
    min-height: 180px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: #999;
    padding: 20px;
}

.seller-message-row {
    display: flex;
    margin: 8px 0;
}

.seller-message-row.mine {
    justify-content: flex-end;
}

.seller-message-bubble {
    max-width: 72%;
    padding: 10px 12px;
    border-radius: 14px;
    background: #fff;
    box-shadow: 0 2px 8px rgba(0, 0, 0, .06);
}

.seller-message-row.mine .seller-message-bubble {
    background: linear-gradient(135deg, #2d8b46, #1b6b30);
    color: #fff;
}

.seller-message-media img,
.seller-message-media video {
    max-width: 100%;
    max-height: 330px;
    border-radius: 10px;
}

.seller-message-time {
    text-align: right;
    font-size: .67rem;
    color: #999;
    margin-top: 4px;
}

.seller-message-row.mine .seller-message-time {
    color: rgba(255, 255, 255, .75);
}

.seller-chat-compose {
    padding: 12px;
    border-top: 1px solid #e2e9e2;
}

.seller-chat-compose-row {
    display: flex;
    gap: 8px;
    align-items: flex-end;
}

.seller-chat-compose textarea {
    flex: 1;
    min-height: 44px;
    max-height: 120px;
    padding: 11px;
    border: 1px solid #dce5dc;
    border-radius: 11px;
    resize: none;
    font-family: 'Sarabun', sans-serif;
}

.seller-chat-attach {
    width: 44px;
    height: 44px;
    border: 0;
    border-radius: 10px;
    background: #e8f5e9;
    cursor: pointer;
}

.seller-chat-send {
    height: 44px;
    padding: 0 20px;
    border: 0;
    border-radius: 10px;
    background: #2d8b46;
    color: #fff;
    font-family: 'Sarabun', sans-serif;
    font-weight: 700;
}

.seller-chat-preview img,
.seller-chat-preview video {
    width: 70px;
    height: 55px;
    object-fit: cover;
    border-radius: 8px;
    margin-bottom: 8px;
}

@media (max-width: 900px) {
    .seller-chat-layout {
        grid-template-columns: 1fr;
        height: auto;
    }

    .seller-chat-list-panel {
        max-height: 260px;
    }

    .seller-chat-room {
        height: 620px;
    }
}