/* Rules that belong to the admin screens only. Colours come from tokens.css. */

/* Background services: one, two or three cards per row. A short last row stretches to the full
   width, so no card is left alone beside a gap. */
.em-service-grid { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 16px; }
.em-service-grid > * { grid-column: span 6; min-width: 0; }
@media (min-width: 768px) {
    .em-service-grid > * { grid-column: span 3; }
    .em-service-grid > :last-child:nth-child(odd) { grid-column: span 6; }
}
@media (min-width: 1200px) {
    .em-service-grid > *,
    .em-service-grid > :last-child:nth-child(odd) { grid-column: span 2; }
    .em-service-grid > :nth-child(3n+1):nth-last-child(2),
    .em-service-grid > :nth-child(3n+2):last-child { grid-column: span 3; }
    .em-service-grid > :nth-child(3n+1):last-child { grid-column: span 6; }
}

/* ISP and bounce rules: an edit box inside a table cell keeps a usable width */
.em-inline-edit { min-width: 5.5rem; }

/* Templates: one row per file waiting to be uploaded */
.em-batch-row { display: flex; align-items: center; gap: 10px; }
.em-batch-row__name,
.em-batch-row__file { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.em-batch-row__name { flex: 1 1 50%; font-weight: 600; }
.em-batch-row__file { flex: 0 1 38%; color: var(--em-muted); font-size: .9rem; text-align: right; }

/* API request log: the request and error columns keep a readable width; the table scrolls instead of squeezing them */
.em-col-text { min-width: 11rem; }
