.root {
  height: 100%;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  cursor: pointer;
  padding: 0 6px;
  color: inherit;
  text-decoration: none;

  &-preview {
    position: relative;
    width: 100%;
    min-height: 0;
    border-radius: 6px;
    overflow: hidden;
    flex-grow: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    //background: hsla(var(--alinea-negative), 0.05);
    background: red;
    transition: background 0.25s ease-out;

    &-picture {
      width: 100%;
      flex-grow: 1;
      display: flex;
      align-items: center;
      justify-content: center;
      min-width: 0;
      min-height: 0;
      background-size: cover;
      background-repeat: no-repeat;
      background-position: center center;
      margin: 5px;

      &-image {
        display: block;
        max-width: 100%;
        max-height: 100%;
        object-fit: cover;
        object-position: center center;
        margin: auto;
      }
    }

    &-icon {
      margin: auto;
      opacity: 0.4;
    }
  }

  &:hover &-preview {
    background: var(--alinea-selected);
  }

  &-title {
    display: flex;
    align-items: center;
    width: 100%;
    overflow: hidden;
    flex-shrink: 0;
    text-align: center;
    padding: 8px 12px;
    padding-top: 6px;
    // background: hsla(var(--alinea-negative), 0.05);

    &-text {
      min-width: 0;
      overflow: hidden;
      text-overflow: ellipsis;
      white-space: nowrap;
      font-size: 12px;
    }

    &-extension {
      opacity: 0.5;
      margin-left: auto;
      padding: 3px 5px;
      flex-shrink: 0;
      font-size: 10px;
      background: hsla(var(--alinea-negative), 0.05);
      border-radius: 6px;
    }
  }
}
