body, html{margin:0;padding:0;font-family:"Chaparral", times, times-new-roman,serif;overflow:hidden;background:#1b4301;}
h1, h2{font-family:"Snippet",tahoma,arial,sans-serif;font-weight:bold;}
h2{font-weight:normal;}
#main_bg{
	position:fixed;
	z-index:-1000;
	display:block;
	top:-20px;
	left:-20px;
	width:calc(100% + 40px);
	height:calc(100% + 40px);
	filter:blur(12px);
	object-fit: cover;
}
main{
	position:absolute;
	top:calc(50% - 25px);
	left:50%;
	transform: translate(-50%, -50%);
	text-align: center;
	width:calc(100% - 80px);
	max-width:420px;
	padding:10px 30px 30px;
	border-radius:15px 15px 15px;
	margin-top:40px;
	font-size:22px;
	background:rgba(255,255,255,.6);
	backdrop-filter:blur(8px) saturate(1.2) brightness(2);
	box-shadow:0 2px 5px rgba(0,0,0,.25);
	transition:cubic-bezier(.5,1.85,.5,1) .5s;
}
main ul{list-style:none;padding:0;}
header{
	text-align:left;
	padding-left:60px;
	margin-bottom:40px;
	text-shadow:0 0 6px #fff;
}
header:before{
	content: "";
	display: block;
	background: url(https://portfolio.thomas-daveluy.fr/public/.carre2_s.jpg) no-repeat center #fff;
	background-size: auto;
	background-size: cover;
	width: 104px;
	height: 104px;
	border-radius: 80px;
	position: absolute;
	left: -30px;
	top: -8px;
	border:2px solid #fff;
	box-shadow:0 0px 5px rgba(0,0,0,.25);
}
header h1{
	margin:0;
	padding:5px 0 5px;
	font-size:34px;
	color:var(--blue);
}
header h2{
	margin:0;
	font-size:19px;
	padding-left:3px;
	font-family:"Chaparral", times, times-new-roman, serif;
}

#square{margin:30px 0;}
#square ul{
	aspect-ratio:4/3;
	display:grid;
	grid-template-columns: calc(25% - 11px) calc(25% - 11px) calc(25% - 11px) calc(25% - 11px);
	grid-template-rows: calc(33% - 11px) calc(33% - 11px) calc(33% - 11px);
	gap:15px;
}
#square li{
	position:relative;
	overflow:hidden;
	transition:all .25s;
	text-align:left;
	box-shadow:0 0 20px rgba(255,255,255,.5);
	text-shadow:0 0 5px rgba(0,0,0,.5), 0 0 0px rgba(0,0,0,0);
}
#square li:hover{text-shadow:0 0px 2px rgba(0,0,0,1), 0 1px 0px rgba(0,0,0,1);}
#square li:before, #square li:after, #square li>img{
	content:"";
	position:absolute;
	top:0;
	left:0;
	right:0;
	bottom:0;
	z-index:-10;
	background:var(--blue);
	object-fit: cover;
	transition:all .25s;
}
#square li>img{z-index:-5;width:100%;height:100%;}
#square li>img.new{animation:new 1s 1 ease;}
@keyframes new{from{opacity:0}to{opacity:1}}
#square li:hover>img{filter:blur(2px);transform: scale(1.05);}
#square li:after{z-index:-1;opacity:.8;}
#square li:hover:after{opacity:.1;}
#square li a{
	color:#fff;
	text-decoration:none;
	display:block;
	width:100%;
	height:100%;
	display:flex;
	flex-direction:column;
	justify-content:flex-end;
	box-sizing:border-box;
	padding:14px 17px;
	transition:all .25s;
}
#square li a strong{font-family:"Snippet",tahoma,arial,helvetica,sans-serif;font-weight:normal;font-size:30px;}
#square li a span{
	font-size:17px;
	display:block;
	height:36px;
	margin-bottom:-40px;
	opacity:0;
	transition:all .25s;
	line-height:19px;
}
#square li a:hover span{margin-bottom:0px;opacity:1;}
#square li a span>span{white-space:nowrap;}
#square li#li_pf{
	grid-column-start: 1;
	grid-column-end: 3;
	grid-row-start: 1;
	grid-row-end: 3;
	text-align:right;
}
#square li#li_pf:before, #square li#li_pf:after{background:var(--portfolio);}
#square li#li_pf a strong{font-size:34px;}
#square li#li_bg{
	grid-column-start: 3;
	grid-column-end: 5;
	grid-row-start: 1;
	grid-row-end: 2;
}
#square li#li_bg:before, #square li#li_bg:after{background:var(--blog);}
#square li#li_at{
	grid-column-start: 3;
	grid-column-end: 5;
	grid-row-start: 2;
	grid-row-end: 3;
}
#square li#li_at:before, #square li#li_at:after{background:var(--ateliers);}
#square li#li_nf, #square li#li_ga{text-shadow:0 0 3px #000;}
#square li#li_nf{
	grid-column-start: 2;
	grid-column-end: 3;
	grid-row-start: 3;
	grid-row-end: 4;
	background-size:280px;
	text-align:right;
}
#square li#li_nf:hover{margin-left:calc(-100% - 14px);}
#square li#li_nf:before, #square li#li_nf:after{background:#222;}
#square li#li_nf:after{background:url(pictures/ns.png) no-repeat left #222;background-size:280px;opacity:.9;}
#square li#li_nf:hover:after{filter:blur(3px);}
#square li#li_ga{
	grid-column-start: 3;
	grid-column-end: 4;
	grid-row-start: 3;
	grid-row-end: 4;
	background-size:280px;
}
#square li#li_ga:hover{margin-right:calc(-100% - 14px);text-shadow:0 1px 1px #000, 0 0px 6px #000;}
#square li#li_ga:before, #square li#li_ga:after{background:#eee;}
#square li#li_ga:hover:before{background:#eee;}
#square li#li_ga:after{background:url(https://portfolio.thomas-daveluy.fr/public/la-galerie/.02_s.jpg) no-repeat left #eee;background-size:280px;opacity:.5;}
#square li#li_ga:hover:after{opacity:.8;filter:blur(3px);}
#square li#li_nf a, #square li#li_ga a {min-width:200px;}
#square li#li_nf a{padding-left:0;}
#square li#li_ga a{padding-right:0;}
#square li#li_nf a strong, #square li#li_ga a strong{
	font-size:24px;
	opacity:0;
	white-space:nowrap;
	margin-bottom:5px;
	transition: all .25s;
}
#square li#li_nf a:hover strong, #square li#li_ga a:hover strong{opacity:1;}
#square li#li_nf a span, #square li#li_ga a span{height:auto;margin-bottom:0px;}
#square li#li_nf a:hover span, #square li#li_ga a:hover span{margin-bottom:0px;opacity:1;}

