.container {
    display: flex;
    align-items: center;
    justify-content: center;
}

.infobox {
    padding-left: 20px;
}

.nunito-font {
    font-family: "Nunito", sans-serif;
    font-optical-sizing: auto;
    font-weight: 600;
    font-style: normal;
    color: white;
}

:root {
    --rotation-speed: 10s;
}
body {
    margin: 0;
    font-family: 'Nunito', sans-serif;
    background: linear-gradient(-45deg, #141e30, #243b55, #1a2a6c, #2a3a7c);
    background-size: 400% 400%;
    animation: gradient 15s ease infinite;
    color: #fff;
    text-align: center;
}

.speed-control {
    position: fixed;
    top: 10px;
    right: 10px;
    background: rgba(255, 255, 255, 0.1);
    padding: 10px;
    border-radius: 5px;
    z-index: 1000;
}

.speed-control label {
    display: block;
    margin-bottom: 5px;
    color: #fff;
}

.speed-control input[type="range"] {
    width: 100%;
}

.speed-control #speed-value {
    display: inline-block;
    margin-top: 5px;
    color: #fff;
}
.friends {
    margin: 40px auto;
    width: 80%;
    max-width: 1000px;
}

.friends-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 20px;
}

.friend-card {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    padding: 20px;
    width: 200px;
    text-align: center;
    transition: transform 0.3s, box-shadow 0.3s;
}

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

.friend-card img {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    margin-bottom: 10px;
    animation: float 3s ease-in-out infinite, spin var(--rotation-speed) linear infinite;
}

.friend-card h4 {
    margin: 10px 0;
    color: #fff;
}

.friend-card a {
    display: inline-block;
    margin-top: 10px;
    padding: 5px 10px;
    background-color: #4CAF50;
    color: white;
    text-decoration: none;
    border-radius: 5px;
    transition: background-color 0.3s;
}

.friend-card a:hover {
    background-color: #45a049;
}
@keyframes gradient {
    0% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
    100% {
        background-position: 0% 50%;
    }
}
@keyframes float {
    0% {
        transform: translatey(0px) rotate(0deg);
    }
    50% {
        transform: translatey(-20px) rotate(180deg);
    }
    100% {
        transform: translatey(0px) rotate(360deg);
    }
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }
    100% {
        transform: rotate(360deg);
    }
}
.container {
    margin: 50px auto;
    text-align: center;
}

.avatar {
    box-shadow: 0 8px 15px rgba(0, 0, 0, 0.2);
    transition: transform 0.3s, box-shadow 0.3s;
    border-radius: 15%;
    animation: float 3s ease-in-out infinite, spin var(--rotation-speed) linear infinite;
}

.avatar:hover {
    transform: scale(1.05);
    box-shadow: 0 12px 25px rgba(0, 0, 0, 0.3);
    animation-play-state: paused;
}

.infobox {
    margin-top: 20px;
}

h1 {
    font-size: 2.5rem;
    font-weight: 800;
    margin: 10px 0;
}

h4 {
    font-size: 1.2rem;
    font-weight: 300;
    color: #b2b2b2;
    margin: 10px 0;
}

.social-links {
    margin: 20px 0;
}

.social-links a {
    margin: 0 10px;
    display: inline-block;
    transition: transform 0.3s;
}

.social-links a:hover {
    transform: scale(1.1);
}

.social-links img {
    width: 48px;
    height: 48px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}
.bordered {
    border-radius: 50%;
}

h3 {
    margin-top: 30px;
    color: #f4f4f4;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    font-size: 1.5rem;
}

.github-card img {
    border-radius: 15px;
    box-shadow: 0 8px 15px rgba(0, 0, 0, 0.3);
}

.github-card {
    margin: 20px auto;
    width: 80%;
    max-width: 600px;
    text-align: center;
}

.projects {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 20px;
    margin: 40px auto;
}

.project {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    padding: 20px;
    width: 250px;
    transition: transform 0.3s;
    position: relative;
    overflow: hidden;
}

.project:hover {
    transform: translateY(-10px);
}

.project h4 {
    color: #fff;
    margin-bottom: 10px;
}

.project p {
    font-size: 0.9rem;
    color: #ddd;
    margin-bottom: 15px;
}

.project-link {
    display: inline-block;
    padding: 5px 10px;
    background-color: #2196F3;
    color: white;
    text-decoration: none;
    border-radius: 5px;
    font-size: 0.9rem;
    transition: background-color 0.3s, transform 0.3s;
}

.project-link:hover {
    background-color: #1e87db;
    transform: translateY(-2px);
}

.notification {
    position: fixed;
    top: -100px;
    left: 50%;
    transform: translateX(-50%);
    background-color: #4CAF50;
    color: white;
    padding: 15px 20px;
    border-radius: 5px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    transition: top 0.5s ease-in-out;
    z-index: 1001;
}

