/* Athreya Restore — homepage hero.
   Rebuilds the 1200x400 Smart Slider hero on Swiper. Brand green #41a62a is the
   theme's own accent (30 uses in arthreya/style.css). */

.athreya-hero {
	--athreya-accent: #41a62a;
	max-width: 1200px;
	margin: 0 auto;
	position: relative;
	overflow: hidden;
	background: #2b2b2b;
}

/* arthreya/style.css sets `.home_banner img { width:100%; height:100px }` (and 141px in a
   media query). Both would flatten the hero, so override with higher specificity. */
.home_banner .athreya-hero img,
.athreya-hero .swiper-slide img {
	display: block;
	width: 100%;
	height: auto;
	aspect-ratio: 1200 / 400;
	object-fit: cover;
	margin: 0;
}

/* Reserve the slot before Swiper initialises so the page does not jump. */
.athreya-hero:not(.swiper-initialized) .swiper-wrapper {
	display: block;
}
.athreya-hero:not(.swiper-initialized) .swiper-slide:not(:first-child) {
	display: none;
}

.athreya-hero .swiper-button-prev,
.athreya-hero .swiper-button-next {
	color: #fff;
	width: 44px;
	height: 44px;
	background: rgba(0, 0, 0, .35);
	border-radius: 50%;
	transition: background .2s ease;
}
.athreya-hero .swiper-button-prev:hover,
.athreya-hero .swiper-button-next:hover {
	background: var(--athreya-accent);
}
.athreya-hero .swiper-button-prev::after,
.athreya-hero .swiper-button-next::after {
	font-size: 18px;
	font-weight: 700;
}
.athreya-hero .swiper-button-prev:focus-visible,
.athreya-hero .swiper-button-next:focus-visible,
.athreya-hero .swiper-pagination-bullet:focus-visible {
	outline: 3px solid var(--athreya-accent);
	outline-offset: 3px;
}

.athreya-hero .swiper-pagination-bullet {
	width: 11px;
	height: 11px;
	background: #fff;
	opacity: .55;
	transition: opacity .2s ease, background .2s ease;
}
.athreya-hero .swiper-pagination-bullet-active {
	background: var(--athreya-accent);
	opacity: 1;
}

@media (max-width: 782px) {
	.athreya-hero .swiper-button-prev,
	.athreya-hero .swiper-button-next {
		display: none;
	}
}

@media (prefers-reduced-motion: reduce) {
	.athreya-hero .swiper-wrapper {
		transition-duration: 1ms !important;
	}
}

/* ---- recovered headline overlay -------------------------------------------
   Copy comes from Athreya's own disabled Revolution Slider (see athreya-restore.php).
   Sits above the slides and stays put while they change. */
.athreya-hero-caption {
	position: absolute;
	z-index: 5;
	top: 50%;
	left: 6%;
	right: 6%;
	transform: translateY(-50%);
	pointer-events: none;          /* clicks fall through to the slider except on the button */
	max-width: 620px;
	/* the theme sets .home_banner{text-align:center}, which the caption would inherit and
	   render as an off-centre cluster; force left alignment to match the original layout */
	text-align: left;
}
.athreya-hero-caption .ahc-kicker,
.athreya-hero-caption .ahc-title {
	margin: 0;
	color: #fff;
	text-shadow: 0 2px 10px rgba(0,0,0,.55);
	line-height: 1.15;
}
.athreya-hero-caption .ahc-kicker {
	font-size: clamp(14px, 1.6vw, 22px);
	font-weight: 400;
	letter-spacing: .01em;
	opacity: .95;
}
.athreya-hero-caption .ahc-title {
	font-size: clamp(22px, 3.4vw, 44px);
	font-weight: 700;
	margin-top: .18em;
}
.athreya-hero-caption .ahc-cta {
	pointer-events: auto;
	display: inline-block;
	margin-top: 1.1em;
	padding: 11px 26px;
	background: rgb(79,161,172);   /* the theme's own button colour */
	color: #fff;
	font-size: clamp(12px, 1.1vw, 15px);
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: .04em;
	border-radius: 2px;
	text-decoration: none;
	transition: background .2s ease;
}
.athreya-hero-caption .ahc-cta:hover,
.athreya-hero-caption .ahc-cta:focus { background: #41a62a; color: #fff; }
.athreya-hero-caption .ahc-cta:focus-visible { outline: 3px solid #fff; outline-offset: 3px; }

/* keep the caption clear of the arrows on small screens */
@media screen and (max-width: 782px) {
	.athreya-hero-caption { left: 20px; right: 20px; text-align: left; }
	.athreya-hero-caption .ahc-cta { margin-top: .8em; padding: 9px 18px; }
}
