/* 雾寻图片工坊 · 前台样式（尽量复用子比主题 main.css 变量，自动适配暗色模式） */

/* ---------- 文章入口卡片 ---------- */
.fogxun-entry {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
    margin: 26px 0;
    padding: 18px 20px;
    background: var(--main-bg-color, #fff);
    border: 1px solid var(--main-border-color, #e7ebf9);
    border-radius: var(--main-radius, 10px);
    box-shadow: 0 12px 34px -26px var(--main-shadow, rgba(30, 40, 100, .55));
}

.fogxun-entry-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 auto;
    width: 44px;
    height: 44px;
    border-radius: 12px;
    color: #fff;
    background: linear-gradient(135deg, #4f6bff, #a56bff);
    box-shadow: 0 10px 20px -12px rgba(90, 80, 255, .75);
}

.fogxun-entry-icon svg {
    width: 24px;
    height: 24px;
    fill: none;
    stroke: currentColor;
}

/* 线条图标：避免被主题的 svg{fill:currentColor} 填成色块 */
.fogxun-entry-icon svg .fx-star,
.fogxun-float svg .fx-star {
    fill: currentColor;
    stroke: none;
}

.fogxun-entry-txt {
    display: flex;
    flex-direction: column;
    gap: 4px;
    flex: 1 1 240px;
    min-width: 0;
}

.fogxun-entry-tag {
    align-self: flex-start;
    padding: 0 8px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 700;
    line-height: 1.7;
    color: #4f6bff;
    background: rgba(79, 107, 255, .10);
}

.fogxun-entry-title {
    font-size: 15px;
    font-weight: 700;
    line-height: 1.5;
    color: var(--key-color, #1b2450);
}

.fogxun-entry-desc {
    font-size: 12.5px;
    line-height: 1.6;
    color: var(--muted-2-color, #6b7793);
}

/* ---------- 按钮 ---------- */
.fogxun-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 10px 18px;
    border-radius: 999px;
    font-size: 13px;
    font-weight: 700;
    line-height: 1.4;
    white-space: nowrap;
    text-decoration: none !important;
    color: #fff !important;
    background: linear-gradient(120deg, #4f6bff, #a56bff);
    box-shadow: 0 12px 24px -14px rgba(110, 90, 255, .8);
    transition: transform .18s, box-shadow .18s;
}

.fogxun-btn:hover {
    color: #fff !important;
    transform: translateY(-1px);
    box-shadow: 0 16px 28px -14px rgba(110, 90, 255, .85);
}

.fogxun-btn-block {
    display: flex;
    width: 100%;
}

/* ---------- 侧栏小工具 ---------- */
.fogxun-widget-desc {
    margin: 0 0 10px;
    font-size: 12.5px;
    line-height: 1.7;
    color: var(--muted-2-color, #6b7793);
}

/* ---------- 悬浮入口（默认收起为图标，悬停展开文字） ---------- */
.fogxun-float {
    position: fixed;
    right: 18px;
    bottom: 92px;
    z-index: 9997;
    display: inline-flex;
    align-items: center;
    gap: 0;
    height: 46px;
    padding: 0 14px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 700;
    text-decoration: none !important;
    color: var(--key-color, #1b2450);
    background: var(--main-bg-color, #fff);
    border: 1px solid var(--main-border-color, #e7ebf9);
    box-shadow: 0 14px 34px -16px rgba(30, 40, 100, .6);
    transition: transform .18s, color .18s, padding .18s;
}

.fogxun-float svg {
    width: 18px;
    height: 18px;
    flex: 0 0 18px;
    color: #4f6bff;
    fill: none;
    stroke: currentColor;
}

.fogxun-float-text {
    max-width: 0;
    margin-left: 0;
    opacity: 0;
    overflow: hidden;
    white-space: nowrap;
    transition: max-width .26s ease, opacity .16s ease, margin-left .26s ease;
}

.fogxun-float:hover,
.fogxun-float:focus-visible {
    padding: 0 16px;
}

.fogxun-float:hover .fogxun-float-text,
.fogxun-float:focus-visible .fogxun-float-text {
    max-width: 120px;
    margin-left: 7px;
    opacity: 1;
}

.fogxun-float:focus-visible {
    outline: 2px solid rgba(79, 107, 255, .55);
    outline-offset: 2px;
}

.fogxun-float:active {
    transform: scale(.97);
}

.fogxun-float:hover {
    color: var(--theme-color, #4f6bff);
    transform: translateY(-2px);
}

.fogxun-float-bl {
    left: 18px;
    right: auto;
}

.fogxun-float-mobile {
    display: none;
}

/* ---------- 短代码内嵌 ---------- */
.fogxun-embed {
    margin: 22px 0;
    overflow: hidden;
    background: var(--main-bg-color, #fff);
    border: 1px solid var(--main-border-color, #e7ebf9);
    border-radius: var(--main-radius, 12px);
    box-shadow: 0 14px 40px -30px var(--main-shadow, rgba(30, 40, 100, .6));
}

.fogxun-embed-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 10px 14px;
    font-size: 12px;
    color: var(--muted-2-color, #6b7793);
    border-bottom: 1px solid var(--main-border-color, #e7ebf9);
}

.fogxun-embed-bar b {
    font-size: 13px;
    color: var(--key-color, #1b2450);
}

.fogxun-embed-frame {
    display: block;
    width: 100%;
    max-height: 90vh;
    border: 0;
    background: #f4f6fd;
}

.fogxun-embed-foot {
    padding: 8px 14px;
    font-size: 12px;
    text-align: right;
    border-top: 1px solid var(--main-border-color, #e7ebf9);
}

.fogxun-embed-foot a {
    text-decoration: none;
    color: var(--theme-color, #4f6bff);
}

@media (max-width: 768px) {
    .fogxun-entry {
        padding: 14px;
        gap: 12px;
    }

    .fogxun-entry-icon {
        width: 38px;
        height: 38px;
        border-radius: 10px;
    }

    .fogxun-entry-icon svg {
        width: 21px;
        height: 21px;
    }

    .fogxun-entry .fogxun-btn {
        width: 100%;
    }

    .fogxun-float {
        right: 14px;
        bottom: 84px;
        height: 42px;
        padding: 0 12px;
    }

    .fogxun-float:hover,
    .fogxun-float:focus-visible {
        padding: 0 12px;
    }

    .fogxun-float-text {
        display: none;
    }

    .fogxun-float-bl {
        left: 14px;
        right: auto;
    }

    .fogxun-float-mobile {
        display: inline-flex;
    }

    .fogxun-embed-frame {
        max-height: 82vh;
    }
}
