/* Styling for search and filter section */
#pm-search {
    display: flex;
    gap: 10px;
    margin-bottom: 15px;
    font-size: 1rem;
}

#pm-search select,
#pm-search input {
    padding: 8px;
    font-size: inherit;
    border: 0px solid #ccc;
    border-radius: 4px;
    width: auto;
    max-width: 170px;
}

.manual-buttons {
    display: flex;              /* Use flexbox for layout */
    gap: 10px;                 /* Space between buttons */
    margin-top: 10px;          /* Space above buttons */
}

.manual-buttons .button {
    flex: 1;                   /* Allow buttons to grow and fill space equally */
    text-align: center;        /* Center the text within the buttons */
}



.loader {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    font-size: 18px;
    margin: 20px 0;
}

.spinner {
    border: 4px solid rgba(0, 0, 0, 0.1);
    border-left-color: #333;
    border-radius: 50%;
    width: 30px;
    height: 30px;
    animation: spin 1s linear infinite;
    margin-top: 10px;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}


#pm-search select:focus,
#pm-search input:focus {
    outline: none;
    border-color: #0073aa;
    box-shadow: 0 0 5px rgba(0, 115, 170, 0.3);
}

/* Grid layout for manuals */
#pm-results {
    display: grid;
    grid-template-columns: repeat(3, 1fr); /* Three columns */
    gap: 20px;
    max-width: 100%; /* Ensure the grid stays within the container */
}

/* Mobile Grid Layout (Under 800px) */
@media (max-width: 800px) {
    #pm-results {
        grid-template-columns: repeat(2, 1fr); /* Two columns */
        gap: 10px!important;
        max-width: 100%; /* Ensure the grid stays within the container */
        justify-content: center!important;
    }
    .manual-item .button {
        margin: 0px;
}
}

.manual-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 10px;
    border: 1px solid #e1e1e1;
    border-radius: 5px;
    background-color: #f9f9f9;
    box-sizing: border-box;
    width: 100%; /* Enforce grid column width */
}

/* Manual image styling */
.manual-image {
    width: 100%;
    max-width: 400px; /* Set a max width for images */
    height: auto;
    border-radius: 5px;
    cursor: pointer;
    transition: box-shadow 0.3s;
}

.manual-image:hover {
    box-shadow: 0 0 10px rgba(0, 115, 170, 0.3);
}

.manual-item h3 {
    font-size: 16px;
    margin: 10px 0;
    text-align: center;
}

/* Styling for buttons */
.manual-item .button {
    display: inline-block;
    padding: 8px 12px;
    margin: 0px;
    background-color: #3892d6;
    color: #fff;
    border: none;
    border-radius: 5px;
    text-decoration: none;
    font-size: 14px;
    transition: background-color 0.3s;
}

.manual-item .button:hover {
    background-color: #005d8a;
}
