/* Shared information-density layer: less chrome, more working data. */
.app-container{padding-top:.45rem;padding-bottom:2rem}
.context-back-row{margin:.2rem auto -.25rem}
.context-back-button{min-height:30px;padding:.2rem .48rem}
.product-heading,.setup-heading,.page-heading{margin-top:.55rem;margin-bottom:.65rem;gap:.65rem}
.product-heading h1,.setup-heading h1,.page-heading h1{margin:.08rem 0;font-size:clamp(1.55rem,2.7vw,2.15rem);line-height:1.05}
.product-heading p,.setup-heading p,.page-heading p{font-size:.78rem;line-height:1.25}
.setup-card,.panel-card,.payment-card{margin-bottom:.6rem;padding:.7rem .85rem;border-radius:14px}
.setup-card-title{margin-bottom:.5rem;padding-bottom:.45rem}
.setup-card-title h2{margin:0;font-size:1rem}.setup-card-title p{margin:.08rem 0 0;font-size:.72rem;line-height:1.25}
.setup-fields{gap:.45rem .65rem}
.product-search{margin-bottom:.55rem}
.product-table-wrap{margin-bottom:1.25rem}
.product-table th{padding:.43rem .58rem}.product-table td{padding:.48rem .58rem;line-height:1.18}
.invoice-period{margin-bottom:.45rem}
.invoice-list{gap:.45rem}.invoice-list article{min-height:0;padding:.52rem .75rem;border-radius:13px;align-items:center}
.invoice-list article>div{gap:.08rem}.invoice-list small{font-size:.73rem}.invoice-list-actions{margin-top:.2rem}
.import-steps{gap:.55rem;margin-bottom:.65rem}.import-steps article{padding:.65rem .8rem}.import-card{padding:.8rem;margin-bottom:.65rem}.import-section-title{margin-bottom:.55rem}.compact-tool-card{display:flex;align-items:center;justify-content:space-between;gap:.75rem}.compact-tool-card .import-section-title{margin:0}
.empty-state{min-height:220px;padding:1.2rem}.empty-state h2{margin:.55rem 0 .2rem}

