.freed-terms {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.freed-terms .freed-terms-summary,
.freed-terms .freed-terms-empty {
  margin: 0;
  color: var(--text-muted);
}
.freed-terms .freed-terms-status {
  margin: 0;
  font-weight: 650;
  color: var(--success);
}
.freed-terms .freed-terms-status:empty {
  display: none;
}
.freed-terms .freed-terms-status.freed-terms-error {
  color: var(--danger);
}
.freed-terms .freed-terms-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.freed-term {
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface);
}
.freed-term .freed-term-title {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 4px 12px;
  margin: 0;
  padding: 10px 12px;
  font-size: 15px;
  border-bottom: 1px solid var(--border);
  background: var(--surface-alt);
  border-radius: 8px 8px 0 0;
}
.freed-term .freed-term-title .freed-term-when {
  font-variant-numeric: tabular-nums;
}
.freed-term .freed-term-title .freed-term-office {
  font-weight: 400;
  color: var(--text-muted);
}
.freed-term .freed-term-title .freed-term-count {
  margin-left: auto;
  font-size: 13px;
  color: var(--warning);
}
.freed-term .freed-term-candidates {
  max-height: 40vh;
  overflow-y: auto;
}
.freed-term .freed-candidate {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr) minmax(0, 1fr) 90px;
  align-items: center;
  gap: 6px 12px;
  padding: 8px 12px;
  border-bottom: 1px solid var(--border);
}
.freed-term .freed-candidate:hover {
  background: var(--surface-hover);
}
.freed-term .freed-candidate:has(input:checked) {
  background: var(--primary-50);
}
.freed-term .freed-candidate .freed-candidate-name {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 650;
  cursor: pointer;
}
.freed-term .freed-candidate .freed-candidate-contact {
  display: flex;
  flex-direction: column;
  font-size: 13px;
  overflow-wrap: anywhere;
}
.freed-term .freed-candidate .freed-candidate-until {
  font-size: 13px;
  color: var(--text-muted);
}
.freed-term .freed-candidate .freed-candidate-slot {
  font-variant-numeric: tabular-nums;
}
@media (max-width: 639.98px) {
  .freed-term .freed-candidate {
    grid-template-columns: minmax(0, 1fr) 90px;
  }
  .freed-term .freed-candidate .freed-candidate-contact,
  .freed-term .freed-candidate .freed-candidate-until {
    grid-column: 1 / -1;
  }
}
.freed-term .freed-term-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  justify-content: flex-end;
  padding: 10px 12px;
}
.freed-terms-page {
  margin-bottom: 32px;
}
.freed-terms-page h2 {
  margin: 0 0 16px;
  font-size: 1.1rem;
}
