/* Основные стили */
body {
    margin: 0;
    font-family: 'Segoe UI', sans-serif;
    background-color: #f5dede;
    color: #9f5f5f;
    
}

.container {
    width: 90%;
    max-width: 64rem;
    margin: 0 auto;
    font-family: 'Times New Roman', Times, serif;
}

/* Hero */
.hero  {
    height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    background: linear-gradient(120deg, #ffecd2, #fcb69f);
    text-align: center;
}

.hero h1 {
    font-size: 3rem;
    margin: 0;
}

.hero p {
    font-size: 1.5rem;
    margin: 0.8rem 0 1.2rem;
}

.hero-photo-centered {
    margin-bottom: 3rem;
    /* Отступ до имени */
}

.hero-photo-centered img {
    width: 20rem;
    /* Делаем его не слишком большим */
    height: 20rem;
    border-radius: 50%;
    object-fit: cover;
    border: 0.5rem solid #765252;
    box-shadow: 0 1rem 2.5rem rgba(0, 0, 0, 0.1);
}

.btn {
    display: inline-block;
    padding: 0.8rem 1.5rem;
    background-color: #675555;
    color: #1deb43;
    text-decoration: none;
    border-radius: 0.6rem;
    transition: 0.3s;
}

.btn:hover {
    background-color: #433333;
}

/* About */
.about,
.projects,
.skills,
.contact {
    padding: 5rem 0;
    text-align: center;
    font-size: 2rem;
}

/* Projects */
.project-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(30rem, 1fr));
    gap: 3rem;
}


.project-card {
    background: #e9c2c2;
    border-radius: 1.2rem;
    border: 0.1rem solid #e3a7a7;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    overflow: hidden;
    text-align: center;
   
}

.project-card:hover {
    transform: translateY(-0.8rem);
    box-shadow: 0 1.5rem 3rem rgba(0, 0, 0, 0.08);
}

.project-card img {
    width: 100%;
    border-radius: 0.9rem;
}

.skills-list {
    display: flex;
    justify-content: center;
    gap: 1.25rem;
    padding: 1rem 0;
    list-style: none;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    
}

.skills-list::-webkit-scrollbar {
    display: none;
    
}


/* Стили для самих маленьких иконок в кнопках */
.skills-list li img {
    width: 2.4rem;
    height: 2.4rem;
    object-fit: contain;
   
}



.skills-list li {
    scroll-snap-align: center;
    flex: 0 0 auto;
    padding: 0.8rem 1.5rem;
    background-color: #675555;
    color: #e88383;
    border-radius: 0.6rem;
    cursor: pointer;
    transition: color 0.3s;
    padding: 0.8rem 1.5rem;
    display: flex;
    align-items: center;
    gap: 1rem;
}


.skills-list li:hover {
    color: #007bff;
    /* Подсветка при наведении */
}

.skills-list li:hover img {
    transform: scale(1.2);
    transition: 0.3s;
}

/* Цвет для активной кнопки, когда фото открыто */
.skills-list li.active {
    background-color: #433333;
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.3);
    transform: translateY(1px);
}

.skills-list li img {
    filter: drop-shadow(0 0 5px rgba(255, 255, 255, 0.5));
}

.skill-preview {
    display: none;
    margin-top: 1.8rem;
    text-align: center;
    animation: fadeIn 0.5s ease;
}

.skill-preview img {
    border-radius: 0.9rem;
    box-shadow: 0 0.2rem 1rem rgba(0, 0, 0, 0.2);
    max-width: 90%;
    width: 40rem;
    border-radius: 0.9rem;
    box-shadow: 0 0.2rem 1rem rgba(0, 0, 0, 0.2);
        
}


/* Fade-in animation */
.fade-in {
    opacity: 0;
    transform: translateY(20px);
    transition: 0.6s ease-out;
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}


.container h2 {
    font-size: 2rem;
    color: #6d8637;
}

.container p  {
    color: #ee6a05;
    font-weight: bold;
    font-style: italic;
}



@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Мобильная версия */
@media (max-width: 768px) {
    .project-grid {
        grid-template-columns: 1fr;
    }

    .project-content {
        text-align: center;
    }

    .project-btns {
        justify-content: center;
    }

    .skills-list {
        justify-content: flex-start;
    }
}