/**
 * Gitakshmi Technologies - Custom Interactive Lead Collection Chatbot
 * 100% Isolated Styles under .gita-chatbot-root to prevent any CSS conflicts with theme.
 */

:root {
    --gita-bot-primary: #092EA0;
    --gita-bot-primary-light: #2E8EFF;
    --gita-bot-accent: #00E5FF;
    --gita-bot-dark: #0B192C;
    --gita-bot-surface: #FFFFFF;
    --gita-bot-bg-subtle: #F8FAFC;
    --gita-bot-border: #E2E8F0;
    --gita-bot-text: #1E293B;
    --gita-bot-text-muted: #64748B;
    --gita-bot-success: #10B981;
    --gita-bot-radius: 20px;
    --gita-bot-shadow: 0 20px 40px -10px rgba(9, 46, 160, 0.25), 0 0 0 1px rgba(226, 232, 240, 0.8);
    --gita-bot-font: 'Poppins', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

/* Base Wrapper */
.gita-chatbot-root {
    font-family: var(--gita-bot-font);
    box-sizing: border-box;
    position: relative;
    z-index: 999990;
}

.gita-chatbot-root *,
.gita-chatbot-root *::before,
.gita-chatbot-root *::after {
    box-sizing: border-box;
}

/* ======================================================
   1. FLOATING LAUNCHER BUTTON (G LOGO ALWAYS VISIBLE)
====================================================== */
.gita-chatbot-launcher {
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: #ffffff;
    border: 3px solid #2E8EFF;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 6px 25px rgba(9, 46, 160, 0.3), 0 2px 8px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.3s ease;
    z-index: 999992;
    outline: none;
    padding: 0;
    overflow: visible;
    -webkit-tap-highlight-color: transparent;
}

.gita-chatbot-launcher:hover {
    transform: scale(1.08);
    box-shadow: 0 10px 30px rgba(46, 142, 255, 0.45), 0 3px 12px rgba(0, 0, 0, 0.15);
}

.gita-chatbot-launcher:active {
    transform: scale(0.95);
}

/* G Logo inside Launcher */
.gita-launcher-g-logo {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.gita-launcher-g-logo img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    border-radius: 50%;
}

.gita-chatbot-launcher:hover .gita-launcher-g-logo {
    transform: rotate(6deg) scale(1.05);
}

/* Close badge over G logo when chat window is active */
.gita-launcher-close-badge {
    position: absolute;
    top: -2px;
    right: -2px;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: #EF4444;
    border: 2px solid #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #ffffff;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.25);
    opacity: 0;
    transform: scale(0.4);
    pointer-events: none;
    transition: all 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.gita-launcher-close-badge svg {
    display: block;
}

.gita-chatbot-root.is-open .gita-launcher-close-badge {
    opacity: 1;
    transform: scale(1);
}

/* Glowing Concentric Pulsing Waves - 100% Mathematically & Visually Centered */
.gita-launcher-pulse {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    border: 2px solid #2E8EFF;
    box-sizing: border-box;
    pointer-events: none;
    transform: translate(-50%, -50%) scale(1);
    transform-origin: center center;
    animation: gitaLauncherPulse 2.4s cubic-bezier(0.24, 0, 0.38, 1) infinite;
}

.gita-launcher-pulse.delay-1 {
    animation-delay: 1.2s;
}

@keyframes gitaLauncherPulse {
    0% {
        transform: translate(-50%, -50%) scale(1);
        opacity: 0.8;
    }

    50% {
        opacity: 0.35;
    }

    100% {
        transform: translate(-50%, -50%) scale(1.55);
        opacity: 0;
    }
}

.gita-chatbot-root.is-open .gita-launcher-pulse {
    display: none;
}

/* Unread Badge */
.gita-chatbot-badge {
    position: absolute;
    top: -3px;
    right: -3px;
    background: #EF4444;
    color: #ffffff;
    font-size: 11px;
    font-weight: 700;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid #ffffff;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
    animation: gitaBadgeBounce 2s infinite ease-in-out;
}

.gita-chatbot-root.is-open .gita-chatbot-badge,
.gita-chatbot-badge.is-hidden {
    display: none !important;
}

@keyframes gitaBadgeBounce {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-4px);
    }
}

