/**
 * GP AI Chatbot - Chatbot Styles
 *
 * @package GP_AI_Chatbot
 */

/* ==========================================================================
   CSS Variables
   ========================================================================== */

:root {
    --gp-ai-primary-color: #0073aa;
    --gp-ai-primary-dark: #005177;
    --gp-ai-bg-color: #ffffff;
    --gp-ai-text-color: #333333;
    --gp-ai-text-light: #666666;
    --gp-ai-border-color: #e0e0e0;
    --gp-ai-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    --gp-ai-radius: 12px;
    --gp-ai-font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
}

/* ==========================================================================
   Container Base
   ========================================================================== */

.gp-ai-chatbot-container {
    font-family: var(--gp-ai-font-family);
    font-size: 14px;
    line-height: 1.5;
    color: var(--gp-ai-text-color);
    box-sizing: border-box;
}

.gp-ai-chatbot-container *,
.gp-ai-chatbot-container *::before,
.gp-ai-chatbot-container *::after {
    box-sizing: border-box;
}

/* ==========================================================================
   Floating Mode
   ========================================================================== */

.gp-ai-chatbot-mode-floating {
    position: fixed;
    z-index: 999999;
}

.gp-ai-chatbot-position-bottom-right {
    bottom: 20px;
    right: 20px;
}

.gp-ai-chatbot-position-bottom-left {
    bottom: 20px;
    left: 20px;
}

.gp-ai-chatbot-position-top-right {
    top: 20px;
    right: 20px;
}

.gp-ai-chatbot-position-top-left {
    top: 20px;
    left: 20px;
}

/* ==========================================================================
   Toggle Button
   ========================================================================== */

.gp-ai-chatbot-toggle {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: var(--gp-ai-primary-color);
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: var(--gp-ai-shadow);
    transition: all 0.3s ease;
}

.gp-ai-chatbot-toggle:hover {
    background: var(--gp-ai-primary-dark);
    transform: scale(1.05);
}

.gp-ai-chatbot-toggle svg {
    width: 28px;
    height: 28px;
    color: #fff;
}

.gp-ai-chatbot-toggle .icon-close {
    display: none;
}

.gp-ai-chatbot-container.is-open .gp-ai-chatbot-toggle .icon-chat {
    display: none;
}

.gp-ai-chatbot-container.is-open .gp-ai-chatbot-toggle .icon-close {
    display: block;
}

/* ==========================================================================
   Chat Window
   ========================================================================== */

.gp-ai-chatbot-window {
    display: none;
    flex-direction: column;
    width: 380px;
    height: 520px;
    max-height: calc(100vh - 100px);
    background: var(--gp-ai-bg-color);
    border-radius: var(--gp-ai-radius);
    box-shadow: var(--gp-ai-shadow);
    overflow: hidden;
    position: absolute;
    bottom: 80px;
    right: 0;
}

.gp-ai-chatbot-container.is-open .gp-ai-chatbot-window {
    display: flex;
}

/* Inline e Embed Mode */
.gp-ai-chatbot-mode-inline .gp-ai-chatbot-window,
.gp-ai-chatbot-mode-embed .gp-ai-chatbot-window {
    display: flex;
    position: relative;
    bottom: auto;
    right: auto;
    width: 100%;
    height: 100%;
    min-height: 400px;
}

.gp-ai-chatbot-mode-inline .gp-ai-chatbot-toggle,
.gp-ai-chatbot-mode-embed .gp-ai-chatbot-toggle {
    display: none;
}

/* Position adjustments */
.gp-ai-chatbot-position-bottom-left .gp-ai-chatbot-window {
    right: auto;
    left: 0;
}

.gp-ai-chatbot-position-top-right .gp-ai-chatbot-window,
.gp-ai-chatbot-position-top-left .gp-ai-chatbot-window {
    bottom: auto;
    top: 80px;
}

.gp-ai-chatbot-position-top-left .gp-ai-chatbot-window {
    right: auto;
    left: 0;
}

/* ==========================================================================
   Header
   ========================================================================== */

.gp-ai-chatbot-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 15px;
    background: var(--gp-ai-primary-color);
    color: #fff;
}

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

.gp-ai-chatbot-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
}

.gp-ai-chatbot-avatar svg {
    width: 24px;
    height: 24px;
}

.gp-ai-chatbot-header-text {
    display: flex;
    flex-direction: column;
}

