body {
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100vh;
    font-family: 'Arial', sans-serif;
    background: linear-gradient(45deg, #36c5f0, #4b7bec);
    color: #fff;
    overflow: hidden; /* Hide body overflow to prevent unnecessary scrolling */
}

#input-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    margin-top: 20px;
}

label {
    margin-right: 10px;
    margin-top: 15px;
    color: #ecf0f1;
}

input {
    margin-top: 15px;
    padding: 8px;
    border: 1px solid #3498db;
    border-radius: 5px;
    color: #2c3e50;
    width: 200px;
}

.btn {
    display: block;
    background-color: #2ecc71;
    color: #fff;
    border: none;
    padding: 8px 16px;
    border-radius: 5px;
    cursor: pointer;
    transition: background-color 0.3s;
}

.btn:hover {
    background-color: #27ae60;
}

#nodeValue {
    padding: 8px;
    margin-right: 10px;
    border: 1px solid #3498db;
    border-radius: 5px;
    color: #2c3e50;
    width: 200px;
}

#tree-container {
    position: relative;
    width: 90vw;
    max-height: 90vh;
    overflow: auto;
    margin-left: 0; /* Remove the left margin */
}

.node {
    position: absolute;
    background-color: #f0f0f0;
    border: 1px solid #ccc;
    border-radius: 5px;
    padding: 8px;
    text-align: center;
    color: #2c3e50;
    font-size: 12px;
}

line {
    stroke: #2c3e50;
    stroke-width: 2px;
}

@media (max-width: 768px) {
    .node {
        font-size: 10px;
        padding: 5px;
    }

    line {
        stroke-width: 1px;
    }
}