/* ======================================================
   2. PROACTIVE TEASER SPEECH BUBBLE
====================================================== */
.gita-chatbot-teaser {
    position: fixed;
    bottom: 100px;
    right: 24px;
    width: 320px;
    background: #ffffff;
    border-radius: 16px;
    padding: 14px 16px;
    box-shadow: 0 12px 35px -5px rgba(9, 46, 160, 0.2), 0 0 0 1px rgba(226, 232, 240, 0.9);
    display: flex;
    align-items: center;
    gap: 12px;
    z-index: 999991;
    cursor: pointer;
    transform: translateY(12px) scale(0.96);
    opacity: 0;
    visibility: hidden;
    transition: all 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.gita-chatbot-teaser.is-visible {
    transform: translateY(0) scale(1);
    opacity: 1;
    visibility: visible;
}

.gita-chatbot-root.is-open .gita-chatbot-teaser {
    display: none !important;
}

.gita-teaser-avatar {
    position: relative;
    flex-shrink: 0;
}

.gita-avatar-ring {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--gita-bot-primary), var(--gita-bot-primary-light));
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2px;
}

.gita-avatar-ring img {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
    background: #ffffff;
}

.gita-status-dot {
    position: absolute;
    bottom: 0;
    right: 0;
    width: 11px;
    height: 11px;
    background: var(--gita-bot-success);
    border-radius: 50%;
    border: 2px solid #ffffff;
}

.gita-teaser-content {
    flex: 1;
    min-width: 0;
}

.gita-teaser-title {
    display: block;
    font-size: 12px;
    font-weight: 700;
    color: var(--gita-bot-primary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 2px;
}

.gita-teaser-text {
    margin: 0;
    font-size: 13px;
    color: var(--gita-bot-text);
    line-height: 1.35;
    font-weight: 500;
}

.gita-teaser-close {
    background: none;
    border: none;
    color: var(--gita-bot-text-muted);
    cursor: pointer;
    padding: 0 4px;
    line-height: 1;
    transition: color 0.2s ease;
    align-self: flex-start;
    display: flex;
    align-items: center;
    justify-content: center;
}

.gita-teaser-close:hover {
    color: var(--gita-bot-text);
}

.gita-teaser-close svg {
    display: block;
}

/* ======================================================
   3. CHATBOT MAIN WINDOW (MODAL)
====================================================== */
.gita-chatbot-window {
    position: fixed;
    bottom: 86px;
    right: 20px;
    width: 345px;
    max-width: calc(100vw - 32px);
    height: 480px;
    max-height: calc(100vh - 110px);
    background: var(--gita-bot-surface);
    border-radius: 16px;
    box-shadow: 0 16px 36px -8px rgba(9, 46, 160, 0.22), 0 0 0 1px rgba(226, 232, 240, 0.85);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    z-index: 999991;
    transform: translateY(16px) scale(0.95);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.25s ease, visibility 0.25s ease;
    border: 1px solid rgba(226, 232, 240, 0.85);
}

.gita-chatbot-root.is-open .gita-chatbot-window {
    transform: translateY(0) scale(1);
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

/* ======================================================
   4. CHAT HEADER & CONTROLS
====================================================== */
.gita-chatbot-header {
    background: linear-gradient(135deg, #071D58 0%, #092EA0 55%, #1852DD 100%);
    color: #ffffff;
    padding: 12px 14px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: relative;
    box-shadow: 0 3px 12px rgba(0, 0, 0, 0.08);
}

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

.gita-header-avatar {
    position: relative;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.15);
    padding: 2px;
    flex-shrink: 0;
    backdrop-filter: blur(4px);
}

.gita-header-avatar img {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
    background: #ffffff;
}

.gita-status-dot.online {
    position: absolute;
    bottom: 0px;
    right: 0px;
    width: 9px;
    height: 9px;
    background: #22C55E;
    border: 2px solid #071D58;
    border-radius: 50%;
}

.gita-header-text {
    display: flex;
    flex-direction: column;
}

.gita-header-title {
    margin: 0;
    font-size: 14px;
    font-weight: 700;
    color: #ffffff;
    letter-spacing: -0.2px;
    line-height: 1.2;
}

.gita-header-subtitle {
    font-size: 11px;
    color: rgba(255, 255, 255, 0.85);
    display: flex;
    align-items: center;
    gap: 4px;
    margin-top: 2px;
    font-weight: 500;
    letter-spacing: 0.2px;
}

.gita-header-controls {
    display: flex;
    align-items: center;
    gap: 5px;
}

.gita-control-btn {
    background: rgba(255, 255, 255, 0.14);
    border: none;
    color: #ffffff;
    width: 28px;
    height: 28px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background 0.2s ease, transform 0.15s ease;
    outline: none;
    padding: 0;
}

.gita-control-btn svg {
    width: 13px;
    height: 13px;
    display: block;
    color: #ffffff;
}

.gita-control-btn:hover {
    background: rgba(255, 255, 255, 0.28);
    transform: translateY(-1px);
}

.gita-control-btn.is-active {
    background: #2E8EFF;
    color: #ffffff;
    box-shadow: 0 0 10px rgba(46, 142, 255, 0.7);
}

.gita-control-btn:active {
    transform: scale(0.92);
}

.gita-control-btn.is-speaking {
    background: #10B981 !important;
    color: #ffffff !important;
    box-shadow: 0 0 12px rgba(16, 185, 129, 0.8) !important;
    animation: gitaSpeakerPulse 0.9s ease-in-out infinite alternate;
}

@keyframes gitaSpeakerPulse {
    0% {
        transform: scale(1);
    }

    100% {
        transform: scale(1.15);
    }
}

/* ======================================================
   5. PROGRESS TRACKER BAR
====================================================== */
.gita-chat-progress-wrap {
    background: #F1F5F9;
    padding: 6px 14px 5px;
    border-bottom: 1px solid #E2E8F0;
}

.gita-chat-progress-bar-bg {
    width: 100%;
    height: 4px;
    background: #E2E8F0;
    border-radius: 10px;
    overflow: hidden;
}

.gita-chat-progress-bar-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--gita-bot-primary) 0%, var(--gita-bot-primary-light) 50%, var(--gita-bot-accent) 100%);
    border-radius: 10px;
    transition: width 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.gita-chat-step-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 4px;
    font-size: 10.5px;
    font-weight: 600;
    color: var(--gita-bot-text-muted);
}

