.card.is-fullwidth {
  margin-bottom: 1rem;

  .add-form {
    margin: 1rem;
  }

  .content {
    padding: 0;
  }
}

.task-add {
  padding: 1rem 1rem 0;
  margin-bottom: 0;

  .button {
    height: 40px;
  }
}

.list-title {
  display: flex;
  align-items: center;
  justify-content: center;

  @media screen and (max-width: $tablet) {
    // We need a fixed width for overflowing ellipsis to work
    width: calc(100vw - #{$user-dropdown-width-mobile} - #{2 * $hamburger-menu-icon-spacing} - #{$hamburger-menu-icon-width} - 1rem); // -1rem for the edit icon
  }

  h1 {
    margin: 0;
  }

  .dropdown-trigger {
    color: $grey-400;
    margin-left: 1rem;
    height: 1rem;
    width: 1rem;
    cursor: pointer;
  }
}

.edit-list {
  padding-bottom: 1rem;
}

$filter-container-top-default: -59px;
$filter-container-top-link-share-gantt: -138px;
$filter-container-top-link-share-list: -47px;

.filter-container {
  text-align: right;
  width: 100%;
  min-width: 400px;
  max-width: 180px;
  position: absolute;
  right: 1.5rem;
  margin-top: $filter-container-top-default;
  z-index: 4;

  .items {
    display: flex;
    justify-content: flex-end;

    .button:not(:last-child) {
      margin-right: .5rem;
    }
  }

  .button {
    height: $switch-view-height;
  }

  .card {
    text-align: left;
    margin-top: calc(1rem - 1px);
  }

  .fancycheckbox {
    display: block;
  }

  .search {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-right: .5rem;

    .button, .input {
      height: $switch-view-height;
    }

    .field {
      transition: width $transition;
      width: 100%;

      &.hidden {
        width: 0;
        height: 0;
        margin: 0;
        overflow: hidden;
      }

      .button {
        height: 100%;
      }
    }
  }

  .filters input {
    font-size: .9rem;
  }

  @media screen and (max-width: $tablet) {
    position: static;
    margin: 0 0 1rem 0;
    max-width: 100%;
    min-width: auto;

    .items {
      justify-content: center;
    }

    .search {
      width: 100%;

      .control:first-child {
        width: 100%;
      }
    }
  }
}

.list-namespace-title {
  color: $grey-500;
}

.link-share-container .gantt-chart-container .filter-container,
.gantt-chart-container .filter-container {
  right: 0;
  margin-top: calc(#{$filter-container-top-link-share-gantt} - 2rem);
}

.link-share-container .list-view .filter-container {
  margin-top: $filter-container-top-link-share-list - 10px;
}

.link-share-container .filter-container {
  right: 9rem;
  margin-top: $filter-container-top-default;
}

.is-archived {
  $notification-height: 1.25rem + 1.25rem + 1.5rem + 1.5rem;

  .filter-container {
    margin-top: calc(#{$filter-container-top-default} - #{$notification-height});
  }

  .link-share-container .gantt-chart-container .filter-container,
  .gantt-chart-container .filter-container {
    margin-top: calc(#{$filter-container-top-link-share-gantt} - 2rem - #{$notification-height});
  }
  
  .link-share-container .list-view .filter-container {
    margin-top: calc(#{$filter-container-top-link-share-list} - #{$notification-height});
  }
  
  .link-share-container .filter-container {
    margin-top: calc(#{$filter-container-top-default} - #{$notification-height});
  }
}
