* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}
.difficulty-title {
    color: #333;
    margin: 3rem 0 1rem;
    font-size: clamp(1.2rem, 3vw, 2rem);
    text-align: left;
    padding-left: 2rem;
}

.difficulty-title:first-of-type {
    margin-top: 1rem;
}
body {
    font-family: Arial, sans-serif;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    background-color: #f0f0f0;
    margin: 0;
    padding: 1rem;
}
.container {
    text-align: center;
    width: 100%;
    max-width: 1200px;
}
h1 {
    margin-bottom: 2rem;
    color: #333;
    font-size: clamp(1.5rem, 4vw, 2.5rem);
}
.flashcard-container {
    perspective: 1000px;
    margin: 2rem auto;
    width: 100%;
    max-width: min(90vw, 800px);  /* Increased from 500px */
    aspect-ratio: 3/2;
}.card-front, .card-back {
    position: absolute;
    width: 100%;
    height: 100%;
    backface-visibility: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: clamp(20px, 4vw, 40px);  /* Increased padding */
    border-radius: 15px;  /* Slightly larger radius */
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
    font-size: clamp(1.2rem, 4vw, 2rem);  /* Larger font size */
}.card-back p {
    color: #4CAF50;  /* Same as background color */
    transition: color 0.8s ease;
    transition-delay: 0.4s;  /* Delay until flip is mostly done */
}

.card-back p.show-answer {
    color: white;  /* Change to white when shown */
}

.card-back {
    background-color: #4CAF50;
    transform: rotateY(180deg);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 30px 20px;
}
.card-inner {
    position: relative;
    width: 100%;
    height: 100%;
    text-align: center;
    transition: transform 0.8s;
    transform-style: preserve-3d;
}
/* Remove or comment out the hover behavior */
/* .flashcard:hover .card-inner {
    transform: rotateY(180deg);
} */

/* Add a class for the flipped state */
.card-inner.is-flipped {
    transform: rotateY(180deg);
}
.card-front {
    background-color: white;
}
.card-back {
    background-color: #4CAF50;
    color: #4CAF50;
    transform: rotateY(180deg);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 30px 20px;
}

.feedback-buttons {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-top: 20px;
}

.feedback-buttons button {
    padding: 8px 16px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 0.9rem;
    color: white;
    transition: opacity 0.3s;
}

#stillLearningBtn {
    background-color: #ff9800;
    min-width: 160px;
}

#knewThisBtn {
    background-color: #2196F3;
    min-width: 100px;
}

.feedback-buttons button:hover {
    opacity: 0.8;
}
.card-packs {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    padding: 2rem;
    max-width: 1200px;
    margin: 0 auto;
}
.pack-card {
    background-color: white;
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
    cursor: pointer;
    transition: transform 0.3s, box-shadow 0.3s;
}
.pack-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 6px 12px rgba(0,0,0,0.15);
}
.pack-card h2 {
    color: #333;
    margin-bottom: 1rem;
}
.controls {
    margin-top: 2rem;
    padding: 1rem;
    display: flex;
    justify-content: center;
    gap: 1rem;
    flex-wrap: wrap;
}
.controls button {
    padding: 10px 20px;
    margin: 0 10px;
    font-size: 16px;
    cursor: pointer;
    color: white;
    border: none;
    border-radius: 5px;
    transition: background-color 0.3s;
}

#prevBtn, #nextBtn {
    min-width: 100px;
    background-color: #4CAF50;
}

#randomBtn {
    background-color: #2196F3;
}

#stillLearningBtn {
    background-color: #ff9800;
    min-width: 160px;
}

#knewThisBtn {
    background-color: #4CAF50;
    min-width: 100px;
}
.controls button:hover {
    opacity: 0.9;
}
.card-back {
    position: relative;
    padding-bottom: 60px !important;
}
.controls button {
    padding: 10px 20px;
    margin: 0 10px;
    font-size: 16px;
    cursor: pointer;
    background-color: #4CAF50;
    color: white;
    border: none;
    border-radius: 5px;
    transition: background-color 0.3s;
}

#randomBtn {
    background-color: #2196F3;
}

#randomBtn:hover {
    background-color: #1976D2;
}
.controls button:hover {
    background-color: #45a049;
}

#prevBtn, #nextBtn {
    min-width: 100px;
}
.back-button {
    display: inline-block;
    margin: 1rem;
    padding: 0.5rem 1rem;
    text-decoration: none;
    color: #4CAF50;
    font-weight: bold;
}

.back-button:hover {
    text-decoration: underline;
}