@import url('../fonts/raleway.css');
@import url('../fonts/jetbrains.css');

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

.hidden {
    opacity: 0;
    transform: translateY(50px);
    transition: opacity 1s ease-in-out, transform 1s ease-in-out;
}
.visible {
    opacity: 1;
    transform: translateY(0);
}

html {
    scroll-behavior: smooth
}

canvas {
    display: block;
    width: 100vw;
    height: 100vh;
    position: fixed;
    top: 0;
    left: 0;
    user-select: none;
    z-index: -1;
}

section {
    width: 100vw;
    .title {
        font-size: 48px;
        font-weight: 800;
        text-align: center;
        margin-bottom: 15px;
        background: linear-gradient(135deg, #ffffff 0%, #c724e8 100%);
        -webkit-background-clip: text;
        -webkit-text-fill-color: transparent;
        background-clip: text;
        font-family: "Raleway", sans-serif;
    }
    .subtitle {
        font-size: 18px;
        color: #b8b8b8;
        text-align: center;
        margin-bottom: 60px;
    }
}

body {
    background: #0e001e;
    background-size: 25px 25px, 25px 25px, auto;
    min-height: 100vh;
    color: #fff;
    font-family: "JetBrains", sans-serif;
}

header {
    position: fixed;
    user-select: none;
    display: flex;
    opacity: 0;
    width: 100%;
    justify-content: space-between;
    align-items: center;
    padding: 20px 50px;
    background-color: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    border-bottom-left-radius: 10px;
    border-bottom-right-radius: 10px;
    z-index: 999999;
    transition: all 0.3s;
    &.scrolled {
        opacity: 1;
    }
    .brand {
        display: flex;
        user-select: none;
        align-items: center;
        gap: 10px;
        h1 {
            font-size: 24px;
            font-weight: bold;
            background: linear-gradient(135deg, #ffffff 0%, #c724e8 100%);
            -webkit-background-clip: text;
            -webkit-text-fill-color: transparent;
            background-clip: text;
        }
        img {
            width: 40px;
            height: 40px;
            border-radius: 50%;
        }
    }
    .links {
        display: flex;
        user-select: none;
        list-style: none;
        gap: 30px;
    }
    .links a {
        color: #fff;
        text-decoration: none;
        user-select: none;
        font-size: 16px;
        transition: all 0.3s;
        position: relative;
    }

    .links a::after {
        content: '';
        position: absolute;
        bottom: -5px;
        left: 0;
        width: 0;
        height: 2px;
        background: #6f00ff;
        transition: width 0.3s;
    }

    .links a:hover::after {
        width: 100%;
    }
}

.hero {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    height: 100vh;
    gap: 20px;
    h1 {
        font-size: 80px;
        margin: 0;
        padding: 0;
        font-weight: 600;
        line-height: 1.2;
        text-align: center;
        font-family: "Raleway", sans-serif;
        background: linear-gradient(135deg, #ffffff 0%, #c724e8 100%);
        -webkit-background-clip: text;
        -webkit-text-fill-color: transparent;
        background-clip: text;
    }
    h2 {
        max-width: 500px;
        font-size: 20px;
        margin: 0;
        padding: 0;
        font-weight: 400;
        line-height: 1.2;
        text-align: center;
        color: #ababab;
    }
    .buttons {
        display: flex;
        gap: 20px;
        flex-wrap: wrap;
        justify-content: center;
        margin-top: 20px;
        user-select: none;
        a {
            padding: 15px 40px;
            text-decoration: none;
            border-radius: 50px;
            user-select: none;
            font-size: 16px;
            font-weight: bold;
            transition: all 0.3s;
            position: relative;
            overflow: hidden;
            &.purple {
                background: linear-gradient(45deg, #ff00e1, #6f00ff);
                color: #ffffff;
            }
        }
        .purple::before {
            content: '';
            position: absolute;
            top: 50%;
            left: 50%;
            width: 0;
            height: 0;
            background: rgba(255, 255, 255, 0.3);
            border-radius: 50%;
            transform: translate(-50%, -50%);
            transition: width 0.5s, height 0.5s;
        }

        .purple:hover::before {
            width: 300px;
            height: 300px;
        }

        .trs:hover {
            background: #6f00ff;
            color: #ffffff;
        }
        .trs {
            background: transparent;
            color: #ffffff;
            border: 2px solid #6f00ff;
        }
    }
}

.projects {
    padding: 50px 0;
    .prjList {
        display: flex;
        justify-content: center;
        flex-wrap: wrap;
        gap: 30px;
        place-items: center;
        margin-top: 50px;
        .card {
            background-color: rgba(255, 255, 255, 0.05);
            backdrop-filter: blur(10px);
            -webkit-backdrop-filter: blur(10px);
            border-radius: 10px;
            width: 348px;
            overflow: hidden;
            border: 2px solid rgba(255, 255, 255, 0.1);
            display: flex;
            flex-direction: column;
            align-items: center;
            gap: 20px;
            transition: all 0.3s;
            cursor: pointer;
            &::after {
                content: 'Просмотреть';
                position: absolute;
                top: 50%;
                left: 50%;
                transform: translate(-50%, -50%);
                background: rgba(170, 0, 255, 0.7);
                color: white;
                padding: 10px 20px;
                border-radius: 5px;
                opacity: 0;
                transition: opacity 0.3s ease;
            }
            img {
                width: 100%;
                height: 200px;
                object-fit: cover;
                transition: all 0.3s;
            }
            h3 {
                font-size: 40px;
                font-weight: 600;
                margin: 0;
                padding: 0;
                text-align: center;
                font-family: "Raleway", sans-serif;
                background: linear-gradient(135deg, #ffffff 0%, #c724e8 100%);
                -webkit-background-clip: text;
                -webkit-text-fill-color: transparent;
                background-clip: text;
            }
            p {
                font-size: 16px;
                font-weight: 400;
                margin: 0;
                padding: 0;
                text-align: center;
                color: #ababab;
            }
            .tags {
                display: flex;
                gap: 10px;
                flex-wrap: wrap;
                justify-content: center;
                margin: 0;
                padding: 0;
                list-style: none;
                padding: 10px 0;
                li {
                    font-size: 14px;
                    font-weight: 400;
                    margin: 0;
                    padding: 0;
                    text-align: center;
                    background-color: rgba(255, 255, 255, 0.1);
                    padding: 5px 10px;
                    border-radius: 5px;
                    color: #c724e8;
                    transition: all 0.2s ease-in-out;
                    &:hover {
                        transform: scale(1.05);
                    }
                }
            }
            &:hover {
                background-color: rgba(255, 255, 255, 0.1);
                transform: scale(1.05);
                img {
                    filter: brightness(0.75) blur(5px);
                }
                &::after {
                    opacity: 1;
                }
            }
        }
    }
}
.reviews {
    padding: 50px 0;
    .revList {
        display: flex;
        justify-content: center;
        flex-wrap: wrap;
        gap: 30px;
        place-items: center;
        margin-top: 50px;
        .card {
            background-color: rgba(255, 255, 255, 0.05);
            backdrop-filter: blur(10px);
            -webkit-backdrop-filter: blur(10px);
            border-radius: 10px;
            width: 400px;
            overflow: hidden;
            border: 2px solid rgba(255, 255, 255, 0.1);
            display: flex;
            flex-direction: column;
            padding: 20px;
            align-items: center;
            gap: 20px;
            transition: all 0.3s;
            cursor: pointer;
            .up {
                display: flex;
                gap: 10px;
                align-items: center;
                justify-content: start;
                width: 100%;
                h3 {
                    font-size: 24px;
                    font-weight: 600;
                    margin: 0;
                    padding: 0;
                    text-align: center;
                    font-family: "JetBrains", sans-serif;
                    background: linear-gradient(135deg, #ffffff 0%, #c724e8 100%);
                    -webkit-background-clip: text;
                    -webkit-text-fill-color: transparent;
                    background-clip: text;
                }
                img {
                    user-select: none;
                    width: 50px;
                    height: 50px;
                    object-fit: cover;
                    border-radius: 50%;
                }
            }
            p {
                font-size: 16px;
                font-weight: 400;
                margin: 0;
                padding: 0;
                text-align: center;
                color: #ababab;
            }
        }
    }
}

.about {
    padding: 50px 0px;
    .aboutList {
        display: flex;
        justify-content: center;
        flex-wrap: wrap;
        gap: 30px;
        place-items: center;
        margin-top: 50px;
        .text {
            width: 600px;
            display: flex;
            flex-direction: column;
            p {
                font-size: 16px;
                line-height: 1.8;
                color: #d0d0d0;
                margin-bottom: 20px;
            }
            strong {
                color: #c724e8;
                font-weight: 600;
            }
        }
        .stats {
            display: flex;
            flex-direction: column;
            gap: 30px;
            div {
                transition: all 0.3s;
                background: rgba(26, 13, 46, 0.6);
                border: 1px solid rgba(199, 36, 232, 0.2);
                backdrop-filter: blur(2px);
                border-radius: 15px;
                padding: 25px;
                text-align: center;
                &:hover {
                    box-shadow: 0 10px 40px rgba(199, 36, 232, 0.3);
                }
                h1 {
                    display: block;
                    font-size: 48px;
                    font-weight: 900;
                    color: #c724e8;
                    margin-bottom: 10px;
                }
                h2 {
                    font-size: 14px;
                    color: #b8b8b8;
                }
            }
        }
    }
}

.contacts {
    padding: 50px 0;
    .contactsList {
        display: flex;
        justify-content: center;
        flex-wrap: wrap;
        gap: 30px;
        place-items: center;
        margin-top: 50px;
        a {
            background: rgba(26, 13, 46, 0.6);
            border: 1px solid rgba(199, 36, 232, 0.2);
            border-radius: 20px;
            padding: 40px 30px;
            text-align: center;
            text-decoration: none;
            color: #ffffff;
            transition: all 0.3s;
            &:hover {
                transform: translateY(-10px);
                border-color: rgba(199, 36, 232, 0.6);
            }
            h1 {
                font-size: 22px;
                font-weight: 700;
                margin-bottom: 10px;
            }
            p {
                font-size: 15px;
                color: #b8b8b8;
            }
        }
    }
}

.skills {
    padding: 50px 0;
    .skillsList {
        display: flex;
        justify-content: center;
        flex-wrap: wrap;
        gap: 30px;
        place-items: center;
        margin-top: 50px;
        .card {
            background: rgba(26, 13, 46, 0.6);
            border: 1px solid rgba(199, 36, 232, 0.2);
            backdrop-filter: blur(2px);
            border-radius: 15px;
            padding: 25px;
            text-align: center;
            transition: all 0.3s;
            &:hover {
                box-shadow: 0 10px 40px rgba(199, 36, 232, 0.3);
            }
            h3 {
                font-size: 28px;
                font-weight: 700;
                margin-bottom: 10px;
            }
            p {
                font-size: 15px;
                color: #b8b8b8;
            }
        }
    }
}

footer {
    background: #0d022144;
    backdrop-filter: blur(2px);
    padding: 30px 50px;
    text-align: center;
    border-top: 1px solid rgba(199, 36, 232, 0.2);
}

footer p {
    font-size: 14px;
    color: #b8b8b8;
}

::selection {
    -webkit-text-fill-color: inherit;
    color: inherit;
    -moz-text-fill-color: inherit;
    background-color: rgba(238, 132, 252, 0.2);
}

::-moz-selection {
    -webkit-text-fill-color: inherit;
    color: inherit;
    -moz-text-fill-color: inherit;
    background-color: rgba(238, 132, 252, 0.2);
}

@media screen and (max-width: 768px) {
    .hero h1 { font-size: 60px; }
    .hero h2 { font-size: 15px;  max-width: 300px; }
    .hero .buttons a { padding: 10px 20px; font-size: 14px; }
    header .brand { font-size: 30px; }
    header { justify-content: center;}
    header .links { display: none; width: 0; }
    .projects .title { font-size: 30px; }
    .projects .subtitle { font-size: 15px; }
    .reviews .title { font-size: 30px; }
    .reviews .subtitle { font-size: 15px; }
    .reviews .reviewsList .card { width: 100%; }
    .about .title { font-size: 30px; }
    .about .subtitle { font-size: 15px; }
    .about .aboutList .text { width: 90%; }
    .about .aboutList .stats { width: 90%; }
}