/* 问答社区 — 骨架屏布局 */

.ask-skel-topic-list {
    padding: 4px 0;
}

.ask-skel-topic-item {
    padding: 18px 20px;
    border-bottom: 1px solid var(--jn-line, #eef0f4);
}

.ask-skel-topic-item:last-child {
    border-bottom: none;
}

.ask-skel-topic-row {
    display: flex;
    align-items: flex-start;
    gap: 14px;
}

.ask-skel-topic-row .ask-skel-avatar {
    width: 48px;
    height: 48px;
    flex-shrink: 0;
}

.ask-skel-topic-main {
    flex: 1;
    min-width: 0;
    padding-top: 2px;
}

.ask-skel-topic-side {
    flex-shrink: 0;
    width: 52px;
    padding-top: 4px;
}

.ask-skel-topic-compact .ask-skel-topic-item {
    padding: 16px 0;
}

.ask-skel-post-detail {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.ask-skel-post-card,
.ask-skel-reply-card {
    background: var(--jn-card, #fff);
    border: 1px solid var(--jn-line, #eef0f4);
    border-radius: var(--jn-radius-l, 12px);
    padding: 24px;
}

.ask-skel-post-title {
    height: 28px;
    width: 68%;
    margin-bottom: 16px;
}

.ask-skel-post-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 22px;
}

.ask-skel-post-meta .el-skeleton__item {
    width: 88px;
    height: 18px;
}

.ask-skel-post-content .el-skeleton__item {
    margin-top: 12px;
}

.ask-skel-post-content .el-skeleton__item:first-child {
    margin-top: 0;
}

.ask-skel-reply-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 18px;
    padding-bottom: 14px;
    border-bottom: 1px solid var(--jn-line, #eef0f4);
}

.ask-skel-reply-bar-title {
    width: 140px;
    height: 20px;
}

.ask-skel-reply-bar-btn {
    width: 88px;
    height: 32px;
    border-radius: 4px;
}

.ask-skel-reply-item {
    padding: 18px 0;
    border-bottom: 1px solid var(--jn-line, #eef0f4);
}

.ask-skel-reply-item:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.ask-skel-reply-row {
    display: flex;
    gap: 12px;
}

.ask-skel-reply-row .ask-skel-avatar {
    width: 44px;
    height: 44px;
    flex-shrink: 0;
}

.ask-skel-reply-main {
    flex: 1;
    min-width: 0;
    padding-top: 2px;
}

.ask-skel-reply-foot {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 12px;
}

.ask-skel-reply-foot-time {
    width: 96px;
    height: 14px;
    margin-right: 4px;
}

.ask-skel-author-panel {
    background: var(--jn-card, #fff);
    border-radius: var(--jn-radius-l, 12px);
    overflow: hidden;
    border: 1px solid var(--jn-line, #eef0f4);
}

.ask-skel-author-cover {
    height: 88px;
}

.ask-skel-author-body {
    padding: 0 20px 20px;
    margin-top: -36px;
}

.ask-skel-author-avatar {
    width: 72px;
    height: 72px;
    margin: 0 auto 14px;
    display: block;
}

.ask-skel-author-name {
    width: 120px;
    height: 20px;
    margin: 0 auto 10px;
}

.ask-skel-author-bio {
    margin: 0 auto;
}

.ask-skel-author-bio .el-skeleton__item {
    margin: 0 auto;
}

.ask-skel-author-stats {
    display: flex;
    justify-content: space-around;
    margin-top: 20px;
    padding-top: 16px;
    border-top: 1px solid var(--jn-line, #eef0f4);
}

.ask-skel-author-stat {
    width: 48px;
    height: 36px;
}

/* —— 个人空间骨架 —— */

.ask-skel-space-layout {
    /* 复用 .ask-jn-space-layout 的 flex 布局 */
}

.ask-skel-space-author .el-skeleton {
    display: block;
}

.ask-skel-space-cover {
    display: block;
    width: 100%;
    height: 120px;
}

.ask-skel-space-profile {
    text-align: center;
}

.ask-skel-space-avatar {
    width: 88px !important;
    height: 88px !important;
    margin: 0 auto 12px;
    display: block;
}

.ask-skel-space-name {
    width: 128px;
    height: 20px;
    margin: 0 auto 10px;
}

.ask-skel-space-bio {
    width: 78%;
    height: 14px;
    margin: 0 auto;
}

.ask-skel-space-stats {
    display: flex;
    flex-wrap: wrap;
    gap: 12px 0;
    margin-top: 18px;
}

.ask-skel-space-stat {
    flex: 0 0 50%;
    text-align: center;
}

.ask-skel-space-stat-num {
    width: 36px;
    height: 18px;
    margin: 0 auto 6px;
}

.ask-skel-space-stat-label {
    width: 52px;
    height: 12px;
    margin: 0 auto;
}

.ask-skel-space-actions {
    margin-top: 16px;
}

.ask-skel-space-btn {
    flex: 1;
    height: 36px;
    border-radius: var(--jn-radius-s, 6px);
}

.ask-skel-space-btn.is-plain {
    opacity: 0.72;
}

.ask-skel-space-main .el-skeleton {
    display: block;
}

.ask-skel-space-tabs {
    padding: 0 20px;
    min-height: 49px;
    border-bottom: 1px solid var(--jn-line, #eef0f4);
    background: var(--jn-box-bg, #f7f8fa);
    box-sizing: border-box;
}

.ask-skel-space-tabs .el-skeleton {
    display: block;
    padding: 14px 0;
}

.ask-skel-space-tabs-inner {
    display: flex;
    align-items: center;
    gap: 20px;
}

.ask-skel-space-tab {
    width: 72px;
    height: 16px;
    border-radius: 4px;
    flex-shrink: 0;
}

.ask-skel-space-topic-wrap {
    background: var(--jn-card, #fff);
}

.ask-skel-space-topic-row {
    padding: 22px 24px;
    border-bottom: 1px solid var(--jn-line, #eef0f4);
    box-sizing: border-box;
}

.ask-skel-space-topic-row:last-child {
    border-bottom: none;
}

.ask-skel-space-topic-inner {
    display: flex;
    align-items: center;
    gap: 16px;
}

.ask-skel-space-topic-content {
    flex: 1;
    min-width: 0;
}

.ask-skel-space-topic-title {
    width: 72%;
    height: 18px;
    margin-bottom: 10px;
}

.ask-skel-space-topic-meta {
    width: 42%;
    height: 14px;
}

.ask-skel-space-topic-stats {
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 8px;
    width: 56px;
}

.ask-skel-space-topic-stat {
    width: 100%;
    height: 14px;
}

.ask-skel-space-reply-list .ask-skel-space-reply-item {
    padding: 16px 20px;
    border-bottom: 1px solid var(--jn-line, #eef0f4);
    box-sizing: border-box;
}

.ask-skel-space-reply-list .ask-skel-space-reply-item:last-child {
    border-bottom: none;
}

.ask-skel-space-reply-title {
    width: 58%;
    height: 18px;
    margin-bottom: 12px;
}

.ask-skel-space-reply-line {
    width: 100%;
    height: 14px;
    margin-bottom: 8px;
}

.ask-skel-space-reply-line.is-short {
    width: 72%;
    margin-bottom: 12px;
}

.ask-skel-space-reply-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.ask-skel-space-reply-time {
    width: 72px;
    height: 12px;
}

.ask-skel-space-reply-link {
    width: 56px;
    height: 12px;
}

.ask-skel-follow-item {
    padding: 14px 0;
    border-bottom: 1px solid var(--jn-line, #eef0f4);
}

.ask-skel-follow-item:last-child {
    border-bottom: none;
}

.ask-skel-follow-inner {
    display: flex;
    align-items: center;
    gap: 12px;
}

.ask-skel-follow-item .ask-skel-avatar {
    width: 44px;
    height: 44px;
    flex-shrink: 0;
}

.ask-skel-follow-main {
    flex: 1;
    min-width: 0;
}

.ask-skel-follow-name {
    width: 36%;
    height: 16px;
    margin-bottom: 8px;
}

.ask-skel-follow-time {
    width: 52%;
    height: 12px;
}

.ask-skel-follow-btn {
    width: 72px;
    height: 28px;
    flex-shrink: 0;
    border-radius: 4px;
}

.ask-skel-follow-list--space .ask-skel-follow-item {
    padding: 16px 20px;
}

.ask-skel-follow-list--space .ask-skel-follow-item:first-child {
    padding-top: 12px;
}

.ask-skel-post-form {
    padding: 8px 0;
}

.ask-skel-form-head {
    width: 120px;
    height: 28px;
    margin-bottom: 20px;
}

.ask-skel-form-label {
    width: 48px;
    height: 14px;
    margin-bottom: 10px;
}

.ask-skel-form-field {
    height: 40px;
    margin-bottom: 22px;
    border-radius: 4px;
}

.ask-skel-form-editor {
    height: 280px;
    margin-bottom: 24px;
    border-radius: 6px;
}

.ask-skel-form-actions {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
}

.ask-skel-form-btn {
    width: 96px;
    height: 36px;
    border-radius: 4px;
}

.ask-skel-post-vote {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 16px;
    padding-top: 14px;
    border-top: 1px solid var(--jn-line, #eef0f4);
}

.ask-skel-vote-btn {
    width: 54px;
    height: 30px;
    border-radius: 16px;
}

.ask-skel-category-tabs {
    flex: 1;
    min-width: 0;
    margin-bottom: -1px;
    padding: 0 8px 0 16px;
    overflow: hidden;
}

.ask-skel-category-tabs-inner {
    display: flex;
    align-items: stretch;
    flex-wrap: nowrap;
    white-space: nowrap;
}

.ask-skel-category-tab {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    height: 48px;
    margin: 0 28px 0 0;
    padding: 0 2px;
    box-sizing: border-box;
    border-bottom: 3px solid transparent;
}

.ask-skel-category-tab.is-active {
    border-bottom-color: rgba(32, 107, 231, 0.28);
}

.ask-skel-category-tab-bar {
    display: block;
    height: 14px;
    border-radius: 4px;
    background: linear-gradient(90deg, #f0f2f5 25%, #e4e7ed 37%, #f0f2f5 63%);
    background-size: 400% 100%;
    animation: ask-skel-shimmer 1.4s ease infinite;
}

.ask-skel-category-tab.is-active .ask-skel-category-tab-bar {
    background: linear-gradient(90deg, rgba(32, 107, 231, 0.1) 25%, rgba(32, 107, 231, 0.2) 37%, rgba(32, 107, 231, 0.1) 63%);
    background-size: 400% 100%;
}

.ask-skel-sidebar-actions .el-skeleton,
.ask-skel-search-widget .el-skeleton {
    display: block;
}

.ask-skel-sidebar-btn {
    width: 100%;
    height: 40px;
    margin-bottom: 10px;
    border-radius: var(--jn-radius-s, 6px);
}

.ask-skel-sidebar-btn:last-child {
    margin-bottom: 0;
}

.ask-skel-widget-head-bar {
    display: inline-block;
    width: 72px;
    height: 15px;
    border-radius: 3px;
    vertical-align: middle;
    background: linear-gradient(90deg, #f0f2f5 25%, #e4e7ed 37%, #f0f2f5 63%);
    background-size: 400% 100%;
    animation: ask-skel-shimmer 1.4s ease infinite;
}

.ask-skel-search-widget {
    margin-bottom: 20px;
}

.ask-skel-search-widget .widget-title {
    border-bottom: 1px solid var(--jn-line, #eef0f4);
}

.ask-skel-search-form {
    display: flex;
    padding: 12px 16px 16px;
}

.ask-skel-search-form .el-skeleton {
    display: block;
    width: 100%;
}

.ask-skel-search-row {
    display: flex;
    align-items: stretch;
    width: 100%;
}

.ask-skel-search-input {
    flex: 1;
    min-width: 0;
    height: 38px;
    border-radius: var(--jn-radius-m, 6px) 0 0 var(--jn-radius-m, 6px);
}

.ask-skel-search-btn {
    width: 44px;
    height: 38px;
    flex-shrink: 0;
    border-radius: 0 var(--jn-radius-m, 6px) var(--jn-radius-m, 6px) 0;
}

.ask-skel-news-list {
    margin-bottom: 20px;
}

.ask-skel-news-list .widget-title {
    border-bottom: 1px solid var(--jn-line, #eef0f4);
}

.ask-skel-news-list .widget-news-list {
    list-style: none;
    margin: 0;
    padding: 4px 16px 8px;
}

.ask-skel-news-list .widget-news-list li {
    margin: 0;
    padding: 12px 0;
    border-bottom: 1px dashed var(--jn-line, #eef0f4);
}

.ask-skel-news-list .widget-news-list li:last-child {
    border-bottom: none;
}

.ask-skel-news-link {
    display: block;
}

.ask-skel-news-link .el-skeleton {
    display: block;
}

.ask-skel-news-line {
    display: block;
    width: 88%;
    height: 14px;
    border-radius: 3px;
}

.ask-skel-news-date {
    display: block;
    width: 42%;
    height: 12px;
    margin-top: 6px;
    border-radius: 3px;
}

.ask-skel-news-list .widget-news-list li:nth-child(1) .ask-skel-news-line {
    width: 92%;
}

.ask-skel-news-list .widget-news-list li:nth-child(2) .ask-skel-news-line {
    width: 78%;
}

.ask-skel-news-list .widget-news-list li:nth-child(3) .ask-skel-news-line {
    width: 86%;
}

.ask-skel-news-list .widget-news-list li:nth-child(4) .ask-skel-news-line {
    width: 70%;
}

.ask-skel-news-list .widget-news-list li:nth-child(5) .ask-skel-news-line {
    width: 82%;
}

.ask-skel-news-list .widget-news-list li:nth-child(odd) .ask-skel-news-date {
    width: 38%;
}

.ask-skel-news-list .widget-news-list li:nth-child(even) .ask-skel-news-date {
    width: 44%;
}

.ask-skel-news-more-wrap {
    border-top: 1px solid var(--jn-line, #eef0f4);
    padding: 12px 16px 14px;
}

.ask-skel-news-more-wrap .el-skeleton {
    display: flex;
    justify-content: center;
}

.ask-skel-news-more {
    width: 72px;
    height: 13px;
    border-radius: 3px;
}

@keyframes ask-skel-shimmer {
    0% {
        background-position: 100% 50%;
    }
    100% {
        background-position: 0 50%;
    }
}

.ask-skel-index-sidebar > .widget + .widget,
.ask-skel-topic-sidebar > .widget + .widget,
.ask-skel-topic-sidebar > .ask-skel-author-panel + .widget {
    margin-top: 16px;
}

@media (max-width: 768px) {
    .ask-skel-category-tabs {
        padding-left: 12px;
    }

    .ask-skel-category-tab {
        height: 44px;
        margin-right: 20px;
    }

    .ask-skel-category-tab-bar {
        height: 13px;
    }

    .ask-skel-space-tabs {
        padding: 0 16px;
        gap: 14px;
        overflow-x: auto;
    }

    .ask-skel-space-topic-row {
        padding: 16px;
    }

    .ask-skel-space-topic-inner {
        flex-wrap: wrap;
    }

    .ask-skel-space-topic-stats {
        flex-direction: row;
        width: 100%;
        justify-content: flex-start;
        margin-top: 4px;
    }

    .ask-skel-space-topic-stat {
        width: 48px;
    }

    .ask-skel-space-reply-list .ask-skel-space-reply-item,
    .ask-skel-follow-list--space .ask-skel-follow-item {
        padding: 16px;
    }

    .ask-skel-post-card,
    .ask-skel-reply-card {
        padding: 18px 16px;
    }

    .ask-skel-topic-item {
        padding: 16px;
    }

    .ask-skel-form-editor {
        height: 220px;
    }
}
