* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Tahoma, sans-serif;
}

.chat-container {
    width: 100%;
    max-width: 450px;
    height: 100vh;
    display: flex;
    flex-direction: column;
    background-color: #e5ddd5;
    /* Ganti URL ini dengan gambar pattern WhatsApp jika ada */
    background-image: url('https://user-images.githubusercontent.com/15075759/28719144-86dc0f70-73b1-11e7-911d-60d70fcded21.png');
    margin: 0 auto;
}

/* Header */
.chat-header {
    background: #fff;
    padding: 10px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.header-left {
    display: flex;
    align-items: center;
    gap: 10px;
}

.profile-pic {
    width: 35px;
    height: 35px;
    border-radius: 50%;
}

.user-name {
    font-weight: 600;
    font-size: 16px;
}

.header-right {
    display: flex;
    gap: 20px;
    color: #555;
    font-size: 18px;
}

/* Chat Body */
.chat-body {
    flex: 1;
    overflow-y: auto;
    padding: 15px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.message {
    display: flex;
    width: 100%;
}

.message.incoming { justify-content: flex-start; }
.message.outgoing { justify-content: flex-end; }

.bubble {
    max-width: 85%;
    padding: 6px 8px;
    border-radius: 8px;
    position: relative;
    font-size: 14.5px;
    box-shadow: 0 1px 1px rgba(0,0,0,0.1);
}

.incoming .bubble {
    background: #fff;
    border-top-left-radius: 0;
}

.outgoing .bubble {
    background: #e7ffdb;
    border-top-right-radius: 0;
}

/* Reply Box */
.reply-box {
    background: rgba(0,0,0,0.05);
    border-left: 4px solid #06cf9c;
    border-radius: 4px;
    padding: 5px 8px;
    margin-bottom: 4px;
}

.reply-blue { border-left-color: #34b7f1; }

.reply-sender {
    display: block;
    font-size: 12px;
    font-weight: bold;
    color: #06cf9c;
}

.reply-blue .reply-sender { color: #34b7f1; }

.reply-box p {
    font-size: 13px;
    color: #666;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Message Info */
.message-text {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    gap: 10px;
}

.message-time {
    font-size: 11px;
    color: #888;
    margin-top: 5px;
}

.message-info {
    display: flex;
    align-items: center;
    gap: 3px;
}

.status-read {
    color: #34b7f1;
    font-size: 12px;
}

/* Footer */
.chat-footer {
    padding: 10px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.input-wrapper {
    flex: 1;
    background: #fff;
    border-radius: 25px;
    padding: 10px 15px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.input-wrapper input {
    flex: 1;
    border: none;
    outline: none;
    font-size: 16px;
}

.input-wrapper i {
    color: #888;
    font-size: 20px;
}

.mic-button {
    width: 45px;
    height: 45px;
    background: #00a884;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 20px;
}

a{
    text-decoration: none;
    color: black;
}

/* Ambil basis CSS dari jawaban sebelumnya, tambahkan ini: */

/* Map Bubble */
.map-bubble {
    padding: 4px !important;
    overflow: hidden;
}
.map-img {
    width: 100%;
    border-radius: 6px;
    display: block;
}
.map-info {
    text-align: right;
    padding: 2px 5px;
}

/* Voice Note Bubble */
.vn-bubble {
    min-width: 200px;
    padding: 10px !important;
}
.vn-controls {
    display: flex;
    align-items: center;
    gap: 10px;
}
.vn-play { font-size: 20px; color: #555; }
.vn-waveform {
    flex: 1;
    height: 15px;
    background: repeating-linear-gradient(90deg, #ccc, #ccc 2px, transparent 2px, transparent 4px);
    position: relative;
}
.waveform-progress {
    width: 30%;
    height: 100%;
    background: repeating-linear-gradient(90deg, #34b7f1, #34b7f1 2px, transparent 2px, transparent 4px);
}
.vn-speed {
    background: #8e9ba3;
    color: white;
    padding: 4px 10px;
    border-radius: 15px;
    font-size: 12px;
}
.vn-footer {
    display: flex;
    justify-content: space-between;
    font-size: 11px;
    color: #888;
    margin-top: 5px;
}

/* Image Bubble */
.image-bubble {
    padding: 4px !important;
    position: relative;
}
.chat-image {
    width: 100%;
    border-radius: 6px;
    display: block;
}
.image-overlay-info {
    position: absolute;
    bottom: 35px;
    right: 10px;
    color: white;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.5);
    font-size: 11px;
    display: flex;
    gap: 5px;
}
.hd-badge {
    border: 1px solid white;
    padding: 0 2px;
    border-radius: 2px;
    font-size: 8px;
}
.reply-count {
    padding: 8px;
    font-size: 13px;
    color: #555;
    border-top: 1px solid #f0f0f0;
}

/* Reply with Image Thumbnail */
.reply-image {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 0 0 8px !important;
}
.reply-text { flex: 1; }
.reply-thumb {
    width: 45px;
    height: 45px;
    object-fit: cover;
    border-radius: 0 4px 4px 0;
}


