.tag {
  display: inline-flex;
  align-items: center;
  gap: .3em;
  padding: .15em .6em;
  border-radius: var(--m-r-full);
  font-size: .8125rem;
  font-weight: 600;
  line-height: 1.45;
  background: var(--m-surface);
  color: var(--m-fg-2);
  border: 1px solid var(--m-border);
  white-space: nowrap;
}
.tag-primary { background: var(--m-primary); border-color: var(--m-primary); color: var(--m-on-primary); }
.tag-success { background: var(--m-success); border-color: var(--m-success); color: #fff; }
.tag-warning { background: var(--m-warning); border-color: var(--m-warning); color: #fff; }
.tag-danger { background: var(--m-danger); border-color: var(--m-danger); color: #fff; }
.tag-soft { background: var(--m-primary-soft); border-color: transparent; color: var(--m-primary); }
.tag-soft-success { background: var(--m-success-soft); border-color: transparent; color: var(--m-success); }
.tag-soft-danger { background: var(--m-danger-soft); border-color: transparent; color: var(--m-danger); }
.tag-rounded { border-radius: 6px; }
.tag-x {
  display: inline-block;
  width: 1em;
  height: 1em;
  border-radius: 50%;
  background: rgba(0,0,0,.15);
  position: relative;
  cursor: pointer;
}
.tag-x::before, .tag-x::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  width: 55%;
  height: 1.5px;
  background: currentColor;
  transform: translate(-50%, -50%) rotate(45deg);
}
.tag-x::after { transform: translate(-50%, -50%) rotate(-45deg); }
.tag-x:hover { background: rgba(0,0,0,.3); }
.tag-primary .tag-x, .tag-success .tag-x, .tag-warning .tag-x, .tag-danger .tag-x { background: rgba(255,255,255,.28); }
.tag-primary .tag-x:hover, .tag-success .tag-x:hover, .tag-warning .tag-x:hover, .tag-danger .tag-x:hover { background: rgba(255,255,255,.45); }
