/* 爆款文章平台 - 主样式 (仿爆了么橙色风格) */

/* ====== 头部导航 ====== */
.bk-header {
    background: #ff5000;
    color: white;
    height: 50px;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}

.bk-header-inner {
    max-width: 1300px;
    margin: 0 auto;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 20px;
}

.bk-logo {
    display: flex;
    align-items: center;
    gap: 8px;
}

.bk-logo-icon {
    font-size: 28px;
}

.bk-logo-text h1 {
    font-size: 18px;
    font-weight: 700;
    color: white;
    line-height: 1.2;
}

.bk-logo-text .bk-tagline {
    font-size: 10px;
    opacity: 0.85;
    line-height: 1;
}

.bk-nav {
    display: flex;
    gap: 5px;
}

.bk-nav-item {
    color: white;
    padding: 6px 14px;
    border-radius: 4px;
    font-size: 13px;
    font-weight: 500;
    transition: background 0.2s;
}

.bk-nav-item:hover, .bk-nav-item.active {
    background: rgba(255,255,255,0.2);
    color: white;
}

.bk-user-area {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 13px;
    color: white;
}

.bk-user-area a { color: white; }
.bk-admin-link {
    background: rgba(255,255,255,0.2);
    padding: 4px 10px;
    border-radius: 4px;
}

/* ====== 主内容区 ====== */
.bk-main {
    max-width: 1300px;
    margin: 0 auto;
    padding: 20px 20px 40px;
}

.bk-container {}

/* ====== 筛选区 ====== */
.bk-filter-section {
    background: white;
    border-radius: 8px;
    padding: 15px 20px;
    box-shadow: 0 1px 6px rgba(0,0,0,0.08);
    margin-bottom: 15px;
}

.bk-filter-row {
    display: flex;
    align-items: flex-start;
    margin-bottom: 10px;
    gap: 10px;
}

.bk-filter-row:last-child {
    margin-bottom: 0;
}

.bk-filter-label {
    flex-shrink: 0;
    width: 50px;
    font-size: 13px;
    color: #999;
    padding-top: 5px;
    font-weight: 500;
}

.bk-tag-group {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.bk-tag {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 4px;
    font-size: 13px;
    color: #555;
    background: #f5f5f5;
    border: 1px solid transparent;
    cursor: pointer;
    transition: all 0.2s;
    white-space: nowrap;
}

.bk-tag:hover {
    background: #fff3e8;
    color: #ff5000;
}

.bk-tag.active {
    background: #ff5000;
    color: white;
}

.bk-tag-orange.active {
    background: #ff5000;
    color: white;
}

.bk-tag-sub {
    font-size: 12px;
    padding: 3px 10px;
    color: #888;
}

.bk-tag-sub.active {
    background: #ff5000;
    color: white;
}

/* 搜索行 */
.bk-search-row {
    margin-top: 8px;
    padding-top: 10px;
    border-top: 1px solid #f0f0f0;
}

.bk-search-group {
    display: flex;
    flex: 1;
    gap: 8px;
    align-items: center;
}

.bk-search-input {
    flex: 1;
    padding: 7px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 13px;
    outline: none;
    transition: border 0.2s;
}

.bk-search-input:focus {
    border-color: #ff5000;
}

/* ====== 按钮 ====== */
.bk-btn {
    padding: 6px 16px;
    border: none;
    border-radius: 4px;
    font-size: 13px;
    cursor: pointer;
    font-weight: 500;
    transition: all 0.2s;
    white-space: nowrap;
}

.bk-btn-primary {
    background: #ff5000;
    color: white;
}

.bk-btn-primary:hover {
    background: #e64800;
}

.bk-btn-success {
    background: #28a745;
    color: white;
}

.bk-btn-success:hover {
    background: #218838;
}

.bk-btn-outline {
    background: white;
    color: #666;
    border: 1px solid #ddd;
}

.bk-btn-outline:hover {
    border-color: #ff5000;
    color: #ff5000;
}

.bk-btn-sm {
    padding: 3px 8px;
    font-size: 12px;
}

.bk-btn-lg {
    padding: 10px 24px;
    font-size: 15px;
    width: 100%;
    margin-top: 10px;
}

/* ====== 结果信息 ====== */
.bk-result-info {
    font-size: 13px;
    color: #666;
    margin-bottom: 10px;
}

.bk-result-info strong {
    color: #ff5000;
}

/* ====== 数据表格 ====== */
.bk-table-container {
    background: white;
    border-radius: 8px;
    box-shadow: 0 1px 6px rgba(0,0,0,0.08);
    overflow: hidden;
}

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

.bk-table thead tr {
    background: #fafafa;
    border-bottom: 2px solid #f0f0f0;
}

.bk-table th {
    padding: 10px 12px;
    text-align: left;
    font-size: 13px;
    font-weight: 600;
    color: #666;
}

.bk-table td {
    padding: 12px 12px;
    font-size: 13px;
    border-bottom: 1px solid #f5f5f5;
    vertical-align: middle;
}

.bk-table tbody tr:hover {
    background: #fff8f0;
}

.bk-table .bk-td-category {
    color: #888;
    font-size: 12px;
}

.bk-table .bk-td-date {
    color: #999;
    font-size: 12px;
}

.bk-table .bk-td-account {
    color: #1a73e8;
    font-size: 12px;
}

.bk-table .bk-td-title a {
    color: #333;
    font-weight: 500;
}

.bk-table .bk-td-title a:hover {
    color: #ff5000;
}

.bk-td-views, .bk-td-likes, .bk-td-shares {
    text-align: center;
    font-size: 13px;
}

.bk-td-views {
    color: #ff5000;
    font-weight: 600;
}

.bk-td-actions {
    display: flex;
    gap: 5px;
    flex-wrap: wrap;
}

.bk-action-btn {
    padding: 3px 8px;
    border-radius: 3px;
    font-size: 11px;
    cursor: pointer;
    border: 1px solid #ddd;
    background: white;
    color: #666;
    transition: all 0.2s;
    white-space: nowrap;
}

.bk-action-btn:hover {
    border-color: #ff5000;
    color: #ff5000;
}

.bk-action-btn.bk-action-ai {
    background: #ff5000;
    color: white;
    border-color: #ff5000;
}

.bk-action-btn.bk-action-ai:hover {
    background: #e64800;
}

/* 格式化数字 */
.bk-num-icon {
    font-size: 11px;
    margin-right: 2px;
    opacity: 0.6;
}

/* ====== 加载中 ====== */
.bk-loading-row {
    text-align: center;
    padding: 40px !important;
    color: #999;
}

.bk-spinner {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid #f0f0f0;
    border-top-color: #ff5000;
    border-radius: 50%;
    animation: bk-spin 0.8s linear infinite;
    margin-right: 8px;
    vertical-align: middle;
}

@keyframes bk-spin {
    to { transform: rotate(360deg); }
}

/* ====== 分页 ====== */
.bk-pagination {
    display: flex;
    justify-content: center;
    gap: 5px;
    margin-top: 20px;
}

.bk-page-btn {
    padding: 6px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    background: white;
    color: #666;
    cursor: pointer;
    font-size: 13px;
    transition: all 0.2s;
}

.bk-page-btn:hover, .bk-page-btn.active {
    background: #ff5000;
    color: white;
    border-color: #ff5000;
}

.bk-page-btn.disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

/* ====== AI 改写弹窗 ====== */
.bk-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
}

