body {
    font-family: sans-serif;
    line-height: 1.6;
    margin: 0;
    background-color: #f4f4f4;
    color: #333;
}

.container {
    max-width: 800px;
    margin: auto;
    overflow: auto;
    padding: 0 20px;
}

h1, h2 {
    color: #0056b3;
}

ul {
    list-style: none;
    padding: 0;
}

li {
    margin-bottom: 10px;
}

a {
    text-decoration: none;
    color: #007bff;
}

a:hover {
    text-decoration: underline;
}

nav {
    background-color: #0056b3;
    padding: 10px;
    text-align: center;
    border-radius: 5px;
    margin-bottom: 20px;
    display: flex;
    justify-content: center;
    align-items: center;
}

nav a {
    color: white;
    margin: 0 15px;
    text-decoration: none;
    font-weight: bold;
}

nav a:hover {
    text-decoration: underline;
}

.dropdown {
    position: relative;
    display: inline-block;
}

.dropbtn {
    color: white;
    margin: 0 15px;
    text-decoration: none;
    font-weight: bold;
    background-color: transparent;
    border: none;
    cursor: pointer;
    font-size: 1em;
    font-family: inherit;
}

.dropdown-content {
    display: none;
    position: absolute;
    background-color: #f9f9f9;
    min-width: 160px;
    box-shadow: 0px 8px 16px 0px rgba(0,0,0,0.2);
    z-index: 1;
    border-radius: 5px;
}

.dropdown-content a {
    color: black;
    padding: 12px 16px;
    text-decoration: none;
    display: block;
    text-align: left;
}

.dropdown-content a:hover {background-color: #f1f1f1;}

.dropdown-content.show {
    display: block;
}

form ol {
    list-style: decimal;
    padding-left: 20px;
}

input[type="text"] {
    border: 1px solid #ccc;
    padding: 8px;
    border-radius: 4px;
    width: 200px;
}

.exercise {
    background: #fff;
    padding: 20px;
    margin-bottom: 20px;
    border-radius: 5px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.exercise ol {
    padding-left: 25px;
}

.fill-in-blanks {
    list-style: none;
    padding-left: 0;
    counter-reset: exercise-counter;
}

.fill-in-blanks li {
    counter-increment: exercise-counter;
    margin-bottom: 15px;
}

.fill-in-blanks li::before {
    content: counter(exercise-counter) ". ";
    margin-right: 8px;
    font-weight: bold;
    min-width: 20px;
}

.translation-exercise li {
    margin-bottom: 15px;
}

.exercise input[type="text"] {
    margin: 0 5px;
}

.word-bank {
    background-color: #e7f3fe;
    border-left: 5px solid #007bff;
    padding: 15px;
    margin: 20px 0;
    border-radius: 0 5px 5px 0;
}

.word-bank strong {
    color: #0056b3;
}



.translation-exercise textarea {
    width: 100%;
    padding: 8px;
    margin-top: 5px;
    border-radius: 4px;
    border: 1px solid #ccc;
    resize: vertical;
    box-sizing: border-box;
}

.banked-cloze-words {
    background: #e7f3fe;
    border: 1px solid #bde0fe;
    padding: 20px;
    margin: 20px auto;
    border-radius: 5px;
    max-width: 600px;
}

.banked-cloze-words ol {
    list-style: none;
    padding: 0;
    margin: 0;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 10px;
}

.banked-cloze-words ol li {
    font-weight: bold;
}

.cloze-article p {
    line-height: 2;
}

.cloze-article input[type="text"] {
    width: 30px;
    text-align: center;
    border: none;
    border-bottom: 2px solid #007bff;
    font-weight: bold;
    color: #0056b3;
    background-color: transparent;
}

.listening-exercise audio {
    width: 100%;
    margin-bottom: 20px;
}

.listening-exercise .questions {
    padding-left: 20px;
}

.listening-exercise .questions > li {
    margin-bottom: 20px;
}

.listening-exercise .options {
    list-style-type: none;
    padding-left: 0;
    margin-top: 10px;
}

.listening-exercise .options li {
    margin-bottom: 8px;
}

.listening-exercise .options label {
    cursor: pointer;
}

#back-to-top-btn {
    display: none;
    position: fixed;
    bottom: 30px;
    right: 30px;
    z-index: 99;
    border: none;
    outline: none;
    background-color: rgba(0, 86, 179, 0.7);
    color: white;
    cursor: pointer;
    padding: 15px;
    border-radius: 50%;
    font-size: 18px;
    width: 50px;
    height: 50px;
    text-align: center;
    line-height: 20px;
    transition: opacity 0.3s, visibility 0.3s;
}

#back-to-top-btn:hover {
    background-color: rgba(0, 86, 179, 1);
}
