:root { --cu-blue: #1f3b5c; --cu-bg: #f5f7fa; }
body { background: var(--cu-bg); color: #1d2b3a; }
.cu-nav { background: var(--cu-blue); }
.card { border: 1px solid #e1e6ed; border-radius: .75rem; box-shadow: 0 1px 2px rgba(20, 40, 70, .04); }
.card-header { background: #fff; border-bottom: 1px solid #edf0f4; font-weight: 600; }
.table > :not(caption) > * > * { vertical-align: middle; }
.table-sm td, .table-sm th { padding: .4rem .5rem; }
.code { font-family: ui-monospace, "SFMono-Regular", Consolas, monospace; font-size: .92em; white-space: nowrap; }
.action-tile { display: block; padding: 1.25rem; border-radius: .9rem; background: #fff; border: 1px solid #e1e6ed;
  text-decoration: none; color: inherit; height: 100%; transition: box-shadow .15s, transform .15s; }
.action-tile:hover { box-shadow: 0 6px 18px rgba(20, 40, 70, .08); transform: translateY(-1px); }
.action-tile i { font-size: 2rem; color: var(--cu-blue); }
.action-tile .step { font-size: .8rem; color: #7a8899; }
.stat { font-size: 1.6rem; font-weight: 600; line-height: 1.1; }
.stat-label { font-size: .85rem; color: #6c7a89; }
.sticky-actions { position: sticky; bottom: 0; background: #fff; border-top: 1px solid #e1e6ed; padding: .6rem; z-index: 5; }

/* сканирование */
.scan-input { font-size: 1.5rem; padding: .8rem 1rem; font-family: ui-monospace, Consolas, monospace; }
.scan-result { border-radius: .9rem; padding: 1rem 1.2rem; min-height: 5.5rem; transition: background .2s; }
.scan-result .title { font-size: 1.25rem; font-weight: 600; }
.scan-result.ok { background: #d9f2e1; border: 2px solid #2e9e5b; }
.scan-result.warn { background: #fff4d6; border: 2px solid #e0a800; }
.scan-result.err { background: #fbe0e0; border: 2px solid #d64545; }
.scan-result.info { background: #e3eefb; border: 2px solid #3d7cc9; }
.scan-result.idle { background: #fff; border: 2px dashed #c9d3df; color: #7a8899; }
.counter { text-align: center; }
.counter .n { font-size: 2rem; font-weight: 700; }
.counter .l { font-size: .8rem; color: #6c7a89; }
#camera-box { max-width: 480px; margin: 0 auto; }
#camera-box video { border-radius: .75rem; }
.recent-list { max-height: 50vh; overflow: auto; }
.r-found { border-left: 4px solid #2e9e5b; }
.r-elsewhere, .r-unexpected { border-left: 4px solid #e0a800; }
.r-duplicate { border-left: 4px solid #9aa5b1; }
.r-unknown { border-left: 4px solid #d64545; }
.r-manual { border-left: 4px solid #3d7cc9; }
.label-preview { image-rendering: pixelated; border: 1px solid #c9d3df; background: #fff; max-width: 100%; }

@media (max-width: 576px) {
  .btn { padding: .6rem .9rem; }
  .form-control, .form-select { font-size: 1rem; padding: .6rem .75rem; }
  h1 { font-size: 1.5rem; }
}

/* печатные листы А4 */
@media print {
  .no-print, nav, .alert { display: none !important; }
  body { background: #fff; }
  main { padding: 0 !important; max-width: none !important; }
  .card { border: 0; box-shadow: none; }
  a { color: inherit; text-decoration: none; }
}
@page { size: A4; margin: 14mm 12mm; }
.sheet table { font-size: 11pt; }
.sheet .sign { margin-top: 18mm; }
.cu-nav .nav-link { white-space: nowrap; padding-left: .55rem !important; padding-right: .55rem !important; }
.cu-nav .navbar-brand { font-size: 1.05rem; }
.scan-input::placeholder { font-family: system-ui, sans-serif; font-size: 1rem; }
