/* V82: live estimator surfaces share the approved V81 smoked glass.
   Accent colours belong to edges and highlights, not opaque colour fields.
   Geometry, typography, graphs, motion and PDF copies remain independent. */
body[data-page="project"] #roi .roi-panel:not(.pdf-snapshot-copy-v2) {
  --section-glass-edge:rgba(206,225,230,.28);
  --section-glass-divider:rgba(206,225,230,.18);
  --section-glass-surface:rgba(30,42,47,.48);
  --section-glass-deep:rgba(6,14,19,.56);
  --section-glass-reflection:linear-gradient(180deg,rgba(223,238,243,.055),rgba(223,238,243,.012) 72px,transparent 180px);
  background-color:rgba(13,22,25,.56);
  border-color:var(--section-glass-edge);
  box-shadow:0 14px 40px rgba(0,0,0,.12);
}
body[data-page="project"] #roi .roi-panel:not(.pdf-snapshot-copy-v2) #roiViewResults { --section-accent-rgb:139,231,139; }
body[data-page="project"] #roi .roi-panel:not(.pdf-snapshot-copy-v2) #roiViewBusiness { --section-accent-rgb:240,183,93; }
body[data-page="project"] #roi .roi-panel:not(.pdf-snapshot-copy-v2) #roiViewCarbon { --section-accent-rgb:159,146,255; }
body[data-page="project"] #roi .roi-panel:not(.pdf-snapshot-copy-v2) #roiViewEmc { --section-accent-rgb:111,158,255; }
body[data-page="project"] #roi .roi-panel:not(.pdf-snapshot-copy-v2) :is(#roiViewResults,#roiViewBusiness,#roiViewCarbon,#roiViewEmc) {
  background:linear-gradient(180deg,rgba(28,40,44,.22),rgba(12,20,23,.26));
}

/* The navigation retains its five colours and explicit selected state.
   A neutral undercoat prevents the coloured reflections becoming solid fills. */
body[data-page="project"] #roi .roi-panel:not(.pdf-snapshot-copy-v2) .roi-tab {
  background-color:rgba(24,35,40,.66);
  background-image:linear-gradient(160deg,rgba(var(--tab-accent-rgb),.085),rgba(223,238,243,.016) 65%);
}
body[data-page="project"] #roi .roi-panel:not(.pdf-snapshot-copy-v2) .roi-tab[aria-selected="true"] {
  background-color:rgba(39,53,59,.75);
  background-image:linear-gradient(160deg,rgba(var(--tab-accent-rgb),.18),rgba(223,238,243,.025) 80%);
}
@media (hover:hover) and (pointer:fine) {
  body[data-page="project"] #roi .roi-panel:not(.pdf-snapshot-copy-v2) .roi-tab[aria-selected="false"]:hover {
    background-color:rgba(33,46,52,.72);
    background-image:linear-gradient(160deg,rgba(var(--tab-accent-rgb),.12),rgba(223,238,243,.02) 75%);
  }
}

/* Main result and commercial cards. Do not paint their animated rings,
   progress tracks, bars or pseudo-element effects. */
body[data-page="project"] #roi .roi-panel:not(.pdf-snapshot-copy-v2) #roiViewResults :is(.equipment-category-v50,.roi-chart.finance),
body[data-page="project"] #roi .roi-panel:not(.pdf-snapshot-copy-v2) #roiViewBusiness :is(.business-year-row,.margin-comparison-card,.revenue-bridge-row,.business-kpis article),
body[data-page="project"] #roi .roi-panel:not(.pdf-snapshot-copy-v2) #roiViewCarbon :is(.carbon-dashboard-v2,.carbon-controls-v2,.carbon-result-v2) {
  border-color:rgba(206,225,230,.30);
  background-color:var(--section-glass-surface);
  background-image:var(--section-glass-reflection);
  box-shadow:0 8px 24px rgba(0,0,0,.09);
  -webkit-backdrop-filter:blur(12px) saturate(70%);
  backdrop-filter:blur(12px) saturate(70%);
}
body[data-page="project"] #roi .roi-panel:not(.pdf-snapshot-copy-v2) #roiViewBusiness .margin-comparison-card.enhanced,
body[data-page="project"] #roi .roi-panel:not(.pdf-snapshot-copy-v2) #roiViewCarbon :is(.carbon-result-v2.coal,.carbon-result-v2.co2) {
  border-color:rgba(215,231,236,.38);
  background-image:linear-gradient(160deg,rgba(var(--section-accent-rgb),.035),transparent 55%),var(--section-glass-reflection);
}
body[data-page="project"] #roi .roi-panel:not(.pdf-snapshot-copy-v2) #roiViewBusiness .business-kpis article {
  border-left-color:rgba(215,231,236,.46);
}
/* V84d: a brighter glass edge identifies the proposed system without
   changing the commercial card geometry or the carbon result frames. */
