/* LONHOW ERP first-batch final token closeout.
   This file is loaded last; keep the scope to global visual tokens and shared surfaces. */
:root{
  --lh-brand:#ed0c1d;
  --lh-brand-hover:#d20a18;
  --lh-brand-soft:#fff1f2;
  --lh-bg:#f7f7f5;
  --lh-surface:#ffffff;
  --lh-surface-soft:#f4f5f3;
  --lh-surface-muted:#fafafa;
  --lh-text:#1f2328;
  --lh-text-secondary:#667085;
  --lh-text-muted:#98a2b3;
  --lh-border:#e5e7eb;
  --lh-border-strong:#d0d5dd;
  --lh-success:#16803c;
  --lh-success-soft:#ecfdf3;
  --lh-warning:#b54708;
  --lh-warning-soft:#fffaeb;
  --lh-danger:#b42318;
  --lh-danger-soft:#fff1f3;
  --lh-radius-md:8px;
  --lh-radius-lg:12px;
  --lh-radius-xl:14px;
  --lh-shadow-sm:0 1px 2px rgba(16,24,40,.05);
  --lh-shadow-float:0 18px 40px rgba(16,24,40,.14);
}

@media (min-width:761px){
  body{
    background:var(--lh-bg)!important;
    color:var(--lh-text)!important;
    padding:0!important;
  }
  body::before,
  body::after{
    display:none!important;
    content:none!important;
  }
  .container{
    max-width:none!important;
    width:100%!important;
  }
  .glass,
  .hero,
  .form-card,
  .table-wrapper,
  .kpi-card,
  .home-panel,
  .sales-summary-card{
    background:var(--lh-surface)!important;
    background-image:none!important;
    border-color:var(--lh-border)!important;
    border-radius:var(--lh-radius-xl)!important;
    box-shadow:var(--lh-shadow-sm)!important;
    color:var(--lh-text)!important;
    backdrop-filter:none!important;
  }
  .hero::before,
  .hero::after,
  .form-card::before,
  .table-wrapper::before,
  .kpi-card::before,
  .home-panel::before,
  .sales-summary-card::before{
    display:none!important;
    content:none!important;
  }
  .hero{
    display:flex!important;
    align-items:center!important;
    gap:10px!important;
    flex-wrap:wrap!important;
    padding:10px 12px!important;
    margin-bottom:14px!important;
  }
  .hero-top{
    display:flex!important;
    align-items:center!important;
    gap:10px!important;
    flex:0 0 auto!important;
  }
  .hero .logo{
    background:none!important;
    -webkit-background-clip:initial!important;
    background-clip:initial!important;
    -webkit-text-fill-color:var(--lh-brand)!important;
    color:var(--lh-brand)!important;
    font-size:22px!important;
    font-weight:760!important;
    letter-spacing:0!important;
    filter:none!important;
    text-shadow:none!important;
  }
  .logo-sub,
  .product-cn,
  .product-ru,
  .home-section-sub,
  .sales-summary-label,
  .sales-summary-note,
  .kpi-title,
  .kpi-sub,
  .muted,
  .field-hint{
    color:var(--lh-text-secondary)!important;
  }
  .logo-sub{
    margin-top:2px!important;
    font-size:12px!important;
  }
  .product-badge{
    text-align:left!important;
    padding-left:12px!important;
    border-left:1px solid var(--lh-border)!important;
  }
  .product-cn{
    font-size:13px!important;
    font-weight:600!important;
    letter-spacing:0!important;
  }
  .product-ru{
    margin-top:2px!important;
    font-size:12px!important;
  }
  .hero > div[style*="position: absolute"]{
    position:static!important;
    display:flex!important;
    align-items:center!important;
    gap:8px!important;
    margin-left:auto!important;
    flex-wrap:wrap!important;
    justify-content:flex-end!important;
  }
  .nav{
    display:flex!important;
    align-items:center!important;
    gap:2px!important;
    margin-top:0!important;
    flex:1 1 640px!important;
    min-width:280px!important;
    justify-content:flex-start!important;
    overflow:visible!important;
  }
  .nav-item{
    min-height:32px!important;
    padding:5px 8px!important;
    border-radius:7px!important;
    border:1px solid transparent!important;
    background:transparent!important;
    background-image:none!important;
    color:var(--lh-text-secondary)!important;
    box-shadow:none!important;
    transform:none!important;
    flex:0 1 auto!important;
  }
  .nav-item:hover{
    background:transparent!important;
    border-color:transparent!important;
    color:var(--lh-text)!important;
    transform:none!important;
  }
  .nav-item.active{
    background:transparent!important;
    border-color:transparent!important;
    border-radius:0!important;
    color:var(--lh-brand)!important;
    box-shadow:none!important;
  }
  .nav-cn,
  .nav-ru{
    margin:0!important;
    font-size:12px!important;
    line-height:1.18!important;
    letter-spacing:0!important;
  }
  .nav-cn{
    font-weight:650!important;
    color:inherit!important;
  }
  .nav-ru{
    margin-top:1px!important;
    font-size:10.5px!important;
    font-weight:500!important;
    color:var(--lh-text-muted)!important;
    opacity:.72!important;
  }
  .nav-item.active .nav-cn{
    color:var(--lh-brand)!important;
  }
  .nav-item.active .nav-ru{
    color:var(--lh-brand)!important;
    opacity:1!important;
  }
  .lang-switch{
    padding:1px!important;
    gap:1px!important;
    border:1px solid transparent!important;
    border-radius:7px!important;
    background:transparent!important;
    backdrop-filter:none!important;
  }
  .lang-btn{
    min-height:28px!important;
    padding:0 7px!important;
    border-radius:6px!important;
    background:transparent!important;
    color:var(--lh-text-secondary)!important;
    font-size:11px!important;
    font-weight:600!important;
    letter-spacing:0!important;
    box-shadow:none!important;
  }
  .lang-btn.active{
    background:var(--lh-brand-soft)!important;
    color:var(--lh-brand)!important;
    box-shadow:none!important;
  }
  .logout-btn{
    min-height:34px!important;
    padding:0 12px!important;
    border-radius:var(--lh-radius-md)!important;
    border:1px solid var(--lh-border)!important;
    background:var(--lh-surface)!important;
    color:var(--lh-text-secondary)!important;
  }
  .section-header{
    margin:0 0 12px!important;
    gap:12px!important;
  }
  .section-header h2,
  .home-section-title{
    color:var(--lh-text)!important;
    background:none!important;
    -webkit-background-clip:initial!important;
    background-clip:initial!important;
    -webkit-text-fill-color:var(--lh-text)!important;
    font-size:20px!important;
    line-height:1.25!important;
    font-weight:700!important;
    letter-spacing:0!important;
  }
  .section-icon{
    width:28px!important;
    height:28px!important;
    min-width:28px!important;
    border-radius:var(--lh-radius-md)!important;
    border:1px solid #ffd6dc!important;
    background:var(--lh-brand-soft)!important;
    box-shadow:none!important;
  }
  .section-icon svg{
    width:16px!important;
    height:16px!important;
    stroke:var(--lh-brand)!important;
  }
  #home .sales-summary-grid{
    display:grid!important;
    grid-template-columns:repeat(4,minmax(0,1fr))!important;
    gap:10px!important;
    margin-bottom:14px!important;
  }
  #home .sales-summary-card{
    min-height:92px!important;
    padding:13px 14px!important;
    border-radius:var(--lh-radius-lg)!important;
    background:var(--lh-surface)!important;
    background-image:none!important;
    border:1px solid var(--lh-border)!important;
    box-shadow:none!important;
  }
  #home .sales-summary-label{
    font-size:11px!important;
    line-height:1.32!important;
    font-weight:600!important;
    color:var(--lh-text-secondary)!important;
    letter-spacing:0!important;
  }
  #home .sales-summary-value{
    margin-top:9px!important;
    font-size:clamp(20px,1.65vw,28px)!important;
    line-height:1.05!important;
    font-weight:680!important;
    color:var(--lh-text)!important;
    letter-spacing:0!important;
    text-shadow:none!important;
    white-space:normal!important;
  }
  #home .sales-summary-value.gold{
    color:var(--lh-text)!important;
    text-shadow:none!important;
  }
  #home .sales-summary-note{
    margin-top:7px!important;
    font-size:11px!important;
    line-height:1.35!important;
    color:var(--lh-text-muted)!important;
  }
  .btn,
  .login-btn{
    min-height:36px!important;
    padding:8px 14px!important;
    border-radius:var(--lh-radius-md)!important;
    border:1px solid transparent!important;
    background:var(--lh-brand)!important;
    background-image:none!important;
    color:#fff!important;
    box-shadow:none!important;
    font-size:13px!important;
    font-weight:650!important;
    letter-spacing:0!important;
    transform:none!important;
    filter:none!important;
  }
  .btn:hover,
  .login-btn:hover{
    background:var(--lh-brand-hover)!important;
    transform:none!important;
    filter:none!important;
    box-shadow:none!important;
  }
  .btn-outline,
  .warn-btn{
    border:1px solid var(--lh-border)!important;
    background:var(--lh-surface)!important;
    background-image:none!important;
    color:var(--lh-text)!important;
  }
  .btn-outline:hover,
  .warn-btn:hover{
    background:var(--lh-surface-soft)!important;
    border-color:var(--lh-border-strong)!important;
    color:var(--lh-text)!important;
  }
  .action{
    color:var(--lh-text-secondary)!important;
    font-size:13px!important;
    font-weight:500!important;
  }
  .action:hover{
    color:var(--lh-brand)!important;
  }
  .action-del{
    color:var(--lh-danger)!important;
  }
  .form-input,
  .form-select,
  .search-input,
  .login-input,
  textarea{
    min-height:38px!important;
    border-radius:var(--lh-radius-md)!important;
    border-color:var(--lh-border)!important;
    background:var(--lh-surface)!important;
    background-image:none!important;
    color:var(--lh-text)!important;
    box-shadow:none!important;
    font-size:13px!important;
  }
  .form-input:focus,
  .form-select:focus,
  .search-input:focus,
  .login-input:focus,
  textarea:focus{
    border-color:var(--lh-brand)!important;
    box-shadow:0 0 0 3px rgba(237,12,29,.09)!important;
  }
  label,
  .form-label{
    color:var(--lh-text-secondary)!important;
    font-weight:650!important;
    letter-spacing:0!important;
  }
  th,
  .home-table th,
  .table-wrapper th{
    background:var(--lh-surface-muted)!important;
    color:var(--lh-text-secondary)!important;
    border-bottom-color:var(--lh-border)!important;
    font-size:12px!important;
    font-weight:650!important;
    letter-spacing:0!important;
    padding:10px 12px!important;
  }
  td,
  .home-table td,
  .table-wrapper td{
    color:var(--lh-text)!important;
    border-bottom-color:var(--lh-border)!important;
    font-size:13px!important;
    font-weight:400!important;
    padding:11px 12px!important;
  }
  .table-wrapper,
  .home-table{
    overflow-x:auto!important;
    overflow-y:hidden!important;
    border:1px solid var(--lh-border)!important;
    border-radius:var(--lh-radius-lg)!important;
    background:var(--lh-surface)!important;
    box-shadow:none!important;
    scrollbar-width:thin!important;
    scrollbar-color:rgba(152,162,179,.65) rgba(244,245,243,.9)!important;
  }
  .table-wrapper::-webkit-scrollbar,
  .home-table::-webkit-scrollbar{
    height:10px!important;
  }
  .table-wrapper::-webkit-scrollbar-track,
  .home-table::-webkit-scrollbar-track{
    background:var(--lh-surface-soft)!important;
    border-radius:999px!important;
  }
  .table-wrapper::-webkit-scrollbar-thumb,
  .home-table::-webkit-scrollbar-thumb{
    border:2px solid var(--lh-surface-soft)!important;
    border-radius:999px!important;
    background:#c7ccd3!important;
  }
  .table-wrapper table,
  .home-table{
    width:100%!important;
    border-collapse:separate!important;
    border-spacing:0!important;
  }
  .table-wrapper thead th:first-child,
  .home-table thead th:first-child{
    border-top-left-radius:var(--lh-radius-lg)!important;
  }
  .table-wrapper thead th:last-child,
  .home-table thead th:last-child{
    border-top-right-radius:var(--lh-radius-lg)!important;
  }
  .table-wrapper tbody tr,
  .home-table tbody tr{
    background:var(--lh-surface)!important;
    transition:background .14s ease!important;
  }
  .table-wrapper tbody tr:hover,
  .home-table tbody tr:hover{
    background:var(--lh-surface-muted)!important;
  }
  .table-wrapper tbody tr:last-child td,
  .home-table tbody tr:last-child td{
    border-bottom:0!important;
  }
  .table-wrapper td strong,
  .home-table td strong,
  .goods-name-cell,
  .goods-main,
  .customer-name,
  .ltrcms-main{
    color:var(--lh-text)!important;
    font-weight:620!important;
  }
  .sku-code,
  .goods-sub,
  .product-meta,
  .table-wrapper small,
  .home-table small,
  .table-wrapper .muted,
  .home-table .muted{
    color:var(--lh-text-secondary)!important;
    font-size:12px!important;
    font-weight:500!important;
    letter-spacing:0!important;
  }
  .home-table .num,
  .home-table .amount,
  .table-wrapper .num,
  .table-wrapper .amount{
    color:var(--lh-text)!important;
    font-weight:600!important;
    text-align:left!important;
    font-variant-numeric:tabular-nums!important;
  }
  .page:not(#product) .price-cell,
  .page:not(#product) .stock-cell,
  .debt-cell,
  .paid-cell,
  .table-wrapper td[id*="Amount"],
  .table-wrapper td[id*="Debt"],
  .table-wrapper td[id*="Paid"]{
    text-align:left!important;
    font-variant-numeric:tabular-nums!important;
    font-weight:560!important;
  }
  .table-wrapper .text-center,
  .home-table .text-center{
    text-align:center!important;
  }
  .action{
    display:inline-flex!important;
    align-items:center!important;
    min-height:26px!important;
    margin:1px 5px!important;
    padding:0!important;
    border:0!important;
    background:transparent!important;
    color:var(--lh-text-secondary)!important;
    font-size:12px!important;
    font-weight:520!important;
    line-height:1.2!important;
    white-space:nowrap!important;
    box-shadow:none!important;
  }
  .action:hover{
    color:var(--lh-brand)!important;
    text-decoration:none!important;
  }
  .action-del,
  .action[onclick*="delete"],
  .action[onclick*="cancel"]{
    color:var(--lh-danger)!important;
  }
  .status-paid,
  .status-unpaid,
  .status-pill,
  .sp-status,
  .v65-badge{
    min-height:22px!important;
    padding:3px 8px!important;
    border-radius:999px!important;
    font-size:11px!important;
    line-height:1!important;
    font-weight:620!important;
    box-shadow:none!important;
  }
  .search-box{
    display:flex!important;
    align-items:center!important;
    gap:10px!important;
    margin:0 0 12px!important;
    min-height:38px!important;
  }
  .search-box .search-input,
  .page.active > .search-box .search-input{
    width:min(420px,100%)!important;
    max-width:100%!important;
    flex:0 1 420px!important;
  }
  .form-card + .search-box,
  .section-header + .search-box{
    margin-top:-4px!important;
  }
  .page:not(#sale):not(#product):not(#stockin):not(#customer):not(#ltrcms) .pagination{
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    gap:8px!important;
    margin:12px 0 0!important;
    color:var(--lh-text-secondary)!important;
    font-size:13px!important;
    line-height:1.4!important;
  }
  .page:not(#sale):not(#product):not(#stockin):not(#customer):not(#ltrcms) .pagination span{
    display:inline-flex!important;
    align-items:center!important;
    min-height:32px!important;
    padding:0 6px!important;
    color:var(--lh-text-secondary)!important;
    font-size:13px!important;
    opacity:1!important;
    visibility:visible!important;
  }
  .page:not(#sale):not(#product):not(#stockin):not(#customer):not(#ltrcms) .pagination button,
  .page-btn{
    min-width:32px!important;
    min-height:32px!important;
    padding:0 11px!important;
    border:1px solid var(--lh-border)!important;
    border-radius:var(--lh-radius-md)!important;
    background:var(--lh-surface)!important;
    color:var(--lh-text-secondary)!important;
    font-size:13px!important;
    font-weight:560!important;
    box-shadow:none!important;
  }
  .page:not(#sale):not(#product):not(#stockin):not(#customer):not(#ltrcms) .pagination button:hover:not(:disabled),
  .page-btn:hover:not(:disabled){
    background:var(--lh-surface-soft)!important;
    border-color:var(--lh-border-strong)!important;
    color:var(--lh-text)!important;
  }
  .page:not(#sale):not(#product):not(#stockin):not(#customer):not(#ltrcms) .pagination button:disabled,
  .page-btn:disabled{
    color:var(--lh-text-muted)!important;
    opacity:.5!important;
    cursor:not-allowed!important;
  }
  #sale .price-cell,
  #sale .price-readonly,
  #sale .price-trace,
  #sale .history-table th:nth-child(6),
  #sale .history-table td:nth-child(6),
  #sale .debt-cell,
  #sale .zero-cell{
    text-align:left!important;
    font-variant-numeric:tabular-nums!important;
  }
  :is(#sale,#product,#stockin,#customer) .pagination{
    justify-content:flex-end!important;
    gap:8px!important;
    margin:10px 0 0!important;
  }
  :is(#sale,#product,#stockin,#customer) .pagination .page-stat{
    margin-right:auto!important;
    min-height:0!important;
    padding:0!important;
    color:#9299A2!important;
    font-size:12px!important;
    font-weight:420!important;
  }
  :is(#sale,#product,#stockin,#customer) .pagination .page-controls{
    display:inline-flex!important;
    align-items:center!important;
    gap:4px!important;
  }
  :is(#sale,#product,#stockin,#customer) .pagination .page-icon,
  :is(#sale,#product,#stockin,#customer) .pagination .page-number{
    width:30px!important;
    min-width:30px!important;
    height:30px!important;
    min-height:30px!important;
    padding:0!important;
    border:1px solid transparent!important;
    border-radius:7px!important;
    background:transparent!important;
    color:#66707C!important;
    font-size:13px!important;
    font-weight:430!important;
    line-height:1!important;
    box-shadow:none!important;
    font-variant-numeric:tabular-nums!important;
  }
  :is(#sale,#product,#stockin,#customer) .pagination .page-icon{
    font-size:17px!important;
    color:#7A838E!important;
  }
  :is(#sale,#product,#stockin,#customer) .pagination .page-number.active{
    background:#F5F3F0!important;
    border-color:#E7E3DD!important;
    color:#303640!important;
    font-weight:560!important;
  }
  :is(#sale,#product,#stockin,#customer) .pagination .page-icon:hover:not(:disabled),
  :is(#sale,#product,#stockin,#customer) .pagination .page-number:hover:not(:disabled){
    background:#F8F8F6!important;
    border-color:#ECE8E1!important;
    color:#303640!important;
  }
  :is(#sale,#product,#stockin,#customer) .pagination .page-icon:disabled{
    color:#CDD2D8!important;
    background:transparent!important;
    border-color:transparent!important;
    opacity:1!important;
  }
  .table-wrapper td[colspan],
  .home-table td[colspan]{
    color:var(--lh-text-secondary)!important;
    text-align:center!important;
    font-size:13px!important;
    font-weight:500!important;
    padding:22px 14px!important;
  }
  .loading,
  .table-loading,
  [class*="loading"]{
    color:var(--lh-text-secondary)!important;
    font-size:13px!important;
    font-weight:500!important;
    background:transparent!important;
    box-shadow:none!important;
  }
  .sales-summary-value,
  .kpi-number{
    color:var(--lh-text)!important;
    font-size:clamp(22px,2.4vw,34px)!important;
    font-weight:650!important;
    letter-spacing:0!important;
    text-shadow:none!important;
    -webkit-text-stroke:0!important;
  }
  .status-paid,
  .sp-active,
  .status-pill,
  .v65-badge.sale{
    color:var(--lh-success)!important;
    background:var(--lh-success-soft)!important;
    border-color:#abefc6!important;
  }
  .status-unpaid,
  .sp-inactive,
  .v65-badge.pending{
    color:var(--lh-warning)!important;
    background:var(--lh-warning-soft)!important;
    border-color:#fedf89!important;
  }
  .page:not(#sale):not(#product):not(#stockin):not(#customer):not(#ltrcms) .pagination button,
  .page-btn{
    min-width:34px!important;
    min-height:34px!important;
    border-radius:var(--lh-radius-md)!important;
    border:1px solid var(--lh-border)!important;
    background:var(--lh-surface)!important;
    color:var(--lh-text-secondary)!important;
    box-shadow:none!important;
  }
  .modal-panel{
    background:var(--lh-surface)!important;
    background-image:none!important;
    color:var(--lh-text)!important;
  }
  #customer .v36-customer-card,
  .detail-card,
  .home-alert,
  .v3-fixed-note{
    background:var(--lh-surface)!important;
    background-image:none!important;
    border-color:var(--lh-border)!important;
    border-radius:var(--lh-radius-lg)!important;
    box-shadow:none!important;
    color:var(--lh-text)!important;
  }
  .detail-table-wrap{
    border-color:var(--lh-border)!important;
    border-radius:var(--lh-radius-lg)!important;
    background:var(--lh-surface)!important;
  }
  #customer .v36-customer-card .kpi-title,
  #customer .v36-customer-card .kpi-sub,
  .home-mini-note,
  .detail-card span,
  .detail-card div{
    color:var(--lh-text-secondary)!important;
  }
  #customer .v36-customer-card .kpi-number,
  .detail-card b,
  .goods-main,
  .modal-section-title{
    color:var(--lh-text)!important;
    -webkit-text-fill-color:var(--lh-text)!important;
  }
  .goods-sub{
    color:var(--lh-text-secondary)!important;
  }
  .btn-sample-delete{
    min-height:36px!important;
    border:1px solid transparent!important;
    border-radius:var(--lh-radius-md)!important;
    background:var(--lh-brand)!important;
    background-image:none!important;
    color:#fff!important;
    box-shadow:none!important;
    font-weight:650!important;
  }
  .btn-sample-delete:hover{
    background:var(--lh-brand-hover)!important;
  }

  /* Second-batch closeout: keep these refinements scoped to the affected lists. */
  #salesTbody .status-paid,
  #salesTbody .status-unpaid,
  #customerTbody .status-paid,
  #customerTbody .status-unpaid{
    min-height:20px!important;
    padding:2px 7px!important;
    border-radius:6px!important;
    font-size:12px!important;
    font-weight:620!important;
    line-height:1.15!important;
    border-width:1px!important;
    box-shadow:none!important;
  }
  #salesTbody .status-unpaid,
  #customerTbody .status-unpaid{
    color:var(--lh-warning)!important;
    background:#fffbf0!important;
    border-color:#f7ddb0!important;
  }
  #salesTbody .status-paid,
  #customerTbody .status-paid{
    color:var(--lh-success)!important;
    background:#f3fbf5!important;
    border-color:#ccebd7!important;
  }
  #customer .kpi-grid{
    grid-template-columns:repeat(4,minmax(0,1fr))!important;
    gap:10px!important;
    margin-bottom:14px!important;
  }
  #customer .kpi-card{
    min-height:104px!important;
    padding:14px 16px!important;
    border-radius:var(--lh-radius-lg)!important;
    box-shadow:none!important;
  }
  #customer .kpi-title{
    margin-bottom:8px!important;
    font-size:11px!important;
    line-height:1.32!important;
    font-weight:600!important;
    color:var(--lh-text-secondary)!important;
  }
  #customer .kpi-number{
    font-size:clamp(22px,1.9vw,30px)!important;
    line-height:1.05!important;
    font-weight:650!important;
    letter-spacing:0!important;
    color:var(--lh-text)!important;
  }
  #customer .kpi-sub{
    margin-top:6px!important;
    font-size:11px!important;
    line-height:1.3!important;
    font-weight:500!important;
    color:var(--lh-text-secondary)!important;
    opacity:1!important;
  }
  #salesTbody .action{
    min-height:24px!important;
    margin:0 4px!important;
    color:var(--lh-text-secondary)!important;
    font-size:12px!important;
    font-weight:520!important;
    white-space:nowrap!important;
    text-decoration:none!important;
  }
  #salesTbody .action:hover{
    color:var(--lh-brand)!important;
  }
  #salesTbody .action-del,
  #salesTbody .action[onclick*="cancelSale"]{
    color:var(--lh-danger)!important;
  }
  #salesTbody td:last-child{
    white-space:nowrap!important;
  }
  #product .goods-main,
  #product .goods-name-cell{
    font-weight:580!important;
  }
  /* Third-batch closeout: Form, Drawer, Modal and detail hierarchy. */
  .form-card{
    padding:16px!important;
    border-radius:var(--lh-radius-xl)!important;
    border:1px solid var(--lh-border)!important;
    background:var(--lh-surface)!important;
    box-shadow:none!important;
  }
  .form-card > .form-grid,
  .modal-grid{
    display:grid!important;
    grid-template-columns:repeat(auto-fit,minmax(190px,1fr))!important;
    gap:12px!important;
    align-items:end!important;
  }
  .form-group{
    min-width:0!important;
    margin:0!important;
    display:flex!important;
    flex-direction:column!important;
    gap:6px!important;
  }
  .form-group label,
  .form-label,
  .v8-sale-mini-label,
  #fbo .v10-fbo-line label{
    margin:0!important;
    color:var(--lh-text-secondary)!important;
    font-size:12px!important;
    line-height:1.35!important;
    font-weight:620!important;
    letter-spacing:0!important;
  }
  .field-hint,
  .select-note,
  .form-card > .muted,
  .sale-hint,
  #fbo .v10-fbo-stock{
    color:var(--lh-text-secondary)!important;
    font-size:12px!important;
    line-height:1.45!important;
    font-weight:500!important;
  }
  .form-input,
  .form-select,
  textarea{
    min-height:38px!important;
    padding:8px 11px!important;
    border-radius:var(--lh-radius-md)!important;
    border:1px solid var(--lh-border)!important;
    background:var(--lh-surface)!important;
    color:var(--lh-text)!important;
    font-size:13px!important;
    font-weight:500!important;
    box-shadow:none!important;
  }
  textarea{
    min-height:86px!important;
    resize:vertical!important;
  }
  .form-input:disabled,
  .form-select:disabled,
  textarea:disabled{
    background:var(--lh-surface-soft)!important;
    color:var(--lh-text-muted)!important;
    cursor:not-allowed!important;
  }
  .form-input::placeholder,
  textarea::placeholder{
    color:var(--lh-text-muted)!important;
    font-weight:400!important;
  }
  .form-input:focus,
  .form-select:focus,
  textarea:focus{
    border-color:var(--lh-brand)!important;
    box-shadow:0 0 0 3px rgba(237,12,29,.09)!important;
    outline:none!important;
  }
  .form-card .btn-group,
  .modal-panel .btn-group{
    gap:8px!important;
  }
  .form-card .btn,
  .modal-panel .btn{
    min-height:36px!important;
  }
  .form-card > div[style*="text-align:right"],
  .form-card > div[style*="text-align: right"],
  .v10-fbo-savebar{
    display:flex!important;
    align-items:center!important;
    justify-content:flex-end!important;
    gap:8px!important;
    margin-top:14px!important;
    padding-top:14px!important;
    border-top:1px solid var(--lh-border)!important;
  }
  .form-group[style*="justify-content"]{
    justify-content:flex-end!important;
  }
  .form-group[style*="justify-content"] .btn{
    margin-top:0!important;
    align-self:flex-end!important;
    width:auto!important;
  }
  .form-card .btn-outline,
  .modal-panel .btn-outline{
    order:0!important;
  }
  #sale .form-card > .form-grid{
    grid-template-columns:minmax(280px,1.4fr) minmax(110px,.5fr) minmax(170px,.75fr) minmax(180px,.8fr)!important;
  }
  #sale .sale-note-row{
    margin-top:12px!important;
  }
  #sale #saleItemsContainer{
    margin:16px 0!important;
  }
  #sale .sale-row,
  #fbo .v10-fbo-line{
    border-radius:var(--lh-radius-lg)!important;
    border:1px solid var(--lh-border)!important;
    background:var(--lh-surface-muted)!important;
    box-shadow:none!important;
  }
  #sale .sale-row{
    padding:12px!important;
  }
  #sale button[onclick*="addSaleItem"]{
    border:1px solid var(--lh-border)!important;
    background:var(--lh-surface)!important;
    color:var(--lh-text)!important;
  }
  #sale button[onclick*="addSaleItem"]:hover{
    background:var(--lh-surface-soft)!important;
    border-color:var(--lh-border-strong)!important;
  }
  #sale .total-box{
    margin-top:14px!important;
    padding-top:12px!important;
    border-top:1px solid var(--lh-border)!important;
  }
  #sale .total-badge{
    color:var(--lh-text-secondary)!important;
    font-size:13px!important;
    font-weight:600!important;
  }
  #sale .total-badge span{
    color:var(--lh-text)!important;
    font-size:20px!important;
    font-weight:680!important;
  }
  #sale button[onclick*="saveSale"]{
    min-width:168px!important;
  }
  #sale .v8-edit-sale-banner{
    margin:14px 0 0!important;
    padding:11px 13px!important;
    border:1px solid var(--lh-border)!important;
    border-radius:var(--lh-radius-lg)!important;
    background:var(--lh-surface-muted)!important;
    color:var(--lh-text)!important;
    box-shadow:none!important;
  }
  #stockProcess .form-grid,
  #stockProcess .form-grid.v64-process-grid,
  #stockProcess .form-grid.v65-process-grid{
    grid-template-columns:minmax(280px,1.5fr) minmax(220px,1fr) minmax(96px,.45fr) minmax(110px,.48fr) minmax(260px,1.15fr) minmax(178px,.7fr)!important;
    gap:12px!important;
  }
  #fbo .form-grid.v10-fbo-toolbar{
    grid-template-columns:minmax(280px,1.35fr) minmax(220px,1fr) minmax(96px,.45fr) minmax(110px,.48fr) minmax(240px,1fr) minmax(178px,.7fr)!important;
    gap:12px!important;
  }
  #fbo .v10-fbo-line{
    padding:12px!important;
    border-top:1px solid var(--lh-border)!important;
  }
  #fbo .v10-fbo-empty{
    padding:14px 16px!important;
    border:1px dashed var(--lh-border-strong)!important;
    border-radius:var(--lh-radius-lg)!important;
    background:var(--lh-surface-muted)!important;
    color:var(--lh-text-secondary)!important;
    box-shadow:none!important;
  }
  #fbo .v10-fbo-savebar{
    margin-top:14px!important;
    padding-top:14px!important;
    border-top:1px solid var(--lh-border)!important;
  }
  .modal-mask{
    background:rgba(16,24,40,.18)!important;
    backdrop-filter:blur(3px)!important;
  }
  .modal-panel{
    border-color:var(--lh-border)!important;
    border-radius:var(--lh-radius-xl) 0 0 var(--lh-radius-xl)!important;
    background:var(--lh-surface)!important;
    box-shadow:0 20px 48px rgba(16,24,40,.16)!important;
  }
  .modal-panel h3{
    margin:0 0 14px!important;
    padding:0 0 13px!important;
    border-bottom:1px solid var(--lh-border)!important;
    color:var(--lh-text)!important;
    font-size:19px!important;
    font-weight:700!important;
    line-height:1.3!important;
  }
  #modalBody,
  #paymentBody{
    padding:0 4px 18px 0!important;
  }
  .modal-panel .btn-group{
    justify-content:flex-end!important;
    border-top:1px solid var(--lh-border)!important;
    background:rgba(255,255,255,.97)!important;
  }
  #modalBody .modal-grid{
    grid-template-columns:repeat(2,minmax(0,1fr))!important;
  }
  #modalBody .modal-section-title,
  #paymentBody strong{
    grid-column:1 / -1!important;
    margin:16px 0 2px!important;
    padding:0 0 8px!important;
    border-bottom:1px solid var(--lh-border)!important;
    color:var(--lh-text)!important;
    font-size:13px!important;
    font-weight:700!important;
    line-height:1.35!important;
  }
  #modalBody .detail-grid{
    grid-template-columns:repeat(3,minmax(0,1fr))!important;
    gap:10px!important;
  }
  #modalBody .detail-card{
    min-height:84px!important;
    padding:12px 13px!important;
    border-radius:var(--lh-radius-lg)!important;
    border:1px solid var(--lh-border)!important;
    background:var(--lh-surface)!important;
    gap:5px!important;
  }
  #modalBody .detail-card:first-child{
    grid-column:span 2!important;
    background:var(--lh-surface-muted)!important;
  }
  #modalBody .detail-card b{
    color:var(--lh-text-secondary)!important;
    font-size:11px!important;
    font-weight:620!important;
  }
  #modalBody .detail-card span,
  #modalBody .detail-card div{
    color:var(--lh-text)!important;
    font-size:13px!important;
    font-weight:500!important;
  }
  #modalBody .detail-card:first-child span,
  #modalBody .detail-card:nth-child(5) span,
  #modalBody .detail-card:nth-child(6) span{
    font-weight:640!important;
  }
  #modalBody .detail-table-wrap{
    max-height:390px!important;
    border-radius:var(--lh-radius-lg)!important;
    border:1px solid var(--lh-border)!important;
    background:var(--lh-surface)!important;
  }
  #paymentBody{
    display:flex!important;
    flex-direction:column!important;
    gap:12px!important;
  }
  #paymentBody .payment-row{
    display:grid!important;
    grid-template-columns:minmax(96px,.7fr) minmax(130px,.8fr) minmax(140px,1fr) auto!important;
    gap:10px!important;
    align-items:center!important;
    padding:9px 0!important;
    border-bottom:1px solid var(--lh-border)!important;
    color:var(--lh-text)!important;
    font-size:13px!important;
  }

  /* Third-batch visual closeout: sales detail, customer drawer and payment drawer. */
  #modalBody > .detail-grid:first-child{
    gap:8px!important;
    margin-bottom:12px!important;
  }
  #modalBody > .detail-grid:first-child .detail-card{
    min-height:62px!important;
    padding:9px 11px!important;
    border-radius:var(--lh-radius-md)!important;
    background:var(--lh-surface)!important;
    box-shadow:none!important;
  }
  #modalBody > .detail-grid:first-child .detail-card:first-child{
    background:var(--lh-surface-muted)!important;
  }
  #modalBody > .detail-grid:first-child .detail-card b{
    font-size:11px!important;
    line-height:1.25!important;
  }
  #modalBody > .detail-grid:first-child .detail-card span{
    font-size:13px!important;
    line-height:1.35!important;
  }
  #modalBody > .detail-grid:first-child .detail-card:nth-child(n+2) span{
    font-weight:620!important;
    font-variant-numeric:tabular-nums!important;
  }
  #modalBody .detail-table-wrap{
    max-height:none!important;
    overflow-y:visible!important;
    overflow-x:auto!important;
  }
  #modalBody .detail-table-wrap table{
    min-width:0!important;
  }
  #modalBody button[onclick*="printSale"]{
    border:1px solid var(--lh-border)!important;
    background:var(--lh-surface)!important;
    color:var(--lh-text)!important;
    box-shadow:none!important;
  }
  #modalBody button[onclick*="printSale"]:hover{
    background:var(--lh-surface-soft)!important;
    border-color:var(--lh-border-strong)!important;
  }
  #modalBody .v8-edit-sale-items-btn,
  #modalBody button[onclick*="editSaleItems"]{
    border:1px solid transparent!important;
    background:var(--lh-brand)!important;
    color:#fff!important;
  }
  #modalBody .v8-edit-sale-items-btn:hover,
  #modalBody button[onclick*="editSaleItems"]:hover{
    background:var(--lh-brand-hover)!important;
  }
  #globalModal:has(#modal_phone):has(#modal_address) .modal-panel{
    width:min(560px,calc(100vw - 28px))!important;
    max-width:min(560px,calc(100vw - 28px))!important;
  }
  #globalModal:has(#modal_phone):has(#modal_address) #modalBody{
    max-width:100%!important;
  }
  #globalModal:has(#modal_phone):has(#modal_address) #modalBody .form-group{
    max-width:100%!important;
  }
  #paymentBody button[onclick*="addPaymentForCustomer"]{
    width:auto!important;
    align-self:flex-start!important;
    min-height:36px!important;
    margin:2px 0 4px!important;
    padding:8px 14px!important;
  }
  #paymentBody > div:last-child{
    margin-top:4px!important;
  }
  #paymentBody > div:last-child > div{
    max-height:none!important;
    overflow:visible!important;
  }
  #paymentBody .payment-row span{
    min-width:0!important;
    overflow-wrap:anywhere!important;
  }
  #paymentBody .payment-row .action-del{
    justify-self:end!important;
    color:var(--lh-danger)!important;
  }
  .tabs,
  .tab-list{
    display:flex!important;
    gap:4px!important;
    border-bottom:1px solid var(--lh-border)!important;
  }
  .tab,
  .tab-btn,
  [role="tab"]{
    min-height:34px!important;
    padding:0 10px!important;
    border:0!important;
    border-radius:0!important;
    background:transparent!important;
    color:var(--lh-text-secondary)!important;
    font-size:13px!important;
    font-weight:600!important;
  }
  .tab.active,
  .tab-btn.active,
  [role="tab"][aria-selected="true"]{
    color:var(--lh-brand)!important;
    box-shadow:inset 0 -2px 0 var(--lh-brand)!important;
  }
  @media (max-width:1280px){
    #stockProcess .form-grid,
    #stockProcess .form-grid.v64-process-grid,
    #stockProcess .form-grid.v65-process-grid,
    #fbo .form-grid.v10-fbo-toolbar{
      grid-template-columns:repeat(3,minmax(0,1fr))!important;
    }
  }
  @media (max-width:980px){
    #sale .form-card > .form-grid,
    #stockProcess .form-grid,
    #stockProcess .form-grid.v64-process-grid,
    #stockProcess .form-grid.v65-process-grid,
    #fbo .form-grid.v10-fbo-toolbar,
    #modalBody .modal-grid{
      grid-template-columns:repeat(2,minmax(0,1fr))!important;
    }
  }

  /* Fourth-batch page-level refinements: page-specific rhythm only. */
  #home .home-v29{
    display:grid!important;
    gap:13px!important;
  }
  #home .home-panel{
    padding:16px!important;
    border-radius:var(--lh-radius-lg)!important;
    min-height:0!important;
  }
  #home .home-section-head{
    margin-bottom:10px!important;
  }
  #home .home-section-title{
    font-size:16px!important;
    line-height:1.35!important;
  }
  #home .home-section-sub,
  #home .v3-fixed-note{
    margin-top:4px!important;
    color:var(--lh-text-secondary)!important;
    font-size:12px!important;
    line-height:1.45!important;
  }
  #home .sales-summary-grid{
    gap:10px!important;
    margin-bottom:0!important;
  }
  #home .home-grid-2{
    gap:12px!important;
  }
  #home .home-alerts{
    display:grid!important;
    gap:8px!important;
  }
  #home .home-alert{
    padding:9px 10px!important;
    border-radius:var(--lh-radius-md)!important;
    background:var(--lh-surface-muted)!important;
  }
  #product .section-header .btn-group{
    gap:8px!important;
  }
  #product .section-header .btn-group .btn-outline{
    color:var(--lh-text-secondary)!important;
    font-weight:560!important;
  }
  #product .search-box{
    margin-bottom:10px!important;
  }
  #product .goods-name-cell,
  #product .goods-main{
    line-height:1.36!important;
  }
  #product .sku-code,
  #product .goods-sub{
    color:var(--lh-text-secondary)!important;
    font-weight:480!important;
  }
  #product .action-del{
    color:var(--lh-danger)!important;
  }
  #stockin .form-card,
  #stockProcess .form-card,
  #fbo .form-card,
  #sale .form-card{
    margin-bottom:14px!important;
  }
  #stockin .form-card{
    padding-bottom:14px!important;
  }
  #stockin .table-wrapper,
  #stockProcess .table-wrapper,
  #fbo .table-wrapper,
  #sale .table-wrapper{
    margin-top:0!important;
  }
  #stockin .search-box,
  #sale .search-box,
  #customer .search-box{
    margin-top:0!important;
  }
  #sale .form-card{
    padding:15px!important;
  }
  #sale .v8-sale-main-line{
    gap:10px!important;
  }
  #sale .v8-gift-panel{
    margin-top:12px!important;
    padding:12px!important;
  }
  #sale .v8-gift-title{
    margin-bottom:8px!important;
    font-size:13px!important;
  }
  #sale .v8-gift-rule-grid,
  #sale .v8-gift-line{
    gap:10px!important;
  }
  #sale .total-box{
    margin-top:12px!important;
  }
  #sale .table-wrapper{
    margin-top:2px!important;
  }
  #stockProcess .form-card,
  #fbo .form-card{
    padding:15px!important;
  }
  #stockProcess .select-note,
  #fbo .select-note{
    margin-top:1px!important;
  }
  #stockProcess button[onclick*="submitStockProcess"],
  #fbo button[onclick*="submitFboMovement"]{
    min-width:160px!important;
  }
  #stockProcess .table-wrapper:has(#processTbody tr:only-child td[colspan]){
    margin-bottom:0!important;
  }
  #stockProcess .table-wrapper:has(#processTbody tr:only-child td[colspan]) table{
    min-height:0!important;
  }
  #stockProcess #processTbody tr:only-child td[colspan]{
    height:48px!important;
    padding:13px 14px!important;
    color:var(--lh-text-secondary)!important;
    font-size:13px!important;
    font-weight:500!important;
    vertical-align:middle!important;
  }
  #fbo .v10-fbo-items{
    gap:10px!important;
    margin-top:12px!important;
  }
  #fbo .v10-fbo-line{
    gap:10px!important;
  }
  #customer .kpi-grid,
  #salespeople .kpi-grid{
    gap:10px!important;
    margin-bottom:12px!important;
  }
  #customer .abbr-note,
  #salespeople .abbr-note{
    margin-bottom:12px!important;
    color:var(--lh-text-secondary)!important;
    font-size:12px!important;
    line-height:1.45!important;
  }
  #customer .customer-name,
  #customerTbody td:first-child,
  #salespeopleTbody td:first-child b{
    font-weight:600!important;
  }
  #salespeople .kpi-card{
    min-height:98px!important;
    padding:13px 15px!important;
    box-shadow:none!important;
  }
  #salespeople .kpi-number{
    font-size:clamp(21px,1.7vw,28px)!important;
    font-weight:650!important;
  }
  #salespeople .sp-status{
    min-height:21px!important;
    padding:3px 8px!important;
    border-radius:6px!important;
    font-size:11px!important;
    font-weight:620!important;
  }
  #salespeople .sp-active{
    background:var(--lh-success-soft)!important;
    border:1px solid #ccebd7!important;
    color:var(--lh-success)!important;
  }
  #salespeople .sp-departed{
    background:var(--lh-surface-soft)!important;
    border:1px solid var(--lh-border)!important;
    color:var(--lh-text-secondary)!important;
  }
  #salespeople .sp-muted{
    color:var(--lh-text-secondary)!important;
    font-weight:480!important;
  }
  #salespeople .sp-action{
    margin:0 4px!important;
  }
  @media (max-width:1280px){
    #home .sales-summary-grid,
    #customer .kpi-grid,
    #salespeople .kpi-grid{
      grid-template-columns:repeat(2,minmax(0,1fr))!important;
    }
    #home .home-grid-2{
      grid-template-columns:1fr!important;
    }
  }
  input[type="date"]::-webkit-calendar-picker-indicator{
    filter:none!important;
    opacity:.72!important;
  }
}

