/* Case Studies Page - Custom Styles */

/* Background Gradient */
.bg-gradient {
	background: linear-gradient(135deg, #ffffff 0%, #fcf7f9 100%);
}

.bg-soft-grape {
	background-color: rgba(122, 30, 79, 0.08) !important;
}

/* Enhanced Hero Content */
.enhanced-content {
	background: linear-gradient(135deg, rgba(122, 30, 79, 0.02) 0%, rgba(122, 30, 79, 0.05) 100%);
	padding: 1.5rem;
	border-radius: 1rem;
	border: 1px solid rgba(122, 30, 79, 0.1);
}

.stats-preview {
	margin-bottom: 1.5rem;
}

.stat-item {
	flex: 1;
	min-width: 100px;
	padding: 0.5rem;
	transition: all 0.3s ease;
}

.stat-item:hover {
	transform: translateY(-3px);
}

.stat-item h3 {
	font-weight: 800;
	transition: color 0.3s ease;
}

.stat-item:hover h3 {
	color: #5d1a3d !important;
}

.quick-filters .badge {
	transition: all 0.3s ease;
	font-weight: 600;
}

.quick-filters .badge:hover {
	transform: translateY(-2px);
	background-color: #7A1E4F !important;
	color: white !important;
	box-shadow: 0 5px 15px rgba(122, 30, 79, 0.2);
}

/* Hero Section - Redesigned */
.hero-image-wrapper {
	position: relative;
	padding: 20px;
}

.image-main {
	border-radius: 1rem !important;
	box-shadow: 0 15px 35px rgba(0, 0, 0, 0.1);
	transition: all 0.3s ease;
}

.image-main:hover {
	transform: translateY(-5px) scale(1.02);
	box-shadow: 0 20px 40px rgba(122, 30, 79, 0.15);
}

.circle-backdrop {
	position: absolute;
	top: -25px;
	right: -25px;
	width: 120px;
	height: 120px;
	background: rgba(122, 30, 79, 0.08);
	border-radius: 50%;
	z-index: -2;
}

.circle-striped {
	position: absolute;
	top: -5px;
	right: -5px;
	width: 60px;
	height: 60px;
	background: repeating-linear-gradient(45deg,
			rgba(122, 30, 79, 0.2),
			rgba(122, 30, 79, 0.2) 4px,
			rgba(90, 22, 58, 0.15) 4px,
			rgba(90, 22, 58, 0.15) 8px);
	border-radius: 50%;
	z-index: -1;
}

/* Filter Preview Badges */
.filter-preview .badge {
	transition: all 0.3s ease;
	font-weight: 600;
	font-size: 0.85rem;
}

.filter-preview .badge:hover {
	transform: translateY(-2px);
	background-color: #7A1E4F !important;
	color: white !important;
}

/* Scroll Indicator */
.scroll-indicator {
	display: flex;
	align-items: center;
	gap: 0.75rem;
	animation: bounce 2s infinite;
}

@keyframes bounce {
	0%, 20%, 50%, 80%, 100% {
		transform: translateY(0);
	}
	40% {
		transform: translateY(-10px);
	}
	60% {
		transform: translateY(-5px);
	}
}

/* Button hover color fix */
.btn-outline-grape:hover {
	background-color: #7A1E4F !important;
	border-color: #7A1E4F !important;
	color: white !important;
}

.btn-outline-white:hover {
	background-color: rgba(255, 255, 255, 0.2) !important;
	border-color: white !important;
	color: white !important;
}

/* Case Study Modals - Distinct design (different from insights/form modals) */
.case-study-modal .modal-dialog {
	max-width: 900px;
}

.case-study-modal .modal-content {
	border: none;
	border-radius: 16px;
	overflow: hidden;
	box-shadow: 0 25px 80px rgba(0, 0, 0, 0.2);
}

.case-study-modal .modal-header {
	border: none;
	padding: 0;
	position: relative;
}

.case-study-modal .modal-hero {
	height: 220px;
	overflow: hidden;
}

.case-study-modal .modal-hero img {
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.case-study-modal .modal-title-wrap {
	position: absolute;
	bottom: 0;
	left: 0;
	right: 0;
	padding: 2rem 2rem 1.5rem;
	background: linear-gradient(to top, rgba(122, 30, 79, 0.95), rgba(122, 30, 79, 0.7));
	color: white;
}

.case-study-modal .modal-title-wrap .modal-title {
	font-size: 1.5rem;
	font-weight: 700;
	margin: 0;
	padding-right: 2.5rem;
	color: white;
}

.case-study-modal .modal-title-wrap .btn-close {
	position: absolute;
	top: 1rem;
	right: 1rem;
	filter: brightness(0) invert(1);
	opacity: 0.9;
}

.case-study-modal .modal-body {
	padding: 2rem 2.5rem;
	max-height: 60vh;
	overflow-y: auto;
}

.case-study-modal .modal-body .cs-section {
	margin-bottom: 1.75rem;
}

.case-study-modal .modal-body .cs-section h4 {
	font-size: 0.85rem;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.8px;
	color: #7A1E4F;
	margin-bottom: 0.6rem;
}

.case-study-modal .modal-body .cs-section p,
.case-study-modal .modal-body .cs-section ul {
	margin-bottom: 0;
	color: #495057;
	line-height: 1.65;
}

.case-study-modal .modal-body .cs-section ul {
	padding-left: 1.25rem;
}

.case-study-modal .modal-body .cs-section ul li {
	margin-bottom: 0.4rem;
}

.case-study-modal .modal-body .cs-results {
	display: flex;
	gap: 1rem;
	flex-wrap: wrap;
	margin-top: 1rem;
}

.case-study-modal .modal-body .cs-result-box {
	flex: 1;
	min-width: 120px;
	text-align: center;
	padding: 1rem;
	background: rgba(122, 30, 79, 0.06);
	border-radius: 12px;
	border: 1px solid rgba(122, 30, 79, 0.12);
}

.case-study-modal .modal-body .cs-result-box .value {
	display: block;
	font-size: 1.5rem;
	font-weight: 800;
	color: #7A1E4F;
}

.case-study-modal .modal-body .cs-result-box .label {
	font-size: 0.8rem;
	color: #6c757d;
}

.case-study-modal .modal-footer {
	border-top: 1px solid #eee;
	padding: 1.25rem 2.5rem;
	background: #f8f9fa;
}

.case-study-modal .modal-footer .btn-grape {
	padding: 0.5rem 1.5rem;
}

.floating-badge {
	position: absolute;
	top: 20%;
	right: 10%;
	background: white;
	border-radius: 12px;
	padding: 1rem 1.5rem;
	box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
	border: 1px solid rgba(122, 30, 79, 0.1);
	z-index: 3;
	animation: float 3s ease-in-out infinite;
}

.badge-content {
	display: flex;
	align-items: center;
}

.badge-content i {
	font-size: 1.5rem;
}

/* ===== Filterable Grid ===== */
.case-study-filters {
	display: flex;
	flex-wrap: wrap;
	gap: 1.5rem 2rem;
	padding: 1.5rem 1.75rem;
	background: white;
	border-radius: 12px;
	box-shadow: 0 4px 20px rgba(0, 0, 0, 0.06);
	border: 1px solid #e9ecef;
}

.filter-group {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 0.75rem 1rem;
}

.filter-label {
	font-weight: 600;
	color: #495057;
	font-size: 0.95rem;
}

.filter-buttons {
	display: flex;
	flex-wrap: wrap;
	gap: 0.5rem;
}

.filter-btn {
	padding: 0.5rem 1rem;
	border: 1px solid #dee2e6;
	background: white;
	border-radius: 9999px;
	font-size: 0.9rem;
	font-weight: 500;
	color: #6c757d;
	cursor: pointer;
	transition: all 0.2s ease;
}

.filter-btn:hover {
	border-color: #7A1E4F;
	color: #7A1E4F;
}

.filter-btn.active {
	background: #7A1E4F;
	border-color: #7A1E4F;
	color: white;
}

/* Case Studies Grid */
.case-studies-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(380px, 1fr));
	gap: 2rem;
}

