/* Modal Specifics */
.modal {
    display: none; 
    position: fixed; 
    z-index: 2000; 
    left: 0;
    top: 0;
    width: 100%; 
    height: 100%; 
    overflow: auto; 
    background-color: rgba(0,0,0,0.5); 
    align-items: center; 
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.modal.show {
    opacity: 1;
}

.modal-content {
    background-color: #fefefe;
    margin: auto;
    padding: 30px; /* Reduced from 40px */
    border: none;
    width: 90%;
    max-width: 600px;
    border-radius: 12px;
    position: relative;
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
    animation: slideDown 0.4s ease;
}

@keyframes slideDown {
    from { transform: translateY(-50px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

.close-modal {
    color: #aaa;
    position: absolute;
    top: 15px;
    right: 25px;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    transition: color 0.3s;
}

.close-modal:hover,
.close-modal:focus {
    color: #e67e22;
    text-decoration: none;
}

.modal-header {
    text-align: center;
}

.modal-header h2 {
    font-size: 2.2rem;
    color: #1a1a2e;
    margin-bottom: 5px;
    font-weight: 700;
}

.modal-header p {
    color: #666;
    margin-bottom: 25px;
    font-size: 1rem;
}

.modal-form {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

/* Ensure inputs in .form-row take available space */
.modal-form .form-row {
    display: flex;
    gap: 15px;
}

.modal-form .form-row > * {
    flex: 1; /* Make inputs share equal width */
}

.modal-form input,
.modal-form select, 
.modal-form textarea {
    width: 100%;
    padding: 15px; /* Increased padding */
    border: 1px solid #e0e0e0; /* Lighter border */
    border-radius: 6px;
    font-size: 1rem;
    font-family: 'Open Sans', sans-serif;
    transition: border-color 0.3s;
    background-color: #fcfcfc; /* Very light background */
    color: #555;
    box-sizing: border-box; /* Important for padding */
}

.modal-form select {
    appearance: none; 
    -webkit-appearance: none;
    -moz-appearance: none;
    background-image: url("data:image/svg+xml;charset=US-ASCII,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22292.4%22%20height%3D%22292.4%22%3E%3Cpath%20fill%3D%22%23333%22%20d%3D%22M287%2069.4a17.6%2017.6%200%200%200-13-5.4H18.4c-5%200-9.3%201.8-12.9%205.4A17.6%2017.6%200%200%200%200%2082.2c0%205%201.8%209.3%205.4%2012.9l128%20127.9c3.6%203.6%207.8%205.4%2012.8%205.4s9.2-1.8%2012.8-5.4L287%2095c3.5-3.5%205.4-7.8%205.4-12.8%200-5-1.9-9.2-5.5-12.8z%22%2F%3E%3C%2Fsvg%3E");
    background-repeat: no-repeat;
    background-position: right 1rem center;
    background-size: 0.65em auto;
}

.modal-form input:focus,
.modal-form select:focus,
.modal-form textarea:focus {
    border-color: #ff9800; /* Orange border on focus */
    outline: none;
    background-color: #fff;
}

.modal-submit-btn {
    width: 100%; /* Full width */
    padding: 15px; /* Larger button */
    font-size: 1.1rem;
    font-weight: bold;
    margin-top: 15px;
    background-color: #ff9800; /* Match orange */
    color: white;
    border: none;
    border-radius: 30px; /* More rounded */
    cursor: pointer;
    transition: background 0.3s;
    align-self: center; /* Center if container is flex col */
}

.modal-submit-btn:hover {
    background-color: #e68900;
}
