/* V16.6: readable bill review and one image viewer for every module. */
.modal.modal-energy-batch{width:calc(100vw - 24px);max-width:1800px}
.energy-batch-modal .energy-batch-column-head,
.energy-batch-modal .energy-batch-row{grid-template-columns:minmax(190px,1.05fr) 128px 94px minmax(220px,1.45fr) 110px 96px 145px 145px;gap:8px}
.energy-batch-modal .energy-batch-column-head{padding:9px 10px;font-size:14px;font-weight:750;color:#35536f;background:#edf3f9;border-radius:8px 8px 0 0}
.energy-batch-modal .energy-batch-row{padding:10px;align-items:start;gap:6px 8px}
.energy-batch-modal .energy-batch-row input,
.energy-batch-modal .energy-batch-row select{min-width:0;width:100%;height:40px;min-height:40px;font-size:15px;padding:7px 8px;box-sizing:border-box}
.energy-batch-modal .energy-batch-row .required-field{border:1px solid #c6d6e5;background:#fff;box-shadow:none}
.energy-batch-modal .energy-batch-row [aria-invalid="true"]{border:1.5px solid #d9584e;background:#fffaf9}
.energy-batch-modal .energy-batch-row>label>small{font-size:14px;color:#44617b}
.energy-batch-modal .energy-batch-ticket{grid-template-columns:22px 58px minmax(0,1fr) 28px;gap:7px}
.energy-batch-modal .energy-batch-ticket>label input{width:20px;height:20px;min-height:20px;margin:0}
.energy-batch-modal .energy-batch-ticket b{font-size:15px}
.energy-batch-modal .energy-batch-ticket small{font-size:12px;line-height:1.4}
.energy-batch-modal .energy-batch-thumb{width:58px;height:62px}
.energy-batch-modal .energy-batch-remove{width:28px;height:30px;font-size:20px}
.energy-batch-modal .energy-batch-status{font-size:12px;padding:3px 6px}
.energy-batch-modal .energy-batch-row-note{font-size:13px;line-height:1.4;padding:4px 0;min-height:0;border-top:0}
.energy-batch-modal .energy-batch-row-note:empty{display:none}
.energy-batch-modal .energy-batch-room{min-width:0}
.energy-batch-modal .energy-room-resolution{display:flex;align-items:center;gap:6px;min-width:0;font-size:12px;line-height:1.4;margin-top:3px}
.energy-batch-modal .energy-room-resolution>span{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.energy-batch-modal .energy-room-source{flex-shrink:0;margin:0;font-size:12px;padding:2px 5px}
.energy-usage-input{display:flex;align-items:center;position:relative;min-width:0}
.energy-batch-modal .energy-usage-input input{padding-right:28px}
.energy-usage-input i{position:absolute;right:8px;font-size:12px;font-style:normal;color:#57728b;pointer-events:none}
.energy-batch-modal .energy-batch-review-guide{padding:7px 10px;border:0;background:none}
.energy-batch-modal .energy-batch-review-guide b{display:none}
.energy-batch-modal .energy-batch-review-guide span{font-size:14px;line-height:1.4}
.energy-batch-modal .energy-batch-review-guide>strong{display:none}
.energy-batch-modal .energy-batch-review-filters{padding:6px;gap:6px}
.energy-batch-modal .energy-batch-review-filters button{font-size:14px;min-height:38px}
.energy-batch-modal .energy-batch-review-filters button b{font-size:12px;min-height:22px}
.energy-batch-modal .energy-batch-filter-label{font-size:12px}
.energy-batch-modal .energy-batch-review-toolbar>label{font-size:14px}
.energy-batch-modal .energy-batch-review-toolbar>div{font-size:13px}
.energy-batch-modal .energy-batch-review-toolbar>.btn{font-size:14px;min-height:38px}
.energy-batch-modal .energy-batch-dedupe-note{font-size:12px;padding:6px 10px}
.energy-batch-modal .energy-batch-dedupe-note b,
.energy-batch-modal .energy-batch-dedupe-note span{font-size:12px;line-height:1.4}
.energy-batch-modal .energy-batch-actions .btn{font-size:15px;min-height:42px}
.energy-batch-modal .energy-batch-save-progress span,
.energy-batch-modal .energy-batch-save-progress small{font-size:13px}
.energy-batch-modal.is-review>.energy-capture-intro{display:none}
@media(min-width:1280px){
  /* Keep accessible row labels without repeating visible desktop headings. */
  .energy-batch-modal .energy-batch-row>label>small{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap}
}
@media(max-width:1279px){
  .energy-batch-modal .energy-batch-column-head{display:none}
  .energy-batch-modal .energy-batch-row{grid-template-columns:repeat(4,minmax(0,1fr))}
  .energy-batch-modal .energy-batch-ticket{grid-column:1/-1;grid-row:auto}
  .energy-batch-modal .energy-batch-room{grid-column:span 2}
  .energy-batch-modal .energy-batch-row-note{grid-column:1/-1}
}
@media(max-width:920px){
  .energy-batch-modal .energy-batch-row{grid-template-columns:repeat(2,minmax(0,1fr));padding:12px;gap:10px}
  .energy-batch-modal .energy-batch-room{grid-column:1/-1}
  .energy-batch-modal .energy-batch-row input,
  .energy-batch-modal .energy-batch-row select{font-size:16px;min-height:44px;height:44px}
  .energy-batch-modal .energy-batch-ticket{grid-template-columns:24px 58px minmax(0,1fr) 44px}
  .energy-batch-modal .energy-batch-remove{width:44px;height:44px}
  .energy-batch-modal .energy-batch-review-toolbar{grid-template-columns:1fr auto}
  .energy-batch-modal .energy-batch-review-toolbar>div{grid-column:1/-1;grid-row:2}
}
@media(max-width:480px){
  .energy-batch-modal .energy-batch-row{grid-template-columns:minmax(0,1fr)}
  .energy-batch-modal .energy-batch-room{grid-column:1}
}

#imageBackdrop .image-preview-stage{box-sizing:border-box;grid-template-columns:minmax(0,1fr);grid-template-rows:minmax(0,1fr);padding:76px 16px 42px}
#imageBackdrop #imagePreview{max-width:none!important;max-height:none!important;object-fit:contain;transition:opacity .12s;grid-area:1/1;will-change:auto;flex-shrink:0}
#imageBackdrop .image-zoom-toolbar{top:12px;left:12px;gap:7px;max-width:calc(100% - 24px);flex-wrap:wrap;box-sizing:border-box}
#imageBackdrop .image-zoom-toolbar button{min-width:42px;min-height:42px;height:42px;padding:0 12px;font-size:15px}
#imageBackdrop .image-zoom-toolbar strong{font-size:14px}
#imageBackdrop .image-zoom-toolbar>span{display:none}
@media(max-width:920px){
  #imageBackdrop .image-preview-stage{padding:calc(50px + env(safe-area-inset-top)) 10px calc(148px + env(safe-area-inset-bottom))!important}
  #imageBackdrop .image-zoom-toolbar{display:grid!important;grid-template-columns:repeat(3,minmax(0,1fr));width:300px;max-width:calc(100% - 24px);bottom:calc(16px + env(safe-area-inset-bottom))!important;top:auto!important;left:50%!important;transform:translateX(-50%);padding:8px;gap:6px}
  #imageBackdrop .image-zoom-toolbar button{width:100%;min-width:0!important;height:44px!important;min-height:44px;font-size:15px!important;padding:0 5px!important}
}

/* V16.9: the whole review page scrolls; the table has no inner scroll area. */
.modal.modal-energy-batch{height:auto;max-height:calc(100dvh - 16px)}
.modal-energy-batch #modalBody{overflow-y:auto;overflow-x:hidden;min-height:0}
.modal-energy-batch .energy-batch-modal{display:block;height:auto;min-height:0;overflow:visible}
.modal-energy-batch .energy-batch-pane[data-energy-batch-pane="review"],
.modal-energy-batch .energy-batch-pane[data-energy-batch-pane="upload"]{display:block;height:auto;max-height:none;overflow:visible}
.modal-energy-batch .energy-batch-rows{flex:none;height:auto;max-height:none;overflow:visible;gap:8px}
.modal-energy-batch .energy-batch-source-preview{height:auto;max-height:none;overflow:visible;grid-template-columns:repeat(auto-fill,minmax(86px,100px))}
.modal-energy-batch .energy-batch-drop{display:block;border:1px solid #c6d6e5;box-shadow:none;background:#fff}
.modal-energy-batch .energy-photo-actions{display:flex;justify-content:flex-end;flex-wrap:wrap;gap:8px;margin-bottom:10px}
.modal-energy-batch .energy-batch-pager{display:flex;align-items:center;justify-content:center;flex-wrap:wrap;gap:12px;padding:14px 0;font-size:14px}
.modal-energy-batch .energy-batch-pager.hidden{display:none}
.modal-energy-batch .energy-batch-actions{position:sticky;bottom:0;z-index:10;flex-wrap:wrap;background:#fff}
.modal-energy-batch .energy-batch-column-head{position:sticky;top:0;z-index:5}
@media(max-width:920px){
  #imageBackdrop .image-preview-stage{padding-bottom:calc(200px + env(safe-area-inset-bottom))!important}
}
.energy-incomplete-list>.energy-progress-pager{display:grid!important;grid-template-columns:minmax(0,1fr) auto 100px 100px!important;gap:12px;align-items:center;padding:16px 10px;color:var(--mist-ink,#263b50)}
.energy-progress-pager label{display:flex;gap:8px;align-items:center;min-width:0}.energy-progress-pager select{width:auto;min-height:44px}.energy-progress-pager>span{white-space:nowrap}.energy-progress-pager .btn{width:100%;min-width:0;min-height:44px;margin:0;white-space:nowrap}
@media(max-width:620px){.energy-incomplete-list>.energy-progress-pager{grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:10px}.energy-progress-pager>span{text-align:right}.energy-progress-pager .btn{grid-row:2}}
.energy-payment-photo{justify-self:start;min-height:44px}.energy-payment-no-photo{margin:0;color:var(--mist-muted,#60768a);font-size:13px}
.energy-progress-buttons:has(.energy-review-block-reason){flex-wrap:wrap}
.energy-review-block-reason{flex:1 1 100%;color:#875114;font-size:12px;line-height:1.35;text-align:right;overflow-wrap:anywhere}
@media(max-width:640px){.energy-review-block-reason{text-align:left}}
.energy-policy-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px}
.energy-policy-card{padding:20px;background:var(--mist-white,#f8fbfd);border:1px solid var(--mist-border,#d3e5f0);border-radius:14px;display:grid;gap:12px;align-content:start}
.energy-policy-card header{display:flex;align-items:center;gap:10px}.energy-policy-card h4{margin:0;font-size:16px}.energy-policy-card header>span{font-variant-numeric:tabular-nums;color:var(--mist-muted,#60768a)}
.energy-policy-offset{display:flex;align-items:center;flex-wrap:wrap;gap:8px;font-size:14px;margin:0}.energy-policy-offset input{width:80px;min-height:44px;margin:0;text-align:center;font-variant-numeric:tabular-nums}
.energy-policy-choice,.energy-policy-switch{display:flex;align-items:center;gap:8px;min-height:44px;font-size:14px;margin:0;cursor:pointer}.energy-policy-choice input,.energy-policy-switch input{width:18px;height:18px;margin:0;flex-shrink:0}
.energy-policy-example{margin:0;padding:12px;background:var(--mist-pale,#eaf3f8);border-radius:8px;color:var(--mist-ink,#263b50);font-size:13px;line-height:1.6;overflow-wrap:anywhere}
.energy-policy-foot{display:flex;align-items:center;justify-content:space-between;gap:20px;margin-top:16px}.energy-policy-foot p{max-width:780px;margin:0;font-size:13px;line-height:1.7;color:var(--mist-ink,#263b50)}.energy-policy-foot .btn{flex-shrink:0;min-height:44px}
.energy-policy-notice{padding:16px;background:var(--mist-pale,#eaf3f8);border-radius:10px;font-size:14px;line-height:1.6}.energy-policy-notice p{margin-bottom:0}
.energy-reminder-bills{display:grid;gap:8px;margin:16px 0}.energy-reminder-bill{display:flex;align-items:center;justify-content:space-between;gap:12px;border:1px solid var(--mist-border,#d3e5f0);border-radius:10px;background:var(--mist-white,#f8fbfd);color:var(--mist-ink,#263b50);padding:12px;min-height:44px;cursor:pointer;text-align:left}.energy-reminder-bill span{font-size:13px}.energy-reminder-bill:focus-visible{outline:2px solid var(--mist-primary,#4b75a2);outline-offset:2px}
@media(max-width:700px){.energy-policy-grid{grid-template-columns:minmax(0,1fr)}.energy-policy-card{padding:16px}.energy-policy-foot{flex-direction:column;align-items:stretch}.energy-reminder-bill{flex-direction:column;align-items:flex-start}}
.energy-policy-month-end{display:flex;align-items:center;flex-wrap:wrap;gap:8px;font-size:14px}.energy-policy-month-end input[type=number]{width:80px;min-height:44px;margin:0;text-align:center}.energy-policy-month-end label{margin:0}
.energy-cycle-help{color:var(--mist-muted,#60768a);font-size:13px;line-height:1.65;margin:0}
.energy-utility-policy .energy-policy-grid{margin:12px 0}.energy-utility-policy .energy-policy-card{padding:16px;gap:8px;background:#fff}.energy-utility-policy .energy-policy-offset input{width:72px}.energy-payment-options{display:flex;align-items:center;gap:8px;flex-wrap:wrap}.energy-period-title{font-size:14px;margin:20px 0 8px}.energy-cycle-result .energy-sequence-warning{color:#975010}.energy-cycle-result small:empty{display:none}.energy-policy-form h3{margin-top:0}.energy-policy-form>h3{font-size:20px}
.energy-room-workflow{min-width:0}.energy-room-account{display:grid;gap:3px;font-size:12px;line-height:1.5;margin:8px 0;overflow-wrap:anywhere}.energy-room-account span{color:var(--mist-muted,#60768a)}.energy-room-account b{color:var(--mist-ink,#263b50);font-weight:500}.energy-room-account small{color:var(--mist-muted,#60768a)}.energy-stage-list{list-style:none;padding:0;margin:10px 0 0;display:grid;gap:7px}.energy-stage-list li{display:grid;grid-template-columns:32px minmax(0,1fr);gap:8px;font-size:12px;line-height:1.5}.energy-stage-list li>span{color:var(--mist-muted,#60768a)}.energy-stage-list li>div{display:grid;gap:1px;min-width:0}.energy-stage-list b{font-weight:500;overflow-wrap:anywhere}.energy-stage-list small{font-size:11px;color:var(--mist-muted,#60768a)}.energy-stage-list .done b{color:#197451}.energy-stage-list .overdue b{color:#af313d}.energy-stage-list .pending b{color:#92510c}.energy-stage-list .waiting b,.energy-stage-list .unknown b{color:var(--mist-muted,#60768a)}.energy-next-arrival{font-size:12px;line-height:1.6;margin:12px 0 0;padding:8px;border-radius:6px;background:#eaf6ef;color:#196543;overflow-wrap:anywhere}.energy-room-workflow .energy-room-empty{min-height:32px;margin:8px 0}.energy-room-workflow .energy-room-empty strong{font-size:13px}
@media(min-width:1001px){.energy-room-card:has(.energy-room-workflow) .energy-room-utilities{grid-template-columns:repeat(auto-fit,minmax(190px,1fr))}}@media(max-width:700px){.energy-room-card:has(.energy-room-workflow) .energy-room-utilities{grid-template-columns:minmax(0,1fr)}.energy-stage-list li{font-size:13px}.energy-stage-list small{font-size:12px}.energy-utility-policy .energy-policy-card{padding:12px}.energy-cycle-result{display:grid!important}.energy-policy-form .energy-policy-offset input{font-size:16px}}
.energy-policy-scanning{margin-top:20px;padding-top:20px;border-top:1px solid var(--mist-border,#d3e5f0)}
.energy-cycle-heading{display:flex;justify-content:space-between;align-items:flex-start;gap:24px;margin-bottom:12px}.energy-cycle-heading h4{margin:0 0 8px;font-size:16px}.energy-cycle-heading h4>span{color:var(--mist-muted,#60768a);font-weight:400;margin-right:8px}.energy-cycle-heading p{max-width:800px;margin:0;font-size:14px;line-height:1.65}.energy-cycle-heading>label{font-size:13px;flex-shrink:0;display:grid;gap:6px}.energy-cycle-heading input{width:100px;min-height:44px;margin:0}
.energy-cycle-list{display:grid;gap:10px;margin-top:16px}.energy-cycle-card{border:1px solid var(--mist-border,#d3e5f0);border-radius:12px;background:var(--mist-white,#f8fbfd);min-width:0;overflow:hidden}.energy-cycle-card>summary{padding:12px 16px;min-height:48px;cursor:pointer;color:var(--mist-ink,#263b50)}.energy-cycle-card>summary strong{margin-left:6px;font-size:15px}.energy-cycle-card>summary span{font-size:13px;margin-left:16px;color:var(--mist-muted,#60768a)}.energy-cycle-card>summary:focus-visible{outline:2px solid var(--mist-primary,#4b75a2);outline-offset:-3px}.energy-cycle-body{padding:0 16px 16px}.energy-cycle-controls{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px;margin:8px 0 12px}.energy-cycle-controls>label{display:grid;gap:6px;font-size:13px;margin:0}.energy-cycle-controls input,.energy-cycle-controls select{min-height:44px;margin:0;width:100%}
.energy-cycle-periods{margin-top:12px;border:1px solid var(--mist-border,#d3e5f0);border-radius:8px;overflow:hidden}.energy-cycle-period{display:grid;grid-template-columns:minmax(140px,1fr) minmax(200px,1fr) minmax(230px,1.25fr);gap:20px;align-items:center;padding:12px;border-top:1px solid var(--mist-border,#d3e5f0)}.energy-cycle-period:first-child{border-top:0}.energy-cycle-period-name,.energy-cycle-result{display:grid;gap:6px;min-width:0}.energy-cycle-period-name strong{font-size:14px}.energy-cycle-period small{color:var(--mist-muted,#60768a);font-size:12px}.energy-cycle-result b{font-size:14px;font-variant-numeric:tabular-nums;overflow-wrap:anywhere;font-weight:500}.energy-cycle-arrival{display:grid;grid-template-columns:minmax(0,1fr) 80px;gap:8px}.energy-cycle-arrival label{display:grid;gap:4px;margin:0;font-size:12px}.energy-cycle-arrival input,.energy-cycle-arrival select{margin:0;width:100%;min-height:44px}
@media(max-width:1000px){.energy-cycle-period{grid-template-columns:minmax(0,1fr) minmax(180px,1fr);gap:12px}.energy-cycle-result{grid-column:1/-1;display:flex;flex-wrap:wrap;align-items:baseline;gap:8px}}
@media(max-width:700px){.energy-policy-offset,.energy-policy-choice,.energy-policy-switch,.energy-policy-month-end{font-size:16px}.energy-cycle-heading{flex-direction:column;gap:12px}.energy-cycle-controls{grid-template-columns:minmax(0,1fr)}.energy-cycle-period{grid-template-columns:minmax(0,1fr);gap:10px}.energy-cycle-card>summary span{display:block;margin:6px 0 0 20px}.energy-cycle-arrival{grid-template-columns:minmax(0,1fr) 90px}.energy-cycle-controls input,.energy-cycle-controls select,.energy-cycle-arrival input,.energy-cycle-arrival select,.energy-policy-month-end input{font-size:16px}.energy-cycle-result{grid-column:auto;display:grid;gap:6px}}

/* Room history: a single room context, current bills, then comparable trends and older records. */
.energy-room-history-modal.v1777{gap:12px}.energy-history-context{display:flex;flex-wrap:wrap;gap:8px;align-items:center;padding:8px 12px;background:#eaf3f8;border-radius:9px;color:#48637a;font-size:13px}.energy-history-context span+span{padding-left:9px;border-left:1px solid #c8dbe8}.energy-history-scroll{flex:1;min-height:0;overflow:auto;display:grid;align-content:start;gap:14px;padding-right:3px}.energy-history-current-grid,.energy-history-chart-grid,.energy-history-group-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px}.energy-history-current-card,.energy-history-chart-panel,.energy-history-group{min-width:0;border:1px solid #d3e5f0;border-radius:11px;background:#f8fbfd;overflow:hidden}.energy-history-current-card{border-top:3px solid #4b75a2}.energy-history-current-card.water,.energy-history-chart-panel.water,.energy-history-group.water{--energy-accent:#2799b6}.energy-history-current-card.gas,.energy-history-chart-panel.gas,.energy-history-group.gas{--energy-accent:#dc922c}.energy-history-current-card.electric,.energy-history-chart-panel.electric,.energy-history-group.electric{--energy-accent:#4b75a2}.energy-history-current-card{border-top-color:var(--energy-accent,#4b75a2)}.energy-history-current-card>header,.energy-history-group>header{display:flex;justify-content:space-between;align-items:center;gap:8px;padding:10px 12px;background:#eaf3f8;color:#263b50}.energy-history-current-card>header small,.energy-history-group>header span{color:#60768a;font-size:12px}.energy-history-current-card>p,.energy-history-group-empty{margin:0;padding:17px;color:#60768a;font-size:13px}.energy-history-bill{padding:10px 12px;border-top:1px solid #d3e5f0;background:#fff}.energy-history-bill.current{border-top:0}.energy-history-bill-main{display:flex;align-items:center;gap:10px;flex-wrap:wrap;min-width:0}.energy-history-bill-main time{font-weight:700;color:#48637a;font-size:13px}.energy-history-bill-main strong{font-size:19px;color:#215d89;font-variant-numeric:tabular-nums}.energy-history-bill-main>span:not(.energy-status):not(.energy-payment-pill){font-size:12px;color:#60768a}.energy-history-bill-actions{display:flex;justify-content:space-between;align-items:center;gap:8px;margin-top:9px}.energy-history-bill-actions .energy-history-actions{display:flex;flex-wrap:wrap;justify-content:flex-end;gap:5px}.energy-history-bill-actions .energy-history-actions .btn{min-width:0;min-height:34px;padding:5px 8px;font-size:12px}.energy-history-bill-actions .energy-history-actions .btn:disabled{display:none}.energy-history-chart{padding:11px;border:1px solid #d3e5f0;border-radius:11px;background:#fff}.energy-history-chart-panel{padding:10px 12px;display:grid;gap:10px}.energy-history-chart-panel h5{margin:0;font-size:14px;color:#263b50}.energy-history-chart-panel p{margin:10px 0;color:#60768a;font-size:13px}.energy-history-bars{display:grid;grid-auto-flow:column;grid-auto-columns:minmax(0,1fr);align-items:end;gap:5px;height:166px}.energy-history-bar-item{display:grid;grid-template-rows:30px minmax(0,1fr) 27px;align-items:end;justify-items:center;min-width:0;height:100%;font-variant-numeric:tabular-nums}.energy-history-bar-item b{max-width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;color:#355b7c;font-size:10px}.energy-history-bar-item small{max-width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;color:#60768a;font-size:10px}.energy-history-bar-track{display:flex;align-items:end;width:min(100%,28px);height:100%;border-radius:5px 5px 0 0;background:#eaf3f8}.energy-history-bar-track i{display:block;width:100%;min-height:3px;border-radius:5px 5px 0 0;background:var(--energy-accent,#4b75a2)}.energy-history-older{display:grid;gap:8px}.energy-history-group>div{display:grid;align-content:start}.energy-history-group>header h4{margin:0;font-size:14px}.energy-history-group .energy-history-bill-main strong{font-size:16px}.energy-history-group .energy-history-bill-actions{flex-wrap:wrap}.energy-history-group .energy-history-actions{flex:1}.energy-history-current-card .energy-history-bill-main{min-height:40px}
@media(max-width:1120px){.energy-history-current-grid,.energy-history-chart-grid,.energy-history-group-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:700px){.energy-history-current-grid,.energy-history-chart-grid,.energy-history-group-grid{grid-template-columns:minmax(0,1fr)}.energy-history-context{font-size:12px}.energy-history-bill-actions{align-items:flex-start;flex-direction:column}.energy-history-bill-actions .energy-history-actions{justify-content:flex-start}.energy-history-chart-panel{min-height:195px}.energy-history-bar-item b{font-size:11px}}

/* Three independent utility cycles: readable on desktop, no horizontal scrolling on phone. */
.energy-progress-summary:has(.energy-cycle-overview){display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px}.energy-cycle-overview{min-width:0;padding:13px;border:1px solid #d3e5f0;border-top:3px solid var(--cycle-accent,#4b75a2);border-radius:11px;background:#f8fbfd}.energy-cycle-overview.electric{--cycle-accent:#4b75a2}.energy-cycle-overview.water{--cycle-accent:#2799b6}.energy-cycle-overview.gas{--cycle-accent:#dc922c}.energy-cycle-overview>header{display:flex;justify-content:space-between;align-items:flex-start;gap:7px}.energy-cycle-overview>header>div{display:grid;gap:3px}.energy-cycle-overview>header b{color:#263b50;font-size:16px}.energy-cycle-overview>header small{color:#60768a;font-size:12px}.energy-cycle-overview>header>span{flex-shrink:0;color:#48637a;font-size:12px}.energy-cycle-timeline{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:5px;list-style:none;margin:15px 0 12px;padding:0}.energy-cycle-timeline li{display:grid;gap:4px;align-content:start;min-width:0;position:relative}.energy-cycle-timeline li:not(:last-child):after{content:'';position:absolute;top:13px;left:27px;width:calc(100% - 20px);height:2px;background:#cbdde9}.energy-cycle-timeline i{display:grid;place-items:center;width:26px;height:26px;border-radius:50%;background:#d6e4ec;color:#526b7e;font-size:12px;font-style:normal;font-weight:800}.energy-cycle-timeline .done i{background:#e0f3e8;color:#237547}.energy-cycle-timeline .overdue i{background:#ffe8db;color:#a85228}.energy-cycle-timeline b{font-size:12px;color:#263b50}.energy-cycle-timeline time{font-size:11px;color:#60768a;overflow-wrap:anywhere}.energy-cycle-counts{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:5px}.energy-cycle-counts>span{display:grid;gap:3px;min-width:0;padding:7px;border-radius:7px;background:#eaf3f8}.energy-cycle-counts>span small{font-size:11px;color:#60768a;overflow-wrap:anywhere}.energy-cycle-counts>span b{font-size:16px;color:#315b7d}.energy-cycle-missing-rooms{display:flex;gap:5px;align-items:center;flex-wrap:wrap;margin:10px 0 0;font-size:11px;color:#60768a}.energy-cycle-missing-rooms b{font-size:12px;color:#985d18}.energy-cycle-missing-rooms span{padding:2px 6px;border-radius:5px;background:#fff0db;color:#795113}.energy-cycle-missing-rooms small{font-size:11px}.energy-progress-kind-group{display:grid;gap:6px;margin-bottom:8px}.energy-progress-kind-group>header{display:flex;justify-content:space-between;align-items:center;padding:8px 10px;border-radius:8px;background:#eaf3f8}.energy-progress-kind-group h5{margin:0;color:#263b50;font-size:14px}.energy-progress-kind-group>header span{font-size:12px;color:#60768a}.energy-incomplete-item.v1777{display:grid;grid-template-columns:minmax(225px,1fr) minmax(150px,.75fr) auto;gap:10px;align-items:center;border-color:#d3e5f0;border-left-color:#4b75a2;background:#fff}.energy-incomplete-item.v1777 .energy-incomplete-identity>strong{font-size:14px}.energy-incomplete-statuses{display:flex;gap:5px;flex-wrap:wrap}.energy-incomplete-statuses span{padding:5px 7px;border-radius:6px;background:#fff0db;color:#915a15;font-size:11px;font-weight:700}.energy-incomplete-item.v1777 .energy-progress-row-actions{grid-column:auto;grid-row:auto}.energy-incomplete-item.v1777 .energy-progress-buttons{display:flex;gap:5px;flex-wrap:wrap;justify-content:flex-end}
@media(max-width:1180px){.energy-progress-summary:has(.energy-cycle-overview){grid-template-columns:repeat(2,minmax(0,1fr))}.energy-incomplete-item.v1777{grid-template-columns:minmax(0,1fr) auto}.energy-incomplete-statuses{grid-column:1}.energy-incomplete-item.v1777 .energy-progress-row-actions{grid-column:2;grid-row:1/3}}
@media(max-width:750px){.energy-progress-summary:has(.energy-cycle-overview){grid-template-columns:minmax(0,1fr)}.energy-incomplete-item.v1777{grid-template-columns:minmax(0,1fr)}.energy-incomplete-statuses,.energy-incomplete-item.v1777 .energy-progress-row-actions{grid-column:auto;grid-row:auto}.energy-incomplete-item.v1777 .energy-progress-buttons{justify-content:flex-start}.energy-cycle-counts>span small{font-size:10px}.energy-cycle-timeline time{font-size:10px}}

/* Room bills: the trend leads, current actions stay on one line, and older rows expand in batches. */
.energy-room-history-modal.v1777{gap:8px}
.energy-room-history-modal.v1777 .energy-history-scroll{gap:10px}
.energy-room-history-modal.v1777 .energy-history-context{padding:6px 10px}
.energy-room-history-modal.v1777 .energy-history-chart{padding:9px 10px}
.energy-room-history-modal.v1777 .energy-history-chart-grid{gap:8px}
.energy-room-history-modal.v1777 .energy-history-chart-panel{gap:4px;padding:8px 10px;background:#f8fbfd}
.energy-history-line-wrap{min-width:0}
.energy-history-line{display:block;width:100%;height:84px;overflow:visible}
.energy-history-line .energy-history-axis{stroke:#cbdde9;stroke-width:.7;vector-effect:non-scaling-stroke}
.energy-history-line polyline{fill:none;stroke:var(--energy-accent,#4b75a2);stroke-width:2;stroke-linecap:round;stroke-linejoin:round;vector-effect:non-scaling-stroke}
.energy-history-line ellipse{fill:var(--energy-accent,#4b75a2);stroke:#fff;stroke-width:1;vector-effect:non-scaling-stroke}
.energy-history-line-labels,.energy-history-chart-values{display:flex;justify-content:space-between;gap:8px;color:#60768a;font-size:11px;font-variant-numeric:tabular-nums}
.energy-history-chart-values{padding-top:3px;border-top:1px solid #d3e5f0}
.energy-history-chart-values b{color:#315b7d;font-size:13px}
.energy-room-history-modal.v1777 .energy-history-current-card>header,.energy-room-history-modal.v1777 .energy-history-group>header{padding:7px 10px}
.energy-room-history-modal.v1777 .energy-history-current-card>header b,.energy-room-history-modal.v1777 .energy-history-group>header h4{font-size:13px}
.energy-room-history-modal.v1777 .energy-history-bill{position:relative;padding:8px 10px;min-width:0}
.energy-room-history-modal.v1777 .energy-history-bill.current{padding-right:10px}
.energy-history-bill-flags{display:flex;justify-content:flex-end;gap:4px;min-height:21px;white-space:nowrap}
.energy-room-history-modal.v1777 .energy-history-bill-main{gap:6px;flex-wrap:nowrap;min-height:0;overflow:hidden}
.energy-room-history-modal.v1777 .energy-history-bill-main time{flex-shrink:0;font-size:12px}
.energy-room-history-modal.v1777 .energy-history-bill-main strong{font-size:16px;white-space:nowrap}
.energy-room-history-modal.v1777 .energy-history-bill-main>span{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.energy-room-history-modal.v1777 .energy-history-bill-actions{display:flex;justify-content:flex-start;align-items:center;flex-wrap:nowrap;gap:6px;margin-top:5px}
.energy-room-history-modal.v1777 .energy-history-bill-actions .btn,.energy-history-load-more,.energy-history-more-actions>summary{min-height:34px;padding:5px 8px;font-size:12px}
.energy-history-load-more{display:block;width:100%;border:0;border-top:1px solid #d3e5f0;background:#f0f6fa;color:#315b7d;cursor:pointer;font-weight:600}
.energy-history-load-more:hover,.energy-history-more-actions>summary:hover{background:#e1edf5}
.energy-history-load-more:focus-visible,.energy-history-more-actions>summary:focus-visible{outline:2px solid #4b75a2;outline-offset:2px}
.energy-room-history-modal.v1777 .energy-history-group .energy-history-bill{display:grid;grid-template-columns:minmax(0,1fr) auto auto;column-gap:5px;align-items:center;padding:5px 8px}
.energy-room-history-modal.v1777 .energy-history-group .energy-history-bill-flags{grid-column:2;grid-row:1;justify-content:flex-start;min-height:0;gap:2px}
.energy-room-history-modal.v1777 .energy-history-group .energy-history-bill-main{grid-column:1;grid-row:1;gap:4px}
.energy-room-history-modal.v1777 .energy-history-group .energy-history-bill-main strong{font-size:14px}
.energy-room-history-modal.v1777 .energy-history-group .energy-history-bill-actions{grid-column:3;grid-row:1;justify-content:flex-end;margin:0;gap:3px}
.energy-room-history-modal.v1777 .energy-history-group .energy-history-bill-actions .btn,.energy-room-history-modal.v1777 .energy-history-group .energy-history-photo-link{min-width:0;padding:4px 5px;font-size:11px}
.energy-room-history-modal.v1777 .energy-history-group .energy-history-bill-flags .energy-status,.energy-room-history-modal.v1777 .energy-history-group .energy-history-bill-flags .energy-payment-pill{font-size:10px;padding:3px 4px}
.energy-room-history-modal.v1777 .energy-history-group .energy-history-more-actions{margin:0}
@media(max-width:1120px){.energy-room-history-modal.v1777 .energy-history-current-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.energy-room-history-modal.v1777 .energy-history-group-grid{grid-template-columns:minmax(0,1fr)}}
@media(max-width:700px){.energy-room-history-modal.v1777 .energy-history-current-grid,.energy-room-history-modal.v1777 .energy-history-chart-grid{grid-template-columns:minmax(0,1fr)}.energy-room-history-modal.v1777 .energy-history-chart-panel{display:grid;grid-template-columns:48px minmax(0,1fr) 70px;align-items:center;gap:7px;padding:5px 8px;min-height:0}.energy-room-history-modal.v1777 .energy-history-chart-panel h5{font-size:12px}.energy-room-history-modal.v1777 .energy-history-chart-panel p{grid-column:2/-1;margin:0}.energy-room-history-modal.v1777 .energy-history-line{height:43px}.energy-room-history-modal.v1777 .energy-history-line-labels{font-size:9px}.energy-room-history-modal.v1777 .energy-history-chart-values{display:grid;gap:2px;border:0;border-left:1px solid #d3e5f0;padding:0 0 0 6px;font-size:10px}.energy-room-history-modal.v1777 .energy-history-chart-values b{font-size:12px}.energy-room-history-modal.v1777 .energy-history-bill-actions{flex-direction:row;align-items:center}.energy-room-history-modal.v1777 .energy-history-group .energy-history-bill{grid-template-columns:minmax(0,1fr) auto;row-gap:4px}.energy-room-history-modal.v1777 .energy-history-group .energy-history-bill-main{grid-column:1/-1;grid-row:1}.energy-room-history-modal.v1777 .energy-history-group .energy-history-bill-flags{grid-column:1;grid-row:2}.energy-room-history-modal.v1777 .energy-history-group .energy-history-bill-actions{grid-column:2;grid-row:2;justify-content:flex-end}.energy-room-history-modal.v1777 .energy-history-group .energy-history-more-actions{margin-left:auto}}

/* V17.8.0: read-only analysis, compact filtering, and original-bill verification. */
.energy-cost-kpis>.energy-kpi-static{position:relative;display:grid;grid-template-columns:40px minmax(0,1fr);grid-template-rows:auto auto auto;column-gap:9px;min-width:0;min-height:92px;padding:11px 12px;border:1px solid #d2e0eb;border-radius:13px;background:#fff;text-align:left;cursor:default}
.energy-cost-kpis>.energy-kpi-static .energy-kpi-icon{grid-row:1/4}.energy-cost-kpis>.energy-kpi-static small{align-self:end}.energy-cost-kpis>.energy-kpi-static b{margin:3px 0 1px;font-size:22px}.energy-cost-kpis>.energy-kpi-static em{overflow:hidden;color:#60768a;font-size:12px;font-style:normal;text-overflow:ellipsis;white-space:nowrap}
.energy-history-period-filter{display:inline-flex;align-items:center;gap:7px;margin-left:auto;white-space:nowrap;font-size:12px;font-weight:700}.energy-history-period-filter select{min-width:142px;min-height:34px;margin:0;padding:4px 8px;border:1px solid #9fb9cc;border-radius:7px;background:#fff;color:#263b50;font-size:13px}
.energy-progress-filters .energy-progress-sort{margin-left:0;min-height:33px;white-space:nowrap}.energy-progress-filters .recent{margin-left:auto}.energy-missing-main>.energy-section-title{margin-bottom:5px}
.custody-task-explainer{display:grid;gap:5px;padding:11px 13px;border:1px solid #bfd6e7;border-left:4px solid #4b75a2;border-radius:9px;background:#eef6fb;color:#263b50;line-height:1.5}.custody-task-explainer p{margin:0;overflow-wrap:anywhere}.custody-task-explainer p+p{color:#4e657a;font-size:13px}
.modal.modal-energy-proof{width:min(1240px,calc(100vw - 22px));max-height:94vh}.modal-energy-proof .energy-proof-layout{display:grid;grid-template-columns:minmax(0,1.2fr) minmax(350px,.8fr);gap:12px;min-height:0;height:min(72vh,680px);padding:12px;overflow:hidden}.energy-proof-media,.energy-proof-form{min-width:0;min-height:0;border:1px solid #d3e5f0;border-radius:11px;background:#f8fbfd}.energy-proof-media{display:flex;flex-direction:column;overflow:hidden}.energy-proof-media>header{display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:7px;padding:8px 10px;background:#eaf3f8}.energy-proof-media>header>div:first-child{display:grid;gap:2px}.energy-proof-media>header b{color:#263b50;font-size:14px}.energy-proof-media>header small{color:#4e657a;font-size:11px}.energy-proof-tools{display:flex;flex-wrap:wrap;align-items:center;gap:4px}.energy-proof-tools button,.energy-proof-full{min-width:34px;min-height:34px;padding:4px 7px;border:1px solid #9bb4c8;border-radius:7px;background:#fff;color:#315b7d;font-size:13px;font-weight:700;cursor:pointer}.energy-proof-tools span{min-width:42px;text-align:center;color:#4e657a;font-size:12px}.energy-proof-stage{display:grid;flex:1;min-height:180px;place-items:center;overflow:hidden;background:#dfeaf1;touch-action:none;cursor:default}.energy-proof-stage.zoomed{cursor:grab}.energy-proof-stage.zoomed:active{cursor:grabbing}.energy-proof-stage img{display:block;max-width:100%;max-height:100%;object-fit:contain;user-select:none;will-change:transform}.energy-proof-stage p{max-width:36ch;margin:12px;text-align:center;color:#60768a}.energy-proof-stage.loading{background:#eaf3f8}.energy-proof-full{align-self:flex-end;margin:6px 9px}.energy-proof-form{display:flex;flex-direction:column;gap:10px;overflow:auto;padding:14px}.energy-proof-form h3{margin:0;color:#263b50;font-size:17px}.energy-proof-facts{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:6px;margin:0}.energy-proof-facts>div{min-width:0;padding:7px 9px;border-radius:7px;background:#eaf3f8}.energy-proof-facts dt{color:#60768a;font-size:11px}.energy-proof-facts dd{margin:3px 0 0;overflow-wrap:anywhere;color:#263b50;font-size:13px;font-weight:700}.energy-proof-facts>div:nth-child(5) dd{color:#215d89;font-family:Georgia,serif;font-size:19px}.energy-proof-form .energy-form-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.energy-proof-form .energy-payment-confirm{padding:9px 10px}.energy-proof-form .energy-review-warning{padding:8px 10px}.energy-proof-form .modal-actions{position:sticky;bottom:-14px;z-index:1;flex-wrap:wrap;margin:auto -14px -14px;padding:10px 14px;background:#f8fbfd;border-top:1px solid #d3e5f0}.energy-proof-reviewed{margin:0;color:#4e657a;font-size:12px}.energy-proof-form>label{display:grid;gap:4px}.energy-proof-form textarea{width:100%;min-height:78px}
.energy-proof-tools button:focus-visible,.energy-proof-full:focus-visible,.energy-proof-stage:focus-visible,.energy-history-period-filter select:focus-visible{outline:2px solid #4b75a2;outline-offset:2px}
@media(max-width:900px){.modal-energy-proof .energy-proof-layout{grid-template-columns:minmax(0,1fr) minmax(320px,.85fr)}.energy-proof-media>header{align-items:flex-start}.energy-proof-tools{width:100%}}
@media(max-width:700px){.energy-history-period-filter{width:100%;margin-left:0}.energy-history-period-filter select{flex:1}.modal.modal-energy-proof{width:calc(100vw - 10px);height:calc(100dvh - 10px);max-height:calc(100dvh - 10px)}.modal-energy-proof .energy-proof-layout{display:flex;flex-direction:column;height:auto;min-height:0;overflow:auto}.energy-proof-media{flex:none}.energy-proof-tools button{min-width:40px;min-height:40px}.energy-proof-stage{height:min(38vh,320px);min-height:220px}.energy-proof-form{overflow:visible;flex:none}.energy-proof-form .energy-form-grid,.energy-proof-facts{grid-template-columns:repeat(2,minmax(0,1fr))}.energy-cost-kpis>.energy-kpi-static{min-height:78px}.energy-progress-filters .recent{margin-left:0}}
@media(max-width:420px){.energy-proof-facts{grid-template-columns:minmax(0,1fr)}.energy-proof-tools button{min-width:32px}.energy-proof-form .energy-form-grid{grid-template-columns:minmax(0,1fr)}}

/* Large review workspace: the paper remains the primary surface. */
.modal.modal-energy-proof{display:flex;flex-direction:column;width:95vw;height:95dvh;max-height:95dvh;overflow:hidden}
.modal-energy-proof .modal-head{flex:0 0 auto}
.modal-energy-proof #modalBody{flex:1;min-height:0;overflow:hidden}
.modal-energy-proof .energy-proof-layout{box-sizing:border-box;height:100%;grid-template-columns:minmax(0,1.55fr) minmax(360px,.85fr)}
.energy-proof-stage{position:relative;cursor:grab}
.energy-proof-stage.dragging{cursor:grabbing}
.energy-proof-layer{position:absolute;left:50%;top:50%;max-width:none;max-height:none;transform-origin:center;will-change:auto}
.energy-proof-stage.dragging .energy-proof-layer{will-change:transform}
.energy-proof-stage .energy-proof-layer img{display:block;width:100%;height:100%;max-width:none;max-height:none;object-fit:contain;pointer-events:none;will-change:auto}
.energy-review-modal #erCorrections{padding:10px;border:1px solid #c9dcea;border-radius:9px;background:#eef6fb}
@media(max-width:700px){.modal.modal-energy-proof{width:calc(100vw - 10px);height:calc(100dvh - 10px);max-height:calc(100dvh - 10px)}.modal-energy-proof #modalBody{overflow:auto}.modal-energy-proof .energy-proof-layout{height:auto;display:flex;flex-direction:column;overflow:auto}.energy-proof-stage{height:min(38vh,320px)}.energy-proof-form{overflow:visible}}

/* V17.8.2: one chronological backlog per room/type, month-aware search. */
#page-energy .energy-room-filters{grid-template-columns:minmax(220px,2fr) minmax(120px,1fr) minmax(120px,1fr) minmax(150px,1fr) auto}
.energy-non-current-badge{margin-left:4px;color:#b42332;font-size:11px;font-style:normal;font-weight:700;white-space:nowrap}
.energy-room-workflow>header{flex-wrap:wrap}
.energy-room-history-modal.v1777 .energy-history-current .energy-section-title{display:flex;align-items:center;justify-content:space-between;gap:8px;flex-wrap:wrap}
.energy-room-history-modal.v1777 .energy-history-current-card .energy-history-bill-actions{justify-content:flex-start;flex-wrap:wrap}

/* V17.8.3: visible actions, legible period-specific backlog labels. */
.energy-history-action-link{display:inline-flex;align-items:center;justify-content:center;min-height:34px;min-width:0;padding:4px 5px;border:0;border-radius:4px;background:transparent;color:#215d89;font:inherit;font-size:12px;font-weight:600;white-space:nowrap;cursor:pointer;text-decoration:underline;text-underline-offset:3px;text-decoration-color:#b5cbdc}
.energy-history-action-link.danger{color:#b42332;text-decoration-color:#dfb9be}
.energy-history-action-link:hover{background:#eaf3f8;text-decoration-color:currentColor}
.energy-history-action-link:focus-visible{outline:2px solid #4b75a2;outline-offset:1px}
.energy-room-history-modal.v1777 .energy-history-group{container-type:inline-size}
.energy-room-history-modal.v1777 .energy-history-group .energy-history-bill-actions{flex-wrap:wrap;min-width:0;gap:4px}
.energy-room-history-modal.v1777 .energy-history-group .energy-history-photo-link{border:0;background:transparent;color:#215d89;font-size:12px;text-decoration:underline;text-underline-offset:3px}
.energy-incomplete-item.v1777 .energy-incomplete-identity h4{white-space:normal;overflow:visible;overflow-wrap:anywhere}
.energy-incomplete-list .energy-pending-area{margin-left:6px;color:var(--mist-muted,#60768a);font-size:12px;font-weight:400}
.energy-incomplete-list>.energy-progress-pager>span{color:var(--mist-muted,#60768a);font-size:13px;font-weight:400}
.energy-incomplete-statuses{align-items:center}
.energy-incomplete-statuses>span{white-space:nowrap}
.energy-incomplete-statuses>.energy-non-current-badge{margin:0}
@container(max-width:600px){
  .energy-room-history-modal.v1777 .energy-history-group .energy-history-bill{grid-template-columns:minmax(0,1fr) auto;row-gap:0}
  .energy-room-history-modal.v1777 .energy-history-group .energy-history-bill-main{grid-column:1;grid-row:1;flex-wrap:wrap;overflow:visible}
  .energy-room-history-modal.v1777 .energy-history-group .energy-history-bill-flags{grid-column:2;grid-row:1}
  .energy-room-history-modal.v1777 .energy-history-group .energy-history-bill-actions{grid-column:1/-1;grid-row:2;justify-content:flex-end}
}
@media(max-width:700px),(pointer:coarse){
  .energy-history-action-link,.energy-room-history-modal.v1777 .energy-history-group .energy-history-photo-link{min-height:44px;min-width:44px}
}
.energy-room-history-modal.v1777 .energy-history-current-card .energy-history-actions{margin-left:auto}
@media(max-width:1000px){#page-energy .energy-room-filters{grid-template-columns:repeat(2,minmax(0,1fr))}.energy-room-query-wrap{grid-column:1/-1}.energy-room-filter-actions{grid-column:1/-1}}
@media(max-width:620px){#page-energy .energy-room-filters{grid-template-columns:minmax(0,1fr)}.energy-room-query-wrap,.energy-room-filter-actions{grid-column:auto}.energy-room-history-modal.v1777 .energy-history-current-card .energy-history-actions{margin-left:0}}

/* Compact query conditions and independent ordering share one applied scope. */
.energy-bill-search-form{display:flex;align-items:end;flex-wrap:wrap;gap:9px;margin-bottom:8px;padding:10px;border:1px solid #d3e5f0;border-radius:11px;background:#f8fbfd}
.energy-bill-search-fields{display:flex;align-items:end;flex-wrap:wrap;flex:1;gap:8px}
.energy-bill-search-fields>label{display:grid;gap:4px;flex:0 0 calc(6em + 36px);min-width:0;margin:0;color:#526e84;font-size:12px;font-weight:600}
.energy-bill-search-fields>label.energy-search-keyword{flex:1 0 160px}
.energy-bill-search-fields input,.energy-bill-search-fields select{width:100%;min-width:0;min-height:36px;padding:6px 7px;border:1px solid #a9c0d3;border-radius:7px;background:#fff;color:#263b50;font-size:12px}
.energy-bill-search-bottom{display:flex;align-items:end;gap:10px;flex-wrap:wrap}
.energy-search-types{min-width:0;margin:0;padding:0;border:0}
.energy-search-types legend{margin:0 0 4px;padding:0;color:#526e84;font-size:12px;font-weight:600}
.energy-search-types label{display:inline-flex;align-items:center;gap:4px;min-height:36px;margin:0;padding:5px 6px;border:1px solid #bfd3e2;border-radius:6px;background:#fff;color:#315b7d;font-size:12px;font-weight:600;white-space:nowrap;cursor:pointer}
.energy-search-types label:has(input:checked){border-color:#4b75a2;background:#e9f2fb}
.energy-search-types input{width:16px;height:16px;margin:0;accent-color:#4b75a2}
.energy-search-submit{display:flex;gap:6px;margin-left:auto}.energy-search-submit .btn{min-width:52px;min-height:36px;padding:6px 10px;font-size:12px}
.energy-progress-panel .energy-progress-filters{flex-wrap:wrap;overflow:visible;gap:6px}
.energy-search-sort-controls{display:flex;align-items:center;gap:8px;margin-left:auto;padding-left:14px;border-left:1px solid #cbdde9;color:#60768a;font-size:12px}
.energy-search-sort-controls label{display:flex;align-items:center;gap:7px;margin:0;white-space:nowrap}
.energy-progress-panel .energy-search-sort-controls select{width:auto;min-height:34px;padding:4px 18px 4px 3px;border:0;border-bottom:1px solid #a9c0d3;border-radius:0;background:transparent;color:#315b7d;font-size:12px;cursor:pointer}
.energy-search-sort-controls select:focus-visible{outline:2px solid #4b75a2;outline-offset:2px}
.energy-bill-search-fields :is(input,select):focus-visible,.energy-search-types input:focus-visible,.energy-search-submit .btn:focus-visible,.energy-progress-filters button:focus-visible{outline:2px solid #4b75a2;outline-offset:2px}
.energy-progress-panel .energy-progress-summary.search-summary{display:grid;grid-template-columns:repeat(var(--energy-type-count,3),minmax(0,1fr));gap:10px}
.energy-search-type-card{min-width:0;padding:13px;border:1px solid #d3e5f0;border-top:3px solid var(--cycle-accent,#4b75a2);border-radius:11px;background:#f8fbfd}
.energy-search-type-card.electric{--cycle-accent:#4b75a2}.energy-search-type-card.water{--cycle-accent:#2799b6}.energy-search-type-card.gas{--cycle-accent:#dc922c}
.energy-search-type-card header{display:flex;align-items:flex-start;justify-content:space-between;gap:8px}.energy-search-type-card header>div{display:grid;gap:3px}.energy-search-type-card header b{color:#263b50;font-size:17px}.energy-search-type-card header small{color:#60768a;font-size:12px}.energy-search-type-card header strong{color:#315b7d;font-size:16px;white-space:nowrap}
.energy-search-type-card dl{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:7px;margin:13px 0 0}.energy-search-type-card dl>div{min-width:0;padding:9px;border-radius:7px;background:#eaf3f8}.energy-search-type-card dt{color:#526e84;font-size:11px}.energy-search-type-card dd{margin:3px 0 0;color:#315b7d;font-size:17px;font-weight:800}.energy-search-void{display:block;margin-top:8px;color:#60768a;font-size:11px}
.energy-search-bill .energy-incomplete-statuses span{background:#fff0db;color:#915a15}.energy-search-bill .energy-incomplete-statuses span.done{background:#e7f5ec;color:#247346}.energy-search-bill .energy-incomplete-statuses span.void{background:#edf0f2;color:#546b7b}.energy-search-bill .energy-incomplete-statuses span.energy-search-period{background:#eaf3f8;color:#315b7d}
.energy-disabled-room{margin-left:5px;color:#805b32;font-size:12px;font-weight:600}.energy-search-bill{border-left-color:#4b75a2;background:#fff}
.energy-search-bill .energy-incomplete-identity h4{white-space:normal;overflow:visible}
@media(max-width:900px){.energy-search-type-card dl{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:700px){.energy-bill-search-fields{flex-basis:100%}.energy-bill-search-fields>label{flex:1 0 calc(50% - 8px)}.energy-bill-search-fields>label.energy-search-keyword{flex-basis:100%}.energy-bill-search-bottom{width:100%}.energy-progress-panel .energy-progress-summary.search-summary{grid-template-columns:minmax(0,1fr)}.energy-search-submit .btn{min-height:44px}.energy-search-types label{min-height:44px}.energy-search-sort-controls{width:100%;margin:4px 0 0;padding:6px 0 0;border-left:0;border-top:1px solid #d3e5f0}.energy-bill-search-fields :is(input,select),.energy-search-sort-controls select{min-height:44px}}
@media(pointer:coarse){.energy-bill-search-fields :is(input,select),.energy-progress-panel .energy-search-sort-controls select,.energy-search-types label,.energy-search-submit .btn{min-height:44px}}
.energy-current-photo{display:grid;gap:6px;width:180px;max-width:100%;min-height:44px;padding:8px;border:1px solid #b9cfe0;border-radius:9px;background:#f5f9fc;color:#315b7d;cursor:zoom-in}
.energy-current-photo img{width:100%;height:150px!important;max-height:150px!important;object-fit:contain;background:#eaf3f8;border-radius:5px}
.energy-current-photo span{font-size:12px;overflow-wrap:anywhere;line-height:1.5}
.energy-current-photo:focus-visible{outline:2px solid #4b75a2;outline-offset:3px}
.energy-manual-photo>.energy-single-preview{grid-template-columns:repeat(auto-fit,minmax(160px,180px));align-items:start}
.energy-single-preview>.energy-review-warning{grid-column:1/-1}
.energy-detail-photo img{height:120px!important;max-height:120px!important;object-fit:contain}
.energy-void-record .energy-review-summary{grid-template-columns:minmax(100px,.8fr) minmax(140px,1fr) minmax(0,2fr)}
.energy-void-record p{white-space:pre-wrap;overflow-wrap:anywhere}
@media(max-width:700px){.energy-void-record .energy-review-summary{grid-template-columns:minmax(0,1fr)}}
/* Continuous review keeps original media in place after the confirmed receipt. */
.modal-energy-proof #modalTitle{display:flex;align-items:center;gap:16px;flex-wrap:wrap;min-width:0;max-height:none;overflow:visible}
.energy-review-nav{display:inline-flex;align-items:center;gap:8px;flex-wrap:wrap;font-size:13px;font-weight:500}
.energy-review-nav [role=status]{color:#4c6783;font-variant-numeric:tabular-nums}
.energy-review-nav .btn{min-height:36px}
.energy-review-modal #erFeedback{color:#236444;font-size:13px;min-height:20px;margin:10px 0;overflow-wrap:anywhere}
.energy-review-modal :disabled{cursor:not-allowed}
@media(max-width:600px){.energy-review-nav{width:100%}.energy-review-nav .btn{min-height:44px}.modal-energy-proof #modalTitle{font-size:18px;gap:8px}.energy-review-nav [role=status]{flex-basis:100%}}
.energy-duplicate-overlay{position:fixed;inset:0;z-index:12000;background:#182c4866;display:grid;place-items:center;padding:16px}
.energy-duplicate-overlay>section{width:min(840px,100%);max-height:90dvh;overflow:auto;border-radius:16px;background:var(--card,#fff);padding:24px;box-shadow:0 20px 60px #132d4c44}
.energy-duplicate-overlay dd{margin:6px 0 18px;overflow-wrap:anywhere}
.energy-duplicate-overlay button{min-height:44px}
#ebeRecognition:not(:empty){padding:12px;border-radius:10px;background:#eef5fc;line-height:1.6}
/* V17.9.5: room + amount form one compact identity, not a stretched blank column. */
.energy-incomplete-item.v1777.energy-search-bill{grid-template-columns:minmax(240px,310px) minmax(0,1fr) auto;gap:16px;padding:12px}
.energy-search-bill .energy-incomplete-identity{grid-template-columns:34px minmax(0,1fr) auto;gap:10px}
.energy-search-bill .energy-incomplete-identity>strong{font-family:inherit;font-variant-numeric:tabular-nums;font-size:17px;white-space:nowrap}
.energy-search-bill .energy-incomplete-statuses{align-items:center;gap:6px}
.energy-search-bill .energy-incomplete-statuses>span{white-space:nowrap;font-size:12px}
.energy-incomplete-statuses .energy-non-current-badge{display:inline-flex;align-items:center;padding:5px 7px;border-radius:6px;background:#fcebed;color:#ac253c;font-style:normal;font-size:12px;font-weight:700;white-space:nowrap}
.energy-search-bill .energy-progress-buttons .btn{min-height:44px;font-size:12px}
.modal-energy-proof #modalTitle,.modal-energy-proof .energy-review-nav,.modal-energy-proof .energy-proof-tools,.modal-energy-proof .energy-proof-form{font-family:"PingFang SC","Microsoft YaHei",system-ui,sans-serif}
.modal-energy-proof #modalTitle{font-size:20px;font-weight:650;line-height:1.5;gap:20px}
.modal-energy-proof .energy-review-nav{gap:8px;font-size:13px;line-height:1.5}
.modal-energy-proof .energy-review-nav [role=status]{padding-right:12px;border-right:1px solid #d3e5f0}
.modal-energy-proof .energy-review-nav .btn{min-height:44px;font-size:13px;font-weight:600;padding:8px 12px}
.modal-energy-proof .energy-proof-tools button{min-height:44px;min-width:44px}
.energy-proof-form .energy-batch-actions{display:flex;flex-direction:column;align-items:stretch;gap:8px}
.energy-batch-actions #energyBatchNavigation{text-align:right}
.energy-batch-actions .energy-review-nav{justify-content:flex-end;width:100%;gap:8px}
.energy-batch-actions .energy-review-nav [role=status]{flex:1;text-align:left;border:0;padding:0}
.energy-batch-actions #energyBatchSummary{margin:0;font-size:12px;color:#4c6783;line-height:1.5;font-variant-numeric:tabular-nums}
.energy-batch-buttons{display:flex;flex-wrap:wrap;justify-content:flex-end;gap:8px}
.energy-batch-buttons .btn{min-height:44px;font-size:13px;padding:8px 12px}
.energy-batch-buttons [aria-pressed=true]{background:#e8f3fc;border-color:#4b75a2;color:#214f76}
.energy-batch-buttons .danger-outline[aria-pressed=true]{background:#fbecef;border-color:#bb3449;color:#a42439}
@media(max-width:700px){.energy-proof-form .energy-batch-actions{position:static}.energy-batch-buttons .btn{flex:1 1 42%}.energy-batch-actions .energy-review-nav [role=status]{flex-basis:100%}}
.energy-payment-modal #epayFeedback{flex-basis:100%;margin:0;color:#236444;font-size:13px;overflow-wrap:anywhere}
.energy-payment-modal :disabled{cursor:not-allowed}
@media(max-width:1100px){.energy-incomplete-item.v1777.energy-search-bill{grid-template-columns:minmax(215px,270px) minmax(0,1fr)}.energy-search-bill .energy-progress-row-actions{grid-column:1/-1}.energy-search-bill .energy-progress-buttons{justify-content:flex-start}}
@media(max-width:600px){.energy-incomplete-item.v1777.energy-search-bill{grid-template-columns:minmax(0,1fr);gap:10px}.energy-search-bill .energy-progress-row-actions{grid-column:1}.energy-search-bill .energy-progress-buttons{width:100%}.energy-search-bill .energy-progress-buttons .btn{flex:1}.modal-energy-proof #modalTitle{font-size:18px;gap:8px}.modal-energy-proof .energy-review-nav [role=status]{border:0;padding:0}.modal-energy-proof .energy-review-nav .btn{flex:1}}
