smart-grid-column,
smart-grid-cell {
  >.smart-label:not(.smart-input) {
    width: 100%;
    height: 100%;

    &.comments::after {
      content: '';
      width: 10px;
      height: 10px;
      background: var(--smart-error);
      position: absolute;
      right: 0;
      transform: rotate(45deg);
      top: -5px;
      right: -5px;
    }
  }

  &.rotate {
    line-height: initial;
    display: inline-block;
    left: 0px;
    top: 0px;
    position: absolute;
    transform-origin: 50% 50% 0;
    transform: rotate(0deg);
  }

  .align-left {
    overflow: hidden;
    text-overflow: ellipsis;
    text-align: left;
    padding-left: 7px;
    padding-right: 2px;
  }

  .align-top {
    align-items: flex-start;
    display: flex;
    line-height: initial;
  }

  .align-bottom {
    align-items: flex-end;
    display: flex;
    line-height: initial;
  }

  .align-right {
    overflow: hidden;
    text-overflow: ellipsis;
    text-align: right;
    padding-right: 7px;
    padding-left: 2px;
  }

  .align-right.align-bottom {
    flex-direction: column-reverse;
  }

  .align-right.align-top {
    flex-direction: column;
    align-items: flex-end;
  }

  .align-center {
    text-overflow: ellipsis;
    overflow: hidden;
    text-align: center;
    padding-right: 7px;
    padding-left: 7px;
  }

  .align-center.align-bottom {
    margin-left: 50%;
    margin-right: 50%;
    padding-left: 0;
    padding-right: 0;
  }

  .align-center.align-top {
    margin-left: 50%;
    margin-right: 50%;
    padding-left: 0;
    padding-right: 0;
  }

  .align-middle {
    display: flex;
    align-items: center;
  }

  .align-center.align-middle {
    justify-content: center;
  }

  &.smart-grid-column-border {
    border-top-color: var(--smart-border);
    border-bottom-color: var(--smart-border);
    border-left-color: var(--smart-border);
    border-right-color: var(--smart-border);
    border-top-width: 0px;
  }

  &:not(.smart-grid-column-border) {
    &:after {
      height: var(--smart-border-width);
      width: 100%;
      content: '';
      position: absolute;
      bottom: 0px;
      left: 0px;
    }

    &:not(.smart-grid-column-border-collapse) {
      &:before {
        width: var(--smart-border-width);
        height: 100%;
        content: '';
        position: absolute;
        top: 0px;
        left: 0px;
      }
    }
  }
}
