/* ==========================================================================
   Animated Headline (.sentio-animated-headline)
   ==========================================================================
   Extracted from frontend.css during the Batch 8 mechanical extraction
   (2026-04-18). Behavior-preserving.
   ========================================================================== */

/* Base */
.sentio-animated-headline {
	text-align: center;
}

.sentio-animated-headline__link {
	text-decoration: none;
	color: inherit;
}

.sentio-animated-headline__text {
	display: inline;
	margin: 0;
	font-weight: inherit;
	font-size: inherit;
	line-height: inherit;
}

/* Animated wrapper — inline for highlighted, inline-block for rotating */
.sentio-animated-headline__animated {
	position: relative;
	display: inline;
}

.sentio-animated-headline--rotating .sentio-animated-headline__animated {
	display: inline-block;
	vertical-align: baseline;
}

/* ---- Highlighted Mode ---- */

.sentio-animated-headline--highlighted .sentio-animated-headline__word {
	position: relative;
	z-index: 1;
}

/* SVG shape overlay */
.sentio-animated-headline__shape {
	position: absolute;
	left: -4%;
	top: -8%;
	width: 108%;
	height: 116%;
	z-index: 0;
	overflow: visible;
	pointer-events: none;
}

.sentio-animated-headline__shape path {
	fill: none;
	stroke: #6366f1;
	stroke-width: 8;
	stroke-dasharray: 0;
	stroke-dashoffset: 0;
	opacity: 0;
	transition: opacity 0.1s ease;
}

/* Animated state — JS adds this class */
.sentio-animated-headline--visible .sentio-animated-headline__shape path {
	opacity: 1;
	animation: sentio-shape-draw var(--sentio-headline-duration, 1200ms) ease forwards;
}

@keyframes sentio-shape-draw {
	0%   { stroke-dashoffset: var(--sentio-path-length); }
	100% { stroke-dashoffset: 0; }
}

/* ---- Rotating Mode — Shared ---- */

.sentio-animated-headline--rotating .sentio-animated-headline__word {
	display: inline-block;
	position: absolute;
	left: 0;
	top: 0;
	opacity: 0;
	white-space: nowrap;
	visibility: hidden;
}

.sentio-animated-headline--rotating .sentio-animated-headline__word--active {
	position: relative;
	opacity: 1;
	visibility: visible;
}

/* ---- Typing ---- */
.sentio-headline--anim-typing .sentio-animated-headline__word {
	position: relative;
	display: none;
	opacity: 1;
	visibility: visible;
}

.sentio-headline--anim-typing .sentio-animated-headline__word--active {
	display: inline;
}

.sentio-animated-headline__cursor {
	display: inline;
	font-weight: 400;
	animation: sentio-cursor-blink 0.7s step-end infinite;
}

@keyframes sentio-cursor-blink {
	0%, 100% { opacity: 1; }
	50%      { opacity: 0; }
}

/* ---- Clip ---- */
.sentio-headline--anim-clip .sentio-animated-headline__animated {
	overflow: hidden;
}

.sentio-headline--anim-clip .sentio-animated-headline__word {
	opacity: 1;
	visibility: visible;
}

.sentio-headline--anim-clip .sentio-animated-headline__word--active {
	animation: sentio-clip-in 0.6s ease both;
}

.sentio-headline--anim-clip .sentio-animated-headline__word--out {
	animation: sentio-clip-out 0.6s ease both;
}

@keyframes sentio-clip-in {
	0%   { clip-path: inset(0 100% 0 0); }
	100% { clip-path: inset(0 0 0 0); }
}

@keyframes sentio-clip-out {
	0%   { clip-path: inset(0 0 0 0); }
	100% { clip-path: inset(0 0 0 100%); }
}

/* ---- Flip ---- */
.sentio-headline--anim-flip .sentio-animated-headline__animated {
	perspective: 600px;
}

.sentio-headline--anim-flip .sentio-animated-headline__word--active {
	animation: sentio-flip-in 0.6s ease both;
}

.sentio-headline--anim-flip .sentio-animated-headline__word--out {
	animation: sentio-flip-out 0.4s ease both;
}

@keyframes sentio-flip-in {
	0%   { opacity: 0; transform: rotateX(90deg); }
	100% { opacity: 1; transform: rotateX(0); }
}

@keyframes sentio-flip-out {
	0%   { opacity: 1; transform: rotateX(0); }
	100% { opacity: 0; transform: rotateX(-90deg); }
}

/* ---- Slide ---- */
.sentio-headline--anim-slide .sentio-animated-headline__word--active {
	animation: sentio-slide-in 0.5s ease both;
}

.sentio-headline--anim-slide .sentio-animated-headline__word--out {
	animation: sentio-slide-out 0.5s ease both;
}

@keyframes sentio-slide-in {
	0%   { opacity: 0; transform: translateY(100%); }
	100% { opacity: 1; transform: translateY(0); }
}

@keyframes sentio-slide-out {
	0%   { opacity: 1; transform: translateY(0); }
	100% { opacity: 0; transform: translateY(-100%); }
}

/* ---- Zoom ---- */
.sentio-headline--anim-zoom .sentio-animated-headline__word--active {
	animation: sentio-zoom-in 0.5s ease both;
}

.sentio-headline--anim-zoom .sentio-animated-headline__word--out {
	animation: sentio-zoom-out 0.4s ease both;
}

@keyframes sentio-zoom-in {
	0%   { opacity: 0; transform: scale(0.3); }
	100% { opacity: 1; transform: scale(1); }
}

@keyframes sentio-zoom-out {
	0%   { opacity: 1; transform: scale(1); }
	100% { opacity: 0; transform: scale(1.5); }
}

/* ---- Fade ---- */
.sentio-headline--anim-fade .sentio-animated-headline__word--active {
	animation: sentio-fade-in 0.6s ease both;
}

.sentio-headline--anim-fade .sentio-animated-headline__word--out {
	animation: sentio-fade-out 0.4s ease both;
}

@keyframes sentio-fade-in {
	0%   { opacity: 0; }
	100% { opacity: 1; }
}

@keyframes sentio-fade-out {
	0%   { opacity: 1; }
	100% { opacity: 0; }
}

/* ---- Drop ---- */
.sentio-headline--anim-drop .sentio-animated-headline__word--active {
	animation: sentio-drop-in 0.5s ease both;
}

.sentio-headline--anim-drop .sentio-animated-headline__word--out {
	animation: sentio-drop-out 0.4s ease both;
}

@keyframes sentio-drop-in {
	0%   { opacity: 0; transform: translateY(-120%); }
	100% { opacity: 1; transform: translateY(0); }
}

@keyframes sentio-drop-out {
	0%   { opacity: 1; transform: translateY(0); }
	100% { opacity: 0; transform: translateY(120%); }
}

