/*
 * Portföy kartı — listeleme (opportunities.php) ve kaydedilenler (my-saved.php) sayfalarında ortak.
 * Tüm kurallar .ipm-card altında; sayfaların kendi eski kart kurallarını geçersiz kılar.
 * Satırlar tek satıra sabitlenir (başlık, konum, etiketler, fiyat, özellikler) ki
 * kart yüksekliği ve dolayısıyla görsel yüksekliği her kartta aynı kalsın.
 */
.ipm-card .card-places {
	margin: 1rem 0;
	display: flex;
	flex-direction: column;
	align-items: stretch;
	width: 100%;
	height: auto;
	border-radius: 4px;
	overflow: hidden;
	background: #fff;
}
.ipm-card.card-hovered .card-places {
	box-shadow: 0 12px 32px rgba(0, 0, 0, 0.28);
	position: relative;
}
.ipm-card .card-image {
	position: relative;
	width: 100%;
	aspect-ratio: 16 / 9;
	flex: none;
}
.ipm-card .card-image .img {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	max-height: none;
	object-fit: cover;
}
.ipm-card .heart-icon {
	position: absolute;
	top: 10px;
	right: 10px;
	left: auto;
	width: 32px;
	height: 32px;
	z-index: 3;
	cursor: pointer;
}
.rtl-direction .ipm-card .heart-icon {
	right: auto;
	left: 10px;
}

/* Fotoğraf üstü badge'ler (sol üst) */
.ipm-card .property-badges {
	position: absolute;
	top: 12px;
	left: 12px;
	right: 56px;
	z-index: 2;
	display: flex;
	flex-wrap: wrap;
	gap: 6px;
	pointer-events: none;
}
.rtl-direction .ipm-card .property-badges {
	left: 56px;
	right: 12px;
}
.ipm-card .property-badge {
	background-color: #025150;
	color: #fff;
	font-size: 0.7rem;
	font-weight: 800;
	padding: 4px 10px;
	border-radius: 5px;
	letter-spacing: 0.3px;
	box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
	line-height: 1.2;
	white-space: nowrap;
}

/* İçerik */
.ipm-card .card-content {
	position: relative;
	display: flex;
	flex-direction: column;
	width: 100%;
	min-width: 0;
	padding: 1rem 1.25rem;
	border: 1px solid #e3e3e3;
	border-top-width: 0;
	border-radius: 0 0 4px 4px;
	background: #fff;
	color: #000;
}
.ipm-card .card-inner {
	display: flex;
	flex-direction: column;
	flex: 1 1 auto;
	min-width: 0;
	color: #000;
}
.ipm-card .card-titles {
	font-size: 1.25rem;
	line-height: 1.6;
	font-weight: 700;
	color: #000;
	margin: 0 0 .25rem;
	min-width: 0;
}
.ipm-card .card-titles span {
	display: block;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis; /* tek kelime bile sığmazsa son çare */
	overflow-wrap: normal;
}
.ipm-card .property-location {
	display: flex;
	flex-wrap: nowrap;
	align-items: center;
	gap: 4px;
	min-width: 0;
	margin-bottom: .5rem;
	font-size: .875rem;
	color: #666;
	white-space: nowrap;
	overflow: hidden;
}
.ipm-card .property-location > span:not(.property-ref) {
	min-width: 0;
	overflow: hidden;
	text-overflow: ellipsis;
}
.ipm-card .property-ref {
	display: inline-flex;
	align-items: center;
	flex-shrink: 0;
}
.ipm-card .property-location > span + .property-ref::before {
	content: '';
	width: 4px;
	height: 4px;
	border-radius: 50%;
	background: currentColor;
	margin: 0 6px 0 4px;
	flex-shrink: 0;
}
.ipm-card .card-tags,
.ipm-card .card-price {
	display: flex;
	flex-wrap: nowrap;
	align-items: center;
	min-width: 0;
	max-width: 100%;
	overflow: hidden;
	white-space: nowrap;
}
.ipm-card .card-tags {
	gap: 4px 8px;
	margin-bottom: .25rem;
}
.ipm-card .card-price {
	gap: 4px 8px;
	font-weight: 700;
}
.ipm-card .card-price > div {
	margin-top: 0 !important;
}
/* Özellikler: en fazla 2 satır, aralarında nokta ayraç. Yükseklik hep 2 satır (kart yüksekliği sabit kalsın) */
.ipm-card .amenties {
	position: static;
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	align-content: flex-start;
	min-width: 0;
	max-width: 100%;
	font-size: .85rem;
	line-height: 1.4;
	row-gap: 2px;
	column-gap: 0;
	height: calc(2.8em + 2px);
	overflow: hidden;
	margin: 8px 0 12px;
}

/* Etiketler */
.ipm-card .tag {
	color: #000;
	font-size: .75rem;
	padding: .35rem .675rem;
	line-height: 1.5;
	display: inline-block;
	font-weight: 700;
	border: 1px solid #b3b3b3;
	border-radius: .25rem;
	text-decoration: none;
	text-align: center;
	white-space: nowrap;
	flex: 0 0 auto;
	max-width: none;
}
.ipm-card .card-tags .tag {
	margin: 0 !important;
}
.ipm-card .amenties .tag {
	border: 0 !important;
	position: relative;
	display: inline-flex;
	align-items: center;
	padding: 0;
	margin: 0;
	font-size: 1em;
	line-height: inherit;
	font-weight: 700;
}
.ipm-card .amenties .tag:hover {
	color: #000 !important;
}
.ipm-card .amenties div:not(:last-child):after {
	content: none;
}
/* .property-ref ile aynı nokta ayraç; satır başındaki öğede gizlenir */
.ipm-card .amenties .tag + .tag::before {
	content: '';
	width: 4px;
	height: 4px;
	border-radius: 50%;
	background: #666;
	margin: 0 8px;
	flex-shrink: 0;
}
.ipm-card .amenties .tag.is-line-start::before {
	display: none;
}

/* Geniş ekran: fotoğraf solda, bilgiler sağda */
@media (min-width: 600px) {
	.ipm-card .card-places {
		flex-direction: row;
	}
	.ipm-card .card-image {
		width: 42%;
		flex: 0 0 42%;
		aspect-ratio: 4 / 3;
		align-self: stretch;
	}
	.ipm-card .card-image .img {
		border-radius: 4px 0 0 4px;
	}
	.ipm-card .card-content {
		flex: 1 1 auto;
		width: auto;
		border-top-width: 1px;
		border-left-width: 0;
		border-radius: 0 4px 4px 0;
	}
	.rtl-direction .ipm-card .card-content {
		border-left-width: 1px;
		border-right-width: 0;
		border-radius: 4px 0 0 4px;
	}
}
@media (min-width: 600px) and (max-width: 1299px) {
	.ipm-card .card-image {
		width: 38%;
		flex-basis: 38%;
	}
	.ipm-card .card-content {
		padding: .85rem 1rem;
	}
}
