/* Общие стили */

*, *::after,
*::before {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    font-size: 62.5%;
    scroll-behavior: smooth;
}

@media (min-width: 1800px) {
    html {
        font-size: 75%;
    }
}

body {
    font-family: "Segoe UI", Roboto, Arial, Helvetica, sans-serif;
    background: linear-gradient(135deg, #0a0b10 0%, #0f172a 30%, #1e1b4b 60%, #321e81 100%);
    background-attachment: fixed;
    min-height: 500vh;
    overflow-x: hidden;
    font-size: 1.6rem;
    color: #fff;
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
}


.container {
    max-width: 120rem;
    margin: 0 auto;
    padding: 0rem 2rem;
}

@media (max-width: 480px) {
    .container {
        max-width: 20rem ;
        padding: 0rem -1.5rem;
    }
}

/* Body */

.bg_shapes {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
    filter: blur(0.2rem);
    pointer-events: none;
}

.shape {
    position: absolute;
    background: rgba(255, 255, 255, 0.03);
    border: .1rem solid rgba(255, 255, 255, 0.05);
    box-shadow: 0 .8rem 3.2rem rgba(0, 0, 0, .2);
    will-change: transform;
    animation: float 10s ease-in-out infinite;
    transition: all 0.5s ease;
}

@keyframes float {
    0%, 100% {
        transform: translateY(0) rotate(var(--start-rotation));
    }

    50% {
        transform: translateY(-3rem) rotate(calc(var(--start-rotation) + 10deg));
    }
}

.shape:nth-child(1) {
    width: 15rem;
    height: 15rem;
    border-radius: 30% 70% 70% 70% / 30% 30% 70%;
    top: -5rem;
    left: 2rem;
    --start-rotation: 15deg
}

.shape:nth-child(2) {
    width: 20rem;
    height: 20rem;
    border-radius: 50%;
    bottom: -8rem;
    right: -5rem;
    background: rgba(255, 140, 0, 0.05);
    --start-rotation: -20deg;
    animation-delay: 2s;
}

.shape:nth-child(3) {
    width: 8rem;
    height: 8rem;
    border-radius: 1.2rem;
    top: 15%;
    right: 10%;
    --start-rotation: 45deg;
    animation-delay: 4s;
}

.shape:nth-child(4) {
    width: 12rem;
    height: 6rem;
    border-radius: 5rem;
    bottom: 25%;
    left: 5%;
    --start-rotation: -15deg;
    animation-delay: 1s;
}

.shape:nth-child(5) {
    width: 4rem;
    height: 4rem;
    border-radius: 50%;
    top: 45%;
    right: 25px;
    --start-rotation: 0deg;
    animation-delay: 1s;
}

.shape:nth-child(6) {
    width: 10rem;
    height: 10rem;
    border-radius: 2rem;
    top: 35%;
    left: 20%;
    --start-rotation: -25deg;
    animation-delay: 2.5s;
}

.shape:hover {
    opacity: 0.5;
}

@media (max-width: 768px) {
    .shape:nth-child(2) {
        width: 15rem;
        height: 15rem;
    }

    .shape:nth-child(4) {
        display: none;
    }
}

.glass {
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(2rem);
    -webkit-backdrop-filter: blur(2rem);
    border: .1rem solid rgba(255, 255, 255, 0.2);
    border-radius: 2rem;
    box-shadow: 0 .8rem 3.2rem rgba(0, 0, 0, .1);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    isolation: isolate;
    will-change: transform;
}

.glass:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(0.5rem);
    box-shadow: 0 1.5rem 4.5rem rgba(0, 0, 0, .15);
}


/* Header */

@media (max-width: 768px) {
    .glass:hover {
        transform: none;
    }
}

header {
    width: 100%;
    padding: clamp(1rem, 2vw, 2rem);
    position: relative;
    z-index: 2000;
    transition: all 0.4 ease;
}

header.scrolled {
    position: fixed;
    top: -1rem;
    left: 0;
    right: 0;
    padding: 0.8rem 0rem;
    z-index: 5000;
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem 3rem;
}

@media (max-width: 768px) {
    nav.glass {
        padding: 1rem 2rem;
    }
}

header.scrolled nav.glass {
    border-radius: 0 0 2rem 2rem;
    background: rgba(10, 11, 16, 0.85);
    border-top: none;
    box-shadow: 0 1rem 3rem rba(0, 0, 0, .3);
}