.gp-ai-chatbot-title {
    font-weight: 600;
    font-size: 15px;
}

.gp-ai-chatbot-status {
    font-size: 12px;
    opacity: 0.9;
}

.gp-ai-chatbot-minimize {
    width: 32px;
    height: 32px;
    border: none;
    background: transparent;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
}

.gp-ai-chatbot-minimize:hover {
    background: rgba(255, 255, 255, 0.2);
}

.gp-ai-chatbot-minimize svg {
    width: 18px;
    height: 18px;
    color: inherit;
    fill: currentColor;
}

/* Header Actions Container */
.gp-ai-chatbot-header-actions {
    display: flex;
    align-items: center;
    gap: 4px;
}

/* Clear Chat Button */
.gp-ai-chatbot-clear {
    width: 32px;
    height: 32px;
    border: none;
    background: transparent;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
    color: inherit;
}

.gp-ai-chatbot-clear:hover {
    background: rgba(255, 255, 255, 0.2);
}

.gp-ai-chatbot-clear svg {
    width: 16px;
    height: 16px;
    color: inherit;
    fill: currentColor;
}

/* ==========================================================================
   Messages Area
   ========================================================================== */

.gp-ai-chatbot-messages {
    flex: 1;
    padding: 15px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 12px;
    background: #f8f9fa;
}

.gp-ai-chatbot-message {
    max-width: 85%;
    animation: messageIn 0.3s ease;
}

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

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

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

.gp-ai-chatbot-message-content {
    padding: 12px 16px;
    border-radius: 18px;
    word-break: break-word;
}

.gp-ai-chatbot-message-bot .gp-ai-chatbot-message-content {
    background: #fff;
    border: 1px solid var(--gp-ai-border-color);
    border-bottom-left-radius: 4px;
}

.gp-ai-chatbot-message-user .gp-ai-chatbot-message-content {
    background: var(--gp-ai-primary-color);
    color: #fff;
    border-bottom-right-radius: 4px;
}

/* ==========================================================================
   Typing Indicator
   ========================================================================== */

.gp-ai-chatbot-typing {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 15px;
    color: var(--gp-ai-text-light);
    font-size: 13px;
}

.gp-ai-chatbot-typing-dots {
    display: flex;
    gap: 4px;
}

.gp-ai-chatbot-typing-dots span {
    width: 8px;
    height: 8px;
    background: var(--gp-ai-primary-color);
    border-radius: 50%;
    animation: typing 1.4s infinite ease-in-out both;
}

.gp-ai-chatbot-typing-dots span:nth-child(1) {
    animation-delay: -0.32s;
}

.gp-ai-chatbot-typing-dots span:nth-child(2) {
    animation-delay: -0.16s;
}

@keyframes typing {
    0%, 80%, 100% {
        transform: scale(0.6);
        opacity: 0.5;
    }
    40% {
        transform: scale(1);
        opacity: 1;
    }
}

/* ==========================================================================
   Error Message
   ========================================================================== */

.gp-ai-chatbot-error {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 15px;
    background: #fff5f5;
    border-top: 1px solid #f5c6cb;
    color: #721c24;
    font-size: 13px;
}

.gp-ai-chatbot-error-dismiss {
    margin-left: auto;
    background: none;
    border: none;
    cursor: pointer;
    font-size: 18px;
    color: #721c24;
    padding: 0;
    line-height: 1;
}

/* ==========================================================================
   Rate Limit
   ========================================================================== */

.gp-ai-chatbot-rate-limit {
    padding: 8px 15px;
    background: #fff3cd;
    color: #856404;
    font-size: 13px;
    text-align: center;
}

/* ==========================================================================
   Input Area
   ========================================================================== */

.gp-ai-chatbot-input-area {
    padding: 12px 15px;
    background: #fff;
    border-top: 1px solid var(--gp-ai-border-color);
}

.gp-ai-chatbot-form {
    display: flex;
    gap: 10px;
}

.gp-ai-chatbot-input {
    flex: 1;
    padding: 10px 15px;
    border: 1px solid var(--gp-ai-border-color);
    border-radius: 20px;
    font-size: 14px;
    font-family: inherit;
    outline: none;
    transition: border-color 0.2s;
}

.gp-ai-chatbot-input:focus {
    border-color: var(--gp-ai-primary-color);
}