.notification.show {
    top: 20px;
}

@keyframes shake {
    0% { transform: translateX(-50%) rotate(0deg); }
    25% { transform: translateX(-50%) rotate(5deg); }
    50% { transform: translateX(-50%) rotate(0deg); }
    75% { transform: translateX(-50%) rotate(-5deg); }
    100% { transform: translateX(-50%) rotate(0deg); }
}

.notification.shake {
    animation: shake 0.5s ease-in-out;
}

/* Мобильная адаптация */
@media screen and (max-width: 768px) {
    body {
        padding: 10px;
    }

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

    .avatar {
        margin-right: 0;
        margin-bottom: 20px;
    }

    .infobox {
        text-align: center;
    }

    .github-card img {
        width: 100%;
        height: auto;
    }

    .projects {
        flex-direction: column;
    }

    .project {
        width: 100%;
        margin-bottom: 20px;
    }

    .friends-container {
        flex-direction: column;
        align-items: center;
    }

    .friend-card {
        width: 80%;
        margin-bottom: 20px;
    }

    .social-links img {
        width: 40px;
        height: 40px;
    }

    .speed-control {
        flex-direction: column;
        align-items: center;
    }

    #speed-slider {
        width: 80%;
        margin: 10px 0;
    }
}

.music-player {
    margin: 20px;
    text-align: center;
}

#music-toggle {
    border: 2px solid var(--accent);
    padding: 15px 30px;
    font-size: 1.1rem;
    transition: all 0.3s;
}

#music-toggle:hover {
    background-color: #7c3aed;
}


/* Новые переменные цветов */
:root {
    --accent: #7c3aed;
    --accent-hover: #6d28d9;
    --neon-shadow: 0 0 15px var(--accent);
}

/* Глобальные улучшения */
body {
    line-height: 1.6;
    overflow-x: hidden;
}

/* Анимированный градиентный заголовок */
h1 {
    background: linear-gradient(45deg, #7c3aed, #3b82f6);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.2);
    animation: hue-shift 8s infinite alternate;
}

/* Неоновые карточки */
.project, .friend-card {
    position: relative;
    overflow: hidden;
    border: 1px solid rgba(124, 58, 237, 0.3);
    transition: 0.4s;
}

.project::before, .friend-card::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(45deg, transparent, rgba(124, 58, 237, 0.1), transparent);
    transform: rotate(45deg);
    pointer-events: none;
}

.project:hover, .friend-card:hover {
    border-color: var(--accent);
    box-shadow: var(--neon-shadow);
}

/* Параллакс эффект */
.container::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('data:image/svg+xml,<svg viewBox="0 0 200 200" xmlns="http://www.w3.org/2000/svg"><path fill="%237C3AED" d="M45,-74C58.4,-69.3,69.3,-58.4,74.6,-45C79.9,-31.6,79.6,-15.8,79.3,0.1C79,16.1,78.7,32.2,71.3,43.2C63.9,54.2,49.3,60.1,35.7,65.6C22.1,71.1,9.5,76.3,-3.5,81.2C-16.5,86.1,-33,90.8,-44.5,84.7C-56,78.7,-62.5,62,-69.2,46.7C-75.9,31.4,-82.7,17.7,-83.9,3.1C-85.1,-11.6,-80.7,-27.2,-73.1,-40.4C-65.6,-53.6,-54.9,-64.4,-42.3,-69.8C-29.7,-75.2,-15.3,-75.3,0.3,-75.8C15.9,-76.3,31.7,-77.2,45,-74Z"/></svg>');
    opacity: 0.05;
    z-index: -1;
    animation: parallax 20s linear infinite;
}

/* Анимации */
@keyframes hue-shift {
    0% { filter: hue-rotate(0deg); }
    100% { filter: hue-rotate(360deg); }
}

@keyframes parallax {
    0% { transform: translate(0,0); }
    100% { transform: translate(-50%,-50%); }
}

/* Улучшенные кнопки */
#music-toggle, .project-link {
    background: linear-gradient(45deg, var(--accent), #3b82f6);
    border: none;
    padding: 12px 24px;
    border-radius: 50px;
    position: relative;
    overflow: hidden;
    transition: 0.3s;
}

#music-toggle::after, .project-link::after {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: rgba(255,255,255,0.1);
    transform: rotate(45deg);
    transition: 0.3s;
}

#music-toggle:hover, .project-link:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(124, 58, 237, 0.4);
}

/* Гласс морфизм */
.speed-control, .github-card {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255,255,255,0.1);
}

/* Адаптация под мобильные */
@media (max-width: 768px) {
    .project, .friend-card {
        width: 90%;
        margin: 15px auto;
    }
    
    .avatar {
        width: 150px;
        height: 150px;
    }
}