/* Case Study Cards - New Grid Layout */
.case-studies-grid .case-study-card {
	background: white;
	border-radius: 16px;
	overflow: hidden;
	box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
	border: 1px solid #e9ecef;
	transition: all 0.3s ease;
	display: flex;
	flex-direction: column;
}

.case-studies-grid .case-study-card:hover {
	transform: translateY(-6px);
	box-shadow: 0 20px 45px rgba(122, 30, 79, 0.12);
}

.case-card-image {
	position: relative;
	height: 200px;
	overflow: hidden;
}

.case-card-image img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	transition: transform 0.4s ease;
}

.case-study-card:hover .case-card-image img {
	transform: scale(1.05);
}

.case-card-image .case-badge {
	position: absolute;
	top: 1rem;
	left: 1rem;
	padding: 0.35rem 0.85rem;
	background: rgba(122, 30, 79, 0.95);
	color: white;
	font-size: 0.75rem;
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: 0.5px;
	border-radius: 9999px;
}

.case-card-body {
	padding: 1.75rem;
	flex: 1;
	display: flex;
	flex-direction: column;
}

.case-title {
	font-size: 1.35rem;
	font-weight: 700;
	margin-bottom: 1.25rem;
	line-height: 1.3;
	color: #212529;
}

.case-section {
	margin-bottom: 1.25rem;
}

