.flex-row-cdt {
  display: flex;
  flex-flow: row wrap;
  width: 100%;
  flex-grow: 1;
  text-align: center;
  min-height: 42px;

  .flex-col {
    display: flex;
    padding-top: 5px;
    padding-bottom: 5px;
    justify-content: left;
    align-items: center;
  }

  @for $i from 1 through 16 {
    &.row__#{$i} {
      .flex-col {
        @for $j from 1 through 16 {
          &.col__#{$j} {
            width: percentage(calc($j / $i));
          }
        }
      }
    }
  }
}

.flex-content, .flex-collapse {
  flex: 1;
  display: flex;
  flex-direction: column;
  width: 100%;
}

.flex-collapse {
  .flex-content {
    visibility: hidden;
    opacity: 0;
    max-height: 0;
    transition: visibility 0.25s, opacity 0.25s ease-out, max-height 0.2s;
  }

  &.open-details {
    .flex-content {
      opacity: 1;
      visibility: visible;
      max-height: 100%;
      transition: visibility 0.25s, opacity 0.25s ease-in;
    }
  }
}

.flex-table {
  display: flex;
  flex-flow: row wrap;
  width: 100%;
  background-color: $white;

  input[type=checkbox] + span::before {
    border: 2px solid $diary-darkgreen;
    border-radius: 4px;
  }

  .flex-row-cdt {
    .flex-col {
      justify-content: center;
      align-items: center;
      text-align: start;
    }
  }

  .flex-head {
    display: flex;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.12);
    color: rgba($diary-grey, 0.7);
    align-items: center;
  }

  .flex-body {
    align-items: center;
    justify-content: center;
    display: flex;
    width: 100%;
    flex-direction: column;

    .flex-row-cdt {
      box-shadow: 0 -1px 1px rgba(0, 0, 0, 0.08);

      &:hover {
        background-color: rgba($diary-grey, 0.2);
        cursor: pointer;
      }
    }
  }
}

.flex-card {
  display: flex;
  flex-wrap: wrap;
  width: 20%;
  min-height: 100px;
  background-color: $diary-white;
  box-sizing: border-box;
  border-radius: 7px;
  //overflow: hidden;

  .flex-content {
    display: flex;
    color: $diary-darkgreen;
    font-size: 35px;
    height: 75%;
    width: 100%;
    justify-content: center;
  }

  .flex-title {
    display: flex;
    width: 100%;
    height: 25%;
    justify-content: center;
    background: $diary-grey;
    border-radius:  0 0 7px 7px;
    color: #fff;
    transition: all 250ms ease;
  }
}

.flex-column {
  flex-direction: column;
}