/* Основные стили и сброс */
:root {
    --background-color: #0f0f1e;
    --text-color: #eaebff;
    --accent-color: #4285f4;
    --secondary-color: #232336;
    --border-color: #2c2c40;
    --light-text: #a9b0c4;
    --transition-time: 0.3s;
    --container-bg: rgba(20, 20, 35, 0.8);
    --card-bg: rgba(30, 30, 50, 0.85);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', 'Segoe UI', Roboto, Arial, sans-serif;
    background-color: var(--background-color);
    color: var(--text-color);
    line-height: 1.6;
    font-size: 16px;
    position: relative;
    overflow-x: hidden;
}

/* Добавляем анимированный фон */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(circle at 20% 30%, rgba(66, 133, 244, 0.15) 0%, transparent 50%),
        radial-gradient(circle at 70% 60%, rgba(134, 80, 255, 0.15) 0%, transparent 50%),
        radial-gradient(circle at 40% 80%, rgba(52, 168, 83, 0.1) 0%, transparent 40%);
    z-index: -2;
}

/* Добавляем анимированные частицы на фон */
.particles {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
    pointer-events: none;
}

.particle {
    position: absolute;
    width: 6px;
    height: 6px;
    background-color: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    z-index: -1;
}

/* Создаем "сетку" на фоне */
body::after {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: 
        linear-gradient(rgba(50, 50, 80, 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(50, 50, 80, 0.03) 1px, transparent 1px);
    background-size: 30px 30px;
    z-index: -1;
}

.container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 2rem;
    position: relative;
    z-index: 1;
}

h1, h2, h3, h4, h5, h6 {
    margin-bottom: 1rem;
    font-weight: 600;
    color: #fff;
}

h1 {
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
}

h2 {
    font-size: 1.5rem;
    color: var(--light-text);
    margin-bottom: 0.75rem;
}

h3 {
    font-size: 1.75rem;
    border-bottom: 2px solid var(--accent-color);
    padding-bottom: 0.5rem;
    margin-bottom: 2rem;
    width: fit-content;
}

h4 {
    font-size: 1.3rem;
    margin-bottom: 0.5rem;
}

h5 {
    font-size: 1.1rem;
    color: var(--light-text);
    margin-bottom: 0.5rem;
}

p {
    margin-bottom: 1rem;
}

a {
    color: var(--accent-color);
    text-decoration: none;
    transition: color var(--transition-time);
}

a:hover {
    color: #5e9bff;
}

section {
    margin-bottom: 4rem;
    background-color: var(--container-bg);
    border-radius: 15px;
    padding: 2rem;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.2);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.05);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

section:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

/* Хедер и профиль */
header {
    height: 50vh;
    min-height: 400px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 3rem;
    position: relative;
}

.profile {
    margin: 0 auto 2rem;
    position: relative;
    overflow: hidden;
    width: 100%;
    max-width: 800px;
    min-height: 200px;
    border-radius: 20px;
    padding: 2rem;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

.profile:hover {
    background: rgba(255, 255, 255, 0.15);
    transform: translateY(-5px);
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.15);
}

/* Добавляем светящуюся рамку профиля */
.profile::before {
    content: '';
    position: absolute;
    inset: -2px;
    z-index: 0;
    border-radius: 22px;
    background: linear-gradient(45deg, 
        rgba(66, 133, 244, 0.8), 
        rgba(134, 80, 255, 0.8), 
        rgba(52, 168, 83, 0.8), 
        rgba(255, 213, 0, 0.8));
    opacity: 0.3;
    transition: opacity 0.3s ease;
    animation: gradientBorder 4s linear infinite;
}

.profile:hover::before {
    opacity: 0.6;
}

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

.profile-content {
    position: relative;
    z-index: 2;
    text-align: center;
    color: #ffffff;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.profile-content h1 {
    font-size: 2.8rem;
    margin-bottom: 0.3rem;
}

.profile-content h2 {
    font-size: 1.4rem;
    font-weight: 400;
    margin-bottom: 1rem;
    color: rgba(255, 255, 255, 0.9);
}

.tagline {
    font-size: 1.1rem;
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 1.5rem;
    font-style: italic;
}

/* Стили для дерева навыков (используем вместо графа) */
.skills-tree-container {
    width: 100%;
    margin-bottom: 30px;
}

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

.skill-category {
    background-color: rgba(15, 15, 30, 0.9);
    border-radius: 10px;
    padding: 1.5rem;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    animation: skill-appear 0.5s ease-out forwards;
    opacity: 0;
    border: 1px solid rgba(255, 255, 255, 0.05);
    position: relative;
    overflow: hidden;
}

