/* Загальні стилі */
body {
    margin: 0;
    padding: 0;
    background-color: #111310;;
    color: #fff;
    overflow: hidden;
}

*, ::after, ::before {
    box-sizing: border-box;
}

/* ====== Заголовки ====== */
h1, h2 {
    font-family: 'Neue Machina', sans-serif;
    font-weight: bold;
    text-transform: uppercase; /* Робить заголовки стильними */
    letter-spacing: 1.5px; /* Покращує читабельність */
    color: #ffffff; /* Чистий білий колір */
}

/* ====== Текст та посилання ====== */
a, p {
    font-family: 'Neue Machina', sans-serif;
    font-size: 1.2em;
    color: #e0e0e0; /* Трохи м’якший білий для кращого сприйняття */
    line-height: 1.5; /* Додає більше повітря між рядками */
}

/* Анімація для посилань */
a,p {
    text-decoration: none;
    transition: color 0.3s ease-in-out;
}

a,p:hover {
    color: #7300ff; /* Яскравий колір при наведенні */
}

h1:hover, h2:hover {
    color: #7300ff;
}


/* ====== ГОЛОВНІ СТИЛІ NAVBAR ====== */
.navbar {
    display: flex;
    justify-content: space-between; /* Вирівнюємо контент між лівим і правим краєм */
    align-items: center;
    padding: 10px 20px;
    background-color: #333;
    position: fixed;
    width: 100%;
    height: 60px;
    z-index: 1000;
    top: 0;
}

/* Список навігації */
.nav-list {
    list-style: none;
    display: flex;
    align-items: center;
    gap: 15px; /* Відстань між елементами */
    padding: 0;
    margin: 0;
    flex-grow: 1; /* Дозволяє зайняти всю доступну ширину */
    justify-content: center; /* Центруємо навігаційні елементи */
}

/* Стилі для посилань */
.nav-list a {
    color: white;
    text-decoration: none;
    font-size: 18px;
    padding: 10px 12px;
    transition: 0.3s;
    display: flex;
    align-items: center;
    gap: 5px;
}

/* Ховер ефект */
.nav-list a:hover {
    background-color: #555;
    border-radius: 5px;
}

/* ====== СТИЛІ ПОШУКУ ====== */
.search-bar {
    display: flex;
    align-items: center;
    width: 100px;
}

#searchButton {
    background: none;
    border: none;
    color: white;
    cursor: pointer;
    font-size: 18px;
    padding: 5px;
    display: flex;
    align-items: center;
    gap: 5px;
}

/* Ховер-ефект для кнопки пошуку */
#searchButton:hover {
    background-color: rgba(255, 255, 255, 0.2);
    border-radius: 5px;
    transition: background-color 0.3s ease-in-out;
}

.search-box {
    position: absolute;
    top: 700%; /* Розташування прямо під кнопкою */
    left: 50%;
    transform: translateX(-50%);
    width: 250px;
    padding: 10px;
    border: 1px solid #ccc;
    border-radius: 5px;
    outline: none;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
    background: white; /* Додаємо фон, щоб текст було видно */
    z-index: 100;
}

/* Активний стан */
.search-box.active {
    opacity: 1;
    visibility: visible;
}

/* Розмитий фон */
.search-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(10px);
    z-index: 99;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

/* Плавне відображення фону */
.search-overlay.active {
    opacity: 1;
    visibility: visible;
}

/* ====== СТИЛІ ДЛЯ ВИБОРУ МОВИ ====== */
.language-selector {
    display: flex;
    align-items: center;
}

.language-selector select {
    background-color: #222; /* Темний фон */
    color: #fff; /* Білий текст */
    border: 1px solid #555; /* Легка обводка */
    padding: 5px 10px;
    border-radius: 5px;
    font-size: 14px;
    cursor: pointer;
    outline: none;
}

.language-selector select:hover {
    background-color: #333;
}

.language-selector select:focus {
    border-color: #fff;
}

