Files
opc-manager/static/styles.css
mac 8dc69f8bd6 feat: OPC 工作台 — 科普(慰心斋)单项目管理系统
Flask + Tailwind CSS + Trix + Chart.js + Lucide Icons + SQLite

- 首页概览:关键指标卡片、财务趋势图、风险提醒、近期动态
- 销售管理:客户表格 + 抽屉详情(自动保存 + 评论)
- 业务方案:版本表格 + 抽屉(文件上传/预览/删除 + 评论)
- 运营管理:项目表格(业务机会/执行项目分类)+ 抽屉
- 产品研发:版本表格 + 抽屉
- 财务管理:月度收入/毛利/成本/净利曲线图 + 明细表
- 所有抽屉:Plane 风格紧凑布局、字段失焦自动保存、Trix 富文本评论框、点击遮罩关闭
2026-05-30 00:08:28 +08:00

442 lines
7.1 KiB
CSS

body {
min-width: 1180px;
font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", sans-serif;
}
.topbar {
display: flex;
align-items: center;
justify-content: space-between;
}
.tabs {
display: flex;
gap: 4px;
}
.tabs button {
align-items: center;
border-bottom: 2px solid transparent;
color: #64748b;
display: inline-flex;
font-size: 14px;
font-weight: 600;
gap: 8px;
padding: 14px 16px;
}
.tabs button.active {
border-bottom-color: #1d4ed8;
color: #1d4ed8;
}
.panel {
display: none;
}
.panel.active {
display: block;
}
.card {
background: white;
border: 1px solid #e2e8f0;
border-radius: 8px;
}
.metric-card {
background: white;
border: 1px solid #e2e8f0;
border-radius: 8px;
padding: 16px;
text-align: left;
transition: border-color 0.2s ease;
}
.metric-card:hover {
border-color: #93c5fd;
}
.badge {
border-radius: 999px;
display: inline-flex;
font-size: 12px;
font-weight: 700;
line-height: 1;
padding: 6px 8px;
}
.badge-red { background: #fef2f2; color: #b91c1c; }
.badge-amber { background: #fffbeb; color: #b45309; }
.badge-green { background: #ecfdf5; color: #047857; }
.badge-blue { background: #eff6ff; color: #1d4ed8; }
.badge-slate { background: #f1f5f9; color: #475569; }
.btn {
align-items: center;
border-radius: 6px;
display: inline-flex;
font-size: 14px;
font-weight: 700;
gap: 8px;
justify-content: center;
min-height: 38px;
padding: 8px 12px;
}
[data-lucide] {
height: 16px;
stroke-width: 2;
width: 16px;
}
.btn-primary { background: #1d4ed8; color: white; }
.btn-primary:hover { background: #1e40af; }
.btn-ghost { background: white; border: 1px solid #e2e8f0; color: #334155; }
.btn-ghost:hover { background: #f8fafc; }
input,
select,
textarea {
border: 1px solid #cbd5e1;
border-radius: 6px;
min-height: 38px;
padding: 8px 10px;
}
textarea {
min-height: 96px;
}
table {
border-collapse: collapse;
width: 100%;
}
th,
td {
border-bottom: 1px solid #e2e8f0;
padding: 12px 14px;
text-align: left;
vertical-align: top;
}
th {
background: #f1f5f9;
color: #475569;
font-size: 13px;
font-weight: 800;
}
td {
font-size: 14px;
}
.btn-sm {
min-height: 30px;
padding: 5px 10px;
font-size: 12px;
}
.drawer {
background: rgba(15, 23, 42, 0.28);
display: none;
inset: 0;
justify-content: flex-end;
position: fixed;
z-index: 50;
}
.drawer.open {
display: flex;
}
.drawer-panel {
background: white;
box-shadow: -18px 0 45px rgba(15, 23, 42, 0.14);
height: 100vh;
overflow-y: auto;
width: 560px;
}
.file-link {
color: #1d4ed8;
font-size: 12px;
font-weight: 700;
}
.drawer-section-title {
color: #334155;
font-size: 13px;
font-weight: 700;
margin-bottom: 8px;
}
.drawer-fields {
display: grid;
gap: 1px;
}
.drawer-field {
align-items: start;
display: grid;
gap: 12px;
grid-template-columns: 148px minmax(0, 1fr);
padding: 5px 0;
}
.drawer-field-label {
align-items: center;
color: #64748b;
display: flex;
font-size: 13px;
font-weight: 500;
gap: 8px;
min-height: 30px;
}
.drawer-field-label [data-lucide] {
color: #94a3b8;
height: 15px;
width: 15px;
}
.drawer-field-control {
min-width: 0;
}
.drawer-value {
background: transparent;
border: 1px solid transparent;
border-radius: 5px;
color: #0f172a;
font-size: 13px;
font-weight: 500;
min-height: 30px;
padding: 4px 8px;
width: 100%;
}
.drawer-value:hover {
background: #f8fafc;
border-color: #e2e8f0;
}
.drawer-value:focus {
background: white;
border-color: #60a5fa;
outline: none;
}
.drawer-textarea {
line-height: 1.45;
min-height: 54px;
resize: vertical;
}
.activity-item {
background: #f8fafc;
border: 1px solid #e2e8f0;
border-radius: 7px;
display: flex;
font-size: 13px;
gap: 9px;
padding: 9px;
}
.activity-icon {
align-items: center;
background: #dbeafe;
border-radius: 999px;
color: #1d4ed8;
display: flex;
flex: 0 0 auto;
height: 24px;
justify-content: center;
width: 24px;
}
.activity-icon [data-lucide] {
height: 13px;
width: 13px;
}
.inline-form input,
.inline-form select {
height: 40px;
border: 1px solid #cbd5e1;
border-radius: 6px;
padding: 8px 10px;
font-size: 14px;
background: white;
min-width: 120px;
}
.inline-form input:focus,
.inline-form select:focus {
border-color: #3b82f6;
outline: none;
}
.clickable-row {
cursor: pointer;
transition: background 0.15s;
}
.clickable-row:hover {
background: #f1f5f9;
}
.save-status {
color: #94a3b8;
font-size: 12px;
font-weight: 500;
}
.save-status[data-tone="success"] {
color: #059669;
}
.save-status[data-tone="danger"] {
color: #dc2626;
}
.comment-box {
border: 1px solid #e2e8f0;
border-radius: 8px;
overflow: hidden;
background: white;
}
.comment-box:focus-within {
border-color: #93c5fd;
box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.08);
}
/* Trix editor inside comment box */
.comment-trix {
min-height: 80px;
}
.comment-trix trix-editor {
border: 0;
border-radius: 0;
font-size: 13px;
line-height: 1.55;
min-height: 80px;
padding: 10px 12px;
outline: none;
}
.comment-trix trix-toolbar {
border: 0;
border-top: 1px solid #e2e8f0;
background: #f8fafc;
padding: 6px 6px;
}
.comment-trix trix-toolbar .trix-button {
border-radius: 4px;
padding: 3px 5px;
font-size: 12px;
background: transparent;
border-color: transparent;
}
.comment-trix trix-toolbar .trix-button:hover,
.comment-trix trix-toolbar .trix-button.trix-active {
background: #e2e8f0;
color: #1e293b;
}
.comment-trix trix-toolbar .trix-button-group {
border-color: #e2e8f0;
margin-right: 4px;
}
.comment-toolbar {
align-items: center;
background: #f8fafc;
border-top: 1px solid #e2e8f0;
display: flex;
justify-content: space-between;
padding: 7px 8px;
}
.comment-hint {
color: #94a3b8;
font-size: 12px;
}
.toolbar-icon {
border-radius: 4px;
cursor: pointer;
padding: 3px;
transition: background 0.15s;
}
.toolbar-icon:hover {
background: #e2e8f0;
color: #1e293b;
}
.btn:disabled,
.btn:disabled:hover {
background: #e2e8f0;
border-color: #e2e8f0;
color: #94a3b8;
cursor: not-allowed;
}
.activity-delete {
align-items: center;
border-radius: 5px;
color: #94a3b8;
display: inline-flex;
flex: 0 0 auto;
height: 26px;
justify-content: center;
opacity: 0;
transition: background 0.15s, color 0.15s, opacity 0.15s;
width: 26px;
}
.activity-item:hover .activity-delete {
opacity: 1;
}
.activity-delete:hover {
background: #fee2e2;
color: #dc2626;
}
.activity-delete [data-lucide] {
height: 14px;
width: 14px;
}
/* Trix content in activity items */
.activity-item .trix-content {
font-size: 13px;
line-height: 1.55;
}
.activity-item .trix-content div {
font-size: 13px;
}
.activity-item .trix-content strong {
font-weight: 600;
}
.activity-item .trix-content a {
color: #1d4ed8;
text-decoration: underline;
}
.activity-item .trix-content ul,
.activity-item .trix-content ol {
padding-left: 16px;
margin: 4px 0;
}
.activity-item .trix-content blockquote {
border-left: 3px solid #e2e8f0;
padding-left: 10px;
color: #64748b;
margin: 4px 0;
}