/* Grades de trabalho: entradas próximas dos resultados, auxiliares recolhidos. */
.project-heading {display:flex;align-items:center;justify-content:space-between;gap:10px;margin-bottom:8px;}
.project-heading h2 {margin:0;}
.project-heading .actions {gap:5px;}
.enterprise-fields {display:grid;grid-template-columns:2fr 1fr 2fr;gap:12px;align-items:end;}
.enterprise-fields .field label {font-size:11px;}
.enterprise-site .info {margin:0;padding:4px 8px;font-size:11px;}
.enterprise-site button {font-size:10px;}
.project-contract {grid-template-columns:repeat(3,minmax(0,1fr));border-top:1px solid #dfebef;padding-top:8px;margin-top:8px;}
.product-overview {display:grid;grid-template-columns:minmax(350px,5fr) minmax(0,7fr);gap:16px;align-items:start;}
.project-product .product-fields {grid-template-columns:repeat(3,minmax(0,1fr));gap:9px 10px;}
.project-product .product-fields>.field:first-child {grid-column:span 2;}
.product-fields>.field>label {font-size:11px;}
.product-fields>label {font-size:11px;}
.product-images {display:flex;gap:7px;align-items:start;overflow-x:auto;}
.product-images figure {margin:0;flex:1;min-width:90px;}
.product-images img {width:100%;height:210px;object-fit:contain;background:#f5f8fa;border:1px solid #dce6ec;border-radius:4px;}
.product-images figcaption {font-size:9px;line-height:1.3;}
.product-images .empty {padding:15px 5px;font-size:11px;}
.project-schedule .premise-cells {grid-template-columns:repeat(4,minmax(0,1fr));}
.project-workspace #product-name {cursor:pointer;background:#f2f8fa;color:#075b73;font-weight:600;}
.project-workspace #block-controls {display:flex;gap:10px;flex-wrap:wrap;align-items:end;margin-top:8px;font-size:11px;}
.project-workspace #block-controls[hidden] {display:none;}
.project-workspace #block-controls>label {max-width:250px;flex:1;}
.project-workspace #block-controls .hint {margin:4px 0;max-width:500px;}
.project-workspace .premise-cells {align-items:start;}
.project-workspace .premise-cell {justify-content:flex-start;}
@media(max-width:1100px){.enterprise-fields{grid-template-columns:2fr 1fr}.enterprise-site{grid-column:1/-1}.product-overview{grid-template-columns:minmax(270px,1fr) minmax(0,1.2fr)}.project-product .product-fields{grid-template-columns:1fr 1fr}.product-images img{height:195px}.product-images figure{min-width:110px}}
@media(max-width:720px){.project-heading{align-items:start;flex-direction:column}.enterprise-fields,.project-contract,.project-schedule .premise-cells{grid-template-columns:1fr 1fr}.product-overview{grid-template-columns:1fr}.product-images img{height:190px}.enterprise-fields>.field:first-child{grid-column:1/-1}}
.worksheet {background:#fff;border:1px solid #d6e2e8;border-radius:6px;margin:0 0 10px;padding:10px 12px;min-width:0;}
.worksheet h2,.worksheet h3 {font-size:13px;margin:0 0 7px;font-weight:600;}
.worksheet .compact-grid table {font-size:12px;}
.worksheet .compact-grid th {font-size:10px;text-transform:none;letter-spacing:0;white-space:normal;font-weight:600;}
.worksheet .compact-grid td:first-child {min-width:180px;max-width:290px;}
.worksheet .compact-grid td:not(:first-child) {font-variant-numeric:tabular-nums;}
.worksheet .compact-grid td,.worksheet .compact-grid th {padding:2px 5px;}
.worksheet .worksheet-group th {background:#dcebf1;color:#123e52;padding:6px 7px;font-size:12px;}
.worksheet-subtotal {background:#edf4f7;font-weight:600;}
.worksheet-total {background:#d9ebef;font-weight:600;}
.worksheet-subtotal .calculated-wrap input,.worksheet-total .calculated-wrap input {font-weight:600;background:transparent!important;}
.worksheet-detail>summary {font-size:12px;font-weight:600;cursor:pointer;list-style-position:inside;padding:3px 0;}
.worksheet-detail[open]>summary {margin-bottom:8px;}
.worksheet-detail .worksheet {border:0;padding:0;margin:8px 0;}
.premise-columns {display:grid;grid-template-columns:1fr 1fr;gap:10px;align-items:start;}
.premise-columns .premise-list {padding:9px 7px;}
.premise-list .compact-grid td:first-child {min-width:100px;width:57%;line-height:1.25;}
.premise-list .compact-grid td:last-child {width:43%;min-width:115px;}
.premise-list td small {display:inline;font-size:10px;}
.premise-list .tablewrap {overflow:visible;}
.premise-cells {display:grid;grid-template-columns:repeat(auto-fit,minmax(150px,1fr));gap:8px 12px;}
.premise-cell {display:flex;flex-direction:column;justify-content:space-between;gap:4px;font-size:11px;min-width:0;}
.premise-cell>span {line-height:1.3;}
.premise-cell small {color:#637983;font-size:10px;}
.premise-cell small,.premise-list td small {margin-left:3px;}
.calculated-cell[data-numeric="1"] {text-align:right;}
.premise-cell input,.premise-cell select {height:29px;min-height:29px;padding:3px 5px;border-radius:3px;font-size:12px;}
.premise-cell .formula-help {flex:0 0 19px;width:19px;height:19px;min-height:19px;padding:0;border-radius:50%;font-size:12px;color:#005a73;border:1px solid #94b4c2;background:#fff;}
.premise-cell .calculated-wrap input {width:100%;}
.compact-legend {margin:0 0 8px;font-size:10px;}
.viability-worksheet .compact-grid td:first-child {min-width:185px;max-width:250px;width:23%;}
.viability-worksheet .compact-grid th {font-size:10px;padding:5px;}
.viability-worksheet .compact-grid td {font-size:11px;}
.viability-worksheet .compact-grid td:nth-child(n+3) {text-align:right;min-width:100px;}
.viability-worksheet .compact-grid td:nth-child(3) {min-width:80px;width:90px;}
.viability-worksheet input {font-size:11px!important;}
.cost-curve-actions {display:flex;gap:3px;align-items:center;white-space:nowrap;}
.cost-curve-actions button {padding:3px 5px;font-size:10px;min-height:24px;border-radius:3px;}
.financial-summary {display:grid;grid-template-columns:repeat(4,1fr);gap:12px;background:#e7f1f4;border:1px solid #cbdee6;border-radius:6px;margin:10px 0;padding:10px 14px;}
.financial-summary>span {font-size:11px;}
.financial-summary b {display:block;font-size:19px;margin-top:2px;}
.monthly-results td {white-space:nowrap;}
.monthly-results td:first-child,.monthly-results th:first-child {position:sticky;left:0;background:#edf4f7;z-index:1;}
.cash-chart {height:220px!important;}
.budget-header {display:flex;justify-content:space-between;gap:15px;align-items:center;margin-bottom:12px;}
.budget-metrics {display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:3px 16px;background:#e8f2f5;border:1px solid #cbdfe7;border-radius:5px;padding:8px 12px;margin-bottom:10px;font-variant-numeric:tabular-nums;}
.budget-metrics>div>span {font-size:10px;color:#486877;display:block;}
.budget-metrics b {font-size:18px;font-weight:600;white-space:nowrap;}
.budget-metrics>small {grid-column:1/-1;font-size:9px;color:#486877;}
.budget-metrics[data-current=false]>small {color:#946619;}
@media(max-width:800px){.budget-metrics{grid-template-columns:1fr 1fr}.budget-metrics b{font-size:16px}}
.budget-identity h1 {font-size:21px;margin:2px 0;}
.budget-identity {flex:1;min-width:0;}
.budget-title-row {display:flex;gap:14px;align-items:center;}
.budget-title-row h1 {flex:0 1 32%;font-size:19px;overflow-wrap:anywhere;}
.premises-inline-selector {display:flex;align-items:end;gap:7px;flex:1;min-width:0;}
.premises-inline-selector>.field {flex:1;min-width:0;}
.premises-inline-selector label {font-size:9px!important;}
.premises-inline-selector select {width:100%;max-width:100%;}
.premises-inline-selector>.btn {white-space:nowrap;font-size:11px;}
@media(max-width:1150px){.budget-title-row{gap:8px;align-items:end}.budget-title-row h1{font-size:17px}.budget-header{gap:10px;flex-wrap:wrap}.budget-actions{margin-left:auto}.budget-actions .actions{margin-top:2px}}
@media(max-width:720px){.budget-title-row{align-items:start;flex-direction:column}.budget-title-row h1{flex:auto}.premises-inline-selector{width:100%;flex-wrap:wrap}.budget-identity{width:100%}}
.budget-identity>a,.budget-identity>small,.budget-actions>small {font-size:10px;}
.budget-actions {text-align:right;}
.budget-actions .actions {margin-top:5px;gap:6px;}
.budget-workspace button,.budget-workspace .btn {padding:6px 10px;}
.budget-workspace .tabs {margin-bottom:10px;gap:3px;}
.budget-workspace .tabs button {padding:8px 12px;}
.budget-workspace .tabs button.active {background:#075b73;color:#fff;border-color:#075b73;font-weight:600;}
.budget-workspace .operation-tabs {background:#eaf1f5;border-radius:5px;padding:3px;margin-top:0;}
.budget-workspace .operation-tabs button {padding:5px 10px;border-radius:3px;border:0;font-size:11px;}
.budget-workspace .card {padding:14px;margin-bottom:12px;}
.budget-workspace .card h2 {font-size:15px;margin-bottom:10px;}
.budget-workspace .fields {gap:10px 12px;}
.budget-workspace .field input,.budget-workspace .field select {padding:6px 8px;min-height:33px;font-size:12px;}
.budget-workspace .two {gap:12px;}
.budget-workspace .footer {margin-top:10px;padding-top:10px;gap:6px;}
.budget-workspace .stats {gap:10px;}
.budget-workspace .stat b {font-size:21px;margin:4px 0;}
.budget-workspace .info {padding:8px 12px;margin-bottom:10px;}
.budget-workspace .compact-grid input {min-height:26px;}
.result-filter {display:flex;gap:10px;align-items:center;margin:10px 0;font-size:11px;}
.result-filter input {min-height:30px;max-width:440px;padding:5px 8px;}
.product-grid table {table-layout:fixed;}
.product-grid th {text-transform:none;}
.product-grid td {font-size:12px;}
.product-grid td:nth-child(3) {border-left:2px solid #d5e3e9;}
.product-grid td:nth-child(2),.product-grid td:nth-child(4) {width:24%;}
.product-grid td:nth-child(1),.product-grid td:nth-child(3) {width:26%;min-width:0;}
.product-grid .product-value {display:flex;align-items:center;gap:4px;}
.product-grid .product-value>.calculated-wrap,.product-grid .product-value>input,.product-grid .product-value>select {flex:1;min-width:0;width:100%;}
.product-value>small {flex:0 0 28px;color:#637983;font-size:10px;text-align:right;}
.product-grid .product-group th {background:#dcebf1;padding:5px;font-size:12px;}
.compare-cell {display:grid;grid-template-columns:repeat(3,minmax(62px,1fr));gap:7px;padding:3px 6px!important;min-width:212px;width:100%;font-variant-numeric:tabular-nums;text-align:right;}
.compare-cell small {font-size:9px;color:#617681;line-height:1.1;}
.main:has(#parameters-form) .pagehead {margin-bottom:12px;}
.main:has(#parameters-form) h1 {font-size:23px;}
.main:has(#parameters-form) .card {padding:12px;margin-bottom:12px;}
.main:has(#parameters-form) .card:has(#parameter-base) {display:flex;align-items:center;gap:18px;}
.main:has(#parameters-form) .card:has(#parameter-base) .fields {display:block;flex:1;max-width:660px;}
.main:has(#parameters-form) input,.main:has(#parameters-form) select {min-height:29px;padding:4px 6px;}
.main:has(#parameters-form) .tabs {margin-bottom:10px;}
.main:has(#parameters-form) .tabs button {padding:8px 12px;}
.main:has(#parameters-form) .tabs button.active {background:#075b73;color:#fff;}
#parameters-form>.card {display:flex;align-items:end;gap:14px;}
#parameters-form>.card .fields {display:block;flex:1;}
#parameters-form>.card .footer {border:0;padding:0;margin:0;align-items:center;}
@media(min-width:1700px){.main{max-width:none;padding:20px 26px 40px}}
@media(max-width:1300px){.main{padding:18px}.sidebar{width:200px}.shell{margin-left:200px}.premise-columns{grid-template-columns:1fr 1fr}.premise-cells{grid-template-columns:repeat(4,minmax(95px,1fr))}.viability-worksheet .compact-grid td:first-child{min-width:185px}.cost-curve-actions{flex-wrap:wrap}}
@media(max-width:850px){.premise-columns{grid-template-columns:1fr}.premise-cells{grid-template-columns:repeat(3,minmax(90px,1fr))}.budget-header{align-items:flex-start}.financial-summary{grid-template-columns:1fr 1fr}.budget-actions .actions{justify-content:flex-end}.product-grid table{min-width:780px}}
@media(max-width:720px){.shell{margin:0}.sidebar{width:100%}.premise-cells{grid-template-columns:1fr 1fr}.budget-header{flex-direction:column}.budget-actions{text-align:left}.budget-identity h1{font-size:18px}.main{padding:12px}.budget-actions .actions{justify-content:flex-start}.main:has(#parameters-form) .card:has(#parameter-base),#parameters-form>.card{display:block}#parameters-form>.card .footer{margin-top:10px;flex-wrap:wrap}}