.case-section-title {
	font-size: 0.8rem;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.8px;
	color: #7A1E4F;
	margin-bottom: 0.5rem;
}

.case-section p {
	font-size: 0.9rem;
	line-height: 1.55;
	color: #495057;
	margin: 0;
}

.strategy-list {
	margin: 0;
	padding-left: 1.25rem;
	font-size: 0.9rem;
	line-height: 1.6;
	color: #495057;
}

.strategy-list li {
	margin-bottom: 0.35rem;
}

.results-metrics {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 0.75rem;
	margin-bottom: 1rem;
}

.results-metrics .metric {
	text-align: center;
	padding: 0.75rem;
	background: rgba(122, 30, 79, 0.06);
	border-radius: 10px;
	border: 1px solid rgba(122, 30, 79, 0.1);
}

.results-metrics .metric-value {
	display: block;
	font-size: 1.35rem;
	font-weight: 800;
	color: #7A1E4F;
}

.results-metrics .metric-label {
	font-size: 0.7rem;
	text-transform: uppercase;
	letter-spacing: 0.5px;
	color: #6c757d;
}

.case-teaser {
	font-size: 0.9rem;
	line-height: 1.5;
	color: #6c757d;
	margin-bottom: 1rem;
}

/* Legacy support */
.case-image {
	height: 100%;
	min-height: 300px;
}

.case-content {
	display: flex;
	flex-direction: column;
	justify-content: center;
}

.results-grid {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
	gap: 1.5rem;
	margin-top: 2rem;
}

.result-item {
	text-align: center;
	padding: 1rem;
	background: rgba(122, 30, 79, 0.05);
	border-radius: 12px;
	border: 1px solid rgba(122, 30, 79, 0.1);
}

.result-item h4 {
	font-size: 1.8rem;
	font-weight: 700;
	margin-bottom: 0.5rem;
}

/* Stats Section */
.stat-card {
	background: white;
	border-radius: 16px;
	padding: 2.5rem 1.5rem;
	box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
	border: 1px solid #e9ecef;
	transition: all 0.3s ease;
}

.stat-card:hover {
	transform: translateY(-5px);
	box-shadow: 0 10px 25px rgba(122, 30, 79, 0.1);
}

.stat-icon {
	width: 80px;
	height: 80px;
	background: rgba(122, 30, 79, 0.1);
	border-radius: 50%;
	display: flex;
	align-items: center;
	justify-content: center;
	margin: 0 auto;
}

.stat-icon i {
	font-size: 2rem;
	color: #7A1E4F;
}

/* Industry Cards */
.industry-card {
	background: white;
	border-radius: 16px;
	box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
	border: 1px solid #e9ecef;
	transition: all 0.3s ease;
}

