html, body {
    margin: 0;
    padding: 0;
    min-height: 100vh;
    height: 100%;
    display: flex;
    flex-direction: column;
    background-color: #2b2b2b;
    color: white;
    font-family: 'Arial', sans-serif;
}

/* Контейнер для всего основного контента */
.tarot-container {
    flex: 1; /* Этот элемент растет, занимая все доступное пространство выше футера */
    text-align: center;
    margin: 20px auto;
    max-width: 1024px;
    padding: 0 15px; /* Добавляем отступы */
}

/* Обновляем стили для кнопок */
button {
    background-color: #444;
    color: white;
    padding: 10px 20px;
    border: none;
    cursor: pointer;
    font-size: 18px;
    margin-bottom: 20px;
}

button:hover {
    background-color: #666;
}

/* Карты */
.cards {
    display: flex;
    justify-content: center;
    gap: 20px;
    flex-wrap: wrap; /* Добавляем перенос карт на маленьких экранах */
}

.card {
    width: 160px;
    height: 250px;
    perspective: 1000px;
    position: relative;
    margin: 10px;
}

.card-inner {
    position: relative;
    width: 100%;
    height: 100%;
    transition: transform 0.6s;
    transform-style: preserve-3d;
}

.card.flipped .card-inner {
    transform: rotateY(180deg);
}

.card-front, .card-back {
    position: absolute;
    width: 100%;
    height: 100%;
    backface-visibility: hidden;
    border-radius: 10px;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.5);
}

.card-front {
    background-size: cover;
    background-repeat: no-repeat;
    background-position: center;
    transform: rotateY(180deg);
}

.card-back {
    background-image: url('back-of-card2.webp');
    background-size: cover;
}

/* Информация о картах */
#card-info {
    overflow-y: auto;
    width: 100%;
    margin-top: 20px;
    padding: 10px 0;
    background-color: #333;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.5);
    display: flex;
    flex-direction: column;
    gap: 10px;
    font-size: 16px;
    color: #e0b000;
    font-family: 'Georgia', serif;
    text-shadow: 2px 2px 5px rgba(0, 0, 0, 0.5);
    letter-spacing: 2px;
}

.card-info-block h2 {
    font-size: 20px;
    margin: 0;
}

.card-info-block p {
    margin: 5px 0;
    padding: 0 40px;
}

.question {
    font-style: italic;
}

.hidden {
    visibility: hidden;
}

/* Заголовок */
.tarot-heading {
    font-size: 36px;
    color: #e0b000;
    font-family: 'Georgia', serif;
    margin-bottom: 30px;
    text-shadow: 2px 2px 5px rgba(0, 0, 0, 0.5);
    letter-spacing: 2px;
}

/* Анимация появления кнопки */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: scale(0.9);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

/* Анимация тряски при нажатии */
@keyframes shake {
    0% { transform: translate(0, 0); }
    25% { transform: translate(3px, 0); }
    50% { transform: translate(-3px, 0); }
    75% { transform: translate(3px, 0); }
    100% { transform: translate(0, 0); }
}

/* Анимация исчезновения кнопки */
@keyframes fadeOut {
    from {
        opacity: 1;
    }
    to {
        opacity: 0;
    }
}

/* Кнопка "Разложить заново" */
.reshuffle-button {
    display: none;
    position: sticky;
    bottom: 20px;
    right: 20px;
    padding: 10px 20px;
    background-color: #444;
    border: none;
    cursor: pointer;
    font-size: 18px;
    border-radius: 5px;
    opacity: 0;
    animation: fadeIn 0.5s forwards;
    color: #e0b000;
    font-family: 'Georgia', serif;
    text-shadow: 2px 2px 5px rgba(0, 0, 0, 0.5);
    letter-spacing: 2px;
    margin: 10px auto 30px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.5);
}

.reshuffle-button:hover {
    background-color: #666;
}

/* Класс для исчезновения кнопки */
.fadeOut {
    animation: fadeOut 0.25s forwards;
}

/* Контейнер для карт */
.cards {
    position: relative; /* Позиционирование для добавления карт рядом */
    display: flex; /* Используем flex для позиционирования карт */
    gap: 10px; /* Добавляем промежуток между картами */
    justify-content: center;
    align-items: center;
    margin-top: 20px;
}

/* Карты, которые появляются с анимацией броска */
.card {
    position: relative; /* Каждая карта будет располагаться рядом */
    transform-origin: center center;
    transition: transform 0.6s;
}

/* Анимация броска карты сверху */
@keyframes throwCard {
    0% {
        transform: translateY(-500px) rotate(0deg) scale(0.8);
        opacity: 0;
    }
    100% {
        transform: translateY(0) rotate(var(--random-rotation, 10deg)) scale(1);
        opacity: 1;
    }
}


/* Анимация покачивания для открытых карт */
@keyframes sway {
    0% {
        transform: rotate(0deg);
    }
    50% {
        transform: rotate(5deg);
    }
    100% {
        transform: rotate(0deg);
    }
}


/* Футер */
.site-footer {
    background-color: #222;
    color: #e0b000;
    text-align: center;
    padding: 20px;
    border-top: 1px solid #444;
    font-family: 'Georgia', serif;
    width: 100%; /* Футер занимает всю ширину */
}

.site-footer p {
    margin: 10px 0;
    font-size: 14px;
}

.footer-links {
    list-style: none;
    padding: 0;
    margin: 10px 0;
}

.footer-links li {
    display: inline-block;
    margin-right: 10px;
}

.footer-links a {
    color: #e0b000;
    text-decoration: none;
}

.footer-links a:hover {
    text-decoration: underline;
}

/* Стили для формы подписки */
.subscribe-form {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-top: 15px;
}

.subscribe-form input[type="email"] {
    padding: 10px;
    border-radius: 5px;
    border: 1px solid #666;
    font-size: 14px;
    margin-right: 10px;
    color: #333;
}

.subscribe-form button {
    padding: 10px 20px;
    background-color: #e0b000;
    border: none;
    color: #333;
    cursor: pointer;
    border-radius: 5px;
}

.subscribe-form button:hover {
    background-color: #ffcc00;
}