/* LONHOW ERP Mobile Lite V1
   Mobile uses a dedicated dashboard instead of shrinking PC tables. */

.mobile-lite-shell {
  display: none;
}

@media (max-width: 760px) {
  html,
  body {
    width: 100%;
    max-width: 100%;
    overflow-x: hidden;
  }

  body {
    padding: 10px;
    background:
      radial-gradient(circle at 12% 0%, rgba(82, 160, 206, .26), transparent 34%),
      radial-gradient(circle at 92% 8%, rgba(139, 92, 246, .20), transparent 36%),
      #06101d;
  }

  .container,
  .main-wrapper {
    width: 100%;
    max-width: 100%;
    overflow-x: hidden;
  }

  .hero.glass {
    position: sticky;
    top: 6px;
    z-index: 30;
    padding: 14px;
    margin-bottom: 14px;
    border-radius: 24px;
  }

  .hero-top {
    align-items: flex-start;
    gap: 8px;
  }

  .hero .logo {
    font-size: clamp(34px, 12vw, 44px);
    line-height: .95;
  }

  .logo-sub {
    font-size: 11px;
    line-height: 1.45;
  }

  .product-badge {
    width: 100%;
    text-align: left;
    margin-top: 4px;
  }

  .product-cn,
  .product-ru {
    font-size: 13px;
    line-height: 1.35;
  }

  .hero > div[style*="position: absolute"] {
    position: static !important;
    width: 100%;
    margin-top: 12px;
    justify-content: space-between !important;
  }

  .nav {
    display: none !important;
  }

  body:not(.mobile-full-mode) .page {
    display: none !important;
  }

  body.mobile-full-mode .mobile-lite-shell {
    display: none !important;
  }

  body.mobile-full-mode .nav {
    display: flex !important;
    flex-wrap: nowrap !important;
    gap: 10px !important;
    margin-top: 14px !important;
    overflow-x: auto;
    scrollbar-width: none;
  }

  body.mobile-full-mode .nav::-webkit-scrollbar {
    display: none;
  }

  body.mobile-full-mode .nav-item {
    flex: 0 0 auto;
    min-width: 108px;
    padding: 11px 16px !important;
    text-align: center;
  }

  .mobile-lite-shell {
    display: block;
    color: #eef6ff;
  }

  .mobile-lite-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    margin: 6px 0 14px;
  }

  .mobile-lite-title {
    font-size: 24px;
    line-height: 1.18;
    font-weight: 950;
    letter-spacing: -.02em;
  }

  .mobile-lite-sub {
    margin-top: 5px;
    color: #a8bbda;
    font-size: 12px;
    line-height: 1.45;
  }

  .mobile-lite-chip {
    flex: 0 0 auto;
    border: 1px solid rgba(174, 206, 255, .22);
    border-radius: 999px;
    padding: 9px 12px;
    color: #dbeafe;
    background: rgba(18, 31, 52, .72);
    font-size: 12px;
    font-weight: 900;
  }

  .mobile-lite-kpis {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    margin-bottom: 12px;
  }

  .mobile-lite-card,
  .mobile-lite-section,
  .mobile-lite-action {
    border: 1px solid rgba(174, 206, 255, .18);
    background: linear-gradient(135deg, rgba(35, 68, 105, .72), rgba(28, 31, 58, .84));
    border-radius: 22px;
    box-shadow: inset 0 1px 0 rgba(255,255,255,.05);
  }

  .mobile-lite-card {
    padding: 14px;
    min-height: 96px;
  }

  .mobile-lite-label {
    color: #b9c9e5;
    font-size: 12px;
    font-weight: 800;
    line-height: 1.35;
  }

  .mobile-lite-value {
    margin-top: 9px;
    font-size: 27px;
    line-height: 1;
    font-weight: 950;
    letter-spacing: -.03em;
    color: #fff;
  }

  .mobile-lite-value.gold {
    color: #ffd76a;
  }

  .mobile-lite-note {
    margin-top: 8px;
    color: #9fb2d2;
    font-size: 11px;
    line-height: 1.35;
  }

  .mobile-lite-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    margin: 12px 0;
  }

  .mobile-lite-action {
    min-height: 54px;
    padding: 12px;
    color: #eef6ff;
    font-size: 14px;
    font-weight: 950;
    text-align: left;
    cursor: pointer;
  }

  .mobile-lite-action span {
    display: block;
    margin-top: 4px;
    color: #9fb2d2;
    font-size: 11px;
    font-weight: 700;
  }

  .mobile-lite-action.primary {
    background: linear-gradient(135deg, #267df5, #895df5);
    border-color: rgba(255,255,255,.22);
  }

  .mobile-lite-section {
    padding: 15px;
    margin: 12px 0;
  }

  .mobile-lite-section-title {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    align-items: baseline;
    margin-bottom: 10px;
    font-size: 17px;
    font-weight: 950;
  }

  .mobile-lite-section-title small {
    color: #9fb2d2;
    font-size: 11px;
    font-weight: 800;
  }

  .mobile-lite-list {
    display: grid;
    gap: 9px;
  }

  .mobile-lite-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 10px;
    align-items: center;
    padding: 11px 12px;
    border: 1px solid rgba(174, 206, 255, .14);
    border-radius: 16px;
    background: rgba(10, 20, 36, .36);
  }

  .mobile-lite-row-main {
    min-width: 0;
  }

  .mobile-lite-row-title {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-size: 14px;
    font-weight: 900;
    color: #f5f9ff;
  }

  .mobile-lite-row-sub {
    margin-top: 4px;
    color: #aabbd7;
    font-size: 12px;
    line-height: 1.35;
  }

  .mobile-lite-row-value {
    white-space: nowrap;
    font-size: 14px;
    font-weight: 950;
    color: #fff;
    text-align: right;
  }

  .mobile-lite-row-value.warn {
    color: #ffd76a;
  }

  .mobile-lite-empty {
    padding: 14px;
    border: 1px dashed rgba(174, 206, 255, .18);
    border-radius: 16px;
    color: #9fb2d2;
    font-size: 13px;
  }

  .mobile-lite-footer {
    margin: 16px 0 8px;
    color: #7f93b3;
    font-size: 11px;
    line-height: 1.5;
    text-align: center;
  }

  .mobile-lite-back {
    display: none;
    position: fixed;
    right: 14px;
    bottom: 14px;
    z-index: 80;
    width: auto;
    min-height: 46px;
    border: 1px solid rgba(255,255,255,.18);
    border-radius: 999px;
    padding: 0 16px;
    color: #fff;
    background: linear-gradient(135deg, #267df5, #895df5);
    font-weight: 950;
    box-shadow: 0 16px 34px rgba(0,0,0,.28);
  }

  body.mobile-full-mode .mobile-lite-back {
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }
}

