/* WhatsApp Sender Pro V8 - Styles */
:root {
    --primary: #00a884;
    --primary-dark: #008069;
    --primary-light: #25d366;
    --secondary: #111b21;
    --bg-primary: #0b141a;
    --bg-secondary: #111b21;
    --bg-card: #1f2c34;
    --bg-hover: #2a3942;
    --text-primary: #e9edef;
    --text-secondary: #8696a0;
    --text-muted: #667781;
    --border: #2a3942;
    --success: #00c853;
    --danger: #f15c6d;
    --warning: #f7c94b;
    --info: #53bdeb;
    --gradient-green: linear-gradient(135deg, #00a884, #00c853);
    --gradient-blue: linear-gradient(135deg, #0088cc, #53bdeb);
    --gradient-purple: linear-gradient(135deg, #7c4dff, #b47cff);
    --gradient-red: linear-gradient(135deg, #f15c6d, #ff8a80);
    --bg-tertiary: #1a2730;
    --shadow: 0 2px 12px rgba(0, 0, 0, 0.3);
    --radius: 12px;
    --radius-sm: 8px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Plus Jakarta Sans', sans-serif;
    background: var(--bg-primary);
    color: var(--text-primary);
    min-height: 100vh;
}

/* Layout */
.app-container {
    display: flex;
    min-height: 100vh;
}

/* Sidebar */
.sidebar {
    width: 260px;
    background: var(--bg-secondary);
    border-right: 1px solid var(--border);
    display: flex;
    flex-direction: column;
    position: fixed;
    height: 100vh;
    z-index: 100;
}

.logo {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 20px;
    border-bottom: 1px solid var(--border);
}

.logo-icon {
    width: 44px;
    height: 44px;
    background: var(--gradient-green);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    color: white;
}

.logo-text {
    display: flex;
    flex-direction: column;
}

.logo-text .brand {
    font-weight: 700;
    font-size: 18px;
}

.logo-text .version {
    font-size: 11px;
    color: var(--primary);
    font-weight: 600;
}

.nav-menu {
    flex: 1;
    padding: 12px;
    overflow-y: auto;
}

.nav-section {
    margin-bottom: 20px;
}

.nav-label {
    font-size: 11px;
    color: var(--text-muted);
    text-transform: uppercase;
    padding: 8px 12px;
    display: block;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 14px;
    border-radius: var(--radius-sm);
    color: var(--text-secondary);
    text-decoration: none;
    font-weight: 500;
    font-size: 14px;
    transition: all 0.2s;
}

.nav-item:hover {
    background: var(--bg-hover);
    color: var(--text-primary);
}

.nav-item.active {
    background: var(--primary);
    color: white;
}

.nav-item i {
    width: 20px;
    text-align: center;
}

.connection-status {
    padding: 16px 20px;
    border-top: 1px solid var(--border);
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 13px;
}

.status-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    animation: pulse 2s infinite;
}

.status-dot.connected {
    background: var(--success);
    box-shadow: 0 0 8px var(--success);
}

.status-dot.disconnected {
    background: var(--danger);
    box-shadow: 0 0 8px var(--danger);
}

@keyframes pulse {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0.5;
    }
}

/* Main Content */
.main-content {
    flex: 1;
    margin-left: 260px;
    padding: 24px;
    min-height: 100vh;
    background: var(--bg-primary);
}

/* Header */
.header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
}

.header h1 {
    font-size: 26px;
    font-weight: 700;
}

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

.incoming-badge {
    background: var(--danger);
    color: white;
    padding: 8px 14px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 600;
    animation: bounce 1s infinite;
}

@keyframes bounce {

    0%,
    100% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.05);
    }
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    border: none;
    border-radius: var(--radius-sm);
    font-family: inherit;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-primary {
    background: var(--primary);
    color: white;
}

.btn-primary:hover {
    background: var(--primary-dark);
    transform: translateY(-1px);
}

.btn-success {
    background: var(--success);
    color: white;
}

