:root {
    --csp-primary: #696cff;
}

body {
    font-family: 'Public Sans', 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
}

/* ------------------------------------------------------------------
   Page header (title + breadcrumb) inside Sneat content wrapper
------------------------------------------------------------------- */
.page-title-row {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1.5rem;
}

.page-title-row .page-title {
    font-size: 1.4rem;
    margin-bottom: 0;
}

.csp-breadcrumb {
    background: transparent;
    margin-bottom: 0;
}

.csp-breadcrumb .breadcrumb-item + .breadcrumb-item::before {
    color: #a3a4cc;
}

/* ------------------------------------------------------------------
   Cards (AdminLTE-style header tools + spacing)
------------------------------------------------------------------- */
.card {
    margin-bottom: 1.25rem;
}

.card-header {
    position: relative;
    padding: 1rem 1.25rem;
    border-bottom: 1px solid rgba(105, 108, 255, 0.12);
}

.card-header .card-title {
    display: inline-block;
    font-size: 1.05rem;
    font-weight: 600;
    color: #566a7f;
    margin-bottom: 0;
    margin-right: 0.75rem;
    vertical-align: middle;
}

.card-tools {
    float: right;
    margin-top: -0.15rem;
    vertical-align: middle;
}

.card-header::after {
    content: '';
    display: table;
    clear: both;
}

.card-header .card-tools .btn + .btn,
.card-header .card-tools form:not(:first-of-type) {
    margin-left: 0.25rem;
}

.card-body {
    padding: 1.25rem;
}

.card.card-outline {
    border: 0;
    border-top: 3px solid #696cff;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
}

.card.card-primary.card-outline {
    border-top-color: #696cff;
}

.card.card-secondary.card-outline {
    border-top-color: #8592a3;
}

.card.card-success.card-outline {
    border-top-color: #71dd37;
}

/* ------------------------------------------------------------------
   Forms: Bootstrap 4 compatibility (form-group, switches, custom-file)
------------------------------------------------------------------- */
.form-group {
    margin-bottom: 1.25rem;
}

.form-group label {
    display: inline-block;
    margin-bottom: 0.5rem;
    font-weight: 500;
}

.card-body .card-title {
    margin-bottom: 0.85rem;
}

.btn-block {
    display: block;
    width: 100%;
}

/* Bootstrap 4 custom-control / custom-switch emulation */
.custom-control {
    position: relative;
    display: block;
    min-height: 1.5rem;
    padding-left: 1.6rem;
}

.custom-control-inline {
    display: inline-flex;
    margin-right: 1rem;
}

.custom-control-input {
    position: absolute;
    z-index: -1;
    opacity: 0;
    width: 1rem;
    height: 1.15rem;
    margin-top: 0.18rem;
    left: 0;
}

.custom-control-input:focus ~ .custom-control-label::before {
    box-shadow: 0 0 0 0.15rem rgba(105, 108, 255, 0.25);
}

.custom-control-input:checked ~ .custom-control-label::before {
    color: #fff;
    border-color: #696cff;
    background-color: #696cff;
}

.custom-control-input:disabled ~ .custom-control-label {
    color: #6c757d;
}

.custom-control-label {
    position: relative;
    margin-bottom: 0;
    vertical-align: top;
    cursor: pointer;
}

.custom-control-label::before {
    position: absolute;
    top: 0.05rem;
    left: -1.6rem;
    display: block;
    width: 1rem;
    height: 1rem;
    content: '';
    background-color: #fff;
    border: 1px solid #d3d4e8;
    border-radius: 0.25rem;
    transition: background-color 0.15s ease-in-out, border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
}

.custom-control-label::after {
    position: absolute;
    top: 0.05rem;
    left: -1.6rem;
    display: block;
    width: 1rem;
    height: 1rem;
    content: '';
    background: no-repeat 50% / 50% 50%;
}

.custom-switch {
    padding-left: 2.35rem;
}

.custom-switch .custom-control-label::before {
    left: -2.35rem;
    width: 1.85rem;
    border-radius: 0.6rem;
    pointer-events: all;
}

