:root {
    font-family: Inter, Arial, sans-serif;
    color: #1f2937;
    background: #f4f6f8;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    background: #f4f6f8;
}

.topbar {
    background: #111827;
    color: white;
    padding: 24px 32px;
}

.topbar h1 {
    margin: 0 0 5px;
    font-size: 28px;
}

.topbar p {
    margin: 0;
    color: #b7c0ce;
}

.container {
    width: min(1080px, calc(100% - 32px));
    margin: 26px auto;
    display: grid;
    gap: 18px;
}

.card {
    background: white;
    border: 1px solid #d9dee7;
    border-radius: 14px;
    padding: 22px;
}

.section-title,
.table-toolbar {
    display: flex;
    justify-content: space-between;
    gap: 18px;
    align-items: center;
    margin-bottom: 18px;
}

h2 {
    margin: 0;
    font-size: 19px;
}

.section-title p,
.table-toolbar p {
    margin: 5px 0 0;
    color: #6b7280;
    font-size: 13px;
}

.form-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 14px;
}

label span {
    display: block;
    margin-bottom: 7px;
    font-size: 12px;
    font-weight: 700;
    color: #6b7280;
}

input {
    width: 100%;
    border: 1px solid #d9dee7;
    border-radius: 9px;
    padding: 12px 13px;
    font: inherit;
    outline: none;
}

input:focus {
    border-color: #2563eb;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.10);
}

.actions {
    display: flex;
    gap: 10px;
    margin-top: 18px;
}

.btn {
    border: 0;
    border-radius: 9px;
    padding: 11px 16px;
    font-weight: 700;
    cursor: pointer;
}

.primary {
    background: #2563eb;
    color: white;
}

.secondary {
    background: #e5e7eb;
    color: #111827;
}

.danger {
    background: #fee2e2;
    color: #b91c1c;
}

.edit {
    background: #e0e7ff;
    color: #3730a3;
}

.small {
    padding: 7px 10px;
    font-size: 12px;
}

.search {
    max-width: 300px;
}

.badge {
    background: #e0e7ff;
    color: #3730a3;
    border-radius: 999px;
    padding: 7px 11px;
    font-size: 12px;
    font-weight: 700;
}

.hidden {
    display: none;
}

.table-wrap {
    overflow-x: auto;
}

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

th,
td {
    text-align: left;
    padding: 13px 12px;
    border-bottom: 1px solid #edf0f4;
}

th {
    background: #e9eef5;
    font-size: 12px;
}

td:first-child,
th:first-child {
    width: 75px;
}

tbody tr:hover {
    background: #f8fafc;
}

.row-actions {
    display: flex;
    gap: 7px;
}

@media (max-width: 720px) {
    .form-grid {
        grid-template-columns: 1fr;
    }

    .table-toolbar {
        align-items: stretch;
        flex-direction: column;
    }

    .search {
        max-width: none;
    }
}
