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

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Manrope', sans-serif;
    background-color: #0a0a0c;
    color: #e2e2e2;
}

.site-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 30px;
    background-color: rgba(10, 10, 15, 0.8);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    position: sticky;
    top: 0;
    z-index: 100;
}

.logo {
    font-size: 24px;
    font-weight: 800;
    color: #fff;
    letter-spacing: 1px;
}

.logo:active {
    transform: scale(1.2);
    text-shadow: 0 0 2px #000000;
    transition: all 0.5s;
}

.site-header a { 
    color: #fff; 
    text-decoration: none; 
}

.main-nav {
    display: flex;
    gap: 15px;
    padding: 8px 20px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 30px;
}

.main-nav a {
    transition: 0.3s ease;
    padding: 5px 15px;
    border-radius: 20px;
    color: #aaa;
    font-weight: 600;
    font-size: 0.9rem;
}

.main-nav a:hover {
    background-color: rgba(157, 0, 255, 0.2);
    color: #fff;
}

.hero {
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    background-image: radial-gradient(circle at center, rgba(157, 0, 255, 0.15) 0%, transparent 60%);
    position: relative;
}

.hero::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    width: 100%;
    height: 150px;

    background: linear-gradient(to top, rgb(17, 0, 11), transparent);
}

.hero-content {
    text-align: center;
}

.hero-content h1 {
    font-size: 80px;
    font-weight: 800;
    /* Делаем градиентный текст вместо обводки */
    background: linear-gradient(45deg, #fff, #9d00ff);
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    transition: 0.4s ease;
}

.hero-content h1:hover {
    font-size: 100px;
    text-shadow: 0px 0px 15px rgb(255, 255, 255);
}

.hero-content p {
    font-size: 24px;
    color: #aaa;
    letter-spacing: 2px;
    text-transform: uppercase;
    transition: 0.4s ease;
}

.hero-content p:hover {
    font-size: 40px;
    text-shadow: 0px 0px 10px rgb(255, 255, 255);
}

.portfolio { 
    padding: 80px 20px; 
}

.section-title {
    text-align: center;
    font-size: 40px;
    margin-bottom: 50px;
    color: #fff;
    transition: 0.4s ease;
}

.section-title:hover {
    font-size: 70px;
    text-shadow: 0 0 15px #f706ff49;
}

.portfolio-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 30px;
    max-width: 1200px;
    margin: 0 auto;
}

.card {
    width: 350px;
    background-color: rgba(20, 20, 25, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 20px;
    transition: 0.4s ease;
    overflow: hidden;
    position: relative;
}

.image-box {
    position: relative;
}

.card-content {
    padding: 25px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    transition: 0.4s ease;
}

.card-image {
    width: 100%;
    height: 350px;
    object-fit: cover;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.card:hover {
    transform: translateY(-10px);
    border-color: rgba(157, 0, 255, 0.5);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.5), 0 0 20px rgba(157, 0, 255, 0.2);
}

.card-content h2 { 
    font-size: 1.3rem; 
    color: #fff; 
}
.card-content p { 
    font-size: 0.9rem; 
    color: #aaa; 
}

.card-button {
    display: inline-block;
    margin-top: 15px;
    padding: 12px;
    text-align: center;
    background: rgba(157, 0, 255, 0.1);
    border: 1px solid var(--primary, #9d00ff);
    border-radius: 12px;
    color: #fff;
    font-weight: 600;
    transition: 0.3s ease;
}

.card-button:hover {
    background: #9d00ff;
    box-shadow: 0 0 15px rgba(157, 0, 255, 0.5);
}

.card:hover .card-content {
    padding-bottom: 60px;
}

.card-button:hover {
    background-color: rgb(70, 0, 21);
    color: white;
    font-weight: bold;
    box-shadow: 0 0 10px 2px #000000;
}

.card-button:active {
    transform: scale(0.98);
    box-shadow: 0 0 2px #000000;
}

#site-card {
    position: relative;
}

#mika-card {
    position: relative;
}

.click-nose-mika {
    position: absolute;
    color: white;
    border-radius: 50%;

    width: 40px;
    height: 40px;

    left: 57%;
    top: 72%;
}

.click-nose-site {
    position: absolute;
    color: white;
    border-radius: 50%;

    width: 30px;
    height: 30px;

    left: 60%;
    top: 46%;
}

.site-footer-bottom {
    background-color: #050508;
    color: #555;
    padding: 20px;
    text-align: center;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}


@keyframes click-effect_animation {
    from {
        transform: scale(0.2) rotate(0deg);
        opacity: 1;
    }
    to {
        transform: scale(50) rotate(70deg);
        opacity: 0;
    }
}

.click-symbol {
    position: fixed;

    font-size: 30px;
    color: white;
    
    user-select: none;
    display: none;

    animation: click-effect_animation 1.2s ease-out;
}

/* =================================================== */
/*          АДАПТАЦИЯ ДЛЯ МОБИЛЬНЫХ УСТРОЙСТВ          */
/* =================================================== */

/* Применяем стили, если ширина экрана 768px или меньше */
@media (max-width: 768px) {

    .site-header {
        /* Лого и навигация встают друг под другом */
        flex-direction: column;
        padding: 15px;
        /* Добавляем вертикальный отступ между лого и навигацией */
        gap: 15px;
    }

    .main-nav {
        /* Элементы внутри "таблетки" снова горизонтальны */
        flex-direction: row; 
        
        /* Заставляем "таблетку" занять всю доступную ширину */
        width: 100%; 
        
        /* Равномерно распределяем ссылки внутри "таблетки" */
        justify-content: space-around;
        
        /* Убираем лишние отступы, которые были у ссылок */
        padding: 5px;
    }

    .main-nav a {
        /* Убираем внешний отступ, так как justify-content делает всю работу */
        margin-left: 0;
        /* Можно немного уменьшить внутренний отступ для компактности */
        padding: 5px 8px;
    }

    .hero-content h1 {
        font-size: 48px; /* Уменьшаем размер */
        color: white;    /* Делаем текст чисто белым для максимального контраста */

        /* Убираем и обводку, и тень, которые могут давать артефакты */
        -webkit-text-stroke: none;
    }

    .hero-content p {
        font-size: 24px;
        color: white;
        -webkit-text-stroke: none;
    }

    .portfolio {
        /* Уменьшаем боковые отступы секции */
        padding: 50px 20px;
    }

    .portfolio-grid {
        /* Уменьшаем внутренние отступы сетки */
        padding: 20px;
    }

    .section-title {
        font-size: 36px; /* Было 50px */
        padding-top: 20px;
    }

    /* Карточки автоматически перестроятся благодаря flex-wrap,
       но мы можем немного уменьшить их высоту на всякий случай */
    .card-image {
        height: 250px;
    }
}