.gita-chat-step-percent {
    color: var(--gita-bot-primary);
}

/* ======================================================
   6. MESSAGES CONTAINER & BUBBLES
====================================================== */
.gita-chatbot-body {
    flex: 1;
    overflow-y: auto;
    padding: 12px 12px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    background: #F8FAFC;
    scroll-behavior: smooth;
}

/* Custom modern scrollbar */
.gita-chatbot-body::-webkit-scrollbar {
    width: 6px;
}

.gita-chatbot-body::-webkit-scrollbar-track {
    background: transparent;
}

.gita-chatbot-body::-webkit-scrollbar-thumb {
    background: #CBD5E1;
    border-radius: 10px;
}

.gita-chatbot-body::-webkit-scrollbar-thumb:hover {
    background: #94A3B8;
}

.gita-chat-messages {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

/* Single Message Item */
.gita-msg-item {
    display: flex;
    gap: 10px;
    max-width: 88%;
    animation: gitaMsgSlideIn 0.32s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes gitaMsgSlideIn {
    from {
        opacity: 0;
        transform: translateY(10px) scale(0.98);
    }

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

/* Bot Message */
.gita-msg-item.bot {
    align-self: flex-start;
}

.gita-msg-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--gita-bot-primary), var(--gita-bot-primary-light));
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    box-shadow: 0 2px 6px rgba(9, 46, 160, 0.2);
    overflow: hidden;
}

.gita-msg-avatar img {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
    background: #ffffff;
}

.gita-msg-content-wrap {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.gita-msg-bubble {
    background: #ffffff;
    color: var(--gita-bot-text);
    padding: 8px 12px;
    border-radius: 4px 13px 13px 13px;
    font-size: 12.5px;
    line-height: 1.44;
    box-shadow: 0 1px 6px rgba(0, 0, 0, 0.03), 0 0 0 1px #E2E8F0;
    word-break: break-word;
}

.gita-msg-bubble p {
    margin: 0 0 6px 0;
}

.gita-msg-bubble p:last-child {
    margin-bottom: 0;
}

.gita-msg-bubble strong {
    color: var(--gita-bot-primary);
    font-weight: 600;
}

.gita-msg-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1px 2px 0 2px;
    gap: 8px;
}

