/* Shared battery colors: percentage is decorative; protection remains textual. */
.ab-battery-resume{display:block;font-size:12px;line-height:1.5;margin-top:6px;white-space:normal;overflow-wrap:anywhere;font-variant-numeric:tabular-nums}
.ab-battery-resume[hidden]{display:none!important}
[data-bat-tone]{border-left:4px solid var(--ab-bat-color,#758493)!important}
[data-bat-tone="red"]{--ab-bat-color:#d74743}
[data-bat-tone="orange"]{--ab-bat-color:#df8116}
[data-bat-tone="yellow"]{--ab-bat-color:#967100}
[data-bat-tone="blue"]{--ab-bat-color:#2877bb}
[data-bat-tone="green"]{--ab-bat-color:#26864b}
[data-bat-tone="unknown"]{--ab-bat-color:#758493}
[data-bat-tone] [data-ab="battery"],[data-bat-tone] [data-ab-admin="battery"]{color:var(--ab-bat-color)!important;white-space:normal!important;font-variant-numeric:tabular-nums}
.ab-live-chip[data-bat-tone="yellow"]{--ab-bat-color:#ecca4c}
.ab-live-chip[data-bat-tone="blue"]{--ab-bat-color:#72b5f0}
.ab-live-chip[data-bat-tone="green"]{--ab-bat-color:#70ce94}
.ab-live-chip[data-bat-tone="red"]{--ab-bat-color:#ff837b}
.ab-live-chip[data-bat-tone="orange"]{--ab-bat-color:#ffb260}
.ab-battery-age,.ab-battery-protection{display:block!important;font-size:11px!important;line-height:1.5!important;opacity:.85;white-space:normal!important;margin-top:3px}
.ab-battery-forecast strong,.ab-battery-trend strong{white-space:normal!important;line-height:1.4!important;font-size:14px!important}
.ab-battery-forecast{min-width:200px}
.ab-battery-limit-note{padding:12px;border-left:4px solid #df8116;background:#fff8e7;color:#513900;line-height:1.6;margin:12px 0;border-radius:8px}
.ab-battery-history-live{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px;margin:16px 0}
.ab-battery-chart-detail{background:#f1f5f9;color:#172c41;border-radius:9px;line-height:1.6;padding:12px;min-height:46px}
#aeroboat-bat-charge-chart{display:block;width:100%;height:290px;touch-action:pan-y}
.ab-battery-legend{display:flex;gap:12px;flex-wrap:wrap;font-size:12px;margin:12px 0}
.ab-battery-legend span::before{content:"";display:inline-block;width:10px;height:10px;background:var(--legend);border-radius:50%;margin-right:5px}
.ab-battery-voltage-details>summary{padding:12px;cursor:pointer;font-weight:600}
.ab-battery-historical-note{font-size:12px;color:#526477}
[data-ab-battery-projection]{font-size:11px!important;line-height:1.5;display:block;white-space:normal!important}
@media(max-width:680px){.ab-battery-history-live{grid-template-columns:1fr}.ab-battery-forecast{min-width:0}}
/* Keep forecast/trend cards inside the public grid at intermediate desktop widths. */
.aeroboat-portal .ab-battery-forecast,.aeroboat-portal .ab-battery-trend{min-width:0;grid-column:span 2}
.aeroboat-portal .ab-battery-forecast small,.aeroboat-portal .ab-battery-trend small{white-space:normal;line-height:1.35}

/* 2.2.62 – compact status header; details do not participate in grid sizing.
   Scoped to live cards. The full battery-history page keeps its own cards. */
.ab-battery-compact{position:relative;min-width:0;box-sizing:border-box}
.ab-battery-compact .ab-battery-trigger{appearance:none;-webkit-appearance:none;display:block;box-sizing:border-box;width:100%;border:0!important;border-radius:5px;padding:0!important;margin:0!important;background:transparent!important;box-shadow:none!important;color:inherit!important;font:inherit!important;text-align:left!important;text-transform:none!important;letter-spacing:normal!important;cursor:pointer;line-height:1.2!important;min-height:34px;touch-action:manipulation}
.ab-battery-compact .ab-battery-trigger:focus-visible{outline:2px solid #2680bb;outline-offset:4px}
.ab-battery-compact .ab-battery-trigger .ab-battery-caption{display:flex;align-items:center;justify-content:space-between;gap:4px;white-space:nowrap;margin:0}
.ab-battery-compact .ab-battery-caption>span{display:inline;line-height:inherit;font-size:inherit;margin:0;min-width:0}
.ab-battery-compact .ab-battery-info{font-size:13px!important;opacity:.8;flex:0 0 auto}
.ab-battery-compact .ab-battery-trigger>strong{white-space:nowrap!important;overflow:hidden;text-overflow:ellipsis;font-variant-numeric:tabular-nums}
.ab-battery-compact .ab-battery-alert{display:block;margin:4px 0 0;padding:2px 4px;border-radius:4px;font-size:10px!important;line-height:1.3!important;font-weight:700;white-space:normal;overflow-wrap:anywhere;color:#6b4300;background:#fff0c2}
.ab-battery-compact[data-battery-alert="critical"] .ab-battery-alert{color:#850d26;background:#ffdee5}
.ab-battery-compact [hidden]{display:none!important}
.ab-battery-compact .ab-battery-popover{box-sizing:border-box;position:fixed;z-index:1001000;inset:auto;display:block;width:360px;max-width:calc(100vw - 24px);overflow:auto;overscroll-behavior:contain;border:1px solid #aab8c5;border-radius:13px;background:#fff;color:#172c41;box-shadow:0 14px 45px rgba(0,0,0,.26);padding:14px;text-align:left;font-family:system-ui,-apple-system,Segoe UI,Roboto,Arial,sans-serif;line-height:1.45;font-size:13px;font-weight:400;white-space:normal;overflow-wrap:anywhere}
.ab-battery-compact .ab-battery-popover-heading{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:10px}
.ab-battery-compact .ab-battery-popover-heading h3{font-size:15px;font-weight:700;color:inherit;margin:0;line-height:1.3;letter-spacing:normal;text-transform:none}
.ab-battery-compact [data-ab-battery-close]{appearance:none;display:flex;align-items:center;justify-content:center;flex:0 0 36px;width:36px;height:36px;min-height:36px;border:1px solid #b9c9d6;border-radius:8px;background:transparent;color:inherit;cursor:pointer;font-size:23px;font-weight:400;line-height:1;padding:0;margin:0;box-shadow:none;touch-action:manipulation}
.ab-battery-compact [data-ab-battery-close]:focus-visible{outline:2px solid #2680bb;outline-offset:2px}
.ab-battery-compact .ab-battery-details-list{margin:0;padding:0;display:grid;gap:9px}
.ab-battery-compact .ab-battery-details-list>div{padding:0 0 9px;border-bottom:1px solid rgba(130,155,177,.26)}
.ab-battery-compact .ab-battery-details-list dt{font-size:11px;font-weight:400;color:#5c6d7d;line-height:1.4;margin:0 0 3px;padding:0;white-space:normal}
.ab-battery-compact .ab-battery-details-list dd{margin:0;padding:0;color:inherit;font-size:13px!important;line-height:1.45!important;font-weight:500;white-space:normal!important;opacity:1;min-width:0}
.ab-battery-compact .ab-battery-detail-note{font-size:11px;color:#5c6d7d;line-height:1.45;margin:9px 0 0}
.aeroboat-portal .ab-battery-popover{background:#0d2032;color:#eaf6ff;border-color:#466882}
.aeroboat-portal .ab-battery-details-list dt,.aeroboat-portal .ab-battery-detail-note{color:#a7bdcf}
.aeroboat-portal .ab-battery-compact [data-ab-battery-close]{border-color:#466882}
.aeroboat-portal .ab-battery-compact .ab-battery-trigger:focus-visible{outline-color:#8deaff}
.aeroboat-portal .ab-battery-compact [data-ab-battery-close]:focus-visible{outline-color:#8deaff}
.aeroboat-portal .ab-battery-compact .ab-battery-alert{color:#ffe59a;background:#49380e}
.aeroboat-portal .ab-battery-compact[data-battery-alert="critical"] .ab-battery-alert{color:#ffd4dc;background:#602337}
/* Keep the old compact 9/6/4/2-column grid and all status values. */
.aeroboat-portal .ab-live-status-strip{align-items:stretch}
.aeroboat-portal .ab-live-status-strip>.ab-live-chip{box-sizing:border-box;min-height:52px}
.aeroboat-portal .ab-live-status-strip>.ab-live-chip>small{overflow:hidden;text-overflow:ellipsis}
.aeroboat-portal .ab-live-chip [data-ab-pump-countdown]{display:block;font-size:10px!important;line-height:1.3;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;margin-top:2px}
/* Admin top summary: single reading line, original details remain below or in the popover. */
.ab-admin-cards-wide>.ab-battery-compact .ab-battery-caption{font-size:12px;color:#526477}
.ab-admin-cards-wide>.ab-battery-compact .ab-battery-trigger>strong{display:block;font-size:15px;line-height:1.2;margin-top:5px}