.btn-danger {
    background: var(--danger);
    color: white;
}

.btn-outline {
    background: transparent;
    border: 2px solid var(--border);
    color: var(--text-primary);
}

.btn-outline:hover {
    border-color: var(--primary);
    color: var(--primary);
}

.btn-ghost {
    background: transparent;
    color: var(--text-secondary);
}

.btn-ghost:hover {
    color: var(--text-primary);
}

.btn-sm {
    padding: 6px 12px;
    font-size: 12px;
}

.btn-lg {
    padding: 14px 28px;
    font-size: 16px;
}

.btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.button-group {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

/* Cards */
.card {
    background: var(--bg-card);
    border-radius: var(--radius);
    border: 1px solid var(--border);
    margin-bottom: 20px;
}

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 20px;
    border-bottom: 1px solid var(--border);
}

.card-header h3 {
    font-size: 16px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.card-header h3 i {
    color: var(--primary);
}

.card-body {
    padding: 20px;
}

/* Stats Grid */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 16px;
    margin-bottom: 24px;
}

.stat-card {
    background: var(--bg-card);
    border-radius: var(--radius);
    padding: 20px;
    display: flex;
    align-items: center;
    gap: 16px;
    border: 1px solid var(--border);
}

.stat-card.gradient-green {
    background: var(--gradient-green);
    border: none;
}

.stat-card.gradient-blue {
    background: var(--gradient-blue);
    border: none;
}

.stat-card.gradient-purple {
    background: var(--gradient-purple);
    border: none;
}

.stat-card.gradient-red {
    background: var(--gradient-red);
    border: none;
}

.stat-icon {
    width: 50px;
    height: 50px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
}

.stat-info h3 {
    font-size: 28px;
    font-weight: 700;
}

.stat-info p {
    font-size: 13px;
    opacity: 0.9;
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 30px 20px;
    color: var(--text-muted);
}

.empty-state i {
    font-size: 40px;
    margin-bottom: 12px;
    display: block;
    opacity: 0.3;
}

.empty-state p {
    font-size: 14px;
}

/* Content Sections */
.content-section {
    display: none;
    animation: fadeIn 0.3s;
}

.content-section.active {
    display: block;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

/* QR Section */
.qr-section {
    margin-bottom: 24px;
}

.qr-card {
    background: var(--bg-card);
    border-radius: var(--radius);
    padding: 32px;
    text-align: center;
    border: 1px solid var(--border);
}

.qr-card h2 {
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.qr-card h2 i {
    color: var(--primary);
}

.qr-card>p {
    color: var(--text-secondary);
    margin-bottom: 24px;
}

.qr-container {
    min-height: 250px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.qr-container img {
    border-radius: 12px;
}

.qr-placeholder {
    color: var(--text-muted);
    text-align: center;
}

.qr-placeholder i {
    font-size: 64px;
    margin-bottom: 16px;
    opacity: 0.3;
}

/* Forms */
.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    font-size: 14px;
}

.form-group small {
    display: block;
    margin-top: 6px;
    color: var(--text-muted);
    font-size: 12px;
}

.form-group input[type="text"],
.form-group input[type="number"],
.form-group input[type="datetime-local"],
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid var(--border);
    border-radius: var(--radius-sm);
    background: var(--bg-secondary);
    color: var(--text-primary);
    font-family: inherit;
    font-size: 14px;
    transition: border-color 0.2s;
}

.form-group input[type="date"],
.form-group input[type="time"] {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid var(--border);
    border-radius: var(--radius-sm);
    background: var(--bg-secondary);
    color: var(--text-primary);
    font-family: inherit;
    font-size: 14px;
    transition: border-color 0.2s;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--primary);
}