body[data-page="project"] #roi .roi-panel:not(.pdf-snapshot-copy-v2) #roiViewBusiness .margin-comparison-card.enhanced {
  border-color:rgba(188,229,213,.78);
  box-shadow:inset 0 0 0 1px rgba(210,242,228,.07),0 0 20px rgba(131,210,172,.045),0 8px 24px rgba(0,0,0,.09);
}
body[data-page="project"] #roi .roi-panel:not(.pdf-snapshot-copy-v2) #roiViewCarbon .carbon-formulas-v2 p {
  border-color:var(--section-glass-divider);
  background:rgba(26,38,43,.32);
}
body[data-page="project"] #roi .roi-panel:not(.pdf-snapshot-copy-v2) #roiViewCarbon .carbon-result-v2:hover {
  box-shadow:0 18px 42px rgba(0,0,0,.18);
}
body[data-page="project"] #roi .roi-panel:not(.pdf-snapshot-copy-v2) #roiViewCarbon .carbon-result-v2:focus-visible {
  box-shadow:0 0 0 2px #fff,0 0 0 5px currentColor;
}
body[data-page="project"] #roi .roi-panel:not(.pdf-snapshot-copy-v2) :is(#roiViewBusiness,#roiViewCarbon) :is(input,select,.money-input,.carbon-region-toggle):not([aria-invalid="true"]):not(.is-invalid) {
  background-color:var(--section-glass-deep);
  background-image:linear-gradient(180deg,rgba(0,0,0,.07),rgba(199,225,235,.018));
  border-color:var(--section-glass-edge);
}
body[data-page="project"] #roi .roi-panel:not(.pdf-snapshot-copy-v2) #roiViewBusiness .money-input > input:not([aria-invalid="true"]) {
  background:transparent;
}
body[data-page="project"] #roi .roi-panel:not(.pdf-snapshot-copy-v2) :is(#roiViewBusiness,#roiViewCarbon) :is(input,select,.carbon-region-toggle):not([aria-invalid="true"]):not(.is-invalid):is(:focus,:focus-visible,[aria-expanded="true"]),
body[data-page="project"] #roi .roi-panel:not(.pdf-snapshot-copy-v2) #roiViewBusiness .money-input:focus-within {
  border-color:rgba(var(--section-accent-rgb),.76);
  outline-color:rgba(var(--section-accent-rgb),.76);
}

/* V83: two softly tinted glass finishes, with the V80 selected indicator. */
body[data-page="project"] #roi .roi-panel:not(.pdf-snapshot-copy-v2) #roiViewEmc :is(.returns-mode-switch,.returns-mode-switch[data-returns-mode="emc"],.returns-mode-switch-track) {
  border-color:var(--section-glass-edge);
  background:rgba(23,34,40,.50);
}
body[data-page="project"] #roi .roi-panel:not(.pdf-snapshot-copy-v2) #roiViewEmc .returns-mode-switch-tab[data-returns-mode-tab="emc"] {
  --mode-accent:#a8b1df;
  --mode-accent-rgb:151,158,213;
  --mode-idle:rgba(32,39,52,.40);
  --mode-selected:rgba(54,64,87,.50);
}
body[data-page="project"] #roi .roi-panel:not(.pdf-snapshot-copy-v2) #roiViewEmc .returns-mode-switch-tab[data-returns-mode-tab="buyout"] {
  --mode-accent:#9bd6b4;
  --mode-accent-rgb:155,214,180;
  --mode-idle:rgba(30,48,42,.40);
  --mode-selected:rgba(49,79,65,.58);
}
body[data-page="project"] #roi .roi-panel:not(.pdf-snapshot-copy-v2) #roiViewEmc .returns-mode-switch-backdrop {
  background:linear-gradient(160deg,rgba(197,220,234,.08),rgba(23,37,45,.12));
}

/* Cool blue-violet EMC and sage buyout share the same transparency and reflection.
   Customer/investor/negative chart colours keep their existing meaning. */