.logo {
    display: flex;
    align-items: center;
    gap: 1.2rem;
    font-size: clamp(2rem, 3vw, 2.6rem);
    font-weight: 700;
    color: #fff;
    text-transform: uppercase;
    letter-spacing: .1rem;
    cursor: pointer;
    position: relative;
    z-index: 6000;
    user-select: none;
}

.logo-icon {
    width: clamp(3.5rem, 5vw, 4.5rem);
    height: clamp(3.5rem, 5vw, 4.5rem);
    display: flex;
    justify-content: center;
    align-items: center;
}

.logo-icon svg {
    width: 100%;
    height: 100%;
    filter: drop-shadow(0 0 0.8rem rgba(255, 255, 255, 0.2));
    transition: all 0.6s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.logo:hover .logo-icon svg {
    transform: rotate(180deg);
    filter: drop-shadow(0 0 1.2rem rgba(255, 140, 0, 0.6));
}

.logo:hover span {
    text-shadow: 0 0 2.5rem rgba(255, 255, 255, 0.4);
}

@media (max-width: 480px) {
    .logo {
        gap: 0.8rem;
    }
}

.nav-links {
    display: flex;
    gap: 1rem;
    align-items: center;
    transition: all 0.4s;
}

.nav-links a {
    text-decoration: none;
    color: rgba(255, 255, 255, 0.8);
    font-size: 1.5rem;
    font-weight: 500;
    padding: 1rem 2rem;
    border-radius: 1rem;
    transition: all .3s;
}

.nav-links a:hover,
.nav-links a.active {
    color: #fff;
    background: rgba(255, 255, 255, 0.1);
}

@media (max-width: 768px) {
    .nav-links {
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        width: 100%;
        height: 100vh;
        background: rgba(10, 11, 16, 0.98);
        backdrop-filter: blur(2rem);
        flex-direction: column;
        justify-content: center;
        align-items: center;
        gap: 3rem;
        opacity: 0;
        visibility: hidden;
        transform: translateY(-5rem);
        transition: 0.4s ease-in-out;
    }

    .nav-links.mobile-active {
        opacity: 1;
        visibility: visible;
        transform: translateY(0rem);

    }
}

.menu-toggle {
    display: none;
    flex-direction: column;
    justify-content: space-between;
    width: 3rem;
    height: 2.2rem;
    cursor: pointer;
    position: relative;
    z-index: 10001;
}

@media (max-width: 768px) {
    .menu-toggle {
        display: flex;
        max-width: 1.5rem;
    }
}


.menu-toggle {
    width: 30px;
    height: 24px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    cursor: pointer;
    position: relative;
}


.menu-toggle .bar {
    width: 100%;
    height: 4px;
    background-color: #fff;
    transition: all 0.3s ease-in-out;
    display: block;
    border-radius: 2px;
}


.menu-toggle.is-active .bar:nth-child(1) {
    transform: translateY(10px) rotate(45deg);
}


.menu-toggle.is-active .bar:nth-child(2) {
    opacity: 0;
    transform: translateX(-20px);
}


.menu-toggle.is-active .bar:nth-child(3) {
    transform: translateY(-10px) rotate(-45deg);
}


.menu-toggle:hover .bar {
    box-shadow: 0 0 .8rem rgba(255, 255, 255, 0.5);
}


.menu-toggle {
    display: none;
    flex-direction: column;
    justify-content: space-between;
    width: 30px;
    height: 24px;
    cursor: pointer;
}


@media screen and (max-width: 768px) {
    .menu-toggle {
        display: flex;
    }

    .scrolled {
        max-width: 85%;
        justify-content: center;
    }
}

.menu-toggle .bar {
    width: 100%;
    height: 4px;
    background-color: #fff;
    transition: all 0.3s ease-in-out;
}

.menu-toggle.is-active .bar:nth-child(1) {
    transform: translateY(10px) rotate(45deg);
}

.menu-toggle.is-active .bar:nth-child(2) {
    opacity: 0;
    transform: translateX(-20px);
}

.menu-toggle.is-active .bar:nth-child(3) {
    transform: translateY(-10px) rotate(-45deg);
}

/* Home section */

.page {
    padding: clamp(3rem, 5vw, 4rem) 2rem 2rem;
    scroll-margin-top: 10rem;
}

.container {
    max-width: 120em;
    margin: 0 auto;
    padding: 0rem 2rem;
    width: 100%;
}

.container-wrapper {
    min-height: calc(100vh - 30rem);
    display: flex;
    flex-direction: column;
}

.hero {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: clamp(2rem, 5vw, 4rem);
    align-items: center;
    padding: clamp(3rem, 8vw, 6rem) clamp(2rem, 5vw, 4rem);
    margin-bottom: 4rem;
}

@media (max-width: 768px) {
    .hero {
        grid-template-columns: 1fr;
        text-align: center;
    }
}

.hero .hero-image {
    display: flex;
    justify-content: center;
    align-items: center;
}

.hero .hero-image img {
    width: 100%;
    max-width: 44rem;
    height: auto;
    border-radius: 2rem;
    box-shadow: 0 1.5rem 3.5rem rgba(0, 0, 0, .2);
}

.hero .hero-content {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.hero .hero-content h2 {
    font-size: clamp(2.8rem, 5vw, 4.5rem);
    margin-bottom: 2rem;
    line-height: 1.2;
    text-shadow: 0 .4rem 1.5rem rgba(0, 0, 0, .2);
}

.hero .hero-content p {
    font-size: clamp(1.6rem, 2vw, 1.8rem);
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 3rem;
    line-height: 1.6;
}

@media (max-width: 768px) {
    .hero .hero-content {
        align-items: center;
    }
}

.cta-button {
    display: inline-block;
    padding: 1.5rem 4rem;
    background: rgba(255, 255, 255, 0.2);
    color: #fff;
    text-decoration: none;
    border-radius: 5rem;
    font-weight: 600;
    font-size: 1.6rem;
    border: .2rem solid rgba(255, 255, 255, 0.3);
    transition: all .3s ease;

    &:hover {
        background: rgba(255, 255, 255, 0.3);
        transform: translateY(-.3rem);
        box-shadow: 0 1rem 2.5rem rgba(0, 0, 0, .2);
    }
}

/* Section features */

.features {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(35rem, 1fr));
    gap: 3rem;
    margin-bottom: 4rem;

}

.feature-card {
    padding: 4rem 3rem;
    text-align: center;
    color: #fff;
}

.feature-card .feature-icon {
    width: 6rem;
    height: 6rem;
    margin: 0 auto 2rem;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 2.4rem;
}

.feature-card h3 {
    font-size: 2.2rem;
    margin-bottom: 1.5rem;
    color: #fff;
}

.feature-card p {
    font-size: 1.5rem;
    color: rgba(255, 255, 255, 0.8);
    line-height: 1.6;
}

/* about section */

.about-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: clamp(2rem, 5vw, 4rem);
    align-items: center;
    margin-bottom: 4rem;
}

