/* ============================================
   AI CHAT ASSISTANT PRO - MODERN ANIMATIONS
   Version: 3.0 - Premium Edition
   ============================================ */

/* ============================================
   CHAT CONTAINER & BUTTON
   ============================================ */
#aica-chat-container {
    position: fixed;
    bottom: 20px;
    z-index: 99999;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
}

#aica-chat-container.aica-position-right { right: 20px; }
#aica-chat-container.aica-position-left { left: 20px; }

/* Animated Chat Button */
#aica-chat-button {
    /* Larger bubble + resilient icon sizing (Elementor/themes often override img/button rules) */
    width: 72px;
    height: 72px;
    border-radius: 50%;
    border: none;
    cursor: pointer;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    padding: 0 !important;
    background-repeat: no-repeat !important;
    background-position: center !important;
    /* If the icon is rendered as a background-image, force its visible size */
    background-size: 66px 66px !important;
}

/* Pulse animation for attention */
#aica-chat-button::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    border-radius: 50%;
    background: inherit;
    animation: pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
    opacity: 0;
}

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

/* Hover effects */
#aica-chat-button:hover {
    transform: scale(1.1) translateY(-2px);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.25);
}

#aica-chat-button:active {
    transform: scale(0.95);
}

#aica-chat-button img {
    /* Bigger icon (some themes override img sizing) */
    width: 56px !important;
    height: 56px !important;
    object-fit: contain;
    max-width: none !important;
    max-height: none !important;
    transition: transform 0.3s ease;
    display: block;
}

/* Bigger default SVG icon too */
#aica-chat-button svg {
    width: 32px !important;
    height: 32px !important;
    display: block;
}

#aica-chat-button:hover img {
    transform: rotate(15deg) scale(1.1);
}

/* ============================================
   CHAT WINDOW - SLIDING ANIMATIONS
   ============================================ */
#aica-chat-window {
    position: fixed;
    bottom: 100px;
    width: 400px;
    max-width: calc(100vw - 40px);
    height: 600px;
    max-height: calc(100vh - 140px);
    background: #ffffff;
    border-radius: 20px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
    display: none;
    flex-direction: column;
    overflow: hidden;
    opacity: 0;
    transform: translateY(20px) scale(0.95);
    transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

#aica-chat-container.aica-position-right #aica-chat-window { right: 20px; }
#aica-chat-container.aica-position-left #aica-chat-window { left: 20px; }

#aica-chat-window.active {
    display: flex;
    opacity: 1;
    transform: translateY(0) scale(1);
}


/* ============================================
   HARD RESET INSIDE WIDGET (AVOID THEME OVERRIDES)
   ============================================ */
#aica-chat-window, 
#aica-chat-window * {
    box-sizing: border-box !important;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif !important;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

#aica-chat-window h1,
#aica-chat-window h2,
#aica-chat-window h3,
#aica-chat-window h4,
#aica-chat-window p {
    margin: 0 !important;
}

#aica-chat-window button {
    -webkit-appearance: none;
    appearance: none;
    border: none;
    background: none;
    padding: 0;
    margin: 0;
    font: inherit;
    line-height: 1;
}

#aica-chat-window svg {
    display: block !important;
}



/* Allow WordPress Dashicons inside widget (our hard reset overrides font-family) */
#aica-chat-window .dashicons,
#aica-chat-window .dashicons:before {
    font-family: dashicons !important;
    font-weight: normal !important;
    font-style: normal !important;
    speak: none !important;
    text-decoration: inherit !important;
    text-transform: none !important;
    -webkit-font-smoothing: antialiased !important;
    -moz-osx-font-smoothing: grayscale !important;
}

/* ============================================
   AICA OVERRIDE GUARD
   Prevent Elementor/theme typography from overriding widget
   ============================================ */
#aica-chat-window .aica-header-content h3 {
    font-size: 17px !important;
    font-weight: 600 !important;
    letter-spacing: -0.2px !important;
    line-height: 1.2 !important;
    color: #ffffff !important;
}

#aica-chat-window .aica-header-content p {
    font-size: 12px !important;
    opacity: 0.9 !important;
    line-height: 1.2 !important;
    color: #ffffff !important;
}

#aica-chat-window .aica-step-content h3 {
    font-size: 20px !important;
    font-weight: 700 !important;
    color: #1a1a1a !important;
    letter-spacing: -0.3px !important;
}

#aica-chat-window .aica-step-content p {
    font-size: 14px !important;
    color: #666 !important;
    line-height: 1.6 !important;
}

/* ============================================
   LARGE CHANNEL ICONS (WHATSAPP/EMAIL/CALL)
   ============================================ */
#aica-chat-window .aica-channel-icon-large{
    width: 72px;
    height: 72px;
    border-radius: 50%;
    background: #f3f4f6;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 6px auto 14px;
    color: var(--primary-color, #0084ff);
}

#aica-chat-window .aica-channel-icon-large svg{
    width: 34px;
    height: 34px;
    display: block;
}

/* WhatsApp gets its brand green */
#aica-chat-window #aica-step-whatsapp .aica-channel-icon-large{
    color: #25D366;
}

#aica-chat-window .aica-success-message{
    margin-top: 14px;
    padding: 12px 14px;
    border-radius: 12px;
    background: #f1f5f9;
    color: #111827;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}



#aica-chat-window .aica-form-group label {
    font-size: 13px !important;
    font-weight: 600 !important;
    color: #333 !important;
}

#aica-chat-window .aica-form-group input,
#aica-chat-window .aica-form-group textarea {
    font-size: 14px !important;
}

/* ============================================
   HEADER - GRADIENT & ANIMATIONS
   ============================================ */
