* { box-sizing: border-box; }
body {
    font-family: -apple-system, Segoe UI, Roboto, Arial, sans-serif;
    background: #f4f6f9;
    color: #1f2937;
    margin: 0;
}
.wrap { max-width: 1200px; margin: 0 auto; padding: 24px 20px 60px; }
h1 { font-size: 22px; margin: 8px 0 4px; }
h2 { font-size: 17px; margin: 28px 0 10px; color: #2f5597; }
.muted { color: #6b7280; font-size: 13px; }

.nav {
    display: flex; gap: 4px; margin-bottom: 18px;
    border-bottom: 2px solid #e5e7eb;
}
.nav a {
    padding: 10px 18px; text-decoration: none; color: #4b5563; font-weight: 600; font-size: 14px;
    border-bottom: 2px solid transparent; margin-bottom: -2px;
}
.nav a.active, .nav a:hover { color: #2f5597; border-bottom-color: #2f5597; }

.page-head { display: flex; align-items: center; justify-content: space-between; }

.card {
    background: #fff; border: 1px solid #e5e7eb; border-radius: 10px;
    padding: 20px; max-width: 520px; margin: 16px 0 30px;
}
.field { margin-bottom: 14px; }
.field label { display: block; font-weight: 600; font-size: 13px; margin-bottom: 6px; }
.field input[type="file"] { width: 100%; }

.btn {
    display: inline-block; background: #2f5597; color: #fff; border: none;
    padding: 10px 18px; border-radius: 6px; font-size: 14px; font-weight: 600;
    cursor: pointer; text-decoration: none;
}
.btn:hover { background: #24417a; }
.btn-secondary { background: #6b7280; }
.btn-secondary:hover { background: #4b5563; }

.alert { padding: 12px 16px; border-radius: 8px; margin: 14px 0; font-size: 14px; }
.alert-success { background: #dcfce7; color: #166534; border: 1px solid #86efac; }
.alert-error { background: #fee2e2; color: #991b1b; border: 1px solid #fca5a5; }
.alert ul { margin: 6px 0 0 18px; }

.filters { display: flex; gap: 8px; margin: 10px 0 6px; flex-wrap: wrap; }
.filters input[type="text"] {
    flex: 1; min-width: 240px; padding: 9px 12px; border: 1px solid #d1d5db; border-radius: 6px; font-size: 14px;
}
.filters select { padding: 9px 12px; border: 1px solid #d1d5db; border-radius: 6px; font-size: 14px; }

.table-scroll { overflow-x: auto; background: #fff; border: 1px solid #e5e7eb; border-radius: 10px; }
table.grid { width: 100%; border-collapse: collapse; font-size: 13px; white-space: nowrap; }
table.grid th {
    background: #2f5597; color: #fff; text-align: left; padding: 10px 12px; position: sticky; top: 0;
}
table.grid td { padding: 8px 12px; border-bottom: 1px solid #eef0f3; }
table.grid tr:hover td { background: #f8fafc; }

.pagination { display: flex; align-items: center; gap: 14px; margin-top: 16px; font-size: 14px; }
.pagination a { color: #2f5597; text-decoration: none; font-weight: 600; }
.pagination a:hover { text-decoration: underline; }