.industry-card:hover {
	transform: translateY(-3px);
	box-shadow: 0 10px 25px rgba(122, 30, 79, 0.1);
}

.industry-icon {
	width: 70px;
	height: 70px;
	background: rgba(122, 30, 79, 0.1);
	border-radius: 50%;
	display: flex;
	align-items: center;
	justify-content: center;
	margin: 0 auto;
}

.industry-icon i {
	font-size: 1.8rem;
	color: #7A1E4F;
}


/* Animations */
@keyframes float {

	0%,
	100% {
		transform: translateY(0px);
	}

	50% {
		transform: translateY(-10px);
	}
}

/* Responsive Design */
@media (max-width: 992px) {
	.case-studies-grid {
		grid-template-columns: 1fr;
	}

	.case-study-filters {
		flex-direction: column;
		align-items: stretch;
		padding: 1.25rem 1rem;
	}

	.filter-group {
		flex-direction: column;
		align-items: flex-start;
	}

	.case-study-card .row {
		flex-direction: column;
	}

	.case-image {
		min-height: 250px;
	}

	.results-grid {
		grid-template-columns: repeat(3, 1fr);
		gap: 1rem;
	}

	.stat-card {
		padding: 2rem 1rem;
	}
}

@media (max-width: 768px) {
	/* Section padding */
	.wrapper .container {
		padding-left: 1rem !important;
		padding-right: 1rem !important;
	}

	/* Hero */
	.display-2 {
		font-size: 1.75rem !important;
		line-height: 1.25;
	}

	.lead.fs-20 {
		font-size: 1rem !important;
	}

	.hero-image-wrapper {
		padding: 10px;
	}

	.case-studies-grid {
		grid-template-columns: 1fr;
		gap: 1.5rem;
	}

	.case-study-filters {
		padding: 1rem 0.75rem;
		gap: 1rem;
	}

	.filter-label {
		font-size: 0.9rem;
	}

	.filter-btn {
		padding: 0.45rem 0.85rem;
		font-size: 0.85rem;
	}

	.case-card-body {
		padding: 1.5rem;
	}

	.case-title {
		font-size: 1.15rem;
		line-height: 1.3;
	}

	.case-teaser {
		font-size: 0.85rem;
	}

	.results-metrics {
		grid-template-columns: repeat(3, 1fr);
		gap: 0.5rem;
	}

	.results-metrics .metric {
		padding: 0.6rem 0.5rem;
	}

	.results-metrics .metric-value {
		font-size: 1.1rem;
	}

	.results-metrics .metric-label {
		font-size: 0.65rem;
	}

	.case-study-card .btn-sm {
		width: 100%;
		text-align: center;
	}

	.results-grid {
		grid-template-columns: 1fr 1fr;
		gap: 1rem;
	}

	.result-item {
		padding: 0.8rem;
	}

	.result-item h4 {
		font-size: 1.5rem;
	}

	.floating-badge {
		top: 10%;
		right: 5%;
		padding: 0.75rem 1rem;
	}

	.badge-content i {
		font-size: 1.2rem;
	}

	/* Modal mobile - Close button at top right inside modal */
	.case-study-modal .modal-dialog {
		margin: 0.5rem;
		max-width: calc(100% - 1rem);
	}

	.case-study-modal .modal-hero {
		height: 160px;
	}

	.case-study-modal .modal-title-wrap .modal-title {
		font-size: 1.15rem;
		padding-right: 2.5rem;
	}

	/* Close button at top right on mobile */
	.case-study-modal .modal-title-wrap .btn-close {
		position: absolute;
		top: 1rem;
		right: 1rem;
		left: auto;
		bottom: auto;
		opacity: 0.9;
		filter: brightness(0) invert(1);
	}

	.case-study-modal .modal-body {
		padding: 1.5rem 1.25rem;
		max-height: 55vh;
	}

	.case-study-modal .modal-body .cs-results {
		flex-direction: column;
	}

	.case-study-modal .modal-body .cs-result-box {
		min-width: 100%;
	}
}

