:root {
            /* Brand Colors */
            --brand-deep: #3C0753;
            --brand-plum: #720455;
            --brand-rasp: #910A67;
            --brand-orange: #ff6c2c;
            --brand-orange-hover: #e8591e;
            
            /* UI Colors */
            --bg-site: #170822; /* Just for demo background */
            --bg-modal: #f9fafb;
            --bg-panel: #ffffff;
            --text-main: #111827;
            --text-muted: #6b7280;
            --border-light: #e5e7eb;
            
            /* Typography */
            --font-ui: 'Inter', sans-serif;
            --font-display: 'Space Grotesk', sans-serif;
            --font-mono: 'IBM Plex Mono', monospace;
            
            /* Shadows & Effects */
            --shadow-soft: 0 4px 20px rgba(0, 0, 0, 0.05);
            --shadow-hover: 0 10px 25px -5px rgba(60, 7, 83, 0.15);
            --radius-lg: 16px;
            --radius-md: 12px;
            --radius-sm: 8px;
        }
        /* =========================================
           Floating Action Button (FAB)
           ========================================= */
        .ai-fab-container {
            position: fixed;
            bottom: 30px;
            left: 30px; /* Moved to right for modern standard, can be left if preferred */
            display: flex;
            align-items: flex-end;
            gap: 16px;
            z-index: 9999;
            flex-direction: row-reverse;
        }

        /* Styling for the custom image icon */
.ai-fab-image {
    width: 60px;  /* Adjust this size if you want the robot bigger or smaller */
    height: auto;
    object-fit: contain; /* Ensures the image doesn't get stretched or squished */
    transition: transform 0.3s ease;
}

