/* Shared "test connection / test job" panel (M-329) — the ONE presentation for a driver probe's rich output,
   used by the connector, import-job and storage-Locations edit pages through `<x-platform::probe-panel>`. It
   was Locations' own `.platform-location-test` block (M-326); generalized here so no module re-declares it and
   masterdata carries no probe CSS at all (coding-standards §3). No inline styles, no markup in JS (§4); every
   colour comes from a design token. */

/* The panel body: the run button, the resting hint, the tone-coded verdict, the details, the listing, the
   truncation note and the trailing note line. The resting states carry neither tone class. */
.platform-probe {
    display: flex;
    flex-direction: column;
    gap: var(--platform-space-sm, 0.5rem);
}

.platform-probe__run {
    align-self: flex-start;
}

.platform-probe__idle {
    margin: 0;
    color: var(--platform-color-text-muted, #57606a);
    font-size: var(--platform-font-size-sm, 0.875rem);
}

.platform-probe__verdict,
.platform-probe__note {
    margin: 0;
    font-weight: 600;
}

.platform-probe__verdict.is-ok,
.platform-probe__note.is-ok {
    color: var(--platform-color-ok, #1a7f37);
}

.platform-probe__verdict.is-error,
.platform-probe__note.is-error {
    color: var(--platform-color-error, #cf222e);
}

/* The labelled facts under the verdict: "Label: value" per row, the label muted, the value emphasised. A row
   may carry a tone (the read-check note shares this look), so is-ok/is-error tint the whole line. */
.platform-probe__details {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: var(--platform-space-xs, 0.25rem);
}

.platform-probe__detail {
    display: flex;
    gap: var(--platform-space-sm, 0.5rem);
    align-items: baseline;
}

.platform-probe__detail.is-ok {
    color: var(--platform-color-ok, #1a7f37);
}

.platform-probe__detail.is-error {
    color: var(--platform-color-error, #cf222e);
}

.platform-probe__detail-label,
.platform-probe__note-label {
    flex: 0 0 auto;
    color: var(--platform-color-text-muted, #57606a);
    font-size: var(--platform-font-size-sm, 0.875rem);
}

.platform-probe__detail-value {
    flex: 1 1 auto;
    font-variant-numeric: tabular-nums;
}

.platform-probe__note-value {
    margin-inline-start: var(--platform-space-xs, 0.25rem);
}

/* The folder/file/record listing: one row per entry, a type badge, the entry name (wraps on long names) and a
   right-aligned meta (a formatted size, a record identifier). */
.platform-probe__entries {
    list-style: none;
    margin: 0;
    padding: 0;
}

.platform-probe__entry {
    display: flex;
    align-items: baseline;
    gap: var(--platform-space-sm, 0.5rem);
    padding: var(--platform-space-xs, 0.25rem) 0;
    border-bottom: 1px solid var(--platform-color-border, #d0d7de);
}

.platform-probe__entry-badge {
    flex: 0 0 auto;
    padding: 0 var(--platform-space-xs, 0.25rem);
    border-radius: var(--platform-radius-sm, 0.25rem);
    background: var(--platform-color-surface-muted, #f6f8fa);
    color: var(--platform-color-text-muted, #57606a);
    font-size: var(--platform-font-size-xs, 0.75rem);
}

/* Per-kind accents: a folder and a record read as "container-ish" (accent), a file stays muted. */
.platform-probe__entry-badge--folder,
.platform-probe__entry-badge--record {
    color: var(--platform-color-accent, #0969da);
}

.platform-probe__entry-name {
    flex: 1 1 auto;
    word-break: break-all;
}

.platform-probe__entry-meta {
    flex: 0 0 auto;
    color: var(--platform-color-text-muted, #57606a);
    font-size: var(--platform-font-size-sm, 0.875rem);
    font-variant-numeric: tabular-nums;
}

.platform-probe__truncated {
    margin: var(--platform-space-xs, 0.25rem) 0 0;
    color: var(--platform-color-text-muted, #57606a);
    font-size: var(--platform-font-size-xs, 0.75rem);
}
