/* Card Module Styles */

.card {
    position: absolute;
    width: 80px;
    height: 120px;
    cursor: pointer;
    transition: all 0.3s ease;
    transform-style: preserve-3d;
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
}

.card:hover {
    transform: scale(1.05);
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.4);
}

.card-face {
    position: absolute;
    width: 100%;
    height: 100%;
    border-radius: 8px;
    border: 2px solid #333;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    font-weight: bold;
    backface-visibility: hidden;
    transition: all 0.6s ease;
}

.card-front {
    background: white;
    color: #333;
    transform: rotateY(0deg);
}

.card-back {
    background: linear-gradient(45deg, #1a4c96 0%, #2d5aa0 50%, #1a4c96 100%);
    color: white;
    font-size: 40px;
    transform: rotateY(180deg);
}

/* Face up state */
.card.face-up .card-front {
    transform: rotateY(0deg);
    opacity: 1;
    z-index: 2;
}

.card.face-up .card-back {
    transform: rotateY(180deg);
    opacity: 0;
    z-index: 1;
}

/* Face down state */
.card.face-down .card-front {
    transform: rotateY(-180deg);
    opacity: 0;
    z-index: 1;
}

.card.face-down .card-back {
    transform: rotateY(0deg);
    opacity: 1;
    z-index: 2;
}

/* Highlighted card effect */
.card.highlighted .card-face {
    border: 3px solid #ffd700 !important;
    box-shadow: 
        0 0 10px rgba(255, 215, 0, 0.6),
        0 0 20px rgba(255, 215, 0, 0.4),
        0 0 30px rgba(255, 215, 0, 0.2);
}

/* Card suit colors */
.card-front:has-text("♥"), .card-front:has-text("♦") {
    color: #d32f2f;
}

.card-front:has-text("♠"), .card-front:has-text("♣") {
    color: #333;
}