@media (max-width: 768px) {
    .about-content {
        grid-template-columns: 1fr;
        text-align: center;
    }
}

.about-content .about-text {
    padding: clamp(2rem, 5vw, 4rem);
}

.about-content .about-text h2 {
    font-size: clamp(2.5rem, 4vw, 3.5rem);
    margin-bottom: 2rem;
    text-shadow: 0 0.2rem 1rem rgba(0, 0, 0, .3);
}

.about-content .about-text p {
    font-size: clamp(1.6rem, 2vw, 1.8rem);
    line-height: 1.8;
    color: rgba(255, 255, 255, 0.9);
}

.stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(25rem, 1fr));
    gap: 3rem;
    margin-bottom: 6rem;
}

.stats .stat-card {
    text-align: center;
    padding: 3rem;
    color: #fff;
}

.stats .stat-card .stat-number {
    font-size: clamp(3rem, 5vw, 4.5rem);
    font-weight: bold;
    color: #ff8c00;
    text-shadow: 0 0.2rem 1.5rem rgba(255, 140, 0, 0.3);
}

.stats .stat-card .stat-number .stat-label {
    font-size: 1.6rem;
    color: rgba(255, 255, 255, 0.8);
    margin-top: 1rem;
    text-transform: uppercase;
    letter-spacing: 0.1rem;
}

/* Skills section */

.skill-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(35rem, 1fr));
    gap: clamp(2rem, 4vw, 3rem);
    margin-bottom: 4rem;
}

@media (max-width: 480px) {
    .skill-grid {
        grid-template-columns: 1fr;
    }
}

.skill-grid .skills-card {
    padding: clamp(2.5rem, 5vw, 4rem);
    display: flex;
    flex-direction: column;
    min-height: 100%;
}

