:root {
    --bg: #101522;
    --panel: #171f31;
    --panel2: #202a40;
    --text: #edf2ff;
    --muted: #aeb9d4;
    --line: #2f3b56;
    --accent: #58a6ff;
    --good: #25c26e;
    --warn: #f5b83d;
    --bad: #ff6b6b;
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--bg); color: var(--text); font-family: Arial, Helvetica, sans-serif; }
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
.topbar { display: flex; justify-content: space-between; align-items: center; gap: 20px; padding: 16px 24px; background: #0b1020; border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 2; }
.brand { font-weight: 800; font-size: 20px; letter-spacing: .3px; }
.topbar nav { display: flex; gap: 14px; flex-wrap: wrap; }
.topbar nav a { color: var(--text); opacity: .92; }
.container { width: min(1180px, calc(100% - 32px)); margin: 24px auto 70px; }
.footer { border-top: 1px solid var(--line); padding: 18px 24px; color: var(--muted); text-align: center; }
.card { background: linear-gradient(180deg, var(--panel), #131b2b); border: 1px solid var(--line); border-radius: 16px; padding: 22px; margin-bottom: 18px; box-shadow: 0 14px 40px rgba(0,0,0,.2); }
.card h1, .card h2, .card h3 { margin-top: 0; }
.grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 16px; }
.stat { background: var(--panel2); border: 1px solid var(--line); border-radius: 14px; padding: 18px; }
.stat .num { font-size: 30px; font-weight: 800; margin-top: 8px; }
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; min-width: 760px; }
th, td { text-align: left; border-bottom: 1px solid var(--line); padding: 12px 10px; vertical-align: top; }
th { color: #cdd7ef; background: rgba(255,255,255,.03); font-size: 13px; text-transform: uppercase; letter-spacing: .04em; }
tr:hover td { background: rgba(255,255,255,.025); }
.form-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 14px; }
label { display: block; color: var(--muted); margin-bottom: 6px; font-size: 14px; }
input, select, textarea { width: 100%; background: #0f1627; color: var(--text); border: 1px solid var(--line); border-radius: 10px; padding: 11px 12px; outline: none; }
textarea { min-height: 120px; resize: vertical; }
input:focus, select:focus, textarea:focus { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(88,166,255,.12); }
.btn, button { display: inline-flex; align-items: center; justify-content: center; gap: 8px; background: var(--accent); color: #07111f; border: none; border-radius: 10px; padding: 10px 14px; font-weight: 700; cursor: pointer; text-decoration: none; }
.btn:hover, button:hover { filter: brightness(1.06); text-decoration: none; }
.btn.secondary, button.secondary { background: #2a3550; color: var(--text); }
.btn.danger, button.danger { background: var(--bad); color: #1b0606; }
.btn.good, button.good { background: var(--good); color: #04150b; }
.actions { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.badge { display: inline-block; border-radius: 999px; padding: 5px 10px; font-size: 12px; font-weight: 700; }
.badge.active, .badge.paid { background: rgba(37,194,110,.16); color: #72e6aa; }
.badge.pending { background: rgba(245,184,61,.16); color: #ffd074; }
.badge.suspended, .badge.rejected, .badge.unpaid { background: rgba(255,107,107,.16); color: #ff9a9a; }
.badge.info { background: rgba(88,166,255,.16); color: #99c9ff; }
.alert { border-radius: 12px; padding: 12px 14px; margin-bottom: 14px; border: 1px solid var(--line); }
.alert-success { background: rgba(37,194,110,.14); color: #9ff2c4; }
.alert-error { background: rgba(255,107,107,.14); color: #ffb6b6; }
.alert-info { background: rgba(88,166,255,.14); color: #b8dcff; }
.help-block { line-height: 1.65; color: #dce5fa; }
.small { color: var(--muted); font-size: 13px; }
.hero { display: grid; grid-template-columns: 1.2fr .8fr; gap: 18px; align-items: center; }
@media (max-width: 760px) { .hero { grid-template-columns: 1fr; } .topbar { align-items: flex-start; flex-direction: column; } }

.log-preview { white-space: pre-wrap; max-height: 180px; overflow: auto; background: #0f1627; border: 1px solid var(--line); border-radius: 10px; padding: 10px; color: var(--muted); }
.badge.uploaded { background: rgba(88,166,255,.16); color: #99c9ff; }
.badge.processed { background: rgba(37,194,110,.16); color: #72e6aa; }
.badge.failed { background: rgba(255,107,107,.16); color: #ff9a9a; }
.badge.open { background: rgba(88,166,255,.16); color: #99c9ff; }
.badge.in_progress { background: rgba(245,184,61,.16); color: #ffd074; }
.badge.shipped { background: rgba(37,194,110,.16); color: #72e6aa; }
.badge.completed { background: rgba(37,194,110,.16); color: #72e6aa; }
.badge.cancelled { background: rgba(255,107,107,.16); color: #ff9a9a; }

.shipping-box { margin-top: 7px; padding: 9px 10px; background: rgba(255,255,255,.035); border: 1px solid var(--line); border-radius: 10px; line-height: 1.55; }
.compact-form p { margin: 0 0 9px; }
.compact-form textarea { min-height: 72px; }

.stat-warn { border-color: rgba(245,184,61,.45); background: linear-gradient(180deg, rgba(245,184,61,.12), var(--panel2)); }
.stat-info { border-color: rgba(88,166,255,.45); background: linear-gradient(180deg, rgba(88,166,255,.12), var(--panel2)); }
.stat-good { border-color: rgba(37,194,110,.42); background: linear-gradient(180deg, rgba(37,194,110,.10), var(--panel2)); }
.dashboard-actions { margin-top: 16px; }
