/* ===== LiveGood AI Desktop Help Box ===== */

#lg-ai-box {
    position: fixed;
    right: 20px;
    bottom: 20px;
    width: 360px;
    max-width: calc(100vw - 32px);
    height: 480px;
    display: flex;
    flex-direction: column;
    background: #ffffff;
    border: 1px solid #dbe7d8;
    border-radius: 22px;
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.18);
    overflow: hidden;
    z-index: 9999;
}

.lg-ai-box-header {
    padding: 18px 18px 14px 18px;
    background: linear-gradient(135deg, #ecfdf3 0%, #ffffff 100%);
    border-bottom: 1px solid #e5e7eb;
}

.lg-ai-box-eyebrow {
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: #15803d;
    margin-bottom: 8px;
}

.lg-ai-box-title {
    margin: 0 0 8px 0;
    font-size: 22px;
    line-height: 1.15;
    font-weight: 800;
    color: #111827;
}

.lg-ai-box-subtitle {
    margin: 0;
    font-size: 14px;
    line-height: 1.45;
    color: #4b5563;
}

.lg-ai-quick-prompts {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    padding: 12px 16px 0 16px;
    background: #fff;
}

.lg-ai-quick-btn {
    border: 1px solid #d1fae5;
    background: #f0fdf4;
    color: #166534;
    padding: 8px 10px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
}

#lg-ai-messages {
    flex: 1;
    overflow-y: auto;
    padding: 14px 16px;
    background: #ffffff;
}

.lg-ai-msg {
    margin-bottom: 10px;
    padding: 10px 12px;
    border-radius: 14px;
    font-size: 14px;
    line-height: 1.45;
    max-width: 88%;
    word-wrap: break-word;
}

.lg-ai-msg.ai {
    background: #f3f4f6;
    color: #111827;
}

.lg-ai-msg.user {
    margin-left: auto;
    background: #dcfce7;
    color: #14532d;
}

.lg-ai-link {
    color: #15803d;
    text-decoration: underline;
    font-weight: 600;
}

.lg-ai-input-row {
    display: flex;
    gap: 8px;
    padding: 12px;
    border-top: 1px solid #e5e7eb;
    background: #fff;
}

.lg-ai-input-row input,
#lg-ai-text {
    flex: 1;
    min-width: 0;
    border: 1px solid #d1d5db;
    border-radius: 12px;
    padding: 12px 14px;
    font-size: 14px;
    outline: none;
}

.lg-ai-input-row button,
#lg-ai-send {
    border: none;
    background: #22c55e;
    color: #fff;
    border-radius: 12px;
    padding: 0 16px;
    font-weight: 700;
    cursor: pointer;
    flex: 0 0 auto;
}

@media (max-width: 900px) {
    #lg-ai-box {
        right: 12px;
        left: 12px;
        bottom: 12px;
        width: auto;
        max-width: none;
        height: 68vh;
    }

    .lg-ai-box-title {
        font-size: 18px;
    }

    .lg-ai-box-subtitle {
        font-size: 13px;
    }
}

#lg-ai-mobile-launcher{
    display:none;
}

#lg-ai-close{
    display:none;
}

@media (max-width:900px){

    #lg-ai-box{
        display:none !important;
        right:12px;
        left:12px;
        bottom:12px;
        width:auto;
        max-width:none;
        height:68vh;
    }

    #lg-ai-box.is-open{
        display:flex !important;
    }

    #lg-ai-mobile-launcher{
        display:flex !important;
        position:fixed;
        right:16px;
        bottom:16px;
        width:60px;
        height:60px;
        border-radius:50%;
        background:#22c55e;
        color:#fff;
        font-size:30px;
        font-weight:800;
        align-items:center;
        justify-content:center;
        box-shadow:0 12px 30px rgba(0,0,0,0.22);
        z-index:10000;
        cursor:pointer;
    }

    #lg-ai-close{
        display:block;
        position:absolute;
        top:10px;
        right:12px;
        border:none;
        background:transparent;
        color:#6b7280;
        font-size:28px;
        line-height:1;
        cursor:pointer;
    }

    .lg-ai-box-header{
        position:relative;
    }
}