.gita-msg-time {
    font-size: 10px;
    color: #94A3B8;
    padding-left: 2px;
}

.gita-msg-action-slot {
    display: flex;
    align-items: center;
    justify-content: flex-end;
}

/* User Message */
.gita-msg-item.user {
    align-self: flex-end;
    flex-direction: row-reverse;
}

.gita-msg-item.user .gita-msg-content-wrap {
    align-items: flex-end;
}

.gita-msg-item.user .gita-msg-bubble {
    background: linear-gradient(135deg, var(--gita-bot-primary) 0%, var(--gita-bot-primary-light) 100%);
    color: #ffffff;
    border-radius: 16px 4px 16px 16px;
    box-shadow: 0 4px 14px rgba(9, 46, 160, 0.25);
}

.gita-msg-item.user .gita-msg-time {
    text-align: right;
    padding-right: 2px;
}

/* Success Card Message (Step 7) */
.gita-msg-success-card {
    background: linear-gradient(135deg, #ECFDF5 0%, #D1FAE5 100%);
    border: 1px solid #A7F3D0;
    border-radius: 14px;
    padding: 16px;
    text-align: center;
    color: #065F46;
    margin-top: 6px;
}

.gita-msg-success-icon {
    width: 44px;
    height: 44px;
    background: #10B981;
    color: #ffffff;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 10px;
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.35);
}

.gita-msg-success-icon svg {
    display: block;
}

.gita-msg-success-card h4 {
    margin: 0 0 6px 0;
    font-size: 16px;
    font-weight: 700;
    color: #064E3B;
}

.gita-msg-success-card p {
    margin: 0;
    font-size: 13px;
    line-height: 1.4;
    color: #047857;
}

/* ======================================================
   7. TYPING INDICATOR
====================================================== */
.gita-typing-indicator {
    display: none;
    align-items: center;
    gap: 8px;
    align-self: flex-start;
    animation: gitaMsgSlideIn 0.25s ease forwards;
}

.gita-typing-indicator.is-active {
    display: flex;
}

.gita-typing-avatar {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: var(--gita-bot-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

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

.gita-typing-bubble {
    background: #ffffff;
    border: 1px solid #E2E8F0;
    border-radius: 16px;
    padding: 9px 14px;
    display: flex;
    align-items: center;
    gap: 4px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.04);
}

.gita-typing-bubble span {
    width: 6px;
    height: 6px;
    background: #94A3B8;
    border-radius: 50%;
    animation: gitaTypingDot 1.4s infinite ease-in-out;
}

.gita-typing-bubble span:nth-child(1) {
    animation-delay: 0s;
}

.gita-typing-bubble span:nth-child(2) {
    animation-delay: 0.2s;
}

.gita-typing-bubble span:nth-child(3) {
    animation-delay: 0.4s;
}

@keyframes gitaTypingDot {

    0%,
    60%,
    100% {
        transform: translateY(0);
        opacity: 0.4;
    }

    30% {
        transform: translateY(-5px);
        opacity: 1;
        background: var(--gita-bot-primary-light);
    }
}

/* ======================================================
   8. QUICK REPLY OPTIONS (STEP 4 & STEP 5)
====================================================== */
.gita-chat-options {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-top: 4px;
    animation: gitaMsgSlideIn 0.35s ease forwards;
}

/* Categories Compact Flex Pills (Step 4) */
.gita-categories-grid,
.gita-categories-flex {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    width: 100%;
    margin-top: 3px;
}

.gita-category-card,
.gita-category-pill {
    background: #ffffff;
    border: 1px solid #CBD5E1;
    border-radius: 20px;
    padding: 6px 11px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    cursor: pointer;
    font-size: 11.5px;
    font-weight: 600;
    line-height: 1.2;
    color: var(--gita-bot-text);
    transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.03);
    text-align: left;
    outline: none;
    box-sizing: border-box;
    white-space: nowrap;
    flex: 0 1 auto;
}

.gita-category-card:hover,
.gita-category-pill:hover {
    border-color: var(--gita-bot-primary-light);
    background: #EFF6FF;
    color: var(--gita-bot-primary);
    transform: translateY(-1px);
    box-shadow: 0 3px 8px rgba(46, 142, 255, 0.14);
}

