:root {
    --error: #ef4444;
    --success: #10b981;
    --gray: #6b7280;
    --light-gray: #f3f4f6;
    --primary: #602aa5;
    --primary-light: #8f9bcd;
    --text-dark: #121212;
    --text-light: whitesmoke;
    --section-padding: 4rem 1.25rem;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: "Montserrat", sans-serif;
    color: var(--text-light);
    font-weight: normal;
}

body {
    min-height: 100vh;
    background: var(--text-dark);
    perspective: 1000px;
    overflow-x: hidden;
    transition: background-color 0.5s ease;
}
.body-bg-changed {
    background: -webkit-linear-gradient(left, #602aa5 39%, #ff3366 56.75%);
    background: -o-linear-gradient(left, #602aa5 39%, #ff3366 56.75%);
    background: linear-gradient(44.91deg, #602aa5 39%, #ff3366 56.75%);
}
section {
    padding: var(--section-padding);
    position: relative;
}

.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1.25rem;
}
header {
    position: sticky;
    top: 0;
    left: 0;
    padding: 6px 0px;
    z-index: 999;
    background: black;
}

/* Header styles */
.header-container {
    margin-top: 1rem;
    display: grid;
    grid-template-columns: auto 1fr;
    align-items: center;
    gap: 1.5rem;
    padding: 0 1.25rem;
}

header nav ul {
    list-style: none;
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 1rem;
}

header nav ul li a {
    font-size: 1rem;
    line-height: 1.5;
    font-weight: 600;
    display: block;
    text-decoration: none;
    color: var(--text-light);
    text-transform: uppercase;
    padding: 0.5rem;
    transition: color 0.4s ease-in-out;
}

header nav ul li a:hover {
    color: var(--primary);
}

.mobile-menu-button {
    display: none;
    background: none;
    border: none;
    color: var(--text-light);
    font-size: 1.5rem;
    cursor: pointer;
}

/* Button styles */
button {
    border: none;
    outline: none;
    border-radius: 5px;
    background: var(--primary);
    font-size: 16px;
    font-weight: 300;
    letter-spacing: 1px;
    padding: 0.75rem 1.5rem;
    cursor: pointer;
    margin-top: 1rem;
    transition: background-color 0.3s ease;
}

button:hover {
    background-color: var(--primary-light);
}

/* Typography */
h1,
h2,
h3 {
    line-height: 1.3;
    font-weight: bolder;
    margin-bottom: 1rem;
}

h1 {
    font-size: clamp(1rem, 4.3vw, 2.3rem);
}

h2 {
    font-size: clamp(1rem, 3vw, 1.4rem);
    margin-bottom: 2rem;
    text-align: center;
}

h3 {
    font-size: clamp(0.7rem, 2.5vw, 1.2rem);
}

.accent {
    font-weight: 600;
    font-size: 1.375rem;
    color: var(--primary-light);
}

.accent_2 {
    text-decoration: underline;
    text-decoration-color: var(--primary);
    text-decoration-thickness: 2px;
}

.list {
    padding: 10px;
    line-height: 1.5;
}

.clip-text {
    font-weight: 900;
    background: linear-gradient(45deg, #ff3366, #4a00e0, #00d2ff);
    animation: gradient 5s ease infinite;
    color: transparent;
    -webkit-background-clip: text;
    background-clip: text;
    text-align: start;
    margin: 0;
    background-size: 200% 200%;
}

@keyframes gradient {
    0% {
        background-position: 0% 50%;
    }

    50% {
        background-position: 100% 50%;
    }

    100% {
        background-position: 0% 50%;
    }
}

.logo {
    width: 100%;
    max-width: 280px;
    height: auto;
}

/* Banner styles */
.banner-top {
    overflow: hidden;
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
    padding: 2rem 0;
}

.banner-top_text {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    text-align: center;
    padding: 0 12px;
}

.banner-top_text strong {
    display: block;
    margin: 0.25rem 0;
    font-size: 1.375rem;
    padding: 0 12px;
}

.parallax-container {
    right: -100%;
    top: 250px;
    position: absolute;
    width: 100%;
    height: auto;
    transform-style: preserve-3d;
    z-index: -1;
}

.funnel {
    position: relative;
    width: 100%;
    max-width: 400px;
    height: auto;
    margin: 0 auto;
}

/* Text rotator */
.text-rotator {
    font-size: 3.5rem;
    font-weight: bold;
    height: 18.5rem;
    overflow: hidden;
    position: relative;
}

.rotating-text {
    display: flex;
    position: relative;
    white-space: nowrap;
}

.rotating-text span {
    display: inline-block;
    position: absolute;
    left: 0;
    top: 0;
    opacity: 0;
    transform: translateY(20px);
    animation: rotateWord 12s linear infinite;
}

.rotating-text span:nth-child(1) {
    animation-delay: 0s;
    color: #ff3366;
}

.rotating-text span:nth-child(2) {
    animation-delay: 3s;
    color: #4a00e0;
}

.rotating-text span:nth-child(3) {
    animation-delay: 6s;
    color: #00d2ff;
}

.rotating-text span:nth-child(4) {
    animation-delay: 9s;
    color: #ff9a00;
}

@keyframes rotateWord {
    0% {
        opacity: 0;
        transform: translateY(20px);
    }

    2% {
        opacity: 1;
        transform: translateY(0px);
    }

    18% {
        opacity: 1;
        transform: translateY(0px);
    }

    20% {
        opacity: 0;
        transform: translateY(-20px);
    }

    100% {
        opacity: 0;
        transform: translateY(-20px);
    }
}

.static-text {
    display: inline-block;
}

/* About section */
.about-container {
    display: flex;
    align-items: flex-start;
    gap: 2rem;
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem;
    background-color: rgba(31, 31, 31, 0.8);
    border-radius: 1rem;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
}

.photo-container {
    flex-shrink: 0;
    width: 250px;
    height: 250px;
    border-radius: 50%;
    overflow: hidden;
    border: 5px solid var(--primary);
    box-shadow: 0 4px 20px rgba(96, 42, 165, 0.3);
}

.photo {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    transition: transform 0.3s ease;
}

.photo:hover {
    transform: scale(1.05);
}

.description {
    flex-grow: 1;
}

.description h2 {
    margin-top: 0;
    color: var(--text-light);
    font-size: 1.4rem;
    text-align: left;
}
.citata {
    text-align: end;
    font-size: 16px!important;
}
.description p {
    color: var(--text-light);
    line-height: 1.6;
    opacity: 0.9;
    margin-bottom: 1rem;
    font-size: 1rem;
}

/* Skills sections */
.triangle-wrapper {
  position: absolute;
  top: 0;
  left: 10px;
  transform: translate(-50%, -50%);
  width: 40vw; /* Адаптивный размер */
  height: 40vw;
  min-width: 50px; /* Минимальный размер */
  min-height: 50px;
  z-index: -1;
}

.rotating-triangle {
  width: 100%;
  height: 100%;
  animation: rotate 20s linear infinite;
  transform-origin: center center; /* Вращение вокруг геометрического центра */
}

@keyframes rotate {
  from {
    transform: rotate(0deg);
  }
  to {
    transform: rotate(360deg);
  }
}

/* Адаптация для мобильных */
@media (max-width: 768px) {
  .triangle-wrapper {
    width: 65vw;
    height: 65vw;
  }
}

.skills-section {
    position: relative;
    background-color: rgba(18, 18, 18, 0.9);
    border-radius: 1rem;
    padding: 2rem;
    margin-bottom: 3rem;
}

.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1.5rem;
    margin-top: 2rem;
}

.skill-card {
    background: rgba(31, 31, 31, 0.8);
    border-radius: 0.75rem;
    padding: 1.5rem;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border-left: 4px solid var(--primary);
}

.skill-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(96, 42, 165, 0.2);
}

.skill-card h3 {
    color: var(--primary-light);
    margin-bottom: 0.75rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.skill-card p {
    color: var(--text-light);
    opacity: 0.8;
    line-height: 1.6;
    font-size: 0.8rem;
}

.skill-icon {
    max-width: 48px;
}

/* Portfolio section */
.portfolio-section {
    background-color: rgba(18, 18, 18, 0.9);
    padding: 3rem 0;
}

.swiper {
    width: 100%;
    padding: 2rem 0;
}

.portfolio-card {
    background: rgba(31, 31, 31, 0.8);
    border-radius: 0.75rem;
    overflow: hidden;
    transition: transform 0.3s ease;
    height: auto;
    display: flex;
    flex-direction: column;
}

.portfolio-card:hover {
    transform: scale(1.03);
}

.portfolio-image {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.portfolio-content {
    padding: 1.5rem;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.portfolio-content h3 {
    color: var(--primary-light);
    margin-bottom: 0.5rem;
}

.portfolio-content p {
    color: var(--text-light);
    opacity: 0.8;
    margin-bottom: 1rem;
    flex-grow: 1;
    font-size: 0.8rem;
}

.portfolio-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.tag {
    background-color: var(--primary);
    color: var(--text-light);
    padding: 0.25rem 0.75rem;
    border-radius: 1rem;
    font-size: 0.75rem;
    font-weight: 500;
}

.portfolio-link {
    display: inline-block;
    color: var(--primary-light);
    text-decoration: none;
    font-weight: 600;
    margin-top: auto;
    transition: color 0.3s ease;
}

.portfolio-link:hover {
    color: var(--primary);
}

.swiper-pagination-bullet {
    background: var(--text-light);
    opacity: 0.5;
}

.swiper-pagination-bullet-active {
    background: var(--primary);
    opacity: 1;
}

/* Form styles */
.form-container {
    background: rgba(31, 31, 31, 0.9);
    border-radius: 1rem;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
    width: 100%;
    max-width: 500px;
    margin: 0 auto;
    padding: 2rem;
    transition: all 0.3s ease;
}

.form-container:hover {
    box-shadow: 0 10px 25px rgba(96, 42, 165, 0.3);
}

.form-group {
    margin-bottom: 1.25rem;
    position: relative;
}

label {
    display: block;
    color: var(--text-light);
    font-size: 0.875rem;
    font-weight: 500;
    margin-bottom: 0.5rem;
    opacity: 0.9;
}

input,
textarea {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 1px solid rgba(209, 213, 219, 0.2);
    border-radius: 0.5rem;
    font-size: 1rem;
    transition: all 0.2s;
    color: var(--text-light);
    background-color: rgba(18, 18, 18, 0.7);
}

input:focus,
textarea:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(96, 42, 165, 0.3);
}

input.error,
textarea.error {
    border-color: var(--error);
}

.error-message {
    color: var(--error);
    font-size: 0.75rem;
    margin-top: 0.25rem;
    display: none;
}

.btn {
    border: none;
    border-radius: 0.5rem;
    padding: 0.75rem 1.5rem;
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    width: 100%;
    transition: all 0.2s;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.5rem;
    background-color: var(--primary);
    color: var(--text-light);
}

.btn:hover {
    background-color: var(--primary-light);
}

.btn:disabled {
    background-color: var(--gray);
    cursor: not-allowed;
}

.success-message {
    display: none;
    background-color: rgba(16, 185, 129, 0.1);
    border: 1px solid var(--success);
    color: var(--success);
    padding: 1rem;
    border-radius: 0.5rem;
    margin-top: 1.25rem;
    text-align: center;
}

.social-links {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-top: 1.5rem;
}

.social-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.5rem;
    height: 2.5rem;
    border-radius: 50%;
    background-color: var(--primary);
    color: var(--text-light);
    transition: all 0.2s;
    text-decoration: none;
}

.social-link:hover {
    background-color: var(--primary-light);
    transform: scale(1.1);
}

.phone-prefix {
    position: absolute;
    left: 1rem;
    top: 2.25rem;
    color: var(--primary-light);
    pointer-events: none;
}

#phone {
    padding-left: 2.5rem;
}

.honeypot {
    position: absolute;
    left: -9999px;
    opacity: 0;
}

/* Footer */
footer {
    background-color: rgba(18, 18, 18, 0.9);
    padding: 2rem 0;
    text-align: center;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-container p {
    color: var(--text-light);
    opacity: 0.7;
    font-size: 0.875rem;
}

/* Responsive styles */
@media (min-width: 768px) {
    .banner-top {
        grid-template-columns: 1fr 1fr;
        align-items: center;
    }

    .banner-top_text {
        text-align: left;
    }

    header nav ul li a {
        font-size: 1.125rem;
    }
}

@media (max-width: 1024px) {
    .about-container {
        flex-direction: column;
        text-align: center;
    }

    .description h2 {
        text-align: center;
    }
}
@media (max-width: 520px) {
    .about-container {
        flex-direction: column;
        text-align: start;
        align-items: center;
    }
}

@media (max-width: 767px) {
    .header-container {
        grid-template-columns: auto auto;
        justify-content: space-between;
    }

    nav {
        display: none;
    }

    .mobile-menu-button {
        display: block;
    }

    nav.active {
        display: block;
        position: absolute;
        top: 100px;
        left: 0;
        width: 100%;
        background: var(--text-dark);
        padding: 1rem;
        z-index: 1000;
        box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    }

    nav.active ul {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }

    .text-rotator {
        font-size: 1.8rem;
        height: 6.8rem;
    }

    .photo-container {
        width: 200px;
        height: 200px;
    }

    .skills-grid {
        grid-template-columns: 1fr;
    }

    .swiper {
        padding: 1rem 0;
    }
}

.badges-container {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    margin: 20px 0;
    align-items: center;
}

.badge-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100px;
    text-align: center;
}

.badge-item img {
    width: 70px;
    height: 70px;
    object-fit: contain;
    margin-bottom: 8px;
    border-radius: 50%;
    background: #f5f0ff;
    padding: 5px;
}

.badge-item span {
    font-size: 12px;
    font-weight: 500;
    color: #602aa5;
}