Files
SchoolVue/public/style.css
2026-07-07 10:14:36 +05:00

690 lines
13 KiB
CSS

* { margin: 0; padding: 0; box-sizing: border-box; }
body {
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
background: #f0f2f5;
color: #1a1a2e;
min-height: 100vh;
}
header {
background: #1a1a2e;
color: #fff;
padding: 16px 32px;
display: flex;
align-items: center;
justify-content: space-between;
}
header h1 { font-size: 22px; font-weight: 600; }
.status { font-size: 13px; opacity: 0.7; }
.status.loaded { color: #4ade80; }
main { max-width: 1200px; margin: 0 auto; padding: 24px; }
.upload-section {
background: #fff;
border-radius: 12px;
padding: 24px;
margin-bottom: 20px;
box-shadow: 0 1px 3px rgba(0,0,0,0.08);
}
.upload-section form {
display: flex;
gap: 16px;
align-items: center;
}
.drop-zone {
flex: 1;
border: 2px dashed #c0c0d0;
border-radius: 10px;
padding: 28px 20px;
text-align: center;
cursor: pointer;
transition: all 0.2s;
display: block;
}
.drop-zone:hover, .drop-zone.drag-over {
border-color: #4f46e5;
background: #f5f3ff;
}
.drop-text { display: block; font-size: 15px; color: #555; margin-bottom: 4px; }
.drop-hint { font-size: 12px; color: #999; }
button {
background: #4f46e5;
color: #fff;
border: none;
padding: 12px 28px;
border-radius: 8px;
font-size: 15px;
cursor: pointer;
transition: background 0.15s;
white-space: nowrap;
}
button:hover:not(:disabled) { background: #4338ca; }
button:disabled { opacity: 0.5; cursor: not-allowed; }
#uploadStatus {
font-size: 13px;
color: #666;
min-width: 200px;
}
#uploadStatus.success { color: #16a34a; }
#uploadStatus.error { color: #dc2626; }
.tabs {
display: flex;
gap: 0;
background: #fff;
border-radius: 12px 12px 0 0;
overflow: hidden;
box-shadow: 0 1px 3px rgba(0,0,0,0.08);
}
.tab {
padding: 12px 24px;
border: none;
background: #fff;
color: #666;
font-size: 14px;
cursor: pointer;
border-bottom: 3px solid transparent;
transition: all 0.15s;
border-radius: 0;
}
.tab:hover { color: #4f46e5; background: #f9f9fb; }
.tab.active { color: #4f46e5; border-bottom-color: #4f46e5; font-weight: 600; }
.tab-content {
display: none;
background: #fff;
padding: 24px;
border-radius: 0 0 12px 12px;
box-shadow: 0 1px 3px rgba(0,0,0,0.08);
}
.tab-content.active { display: block; }
.summary-cards {
display: grid;
grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
gap: 16px;
margin-bottom: 24px;
}
.card {
background: #f8f9fc;
border-radius: 10px;
padding: 20px;
text-align: center;
border: 1px solid #e5e7eb;
}
.card .value { font-size: 28px; font-weight: 700; color: #4f46e5; }
.card .label { font-size: 13px; color: #666; margin-top: 4px; }
.alerts { display: flex; flex-direction: column; gap: 8px; }
.alert {
padding: 12px 16px;
border-radius: 8px;
font-size: 14px;
display: flex;
align-items: center;
gap: 8px;
}
.alert.warning { background: #fef3c7; color: #92400e; border: 1px solid #fcd34d; }
.alert.danger { background: #fee2e2; color: #991b1b; border: 1px solid #fca5a5; }
.alert.info { background: #e0f2fe; color: #075985; border: 1px solid #7dd3fc; }
.table-wrapper { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: 14px; }
th, td { padding: 10px 12px; text-align: left; border-bottom: 1px solid #f0f0f0; }
th { background: #f8f9fc; font-weight: 600; color: #555; font-size: 13px; white-space: nowrap; }
tr:hover td { background: #f9f9fb; }
td.num { text-align: center; font-variant-numeric: tabular-nums; }
.low-grades { color: #dc2626; font-weight: 600; }
.no-grades { color: #d97706; font-weight: 600; }
h2 { font-size: 18px; margin-bottom: 16px; color: #1a1a2e; }
.empty-state {
text-align: center;
padding: 40px;
color: #999;
}
.filters {
display: flex;
gap: 8px;
flex-wrap: wrap;
margin-bottom: 16px;
align-items: center;
}
.filters input {
padding: 6px 10px;
border: 1px solid #d0d0d0;
border-radius: 6px;
font-size: 13px;
width: 140px;
}
.filters input:focus {
outline: none;
border-color: #4f46e5;
}
.global-filters {
display: flex;
gap: 8px;
flex-wrap: wrap;
align-items: center;
background: #fff;
border-radius: 12px;
padding: 14px 20px;
margin-bottom: 16px;
box-shadow: 0 1px 3px rgba(0,0,0,0.08);
}
.global-filters input {
padding: 7px 10px;
border: 1px solid #d0d0d0;
border-radius: 6px;
font-size: 13px;
width: 140px;
}
.global-filters input[type="date"] {
width: 145px;
}
.global-filters .btn-reset {
background: transparent;
color: #666;
border: 1px solid #d0d0d0;
margin-left: auto;
}
.global-filters .btn-reset:hover {
background: #f5f5f5;
color: #333;
}
.upload-progress {
width: 100%;
margin-top: 10px;
}
.upload-progress.hidden { display: none; }
.progress-bar {
width: 100%;
height: 6px;
background: #e5e5e5;
border-radius: 3px;
overflow: hidden;
}
.progress-fill {
height: 100%;
width: 0%;
background: #4f46e5;
border-radius: 3px;
transition: width 0.3s ease;
}
.progress-fill:not(.determinate) {
animation: progress-indeterminate 1.5s ease-in-out infinite;
}
@keyframes progress-indeterminate {
0% { width: 0%; margin-left: 0%; }
50% { width: 60%; margin-left: 20%; }
100% { width: 0%; margin-left: 100%; }
}
.progress-text {
display: block;
text-align: center;
font-size: 12px;
color: #888;
margin-top: 6px;
}
@keyframes spin {
to { transform: rotate(360deg); }
}
.spinner {
display: inline-block;
width: 16px;
height: 16px;
border: 2px solid #d0d0d0;
border-top-color: #4f46e5;
border-radius: 50%;
animation: spin 0.6s linear infinite;
vertical-align: middle;
margin-right: 6px;
}
.btn-danger {
background: #dc2626;
}
.btn-danger:hover:not(:disabled) {
background: #b91c1c;
}
.modal-overlay {
display: none;
position: fixed;
inset: 0;
background: rgba(0,0,0,0.4);
z-index: 1000;
align-items: center;
justify-content: center;
}
.modal-overlay.open {
display: flex;
}
.modal {
background: #fff;
border-radius: 14px;
width: 480px;
max-width: 95vw;
max-height: 90vh;
overflow-y: auto;
box-shadow: 0 8px 30px rgba(0,0,0,0.18);
}
.modal-header {
display: flex;
justify-content: space-between;
align-items: center;
padding: 18px 22px 12px;
}
.modal-header h3 { font-size: 17px; }
.modal-close {
background: none;
border: none;
font-size: 22px;
cursor: pointer;
color: #999;
padding: 0 4px;
}
.modal-close:hover { color: #333; }
.modal-body {
padding: 0 22px 20px;
}
.modal-option {
padding: 12px 0;
}
.modal-option strong {
display: block;
margin-bottom: 8px;
font-size: 14px;
}
.modal-option input {
padding: 7px 10px;
border: 1px solid #d0d0d0;
border-radius: 6px;
font-size: 13px;
width: 160px;
margin-right: 8px;
}
.modal-option input:focus {
outline: none;
border-color: #4f46e5;
}
.modal-option hr {
border: none;
border-top: 1px solid #eee;
margin: 12px 0;
}
.modal-option p {
font-size: 12px;
color: #999;
margin: 6px 0 10px;
}
.danger-zone {
background: #fef2f2;
border-radius: 8px;
padding: 14px;
margin-top: 4px;
}
.modal-option span {
font-size: 12px;
margin-left: 8px;
}
.modal-option span.success { color: #16a34a; }
.modal-option span.error { color: #dc2626; }
.period-selector {
display: flex;
gap: 6px;
align-items: center;
margin-bottom: 14px;
}
.per-btn {
padding: 6px 16px;
border: 1px solid #d0d0d0;
background: #fff;
border-radius: 6px;
font-size: 13px;
cursor: pointer;
color: #555;
}
.per-btn.active {
background: #4f46e5;
color: #fff;
border-color: #4f46e5;
}
.per-info {
margin-left: auto;
font-size: 13px;
color: #888;
}
.pivot-scroll {
overflow-x: auto;
max-width: 100%;
}
#pivotTable {
border-collapse: collapse;
font-size: 13px;
min-width: 100%;
}
#pivotTable th, #pivotTable td {
padding: 6px 8px;
border: 1px solid #e5e5e5;
white-space: nowrap;
vertical-align: middle;
}
#pivotTable th {
background: #f0f2f5;
font-weight: 600;
color: #444;
position: sticky;
top: 0;
z-index: 1;
}
#pivotTable thead th:first-child {
position: sticky;
left: 0;
z-index: 2;
background: #f0f2f5;
}
#pivotTable td:first-child {
position: sticky;
left: 0;
background: #fff;
font-weight: 500;
z-index: 0;
min-width: 160px;
border-right: 2px solid #d0d0d0;
}
#pivotTable tr:hover td {
background: #f8f9fc;
}
#pivotTable tr:hover td:first-child {
background: #f0f2f5;
}
.pivot-subject {
cursor: pointer;
font-weight: 700;
color: #1a1a2e;
}
.pivot-subject .toggle {
display: inline-block;
width: 16px;
font-size: 11px;
transition: transform 0.15s;
}
.pivot-subject .toggle.open {
transform: rotate(90deg);
}
.pivot-teacher {
padding-left: 20px !important;
color: #555;
}
.pivot-student {
padding-left: 36px !important;
font-size: 12px;
color: #666;
}
.pivot-cell {
text-align: center;
font-variant-numeric: tabular-nums;
color: #333;
}
.pivot-hidden { display: none; }
.control-tabs {
display: flex;
gap: 0;
margin-bottom: 12px;
}
.ctrl-tab {
padding: 7px 18px;
border: 1px solid #d0d0d0;
background: #fff;
font-size: 13px;
cursor: pointer;
color: #555;
}
.ctrl-tab:first-child { border-radius: 6px 0 0 6px; }
.ctrl-tab:last-child { border-radius: 0 6px 6px 0; }
.ctrl-tab.active {
background: #4f46e5;
color: #fff;
border-color: #4f46e5;
}
.control-filters {
display: flex;
gap: 16px;
align-items: center;
margin-bottom: 12px;
font-size: 13px;
}
.control-filters label {
cursor: pointer;
display: flex;
align-items: center;
gap: 4px;
}
.control-filters input[type="checkbox"] {
cursor: pointer;
}
.control-filters input[type="number"] {
padding: 4px 6px;
border: 1px solid #d0d0d0;
border-radius: 4px;
font-size: 13px;
}
#controlTable td.missing {
background: #fee2e2;
color: #991b1b;
font-style: italic;
}
#controlTable tr.red-row td {
background: #fee2e2;
}
#controlTable td.grades-cell {
max-width: 300px;
white-space: normal;
word-break: break-all;
font-size: 12px;
}
#controlTable tr.red-row td {
background: #fee2e2;
}
#controlTable tr.green-row td {
background: #dcfce7;
}
.chain-mini {
border-collapse: collapse;
display: inline-table;
vertical-align: middle;
}
.chain-mini td {
padding: 2px 5px;
border: 1px solid #e5e5e5;
font-size: 12px;
text-align: center;
background: #fff;
}
.cm-date {
color: #888;
font-size: 11px !important;
}
.cm-grade {
font-weight: 600;
min-width: 22px;
}
.cm-bad {
color: #dc2626;
}
.control-filters select {
padding: 4px 8px;
border: 1px solid #d0d0d0;
border-radius: 4px;
font-size: 13px;
cursor: pointer;
}
.dvoiki-pills {
display: flex;
gap: 6px;
flex-wrap: wrap;
}
.pill {
padding: 7px 16px;
border: 1px solid #d0d0d0;
background: #fff;
border-radius: 20px;
font-size: 13px;
cursor: pointer;
transition: all 0.15s;
color: #555;
}
.pill:hover {
border-color: #4f46e5;
color: #4f46e5;
}
.pill.active {
background: #4f46e5;
color: #fff;
border-color: #4f46e5;
}
.pill-badge {
display: inline-flex;
align-items: center;
justify-content: center;
min-width: 18px;
height: 18px;
border-radius: 9px;
background: #dc2626;
color: #fff;
font-size: 11px;
font-weight: 700;
padding: 0 5px;
margin-left: 4px;
}
.dvoiki-cards {
display: grid;
grid-template-columns: repeat(auto-fill, minmax(420px, 1fr));
gap: 14px;
margin-top: 14px;
}
.d-card {
background: #fff;
border-radius: 12px;
padding: 16px 18px;
border: 1px solid #e5e5e5;
box-shadow: 0 1px 4px rgba(0,0,0,0.04);
}
.d-card.unresolved {
border-left: 4px solid #dc2626;
}
.d-card.resolved {
border-left: 4px solid #16a34a;
}
.d-card-top {
display: flex;
justify-content: space-between;
align-items: center;
margin-bottom: 8px;
}
.d-card-status {
font-size: 12px;
color: #888;
}
.d-card-steps {
font-size: 11px;
color: #aaa;
}
.d-card-student {
font-size: 15px;
font-weight: 600;
color: #1a1a2e;
margin-bottom: 3px;
}
.d-card-subject {
font-size: 13px;
color: #666;
margin-bottom: 12px;
}
.step-grid {
display: flex;
flex-wrap: wrap;
gap: 4px;
}
.step {
display: flex;
flex-direction: column;
align-items: center;
min-width: 42px;
}
.step-date {
font-size: 10px;
color: #999;
margin-bottom: 3px;
}
.step-grade {
width: 28px;
height: 28px;
border-radius: 6px;
display: flex;
align-items: center;
justify-content: center;
font-size: 13px;
font-weight: 700;
color: #fff;
}
.s-2 { background: #dc2626; }
.s-3 { background: #f59e0b; }
.s-45 { background: #16a34a; }
.s-sym { background: #e5e5e5; color: #888; }
.s-stop {
background: #fff;
color: #dc2626;
border: 2px solid #dc2626;
font-weight: 900;
}
.s-empty {
background: #fff;
color: #999;
border: 1px dashed #ccc;
font-weight: 400;
}
.pagination {
display: flex;
justify-content: center;
align-items: center;
gap: 12px;
margin-top: 16px;
font-size: 14px;
}
.pagination button {
padding: 6px 14px;
font-size: 13px;
}
@media (max-width: 640px) {
.upload-section form { flex-direction: column; }
button { width: 100%; }
.tabs { overflow-x: auto; }
.tab { padding: 10px 14px; font-size: 13px; }
}