body {
    font-family: sans-serif;
    background-color: #f4f4f4;
    color: #333;
    display: flex;
    justify-content: center;
    padding: 2rem 0;
}

.container {
    background: #fff;
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
    width: 100%;
    max-width: 1200px;
}

h1, h2, h3 {
    text-align: center;
    color: #0056b3;
}

.materials-container {
    display: flex;
    gap: 2rem;
    justify-content: space-around;
    margin-bottom: 1rem;
}

.material-group {
    flex: 1;
    min-width: 300px;
}

#calculator-form {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

fieldset {
    border: 1px solid #ccc;
    border-radius: 4px;
    padding: 1rem;
    display: flex;
    flex-direction: column;
    gap: 0.5rem; /* Tighter spacing for inputs */
}

.element-inputs label {
    display: grid;
    grid-template-columns: 1fr 1fr;
    align-items: center;
}

legend {
    padding: 0 0.5rem;
    font-weight: bold;
    color: #0056b3;
}

label {
    font-weight: bold;
}

input[type="number"], select {
    padding: 0.5rem;
    border: 1px solid #ccc;
    border-radius: 4px;
    font-size: 1rem;
    width: 100%;
    box-sizing: border-box;
}

button {
    padding: 0.75rem;
    background-color: #007bff;
    color: white;
    border: none;
    border-radius: 4px;
    font-size: 1rem;
    cursor: pointer;
    transition: background-color 0.3s;
    max-width: 400px;
    align-self: center;
}

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

#results {
    margin-top: 2rem;
    padding-top: 1rem;
    border-top: 1px solid #eee;
}

#result-points p {
    font-size: 1.1rem;
    background: #e9ecef;
    padding: 0.75rem;
    border-radius: 4px;
    display: flex;
    justify-content: space-between;
}

#recommendation {
    margin-top: 1rem;
    padding: 1rem;
    background-color: #d1ecf1;
    border: 1px solid #bee5eb;
    color: #0c5460;
    border-radius: 4px;
}

#recommendation h3 {
    margin-top: 0;
    color: #0c5460;
}

#filler-recommendation span {
    font-weight: bold;
}

.chart-container {
    margin-top: 2rem;
    position: relative;
    height: 60vh;
    width: 100%;
}