@media (max-width: 390px) {
  .mobile-lite-kpis,
  .mobile-lite-actions {
    grid-template-columns: 1fr;
  }

  .mobile-lite-value {
    font-size: 25px;
  }
}

@media (max-width: 760px) {
  body{
    background:var(--lh-bg)!important;
    color:var(--lh-text)!important;
  }
  .hero.glass,
  .mobile-lite-card,
  .mobile-lite-section,
  .mobile-lite-list,
  .mobile-lite-action,
  .mobile-lite-back{
    background:var(--lh-surface)!important;
    background-image:none!important;
    border-color:var(--lh-border)!important;
    box-shadow:var(--lh-shadow-sm)!important;
    color:var(--lh-text)!important;
  }
  .hero .logo{
    color:var(--lh-brand)!important;
    -webkit-text-fill-color:var(--lh-brand)!important;
    background:none!important;
    text-shadow:none!important;
    filter:none!important;
  }
  .mobile-lite-title,
  .mobile-lite-row-title,
  .mobile-lite-card-title,
  .mobile-lite-value{
    color:var(--lh-text)!important;
  }
  .mobile-lite-sub,
  .mobile-lite-card-sub,
  .mobile-lite-row-sub,
  .mobile-lite-footer,
  .mobile-lite-empty{
    color:var(--lh-text-secondary)!important;
  }
  .mobile-lite-action,
  .mobile-lite-back{
    border-radius:var(--lh-radius-lg)!important;
  }
  .mobile-lite-row{
    background:var(--lh-surface)!important;
    border-color:var(--lh-border)!important;
  }
  .mobile-lite-row-value.warn{
    color:var(--lh-warning)!important;
  }
  .mobile-lite-action.primary{
    background:var(--lh-brand-soft)!important;
    border-color:#ffd6dc!important;
    color:var(--lh-brand)!important;
  }
  .nav-item.active{
    background:transparent!important;
    border-color:transparent!important;
    color:var(--lh-brand)!important;
  }
  .form-card > .form-grid,
  #sale .form-card > .form-grid,
  #stockProcess .form-grid,
  #fbo .form-grid.v10-fbo-toolbar,
  #modalBody .modal-grid,
  #modalBody .detail-grid{
    grid-template-columns:1fr!important;
  }
  .form-card{
    padding:14px!important;
  }
  .form-group{
    gap:6px!important;
  }
  .modal-panel{
    border-radius:0!important;
    box-shadow:none!important;
  }
  #modalBody .detail-card:first-child{
    grid-column:auto!important;
  }
  #paymentBody .payment-row{
    grid-template-columns:1fr!important;
    gap:5px!important;
  }
}

