:root {
    --bg-primary: #0a0a0f;
    --bg-secondary: #12121a;
    --bg-message-user: #1a1a2e;
    --bg-message-agent: #0f3460;
    --text-primary: #e8e8e8;
    --text-secondary: #a0a0a0;
    --accent-whatsapp: #25d366;
    --accent-phone: #f97316;
    --accent-sms: #8b5cf6;
    --accent-email: #3b82f6;
    --accent-chatbot: #ec4899;
    --border-color: #2a2a3a;
    --nav-height: 53px;
    --input-height: 74px;
}

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

html, body {
    height: 100%;
    margin: 0;
    padding: 0;
    overflow: hidden;
}

body {
    font-family: 'DM Sans', -apple-system, BlinkMacSystemFont, sans-serif;
    background: var(--bg-primary);
    color: var(--text-primary);
    height: 100vh;
    transition: background 0.3s ease;
}

.app {
    height: 100vh;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.nav {
    display: flex;
    justify-content: space-between;
    align-items: stretch;
    background: var(--bg-secondary);
    box-shadow: 0 1px 0 var(--border-color);
    padding-right: 20px;
    flex-shrink: 0;
    height: var(--nav-height);
}

.nav-left {
    display: flex;
    align-items: stretch;
}

.nav-right {
    display: flex;
    align-items: center;
    gap: 15px;
}

.nav__button {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 24px;
    background: none;
    border: none;
    border-bottom: 3px solid transparent;
    color: var(--text-secondary);
    font-family: 'DM Sans', sans-serif;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    margin-bottom: -1px;
}

.nav__button:hover {
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.05);
}

.nav__button--active {
    color: var(--text-primary);
    background: rgba(59, 130, 246, 0.1);
    border-bottom-color: #3b82f6;
}

/* Authentication Styles */
.auth-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background: linear-gradient(135deg, #0a0a0f 0%, #1a1a2e 50%, #0f0f23 100%);
    display: flex;
    align-items: flex-start;
    justify-content: center;
    z-index: 1000;
    backdrop-filter: blur(10px);
    padding: 20px;
    overflow-y: auto;
    box-sizing: border-box;
}