#links ul{
	display:flex;
	flex-wrap:wrap;
	gap:10px 20px;
	margin:30px 0 0;
	padding:28px 0 0;
	justify-content:center;
	border-top:2px solid rgba(0,0,0,.1);
}
#links li{order:2;}
#links li a{
	display:block;
	width:max-content;
	padding:5px 20px 5px;
	line-height:28px;
	height:26px;
	border-radius:40px;
	border:2px solid var(--blue);
	background:rgba(255,255,255,.8);
	color:var(--blue);
	text-decoration: none;
	box-shadow:0 0 10px rgba(255,255,255,.5);
	transition:all .25s;
	font-size:20px;
}
#links li a[download]:before{
	content:"";
	display:inline-block;
	vertical-align: top;
	background:url(pictures/dlpdf.svg?v=2) no-repeat center;
	background-size:24px;
	width:24px;
	height:24px;
	margin:0 8px 0 -4px
}
#links li a:hover{background:var(--blue);opacity:1;color:#fff;}
#links li a[download]:hover:before{animation:dlpdf .75s 1 ease;}
@keyframes dlpdf{
	0%,100%{background-position:0px 0px;}
	50%{background-position:0px 24px;}
	50.0001%{background-position:0px -24px;}
}

footer{
	font-size:18px;
	color:rgba(255,255,255,.6);
	text-shadow:0 0 5px rgba(0,0,0,.4);
	position:fixed;
	left:50%;
	width:480px;
	transform: translateX(-50%);
	bottom:20px;
	text-align:center;
	transition:cubic-bezier(.5,1.85,.5,1) .5s;
}
footer p{margin:0 0 5px 0;}
footer ul{
	list-style:none;
	margin:0;
	font-size:18px;
	display:flex;
	justify-content:center;
	gap:40px;
	padding:0;
}
footer a{text-decoration: none;color:rgba(255,255,255,.75);}
footer a:hover{color:rgba(255,255,255,1);text-shadow:0 0 6px rgba(0,0,0,1);}

