/* 自定义样式 */

body {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.container {
    flex: 1;
}

footer {
    margin-top: auto;
}

/* 卡片悬停效果 */
.card {
    transition: transform 0.2s, box-shadow 0.2s;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}

/* 等级徽章 */
.badge {
    font-size: 1em;
    padding: 0.5em 0.8em;
}

/* 进度条 */
.progress {
    height: 25px;
}

.progress-bar {
    font-size: 14px;
    line-height: 25px;
}

/* 表格 */
.table-hover tbody tr:hover {
    background-color: rgba(0, 123, 255, 0.1);
}

/* 响应式调整 */
@media (max-width: 768px) {
    .card-body h5 {
        font-size: 1rem;
    }

    .btn-group-sm > .btn {
        padding: 0.25rem 0.5rem;
        font-size: 0.875rem;
    }
}

/* 分数输入框 */
#score {
    text-align: center;
    font-size: 1.5rem;
    font-weight: bold;
}

/* 等级显示 */
#gradeDisplay {
    min-height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* 表格固定列宽 */
.table th,
.table td {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* 打分状态颜色 */
.table-success {
    background-color: rgba(40, 167, 69, 0.1) !important;
}

.table-warning {
    background-color: rgba(255, 193, 7, 0.1) !important;
}

/* 导航栏用户下拉菜单 */
.navbar .dropdown-menu {
    right: 0;
    left: auto;
}

/* ============== Issue 看板样式 ============== */

.kanban-board {
    display: flex;
    gap: 1rem;
    overflow-x: auto;
    padding: 1rem 0;
    min-height: 600px;
}

.kanban-column {
    min-width: 300px;
    max-width: 350px;
    background: #f8f9fa;
    border-radius: 8px;
    padding: 0;
    display: flex;
    flex-direction: column;
}

.kanban-column-header {
    padding: 1rem;
    background: #e9ecef;
    border-radius: 8px 8px 0 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 2px solid #dee2e6;
}

.kanban-column-title {
    margin: 0;
    font-size: 1rem;
    font-weight: 600;
    color: #495057;
}

.kanban-count {
    font-size: 0.875rem;
}

.kanban-cards {
    flex: 1;
    padding: 0.75rem;
    min-height: 200px;
    overflow-y: auto;
}

.kanban-cards.drag-over {
    background: #e3f2fd;
    border: 2px dashed #2196f3;
    border-radius: 4px;
}

.issue-card {
    background: white;
    border: 1px solid #dee2e6;
    border-radius: 6px;
    padding: 0.75rem;
    margin-bottom: 0.75rem;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}

.issue-card:hover {
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    transform: translateY(-2px);
    border-color: #adb5bd;
}

.issue-card.dragging {
    opacity: 0.5;
    transform: rotate(3deg);
    cursor: grabbing;
}

.issue-card.dragging * {
    pointer-events: none;
}

.issue-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.5rem;
    font-size: 0.875rem;
}

.issue-id {
    font-weight: 600;
    color: #6c757d;
}

.issue-id i {
    font-size: 0.875rem;
}

.priority-badge {
    font-size: 0.75rem;
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    font-weight: 600;
}

.priority-low {
    background: #e3f2fd;
    color: #1976d2;
}

.priority-medium {
    background: #fff3e0;
    color: #f57c00;
}

.priority-high {
    background: #ffe0b2;
    color: #e65100;
}

.priority-urgent {
    background: #ffebee;
    color: #c62828;
}

.issue-title {
    font-size: 0.9rem;
    line-height: 1.4;
    margin-bottom: 0.5rem;
    color: #212529;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.issue-meta {
    display: grid;
    gap: 0.3rem;
    margin-bottom: 0.65rem;
    font-size: 0.78rem;
    color: #667085;
}

.issue-meta-item {
    display: flex;
    align-items: center;
    gap: 0.35rem;
}

.issue-card-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.8rem;
    color: #6c757d;
}

.assignee {
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.assignee i {
    font-size: 0.875rem;
}

.issue-update-time {
    color: #98a2b3;
}

.issue-risk-flag {
    margin-top: 0.65rem;
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    font-size: 0.76rem;
    color: #b42318;
    background: #fef3f2;
    border-radius: 999px;
    padding: 0.2rem 0.55rem;
}

.issue-board-filter {
    width: auto;
    min-width: 140px;
}

.issue-overview-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 0.75rem;
}

.issue-overview-card {
    border-radius: 12px;
    padding: 1rem;
    border: 1px solid #e5e7eb;
    background: #fff;
}

.issue-overview-label {
    font-size: 0.82rem;
    color: #667085;
    margin-bottom: 0.35rem;
}

.issue-overview-count {
    font-size: 1.6rem;
    font-weight: 700;
    line-height: 1;
    color: #101828;
}

.issue-overview-primary {
    background: linear-gradient(180deg, #eff6ff 0%, #dbeafe 100%);
}

.issue-overview-danger {
    background: linear-gradient(180deg, #fff1f2 0%, #ffe4e6 100%);
}

.issue-overview-warning {
    background: linear-gradient(180deg, #fffbeb 0%, #fef3c7 100%);
}

.issue-overview-success {
    background: linear-gradient(180deg, #ecfdf3 0%, #d1fadf 100%);
}

.issue-risk-list {
    padding-left: 1.1rem;
    color: #475467;
}

/* Toast 容器 */
.toast-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 1050;
}

/* 响应式 */
@media (max-width: 768px) {
    .kanban-board {
        flex-direction: column;
    }

    .kanban-column {
        min-width: 100%;
        max-width: 100%;
    }
}

/* 滚动条美化 */
.kanban-cards::-webkit-scrollbar {
    width: 6px;
}

.kanban-cards::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 3px;
}

.kanban-cards::-webkit-scrollbar-thumb {
    background: #888;
    border-radius: 3px;
}

.kanban-cards::-webkit-scrollbar-thumb:hover {
    background: #555;
}

/* Issue 详情页两栏布局 */
.issue-detail-layout {
    display: grid;
    grid-template-columns: 1fr 300px;
    gap: 1.5rem;
}
@media (max-width: 991px) {
    .issue-detail-layout {
        grid-template-columns: 1fr;
    }
}
.issue-sidebar .sidebar-field {
    padding: 0.5rem 0;
    border-bottom: 1px solid #f0f0f0;
}
.issue-sidebar .sidebar-field:last-child {
    border-bottom: none;
}
.issue-sidebar .field-label {
    font-size: 0.75rem;
    color: #6c757d;
    margin-bottom: 0.25rem;
}
