:root {
    --container-max-width: 480px; /* Narrower and more responsive container */
    --body-background-color: #f4f4f4

}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif; /* Improved font */
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    background-color: #f4f4f4;
}

footer {
	position: fixed;
	bottom: 0;
	left: 0;
	width: 100%;
	margin-inline: auto;
	background-color: var(--body-background-color);
	padding-block: .4em .6em
}

header, footer {
    text-align: center;
}

nav {
	display: flex;
	width: fit-content;
	gap: 2em;
	margin-inline: auto;
	font-weight: 900;
}

nav a {
	display: inline-block;
	width: fit-content;
}
canvas {
	display: none;
}

.container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    padding: 1rem;
    width: 40%; /* Responsive width */
    max-width: var(--container-max-width);
    border-radius: 0.5rem;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    background-color: #fff;
}

.container {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 20px;
}

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

.password-container {
    display: flex;
    width: 100%;
    max-width: 600px;
    align-items: stretch;
    justify-content: space-between;
}

#password-display {
    width: 80%; /* Responsive width */
    height: 1.6em; /* Height based on em */
    padding: 0.2em; /* Padding for better text alignment */
    font-size: 1.2em; /* Ensures the height in em units scales properly */
    text-align: right;
}

#copy-button {
    height: 2em; /* Height to somewhat match the password display */
	appearance: none;
	-webkit-appearance: none;
    display: flex;
    justify-content: center;
    align-items: center;
    background-color: transparent;
    border: none;
    flex-shrink: 0; /* Prevents the button from resizing */
}





.form-group {
    width: 100%;
    border: none; /* Ensures no border around the fieldset */
    margin: 0.5rem 0; /* Adjusts margin around the fieldset */
}

/* Other styles for .form-group, input, and button remain the same */

.form-group  > div {
	display: flex;
	gap: 2%
}

.form-group  > div div {
	width: fit-content;
	
}

.form-group  > div input, .form-group  > div label {
	width: fit-content;
	display: inline-block;
}

.form-group button {
    font-weight: 600; /* Makes the button text bolder */
    padding: 0.75rem;
    margin-top: 0.5rem; /* Adjust spacing as needed */
    border: none; /* Removes border for a cleaner look */
    border-radius: 0.375rem;
    background-color: #007bff;
    color: white;
    cursor: pointer;
    transition: background-color 0.3s; /* Smooth transition for hover effect */
}

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

.form-group label {
    font-size: 0.85rem; /* Adjust for smaller, more pronounced look */
    font-weight: bold; /* Bolder for emphasis */
    margin-bottom: 0.5rem; /* Tighter spacing to the input */
    display: block; /* Ensure label is block-level for proper spacing */
}

.form-group input, .form-group button {
    width: 100%; /* Full width to match the fieldset */
    padding: 0.75rem;
    font-size: 1rem; /* Readable font size */
    border: 1px solid #ccc;
    border-radius: 0.375rem; /* Rounded corners for modern look */
    box-sizing: border-box; /* Include padding and border in width calculation */
    margin-block: 0.25rem; /* Adjust top margin for closer element grouping */
}

button {
    cursor: pointer;
    background-color: #007bff;
    color: white;
    font-weight: normal; /* Adjust based on preference */
    transition: background-color 0.3s; /* Smooth hover transition */
}

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


.credit {
    margin-top: 2rem;
    font-size: 1rem;
}

/* Responsive adjustments for viewports less than 800px wide */
@media (max-width: 800px) {
    .container {
        width: 90%; /* Increase width to 90% for smaller screens */
    }
}