/* Annamalai University — site-wide interactions (hero slider). */

/* ---------------------------------------------------------- hero slider */

.annu-hero-slider {
	position: relative;
	isolation: isolate;
}

.annu-hero-slider .annu-slide {
	transition: opacity 900ms ease;
	will-change: opacity;
}

.annu-hero-slider .annu-slide-img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.annu-hero-slider:focus-visible {
	outline: 3px solid #c9a227;
	outline-offset: -3px;
}

/* Controls ------------------------------------------------------------- */

.annu-hero-ui {
	position: absolute;
	right: 16px;
	bottom: 14px;
	z-index: 5;
	display: flex;
	align-items: center;
	gap: 12px;
	padding: 6px 10px;
	border-radius: 999px;
	background: rgba(7, 28, 51, 0.55);
	-webkit-backdrop-filter: blur(4px);
	backdrop-filter: blur(4px);
}

.annu-hero-dots {
	display: flex;
	align-items: center;
	gap: 6px;
	margin: 0;
	padding: 0;
	list-style: none;
}

.annu-hero-dot {
	width: 9px;
	height: 9px;
	margin: 0;
	padding: 0;
	border: 0;
	border-radius: 50%;
	background: rgba(255, 255, 255, 0.45);
	cursor: pointer;
	transition: background-color 150ms ease, transform 150ms ease;
}

.annu-hero-dot:hover,
.annu-hero-dot:focus-visible {
	background: rgba(255, 255, 255, 0.85);
	transform: scale(1.15);
}

.annu-hero-dot[aria-current="true"] {
	background: #c9a227;
	transform: scale(1.15);
}

.annu-hero-toggle {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 26px;
	height: 26px;
	margin: 0;
	padding: 0;
	border: 0;
	border-radius: 50%;
	background: transparent;
	color: #ffffff;
	cursor: pointer;
}

.annu-hero-toggle:hover,
.annu-hero-toggle:focus-visible {
	background: rgba(255, 255, 255, 0.18);
}

.annu-hero-toggle svg {
	width: 12px;
	height: 12px;
	fill: currentColor;
	pointer-events: none;
}

.annu-hero-arrow {
	position: absolute;
	top: 50%;
	z-index: 5;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 42px;
	height: 42px;
	margin: 0;
	padding: 0;
	border: 1px solid rgba(255, 255, 255, 0.55);
	border-radius: 50%;
	background: rgba(7, 28, 51, 0.45);
	color: #ffffff;
	cursor: pointer;
	opacity: 0.55;
	transform: translateY(-50%);
	transition: opacity 180ms ease, background-color 180ms ease;
}

.annu-hero-arrow svg {
	width: 16px;
	height: 16px;
	fill: none;
	stroke: currentColor;
	stroke-width: 2;
	stroke-linecap: round;
	stroke-linejoin: round;
	pointer-events: none;
}

.annu-hero-prev {
	left: 14px;
}

.annu-hero-next {
	right: 14px;
}

.annu-hero-slider:hover .annu-hero-arrow,
.annu-hero-slider:focus-within .annu-hero-arrow,
.annu-hero-arrow:focus-visible {
	opacity: 1;
}

.annu-hero-arrow:hover,
.annu-hero-arrow:focus-visible {
	background: rgba(7, 28, 51, 0.75);
}

/* A screen-reader-only label for the controls. */
.annu-sr-only {
	position: absolute !important;
	width: 1px;
	height: 1px;
	margin: -1px;
	padding: 0;
	overflow: hidden;
	clip: rect(0 0 0 0);
	clip-path: inset(50%);
	border: 0;
	white-space: nowrap;
}

.annu-hero-slider.is-paused .annu-hero-toggle {
	color: #c9a227;
}

@media (max-width: 700px) {
	.annu-hero-ui {
		right: 10px;
		bottom: 10px;
		gap: 8px;
		padding: 5px 8px;
	}

	.annu-hero-arrow {
		width: 34px;
		height: 34px;
		opacity: 1;
	}

	.annu-hero-prev {
		left: 8px;
	}

	.annu-hero-next {
		right: 8px;
	}
}

@media (prefers-reduced-motion: reduce) {
	.annu-hero-slider .annu-slide,
	.annu-hero-dot,
	.annu-hero-arrow {
		transition: none;
	}

	.annu-hero-arrow {
		opacity: 1;
	}
}