.form-group textarea {
    min-height: 120px;
    resize: vertical;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

.input-with-btn {
    display: flex;
    gap: 10px;
}

.input-with-btn input {
    flex: 1;
}

.textarea-footer {
    display: flex;
    justify-content: space-between;
    margin-top: 8px;
    font-size: 12px;
    color: var(--text-muted);
}

.file-upload {
    display: flex;
    align-items: center;
    gap: 12px;
}

/* Two Column Layout */
.two-column {
    display: grid;
    grid-template-columns: 1fr 350px;
    gap: 20px;
}

/* Phone Mockup */
.phone-mockup {
    background: #e5ddd5;
    border-radius: 20px;
    overflow: hidden;
}

.phone-header {
    background: var(--primary-dark);
    color: white;
    padding: 12px 16px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.phone-header .contact-info {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 10px;
}

.phone-header .avatar {
    width: 36px;
    height: 36px;
    background: var(--primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
}

.phone-body {
    padding: 16px;
    min-height: 300px;
    background-size: 400px;
}

.message-bubble {
    background: #dcf8c6;
    padding: 8px 12px;
    border-radius: 8px;
    border-top-right-radius: 0;
    max-width: 85%;
    margin-left: auto;
    color: #303030;
    font-size: 14px;
}

.message-bubble .time {
    display: block;
    text-align: right;
    font-size: 11px;
    color: #667781;
    margin-top: 4px;
}

/* Progress */
.progress-section {
    margin-top: 20px;
    padding: 16px;
    background: var(--bg-secondary);
    border-radius: var(--radius-sm);
}

.progress-bar {
    height: 8px;
    background: var(--border);
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 12px;
}

.progress-fill {
    height: 100%;
    background: var(--gradient-green);
    width: 0%;
    transition: width 0.3s;
}

.progress-stats {
    display: flex;
    gap: 20px;
    font-size: 14px;
    font-weight: 600;
}

/* Tables */
.table-wrapper {
    overflow-x: auto;
    max-width: 100%;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
    table-layout: fixed;
}

.data-table th,
.data-table td {
    padding: 12px 10px;
    text-align: left;
    border-bottom: 1px solid var(--border);
    overflow: hidden;
    text-overflow: ellipsis;
}

.data-table th {
    background: var(--bg-secondary);
    font-weight: 600;
    font-size: 12px;
    text-transform: uppercase;
    color: var(--text-muted);
}

.data-table tr:hover {
    background: var(--bg-hover);
}

.data-table input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: var(--primary);
}

/* Contact table specific column widths */
#contactsTable td:nth-child(1),
#contactsSection th:nth-child(1) {
    width: 40px;
}

#contactsTable td:nth-child(2),
#contactsSection th:nth-child(2) {
    width: 25%;
}

#contactsTable td:nth-child(3),
#contactsSection th:nth-child(3) {
    width: 20%;
}

#contactsTable td:nth-child(4),
#contactsSection th:nth-child(4) {
    width: 15%;
}

#contactsTable td:nth-child(5),
#contactsSection th:nth-child(5) {
    width: 120px;
}

/* Pagination */
#contactsPagination {
    display: flex !important;
    justify-content: center;
    align-items: center;
    gap: 15px;
    padding: 15px;
    background: var(--bg-tertiary);
    border-top: 1px solid var(--border);
    margin-top: 0;
}

/* Templates Grid */
.templates-grid,
.groups-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 16px;
    padding: 20px;
}

.template-card,
.group-card {
    background: var(--bg-secondary);
    border-radius: var(--radius-sm);
    padding: 16px;
    border: 1px solid var(--border);
    transition: all 0.2s;
}

.template-card:hover,
.group-card:hover {
    border-color: var(--primary);
}

.template-card h4 {
    color: var(--primary);
    margin-bottom: 8px;
}

.template-card p {
    color: var(--text-secondary);
    font-size: 13px;
    line-height: 1.5;
    margin-bottom: 12px;
}

/* Activity Log */
.activity-log {
    max-height: 350px;
    overflow-y: auto;
    padding: 16px;
}

.log-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 14px;
    border-radius: var(--radius-sm);
    margin-bottom: 8px;
    background: var(--bg-secondary);
    font-size: 13px;
}

