/* Homepage-only adaptation of the supplied Tracle reference, in the existing silver UI. */
.home-reference-section {
	--home-panel-border: rgba(var(--ui-text-silver-rgb), .2);
	--home-panel-surface: var(--ui-panel-surface);
	--home-light-origin: 22%;
	isolation: isolate;
}

.home-reference-section::before,
.home-reference-section::after {
	content: none;
	position: absolute;
	z-index: 0;
	pointer-events: none;
	width: min(780px, 76vw);
	height: 900px;
	background: radial-gradient(ellipse at var(--home-light-origin) 50%, rgba(var(--ui-text-silver-rgb), .19) 0, rgba(var(--ui-text-silver-rgb), .08) 26%, transparent 68%);
}

#products.home-reference-section::before {
	top: 14%;
	left: -48px;
}

#products.home-reference-section::after {
	--home-light-origin: 78%;
	right: -48px;
	bottom: -16%;
	opacity: .7;
}

#Testimonial.home-reference-section::before {
	--home-light-origin: 78%;
	right: -48px;
	top: 12%;
}

#Testimonial.home-reference-section::after {
	left: -48px;
	bottom: -12%;
	opacity: .65;
}

#faq.home-reference-section::before {
	left: -48px;
	top: 2%;
}

#faq.home-reference-section::after {
	--home-light-origin: 78%;
	right: -48px;
	bottom: -35%;
	opacity: .65;
}

/* Override legacy important fills while keeping a controlled, light-free hover. */
#products .product-card,
#products .product-card:hover {
	border: 1px solid var(--home-panel-border) !important;
	border-radius: 24px;
	background: var(--home-panel-surface) !important;
	box-shadow: var(--ui-panel-inset-shadow), var(--ui-panel-shadow) !important;
	transform: none !important;
	transition: transform .22s ease, border-color .22s ease !important;
}

@media (hover: hover) and (pointer: fine) {
	#products .product-card:hover,
	#products .product-card:focus-within {
		border-color: rgba(var(--ui-text-silver-rgb), .42) !important;
		transform: translateY(-3px) !important;
	}
}

body.home .section-bottom-silver-glow {
	background: radial-gradient(ellipse 66% 60% at 50% 100%, rgba(var(--ui-text-silver-rgb), .44) 0, rgba(var(--ui-text-silver-rgb), .26) 30%, rgba(var(--ui-text-silver-rgb), .13) 52%, rgba(var(--ui-text-silver-rgb), .06) 66%, transparent 86%);
}

body.home .tech-marquee-compact.marquee-section {
	background: #0b0b0b !important;
	border: 1px solid rgba(var(--ui-text-silver-rgb), .2) !important;
	border-image: none !important;
	border-radius: 0;
	box-shadow: var(--ui-panel-inset-shadow) !important;
}

body.home .tech-marquee-compact.marquee-section::before {
	content: none !important;
	display: none !important;
}

/* Override the older hero utility fills and mobile shadows, not their geometry. */
body.home #home .hero-highlight-pill,
body.home #home .hero-mobile-highlight-pill,
body.home #home .hero-social {
	background: var(--ui-panel-surface) !important;
	border: 1px solid rgba(var(--ui-text-silver-rgb), .2) !important;
	border-radius: 999px;
	box-shadow: var(--ui-panel-inset-shadow), 0 8px 20px rgba(0, 0, 0, .22) !important;
}

/* The existing hover icon filter is dark, so retain its original white surface. */
body.home #home .hero-social:hover {
	background: #fff !important;
	border-color: #fff !important;
	box-shadow: inset 0 0 25px rgba(0, 0, 0, .12), 0 0 20px rgba(255, 255, 255, .5) !important;
}

body.home #home .hero-grid-overlay {
	-webkit-mask-image: linear-gradient(180deg, #000 0%, #000 24%, rgba(0, 0, 0, .6) 58%, transparent 100%);
	mask-image: linear-gradient(180deg, #000 0%, #000 24%, rgba(0, 0, 0, .6) 58%, transparent 100%);
}

@media (max-width: 767px) {
	body.home #home .hero-grid-overlay {
		opacity: .02;
	}
}

