@font-face {
    font-family: 'LIBRAS D Dactylology';
    src: url('./Libras2020-Regular.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
}

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

header {
    background-color: #007bff;
    color: #fff;
    padding: 1rem 0;
    text-align: center;
}

header h1 {
    margin: 0;
}

main {
    max-width: 900px;
    margin: 2rem auto;
    padding: 1rem;
    background-color: #fff;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
}

section {
    margin-bottom: 2rem;
    padding: 1.5rem;
    border: 1px solid #ddd;
    border-radius: 5px;
}

h2 {
    color: #007bff;
    border-bottom: 2px solid #007bff;
    padding-bottom: 0.5rem;
    margin-bottom: 1rem;
}

h3 {
    color: #555;
    margin-top: 1.5rem;
}

input[type="text"], select {
    padding: 0.7rem;
    border: 1px solid #ccc;
    border-radius: 4px;
    margin-right: 0.5rem;
    margin-bottom: 0.5rem; 
    font-size: 1rem;
    width: calc(100% - 1.6rem); 
    box-sizing: border-box; 
}

button {
    padding: 0.7rem 1.5rem;
    background-color: #007bff;
    color: #fff;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 1rem;
    transition: background-color 0.3s ease;
    display: block; 
    width: 100%; 
    margin-top: 1rem; 
}

button:hover {
    background-color: #0056b3;
}

.result-area {
    margin-top: 1.5rem;
    padding: 1rem;
    background-color: #e9ecef;
    border: 1px solid #ced4da;
    border-radius: 4px;
    min-height: 50px;
    display: flex; 
    flex-wrap: wrap; 
    gap: 15px; 
    align-items: center; 
}

.result-area img {
    max-width: 100px; 
    height: auto; 
    border: 1px solid #ccc;
    padding: 5px;
    background-color: #fff;
    margin: 5px; 
}

.result-area p {
    margin: 0;
    width: 100%; 
}

.result-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.result-item span {
    margin-top: 5px;
    font-size: 0.9em;
    color: #555;
}

.sentence-input-area {
    display: flex;
    flex-direction: column; 
    gap: 1rem; 
}

.input-group {
    display: flex;
    flex-direction: column; 
}

.input-group label {
    margin-bottom: 0.3rem;
    font-weight: bold;
}

.checkbox-group {
    display: flex;
    align-items: center;
    margin-top: 0.5rem; 
}

.checkbox-group input[type="checkbox"] {
    margin-right: 0.5rem;
    width: auto; 
    cursor: pointer;
}

.checkbox-group label {
    margin-bottom: 0; 
    font-weight: normal; 
    font-size: 0.9em;
    color: #555;
    cursor: pointer;
}

.input-group small {
    font-size: 0.8em;
    color: #666;
    margin-top: 0.2rem;
}

.dactylology-display {
    justify-content: center; 
    font-family: 'LIBRAS Dactylology', 'LIBRAS D Dactylology', sans-eif;
    font-size: 2.5em; 
    letter-spacing: 5px; 
    min-height: 80px; 
    padding: 15px; 
    flex-wrap: wrap; 
}

.dactylology-display .letter-item {
    padding: 5px;
    border: 1px solid #ddd;
    background-color: #fff;
    margin: 3px;
    border-radius: 4px;
    min-width: 40px; 
    text-align: center;
    line-height: 1.2; 
}

.dactylology-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 10px;
    border: 1px dashed #aaa;
    background-color: #f8f8f8;
    border-radius: 4px;
    margin: 5px;
}

.sentence-result .dactylology-container {
    max-width: 150px;
    box-sizing: border-box;
}

.sentence-result .dactylology-container .letters {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 3px;
    font-family: 'LIBRAS Dactylology', monospace; 
    font-size: 1.4em;
    color: #333;
    margin-bottom: 5px;
    letter-spacing: 2px;
}

.sentence-result .dactylology-container span {
    margin-top: 5px;
    font-size: 0.8em;
    color: #555;
}

hr {
    border: 0;
    height: 1px;
    background: #ddd;
    margin: 2rem 0;
}

footer {
    text-align: center;
    margin-top: 2rem;
    padding: 1rem;
    background-color: #e9ecef;
    color: #666;
    font-size: 0.9em;
}

#explanation-section ul {
    list-style: none;
    padding-left: 0;
}

#explanation-section li {
    margin-bottom: 0.5rem;
    padding-left: 1.2em;
    position: relative;
}

#explanation-section li::before {
    content: "✔️"; 
    position: absolute;
    left: 0;
    color: #007bff;
}

#explanation-section ul ul {
    margin-left: 1.5em;
    margin-top: 0.5em;
}