.log-item.success {
    border-left: 3px solid var(--success);
}

.log-item.error {
    border-left: 3px solid var(--danger);
}

.log-item.info {
    border-left: 3px solid var(--info);
}

.log-item i {
    font-size: 14px;
}

.log-item.success i {
    color: var(--success);
}

.log-item.error i {
    color: var(--danger);
}

.log-item.info i {
    color: var(--info);
}

.log-item .msg {
    flex: 1;
}

.log-item .time {
    color: var(--text-muted);
    font-size: 11px;
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 40px;
    color: var(--text-muted);
}

.empty-state i {
    font-size: 48px;
    margin-bottom: 12px;
    opacity: 0.3;
}

/* Settings */
.setting-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 0;
    border-bottom: 1px solid var(--border);
}

.setting-item:last-child {
    border-bottom: none;
}

.setting-item.danger {
    color: var(--danger);
}

.setting-info h4 {
    margin-bottom: 4px;
}

.setting-info p {
    font-size: 13px;
    color: var(--text-muted);
}

/* Switch */
.switch {
    position: relative;
    width: 48px;
    height: 26px;
}

.switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.slider {
    position: absolute;
    cursor: pointer;
    inset: 0;
    background: var(--border);
    border-radius: 26px;
    transition: 0.3s;
}

.slider:before {
    position: absolute;
    content: "";
    height: 20px;
    width: 20px;
    left: 3px;
    bottom: 3px;
    background: white;
    border-radius: 50%;
    transition: 0.3s;
}

input:checked+.slider {
    background: var(--primary);
}

input:checked+.slider:before {
    transform: translateX(22px);
}

/* Modal */
.modal {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.7);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    backdrop-filter: blur(4px);
}

.modal.active {
    display: flex;
}

.modal-content {
    background: var(--bg-card);
    border-radius: var(--radius);
    width: 90%;
    max-width: 500px;
    max-height: 90vh;
    overflow: hidden;
    animation: modalIn 0.3s;
}

@keyframes modalIn {
    from {
        opacity: 0;
        transform: scale(0.9);
    }

    to {
        opacity: 1;
        transform: scale(1);
    }
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 20px;
    border-bottom: 1px solid var(--border);
}

.modal-close {
    background: none;
    border: none;
    font-size: 24px;
    color: var(--text-muted);
    cursor: pointer;
}

.modal-close:hover {
    color: var(--danger);
}

.modal-body {
    padding: 20px;
    max-height: 60vh;
    overflow-y: auto;
}

.modal-footer {
    padding: 16px 20px;
    border-top: 1px solid var(--border);
    display: flex;
    justify-content: flex-end;
    gap: 10px;
}