.gita-category-card:active,
.gita-category-pill:active {
    transform: scale(0.96);
}

.gita-category-card .gita-cat-icon,
.gita-category-pill .gita-cat-icon {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: #EFF6FF;
    color: var(--gita-bot-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: all 0.2s ease;
}

.gita-category-card .gita-cat-icon svg,
.gita-category-pill .gita-cat-icon svg {
    width: 10px;
    height: 10px;
    display: block;
}

.gita-category-card:hover .gita-cat-icon,
.gita-category-pill:hover .gita-cat-icon {
    background: var(--gita-bot-primary);
    color: #ffffff;
}

.gita-category-card .gita-cat-title,
.gita-category-pill .gita-cat-title {
    white-space: nowrap;
}

/* Sub-Services Grid / Chips (Step 5) */
.gita-services-chips-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
    margin-top: 2px;
}

.gita-service-chip {
    background: #ffffff;
    border: 1px solid #CBD5E1;
    border-radius: 20px;
    padding: 7px 13px;
    font-size: 12.5px;
    font-weight: 500;
    color: var(--gita-bot-text);
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.02);
    outline: none;
}

.gita-service-chip:hover {
    background: var(--gita-bot-primary);
    border-color: var(--gita-bot-primary);
    color: #ffffff;
    transform: translateY(-2px);
    box-shadow: 0 4px 10px rgba(9, 46, 160, 0.2);
}

.gita-service-chip:active {
    transform: scale(0.95);
}

/* Category Pill: 'Other / Custom Requirement' */
.gita-category-pill.is-other {
    background: linear-gradient(135deg, #FAF5FF 0%, #F3E8FF 100%);
    border-color: #D8B4FE;
    color: #6B21A8;
}

.gita-category-pill.is-other:hover {
    background: linear-gradient(135deg, #F3E8FF 0%, #E9D5FF 100%);
    border-color: #A855F7;
    color: #581C87;
    box-shadow: 0 4px 14px rgba(168, 85, 247, 0.2);
}

.gita-category-pill.is-other .gita-cat-icon {
    background: #E9D5FF;
    color: #7E22CE;
}

.gita-category-pill.is-other:hover .gita-cat-icon {
    background: #7E22CE;
    color: #ffffff;
}

/* Persistent Micro Prev Button - Located on bottom right of the bot message bubble */
.gita-chatbot-root button.gita-back-btn,
.gita-chatbot-root .gita-back-btn,
.gita-back-btn {
    display: inline-flex !important;
    align-items: center !important;
    gap: 2px !important;
    background: #ffffff !important;
    border: 1px solid #CBD5E1 !important;
    border-radius: 4px !important;
    padding: 1px 5px !important;
    font-size: 8.5px !important;
    font-weight: 500 !important;
    color: #64748B !important;
    cursor: pointer !important;
    transition: all 0.15s ease !important;
    outline: none !important;
    line-height: 1.2 !important;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.03) !important;
    letter-spacing: 0.1px !important;
    height: auto !important;
    min-height: 0 !important;
    vertical-align: middle !important;
    white-space: nowrap !important;
    flex-shrink: 0 !important;
}

.gita-chatbot-root .gita-back-btn *,
.gita-chatbot-root .gita-back-btn span,
.gita-back-btn span,
.gita-back-btn .gita-prev-text {
    font-size: 8.5px !important;
    font-weight: 500 !important;
    color: #64748B !important;
    line-height: 1.2 !important;
    display: inline-block !important;
}

.gita-chatbot-root .gita-back-btn .gita-prev-arrow,
.gita-back-btn .gita-prev-arrow {
    font-size: 9px !important;
    font-weight: 700 !important;
    line-height: 1 !important;
    margin-right: 1px !important;
    color: #94A3B8 !important;
}

.gita-chatbot-root .gita-back-btn:hover,
.gita-back-btn:hover {
    background: #F8FAFC !important;
    border-color: #94A3B8 !important;
    color: #0F172A !important;
}

.gita-chatbot-root .gita-back-btn:hover *,
.gita-back-btn:hover span {
    color: #0F172A !important;
}

/* Smart Contextual Search Suggestions Container */
.gita-suggestions-wrapper {
    display: flex;
    flex-direction: column;
    gap: 8px;
    width: 100%;
}

.gita-suggestions-title {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.6px;
    color: var(--gita-bot-primary);
    display: flex;
    align-items: center;
    gap: 5px;
    margin-top: 2px;
}

.gita-suggestions-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
}

