/* Ajustes de Stocker sobre el tema Neon */
.logo .brand { color: #fff; font-size: 22px; font-weight: 700; text-decoration: none; display: inline-block; line-height: 1; }
.logo .brand i { color: #00b19d; margin-right: 6px; }
.sidebar-collapsed .logo .brand span { display: none; }
.sidebar-company { padding: 12px 20px; border-bottom: 1px solid #454a54; color: #aaabae; line-height: 1.4; }
.sidebar-company strong { display: block; color: #fff; }
.sidebar-collapsed .sidebar-company { display: none; }
.avatar-initials { display: inline-block; width: 36px; height: 36px; line-height: 36px; text-align: center; background: #00b19d; color: #fff; font-weight: 700; margin-right: 6px; }
.page-title .page-actions { padding-top: 8px; }
.page-title .page-actions .btn { margin-left: 4px; margin-bottom: 4px; }
.mb0 { margin-bottom: 0 !important; }
.nowrap { white-space: nowrap; }
.inline-form { display: inline-block; }
.filter-form .form-group, .filter-form .checkbox { margin-right: 8px; margin-bottom: 6px; }
.filter-form .select2-container { min-width: 220px; }
.search-inline .input-group { max-width: 320px; }
.tile-stats .num { font-size: 26px; }
.tile-stats h3 { font-size: 15px; }
.tile-gray { background: #8e97a8; color: #fff; }
.tile-gray .icon { color: rgba(0,0,0,.2); }
.tile-stats.tile-gray h3, .tile-stats.tile-gray p { color: #fff; }
.totals-table td { border-top: 0; }
.totals-table .total-row td { border-top: 2px solid #ddd; font-size: 17px; }
.dl-horizontal-sm dt { font-weight: 700; margin-top: 8px; }
.dl-horizontal-sm dd { margin-left: 0; }
#items-table .col-qty { width: 90px; } #items-table .col-price { width: 130px; } #items-table .col-subtotal { width: 120px; }
#items-table .item-qty { max-width: 80px; text-align: right; }
#items-table .item-price { max-width: 120px; text-align: right; }
.login-page .logo { color: #fff; font-size: 32px; font-weight: 700; text-decoration: none; }
.login-page .logo i { color: #00b19d; }
.form-login-error { background: #cc2424; color: #fff; padding: 10px; margin-bottom: 20px; border-radius: 3px; text-align: left; }
.form-login-error h3 { margin: 0 0 5px; font-size: 15px; }
.form-login-error p { margin: 0; }

/* Móvil */
@media (max-width: 767px) {
    .page-title { padding-bottom: 8px; }
    .page-title .title-env, .page-title .page-actions { float: none; text-align: left; width: 100%; }
    .page-title .page-actions .btn { margin-left: 0; margin-right: 4px; }
    .page-title .title { font-size: 22px; }
    .tile-stats { padding: 14px; margin-bottom: 12px; }
    .tile-stats .num { font-size: 20px; }
    .tile-stats .icon { font-size: 48px; }
    .filter-form .form-group, .filter-form .form-control, .filter-form .select2-container { display: block; width: 100%; }
    .filter-form .form-group { margin-right: 0; }
    .search-inline .input-group { max-width: none; }
    .main-content { padding: 12px; }
    .table-responsive { border: 0; }
    #items-table .item-qty { max-width: 60px; }
    #items-table .item-price { max-width: 90px; }
    .btn-lg { font-size: 17px; }
    .user-info .profile-info small { display: none; }
}
#items-table .item-name { font-weight: 600; }
#items-table td { vertical-align: middle; }
#items-table .item-subtotal { white-space: nowrap; }
@media (max-width: 767px) {
    /* Cada ítem de la venta se apila como una tarjeta */
    #items-table thead { display: none; }
    #items-table tr.item-row { display: block; border-bottom: 1px solid #eee; padding: 6px 0; }
    #items-table tr.item-row td { display: inline-block; border: 0; padding: 3px 4px; vertical-align: middle; }
    #items-table tr.item-row td:first-child { display: block; width: 100%; padding-bottom: 0; }
    #items-table .item-qty { width: 64px !important; max-width: none; }
    #items-table .item-price { width: 104px !important; max-width: none; }
    #items-table .item-subtotal { min-width: 96px; font-weight: 600; }
    #items-table .item-qty::before { content: "x"; }
}
#select2-drop-mask, #select2-drop { z-index: 1060; }
.modal .well { margin-bottom: 0; }

/* Switches (bootstrap-switch mini) */
.switch-field { display: flex; align-items: center; gap: 8px; }
.switch-field .control-label, .switch-field label { margin: 0; font-weight: normal; cursor: pointer; }
.switch-field .has-switch { margin: 0; }
.filter-form .switch-field { display: inline-flex; vertical-align: middle; }

.profile-head { display: flex; align-items: center; gap: 14px; }
.avatar-initials.avatar-lg { width: 64px; height: 64px; line-height: 64px; font-size: 28px; margin: 0; }
tr.clickable { cursor: pointer; }

/* Cards (panels) con más presencia */
.page-body, .page-container .main-content { background: #f3f5f8; }
.panel {
    border: 1px solid #d9dee5;
    border-radius: 4px;
    box-shadow: 0 2px 10px rgba(30, 40, 60, .10), 0 1px 2px rgba(30, 40, 60, .06);
    margin-bottom: 24px;
    background: #fff;
}
.panel > .panel-heading {
    padding: 0;
    min-height: 44px;
    border-bottom: 1px solid #e1e5eb;
    border-left: 4px solid #8e97a8;
    border-radius: 3px 3px 0 0;
    background: #f7f9fb;
}
.panel > .panel-heading .panel-title { font-size: 14px; font-weight: 700; color: #303641; padding: 12px 16px; }
.panel > .panel-heading .panel-options { padding: 12px 16px; }
.panel-primary > .panel-heading { border-left-color: #00b19d; }
.panel-danger > .panel-heading { border-left-color: #cc2424; background: #fff5f5; }
.panel-danger > .panel-heading .panel-title { color: #cc2424; }
.panel > .panel-body { padding: 18px 16px; }
.panel > .table-responsive > .table, .panel > .table { margin-bottom: 0; }
.panel .table > thead > tr > th { background: #fafbfc; border-bottom: 2px solid #e1e5eb; color: #555; }
.tile-stats { box-shadow: 0 2px 10px rgba(30, 40, 60, .12); border-radius: 4px; }
.modal-content { box-shadow: 0 10px 40px rgba(0, 0, 0, .35); border-radius: 4px; }
.modal-header { background: #f7f9fb; border-bottom: 1px solid #e1e5eb; }
.modal-footer { background: #f7f9fb; border-top: 1px solid #e1e5eb; }

/* Barra de filtros dentro de la cabecera de la card */
.panel > .panel-heading > form { padding: 12px 16px; margin: 0; }
.panel > .panel-heading > form .form-group { margin-bottom: 0; margin-right: 8px; vertical-align: middle; }
.panel > .panel-heading > form .btn { vertical-align: middle; }
.filter-form .form-control { width: auto; display: inline-block; }
.filter-form input[type="text"] { min-width: 200px; }

/* Inputs con más definición */
.form-control {
    border: 1px solid #c9d0d9;
    border-radius: 3px;
    box-shadow: inset 0 1px 2px rgba(0, 0, 0, .04);
    background: #fff;
    color: #303641;
    height: 36px;
    padding: 6px 12px;
    font-size: 13px;
    transition: border-color .15s, box-shadow .15s;
}
textarea.form-control { height: auto; }
.form-control:focus { border-color: #00b19d; box-shadow: 0 0 0 3px rgba(0, 177, 157, .15); }
.form-control::placeholder { color: #9aa3ad; }
select.form-control { padding-right: 28px; }
.input-group-addon { border: 1px solid #c9d0d9; background: #f7f9fb; border-radius: 3px; }
.input-group .form-control:first-child { border-radius: 3px 0 0 3px; }
.input-group .input-group-btn .btn { height: 36px; border-radius: 0 3px 3px 0; }
.page-body .select2-container .select2-choice { border: 1px solid #c9d0d9; border-radius: 3px; height: 36px; line-height: 34px; }
.page-body .select2-container .select2-choice .select2-arrow { border-left: 1px solid #c9d0d9; }
.page-body .select2-container.select2-dropdown-open .select2-choice,
.page-body .select2-container.select2-container-active .select2-choice { border-color: #00b19d; box-shadow: 0 0 0 3px rgba(0, 177, 157, .15); }
.page-body .select2-drop { border: 1px solid #c9d0d9; border-radius: 0 0 3px 3px; box-shadow: 0 6px 20px rgba(0, 0, 0, .12); }
.control-label { color: #4a5160; }
.btn { border-radius: 3px; }
.btn-default, .btn-white { border: 1px solid #c9d0d9; background: #fff; color: #303641; }
.btn-default:hover, .btn-white:hover { background: #f3f5f8; border-color: #b8c0cb; }

/* Tablas */
.table { font-size: 13px; }
.table > thead > tr > th, .panel .table > thead > tr > th {
    background: #eef1f5;
    color: #4a5160;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .04em;
    border-bottom: 1px solid #d9dee5;
    padding: 10px 12px;
    white-space: nowrap;
}
.table > tbody > tr > td { padding: 10px 12px; vertical-align: middle; border-top: 1px solid #edf0f3; color: #303641; }
.table > tfoot > tr > td { padding: 8px 12px; border-top: 1px solid #edf0f3; }
.table-hover > tbody > tr:hover { background: #f4fbfa; }
.table > tbody > tr > td .text-muted, .table > tbody > tr.text-muted > td { color: #8e97a8; }
.table .label { font-size: 11px; padding: 4px 8px; font-weight: 600; }
.pagination > li > a { border-color: #d9dee5; color: #303641; }
.pagination > .active > a, .pagination > .active > a:hover { background: #00b19d; border-color: #00b19d; }
@media (max-width: 767px) {
    .filter-form .form-control, .filter-form .form-group, .filter-form input[type="text"] { display: block; width: 100%; min-width: 0; }
    .panel > .panel-heading > form .form-group { margin-right: 0; margin-bottom: 8px; }
    .filter-form .btn { width: 100%; }
}

/* Imagen de producto */
.col-thumb { width: 56px; padding-right: 0 !important; }
.product-thumb { width: 40px; height: 40px; object-fit: cover; border-radius: 4px; border: 1px solid #e1e5eb; background: #fff; }
.product-thumb-empty { display: inline-flex; align-items: center; justify-content: center; color: #c5ccd6; background: #f3f5f8; font-size: 18px; }
.product-image-box { display: flex; gap: 12px; align-items: flex-start; }
.product-image-preview { width: 120px; height: 120px; flex: 0 0 120px; border: 1px dashed #c9d0d9; border-radius: 4px; background: #f7f9fb; display: flex; align-items: center; justify-content: center; color: #c5ccd6; font-size: 40px; overflow: hidden; }
.product-image-preview img { width: 100%; height: 100%; object-fit: cover; }
.product-image-actions { flex: 1; }
.product-image-actions .btn { margin-bottom: 6px; }
.file-btn input[type="file"] { display: none; }
.mt5 { margin-top: 5px; }

/* Cámara en vivo */
.camera-box { margin-top: 10px; background: #111; border-radius: 4px; overflow: hidden; }
.camera-box video { display: block; width: 100%; max-height: 360px; object-fit: contain; background: #000; }
.camera-controls { display: flex; gap: 6px; padding: 8px; background: #222; }
.camera-controls .btn-success { flex: 1; }
.camera-controls .entypo-cycle { display: none; }

/* Aviso de instalación de la PWA */
.pwa-install-bar {
    position: fixed; left: 12px; right: 12px; bottom: 12px; z-index: 1050;
    display: flex; align-items: center; gap: 12px;
    padding: 10px 14px; background: #2c2e2f; color: #fff;
    border-radius: 6px; box-shadow: 0 4px 16px rgba(0,0,0,.35); font-size: 14px;
}
.pwa-install-bar img { width: 36px; height: 36px; border-radius: 8px; }
.pwa-install-bar span { flex: 1; }
.pwa-install-bar .pwa-install-close {
    background: none; border: 0; color: #aaa; font-size: 22px; line-height: 1; padding: 0 4px;
}
@media (min-width: 768px) { .pwa-install-bar { left: auto; max-width: 420px; } }
