/*
font-family: 'Courgette', cursive;
font-family: 'Montserrat', sans-serif;
*/

*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    min-height: 100vh;
    font-size: 26px;
    max-width: 100vw;
    font-family: 'Caveat Brush', Caveat;
}

body {
    min-height: 100%;
    display: grid;
    grid-template-columns: auto;
    grid-template-rows: max-content 1fr max-content;
    grid: "header""main""footer";
    min-width: 360px;
    overflow-x: hidden;
}

/* header begin */
header {
    height: 80px;
    max-width: min(1024px, 90%);
    margin: 0 auto;
    width: 100%;
    grid-area: header;
    display: flex;
    flex-direction: row;
    align-items: center;
    position: relative;
}

.logo {
    font-family: 'Caveat Brush', cursive;
    font-size: 30px;
    color: #131936;
}

nav,
.nav-icon {
    margin-left: auto;
}

nav ul {
    display: flex;
    list-style: none;
    gap: 3em;
    font-weight: 600;
    font-size: 0.8rem;
}

nav a {
    text-decoration: none;
    color: #080A20;
}

nav a:hover {
    color: #080A20;

}

.nav-icon {
    display: none;
}

.nav-icon img {
    width: 24px;
}

/* header end */
/* main begin */
.align-center {
    display: flex;
    align-items: center;
    width: 100%;
    max-width: min(1024px, 90%);
    margin: 0 auto;
    padding-bottom: 2rem;
}

.gray-bg {
    box-shadow: 0 -3px 5px 0px #59485925, 0 4px 5px 0px #59485925;
    background-color: #f7f1f7;
}

main {
    grid-area: main;
    width: 100%;
}

.container {
    display: flex;
    align-items: center;
    gap: 40px;
    font-size: clamp(1rem, 1.5vw, 1rem);
    flex-wrap: wrap;
    justify-content: center;
}

.about-text {
    margin-left: calc(100% / 12);
    display: flex;
    flex-direction: column;
}

.portrait {
    padding-top: 2rem;
    width: max(40%, 300px);
    float: left;
}

h1 {
    margin: 0 auto;
    padding: 2rem 0;
    font-weight: 800;
    font-size: clamp(1rem, 5vw, 1.5rem);
    text-align: center;
    max-width: min(1024px, 90%);
    color: #695F69;
}

.about h1 {
    text-align: left;
    margin: 0;
}

.about a {
    margin: 2em 0;
    padding: 0.5em 1.5em;
    text-decoration: none;
    font-weight: 600;
    border-radius: 10px;
    background-color: #000080;
    width: max-content;
    color: white;
    transition: 300ms ease 150ms;
    font-size: clamp(0.8rem, 2vw, 1rem);
}

.about a:hover {
    background-color: #454078;
    box-shadow: 0 3px 5px 0 #695f6990;
    transition: 300ms ease;

}

.skill {
    display: flex;
    align-items: center;
    margin: 1em 0;
    width: clamp(280px, calc(100% / 4), 90%);
    height: 50px;
}
.contacts.skill{
    
            display: flex;
            align-items: center;
            width: 50px;
            height: 50px;
}
.icon-container {
    display: flex;
    justify-content: center;
    align-items: center;
    border-radius: 50%;
    background-color: #454078;
    margin-right: 0.5em;
    border: 1px solid #454078;
    width: 60px;
    height: 60px;
}

#contacts .align-center {
    flex-direction: row;
}

.skill img {
    width: 30px;
    margin: 0.7rem;
}

.skill-caption {
    display: flex;
    flex-direction: column;
    width: 100%;
    transform: translateY(-10px);
}

.skill-name {
    font-weight: 800;
    margin-bottom: 0.5em;
}

.skill-level {

    border: 1px solid #000080;
    height: 10px;
    border-radius: 5px;
    position: relative;
    z-index: 1;
}

.range {
    height: 8px;
    border-radius: 4px;
    position: absolute;
    top: 0;
    left: 0;
    background-color: #3A4CA9;
}

/* main end */
/* галерея починається */

.portfolio a {
    width: clamp(300px, 30%, 400px);
    height: 200px;
    overflow: hidden;
    border-radius: 10px;
    position: relative;
}

a figcaption {
    position: absolute;
    bottom: 0;
    border-radius: 10px;
    background-color: rgba(0, 0, 0, 0.70);
    height: auto;
    width: 100%;
    transform: translateY(0);
    padding: 0.5rem 0.8rem;
    color: white;
    transition: all 300ms ease 150ms;
}

a img {
    width: 100%;
    transform: translateY(0) scale(100%, 100%);
    transition: all 300ms ease 150ms;
}

#portfolio h2 {
    font-size: 1rem;
    font-weight: 600;
    padding-bottom: 0.2rem;
}

a:hover figcaption {
    background-color: rgba(0, 0, 0, 0.40);
    transform: translateY(43%);
    transition: all 150ms ease;
}

a:hover img {
    transform: translateY(-10%) scale(110%, 110%);
    transition: all 300ms ease;
}

/* галерея закінчилась*/

/* підвал */
footer nav {
    margin: 2rem auto 0;
}

footer .container {
    flex-direction: column;
}

footer .copyright {
    margin-top: 1rem;
    font-size: 0.7rem;
    color: #695F69;
}
/* підвал */
@media only screen and (max-width: 650px) {

    /* header begin */
    .nav-icon {
        display: block;
    }

    #nav {
        visibility: hidden;
        opacity: 0;
        margin: 0;
        padding: 2em;
        box-shadow: 0px 2px 3px #131936;
        position: absolute;
        top: 80px;
        right: 0;
        width: auto;
        background-color: white;
        border-radius: 10px;
        transition: all 300ms ease;
    }

    #nav.show {
        visibility: visible;
        opacity: 100;
        top: 100px;
        transition: all 300ms ease;
    }

    nav ul {
        flex-direction: column;
        row-gap: 2em;
    }
    /* footer in media*/
footer nav {
	display: none;
}

/* footer in media*/
    /* main begin */
    .align-center {
        flex-direction: column;
        align-items: center;
        row-gap: 20px;
    }

    .about-text {
        align-items: center;
        margin: 0;
    }

    .about-text h1 {
        padding-top: 0;
    }

    .about a {
        width: max(50%, 200px);
        text-align: center;
    }

    .contacts.align-center{
        flex-direction: row;
    }
    /* main end */
}
    /* header end */