.aica-chat-header {
    padding: 24px 20px;
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    position: relative;
    overflow: hidden;
    background: var(--header-background, linear-gradient(135deg, var(--primary-color, #0084ff) 0%, var(--primary-color-dark, #0066cc) 100%));
}

#aica-chat-window .aica-chat-header h3,
#aica-chat-window .aica-chat-header p {
    color: #ffffff !important;
}

/* Animated background gradient */
.aica-chat-header::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, transparent 70%);
    animation: headerGlow 8s linear infinite;
    pointer-events: none;
}

@keyframes headerGlow {
    0% { transform: translate(0, 0) rotate(0deg); }
    100% { transform: translate(50%, 50%) rotate(360deg); }
}

.aica-chat-header[data-aica-header-mode="flat"] {
    background: var(--header-flat-color, var(--primary-color, #f59e0b)) !important;
}

.aica-chat-header[data-aica-header-mode="flat"]::before {
    display: none !important;
}

.aica-chat-header[data-aica-header-mode="gradient"] {
    background: var(--header-background, linear-gradient(135deg, var(--primary-color, #0084ff) 0%, var(--primary-color-dark, #0066cc) 100%)) !important;
}

.aica-header-content {
    display: flex;
    align-items: center;
    gap: 12px;
    flex: 1;
    position: relative;
    z-index: 1;
}

/* Animated Avatar */
.aica-avatar {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    font-size: 20px;
    flex-shrink: 0;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    animation: none;
}

@keyframes avatarBounce {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-3px); }
}

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

.aica-header-content h3 {
    margin: 0;
    font-size: 17px;
    font-weight: 600;
    letter-spacing: -0.2px;
}

.aica-header-content p {
    margin: 2px 0 0;
    font-size: 12px;
    opacity: 0.9;
    display: flex;
    align-items: center;
    gap: 4px;
}

/* Online indicator pulse */
.aica-header-content p::before {
    content: '';
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #4caf50;
    animation: onlinePulse 2s ease-in-out infinite;
}

@keyframes onlinePulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.6; transform: scale(1.2); }
}

/* Close button with smooth transition */
.aica-close-button {
    background: rgba(255, 255, 255, 0.2);
    border: none;
    color: #ffffff;
    cursor: pointer;
    padding: 0 !important; /* avoid theme padding */
    border-radius: 999px !important;
    opacity: 0.9;
    transition: all 0.2s ease;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    z-index: 10;
    width: 36px !important;
    height: 36px !important;
    min-width: 36px !important;
    min-height: 36px !important;
}


.aica-back-hidden {
    visibility: hidden;
    opacity: 0;
    pointer-events: none;
}
.aica-close-button:hover {
    opacity: 1;
    background: rgba(255, 255, 255, 0.3);
    transform: rotate(90deg);
}

.aica-close-button svg {
    display: block;
    pointer-events: none;
}

/* ============================================
   CONTENT AREA - SMOOTH TRANSITIONS
   ============================================ */
#aica-content {
    flex: 1;
    overflow: hidden;
    position: relative;
    background: #ffffff;
}

.aica-channel-shortcuts {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 14px;
    padding: 8px 14px 6px;
    background: transparent;
    border-bottom: none;
    flex-wrap: wrap;
    position: relative;
    z-index: 2;
}

.aica-shortcuts-hidden {
    display: none !important;
}

