body {
    font-family: sans-serif;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    background-color: #f4f4f4;
    margin: 0;
}

.calculator-container {
    background-color: #fff;
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    width: 100%;
    max-width: 500px;
}

h1, h2 {
    text-align: center;
    color: #333;
    margin-bottom: 10px; /* Reduced margin for h1 */
}

.intro-text {
    text-align: center;
    margin-bottom: 25px;
    color: #666;
    font-size: 0.95em;
    line-height: 1.5;
}

h2 {
    text-align: center;
    color: #333;
}

.form-group {
    margin-bottom: 25px; /* Increased spacing between groups */
}

label {
    display: block;
    margin-bottom: 8px;
    font-weight: bold;
    color: #555;
}

input[type="number"],
select {
    width: 100%;
    padding: 10px;
    border: 1px solid #ccc;
    border-radius: 4px;
    box-sizing: border-box; /* Prevents padding from adding to width */
}

.help-text {
    display: block;
    margin-top: 6px;
    font-size: 0.85em;
    color: #777;
    font-style: italic;
}

#rate-display {
    background-color: #e9e9e9;
    padding: 10px;
    border-radius: 4px;
    font-style: italic;
    color: #666;
    min-height: 1.5em; /* Ensure space even when empty */
}

.output-section {
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid #eee;
}

.output-section p {
    font-size: 1.1em;
    color: #333;
    margin-bottom: 10px;
}

.output-section span {
    font-weight: bold;
    color: #007bff; /* A highlight color */
}

/* Hide elements visually but keep them accessible */
.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}
