/*
Theme Name: Salient Child Theme
Description: This is a custom child theme for Salient
Theme URI:   https://themeforest.net/item/salient-responsive-multipurpose-theme/4363266
Author: ThemeNectar
Author URI:  https://themeforest.net/user/themenectar
Template: salient
Version: 1.0
*/

/* ========================================
   PARALLAX HEADER STYLES
   ======================================== */

.project-parallax-header {
	position: relative;
	height: 60vh;
	min-height: 400px;
	background-attachment: fixed;
	background-position: center;
	background-repeat: no-repeat;
	background-size: cover;
	display: flex;
	align-items: center;
	justify-content: center;
	overflow: hidden;
}

.parallax-overlay {
	position: absolute;
	top: 0;
	left: 0;
	right: 0;
	bottom: 0;
	background: rgba(0, 0, 0, 0.4);
	display: flex;
	align-items: center;
	justify-content: center;
}

.parallax-content {
	text-align: center;
	color: white;
	z-index: 2;
	padding: 20px;
}

.parallax-content h1 {
	font-size: 3em;
	margin: 0;
	text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
	color:#fff;
}

/* ========================================
   PROJECT DETAILS TABLE & MAP
   ======================================== */

.project-details-row {
	margin-top: 30px;
	margin-bottom: 30px;
}

.project-info-table {
	width: 100%;
	border-collapse: collapse;
}

.project-info-table td {
	padding: 10px 15px 10px 0;
	vertical-align: top;
}

.project-info-table td:first-child {
	width: 40%;
}

.project-location-map {
	width: 100%;
	height: 100%;
	min-height: 400px;
}

.no-location-message {
	background: #f5f5f5;
	height: 400px;
	display: flex;
	align-items: center;
	justify-content: center;
}

.no-location-message p {
	color: #999;
}

/* ========================================
   PROJECT PHOTOS GRID (150x150px squares)
   ======================================== */

.project-photos-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, 150px);
	gap: 10px;
	margin-top: 5px;
}

