src/components/table/table.scss
@import '../../common/styles/functions';

.table-wrapper {
  position: relative;
  max-width: 100%;
  overflow: visible;
}

.pure-table {
  border-collapse: collapse;
  border-spacing: 0;
  empty-cells: show;
  width: 100%;
  background: #fff;
  box-shadow: 0 1px 3px rgba(0,0,0,0.05);
  font-weight: 300;

  tr {
    border-bottom: 1px solid #f2f2f2;
  }

  tbody tr {
    transition: background 0.1s ease;
    &:hover {
      background: #f7f7f7;
    }
  }

  th, td {
    font-weight: unset;
    padding: 15px;
  }

  th {
    font-size: 14px;
    color: #333333;
    line-height: 1.4;
    text-transform: uppercase;
    padding-top: 21px;
    padding-bottom: 21px;
    font-weight: 700;
    background: #fff;
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);

    .th-content {
      display: flex;
      align-items: center;
      gap: 8px;

      .help-icon {
        position: relative;
        display: inline-block;
        color: #999;

        .help-text {
          visibility: hidden;
          opacity: 0;
          position: absolute;
          min-width: 120px;
          max-width: 250px;
          left: 50%;
          margin-left: -60px;
          bottom: 100%;  /* Use half of the width (120/2 = 60), to center the tooltip */
          z-index: 1000;

          font-family: 'Open Sans', sans-serif;
          color: black;
          background-color: #e6e6e6;
          padding: 8px 12px;
          border-radius: 4px;
          margin-bottom: 10px;
          transition: opacity 0.5s ease, visibility 0.5s ease;

          text-align: left;
          white-space: normal;
          line-height: 1.4;
          font-size: 14px;
          text-transform: none;

          // After element vor triangle
          &::after {
            content: '';
            position: absolute;
            top: 100%;
            left: 50%;
            margin-left: -5px;
            border-width: 5px;
            border-style: solid;
            border-color: #e6e6e6 transparent transparent transparent;
          }
        }
      }

      .help-icon {
        &:hover {
          .help-text {
            visibility: visible;
            opacity: 1;
          }

          opacity: 1;
        }

        .help-text {
          transition: opacity 0.15s ease-in-out;
        }
      }


    }
  }

  td {
    font-size: 15px;
    line-height: 1.4;
    color: #656565;

    &.truncate {
      white-space: nowrap;
      text-overflow: ellipsis;
      overflow: hidden;
      max-width: 1px;
    }

    .actions-wrapper {
      display: flex;
      align-items: center;
      justify-content: flex-start;

      > * {
        margin: 0 5px;
        border-radius: 50em;
        width: 42px;
        height: 42px;
        font-size: 18px;
        background: v(actionButtonBackground, #e6e6e6);
        color: v(actionButtonText, #000000cc);

        &:hover {
          background: v(actionButtonHoverBackground, #ebebeb);
        }
      }
    }

    img {
      width: 200px;
      height: 150px;
      object-fit: cover;
      background: no-repeat center center;
      background-size: cover;
    }

    .colorbox {
      width: 80px;
      height: 20px;
    }

    .bool {
      width: 15px;
      height: 15px;
      display: inline-block;
      border-radius: 50em;

      &.true {
        background-color: #118711;
      }

      &.false {
        background-color: #871111;
      }
    }
  }
}