body {
    font-family: sans-serif;
    display: flex;
    justify-content: center;
    align-items: flex-start; /* Align items to the top */
    min-height: 100vh;
    margin: 0;
    background-color: #f0f0f0;
    padding: 20px;
    box-sizing: border-box;
}

.container {
    background-color: #fff;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    text-align: center;
    width: 100%;
    max-width: 600px; /* Limit max width */
}

h1 {
    color: #333;
    margin-bottom: 20px;
}

.input-area {
    margin-bottom: 20px;
}

#promptInput {
    width: calc(100% - 22px); /* Adjust for padding/border */
    padding: 10px;
    margin-bottom: 10px;
    border: 1px solid #ccc;
    border-radius: 4px;
    font-size: 1rem;
    min-height: 80px; /* Make textarea taller */
    resize: vertical; /* Allow vertical resize */
}

#generateBtn {
    padding: 10px 20px;
    background-color: #007bff;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 1rem;
    transition: background-color 0.3s ease;
    width: 100%; /* Full width button on mobile */
}

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

#loading {
    font-size: 1.1rem;
    color: #555;
    margin-top: 10px;
}

.hidden {
    display: none;
}

.image-area {
    margin-top: 20px;
}

#generatedImage {
    max-width: 100%; /* Ensure image fits container */
    height: auto;
    border: 1px solid #eee;
    border-radius: 4px;
    background-color: #f9f9f9; /* Placeholder background */
    min-height: 150px; /* Give it some height even when empty */
    display: block; /* Remove extra space below image */
    margin: 0 auto; /* Center image */
}

/* Basic mobile adjustments */
@media (max-width: 600px) {
    .container {
        padding: 15px;
    }

    #promptInput {
        font-size: 0.9rem;
    }

    #generateBtn {
        font-size: 0.9rem;
    }
}

