:root {
    color-scheme: light;
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    color: #172033;
    background: #f3f6fb;
    font-synthesis: none;
}

* { box-sizing: border-box; }
body { margin: 0; min-width: 320px; }
button, input { font: inherit; }
a { color: inherit; }
.container { width: min(1120px, calc(100% - 40px)); margin: 56px auto 32px; }
.hero { display: flex; align-items: center; justify-content: space-between; gap: 24px; margin-bottom: 28px; }
h1, h2, h3, p { margin-top: 0; }
h1 { margin-bottom: 10px; font-size: clamp(2rem, 4vw, 3rem); letter-spacing: -0.045em; }
h2 { margin-bottom: 0; font-size: 1.25rem; }
.hero p { margin-bottom: 0; color: #64748b; }
.eyebrow { display: block; margin-bottom: 10px; color: #4f46e5; font-size: 0.75rem; font-weight: 800; letter-spacing: 0.12em; text-transform: uppercase; }
.panel { overflow: hidden; background: #fff; border: 1px solid #e3e9f2; border-radius: 18px; box-shadow: 0 16px 45px rgb(35 48 74 / 7%); }
.form-panel { padding: 28px; }
.panel-heading { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 22px 26px; border-bottom: 1px solid #e8edf4; }
.form-panel .panel-heading { padding: 0 0 22px; margin-bottom: 24px; }
.count { padding: 5px 10px; border-radius: 999px; background: #eef2ff; color: #4f46e5; font-size: 0.8rem; font-weight: 700; }
.button { display: inline-flex; align-items: center; justify-content: center; min-height: 42px; padding: 10px 17px; border: 0; border-radius: 10px; text-decoration: none; font-weight: 750; cursor: pointer; transition: transform 120ms ease, background 120ms ease; }
.button:hover { transform: translateY(-1px); }
.button-primary { background: #4f46e5; color: #fff; }
.button-primary:hover { background: #4338ca; }
.button-secondary { border: 1px solid #d8e0ec; background: #fff; color: #334155; }
.button-secondary:hover { background: #f8fafc; }
.button-danger { background: #fff1f2; color: #be123c; }
.button-danger:hover { background: #ffe4e6; }
.button-small { min-height: 34px; padding: 6px 11px; font-size: 0.83rem; }
.alert { margin-bottom: 20px; padding: 15px 18px; border-radius: 12px; }
.alert-success { border: 1px solid #a7f3d0; background: #ecfdf5; color: #047857; }
.alert-error { border: 1px solid #fecdd3; background: #fff1f2; color: #9f1239; }
.alert-error ul { margin: 8px 0 0; padding-left: 20px; }
.table-wrapper { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; }
th, td { padding: 17px 24px; text-align: left; border-bottom: 1px solid #edf1f6; vertical-align: middle; }
th { background: #f8fafc; color: #64748b; font-size: 0.74rem; letter-spacing: 0.06em; text-transform: uppercase; }
tbody tr:last-child td { border-bottom: 0; }
.login-badge { display: inline-block; padding: 4px 9px; border-radius: 6px; background: #f1f5f9; font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 0.85rem; }
.actions { display: flex; justify-content: flex-end; gap: 8px; white-space: nowrap; }
.actions form { margin: 0; }
form .field { margin-bottom: 20px; }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
.field label { display: block; margin-bottom: 7px; color: #334155; font-size: 0.9rem; font-weight: 700; }
.field input { width: 100%; height: 46px; padding: 10px 12px; border: 1px solid #ccd6e4; border-radius: 9px; background: #fff; color: #172033; outline: none; }
.field input:focus { border-color: #6366f1; box-shadow: 0 0 0 3px rgb(99 102 241 / 14%); }
.field small { display: block; margin-top: 7px; color: #64748b; line-height: 1.45; }
.empty-state { padding: 58px 24px; text-align: center; }
.empty-state h3 { margin-bottom: 8px; }
.empty-state p { margin-bottom: 22px; color: #64748b; }
footer { padding: 24px 0; color: #64748b; font-size: 0.85rem; text-align: center; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }

@media (max-width: 760px) {
    .container { width: min(100% - 24px, 1120px); margin-top: 28px; }
    .hero { align-items: flex-start; flex-direction: column; }
    .form-grid { grid-template-columns: 1fr; gap: 0; }
    .form-panel { padding: 20px; }
    th { display: none; }
    table, tbody, tr, td { display: block; width: 100%; }
    tr { padding: 16px 20px; border-bottom: 1px solid #e8edf4; }
    td { display: grid; grid-template-columns: 90px 1fr; gap: 10px; padding: 6px 0; border: 0; }
    td::before { content: attr(data-label); color: #64748b; font-size: 0.75rem; font-weight: 700; text-transform: uppercase; }
    td.actions { display: flex; padding-top: 14px; }
    td.actions::before { display: none; }
}
