/* ===== Подключение шрифтов ===== */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&family=Playfair+Display:wght@600;700&display=swap');

/* ===== CSS переменные ===== */
:root {
    --primary: #6C63FF;
    --primary-dark: #5A52D5;
    --primary-light: #8B83FF;
    --secondary: #FF6584;
    --accent: #FFD93D;
    --bg-color: #F8F9FE;
    --bg-card: #FFFFFF;
    --text-primary: #1A1A2E;
    --text-secondary: #6B6B8A;
    --text-light: #9A9ABF;
    --border-color: #E8E8F0;
    --shadow: 0 8px 30px rgba(108, 99, 255, 0.10);
    --shadow-hover: 0 16px 48px rgba(108, 99, 255, 0.20);
    --gradient-1: linear-gradient(135deg, #6C63FF 0%, #FF6584 100%);
    --gradient-2: linear-gradient(135deg, #FFD93D 0%, #FF6584 100%);
    --border-radius: 24px;
    --border-radius-sm: 14px;
    --border-radius-xs: 10px;
    --transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    --font-primary: 'Inter', sans-serif;
    --font-display: 'Playfair Display', serif;
}

/* ===== Тёмная тема ===== */
[data-theme="dark"] {
    --bg-color: #0F0F1A;
    --bg-card: #1A1A2E;
    --text-primary: #EAEAFF;
    --text-secondary: #B0B0D0;
    --text-light: #7A7A9A;
    --border-color: #2D2D44;
    --shadow: 0 8px 30px rgba(0, 0, 0, 0.4);
    --shadow-hover: 0 16px 48px rgba(108, 99, 255, 0.15);
}

/* ===== Сброс стилей ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-primary);
    background: var(--bg-color);
    color: var(--text-primary);
    line-height: 1.6;
    transition: background 0.3s ease, color 0.3s ease;
    overflow-x: hidden;
    position: relative;
}

/* ===== Фоновые декоративные элементы ===== */
body::before {
    content: '';
    position: fixed;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(ellipse at 30% 20%, rgba(108, 99, 255, 0.05) 0%, transparent 60%),
        radial-gradient(ellipse at 70% 80%, rgba(255, 101, 132, 0.05) 0%, transparent 60%);
    z-index: -1;
    pointer-events: none;
}

/* ===== Кастомный скроллбар ===== */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--bg-color);
}

::-webkit-scrollbar-thumb {
    background: var(--gradient-1);
    border-radius: 10px;
}

::-webkit-scrollbar-thumb:hover {
    opacity: 0.8;
}

/* ===== Хедер / Навигация ===== */
.header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    padding: 0.7rem 2rem;
    border-bottom: 1px solid rgba(232, 232, 240, 0.5);
    transition: var(--transition);
}

[data-theme="dark"] .header {
    background: rgba(15, 15, 26, 0.85);
    border-bottom-color: rgba(45, 45, 68, 0.5);
}

.header__nav {
    max-width: 1280px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.header__menu {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    padding: 0.5rem 1rem;
    border-radius: 30px;
    transition: var(--transition);
    position: relative;
}

.header__menu:hover {
    color: var(--primary);
    background: rgba(108, 99, 255, 0.08);
    transform: translateY(-1px);
}

.header__menu::after {
    content: '';
    position: absolute;
    bottom: 4px;
    left: 50%;
    width: 0;
    height: 2.5px;
    background: var(--gradient-1);
    transition: var(--transition);
    transform: translateX(-50%);
    border-radius: 2px;
}

.header__menu:hover::after {
    width: 50%;
}

.header__menu--active {
    color: var(--primary);
}

.header__menu--active::after {
    width: 50%;
}

/* ===== Бургер-меню ===== */
.burger-menu {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
    transition: var(--transition);
}

.burger-menu span {
    display: block;
    width: 28px;
    height: 3px;
    background: var(--text-primary);
    border-radius: 3px;
    transition: var(--transition);
}

.burger-menu.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

.burger-menu.active span:nth-child(2) {
    opacity: 0;
    transform: scale(0);
}

.burger-menu.active span:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
}

/* ===== Основной контент ===== */
.main {
    max-width: 1280px;
    margin: 0 auto;
    padding: 6rem 2rem 2rem;
}

.main__section {
    margin-bottom: 5rem;
    animation: fadeInUp 0.8s ease forwards;
    opacity: 0;
}

