.ai-help-wrap {
    position: relative;
    display: inline-flex;
}

.ai-help-trigger {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    border: 1px solid #cbd5e1;
    border-radius: 9999px;
    background: #f8fafc;
    color: #0f172a;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    padding: 0.3rem 0.65rem;
    transition: all 0.18s ease;
}

.ai-help-trigger:hover {
    transform: translateY(-1px);
    box-shadow: 0 10px 20px rgba(15, 23, 42, 0.14);
    border-color: #67e8f9;
}

.ai-help-icon {
    width: 0.9rem;
    height: 0.9rem;
    display: inline-flex;
}

.ai-help-popover {
    position: absolute;
    z-index: 40;
    top: calc(100% + 8px);
    right: 0;
    width: min(460px, 90vw);
    border: 1px solid #cbd5e1;
    border-radius: 14px;
    background: #ffffff;
    box-shadow: 0 22px 48px rgba(15, 23, 42, 0.2);
    padding: 0.6rem;
}

.ai-help-popover[hidden] {
    display: none;
}

.ai-help-popover-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 12px;
    color: #0f172a;
    margin-bottom: 0.4rem;
}

.ai-help-close {
    border: none;
    background: transparent;
    cursor: pointer;
    color: #64748b;
    font-size: 18px;
    line-height: 1;
}

.ai-help-controls {
    display: flex;
    gap: 0.45rem;
    align-items: center;
}

.ai-help-input {
    flex: 1;
    border: 1px solid #cbd5e1;
    border-radius: 10px;
    padding: 0.45rem 0.6rem;
    font-size: 13px;
}

.ai-help-ask {
    border: 1px solid #0f172a;
    border-radius: 10px;
    padding: 0.4rem 0.65rem;
    background: #0f172a;
    color: #fff;
    font-size: 12px;
    font-weight: 700;
}

.ai-help-output {
    margin-top: 0.55rem;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    background: #f8fafc;
    min-height: 82px;
    max-height: 270px;
    overflow: auto;
    padding: 0.55rem;
    font-size: 12px;
    color: #0f172a;
}
