/* Nessa battery sizing tool. Scoped to the Resources page and its hero link. */
.nessa-resources .np-hero__lede a[href="#battery-ah-calculator"] { color: var(--nc-green-dark); text-decoration: underline; text-underline-offset: 3px; }
.nessa-resources .np-hero__lede a[href="#battery-ah-calculator"]:focus-visible { outline: 2px solid var(--nc-orange); outline-offset: 3px; }
.nbc { padding: 48px 0; scroll-margin-top: 112px; background: var(--nc-field, #f8faf9); color: var(--nc-ink, #111827); }
.nbc [hidden] { display: none !important; }
.nbc__heading { display: grid; grid-template-columns: 1.3fr 1fr; align-items: end; gap: 48px; margin-bottom: 28px; }
.nbc__eyebrow { display: flex; align-items: center; gap: 10px; margin: 0 0 12px; color: var(--nc-green-dark); font-size: 11px; font-weight: 650; letter-spacing: .14em; text-transform: uppercase; }
.nbc__eyebrow::before { content: ''; width: 24px; height: 2px; background: var(--nc-orange); }
.nbc__heading h2 { margin: 0; font-size: clamp(27px, 2.7vw, 36px); line-height: 1.2; letter-spacing: -.035em; font-weight: 650; }
.nbc__intro { max-width: 52ch; margin: 0 0 2px; color: var(--nc-body); font-size: 14px; line-height: 1.7; }
.nbc__notice { padding: 16px; margin: 0 0 24px; border-left: 3px solid var(--nc-orange); background: var(--nc-peach); font-size: 14px; line-height: 1.6; }
.nbc__grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; align-items: start; }
.nbc-panel { min-width: 0; margin: 0; padding: 28px; border: 1px solid #dfe6e1; border-radius: 14px; background: #fff; }
.nbc-panel__heading { display: flex; justify-content: space-between; gap: 16px; margin-bottom: 24px; }
.nbc-panel__index { margin: 0 0 8px; font-size: 10px; font-weight: 650; letter-spacing: .1em; text-transform: uppercase; color: var(--nc-body); }
.nbc-panel h3 { margin: 0 0 8px; font-size: 20px; line-height: 1.3; letter-spacing: -.025em; font-weight: 650; }
.nbc-panel__description { margin: 0; font-size: 13px; line-height: 1.6; color: var(--nc-body); }
.nbc-battery { flex-shrink: 0; width: 40px; height: 44px; color: var(--nc-ink); }
.nbc-battery__charge { fill: var(--nc-mint); }
.nbc-battery__bolt { fill: var(--nc-orange); }
.nbc-panel--steady .nbc-battery__charge { fill: var(--nc-peach); }
.nbc-panel--steady .nbc-battery__bolt { fill: var(--nc-green); }
.nbc-schedule { margin-bottom: 24px; padding: 16px; border-radius: 8px; background: var(--nc-peach); }
.nbc-panel--steady .nbc-schedule { background: var(--nc-mint); }
.nbc-schedule__caption { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 4px 12px; margin: 0 0 16px; font-size: 11px; line-height: 1.5; color: var(--nc-body); }
.nbc-schedule__caption strong { font-weight: 600; color: var(--nc-ink); }
.nbc-schedule__stages { display: grid; grid-template-columns: 2.5fr 3fr 7fr; gap: 8px; margin: 0; padding: 0; list-style: none; }
.nbc-schedule__stages li { display: grid; min-width: 0; gap: 6px; font-size: 11px; line-height: 1.5; }
.nbc-schedule__bar { position: relative; display: block; height: 20px; border-bottom: 1px solid #11182720; }
.nbc-schedule__bar::before { content: ''; position: absolute; inset: 0 0 0; background: var(--nc-orange); }
.nbc-schedule__stages li:nth-child(2) .nbc-schedule__bar::before { top: 50%; }
.nbc-schedule__stages li:nth-child(3) .nbc-schedule__bar::before { top: 75%; }
.nbc-schedule__stages strong { font-weight: 650; }
.nbc-schedule__stages strong span { font-weight: 400; color: var(--nc-body); }
.nbc-schedule__stages--steady { grid-template-columns: minmax(0, 1fr); }
.nbc-schedule__stages--steady .nbc-schedule__bar::before { background: var(--nc-green); }
.nbc-panel__controls { min-width: 0; margin: 0; padding: 0; border: 0; }
.nbc-fields { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.nbc-field { min-width: 0; }
.nbc-field>label { display: block; margin-bottom: 8px; font-size: 12px; line-height: 1.5; font-weight: 600; }
.nbc-field__input, .nbc-field__select { position: relative; display: flex; align-items: center; }
.nbc-field input, .nbc-field select { width: 100%; min-width: 0; min-height: 48px; margin: 0; padding: 12px; border: 1px solid #ced8d1; border-radius: 8px; background: #fff; color: var(--nc-ink); font: inherit; font-size: 14px; line-height: 1.5; box-shadow: none; }
.nbc-field input { padding-right: 36px; appearance: textfield; -moz-appearance: textfield; }
.nbc-field input::-webkit-inner-spin-button, .nbc-field input::-webkit-outer-spin-button { appearance: none; margin: 0; }
.nbc-field input::placeholder { color: #68746e; opacity: 1; }
.nbc-field__input>span { position: absolute; right: 12px; color: var(--nc-body); font-size: 12px; pointer-events: none; }
.nbc-field select { padding-right: 36px; appearance: none; }
.nbc-field__select>svg { position: absolute; right: 12px; width: 16px; height: 16px; pointer-events: none; }
.nbc-field input:focus, .nbc-field input:focus-visible, .nbc-field select:focus, .nbc-field select:focus-visible { outline: none; border-color: #ced8d1; box-shadow: none; }
.nbc button:focus-visible, .nbc-method summary:focus-visible { outline: 2px solid var(--nc-orange); outline-offset: 3px; }
.nbc-field input[aria-invalid=true] { border-color: #b42318; }
/* A select-only combobox enhances the native select after JavaScript loads. */
.nbc-voltage { position: relative; width: 100%; min-width: 0; }
.nbc .nbc-voltage__trigger { display: flex; align-items: center; justify-content: space-between; gap: 12px; width: 100%; min-height: 48px; padding: 12px; border: 1px solid #ced8d1; border-radius: 8px; background: #fff; color: var(--nc-ink); font-size: 14px; line-height: 1.5; text-align: left; box-shadow: none; transition: background-color .15s ease, border-color .15s ease; }
.nbc .nbc-voltage__trigger:hover { background: var(--nc-field); }
.nbc .nbc-voltage__trigger[aria-expanded=true] { background: var(--nc-field); }
.nbc .nbc-voltage__trigger:focus, .nbc .nbc-voltage__trigger:focus-visible { outline: none; border-color: #ced8d1; box-shadow: none; }
.nbc-voltage__trigger svg { flex-shrink: 0; width: 16px; height: 16px; }
.nbc-voltage__trigger[aria-expanded=true] svg { transform: rotate(180deg); }
.nbc-voltage__menu { position: absolute; z-index: 20; inset: calc(100% + 7px) 0 auto; padding: 5px; border: 1px solid #dfe6e1; border-radius: 10px; background: #fff; box-shadow: 0 4px 8px #142b2008, 0 14px 28px -8px #142b2026; }
.nbc-voltage__option { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 44px; padding: 10px; border-radius: 6px; color: var(--nc-ink); font-size: 14px; line-height: 1.5; cursor: pointer; }
.nbc-voltage__option.is-active { background: var(--nc-field); }
.nbc-voltage__option[aria-selected=true] { background: var(--nc-mint); color: var(--nc-green-dark); font-weight: 600; }
.nbc-voltage__check { visibility: hidden; width: 16px; height: 16px; flex-shrink: 0; }
.nbc-voltage__option[aria-selected=true] .nbc-voltage__check { visibility: visible; }
.nbc-error { margin: 10px 0 0; color: #b42318; font-size: 12px; line-height: 1.5; }
.nbc-preview { display: flex; justify-content: space-between; align-items: baseline; flex-wrap: wrap; gap: 8px 16px; margin: 16px 0 20px; padding: 12px 14px; border-radius: 8px; background: var(--nc-field); }
.nbc-preview label { font-size: 12px; line-height: 1.6; color: var(--nc-body); }
.nbc-preview output { max-width: 100%; overflow-wrap: anywhere; font-size: 17px; font-weight: 600; font-variant-numeric: tabular-nums; }
.nbc-panel__actions { display: flex; align-items: center; gap: 16px; }
.nbc button { font-family: inherit; cursor: pointer; }
/* Reuse the same shared button as “Ask an engineer”, including its hover state. */
.nbc-calculate.nc-btn { min-height: 3.25rem; padding: 0 1.5rem; font-size: .9375rem; font-weight: 700; }
.nbc-reset { min-height: 44px; padding: 10px 12px; border: 0; border-radius: 999px; background: transparent; color: var(--nc-body); font-size: 12px; }
.nbc-reset:hover { background: var(--nc-mint); color: var(--nc-green-dark); }
.nbc fieldset:disabled { opacity: .6; }
.nbc fieldset:disabled button { cursor: default; }
.nbc-panel__placeholder { margin: 24px 0 0; padding-top: 20px; border-top: 1px solid var(--nc-line); color: var(--nc-body); font-size: 12px; line-height: 1.5; }
.nbc-result { margin-top: 24px; padding-top: 20px; border-top: 1px solid var(--nc-line); }
.nbc-result h4 { margin: 0 0 8px; font-size: 12px; line-height: 1.5; font-weight: 500; color: var(--nc-body); }
.nbc-result__capacity { display: flex; flex-wrap: wrap; align-items: baseline; gap: 8px; margin: 0 0 12px; color: var(--nc-green-dark); }
.nbc-result__capacity strong { min-width: 0; max-width: 100%; overflow-wrap: anywhere; font-size: 44px; line-height: 1.15; letter-spacing: -.035em; font-weight: 650; font-variant-numeric: tabular-nums; }
.nbc-result__capacity>span { font-size: 16px; }
.nbc-result__rounded { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 8px 12px; margin: 0 0 20px; font-size: 12px; line-height: 1.5; }
.nbc-result__rounded strong { min-width: 0; overflow-wrap: anywhere; font-size: 17px; font-weight: 600; }
.nbc-result__breakdown { display: grid; grid-template-columns: 1fr 1fr .8fr; gap: 12px; margin: 0; padding-top: 16px; border-top: 1px solid var(--nc-line); }
.nbc-result__breakdown>div { min-width: 0; }
.nbc-result__breakdown dt { margin: 0 0 6px; color: var(--nc-body); font-size: 11px; line-height: 1.5; }
.nbc-result__breakdown dd { margin: 0; font-size: 13px; line-height: 1.5; font-weight: 600; overflow-wrap: anywhere; }
.nbc-result__note { margin: 16px 0 0; color: var(--nc-body); font-size: 11px; line-height: 1.65; }
.nbc-method { margin-top: 24px; border-block: 1px solid #dce4de; }
.nbc-method summary { display: flex; justify-content: space-between; gap: 16px; min-height: 56px; padding: 16px 0; font-size: 14px; line-height: 1.6; font-weight: 600; list-style: none; cursor: pointer; }
.nbc-method summary::-webkit-details-marker { display: none; }
.nbc-method summary>span { display: grid; place-items: center; }
.nbc-method summary svg { width: 18px; height: 18px; }
.nbc-method[open] summary svg { transform: rotate(180deg); }
.nbc-method__body { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 32px; padding: 8px 0 24px; }
.nbc-method h3 { margin: 0 0 12px; font-size: 14px; line-height: 1.5; font-weight: 600; }
.nbc-method p { margin: 0 0 12px; color: var(--nc-body); font-size: 12px; line-height: 1.7; }
.nbc-method p:last-child { margin-bottom: 0; }
.nbc-method .nbc-method__formula { color: var(--nc-green-dark); font-weight: 500; }
@media (max-width: 959px) {
  .nbc__heading { grid-template-columns: minmax(0, 1fr); gap: 16px; }
  .nbc__intro { max-width: 70ch; }
  .nbc-panel { padding: 20px; }
  .nbc-panel h3 { font-size: 18px; }
  .nbc-schedule { padding: 12px; }
  .nbc-schedule__stages strong span { display: block; }
  .nbc-calculate.nc-btn { padding-inline: 18px; }
}
@media (max-width: 767px) {
  .nbc { padding: 32px 0; }
  .nbc__grid, .nbc-method__body { grid-template-columns: minmax(0, 1fr); }
  .nbc__heading h2 { font-size: 28px; }
  .nbc__grid { gap: 20px; }
  .nbc-panel { padding: 20px; }
  .nbc-battery { width: 32px; height: 38px; }
  .nbc-schedule__stages { grid-template-columns: 1fr 1fr 1.6fr; }
  .nbc-schedule__stages--steady { grid-template-columns: minmax(0, 1fr); }
  .nbc-fields { gap: 12px; }
  .nbc-field input, .nbc-field select { font-size: 16px; }
  .nbc .nbc-voltage__trigger { font-size: 16px; }
  .nbc-panel__actions { gap: 12px; }
  .nbc-calculate.nc-btn { flex: 1; padding-inline: 14px; }
  .nbc-reset { padding-inline: 8px; }
  .nbc-method__body { gap: 24px; }
}
@media (prefers-reduced-motion: reduce) {
  .nbc .nc-btn { transition: none; }
  .nbc .nc-btn:hover { transform: none; }
  .nbc .nbc-voltage__trigger { transition: none; }
}
