/* 通用布局与组件样式 */
body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial;
    margin: 0;
    padding: 0;
}

/* 顶部导航栏 */
.top-menu {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 32px;
    background: #f8f9fa;
    border-bottom: 1px solid #e5e5e5;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
}

.top-menu-left {
    display: flex;
    align-items: center;
}

.top-menu-right {
    display: flex;
    width: 60%;
}

.top-menu-right button {
    flex: 1;
    margin-left: 8px;
    padding: 8px 12px;
    background: #f0f0f0;
    color: #333;
    border: 1px solid #e5e5e5;
    border-radius: 6px;
    cursor: pointer;
}

.top-menu-right button.active {
    background: #1677ff;
    color: #fff;
    border-color: #1677ff;
}

/* 主布局 */
.main-layout {
    max-width: 1200px;
    margin: 100px auto 32px;
    padding: 0 32px;
}

.card {
    border: 1px solid #e5e5e5;
    padding: 24px;
    border-radius: 8px;
    background: #fff;
    margin-bottom: 24px;
}

.row {
    margin-bottom: 16px;
}

.grid {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 8px;
    align-items: center;
}

label {
    display: inline-block;
    margin-bottom: 8px;
    font-weight: 600;
}

/* 按钮样式 */
button {
    padding: 10px 16px;
    background: #1677ff;
    color: #fff;
    border: none;
    border-radius: 4px;
    cursor: pointer;
}

button:disabled {
    background: #9dbaf7;
    cursor: not-allowed;
}

/* 图标按钮 */
button.icon-btn {
    background: #fff;
    color: #333;
    padding: 6px;
    border: 1px solid #e5e5e5;
    border-radius: 6px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    position: relative;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

button.icon-btn:hover {
    background: #f8f9fa;
    border-color: #1677ff;
    color: #1677ff;
    transform: translateY(-1px);
    box-shadow: 0 2px 4px rgba(22, 119, 255, 0.1);
}

button.icon-btn:disabled {
    background: #f5f5f5;
    border-color: #e5e5e5;
    color: #bfbfbf;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

button.icon-btn img,
button.icon-btn svg {
    width: 18px;
    height: 18px;
    display: block;
}

button.icon-btn:disabled img,
button.icon-btn:disabled svg {
    filter: grayscale(1) opacity(0.3);
}

/* 进度条 */
.progress {
    width: 100%;
    height: 8px;
    background: #eee;
    border-radius: 4px;
    overflow: hidden;
    margin-top: 8px;
}

.bar {
    height: 100%;
    width: 0%;
    background: #52c41a;
    transition: width 0.2s ease;
}

.muted {
    color: #666;
    font-size: 13px;
}

/* 表格样式 */
.table-wrap {
    max-height: 420px;
    overflow: auto;
}

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

.table th,
.table td {
    border: 1px solid #e5e5e5;
    padding: 8px 12px;
    vertical-align: middle;
    line-height: 1.5;
}

.table th {
    background: #f5f7fa;
    font-weight: 600;
}

.ops-icons {
    display: flex;
    gap: 8px;
    justify-content: flex-end;
    align-items: center;
    min-height: 24px;
}

/* 弹窗 */
.modal {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
}

.hidden {
    display: none;
}