.telemetry-live-card {
    margin: 8px 10px 0;
    border: 1px solid #b9d0f3;
    border-radius: 7px;
    background: #fff;
    box-shadow: none;
    overflow: hidden;
}
.telemetry-live-head {
    min-height: 31px;
    padding: 5px 8px 3px;
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 8px;
    background: #fff;
}
.telemetry-live-title,
.telemetry-live-actions { display: flex; align-items: center; min-width: 0; }
.telemetry-live-title { gap: 6px; flex: 1 1 auto; }
.telemetry-live-title strong {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    color: #334155;
    font-size: 11px;
    line-height: 1.2;
    font-weight: 800;
}
.telemetry-live-actions { justify-content: flex-end; gap: 5px; flex: 0 1 auto; }
.telemetry-reading-time {
    color: #475569;
    font-size: 9px;
    line-height: 1.3;
    font-weight: 700;
    text-align: right;
    white-space: nowrap;
}
.telemetry-status-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 0;
    border: 0;
    background: transparent;
    border-radius: 0;
    font-size: 9px;
    line-height: 1;
    font-weight: 800;
    white-space: nowrap;
}
.telemetry-status-badge i {
    width: 8px;
    height: 8px;
    flex: 0 0 8px;
    border-radius: 50%;
    background: currentColor;
    box-shadow: 0 0 0 2px color-mix(in srgb, currentColor 13%, transparent);
}
.telemetry-status-badge.is-online { color: #16a34a; }
.telemetry-status-badge.is-offline,
.telemetry-status-badge.is-error { color: #dc2626; }
.telemetry-status-badge.is-unregistered { color: #64748b; }
.telemetry-status-badge.is-loading { color: #2563eb; }
.telemetry-status-badge.is-loading i { animation: telemetryPulse 1.1s ease-in-out infinite; }
.telemetry-refresh-button {
    width: 19px;
    height: 19px;
    padding: 0;
    border: 0;
    border-radius: 5px;
    background: transparent;
    color: #64748b;
    font-size: 13px;
    font-weight: 800;
    cursor: pointer;
}
.telemetry-refresh-button:hover { color: #0369a1; background: #eff6ff; }
.telemetry-live-body { padding: 0 8px 7px; }
.telemetry-device-tags {
    display: flex;
    align-items: center;
    gap: 4px;
    min-height: 15px;
    margin: -1px 0 5px;
}
.telemetry-device-tags span {
    display: inline-flex;
    align-items: center;
    min-height: 13px;
    padding: 1px 4px;
    border: 1px solid #cbd5e1;
    border-radius: 3px;
    background: #f8fafc;
    color: #64748b;
    font-size: 7px;
    line-height: 1;
    font-weight: 700;
}
.telemetry-metric-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(76px, 1fr));
    gap: 0;
    align-items: stretch;
}
.telemetry-metric-card {
    min-width: 0;
    min-height: 45px;
    padding: 4px 6px 2px;
    border: 0;
    border-left: 1px solid #eef2f7;
    border-radius: 0;
    background: #fff;
    text-align: center;
}
.telemetry-metric-card:first-child { border-left: 0; }
.telemetry-metric-card strong {
    display: block;
    min-height: 22px;
    color: #1e293b;
    font-size: 12px;
    line-height: 1.25;
    font-weight: 800;
    overflow-wrap: anywhere;
}
.telemetry-metric-card strong small {
    margin-left: 2px;
    color: #475569;
    font-size: 7px;
    font-weight: 800;
}
.telemetry-metric-card > span {
    display: block;
    min-height: 0;
    margin-top: 1px;
    color: #64748b;
    font-size: 8px;
    line-height: 1.2;
}
.telemetry-condition-card strong { font-size: 20px; line-height: 1; }
.telemetry-condition-card.is-rain > span { color: #0369a1; font-style: italic; }
.telemetry-condition-card.is-dry > span { color: #94a3b8; font-style: italic; }
.telemetry-loading {
    min-height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    color: #64748b;
    font-size: 9px;
}
.telemetry-loading span {
    width: 13px;
    height: 13px;
    border: 2px solid #bfdbfe;
    border-top-color: #2563eb;
    border-radius: 50%;
    animation: telemetrySpin .8s linear infinite;
}
.telemetry-empty,
.telemetry-error-message {
    padding: 8px;
    border-radius: 6px;
    display: flex;
    flex-direction: column;
    gap: 3px;
    font-size: 9px;
}
.telemetry-empty { color: #475569; background: #f8fafc; border: 1px dashed #cbd5e1; }
.telemetry-error-message { color: #991b1b; background: #fef2f2; border: 1px solid #fecaca; }
.telemetry-error-message button {
    align-self: flex-start;
    margin-top: 3px;
    border: 0;
    border-radius: 5px;
    padding: 4px 7px;
    background: #dc2626;
    color: #fff;
    font-size: 8px;
    font-weight: 700;
    cursor: pointer;
}
.leaflet-marker-icon.telemetry-online {
    filter: drop-shadow(0 0 3px #22c55e) drop-shadow(0 0 6px #22c55e);
}
.leaflet-marker-icon.telemetry-offline,
.leaflet-marker-icon.telemetry-error {
    filter: grayscale(.25) drop-shadow(0 0 3px #ef4444) drop-shadow(0 0 6px #ef4444);
}
.leaflet-marker-icon.telemetry-unregistered { filter: grayscale(.55) opacity(.82); }
@keyframes telemetrySpin { to { transform: rotate(360deg); } }
@keyframes telemetryPulse { 50% { opacity: .25; transform: scale(.72); } }
@media (max-width: 520px) {
    .telemetry-live-card { margin: 7px 7px 0; }
    .telemetry-live-head { padding: 5px 6px 3px; }
    .telemetry-live-body { padding: 0 6px 6px; }
    .telemetry-reading-time { max-width: 112px; white-space: normal; }
    .telemetry-metric-grid { grid-template-columns: repeat(3, minmax(68px, 1fr)); }
}
@media (max-width: 360px) {
    .telemetry-metric-grid { grid-template-columns: repeat(2, minmax(68px, 1fr)); }
}