.bk-modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.5);
}

.bk-modal-content {
    position: relative;
    background: white;
    border-radius: 12px;
    width: 700px;
    max-height: 85vh;
    overflow-y: auto;
    box-shadow: 0 10px 40px rgba(0,0,0,0.3);
}

.bk-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 24px;
    border-bottom: 1px solid #eee;
}

.bk-modal-header h3 {
    font-size: 18px;
    color: #ff5000;
}

.bk-modal-close {
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    color: #999;
    padding: 0;
    line-height: 1;
}

.bk-modal-close:hover { color: #333; }

.bk-modal-body {
    padding: 20px 24px;
}

.bk-ai-section {
    margin-bottom: 16px;
}

.bk-ai-section h4 {
    font-size: 14px;
    color: #555;
    margin-bottom: 8px;
}

.bk-ai-section label {
    font-size: 13px;
    color: #555;
    font-weight: 600;
    margin-bottom: 6px;
    display: block;
}

.bk-ai-section select {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 13px;
    outline: none;
}

.bk-original-text {
    background: #f8f9fa;
    border: 1px solid #eee;
    border-radius: 6px;
    padding: 12px;
    font-size: 13px;
    line-height: 1.7;
    color: #555;
}

.bk-custom-prompt {
    width: 100%;
    margin-top: 8px;
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 13px;
    resize: vertical;
    min-height: 60px;
    outline: none;
}

.bk-custom-prompt:focus { border-color: #ff5000; }

.bk-ai-result {
    background: #f0fff0;
    border: 1px solid #a5d6a7;
    border-radius: 6px;
    padding: 15px;
    font-size: 14px;
    line-height: 1.8;
    white-space: pre-wrap;
    max-height: 300px;
    overflow-y: auto;
}

.bk-ai-actions {
    display: flex;
    gap: 10px;
    margin-top: 10px;
}

.bk-ai-loading {
    text-align: center;
    padding: 30px;
    color: #999;
}

/* ====== 底部 ====== */
.bk-footer {
    text-align: center;
    padding: 20px;
    color: #aaa;
    font-size: 12px;
    border-top: 1px solid #eee;
    margin-top: 40px;
}

/* ====== 收藏按钮状态 ====== */
.bk-action-btn.favorited {
    background: #fff3e8;
    border-color: #ff5000;
    color: #ff5000;
}

/* ====== 提示词库页面布局 ====== */
.bk-prompts-layout {
    display: flex;
    gap: 20px;
    min-height: calc(100vh - 130px);
}

/* 左侧分组侧栏 */
.bk-prompts-sidebar {
    width: 180px;
    flex-shrink: 0;
    background: white;
    border-radius: 8px;
    box-shadow: 0 1px 6px rgba(0,0,0,0.08);
    padding: 10px 0;
    align-self: flex-start;
    position: sticky;
    top: 70px;
}

.bk-sidebar-item {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 10px 16px;
    font-size: 13px;
    color: #333;
    cursor: pointer;
    transition: all 0.15s;
    border-left: 3px solid transparent;
}

.bk-sidebar-item:hover {
    background: #fff3e8;
    color: #ff5000;
}

.bk-sidebar-item.active {
    background: #ff5000;
    color: white;
    border-left-color: #cc4000;
}

.bk-sidebar-icon {
    font-size: 14px;
}

.bk-sidebar-section {
    margin-top: 8px;
    border-top: 1px solid #f0f0f0;
    padding-top: 8px;
}

.bk-sidebar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 4px 16px 8px;
    font-size: 11px;
    color: #999;
}

.bk-sidebar-manage {
    background: none;
    border: none;
    font-size: 11px;
    color: #999;
    cursor: pointer;
}

.bk-sidebar-manage:hover { color: #ff5000; }

.bk-sidebar-group {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    font-size: 13px;
    color: #555;
    cursor: pointer;
    transition: all 0.15s;
    border-left: 3px solid transparent;
}

.bk-sidebar-group:hover {
    background: #fff3e8;
    color: #ff5000;
}

.bk-sidebar-group.active {
    background: #ff5000;
    color: white;
}

.bk-sidebar-group .bk-group-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #ff5000;
    flex-shrink: 0;
}

.bk-sidebar-group.active .bk-group-dot {
    background: white;
}

/* 右侧主内容 */
.bk-prompts-main {
    flex: 1;
    min-width: 0;
}

.bk-prompts-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
}

