/* =========================================
   1. БАЗОВІ НАЛАШТУВАННЯ ТА ФОН
   ========================================= */
   * {
    box-sizing: border-box; /* Теперь padding и border не расширяют элементы */
}
html {
    margin: 0;
    padding: 0;
}

body {
    margin: 0;
    padding: 0;
    font-family: 'JetBrains Mono', monospace; /* [cite: 2] */
    
    /* ФОН: Фіксований на всю сторінку, включаючи футер */
    background-image: url('../image/image-2.png'); /* [cite: 2] */
    background-repeat: no-repeat;
    background-position: center center;
    background-size: cover;
    background-attachment: fixed; /* Фон не рухається при скролі */
    
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* Основний контент займає весь доступний простір */
main {
    flex: 1 0 auto;
}

/* =========================================
   2. ГОЛОВНИЙ КОНТЕЙНЕР (ВІЗИТКА)
   ========================================= */
.container {
    display: flex;
    align-items: center;
    gap: 40px;
    padding: 40px;
    border: 2px solid rgb(0, 212, 255); /* [cite: 2] */
    border-radius: 16px;
    margin: 50px auto;
    width: 75%;
    max-width: 1100px;
    min-height: 480px;
    background: rgba(10, 25, 41, 0.75); /* Темна підкладка для читабельності [cite: 2] */
    box-shadow: 0 10px 30px rgba(0, 212, 255, 0.2);
}

.text-box {
    flex: 1.2;
    text-align: center;
}

.photo-box {
    flex: 1;
    text-align: center;
}

/* Фото профілю */
.photo-box img {
    border-radius: 16px;
    max-width: 100%;
    height: auto;
    display: block;
    margin: 0 auto;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.4);
}

/* =========================================
   3. ТИПОГРАФІКА
   ========================================= */
.profile-name {
    font-size: 2.2rem;
    font-weight: bold;
    color: rgb(78, 143, 221); /* [cite: 2] */
    margin-bottom: 10px;
}

.profile-subtitle {
    font-size: 1.35rem;
    color: rgb(78, 143, 221); /* [cite: 2] */
    margin-bottom: 25px;
}

.profile-description {
    color: rgb(175, 238, 238); /* [cite: 2] */
    font-size: 17.5px;
    line-height: 1.65;
    text-align: justify;
}

/* =========================================
   4. КНОПКИ ДІЙ
   ========================================= */
.action-buttons {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin: 45px auto 70px auto;
    flex-wrap: wrap;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 16px 34px;
    font-size: 15.5px;
    font-weight: bold;
    text-decoration: none;
    border-radius: 12px;
    transition: all 0.35s ease;
    min-width: 230px;
}


.btn-secondary {
    background: transparent;
    color: rgb(175, 238, 238);
    border: 2px solid rgb(0, 212, 255);
}

.btn:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 212, 255, 0.4);
}

/* =========================================
   5. ФУТЕР (КОНТАКТИ)
   ========================================= */
footer {
    flex: 0 0 auto;
    margin-top: 80px;
    padding-bottom: 40px;
    text-align: center;
    background: transparent; /* Щоб було видно загальний фон body */
}

.footer-title {
    color: rgb(78, 143, 221);
    font-size: 1.6rem;
    font-weight: bold;
    margin-bottom: 25px;
}

.footer-contacts {
    display: flex;
    justify-content: center;
    align-items: center; /* Центрування по вертикалі */
    flex-wrap: wrap;
    gap: 30px;
}

.contact-item {
    display: flex;
    align-items: center; /* Центрування іконки та тексту */
    gap: 10px;
    color: rgb(175, 238, 238);
    font-size: 14.5px;
}

/* Іконки в футері */
.contact-item img {
    border-radius: 0 !important;        /* Убираем скругление фона */
    box-shadow: none !important;        /* Убираем тень, создающую контур */
    width: 26px;
    height: 26px;
    object-fit: contain;
    display: block;                     /* Убирает лишние отступы снизу */
}

.contact-item a {
    display: flex;
    align-items: center;
    gap: 10px;
    color: inherit;
    text-decoration: none;
    transition: 0.3s;
}

.contact-item a:hover {
    color: rgb(0, 212, 255);
    transform: translateY(-2px);
}

/* =========================================
   7. МОБІЛЬНА АДАПТАЦІЯ
   ========================================= */
@media (max-width: 768px) {
    body {
        background-attachment: scroll; /* Для кращої продуктивності на мобільних */
    }

    .container {
        flex-direction: column; /* Фото зверху, текст знизу */
        width: 92%;
        padding: 25px;
        min-height: auto;
        gap: 20px;
        margin: 30px auto;
    }

    .photo-box {
        order: -1; /* Фото стає першим елементом у списку */
    }

    .photo-box img {
        width: 180px;
        height: 180px;
        border-radius: 50%; /* На мобільних фото кругле */
        object-fit: cover;
    }

    .profile-description {
        text-align: center; /* Центрування тексту для мобільних */
    }

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

    .btn {
        width: 90%;
        min-width: unset;
    }

    .footer-contacts {
        flex-direction: column;
        gap: 20px;
    }

    .resume-grid {
        flex-direction: column;
    }
}