body[data-page="project"] #roi .roi-panel:not(.pdf-snapshot-copy-v2) #roiViewEmc .emc-dashboard-v2 {
  --section-accent-rgb:151,158,213;
  --finance-glass-base:rgba(29,36,46,.42);
  --finance-glass-panel:rgba(43,51,65,.43);
  --finance-glass-fixed:rgba(62,72,91,.64);
  --finance-glass-fixed-edge:rgba(202,211,235,.52);
  --finance-glass-manual:rgba(36,46,65,.72);
  --finance-glass-inset:rgba(19,25,35,.36);
  --finance-glass-field:rgba(11,17,26,.50);
  --emc-bg:var(--finance-glass-base);
  --emc-panel:var(--finance-glass-panel);
  --emc-panel-raised:rgba(52,63,81,.48);
  --emc-contract:#9299cc;
  --emc-contract-bright:#c3ccef;
  --emc-line:rgba(195,207,230,.30);
  --emc-line-strong:rgba(175,185,224,.58);
  --emc-v13-average-fill:linear-gradient(100deg,rgba(111,131,158,.32),rgba(45,58,76,.44));
  --emc-v13-average-active:linear-gradient(100deg,rgba(138,154,183,.40),rgba(56,71,90,.52));
  --emc-v13-total-fill:linear-gradient(100deg,rgba(119,128,171,.36),rgba(46,56,79,.46));
  --emc-v13-total-active:linear-gradient(100deg,rgba(144,152,195,.44),rgba(60,74,100,.54));
}
body[data-page="project"] #roi .roi-panel:not(.pdf-snapshot-copy-v2) #roiViewEmc .buyout-dashboard {
  --section-accent-rgb:155,214,180;
  --finance-glass-base:rgba(29,45,39,.42);
  --finance-glass-panel:rgba(42,64,53,.43);
  --finance-glass-fixed:rgba(58,79,68,.64);
  --finance-glass-fixed-edge:rgba(198,224,211,.52);
  --finance-glass-manual:rgba(32,52,44,.72);
  --finance-glass-inset:rgba(18,30,25,.36);
  --finance-glass-field:rgba(10,21,17,.50);
  --buyout-bg:var(--finance-glass-base);
  --buyout-panel:var(--finance-glass-panel);
  --buyout-green:#91cba9;
  --buyout-green-bright:#c5ebd4;
  --buyout-line:rgba(194,222,211,.30);
  --buyout-line-strong:rgba(160,211,183,.58);
  --buyout-average-fill:linear-gradient(100deg,rgba(111,150,128,.32),rgba(43,65,54,.44));
  --buyout-total-fill:linear-gradient(100deg,rgba(107,164,130,.36),rgba(39,73,55,.46));
}
body[data-page="project"] #roi .roi-panel:not(.pdf-snapshot-copy-v2) #roiViewEmc :is(.emc-dashboard-v2,.buyout-dashboard) {
  border-color:rgba(var(--section-accent-rgb),.32);
  background-color:var(--finance-glass-base);
  background-image:linear-gradient(150deg,rgba(var(--section-accent-rgb),.09),transparent 48%),var(--section-glass-reflection);
  box-shadow:inset 0 1px rgba(236,242,246,.08),0 12px 34px rgba(0,0,0,.12);
  -webkit-backdrop-filter:blur(12px) saturate(70%);
  backdrop-filter:blur(12px) saturate(70%);
}
body[data-page="project"] #roi .roi-panel:not(.pdf-snapshot-copy-v2) #roiViewEmc :is(.emc-v2-parameter,.buyout-parameter):not(.is-invalid),
body[data-page="project"] #roi .roi-panel:not(.pdf-snapshot-copy-v2) #roiViewEmc :is(.emc-v2-chart-board,.emc-v2-details,.buyout-chart-board,.buyout-details) {
  border-color:rgba(var(--section-accent-rgb),.32);
  background-color:var(--finance-glass-panel);
  background-image:var(--section-glass-reflection);
  box-shadow:0 8px 24px rgba(0,0,0,.09);
}
/* Fixed results sit on a lighter pane; the four editable parameter panes
   retain their deeper fill. Do not recolour charts, annual cards or errors. */
body[data-page="project"] #roi .roi-panel:not(.pdf-snapshot-copy-v2) #roiViewEmc :is(.emc-v2-parameter.is-automatic,.buyout-parameter:not(.is-editable)):not(.is-invalid) {
  border-color:var(--finance-glass-fixed-edge);
  background-color:var(--finance-glass-fixed);
  background-image:linear-gradient(180deg,rgba(231,240,246,.075),rgba(231,240,246,.018) 74%,transparent);
  box-shadow:inset 0 1px rgba(239,246,250,.09),0 5px 16px rgba(0,0,0,.10);
}
/* V84f: editable panes share the result tint at a distinct lower brightness,
   with a recessed reflection
   rather than a black fill. Keep error borders independent of the surface. */
