:root {
    --gt-blue: #0d47a1;
    --gt-blue-2: #1565c0;
    --gt-soft: #f3f6fb;
    --gt-gray: #6c757d;
    --gt-dark: #172033;
    --gt-sidebar-gradient-start: #1a237e;
    --gt-sidebar-gradient-end: #3949ab;
    --gt-sidebar-gradient-direction: 180deg;
}

body {
    background: var(--gt-soft);
    color: var(--gt-dark);
    font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.login-page {
    min-height: 100vh;
    background: linear-gradient(135deg, var(--gt-blue), var(--gt-blue-2) 45%, #eef3fb 45%);
}

.login-card {
    border: 0;
    border-radius: 24px;
    overflow: hidden;
    box-shadow: 0 20px 60px rgba(13, 71, 161, .22);
}

.app-layout {
    min-height: 100vh;
    display: flex;
}

.app-sidebar {
    width: 282px;
    background: linear-gradient(var(--gt-sidebar-gradient-direction), var(--gt-sidebar-gradient-start), var(--gt-sidebar-gradient-end));
    color: #fff;
    position: fixed;
    inset: 0 auto 0 0;
    z-index: 1040;
    padding: 22px 18px;
    box-shadow: 10px 0 30px rgba(9, 45, 104, .15);
}

.brand-box {
    display: flex;
    gap: 12px;
    align-items: center;
    margin-bottom: 28px;
    padding: 12px;
    background: rgba(255,255,255,.08);
    border-radius: 18px;
}

.sidebar-gradient-preview {
    min-height: 145px;
    border-radius: 22px;
    background: linear-gradient(var(--gt-sidebar-gradient-direction), var(--gt-sidebar-gradient-start), var(--gt-sidebar-gradient-end));
    color: #fff;
    padding: 18px;
    box-shadow: inset 0 0 0 1px rgba(255,255,255,.16), 0 15px 35px rgba(14,42,86,.12);
}

.sidebar-gradient-preview .preview-pill {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 12px;
    border-radius: 14px;
    background: rgba(255,255,255,.14);
    margin-top: 12px;
}

.brand-icon {
    width: 45px;
    height: 45px;
    border-radius: 14px;
    background: #fff;
    color: var(--gt-blue);
    display: grid;
    place-items: center;
    font-size: 1.35rem;
}


.brand-logo {
    width: 48px;
    height: 48px;
    border-radius: 14px;
    background: #fff;
    object-fit: contain;
    padding: 5px;
    box-shadow: 0 4px 14px rgba(0,0,0,.08);
}

.config-logo-preview {
    width: 110px;
    height: 110px;
    border-radius: 22px;
    object-fit: contain;
    background: #fff;
    border: 1px solid #e8edf5;
    padding: 10px;
}

.receipt-logo {
    width: 72px;
    height: 72px;
    border-radius: 18px;
    object-fit: contain;
    border: 1px solid #e8edf5;
    padding: 8px;
    background: #fff;
}

.report-header {
    border: 1px solid #e8edf5;
    border-radius: 22px;
    padding: 20px;
    background: #fff;
}

.brand-title {
    font-weight: 800;
    letter-spacing: .3px;
    line-height: 1;
}

.sidebar-menu a {
    display: flex;
    align-items: center;
    gap: 12px;
    color: rgba(255,255,255,.84);
    text-decoration: none;
    padding: 12px 14px;
    border-radius: 14px;
    margin-bottom: 7px;
    transition: .18s ease;
}

.sidebar-menu a:hover,
.sidebar-menu a.active {
    color: #fff;
    background: rgba(255,255,255,.14);
    transform: translateX(3px);
}

.sidebar-label {
    color: rgba(255,255,255,.55);
    font-size: .72rem;
    text-transform: uppercase;
    font-weight: 800;
    letter-spacing: .09rem;
    margin: 18px 12px 8px;
}

.app-main {
    flex: 1;
    margin-left: 282px;
    min-width: 0;
}

.topbar {
    min-height: 82px;
    background: #fff;
    border-bottom: 1px solid #e8edf5;
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 16px 28px;
    position: sticky;
    top: 0;
    z-index: 1030;
}

.topbar h1 {
    font-size: clamp(1.2rem, 2vw, 1.65rem);
    margin: 0;
    font-weight: 800;
    color: var(--gt-blue);
}

.user-box { display: flex; align-items: center; gap: 12px; }
.content-wrapper { padding: 28px; }

.card-modern,
.stat-card {
    border: 0;
    border-radius: 22px;
    box-shadow: 0 10px 35px rgba(14, 42, 86, .08);
}

.stat-icon {
    width: 48px;
    height: 48px;
    border-radius: 16px;
    display: grid;
    place-items: center;
    background: rgba(13, 71, 161, .1);
    color: var(--gt-blue);
    font-size: 1.4rem;
}

.btn-primary {
    --bs-btn-bg: var(--gt-blue);
    --bs-btn-border-color: var(--gt-blue);
    --bs-btn-hover-bg: #0b3d8a;
    --bs-btn-hover-border-color: #0b3d8a;
}

.text-primary { color: var(--gt-blue) !important; }
.badge-stock { border-radius: 99px; padding: .45rem .7rem; }

.product-img {
    width: 58px;
    height: 58px;
    object-fit: cover;
    border-radius: 16px;
    border: 1px solid #edf1f7;
    background: #f8f9fa;
}

.product-img-placeholder {
    width: 58px;
    height: 58px;
    border-radius: 16px;
    border: 1px solid #edf1f7;
    background: #f4f7fb;
    display: grid;
    place-items: center;
    color: #8b98aa;
    font-size: 1.25rem;
}

.table > :not(caption) > * > * { vertical-align: middle; }
.receipt-box { max-width: 860px; margin-inline: auto; }
.variant-row { background: #f8fbff; border-radius: 14px; }

@media (max-width: 991.98px) {
    .app-sidebar { transform: translateX(-100%); transition: .25s ease; }
    .app-sidebar.show { transform: translateX(0); }
    .app-main { margin-left: 0; }
    .content-wrapper { padding: 18px; }
}

@media print {
    .app-sidebar, .topbar, .no-print, .dataTables_filter, .dataTables_length, .dataTables_info, .dataTables_paginate { display: none !important; }
    .app-main { margin-left: 0 !important; }
    body { background: #fff; }
    .content-wrapper { padding: 0; }
    .card-modern { box-shadow: none; border: 1px solid #ddd; }
}

.place-items-center { place-items: center; }

.mini-stat {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 16px;
    border: 1px solid #e8edf5;
    border-radius: 18px;
    background: #fff;
}

.mini-stat i {
    width: 42px;
    height: 42px;
    border-radius: 14px;
    display: grid;
    place-items: center;
    background: rgba(13, 71, 161, .1);
    color: var(--gt-blue);
    font-size: 1.2rem;
}

.mini-stat small {
    display: block;
    color: #6c757d;
    font-weight: 600;
}

.mini-stat h4 {
    margin: 0;
    font-weight: 800;
}

.sales-products {
    min-width: 260px;
    max-width: 420px;
    white-space: normal;
    line-height: 1.35;
}
