* { box-sizing: border-box; margin: 0; padding: 0; font-family: 'Segoe UI', Tahoma, sans-serif; }
body { background: #0b1626; color: #eaf2fb; min-height: 100vh; }
#splash { position: fixed; inset: 0; background: #0b1626; display: flex; flex-direction: column; align-items: center; justify-content: center; z-index: 99; gap: 10px; transition: opacity .5s; }
#splash img { width: 120px; }
.splash-name { font-size: 22px; font-weight: 800; letter-spacing: 2px; color: #0058a8; }
.splash-sub { font-size: 13px; color: #8aa2bf; }
.splash-spin { width: 26px; height: 26px; border: 3px solid #1d3252; border-top-color: #0058a8; border-radius: 50%; animation: sp 1s linear infinite; margin-top: 8px; }
@keyframes sp { to { transform: rotate(360deg); } }
#app { display: flex; min-height: 100vh; }
#sidebar { width: 215px; background: #0e1c30; border-left: 1px solid #1d3252; padding: 16px 12px; display: flex; flex-direction: column; position: fixed; top: 0; bottom: 0; right: 0; overflow-y: auto; }
.brand { text-align: center; padding-bottom: 14px; border-bottom: 1px solid #1d3252; margin-bottom: 12px; }
.brand-logo { width: 78px; }
.brand-sub { font-size: 12px; color: #8aa2bf; margin-top: 4px; }
#nav { display: flex; flex-direction: column; gap: 6px; flex: 1; }
#nav a { padding: 13px 14px; border-radius: 10px; cursor: pointer; font-size: 16px; font-weight: 600; color: #c9d8ea; transition: .15s; }
#nav a:hover { background: #16273f; }
#nav a.active { background: #0058a8; color: #fff; }
.side-foot { font-size: 10px; color: #54687f; text-align: center; padding-top: 10px; }
#main { flex: 1; margin-right: 215px; padding: 18px 22px; }
#topbar { display: flex; justify-content: space-between; align-items: center; padding-bottom: 14px; border-bottom: 1px solid #1d3252; margin-bottom: 18px; }
#page-title { font-size: 22px; font-weight: 800; }
#today { color: #8aa2bf; font-size: 13px; }
.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 12px; margin-bottom: 18px; }
.card { background: #0e1c30; border: 1px solid #1d3252; border-radius: 14px; padding: 16px; }
.card-label { font-size: 13px; color: #8aa2bf; margin-bottom: 6px; }
.card-value { font-size: 26px; font-weight: 800; }
.ok-text { color: #2ecc71; } .danger-text { color: #e74c3c; } .warn-text { color: #f39c12; } .muted { color: #8aa2bf; } .small { font-size: 12px; }
.tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 14px; margin-bottom: 18px; }
.tile { background: linear-gradient(135deg, #0e1c30, #122540); border: 1px solid #1d3252; border-radius: 14px; padding: 22px 14px; text-align: center; cursor: pointer; font-size: 17px; font-weight: 700; transition: .15s; }
.tile:hover { border-color: #0058a8; transform: translateY(-2px); }
.tile .ic { font-size: 30px; display: block; margin-bottom: 8px; }
.btn { background: #1d3252; color: #eaf2fb; border: none; padding: 11px 18px; border-radius: 10px; cursor: pointer; font-size: 15px; font-weight: 600; }
.btn:hover { background: #264475; }
.btn-primary { background: #0058a8; } .btn-primary:hover { background: #006bc9; }
.btn-green { background: #1e8e4f; } .btn-red { background: #b03a3a; } .btn-danger { background: #b03a3a; }
.btn-block { width: 100%; margin-top: 12px; font-size: 17px; padding: 14px; }
.btn-sm { padding: 6px 12px; font-size: 13px; }
.mb { margin-bottom: 14px; } .mt { margin-top: 12px; } .row { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.tbl-wrap { overflow-x: auto; }
.tbl { width: 100%; border-collapse: collapse; font-size: 15px; }
.tbl th { text-align: right; padding: 10px 12px; color: #8aa2bf; font-size: 13px; border-bottom: 1px solid #1d3252; }
.tbl td { padding: 11px 12px; border-bottom: 1px solid #14243a; }
.num { font-weight: 700; }
.empty-row { text-align: center; color: #54687f; padding: 30px !important; }
.f { display: block; margin-bottom: 12px; }
.f > span { display: block; font-size: 13px; color: #8aa2bf; margin-bottom: 5px; }
input, select { background: #0b1626; border: 1px solid #1d3252; color: #eaf2fb; padding: 11px 12px; border-radius: 9px; font-size: 15px; width: 100%; }
input:focus, select:focus { outline: none; border-color: #0058a8; }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.totals .r { display: flex; justify-content: space-between; align-items: center; padding: 10px 4px; border-bottom: 1px dashed #1d3252; font-size: 15px; }
.totals .r.g { font-size: 19px; font-weight: 800; color: #0058a8; border-bottom: none; }
.totals .r input, .totals .r select { width: 150px; }
.modal-bg { position: fixed; inset: 0; background: rgba(4,10,20,.75); display: flex; align-items: center; justify-content: center; z-index: 50; }
.modal { background: #0e1c30; border: 1px solid #1d3252; border-radius: 16px; padding: 20px; width: 480px; max-width: 94vw; max-height: 88vh; overflow-y: auto; }
.modal h3 { margin-bottom: 14px; font-size: 18px; }
.modal-foot { margin-top: 16px; display: flex; gap: 10px; }
.modal-x { position: absolute; top: 12px; left: 14px; background: none; border: none; color: #8aa2bf; font-size: 20px; cursor: pointer; }
#toast { position: fixed; bottom: 22px; right: 50%; transform: translateX(50%); z-index: 60; display: flex; flex-direction: column; gap: 8px; align-items: center; }
.toast { background: #0e1c30; border: 1px solid #0058a8; padding: 12px 22px; border-radius: 12px; font-size: 15px; font-weight: 600; }
.toast.err { border-color: #e74c3c; }
.badge { background: #1d3252; padding: 4px 10px; border-radius: 20px; font-size: 12px; }
.badge.danger { background: #b03a3a; color: #fff; }
.badge.ok { background: #1e8e4f; color: #fff; }
.badge.warn { background: #8a6d1a; color: #fff; }
.chip { padding: 8px 16px; border-radius: 20px; border: 1px solid #1d3252; background: #0b1626; cursor: pointer; font-size: 14px; font-weight: 600; }
.chip.active { background: #0058a8; border-color: #0058a8; color: #fff; }

/* svg icons */
#nav a { display: flex; align-items: center; gap: 10px; }
#nav a svg { width: 19px; height: 19px; flex: none; }
.tile .ic svg { width: 32px; height: 32px; }
.btn svg, .btn-sm svg { width: 15px; height: 15px; vertical-align: -2px; }
