
@import "../../styles/variables.scss";

.cellWrapper {
  //width: 70%;
}

.table {
  display: flex;
  flex-flow: column nowrap;
  justify-content: space-between;

  // .Table-row
  .row {
    display: block;
    padding: $m-spacing 0;
    width: 100%;

    @media only screen and (min-width: 60em) {
      border-bottom: $light-border;
      display: flex;
      padding: $base-spacing 0;
      justify-content: space-between;
      align-items: center;
      flex-direction: row;
    }

    &:not(:last-child) {
      border-bottom: $light-border;
    }
  }

  .row.rowHover:hover {
    background-color: $brand-nearWhite;
  }

  .row.rowHover {
    cursor: pointer;
  }

  // .Table-header
  .header {
    display: none;

    .cell {
      line-height: 1.3;
    }

    @media only screen and (min-width: 60em) {
      display: flex;
    }
  }
}

.cell {
  align-self: center;
  align-items: center;
  display: flex;
  flex-direction: row;
  flex-grow: 0;
  flex-basis: 0;
  justify-content: space-between;

  &:before {
    content: attr(data-header);
    font-size: $body-small-font-size;
    color: $brand-grey;
  }

  &:not(:last-child) {
    padding-bottom: $m-spacing;
  }

  @media only screen and (min-width: 60em) {
    justify-content: flex-start;

    &:not(:last-child) {
      padding-right: $base-spacing;
      padding-bottom: 0;
    }

    &:before {
      display: none;
    }
  }
}

.numerical {
  text-align: right;

  @media only screen and (min-width: 60em) {
    justify-content: flex-end;
  }

  @media only screen and (min-width: 60em) {
    &:not(:last-child) {
      padding-right: $l-spacing;
    }
  }
}
