.currency-container {
    display: flex;
    flex-direction: column;
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding-top: 20px;
    overflow-x: auto; /* Добавление горизонтальной прокрутки для всего блока */
    white-space: nowrap; /* Отключаем перенос строк внутри контейнера */
}

.currency-item {
    display: flex;
    align-items: center;
    padding: 20px;
    border-bottom: 1px solid #ccc;
    min-width: 800px; /* Минимальная ширина для валюты, чтобы все элементы умещались в одной строке */
    transition: background-color 0.3s, box-shadow 0.3s; /* Плавный переход для выделения */
    cursor: pointer; /* Изменение курсора на указатель */
}

.currency-item:hover {
    background-color: #f0f8ff; /* Светло-голубой фон при наведении */
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1); /* Тень при наведении */
}

.currency-flag {
    width: 30px;
    height: 30px;
    margin-right: 10px;
}

.currency-details {
    display: flex;
    align-items: center;
    width: 90%;
}

.currency-code {
    flex: 0 0 20%;
    font-weight: bold;
    display: flex;
    align-items: center;
}

.currency-name {
    flex: 0 0 35%;
    margin-left: 10px;
    display: flex;
    align-items: center;
}

.currency-nominal {
    flex: 0 0 20%;
    margin-left: 10px;
    display: flex;
    align-items: center;
}

.currency-value {
    flex: 0 0 25%;
    margin-left: 10px;
    font-weight: bold;
    display: flex;
    align-items: center;
    justify-content: flex-end;
}

/* Адаптация под мобильные устройства */
@media (max-width: 768px) {
    .currency-item {
        font-size: 0.9em; /* Уменьшение размера шрифта для компактного отображения */
        min-width: 600px; /* Уменьшение минимальной ширины для удобного отображения на мобильных */
    }

    .currency-code,
    .currency-name,
    .currency-nominal,
    .currency-value {
        flex: 0 1 auto; /* Автоматическая ширина для всех элементов */
        margin: 5px 10px; /* Уменьшенные отступы для экономии пространства */
    }

    .currency-value {
        justify-content: flex-start; /* Выравнивание значения курса влево */
    }
}
