/* Гадание «На цветах» */
.mgc-zvety {
    margin: 20px auto;
    -webkit-tap-highlight-color: transparent;
    -webkit-user-select: none;
    user-select: none;
}

/* Три ячейки для выбранных карточек — в двойной рамке («виньетки», как в Ромашке) */
.mgczv-slots {
    display: flex;
    justify-content: center;
    gap: 20px;
    max-width: 400px;
    margin: 0 auto;
    padding: 14px 10px;
}
.mgczv-slot {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100px;
    height: 100px;
    border: 1px solid #8b5a2b;
    outline: 1px solid #c9a77a;
    outline-offset: 3px;
}
.mgczv-slot__num {
    font-size: 30px;
    font-style: italic;
    color: #8b5a2b;
}

/* Карточка в ячейке переворачивается и показывает цветок */
.mgczv-flip {
    display: none;
    width: 100px;
    height: 100px;
    perspective: 1000px;
}
.mgczv-flip__inner {
    position: relative;
    width: 100%;
    height: 100%;
    transition: transform 0.8s;
    transform-style: preserve-3d;
}
.mgczv-flip__inner_open {
    transform: rotateY(180deg);
}
.mgczv-flip__front,
.mgczv-flip__back {
    position: absolute;
    width: 100%;
    height: 100%;
    background-size: cover;
    -webkit-backface-visibility: hidden;
    backface-visibility: hidden;
}
.mgczv-flip__front {
    background-image: url('../img/zvety/back.jpg');
}
.mgczv-flip__back {
    transform: rotateY(180deg);
}

/* Подсказка и толкования: под подсказкой завиток; название цветка — курсивом, малиновым, с завитком, текст по центру */
.mgczv-head {
    margin: 10px 0;
    font-size: 21px;
    font-style: italic;
    color: #6b4423;
    text-align: center;
}
.mgczv-head::after {
    content: '';
    display: block;
    width: 180px;
    height: 10px;
    margin: 4px auto 0;
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 200 12'%3E%3Cpath d='M4 6 C30 6 50 3 78 6 M122 6 C150 3 170 6 196 6' stroke='%238b5a2b' stroke-width='1.2' fill='none' stroke-linecap='round'/%3E%3Ccircle cx='84' cy='6' r='1.7' fill='%238b5a2b'/%3E%3Ccircle cx='116' cy='6' r='1.7' fill='%238b5a2b'/%3E%3Cpath d='M100 11 C95 7.5 91 5.5 91 3 C91 1.2 92.6 0 94.6 0 C97 0 98.6 1.3 100 3 C101.4 1.3 103 0 105.4 0 C107.4 0 109 1.2 109 3 C109 5.5 105 7.5 100 11 Z' fill='%23b0245c'/%3E%3C/svg%3E") center / contain no-repeat;
}
.mgczv-result {
    display: none;
    padding: 10px 20px;
}
.mgczv-result__item {
    margin: 0;
    text-align: center;
}
.mgczv-result__item + .mgczv-result__item {
    margin-top: 22px;
}
.mgczv-result__name {
    display: block;
    font-size: 25px;
    font-style: italic;
    line-height: 1.2;
    color: #b0245c;
}
.mgczv-result__name::after {
    content: '';
    display: block;
    width: 150px;
    height: 10px;
    margin: 3px auto 6px;
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 200 12'%3E%3Cpath d='M4 6 C30 6 50 3 78 6 M122 6 C150 3 170 6 196 6' stroke='%23b0245c' stroke-width='1.2' fill='none' stroke-linecap='round'/%3E%3Ccircle cx='84' cy='6' r='1.7' fill='%23b0245c'/%3E%3Ccircle cx='116' cy='6' r='1.7' fill='%23b0245c'/%3E%3Cpath d='M100 11 C95 7.5 91 5.5 91 3 C91 1.2 92.6 0 94.6 0 C97 0 98.6 1.3 100 3 C101.4 1.3 103 0 105.4 0 C107.4 0 109 1.2 109 3 C109 5.5 105 7.5 100 11 Z' fill='%23b0245c'/%3E%3C/svg%3E") center / contain no-repeat;
}

/* Колода: карточки раскладывает скрипт, он же задаёт высоту */
.mgczv-deck {
    position: relative;
    max-width: 550px;
    min-height: 140px;
    margin: 0 auto;
}
.mgczv-card {
    position: absolute;
    width: 100px;
    height: 100px;
    background: url('../img/zvety/back.jpg') center / cover;
    box-shadow: 0 0 5px rgba(0, 0, 0, 0.8);
    cursor: pointer;
    outline: none;
}
/* Подъём карточки — только с мышью (на телефоне после касания он «залипал») и с клавиатуры */
@media (hover: hover) {
    .mgczv-card:hover {
        border: 1px solid #000;
        box-shadow: 0 0 30px rgba(0, 0, 0, 0.8);
        transform: translate(0, -10%);
    }
}
.mgczv-card:focus-visible {
    border: 1px solid #000;
    box-shadow: 0 0 30px rgba(0, 0, 0, 0.8);
    transform: translate(0, -10%);
}

/* Кнопка */
.mgc-btn-2 {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 235px;
    height: 65px;
    margin: 10px auto 0;
    background-color: #f1e7d4;
    background-image: url('/wp-content/themes/gadanie-online/assets/images/knopka.webp');
    background-size: cover;
    background-position: center;
    color: #4a3828;
    font-size: 17px;
    font-weight: 400;
    font-family: 'EB Garamond', 'Georgia', serif;
    border: none;
    border-radius: 0;
    padding: 0 0 4px 0;
    outline: none;
    cursor: pointer;
    transition: transform 0.2s ease, opacity 0.3s ease;
    -webkit-tap-highlight-color: transparent;
}
.mgc-btn-2:hover {
    transform: translateY(-2px);
}
.mgc-btn-2:active,
.mgc-btn-2.mgc-btn-2--active {
    background-image: url('/wp-content/themes/gadanie-online/assets/images/knopka-1.webp');
    transform: translateY(2px);
}
.mgc-zvety .mgczv-reload {
    margin: 30px auto 20px;
}

@media (max-width: 600px) {
    .mgczv-slot,
    .mgczv-flip {
        width: 85px;
        height: 85px;
    }
}