.main__section:nth-child(1) {
    animation-delay: 0.1s;
}

.main__section:nth-child(2) {
    animation-delay: 0.2s;
}

.main__section:nth-child(3) {
    animation-delay: 0.3s;
}

.main__section:nth-child(4) {
    animation-delay: 0.4s;
}

.main__section:nth-child(5) {
    animation-delay: 0.5s;
}

.main__section:nth-child(6) {
    animation-delay: 0.6s;
}

.main__section:nth-child(7) {
    animation-delay: 0.7s;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(40px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.main__title {
    font-family: var(--font-display);
    font-size: 3rem;
    font-weight: 700;
    text-align: center;
    margin-bottom: 2.5rem;
    background: var(--gradient-1);
    background-clip: text;
    -webkit-background-clip: text;
    color: transparent;
    position: relative;
    letter-spacing: -0.5px;
}

/* ===== Hero-секция ===== */
.hero {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 70vh;
    text-align: center;
    padding: 2rem 0;
    gap: 2rem;
}

.hero__text {
    font-size: 1.8rem;
    font-weight: 400;
    color: var(--text-secondary);
    line-height: 1.8;
}

.hero__text span {
    font-size: 2rem;
    font-weight: 600;
    background: var(--gradient-1);
    background-clip: text;
    -webkit-background-clip: text;
    color: transparent;
}

.hero__buttons {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    justify-content: center;
}

.hero__button1,
.hero__button2 {
    padding: 0.9rem 2.5rem;
    border-radius: 50px;
    font-weight: 600;
    font-size: 1rem;
    text-decoration: none;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    position: relative;
    overflow: hidden;
}

.hero__button1 {
    background: var(--gradient-1);
    color: white;
    box-shadow: var(--shadow);
}

.hero__button1::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: 0.6s;
}

.hero__button1:hover::before {
    left: 100%;
}

.hero__button1:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-hover);
}

.hero__button2 {
    background: transparent;
    color: var(--text-primary);
    border: 2px solid var(--border-color);
}

.hero__button2:hover {
    border-color: var(--primary);
    color: var(--primary);
    transform: translateY(-3px);
    background: rgba(108, 99, 255, 0.04);
}

.hero__image {
    width: 280px;
    height: 280px;
    border-radius: 50%;
    object-fit: cover;
    box-shadow: var(--shadow-hover);
    border: 4px solid var(--bg-card);
    transition: var(--transition);
    animation: float 6s ease-in-out infinite;
}

@keyframes float {

    0%,
    100% {
        transform: translateY(0);
    }

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

.hero__image:hover {
    transform: scale(1.03) rotate(-2deg);
    border-color: var(--primary);
}

/* ===== Обо мне ===== */
.about {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    align-items: start;
    background: var(--bg-card);
    padding: 3rem;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    border: 1px solid var(--border-color);
}

.about__grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
}

.about__text1 {
    background: var(--bg-color);
    padding: 1.2rem;
    border-radius: var(--border-radius-sm);
    font-weight: 500;
    color: var(--text-primary);
    transition: var(--transition);
    border: 1px solid var(--border-color);
    text-align: center;
}

.about__text1:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow);
    border-color: var(--primary);
}

.about__text2 {
    grid-column: 1 / -1;
    background: rgba(108, 99, 255, 0.05);
    padding: 1.5rem;
    border-radius: var(--border-radius-sm);
    color: var(--text-secondary);
    line-height: 1.8;
    border-left: 4px solid var(--primary);
}

.about__title {
    font-family: var(--font-display);
    font-size: 1.8rem;
    color: var(--text-primary);
    margin-bottom: 1rem;
}

.about__ul {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
}

.about__li {
    color: var(--text-secondary);
    padding: 0.8rem 1.2rem;
    border-radius: var(--border-radius-xs);
    transition: var(--transition);
    border-bottom: 1px solid var(--border-color);
}

.about__li:hover {
    color: var(--primary);
    transform: translateX(5px);
    border-color: var(--primary);
}

/* ===== Навыки ===== */
.scills {
    background: var(--bg-card);
    padding: 3rem;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    border: 1px solid var(--border-color);
}

.scills__title {
    font-size: 1.4rem;
    font-weight: 600;
    margin: 2rem 0 1rem;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 0.8rem;
}

.scills__title:first-of-type {
    margin-top: 0;
}