.bk-prompts-header h2 {
    font-size: 18px;
    font-weight: 700;
    color: #333;
    margin-bottom: 2px;
}

.bk-prompts-count {
    font-size: 12px;
    color: #999;
}

.bk-prompts-count strong {
    color: #ff5000;
}

.bk-prompts-actions {
    display: flex;
    gap: 8px;
}

/* 状态标签 */
.bk-status-tag {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 10px;
    font-size: 11px;
    font-weight: 500;
}

.bk-status-done {
    background: #e8f5e9;
    color: #2e7d32;
}

.bk-status-pending {
    background: #fff3e0;
    color: #e65100;
}

.bk-status-error {
    background: #ffebee;
    color: #c62828;
}

/* 分类标签 (表格内) */
.bk-category-badge {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 3px;
    font-size: 11px;
    background: #fff3e8;
    color: #ff5000;
    border: 1px solid #ffe0c0;
}

/* 提示词操作按钮 */
.bk-prompt-actions {
    display: flex;
    gap: 5px;
}

.bk-prompt-action {
    padding: 3px 8px;
    border-radius: 3px;
    font-size: 11px;
    cursor: pointer;
    border: 1px solid #ddd;
    background: white;
    color: #666;
    transition: all 0.2s;
}

.bk-prompt-action:hover {
    border-color: #ff5000;
    color: #ff5000;
}

.bk-prompt-action.bk-action-delete:hover {
    border-color: #e53935;
    color: #e53935;
}

/* ====== 提示词弹窗表单 ====== */
.bk-form-group {
    margin-bottom: 16px;
}

.bk-form-group label {
    display: block;
    font-size: 14px;
    font-weight: 600;
    color: #333;
    margin-bottom: 4px;
}

.bk-form-tip {
    font-size: 12px;
    color: #999;
    margin-bottom: 6px;
}

.bk-form-input {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 13px;
    outline: none;
}

.bk-form-input:focus { border-color: #ff5000; }

.bk-form-select {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 13px;
    outline: none;
    background: white;
}

.bk-form-textarea {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 13px;
    outline: none;
    resize: vertical;
    font-family: inherit;
    line-height: 1.5;
}

.bk-form-textarea:focus { border-color: #ff5000; }

.bk-radio-group {
    display: flex;
    gap: 20px;
    margin-top: 4px;
}

.bk-radio {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 13px;
    color: #555;
    cursor: pointer;
}

.bk-radio input[type="radio"] {
    accent-color: #ff5000;
}

.bk-prompt-tips {
    background: #fafafa;
    border-radius: 6px;
    padding: 10px 14px;
    margin-top: 12px;
    font-size: 12px;
    line-height: 1.8;
    color: #666;
}

.bk-prompt-tips strong {
    color: #333;
}

.bk-modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    margin-top: 16px;
    padding-top: 12px;
    border-top: 1px solid #eee;
}

/* 分组管理列表 */
.bk-group-list-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 8px 0;
    border-bottom: 1px solid #f5f5f5;
    font-size: 13px;
}

.bk-group-list-item:last-child { border-bottom: none; }

.bk-group-delete {
    background: none;
    border: none;
    color: #ccc;
    cursor: pointer;
    font-size: 16px;
}

.bk-group-delete:hover { color: #e53935; }
