/* AI 詢問按鈕 - 共用樣式（置於 flex-nav iconshare 內）
 *
 * 覆蓋原因：icon_share2.css 中 .communtity li 設定了
 *   width: 35px; height: 35px; border-radius: 50%;
 * 這會把所有 li 壓成小圓形，導致膠囊按鈕的文字與 icon 溢出。
 * 以下透過 .ai-ask-li 重設 width/height/border-radius/overflow，
 * 讓此 li 改為自適應寬度的膠囊容器。
 */

/* li 容器：覆蓋固定尺寸與圓形 */
.ai-ask-li {
    /* 覆蓋 .communtity li 的 width/height/border-radius */
    width: auto !important;
    height: auto !important;
    border-radius: 20px !important;
    background-color: transparent !important;
    background-image: none !important;
    overflow: visible;
    display: inline-flex;
    align-items: center;
    margin-left: 10px;
    vertical-align: middle;
    animation: aiAskFadeIn 0.5s ease-out both;
}

/* 膠囊按鈕本體 */
.ai-ask-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    height: 44px;
    padding: 2px 22px 0;
    font-size: 1.3rem;
    font-weight: 700;
    font-family: "jf-openhuninn", "cwTeXYen", "Noto Sans TC", "Microsoft JhengHei", "Arial Rounded MT Bold", sans-serif;
    line-height: 1;
    color: #00a896 !important;
    background: #fff;
    border: 2px solid #00a896;
    border-radius: 20px;
    text-decoration: none;
    white-space: nowrap;
    overflow: hidden;
    box-shadow: 0 2px 6px rgba(0, 168, 150, 0.15);
    transition: transform 0.25s ease, box-shadow 0.25s ease,
                background 0.25s ease, color 0.25s ease;
}

.ai-ask-btn:hover,
.ai-ask-btn:focus {
    color: #fff !important;
    background: #00a896;
    transform: translateY(-1px) scale(1.05);
    box-shadow: 0 4px 14px rgba(0, 168, 150, 0.35);
    text-decoration: none;
}

.ai-ask-btn:active {
    transform: translateY(0) scale(0.97);
    box-shadow: 0 1px 4px rgba(0, 168, 150, 0.2);
}

.ai-ask-btn .ai-icon {
    font-size: 1.5rem;
    line-height: 1;
    flex-shrink: 0;
}

@keyframes aiAskFadeIn {
    from { opacity: 0; transform: scale(0.9); }
    to   { opacity: 1; transform: scale(1); }
}

/* RWD */
@media (max-width: 575px) {
    .ai-ask-li {
        margin-left: 6px;
    }
    .ai-ask-btn {
        height: 36px;
        padding: 0 12px;
        font-size: 1rem;
    }
}