.skill-grid .skills-card .skill-header {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-bottom: 2rem;
    font-size: 2.6rem;
    margin-right: 1.8rem;
    transition: all .4s;
}

.skills-card .skill-header .skill-icon {
    width: 5.5rem;
    height: 5.5rem;
    background: rgba(255, 255, 255, 0.1);
    border: 0.1rem solid rgba(255, 255, 255, 0.15);
    border-radius: 1.2rem;
    display: flex;
    justify-content: center;
    align-items: center;
}

.skills-card h3 {
    font-size: clamp(1.8rem, 2.5vw, 2.2rem);
    font-weight: 600;
    color: #fff;
    letter-spacing: 0.05rem;
}

.skills-card p {
    font-size: 1.5rem;
    line-height: 1.7;
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 2.5rem;
}

.skills-card .skill-list {
    list-style: none;
    margin-top: auto;
    padding-top: 2rem;
    border-top: .1rem solid rgba(255, 255, 255, 0.1);
}

.skills-card .skill-list li {
    font-size: 1.4rem;
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 1.2rem;
    padding-left: 2.5rem;
    position: relative;
    display: flex;
    align-items: center;
    transition: transform .2s ease;
}

.skills-card .skill-list li::before {
    content: '→';
    position: absolute;
    left: 0;
    color: #ff8c00;
    font-weight: bold;
}

.skills-card .skill-list li {
    font-size: 1.4rem;
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 1.2rem;
    padding-left: 2.5rem;
    position: relative;
    display: flex;
    align-items: center;
    transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    will-change: transform;
}


.skills-card .skill-icon {
    transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1),
        background 0.5s ease;
    will-change: transform;
}

.skills-card .skill-list li:hover {
    transform: translateX(0.8rem);
}

.skills-card:hover .skill-icon {
    transform: scale(1.1) rotate(-8deg);
    background: rgba(255, 255, 255, 0.2);
}

/* Project section */

.projects-orbit-wrapper {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 70rem;
    padding: 5rem 0rem;
}

.orbit-container {
    width: 50rem;
    height: 50rem;
    border-radius: 50%;
    border: .2rem dashed rgba(255, 255, 255, 0.1);
    display: grid;
    place-content: center;
    position: relative;
}

.orbit-center {
    position: relative;
    grid-area: 1/1;
    width: 15rem;
    height: auto;
    max-width: 100%;
    aspect-ratio: 1 / 1;

    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;

    justify-self: center;
    align-self: center;

    color: #ff8c00;
    box-shadow: 0 0 3rem rgba(255, 140, 0, 0.2);
    border: .2rem solid rgba(255, 140, 0, 0.3);
    z-index: 2;
}


.orbit-container .item {
    grid-area: 1/1;
    width: 12rem;
    height: 12rem;
    border-radius: 50%;
    animation: spin 12s var(--d, 0s) linear infinite;
    transform: rotate(0deg) translate(25rem) rotate(0deg);
    z-index: 3;
    cursor: pointer;
    transition: box-shadow 0.3s ease;
}

.orbit-container .item img {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
    transition: transform 0.3s ease, opacity 0.3s ease;
}

.orbit-container .item:hover {
    box-shadow: 0 0 3rem #ff8c00;
}

.orbit-container .item:hover img {
    opacity: 1;
    transform: scale(1.1);
}

@keyframes spin {
    0% {
        transform: rotate(0deg) translate(25rem) rotate(0deg);
    }

    100% {
        transform: rotate(1turn) translate(25rem) rotate(-1turn);
    }
}

@media (max-width: 600px) {
    .orbit-container {
        width: 8rem;
        height: 8rem;
        grid-template-columns: 8rem;
        grid-template-rows: 8rem;
    }

    .orbit-container .item {
        width: 8rem;
        height: 8rem;
        transform: rotate(0deg) translate(15rem) rotate(0deg);
    }

    @keyframes spin {
        100% {
            transform: rotate(1turn) translate(15rem) rotate(-1turn);
        }
    }
}

/* Contact section */

.contact-grid {
    display: grid;
    grid-template-columns: 1.5fr 1fr;
    gap: 3rem;
    margin-bottom: 4rem;
}

@media (max-width: 992px) {
    .contact-grid {
        grid-template-columns: 1fr;
    }
}

.contact-form, .contact-info, .contact-map {
    padding: clamp(2rem, 5vw, 4rem)
}