/*HOVER*/
body.hover main, body.hover footer{
	opacity:0;
	transform-origin:center;
	transform: translateX(-50%) scale(.5);
	pointer-events:none;
}
body.hover main{filter:blur(10px);transform: translate(-50%, -50%) scale(.5);}

@media screen and (max-width:650px){
	footer{
		left:0;
		bottom:20px;
		transform: none;
		width:auto;
		right:80px;
	}
	body.hover footer{transform: scale(.5);}
	footer ul{gap:0px 10px;justify-content:space-evenly;flex-wrap:wrap;}
	footer li{width:calc(50% - 20px);}
	footer a span{	display:none;}
}
@media screen and ((max-width:480px) or (max-height:680px)){
	main{
		top:calc(50% - 70px);
		max-height:calc(100vh - 160px);
		padding:10px 20px 20px;
		width:calc(100% - 60px);
		overflow:hidden;
		overflow-y:auto;
	}
	body.hover main{transform: none}
	body.hover footer{transform: none}
	header{padding-left:75px;margin-bottom:20px;}
	header:before{
		left:15px;
		top:15px;
		width:65px;
		height:65px;
		border:1px solid #fff;
	}
	header h1{
		padding:5px 0 2px 0;
		font-size:29px;
		letter-spacing:-1px;
		white-space:nowrap;
		line-height:32px;
	}
	header h2{line-height:22px;}
	#square{margin:20px 0;}
	#square li a{min-width: 0px!important;padding:10px}
	#square li#li_nf a, #square li#li_ga a{padding:5px 10px;max-width:80px;}
	#square li a strong,#square li#li_pf a strong,#square li#li_nf a strong,#square li#li_ga a strong{font-size:24px;opacity:1;}
	#square li#li_nf a strong,#square li#li_ga a strong{font-size:12px;padding-right:10px;white-space:wrap;}
	#square li a span{display:none;}
	#links ul{margin:0;padding:20px 0 0;}
	#links li#li_contact{order:1;}
	footer p{margin:0;}
}
@media screen and (max-height:750px){
	main{
		top:calc(50% - 70px);
		max-height:calc(100vh - 160px);
		padding:10px 20px 20px;
		width:calc(100% - 60px);
	}
	footer p{margin:0;}
}
@media screen and (max-height: 700px) and (max-width: 500px) {footer {bottom: 10px;}}
@media screen and (max-height:540px){
	footer{display:none;}
	main{
		background:none;
		backdrop-filter:none;
		box-shadow:none;
		transform: none;
		border-radius:0 20px 20px 0;
		left:0;
		top:10px;
		bottom:10px;
		padding:0;
		max-height:1000%;
		margin:0;
		overflow:visible;
		width:0%;
		max-width:0%;
	}
	header, #square, #links{
		position:fixed;
		background:rgba(255,255,255,.6);
		backdrop-filter:blur(8px) saturate(1.2) brightness(2);
		box-shadow:0 2px 5px rgba(0,0,0,.25);
		padding:10px 2%;
		box-sizing:border-box;
		margin:0;
		max-width:420px;
		width:50%;
	}
	header{
		right:0;
		height:auto;
		min-height:98px;
		padding:0 15px 0 100px;
		width:45%;
		max-width:480px;
		border-radius:50px 0 0 50px;
		display:flex;
		flex-direction:column;
		justify-content: center;
	}
	header:before{
		box-sizing:border-box;
		width:70px;
		height:70px;
		left:15px;
		top:15px;
	}
	header h1{white-space:wrap;font-size:26px;letter-spacing:0;}
	#square{
		top:10px;
		height:calc(100% - 81px);
		border-radius:0 20px 0 0 ;
		overflow:hidden;
		overflow-y:auto;
		display:flex;
		justify-content: center;
	}
	#square ul{
		box-sizing:border-box;
		margin:0;
		position:absolute;
		max-width:calc(100% - 30px);
		max-height:calc(100% - 30px);
		margin:0 auto;
		top:50%;
		transform: translateY(-50%);
	}

	#links{bottom:10px;height:60px;border-radius:0 0 20px 0;}
	#links ul{
		margin:0;
		padding:0;
		border:none;
		gap:0;
		justify-content: space-around;
	}
}
@media screen and (max-height:540px) and (max-width:700px){
	header h1{font-size:22px;}
	header h2{font-size:18px}
	#links li a[download]::before{display:none;}
}