.project-photos-grid a {
	display: block;
	width: 150px;
	height: 150px;
	overflow: hidden;
	border-radius: 4px;
	transition: transform 0.3s ease, box-shadow 0.3s ease;
	box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.project-photos-grid a:hover {
	transform: scale(1.05);
	box-shadow: 0 4px 8px rgba(0,0,0,0.2);
	z-index: 10;
}

.project-photos-grid img {
	width: 150px !important;
	height: 150px !important;
	object-fit: cover;
	object-position: center;
	display: block;
}

/* ========================================
   PROJECT GALLERY
   ======================================== */

.project-gallery {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
	gap: 20px;
	list-style: none;
	padding: 0;
	margin: 20px 0;
}

.project-gallery li {
	margin: 0;
}

.project-gallery img {
	width: 100%;
	height: 200px;
	object-fit: cover;
	border-radius: 4px;
	transition: transform 0.3s ease;
}

.project-gallery a:hover img {
	transform: scale(1.05);
}

.project-gallery p {
	margin-top: 8px;
	font-size: 14px;
	color: #666;
}

/* ========================================
   ORIGINAL PROJECT STYLING
   ======================================== */

.project {
	border: 1px solid #d3d3d3;
	-webkit-border-radius: 5px;
	-moz-border-radius: 5px;
	border-radius: 5px;
	margin-bottom: 15px;
	padding-top:10px;
}

/* Project grid styling voor gelijke hoogtes */
.project-grid-wrapper {
    display: flex;
    flex-wrap: wrap;
    margin: 0 -15px;
    gap: 0; /* Reset gap, we gebruiken padding */
}

.project-grid-wrapper > .project {
    width: calc(33.333% - 20px); /* 33.333% minus de totale horizontal padding */
    margin: 0 10px 30px 10px; /* 10px links en rechts = 20px totaal tussen cards */
    padding-top: 0;
    box-sizing: border-box;
}

/* Override de theme's col margin-right binnen onze grid */
@media (min-width: 691px) {
    .project-grid-wrapper > .project.col {
        margin-right: 10px;
        margin-left: 10px;
    }
}

.project-grid-item {
    display: flex;
    flex-direction: column;
    height: 100%;
    padding: 20px;
    background: #fff;
    position: relative;
    z-index: 1;
}

.project-grid-item:hover {
    z-index: 10;
}

.project-title {
    min-height: 70px; /* Verhoogd voor grotere titels */
    display: flex;
    align-items: flex-start;
    margin-bottom: 15px;
}

.project-title h4 {
    margin: 0;
    font-size: 22px; /* Groter gemaakt van 18px */
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2; /* Max 2 regels */
    -webkit-box-orient: vertical;
    overflow: hidden;
    font-weight: 600;
}

.project-image {
    position: relative;
    width: 100%;
    height: 250px; /* Fixed height voor alle afbeeldingen */
    overflow: hidden;
    margin-bottom: 15px;
    background: #f5f5f5;
    display: block;
    line-height: 0; /* Verwijdert extra ruimte onder inline afbeeldingen */
}

.project-image a {
    display: block;
    width: 100%;
    height: 100%;
    line-height: 0;
}

.project-image img {
    width: 100% !important;
    height: 100% !important;
    min-height: 100%; /* Zorgt ervoor dat de afbeelding altijd de volledige hoogte vult */
    object-fit: cover;
    object-position: center;
    transition: transform 0.3s ease;
    display: block; /* Verwijdert inline spacing */
}

.project-grid-item:hover .project-image img {
    transform: scale(1.05);
}

.project-excerpt {
    min-height: 80px; /* Fixed height voor excerpt (ongeveer 3-4 regels) */
    margin-bottom: 15px;
    font-size: 14px;
    line-height: 1.6;
    color: #666;
    flex-grow: 1; /* Neemt resterende ruimte in */
}

.project-button {
    margin-top: auto; /* Duwt button naar beneden */
    width: 100%;
}

.project-button a {
    display: block; /* Block voor volledige breedte */
    width: 100%;
    padding: 12px 25px;
    background: #000;
    color: #fff !important;
    text-decoration: none;
    text-align: center;
    transition: background 0.3s ease;
    box-sizing: border-box;
}

.project-button a:hover {
    background: #333;
}

/* Loading state voor AJAX paginering */
.projects-loading {
    opacity: 0.5;
    pointer-events: none;
    position: relative;
}

.projects-loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 50px;
    height: 50px;
    margin: -25px 0 0 -25px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid #000;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Pagination styling */
.pagination {
    margin-top: 40px;
    text-align: center;
}

.pagination a,
.pagination span {
    display: inline-block;
    padding: 10px 15px;
    margin: 0 5px;
    background: #f5f5f5;
    color: #333;
    text-decoration: none;
    transition: background 0.3s ease;
}

.pagination a:hover {
    background: #000;
    color: #fff;
}

.pagination .current {
    background: #000;
    color: #fff;
}

/* ========================================
   RESPONSIVE STYLES
   ======================================== */

/* Tablets */
@media (max-width: 999px) {
    .project-grid-wrapper > .project {
        width: calc(50% - 20px); /* 2 columns op tablets */
    }
    
    .project-title {
        min-height: 60px;
    }
    
    .project-title h4 {
        font-size: 20px;
    }
    
    .project-image {
        height: 200px;
    }
    
    .project-info-table td:first-child {
        width: 35%;
    }
}

/* Mobile - Parallax & Project Grid */
@media (max-width: 768px) {
	/* Mobile parallax optimization - disable parallax on mobile */
	.project-parallax-header {
		background-attachment: scroll;
		height: 40vh;
		min-height: 300px;
	}
	
	.parallax-content h1 {
		font-size: 2em;
	}
	
	.project-location-map {
		min-height: 300px;
	}
	
	.project-gallery {
		grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
		gap: 15px;
	}
	
	.project-gallery img {
		height: 150px;
	}
	
	/* Responsive photo grid - 2 columns on tablets */
	.project-photos-grid {
		grid-template-columns: repeat(auto-fill, 150px);
	}
}

@media (max-width: 690px) {
    .project-grid-wrapper > .project {
        width: calc(100% - 20px); /* 1 column op mobile */
    }
    
    .project-title h4 {
        font-size: 18px;
    }
    
    .project-image {
        height: 250px;
    }
    
    .project-excerpt {
        min-height: auto;
    }
    
    /* Responsive photo grid - 2 columns on mobile */
    .project-photos-grid {
        grid-template-columns: repeat(2, 150px);
    }
}