/* The client page's Support information list: one line per thing the client
   may receive, its name on the left and "used / allowed" then what's left on
   the right. One that is almost used up turns amber. On a phone the longer
   names give way to short ones. */
.support-list {
  --support-ink: #1f313b;
  --support-soft-ink: #4c5a62;
  --support-muted: #8b969c;
  --support-line: #e7e1d6;
  --support-amber: #8a5a12;

  display: flex;
  flex-direction: column;
  color: var(--support-ink);
}

.support-list__head,
.support-list__row {
  display: flex;
  align-items: center;
  gap: 1rem;
  border-bottom: 1px solid var(--support-line);
}

.support-list__head {
  padding: 0 0 0.5rem;
  font-size: 0.8125rem;
  color: var(--support-muted);
}

.support-list__head .support-list__used { margin-left: auto; }

.support-list__row {
  padding: 0.625rem 0;
  font-size: 0.9375rem;

  &:last-child { border-bottom: 0; }
}

.support-list__name {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
  min-width: 0;
  margin-right: auto;
  color: var(--support-soft-ink);
}

.support-list__name-short { display: none; }

.support-list__used,
.support-list__left,
.support-list__value {
  font-variant-numeric: tabular-nums;
  text-align: right;
  white-space: nowrap;
}

.support-list__left {
  min-width: 3.5rem;
  font-weight: 700;
}

.support-list__head .support-list__left { font-weight: 400; }

.support-list__none {
  font-weight: 400;
  color: var(--support-muted);
}

.support-list__row--almost-used-up .support-list__used,
.support-list__row--almost-used-up .support-list__left {
  color: var(--support-amber);
}

.support-list__flag {
  padding: 0.125rem 0.375rem;
  border: 1px solid var(--color-warning);
  border-radius: 0.375rem;
  background: color-mix(in oklab, var(--color-warning) 20%, transparent);
  font-size: 0.6875rem;
  font-weight: 600;
  color: var(--color-warning-content);
  white-space: nowrap;
}

@media (max-width: 639px) {
  .support-list__name-long { display: none; }
  .support-list__name-short { display: inline; }
  .support-list__head,
  .support-list__row { gap: 0.75rem; }
}
