/* Hide the entity browser "Upload" handle text. The iframe is already
 * visible and provides its own dropzone UI; the handle link is redundant.
 * !important is needed to override the inline style="display: inline;"
 * set by the entity browser JS. */
#edit-field-media-file .entity-browser-handle,
.upload .entity-browser-handle {
  display: none !important;
}

/* Per-file detail cards for multi-upload. */
.file-detail-card .file-upload-card__outer {
  background: #262b31;
  padding: 6px;
}
.file-detail-card .file-upload-card__inner {
  position: relative;
  display: flex;
  align-items: center;
  min-height: 44px;
  padding: 0.5rem 40px 0.5rem 56px;
  border-radius: 8px;
  background: #474e57;
}
.file-detail-card .file-upload-card__icon {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  left: 0.5rem;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: #777777 url('../icons/upload-file.svg') no-repeat center;
  background-size: 36px 36px;
}
.file-detail-card .file-upload-card__details {
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.file-detail-card .file-upload-card__name {
  color: #fff;
  font-size: 0.875rem;
  line-height: 20px;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.file-detail-card .file-upload-card__meta {
  color: #fff;
  font-size: 0.75rem;
  line-height: 16px;
  text-transform: uppercase;
  opacity: 0.7;
}
.file-detail-card .remove-button {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  right: 1rem;
  width: 14px;
  height: 14px;
  padding: 0;
  border: none;
  border-radius: 0;
  background: transparent;
  color: #fff;
  font-size: 18px;
  line-height: 14px;
  cursor: pointer;
}

.file-details-wrapper {
  max-width: 368px;
}

.file-detail-item {
  margin-bottom: 0.5rem;
}
.file-detail-item .file-detail-fields {
  border: 1px solid #ccc;
  border-radius: 4px;
  padding: 0.5rem;
  margin-top: 0.25rem;
  background: #f5f5f5;
}
.file-detail-item .file-detail-fields .form-group {
  position: relative;
}
.file-detail-item .file-detail-fields .form-group::before {
  content: '';
  position: absolute;
  left: 4px;
  top: 50%;
  transform: translateY(-50%);
  width: 20px;
  height: 20px;
  border-radius: 4px;
  background-color: #777777;
  z-index: 1;
  pointer-events: none;
}
.file-detail-item .file-detail-fields .form-group::after {
  content: '';
  position: absolute;
  left: 8px;
  top: 50%;
  transform: translateY(-50%);
  width: 12px;
  height: 12px;
  z-index: 2;
  pointer-events: none;
  background-color: #fff;
  mask-repeat: no-repeat;
  mask-position: center;
  mask-size: contain;
}
.file-detail-item .file-detail-fields .form-group input.form-text {
  padding-left: 30px;
}
.file-detail-item .file-detail-fields .form-group:nth-child(1)::after {
  mask-image: url('../icons/action-edit.svg');
}
.file-detail-item .file-detail-fields .form-group:nth-child(2)::after {
  mask-image: url('../icons/img.svg');
}
.file-detail-item .form-group {
  margin-bottom: 0.25rem;
}
.file-detail-item .form-group > .control-label {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip-path: inset(50%) !important;
  white-space: nowrap !important;
  border: 0 !important;
}

#edit-create .file-detail-item {
  margin-bottom: 1rem;
  border-bottom: none;
}