body[data-page="project"] #roi .roi-panel:not(.pdf-snapshot-copy-v2) #roiViewEmc :is(.emc-v2-parameter.is-manual,.buyout-parameter.is-editable) {
  background-color:var(--finance-glass-manual);
  background-image:linear-gradient(180deg,rgba(223,234,242,.01),rgba(223,234,242,.025));
}
body[data-page="project"] #roi .roi-panel:not(.pdf-snapshot-copy-v2) #roiViewEmc :is(.emc-v2-parameter.is-manual,.buyout-parameter.is-editable):not(.is-invalid) {
  border-color:rgba(var(--section-accent-rgb),.48);
  box-shadow:inset 0 2px 5px rgba(8,15,23,.16),inset 0 -1px rgba(228,241,247,.09);
}
body[data-page="project"] #roi .roi-panel:not(.pdf-snapshot-copy-v2) #roiViewEmc :is(.emc-v2-parameter.is-manual,.buyout-parameter.is-editable):not(.is-invalid):focus-within {
  border-color:rgba(var(--section-accent-rgb),.84);
  box-shadow:inset 0 2px 5px rgba(8,15,23,.12),inset 0 -1px rgba(228,241,247,.09),0 0 0 1px rgba(var(--section-accent-rgb),.22);
}
body[data-page="project"] #roi .roi-panel:not(.pdf-snapshot-copy-v2) #roiViewEmc :is(.emc-v2-input,.emc-v2-share-input,.emc-v2-select,.buyout-input):not([readonly]):not(:disabled):not([aria-invalid="true"]):not(.is-invalid) {
  background-color:var(--finance-glass-field);
}
/* Only the four main parameter inputs: retain their editable underline,
   without a second dark rectangle behind the number. */
body[data-page="project"] #roi .roi-panel:not(.pdf-snapshot-copy-v2) #roiViewEmc .emc-dashboard-v2[data-emc-v2-pdf="false"] .emc-v2-parameter.is-manual > .emc-v2-parameter-field > .emc-v2-input,
body[data-page="project"] #roi .roi-panel:not(.pdf-snapshot-copy-v2) #roiViewEmc .buyout-dashboard[data-buyout-pdf="false"] .buyout-parameter.is-editable > .buyout-parameter-value > .buyout-input {
  background:transparent;
}
/* The global selection rule uses black text. Editing these dark-glass
   inputs keeps the number light, with a local tinted selection instead. */
body[data-page="project"] #roi .roi-panel:not(.pdf-snapshot-copy-v2) #roiViewEmc .emc-dashboard-v2[data-emc-v2-pdf="false"] .emc-v2-parameter.is-manual > .emc-v2-parameter-field > .emc-v2-input::selection,
body[data-page="project"] #roi .roi-panel:not(.pdf-snapshot-copy-v2) #roiViewEmc .buyout-dashboard[data-buyout-pdf="false"] .buyout-parameter.is-editable > .buyout-parameter-value > .buyout-input::selection {
  color:#f2f6f8;
  background-color:rgba(var(--section-accent-rgb),.30);
  text-shadow:none;
}
body[data-page="project"] #roi .roi-panel:not(.pdf-snapshot-copy-v2) #roiViewEmc :is(.emc-v2-chart-panel,.buyout-chart,.emc-v2-table,.buyout-table) {
  border-color:var(--section-glass-edge);
  background-color:var(--finance-glass-inset);
  background-image:linear-gradient(180deg,rgba(221,237,246,.018),transparent 55%);
}
body[data-page="project"] #roi .roi-panel:not(.pdf-snapshot-copy-v2) #roiViewEmc :is(.emc-v2-table,.buyout-table) thead th {
  background:linear-gradient(180deg,rgba(var(--section-accent-rgb),.10),transparent),var(--finance-glass-panel);
}
body[data-page="project"] #roi .roi-panel:not(.pdf-snapshot-copy-v2) #roiViewEmc :is(.emc-v2-year-strip,.buyout-year-strip) {
  border-color:var(--section-glass-edge);
  border-left-color:rgba(var(--section-accent-rgb),.78);
  background:linear-gradient(90deg,rgba(var(--section-accent-rgb),.10),transparent),var(--finance-glass-panel);
}
/* Leave hovered/selected yearly cards to their existing animation rules. */
body[data-page="project"] #roi .roi-panel:not(.pdf-snapshot-copy-v2) #roiViewEmc .emc-v2-year-card:not(:hover):not(:focus-visible):not(.is-year-preview),
body[data-page="project"] #roi .roi-panel:not(.pdf-snapshot-copy-v2) #roiViewEmc .buyout-year-card:not(.buyout-summary-card):not(:hover):not(:focus-visible):not(.is-year-preview) {
  border-color:rgba(var(--section-accent-rgb),.30);
  background-color:var(--finance-glass-panel);
  background-image:var(--section-glass-reflection);
}
body[data-page="project"] #roi .roi-panel:not(.pdf-snapshot-copy-v2) #roiViewEmc :is(.emc-v2-year-card,.buyout-year-card):not(.buyout-summary-card):is(:hover,:focus-visible,.is-year-preview) {
  background:linear-gradient(150deg,rgba(var(--section-accent-rgb),.12),transparent),var(--finance-glass-panel);
}