/* Optional: Add a slight spin or scale effect when hovering over the button */
.ai-fab-btn:hover .ai-fab-image {
    transform: scale(1.1);
}

        .ai-fab-tooltip {
            background: #ffffff;
            padding: 12px 20px;
            border-radius: var(--radius-md);
            box-shadow: 0 10px 25px rgba(0,0,0,0.1);
            position: relative;
            transform-origin: right bottom;
            animation: bounceIn 0.6s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards;
            opacity: 0;
        }

        .ai-fab-tooltip::after {
          content: '';
          position: absolute;
          left: -8px;
          bottom: 20px;
          border-width: 8px 8px 8px 0px;
          border-style: solid;
          border-color: transparent #ffffff transparent transparent;
        }

        .ai-fab-tooltip h4 {
            font-family: var(--font-display);
            color: var(--brand-deep);
            font-size: 15px;
            margin-bottom: 4px;
        }

        .ai-fab-tooltip p {
            font-size: 12px;
            color: var(--text-muted);
        }

        .ai-fab-btn {
            width: 64px;
            height: 64px;
            background: transparent;
            border: none;
            border-radius: 50%;
            cursor: pointer;
            /* box-shadow: 0 8px 24px rgba(255, 108, 44, 0.4); */
            display: flex;
            align-items: center;
            justify-content: center;
            transition: all 0.3s ease;
            position: relative;
        }

        .ai-fab-btn:hover {
            transform: scale(1.05) translateY(-4px);
            box-shadow: 0 12px 30px rgba(255, 108, 44, 0.6);
            background: var(--brand-orange-hover);
        }

        .ai-fab-btn svg {
            width: 32px;
            height: 32px;
            fill: #ffffff;
        }

        /* Pulse ring */
        .ai-fab-btn::before {
            content: '';
            position: absolute;
            inset: -4px;
            border-radius: 50%;
            border: 2px solid var(--brand-orange);
            animation: pulse-ring 2s infinite cubic-bezier(0.215, 0.61, 0.355, 1);
            opacity: 0;
        }

        @keyframes pulse-ring {
            0% { transform: scale(0.8); opacity: 0.5; }
            80%, 100% { opacity: 0; transform: scale(1.4); }
        }

        @keyframes bounceIn {
            0% { opacity: 0; transform: scale(0.9) translateX(20px); }
            100% { opacity: 1; transform: scale(1) translateX(0); }
        }


        /* =========================================
           Modal Overlay & Layout
           ========================================= */
        .ai-overlay {
            position: fixed;
            inset: 0;
            background: rgba(23, 8, 34, 0.6);
            backdrop-filter: blur(8px);
            z-index: 10000;
            display: flex;
            align-items: center;
            justify-content: center;
            padding: 24px;
            opacity: 0;
            visibility: hidden;
            transition: all 0.3s ease;
        }

        .ai-overlay.is-open {
            opacity: 1;
            visibility: visible;
        }

        .ai-modal {
            width: 100%;
            max-width: 1300px;
            height: 90vh;
            max-height: 850px;
            background: var(--bg-modal);
            border-radius: var(--radius-lg);
            display: flex;
            flex-direction: column;
            overflow: hidden;
            box-shadow: 0 24px 50px rgba(0,0,0,0.3);
            transform: translateY(20px) scale(0.98);
            transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
        }

        .ai-overlay.is-open .ai-modal {
            transform: translateY(0) scale(1);
        }

        /* Header */
        .ai-header {
            background: linear-gradient(135deg, var(--brand-deep) 0%, var(--brand-plum) 100%);
            padding: 16px 24px;
            display: flex;
            justify-content: space-between;
            align-items: center;
            color: #ffffff;
            border-bottom: 3px solid var(--brand-orange);
            flex-shrink: 0;
        }

        .ai-header-left {
            display: flex;
            align-items: center;
            gap: 16px;
        }

        .ai-header-icon {
            width: 40px;
            height: 40px;
            background: rgba(255,255,255,0.1);
            border-radius: var(--radius-sm);
            display: flex;
            align-items: center;
            justify-content: center;
        }

        .ai-header-icon svg { width: 24px; height: 24px; fill: var(--brand-orange); }

        .ai-header-title { font-family: var(--font-display); font-size: 18px; font-weight: 700; display: flex; align-items: center; gap: 8px;}
        .ai-header-badge { background: var(--brand-orange); color: #fff; font-size: 10px; font-family: var(--font-mono); padding: 2px 6px; border-radius: 4px; font-weight: bold;}
        .ai-header-sub { font-size: 12px; opacity: 0.8; margin-top: 2px;}

        .ai-header-actions { display: flex; gap: 12px; }
        .ai-btn-ghost {
            background: rgba(255,255,255,0.1);
            border: 1px solid rgba(255,255,255,0.2);
            color: #fff;
            padding: 8px 16px;
            border-radius: var(--radius-sm);
            font-size: 13px;
            cursor: pointer;
            display: flex;
            align-items: center;
            gap: 8px;
            transition: all 0.2s;
        }
        .ai-btn-ghost:hover { background: rgba(255,255,255,0.2); }
        .ai-btn-icon { padding: 8px; width: 36px; height: 36px; justify-content: center;}

        /* Main Split Layout */
        .ai-layout {
            display: grid;
            grid-template-columns: 380px 1fr;
            flex: 1;
            overflow: hidden;
        }

        /* =========================================
           Left Panel: Chat & Input
           ========================================= */
        .ai-sidebar {
            background: var(--bg-panel);
            border-right: 1px solid var(--border-light);
            display: flex;
            flex-direction: column;
            overflow: hidden;
            position: relative;
        }

        .ai-chat-history {
            flex: 1;
            overflow-y: auto;
            padding: 24px;
            display: flex;
            flex-direction: column;
            gap: 20px;
        }

        /* Custom Scrollbar */
        .ai-chat-history::-webkit-scrollbar, .ai-results-area::-webkit-scrollbar { width: 6px; }
        .ai-chat-history::-webkit-scrollbar-track, .ai-results-area::-webkit-scrollbar-track { background: transparent; }
        .ai-chat-history::-webkit-scrollbar-thumb, .ai-results-area::-webkit-scrollbar-thumb { background: #d1d5db; border-radius: 4px; }

        .ai-bubble-wrap { display: flex; flex-direction: column; max-width: 85%; }
        .ai-bubble-wrap.user { align-self: flex-end; align-items: flex-end; }
        .ai-bubble-wrap.bot { align-self: flex-start; align-items: flex-start; }

        .ai-bubble-label { font-size: 11px; font-weight: 600; color: var(--text-muted); margin-bottom: 4px; padding: 0 4px; }
        
        .ai-bubble {
            padding: 12px 16px;
            font-size: 14px;
            line-height: 1.5;
            box-shadow: var(--shadow-soft);
        }
        
        .ai-bubble.user {
            background: var(--brand-deep);
            color: #ffffff;
            border-radius: 16px 16px 0 16px;
        }

        .ai-bubble.bot {
            background: #f3f4f6;
            color: var(--text-main);
            border-radius: 16px 16px 16px 0;
            border: 1px solid var(--border-light);
        }

        /* Input Area */
        .ai-input-area {
            padding: 20px 24px;
            background: #ffffff;
            border-top: 1px solid var(--border-light);
            box-shadow: 0 -4px 20px rgba(0,0,0,0.02);
        }

        .ai-input-wrapper {
    display: flex;
    align-items: center; /* Changed from flex-end to keep button perfectly centered */
    background: #f9fafb;
    border: 2px solid var(--border-light);
    border-radius: var(--radius-md);
    padding: 6px 8px 6px 12px; /* Adjusted padding */
    transition: all 0.3s ease;
}

.ai-input-wrapper:focus-within {
    border-color: var(--brand-rasp);
    background: #ffffff;
    box-shadow: 0 0 0 4px rgba(145, 10, 103, 0.1);
}

.ai-input {
    flex: 1;
    border: none;
    background: transparent;
    resize: none;
    font-family: var(--font-ui);
    font-size: 14px;
    line-height: 24px;
    padding: 8px 12px 8px 0; /* Extra right padding so text doesn't hit the button */
    color: var(--text-main);
    max-height: 120px;
    min-height: 40px; /* Increased to prevent placeholder wrapping/clipping */
    height: 40px;
    outline: none;
    overflow-y: hidden; /* Hides the ugly up/down scroll arrows */
}

.ai-input::placeholder { color: #9ca3af; }

.ai-send-btn {
    background: var(--brand-orange);
    color: white;
    border: none;
    width: 40px; /* Slightly larger for a better click target */
    height: 40px;
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s;
    flex-shrink: 0;
    margin: 0; /* Removed margin-bottom */
}

        .ai-send-btn:hover { background: var(--brand-orange-hover); transform: translateY(-1px); }
        .ai-send-btn:disabled { background: #d1d5db; cursor: not-allowed; transform: none; }
        .ai-send-btn svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2.5; stroke-linecap: round; stroke-linejoin: round;}

        /* Typing Indicator */
        .typing-indicator { display: flex; gap: 4px; padding: 8px 4px; align-items: center;}
        .typing-indicator span { width: 6px; height: 6px; background: var(--brand-rasp); border-radius: 50%; animation: typing 1.4s infinite ease-in-out both; }
        .typing-indicator span:nth-child(1) { animation-delay: -0.32s; }
        .typing-indicator span:nth-child(2) { animation-delay: -0.16s; }
        @keyframes typing { 0%, 80%, 100% { transform: scale(0); } 40% { transform: scale(1); } }

        /* =========================================
           Right Panel: Results Area
           ========================================= */
        .ai-results-area {
            background: var(--bg-modal);
            padding: 32px;
            overflow-y: auto;
            position: relative;
        }

        /* Idle State / Suggestions */
        .ai-idle-state {
            max-width: 800px;
            margin: 0 auto;
        }
        .ai-idle-title {
            font-family: var(--font-display);
            font-size: 24px;
            color: var(--brand-deep);
            margin-bottom: 8px;
        }
        .ai-idle-sub { color: var(--text-muted); margin-bottom: 32px; font-size: 15px;}
        
        .ai-suggestions-grid {
            display: grid;
            grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
            gap: 16px;
        }

        .ai-suggestion-card {
            background: #ffffff;
            border: 1px solid var(--border-light);
            padding: 20px;
            border-radius: var(--radius-md);
            cursor: pointer;
            transition: all 0.2s ease;
            box-shadow: var(--shadow-soft);
        }

        .ai-suggestion-card:hover {
            border-color: var(--brand-orange);
            transform: translateY(-2px);
            box-shadow: var(--shadow-hover);
        }

        .ai-suggestion-card h4 { font-size: 15px; color: var(--brand-deep); margin-bottom: 6px; }
        .ai-suggestion-card p { font-size: 13px; color: var(--text-muted); }

        /* Results Header */
        .ai-results-header {
            display: flex;
            justify-content: space-between;
            align-items: center;
            margin-bottom: 24px;
            padding-bottom: 16px;
            border-bottom: 1px solid var(--border-light);
            display: none; /* Hidden initially */
        }

        .ai-results-count {
            font-family: var(--font-display);
            font-size: 20px;
            font-weight: 700;
            color: var(--brand-deep);
        }
        .ai-results-count span { color: var(--brand-orange); }

        .ai-match-tags {
            display: flex;
            gap: 8px;
            align-items: center;
            font-family: var(--font-mono);
            font-size: 11px;
            color: var(--text-muted);
            margin-top: 8px;
        }
        .ai-match-tag {
            background: rgba(255, 108, 44, 0.1);
            color: var(--brand-orange);
            padding: 4px 8px;
            border-radius: 4px;
            font-weight: 600;
            border: 1px solid rgba(255, 108, 44, 0.2);
        }

        /* Server Cards List */
        .ai-server-list {
            display: flex;
            flex-direction: column;
            gap: 16px;
            display: none; /* Hidden initially */
        }

        .ai-server-card {
            background: #ffffff;
            border: 1px solid var(--border-light);
            border-radius: var(--radius-md);
            display: flex;
            overflow: hidden;
            transition: all 0.3s ease;
            box-shadow: var(--shadow-soft);
        }

        .ai-server-card:hover {
            border-color: var(--brand-plum);
            box-shadow: var(--shadow-hover);
            transform: translateY(-2px);
        }

        /* Visual LED Strip */
        .ai-server-status {
            width: 0px;
            background: var(--brand-deep);
            flex-shrink: 0;
            position: relative;
        }
        .ai-server-status::after {
            content: '';
            position: absolute;
            top: 20px;
            left: 50%;
            transform: translateX(-50%);
            width: 4px;
            height: 4px;
            border-radius: 50%;
            background: #10b981; /* Green LED */
            box-shadow: 0 0 8px #10b981;
        }

        .ai-server-main {
            padding: 24px;
            flex: 1;
        }

        .ai-server-top {
            display: flex;
            justify-content: space-between;
            margin-bottom: 12px;
        }

        .ai-server-sn { font-family: var(--font-mono); font-size: 12px; color: var(--text-muted); font-weight: 600;}
        .ai-server-loc { display: flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 500; color: var(--text-muted); }
        .ai-server-loc svg { width: 14px; height: 14px; fill: currentColor;}

        .ai-server-title-row {
            display: flex;
            align-items: center;
            gap: 12px;
            margin-bottom: 8px;
        }

        .ai-server-title {
            font-family: var(--font-display);
            font-size: 20px;
            font-weight: 700;
            color: var(--text-main);
            margin: 0;
        }

        .ai-badge-highram {
            background: rgba(145, 10, 103, 0.1);
            color: var(--brand-rasp);
            font-family: var(--font-mono);
            font-size: 10px;
            padding: 2px 8px;
            border-radius: 4px;
            font-weight: 700;
        }

        .ai-server-cpu {
            font-size: 13px;
            color: var(--text-muted);
            margin-bottom: 20px;
            display: flex;
            align-items: center;
            gap: 6px;
        }
        .ai-server-cpu svg { width: 14px; height: 14px; stroke: currentColor; fill: none; stroke-width: 2;}

        /* Specs Grid */
        .ai-specs-grid {
            display: grid;
            grid-template-columns: repeat(3, 1fr);
            gap: 16px;
            background: #f9fafb;
            border: 1px solid var(--border-light);
            border-radius: var(--radius-sm);
            padding: 16px;
            margin-bottom: 16px;
        }

        .ai-spec-item { display: flex; flex-direction: column; gap: 4px;}
        .ai-spec-label { font-family: var(--font-mono); font-size: 11px; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.05em;}
        .ai-spec-value { font-family: var(--font-mono); font-size: 14px; font-weight: 700; color: var(--text-main); }

        .ai-server-features {
            display: flex;
            gap: 8px;
            flex-wrap: wrap;
        }
        .ai-feature-pill {
            display: flex;
            align-items: center;
            gap: 4px;
            font-size: 12px;
            font-weight: 500;
            color: #059669; /* Green text */
            background: #ecfdf5; /* Light green bg */
            padding: 4px 10px;
            border-radius: 12px;
        }
        .ai-feature-pill svg { width: 12px; height: 12px; stroke: currentColor; stroke-width: 2; fill: none;}

        /* Pricing Column */
        .ai-server-action {
            width: 220px;
            padding: 24px;
            display: flex;
            flex-direction: column;
            align-items: center;
            justify-content: center;
            border-left: 1px dashed var(--border-light);
            background: #fafafa;
        }

        .ai-price-wrap {
            text-align: center;
            margin-bottom: 16px;
        }

        .ai-price {
            font-family: var(--font-display);
            font-size: 36px;
            font-weight: 700;
            color: var(--brand-orange);
            line-height: 1;
            display: flex;
            align-items: flex-start;
            justify-content: center;
        }
        .ai-price-currency { font-size: 20px; margin-top: 4px; margin-right: 2px;}
        .ai-price-term { font-family: var(--font-mono); font-size: 12px; color: var(--text-muted); text-transform: uppercase; margin-top: 4px; letter-spacing: 0.05em;}

        .ai-btn-primary {
            width: 100%;
            background: var(--brand-deep);
            color: #ffffff;
            border: none;
            padding: 12px;
            border-radius: var(--radius-sm);
            font-family: var(--font-ui);
            font-size: 14px;
            font-weight: 600;
            cursor: pointer;
            transition: all 0.2s;
            text-align: center;
            text-decoration: none;
        }
        .ai-btn-primary:hover {
            background: var(--brand-plum);
            transform: translateY(-2px);
            box-shadow: 0 4px 12px rgba(114, 4, 85, 0.3);
        }

        /* =========================================
           Responsive Design
           ========================================= */
        @media (max-width: 1024px) {
            .ai-layout { grid-template-columns: 1fr; }
            .ai-results-area { display: none; } /* On smaller screens, results take over or are hidden initially */
            .ai-layout.show-results .ai-sidebar { display: none; }
            .ai-layout.show-results .ai-results-area { display: block; }
            
            /* Add a back button for mobile results */
            .ai-mobile-back { display: block; margin-bottom: 16px; background: none; border: none; color: var(--brand-deep); font-weight: 600; font-size: 14px; cursor: pointer; display: flex; align-items: center; gap: 8px;}
            .ai-mobile-back svg { width: 16px; height: 16px; fill: currentColor;}
        }

        @media (min-width: 1025px) {
            .ai-mobile-back { display: none; }
        }

        @media (max-width: 768px) {
            .ai-server-card { flex-direction: column; }
            .ai-server-status { width: 100%; height: 6px; }
            .ai-server-status::after { top: 50%; left: 16px; transform: translateY(-50%); }
            .ai-server-action { width: 100%; border-left: none; border-top: 1px dashed var(--border-light); padding: 20px; flex-direction: row; justify-content: space-between; align-items: center;}
            .ai-price-wrap { margin-bottom: 0; text-align: left;}
            .ai-price { justify-content: flex-start; }
            .ai-btn-primary { width: auto; padding: 12px 24px; }
            .ai-specs-grid { grid-template-columns: 1fr; gap: 12px; }
        }