.aica-shortcut-button {
    width: 28px;
    height: 28px;
    border: none;
    background: transparent !important;
    box-shadow: none !important;
    color: var(--channel-chat-color, #c83d76);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: transform 0.2s ease, opacity 0.2s ease, color 0.2s ease;
    padding: 0;
    border-radius: 0;
    opacity: 0.9;
    appearance: none;
    -webkit-appearance: none;
    outline: none !important;
}


.aica-shortcut-button:focus,
.aica-shortcut-button:focus-visible,
.aica-shortcut-button:active {
    outline: none !important;
    background: transparent !important;
    box-shadow: none !important;
}

.aica-shortcut-button svg {
    width: 18px;
    height: 18px;
    pointer-events: none;
}
.aica-shortcut-button--chat{color:var(--channel-chat-color,#ec4899)!important;}
.aica-shortcut-button--whatsapp{color:var(--channel-whatsapp-color,#22c55e)!important;}
.aica-shortcut-button--email{color:var(--channel-email-color,#f97316)!important;}
.aica-shortcut-button--call{color:var(--channel-call-color,#8b5cf6)!important;}

.aica-shortcut-button:hover {
    transform: translateY(-1px) scale(1.08);
    opacity: 1;
    border: none;
    background: transparent !important;
    box-shadow: none !important;
    filter: saturate(1.15);
}

.aica-shortcut-button.active {
    background: transparent !important;
    border: none;
    box-shadow: none !important;
    opacity: 1;
    filter: saturate(1.15);
}

#aica-step-channels .aica-step-content {
    display: none !important;
}

.aica-step {
    display: none;
    height: 100%;
    opacity: 0;
    transform: translateX(20px);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.aica-step.active {
    display: flex;
    flex-direction: column;
    opacity: 1;
    transform: translateX(0);
}

/* Specific fix for chat step */
#aica-step-chat {
    display: none;
}

#aica-step-chat.active {
    display: flex;
    flex-direction: column;
    height: 100%;
}

.aica-step-content {
    padding: 28px 24px;
    overflow-y: auto;
    flex: 1;
}

.aica-step-content::-webkit-scrollbar {
    width: 6px;
}

.aica-step-content::-webkit-scrollbar-track {
    background: transparent;
}

.aica-step-content::-webkit-scrollbar-thumb {
    background: #ddd;
    border-radius: 10px;
}

.aica-step-content::-webkit-scrollbar-thumb:hover {
    background: #bbb;
}

.aica-step-content h3 {
    margin: 0 0 8px;
    font-size: 20px;
    font-weight: 700;
    color: #1a1a1a;
    letter-spacing: -0.3px;
}

.aica-step-content p {
    margin: 0 0 24px;
    color: #666;
    font-size: 14px;
    line-height: 1.6;
}

/* ============================================
   FORM ELEMENTS - MODERN INPUTS
   ============================================ */
.aica-form-group {
    margin-bottom: 20px;
}

.aica-form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    font-size: 13px;
    color: #333;
    letter-spacing: 0.2px;
}

.aica-form-group input,
.aica-form-group textarea {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid #e8e8e8;
    border-radius: 12px;
    font-size: 14px;
    font-family: inherit;
    transition: all 0.3s ease;
    background: #fafafa;
}

.aica-form-group input:focus,
.aica-form-group textarea:focus {
    outline: none;
    border-color: var(--primary-color, #0084ff);
    background: #ffffff;
    box-shadow: 0 0 0 4px rgba(0, 132, 255, 0.1);
    transform: translateY(-1px);
}

.aica-form-group input::placeholder,
.aica-form-group textarea::placeholder {
    color: #999;
}

/* Animated Submit Button */
.aica-submit-button {
    width: 100%;
    padding: 14px 24px;
    border: none;
    border-radius: 12px;
    font-size: 15px;
    font-weight: 700;
    color: #ffffff;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    letter-spacing: 0.3px;
    box-shadow: 0 4px 12px rgba(0, 132, 255, 0.3);
}

.aica-submit-button::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.aica-submit-button:hover::before {
    width: 300px;
    height: 300px;
}

.aica-submit-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 132, 255, 0.4);
}

.aica-submit-button:active {
    transform: translateY(0);
}

/* ============================================
   CHANNEL SELECTION - CARD ANIMATIONS
   ============================================ */
#aica-channels-list {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 14px;
    margin-top: 24px;
}

.aica-channel-option {
    background: #ffffff;
    border: 2px solid #f0f0f0;
    border-radius: 16px;
    padding: 24px 16px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    position: relative;
    overflow: hidden;
}

.aica-channel-option::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--header-background, linear-gradient(135deg, var(--primary-color, #0084ff) 0%, var(--primary-color-dark, #0066cc) 100%));
    opacity: 0;
    transition: opacity 0.3s ease;
}

.aica-channel-option:hover {
    border-color: var(--primary-color, #0084ff);
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(0, 132, 255, 0.2);
}

.aica-channel-option:hover::before {
    opacity: 0.05;
}

.aica-channel-option:active {
    transform: translateY(-2px) scale(0.98);
}

.aica-channel-icon {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: linear-gradient(135deg, #f5f5f5 0%, #e8e8e8 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    position: relative;
    z-index: 1;
}

.aica-channel-option:hover .aica-channel-icon {
    transform: scale(1.1) rotate(5deg);
    background: var(--header-background, linear-gradient(135deg, var(--primary-color, #0084ff) 0%, var(--primary-color-dark, #0066cc) 100%));
}

.aica-channel-icon .dashicons {
    font-size: 32px;
    width: 32px;
    height: 32px;
    color: #666;
    transition: color 0.3s ease;
}

.aica-channel-option:hover .aica-channel-icon .dashicons {
    color: #ffffff;
}

.aica-channel-option h4 {
    margin: 0;
    font-size: 14px;
    font-weight: 700;
    color: #333;
    position: relative;
    z-index: 1;
    letter-spacing: 0.2px;
}

/* ============================================
   CHAT MESSAGES - SMOOTH ANIMATIONS
   ============================================ */
.aica-chat-messages {
    flex: 1;
    overflow-y: auto;
    overflow-x: hidden;
    padding: 20px;
    background: linear-gradient(to bottom, #fafafa 0%, #f5f5f5 100%);
    scroll-behavior: smooth;
    min-height: 0; /* Important for flex */
}

.aica-chat-messages::-webkit-scrollbar {
    width: 6px;
}

.aica-chat-messages::-webkit-scrollbar-track {
    background: transparent;
}

.aica-chat-messages::-webkit-scrollbar-thumb {
    background: #ddd;
    border-radius: 10px;
}

.aica-message {
    margin-bottom: 16px;
    display: flex;
    gap: 10px;
    animation: messageSlideIn 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes messageSlideIn {
    from {
        opacity: 0;
        transform: translateY(15px) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.aica-message.user {
    flex-direction: row-reverse;
}

.aica-message-avatar {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    background: linear-gradient(135deg, #e8e8e8 0%, #d0d0d0 100%);
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
}

.aica-message.assistant .aica-message-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.aica-message-content {
    max-width: 75%;
    padding: 13px 18px;
    border-radius: 20px;
    line-height: 1.5;
    font-size: 14px;
    background: #ffffff;
    color: #333;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    position: relative;
    word-wrap: break-word;
}

.aica-message.assistant .aica-message-content {
    border-bottom-left-radius: 4px;
}

.aica-message.user .aica-message-content {
    background: var(--header-background, linear-gradient(135deg, var(--primary-color, #0084ff) 0%, var(--primary-color-dark, #0066cc) 100%));
    color: #ffffff;
    border-bottom-right-radius: 4px;
    box-shadow: 0 2px 12px rgba(0, 132, 255, 0.3);
}

/* ============================================
   TYPING INDICATOR - ANIMATED DOTS
   ============================================ */
.aica-typing {
    display: none;
    align-items: flex-end;
    gap: 10px;
    padding: 10px 0;
}

.aica-typing.active {
    display: flex;
    animation: messageSlideIn 0.4s ease-out;
}

.aica-typing .aica-message-content {
    display: inline-flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
    min-width: 112px;
}

.aica-thinking-label {
    font-size: 12px;
    font-weight: 600;
    line-height: 1.1;
    color: #8a8a8a;
    letter-spacing: 0.02em;
}

.aica-typing-dots {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 0;
    background: transparent;
    border-radius: 0;
    box-shadow: none;
}

.aica-typing-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--primary-color, #f5a623);
    animation: typingBounce 1.2s ease-in-out infinite;
}

.aica-typing-dot:nth-child(2) {
    animation-delay: 0.2s;
}

.aica-typing-dot:nth-child(3) {
    animation-delay: 0.4s;
}

#aica-chat-container[data-aica-mode="dark"] .aica-thinking-label {
    color: rgba(255,255,255,0.72);
}

#aica-chat-container[data-aica-mode="dark"] .aica-typing-dot {
    background: rgba(255,255,255,0.9);
}

@keyframes typingBounce {
    0%, 60%, 100% {
        transform: translateY(0);
        opacity: 0.7;
    }
    30% {
        transform: translateY(-8px);
        opacity: 1;
    }
}

/* ============================================
   INPUT AREA - FLOATING SEND BUTTON
   ============================================ */
.aica-chat-input-area {
    padding: 14px 16px;
    background: rgba(255,255,255,0.92);
    border-top: 1px solid rgba(226, 232, 240, 0.9);
    display: flex;
    gap: 10px;
    align-items: center;
    justify-content: center;
    flex-shrink: 0; /* Never shrink */
    position: relative;
    z-index: 10;
    backdrop-filter: blur(8px);
}

.aica-chat-input-tools {
    display: flex;
    gap: 6px;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    padding-bottom: 0;
}

.aica-tool-button {
    width: var(--tool-button-size, 34px);
    height: var(--tool-button-size, 34px);
    min-width: var(--tool-button-size, 34px);
    min-height: var(--tool-button-size, 34px);
    border-radius: 999px;
    border: none !important;
    background: transparent !important;
    color: var(--tool-button-icon, #f97316) !important;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: transform 0.2s ease, opacity 0.2s ease, color 0.2s ease;
    box-shadow: none !important;
    padding: 0 !important;
    border-radius: 999px !important;
    appearance: none;
    -webkit-appearance: none;
    outline: none !important;
}

.aica-tool-button svg {
    width: calc(var(--tool-button-size, 34px) * 0.62);
    height: calc(var(--tool-button-size, 34px) * 0.62);
    display: block;
    color: inherit !important;
    stroke: currentColor !important;
    fill: none;
}

.aica-tool-icon-image{
    width: calc(var(--tool-button-size, 34px) * 0.62);
    height: calc(var(--tool-button-size, 34px) * 0.62);
    object-fit: contain;
    display:block;
}

.aica-tool-button:hover {
    transform: translateY(-1px) scale(1.06);
    color: var(--tool-button-icon, #f97316) !important;
    opacity: 1;
    background: transparent !important;
    box-shadow: none !important;
}

.aica-tool-button.is-active {
    background: transparent !important;
    color: var(--tool-button-icon, #f97316) !important;
    box-shadow: none !important;
    opacity: 1;
}

.aica-tool-button.is-speaking,
.aica-tool-button.is-listening {
    position: relative;
    color: var(--primary-color, #f59e0b) !important;
}

.aica-tool-button.is-speaking svg,
.aica-tool-button.is-listening svg,
.aica-tool-button.is-speaking .aica-tool-icon-image,
.aica-tool-button.is-listening .aica-tool-icon-image {
    animation: aicaToolSoundPulse 0.95s ease-in-out infinite;
    transform-origin: center center;
}

.aica-tool-button.is-speaking::after,
.aica-tool-button.is-listening::after {
    content: '';
    position: absolute;
    inset: 4px;
    border-radius: 999px;
    border: 1px solid currentColor;
    opacity: 0.28;
    animation: aicaToolRing 1.1s ease-out infinite;
    pointer-events: none;
}

.aica-tool-button.is-disabled {
    opacity: 0.45;
    cursor: not-allowed;
    box-shadow: none;
}

#aica-message-input {
    flex: 1;
    min-width: 0;
    width: 100%;
    padding: 13px 18px;
    border: 2px solid rgba(249, 115, 22, 0.18);
    border-radius: 999px;
    font-size: 15px;
    font-family: inherit;
    resize: none;
    max-height: 120px;
    min-height: 48px;
    transition: all 0.3s ease;
    background: rgba(255,255,255,0.92);
    line-height: 1.4;
    box-shadow: inset 0 1px 2px rgba(15, 23, 42, 0.03), 0 8px 18px rgba(15, 23, 42, 0.05);
}

#aica-message-input:focus {
    outline: none;
    border-color: var(--primary-color, #0084ff);
    background: #ffffff;
    box-shadow: 0 0 0 4px rgba(0, 132, 255, 0.1);
}

#aica-send-button {
    width: var(--send-button-size, 52px);
    height: var(--send-button-size, 52px);
    min-width: var(--send-button-size, 52px);
    min-height: var(--send-button-size, 52px);
    border-radius: 999px;
    border: 1px solid rgba(255,255,255,0.24);
    color: var(--send-button-icon, #ffffff);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: all 0.22s ease;
    box-shadow: 0 14px 26px rgba(249, 115, 22, 0.22);
    padding: 0;
    background: var(--send-button-bg, #f59e0b);
}

#aica-send-button:hover {
    transform: translateY(-2px) scale(1.03);
    box-shadow: 0 18px 32px rgba(249, 115, 22, 0.28);
}

#aica-send-button:active {
    transform: translateY(0) scale(0.98);
}

#aica-send-button svg {
    width: calc(var(--send-button-size, 52px) * 0.44);
    height: calc(var(--send-button-size, 52px) * 0.44);
    display: block;
    color: var(--send-button-icon, #ffffff) !important;
    stroke: currentColor !important;
    fill: none;
}

.aica-send-icon-image{
    width: calc(var(--send-button-size, 52px) * 0.44);
    height: calc(var(--send-button-size, 52px) * 0.44);
    object-fit: contain;
    display:block;
}

@keyframes aicaToolSoundPulse {
    0%, 100% {
        transform: scale(1);
        opacity: 0.95;
    }
    50% {
        transform: scale(1.14);
        opacity: 1;
    }
}

@keyframes aicaToolRing {
    0% {
        transform: scale(0.72);
        opacity: 0.32;
    }
    70% {
        transform: scale(1.24);
        opacity: 0;
    }
    100% {
        transform: scale(1.24);
        opacity: 0;
    }
}

/* ============================================
   MOBILE RESPONSIVE (CARD STYLE, NOT FULLSCREEN)
   ============================================ */
@media (max-width: 480px) {

    #aica-chat-container {
        bottom: calc(16px + env(safe-area-inset-bottom)) !important;
    }
    #aica-chat-container.aica-position-right { right: 16px !important; }
    #aica-chat-container.aica-position-left { left: 16px !important; }

    #aica-chat-window {
        width: calc(100vw - 24px) !important;
        max-width: 420px !important;
        height: min(640px, calc(100dvh - 140px)) !important;
        max-height: calc(100dvh - 140px) !important;
        bottom: calc(92px + env(safe-area-inset-bottom)) !important;
        left: 12px !important;
        right: 12px !important;
        border-radius: 22px !important;
        box-shadow: 0 14px 50px rgba(0, 0, 0, 0.25) !important;
        overflow: hidden !important;
    }

    .aica-chat-input-area {
        gap: 8px;
        padding: 12px 12px calc(12px + env(safe-area-inset-bottom));
        align-items: center;
    }

    .aica-chat-input-tools {
        gap: 8px;
        justify-content: center;
    }

    .aica-tool-button {
        width: clamp(26px, var(--tool-button-size, 34px), 32px);
        height: clamp(26px, var(--tool-button-size, 34px), 32px);
        min-width: clamp(26px, var(--tool-button-size, 34px), 32px);
        min-height: clamp(26px, var(--tool-button-size, 34px), 32px);
    }

    .aica-tool-button svg,
    .aica-tool-icon-image {
        width: 16px;
        height: 16px;
    }

    #aica-message-input {
        min-height: 46px;
        max-height: 100px;
        padding: 12px 16px;
        font-size: 16px;
        line-height: 1.3;
    }

    #aica-send-button {
        width: clamp(42px, var(--send-button-size, 52px), 48px);
        height: clamp(42px, var(--send-button-size, 52px), 48px);
        min-width: clamp(42px, var(--send-button-size, 52px), 48px);
        min-height: clamp(42px, var(--send-button-size, 52px), 48px);
    }

    #aica-send-button svg,
    .aica-send-icon-image {
        width: 20px;
        height: 20px;
    }

    .aica-chat-header {
        padding: 18px 16px !important;
    }

    .aica-avatar {
        width: 42px !important;
        height: 42px !important;
        animation: none !important;
    }

    .aica-header-content h3 {
        font-size: 16px !important;
        line-height: 1.2 !important;
        max-width: 240px;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    .aica-header-content p {
        font-size: 12px !important;
        gap: 6px !important;
    }

    .aica-close-button {
        width: 36px !important;
        height: 36px !important;
        min-width: 36px !important;
        min-height: 36px !important;
        border-radius: 999px !important;
        padding: 0 !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
    }

    .aica-step-content {
        padding: 22px 18px !important;
    }

    #aica-channels-list {
        grid-template-columns: 1fr !important;
    }

    .aica-form-group input {
        border-radius: 12px !important;
        padding: 12px 14px !important;
    }

    .aica-submit-button {
        border-radius: 12px !important;
        padding: 14px 16px !important;
    }
}

/* ============================================
   UTILITY ANIMATIONS
   ============================================ */
.aica-fade-in {
    animation: fadeIn 0.3s ease-out;
}

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

.aica-slide-up {
    animation: slideUp 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

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

/* ============================================
   SUCCESS/ERROR STATES
   ============================================ */
.aica-success-message,
.aica-error-message {
    padding: 12px 16px;
    border-radius: 12px;
    margin: 10px 0;
    animation: messageSlideIn 0.4s ease-out;
    font-size: 14px;
}

.aica-success-message {
    background: #e8f5e9;
    color: #2e7d32;
    border-left: 4px solid #4caf50;
}

.aica-error-message {
    background: #ffebee;
    color: #c62828;
    border-left: 4px solid #f44336;
}

/* ============================================
   HUMAN AGENT REQUEST BUTTON
   ============================================ */
.aica-human-agent-section {
    padding: 12px 20px;
    background: linear-gradient(to bottom, #ffffff 0%, #fafafa 100%);
    border-top: 1px solid #f0f0f0;
    border-bottom: 1px solid #f0f0f0;
}

.aica-request-human-button {
    width: 100%;
    padding: 12px 20px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border: none;
    border-radius: 12px;
    color: #ffffff;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 2px 8px rgba(102, 126, 234, 0.3);
    position: relative;
    overflow: hidden;
}

.aica-request-human-button::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.aica-request-human-button:hover::before {
    width: 300px;
    height: 300px;
}

.aica-request-human-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 16px rgba(102, 126, 234, 0.4);
}

.aica-request-human-button:active {
    transform: translateY(0);
    box-shadow: 0 2px 8px rgba(102, 126, 234, 0.3);
}

.aica-request-human-button .dashicons {
    font-size: 20px;
    width: 20px;
    height: 20px;
}

.aica-request-human-button .button-text {
    position: relative;
    z-index: 1;
}

/* Button states */
.aica-request-human-button.waiting {
    background: linear-gradient(135deg, #fbbf24 0%, #f59e0b 100%);
    cursor: wait;
}

.aica-request-human-button.waiting .dashicons {
    animation: pulseIcon 1.5s ease-in-out infinite;
}

.aica-request-human-button.connected {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
}

.aica-request-human-button.unavailable {
    background: linear-gradient(135deg, #9ca3af 0%, #6b7280 100%);
    cursor: not-allowed;
}

.aica-request-human-button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

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

/* Hide button when with agent */
.aica-step-chat.with-agent .aica-human-agent-section {
    display: none;
}

/* Agent connected indicator */
.aica-agent-indicator {
    display: none;
    padding: 10px 20px;
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
    text-align: center;
    font-size: 13px;
    font-weight: 600;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
}

.aica-agent-indicator.active {
    display: block;
}

.aica-agent-indicator .dashicons {
    vertical-align: middle;
    margin-right: 5px;
}


/* FORCE WHITE HEADER TEXT (theme-proof) */
#aica-chat-window .aica-chat-header h3,
#aica-chat-window .aica-chat-header p {
    color: #ffffff !important;
}

@media (max-width: 480px) {
    .aica-channel-shortcuts {
        gap: 12px;
        padding: 8px 10px 6px;
    }

    .aica-shortcut-button {
        width: 26px;
        height: 26px;
    }

    .aica-shortcut-button svg {
        width: 17px;
        height: 17px;
    }
}


/* ============================================
   v3.9.0 DESIGN SYSTEM UPDATES
   ============================================ */
#aica-chat-container {
    --aica-surface: #ffffff;
    --aica-surface-2: #f8fafc;
    --aica-border: rgba(15, 23, 42, 0.06);
    --aica-text: #1f2937;
    --aica-muted: #6b7280;
    --aica-shadow: 0 18px 55px rgba(15, 23, 42, 0.18);
}

#aica-chat-container[data-aica-mode="dark"] {
    --aica-surface: #0f172a;
    --aica-surface-2: #111827;
    --aica-border: rgba(255,255,255,0.08);
    --aica-text: #f8fafc;
    --aica-muted: rgba(226,232,240,0.78);
    --aica-shadow: 0 20px 60px rgba(2, 6, 23, 0.55);
}

#aica-chat-window {
    background: var(--aica-surface);
    box-shadow: var(--aica-shadow);
    border: 1px solid var(--aica-border);
}

#aica-content,
.aica-chat-input-area,
.aica-step-content,
.aica-chat-messages {
    background: transparent;
}

.aica-chat-header {
    min-height: 92px;
    padding: 18px 16px 14px;
    align-items: center;
    gap: 10px;
    background: linear-gradient(135deg, var(--primary-color, #ff9f0a) 0%, var(--primary-color-dark, #d97706) 62%, rgba(255,255,255,0.08) 100%);
}

#aica-chat-container[data-aica-mode="dark"] .aica-chat-header {
    background: linear-gradient(135deg, var(--primary-color, #ff9f0a) 0%, #111827 100%);
}

.aica-header-side {
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 4;
}

.aica-header-content {
    width: 100%;
    margin-left: 0;
    gap: 10px;
    justify-content: flex-start;
    align-items: center;
}

.aica-avatar {
    width: 48px;
    height: 48px;
    margin-left: 0;
    box-shadow: 0 8px 24px rgba(0,0,0,0.14);
}

.aica-header-text {
    min-width: 0;
}

#aica-chat-window .aica-header-content h3 {
    font-size: 15px !important;
    font-weight: 700 !important;
    letter-spacing: -0.15px !important;
    margin-bottom: 2px !important;
}

#aica-chat-window .aica-header-content p {
    font-size: 12px !important;
    font-weight: 600 !important;
    color: rgba(255,255,255,0.95) !important;
}

.aica-close-button {
    background: transparent !important;
    box-shadow: none !important;
}

.aica-close-button:hover {
    background: rgba(255,255,255,0.16) !important;
    transform: none;
}

.aica-channel-shortcuts {
    position: absolute;
    top: 94px;
    left: 0;
    right: 0;
    z-index: 4;
    gap: 18px;
    padding: 0 18px;
    height: 0;
    background: transparent !important;
    border: none !important;
    pointer-events: none;
}

.aica-shortcut-button {
    width: 34px;
    height: 34px;
    color: #d13f73;
    opacity: 0.94;
    pointer-events: auto;
}

#aica-chat-container[data-aica-mode="dark"] .aica-shortcut-button {
    color: #f9a8d4;
}

.aica-shortcut-button--chat { color: var(--channel-chat-color, #ec4899); }
.aica-shortcut-button--whatsapp { color: var(--channel-whatsapp-color, #22c55e); }
.aica-shortcut-button--email { color: var(--channel-email-color, #f97316); }
.aica-shortcut-button--call { color: var(--channel-call-color, #8b5cf6); }

.aica-shortcut-button.active,
.aica-shortcut-button:hover {
    background: transparent !important;
    box-shadow: none !important;
}

#aica-content {
    padding-top: 26px;
}

#aica-content::before {
    content: '';
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: 0;
    opacity: 1;
}

#aica-content > * {
    position: relative;
    z-index: 1;
}

#aica-chat-container[data-aica-bg="none"] #aica-content::before {
    background: linear-gradient(180deg, rgba(248,250,252,0.92) 0%, rgba(255,255,255,0.92) 100%);
}
#aica-chat-container[data-aica-bg="aurora"] #aica-content::before {
    background: radial-gradient(circle at 10% 10%, rgba(96,165,250,0.22), transparent 30%), radial-gradient(circle at 90% 10%, rgba(244,114,182,0.18), transparent 28%), linear-gradient(180deg, rgba(255,255,255,0.88) 0%, rgba(255,247,237,0.9) 100%);
}
#aica-chat-container[data-aica-bg="mesh-orange"] #aica-content::before {
    background: radial-gradient(circle at 0% 0%, rgba(251,146,60,0.2), transparent 30%), radial-gradient(circle at 100% 20%, rgba(245,158,11,0.2), transparent 32%), linear-gradient(180deg, rgba(255,251,235,0.95) 0%, rgba(255,237,213,0.92) 100%);
}
#aica-chat-container[data-aica-bg="mesh-blue"] #aica-content::before {
    background: radial-gradient(circle at 0% 20%, rgba(59,130,246,0.18), transparent 32%), radial-gradient(circle at 90% 0%, rgba(56,189,248,0.18), transparent 28%), linear-gradient(180deg, rgba(239,246,255,0.95) 0%, rgba(219,234,254,0.92) 100%);
}
#aica-chat-container[data-aica-bg="warm-glow"] #aica-content::before {
    background: radial-gradient(circle at 30% 18%, rgba(251,191,36,0.18), transparent 26%), radial-gradient(circle at 70% 10%, rgba(251,113,133,0.14), transparent 24%), linear-gradient(180deg, rgba(255,247,237,0.96) 0%, rgba(255,255,255,0.9) 100%);
}
#aica-chat-container[data-aica-bg="glass"] #aica-content::before {
    background: linear-gradient(180deg, rgba(248,250,252,0.78) 0%, rgba(255,255,255,0.74) 100%);
    backdrop-filter: blur(14px);
}
#aica-chat-container[data-aica-bg="dots"] #aica-content::before {
    background-image: radial-gradient(rgba(15,23,42,0.08) 1px, transparent 1.5px), linear-gradient(180deg, rgba(248,250,252,0.95) 0%, rgba(255,255,255,0.94) 100%);
    background-size: 18px 18px, auto;
}
#aica-chat-container[data-aica-bg="grid"] #aica-content::before {
    background-image: linear-gradient(rgba(15,23,42,0.06) 1px, transparent 1px), linear-gradient(90deg, rgba(15,23,42,0.06) 1px, transparent 1px), linear-gradient(180deg, rgba(248,250,252,0.97) 0%, rgba(255,255,255,0.95) 100%);
    background-size: 20px 20px, 20px 20px, auto;
}
#aica-chat-container[data-aica-bg="sunrise"] #aica-content::before {
    background: linear-gradient(180deg, rgba(255,247,237,0.95) 0%, rgba(255,228,230,0.93) 100%);
}
#aica-chat-container[data-aica-bg="midnight"] #aica-content::before {
    background: radial-gradient(circle at top, rgba(59,130,246,0.16), transparent 28%), linear-gradient(180deg, rgba(15,23,42,0.98) 0%, rgba(30,41,59,0.97) 100%);
}
#aica-chat-container[data-aica-bg="waves"] #aica-content::before {
    background: radial-gradient(circle at 20% 20%, rgba(34,211,238,0.14), transparent 26%), radial-gradient(circle at 80% 8%, rgba(168,85,247,0.14), transparent 24%), linear-gradient(180deg, rgba(236,254,255,0.95) 0%, rgba(245,243,255,0.92) 100%);
}

#aica-chat-container[data-aica-bg="custom"] #aica-content::before {
    background-image: linear-gradient(180deg, rgba(255,255,255,0.72) 0%, rgba(255,255,255,0.76) 100%), var(--aica-custom-bg-url);
    background-size: cover, cover;
    background-position: center, center;
}

#aica-chat-container[data-aica-mode="dark"][data-aica-bg="custom"] #aica-content::before {
    background-image: linear-gradient(180deg, rgba(15,23,42,0.74) 0%, rgba(17,24,39,0.78) 100%), var(--aica-custom-bg-url);
    background-size: cover, cover;
    background-position: center, center;
}

#aica-chat-container[data-aica-mode="dark"] #aica-content::before,
#aica-chat-container[data-aica-mode="dark"][data-aica-bg="none"] #aica-content::before {
    background: linear-gradient(180deg, rgba(15,23,42,0.98) 0%, rgba(17,24,39,0.98) 100%);
}
#aica-chat-container[data-aica-mode="dark"][data-aica-bg="aurora"] #aica-content::before {
    background: radial-gradient(circle at 15% 12%, rgba(56,189,248,0.18), transparent 30%), radial-gradient(circle at 85% 10%, rgba(217,70,239,0.16), transparent 26%), linear-gradient(180deg, rgba(15,23,42,0.97) 0%, rgba(17,24,39,0.97) 100%);
}
#aica-chat-container[data-aica-mode="dark"][data-aica-bg="mesh-orange"] #aica-content::before {
    background: radial-gradient(circle at 10% 0%, rgba(251,146,60,0.18), transparent 28%), radial-gradient(circle at 100% 20%, rgba(245,158,11,0.14), transparent 25%), linear-gradient(180deg, rgba(17,24,39,0.98) 0%, rgba(30,41,59,0.98) 100%);
}
#aica-chat-container[data-aica-mode="dark"][data-aica-bg="mesh-blue"] #aica-content::before {
    background: radial-gradient(circle at 0% 15%, rgba(59,130,246,0.18), transparent 28%), radial-gradient(circle at 100% 5%, rgba(34,211,238,0.14), transparent 25%), linear-gradient(180deg, rgba(15,23,42,0.98) 0%, rgba(30,41,59,0.98) 100%);
}
#aica-chat-container[data-aica-mode="dark"][data-aica-bg="warm-glow"] #aica-content::before {
    background: radial-gradient(circle at 30% 18%, rgba(251,191,36,0.15), transparent 24%), radial-gradient(circle at 72% 5%, rgba(251,113,133,0.12), transparent 22%), linear-gradient(180deg, rgba(17,24,39,0.98) 0%, rgba(30,41,59,0.98) 100%);
}
#aica-chat-container[data-aica-mode="dark"][data-aica-bg="glass"] #aica-content::before {
    background: linear-gradient(180deg, rgba(15,23,42,0.78) 0%, rgba(17,24,39,0.74) 100%);
    backdrop-filter: blur(14px);
}
#aica-chat-container[data-aica-mode="dark"][data-aica-bg="dots"] #aica-content::before {
    background-image: radial-gradient(rgba(255,255,255,0.07) 1px, transparent 1.5px), linear-gradient(180deg, rgba(15,23,42,0.98) 0%, rgba(17,24,39,0.98) 100%);
    background-size: 18px 18px, auto;
}
#aica-chat-container[data-aica-mode="dark"][data-aica-bg="grid"] #aica-content::before {
    background-image: linear-gradient(rgba(255,255,255,0.06) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,0.06) 1px, transparent 1px), linear-gradient(180deg, rgba(15,23,42,0.98) 0%, rgba(17,24,39,0.98) 100%);
    background-size: 20px 20px, 20px 20px, auto;
}
#aica-chat-container[data-aica-mode="dark"][data-aica-bg="sunrise"] #aica-content::before {
    background: linear-gradient(180deg, rgba(31,41,55,0.98) 0%, rgba(55,65,81,0.96) 100%);
}
#aica-chat-container[data-aica-mode="dark"][data-aica-bg="midnight"] #aica-content::before {
    background: radial-gradient(circle at 50% 10%, rgba(96,165,250,0.18), transparent 30%), linear-gradient(180deg, rgba(2,6,23,0.99) 0%, rgba(15,23,42,0.99) 100%);
}
#aica-chat-container[data-aica-mode="dark"][data-aica-bg="waves"] #aica-content::before {
    background: radial-gradient(circle at 20% 18%, rgba(34,211,238,0.14), transparent 26%), radial-gradient(circle at 80% 8%, rgba(168,85,247,0.12), transparent 22%), linear-gradient(180deg, rgba(15,23,42,0.98) 0%, rgba(17,24,39,0.98) 100%);
}