/* Invoice registers use a real dense row layout rather than tall generic cards. */
.invoice-index-page{width:100%}
.invoice-index-page .invoice-index-heading{max-width:none;margin:.25rem 0 .38rem;align-items:center}
.invoice-index-page .invoice-index-heading h1{font-size:1.55rem}
.invoice-index-page .invoice-index-period{max-width:none;margin:0 0 .42rem;align-items:center}
.invoice-index-page .invoice-index-period label{display:flex;align-items:center;gap:.35rem;font-size:.66rem}
.invoice-index-page .invoice-index-period input{width:175px;min-height:34px;height:34px;padding:.25rem .45rem}
.invoice-index-page .invoice-index-period .btn{min-height:34px;padding:.28rem .65rem}
.invoice-index-page .compact-invoice-list{gap:.32rem}
.invoice-index-page .compact-invoice-list article{display:grid!important;grid-template-columns:minmax(260px,1fr) minmax(150px,190px) auto;align-items:center;gap:.65rem;min-height:52px!important;padding:.38rem .62rem!important;border-radius:11px}
.invoice-index-page .compact-invoice-list .invoice-list-identity{display:flex;align-items:center;gap:.45rem;min-width:0}
.invoice-index-page .compact-invoice-list .invoice-list-identity>strong{min-width:58px}
.invoice-index-page .compact-invoice-list .invoice-list-identity>small{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.invoice-index-page .compact-invoice-list .status-pill{padding:.18rem .38rem;font-size:.56rem}
.invoice-index-page .compact-invoice-list .invoice-list-money{display:grid;gap:0;text-align:right;line-height:1.1}
.invoice-index-page .compact-invoice-list .invoice-list-money strong{font-size:.82rem}
.invoice-index-page .compact-invoice-list .invoice-list-money small{font-size:.62rem}
.invoice-index-page .compact-invoice-list .invoice-list-actions{display:flex;align-items:center;justify-content:flex-end;flex-wrap:nowrap;gap:.22rem;margin:0}
.invoice-index-page .compact-invoice-list .invoice-list-actions a,.invoice-index-page .compact-invoice-list .invoice-list-actions button{min-height:28px!important;padding:.22rem .36rem!important;font-size:.6rem!important;border-radius:7px}
.invoice-index-page .compact-invoice-list .invoice-list-actions .inline-action{display:inline-flex;margin:0}

/* All report routes share one compact visual rhythm. Standalone Share moves beside Back. */
.report-grid-page .report-context-tools{display:flex;align-items:center;justify-content:space-between;max-width:none;margin:.12rem 0 .18rem}
.report-grid-page .report-context-tools .share-toolbox{margin:0 0 0 auto}
.report-grid-page .report-inline-share{display:inline-flex;margin:0}.report-grid-page .report-inline-share .share-primary,.report-grid-page .report-inline-share .share-more-toggle{min-height:34px;height:34px}.report-grid-page .report-inline-share .share-primary{padding:.3rem .58rem;font-size:.72rem}.report-grid-page .report-inline-share .share-more-toggle{width:34px}
.report-grid-page .report-context-tools .share-primary,.report-grid-page .report-context-tools .share-more-toggle{min-height:32px;height:32px}
.report-grid-page .report-context-tools .share-primary{padding:.28rem .55rem;font-size:.68rem}.report-grid-page .report-context-tools .share-more-toggle{width:32px}
.report-grid-page main>.product-heading,.report-grid-page main>form+.product-heading{max-width:none;margin:.28rem 0 .45rem;align-items:center}
.report-grid-page .product-heading h1{font-size:1.55rem}.report-grid-page .product-heading p{font-size:.72rem}
.report-grid-page .inventory-actions{gap:.32rem}.report-grid-page .inventory-actions .btn{min-height:34px;padding:.3rem .58rem;font-size:.72rem}
.report-grid-page .setup-card{padding:.62rem .78rem;margin-bottom:.48rem}
.report-grid-page .product-table-wrap{margin-bottom:.75rem}.report-grid-page .product-table th{padding:.36rem .5rem}.report-grid-page .product-table td{padding:.4rem .5rem}
.report-grid-page .report-kpis,.report-grid-page .inventory-stats,.report-grid-page .flow-summary{gap:.4rem;margin-bottom:.5rem}
.report-grid-page .report-kpis article,.report-grid-page .inventory-stats article,.report-grid-page .flow-summary article{padding:.5rem .65rem}

/* Platform Catalog prioritizes safe tenant candidates and keeps manual entry secondary. */
.catalog-heading{max-width:none;margin:.35rem 0 .55rem}.catalog-heading h1{font-size:1.7rem}
.catalog-candidate-filter{display:grid;grid-template-columns:minmax(260px,1fr) auto auto;align-items:center;gap:.45rem;margin-bottom:.5rem}
.catalog-candidate-filter>input{min-height:36px;padding:.35rem .55rem;border:1px solid #c9dcd8;border-radius:9px}
.catalog-candidate-filter .switch-row.compact{min-height:36px;padding:.3rem .5rem}.catalog-candidate-filter .btn{min-height:36px}
.catalog-candidate-table{max-width:none;margin:0;max-height:430px}.catalog-candidate-table input[type=checkbox]{width:18px;height:18px}
.catalog-candidate-table tr.is-catalogued{opacity:.65}.catalog-candidate-table td:first-child,.catalog-candidate-table th:first-child{text-align:center}
.catalog-management-grid{display:grid;grid-template-columns:minmax(320px,.85fr) minmax(0,1.35fr);gap:.6rem;align-items:start}
.catalog-manual-editor>summary{cursor:pointer;color:#123a54;font-size:.9rem;font-weight:850}.catalog-manual-editor[open]>summary{margin-bottom:.55rem;padding-bottom:.4rem;border-bottom:1px solid #dce8e5}

@media(max-width:767.98px){
  .app-container{padding-top:.2rem;padding-bottom:1rem}
  .context-back-row{margin:.18rem 0 -.15rem}.context-back-button{min-height:32px}
  .product-heading,.setup-heading,.page-heading{gap:.42rem;margin:.4rem 0 .55rem}
  .product-heading h1,.setup-heading h1,.page-heading h1{font-size:1.42rem;line-height:1.05}
  .product-heading p,.setup-heading p,.page-heading p{margin:0;font-size:.7rem;line-height:1.2}
  .product-heading>.d-flex,.setup-heading>.d-flex,.page-heading>.d-flex{gap:.3rem!important}
  .product-heading>.d-flex .btn,.setup-heading>.d-flex .btn,.page-heading>.d-flex .btn{min-height:36px;padding:.35rem .5rem;font-size:.72rem}
  .setup-card,.panel-card,.payment-card{padding:.55rem .6rem;margin-bottom:.45rem;border-radius:12px}
  .setup-card-title{margin-bottom:.38rem;padding-bottom:.35rem}.setup-card-title>span{width:28px;height:28px}
  .setup-card-title h2{font-size:.9rem}.setup-card-title p{font-size:.65rem}
  .setup-fields{gap:.4rem}
  .invoice-period{grid-template-columns:minmax(0,1fr) minmax(0,1fr) auto;gap:.35rem;margin-bottom:.4rem}
  .invoice-period label{font-size:.62rem}.invoice-period input{min-height:38px!important;padding:.35rem .42rem;font-size:.82rem!important}
  .invoice-period .btn{width:auto;min-height:38px;padding:.35rem .55rem}.invoice-period>a{grid-column:1/-1;padding:.1rem .2rem;font-size:.68rem}
  .invoice-list{gap:.35rem}.invoice-list article{grid-template-columns:minmax(0,1fr) auto!important;gap:.4rem;padding:.48rem .55rem}
  .invoice-list article>div:last-child{text-align:right}.invoice-list article strong{font-size:.86rem}.invoice-list small{font-size:.64rem;line-height:1.15}
  .invoice-list-actions{display:flex;justify-content:flex-end;gap:.25rem;flex-wrap:wrap}.invoice-list-actions a,.invoice-list-actions button{min-height:30px!important;padding:.26rem .38rem!important;font-size:.62rem!important}
  .import-steps{grid-template-columns:repeat(3,minmax(0,1fr));gap:.3rem}.import-steps article{display:block;padding:.48rem;text-align:center}.import-steps article>span{margin:auto auto .2rem}.import-steps small{display:none}.import-steps strong{font-size:.65rem;line-height:1.1}
  .import-card{padding:.6rem;margin-bottom:.45rem}.import-section-title{gap:.45rem}.import-section-title h2{font-size:.92rem}.import-section-title p{font-size:.67rem;line-height:1.25}.import-card>.btn{min-height:36px;padding:.38rem .55rem;font-size:.72rem}
  .compact-tool-card{align-items:stretch;flex-direction:column}
  .product-table th,.product-table td{padding:.4rem .45rem;font-size:.7rem}
  .empty-state{min-height:160px;padding:.8rem}.empty-icon{width:42px;height:42px}.empty-state h2{font-size:1rem}
  .invoice-index-page .invoice-index-heading{display:grid;grid-template-columns:1fr auto;align-items:end!important;margin:.28rem 0 .4rem}
  .invoice-index-page .invoice-index-heading h1{font-size:1.28rem}
  .invoice-index-page .invoice-index-heading p{display:none}
  .invoice-index-page .invoice-index-heading>.d-flex{display:flex!important;width:auto;align-self:end}
  .invoice-index-page .invoice-index-heading>.d-flex .btn{min-height:32px;padding:.28rem .42rem;font-size:.66rem}
  .invoice-index-page .invoice-index-period{display:grid;grid-template-columns:1fr 1fr auto;align-items:end;gap:.28rem}
  .invoice-index-page .invoice-index-period label{display:grid;gap:.1rem}
  .invoice-index-page .invoice-index-period input{width:100%;min-height:36px!important;height:36px!important}
  .invoice-index-page .invoice-index-period .btn{min-height:36px}
  .invoice-index-page .invoice-index-period>a{grid-column:auto;align-self:center;white-space:nowrap}
  .invoice-index-page .compact-invoice-list article{grid-template-columns:minmax(0,1fr) auto!important;gap:.25rem .45rem;min-height:0!important;padding:.42rem .5rem!important}
  .invoice-index-page .compact-invoice-list .invoice-list-identity{display:grid;grid-template-columns:auto 1fr;gap:.05rem .35rem}
  .invoice-index-page .compact-invoice-list .invoice-list-identity>strong{min-width:0}
  .invoice-index-page .compact-invoice-list .invoice-list-identity>small{grid-column:1/-1}
  .invoice-index-page .compact-invoice-list .invoice-list-money{text-align:right}
  .invoice-index-page .compact-invoice-list .invoice-list-actions{grid-column:1/-1;display:grid!important;grid-template-columns:repeat(4,minmax(0,1fr));width:100%;gap:.22rem}
  .invoice-index-page .compact-invoice-list .invoice-list-actions a,.invoice-index-page .compact-invoice-list .invoice-list-actions button{width:100%;min-height:30px!important;text-align:center}
  .invoice-index-page .compact-invoice-list .invoice-list-actions .inline-action{grid-column:auto;display:block;width:100%}
  .report-grid-page .report-context-tools{margin:.08rem 0 .15rem}.report-grid-page main>.product-heading{margin:.2rem 0 .38rem}.report-grid-page .product-heading h1{font-size:1.3rem}.report-grid-page .product-heading p{display:none}
  .catalog-candidate-filter{grid-template-columns:1fr 1fr}.catalog-candidate-filter>input{grid-column:1/-1}.catalog-management-grid{grid-template-columns:1fr}.catalog-candidate-table{max-height:55vh}
}

@media(max-width:420px){
  .invoice-list article{grid-template-columns:1fr!important}.invoice-list article>div:last-child{text-align:left}.invoice-list-actions{justify-content:flex-start}
  .invoice-index-page .invoice-index-heading{grid-template-columns:1fr}.invoice-index-page .invoice-index-heading>.d-flex{width:100%}
  .invoice-index-page .invoice-index-period{grid-template-columns:1fr 1fr}.invoice-index-page .invoice-index-period .btn,.invoice-index-page .invoice-index-period>a{grid-column:auto}
  .invoice-index-page .compact-invoice-list article{grid-template-columns:minmax(0,1fr) auto!important}
  .invoice-index-page .compact-invoice-list .invoice-list-actions{grid-template-columns:repeat(2,minmax(0,1fr))}
}

