:root {
	--bs-primary: #7c3aed;
	--bs-primary-rgb: 124, 58, 237;
	--bs-link-color: #6d28d9;
	--bs-link-hover-color: #5b21b6;
	--jb-dark: #2e1065;
	--jb-mid: #5b21b6;
	--jb-soft: #f5f3ff;
	--jb-line: #e9e3fb;
}
body { background: #f7f5fc; font-size: .9rem; }
.btn-primary { --bs-btn-bg: #7c3aed; --bs-btn-border-color: #7c3aed; --bs-btn-hover-bg: #6d28d9; --bs-btn-hover-border-color: #6d28d9; --bs-btn-active-bg: #5b21b6; --bs-btn-active-border-color: #5b21b6; --bs-btn-disabled-bg: #7c3aed; --bs-btn-disabled-border-color: #7c3aed; }
.btn-outline-primary { --bs-btn-color: #7c3aed; --bs-btn-border-color: #7c3aed; --bs-btn-hover-bg: #7c3aed; --bs-btn-hover-border-color: #7c3aed; --bs-btn-active-bg: #6d28d9; --bs-btn-active-border-color: #6d28d9; }
.text-bg-primary { background-color: #7c3aed !important; }
.form-control:focus, .form-select:focus { border-color: #a78bfa; box-shadow: 0 0 0 .2rem rgba(124, 58, 237, .18); }
.form-check-input:checked { background-color: #7c3aed; border-color: #7c3aed; }

.app-shell { display: flex; min-height: 100vh; }
.sidebar { width: 245px; background: linear-gradient(180deg, var(--jb-dark), #4c1d95); color: #ddd6fe; flex-shrink: 0; position: sticky; top: 0; height: 100vh; overflow-y: auto; }
.sidebar .brand { display: flex; align-items: center; gap: .6rem; padding: 1.1rem 1.2rem; font-weight: 700; font-size: 1.15rem; color: #fff; text-decoration: none; border-bottom: 1px solid rgba(255,255,255,.1); }
.sidebar .brand i { color: #c4b5fd; font-size: 1.5rem; }
.sidebar nav { padding: .6rem; }
.sidebar .nav-link { display: flex; align-items: center; gap: .7rem; color: #ddd6fe; padding: .55rem .8rem; border-radius: .5rem; margin-bottom: 2px; }
.sidebar .nav-link:hover { background: rgba(255,255,255,.08); color: #fff; }
.sidebar .nav-link.active { background: #7c3aed; color: #fff; box-shadow: 0 4px 12px rgba(124,58,237,.4); }
.sidebar .nav-link i { font-size: 1.05rem; width: 1.2rem; text-align: center; }
.main { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.topbar { background: #fff; border-bottom: 1px solid var(--jb-line); padding: .6rem 1.2rem; display: flex; align-items: center; gap: .8rem; position: sticky; top: 0; z-index: 50; }
.page-title { font-size: 1.15rem; font-weight: 600; margin: 0; color: var(--jb-dark); }
.content { padding: 1.2rem; }

.card { border: 1px solid var(--jb-line); border-radius: .75rem; box-shadow: 0 1px 3px rgba(76, 29, 149, .05); }
.card-header { background: #fff; border-bottom: 1px solid var(--jb-line); font-weight: 600; color: var(--jb-dark); }
.table > :not(caption) > * > * { padding: .55rem .7rem; }
.table thead th { background: var(--jb-soft); color: var(--jb-mid); font-weight: 600; white-space: nowrap; border-bottom: 1px solid var(--jb-line); }
.stat { display: flex; align-items: center; gap: .9rem; padding: 1rem; }
.stat .ico { width: 46px; height: 46px; border-radius: 12px; display: grid; place-items: center; font-size: 1.4rem; background: var(--jb-soft); color: #7c3aed; }
.stat .num { font-size: 1.35rem; font-weight: 700; line-height: 1.1; color: var(--jb-dark); }
.stat .lbl { color: #6b7280; font-size: .8rem; }
.page-link { color: #7c3aed; }
.page-item.active .page-link { background: #7c3aed; border-color: #7c3aed; }

/* POS */
.pos-items { display: grid; grid-template-columns: repeat(auto-fill, minmax(118px, 1fr)); gap: .5rem; max-height: 52vh; overflow-y: auto; padding: 2px; }
.pos-item { border: 1px solid var(--jb-line); background: #fff; border-radius: .6rem; padding: .6rem .4rem; text-align: center; cursor: pointer; transition: .12s; }
.pos-item:hover { border-color: #7c3aed; background: var(--jb-soft); transform: translateY(-1px); }
.pos-item .nm { font-weight: 600; font-size: .82rem; }
.pos-item .pr { color: #7c3aed; font-size: .78rem; }
.svc-chip { cursor: pointer; }
.cart-table td, .cart-table th { vertical-align: middle; }
.qty-box { width: 72px; text-align: center; }
.sum-row { display: flex; justify-content: space-between; padding: .2rem 0; }
.sum-total { font-size: 1.25rem; font-weight: 700; color: #5b21b6; border-top: 2px dashed var(--jb-line); margin-top: .4rem; padding-top: .5rem; }

/* auth */
.auth-bg { min-height: 100vh; display: grid; place-items: center; background: radial-gradient(circle at 20% 20%, #a78bfa, #4c1d95 60%, #2e1065); padding: 1rem; }
.auth-card { width: 100%; max-width: 410px; background: #fff; border-radius: 1rem; padding: 2rem; box-shadow: 0 20px 50px rgba(0,0,0,.3); }
.auth-card .logo { width: 62px; height: 62px; border-radius: 16px; background: #7c3aed; color: #fff; display: grid; place-items: center; font-size: 2rem; margin: 0 auto 1rem; }

.timeline { list-style: none; padding-left: 0; margin: 0; }
.timeline li { position: relative; padding: 0 0 1rem 1.6rem; border-left: 2px solid var(--jb-line); margin-left: .5rem; }
.timeline li::before { content: ""; position: absolute; left: -7px; top: 2px; width: 12px; height: 12px; border-radius: 50%; background: #7c3aed; }

@media (max-width: 991px) {
	.sidebar { position: fixed; z-index: 100; left: -260px; transition: left .2s; }
	.sidebar.open { left: 0; }
}
@media print {
	.sidebar, .topbar, .no-print, .dataTables_filter, .dataTables_length, .dataTables_paginate, .dataTables_info { display: none !important; }
	.content { padding: 0; }
	body { background: #fff; }
	.card { box-shadow: none; border: 0; }
}
