body {
    font-family: 'Noto Sans', sans-serif;
    text-align: center;
    background: linear-gradient(to right, #f4f4f4, #eaeaea);
    margin: 0;
    padding: 20px;
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: background 0.5s;
}

.welcome-container {
    background: rgba(255, 255, 255, 0.9);
    border-radius: 20px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
    padding: 40px;
    max-width: 500px;
    margin: auto;
    transition: transform 0.3s;
}

.welcome-container:hover {
    transform: scale(1.02);
}

.welcome-container h1 {
    color: #d9534f;
    font-size: 2.5rem;
    margin-bottom: 10px;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.2);
}

.start-button {
    display: inline-block;
    padding: 15px 30px;
    background: linear-gradient(135deg, #5cb85c, #4cae4c);
    color: white;
    text-decoration: none;
    border-radius: 10px;
    font-size: 18px;
    transition: background 0.3s, transform 0.2s, box-shadow 0.2s;
}

.start-button:hover {
    background: linear-gradient(135deg, #4cae4c, #5cb85c);
    transform: scale(1.05);
}

.level-container {
    background: rgba(255, 255, 255, 0.9);
    border-radius: 20px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
    padding: 40px;
    max-width: 500px;
    margin: auto;
}

.flashcard-container {
    width: 90%;
    max-width: 500px;
    margin: auto;
}

.flashcard {
    width: 100%;
    aspect-ratio: 4 / 3;
    position: relative;
    perspective: 1000px;
}

.flashcard > div {
    width: 100%;
    height: 100%;
    position: absolute;
    backface-visibility: hidden;
    display: flex;
    justify-content: center;
    align-items: center;
    border: 2px solid #ccc;
    background-color: #fff;
    border-radius: 15px;
    box-shadow: 0 0 15px rgba(0, 0, 0, 0.3);
    transition: transform 0.6s, box-shadow 0.3s;
}

.front {
    z-index: 2;
}

.back {
    transform: rotateY(180deg);
}

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

.flipped .back {
    transform: rotateY(0);
}

h2, h3 {
    margin: 0;
    font-size: 1.5rem;
    word-wrap: break-word;
    color: #333; /* Darker text for readability */
}

button {
    margin-top: 20px;
    padding: 10px 20px;
    background-color: #4CAF50;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    transition: background-color 0.3s, transform 0.2s;
    width: 80%;
}

button:hover {
    background-color: #45a049;
}

.options {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-top: 20px;
}

.options button {
    width: 80%;
    padding: 15px;
    font-size: 1.1rem;
    margin: 5px 0;
    background-color: #5cb85c;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    transition: background-color 0.3s, transform 0.2s;
}

.options button:hover {
    background-color: #4cae4c;
    transform: scale(1.05);
}

/* Feedback styles */
.correct {
    background-color: #d4edda;
    color: #155724;
    border: 2px solid #c3e6cb;
    transition: all 0.5s;
}

.wrong {
    background-color: #f8d7da;
    color: #721c24;
    border: 2px solid #f5c6cb;
    transition: all 0.5s;
}

/* Centering for level selection */
.level-container {
    text-align: center;
    margin-top: 50px;
    background: #fff;
    border-radius: 15px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    padding: 30px;
    width: 80%;
    max-width: 600px;
}