.gp-ai-chatbot-input:disabled {
    background: #f5f5f5;
    cursor: not-allowed;
}

.gp-ai-chatbot-send {
    width: 40px;
    height: 40px;
    border: none;
    background: var(--gp-ai-primary-color);
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
}

.gp-ai-chatbot-send:hover {
    background: var(--gp-ai-primary-dark);
}

.gp-ai-chatbot-send:disabled {
    background: #ccc;
    cursor: not-allowed;
}

.gp-ai-chatbot-send svg {
    width: 18px;
    height: 18px;
    color: #fff;
}

/* ==========================================================================
   Disclaimer
   ========================================================================== */

.gp-ai-chatbot-disclaimer {
    padding: 8px 15px;
    background: #f8f9fa;
    border-top: 1px solid var(--gp-ai-border-color);
    font-size: 11px;
    color: var(--gp-ai-text-light);
    text-align: center;
}

/* ==========================================================================
   Responsive
   ========================================================================== */

@media screen and (max-width: 480px) {
    .gp-ai-chatbot-window {
        width: calc(100vw - 20px);
        height: calc(100vh - 100px);
        max-height: none;
        right: 10px;
        bottom: 70px;
        border-radius: 8px;
    }

    .gp-ai-chatbot-container.gp-ai-chatbot-position-bottom-left .gp-ai-chatbot-window {
        left: 10px;
        right: auto;
    }

    .gp-ai-chatbot-toggle {
        width: 50px;
        height: 50px;
    }

    .gp-ai-chatbot-toggle svg {
        width: 24px;
        height: 24px;
    }
}

/* ==========================================================================
   Disabled Notice (for shortcode)
   ========================================================================== */

.gp-ai-chatbot-disabled-notice {
    padding: 20px;
    background: #fff3cd;
    border: 1px solid #ffc107;
    border-radius: 4px;
    color: #856404;
    text-align: center;
}

/* Link Preview Cards - v1.1.0 */
.gp-ai-chatbot-links {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-top: 10px;
}

.gp-ai-chatbot-link-preview {
    display: flex;
    text-decoration: none;
    color: inherit;
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 8px;
    overflow: hidden;
    transition: all 0.2s ease;
}