#Testimonial .home-review-inner {
	position: relative;
	z-index: 1;
	max-width: 1350px;
	margin-inline: auto;
	padding-inline: 15px;
}

#Testimonial .home-review-grid {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 24px;
	margin: 60px auto 0;
	align-items: start;
}

#Testimonial.home-reviews-ready .home-review-grid {
	height: 1100px;
	overflow: hidden;
	mask-image: linear-gradient(transparent, #000 6%, #000 91%, transparent);
}

#Testimonial .home-review-column {
	min-width: 0;
	max-width: 424px;
}

#Testimonial .home-review-track,
#Testimonial .home-review-group {
	display: flex;
	flex-direction: column;
	gap: 24px;
}

#Testimonial .home-review-track {
	animation: home-review-rise 70s linear infinite;
	animation-play-state: paused;
	transform: none;
}

#Testimonial.home-reviews-running .home-review-track {
	animation-play-state: running;
	will-change: transform;
}

#Testimonial .home-review-column--reverse .home-review-track {
	animation-direction: reverse;
}

#Testimonial .home-review-group {
	flex: none;
}

#Testimonial .home-review-card {
	position: relative;
	isolation: isolate;
	flex: none;
	padding: 24px;
	border: 1px solid var(--home-panel-border);
	border-radius: 16px;
	background: #0b0b0b;
	box-shadow: inset 0 4px 85.1px #1c1c1c;
}

#Testimonial .home-review-card::before {
	content: "";
	position: absolute;
	inset: 0;
	z-index: -1;
	border-radius: inherit;
	background: url("../images/product-reference/review-glow.webp") center / cover no-repeat;
	filter: grayscale(1);
	opacity: 0;
	pointer-events: none;
}

#Testimonial .home-review-card:nth-child(odd)::before {
	opacity: .8;
}

#Testimonial .home-review-client {
	display: flex;
	align-items: center;
	gap: 12px;
	margin-bottom: 20px;
}

#Testimonial .home-review-avatar {
	width: 44px;
	height: 44px;
	flex: 0 0 44px;
	object-fit: cover;
	object-position: center 22%;
	border-radius: 100px;
	background: #fff;
}

#Testimonial .home-review-name {
	margin: 0;
	font-size: 16px;
	font-weight: 500;
	line-height: 1.5;
	color: var(--ui-text-silver);
}

#Testimonial .home-review-role {
	margin: 4px 0 0;
	font-size: 12px;
	line-height: 1.5;
	color: rgba(var(--ui-text-silver-rgb), .55);
}

#Testimonial .home-review-quote {
	margin: 0;
	font-size: 18px;
	line-height: 1.65;
	color: rgba(var(--ui-text-silver-rgb), .8);
}

#Testimonial[data-active-lang="ar"] .home-review-card {
	direction: rtl;
	text-align: right;
}

@keyframes home-review-rise {
	from { transform: translateY(0); }
	to { transform: translateY(calc(-1 * var(--home-review-distance, 0px))); }
}

/* Specificity intentionally replaces the legacy homepage accordion, not product FAQs. */
#faq .faq-layout {
	max-width: 960px;
}

#faq .faq-item-wrapper {
	gap: 24px;
}

#faq .faq-item {
	position: relative;
	isolation: isolate;
	padding: 0;
	padding-bottom: 36px;
	border: 1px solid var(--home-panel-border) !important;
	border-radius: 20px;
	background: var(--home-panel-surface) !important;
	box-shadow: var(--ui-panel-inset-shadow) !important;
	cursor: default;
	transition: border-color .3s, box-shadow .3s;
}

#faq .faq-item:hover {
	border-color: var(--home-panel-border) !important;
}

#faq .faq-item.is-active {
	border-color: rgba(var(--ui-text-silver-rgb), .4) !important;
	box-shadow: var(--ui-panel-inset-shadow) !important;
}

#faq .faq-item::before {
	content: "";
	position: absolute;
	inset: 0;
	z-index: -1;
	border-radius: inherit;
	background: url("../images/product-reference/faq-glow.webp") center / 100% 100% no-repeat;
	filter: grayscale(1);
	opacity: 0;
	transition: opacity .3s;
	pointer-events: none;
}

