/* Basic Reset */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    line-height: 1.6;
    background-color: #f4f4f4;
    color: #333;
    display: flex;
    justify-content: center;
    align-items: flex-start; /* Align to top for scrollability */
    min-height: 100vh;
    padding: 20px;
}

.app-container {
    background-color: #fff;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 0 15px rgba(0,0,0,0.1);
    width: 100%;
    max-width: 450px; /* Max width for larger screens, good for phone-first */
    text-align: center;
}

header h1 {
    color: #333;
    margin-bottom: 20px;
    font-size: 1.8em;
}

main {
    margin-bottom: 20px;
}

#start-screen p {
    margin-bottom: 15px;
    font-size: 1.1em;
}

#question-screen h2 {
    margin-bottom: 15px;
    font-size: 1.5em;
    color: #555;
}

#progress-text {
    font-size: 0.9em;
    color: #777;
    margin-bottom: 10px;
}

#answer-input {
    width: calc(100% - 22px); /* Account for padding and border */
    padding: 10px;
    margin-bottom: 15px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 1.1em;
    text-align: center;
}
/* Hide number input spinners for a cleaner look on mobile */
input[type=number]::-webkit-inner-spin-button,
input[type=number]::-webkit-outer-spin-button {
  -webkit-appearance: none;
  margin: 0;
}
input[type=number] {
  -moz-appearance: textfield; /* Firefox */
}


.btn {
    background-color: #007bff;
    color: white;
    border: none;
    padding: 12px 20px;
    text-align: center;
    text-decoration: none;
    display: inline-block;
    font-size: 1em;
    border-radius: 5px;
    cursor: pointer;
    transition: background-color 0.3s ease;
    width: 100%;
    max-width: 200px; /* Prevent button from being too wide */
    margin-top: 10px;
}

.btn:hover {
    background-color: #0056b3;
}

#feedback-text {
    margin-top: 10px;
    font-weight: bold;
    min-height: 1.2em; /* Reserve space to prevent layout shifts */
}

.feedback-correct {
    color: #28a745;
}

.feedback-incorrect {
    color: #dc3545;
}

#results-screen h2 {
    margin-bottom: 15px;
    color: #333;
}

#results-screen p {
    font-size: 1.1em;
    margin-bottom: 10px;
}

#results-screen span {
    font-weight: bold;
}

footer {
    font-size: 0.8em;
    color: #777;
    margin-top: 20px;
    border-top: 1px solid #eee;
    padding-top: 10px;
}

.hidden {
    display: none;
}