* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

body {
    background-color: #f0f2f5;
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
}

/* ===================== CONTAINER ===================== */
.chat-container {
    width: 100%;
    max-width: 450px;
    height: 90vh;
    background: white;
    display: flex;
    flex-direction: column;
    box-shadow: 0 12px 28px rgba(0, 0, 0, 0.12);
    border-radius: 12px;
    overflow: hidden;
}

/* ===================== HEADER ===================== */
.chat-header {
    background: #004a8e;
    color: white;
    padding: 15px 20px;
    display: flex;
    align-items: center;
}

.header-info {
    display: flex;
    align-items: center;
    gap: 12px;
}

.avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-size: cover;
    background-position: center;
}

.status h2 {
    font-size: 16px;
    font-weight: 600;
}

.online-status {
    font-size: 12px;
    opacity: 0.85;
}

.online-status::before {
    content: '';
    display: inline-block;
    width: 8px;
    height: 8px;
    background: #42b72a;
    border-radius: 50%;
    margin-right: 5px;
}

/* ===================== MESSAGES ===================== */
.chat-messages {
    flex: 1;
    padding: 20px;
    overflow-y: auto;
    background: #e5ddd5;
    display: flex;
    flex-direction: column;
    gap: 15px;
    scroll-behavior: smooth;
}

.message {
    max-width: 85%;
    display: flex;
    flex-direction: column;
    animation: fadeIn 0.3s ease-out forwards;
}

.message.bot {
    align-self: flex-start;
}

.message.user {
    align-self: flex-end;
}

.bubble {
    padding: 10px 15px;
    border-radius: 18px;
    font-size: 14px;
    line-height: 1.4;
}

.bot .bubble {
    background: #ffffff;
    color: #333;
    border-bottom-left-radius: 4px;
    box-shadow: 0 1px 2px rgba(0,0,0,0.1);
}

.user .bubble {
    background: #dcf8c6;
    color: #333;
    border-bottom-right-radius: 4px;
    box-shadow: 0 1px 2px rgba(0,0,0,0.1);
}

/* ===================== MEDIA ===================== */
.media-bubble {
    padding: 0 !important;
    overflow: hidden;
}

.media-bubble img {
    display: block;
    width: 100%;
    border-radius: 10px;
}

/* ===================== AUDIO CHAT ===================== */
.audio-bubble {
    padding: 8px 10px !important;
    background: #f1f1f1 !important;
}

.audio-bubble audio {
    width: 100%;
    max-width: 260px;
    border-radius: 12px;
    outline: none;
}

/* Remove estilo feio do Chrome */
audio::-webkit-media-controls-panel {
    background-color: #f1f1f1;
}

audio::-webkit-media-controls-play-button {
    background-color: #004a8e;
    border-radius: 50%;
}

audio::-webkit-media-controls-current-time-display,
audio::-webkit-media-controls-time-remaining-display {
    color: #333;
    font-size: 11px;
}

audio::-webkit-media-controls-timeline {
    border-radius: 10px;
}

/* ===================== SPECIAL BUBBLES ===================== */
.data-card {
    border-left: 4px solid #004a8e;
}

.status-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.status-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
}

.status-item i.fa-check-circle {
    color: #28a745;
}

.highlight {
    background: #fff3cd !important;
    border: 1px solid #ffeeba;
    font-weight: bold;
    text-align: center;
}

.success {
    background: #d4edda !important;
    color: #155724 !important;
    border: 1px solid #c3e6cb;
}

.warning {
    background: #fff3cd !important;
    color: #856404 !important;
    border: 1px solid #ffeeba;
}

/* ===================== SLIDER ===================== */
.slider-container {
    width: 100%;
    text-align: center;
}

.slider-box {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 15px 0;
}

.slider {
    flex: 1;
    cursor: pointer;
}

.current-val {
    font-size: 24px;
    font-weight: bold;
    color: #004a8e;
    margin-bottom: 10px;
}

.confirm-btn,
.pay-btn {
    width: 100%;
    padding: 10px;
    background: #28a745;
    color: white;
    border: none;
    border-radius: 8px;
    font-weight: bold;
    cursor: pointer;
    transition: background 0.3s;
}

.confirm-btn:hover,
.pay-btn:hover {
    background: #218838;
}

/* ===================== OPTIONS ===================== */
.options-container {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: center;
    width: 100%;
}

.opt-btn {
    padding: 8px 15px;
    background: #004a8e;
    color: white;
    border-radius: 20px;
    cursor: pointer;
    font-size: 13px;
    border: none;
}

/* ===================== INPUT ===================== */
.chat-input {
    padding: 15px;
    background: #f0f2f5;
    border-top: 1px solid #ddd;
}

.input-field-mock {
    width: 100%;
    padding: 10px;
    border: 1px solid #004a8e;
    border-radius: 8px;
    outline: none;
}

/* ===================== TYPING ===================== */
.typing-dots {
    display: flex;
    gap: 4px;
}

.typing-dots span {
    width: 8px;
    height: 8px;
    background: #999;
    border-radius: 50%;
    animation: typing 1s infinite;
}

.typing-dots span:nth-child(2) { animation-delay: 0.2s; }
.typing-dots span:nth-child(3) { animation-delay: 0.4s; }

@keyframes typing {
    50% { transform: translateY(-5px); }
}

/* === AUDIO CHAT STYLE === */
.audio-chat {
    display: flex;
    align-items: center;
    gap: 10px;
    background: #f1f1f1;
    padding: 10px 12px;
    border-radius: 14px;
    max-width: 260px;
}

.audio-play {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    border: none;
    background: #4CAF50;
    color: white;
    font-size: 14px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.audio-content {
    flex: 1;
}

.audio-bar {
    width: 100%;
    height: 6px;
    background: #ddd;
    border-radius: 5px;
    overflow: hidden;
}

.audio-progress {
    width: 0%;
    height: 100%;
    background: #4CAF50;
    transition: width 0.1s linear;
}

.audio-time {
    font-size: 11px;
    color: #555;
    margin-top: 4px;
    text-align: right;
}

.audio-chat audio {
    display: none;
}

/* ===== AUDIO FIX ===== */

.audio-bubble {
    width: 100%;
    max-width: 280px;
    padding: 8px !important;
}

.audio-bubble audio {
    width: 100% !important;
    height: 40px;
    border-radius: 12px;
}

/* Ajuste geral do bubble para mídia */
.message.bot .audio-bubble {
    background: #ffffff;
}


/* ===================== TAX CARD ===================== */
.tax-card {
    background: #f8f9fa !important;
    border: 1px solid #dee2e6 !important;
    padding: 0 !important;
}

.tax-header {
    background: #343a40;
    color: white;
    padding: 8px;
    text-align: center;
    font-weight: bold;
}

.tax-body {
    padding: 15px;
}

/* ===================== ANIMATIONS ===================== */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ===================== SCROLLBAR ===================== */
.chat-messages::-webkit-scrollbar {
    width: 6px;
}

.chat-messages::-webkit-scrollbar-thumb {
    background: rgba(0,0,0,0.15);
    border-radius: 10px;
}