.custom-switch .custom-control-label::after {
    top: calc(0.05rem + 2px);
    left: calc(-2.35rem + 2px);
    width: calc(1rem - 4px);
    height: calc(1rem - 4px);
    background-color: #adb5bd;
    border-radius: 50%;
    transition: transform 0.15s ease-in-out, background-color 0.15s ease-in-out;
}

.custom-switch .custom-control-input:checked ~ .custom-control-label::after {
    background-color: #fff;
    transform: translateX(0.85rem);
}

.custom-checkbox .custom-control-input:checked ~ .custom-control-label::after {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' width='8' height='8' viewBox='0 0 8 8'%3e%3cpath fill='%23fff' d='M6.564.75l-3.59 3.612-1.538-1.55L0 4.26l2.974 2.99L8 2.193z'/%3e%3c/svg%3e");
}

/* Bootstrap 4 custom-file emulation */
.custom-file {
    position: relative;
    display: inline-block;
    width: 100%;
    height: calc(1.5em + 0.75rem + 2px);
    margin-bottom: 0;
}

.custom-file-input {
    position: relative;
    z-index: 2;
    width: 100%;
    height: calc(1.5em + 0.75rem + 2px);
    margin: 0;
    opacity: 0;
}

.custom-file-label {
    position: absolute;
    top: 0;
    right: 0;
    left: 0;
    z-index: 1;
    height: calc(1.5em + 0.75rem + 2px);
    padding: 0.375rem 0.75rem;
    font-weight: 400;
    line-height: 1.5;
    color: #697a8d;
    background-color: #fff;
    border: 1px solid #d9dee3;
    border-radius: 0.375rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.custom-file-label::after {
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    z-index: 3;
    display: block;
    height: calc(1.5em + 0.75rem);
    padding: 0.375rem 0.75rem;
    line-height: 1.5;
    color: #697a8d;
    content: 'Browse';
    background-color: #eef0f4;
    border-left: inherit;
    border-radius: 0 0.375rem 0.375rem 0;
}

/* Input groups: Bootstrap 4 prepend/append wrappers still work visually */
.input-group-append,
.input-group-prepend {
    display: flex;
}

/* ------------------------------------------------------------------
   Bootstrap 4 badge colors -> Sneat palette
------------------------------------------------------------------- */
.badge-primary {
    background-color: #696cff !important;
    color: #fff !important;
}

.badge-secondary {
    background-color: #8592a3 !important;
    color: #fff !important;
}

.badge-success {
    background-color: #71dd37 !important;
    color: #fff !important;
}

.badge-info {
    background-color: #03c3ec !important;
    color: #fff !important;
}

.badge-warning {
    background-color: #ffab00 !important;
    color: #212529 !important;
}

.badge-danger {
    background-color: #ff3e1d !important;
    color: #fff !important;
}

.badge-dark {
    background-color: #233446 !important;
    color: #fff !important;
}

.badge-light {
    background-color: #eceef1 !important;
    color: #212529 !important;
}

/* ------------------------------------------------------------------
   Bootstrap 4 spacing / alignment utilities (aliases for BS5)
------------------------------------------------------------------- */
/* :where() keeps specificity at 0 so utility classes like .g-2/.g-4
   can still control the vertical gutter; this is only the default. */
:where(.content-wrapper .row) {
    --bs-gutter-y: 0.75rem;
}

/* h-100 cards fill their column exactly — the legacy margin-bottom would
   make them overflow into the next grid row and overlap. */
.content-wrapper .row .card.h-100 {
    margin-bottom: 0;
}

.mr-0 { margin-right: 0 !important; } .ml-0 { margin-left: 0 !important; }
.mr-1 { margin-right: 0.25rem !important; } .ml-1 { margin-left: 0.25rem !important; }
.mr-2 { margin-right: 0.5rem !important; } .ml-2 { margin-left: 0.5rem !important; }
.mr-3 { margin-right: 1rem !important; } .ml-3 { margin-left: 1rem !important; }
.mr-4 { margin-right: 1.5rem !important; } .ml-4 { margin-left: 1.5rem !important; }
.mr-5 { margin-right: 3rem !important; } .ml-5 { margin-left: 3rem !important; }
.mr-auto { margin-right: auto !important; } .ml-auto { margin-left: auto !important; }

.pr-0 { padding-right: 0 !important; } .pl-0 { padding-left: 0 !important; }
.pr-1 { padding-right: 0.25rem !important; } .pl-1 { padding-left: 0.25rem !important; }
.pr-2 { padding-right: 0.5rem !important; } .pl-2 { padding-left: 0.5rem !important; }
.pr-3 { padding-right: 1rem !important; } .pl-3 { padding-left: 1rem !important; }
.pr-4 { padding-right: 1.5rem !important; } .pl-4 { padding-left: 1.5rem !important; }
.pr-5 { padding-right: 3rem !important; } .pl-5 { padding-left: 3rem !important; }

.float-left { float: left !important; }
.float-right { float: right !important; }
.float-sm-right { float: right !important; }

.text-left { text-align: left !important; }
.text-right { text-align: right !important; }

.font-weight-bold { font-weight: 700 !important; }
.font-weight-bolder { font-weight: 800 !important; }
.font-weight-normal { font-weight: 400 !important; }
.font-weight-light { font-weight: 300 !important; }
.font-italic { font-style: italic !important; }

.no-gutters {
    margin-right: 0 !important;
    margin-left: 0 !important;
}

.no-gutters > .col,
.no-gutters > [class*='col-'] {
    padding-right: 0 !important;
    padding-left: 0 !important;
}

.text-muted {
    color: #8592a3 !important;
}

.text-sm {
    font-size: 0.875rem;
}

.text-xs {
    font-size: 0.75rem;
}

/* ------------------------------------------------------------------
   AdminLTE misc (avatars, badges, dropdowns, elevation)
------------------------------------------------------------------- */
.img-circle {
    border-radius: 50% !important;
}

.img-size-32 {
    width: 32px;
    height: 32px;
    object-fit: cover;
}

.img-size-64 {
    width: 64px;
    height: 64px;
    object-fit: cover;
}

.elevation-1 { box-shadow: 0 1px 3px rgba(0, 0, 0, 0.12) !important; }
.elevation-2 { box-shadow: 0 3px 6px rgba(0, 0, 0, 0.16) !important; }
.elevation-3 { box-shadow: 0 10px 20px rgba(0, 0, 0, 0.19) !important; }
.elevation-4 { box-shadow: 0 14px 28px rgba(0, 0, 0, 0.25) !important; }

.dropdown-menu-right {
    right: 0;
    left: auto;
}

.navbar-badge {
    font-size: 0.6rem;
}

.badge {
    padding: 0.42em 0.6em;
    font-weight: 600;
}

/* ------------------------------------------------------------------
   Sneat menu icons use the theme's own sizing (icon-base / tf-icons).
------------------------------------------------------------------- */

/* ------------------------------------------------------------------
   DataTables / Select2 / misc polish
------------------------------------------------------------------- */
table.dataTable {
    width: 100% !important;
}

.dt-buttons .btn {
    margin-right: 4px;
}

table.dataTable tbody tr td {
    vertical-align: middle;
}

.select2-container .select2-selection--single .select2-selection__rendered {
    line-height: 34px;
}

.select2-container .select2-selection--single {
    height: 34px;
}

.select2-container .select2-selection--multiple .select2-selection__choice {
    font-size: 0.85rem;
}

.permission-check {
    width: 18px;
    height: 18px;
}

.pagination {
    margin-bottom: 0;
}

td .btn-sm {
    padding: 0.15rem 0.5rem;
}

.action-btns .btn + .btn {
    margin-left: 4px;
}

.password-strength-hint {
    font-size: 0.8rem;
    color: #6c757d;
}

/* Close buttons / modals */
.close {
    font-size: 1.4rem;
    font-weight: 700;
    line-height: 1;
    color: #000;
    text-shadow: 0 1px 0 #fff;
    opacity: 0.5;
    background: transparent;
    border: 0;
}

.modal .close {
    float: right;
}

/* profile widget used by users/show */
.card-primary.card-outline .profile-user-img {
    width: 96px;
    height: 96px;
    margin: 0 auto;
    display: block;
    object-fit: cover;
    border-radius: 50%;
}


/* ------------------------------------------------------------------
   POS product tiles
------------------------------------------------------------------- */
.cursor-pointer {
    cursor: pointer;
}

.product-tile {
    transition: transform 0.15s ease-in-out, box-shadow 0.15s ease-in-out, border-color 0.15s ease-in-out;
}

.product-tile:hover {
    transform: translateY(-3px);
    border-color: rgba(105, 108, 255, 0.5);
    box-shadow: 0 0.5rem 1rem rgba(105, 108, 255, 0.18);
}

/* POS cart stays visible while scrolling products (desktop only) */
@media (min-width: 992px) {
    .pos-cart-sticky {
        position: sticky;
        top: 6rem;
        z-index: 5;
    }
}

/* ------------------------------------------------------------------
   POS dense mode: compact fonts + spacing so the whole screen fits
------------------------------------------------------------------- */
.pos-dense {
    font-size: 0.78rem;
}

.pos-dense .card-body {
    padding: 0.6rem;
}

.pos-dense .card-header {
    padding: 0.6rem 0.75rem;
}

.pos-dense .card-header .card-title {
    font-size: 0.9rem;
}

.pos-dense .form-label {
    font-size: 0.75rem;
    margin-bottom: 0.25rem;
}

.pos-dense .mb-3 {
    margin-bottom: 0.6rem !important;
}

.pos-dense .form-control,
.pos-dense .input-group-text,
.pos-dense .btn {
    font-size: 0.76rem;
}

.pos-dense .list-group-item {
    padding: 0.25rem 0;
    font-size: 0.8rem;
}

.pos-dense .table {
    font-size: 0.78rem;
}

.pos-dense .badge {
    font-size: 0.65rem;
}

.pos-dense .product-tile .pos-avatar {
    width: 2rem;
    height: 2rem;
}

.pos-dense .product-tile .pos-avatar i {
    font-size: 1rem;
}

.pos-product-img {
    width: 2.5rem;
    height: 2.5rem;
    object-fit: cover;
    border-radius: 0.5rem;
    background: #f2f3f3;
}

/* POS floating actions: sidebar toggle + fullscreen toggle */
.pos-float-actions {
    position: fixed;
    right: 0.6rem;
    bottom: 0.6rem;
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
    z-index: 9999;
}

.pos-float-actions .btn {
    width: 2.4rem;
    height: 2.4rem;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 0.35rem 0.8rem rgba(0, 0, 0, 0.3);
    border: 2px solid #fff;
    padding: 0;
}

.pos-float-actions .btn i {
    font-size: 1rem;
    line-height: 1;
}

.pos-dense .product-tile .pos-sku {
    font-size: 0.62rem;
}

.pos-dense .product-tile .pos-name {
    font-size: 0.76rem;
    font-weight: 600;
}

.pos-dense .product-tile .pos-price {
    font-size: 0.82rem;
}


/* POS scrollable panels: fixed screen, inner scroll */
.pos-products-scroll {
    overflow-y: auto;
    max-height: calc(100vh - 220px);
    min-height: 300px;
    padding-right: 0.25rem;
    border-radius: 0.5rem;
}
.pos-cart-table {
    max-height: 185px;
}
.pos-dense .pos-tile-img {
    height: 62px;
}/* POS Delta style: tiles with qty badge, table cart, summary, bottom bar */
.pos-top-links {
    display: flex;
    flex-wrap: wrap;
    gap: 0.2rem 0.9rem;
    align-items: center;
    font-size: 0.74rem;
    margin-bottom: 0.35rem;
}
.pos-top-links a {
    color: #566a7f;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
}
.pos-top-links a:hover {
    color: #696cff;
}
.pos-tile-img {
    position: relative;
    height: 72px;
    overflow: hidden;
    border-bottom: 1px solid rgba(105, 108, 255, 0.1);
    background: #f2f3f3;
    border-top-left-radius: 0.375rem;
    border-top-right-radius: 0.375rem;
}
.pos-tile-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}
.pos-tile-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;
    color: #696cff;
    font-size: 2rem;
}
.pos-qty-badge {
    position: absolute;
    left: 6px;
    bottom: 6px;
    background: rgba(35, 52, 70, 0.85);
    color: #fff;
    font-size: 0.65rem;
    font-weight: 600;
    padding: 0.1rem 0.45rem;
    border-radius: 0.375rem;
}
.pos-cond-badge {
    position: absolute;
    left: 6px;
    top: 6px;
    background: rgba(255, 159, 67, 0.92);
    color: #fff;
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 0.03em;
    padding: 0.1rem 0.45rem;
    border-radius: 0.375rem;
}
.pos-cond-badge-used {
    background: rgba(220, 53, 69, 0.92);
}
.pos-cart-table {
    overflow-y: auto;
}
.pos-cart-table thead th {
    position: sticky;
    top: 0;
    background: #fff;
    z-index: 1;
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.02em;
    white-space: nowrap;
}
.pos-cart-table tbody td {
    font-size: 0.78rem;
    vertical-align: middle;
}
.pos-summary {
    display: flex;
    flex-wrap: wrap;
    gap: 0.2rem 1.2rem;
    align-items: center;
    font-size: 0.75rem;
    padding: 0.35rem 0.25rem;
    border-bottom: 1px solid rgba(105, 108, 255, 0.12);
}
.pos-balance-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.75rem;
    padding: 0.1rem 0;
}
.pos-bottom-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 0.6rem;
}
.pos-bottom-bar .btn {
    flex: 1 1 auto;
}
.pos-stepper {
    display: inline-flex;
    align-items: center;
    border: 1px solid #d9dee3;
    border-radius: 0.4rem;
    overflow: hidden;
    background: #fff;
}
.pos-step {
    width: 24px;
    height: 24px;
    border: 0;
    background: #f2f3f3;
    font-weight: 700;
    line-height: 1;
    font-size: 0.85rem;
    color: #566a7f;
}
.pos-step:active {
    background: #e4e6ea;
}
.pos-qty {
    width: 32px;
    border: 0;
    text-align: center;
    font-size: 0.78rem;
    font-weight: 600;
    -moz-appearance: textfield;
    appearance: textfield;
}
.pos-qty::-webkit-outer-spin-button,
.pos-qty::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}
/* ------------------------------------------------------------------
   Action icon colors (#2): keep meaning-aligned icon colors
------------------------------------------------------------------- */
.btn-outline-primary i,
.btn-primary i {
    color: inherit;
}

