@import url('https://fonts.googleapis.com/css2?family=Comic+Neue&display=swap');

body {
  font-family: 'Comic Neue', sans-serif;

    font-family: 'Comic Neue', cursive;
    background-color: #f0f8ff; /* AliceBlue - light pastel */
    display: flex;
    flex-direction: column; /* Ensure content flows vertically */
    justify-content: center; /* Center content vertically */
    align-items: center; /* Center horizontally */
    min-height: 100vh;
    margin: 0;
    background-image: url('../images/background_elements.png'); /* Add some background elements */
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat; /* Ensure the background image doesn't repeat */
    background-attachment: fixed; /* Keep the background fixed when scrolling */
    color: #333;
}

.container {
    background-color: rgba(255, 255, 255, 0.8); /* Semi-transparent white for the paper effect */
    padding: 30px;
    border-radius: 15px;
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.2);
    text-align: center;
    max-width: 500px;
    width: 90%;
    min-width: 300px; /* Added min-width to prevent collapsing */
    position: relative;
    overflow: hidden;
    border: 2px dashed #ffb6c1; /* Light pink dashed border */
    display: flex; /* Use flexbox for internal alignment */
    flex-direction: column; /* Stack children vertically */
    align-items: center; /* Center children horizontally */
}

.container::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    background-image: linear-gradient(to bottom, transparent 1px, #e0e0e0 1px, #e0e0e0 2px, transparent 2px); /* Lined paper effect */
    background-size: 100% 25px; /* Line height */
    z-index: -1;
}

.logo {
    max-width: 250px; /* Increased size for the logo */
    margin-bottom: 20px;
}

h1 {
    color: #ff69b4; /* HotPink */
    font-size: 2.5em;
    margin-bottom: 10px;
    text-shadow: 2px 2px #ffe4e1; /* MistyRose */
}

h2 {
    color: #ffa07a; /* LightSalmon */
    font-size: 1.8em;
    margin-bottom: 15px;
    text-shadow: 1px 1px #fffacd; /* LemonChiffon */
}

.tagline {
    font-style: italic;
    color: #87ceeb; /* SkyBlue */
    margin-bottom: 30px;
    font-size: 1.1em;
}

.form-group {
    margin-bottom: 20px;
    text-align: left;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: bold;
    color: #6a5acd; /* SlateBlue */
}

.form-group input[type="text"],
.form-group input[type="number"],
.form-group input[type="tel"],
.form-group input[type="email"], /* Added email input type */
.form-group select {
    width: 100%; /* Make inputs take full width */
    padding: 10px;
    border: 2px solid #add8e6; /* LightBlue */
    border-radius: 8px;
    font-size: 1em;
    background-color: #f8f8ff; /* GhostWhite */
    color: #333;
    box-sizing: border-box; /* Include padding and border in the element's total width and height */
}

.form-group input[type="text"]:focus,
.form-group input[type="number"]:focus,
.form-group input[type="tel"]:focus,
.form-group input[type="email"]:focus, /* Added email input type */
.form-group select:focus {
    outline: none;
    border-color: #ff69b4; /* HotPink */
    box-shadow: 0 0 5px rgba(255, 105, 180, 0.5);
}

.question-group {
    margin-top: 25px;
    margin-bottom: 25px;
    padding: 15px;
    border: 1px solid #ffe4e1; /* MistyRose */
    border-radius: 10px;
    background-color: #fffafa; /* Snow */
    text-align: left;
}

.question-group label {
    font-size: 1.1em;
    margin-bottom: 10px;
    color: #4682b4; /* SteelBlue */
    font-weight: bold;
    display: block;
}

.radio-option {
    margin-bottom: 10px;
    display: flex;
    align-items: center;
}

.radio-option input[type="radio"] {
    margin-right: 10px;
    transform: scale(1.2); /* Slightly larger radio buttons */
    accent-color: #ff69b4; /* HotPink */
}