.gp-ai-chatbot-link-preview:hover {
    background: #e9ecef;
    border-color: var(--gp-ai-primary-color, #0073aa);
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.link-preview-image {
    flex-shrink: 0;
    width: 80px;
    height: 80px;
    overflow: hidden;
    background: #dee2e6;
    display: flex;
    align-items: center;
    justify-content: center;
}

.link-preview-image.no-image {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: rgba(255, 255, 255, 0.7);
}

.link-preview-image.no-image svg {
    opacity: 0.8;
}

.link-preview-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.link-preview-content {
    flex: 1;
    padding: 8px 12px;
    min-width: 0;
}

.link-preview-title {
    font-weight: 600;
    font-size: 13px;
    color: #212529;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin-bottom: 4px;
}

.link-preview-description {
    font-size: 12px;
    color: #6c757d;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.link-preview-domain {
    font-size: 11px;
    color: #adb5bd;
    margin-top: 4px;
}

/* Product info in link previews */
.link-preview-product-info {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 6px;
    font-size: 12px;
}

.link-preview-price {
    font-weight: 700;
    color: #212529;
}

.link-preview-stock {
    font-size: 11px;
    padding: 2px 6px;
    border-radius: 3px;
}

.link-preview-stock.in-stock {
    background: #d4edda;
    color: #155724;
}

.link-preview-stock.out-of-stock {
    background: #f8d7da;
    color: #721c24;
}

/* Rich message formatting */
.gp-ai-chatbot-message-content a {
    color: var(--gp-ai-primary-color, #0073aa);
    text-decoration: underline;
}

.gp-ai-chatbot-message-content a:hover {
    color: var(--gp-ai-primary-dark, #005177);
}

.gp-ai-chatbot-message-content strong {
    font-weight: 600;
}

.gp-ai-chatbot-message-content em {
    font-style: italic;
}

/* Force consistent icon colors - Default: white icons for dark headers */
.gp-ai-chatbot-header {
    color: #ffffff;
}

.gp-ai-chatbot-send svg,
.gp-ai-chatbot-minimize svg,
.gp-ai-chatbot-toggle svg {
    fill: currentColor !important;
    color: inherit !important;
}

.gp-ai-chatbot-header svg {
    fill: currentColor !important;
    color: inherit !important;
}

/* Default toggle button icon color */
.gp-ai-chatbot-toggle {
    color: #ffffff;
}

.gp-ai-chatbot-send {
    color: #ffffff;
}

/* ======================================================================
   Chatbot Themes - Widget Styles
   ====================================================================== */

/* Theme: Default (already styled via CSS variables) */
.gp-ai-chatbot-widget.theme-default {
    --gp-ai-header-bg: var(--gp-ai-primary-color, #0073aa);
    --gp-ai-body-bg: #f5f5f5;
    --gp-ai-bot-msg-bg: #e0e0e0;
    --gp-ai-user-msg-bg: var(--gp-ai-primary-color, #0073aa);
    --gp-ai-input-bg: #ffffff;
}

/* Theme: Corporate */
.gp-ai-chatbot-widget.theme-corporate {
    --gp-ai-header-bg: #1a1a2e;
    --gp-ai-body-bg: #16213e;
    --gp-ai-bot-msg-bg: #0f3460;
    --gp-ai-bot-msg-color: #e0e0e0;
    --gp-ai-user-msg-bg: #e94560;
    --gp-ai-user-msg-color: #ffffff;
    --gp-ai-input-bg: #1a1a2e;
    --gp-ai-input-color: #e0e0e0;
    --gp-ai-input-border: #0f3460;
}


.gp-ai-chatbot-widget.theme-corporate .gp-ai-chatbot-header {
    background: #1a1a2e;
}

.gp-ai-chatbot-widget.theme-corporate .gp-ai-chatbot-message-user .gp-ai-chatbot-message-content {
    background: #e94560;
    color: #ffffff;
}

.gp-ai-chatbot-widget.theme-corporate .gp-ai-chatbot-send {
    background: #e94560;
}

.gp-ai-chatbot-widget.theme-corporate .gp-ai-chatbot-toggle {
    background: #1a1a2e;
}
.gp-ai-chatbot-widget.theme-corporate .gp-ai-chatbot-messages {
    background: var(--gp-ai-body-bg);
}

.gp-ai-chatbot-widget.theme-corporate .gp-ai-chatbot-message-bot .gp-ai-chatbot-message-content {
    background: var(--gp-ai-bot-msg-bg);
    color: var(--gp-ai-bot-msg-color);
}

.gp-ai-chatbot-widget.theme-corporate .gp-ai-chatbot-input-area {
    background: var(--gp-ai-input-bg);
    border-top-color: var(--gp-ai-input-border);
}

.gp-ai-chatbot-widget.theme-corporate .gp-ai-chatbot-input {
    background: #0f3460;
    color: var(--gp-ai-input-color);
    border-color: #0f3460;
}

/* Theme: Emerald */
.gp-ai-chatbot-widget.theme-emerald {
    --gp-ai-header-bg: #059669;
    --gp-ai-body-bg: #ecfdf5;
    --gp-ai-bot-msg-bg: #d1fae5;
    --gp-ai-user-msg-bg: #10b981;
    --gp-ai-primary-color: #059669;
}

.gp-ai-chatbot-widget.theme-emerald .gp-ai-chatbot-messages {
    background: var(--gp-ai-body-bg);
}

.gp-ai-chatbot-widget.theme-emerald .gp-ai-chatbot-message-bot .gp-ai-chatbot-message-content {
    background: var(--gp-ai-bot-msg-bg);
}

.gp-ai-chatbot-widget.theme-emerald .gp-ai-chatbot-toggle {
    background: #059669;
}

.gp-ai-chatbot-widget.theme-emerald .gp-ai-chatbot-send {
    background: #10b981;
}

.gp-ai-chatbot-widget.theme-emerald .gp-ai-chatbot-message-user .gp-ai-chatbot-message-content {
    background: #10b981;
}

/* Theme: Neon Cyber */
.gp-ai-chatbot-widget.theme-neon {
    --gp-ai-header-bg: linear-gradient(90deg, #ff00ff, #00ffff);
    --gp-ai-body-bg: #0a0a0a;
    --gp-ai-bot-msg-bg: #1a1a1a;
    --gp-ai-bot-msg-color: #00ffff;
    --gp-ai-user-msg-bg: linear-gradient(90deg, #00ffff, #ff00ff);
    --gp-ai-input-bg: #111111;
}

.gp-ai-chatbot-widget.theme-neon .gp-ai-chatbot-header {
    background: linear-gradient(90deg, #ff00ff, #00ffff);
}

.gp-ai-chatbot-widget.theme-neon .gp-ai-chatbot-messages {
    background: var(--gp-ai-body-bg);
}

.gp-ai-chatbot-widget.theme-neon .gp-ai-chatbot-message-bot .gp-ai-chatbot-message-content {
    background: var(--gp-ai-bot-msg-bg);
    color: var(--gp-ai-bot-msg-color);
    border: 1px solid #ff00ff;
    text-shadow: 0 0 5px rgba(255, 0, 255, 0.3);
}

.gp-ai-chatbot-widget.theme-neon .gp-ai-chatbot-message-user .gp-ai-chatbot-message-content {
    background: linear-gradient(90deg, #00ffff, #ff00ff);
}

.gp-ai-chatbot-widget.theme-neon .gp-ai-chatbot-input-area {
    background: var(--gp-ai-input-bg);
}

.gp-ai-chatbot-widget.theme-neon .gp-ai-chatbot-input {
    background: #1a1a1a;
    color: #00ffff;
    border-color: #00ffff;
}

.gp-ai-chatbot-widget.theme-neon .gp-ai-chatbot-toggle {
    background: linear-gradient(90deg, #ff00ff, #00ffff);
}

.gp-ai-chatbot-widget.theme-neon .gp-ai-chatbot-send {
    background: linear-gradient(90deg, #ff00ff, #00ffff);
}

/* Theme: Sunset */
.gp-ai-chatbot-widget.theme-sunset .gp-ai-chatbot-header {
    background: linear-gradient(90deg, #f97316, #ec4899);
}

.gp-ai-chatbot-widget.theme-sunset .gp-ai-chatbot-messages {
    background: #fff7ed;
}

.gp-ai-chatbot-widget.theme-sunset .gp-ai-chatbot-message-bot .gp-ai-chatbot-message-content {
    background: #fed7aa;
}

.gp-ai-chatbot-widget.theme-sunset .gp-ai-chatbot-message-user .gp-ai-chatbot-message-content {
    background: linear-gradient(90deg, #fb923c, #f472b6);
}

.gp-ai-chatbot-widget.theme-sunset .gp-ai-chatbot-send {
    background: linear-gradient(90deg, #f97316, #ec4899);
}

.gp-ai-chatbot-widget.theme-sunset .gp-ai-chatbot-toggle {
    background: linear-gradient(90deg, #f97316, #ec4899);
}

/* Theme: Ocean */
.gp-ai-chatbot-widget.theme-ocean .gp-ai-chatbot-header {
    background: linear-gradient(90deg, #0ea5e9, #06b6d4);
}

.gp-ai-chatbot-widget.theme-ocean .gp-ai-chatbot-messages {
    background: #ecfeff;
}

.gp-ai-chatbot-widget.theme-ocean .gp-ai-chatbot-message-bot .gp-ai-chatbot-message-content {
    background: #a5f3fc;
}

.gp-ai-chatbot-widget.theme-ocean .gp-ai-chatbot-message-user .gp-ai-chatbot-message-content {
    background: #0891b2;
}

.gp-ai-chatbot-widget.theme-ocean .gp-ai-chatbot-toggle {
    background: linear-gradient(90deg, #0ea5e9, #06b6d4);
}

.gp-ai-chatbot-widget.theme-ocean .gp-ai-chatbot-send {
    background: #0891b2;
}

/* Theme: Midnight */
.gp-ai-chatbot-widget.theme-midnight {
    --gp-ai-header-bg: #312e81;
}

.gp-ai-chatbot-widget.theme-midnight .gp-ai-chatbot-header {
    background: #312e81;
}

.gp-ai-chatbot-widget.theme-midnight .gp-ai-chatbot-messages {
    background: #1e1b4b;
}

.gp-ai-chatbot-widget.theme-midnight .gp-ai-chatbot-message-bot .gp-ai-chatbot-message-content {
    background: #3730a3;
    color: #e0e7ff;
}

.gp-ai-chatbot-widget.theme-midnight .gp-ai-chatbot-message-user .gp-ai-chatbot-message-content {
    background: #6366f1;
}

.gp-ai-chatbot-widget.theme-midnight .gp-ai-chatbot-input-area {
    background: #312e81;
}

.gp-ai-chatbot-widget.theme-midnight .gp-ai-chatbot-input {
    background: #3730a3;
    color: #e0e7ff;
    border-color: #4f46e5;
}

.gp-ai-chatbot-widget.theme-midnight .gp-ai-chatbot-toggle {
    background: #312e81;
}

.gp-ai-chatbot-widget.theme-midnight .gp-ai-chatbot-send {
    background: #6366f1;
}

/* Theme: Aurora */
.gp-ai-chatbot-widget.theme-aurora .gp-ai-chatbot-header {
    background: linear-gradient(90deg, #a855f7, #06b6d4);
}

.gp-ai-chatbot-widget.theme-aurora .gp-ai-chatbot-messages {
    background: #faf5ff;
}

.gp-ai-chatbot-widget.theme-aurora .gp-ai-chatbot-message-bot .gp-ai-chatbot-message-content {
    background: #e9d5ff;
}

.gp-ai-chatbot-widget.theme-aurora .gp-ai-chatbot-message-user .gp-ai-chatbot-message-content {
    background: linear-gradient(90deg, #a855f7, #14b8a6);
}

.gp-ai-chatbot-widget.theme-aurora .gp-ai-chatbot-toggle {
    background: linear-gradient(90deg, #a855f7, #06b6d4);
}

.gp-ai-chatbot-widget.theme-aurora .gp-ai-chatbot-send {
    background: linear-gradient(90deg, #a855f7, #14b8a6);
}

/* Theme: Minimal Light */
.gp-ai-chatbot-widget.theme-minimal .gp-ai-chatbot-header {
    background: #f5f5f5;
    border-bottom: 1px solid #e0e0e0;
    color: #333333;
}

.gp-ai-chatbot-widget.theme-minimal .gp-ai-chatbot-toggle {
    background: #333333;
    color: #ffffff;
}

.gp-ai-chatbot-widget.theme-minimal .gp-ai-chatbot-header,
.gp-ai-chatbot-widget.theme-minimal .gp-ai-chatbot-header * {
    color: #333333 !important;
    fill: #333333 !important;
}

.gp-ai-chatbot-widget.theme-minimal .gp-ai-chatbot-messages {
    background: #ffffff;
}

.gp-ai-chatbot-widget.theme-minimal .gp-ai-chatbot-message-bot .gp-ai-chatbot-message-content {
    background: #f5f5f5;
    border: 1px solid #e0e0e0;
}

.gp-ai-chatbot-widget.theme-minimal .gp-ai-chatbot-message-user .gp-ai-chatbot-message-content {
    background: #333333;
}

.gp-ai-chatbot-widget.theme-minimal .gp-ai-chatbot-send {
    background: #333333;
}

/* Theme: Paper */
.gp-ai-chatbot-widget.theme-paper .gp-ai-chatbot-header {
    background: #faf8f5;
    border-bottom: 1px solid #e8e4dc;
    color: #5a4a3a;
}

.gp-ai-chatbot-widget.theme-paper .gp-ai-chatbot-toggle {
    background: #c49a6c;
    color: #ffffff;
}

.gp-ai-chatbot-widget.theme-paper .gp-ai-chatbot-header,
.gp-ai-chatbot-widget.theme-paper .gp-ai-chatbot-header * {
    color: #5a4a3a !important;
    fill: #5a4a3a !important;
}

.gp-ai-chatbot-widget.theme-paper .gp-ai-chatbot-messages {
    background: #fffefa;
}

.gp-ai-chatbot-widget.theme-paper .gp-ai-chatbot-message-bot .gp-ai-chatbot-message-content {
    background: #f5f0e6;
    border: 1px solid #e8e4dc;
}

.gp-ai-chatbot-widget.theme-paper .gp-ai-chatbot-message-user .gp-ai-chatbot-message-content {
    background: #d4a574;
}

.gp-ai-chatbot-widget.theme-paper .gp-ai-chatbot-send {
    background: #c49a6c;
}

/* Theme: WhatsApp */
.gp-ai-chatbot-widget.theme-whatsapp .gp-ai-chatbot-header {
    background: #075e54;
}

.gp-ai-chatbot-widget.theme-whatsapp .gp-ai-chatbot-messages {
    background: #ece5dd;
}

.gp-ai-chatbot-widget.theme-whatsapp .gp-ai-chatbot-message-bot .gp-ai-chatbot-message-content {
    background: #ffffff;
    border-radius: 0 8px 8px 8px;
}

.gp-ai-chatbot-widget.theme-whatsapp .gp-ai-chatbot-message-user .gp-ai-chatbot-message-content {
    background: #dcf8c6;
    color: #000000;
    border-radius: 8px 0 8px 8px;
}

.gp-ai-chatbot-widget.theme-whatsapp .gp-ai-chatbot-send {
    background: #25d366;
}

.gp-ai-chatbot-widget.theme-whatsapp .gp-ai-chatbot-toggle {
    background: #25d366;
}

/* Theme: Messenger */
.gp-ai-chatbot-widget.theme-messenger .gp-ai-chatbot-header {
    background: linear-gradient(90deg, #00c6ff, #0078ff);
}

.gp-ai-chatbot-widget.theme-messenger .gp-ai-chatbot-messages {
    background: #ffffff;
}

.gp-ai-chatbot-widget.theme-messenger .gp-ai-chatbot-message-bot .gp-ai-chatbot-message-content {
    background: #e4e6eb;
    border-radius: 18px;
}

.gp-ai-chatbot-widget.theme-messenger .gp-ai-chatbot-message-user .gp-ai-chatbot-message-content {
    background: linear-gradient(90deg, #00c6ff, #0078ff);
    border-radius: 18px;
}

.gp-ai-chatbot-widget.theme-messenger .gp-ai-chatbot-input-area {
    background: #f0f2f5;
}

.gp-ai-chatbot-widget.theme-messenger .gp-ai-chatbot-input {
    border-radius: 20px;
}

.gp-ai-chatbot-widget.theme-messenger .gp-ai-chatbot-send {
    background: linear-gradient(90deg, #00c6ff, #0078ff);
    border-radius: 50%;
}

.gp-ai-chatbot-widget.theme-messenger .gp-ai-chatbot-toggle {
    background: linear-gradient(90deg, #00c6ff, #0078ff);
}

/* Theme: Glass */
.gp-ai-chatbot-widget.theme-glass {
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.9), rgba(118, 75, 162, 0.9));
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
}

.gp-ai-chatbot-widget.theme-glass .gp-ai-chatbot-header {
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
}

.gp-ai-chatbot-widget.theme-glass .gp-ai-chatbot-messages {
    background: rgba(255, 255, 255, 0.1);
}

.gp-ai-chatbot-widget.theme-glass .gp-ai-chatbot-message-bot .gp-ai-chatbot-message-content {
    background: rgba(255, 255, 255, 0.3);
    backdrop-filter: blur(5px);
}

.gp-ai-chatbot-widget.theme-glass .gp-ai-chatbot-message-user .gp-ai-chatbot-message-content {
    background: rgba(255, 255, 255, 0.5);
    color: #333;
}

.gp-ai-chatbot-widget.theme-glass .gp-ai-chatbot-input-area {
    background: rgba(255, 255, 255, 0.2);
}

.gp-ai-chatbot-widget.theme-glass .gp-ai-chatbot-input {
    background: rgba(255, 255, 255, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.4);
    color: #ffffff;
}

.gp-ai-chatbot-widget.theme-glass .gp-ai-chatbot-input::placeholder {
    color: rgba(255, 255, 255, 0.7);
}

.gp-ai-chatbot-widget.theme-glass .gp-ai-chatbot-toggle {
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.9), rgba(118, 75, 162, 0.9));
}

.gp-ai-chatbot-widget.theme-glass .gp-ai-chatbot-send {
    background: rgba(255, 255, 255, 0.3);
}


/* ======================================================================
   Typewriter Effect
   ====================================================================== */

/* Blinking cursor during typing */
.gp-ai-chatbot-message-content.typing::after {
    content: '▋';
    animation: blink-cursor 0.7s step-end infinite;
    color: var(--gp-ai-primary-color, #0073aa);
    font-weight: bold;
}

@keyframes blink-cursor {
    0%, 100% { opacity: 1; }
    50% { opacity: 0; }
}

/* Smooth transition when typing completes */
.gp-ai-chatbot-message-content {
    transition: all 0.2s ease;
}

/* Links fade in after typing */
.gp-ai-chatbot-links {
    animation: fadeIn 0.3s ease-in;
}

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