.table .btn-outline-warning i {
    color: #ffab00;
}

.table .btn-outline-danger i {
    color: #ff3e1d;
}

.table .btn-outline-success i {
    color: #1c9e4a;
}

.table .btn-outline-info i {
    color: #03c3ec;
}

.table .btn-warning i,
.table .btn-danger i,
.table .btn-success i,
.table .btn-info i,
.table .btn-primary i,
.table .btn-secondary i,
.table .btn-dark i {
    color: #fff;
}

.card-tools .btn i,
.badge i {
    color: inherit;
}

/* ------------------------------------------------------------------
   Logo chrome: sidebar + header in Shri RAM COMPUTER logo colors
   (dark slate #222834 bg + lime #b5d220 accents)
------------------------------------------------------------------- */
.bg-menu-theme {
    --bs-menu-bg: #222834;
    --bs-menu-color: #c9cfd8;
    --bs-menu-color-rgb: 201, 207, 216;
    --bs-menu-hover-bg: rgba(181, 210, 32, 0.12);
    --bs-menu-hover-color: #b5d220;
    --bs-menu-active-color: #b5d220;
    --bs-menu-active-bg: rgba(181, 210, 32, 0.16);
    --bs-menu-sub-active-bg: rgba(181, 210, 32, 0.12);
    --bs-menu-sub-active-color: #b5d220;
    --bs-menu-active-toggle-bg: rgba(181, 210, 32, 0.12);
    background-color: #222834 !important;
    color: #c9cfd8;
}

.bg-menu-theme .app-brand-text.demo {
    color: #b5d220;
}

.bg-menu-theme .layout-menu-toggle {
    color: #c9cfd8;
}

.bg-menu-theme .layout-menu-toggle:hover {
    color: #b5d220;
}

.bg-navbar-theme {
    background-color: #222834 !important;
}

.bg-navbar-theme .nav-link,
.bg-navbar-theme a.nav-link {
    color: #c9cfd8;
}

.bg-navbar-theme .nav-link:hover,
.bg-navbar-theme .nav-link:focus {
    color: #b5d220;
}