.skill-category:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
}

.skill-category::before {
    content: '';
    position: absolute;
    width: 200px;
    height: 200px;
    background: linear-gradient(rgba(66, 133, 244, 0.1), transparent);
    border-radius: 50%;
    bottom: -100px;
    right: -100px;
    z-index: 0;
    opacity: 0.5;
    transition: all 0.3s ease;
}

#mobile-category::before {
    background: linear-gradient(rgba(66, 133, 244, 0.15), transparent);
}

#frontend-category::before {
    background: linear-gradient(rgba(234, 67, 53, 0.15), transparent);
}

#backend-category::before {
    background: linear-gradient(rgba(251, 188, 5, 0.15), transparent);
    right: 0;
    transform: translateX(50%);
}

#database-category::before {
    background: linear-gradient(rgba(52, 168, 83, 0.15), transparent);
}

#tgbots-category::before {
    background: linear-gradient(rgba(41, 121, 255, 0.15), transparent);
}

#other-category::before {
    background: linear-gradient(rgba(156, 39, 176, 0.15), transparent);
}

.skill-category-header {
    display: flex;
    align-items: center;
    margin-bottom: 1.5rem;
    padding-bottom: 0.75rem;
    border-bottom: 2px solid rgba(255, 255, 255, 0.05);
    position: relative;
    z-index: 1;
}

.skill-category-header i {
    font-size: 1.5rem;
    margin-right: 1rem;
}

.skill-category-header h4 {
    margin: 0;
    font-size: 1.2rem;
    font-weight: 600;
}

.skill-items {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    position: relative;
    z-index: 1;
}

.skill-item {
    display: flex;
    align-items: center;
    padding: 0.5rem;
    border-radius: 6px;
    transition: all 0.2s ease;
    background-color: rgba(255, 255, 255, 0.03);
}

.skill-item:last-child {
    margin-bottom: 0;
}

.skill-item:hover {
    background-color: rgba(255, 255, 255, 0.08);
    transform: translateX(5px);
}

.skill-item i {
    font-size: 1.2rem;
    width: 2rem;
    text-align: center;
    margin-right: 1rem;
    color: var(--accent-color);
    transition: transform 0.3s ease;
}

.skill-item:hover i {
    transform: scale(1.2);
}

.skill-item span {
    flex: 1;
    font-weight: 500;
}

/* Цвета категорий */
#mobile-category .skill-category-header i {
    color: #4285f4;
}

#frontend-category .skill-category-header i {
    color: #ea4335;
}

#backend-category .skill-category-header i {
    color: #fbbc05;
}

#database-category .skill-category-header i {
    color: #34a853;
}

#tgbots-category .skill-category-header i {
    color: #2979FF;
}

#other-category .skill-category-header i {
    color: #9c27b0;
}

@media (max-width: 768px) {
    .skill-category-header {
        flex-direction: column;
    }
    
    .skill-category-header i {
        margin-bottom: 0.5rem;
    }
    
    .skill-category-header h4 {
        text-align: center;
    }
    
    .skill-item {
        padding: 0.75rem 0.5rem;
    }
}

/* Анимация заполнения прогресс-бара */
@keyframes fillProgress {
    from { width: 0; }
    to { width: 100%; }
}

/* Опыт работы - новый современный дизайн */
.experience-timeline {
    position: relative;
    padding-left: 40px;
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.experience-timeline::before {
    content: '';
    position: absolute;
    left: 19px;
    top: 0;
    bottom: 0;
    width: 2px;
    background: linear-gradient(to bottom, var(--accent-color), rgba(66, 133, 244, 0.2));
    z-index: 1;
}

.timeline-node {
    position: relative;
}

.timeline-dot {
    position: absolute;
    left: -40px;
    top: 0;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: var(--accent-color);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 0 15px rgba(66, 133, 244, 0.5);
    z-index: 2;
}

.timeline-dot::before {
    content: '';
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background-color: #fff;
    box-shadow: inset 0 0 5px rgba(66, 133, 244, 0.3);
}

.timeline-date {
    display: inline-block;
    padding: 0.5rem 1rem;
    background-color: rgba(66, 133, 244, 0.15);
    border-radius: 6px;
    font-weight: 600;
    margin-bottom: 1rem;
    color: #fff;
}

.timeline-card {
    background-color: rgba(15, 15, 30, 0.9);
    border-radius: 8px;
    padding: 1.5rem;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.05);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    position: relative;
    overflow: hidden;
}