.gita-suggestion-chip {
    background: #EFF6FF;
    border: 1.5px solid #BFDBFE;
    border-radius: 20px;
    padding: 7px 14px;
    font-size: 12.5px;
    font-weight: 600;
    color: var(--gita-bot-primary);
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
    display: inline-flex;
    align-items: center;
    gap: 6px;
    outline: none;
}

.gita-suggestion-chip:hover {
    background: var(--gita-bot-primary);
    border-color: var(--gita-bot-primary);
    color: #ffffff;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(9, 46, 160, 0.25);
}

.gita-proceed-custom-btn {
    background: #ffffff;
    border: 1.5px dashed #94A3B8;
    border-radius: 12px;
    padding: 9px 13px;
    font-size: 12px;
    font-weight: 600;
    color: #334155;
    cursor: pointer;
    text-align: left;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    outline: none;
    width: 100%;
}

.gita-proceed-custom-btn:hover {
    background: #F8FAFC;
    border-color: var(--gita-bot-primary-light);
    color: var(--gita-bot-primary);
    transform: translateY(-1px);
}

.gita-proceed-custom-btn strong {
    color: var(--gita-bot-primary);
}

/* 2-Option Friendly Resolution (Select Category vs Type Specific Requirement) */
.gita-choice-actions {
    display: flex;
    flex-direction: column;
    gap: 8px;
    width: 100%;
    margin-top: 4px;
    animation: gitaMsgSlideIn 0.3s ease forwards;
}

.gita-choice-btn {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 9px;
    padding: 10px 14px;
    border-radius: 12px;
    font-size: 12.5px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.22s cubic-bezier(0.16, 1, 0.3, 1);
    outline: none;
    text-align: left;
    width: 100%;
    box-sizing: border-box;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}

.gita-choice-btn.is-category {
    background: #EFF6FF;
    border: 1.5px solid #93C5FD;
    color: var(--gita-bot-primary);
}

.gita-choice-btn.is-category:hover {
    background: var(--gita-bot-primary);
    border-color: var(--gita-bot-primary);
    color: #ffffff;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(9, 46, 160, 0.22);
}

.gita-choice-btn.is-custom {
    background: #FAF5FF;
    border: 1.5px solid #D8B4FE;
    color: #7E22CE;
}

.gita-choice-btn.is-custom:hover {
    background: #7E22CE;
    border-color: #7E22CE;
    color: #ffffff;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(126, 34, 206, 0.22);
}

.gita-choice-btn.is-switch {
    background: #ECFDF5;
    border: 1.5px solid #6EE7B7;
    color: #047857;
}

.gita-choice-btn.is-switch:hover {
    background: #059669;
    border-color: #059669;
    color: #ffffff;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(5, 150, 105, 0.25);
}

.gita-choice-btn:active {
    transform: scale(0.97);
}


/* ======================================================
   9. INPUT FOOTER
====================================================== */
.gita-chatbot-footer {
    background: #ffffff;
    padding: 10px 14px;
    border-top: 1px solid #E2E8F0;
    display: flex;
    flex-direction: column;
}

.gita-chat-form {
    margin: 0;
}

.gita-input-wrapper {
    display: flex;
    align-items: center;
    position: relative;
    background: #F8FAFC;
    border: 1.5px solid #CBD5E1;
    border-radius: 24px;
    padding: 3px 4px 3px 14px;
    transition: all 0.2s ease;
}

.gita-input-wrapper:focus-within {
    border-color: var(--gita-bot-primary-light);
    background: #ffffff;
    box-shadow: 0 0 0 3px rgba(46, 142, 255, 0.2);
}

.gita-chat-input {
    flex: 1;
    border: none;
    background: transparent;
    padding: 8px 4px;
    font-size: 13.5px;
    color: var(--gita-bot-text);
    outline: none;
    min-width: 0;
    text-align: left !important;
    text-indent: 0 !important;
    margin-left: 0 !important;
}