/* Toast */
.toast-container {
    position: fixed;
    bottom: 24px;
    right: 24px;
    z-index: 1001;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.toast {
    background: var(--bg-card);
    border-radius: var(--radius-sm);
    padding: 14px 18px;
    display: flex;
    align-items: center;
    gap: 12px;
    box-shadow: var(--shadow);
    animation: toastIn 0.3s;
    min-width: 280px;
}

@keyframes toastIn {
    from {
        opacity: 0;
        transform: translateX(100px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.toast.success {
    border-left: 4px solid var(--success);
}

.toast.error {
    border-left: 4px solid var(--danger);
}

.toast.info {
    border-left: 4px solid var(--info);
}

.toast i {
    font-size: 18px;
}

.toast.success i {
    color: var(--success);
}

.toast.error i {
    color: var(--danger);
}

.toast.info i {
    color: var(--info);
}

/* Status badges */
.badge {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
}

.badge-success {
    background: rgba(0, 200, 83, 0.15);
    color: var(--success);
}

.badge-danger {
    background: rgba(241, 92, 109, 0.15);
    color: var(--danger);
}

.badge-warning {
    background: rgba(247, 201, 75, 0.15);
    color: var(--warning);
}

.badge-info {
    background: rgba(83, 189, 235, 0.15);
    color: var(--info);
}

/* Text utilities */
.text-success {
    color: var(--success);
}

.text-danger {
    color: var(--danger);
}

.text-warning {
    color: var(--warning);
}

.text-muted {
    color: var(--text-muted);
}

/* Scrollbar */
::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}

::-webkit-scrollbar-track {
    background: var(--bg-primary);
}

::-webkit-scrollbar-thumb {
    background: var(--border);
    border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--primary);
}

/* Responsive */
@media (max-width: 1200px) {
    .two-column {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .sidebar {
        width: 70px;
    }

    .logo-text,
    .nav-label,
    .nav-item span,
    .connection-status span {
        display: none;
    }

    .nav-item {
        justify-content: center;
    }

    .main-content {
        margin-left: 70px;
        padding: 16px;
    }

    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* WhatsApp Web Style Inbox */
.wa-inbox {
    display: flex;
    height: calc(100vh - 100px);
    background: #111b21;
    border-radius: 0;
    overflow: hidden;
}

.wa-sidebar {
    width: 400px;
    min-width: 340px;
    background: #111b21;
    border-right: 1px solid #2a3942;
    display: flex;
    flex-direction: column;
}

.wa-sidebar-header {
    height: 60px;
    background: #202c33;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 16px;
}

.wa-profile {
    display: flex;
    align-items: center;
}

.wa-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: #6b7c85;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #cfd8dc;
    overflow: hidden;
}

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

.wa-header-actions {
    display: flex;
    gap: 8px;
}

.wa-icon-btn {
    width: 40px;
    height: 40px;
    border: none;
    background: transparent;
    color: #aebac1;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    transition: background 0.2s;
}

.wa-icon-btn:hover {
    background: rgba(255, 255, 255, 0.1);
}

.wa-search {
    padding: 8px 12px;
    background: #111b21;
}

.wa-search-box {
    display: flex;
    align-items: center;
    background: #202c33;
    border-radius: 8px;
    padding: 0 12px;
    height: 35px;
}

.wa-search-box i {
    color: #8696a0;
    font-size: 14px;
    margin-right: 12px;
}

.wa-search-box input {
    flex: 1;
    border: none;
    background: transparent;
    color: #e9edef;
    font-size: 14px;
    outline: none;
}

.wa-search-box input::placeholder {
    color: #8696a0;
}

.wa-chat-list {
    flex: 1;
    overflow-y: auto;
}

.wa-chat-item {
    display: flex;
    align-items: center;
    padding: 12px 16px;
    cursor: pointer;
    border-bottom: 1px solid #222d34;
    transition: background 0.15s;
}

.wa-chat-item:hover {
    background: #202c33;
}

.wa-chat-item.active {
    background: #2a3942;
}

.wa-chat-item .wa-avatar {
    width: 49px;
    height: 49px;
    margin-right: 14px;
    flex-shrink: 0;
}

.wa-chat-content {
    flex: 1;
    min-width: 0;
}

.wa-chat-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 3px;
}

.wa-chat-name {
    font-size: 16px;
    color: #e9edef;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.wa-chat-time {
    font-size: 12px;
    color: #8696a0;
    flex-shrink: 0;
    margin-left: 8px;
}

.wa-chat-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.wa-chat-preview {
    font-size: 14px;
    color: #8696a0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    flex: 1;
}

.wa-unread {
    background: #00a884;
    color: #111b21;
    font-size: 11px;
    font-weight: 600;
    padding: 2px 6px;
    border-radius: 10px;
    min-width: 20px;
    text-align: center;
    margin-left: 8px;
}

/* Main Chat Area */
.wa-main {
    flex: 1;
    display: flex;
    flex-direction: column;
    background: #0b141a;
}

.wa-chat-header {
    height: 60px;
    background: #202c33;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 16px;
}

.wa-chat-info {
    display: flex;
    align-items: center;
    gap: 14px;
}

.wa-chat-details h4 {
    font-size: 16px;
    color: #e9edef;
    font-weight: 500;
    margin: 0;
}

.wa-chat-details span {
    font-size: 13px;
    color: #8696a0;
}

.wa-chat-actions {
    display: flex;
    gap: 4px;
}

/* Messages Area */
.wa-messages {
    flex: 1;
    overflow-y: auto;
    padding: 20px 60px;
    background-color: #0b141a;
    background-image: url("data:image/svg+xml,%3Csvg width='412' height='412' xmlns='http://www.w3.org/2000/svg'%3E%3Cdefs%3E%3Cpattern id='a' patternUnits='userSpaceOnUse' width='20' height='20'%3E%3Cpath d='M0 20L20 0M-5 5L5-5M15 25L25 15' stroke='%23101d24' stroke-width='1'/%3E%3C/pattern%3E%3C/defs%3E%3Crect fill='url(%23a)' width='100%25' height='100%25'/%3E%3C/svg%3E");
    position: relative;
}

.wa-welcome {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    text-align: center;
    color: #8696a0;
    position: relative;
    z-index: 1;
}

.wa-welcome h2 {
    color: #e9edef;
    font-weight: 300;
    font-size: 32px;
    margin: 20px 0 10px;
}

.wa-welcome p {
    font-size: 14px;
}

.wa-welcome img {
    filter: grayscale(1) brightness(0.6);
}

/* Message Bubbles */
.wa-msg {
    display: flex;
    margin-bottom: 4px;
    position: relative;
    z-index: 10;
}

.wa-msg.out {
    justify-content: flex-end;
}

.wa-msg.in {
    justify-content: flex-start;
}

.wa-msg-bubble {
    max-width: 65%;
    padding: 6px 7px 8px 9px;
    border-radius: 7.5px;
    position: relative;
    box-shadow: 0 1px 0.5px rgba(0, 0, 0, 0.13);
    z-index: 10;
}

.wa-msg.out .wa-msg-bubble {
    background: #005c4b;
    border-top-right-radius: 0;
}

.wa-msg.in .wa-msg-bubble {
    background: #202c33;
    border-top-left-radius: 0;
}

.wa-msg-author {
    font-size: 12.5px;
    font-weight: 500;
    color: #06cf9c;
    margin-bottom: 2px;
}

.wa-msg-text {
    font-size: 14.2px;
    color: #e9edef;
    line-height: 19px;
    white-space: pre-wrap;
    word-wrap: break-word;
}

.wa-msg-meta {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 4px;
    margin-top: 2px;
    margin-left: 10px;
    float: right;
}

.wa-msg-time {
    font-size: 11px;
    color: rgba(255, 255, 255, 0.6);
}

.wa-msg-status {
    font-size: 14px;
    color: #53bdeb;
}

/* Input Area */
.wa-input-area {
    display: flex;
    align-items: center;
    padding: 10px 16px;
    background: #202c33;
    gap: 8px;
}

.wa-input-box {
    flex: 1;
    background: #2a3942;
    border-radius: 8px;
    padding: 9px 12px;
}

.wa-input-box input {
    width: 100%;
    border: none;
    background: transparent;
    color: #e9edef;
    font-size: 15px;
    outline: none;
}

.wa-input-box input::placeholder {
    color: #8696a0;
}

.wa-send-btn {
    color: #8696a0;
}

.wa-send-btn:hover {
    color: #00a884;
}

/* Empty State */
.wa-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    color: #8696a0;
    text-align: center;
    padding: 20px;
}

.wa-empty i {
    font-size: 48px;
    margin-bottom: 16px;
    opacity: 0.5;
}

/* Scrollbar WhatsApp Style */
.wa-chat-list::-webkit-scrollbar,
.wa-messages::-webkit-scrollbar {
    width: 6px;
}

.wa-chat-list::-webkit-scrollbar-thumb,
.wa-messages::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.2);
    border-radius: 3px;
}

:root {
    --primary-alpha: rgba(0, 168, 132, 0.15);
}