.timeline-card::before {
    content: '';
    position: absolute;
    width: 200px;
    height: 200px;
    background: linear-gradient(rgba(66, 133, 244, 0.1), transparent);
    border-radius: 50%;
    bottom: -100px;
    right: -100px;
    z-index: 0;
    opacity: 0.3;
}

.timeline-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.25);
}

.timeline-card h4, .timeline-card h5, .timeline-card p {
    position: relative;
    z-index: 1;
}

.timeline-card h4 {
    color: #fff;
    margin-bottom: 0.5rem;
}

.timeline-card h5 {
    color: var(--light-text);
    margin-bottom: 1rem;
}

@media (max-width: 768px) {
    .experience-timeline {
        padding-left: 30px;
    }
    
    .timeline-dot {
        left: -30px;
        width: 30px;
        height: 30px;
    }
    
    .timeline-dot::before {
        width: 15px;
        height: 15px;
    }
}

@media (max-width: 480px) {
    .experience-timeline {
        padding-left: 25px;
    }
    
    .timeline-dot {
        left: -25px;
        width: 25px;
        height: 25px;
    }
    
    .timeline-dot::before {
        width: 12px;
        height: 12px;
    }
    
    .timeline-card {
        padding: 1rem;
    }
}

/* Projects */
.projects-showcase {
    width: 100%;
    position: relative;
}

.project-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 2rem;
    justify-content: center;
}

.filter-btn {
    padding: 0.6rem 1.2rem;
    border: none;
    background-color: rgba(30, 30, 50, 0.7);
    color: var(--light-text);
    border-radius: 30px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.filter-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.25);
    color: white;
}

.filter-btn.active {
    background-color: var(--accent-color);
    color: white;
    box-shadow: 0 6px 15px rgba(66, 133, 244, 0.3);
}

.projects-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 2.5rem;
    perspective: 1000px;
}

.project-card {
    perspective: 1000px;
    margin-bottom: 30px;
    width: 100%;
    height: 420px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    cursor: pointer;
}

.project-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.15);
}

.project-inner {
    position: relative;
    width: 100%;
    height: 100%;
    transition: transform 0.8s;
    transform-style: preserve-3d;
}

.project-front, .project-back {
    position: absolute;
    width: 100%;
    height: 100%;
    backface-visibility: hidden;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
    background-color: var(--card-bg);
}

.project-front {
    z-index: 2;
    transform: rotateY(0deg);
    display: flex;
    flex-direction: column;
}

.project-back {
    transform: rotateY(180deg);
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    overflow-y: auto;
}

/* Изображения проектов */
.project-image {
    width: 100%;
    height: 200px;
    overflow: hidden;
    position: relative;
    border-top-left-radius: 15px;
    border-top-right-radius: 15px;
    background-color: #1a1a2e;
}

.project-image::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(0deg, rgba(0, 0, 0, 0.4) 0%, rgba(0, 0, 0, 0) 60%);
    z-index: 1;
    opacity: 0.8;
    transition: opacity 0.3s ease;
}

.project-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.project-preview {
    padding: 1.5rem;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    height: calc(100% - 200px);
}

.project-preview h4 {
    font-size: 1.3rem;
    margin-bottom: 0.8rem;
    font-weight: 600;
}

.project-brief {
    color: var(--text-color);
    margin-bottom: 1.5rem;
    line-height: 1.5;
    flex-grow: 1;
}