@media (max-width: 576px) {
	.wrapper .container {
		padding-left: 0.75rem !important;
		padding-right: 0.75rem !important;
	}

	.display-2 {
		font-size: 1.5rem !important;
	}

	.case-card-image {
		height: 180px;
	}

	.case-card-body {
		padding: 1.25rem;
	}

	.case-title {
		font-size: 1.05rem;
	}

	.results-metrics {
		grid-template-columns: 1fr;
		gap: 0.5rem;
	}

	.results-metrics .metric-value {
		font-size: 1.25rem;
	}

	.filter-group {
		gap: 0.5rem;
	}

	.filter-buttons {
		width: 100%;
		flex-wrap: wrap;
	}

	.filter-btn {
		flex: 1 1 auto;
		min-width: calc(50% - 0.25rem);
	}

	.results-grid {
		grid-template-columns: 1fr;
	}

	.stat-card {
		padding: 1.5rem 1rem;
	}

	.stat-icon {
		width: 60px;
		height: 60px;
	}

	.stat-icon i {
		font-size: 1.5rem;
	}

	.no-results-message .display-4 {
		font-size: 2rem !important;
	}

	footer .d-md-flex {
		flex-direction: column;
		align-items: flex-start !important;
		gap: 1rem;
	}
}

/* Custom Underline Animation */
.animated-underline {
	position: relative;
	text-decoration: none !important;
	/* Forces removal of browser default underline */
	display: inline-block;
	/* Ensures positioning is relative to text width */
}

.animated-underline::after {
	content: '';
	position: absolute;
	/* Controls the length (60% of text width) */
	width: 0;
	/* Controls thickness */
	height: 2px;
	/* Controls distance from text (Higher number = closer) */
	bottom: 2px;
	left: 50%;
	transform: translateX(-50%);
	background-color: #7A1E4F;
	/* Your Brand Grape Color */
	visibility: hidden;
}

/* Entry Animation for the Active State */
.animated-underline.active::after {
	visibility: visible;
	animation: underline-entry 0.8s cubic-bezier(0.65, 0, 0.35, 1) forwards;
}

@keyframes underline-entry {
	0% {
		width: 0;
	}

	100% {
		width: 60%;
		/* Adjust this % to make the line even shorter or longer */
	}
}

/* Social Media Icons Footer Styling - Match Index Page */
.x-social-icon i::before {
	content: "\edc5" !important;
	font-family: "unicons" !important;
	font-style: normal;
	font-weight: normal;
	display: inline-block;
	text-decoration: inherit;
	color: #ffffff;
	opacity: 1 !important;
}

/* Ensure the container uses flexbox for alignment */
.nav.social.social-white {
	display: flex !important;
	align-items: center !important;
	gap: 20px !important;
	/* This creates exactly equal 20px space between every icon */
}

/* Reset anchor tags to ensure they don't have inherited margins */
.nav.social.social-white a {
	margin: 0 !important;
	padding: 0 !important;
	display: inline-flex !important;
	align-items: center !important;
	justify-content: center !important;
	color: #ffffff !important;
	line-height: 1 !important;
}

/* Align the SVG Twitter-X icon perfectly with FontIcons */
.x-social-icon {
	height: 14px;
	/* Matches the SVG height for a tight bounding box */
}

.x-social-icon svg {
	display: block;
	fill: #ffffff !important;
	/* Ensures the X is white */
}

/* Ensure Unicons match the visual center */
.nav.social.social-white i {
	font-size: 1rem;
	display: block;
	line-height: 1;
}

.widget-title {
    margin-bottom: 1.25rem !important;
    font-size: 0.95rem !important;
    text-transform: uppercase;
    letter-spacing: 0.05rem;
    color: #ffffff !important;
}

footer .fs-sm,
footer address,
footer p,
footer li a {
    font-size: 0.85rem !important;
    line-height: 1.6;
    color: rgba(255, 255, 255, 0.6) !important;
}
/* Hover effect */
.hover-grape:hover {
    color: #7a1e4f !important;
}
