/* Contact Intro Section */
#contact-intro {
    text-align: center;
    padding: 50px 20px;
    background: linear-gradient(135deg, #1E2A38, #2E3E4E);
    color: white;
}

/* Contact Form Section */
#contact-form {
    display: flex;
    justify-content: center;
    align-items: center; /* Centers vertically */
    min-height: calc(100vh - 300px); /* Ensures space between intro and footer */
    padding: 0px 20px;
}

/* Contact Container */
.contact-container {
    display: flex;
    gap: 40px;
    max-width: 900px;
    width: 100%;
    align-items: center; /* Ensures both sections align properly */
}

/* Contact Info */
.contact-info {
    flex: 1;
    background: #f8f8f8;
    padding: 20px;
    border-radius: 8px;
    max-width: 400px; /* Prevents stretching */
}

.contact-info h2 {
    font-size: 24px;
    color: #1E2A38;
}

.contact-info p {
    font-size: 16px;
    color: #555;
    margin: 10px 0;
}

/* Contact Form */
.form-container {
    flex: 1;
    background: white;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    max-width: 400px; /* Prevents it from overflowing */
}

/* Form Elements */
form {
    display: flex;
    flex-direction: column;
    max-width: 100%; /* Ensures no extra width */
}

input, textarea {
    margin-bottom: 15px;
    padding: 12px;
    font-size: 16px;
    border: 1px solid #ccc;
    border-radius: 5px;
    width: calc(100% - 24px); /* Prevents overflowing */
    box-sizing: border-box; /* Ensures proper sizing */
}

/* Submit Button */
button {
    background-color: #ff6600;
    color: white;
    padding: 12px;
    font-size: 18px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    transition: background 0.3s;
}

button:hover {
    background-color: #e65500;
}

/* Responsive Design for Mobile */

/* Responsive Design for Tablets & Mobile */
@media (max-width: 768px) {
    #contact-form {
        min-height: unset; /* Adjust height for smaller screens */
        padding: 30px 15px;
        margin-top: 50px; /* Reduce padding for better spacing */
    }

    .contact-container {
        flex-direction: column;
        text-align: center;
        gap: 20px;
    }

    .contact-info, .form-container {
        max-width: 90%; /* Increase width */
        padding: 25px;
    }

    .contact-info h2,
    .form-container h2 {
        font-size: 22px; /* Reduce font size slightly */
    }

    input, textarea {
        width: 100%; /* Ensure full width */
        max-width: 600px; 
        width: 350px;/* Limit width on larger mobile screens */
        
    }

    textarea {
        height: 100px;
    }
}

/* Extra Small Screens (Phones) */
@media (max-width: 480px) {
    #contact-intro {
        padding: 30px 15px;
    }

    .contact-info, .form-container {
        max-width: 95%; /* Make slightly wider */
        padding: 20px;
    }

    .contact-info h2,
    .form-container h2 {
        font-size: 20px;
    }

    input, textarea {
        font-size: 14px;
        padding: 12px;
        width: 100%;
    }

    button {
        font-size: 16px;
        padding: 12px;
    }
}
