/* Facebook Feed Display — front-end styles
   Scoped under .ffd-feed; colors/typography inherit from the active theme. */

.ffd-feed {
	--ffd-text: #1c1f27;
	--ffd-muted: #6b7280;
	--ffd-border: #e6e8ec;
	--ffd-radius: 12px;
	--ffd-accent: #1877f2;

	display: grid;
	gap: 1.25rem;
	font-family: inherit;
}

.ffd-layout-grid {
	grid-template-columns: repeat( auto-fill, minmax( 16rem, 1fr ) );
}

.ffd-layout-list {
	grid-template-columns: 1fr;
	max-width: 40rem;
}

.ffd-post {
	display: flex;
	flex-direction: column;
	border: 1px solid var( --ffd-border );
	border-radius: var( --ffd-radius );
	overflow: hidden;
	background: #fff;
}

.ffd-layout-list .ffd-post {
	flex-direction: row;
}

.ffd-post-image-link {
	display: block;
	aspect-ratio: 16 / 9;
	overflow: hidden;
	background: var( --ffd-border );
	flex-shrink: 0;
}

.ffd-layout-list .ffd-post-image-link {
	width: 9rem;
	aspect-ratio: 1 / 1;
}

.ffd-post-image {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

.ffd-post-body {
	display: flex;
	flex-direction: column;
	gap: 0.6rem;
	padding: 1rem;
	flex: 1;
}

.ffd-post-message {
	margin: 0;
	font-size: 0.95rem;
	line-height: 1.45;
	color: var( --ffd-text );
}

.ffd-post-meta {
	margin-top: auto;
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 0.5rem;
	font-size: 0.8rem;
	color: var( --ffd-muted );
}

.ffd-post-link {
	display: inline-flex;
	align-items: center;
	gap: 0.25rem;
	color: var( --ffd-accent );
	text-decoration: none;
	font-weight: 600;
}

.ffd-post-link:hover {
	text-decoration: underline;
}

.ffd-post-link svg {
	width: 0.85rem;
	height: 0.85rem;
}

.ffd-error,
.ffd-empty {
	color: var( --ffd-muted );
	font-size: 0.9rem;
}

@media ( max-width: 480px ) {
	.ffd-layout-list .ffd-post {
		flex-direction: column;
	}
	.ffd-layout-list .ffd-post-image-link {
		width: 100%;
		aspect-ratio: 16 / 9;
	}
}