.scills__title::before {
    content: '✦';
    color: var(--primary);
    font-size: 1.6rem;
}

.scills__grid {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.8rem 1.2rem;
    border-radius: var(--border-radius-xs);
    background: var(--bg-color);
    margin-bottom: 0.5rem;
    transition: var(--transition);
    border: 1px solid transparent;
}

.scills__grid:hover {
    border-color: var(--primary);
    transform: translateX(5px);
}

.scills__icontext {
    font-weight: 500;
    color: var(--text-primary);
}

.scills__star {
    color: var(--accent);
    font-size: 1.2rem;
    letter-spacing: 2px;
}

.scills__li {
    padding: 0.8rem 1.2rem;
    border-bottom: 1px solid var(--border-color);
    color: var(--text-secondary);
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: var(--transition);
}

.scills__li:hover {
    color: var(--primary);
    transform: translateX(5px);
}

.scills__li:last-child {
    border-bottom: none;
}

/* ===== Проекты ===== */
.project {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 2rem;
}

.project__grid {
    background: var(--bg-card);
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: var(--transition);
    border: 1px solid var(--border-color);
    padding: 1.5rem;
}

.project__grid:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-hover);
}

.project__text {
    margin-bottom: 0.8rem;
}

.project__text:first-child {
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--text-primary);
}

.project__text:nth-child(2) {
    color: var(--text-secondary);
    font-size: 0.95rem;
    line-height: 1.7;
}

.project__text:nth-child(3) {
    display: inline-block;
    background: rgba(108, 99, 255, 0.08);
    color: var(--primary);
    padding: 0.25rem 1rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
}

.project__img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    border-radius: var(--border-radius-xs);
    transition: var(--transition);
    margin-top: 1rem;
}

.project__img:hover {
    transform: scale(1.02);
    box-shadow: var(--shadow);
}

/* ===== Образование ===== */
.education {
    background: var(--bg-card);
    padding: 3rem;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    border: 1px solid var(--border-color);
}

.education__text {
    color: var(--text-secondary);
    line-height: 1.8;
    font-size: 1.05rem;
    padding: 0.5rem 0;
    border-bottom: 1px solid var(--border-color);
}

.education__text:last-of-type {
    border-bottom: none;
}

.education__title {
    font-family: var(--font-display);
    font-size: 1.6rem;
    color: var(--text-primary);
    margin: 1.5rem 0 1rem;
}

.education ul {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    gap: 0.8rem;
}

.education__li {
    background: rgba(108, 99, 255, 0.08);
    color: var(--primary);
    padding: 0.4rem 1.4rem;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 500;
    transition: var(--transition);
}

.education__li:hover {
    background: var(--primary);
    color: white;
    transform: translateY(-2px);
}

/* ===== Отзывы ===== */
.comment__items {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
}

.comment__item {
    background: var(--bg-card);
    padding: 2rem;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    border: 1px solid var(--border-color);
    transition: var(--transition);
    position: relative;
}

.comment__item::before {
    content: '"';
    position: absolute;
    top: 0.5rem;
    left: 1.5rem;
    font-size: 4rem;
    color: var(--primary);
    opacity: 0.1;
    font-family: var(--font-display);
}

.comment__item:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-hover);
}

.comment__text {
    color: var(--text-secondary);
    line-height: 1.8;
    font-style: italic;
}

.comment__text b {
    color: var(--text-primary);
    font-style: normal;
    font-size: 1.05rem;
}

/* ===== Контакты ===== */
.contact {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    background: var(--bg-card);
    padding: 3rem;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    border: 1px solid var(--border-color);
}

.contact__form {
    display: flex;
    flex-direction: column;
    gap: 1.2rem;
}

.contact__label {
    font-weight: 600;
    color: var(--text-primary);
    font-size: 0.95rem;
}

.contact__input {
    padding: 0.9rem 1.2rem;
    border: 2px solid var(--border-color);
    border-radius: var(--border-radius-sm);
    font-family: var(--font-primary);
    font-size: 1rem;
    transition: var(--transition);
    background: var(--bg-color);
    color: var(--text-primary);
}

.contact__input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(108, 99, 255, 0.08);
}

.contact__input::placeholder {
    color: var(--text-light);
}

.contact__button {
    background: var(--gradient-1);
    color: white;
    border: none;
    padding: 0.9rem 2.5rem;
    border-radius: 50px;
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    transition: var(--transition);
    align-self: flex-start;
    box-shadow: var(--shadow);
}

