/* Keep the button text in the DOM as its accessible name; only its visual is replaced. */
.edit-link,
.delete-link,
.remove-windfall,
[data-remove-scenario] {
  display: inline-grid;
  place-items: center;
  flex: none;
  width: 34px;
  height: 34px;
  padding: 0;
  border: 0;
  border-radius: 10px;
  font-size: 0;
  line-height: 0;
  text-decoration: none;
  cursor: pointer;
}

.edit-link {
  color: #2867b0;
  background: #eaf2fc;
}

.delete-link,
.remove-windfall,
[data-remove-scenario] {
  color: #b94747;
  background: #fcecec;
}

.edit-link::before,
.delete-link::before,
.remove-windfall::before,
[data-remove-scenario]::before {
  content: '';
  display: block;
  width: 18px;
  height: 18px;
  background: currentColor;
  mask: var(--action-icon) center / contain no-repeat;
}

.edit-link {
  --action-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 20h4L19 9l-4-4L4 16v4Z'/%3E%3Cpath d='m13 7 4 4'/%3E%3C/svg%3E");
}

.delete-link,
.remove-windfall,
[data-remove-scenario] {
  --action-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 7h16M9 7V4h6v3M6 7l1 13h10l1-13M10 11v5M14 11v5'/%3E%3C/svg%3E");
}

.edit-link:hover { background: #dceafb; }
.delete-link:hover,
.remove-windfall:hover,
[data-remove-scenario]:hover { background: #f9dcdc; text-decoration: none; }

.windfall-row .remove-windfall,
.scenario-row [data-remove-scenario] {
  width: 34px;
  height: 34px;
  padding: 0;
  background: #fcecec;
  font-size: 0;
}

.windfall-row .remove-windfall:hover,
.scenario-row [data-remove-scenario]:hover { background: #f9dcdc; }

.edit-link:focus-visible,
.delete-link:focus-visible,
.remove-windfall:focus-visible,
[data-remove-scenario]:focus-visible {
  outline: 2px solid currentColor;
  outline-offset: 2px;
}
