/* Custom styles */
body {
    background-image: url('../images/Background.png');
    background-size: cover;
    background-repeat: repeat;
    background-attachment: fixed;
    perspective: 1000px;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.card-container {
    aspect-ratio: 9/16;  /* Tỷ lệ 1080x1920 */
    width: 100%;
    max-width: 400px;
    height: calc(100vh - 200px); /* Chiều cao tối đa trừ đi space cho header và buttons */
    max-height: 800px;
    margin: 0 auto;
    position: relative;
    transform-style: preserve-3d;
}

.card {
    position: absolute;
    width: 100%;
    height: 100%;
    transform-style: preserve-3d;
    transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

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

.card-face {
    position: absolute;
    width: 100%;
    height: 100%;
    backface-visibility: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 0.5rem;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

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

.card-back {
    transform: rotateY(0deg);
}

.card img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    border-radius: 0.5rem;
}

/* Carousel styles */
.carousel-container {
    width: 100%;
    overflow: hidden;
    position: relative;
    padding: 20px 0;
    height: calc(100vh - 100px);
    display: flex;
    flex-direction: column;
}

.carousel-track {
    display: flex;
    transition: transform 0.5s ease-in-out;
    gap: 20px;
    padding: 0 20%;
    height: 100%;
}

.carousel-card {
    min-width: 300px;
    height: 80vh;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 1rem;
    padding: 1rem;
    transform: scale(0.9);
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
}

.carousel-card.active {
    transform: scale(1);
}

.carousel-nav {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-top: 20px;
}

.carousel-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.3);
    cursor: pointer;
    transition: all 0.3s ease;
}

.carousel-dot.active {
    background: rgba(255, 255, 255, 0.8);
    transform: scale(1.2);
}

/* Game container styles */
.game-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: space-between;
    min-height: calc(100vh - 100px);
    padding: 20px 0;
}

.button-container {
    margin-top: 20px;
    display: flex;
    gap: 20px;
    width: 100%;
    justify-content: center;
}

/* Hover effects */
.card-container:hover {
    transform: translateZ(20px);
    transition: transform 0.3s ease;
}

/* Animation for card flip */
@keyframes flip {
    0% { transform: rotateY(0deg); }
    100% { transform: rotateY(180deg); }
}

.flip-animation {
    animation: flip 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Card shine effect */
.card::after {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    background: linear-gradient(
        225deg,
        rgba(255, 255, 255, 0) 0%,
        rgba(255, 255, 255, 0.2) 50%,
        rgba(255, 255, 255, 0) 100%
    );
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
    border-radius: 0.5rem;
}

.card:hover::after {
    opacity: 1;
}

/* Navigation buttons */
.carousel-button {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    z-index: 10;
}

.carousel-button:hover {
    background: rgba(255, 255, 255, 0.2);
}

.carousel-button.prev {
    left: 5%;
}

.carousel-button.next {
    right: 5%;
} 