.aica-chat-messages {
    background: transparent;
}

.aica-message-content,
.aica-chat-input-area,
#aica-message-input,
.aica-step-content h3,
.aica-step-content p,
.aica-form-group label {
    color: inherit;
}

#aica-chat-container[data-aica-mode="dark"] .aica-message.assistant .aica-message-content {
    background: rgba(255,255,255,0.08);
    color: #f8fafc;
    box-shadow: 0 10px 24px rgba(2,6,23,0.24);
}

#aica-chat-container[data-aica-mode="dark"] .aica-message-avatar {
    background: rgba(255,255,255,0.1);
    color: #f8fafc;
}

#aica-chat-container[data-aica-mode="dark"] .aica-step-content h3,
#aica-chat-container[data-aica-mode="dark"] .aica-form-group label,
#aica-chat-container[data-aica-mode="dark"] #aica-message-input,
#aica-chat-container[data-aica-mode="dark"] .aica-step-content,
#aica-chat-container[data-aica-mode="dark"] .aica-step-content p,
#aica-chat-container[data-aica-mode="dark"] .aica-chat-input-area,
#aica-chat-container[data-aica-mode="dark"] .aica-success-message,
#aica-chat-container[data-aica-mode="dark"] #call-office-hours {
    color: #f8fafc !important;
}

