#include<bits/stdc++.h>
#define rep(i,a,b) for(int i=(a);i<=(b);++i)
using namespace std;
const int N=1000005,P=1e9+7;
int n,H,D,f[N],fac[N],sum[N];
int fpow(int k1,int k2){int k3=1;for(;k2;k2>>=1,k1=1LL*k1*k1%P)if(k2&1)k3=1LL*k3*k1%P;return k3;}
int main(){
	fac[0]=1;rep(i,1,N-1)fac[i]=1LL*fac[i-1]*i%P;
	scanf("%d%d%d",&n,&H,&D);
	f[0]=1,sum[0]=1;
	int c=0;
	rep(i,1,n)(c+=fac[i])%=P;
	rep(i,1,H){
		int num=sum[i-1];
		if(i-D>0)(num-=sum[i-D-1])%=P;
		f[i]=1LL*num*c%P;
		sum[i]=(sum[i-1]+f[i])%P;
	}
	f[H]=1LL*f[H]*fac[n]%P*fpow(c,P-2)%P;
	printf("%d\n",(f[H]+P)%P);
	return 0;
}