.contact__button:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-hover);
}

.contact__texts {
    display: flex;
    flex-direction: column;
    gap: 1.2rem;
    justify-content: center;
}

.contact__text {
    color: var(--text-secondary);
    padding: 0.8rem 1.2rem;
    border-radius: var(--border-radius-xs);
    transition: var(--transition);
    border-left: 3px solid transparent;
}

.contact__text:hover {
    border-left-color: var(--primary);
    background: rgba(108, 99, 255, 0.04);
    transform: translateX(5px);
}

.contact__download {
    background: var(--gradient-1);
    color: white;
    border: none;
    padding: 0.9rem 2.5rem;
    border-radius: 50px;
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    transition: var(--transition);
    align-self: flex-start;
    box-shadow: var(--shadow);
}

.contact__download:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-hover);
}

/* ===== Футер ===== */
.footer {
    background: var(--bg-card);
    border-top: 1px solid var(--border-color);
    padding: 2rem;
    text-align: center;
}

.footer__copy {
    color: var(--text-secondary);
    font-size: 1rem;
}

.footer__copy .heart {
    color: var(--secondary);
    display: inline-block;
    animation: heartbeat 1.5s ease-in-out infinite;
}

@keyframes heartbeat {

    0%,
    100% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.2);
    }
}

/* ===== Кнопка "Наверх" ===== */
.scroll-top {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 48px;
    height: 48px;
    background: var(--gradient-1);
    color: white;
    border: none;
    border-radius: 50%;
    font-size: 1.2rem;
    cursor: pointer;
    box-shadow: var(--shadow);
    transition: var(--transition);
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    z-index: 999;
}

.scroll-top.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.scroll-top:hover {
    transform: translateY(-4px) scale(1.05);
    box-shadow: var(--shadow-hover);
}

/* ===== Адаптивность ===== */
@media (max-width: 1024px) {
    .about {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

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

    .contact {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .contact__button,
    .contact__download {
        align-self: stretch;
        text-align: center;
        justify-content: center;
    }

    .hero__text {
        font-size: 1.5rem;
    }

    .hero__image {
        width: 220px;
        height: 220px;
    }
}

@media (max-width: 768px) {
    .main {
        padding: 5rem 1rem 1rem;
    }

    .main__title {
        font-size: 2.2rem;
    }

    .header {
        padding: 0.5rem 1rem;
    }

    .header__nav {
        display: none;
        flex-direction: column;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: var(--bg-card);
        padding: 1rem 2rem;
        box-shadow: var(--shadow-hover);
        gap: 0.5rem;
        border-bottom: 1px solid var(--border-color);
    }

    .header__nav.active {
        display: flex;
    }

    .burger-menu {
        display: flex;
        margin-left: auto;
    }

    .header__menu {
        width: 100%;
        text-align: center;
    }

    .hero__text {
        font-size: 1.2rem;
    }

    .hero__text span {
        font-size: 1.5rem;
    }

    .hero__image {
        width: 180px;
        height: 180px;
    }

    .about {
        padding: 1.5rem;
    }

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

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

    .scills {
        padding: 1.5rem;
    }

    .education {
        padding: 1.5rem;
    }

    .contact {
        padding: 1.5rem;
    }

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

    .comment__item {
        padding: 1.5rem;
    }

    .scills__grid {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.3rem;
    }
}

@media (max-width: 480px) {
    .main__title {
        font-size: 1.8rem;
    }

    .hero__text {
        font-size: 1rem;
    }

    .hero__text span {
        font-size: 1.2rem;
    }

    .hero__buttons {
        flex-direction: column;
        align-items: center;
        width: 100%;
    }

    .hero__button1,
    .hero__button2 {
        width: 100%;
        justify-content: center;
        padding: 0.8rem 1.5rem;
    }

    .hero__image {
        width: 150px;
        height: 150px;
    }

    .header__menu {
        font-size: 0.9rem;
        padding: 0.5rem;
    }

    .project__grid {
        padding: 1rem;
    }

    .project__img {
        height: 160px;
    }

    .education__title {
        font-size: 1.3rem;
    }

    .footer__copy {
        font-size: 0.85rem;
    }
}

/* ===== Утилиты ===== */
.text-gradient {
    background: var(--gradient-1);
    background-clip: text;
    -webkit-background-clip: text;
    color: transparent;
}