.radio-option label {
    font-weight: normal;
    color: #333;
    margin-bottom: 0; /* Override default label margin */
}

button[type="submit"] {
    background-color: #98fb98; /* PaleGreen */
    color: white;
    padding: 12px 25px;
    border: none;
    border-radius: 25px;
    font-size: 1.2em;
    cursor: pointer;
    transition: background-color 0.3s ease, transform 0.2s ease;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    font-weight: bold;
    text-transform: uppercase;
    letter-spacing: 1px;
}

button[type="submit"]:hover {
    background-color: #76ee76; /* Darker PaleGreen */
    transform: translateY(-2px);
}

.result-box {
    margin-top: 30px;
    padding: 20px;
    background-color: #fffacd; /* LemonChiffon */
    border: 2px dashed #ffb6c1; /* Light pink dashed border */
    border-radius: 10px;
    color: #4682b4; /* SteelBlue */
    font-size: 1.1em;
    font-weight: bold;
}

.result-box p {
    margin: 0;
}

.flower-result-image {
    max-width: 100px; /* Adjust as needed */
    height: auto;
    margin-top: 15px;
    border-radius: 5px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

/* The Modal (background) */
.modal {
    display: none; /* Hidden by default, will be set to flex by JS when active */
    position: fixed; /* Stay in place */
    z-index: 1; /* Sit on top */
    left: 0;
    top: 0;
    width: 100%; /* Full width */
    height: 100%; /* Full height */
    overflow: auto; /* Enable scroll if needed */
    background-color: rgba(0,0,0,0.6); /* Black w/ opacity */
    justify-content: center;
    align-items: center;
}

/* Modal Content/Box */
.modal-content {
    background-color: #fff;
    margin: auto;
    padding: 30px;
    border: 2px solid #ffb6c1;
    border-radius: 15px;
    width: 80%; /* Could be more or less, depending on screen size */
    max-width: 400px;
    box-shadow: 0 10px 20px rgba(0,0,0,0.3);
    text-align: center;
    position: relative;
    transform: scale(0); /* Hidden by default */
    transition: transform 0.3s ease-out; /* Smooth transition for scaling */
    transform-origin: center; /* Scale from center */
}

/* When modal is active */
.modal.active {
    display: flex; /* Show the modal container */
}

.modal.active .modal-content {
    transform: scale(1); /* Scale up to show content */
}

/* The Close Button */
.close-button {
    color: #aaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
    position: absolute;
    top: 10px;
    right: 15px;
    cursor: pointer;
}

.close-button:hover,
.close-button:focus {
    color: black;
    text-decoration: none;
    cursor: pointer;
}

#modalResultContent {
    margin-top: 20px;
    font-size: 1.1em;
    color: #4682b4;
}

#modalResultContent img {
    max-width: 120px; /* Slightly larger image in modal */
    height: auto;
    margin-top: 20px;
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
}

@keyframes fadeIn {
    from {opacity: 0;}
    to {opacity: 1;}
}

/* Responsive adjustments */
@media (max-width: 600px) {
    h1 {
        font-size: 2em;
    }
    h2 {
        font-size: 1.5em;
    }
    .tagline {
        font-size: 1em;
    }
    .form-group label {
        font-size: 0.9em;
    }
    .form-group input[type="text"],
    .form-group input[type="number"],
    .form-group input[type="tel"],
    .form-group input[type="email"],
    .form-group select {
        font-size: 0.9em;
        padding: 8px;
    }
    .question-group label {
        font-size: 1em;
    }
    .radio-option label {
        font-size: 0.9em;
    }
    button[type="submit"] {
        font-size: 1em;
        padding: 10px 20px;
    }
    .modal-content {
        width: 90%;
        padding: 20px;
    }
    #modalResultContent {
        font-size: 1em;
    }
    #modalResultContent img {
        max-width: 100px;
    }
}
