.success-message {
    border: 1px solid #2c6700;
    background-color: #96c56f;
    padding: 6px;
    color: #ffffff;
    margin-bottom: 10px;
}

input[type="text"] {
    border: none;
    border-bottom: 1px solid #cccccc;
    padding: 10px !important;
    margin-left: 0px;
    border-radius: 0px;
}

table tr th,
table tr,
td {
    padding: 5px;
}

.quote-result {
    background-color: #eeeeee;
    padding: 10px;
    border-radius: 8px;
    margin-top: 1rem;
    text-align: center;
    display: none;
}

#result_error {
    text-align: center;
    color: #f00;
    font-weight: bold;
    margin-top: 0.5rem;
}

.calculator-section {
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    align-items: start;
    margin-bottom: 2rem;
}

.disclaimer {
    width: 49%;
}

.disclaimer h2 {
    color: #616161;
    font-family: "Roboto", Sans-serif;
    font-size: 25px;
    font-weight: 600;
    margin-bottom: 1rem;
}

.disclaimer p {
    color: #7a7a7a;
}

.delivery p {
    text-decoration: underline;
    font-weight: bold;
    color: #000 !important;
}

.calculator {
    border: 2px solid #000;
    border-radius: 10px;
    display: flex;
    justify-content: center;
    align-items: center;
    width: 48%;
}

.calculator-form {
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 1.5rem 1rem;
}

.width-container,
.depth-container,
.height-container {
    display: flex;
    align-items: center;
    justify-content: start;
    padding: 0.8rem;
    border: 2px solid #eeeeee;
    background: #eeeeee;
    border-radius: 8px;
    margin: 0.6rem 0;
    width: 100%;
}

.width-container:has(.input-error)::after,
.depth-container:has(.input-error)::after,
.height-container:has(.input-error)::after {
    content: "X";
    color: #f00;
    font-weight: 600;
}

.width-container:has(input:valid)::after,
.depth-container:has(input:valid)::after,
.height-container:has(input:valid)::after {
    content: "✓";
    color: #32cc32;
    font-weight: bold;
}

.width-label,
.depth-label,
.height-label {
    width: 100%;
    margin-right: 0.5rem;
    cursor: pointer;
    line-height: 1.5;
}

#quote_width::placeholder,
#quote_depth::placeholder,
#quote_height::placeholder {
    text-overflow: ellipsis;
}

@media (max-width: 1020px) {
    .width-label,
    .depth-label,
    .height-label {
        font-size: 0.9rem;
    }

    #quote_width::placeholder,
    #quote_depth::placeholder,
    #quote_height::placeholder {
        font-size: 0.9rem;
    }

    #calculate-button {
        font-size: 1rem !important;
    }
}

@media (max-width: 787px) {
    .calculator-section {
        flex-direction: column;
        align-items: center;
    }

    .calculator {
        width: 65%;
        margin-bottom: 1.5rem;
    }

    .disclaimer {
        width: 100%;
    }
}

@media (max-width: 700px) {
    .calculator {
        width: 75%;
        margin-bottom: 1.5rem;
    }
}

@media (max-width: 567px) {
    .width-label,
    .depth-label,
    .height-label {
        font-size: 0.8rem !important;
    }

    #quote_width::placeholder,
    #quote_depth::placeholder,
    #quote_height::placeholder {
        font-size: 0.8rem !important;
    }

    .calculator {
        width: 90%;
    }
}

@media (max-width: 420px) {
    .calculator {
        width: 95%;
    }
}

#quote_width,
#quote_depth,
#quote_height {
    border: 1px solid #000 !important;
    border-radius: 5px;
    padding: 0.5rem 1rem !important;
    position: relative;
    margin-right: 0.5rem;
}

.input-error {
    outline: 2px solid #ff0000;
}

#quote_width:valid,
#quote_depth:valid,
#quote_height:valid {
    outline: 2px solid #32cc32;
}

#quote_width:focus,
#quote_depth:focus,
#quote_height:focus {
    outline: 0px none transparent;
    -webkit-appearance: none;
    appearance: none;
    border: 2px solid #000 !important;
}

.star-required {
    color: #ff0000;
}

.calculate-btn-container {
    width: 100%;
    display: flex;
    justify-content: center;
    margin-top: 0.5rem;
}

#calculate-button {
    border-radius: 8px;
    padding: 0.8rem 1.5rem;
    text-transform: uppercase;
    background: #f15050 !important;
    border: 2px solid #f15050;
    width: 100%;
    font-weight: bold;
    letter-spacing: 1.5px;
    font-size: 1.2rem;
    transition: all 0.3s;
}

#calculate-button:hover {
    background: #fff !important;
    color: #f15050 !important;
    border: 2px solid #f15050 !important;
}

/* Modal Styles */
.modal {
    display: block;
    position: initial;
    z-index: 1;
    left: 0;
    top: 0;
    width: 90%;
    max-width: 1100px;
    height: 700px;
    overflow: auto;
    background-color: white !important;
    border-radius: 20px;
}

.modal-heading {
    text-align: center;
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 1.5rem;
    position: relative;
}

