/*
Theme Name: Workers Student
Text Domain: promisys
Author: Promisys
Version: 1.0
*/

:root{
	--font-size: 1rem;
	--site-width: 70rem;
	--header-height: 74px;

	--color: #232323;
	--dark-gray: #15181f;
	--light-gray: #d1d1d1;
	--medium-gray: #737b8c;
	--card-gray: #f4f4f6;
	--link : #242424;

	--btn-background: #14181f;
	--btn-alt-background: transparent;
	--btn-hover: #2b2e35;

	--primary: #7326c5;
	--primary-hover: #6a24ad;
	--accent:  hsl(180, 18%, 96%);
	--hover:   hsl(180, 18%, 50%);
	
}

html{
	scroll-padding-top: 100px;
}

body{
	font-family: "Manrope", "Segoe UI", "Helvetica Neue",Arial, 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);
}

.wrap, .container{
	width: min(100% - 3rem, var(--site-width));
	margin-inline: auto;
}
main{
}

section.banner{
	height: 800px;
	background-position: top center;
	background-repeat: no-repeat;
	background-size: cover;
	position: relative;
	transition: height .2s;
}
header{
	position: sticky;
	top: var(--wp-admin--admin-bar--height, 0px);
	z-index: 99;
	background: transparent;
	padding: 1rem 2rem;
	height: var(--header-height);
	border-bottom: 1px solid;
	border-color: transparent;
	transition: background 0.4s, border-color 0.2s;
}

#page:has( > #content .entry-content > section.hero:first-child) header{
	position: fixed;
	width: 100%;
}

header .container{
	--gap: 2rem;
	display: flex;
	align-items: center;
	gap: var(--gap);
}
#page:not(:has( > #content .entry-content > section.hero:first-child)) header,
header.scroll{
	background: #fff;
	border-color: #f7f7f7;
}

header .logo svg{
	height: 36px;
}
header .logo svg path{
	transition: fill 0.4s;
}
#page:has( > #content .entry-content > section.hero:first-child) header:not(.scroll) .logo svg path{
	fill: #fff;
}


footer{
	padding-block: 2rem;
	margin-top: auto;
}
footer .site-info{
	gap: 2rem;
}
footer nav ul{
	gap: 1rem;
}

.socials{
	gap: 1rem;
}


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: 0.875em 1.7em;
	font-size: var(--font-size);
	background: var(--btn-background);
	border-radius: 50px;
	font-weight: 600;
	display: inline-flex;
	text-decoration: none;
	border: 0;
	cursor: pointer;
	transition: background 0.2s;
}
a.btn.primary,
button.btn.primary,
input[type="submit"].primary,
.primary a.wp-block-button__link{
	background: var(--primary);
}
a.btn.alt,
button.btn.alt,
input[type="submit"].alt,
.alt a.wp-block-button__link{
	background: transparent;
	border: 1px solid hsl(0deg 0% 73.33% / 49.02%);
}

a.btn:hover,
button.btn:hover,
input[type="submit"]:hover,
a.btn.active,
a.wp-block-button__link:hover{
	color: #fff;
	text-decoration: none;
	background: var(--btn-hover);
}
a.btn.primary:hover,
button.btn.primary:hover,
input[type="submit"].primary:hover,
.primary a.wp-block-button__link:hover{
	background: var(--primary-hover);
}
a.btn.alt:hover,
button.btn.alt:hover,
input[type="submit"].alt:hover,
.alt a.wp-block-button__link:hover{
	background: hsl(0 0% 100% / .1);
}

h1, h2, h3{
	line-height: 1.1;
	text-wrap: balance;
}
:is(h1, h2, h3).has-text-align-center{
	margin-inline: auto;
}
h1{
	font-size: clamp(1.3rem, 2.5vw, 2rem);
	margin-bottom: 1em;
}
h2{
	font-size: clamp(1.1rem, 2.5vw, 1.5rem);
	margin-bottom: .3em;
}
h3{
	font-size: clamp(1.4rem, 2.5vw, 2.1rem);
	margin-bottom: 0.3em;
	line-height: 1.4;
}
h4{
	color: #5a5d62;
	font-size: clamp(1rem, 2.5vw, 1.2rem);
	font-weight: 500;
	margin-bottom: 0.3em;
}

p{
	margin-bottom: 1rem;
}

p.pre-title{
	text-transform: uppercase;
	color: var(--light-gray);
	font-weight: 700;
	font-size: .875rem;
	margin-bottom: 0;
}

.entry-content :is(ul, ol){
	padding-left: 18px;
}


.contact__wrapper{
	gap: 4rem;
}
aside .contact-info{
	display: flex;
	flex-direction: column;
	gap: 1rem;
}

strong{
	font-weight: 600;
}
#content .content-area img{
	display: block;
	font-style: italic;
	max-width: 100%;
	height: auto;
	width: auto;
}

figure{
	margin-bottom: 0;
}
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;
}

.wp-block-media-text img{
	border-radius: 1rem;
}

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;
}

/*BLOG*/
aside {
    width: min(100%, 300px);
}
main:has( > aside) {
    display: flex;
    align-items: flex-start;
    gap: 3rem;
}
main.posts{
	gap: 4rem;
}
main.posts h2,
.single-post h1{
	margin-bottom: .5rem;
}

.post-img{
	margin-bottom: 2rem;
}
.post-img a{
	display: inline-block;
	height: 24rem;
	width: 100%;
	border-radius: 8px;
}
.content-area .post-img img{
	height: 100%;
	width: 100%;
	object-fit: cover;
}
span.date{
	font-size: .7rem;
	line-height: 1;
}
.single-post article{
	max-width: 75ch;
}

aside .posts{
	flex-direction: column;
	gap: .8rem;
}
aside .posts li{
	display: flex;
	flex-flow: row;
	align-items: center;
	gap: 1rem;
}
aside .posts li a{
	font-size: 0.9rem;
	color: var(--color);
}
aside .posts a:last-child{
	flex: 1;
}
aside .posts li:hover a{
	color: var(--primary);
	text-decoration: none;
}
aside .posts li img{
	width: 60px;
	height: auto;
	aspect-ratio: 1;
	object-fit: cover;
	max-width: initial;
}

.flex{
	display: flex;
	flex-wrap: wrap;
}
.flex.column{
	flex-direction: column;
}

.grid {
  --min-col-size: 200px;
  --gap: 1rem;

  display: grid;
  gap: var(--gap);
  grid-template-columns: repeat(auto-fit, minmax(min(var(--min-col-size), 100%), 1fr));
}
.grid.auto-fill{
  grid-template-columns: repeat(auto-fill, minmax(min(var(--min-col-size), 100%), 1fr));
}

.grid[data-columns="5"]{ --grid-max-col-count: 5; }
.grid[data-columns="4"]{ --grid-max-col-count: 4; }
.grid[data-columns="3"]{ --grid-max-col-count: 3; }
.grid[data-columns="2"]{ --grid-max-col-count: 2; }

.grid[data-columns]{
	--grid-max-col-count: 3;
	--grid-col-size-calc: calc(
	  (100% - var(--gap) * var(--grid-max-col-count)) /
	    var(--grid-max-col-count)
	);
	--grid-col-min-size-calc: min(
	  100%,
	  max(var(--min-col-size), var(--grid-col-size-calc))
	);
	grid-template-columns: repeat(
	  auto-fill,
	  minmax(var(--grid-col-min-size-calc), 1fr)
	);
}


*:has( > [class*="svg-inline"]){
	display: flex;
	gap: 5px;
	align-items: center;
}

.card{
	background: var(--card-gray);
	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;
	}
}