/* Ensure no unwanted left padding/spacing leaks into standard text inputs */
.gita-input-wrapper:not(.has-iti) .gita-chat-input,
.gita-chatbot-root .gita-input-wrapper:not(.has-iti) input.gita-chat-input,
.gita-chatbot-root input.gita-chat-input:not([type="tel"]) {
    padding-left: 4px !important;
    padding-right: 4px !important;
    margin-left: 0 !important;
    text-indent: 0 !important;
    text-align: left !important;
}

.gita-chat-input::placeholder {
    color: #94A3B8;
    font-size: 13px;
    text-align: left !important;
}

.gita-chat-send-btn {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--gita-bot-primary) 0%, var(--gita-bot-primary-light) 100%);
    border: none;
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
    flex-shrink: 0;
    outline: none;
    padding: 0;
}

.gita-chat-send-btn svg {
    display: block;
    transform: translateX(1px);
}

.gita-chat-send-btn:hover {
    transform: scale(1.06);
    box-shadow: 0 3px 10px rgba(46, 142, 255, 0.4);
}

.gita-chat-send-btn:active {
    transform: scale(0.92);
}

.gita-chat-send-btn:disabled {
    background: #CBD5E1;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

/* WhatsApp-Style Voice Typing Microphone Button */
.gita-chat-mic-btn {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: transparent;
    border: none;
    color: #64748B;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
    flex-shrink: 0;
    outline: none;
    padding: 0;
    margin-right: 4px;
    position: relative;
    -webkit-tap-highlight-color: transparent;
}

.gita-chat-mic-btn svg {
    display: block;
    transition: transform 0.2s ease, stroke 0.2s ease;
}

.gita-chat-mic-btn:hover {
    background: #E2E8F0;
    color: var(--gita-bot-primary);
    transform: scale(1.06);
}

.gita-chat-mic-btn:active {
    transform: scale(0.92);
}

.gita-chat-mic-btn:disabled {
    opacity: 0.35;
    cursor: not-allowed;
    pointer-events: none;
    transform: none;
}

/* WhatsApp-style Active Voice Recording State */
.gita-chat-mic-btn.is-recording {
    background: #EF4444 !important;
    color: #FFFFFF !important;
    animation: gitaMicPulse 1.4s infinite cubic-bezier(0.4, 0, 0.2, 1);
}

.gita-chat-mic-btn.is-recording svg {
    stroke: #FFFFFF !important;
    animation: gitaMicVibrate 0.35s infinite ease-in-out alternate;
}

.gita-input-wrapper.is-listening {
    border-color: #EF4444 !important;
    box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.2) !important;
    background: #FFF5F5 !important;
}

@keyframes gitaMicPulse {
    0% {
        box-shadow: 0 0 0 0 rgba(239, 68, 68, 0.7);
        transform: scale(1.02);
    }
    60% {
        box-shadow: 0 0 0 10px rgba(239, 68, 68, 0);
        transform: scale(1.12);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(239, 68, 68, 0);
        transform: scale(1.02);
    }
}

@keyframes gitaMicVibrate {
    0% {
        transform: rotate(-4deg) scale(1);
    }
    100% {
        transform: rotate(4deg) scale(1.08);
    }
}

/* ======================================================
   9b. MICROPHONE PERMISSION SCREEN MODAL
====================================================== */
.gita-mic-modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(11, 25, 44, 0.72);
    backdrop-filter: blur(3px);
    -webkit-backdrop-filter: blur(3px);
    z-index: 999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
    animation: gitaFadeIn 0.2s ease-out;
}

