/* The Modal (background) */
.custom-modal {
    display: none; /* Hidden by default */
    position: fixed; /* Stay in place */
    z-index: 10000; /* Sit on top (higher than other elements) */
    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.7); /* Black w/ opacity */
}

/* Modal Content/Box */
.custom-modal-content {
    background-color: #fefefe;
    margin: 5% auto; /* 5% from the top and centered */
    padding: 30px;
    border: 1px solid #888;
    width: 90%; /* Could be more responsive */
    max-width: 600px; /* Max width for larger screens */
    position: relative;
    box-shadow: 0 4px 8px 0 rgba(0,0,0,0.2), 0 6px 20px 0 rgba(0,0,0,0.19);
    animation-name: animatetop;
    animation-duration: 0.4s
}

/* Add Animation */
@keyframes animatetop {
    from {top: -300px; opacity: 0}
    to {top: 0; opacity: 1}
}

/* The Close Button */
.custom-modal-close {
    color: #aaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
    position: absolute;
    right: 15px;
    top: 10px;
}

.custom-modal-close:hover,
.custom-modal-close:focus {
    color: black;
    text-decoration: none;
    cursor: pointer;
}

/* Styling for the product info inside the modal */
.product-info-for-quote {
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 20px;
    border-bottom: 1px solid #eee;
}
.product-info-for-quote img {
    max-width: 80px; /* Adjust size as needed */
    height: auto;
    margin-right: 15px;
    border: 1px solid #eee;
    padding: 5px;
}
.product-info-for-quote .product-title-in-modal {
    font-size: 1.2em;
    font-weight: bold;
    margin: 0;
}

/* Basic styling for the button */
#price-on-request-button {
    /* Add specific button styles if your theme's default WooCommerce styles aren't quite right */
    background-color: #333;
    color: #fff;
    padding: 15px 30px;
    border: none;
    cursor: pointer;
    font-size: 16px;
    border-radius: 3px;
    margin-bottom: 20px;
}
#price-on-request-button:hover {
    background-color: #555;
}

/* Contact Form 7 specific adjustments inside the modal if needed */
.custom-modal-content .wpcf7-form {
    margin-top: 20px;
}
.custom-modal-content .wpcf7-form p {
    margin-bottom: 15px;
}
.custom-modal-content .wpcf7-form input[type="text"],
.custom-modal-content .wpcf7-form input[type="email"],
.custom-modal-content .wpcf7-form input[type="tel"],
.custom-modal-content .wpcf7-form textarea {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 3px;
    box-sizing: border-box; /* Include padding and border in the element's total width */
}
.custom-modal-content .wpcf7-form input[type="submit"] {
    background-color: #333;
    color: #fff;
    padding: 12px 25px;
    border: none;
    border-radius: 3px;
    cursor: pointer;
    font-size: 1.1em;
    margin-top: 20px;
    width: auto; /* Allow button to size naturally */
}
.custom-modal-content .wpcf7-form input[type="submit"]:hover {
    background-color: #555;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .custom-modal-content {
        width: 95%;
        margin: 10% auto;
    }
}