.project-tags {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    padding: 10px;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.project-tag {
    display: inline-block;
    padding: 5px 10px;
    background-color: rgba(66, 133, 244, 0.3);
    color: white;
    border-radius: 4px;
    font-size: 0.8rem;
    backdrop-filter: blur(5px);
}

.details-btn {
    align-self: center;
    margin-top: auto;
    padding: 0.7rem 1.8rem;
    background: rgba(66, 133, 244, 0.2);
    color: #ffffff;
    border: 1px solid rgba(66, 133, 244, 0.3);
    border-radius: 30px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    width: auto;
    margin-bottom: 1rem;
    letter-spacing: 0.5px;
}

.details-btn:hover {
    background: rgba(66, 133, 244, 0.4);
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(66, 133, 244, 0.3), 0 0 8px rgba(66, 133, 244, 0.5);
    color: #ffffff;
    text-decoration: none;
}

.details-btn i {
    margin-right: 0.5rem;
    font-size: 0.9rem;
}

.close-details {
    align-self: flex-start;
    padding: 8px;
    border: none;
    background-color: transparent;
    color: var(--light-text);
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 1.1rem;
    margin-bottom: 1rem;
}

.close-details:hover {
    color: white;
}

.project-details {
    margin: 1rem 0;
    flex-grow: 1;
    overflow-y: auto;
    max-height: 180px;
    padding-right: 10px;
    scrollbar-width: thin;
    scrollbar-color: var(--accent-color) rgba(30, 30, 50, 0.3);
    position: relative;
}

.project-details::-webkit-scrollbar {
    width: 8px;
}

.project-details::-webkit-scrollbar-track {
    background: rgba(30, 30, 50, 0.3);
    border-radius: 10px;
}

.project-details::-webkit-scrollbar-thumb {
    background-color: var(--accent-color);
    border-radius: 10px;
    border: 2px solid rgba(30, 30, 50, 0.3);
}

.project-details::-webkit-scrollbar-thumb:hover {
    background-color: #5e9bff;
}

.scroll-hint {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    text-align: center;
    background: linear-gradient(to bottom, transparent, var(--card-bg) 70%);
    padding: 20px 0 5px;
    pointer-events: none;
    opacity: 0.8;
    transition: opacity 0.3s ease;
    cursor: pointer;
}

.scroll-hint i {
    color: var(--accent-color);
    animation: bounce 1.5s infinite;
    font-size: 14px;
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translateY(0);
    }
    40% {
        transform: translateY(-5px);
    }
    60% {
        transform: translateY(-3px);
    }
}

/* При достижении конца контента скрываем подсказку */
.project-details.at-bottom .scroll-hint {
    opacity: 0;
}

.project-stats {
    display: flex;
    justify-content: space-around;
    margin: 1.5rem 0;
    padding: 15px;
    background-color: rgba(15, 15, 30, 0.7);
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.stat {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.stat-value {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--accent-color);
}

.stat-label {
    font-size: 0.8rem;
    color: var(--light-text);
}

.project-links {
    display: flex;
    gap: 1rem;
    margin-top: auto;
}

.project-btn {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.project-btn.disabled {
    opacity: 0.7;
    cursor: not-allowed;
    background-color: rgba(50, 50, 70, 0.5);
    color: var(--light-text);
}

.project-btn.disabled:hover {
    background-color: rgba(50, 50, 70, 0.6);
    transform: none;
    box-shadow: none;
}

.projects-grid {
    display: none; /* Скрываем старый стиль */
}

@media (max-width: 768px) {
    .project-filters {
        overflow-x: auto;
        padding-bottom: 10px;
        justify-content: flex-start;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none; /* Для Firefox */
    }
    
    .project-filters::-webkit-scrollbar {
        display: none; /* Для Chrome, Safari и Opera */
    }
    
    .filter-btn {
        font-size: 0.9rem;
        padding: 0.5rem 1rem;
        white-space: nowrap;
    }
    
    .projects-container {
        grid-template-columns: 1fr;
    }
    
    .project-card {
        height: auto;
        min-height: 400px;
        max-height: 450px;
        width: 100%;
        margin: 0 auto;
    }
    
    .project-inner, .project-front, .project-back {
        height: 100%;
        width: 100%;
        max-height: 450px;
    }
    
    .project-image {
        height: 180px;
    }
    
    .project-image img {
        object-position: center center;
    }
    
    .project-preview {
        padding: 1rem;
    }
    
    .project-back {
        padding: 1rem;
        overflow-y: auto;
    }
    
    .project-details {
        max-height: 150px;
    }
}

@media (max-width: 480px) {
    .project-card {
        min-height: 380px;
        max-height: 430px;
    }
    
    .project-image {
        height: 150px;
    }
    
    .project-preview {
        padding: 1rem;
    }
    
    .project-back {
        padding: 1rem;
    }
    
    .project-stats {
        flex-direction: column;
        gap: 10px;
        padding: 10px;
        margin: 1rem 0;
    }
    
    .stat {
        flex-direction: row;
        justify-content: space-between;
        width: 100%;
    }
    
    .project-tags {
        padding: 5px;
    }
    
    .project-tag {
        font-size: 0.7rem;
        padding: 3px 8px;
    }
    
    .details-btn {
        padding: 0.5rem 1rem;
        font-size: 0.9rem;
    }
    
    .project-details {
        max-height: 120px;
        -webkit-overflow-scrolling: touch;
    }
}

/* Contact section */
.contact-container {
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem;
    justify-content: center;
}

.contact-item {
    display: flex;
    align-items: center;
    padding: 1.25rem;
    background-color: var(--card-bg);
    border-radius: 8px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.05);
    color: var(--text-color);
    min-width: 250px;
    max-width: 100%;
    flex: 1 1 300px;
}

.contact-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.2);
    border-color: var(--accent-color);
}