#faq .faq-item.is-active::before {
	opacity: 1;
}

#faq .faq-item > .glow-inner,
#faq .faq-item > .glow-overlay {
	display: none;
}

#faq .faq-title-wrap {
	position: relative;
	z-index: 1;
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 20px;
	width: 100%;
	padding: 36px 36px 0;
	margin: 0;
	border: 0;
	border-radius: 0;
	background: transparent;
	color: inherit;
	font: inherit;
	text-align: start;
	cursor: pointer;
	box-shadow: none;
}

#faq .faq-title-wrap:hover,
#faq .faq-title-wrap:focus {
	background: transparent;
	color: inherit;
}

#faq .faq-title-wrap:focus-visible {
	outline: 2px solid var(--ui-text-silver);
	outline-offset: -8px;
	border-radius: 12px;
}

#faq .faq-title {
	margin: 0;
	font-size: 18px;
	font-weight: 500;
	line-height: 1.5;
}

#faq .faq-icon {
	width: 28px;
	height: 28px;
	flex: 0 0 28px;
	border: 1px solid rgba(var(--ui-text-silver-rgb), .16);
	border-radius: 8px;
	background: rgba(255, 255, 255, .04);
}

#faq .faq-text-wrap {
	display: grid;
	grid-template-rows: 0fr;
	max-height: none;
	opacity: 0;
	transition: grid-template-rows .35s ease, opacity .25s ease;
}

#faq .faq-item.is-active .faq-text-wrap {
	grid-template-rows: 1fr;
	max-height: none;
	opacity: 1;
}

#faq .faq-text-wrap > div {
	min-height: 0;
	max-width: none;
	overflow: hidden;
	padding: 0 36px;
}

#faq .faq-text {
	padding: 24px 0 0;
	margin: 0;
	font-size: 16px;
	line-height: 1.7;
	color: rgba(var(--ui-text-silver-rgb), .65);
}

/* The parent theme's button reset uses nowrap; allow narrow FAQ cards to grow. */
@media (max-width: 1024px) {
	#faq .faq-title-wrap {
		white-space: normal;
	}

	#faq .faq-title {
		flex: 1 1 0%;
		min-width: 0;
		overflow-wrap: anywhere;
	}
}

@media (max-width: 1024px) {
	.home-reference-section::before,
	.home-reference-section::after { display: none; }
}

@media (max-width: 991px) {
	#Testimonial .home-review-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
	#Testimonial.home-reviews-ready .home-review-grid { height: 800px; }
	#Testimonial.home-reviews-ready .home-review-column:nth-child(3) { display: none; }
	#Testimonial .home-review-column { max-width: none; }
	#Testimonial .home-review-card { padding: 20px; }
}

@media (max-width: 767px) {
	#Testimonial .home-review-grid { grid-template-columns: minmax(0, 1fr); gap: 20px; }
	#Testimonial.home-reviews-ready .home-review-column:nth-child(2) { display: none; }
	#Testimonial .home-review-track,
	#Testimonial .home-review-group { gap: 20px; }
	#Testimonial .home-review-card { padding: 16px; }
	#Testimonial .home-review-quote { font-size: 16px; }
	#faq .faq-title-wrap { padding: 36px 20px 0; }
	#faq .faq-text-wrap > div { padding: 0 20px; }
}

@media (max-width: 479px) {
	#faq .faq-item { padding-bottom: 24px; }
	#faq .faq-title-wrap { padding: 24px 16px 0; }
	#faq .faq-text-wrap > div { padding: 0 16px; }
	#faq .faq-text { padding-top: 16px; }
}

@media (prefers-reduced-motion: reduce) {
	#products .product-card,
	#products .product-card:hover,
	#products .product-card:focus-within {
		transform: none !important;
		transition: none !important;
	}

	#Testimonial .home-review-track { animation: none; transform: none; }
	#Testimonial.home-reviews-ready .home-review-grid { height: auto; overflow: visible; mask-image: none; }
	#Testimonial .home-review-clone { display: none; }
	#faq .faq-text-wrap,
	#faq .faq-item,
	#faq .faq-item::before { transition: none; }
}