.modal-content {
    background-color: white;
    margin: 15% auto;
    padding: 20px;
    border: 1px solid #888;
    width: 80%;
    max-width: 600px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.logo-container {
    text-align: center;
    display: flex;
    justify-content: center;
}

.logo {
    width: 93%;
    display: flex;
    justify-content: center;
}

.close-button {
    width: 3%;
    display: flex;
    justify-content: end;
    align-items: center;
    cursor: pointer;
}

.close-btn svg {
    width: 20%;
}

.product-information {
    display: flex;
    justify-content: space-between;
    width: 80%;
    margin: auto;
}

.product-match,
.product-details {
    text-align: center;
    width: 40%;
    max-width: 500px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    align-items: center;
    border: 2px solid #000;
    padding: 1.5rem;
    border-radius: 20px;
    position: relative;
}

.product-match::after {
    content: "";
    position: absolute;
    background: #000;
    width: 2px;
    height: 107%;
    right: -26%;
    transform: translateX(26%);
    top: -4%;
}

.product-criteria {
    text-align: center;
    width: 40%;
    max-width: 500px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    border: 2px solid #000;
    padding: 1.5rem;
    border-radius: 20px;
}

.error-message {
    text-align: center;
    color: #ff0000;
    font-weight: bold;
    font-size: 1.2rem;
    margin: 0;
}

.disabledBtn {
    background: #838383 !important;
    pointer-events: none;
}

.product-specs {
    font-size: 1.3rem;
}

.product-image {
    width: 50%;
}

.closest-match,
.quote-breakdown {
    font-size: 1.4rem;
}

.quote-message1,
.quote-message2,
.weight_text,
.price_text,
.requested-dimensions {
    font-size: 1.2rem;
}

@media (max-width: 990px) {
    .closest-match,
    .quote-breakdown {
        font-size: 1.3rem;
    }

    .product-specs {
        font-size: 1.2rem;
    }

    .quote-message1,
    .quote-message2,
    .weight_text,
    .price_text,
    .requested-dimensions {
        font-size: 1.1rem;
    }

    .product-information {
        display: flex;
        justify-content: space-between;
        width: 90%;
        margin: auto;
    }

    .product-match,
    .product-details,
    .product-criteria {
        width: 45%;
        max-width: unset;
    }

    .product-match::after {
        right: -12%;
    }

    .main-logo {
        margin-top: 2rem;
        width: 10% !important;
        margin-left: 2.1rem !important;
    }

    .close-button {
        width: 4%;
        align-items: start;
        margin-top: 0.5rem;
    }
}

.cta-btn {
    text-transform: uppercase;
    background: #000;
    color: #fff;
    padding: 1rem 1rem;
    width: 100%;
    min-width: 250px;
    border-radius: 8px;
    font-weight: 700;
    margin: 0.3rem 0rem;
    text-align: center;
    border: 2px solid #000;
    transition: all 0.3s;
}

.contact-buttons,
.product-buttons {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.contact-buttons a:hover,
.product-buttons a:hover {
    background: #fff;
    border: 2px solid #000;
    color: #000;
}

/* Add media query for mobile responsiveness */
@media (max-width: 768px) {
    .logo {
        width: 90%;
    }

    .main-logo {
        width: 12% !important;
        margin-left: 1.5rem !important;
    }

    .close-button {
        align-items: start;
        margin-top: 0.8rem;
    }

    .product-information {
        flex-direction: column;
        align-items: center;
    }

    .product-match,
    .product-details,
    .product-criteria {
        width: 100%;
        border: none;
    }

    .product-criteria {
        padding: 1rem;
    }

    .product-match:after {
        right: 26%;
        top: 100%;
        height: 2px;
        width: 100%;
    }

    .modal-heading::after {
        content: "";
        position: absolute;
        background: #000;
        right: 5%;
        top: 150%;
        height: 2px;
        width: 90%;
    }

    .modal-heading {
        margin-bottom: 0.8rem;
    }
}

@media screen and (max-width: 600px) {
    .modal-content {
        width: 95%; /* Adjust the width for smaller screens */
        margin: 30% auto; /* Increase the top margin for better centering on mobile */
    }

    .close-button {
        width: 6%;
        margin-top: 2%;
    }

    .close-btn:hover {
        color: #f44336;
    }
    .modal-close {
        top: 8%; /* Adjust the close button position for better visibility on mobile */
        right: 4%;
    }
}

@media (max-width: 420px) {
    .close-button {
        width: 7%;
    }
}

/* Additional Styles for Quote Details */
#quote-details h2 {
    margin-top: 0;
    font-size: 1.2em; /* Increase font size for better readability */
}

#quote-details p {
    margin-bottom: 10px;
    line-height: 1.6; /* Increase line height for better readability */
}

#quote-details strong {
    display: block;
    margin-bottom: 5px;
}

/* Style for the modal overlay */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    overflow: hidden; /* Prevent scrolling in the background when the modal is open */
}

/* Style for the close button */
.modal-close {
    position: absolute;
    top: 26%;
    right: 26%;
    padding: 5px 10px;
    background-color: #ff0000;
    color: #fff;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px; /* Adjust font size for better visibility on mobile */
}

table {
    background-color: #cbcacb;
    width: 100%;
    margin-bottom: 15px;
    font-size: 0.9em;
    border-spacing: 0;
    border-collapse: collapse;
    border-radius: 5px;
}
/* Add media query for mobile responsiveness */
@media screen and (max-width: 600px) {
    .main-logo {
        width: 20% !important;
        height: auto;
        margin-bottom: 10px;
        margin-top: 10px;
        margin-left: 2rem !important;
    }
}

@media screen and (max-width: 450px) {
    .main-logo {
        margin-left: 1.5rem !important;
    }
}

.main-logo {
    margin-top: 1rem;
    width: 7%;
    margin-left: 1.9rem;
    margin-bottom: -0.5rem;
}

.weight_text {
    display: grid !important;
    text-align: center;
}
.price_text {
    display: grid !important;
    text-align: center;
}
.quote-message1 {
    text-align: center;
}
.quote-message2 {
    text-align: center;
}
