/* AISummary Styles - 适配 Momo 博客主题 */
.aisummary-container {
    background: var(--button-hover-color);
    border-radius: 0.75rem;
    padding: 1rem;
    line-height: 1.5;
    border: 1px solid var(--button-border-color);
    margin: 1.25rem 0;
    box-shadow: 0 2px 8px var(--shadow-color);
    transition: all 0.3s ease;
}

.aisummary-container:hover {
    box-shadow: 0 4px 12px var(--shadow-color);
    transform: translateY(-2px);
}

@media screen and (max-width: 768px) {
    .aisummary-container {
        margin-top: 1.5rem;
        padding: 0.875rem;
        border-radius: 0.5rem;
    }
}

@media screen and (max-width: 480px) {
    .aisummary-container {
        margin-top: 1rem;
        padding: 0.75rem;
    }
}

.aisummary-title {
    display: flex;
    color: var(--text-color-70);
    border-radius: 0.5rem;
    align-items: center;
    padding: 0 0.75rem;
    cursor: default;
    user-select: none;
    font-family: "Noto Serif SC", "Times New Roman", "STZhongsong", serif;
}

.aisummary-title-text {
    font-weight: 600;
    margin-left: 0.625rem;
    line-height: 1.2;
    letter-spacing: -0.01em;
    color: var(--text-color);
}

.aisummary-explanation {
    margin-top: 0.875rem;
    padding: 0.75rem 1rem;
    background: var(--bg-color);
    border-radius: 0.5rem;
    border: 1px solid var(--button-border-color);
    font-size: 0.9375rem;
    line-height: 1.6;
    display: block;
    position: relative;
    overflow: visible;
    max-height: none !important;
    will-change: contents;
    color: var(--text-color);
}

.aisummary-explanation::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0;
    height: 100%;
    width: 3px;
    background: var(--link-color);
    border-radius: 0 2px 2px 0;
}

.aisummary-tag {
    font-size: 0.75rem;
    background-color: var(--link-color);
    color: #ffffff;
    font-weight: 600;
    border-radius: 0.25rem;
    margin-left: auto;
    line-height: 1;
    padding: 0.375rem 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: 0.3s;
}

.aisummary-tag:hover {
    background: var(--link-color);
    opacity: 0.9;
    transform: scale(1.05);
}

[data-theme="dark"] .aisummary-tag {
    color: #ffffff;
}

.aisummary-title-icon {
    width: 1.25rem;
    height: 1.25rem;
    display: flex;
    align-items: center;
    justify-content: center;
}

.aisummary-title-icon svg {
    width: 1.25rem;
    height: 1.25rem;
    fill: var(--link-color);
}

.aisummary-title-icon svg path {
    fill: var(--link-color);
}

.aisummary-disclaimer {
    font-size: 0.75rem;
    color: var(--text-color-70);
    margin-top: 0.5rem;
    padding: 0 0.5rem;
}

.blinking-cursor {
    background-color: var(--link-color);
    width: 0.625rem;
    height: 1rem;
    display: inline-block;
    vertical-align: middle;
    animation: blinking-cursor 0.5s infinite;
    -webkit-animation: blinking-cursor 0.5s infinite;
    margin-left: 0.25rem;
    border-radius: 1px;
}

@keyframes blinking-cursor {
    0% {
        opacity: 1;
    }
    40% {
        opacity: 1;
    }
    50% {
        opacity: 0;
    }
    90% {
        opacity: 0;
    }
    100% {
        opacity: 1;
    }
}

/* 可访问性：减少动态效果时关闭光标闪烁 */
@media (prefers-reduced-motion: reduce) {
    .blinking-cursor {
        animation: none;
        -webkit-animation: none;
    }
}

/*
 参考：https://www.konoxin.top/posts/db7b3418
*/