.gita-mic-modal-card {
    background: #FFFFFF;
    border-radius: 18px;
    padding: 22px 18px 18px;
    box-shadow: 0 20px 45px rgba(0, 0, 0, 0.35);
    max-width: 320px;
    width: 100%;
    text-align: center;
    box-sizing: border-box;
    border: 1px solid #E2E8F0;
    animation: gitaPopIn 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.gita-mic-modal-icon {
    width: 52px;
    height: 52px;
    border-radius: 50%;
    background: #FEE2E2;
    color: #EF4444;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 12px;
    box-shadow: 0 0 0 6px rgba(239, 68, 68, 0.12);
}

.gita-mic-modal-title {
    font-size: 15px;
    font-weight: 700;
    color: #0B192C;
    margin: 0 0 6px 0;
    line-height: 1.3;
}

.gita-mic-modal-desc {
    font-size: 12.5px;
    color: #64748B;
    margin: 0 0 14px 0;
    line-height: 1.45;
}

.gita-mic-modal-steps {
    text-align: left;
    background: #F8FAFC;
    border-radius: 12px;
    padding: 10px 12px;
    margin-bottom: 16px;
    border: 1px solid #E2E8F0;
}

.gita-mic-step {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    font-size: 11.5px;
    color: #334155;
    margin-bottom: 8px;
    line-height: 1.35;
}

.gita-mic-step:last-child {
    margin-bottom: 0;
}

.gita-step-num {
    background: linear-gradient(135deg, var(--gita-bot-primary) 0%, var(--gita-bot-primary-light) 100%);
    color: #FFFFFF;
    font-size: 10px;
    font-weight: 700;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    margin-top: 1px;
}

.gita-mic-modal-actions {
    display: flex;
    gap: 8px;
    align-items: center;
}

.gita-btn-mic-retry {
    flex: 1;
    background: linear-gradient(135deg, var(--gita-bot-primary) 0%, var(--gita-bot-primary-light) 100%);
    color: #FFFFFF;
    border: none;
    padding: 10px 14px;
    border-radius: 20px;
    font-size: 12.5px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    transition: all 0.2s ease;
    box-shadow: 0 4px 12px rgba(46, 142, 255, 0.3);
}

.gita-btn-mic-retry:hover {
    transform: scale(1.03);
    box-shadow: 0 6px 16px rgba(46, 142, 255, 0.45);
}

.gita-btn-mic-retry:active {
    transform: scale(0.97);
}

.gita-btn-mic-close {
    background: #F1F5F9;
    color: #64748B;
    border: none;
    padding: 10px 16px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
}

.gita-btn-mic-close:hover {
    background: #E2E8F0;
    color: #1E293B;
}

.gita-mic-modal-card.is-shaking {
    animation: gitaShake 0.4s ease-in-out;
}

@keyframes gitaPopIn {
    0% {
        opacity: 0;
        transform: scale(0.85);
    }
    100% {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes gitaShake {
    0%, 100% { transform: translateX(0); }
    20%, 60% { transform: translateX(-6px); }
    40%, 80% { transform: translateX(6px); }
}

/* ======================================================
   10. MOBILE & RESPONSIVE DESIGN
====================================================== */
@media (max-width: 480px) {
    .gita-chatbot-window {
        bottom: 0;
        right: 0;
        width: 100vw;
        max-width: 100vw;
        height: 100dvh;
        max-height: 100dvh;
        border-radius: 0;
        border: none;
    }

    .gita-chatbot-launcher {
        bottom: 16px;
        right: 16px;
        width: 58px;
        height: 58px;
    }

    .gita-launcher-g-logo {
        width: 42px;
        height: 42px;
    }

    .gita-chatbot-teaser {
        right: 16px;
        bottom: 84px;
        width: calc(100vw - 32px);
    }
}

/* ======================================================
   11. INTL-TEL-INPUT CUSTOM ADAPTATION FOR CHATBOT
====================================================== */
.gita-chatbot-root .iti {
    flex: 1;
    min-width: 0;
    width: 100%;
    position: relative;
    display: flex;
    align-items: center;
}

.gita-chatbot-root .gita-input-wrapper.has-iti .iti input.gita-chat-input,
.gita-chatbot-root .iti input.gita-chat-input[type="tel"] {
    width: 100% !important;
    padding-left: 80px !important;
    font-size: 12.5px;
}

.gita-chatbot-root .iti--separate-dial-code .iti__selected-flag {
    background-color: transparent;
    border-radius: 20px 0 0 20px;
    padding: 0 4px 0 8px;
    display: flex;
    align-items: center;
    gap: 3px;
}

.gita-chatbot-root .iti__selected-dial-code {
    font-size: 12px;
    font-weight: 600;
    color: #1E293B;
    margin-left: 2px;
}

.gita-chatbot-root .iti__country-list {
    bottom: 100% !important;
    top: auto !important;
    margin-bottom: 8px !important;
    max-height: 200px !important;
    border-radius: 12px !important;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2) !important;
    border: 1px solid #E2E8F0 !important;
    z-index: 999999 !important;
    width: 290px !important;
    max-width: calc(100vw - 40px) !important;
}