.contact-item i {
    font-size: 1.5rem;
    margin-right: 1rem;
    color: var(--accent-color);
    transition: transform 0.3s ease;
    flex-shrink: 0;
}

.contact-item span {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.contact-item:hover i {
    transform: scale(1.2);
}

@media (max-width: 768px) {
    .contact-container {
        flex-direction: column;
    }
    
    .contact-item {
        width: 100%;
        flex: 1 1 auto;
    }
}

/* Footer */
footer {
    text-align: center;
    padding: 2rem 0;
    color: var(--light-text);
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    margin-top: 3rem;
}

/* Media queries */
@media (max-width: 768px) {
    .container {
        padding: 1rem;
    }
    
    header {
        height: auto;
        min-height: auto;
    }
    
    h1 {
        font-size: 2rem;
    }
    
    h2 {
        font-size: 1.25rem;
    }
    
    .skills-tree-container {
        padding: 0;
    }
    
    .experience-timeline {
        padding-left: 30px;
    }
    
    .timeline-dot {
        left: -30px;
        width: 30px;
        height: 30px;
    }
    
    .timeline-dot::before {
        width: 15px;
        height: 15px;
    }
    
    .projects-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    h1 {
        font-size: 1.75rem;
    }
    
    .skill-category {
        width: 100%;
        margin-bottom: 1rem;
    }
    
    .skill-item {
        padding: 0.5rem 0;
    }
    
    .timeline-card {
        padding: 1rem;
    }
    
    .contact-item {
        width: 100%;
    }
}

/* Улучшенная анимация при появлении навыков */
@keyframes skill-appear {
    0% {
        opacity: 0;
        transform: translateY(30px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

.skill-category:nth-child(1) { animation-delay: 0.1s; }
.skill-category:nth-child(2) { animation-delay: 0.2s; }
.skill-category:nth-child(3) { animation-delay: 0.3s; }
.skill-category:nth-child(4) { animation-delay: 0.4s; }
.skill-category:nth-child(5) { animation-delay: 0.5s; }

/* Стили для иконок технологий */
.custom-icon-container {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 2rem;
    margin-right: 1rem;
    transition: transform 0.3s ease;
}

.custom-icon {
    width: 24px;
    height: 24px;
    object-fit: contain;
    transition: transform 0.3s ease;
}

.skill-item:hover .custom-icon-container,
.skill-item:hover i {
    transform: scale(1.2);
}

/* Футуристический таймлайн в стиле платы */
.circuit-timeline {
    position: relative;
    padding-left: 30px;
    margin-left: 30px;
    display: flex;
    flex-direction: column;
    gap: 3rem;
}

/* Removing the vertical line on the left as requested */
/* 
.circuit-timeline::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 3px;
    background: linear-gradient(to bottom, 
        rgba(66, 133, 244, 0.8), 
        rgba(52, 168, 83, 0.8), 
        rgba(251, 188, 5, 0.8));
    z-index: 1;
    box-shadow: 0 0 15px rgba(66, 133, 244, 0.5),
                0 0 30px rgba(66, 133, 244, 0.3);
}
*/

.circuit-node {
    position: relative;
    perspective: 1000px;
}

/* Restoring only the pulse-dot elements as requested */
.node-connector {
    position: absolute;
    left: -43px;
    top: 40px;
    display: flex;
    align-items: center;
    z-index: 2;
}

/* Keeping the connector-line commented out
.connector-line {
    width: 40px;
    height: 2px;
    background: linear-gradient(to right, rgba(66, 133, 244, 0.8) 70%, transparent);
    position: relative;
    margin-left: -12px;
}

.connector-line::before {
    content: '';
    position: absolute;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, 
        rgba(66, 133, 244, 0.8),
        rgba(66, 133, 244, 0.1));
    animation: circuitPulse 2s infinite;
}
*/

.pulse-dot {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background-color: var(--accent-color);
    box-shadow: 0 0 10px var(--accent-color), 
                0 0 20px rgba(66, 133, 244, 0.5);
    position: relative;
    z-index: 3;
}

.pulse-dot::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #fff;
    box-shadow: inset 0 0 5px rgba(66, 133, 244, 0.3);
}

.pulse-dot::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    background: rgba(66, 133, 244, 0.4);
    z-index: -1;
    animation: pulse 2s infinite;
}

.experience-chip {
    background: rgba(15, 15, 35, 0.9);
    border-radius: 10px;
    padding: 1.5rem;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.3);
    position: relative;
    transition: transform 0.4s ease, box-shadow 0.4s ease;
    border: 1px solid rgba(66, 133, 244, 0.3);
    overflow: hidden;
    transform-style: preserve-3d;
}

.circuit-node.current .experience-chip {
    border-color: rgba(66, 133, 244, 0.6);
    box-shadow: 0 10px 30px rgba(66, 133, 244, 0.25);
}

.experience-chip::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(circle at 30% 20%, rgba(66, 133, 244, 0.05) 0%, transparent 50%),
        radial-gradient(circle at 70% 60%, rgba(52, 168, 83, 0.05) 0%, transparent 50%);
    z-index: 0;
}

