@import "styles.css";

.card-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    width: 100%;
    max-width: 1200px;
}

.card {
    width: 100%;
    height: 300px;
    perspective: 1000px;
}

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

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

.card-front,
.card-back {
    position: absolute;
    width: 100%;
    height: 100%;
    backface-visibility: hidden;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 20px 40px; 
    border: 1px solid #ddd;
    border-radius: 8px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    font-size: 1.1rem;
    box-sizing: border-box;
}

/* Jemné pastelové barvy pro karty */
.card:nth-child(1) .card-front,
.card:nth-child(1) .card-back {
    background-color: #ffe699;
}

.card:nth-child(2) .card-front,
.card:nth-child(2) .card-back {
    background-color: #FFD9E2;
}

.card:nth-child(3) .card-front,
.card:nth-child(3) .card-back {
    background-color: #FFF9C4;
}

.card:nth-child(4) .card-front,
.card:nth-child(4) .card-back {
    background-color: #E0F2F1;
}

.card:nth-child(5) .card-front,
.card:nth-child(5) .card-back {
    background-color: #d9ffcc;
}

.card:nth-child(6) .card-front,
.card:nth-child(6) .card-back {
    background-color: #f2e6ff;
}

.card-front {
    font-size: 1.4rem;
    font-weight: bold;
}

.card-back {
    transform: rotateY(180deg);
    font-size: 0.9rem;
    line-height: 1.5;
    color: #555;
    text-align: left;
}

@media only screen and (max-width: 800px) {
    .card {
        height: 600px;
    }
}