/* -------------------------------------------------
	Fonts
   ------------------------------------------------- */
@font-face {
    font-family: 'Merriweather';
    src: url('../fonts/Merriweather-Regular.ttf') format('truetype');
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'PT Sans Caption';
    src: url('../fonts/PTSansCaption-Regular.ttf') format('truetype');
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'PT Sans Caption';
    src: url('../fonts/PTSansCaption-Bold.ttf') format('truetype');
    font-weight: 700;
    font-style: normal;
    font-display: swap;
}

/* -------------------------------------------------
	Base styles
   ------------------------------------------------- */
* {
    margin: 0;
    padding: 0;
}

*,
*::after,
*::before {
    box-sizing: border-box;
}

html,
body {
    font-family: 'PT Sans Caption', sans-serif;
    line-height: 1.5;
}

ul,
li {
    list-style: none;
    margin: 0;
    padding: 0;
}

a {
    text-decoration: none;
    transition: 0.2s ease-out;
}

img {
    display: inline-block;
}

/* -------------------------------------------------
	Header
   ------------------------------------------------- */
header {
    height: 100vh;
    background: #343c4e;
    background: url('../images/header-bg.jpg') no-repeat center;
    -webkit-background-size: cover;
    background-size: cover;
    color: #fff;
    text-align: center;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    position: relative;
}

header::before {
    content: '';
    width: 100%;
    height: 100%;
    position: absolute;
    background-color: rgba(52, 60, 78, 0.8);
}

.header__title {
    margin-top: -70px;
    font-family: 'Merriweather', sans-serif;
    font-size: 56px;
    line-height: 62px;
    z-index: 1;
}

.header__subtitle {
    margin-bottom: 15px;
    font-size: 22px;
    line-height: 42px;
    z-index: 1;
}

.header__slogan {
    font-size: 26px;
    line-height: 42px;
    z-index: 1;
}

.header__arrow {
    width: 60px;
    height: 50px;
    margin-left: -30px;
    font-size: 48px;
    position: absolute;
    bottom: 50px;
    left: 50%;
    z-index: 1;
}

/* -------------------------------------------------
	Portfolio
   ------------------------------------------------- */
.container {
    max-width: 1140px;
    margin: 0 auto;
    text-align: center;
}

.portfolio {
    padding-top: 20px;
    padding-bottom: 40px;
}

.portfolio__title {
    font-family: 'Merriweather', sans-serif;
    font-size: 46px;
    text-align: center;
    color: black;
}

.portfolio__projects-title {
    margin-top: 10px;
    margin-bottom: 40px;
    font-family: 'Merriweather', sans-serif;
    font-size: 26px;
    color: #ff0000;
    text-align: center;
    border-top: 1px solid #ff0000;
    border-bottom: 1px solid #ff0000;
}

.portfolio__projects {
    display: flex;
    flex-wrap: wrap;
}

.portfolio__projects > div + div {
    margin-left: 57px;
}

.portfolio-item:nth-child(4),
.portfolio-item:nth-child(7) {
    margin-left: 0;
}

.portfolio-item {
    margin-bottom: 30px;
    flex-basis: 30%;
    text-align: center;
    box-shadow: 3px 4px 10px rgba(0, 0, 0, 0.1);
}

.portfolio-item__img {
    margin-bottom: 17px;
}

.portfolio-item__img img {
    max-width: 100%;
    box-shadow: 3px 4px 10px rgba(0, 0, 0, 0.1);
    cursor: pointer;
}

.portfolio-item__img img:focus {
    position: fixed;
    top: 50%;
    left: 50%;
    z-index: 31;
    width: 80%;
    height: auto;
    outline: none;
    pointer-events: none;
    -webkit-transform: translate(-50%, -50%);
    transform: translate(-50%, -50%);
    -moz-user-select: none;
    user-select: none;
}

.portfolio-item__img img:focus ~ .overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 30;
    background: rgba(52, 60, 78, 0.9);
}

.portfolio-item__content {
    padding: 0 10px;
}

.portfolio-item__title {
    margin-bottom: 20px;
    font-size: 20px;
    line-height: normal;
}

.portfolio-item__title a {
    color: #000;
    border-bottom: 1px solid #000;
}

.portfolio-item__title a:nth-child(3) {
    font-size: 16px;
}

.portfolio-item__title a:hover {
    color: #0052c2;
    border-bottom: 1px solid #0052c2;
}

.portfolio-item__descr p {
    margin-top: 0;
    margin-bottom: 15px;
}

.last {
    margin: 0 auto;
}

.lavlabel-title {
    margin-bottom: -8px;
}

.training-projects {
    margin-top: 30px;
}

.btn__link {
    display: inline-block;
    margin: 0 auto;
    padding: 8px 23px;
    border: 2px solid #343c4e;
    border-radius: 50px;
    font-weight: 700;
    letter-spacing: 1.6px;
    text-transform: uppercase;
    color: #343c4e;
    box-shadow: 3px 4px 10px rgba(0, 0, 0, 0.5);
}

.btn__link:hover {
    background-color: #343c4e;
    color: #fff;
}

.btn__link-back {
    display: block;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background-color: #343c4e;
    position: fixed;
    bottom: 5%;
    transform: translateX(-5%);
    left: 3%;
    box-shadow: 3px 4px 10px rgba(0, 0, 0, 0.5);
}

.btn__link-back span,
.btn__link-back span::before,
.btn__link-back span::after {
    position: absolute;
    top: 50%;
    margin-top: -1px;
    left: 50%;
    margin-left: -10px;
    width: 20px;
    height: 2px;
    background-color: #fff;
}

.btn__link-back span::before,
.btn__link-back span::after {
    content: '';
    display: block;
}

.btn__link-back span::before {
    transform: rotate(-35deg);
    width: 10px;
    transform-origin: left bottom;
}

.btn__link-back span::after {
    transform: rotate(35deg);
    width: 10px;
    transform-origin: left top;
}

/* -------------------------------------------------
	Footer
   ------------------------------------------------- */
footer {
    padding: 50px 0;
    background-color: #061634;
    color: #6479a2;
}

.footer__content-inner {
    display: flex;
    justify-content: space-around;
    align-items: center;
    text-align: center;
}

footer p {
    margin-top: 0;
    margin-bottom: 15px;
}

.footer__name {
    margin-bottom: 10px;
    font-family: 'Merriweather', sans-serif;
    font-size: 28px;
    line-height: normal;
    color: #fff;
}

.footer__socials-icons {
    font-size: 32px;
}

.footer__socials-icons a {
    margin-right: 30px;
    color: #fff;
}

.footer__socials-icons a:last-child {
    margin-right: 0;
}

.footer__socials-icons a:hover {
    color: #ffe400;
}

/*	-------------------------------------------------
	 Media
	------------------------------------------------- */
@media (max-width: 1160px) {
    .container {
        width: 100%;
    }

    /*<----- Portfolio ----->*/
    .portfolio__projects {
        justify-content: space-around;
    }

    .portfolio__projects > div + div {
        margin-left: 0;
    }
}

@media (max-width: 992px) {
    /*<----- Portfolio ----->*/
    .portfolio-item {
        flex-basis: 45%;
    }

    .last {
        margin: 0 0 30px 0;
    }
}

@media (max-width: 576px) {
    /*<----- Portfolio ----->*/
    .portfolio-item {
        flex-basis: 90%;
    }

    .portfolio-item__img img:focus {
        display: none;
    }

    /*<----- Footer ----->*/
    .footer__content-inner {
        flex-direction: column;
    }
}