.contact-form, h2 .contact-info h2, .contact-map h2 {
    font-size: 2.8rem;
    margin-bottom: 3rem;
    color: #fff;
    text-shadow: 0 0.2rem 1rem rgba(255, 255, 255, 0.3);
}

.contact-form p {
    margin-bottom: 2.5rem;
}

.form-group {
    margin-bottom: 2rem;
}

.form-group label {
    display: block;
    font-size: 1.4rem;
    margin-bottom: 0.8rem;
    color: rgba(255, 255, 255, 0.8);
    letter-spacing: 0.05rem;
}

.form-group input, .form-group textarea {
    width: 100%;
    padding: 1.5rem;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 1rem;
    border: 0.1rem solid rgba(255, 255, 255, 0.1);
    color: #fff;
    font-family: inherit;
    font-size: 1.6rem;
    transition: all 0.3s ease;
}

.form-group textarea {
    min-height: 15rem;
    resize: vertical;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    background: rgba(255, 255, 255, 0.1);
    border-color: #ff8c00;
    box-shadow: 0 0 1.5rem rgba(255, 140, 0, 0.2);
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 2rem;
    margin-bottom: 3rem;
    transition: transform 0.3s;
}

.contact-item:hover {
    transform: translateX(1rem);
}

.contact-item-icon {
    font-size: 4rem;
    width: 5rem;
    height: 5rem;
    background: rgba(255, 140, 0, 0.2);
    border-radius: 1.2rem;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-shrink: 0;
    box-shadow: 0 0.4rem 1.5rem rgba(0, 0, 0, .2);
}

.contact-item-text h4 {
    font-size: 1.8rem;
    color: #fff;
    margin-bottom: 0.5rem;
}

.contact-item-text p {
    font-size: 1.5rem;
    color: rgba(255, 255, 255, 0.8);
    line-height: 1.6;
}

.contact-map-section {
    margin-bottom: 4rem;
}

.map-container {
    width: 100%;
    height: 45rem;
    background: #1a1a1a;
    border-radius: 2rem;
    overflow: hidden;
    border: 0.1rem solid rgba(255, 255, 255, 0.1);
    position: relative;
}

.google-map-iframe {
    width: 100%;
    height: 100%;
    border: none;
    filter: grayscale(100%) invert(90%) opacity(0.8);
    transition: all .3s ease;
}

.google-map-iframe:hover {
    filter: grayscale(30%) invert(90%) opacity(1);
}

/* Footer */

#footer {
    margin-top: clamp(4rem, 8vw, 6rem);
    padding: 3rem 0rem;
}

#footer .footer-content {
    padding: clamp(2rem, 5vw, 3rem);
    text-align: center;
    color: rgba(255, 255, 255, 0.8);
}

#footer .footer-links {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin-bottom: 2rem;
    flex-wrap: wrap;
}

#footer .footer-links a {
    text-decoration: none;
    color: rgba(255, 255, 255, 0.8);
    font-size: 1.4rem;
    padding: 0.5rem 1rem;
    transition: all 0.3s ease;
}

#footer .footer-links a:hover {
    color: #fff;
    transform: translateY(-.2rem);
}

#footer .copyright {
    font-size: 1.4rem;
    color: rgba(255, 255, 255, 0.8);
    border-top: 0.1rem solid rgba(255, 255, 255, 0.1);
    padding-top: 2rem;
    margin-top: 1rem;
}

/* Back to top btn */

.back-to-top {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 5.5rem;
    height: 5.5rem;
    border-radius: 1.5rem;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 4000;
    opacity: 0;
    visibility: hidden;
    transform: translateY(2rem);
    transition: all .3s ease;
}

.back-to-top.show {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.back-to-top:hover {
    background: rgba(255, 140, 0, 0.2);
    border-color: rgba(255, 140, 0, 0.5);
    transform: translateY(-0.8rem);
    box-shadow: 0 1rem 3rem rgba(255, 140, 0, 0.3);
}

.back-to-top:hover span {
    transform: scale(1.2);
    text-shadow: 0 0 1.5rem rgba(255, 255, 255, 0.5);
}

@media (max-width: 768px) {
    .back-to-top{
        width: 4.8rem;
        height: 4.8rem;
        font-size: 2rem;
    }

    .back-to-top:active {
        transform: translateY(-0.2rem) scale(0.95);
    }
}

#main-header.scrolled {
    max-width: 90%;
}

#mobile-menu {
    max-width: 90%;
}
