.lw-heading{display:flex;justify-content:space-between;align-items:center;gap:16px;margin-bottom:18px}.lw-heading h1{font-size:24px;margin:0}.lw-heading p{margin:6px 0 0}.lw-tabs{display:flex;gap:8px;flex-wrap:wrap;margin-bottom:22px}.lw-tabs button.active{background:#14753f;color:white;border-color:#14753f}.lw-tabs .badge{margin-left:5px}.lw-filters{display:flex;align-items:flex-end;gap:12px;flex-wrap:wrap;padding:16px;background:white;border:1px solid var(--line);border-radius:12px;margin-bottom:20px}.lw-filters input,.lw-filters select{max-width:230px;min-width:125px}.lw-stats{grid-template-columns:repeat(4,minmax(0,1fr))}.lw-stats small{display:block;color:var(--muted);line-height:1.5}.lw-pager{display:flex;align-items:center;justify-content:flex-end;gap:12px;margin-top:18px;font-size:13px}.lw-block{display:block;color:var(--muted);font-weight:400;margin-top:5px}.lw-root .badge{display:inline-block;margin:2px}.lw-pendente,.lw-parcial,.lw-revisar{background:#fff2cc;color:#795a06}.lw-vencido,.lw-cancelada{background:#fde9e7;color:#a12b23}.lw-root .card strong{font-size:23px;display:block;margin:10px 0}.lw-root details{margin:16px 0}.lw-detail-actions{flex-wrap:wrap;margin-top:18px}.lw-note{white-space:pre-wrap;overflow-wrap:anywhere}.lw-json{white-space:pre-wrap;overflow-wrap:anywhere;font-size:11px;max-height:260px;overflow:auto}#lw-form .source-panel{margin:0}#lw-form input,#lw-form select{min-width:0;width:100%}#lw-form button:disabled{opacity:.65;cursor:wait}#lw-form .notice{margin:0}.lw-root td .badge{white-space:nowrap}.lw-root .panel h2{font-size:17px}
@media(max-width:800px){.lw-stats{grid-template-columns:repeat(2,minmax(0,1fr))}.lw-heading{align-items:flex-start}.lw-filters label{flex:1 1 140px}.lw-filters input,.lw-filters select{max-width:100%;width:100%}.lw-tabs{gap:6px}.lw-tabs button{font-size:12px;padding:9px 11px}.lw-pager{justify-content:space-between;gap:6px}.lw-stats .card strong{font-size:19px}}
@media print{.lw-tabs,.lw-filters,.lw-pager,.lw-heading>button{display:none!important}.lw-root .scroll{overflow:visible}.lw-root td{white-space:normal}.lw-stats{display:grid;grid-template-columns:repeat(4,1fr)}}
/* Entradas e Financeiro: dados e ações sempre dentro da largura disponível. */
.lw-root .lw-entry-table{overflow:visible;max-width:100%}
.lw-entry-table table{table-layout:fixed;width:100%}
.lw-entry-table th,.lw-entry-table td{white-space:normal;overflow-wrap:anywhere;padding:12px 8px;vertical-align:top}
.lw-entry-table .lw-block,.lw-root .lw-entry-table .badge{white-space:normal;overflow-wrap:anywhere}
.lw-entry-table .actions{flex-wrap:wrap;gap:6px}
.lw-entry-table .actions button{white-space:normal;max-width:100%}
@media(max-width:1200px){
 .lw-entry-table table,.lw-entry-table tbody{display:block;width:100%}
 .lw-entry-table thead{position:absolute;width:1px;height:1px;padding:0;overflow:hidden;clip-path:inset(50%);white-space:nowrap}
 .lw-entry-table tbody{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:14px}
 .lw-entry-table tr{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:0;border:1px solid var(--line);border-radius:12px;padding:8px;background:white;min-width:0}
 .lw-entry-table td{display:block;min-width:0;border:0;padding:9px 8px}
 .lw-entry-table td::before{content:attr(data-label);display:block;color:var(--muted);font-size:11px;font-weight:600;margin-bottom:6px}
 .lw-entry-table td:nth-child(2),.lw-entry-table td:nth-child(3),.lw-entry-table td:nth-child(8),.lw-entry-table td:last-child{grid-column:1/-1}
 .lw-entry-table td:last-child{border-top:1px solid var(--line);margin-top:6px;padding-top:12px}
 .lw-entry-table td.empty{grid-column:1/-1}
 .lw-entry-table td.empty::before{display:none}
 .lw-entry-table .actions{justify-content:flex-start}
 .lw-entry-table .actions button{padding:10px 14px}
}
@media(max-width:650px){.lw-entry-table tbody{grid-template-columns:minmax(0,1fr)}.lw-pager{flex-wrap:wrap}}
@media print{.lw-entry-table tbody{display:block}.lw-entry-table tr{break-inside:avoid;margin-bottom:12px}.lw-entry-table td:last-child{display:none}}
#lw-form .lw-dimensions{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px;align-items:end}
#lw-form .lw-dimensions>p{grid-column:1/-1;color:var(--muted);font-size:13px;line-height:1.5;margin:0}
@media(max-width:650px){#lw-form .lw-dimensions{grid-template-columns:1fr}}
/* Módulo independente: usa a rolagem única da página principal. */
.lw-root{max-width:100%;min-width:0}
.lw-root .scroll{overflow:visible;max-width:100%}
.lw-root .stats{grid-template-columns:repeat(auto-fit,minmax(185px,1fr));gap:14px;margin:20px 0}
.lw-root .card{background:#fff;border:1px solid var(--line);border-radius:12px;padding:18px;box-shadow:var(--shadow)}
.lw-root .panel{background:#fff;border:1px solid var(--line);border-radius:12px;padding:18px;margin-bottom:18px;overflow:visible}
.lw-root .panel-head{display:flex;align-items:center;justify-content:space-between;gap:10px;flex-wrap:wrap;margin-bottom:14px}
.lw-root table{width:100%;border-collapse:collapse;font-size:12px;table-layout:auto}
.lw-root th,.lw-root td{padding:7px 6px;white-space:normal;overflow-wrap:anywhere;vertical-align:middle;border-bottom:1px solid #edf1ee}
.lw-root th{font-size:10px;line-height:1.25;text-transform:uppercase}
.lw-root .actions{display:flex;gap:4px;align-items:center;justify-content:flex-start;flex-wrap:nowrap;margin:0}
.lw-root .actions button{font-size:11px;line-height:1.15;padding:6px 7px;white-space:nowrap;flex:0 0 auto}
.lw-entry-table table{table-layout:fixed}
.lw-entry-table th,.lw-entry-table td{padding:6px 4px}
.lw-entry-table .actions button{font-size:10px;padding:6px 5px}
.lw-entry-table:not(.lw-financial) th:nth-child(1){width:8%}.lw-entry-table:not(.lw-financial) th:nth-child(2){width:12%}.lw-entry-table:not(.lw-financial) th:nth-child(3){width:13%}.lw-entry-table:not(.lw-financial) th:nth-child(4){width:9%}.lw-entry-table:not(.lw-financial) th:nth-child(5),.lw-entry-table:not(.lw-financial) th:nth-child(6),.lw-entry-table:not(.lw-financial) th:nth-child(7){width:8%}.lw-entry-table:not(.lw-financial) th:nth-child(8){width:14%}.lw-entry-table:not(.lw-financial) th:nth-child(9){width:20%}
.lw-entry-table.lw-financial th:nth-child(1){width:7%}.lw-entry-table.lw-financial th:nth-child(2){width:11%}.lw-entry-table.lw-financial th:nth-child(3){width:11%}.lw-entry-table.lw-financial th:nth-child(4){width:7%}.lw-entry-table.lw-financial th:nth-child(5),.lw-entry-table.lw-financial th:nth-child(6),.lw-entry-table.lw-financial th:nth-child(7){width:7%}.lw-entry-table.lw-financial th:nth-child(8){width:7%}.lw-entry-table.lw-financial th:nth-child(9){width:14%}.lw-entry-table.lw-financial th:nth-child(10){width:22%}
.lw-pager{display:flex;align-items:center;justify-content:flex-end;gap:10px;flex-wrap:wrap;margin-top:14px}.lw-pager label{display:flex;align-items:center;gap:6px;font-size:12px;color:var(--muted)}.lw-pager select{min-width:64px;padding:6px 8px}
#lenhaModal{border:1px solid var(--line);border-radius:14px;padding:0;width:640px;max-width:calc(100vw - 28px);max-height:90vh;overflow:auto;box-shadow:0 20px 80px #0003}#lenhaModal::backdrop{background:#10211666}#lenhaModal .modalhead{position:sticky;top:0;background:#fff;z-index:1;padding:16px 22px;display:flex;justify-content:space-between;align-items:center;border-bottom:1px solid var(--line)}#lenhaModal .modalhead h2{margin:0;font-size:18px}#lenhaModal .modalhead button{border:0;font-size:20px;padding:0 6px;background:transparent}#lenhaModal form,#lenhaModal .modalbody{padding:22px}#lenhaModal .fields{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:14px}#lenhaModal label{display:flex;flex-direction:column;gap:7px;font-size:13px;font-weight:600}#lenhaModal input,#lenhaModal select,#lenhaModal textarea{width:100%;min-width:0;border:1px solid var(--line);border-radius:8px;padding:10px 11px;background:#fff}#lenhaModal textarea{min-height:75px;resize:vertical}#lenhaModal .wide{grid-column:1/-1}#lenhaModal .formerror{color:#a62929;line-height:1.5;margin:12px 0}#lenhaModal .total{display:flex;justify-content:space-between;padding:14px;background:var(--soft);margin:16px 0;border-radius:8px}
#lenhaToast{z-index:2000;max-width:calc(100vw - 32px)}
@media(max-width:1200px){.lw-entry-table table,.lw-entry-table tbody{display:block;width:100%}.lw-entry-table thead{position:absolute;width:1px;height:1px;padding:0;overflow:hidden;clip-path:inset(50%);white-space:nowrap}.lw-entry-table tbody{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}.lw-entry-table tr{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:0;border:1px solid var(--line);border-radius:12px;padding:7px;background:#fff;min-width:0}.lw-entry-table td{display:block;min-width:0;border:0;padding:8px 7px}.lw-entry-table td::before{content:attr(data-label);display:block;color:var(--muted);font-size:10px;font-weight:600;margin-bottom:5px}.lw-entry-table td:nth-child(2),.lw-entry-table td:nth-child(3),.lw-entry-table td:nth-child(8),.lw-entry-table td:last-child{grid-column:1/-1}.lw-entry-table td:last-child{border-top:1px solid var(--line);margin-top:5px;padding-top:10px}.lw-entry-table td.empty{grid-column:1/-1}.lw-entry-table td.empty::before{display:none}.lw-entry-table .actions{flex-wrap:nowrap}.lw-entry-table .actions button{font-size:11px;padding:7px 9px}}
@media(max-width:650px){.lw-root .stats{grid-template-columns:repeat(2,minmax(0,1fr))}.lw-entry-table tbody{grid-template-columns:minmax(0,1fr)}.lw-entry-table .actions{flex-wrap:nowrap}.lw-entry-table .actions button{font-size:11px;padding:8px 10px}#lenhaModal .fields{grid-template-columns:minmax(0,1fr)}#lenhaModal .wide{grid-column:auto}.lw-pager{justify-content:space-between;gap:6px}}
.lw-entry-table.lw-financial th:nth-child(8){width:14%}.lw-entry-table.lw-financial th:nth-child(9){width:22%}

/* Botões e filtros do módulo Lenha seguem o acabamento dos outros módulos. */
.lw-root button{border-radius:10px;padding:9px 13px;font:inherit;font-size:13px;line-height:1.2;cursor:pointer}
.lw-root button:not(.primary):not(.danger){border:1px solid #d1ddd5;background:#fff;color:#30463a}
.lw-root button:not(:disabled):hover{border-color:#7eae8c}
.lw-root button.primary,.lw-root .lw-tabs button.active{border:1px solid #14753f;border-radius:10px;background:#14753f;color:#fff}
.lw-root button.danger{border:1px solid #e1bcbc;border-radius:10px;background:#fff;color:#a62929}
.lw-root .lw-tabs{gap:9px;margin-bottom:20px}
.lw-root .lw-tabs button{min-height:42px;padding:10px 14px;white-space:nowrap}
.lw-root .lw-filters{gap:12px;padding:18px}
.lw-root .lw-filters label{display:flex;flex:1 1 155px;min-width:130px;flex-direction:column;gap:6px;color:#536159;font-size:12px;font-weight:700}
.lw-root .lw-filters label:has(#lw-search){flex:1.5 1 220px}
.lw-root .lw-filters input,.lw-root .lw-filters select{width:100%;max-width:none;min-width:0;height:42px;border:1px solid #d1ddd5;border-radius:10px;background:#fff;padding:0 11px;color:#26372d;font:inherit;font-size:13px}
.lw-root .lw-entry-table th{font-size:11px}
.lw-root .lw-entry-table td{padding:9px 8px;font-size:13px}
.lw-root .lw-entry-table th:last-child,.lw-root .lw-entry-table td:last-child{padding-right:18px}
.lw-root .lw-entry-table .actions{gap:7px;padding-right:8px}
.lw-root .lw-entry-table .actions button{font-size:12px;padding:8px 10px}
@media(max-width:800px){.lw-root .lw-tabs{gap:7px}.lw-root .lw-tabs button{font-size:12px;padding:9px 11px}.lw-root .lw-filters label{flex:1 1 145px}.lw-root .lw-entry-table .actions button{font-size:12px;padding:8px 11px}}
