:root { --brand:#1f3a5f; --line:#ddd; }
* { box-sizing:border-box; }
body { margin:0; font-family:system-ui,Segoe UI,Arial,sans-serif; background:#f2f4f7; color:#222; }
a { color:#1f4e79; text-decoration:none; }
.shell { display:flex; min-height:100vh; }
aside { width:200px; background:var(--brand); padding:12px; display:flex; flex-direction:column; flex-shrink:0; }
aside a { color:#dfe8f5; padding:8px 10px; border-radius:4px; }
aside a:hover { background:#2d5086; }
.brand { color:#fff; font-weight:700; font-size:1.1rem; padding:8px 10px 16px; }
.who { color:#9fb3d1; padding:16px 10px 4px; font-size:.9rem; margin-top:auto; }
main { flex:1; padding:20px 28px; min-width:0; }
.login { max-width:380px; margin:10vh auto; }
.panel { background:#fff; border:1px solid var(--line); border-radius:6px; padding:16px; margin-bottom:16px; }
.stats { display:grid; grid-template-columns:repeat(auto-fill,minmax(170px,1fr)); gap:12px; }
.stat b { display:block; font-size:1.8rem; }
table { width:100%; border-collapse:collapse; background:#fff; }
th, td { padding:8px 10px; border-bottom:1px solid var(--line); text-align:left; font-size:.92rem; vertical-align:top; }
th { background:#f7f8fa; }
.table-wrap { overflow-x:auto; }
label { display:block; margin:10px 0 4px; font-weight:600; font-size:.9rem; }
input, select, textarea { width:100%; padding:8px; border:1px solid #bbb; border-radius:4px; font:inherit; }
input[type=checkbox] { width:auto; }
.btn { background:var(--brand); color:#fff; border:0; padding:8px 14px; border-radius:4px; cursor:pointer; font:inherit; }
.btn.sm { padding:3px 9px; font-size:.85rem; }
.btn.red { background:#b3261e; }
.btn.gray { background:#6b7280; }
.btn:disabled { opacity:.4; }
.row { display:flex; gap:8px; flex-wrap:wrap; align-items:center; margin-bottom:12px; }
.row input, .row select { width:auto; }
.grid2 { display:grid; grid-template-columns:1fr 1fr; gap:0 16px; }
.badge { padding:2px 8px; border-radius:10px; background:#e5e7eb; font-size:.8rem; }
.badge.paid, .badge.delivered { background:#d1fae5; } .badge.pending { background:#fef3c7; }
.badge.cancelled, .badge.failed, .badge.refunded { background:#fee2e2; }
.low { color:#b3261e; font-weight:700; }
.err { color:#b00020; }
dialog { border:0; border-radius:8px; padding:20px; width:min(640px,95vw); box-shadow:0 10px 40px #0005; }
img.thumb { width:40px; height:56px; object-fit:cover; border-radius:3px; }
#toast { position:fixed; bottom:20px; right:20px; background:#1b7a2b; color:#fff; padding:10px 16px; border-radius:6px; opacity:0; transition:.2s; pointer-events:none; }
#toast.show { opacity:1; } #toast.bad { background:#b00020; }
@media (max-width:700px) { .shell { flex-direction:column; } aside { width:auto; flex-direction:row; flex-wrap:wrap; } .who { margin:0; } .grid2 { grid-template-columns:1fr; } }
