libs/barista-components/tile/src/tile.scss
@import '../../style/font-mixins';
@import '../../core/src/style/variables';
@import '../../core/src/style/interactive-common';

.dt-tile {
  display: block;
  appearance: none;
  position: relative;
  box-sizing: border-box;
  text-decoration: none;
  border-radius: 3px;
  cursor: pointer;
  line-height: -moz-block-height;
  border: 1px solid $gray-200;
  width: 100%;
  padding: 0;
  text-align: left;

  &:hover:not(.dt-tile-disabled) {
    border-color: $gray-700;
  }

  &.dt-tile-disabled {
    pointer-events: none;
    border-color: $gray-300;
    cursor: default;
    box-shadow: none;
  }

  @include dt-cdkmonitor-focus-style();
}

.dt-tile-header {
  display: flex;
  background-color: $gray-100;
  height: 52px;

  // Borders for the header element and bottom
  border-top-right-radius: 3px;
  border-top-left-radius: 3px;
  border-bottom: 1px solid $gray-200;
  width: 100%;

  .dt-tile-small & {
    height: 36px;
  }
}

.dt-tile-icon {
  width: 53px;
  height: 53px;
  background-color: $gray-700;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  // Icon should be "above" the tile border
  margin-left: -1px;
  margin-top: -1px;
  border-top-left-radius: 3px;

  svg {
    fill: #ffffff;
  }

  .dt-tile-small & {
    width: 37px;
    height: 37px;
  }

  .dt-icon {
    width: 32px;
    height: 32px;

    .dt-tile-small & {
      width: 20px;
      height: 20px;
    }
  }
}

.dt-tile-disabled .dt-tile-icon {
  background-color: $gray-300;
}

.dt-tile-heading {
  padding: 8px 11px 0;
  flex: 1 0 8px;
  overflow: hidden;
}

.dt-tile-title {
  @include dt-h2-font(1.2);
  display: block;
  margin-top: 0;

  // Text truncation
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.dt-tile-subtitle {
  @include dt-label-font(1.2);
  display: block;
  margin-top: 0;
  position: relative;

  // Text truncation
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.dt-tile-disabled .dt-tile-title,
.dt-tile-disabled .dt-tile-subtitle {
  color: $gray-300;
}

.dt-tile-content {
  display: block;
  @include dt-main-font();
  margin: 0;
  padding: 11px;
  border: 1px solid transparent;
  border-radius: 0 0 3px 3px;
  border-top: none;
  background-color: #ffffff;
}

.dt-tile-disabled .dt-tile-content {
  color: $gray-300;
}

@import './tile-theme';
