/* ========== 文章管理样式 ========== */

/* 容器 */
.articles-container {
    padding: 24px;
}

/* 工具栏 */
.articles-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding: 16px 20px;
    background: #f8f9fa;
    border-radius: 12px;
    gap: 16px;
}

.articles-toolbar-left {
    display: flex;
    align-items: center;
    gap: 16px;
}

.articles-toolbar h3 {
    font-size: 16px;
    color: #202124;
    margin: 0;
}

.articles-count {
    background: rgba(91, 127, 255, 0.1);
    color: var(--business-color, #5B7FFF);
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 13px;
    font-weight: 500;
}

.articles-toolbar-right {
    display: flex;
    gap: 8px;
}

/* 平台筛选栏 */
.platform-filter-bar {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    background-color: #f8f9fa;
    border-radius: 8px;
    margin-bottom: 16px;
    border: 1px solid #e8eaed;
    flex-wrap: wrap;
}

.platform-filter-label {
    font-size: 13px;
    color: #5f6368;
    font-weight: 500;
    white-space: nowrap;
}

.platform-btn-group {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.platform-btn {
    padding: 6px 14px;
    font-size: 13px;
    color: #5f6368;
    background: white;
    border: 1px solid #dadce0;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s;
}

.platform-btn:hover {
    border-color: var(--business-color, #5B7FFF);
    color: var(--business-color, #5B7FFF);
    background: rgba(91, 127, 255, 0.1);
}

.platform-btn.active {
    background: var(--business-color, #5B7FFF);
    border-color: var(--business-color, #5B7FFF);
    color: white;
}

.platform-btn.disabled {
    opacity: 0.5;
    cursor: not-allowed;
    text-decoration: line-through;
}

.platform-count {
    display: inline-block;
    min-width: 18px;
    height: 18px;
    line-height: 18px;
    padding: 0 5px;
    margin-left: 6px;
    font-size: 11px;
    font-weight: 600;
    text-align: center;
    background: rgba(0, 0, 0, 0.08);
    border-radius: 9px;
}

.platform-btn.active .platform-count {
    background: rgba(255, 255, 255, 0.25);
}

.platform-select-large {
    padding: 12px 16px;
    border: 1px solid #dadce0;
    border-radius: 8px;
    font-size: 14px;
    background: white;
    cursor: pointer;
    width: 100%;
}

/* 表格容器 */
.articles-table-container {
    border: 1px solid #e8eaed;
    border-radius: 12px;
    overflow: hidden;
}

.articles-table {
    width: 100%;
    border-collapse: collapse;
}

.articles-table thead {
    background: #f8f9fa;
}

.articles-table th {
    padding: 14px 16px;
    text-align: left;
    font-weight: 600;
    color: #5f6368;
    border-bottom: 1px solid #e8eaed;
    font-size: 13px;
}

.articles-table td {
    padding: 14px 16px;
    border-bottom: 1px solid #f1f3f4;
    font-size: 14px;
    color: #3c4043;
}

.articles-table tbody tr:hover {
    background: #f8f9fa;
}

/* 表格列宽 */
.articles-table .col-checkbox {
    width: 40px;
    text-align: center;
}

.articles-table .col-id {
    width: 60px;
}

.articles-table .col-title {
    max-width: 400px;
}

.articles-table .col-title span {
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    cursor: pointer;
}

.articles-table .col-title span:hover {
    color: var(--business-color, #5B7FFF);
}

.articles-table .col-platform {
    width: 100px;
}

.articles-table .col-actions {
    width: 180px;
}

/* 平台标签 */
.platform-badge {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 500;
    background: rgba(91, 127, 255, 0.1);
    color: var(--business-color, #5B7FFF);
}

/* 空状态 */
.articles-empty {
    text-align: center;
    padding: 60px 20px;
    color: #9aa0a6;
    font-size: 14px;
}

/* ========== 文章详情弹窗 ========== */
.article-detail-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 3000;
    justify-content: center;
    align-items: center;
}

.article-detail-modal.active {
    display: flex;
}

.article-detail-content {
    position: relative;
    background: white;
    border-radius: 16px;
    width: 90%;
    max-width: 900px;
    max-height: 85vh;
    overflow: visible;
    display: flex;
    flex-direction: column;
    box-shadow: 0 24px 48px rgba(0, 0, 0, 0.2);
}

.article-detail-body {
    overflow-y: auto;
}

.article-detail-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 24px;
    border-bottom: 1px solid #e8eaed;
}

.article-detail-title {
    font-size: 18px;
    font-weight: 600;
    color: #202124;
    flex: 1;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    padding-right: 16px;
}

.article-detail-close {
    width: 36px;
    height: 36px;
    border: none;
    background: #f1f3f4;
    border-radius: 50%;
    font-size: 20px;
    cursor: pointer;
    color: #5f6368;
    flex-shrink: 0;
}

.article-detail-close:hover {
    background: #e8eaed;
}

.article-detail-body {
    padding: 24px;
    overflow-y: auto;
    flex: 1;
}

.article-detail-info {
    margin-bottom: 16px;
}

.article-detail-platform {
    display: inline-block;
    padding: 4px 12px;
    background: rgba(91, 127, 255, 0.1);
    color: var(--business-color, #5B7FFF);
    border-radius: 6px;
    font-size: 13px;
    font-weight: 500;
}

.article-detail-html {
    padding: 20px;
    background: #f8f9fa;
    border-radius: 8px;
    line-height: 1.8;
    font-size: 14px;
}

.article-detail-html p {
    margin-bottom: 12px;
}

.article-detail-html img {
    max-width: 30%;
    border-radius: 8px;
    margin: 12px 0;
}

.article-detail-footer {
    padding: 16px 24px;
    border-top: 1px solid #e8eaed;
    display: flex;
    justify-content: flex-end;
    gap: 12px;
}

/* ========== 批量修改分类弹窗 ========== */
.batch-platform-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 3000;
    justify-content: center;
    align-items: center;
}

.batch-platform-modal.active {
    display: flex;
}

.batch-platform-content {
    background: white;
    border-radius: 16px;
    width: 90%;
    max-width: 400px;
    box-shadow: 0 24px 48px rgba(0, 0, 0, 0.2);
}

.batch-platform-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 24px;
    border-bottom: 1px solid #e8eaed;
}

.batch-platform-title {
    font-size: 18px;
    font-weight: 600;
    color: #202124;
}

.batch-platform-close {
    width: 36px;
    height: 36px;
    border: none;
    background: #f1f3f4;
    border-radius: 50%;
    font-size: 20px;
    cursor: pointer;
    color: #5f6368;
}

.batch-platform-close:hover {
    background: #e8eaed;
}

.batch-platform-body {
    padding: 24px;
}

.batch-platform-body p {
    margin-bottom: 16px;
    color: #5f6368;
}

.batch-platform-label {
    display: block;
    font-size: 14px;
    font-weight: 500;
    color: #202124;
    margin-bottom: 8px;
}

.batch-platform-footer {
    padding: 16px 24px;
    border-top: 1px solid #e8eaed;
    display: flex;
    justify-content: flex-end;
    gap: 12px;
}

/* ========== 文章预览导航按钮（侧边居中） ========== */
.btn-nav-side {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 56px;
    height: 56px;
    border: none;
    background: rgba(255, 255, 255, 0.95);
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #5f6368;
    transition: all 0.2s;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.15);
    z-index: 10;
}

.btn-nav-side svg {
    width: 28px;
    height: 28px;
}

.btn-nav-prev {
    left: -78px;
}

.btn-nav-next {
    right: -78px;
}

.btn-nav-side:hover:not(:disabled) {
    background: white;
    color: var(--business-color, #5B7FFF);
    box-shadow: 0 4px 16px rgba(91, 127, 255, 0.3);
    transform: translateY(-50%) scale(1.08);
}

.btn-nav-side:disabled {
    opacity: 0.3;
    cursor: not-allowed;
}

.btn-nav-side:disabled:hover {
    transform: translateY(-50%);
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.15);
}

.article-nav-index {
    font-size: 13px;
    color: #5f6368;
    background: rgba(91, 127, 255, 0.1);
    padding: 4px 12px;
    border-radius: 12px;
    margin-right: 12px;
}

/* ========== 文章滚动浮动按钮 ========== */
.article-scroll-buttons {
    position: absolute;
    right: 28px;
    bottom: 80px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    z-index: 10;
}

.btn-scroll {
    width: 40px;
    height: 40px;
    border: 1px solid #dadce0;
    background: white;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #5f6368;
    transition: all 0.2s;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.btn-scroll:hover {
    border-color: var(--business-color, #5B7FFF);
    color: var(--business-color, #5B7FFF);
    background: rgba(91, 127, 255, 0.05);
    box-shadow: 0 4px 12px rgba(91, 127, 255, 0.2);
}
