body {
    font-family: sans-serif;
    display: flex;
    justify-content: center;
    align-items: center;
    height: 98vh;
    margin: 0;
    background: #6a6dfb;
    overflow: hidden; 
    min-width: 400px;
}

header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background: #6669f1;
    padding: 10px;
    text-align: center;
    z-index: 1000; 
    font-weight: bold;
    color: white;
}

.dictionary-container {
    display: flex;
    width: 80%;
    height: 87vh;
    background: white;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
    margin-top: 40px;
}

.letters {
    background: #6669f1;
    color: white;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 10px;
}

.letters ul {
    list-style: none;
    padding: 0;
    width: 100%;
}

.letters ul li {
    padding: 10px;
    text-align: center;
    cursor: pointer;
    border: 1px solid;
    margin-bottom: 5px;
    border-radius: 5px;
    background: rgb(235, 232, 232);
    color: blue;
}

.letters ul li:hover {
    background: green;
    color: white;
}

 #letter-list .active {
    background: #3b48e0;
    color: white;
}


.words {

    width: 80%;
    padding: 20px;
    overflow-y: auto;
    border: 1px solid gray;
}

.words h1, .words h2 {
    margin-top: 0;
}

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

.words ul li {
    padding: 9px 0;
    border-bottom: 1px solid #ddd;
    line-height: 1.5em;
    text-align: justify;
}

.word-details {
    margin-left: 10px;
    font-size: 14px;
    color: #555;
}



li .image img {
position: relative;
width: 100%;
max-height: fit-content;
height: auto;
display: block;
margin: 0 auto;
}



a {
    color:#2b7003;
    text-decoration: none;
    font-size: large;
}

@media (min-width:610px) {
    header {
        font-size:1.5em;
        letter-spacing: 0.5rem;
    }

    .container header {
        font-size: 28px;
    }

    .container {
        height: 94vh;
    }
    ul .content {
        max-height: 75vh;   /**/
         overflow: auto;
     }

     .letters {
        width: fit-content;
     }

     li .image img {
        max-height: 50%;
        max-width: 50%;
        object-fit: contain; 
    }
}

@media (max-width:609px) {
    header {
        font-size: 1.5em;
        letter-spacing: 0.5rem;
    }

    .container {
        height: auto;
    }

    ul .content {
        max-height: 65vh;   /**/
         overflow: auto;
     }

     .letters {
        width: fit-content;
        padding-right: 20px;
     }

     .letters ul li {
        min-width: fit-content;
        font-size:smaller;
     }
     li .image img {
        max-height: 50%;
        max-width: 50%;
        object-fit: contain; 
    }
}

footer {
    position: fixed;  
    bottom: 0;
    left: 0;
    width: 100%;  
    background: #f7f8f8;
    padding: 5px 15px;
    font-size: 1em;
    border-top: 2px solid #ccc;
    text-align: right;  
    box-shadow: 0 -2px 5px rgba(0, 0, 0, 0.1); 
    margin-bottom: 0; 
  }


  footer a {
    color: black;
    text-decoration: none;  
    padding-right: 35px;
  }
  
  footer a:hover {
    text-decoration: underline; 
  }