* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Inter', sans-serif;
}

body {
    background: #f5f7fa;
    min-height: 100vh; /* Ensures body takes at least full viewport height */
    display: flex;
    flex-direction: column; /* Stack .container vertically if needed */
    justify-content: center; /* Center .container vertically */
    align-items: center;   /* Center .container horizontally */
    padding: 20px 0; /* Add some vertical padding to the body, especially for smaller screens */
                     /* This prevents the form from touching screen edges if it's tall */
    box-sizing: border-box; /* Include padding in height calculation */
    overflow-y: auto; /* Allow body to scroll ONLY if content absolutely exceeds viewport height */
}

.container {
    width: 100%;
    max-width: 400px; /* Or your preferred max-width */
    /* padding: 20px; */ /* This was here, it's fine, or can be removed if body padding is sufficient */
}

.form-container {
    background: white;
    padding: 30px;     /* Existing padding */
    border-radius: 12px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    width: 100%;       /* Ensure form-container takes full width of .container */
    max-height: calc(100vh - 40px); /* Max height is viewport height minus body's vertical padding */
                                   /* This helps prevent the form itself from causing page scroll */
    overflow-y: auto;  /* If form content is too tall, form-container will scroll, not the page */
    box-sizing: border-box;
}

.title {
    text-align: center;
    margin-top: 0; /* Reduce top margin if form is very tall */
    margin-bottom: 20px; /* Slightly reduce bottom margin */
    color: #1e293b;
}

.form-group {
    margin-bottom: 20px;
}

.label {
    display: block;
    margin-bottom: 8px;
    color: #475569;
}

.input {
    width: 100%;
    padding: 12px;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    font-size: 16px;
    transition: border-color 0.3s;
}

.input:focus {
    outline: none;
    border-color: #3b82f6;
}

.error-message {
    background: #fee2e2;
    color: #991b1b;
    padding: 12px;
    border-radius: 8px;
    margin-bottom: 20px;
}

.success-message {
    background: #dcfce7;
    color: #166534;
    padding: 12px;
    border-radius: 8px;
    margin-bottom: 20px;
}

.submit-btn {
    width: 100%;
    padding: 12px;
    background: #3b82f6;
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    cursor: pointer;
    transition: background-color 0.3s;
}

.submit-btn:hover {
    background: #2563eb;
}

.redirect-text {
    text-align: center;
    margin-top: 20px;
    color: #475569;
}

.redirect-text a {
    color: #3b82f6;
    text-decoration: none;
}

.redirect-text a:hover {
    text-decoration: underline;
}

.remember-container {
    display: flex;
    align-items: center;
    margin-bottom: 20px;
}

.remember {
    margin-right: 8px;
}

.form-group:last-of-type { /* Or target a more specific last element if structure varies */
    margin-bottom: 15px;
}