/* ====== МОБІЛЬНА ВЕРСІЯ (до 768px) ====== */
@media (max-width: 768px) {
    .navbar {
        top: auto;   /* Відміняємо top */
        bottom: 0;   /* Переміщаємо вниз */
        padding: 10px 0;
        box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.2);
    }

    .nav-list {
        display: flex;
        justify-content: space-around;
        align-items: center;
        width: 100%;
        padding: 0;
        margin: 0;
    }

    .nav-list a, 
    .nav-list button {
        font-size: 24px;
        padding: 10px;
        display: flex;
        justify-content: center;
        align-items: center;
        flex-direction: column;
        color: white;
        border: none;
        background: none;
        cursor: pointer;
        transition: transform 0.2s ease-in-out;
    }

    /* Ефект збільшення при натисканні */
    .nav-list a:active, 
    .nav-list button:active {
        transform: scale(1.2);
    }

    /* Ховаємо текст, але показуємо при фокусі */
    .nav-list a span,
    .nav-list button span {
        display: none;
        font-size: 12px;
        margin-top: 5px;
    }

    .nav-list a:focus span,
    .nav-list button:focus span {
        display: block;
    }
    .search-box {
        position: absolute;
        top: -750%; /* Розташування прямо під кнопкою */
    }
}

/* ====== ОСНОВНИЙ КОНТЕЙНЕР ====== */
.main-content {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    gap: 20px;
    padding: 20px;
    background: #121212; /* Темний фон */
    color: #e0e0e0; /* Світлий текст */
}

/* ====== СТИЛІ ДЛЯ БЛОКІВ КОНТЕНТУ ====== */
.content {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    width: 100%;
    max-width: 800px;
    min-height: 250px;
    background: #1e1e1e; /* Темний фон для блоків */
    border-radius: 12px;
    padding: 25px;
    box-shadow: 0 4px 10px rgba(255, 255, 255, 0.1); /* Світла тінь */
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    text-align: center; /* Вирівнювання тексту по центру */
}

/* Анімація при наведенні */
.content:hover {
    transform: translateY(-5px);
    box-shadow: 0 6px 15px rgba(255, 255, 255, 0.15);
}


/* ====== СТИЛІ ДЛЯ КНОПКИ ====== */
.button {
    width: 200px;
    background: linear-gradient(90deg, #7300ff, #a100ff); /* Яскравий акцентний колір */
    color: white;
    border: none;
    padding: 12px 24px;
    font-size: 18px;
    font-weight: bold;
    border-radius: 8px;
    cursor: pointer;
    transition: background 0.3s, transform 0.2s;
}

.button:hover {
    background: linear-gradient(90deg, #8c1bff, #c100ff);
    box-shadow: 0 0 25px rgba(193, 0, 255, 0.6);
    transform: translateY(-3px);
}

/* ====== АДАПТИВНІСТЬ ДЛЯ МОБІЛЬНИХ ====== */
@media (max-width: 768px) {
    .content {
        max-width: 90%;
        min-height: 200px;
        padding: 20px;
    }

    button {
        font-size: 16px;
        padding: 10px 20px;
    }
}

/* ====== ФУТЕР ====== */
footer {
    position: fixed; 
    bottom: 0;
    left: 0;
    right: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    color: #888;
    padding: 15px;
    text-align: center;
    font-size: 1em;
    background: #121212; /* Темний фон, щоб поєднувалося */
}

/* Посилання у футері */
footer a {
    text-decoration: none;
    color: inherit;
    transition: color 0.3s ease;
}

footer a:hover {
    color: #7300ff; /* Світлий ефект при наведенні */
}

/* ====== АДАПТИВНІСТЬ ДЛЯ МОБІЛЬНИХ ====== */
@media (max-width: 768px) {
    footer {
        font-size: 0.9em; /* Трохи зменшуємо розмір */
        bottom: 60px; /* Ще трохи піднімаємо */
        padding: 10px;
    }
}
