/*
Theme Name: Web
Text Domain: td-design
Author: TD Design
Version: 1.0
*/

:root{
	--font-size: 0.9rem;
	--site-width: 85rem;

	--color: #fff;
	--link : #fff;
	--gray : #34393e;

	--primary: hsl(175, 32%, 47%);
	--accent : hsl(180, 18%, 96%);
	--hover:   #3a85bb;
}

html{
	scroll-padding-top: 100px;
}

body{
	font-family: "Open Sans", sans-serif;
	font-optical-sizing: auto;
	font-weight: 400;
	font-style: normal;
	font-variation-settings: "wdth" 100;
	font-size: var(--font-size);
	line-height: 1.4;
	color: var(--color);
	background: #212121;
}

.wrap{
	width: min(100% - 3rem, var(--site-width));
	margin-inline: auto;
}
main{
	padding-block: 4rem;
}

section.banner{
	height: 800px;
	background-position: top center;
	background-repeat: no-repeat;
	background-size: cover;
	position: relative;
	transition: height .2s;
}

header{
	--gap: 2rem;
	position: sticky;
	display: flex;
	background: #252b31;
	top: var(--wp-admin--admin-bar--height, 0);
	align-items: center;
	gap: var(--gap);
	padding: 1rem;
	translate: 0 0;
	transition: box-shadow 0.2s, translate 0.1s;
	z-index: 99;
}
header.scroll{
	box-shadow: 0 -6px 18px #0000002b;
}

header a{
	gap: 5px;
	color: #fff;
	text-decoration: none;
	padding: 1em 2em;
	background: #084470;
	border-radius: 6px;
	font-weight: bold;
	margin-left: auto;
	transition: font-size 0.2s, padding 0.2s;
}


@media (max-width: 767px) {
	header.scroll a{
		font-size: 0.7rem;
		padding: 0.7em 1em;
	}
    header.move-up {
        translate: 0 0;
    }
    header.move-down {
        translate: 0 -70px;
    }
}


footer{
	padding-block: 2rem;
	margin-top: auto;
}

article{
	display: flex;
	flex-wrap: wrap;
	padding: 1rem;
	gap: 1rem;
	border-radius: 8px;
	margin-bottom: 10px;
	min-height: 66px;
	background: var(--gray);
}
article.total{
	background: #252b31;
	gap: 3rem;
}
article div{
	display: flex;
	align-items: center;
}
article div[aria-label]{
	position: relative;
}

@media( min-width: 1024px ){
	#primary > article:first-of-type div[aria-label]::before{
		content: attr(aria-label);
		position: absolute;
		top: -3rem;
	}
}
article div.project-name{
	flex-basis: 18%;
}
article div.hosting{
	flex-basis: 18%;
}
article span{
	background: #0000003b;
	display: inline-block;
	padding: 0.6em 1em;
	border-radius: 8px;
	line-height: 1.2;
}
article .align-right span{
	background: #1e303d;
}
article a[data-action]{
	font-weight: 500;
}

@media( max-width: 650px ){
	.wrap{
		padding-block: 2rem;
	}
	article{
		flex-direction: column;
	}
	article.total{
		gap: 1rem;
	}
	article.total strong{
		display: flex;
		justify-content: space-between;
		align-items: center;
	}
	.align-right span{
		width: 100%;
		justify-content: center;
	}
}

a{
	color: var(--link);
	text-decoration: none;
}
.entry-content a{
	text-decoration: underline;
	text-underline-offset: 2px;
}
a:hover{
	color: var(--hover);
}
a.btn,
button.btn,
input[type="submit"],
a.wp-block-button__link{
	color: #fff;
	padding: 1em 2em;
	font-size: var(--font-size);
	background: var(--secondary);
	border-radius: 6px;
	font-weight: 600;
	display: inline-flex;
	text-decoration: none;
	border: 0;
	cursor: pointer;
}
a.btn:hover,
button.btn:hover,
input[type="submit"]:hover,
a.btn.active,
button.active,
a.wp-block-button__link:hover{
	color: #fff;
	text-decoration: none;
	background: var(--hover);
}

