/* === Instagram Feed Container === */
.wpif2-instagram-feed {
	padding: 2.5rem 0;
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
	display: flex;
	justify-content: center;
}

.wpif2-inner {
	width: 70%;
}

/* === Profile Header === */
.wpif2-profile {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 2rem;
	padding: 1rem 1.5rem;
	flex-wrap: wrap;
}

.wpif2-profile__left {
	display: flex;
	align-items: center;
	gap: 0.875rem;
}

.wpif2-profile__avatar-ring {
	width: 56px;
	height: 56px;
	border-radius: 50%;
	padding: 3px;
	background: linear-gradient(45deg, #f09433, #e6683c, #dc2743, #cc2366, #bc1888);
	flex-shrink: 0;
	display: flex;
	align-items: center;
	justify-content: center;
}

.wpif2-profile__avatar {
	width: 48px;
	height: 48px;
	border-radius: 50%;
	object-fit: cover;
	border: 2px solid #fff;
	display: block;
}

.wpif2-profile__info {
	display: flex;
	flex-direction: column;
	gap: 0.125rem;
}

.wpif2-profile__name {
	font-size: 0.9375rem;
	font-weight: 600;
	color: #262626;
	line-height: 1.3;
}

.wpif2-profile__handle {
	font-size: 0.8125rem;
	color: #8e8e8e;
	line-height: 1.3;
}

.wpif2-profile__right {
	display: flex;
	align-items: center;
	gap: 1.5rem;
}

.wpif2-profile__stats {
	display: flex;
	gap: 1.5rem;
}

.wpif2-profile__stat {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 0;
}

.wpif2-profile__stat-number {
	font-size: 1rem;
	font-weight: 700;
	color: #262626;
	line-height: 1.3;
}

.wpif2-profile__stat-label {
	font-size: 0.75rem;
	color: #8e8e8e;
	line-height: 1.3;
}

.wpif2-profile__follow-btn {
	display: inline-flex;
	align-items: center;
	gap: 0.375rem;
	background: #e50809;
	color: #fff;
	font-size: 0.875rem;
	font-weight: 600;
	padding: 0.5rem 1.25rem;
	border-radius: 4px;
	text-decoration: none;
	transition: background 0.2s ease;
	white-space: nowrap;
}

.wpif2-profile__follow-btn:hover {
	background: #c70607;
	color: #fff;
}

.wpif2-profile__follow-btn svg {
	flex-shrink: 0;
}

/* === Post Carousel === */
.wpif2-carousel {
	position: relative;
}

.wpif2-carousel__track {
	display: flex;
	gap: 4px;
	overflow-x: auto;
	scroll-snap-type: x mandatory;
	scroll-behavior: smooth;
	-webkit-overflow-scrolling: touch;
	scrollbar-width: none;
}

.wpif2-carousel__track::-webkit-scrollbar {
	display: none;
}

.wpif2-carousel__slide {
	flex: 0 0 calc(20% - 3.2px);
	scroll-snap-align: start;
	min-width: 0;
}

.wpif2-carousel__image-link {
	display: block;
	aspect-ratio: 3 / 4;
	overflow: hidden;
}

.wpif2-carousel__image {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
	transition: transform 0.3s ease;
}

.wpif2-carousel__image-link:hover .wpif2-carousel__image {
	transform: scale(1.05);
}

.wpif2-carousel__caption {
	font-size: 0.8125rem;
	color: #8e8e8e;
	line-height: 1.5;
	margin: 8px;
	display: -webkit-box;
	-webkit-line-clamp: 3;
	-webkit-box-orient: vertical;
	overflow: hidden;
}

/* === Navigation Arrows (half-circle) === */
.wpif2-carousel__prev,
.wpif2-carousel__next {
	position: absolute;
	top: 50%;
	transform: translateY(-50%);
	width: 32px;
	height: 56px;
	background: rgba(0, 0, 0, 0.6);
	color: #fff;
	border: none;
	cursor: pointer;
	display: flex;
	align-items: center;
	z-index: 2;
	transition: background 0.2s ease;
	padding: 0;
}

.wpif2-carousel__prev {
	left: 0;
	border-radius: 0 56px 56px 0;
	justify-content: center;
	padding-right: 4px;
}

.wpif2-carousel__next {
	right: 0;
	border-radius: 56px 0 0 56px;
	justify-content: center;
	padding-left: 4px;
}

.wpif2-carousel__prev:hover,
.wpif2-carousel__next:hover {
	background: rgba(0, 0, 0, 0.85);
}

/* === Empty State === */
.wpif2-instagram-feed__empty {
	text-align: center;
	color: #8e8e8e;
	padding: 2rem;
}

/* === Responsive === */
@media (max-width: 1024px) {
	.wpif2-carousel__slide {
		flex: 0 0 calc(33.333% - 2.67px);
	}
}

@media (max-width: 600px) {
	.wpif2-profile {
		flex-direction: column;
		gap: 1rem;
		text-align: center;
	}

	.wpif2-profile__left {
		flex-direction: column;
	}

	.wpif2-profile__right {
		flex-direction: column;
		gap: 1rem;
	}

	.wpif2-carousel__slide {
		flex: 0 0 100%;
	}

	/* Full-width mobile slide: use square crops like the native IG grid. */
	.wpif2-carousel__image-link {
		aspect-ratio: 1 / 1;
	}

	.wpif2-carousel__image {
		object-position: center;
	}

	.wpif2-carousel__prev,
	.wpif2-carousel__next {
		width: 28px;
		height: 48px;
	}

	.wpif2-inner {
		width: 100%;
	}
}
