/* Ajax-Search Results */

#ajax-search-form {
    margin-bottom: 20px;
		margin-top: 5px;
}

@media (max-width: 768px) {
	#ajax-search-form {
		margin: 20px;
	}
}

#ajax-pagination {
    display: flex;
    justify-content: center;
    margin: 20px auto;       /* Ensures the container is treated as a block element */
}

.ajax-search-form-btn, #ajax-search-reset {
    border-radius: 5px;
    margin: 22px 0px 0px 0px !important;
    padding: 10px 40px !important;
	background-color: var(--primary-color) !important;
}

html[lang="ar"] .ajax-search-form-btn, #ajax-search-reset, html[lang="ur"] .ajax-search-form-btn, #ajax-search-reset {
	margin-right: 20px !important;
}

.ajax-form-row {
    display: flex;
    align-items: center;
    flex-wrap: wrap; /* Allows elements to wrap to the next line if needed */
}

.ajax-form-group {
    margin-right: 15px;
    min-width: 150px;  /* Prevents elements from shrinking too much */
    border-radius: 5px;
}

.ajax-input-group {
    display: flex;
    align-items: center;
}

.ajax-form-group:last-child {
    margin-right: 0;
}

/* Responsive Styles */
@media (max-width: 550px) {
    .ajax-form-row {
        flex-direction: column;
        align-items: flex-start;
    }
    .ajax-form-group {
        width: 100%;
        margin-bottom: 15px;
    }
    .ajax-form-group:last-child {
        margin-bottom: 0;
    }
    .ajax-input-group {
        width: 100%;
    }
    .ajax-input-group img {
        margin-left: auto;
    }
    .ajax-page-btn {
        font-size: 1em !important;
    }
    .ajax-page-btn.previousnext {
        width: 100px !important;
    }
}

.ajax-post-item {
    display: flex;
    align-items: center;
	padding: 10px 10px 30px 10px;
	border-bottom: solid 1px #e5e5e5;
	height: 200px;
}

.ajax-post-item:nth-child(odd) {
    background: #e5e5e5;
}

.ajax-post-thumbnail {
  	margin-right: 10px;
  	width: 25%;
	height: 100%;
}

.ajax-post-thumbnail img {
    width: 100%;
	height: 100%;
}

html[lang="ar"] .ajax-post-thumbnail,
html[lang="ur"] .ajax-post-thumbnail {
    margin-right: 0;
    margin-left: 10px;
}


.ajax-post-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
		height: 100%;
}
.ajax-post-title a {
    text-decoration: none !important;
	text-transform: capitalize !important;
	color: var(--secondary-color) !important;
}

.ajax-post-title {
    margin-bottom: 5px !important;
}


.ajax-post-content p {
    margin-bottom: 0px !important;
		font-size: 1.5rem;
}

.ajax-post-excerpt {
    margin: 5px 0;
		
}

.ajax-post-date {
	font-size: 1.5rem;
}

.ajax-read-more-button {
    padding: 5px 10px;
    background-color: var(--primary-color);
    text-decoration: none !important;
    font-size: 1.3rem;
    width: 100px;
	margin-left: auto;
	color: #fff;
}

html[lang="ar"] .ajax-read-more-button, html[lang="ur"] .ajax-read-more-button {
	margin-left: 0;
	margin-right: auto;
}

.ajax-page-btn {
    color: #fff;
    font-weight: 200;
    height: 28px !important;
    background: var(--primary-color);
    padding: 2px 7px;
    margin: 0 10px 0 0; 
    width: 70px;   
    white-space: nowrap; 
    border: none; 
}

.ajax-page-btn:hover, .ajax-page-btn.active  {
    background: var(--secondary-color);
	color: #fff
}

.ajax-page-btn.previousnext {
	background: none;
	color: #333;
}


@media only screen and (max-width: 768px) {
    .ajax-post-item {
        display: block;
/* 			justify-self: center !important; */
        height: auto !important;
/*         max-height: none !important; */
				margin:3% !important;
    }
    
    .ajax-post-thumbnail {
        width: 100%;
        margin-bottom: 10px;
        height: 100% !important;
				margin-right:0px !important;
    }
    
    .ajax-post-thumbnail img {
        width: 100%; 
		}


    .ajax-post-title {
        margin-bottom: 10px; 
				line-height: 1.2 !important;
				font-size: 22px;
    }
	.ajax-post-date {
		 	margin-top: 15px !important;
      margin-bottom: 10px; 	
    }

    .ajax-read-more-button {
        display: block;
        margin-bottom: 10px;
        margin-top: 5px !important;
    }
}
/* End of Ajax-Search Results */