a[data-action="SendPaymentNotification"],
a[data-action="PaymentReceived"]{
	background: #2b6fe2;
	font-size: 1.1rem;
	border-radius: 50rem;
	display: grid;
	place-content: center;
	width: 2.1rem;
	aspect-ratio: 1;
}
a[data-action="PaymentReceived"]{
	background: #35bc35;
}
a[data-action="SendPaymentNotification"]:hover{
	background: #3c84ff;
}
a[data-action="PaymentReceived"]:hover{
	background: #55db55;
}
a[data-action="SetOnline"]{
	color: #78dd78;
}
a[data-action="SetOnline"]:hover{
	color: #aeffae;
}
a[data-action="SetAsPaid"]{
	color: #ff7700;
}
a[data-action="SetAsPaid"]:hover{
	color: #ffa150;
}
a[data-action]:hover{
	color: #fff;
}


h1, h2, h3{
	text-wrap: balance;
}
h1{
	font-size: clamp(1.3rem, 2.5vw, 2rem);
	margin-bottom: 1em;
	color: var(--primary);
}
h2{
	font-size: clamp(.9rem, 2.5vw, 1.1rem);
	margin-bottom: .3em;
}
h3{
	font-size: 0.9rem;
}

p{
	margin-bottom: 1rem;
	max-width: 80ch;
}

.entry-content :is(ul, ol){
	padding-left: 18px;
}


.contact__wrapper{
	gap: 4rem;
}
strong{
	font-weight: 500;
}
#content .content-area img{
	display: block;
	font-style: italic;
	max-width: 100%;
	height: auto;
	width: auto;
}

img{
	display: block;
}
a:has( > img){
	display: block;
	width: fit-content;
	overflow: hidden;
}
a img{
	transition: scale 0.2s
}
#content a:hover img{
	scale: 1.05;
}

@media( min-width: 651px ){
	.align-right{
		margin-left: auto;
	}
}

input,
button,
textarea,
select{
	font: inherit;
}
button{
	background: none;
	border: none;
}
address{
	font-style: normal;
}

form[role="search"]{
	position: relative;
	margin-bottom: 20px;
}
form[role="search"] input.search-field{
	width: 100%;
	height: 40px;
	border: 1px solid #ccc;
	border-radius: 5px;
	padding: 0 10px;
}
form[role="search"] .search-submit{
	position: absolute;
	height: 40px;
	width: 40px;
	right: 0;
	top: 0;
	border: none;
	background: transparent;
	cursor: pointer;
	outline: none;
}


.flex{
	display: flex;
	flex-wrap: wrap;
}
.flex.column{
	flex-direction: column;
}

.grid{
	--min-column-size: 200px;
	--column-count: 4;
	--gap: 2rem;
	
	--breakpoint: calc(var(--min-column-size) * var(--column-count) + (var(--gap) * (var(--column-count) - 1)) );
	--column-size: calc((100% / var(--column-count)) - var(--gap));
	
	display: grid;
	gap: var(--gap);
	
	grid-template-columns: repeat(auto-fit, minmax(
			min(max(var(--column-size), (100% - var(--breakpoint)) * -999 ), 100%), 
			1fr));
}

*:has( > [class*="svg-inline"]){
	display: flex;
	gap: 5px;
	align-items: center;
}

.card{
	border: 1px solid #efefef;
	padding: 2rem;
	border-radius: 1rem;
	max-width: max-content;
	margin: 0 auto;
}
.warning, .notice{
	border: 1px solid;
	padding: 1rem 1.4rem;
	border-radius: 1rem;
	margin: 0 auto;
	text-align: center;
}
.notice{
    background: #e1f6ff;
    color: #1d78d5;
    border-color: #9ccde2;
}
.warning{
	background: #fff8eb;
	color: #c97d00;
	border-color: #e4c896;
}

@media( max-width: 1024px ){
	header{
		--wp-admin--admin-bar--height: 0;
		--header-height: 70px;
		display: flex;
		padding: 0.4rem 1rem;
		height: var(--header-height);
	}
	header .wrap{
		width: 100%;
	}
	header .logo a > *{
		max-height: 40px;
		width: auto;
	}

}


.loader{
	display: flex;
	gap: 0.25rem;
	justify-content: center;
}
.loader > *{
	width: 0.5rem;
	aspect-ratio: 1;
	border-radius: 50%;
	background: var(--primary);
	animation: bounce 0.5s infinite alternate;
}
.loader > *:nth-child(2){
	content: '';
	animation-delay: 100ms;
}
.loader > *:nth-child(3){
	content: '';
	animation-delay: 200ms;
}

@keyframes bounce{
	to{
		translate: 0 -0.25rem;
	}
}