/* UI 2.0 public structure closeout: language, shell, page templates and drawer hierarchy. */
@media (min-width:761px){
  body.erp-ui2{
    --lh-ui2-line:#eceef1;
    --lh-ui2-page-gap:18px;
    padding:16px 18px 20px;
  }

  body.erp-ui2 .container{
    max-width:1540px;
  }

  body.erp-ui2 .hero.erp-shell-v2{
    display:grid!important;
    grid-template-columns:minmax(172px,auto) minmax(0,1fr) auto!important;
    grid-template-areas:
      "brand spacer actions"
      "nav nav nav"!important;
    align-items:center!important;
    gap:8px 16px!important;
    min-height:0!important;
    padding:10px 14px 8px!important;
    margin-bottom:18px!important;
    border-radius:12px!important;
  }

  body.erp-ui2 .hero.erp-shell-v2 .hero-top{
    grid-area:brand!important;
    min-width:0!important;
    gap:8px!important;
  }

  body.erp-ui2 .hero.erp-shell-v2 .brand-lockup{
    min-width:0;
  }

  body.erp-ui2 .hero.erp-shell-v2 .logo{
    font-size:20px;
    line-height:1;
    font-weight:760;
  }

  body.erp-ui2 .hero.erp-shell-v2 .logo-sub{
    margin-top:3px;
    font-size:11px;
    line-height:1.2;
    font-weight:600;
    color:var(--lh-text-secondary);
  }

  body.erp-ui2 .hero.erp-shell-v2 .product-badge,
  body.erp-ui2 .hero.erp-shell-v2 .erp-product-noise{
    display:none;
  }

  body.erp-ui2 .hero.erp-shell-v2 .erp-shell-actions{
    grid-area:actions!important;
    position:static!important;
    margin-left:0!important;
    display:flex!important;
    align-items:center!important;
    justify-content:flex-end!important;
    gap:8px!important;
    min-width:max-content!important;
  }

  body.erp-ui2 .hero.erp-shell-v2 .nav{
    grid-area:nav!important;
    display:flex!important;
    flex-wrap:nowrap!important;
    gap:4px!important;
    min-width:0!important;
    width:100%!important;
    padding-top:7px!important;
    border-top:1px solid var(--lh-ui2-line)!important;
    overflow-x:auto!important;
    scrollbar-width:thin;
  }

  body.erp-ui2 .hero.erp-shell-v2 .nav-item{
    min-height:30px!important;
    padding:6px 9px!important;
    border-radius:7px!important;
    white-space:nowrap!important;
    flex:0 0 auto!important;
    font-size:13px!important;
    line-height:1!important;
    color:var(--lh-text-secondary);
  }

  body.erp-ui2.lang-zh .hero.erp-shell-v2 .nav-ru,
  body.erp-ui2.lang-ru .hero.erp-shell-v2 .nav-cn,
  body.erp-ui2.lang-zh .product-ru,
  body.erp-ui2.lang-ru .product-cn{
    display:none!important;
  }

  body.erp-ui2.lang-zh .hero.erp-shell-v2 .nav-cn,
  body.erp-ui2.lang-ru .hero.erp-shell-v2 .nav-ru{
    display:block;
    margin:0;
    font-size:13px;
    line-height:1.1;
    font-weight:650;
    color:inherit;
  }

  body.erp-ui2 .hero.erp-shell-v2 .nav-item.active{
    background:transparent;
    border-color:transparent;
    color:var(--lh-brand);
  }

  body.erp-ui2 .hero.erp-shell-v2 .lang-switch{
    padding:0;
    gap:2px;
    border:0;
    border-radius:8px;
    background:transparent;
  }

  body.erp-ui2 .hero.erp-shell-v2 .lang-btn{
    min-height:27px;
    padding:0 8px;
    border-radius:7px;
    font-size:11px;
    font-weight:620;
    color:var(--lh-text-secondary);
  }

  body.erp-ui2 .hero.erp-shell-v2 .logout-btn{
    min-height:30px;
    padding:0 10px;
    border-radius:8px;
    font-size:12px;
    font-weight:620;
  }

  body.erp-ui2 .page{
    margin-top:0;
  }

  body.erp-ui2 .erp-page-template{
    display:none;
  }

  body.erp-ui2 .erp-page-template.active{
    display:block;
  }

  body.erp-ui2 .section-header{
    align-items:flex-start;
    margin-bottom:14px;
    padding:2px 0 10px;
    border-bottom:1px solid var(--lh-ui2-line);
  }

  body.erp-ui2 .section-header h2{
    display:block;
    min-width:0;
    font-size:21px;
    line-height:1.22;
    font-weight:720;
  }

  body.erp-ui2 .section-icon{
    display:none;
  }

  body.erp-ui2 .section-header .btn-group,
  body.erp-ui2 .section-header > .btn{
    align-self:center;
  }

  body.erp-ui2 .erp-command-area,
  body.erp-ui2 .erp-page-list .search-box,
  body.erp-ui2 #ltrcms .ltrcms-toolbar{
    display:flex;
    align-items:center;
    flex-wrap:wrap;
    gap:10px;
    margin:0 0 12px;
    padding:0;
    border:0;
    background:transparent;
    box-shadow:none;
  }

  body.erp-ui2 .erp-command-area .search-input,
  body.erp-ui2 .erp-page-list .search-box .search-input{
    width:min(420px,100%);
    max-width:420px;
  }

  body.erp-ui2 .erp-page-list .table-wrapper,
  body.erp-ui2 .erp-page-transaction .table-wrapper{
    margin-top:10px;
  }

  body.erp-ui2 .erp-page-transaction > .form-card:first-of-type,
  body.erp-ui2 .erp-primary-work-area{
    margin-bottom:14px;
  }

  body.erp-ui2 .erp-page-transaction .section-header + .form-card{
    border-color:#dfe3e8;
  }

  body.erp-ui2 .home-section-sub,
  body.erp-ui2 .sales-summary-note,
  body.erp-ui2 .abbr-note,
  body.erp-ui2 .field-hint,
  body.erp-ui2 .select-note,
  body.erp-ui2 .sku-code,
  body.erp-ui2 .inline-sku,
  body.erp-ui2 .sp-muted,
  body.erp-ui2 .ltrcms-sub,
  body.erp-ui2 .table-wrapper .muted{
    color:var(--lh-text-muted);
    font-size:12px;
    line-height:1.35;
    font-weight:500;
  }

  body.erp-ui2 .sku-code,
  body.erp-ui2 .inline-sku,
  body.erp-ui2 .ltrcms-sub,
  body.erp-ui2 .sp-muted{
    display:block;
    max-width:100%;
    overflow:hidden;
    text-overflow:ellipsis;
    white-space:nowrap;
  }

  body.erp-ui2 .modal-panel.erp-drawer-v2{
    border-left:1px solid var(--lh-border);
    background:var(--lh-surface);
  }

  body.erp-ui2 .modal-panel.erp-drawer-v2 h3{
    min-height:0;
    padding-bottom:12px;
    border-bottom:1px solid var(--lh-ui2-line);
    font-size:20px;
    line-height:1.25;
    font-weight:720;
  }

  body.erp-ui2 #modalBody .detail-grid,
  body.erp-ui2 #paymentBody .detail-grid{
    gap:8px;
  }

  body.erp-ui2 #modalBody .detail-card,
  body.erp-ui2 #paymentBody .detail-card{
    padding:10px 0;
    border:0;
    border-bottom:1px solid var(--lh-ui2-line);
    border-radius:0;
    background:transparent;
    box-shadow:none;
  }

  body.erp-ui2 #modalBody .detail-card b,
  body.erp-ui2 #paymentBody .detail-card b{
    margin-bottom:4px;
    color:var(--lh-text-muted);
    font-size:11px;
    line-height:1.2;
    font-weight:650;
  }

  body.erp-ui2 #modalBody .detail-card span,
  body.erp-ui2 #modalBody .detail-card div,
  body.erp-ui2 #paymentBody .detail-card span,
  body.erp-ui2 #paymentBody .detail-card div{
    color:var(--lh-text);
    font-size:14px;
    font-weight:600;
  }
}

@media (min-width:1320px){
  body.erp-ui2 .hero.erp-shell-v2{
    grid-template-columns:minmax(180px,auto) minmax(0,1fr) auto;
  }

  body.erp-ui2 .hero.erp-shell-v2 .nav{
    gap:6px;
  }

  body.erp-ui2 .hero.erp-shell-v2 .nav-item{
    padding-left:11px;
    padding-right:11px;
  }
}

@media (max-width:760px){
  body.erp-ui2.lang-zh .nav-ru,
  body.erp-ui2.lang-ru .nav-cn,
  body.erp-ui2.lang-zh .product-ru,
  body.erp-ui2.lang-ru .product-cn{
    display:none!important;
  }
}