.auth-container {
    background: rgba(26, 26, 38, 0.95);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    padding: 30px;
    width: 100%;
    max-width: 480px;
    max-height: calc(100vh - 40px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(20px);
    margin-top: 20px;
    margin-bottom: 20px;
    overflow-y: auto;
}

/* Responsive adjustments */
@media (max-height: 700px) {
    .auth-overlay {
        padding: 10px;
        align-items: flex-start;
    }

    .auth-container {
        padding: 20px;
        margin-top: 10px;
        margin-bottom: 10px;
        max-height: calc(100vh - 20px);
    }

    .auth-header {
        margin-bottom: 20px;
    }

    .auth-header h1 {
        font-size: 28px;
    }

    .form-group {
        margin-bottom: 15px;
    }

    .auth-form h2 {
        font-size: 20px;
        margin-bottom: 15px;
    }
}

@media (max-width: 480px) {
    .auth-overlay {
        padding: 10px;
    }

    .auth-container {
        padding: 20px;
        max-width: calc(100vw - 20px);
        margin: 10px;
        max-height: calc(100vh - 20px);
    }

    .logout-text {
        display: none;
    }

    .logout-btn {
        padding: 8px;
    }

    .auth-header h1 {
        font-size: 24px;
    }

    .auth-form h2 {
        font-size: 18px;
    }

    .form-group input,
    .form-group textarea {
        font-size: 16px; /* Prevents zoom on iOS */
    }

    .auth-btn {
        padding: 12px;
        margin-top: 15px;
    }

    .auth-switch {
        margin-top: 15px;
        padding-top: 15px;
    }

    .form-help {
        font-size: 11px;
        margin-top: 3px;
    }
}

.auth-header {
    text-align: center;
    margin-bottom: 30px;
}

.auth-header h1 {
    color: var(--text-primary);
    font-size: 32px;
    font-weight: 600;
    margin: 0 0 8px 0;
    background: linear-gradient(135deg, #3b82f6, #8b5cf6);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.auth-header p {
    color: var(--text-secondary);
    font-size: 16px;
    margin: 0;
}

.auth-form h2 {
    color: var(--text-primary);
    font-size: 24px;
    font-weight: 500;
    margin: 0 0 20px 0;
    text-align: center;
}

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

.form-group label {
    display: block;
    color: var(--text-primary);
    font-size: 14px;
    font-weight: 500;
    margin-bottom: 6px;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    background: rgba(0, 0, 0, 0.3);
    color: var(--text-primary);
    font-family: 'DM Sans', sans-serif;
    font-size: 14px;
    outline: none;
    transition: all 0.2s ease;
    box-sizing: border-box;
}

.form-group input:focus,
.form-group textarea:focus {
    border-color: #3b82f6;
    background: rgba(0, 0, 0, 0.5);
}

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

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

/* Make textareas more compact on small screens */
@media (max-height: 700px) {
    .form-group textarea {
        min-height: 50px;
    }
}

.form-help {
    display: block;
    color: var(--text-secondary);
    font-size: 12px;
    margin-top: 4px;
}

/* Custom toggle switch styles */
.checkbox-label {
    display: flex;
    align-items: center;
    justify-content: space-between;
    cursor: pointer;
    user-select: none;
    font-size: 14px;
    font-weight: 500;
    color: var(--text-primary);
    margin-bottom: 0;
    padding: 12px 0;
    min-height: 24px;
    -webkit-tap-highlight-color: transparent;
}

.checkbox-label input[type="checkbox"] {
    position: absolute;
    opacity: 0;
    cursor: pointer;
}

.switch {
    position: relative;
    display: inline-block;
    width: 44px;
    height: 24px;
    background-color: rgba(255, 255, 255, 0.2);
    border-radius: 24px;
    transition: all 0.3s ease;
    flex-shrink: 0;
}

.switch:before {
    content: "";
    position: absolute;
    height: 18px;
    width: 18px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    border-radius: 50%;
    transition: all 0.3s ease;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.checkbox-label input[type="checkbox"]:checked ~ .switch {
    background-color: #3b82f6;
    box-shadow: 0 0 10px rgba(59, 130, 246, 0.3);
}

.checkbox-label input[type="checkbox"]:checked ~ .switch:before {
    transform: translateX(20px);
    background-color: white;
}

.auth-btn {
    width: 100%;
    padding: 14px;
    border: none;
    border-radius: 8px;
    background: linear-gradient(135deg, #3b82f6, #1d4ed8);
    color: white;
    font-family: 'DM Sans', sans-serif;
    font-size: 16px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    margin-top: 10px;
    position: relative;
    overflow: hidden;
}

.auth-btn:hover {
    background: linear-gradient(135deg, #2563eb, #1e40af);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
}

.auth-btn:active {
    transform: translateY(0);
}

.auth-btn:disabled {
    opacity: 0.7;
    cursor: not-allowed;
    transform: none;
}

.btn-loading {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.btn-loading::after {
    content: '';
    width: 16px;
    height: 16px;
    border: 2px solid transparent;
    border-top: 2px solid currentColor;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.auth-switch {
    text-align: center;
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.auth-switch p {
    color: var(--text-secondary);
    font-size: 14px;
    margin: 0;
}

.auth-switch a {
    color: #3b82f6;
    text-decoration: none;
    font-weight: 500;
}

.auth-switch a:hover {
    text-decoration: underline;
}

.auth-error {
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.3);
    border-radius: 8px;
    padding: 12px 16px;
    margin-top: 20px;
    color: #ef4444;
    font-size: 14px;
    text-align: center;
}

/* Company Info in Navigation */
.company-info {
    display: flex;
    align-items: center;
    gap: 12px;
    color: var(--text-secondary);
    font-size: 14px;
}

.company-name {
    color: var(--text-primary);
    font-weight: 500;
}

.company-balance {
    background: rgba(34, 197, 94, 0.1);
    color: #22c55e;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 500;
}

.logout-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.3);
    border-radius: 6px;
    color: #ef4444;
    cursor: pointer;
    padding: 8px 12px;
    transition: all 0.2s ease;
    font-size: 13px;
    font-weight: 500;
    font-family: 'DM Sans', sans-serif;
}

.logout-btn:hover {
    background: rgba(239, 68, 68, 0.2);
    border-color: #ef4444;
    color: #ef4444;
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(239, 68, 68, 0.2);
}

.logout-btn:active {
    transform: translateY(0);
}

.logout-btn svg {
    flex-shrink: 0;
}

.logout-text {
    font-size: 13px;
    font-weight: 500;
}

/* Config Interface Styles */
.config-container {
    flex: 1;
    max-width: 800px;
    width: 100%;
    margin: 0 auto;
    padding: 20px;
    height: calc(100vh - var(--nav-height));
    overflow-y: auto;
    box-sizing: border-box;
}

.config-header {
    text-align: center;
    margin-bottom: 30px;
    padding-top: 0;
}

.config-header h2 {
    color: var(--text-primary);
    font-size: 28px;
    font-weight: 600;
    margin: 0 0 8px 0;
}

.config-header p {
    color: var(--text-secondary);
    font-size: 16px;
    margin: 0;
}

.config-form {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 20px 30px 30px 30px;
    min-height: 100%;
    box-sizing: border-box;
}

.config-section {
    margin-bottom: 25px;
}

.config-section:last-child {
    margin-bottom: 0;
}

.config-section h3 {
    color: var(--text-primary);
    font-size: 18px;
    font-weight: 600;
    margin: 0 0 15px 0;
    padding-bottom: 8px;
    border-bottom: 1px solid var(--border-color);
}

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

@media (max-width: 768px) {
    .form-row {
        grid-template-columns: 1fr;
        gap: 15px;
    }

    .config-container {
        padding: 15px;
        height: calc(100vh - var(--nav-height));
        overflow-y: auto;
    }

    .config-form {
        padding: 15px 20px 20px 20px;
    }

    .config-header h2 {
        font-size: 24px;
    }

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

.config-actions {
    display: flex;
    gap: 12px;
    justify-content: flex-end;
    padding-top: 20px;
    border-top: 1px solid var(--border-color);
}

.btn-primary,
.btn-secondary {
    padding: 12px 24px;
    border: none;
    border-radius: 8px;
    font-family: 'DM Sans', sans-serif;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-width: 120px;
}

.btn-primary {
    background: linear-gradient(135deg, #3b82f6, #1d4ed8);
    color: white;
}

.btn-primary:hover {
    background: linear-gradient(135deg, #2563eb, #1e40af);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
}

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

.btn-secondary:hover {
    background: var(--bg-secondary);
    border-color: var(--text-secondary);
    color: var(--text-primary);
}

.btn-primary:disabled,
.btn-secondary:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

.chat-container {
    flex: 1;
    max-width: 900px;
    width: 100%;
    margin: 0 auto;
    padding: 0;
    display: flex;
    flex-direction: column;
    height: calc(100vh - var(--nav-height));
    overflow: hidden;
    transition: background 0.3s ease;
}

.messages {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 16px;
    padding: 20px 10px;
    padding-bottom: calc(var(--input-height) + 20px);
    overflow-y: auto;
    overflow-x: hidden;
    min-height: 0;
}

/* When in manual simulation mode, let child handle scrolling */
.messages:has(.manual-header) {
    padding: 0;
    gap: 0;
    overflow: visible;
    min-height: 0;
    padding-bottom: 0;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.message {
    max-width: 75%;
    padding: 14px 18px;
    border-radius: 16px;
    position: relative;
    animation: slideIn 0.3s ease-out;
    flex-shrink: 0;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.message--user {
    align-self: flex-end;
    background: var(--bg-message-user);
    border-bottom-right-radius: 4px;
}

.message--agent {
    align-self: flex-start;
    background: var(--bg-message-agent);
    border-bottom-left-radius: 4px;
}

.message--system {
    align-self: center;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
    font-style: italic;
    max-width: 80%;
    text-align: center;
}

.message__header {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 8px;
    font-size: 12px;
}

.message__channel {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 3px 8px;
    border-radius: 4px;
    font-weight: 500;
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.message__channel--whatsapp {
    background: rgba(37, 211, 102, 0.15);
    color: var(--accent-whatsapp);
}

.message__channel--phone {
    background: rgba(249, 115, 22, 0.15);
    color: var(--accent-phone);
}

.message__channel--sms {
    background: rgba(139, 92, 246, 0.15);
    color: var(--accent-sms);
}

.message__channel--email {
    background: rgba(59, 130, 246, 0.15);
    color: var(--accent-email);
}

.message__channel--chatbot {
    background: rgba(236, 72, 153, 0.15);
    color: var(--accent-chatbot);
}

.message__time {
    color: var(--text-secondary);
    font-size: 11px;
}

.message__content {
    line-height: 1.5;
    white-space: pre-wrap;
    word-wrap: break-word;
}

.message__icon {
    width: 14px;
    height: 14px;
}

.message__audio-indicator {
    margin-left: 4px;
    opacity: 0.7;
    font-size: 12px;
}

.message__audio-indicator:hover {
    opacity: 1;
}

/* Manual Simulation Styles */
.manual-header {
    text-align: center;
    padding: 15px 20px;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 0;
    flex-shrink: 0;
    flex-grow: 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.manual-header h3 {
    margin: 0 0 10px 0;
    color: var(--text-primary);
    font-size: 18px;
    font-weight: 600;
}

/* Messages Layout with Sidebar */
.messages-layout {
    display: flex;
    height: 100%;
}

.users-sidebar {
    width: 240px;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(10px);
    border-right: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    flex-direction: column;
}

.sidebar-header {
    padding: 15px 12px 8px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.sidebar-header h4 {
    margin: 0;
    color: white;
    font-size: 13px;
    font-weight: 600;
}

.user-list {
    flex: 1;
    overflow-y: auto;
    padding: 6px 0;
}

.user-item {
    position: relative;
    display: flex;
    align-items: center;
    border-left: 3px solid transparent;
    transition: all 0.2s ease;
}

.user-item:hover {
    border-left-color: rgba(100, 200, 255, 0.6);
}

.user-item.active {
    background: rgba(100, 200, 255, 0.15);
    border-left-color: rgba(100, 200, 255, 1);
}

.user-item.active .user-btn {
    color: rgba(100, 200, 255, 1);
    font-weight: 600;
}

.user-list .user-btn {
    flex: 1;
    display: flex;
    align-items: center;
    padding: 8px 36px 8px 12px;
    border: none;
    border-radius: 0;
    background: transparent;
    color: rgba(255, 255, 255, 0.8);
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 12px;
    font-weight: 500;
    text-align: left;
    position: relative;
}

.user-list .user-btn:hover {
    color: rgba(100, 200, 255, 0.9);
}

.user-content {
    display: flex;
    align-items: center;
    flex: 1;
    min-width: 0;
}

.user-icon {
    margin-right: 8px;
    font-size: 14px;
    flex-shrink: 0;
}

.user-name {
    flex: 1;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.user-info-btn {
    position: absolute;
    right: 8px;
    top: 50%;
    transform: translateY(-50%);
    width: 20px;
    height: 20px;
    padding: 0;
    border: none;
    border-radius: 50%;
    background: transparent;
    color: rgba(255, 255, 255, 0.5);
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.user-info-btn:hover {
    background: rgba(100, 200, 255, 0.15);
    color: rgba(100, 200, 255, 0.9);
}

.user-info-btn svg {
    transition: transform 0.2s ease;
}

.user-info-btn:hover svg {
    transform: scale(1.1);
}

.messages-main {
    flex: 1;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.channel-selector {
    display: flex;
    gap: 10px;
    justify-content: center;
    flex-wrap: wrap;
}

.channel-btn {
    padding: 8px 16px;
    border: 2px solid rgba(255, 255, 255, 0.8);
    border-radius: 20px;
    background: rgba(0, 0, 0, 0.7);
    color: white;
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 12px;
    font-weight: 500;
    backdrop-filter: blur(10px);
}

.channel-btn:hover {
    background: rgba(0, 0, 0, 0.8);
    border-color: rgba(255, 255, 255, 1);
    transform: translateY(-1px);
}

.channel-btn.active {
    background: rgba(255, 255, 255, 0.9);
    color: var(--bg-primary);
    border-color: white;
    font-weight: 600;
}

.manual-messages {
    flex: 1 1 0;
    display: flex;
    flex-direction: column;
    gap: 16px;
    overflow-y: auto;
    overflow-x: hidden;
    min-height: 0;
    max-height: 100%;
    padding: 15px 10px;
    padding-bottom: calc(var(--input-height) + 40px);
}

/* In live view (Messages page), add comfortable bottom padding */
#liveMessages .manual-messages {
    padding-bottom: 70px;
}

/* Compact live input container */
.live-input-container {
    height: 50px !important;
    padding: 10px 10px !important;
}

.live-input-container .live-indicator-message {
    display: flex;
    align-items: center;
    gap: 8px;
    color: rgba(255, 255, 255, 0.8);
    font-size: 13px;
    font-weight: 400;
    flex: 1;
}

.live-input-container .live-dot {
    display: inline-block;
    width: 8px;
    height: 8px;
    background: #10b981;
    border-radius: 50%;
    animation: pulse 2s infinite;
}

.live-input-container .download-prompt-btn {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 6px;
    padding: 6px 8px;
    color: rgba(255, 255, 255, 0.8);
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
}

.live-input-container .download-prompt-btn:hover {
    background: rgba(255, 255, 255, 0.15);
    border-color: rgba(255, 255, 255, 0.3);
    transform: translateY(-1px);
}

/* Chat Input Styles */
.chat-input-container {
    position: fixed;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    max-width: 900px;
    width: 100%;
    padding: 15px 20px;
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(10px);
    border-radius: 0;
    z-index: 10;
    height: var(--input-height);
    display: flex;
    align-items: center;
    gap: 12px;
}

.chat-input-wrapper {
    display: flex;
    gap: 12px;
    align-items: center;
    flex: 1;
    width: 100%;
}

.chat-input {
    flex: 1;
    padding: 12px 16px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 25px;
    background: rgba(0, 0, 0, 0.7);
    color: white;
    font-family: 'DM Sans', sans-serif;
    font-size: 14px;
    outline: none;
    transition: all 0.2s ease;
    backdrop-filter: blur(10px);
}

.chat-input:focus {
    border-color: rgba(255, 255, 255, 0.8);
    background: rgba(0, 0, 0, 0.8);
}

.chat-input::placeholder {
    color: rgba(255, 255, 255, 0.6);
}

.send-btn {
    width: 44px;
    height: 44px;
    border: none;
    border-radius: 50%;
    background: #25d366;
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    font-size: 16px;
    font-weight: bold;
    flex-shrink: 0;
}

.send-btn:hover {
    background: #128c7e;
    transform: scale(1.05);
}

.send-btn:active {
    transform: scale(0.95);
}

/* Download Prompt Button */
.download-prompt-btn {
    width: 44px;
    height: 44px;
    border: 2px solid rgba(255, 255, 255, 0.4);
    border-radius: 50%;
    background: rgba(59, 130, 246, 0.3);
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    flex-shrink: 0;
}

.download-prompt-btn:hover {
    background: rgba(59, 130, 246, 0.6);
    border-color: rgba(255, 255, 255, 0.8);
    transform: scale(1.05);
}

.download-prompt-btn:active {
    transform: scale(0.95);
}

.download-prompt-btn svg {
    width: 20px;
    height: 20px;
}

/* Audio Button */
.audio-btn {
    width: 44px;
    height: 44px;
    border: 2px solid rgba(255, 255, 255, 0.4);
    border-radius: 50%;
    background: rgba(239, 68, 68, 0.3);
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    flex-shrink: 0;
}

.audio-btn:hover {
    background: rgba(239, 68, 68, 0.6);
    border-color: rgba(255, 255, 255, 0.8);
    transform: scale(1.05);
}

.audio-btn:active {
    transform: scale(0.95);
}

.audio-btn.recording {
    background: rgba(239, 68, 68, 0.9);
    border-color: #ef4444;
    animation: pulse 1s infinite;
}

@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.1); }
}

.audio-btn svg {
    width: 20px;
    height: 20px;
}

.no-input-message {
    text-align: center;
    color: rgba(255, 255, 255, 0.7);
    font-size: 14px;
    font-style: italic;
    padding: 12px;
}

/* Scrollbar styling */
.messages::-webkit-scrollbar,
.manual-messages::-webkit-scrollbar {
    width: 8px;
}

.messages::-webkit-scrollbar-track,
.manual-messages::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.2);
    border-radius: 4px;
}

.messages::-webkit-scrollbar-thumb,
.manual-messages::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.2);
    border-radius: 4px;
}

.messages::-webkit-scrollbar-thumb:hover,
.manual-messages::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.3);
}

/* Live mode styles */
.no-messages {
    text-align: center;
    color: var(--text-secondary);
    padding: 40px 20px;
    font-style: italic;
    opacity: 0.7;
}

.live-indicator-message {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    color: var(--text-secondary);
    font-size: 14px;
    padding: 12px 20px;
}

.live-dot {
    width: 10px;
    height: 10px;
    background-color: #ef4444;
    border-radius: 50%;
    animation: pulse-live 1.5s ease-in-out infinite;
}

@keyframes pulse-live {
    0%, 100% {
        opacity: 1;
        transform: scale(1);
    }
    50% {
        opacity: 0.5;
        transform: scale(1.2);
    }
}

#liveIndicator {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 100;
}

/* Config Emails Display */
.config-emails-display {
    background: var(--bg-primary);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 12px;
    min-height: 44px;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
}

.config-emails-display .no-emails {
    color: var(--text-secondary);
    font-size: 13px;
    font-style: italic;
}

.config-email-tag {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: rgba(59, 130, 246, 0.15);
    border: 1px solid rgba(59, 130, 246, 0.3);
    color: var(--text-primary);
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 13px;
}

.config-email-tag svg {
    width: 14px;
    height: 14px;
    fill: #ea4335;
}

/* Gmail Integration Styles */
.config-section-desc {
    color: var(--text-secondary);
    font-size: 14px;
    margin-bottom: 16px;
    line-height: 1.5;
}

.gmail-accounts-container {
    background: var(--bg-primary);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    margin-bottom: 16px;
    min-height: 60px;
}

.gmail-accounts-loading {
    color: var(--text-secondary);
    font-size: 14px;
    padding: 20px;
    text-align: center;
}

.gmail-accounts-list {
    padding: 0;
}

.gmail-account-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 16px;
    border-bottom: 1px solid var(--border-color);
}

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

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

.gmail-account-avatar {
    width: 36px;
    height: 36px;
    background: linear-gradient(135deg, #ea4335 0%, #fbbc04 50%, #34a853 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 600;
    font-size: 14px;
}

.gmail-account-details {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.gmail-account-email {
    color: var(--text-primary);
    font-size: 14px;
    font-weight: 500;
}

.gmail-account-status {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    color: var(--text-secondary);
}

.gmail-status-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #ef4444;
}

.gmail-status-dot.active {
    background: #22c55e;
}

.gmail-account-actions {
    display: flex;
    align-items: center;
    gap: 8px;
}

.btn-gmail-action {
    padding: 6px 12px;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    background: transparent;
    color: var(--text-secondary);
    font-size: 12px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-gmail-action:hover {
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-primary);
}

.btn-gmail-action.danger {
    color: #ef4444;
    border-color: rgba(239, 68, 68, 0.3);
}

.btn-gmail-action.danger:hover {
    background: rgba(239, 68, 68, 0.1);
    border-color: rgba(239, 68, 68, 0.5);
}

.btn-gmail-connect {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 100%;
    padding: 14px 20px;
    background: linear-gradient(135deg, #ea4335 0%, #4285f4 100%);
    border: none;
    border-radius: 8px;
    color: white;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-gmail-connect:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(66, 133, 244, 0.3);
}

.btn-gmail-connect:active {
    transform: translateY(0);
}

.gmail-icon {
    width: 20px;
    height: 20px;
}

.gmail-empty-state {
    padding: 30px 20px;
    text-align: center;
    color: var(--text-secondary);
}

.gmail-empty-state svg {
    width: 48px;
    height: 48px;
    margin-bottom: 12px;
    opacity: 0.5;
}

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

/* ============================================
   CALENDAR STYLES
   ============================================ */

.calendar-container {
    height: calc(100vh - var(--nav-height));
    display: flex;
    flex-direction: column;
    padding: 20px;
    overflow-y: auto;
    background: var(--bg-primary);
}

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

.calendar-nav {
    display: flex;
    align-items: center;
    gap: 16px;
}

.calendar-nav-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    color: var(--text-primary);
    cursor: pointer;
    transition: all 0.2s ease;
}

.calendar-nav-btn:hover {
    background: var(--bg-message-user);
    border-color: var(--accent-email);
}

.calendar-title {
    font-size: 24px;
    font-weight: 600;
    color: var(--text-primary);
    min-width: 200px;
    text-align: center;
}

.calendar-actions {
    display: flex;
    gap: 12px;
}

.calendar-today-btn {
    padding: 8px 16px;
    background: transparent;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    color: var(--text-primary);
    font-size: 14px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.calendar-today-btn:hover {
    background: var(--bg-secondary);
    border-color: var(--accent-email);
}

.calendar-sync-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    background: var(--accent-email);
    border: none;
    border-radius: 6px;
    color: white;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.calendar-sync-btn:hover {
    filter: brightness(1.1);
}

.calendar-sync-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.calendar-sync-btn.syncing svg {
    animation: spin 1s linear infinite;
}

@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

/* Calendar Connection Status */
.calendar-connection-status {
    margin-bottom: 24px;
}

.calendar-not-connected {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 60px 40px;
    background: var(--bg-secondary);
    border: 2px dashed var(--border-color);
    border-radius: 16px;
    text-align: center;
}

.calendar-not-connected svg {
    color: var(--text-secondary);
    margin-bottom: 16px;
    opacity: 0.6;
}

.calendar-not-connected h3 {
    font-size: 20px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 8px;
}

.calendar-not-connected p {
    font-size: 14px;
    color: var(--text-secondary);
    margin-bottom: 24px;
}

.btn-calendar-connect {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 14px 28px;
    background: linear-gradient(135deg, #4285f4 0%, #34a853 50%, #fbbc05 75%, #ea4335 100%);
    border: none;
    border-radius: 8px;
    color: white;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-calendar-connect:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(66, 133, 244, 0.4);
}

.btn-calendar-connect svg {
    width: 20px;
    height: 20px;
}

.calendar-connected-info {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 16px;
    background: rgba(52, 168, 83, 0.1);
    border: 1px solid rgba(52, 168, 83, 0.3);
    border-radius: 8px;
}

.calendar-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 80px 40px;
    background: var(--bg-secondary);
    border-radius: 12px;
    text-align: center;
}

.calendar-loading .spinner {
    width: 50px;
    height: 50px;
    border: 4px solid var(--border-color);
    border-top-color: #4285f4;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 20px;
}

.calendar-loading p {
    font-size: 15px;
    color: var(--text-secondary);
    font-weight: 500;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.connected-account {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    color: #34a853;
}

.connected-account::before {
    content: '';
    width: 8px;
    height: 8px;
    background: #34a853;
    border-radius: 50%;
}

.btn-disconnect-calendar {
    padding: 6px 12px;
    background: transparent;
    border: 1px solid rgba(239, 68, 68, 0.5);
    border-radius: 4px;
    color: #ef4444;
    font-size: 12px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-disconnect-calendar:hover {
    background: rgba(239, 68, 68, 0.1);
}

/* Calendar Grid */
.calendar-main-wrapper {
    display: flex;
    gap: 20px;
    flex: 1;
    overflow: hidden;
}

.calendar-grid-container {
    flex: 1;
    display: flex;
    flex-direction: column;
    background: var(--bg-secondary);
    border-radius: 12px;
    overflow: hidden;
    min-width: 0;
}

.calendar-weekdays {
    width: 100%;
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    background: var(--bg-message-user);
    border-bottom: 1px solid var(--border-color);
}

.weekday {
    padding: 12px;
    text-align: center;
    font-size: 12px;
    font-weight: 600;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.calendar-grid {
    width: 100%;
    height: 500px;
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    grid-template-rows: repeat(6, 1fr);
    gap: 1px;
    background: var(--border-color);
}

.calendar-day {
    background: var(--bg-secondary);
    padding: 8px;
    cursor: pointer;
    transition: background 0.2s ease;
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.calendar-day:hover {
    background: var(--bg-message-user);
}

.calendar-day.other-month {
    opacity: 0.4;
}

.calendar-day.today {
    background: rgba(59, 130, 246, 0.1);
}

.calendar-day.today .day-number {
    background: var(--accent-email);
    color: white;
    border-radius: 50%;
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.calendar-day.selected {
    background: rgba(59, 130, 246, 0.15);
    outline: 2px solid var(--accent-email);
    outline-offset: -2px;
}

.day-number {
    font-size: 14px;
    font-weight: 500;
    color: var(--text-primary);
    margin-bottom: 4px;
    flex-shrink: 0;
}

.day-events {
    display: flex;
    flex-direction: column;
    gap: 2px;
    flex: 1;
    min-height: 0;
    overflow: hidden;
}

.day-event {
    font-size: 11px;
    padding: 2px 6px;
    border-radius: 4px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    color: white;
}

.day-event.all-day {
    background: var(--accent-email);
}

.day-event.timed {
    background: var(--accent-whatsapp);
}

.day-event-more {
    font-size: 11px;
    color: var(--text-secondary);
    padding: 2px 6px;
}

/* Events Panel */
.calendar-events-panel {
    width: 350px;
    min-width: 350px;
    background: var(--bg-secondary);
    border-radius: 12px;
    padding: 0;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    max-height: calc(100vh - var(--nav-height) - 200px);
}

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

.events-panel-close {
    background: none;
    border: none;
    font-size: 28px;
    line-height: 1;
    color: var(--text-secondary);
    cursor: pointer;
    padding: 0;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
    transition: all 0.2s ease;
}

.events-panel-close:hover {
    background: var(--bg-hover);
    color: var(--text-primary);
}

.events-panel-title {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--border-color);
}

.events-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
    padding: 16px;
    overflow-y: auto;
    flex: 1;
}

.event-item {
    display: flex;
    gap: 12px;
    padding: 12px;
    background: var(--bg-primary);
    border-radius: 8px;
    border-left: 4px solid var(--accent-email);
}

.event-time {
    min-width: 70px;
    font-size: 13px;
    font-weight: 500;
    color: var(--accent-email);
}

.event-details {
    flex: 1;
}

.event-title {
    font-size: 14px;
    font-weight: 500;
    color: var(--text-primary);
    margin-bottom: 4px;
}

.event-location {
    font-size: 12px;
    color: var(--text-secondary);
    display: flex;
    align-items: center;
    gap: 4px;
}

.event-location svg {
    width: 12px;
    height: 12px;
}

.no-events {
    text-align: center;
    padding: 20px;
    color: var(--text-secondary);
    font-size: 14px;
}

/* WhatsApp Phone Numbers List */
.whatsapp-phones-list {
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 12px;
    background: var(--bg-secondary);
    min-height: 60px;
    max-height: 400px;
    overflow-y: auto;
}

.no-phones-message {
    text-align: center;
    color: var(--text-secondary);
    font-size: 14px;
    margin: 20px 0;
}

.whatsapp-phone-item {
    background: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    border-radius: 6px;
    padding: 12px;
    margin-bottom: 10px;
    display: flex;
    gap: 12px;
    align-items: flex-start;
    transition: all 0.2s ease;
}

.whatsapp-phone-item:hover {
    border-color: #25d366;
}

.whatsapp-phone-item:last-child {
    margin-bottom: 0;
}

.whatsapp-phone-icon {
    flex-shrink: 0;
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, #25d366 0%, #4caf50 100%);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 20px;
}

.whatsapp-phone-info {
    flex: 1;
    min-width: 0;
}

.whatsapp-phone-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 6px;
}

.whatsapp-phone-name {
    font-weight: 600;
    color: var(--text-primary);
    font-size: 14px;
}

.whatsapp-phone-status {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 500;
}

.whatsapp-phone-status.active {
    background: rgba(34, 197, 94, 0.2);
    color: #22c55e;
}

.whatsapp-phone-status.inactive {
    background: rgba(156, 163, 175, 0.2);
    color: #9ca3af;
}

.whatsapp-phone-number {
    color: var(--text-secondary);
    font-size: 13px;
    margin-bottom: 4px;
    font-family: 'Courier New', monospace;
}

.whatsapp-phone-id {
    color: var(--text-secondary);
    font-size: 11px;
    font-family: 'Courier New', monospace;
}

.whatsapp-phone-actions {
    flex-shrink: 0;
    display: flex;
    gap: 6px;
}

.btn-phone-action {
    background: none;
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
    cursor: pointer;
    padding: 6px 8px;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}

.btn-phone-action:hover {
    background: var(--bg-secondary);
    border-color: var(--text-secondary);
    color: var(--text-primary);
}

.btn-phone-action.edit:hover {
    background: rgba(59, 130, 246, 0.1);
    border-color: #3b82f6;
    color: #3b82f6;
}

.btn-phone-action.delete:hover {
    background: rgba(239, 68, 68, 0.1);
    border-color: #ef4444;
    color: #ef4444;
}

.btn-add-phone {
    background: linear-gradient(135deg, #25d366 0%, #4caf50 100%);
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: all 0.2s ease;
}

.btn-add-phone:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(37, 211, 102, 0.3);
}

.btn-add-phone svg {
    width: 16px;
    height: 16px;
}

/* WhatsApp Phone Form Modal */
.whatsapp-phone-form {
    background: var(--bg-tertiary);
    border: 2px solid #25d366;
    border-radius: 8px;
    padding: 16px;
    margin-top: 12px;
    animation: slideDown 0.3s ease;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.whatsapp-phone-form h4 {
    color: var(--text-primary);
    font-size: 15px;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.whatsapp-phone-form .form-group {
    margin-bottom: 12px;
}

.whatsapp-phone-form .form-group:last-of-type {
    margin-bottom: 16px;
}

.whatsapp-phone-form label {
    display: block;
    font-size: 13px;
    font-weight: 500;
    color: var(--text-secondary);
    margin-bottom: 4px;
}

.whatsapp-phone-form input {
    width: 100%;
    padding: 8px 12px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 4px;
    color: var(--text-primary);
    font-size: 13px;
    transition: all 0.2s ease;
}

.whatsapp-phone-form input:focus {
    outline: none;
    border-color: #25d366;
    background: var(--bg-primary);
}

/* WhatsApp Active Toggle Switch */
.whatsapp-active-group {
    margin-top: 4px;
    margin-bottom: 16px;
}

.whatsapp-active-label {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    cursor: pointer;
    user-select: none;
    -webkit-tap-highlight-color: transparent;
}

.whatsapp-active-checkbox {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

.whatsapp-active-switch {
    position: relative;
    display: inline-block;
    width: 44px;
    height: 24px;
    background: #4a4a4a;
    border-radius: 12px;
    transition: all 0.3s ease;
    flex-shrink: 0;
}

.whatsapp-active-switch::after {
    content: '';
    position: absolute;
    top: 3px;
    left: 3px;
    width: 18px;
    height: 18px;
    background: white;
    border-radius: 50%;
    transition: all 0.3s ease;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.whatsapp-active-checkbox:checked + .whatsapp-active-switch {
    background: #25d366;
}

.whatsapp-active-checkbox:checked + .whatsapp-active-switch::after {
    left: 23px;
}

.whatsapp-active-text {
    font-size: 14px;
    font-weight: 500;
    color: var(--text-primary);
    white-space: nowrap;
}

.whatsapp-phone-form-actions {
    display: flex;
    gap: 8px;
    justify-content: flex-end;
}

.whatsapp-phone-form-actions button {
    padding: 8px 16px;
    border-radius: 4px;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
}

.whatsapp-phone-form-actions .btn-save {
    background: #25d366;
    color: white;
    border: none;
}

.whatsapp-phone-form-actions .btn-save:hover {
    background: #22c55e;
}

.whatsapp-phone-form-actions .btn-cancel {
    background: none;
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
}

.whatsapp-phone-form-actions .btn-cancel:hover {
    background: var(--bg-secondary);
    color: var(--text-primary);
}

/* WhatsApp Verification Status */
.whatsapp-verification-status {
    margin-top: 6px;
    font-size: 12px;
    color: var(--text-secondary);
    display: flex;
    align-items: center;
    gap: 4px;
}

/* Verification Button */
.btn-phone-action.verify {
    background: #3b82f6;
}

.btn-phone-action.verify:hover {
    background: #2563eb;
}

/* Verification Modal */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    animation: fadeIn 0.2s ease;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.modal-content {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    max-width: 500px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
    animation: slideUp 0.3s ease;
}

@keyframes slideUp {
    from {
        transform: translateY(20px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

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

.modal-header h3 {
    margin: 0;
    font-size: 18px;
    color: var(--text-primary);
}

.modal-close {
    background: none;
    border: none;
    color: var(--text-secondary);
    font-size: 28px;
    cursor: pointer;
    padding: 0;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 4px;
    transition: all 0.2s;
}

.modal-close:hover {
    background: var(--bg-tertiary);
    color: var(--text-primary);
}

.modal-body {
    padding: 24px;
}

.verification-phone-info {
    background: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 16px;
    margin-bottom: 24px;
    text-align: center;
}

.verification-phone-info strong {
    display: block;
    font-size: 16px;
    color: var(--text-primary);
    margin-bottom: 8px;
}

.verification-phone-info div {
    font-size: 14px;
    color: var(--text-secondary);
    margin-bottom: 4px;
}

.verification-phone-info small {
    font-size: 12px;
    color: var(--text-secondary);
    opacity: 0.7;
}

.verification-step {
    margin-bottom: 20px;
}

.verification-step h4 {
    font-size: 15px;
    color: var(--text-primary);
    margin-bottom: 12px;
}

.verification-step p {
    font-size: 14px;
    color: var(--text-secondary);
    margin-bottom: 16px;
}

.verification-method-buttons {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.btn-verification-method {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding: 20px;
    background: var(--bg-tertiary);
    border: 2px solid var(--border-color);
    border-radius: 8px;
    color: var(--text-primary);
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-verification-method:hover {
    background: var(--bg-primary);
    border-color: #25d366;
}

.btn-verification-method svg {
    color: #25d366;
}

.verification-loading {
    text-align: center;
    padding: 40px 20px;
}

.spinner {
    width: 48px;
    height: 48px;
    border: 4px solid var(--border-color);
    border-top-color: #25d366;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 16px;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.verification-loading p {
    color: var(--text-secondary);
    font-size: 14px;
}

.verification-result {
    text-align: center;
    padding: 40px 20px;
}

.verification-result svg {
    margin: 0 auto 16px;
}

.verification-result h4 {
    font-size: 18px;
    margin-bottom: 12px;
}

.verification-result.success h4 {
    color: #10b981;
}

.verification-result.error h4 {
    color: #ef4444;
}

.verification-result p {
    color: var(--text-secondary);
    font-size: 14px;
    margin-bottom: 20px;
}

.verification-result button {
    margin: 0 8px;
}