.experience-chip::after {
    content: '';
    position: absolute;
    width: 150%;
    height: 60px;
    background: linear-gradient(90deg, 
        transparent, 
        rgba(66, 133, 244, 0.1), 
        transparent);
    transform: rotate(-45deg);
    top: -50px;
    left: -120px;
    animation: chipGlare 10s infinite;
}

.chip-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 0.5rem;
    position: relative;
    z-index: 1;
}

.chip-period {
    display: inline-block;
    padding: 0.5rem 1rem;
    background: rgba(66, 133, 244, 0.15);
    border-radius: 30px;
    color: #fff;
    font-weight: 600;
    font-size: 0.9rem;
    border-left: 3px solid var(--accent-color);
}

.chip-role {
    font-size: 1.5rem;
    font-weight: 700;
    color: #fff;
    margin-bottom: 0.5rem;
    position: relative;
    padding-right: 20px;
}

.chip-role::after {
    content: '';
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: var(--accent-color);
    box-shadow: 0 0 10px var(--accent-color);
}

.chip-company {
    font-size: 1.1rem;
    color: var(--light-text);
    margin-bottom: 1rem;
    letter-spacing: 0.5px;
    position: relative;
    z-index: 1;
}

.chip-details {
    margin-bottom: 1rem;
    position: relative;
    z-index: 1;
    padding-left: 15px;
}

.chip-details p {
    margin-bottom: 0.5rem;
    line-height: 1.6;
}

.circuit-paths {
    position: absolute;
    bottom: 0;
    right: 0;
    width: 250px;
    height: 150px;
    pointer-events: none;
    opacity: 0.4;
    z-index: 0;
}

.circuit-path {
    position: absolute;
    background: transparent;
}

.circuit-path.path-1 {
    width: 150px;
    height: 80px;
    right: 20px;
    bottom: 20px;
    border-top: 2px solid rgba(66, 133, 244, 0.7);
    border-right: 2px solid rgba(66, 133, 244, 0.7);
    border-top-right-radius: 20px;
}

.circuit-path.path-2 {
    width: 40px;
    height: 2px;
    right: 170px;
    bottom: 60px;
    background: rgba(66, 133, 244, 0.7);
}

.circuit-path.path-3 {
    width: 2px;
    height: 50px;
    right: 170px;
    bottom: 60px;
    background: rgba(66, 133, 244, 0.7);
}

.experience-chip:hover {
    transform: translateY(-5px) rotateX(5deg) rotateY(-5deg);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.4), 
                0 0 20px rgba(66, 133, 244, 0.2);
}

.circuit-node.current .experience-chip:hover {
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.4), 
                0 0 30px rgba(66, 133, 244, 0.3);
}

@keyframes pulse {
    0% {
        transform: scale(1);
        opacity: 0.7;
    }
    50% {
        transform: scale(1.5);
        opacity: 0;
    }
    100% {
        transform: scale(1);
        opacity: 0;
    }
}

@keyframes circuitPulse {
    0% {
        opacity: 0.2;
        transform: scaleX(0);
        transform-origin: left;
    }
    50% {
        opacity: 1;
        transform: scaleX(1);
        transform-origin: left;
    }
    51% {
        transform-origin: right;
    }
    100% {
        opacity: 0.2;
        transform: scaleX(0);
        transform-origin: right;
    }
}