#aica-chat-container[data-aica-mode="dark"] #aica-message-input,
#aica-chat-container[data-aica-mode="dark"] .aica-form-group input,
#aica-chat-container[data-aica-mode="dark"] .aica-form-group textarea {
    background: rgba(255,255,255,0.08);
    border-color: rgba(255,255,255,0.1);
    color: #f8fafc;
}

#aica-chat-container[data-aica-mode="dark"] #aica-message-input::placeholder,
#aica-chat-container[data-aica-mode="dark"] .aica-form-group input::placeholder,
#aica-chat-container[data-aica-mode="dark"] .aica-form-group textarea::placeholder,
#aica-chat-container[data-aica-mode="dark"] .aica-step-content p,
#aica-chat-container[data-aica-mode="dark"] .aica-form-group label,
#aica-chat-container[data-aica-mode="dark"] #call-office-hours {
    color: rgba(226,232,240,0.72) !important;
}

#aica-chat-container[data-aica-mode="dark"] .aica-chat-input-area {
    border-top-color: rgba(255,255,255,0.08);
    background: rgba(2,6,23,0.30);
    backdrop-filter: blur(10px);
}

#aica-chat-container[data-aica-mode="dark"] .aica-channel-icon-large,
#aica-chat-container[data-aica-mode="dark"] .aica-success-message {
    background: rgba(255,255,255,0.08);
}

@media (max-width: 480px) {
    .aica-header-content {
        margin-left: -2px;
    }
    #aica-chat-window .aica-header-content h3 {
        font-size: 14px !important;
    }
    .aica-channel-shortcuts {
        padding-top: 8px;
    }
    .aica-chat-input-area {
        grid-template-columns: auto 1fr auto;
    }
}
