/* ---------- Base ---------- */
html, body {
    height: 100%;
    -webkit-tap-highlight-color: transparent;
}
body {
    overscroll-behavior-y: contain;
}

/* ---------- Input de escaneo ---------- */
#inputEscaneo {
    font-size: 1.15rem;
    letter-spacing: 0.5px;
    font-weight: 500;
}
@media (min-width: 768px) {
    #inputEscaneo { font-size: 1.35rem; letter-spacing: 1px; }
}

/* ---------- Tabla (tablet / monitor) ---------- */
.table td, .table th { white-space: nowrap; }
.table td.desc { white-space: normal; min-width: 180px; }
@media (max-width: 991px) {
    .table td, .table th { font-size: 0.85rem; padding: 0.4rem; }
}

/* ---------- Tarjetas móvil ---------- */
.card-producto {
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 0.75rem;
    padding: 0.85rem 0.9rem;
    margin-bottom: 0.6rem;
    box-shadow: 0 1px 2px rgba(0,0,0,0.04);
}
.card-producto .cp-codigo {
    font-size: 0.75rem;
    color: #6b7280;
    font-weight: 600;
    letter-spacing: 0.3px;
}
.card-producto .cp-desc {
    font-size: 0.95rem;
    font-weight: 600;
    color: #111827;
    margin: 0.1rem 0 0.55rem;
    line-height: 1.2;
}
.card-producto .cp-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.4rem;
    text-align: center;
}
.card-producto .cp-stat {
    background: #f3f4f6;
    border-radius: 0.4rem;
    padding: 0.3rem 0.2rem;
}
.card-producto .cp-stat .label {
    display: block;
    font-size: 0.65rem;
    text-transform: uppercase;
    color: #6b7280;
    letter-spacing: 0.4px;
}
.card-producto .cp-stat .valor {
    font-weight: 700;
    font-size: 1rem;
}
.card-producto .cp-stat.ok .valor   { color: #059669; }
.card-producto .cp-stat.dif .valor  { color: #dc2626; }

/* ---------- Modal móvil ---------- */
.modal-body input[type=number] {
    font-size: 1.6rem;
    text-align: right;
}
@media (max-width: 575.98px) {
    .modal-fullscreen-sm-down .modal-content {
        height: 100%;
        border-radius: 0;
    }
    .modal-body { padding: 1.25rem; }
}

/* ---------- Utilidades ---------- */
.sticky-top { z-index: 1030; }