@keyframes chipGlare {
    0% {
        left: -150%;
    }
    20%, 100% {
        left: 150%;
    }
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .circuit-timeline {
        padding-left: 20px;
        margin-left: 20px;
    }
    
    .node-connector {
        left: -33px;
    }
    
    .chip-header {
        flex-direction: column;
    }
    
    .chip-period {
        margin-bottom: 1rem;
    }
    
    .circuit-paths {
        width: 150px;
        height: 100px;
    }
}

@media (max-width: 480px) {
    .circuit-timeline {
        padding-left: 15px;
        margin-left: 15px;
    }
    
    .node-connector {
        left: -28px;
    }
    
    .pulse-dot {
        width: 16px;
        height: 16px;
    }
    
    .pulse-dot::before {
        width: 8px;
        height: 8px;
    }
    
    .experience-chip {
        padding: 1rem;
    }
    
    .chip-role {
        font-size: 1.2rem;
    }
    
    .circuit-paths {
        display: none;
    }
}

/* Стили для подсказки вместо фото */
.image-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background-color: var(--secondary-color);
    cursor: pointer;
    transition: all 0.3s ease;
    position: absolute;
    top: 0;
    left: 0;
    z-index: 2;
    color: var(--light-text);
}

.image-placeholder i {
    font-size: 2rem;
    margin-bottom: 0.5rem;
    color: var(--accent-color);
}

.image-placeholder span {
    font-size: 0.9rem;
    font-weight: 500;
}

.image-placeholder:hover {
    background-color: rgba(50, 50, 80, 0.9);
    color: white;
}

.image-placeholder:hover i {
    transform: scale(1.2);
}

/* Стили для галереи проекта */
.project-gallery {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(10, 10, 20, 0.98);
    z-index: 1000;
    display: none;
    flex-direction: column;
    overflow: hidden;
}

.project-gallery.active {
    display: flex;
}

.gallery-close {
    position: absolute;
    top: 20px;
    right: 20px;
    width: 40px;
    height: 40px;
    background-color: rgba(0, 0, 0, 0.5);
    border: none;
    border-radius: 50%;
    color: white;
    cursor: pointer;
    z-index: 1003;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    font-size: 1.2rem;
}

.gallery-close:hover {
    background-color: var(--accent-color);
    transform: scale(1.1);
}

.gallery-container {
    flex: 1;
    overflow: hidden;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.gallery-container img {
    position: absolute;
    max-width: 90%;
    max-height: 80%;
    object-fit: contain;
    opacity: 0;
    transition: opacity 0.5s ease, transform 0.5s ease;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    border-radius: 5px;
}

.gallery-container img.active {
    opacity: 1;
    z-index: 1001;
    transform: scale(1);
}

.gallery-nav {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    background-color: rgba(0, 0, 0, 0.3);
    z-index: 1002;
    position: relative;
}

.gallery-prev, .gallery-next {
    width: 50px;
    height: 50px;
    border: none;
    background-color: rgba(35, 35, 54, 0.7);
    color: white;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    font-size: 1.2rem;
    margin: 0 15px;
}

.gallery-prev:hover, .gallery-next:hover {
    background-color: var(--accent-color);
    transform: scale(1.1);
}

.gallery-dots {
    display: flex;
    gap: 12px;
}

.gallery-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.4);
    cursor: pointer;
    transition: all 0.3s ease;
}

.gallery-dot.active {
    background-color: var(--accent-color);
    transform: scale(1.2);
}

.project-gallery-title {
    position: absolute;
    top: 20px;
    left: 20px;
    color: white;
    font-size: 1.2rem;
    z-index: 1002;
    background-color: rgba(0, 0, 0, 0.5);
    padding: 8px 15px;
    border-radius: 30px;
}

/* Дополнительные изменения для адаптивности */
@media (max-width: 768px) {
    .gallery-prev, .gallery-next {
        width: 40px;
        height: 40px;
        margin: 0 10px;
    }
    
    .gallery-close {
        top: 15px;
        right: 15px;
        width: 35px;
        height: 35px;
    }
    
    .project-gallery-title {
        font-size: 1rem;
        top: 15px;
        left: 15px;
    }
}

@media (max-width: 480px) {
    .gallery-prev, .gallery-next {
        width: 35px;
        height: 35px;
        margin: 0 5px;
    }
    
    .gallery-container {
        padding: 10px;
    }
    
    .gallery-dots {
        gap: 8px;
    }
    
    .gallery-dot {
        width: 8px;
        height: 8px;
    }
    
    .gallery-nav {
        padding: 15px 10px;
    }
}

body.gallery-open {
    overflow: hidden;
}

