* { box-sizing: border-box; }
body { font-family: Arial, sans-serif; margin: 0; background: #f5f6fa; color: #222; }
a { color: #0c63e7; text-decoration: none; }
a:hover { text-decoration: underline; }
.layout { display: grid; grid-template-columns: 240px 1fr; min-height: 100vh; }
.sidebar { background: #0c63e7; color: #fff; padding: 20px 16px; display: flex; flex-direction: column; gap: 24px; }
.sidebar .brand { display: flex; flex-direction: column; align-items: flex-start; gap: 6px; font-weight: bold; font-size: 18px; }
.brand-logo { height: 48px; width: auto; display: block; }
.menu { display: flex; flex-direction: column; gap: 10px; }
.menu a { color: #fff; padding: 10px 12px; border-radius: 8px; text-decoration: none; }
.menu a:hover { background: rgba(255,255,255,0.12); }
.content { padding: 24px; max-width: 1400px; width: 100%; margin: 0 auto; }
.card { background: #fff; border-radius: 8px; padding: 16px; margin-bottom: 16px; box-shadow: 0 1px 3px rgba(0,0,0,0.08); }
.card-header { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
h1 { margin-top: 0; }
form { display: flex; flex-direction: column; gap: 12px; }
label { display: flex; flex-direction: column; font-size: 14px; gap: 4px; }
input, select, button { padding: 10px; border: 1px solid #d0d3da; border-radius: 6px; font-size: 14px; }
button, .button { background: #0c63e7; color: #fff; border: 1px solid transparent; cursor: pointer; text-align: center; border-radius: 6px; }
.button { display: inline-block; padding: 10px 12px; border-radius: 6px; border: 1px solid transparent; }
button:hover, .button:hover { background: #0a51bf; }
.filter-actions { display: flex; align-items: flex-end; gap: 8px; }
.filter-actions button,
.filter-actions .button { min-width: 110px; text-align: center; }
.filter-actions .button { display: inline-flex; align-items: center; justify-content: center; }
.alert { padding: 10px; border-radius: 6px; }
.alert-error { background: #ffe3e3; color: #b30000; }
.alert-success { background: #e7f7e7; color: #1f7a1f; }
.table { --cols: 4; display: grid; grid-template-columns: repeat(1, 1fr); gap: 8px; }
.table-row { display: grid; grid-template-columns: repeat(var(--cols), minmax(120px, 1fr)); gap: 8px; padding: 10px; background: #f9fafc; border-radius: 6px; align-items: center; }
.table-3 { --cols: 3; }
.table-5 { --cols: 5; }
.table-6 { --cols: 6; }
.table-head { background: #eef1f7; font-weight: bold; }
.table-row div { overflow-wrap: anywhere; }
.users-table .table-row { grid-template-columns: 1.6fr 1.8fr 1fr 0.6fr 2.6fr; }
.users-table .table-actions { flex-wrap: nowrap; }
.forms-table .table-row { grid-template-columns: 1.6fr 1.8fr 1.4fr 0.9fr 1.6fr 2.7fr; }
.forms-table .table-actions { flex-wrap: nowrap; }
.grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 12px; }
.grid.two-cols { grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); }
.weekdays { display: flex; gap: 10px; flex-wrap: wrap; }
.checkbox { flex-direction: row; align-items: center; gap: 8px; }
.narrow { max-width: 420px; margin: 0 auto; }
.login-card { text-align: center; }
.login-logo { margin-bottom: 8px; }
.login-logo img { height: 64px; width: auto; }
.table-actions { display: flex; gap: 8px; align-items: center; }
.button.ghost { background: transparent; color: #0c63e7; border: 1px solid #0c63e7; border-radius: 6px; }
.button.ghost:hover { background: #e9f1ff; }
button.danger { background: #c0392b; }
button.danger:hover { background: #992d22; }
.tag { display: inline-block; padding: 2px 8px; border-radius: 999px; font-size: 12px; margin-left: 6px; background: #eef1f7; color: #222; }
.tag.danger { background: #ffe3e3; color: #b30000; }
.pagination { display: flex; gap: 12px; align-items: center; margin-top: 12px; }
.form-preview { display: flex; flex-direction: column; gap: 12px; }
.form-section { margin: 12px 0 4px; border-bottom: 1px solid #dfe3eb; padding-bottom: 6px; }
.checkbox.disabled { opacity: 0.7; }
@media (max-width: 900px) {
    .layout { grid-template-columns: 1fr; }
    .sidebar { flex-direction: row; align-items: center; justify-content: space-between; }
    .menu { flex-direction: row; flex-wrap: wrap; }
    .content { padding: 16px; }
}
@media (max-width: 640px) {
    .table-row { grid-template-columns: repeat(2, 1fr); }
    .table-head { display: none; }
}
