
* { box-sizing: border-box; margin: 0; padding: 0; }
body { font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif; background: #0f172a; color: #e2e8f0; }
.header { background: linear-gradient(135deg, #1e3a8a, #1e40af); padding: 18px 24px; display: flex; justify-content: space-between; align-items: center; }
.header h1 { font-size: 20px; }
.stats { display: flex; gap: 16px; padding: 14px 24px; background: #1e293b; flex-wrap: wrap; justify-content: center; }
.stat-card { background: #334155; padding: 10px 16px; border-radius: 8px; min-width: 130px; text-align: center; }
.stat-card .label { font-size: 12px; color: #94a3b8; }
.stat-card .value { font-size: 17px; font-weight: 600; color: #fbbf24; margin-top: 2px; }
.controls { padding: 12px 24px; display: flex; gap: 10px; flex-wrap: wrap; background: #1e293b; border-bottom: 1px solid #334155; align-items: center; justify-content: center; }
.controls input, .controls button, .controls select { padding: 7px 12px; border-radius: 6px; border: 1px solid #475569; background: #0f172a; color: #e2e8f0; font-size: 13px; }
.controls button { background: #2563eb; border: none; cursor: pointer; }
.controls button.green { background: #16a34a; }
.controls button:hover { opacity: 0.9; }
.table-wrap { overflow: auto; max-height: calc(100vh - 210px); }
table { width: 100%; border-collapse: collapse; font-size: 13px; }
th { background: #1e293b; position: sticky; top: 0; padding: 9px 6px; text-align: center; border-bottom: 2px solid #334155; cursor: pointer; user-select: none; }
th:hover { background: #334155; }
th .sort-icon { font-size: 10px; margin-left: 4px; opacity: 0.6; }
td { padding: 7px 6px; border-bottom: 1px solid #334155; text-align: center; }
tr:hover td { background: #1e293b; }
.num { font-variant-numeric: tabular-nums; }
.id { font-family: monospace; font-size: 12px; }
.editable { background: #422006; color: #fbbf24; padding: 3px 6px; border-radius: 4px; min-width: 60px; display: inline-block; }
.editable:focus { outline: 2px solid #fbbf24; }
.warn-yellow { background: #854d0e !important; }
.warn-red { background: #7f1d1d !important; }
.modal { display: none; position: fixed; inset: 0; background: rgba(0,0,0,0.65); align-items: center; justify-content: center; z-index: 100; }
.modal.show { display: flex; }
.modal-content { background: #1e293b; padding: 20px; border-radius: 12px; width: 480px; max-width: 92vw; }
.modal-content h3 { margin-bottom: 12px; }
.form-row { margin-bottom: 10px; }
.form-row label { display: block; font-size: 12px; color: #94a3b8; margin-bottom: 3px; }
.form-row input, .form-row select { width: 100%; padding: 7px 10px; border-radius: 6px; border: 1px solid #475569; background: #0f172a; color: #e2e8f0; }
.modal-actions { display: flex; gap: 10px; justify-content: flex-end; margin-top: 14px; }
.hint { font-size: 12px; color: #94a3b8; margin-top: 6px; }

[hidden]{display:none!important} #gate{min-height:100vh;display:grid;place-items:center} #front-login{width:380px;max-width:92vw;background:#1e293b;border:1px solid #334155;border-radius:12px;padding:28px} #front-login h2{font-size:20px;margin-bottom:16px} #front-login p{color:#94a3b8;font-size:13px;line-height:1.8;margin:12px 0} #front-login input{width:100%;padding:12px;border:1px solid #475569;background:#0f172a;color:#e2e8f0;border-radius:6px;margin:10px 0} #front-login button,#front-lock{background:#2563eb;border:0;color:white;padding:10px 16px;border-radius:6px;cursor:pointer} #front-lock{margin-left:12px;padding:6px 10px} .readonly-value{padding:3px 6px;display:inline-block} #login-error{color:#fca5a5!important}