/* Полноэкранное отображение текста проекта */
.fullscreen-description {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(15, 15, 30, 0.98);
    z-index: 2000;
    display: none;
    flex-direction: column;
    padding: 60px 20px 20px;
    overflow-y: auto;
    backdrop-filter: blur(10px);
}

.fullscreen-description.active {
    display: flex;
}

.fullscreen-description-content {
    max-width: 800px;
    margin: 0 auto;
    padding: 30px;
    background-color: var(--card-bg);
    border-radius: 15px;
    border: 1px solid rgba(255, 255, 255, 0.05);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    position: relative;
    overflow-y: auto;
    flex: 1;
}

.fullscreen-description-content p {
    font-size: 1.1rem;
    line-height: 1.8;
    margin-bottom: 1.5rem;
    color: var(--text-color);
}

.fullscreen-description-content h3 {
    font-size: 1.8rem;
    margin-bottom: 1.5rem;
    color: white;
    border-bottom: 2px solid var(--accent-color);
    padding-bottom: 0.5rem;
}

.fullscreen-close {
    position: absolute;
    top: 20px;
    right: 20px;
    width: 40px;
    height: 40px;
    background-color: rgba(0, 0, 0, 0.5);
    border: none;
    border-radius: 50%;
    color: white;
    cursor: pointer;
    z-index: 2001;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    font-size: 1.2rem;
}

.fullscreen-close:hover {
    background-color: var(--accent-color);
    transform: scale(1.1);
}

.scroll-hint {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    text-align: center;
    background: linear-gradient(to bottom, transparent, var(--card-bg) 70%);
    padding: 20px 0 5px;
    pointer-events: none;
    opacity: 0.8;
    transition: opacity 0.3s ease;
    cursor: pointer;
}

.scroll-hint i {
    color: var(--accent-color);
    animation: bounce 1.5s infinite;
    font-size: 14px;
}

/* Делаем стрелку кликабельной */
.scroll-hint-clickable {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 30px;
    cursor: pointer;
    z-index: 10;
}

@media (max-width: 768px) {
    .fullscreen-description {
        padding: 50px 15px 15px;
    }
    
    .fullscreen-description-content {
        padding: 20px;
    }
    
    .fullscreen-description-content p {
        font-size: 1rem;
        line-height: 1.6;
    }
    
    .fullscreen-description-content h3 {
        font-size: 1.5rem;
    }
    
    .fullscreen-close {
        top: 15px;
        right: 15px;
        width: 35px;
        height: 35px;
    }
}

@media (max-width: 480px) {
    .fullscreen-description {
        padding: 40px 10px 10px;
    }
    
    .fullscreen-description-content {
        padding: 15px;
    }
    
    .fullscreen-description-content p {
        font-size: 0.95rem;
        line-height: 1.5;
    }
    
    .fullscreen-description-content h3 {
        font-size: 1.3rem;
    }
    
    .fullscreen-close {
        top: 10px;
        right: 10px;
        width: 30px;
        height: 30px;
    }
}

/* Примечание о дополнительных проектах */
.projects-note {
    margin-top: 2rem;
    padding: 1rem 1.5rem;
    background-color: rgba(15, 15, 30, 0.7);
    border-radius: 10px;
    border-left: 3px solid var(--accent-color);
    display: flex;
    align-items: center;
    gap: 15px;
    font-size: 0.9rem;
    color: var(--light-text);
    font-style: italic;
    text-align: center;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
    transition: all 0.3s ease;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.projects-note:hover {
    background-color: rgba(20, 20, 40, 0.8);
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
}

.projects-note i {
    color: var(--accent-color);
    font-size: 1.2rem;
    flex-shrink: 0;
}

.projects-note p {
    margin-bottom: 0;
    line-height: 1.5;
}

@media (max-width: 768px) {
    .projects-note {
        flex-direction: column;
        padding: 1rem;
        gap: 10px;
    }
    
    .projects-note i {
        margin-bottom: 5px;
    }
}

.download-resume-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-top: 1.5rem;
    padding: 0.8rem 1.5rem;
    background: rgba(255, 255, 255, 0.15);
    color: #ffffff;
    border-radius: 30px;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.download-resume-btn:hover {
    background: rgba(255, 255, 255, 0.25);
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.15);
}

.download-resume-btn i {
    margin-right: 0.5rem;
}

.project-card:hover .project-image::before {
    opacity: 0.9;
}

.project-card.flipped .project-inner {
    transform: rotateY(180deg);
}
