.ksaber-app-shell {
	box-sizing: border-box;
	width: 100%;
	margin: 24px 0;
}

.ksaber-app-shell *,
.ksaber-app-shell *::before,
.ksaber-app-shell *::after {
	box-sizing: border-box;
}

.ksaber-app-content {
	width: 100%;
}

.ksaber-app-notice {
	border: 1px solid #dcdcde;
	border-radius: 12px;
	padding: 14px 16px;
	background: #f6f7f7;
	margin: 18px 0;
}

.ksaber-app-error {
	background: #1d2327;
	color: #fff;
	padding: 12px;
	border-radius: 8px;
	overflow: auto;
	white-space: pre-wrap;
}

.ksaber-app-library {
	display: grid;
	gap: 20px;
	margin: 24px 0;
}

.ksaber-app-library--cols-1 {
	grid-template-columns: 1fr;
}

.ksaber-app-library--cols-2 {
	grid-template-columns: repeat(2, minmax(0, 1fr));
}

.ksaber-app-library--cols-3 {
	grid-template-columns: repeat(3, minmax(0, 1fr));
}

.ksaber-app-library--cols-4 {
	grid-template-columns: repeat(4, minmax(0, 1fr));
}

.ksaber-app-card {
	background: #fff;
	border: 1px solid #e5e7eb;
	border-radius: 16px;
	overflow: hidden;
	box-shadow: 0 8px 22px rgba(15, 23, 42, 0.06);
}

.ksaber-app-card.is-featured {
	border-width: 2px;
}

.ksaber-app-card__image img {
	display: block;
	width: 100%;
	height: auto;
}

.ksaber-app-card__body {
	padding: 18px;
}

.ksaber-app-card__title {
	font-size: 1.1rem;
	margin: 0 0 8px;
}

.ksaber-app-card__title a {
	text-decoration: none;
}

.ksaber-app-card__meta {
	font-size: 0.86rem;
	opacity: 0.75;
	margin: 0 0 10px;
}

.ksaber-app-card__summary {
	margin: 0 0 14px;
}

.ksaber-app-card__button {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	padding: 9px 14px;
	border-radius: 999px;
	background: #111827;
	color: #fff;
	text-decoration: none;
	font-size: 0.92rem;
}

@media (max-width: 900px) {
	.ksaber-app-library--cols-3,
	.ksaber-app-library--cols-4 {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}
}

@media (max-width: 640px) {
	.ksaber-app-library--cols-2,
	.ksaber-app-library--cols-3,
	.ksaber-app-library--cols-4 {
		grid-template-columns: 1fr;
	}
}

.ksaber-fraction {
	display: inline-flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	vertical-align: middle;
	line-height: 1;
	font-variant-numeric: lining-nums;
}

.ksaber-fraction__top,
.ksaber-fraction__bottom {
	display: block;
	padding: 0 0.18em;
}

.ksaber-fraction__bar {
	display: block;
	width: 100%;
	border-top: 1px solid currentColor;
	margin: 0.12em 0;
}

.ksaber-timeline-shell {
	--ksaber-timeline-black: #0a0a0a;
	--ksaber-timeline-white: #ffffff;
	--ksaber-timeline-border: #d7d7d7;
	--ksaber-timeline-muted: #666666;
	box-sizing: border-box;
	width: 100%;
	margin: 28px 0;
	padding: 24px;
	background: var(--ksaber-timeline-white);
	border: 1px solid var(--ksaber-timeline-border);
	border-radius: 22px;
	box-shadow: 0 16px 34px rgba(0, 0, 0, 0.06);
	font-family: inherit;
}

.ksaber-timeline-shell *,
.ksaber-timeline-shell *::before,
.ksaber-timeline-shell *::after {
	box-sizing: border-box;
}

.ksaber-timeline__header {
	margin: 0 0 18px;
}

.ksaber-timeline__main-title {
	margin: 0;
	font-size: clamp(1.35rem, 3vw, 2rem);
	line-height: 1.15;
	color: var(--ksaber-timeline-black);
}

.ksaber-timeline__viewport {
	position: relative;
	width: 100%;
}

.ksaber-timeline__line {
	position: absolute;
	background: var(--ksaber-timeline-black);
	z-index: 0;
}

.ksaber-timeline__track {
	position: relative;
	z-index: 1;
}

.ksaber-timeline__point {
	appearance: none;
	-webkit-appearance: none;
	border: 0;
	background: transparent;
	color: var(--ksaber-timeline-black);
	font: inherit;
	cursor: pointer;
	text-align: center;
	padding: 0;
}

.ksaber-timeline__dot {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 22px;
	height: 22px;
	border-radius: 999px;
	background: var(--ksaber-timeline-white);
	border: 3px solid var(--ksaber-timeline-black);
	box-shadow: 0 0 0 5px var(--ksaber-timeline-white);
	transition: transform 0.18s ease, background 0.18s ease;
}

.ksaber-timeline__point:hover .ksaber-timeline__dot,
.ksaber-timeline__point:focus-visible .ksaber-timeline__dot,
.ksaber-timeline__point.is-active .ksaber-timeline__dot {
	background: var(--ksaber-timeline-black);
	transform: scale(1.12);
}

.ksaber-timeline__point:focus-visible {
	outline: 2px solid var(--ksaber-timeline-black);
	outline-offset: 6px;
	border-radius: 12px;
}

.ksaber-timeline__point-title {
	display: block;
	font-weight: 750;
	line-height: 1.2;
	font-size: 0.94rem;
	color: var(--ksaber-timeline-black);
}

.ksaber-timeline--horizontal .ksaber-timeline__viewport {
	overflow-x: auto;
	padding: 40px 6px 16px;
}

.ksaber-timeline--horizontal .ksaber-timeline__line {
	left: 20px;
	right: 20px;
	top: 52px;
	height: 3px;
}

.ksaber-timeline--horizontal .ksaber-timeline__track {
	display: grid;
	grid-auto-flow: column;
	grid-auto-columns: minmax(150px, 1fr);
	gap: 28px;
	min-width: max-content;
	align-items: start;
}

.ksaber-timeline--horizontal .ksaber-timeline__point {
	display: grid;
	justify-items: center;
	gap: 14px;
	min-width: 150px;
}

.ksaber-timeline--vertical,
.ksaber-timeline--alternada {
	padding: 28px;
}

.ksaber-timeline--vertical .ksaber-timeline__viewport,
.ksaber-timeline--alternada .ksaber-timeline__viewport {
	padding: 6px 0;
}

.ksaber-timeline--vertical .ksaber-timeline__line,
.ksaber-timeline--alternada .ksaber-timeline__line {
	top: 0;
	bottom: 0;
	left: 18px;
	width: 3px;
}

.ksaber-timeline--vertical .ksaber-timeline__track,
.ksaber-timeline--alternada .ksaber-timeline__track {
	display: flex;
	flex-direction: column;
	gap: 18px;
}

.ksaber-timeline--vertical .ksaber-timeline__point,
.ksaber-timeline--alternada .ksaber-timeline__point {
	display: grid;
	grid-template-columns: 38px minmax(0, 1fr);
	align-items: center;
	gap: 14px;
	text-align: left;
	width: 100%;
}

.ksaber-timeline--vertical .ksaber-timeline__point-title,
.ksaber-timeline--alternada .ksaber-timeline__point-title {
	padding: 14px 16px;
	border: 1px solid var(--ksaber-timeline-border);
	border-radius: 14px;
	background: var(--ksaber-timeline-white);
}

@media (min-width: 820px) {
	.ksaber-timeline--alternada .ksaber-timeline__line {
		left: 50%;
		transform: translateX(-50%);
	}

	.ksaber-timeline--alternada .ksaber-timeline__point {
		grid-template-columns: minmax(0, 1fr) 38px minmax(0, 1fr);
	}

	.ksaber-timeline--alternada .ksaber-timeline__point .ksaber-timeline__dot {
		grid-column: 2;
	}

	.ksaber-timeline--alternada .ksaber-timeline__point .ksaber-timeline__point-title {
		grid-column: 3;
	}

	.ksaber-timeline--alternada .ksaber-timeline__point:nth-child(even) .ksaber-timeline__point-title {
		grid-column: 1;
		grid-row: 1;
		text-align: right;
	}
}

.ksaber-timeline__modal {
	position: fixed;
	inset: 0;
	z-index: 99999;
	display: none;
	align-items: center;
	justify-content: center;
	padding: 18px;
}

.ksaber-timeline__modal.is-open {
	display: flex;
}

.ksaber-timeline__modal-backdrop {
	position: absolute;
	inset: 0;
	background: rgba(0, 0, 0, 0.72);
}

.ksaber-timeline__dialog {
	position: relative;
	z-index: 1;
	width: min(820px, 100%);
	max-height: min(86vh, 760px);
	overflow: auto;
	background: var(--ksaber-timeline-white);
	color: var(--ksaber-timeline-black);
	border-radius: 22px;
	box-shadow: 0 30px 80px rgba(0, 0, 0, 0.32);
}

.ksaber-timeline__close {
	position: sticky;
	top: 0;
	left: 100%;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 44px;
	height: 44px;
	margin-left: auto;
	border: 0;
	background: var(--ksaber-timeline-black);
	color: var(--ksaber-timeline-white);
	font-size: 28px;
	line-height: 1;
	cursor: pointer;
	z-index: 2;
}

.ksaber-timeline__modal-body {
	padding: 0 26px 28px;
}

.ksaber-timeline__event-image {
	margin: 0 -26px 24px;
	background: #f2f2f2;
}

.ksaber-timeline__event-image img {
	display: block;
	width: 100%;
	max-height: 440px;
	object-fit: cover;
}

.ksaber-timeline__event-title {
	margin: 0 0 12px;
	font-size: clamp(1.35rem, 3vw, 2rem);
	line-height: 1.12;
	color: var(--ksaber-timeline-black);
}

.ksaber-timeline__event-description {
	font-size: 1rem;
	line-height: 1.7;
	color: #222;
}

.ksaber-timeline__event-description p:first-child {
	margin-top: 0;
}

.ksaber-timeline__event-description p:last-child {
	margin-bottom: 0;
}

@media (max-width: 700px) {
	.ksaber-timeline-shell {
		padding: 18px;
		border-radius: 18px;
	}

	.ksaber-timeline--horizontal .ksaber-timeline__track {
		grid-auto-columns: minmax(125px, 1fr);
		gap: 20px;
	}

	.ksaber-timeline__point-title {
		font-size: 0.88rem;
	}

	.ksaber-timeline__modal-body {
		padding: 0 18px 22px;
	}

	.ksaber-timeline__event-image {
		margin: 0 -18px 20px;
	}
}


/* v1.1.1: línea de tiempo optimizada para móviles. En pantallas pequeñas,
   todos los layouts se convierten en una cronología vertical legible. */
.ksaber-timeline__track {
	counter-reset: ksaberTimelinePoint;
}

.ksaber-timeline__point {
	counter-increment: ksaberTimelinePoint;
}

@media (max-width: 700px) {
	.ksaber-timeline-shell {
		margin: 18px 0;
		padding: 14px;
		border-radius: 18px;
		box-shadow: 0 10px 26px rgba(0, 0, 0, 0.05);
		overflow: hidden;
	}

	.ksaber-timeline__header {
		margin-bottom: 14px;
	}

	.ksaber-timeline__main-title {
		font-size: clamp(1.15rem, 7vw, 1.55rem);
	}

	.ksaber-timeline--horizontal,
	.ksaber-timeline--vertical,
	.ksaber-timeline--alternada {
		padding: 14px;
	}

	.ksaber-timeline--horizontal .ksaber-timeline__viewport,
	.ksaber-timeline--vertical .ksaber-timeline__viewport,
	.ksaber-timeline--alternada .ksaber-timeline__viewport {
		overflow: visible;
		padding: 4px 0 2px;
	}

	.ksaber-timeline--horizontal .ksaber-timeline__line,
	.ksaber-timeline--vertical .ksaber-timeline__line,
	.ksaber-timeline--alternada .ksaber-timeline__line {
		top: 0;
		bottom: 0;
		left: 16px;
		right: auto;
		width: 2px;
		height: auto;
		transform: none;
		background: #111;
	}

	.ksaber-timeline--horizontal .ksaber-timeline__track,
	.ksaber-timeline--vertical .ksaber-timeline__track,
	.ksaber-timeline--alternada .ksaber-timeline__track {
		display: flex;
		flex-direction: column;
		gap: 12px;
		min-width: 0;
		width: 100%;
	}

	.ksaber-timeline--horizontal .ksaber-timeline__point,
	.ksaber-timeline--vertical .ksaber-timeline__point,
	.ksaber-timeline--alternada .ksaber-timeline__point,
	.ksaber-timeline--alternada .ksaber-timeline__point:nth-child(even) {
		display: grid;
		grid-template-columns: 34px minmax(0, 1fr);
		gap: 12px;
		align-items: start;
		justify-items: stretch;
		width: 100%;
		min-width: 0;
		padding: 0;
		text-align: left;
	}

	.ksaber-timeline--horizontal .ksaber-timeline__point .ksaber-timeline__dot,
	.ksaber-timeline--vertical .ksaber-timeline__point .ksaber-timeline__dot,
	.ksaber-timeline--alternada .ksaber-timeline__point .ksaber-timeline__dot,
	.ksaber-timeline--alternada .ksaber-timeline__point:nth-child(even) .ksaber-timeline__dot {
		grid-column: 1;
		grid-row: 1;
		align-self: start;
		justify-self: center;
		width: 28px;
		height: 28px;
		margin-top: 10px;
		background: #111;
		border: 2px solid #111;
		box-shadow: 0 0 0 4px #fff;
		color: #fff;
		font-size: 0.72rem;
		font-weight: 800;
		line-height: 1;
	}

	.ksaber-timeline__dot::after {
		content: counter(ksaberTimelinePoint);
	}

	.ksaber-timeline__point:hover .ksaber-timeline__dot,
	.ksaber-timeline__point:focus-visible .ksaber-timeline__dot,
	.ksaber-timeline__point.is-active .ksaber-timeline__dot {
		background: #fff;
		color: #111;
		transform: none;
	}

	.ksaber-timeline--horizontal .ksaber-timeline__point .ksaber-timeline__point-title,
	.ksaber-timeline--vertical .ksaber-timeline__point .ksaber-timeline__point-title,
	.ksaber-timeline--alternada .ksaber-timeline__point .ksaber-timeline__point-title,
	.ksaber-timeline--alternada .ksaber-timeline__point:nth-child(even) .ksaber-timeline__point-title {
		grid-column: 2;
		grid-row: 1;
		display: block;
		width: 100%;
		min-width: 0;
		padding: 12px 13px;
		border: 1px solid #d7d7d7;
		border-radius: 14px;
		background: #fff;
		box-shadow: 0 6px 18px rgba(0, 0, 0, 0.045);
		font-size: 0.94rem;
		line-height: 1.28;
		font-weight: 750;
		text-align: left;
		white-space: normal;
		overflow-wrap: anywhere;
	}

	.ksaber-timeline__point:focus-visible {
		outline-offset: 3px;
	}

	.ksaber-timeline__modal {
		align-items: flex-end;
		justify-content: center;
		padding: 10px;
	}

	.ksaber-timeline__dialog {
		width: 100%;
		max-height: min(92svh, 92vh);
		border-radius: 20px 20px 0 0;
		overflow: auto;
	}

	.ksaber-timeline__close {
		width: 48px;
		height: 48px;
		font-size: 30px;
	}

	.ksaber-timeline__modal-body {
		padding: 0 16px 22px;
	}

	.ksaber-timeline__event-image {
		margin: 0 -16px 18px;
	}

	.ksaber-timeline__event-image img {
		max-height: 42vh;
		object-fit: cover;
	}

	.ksaber-timeline__event-title {
		font-size: clamp(1.25rem, 6vw, 1.65rem);
	}

	.ksaber-timeline__event-description {
		font-size: 0.96rem;
		line-height: 1.65;
	}
}

@media (max-width: 380px) {
	.ksaber-timeline-shell,
	.ksaber-timeline--horizontal,
	.ksaber-timeline--vertical,
	.ksaber-timeline--alternada {
		padding: 12px;
	}

	.ksaber-timeline--horizontal .ksaber-timeline__point,
	.ksaber-timeline--vertical .ksaber-timeline__point,
	.ksaber-timeline--alternada .ksaber-timeline__point {
		grid-template-columns: 30px minmax(0, 1fr);
		gap: 10px;
	}

	.ksaber-timeline--horizontal .ksaber-timeline__line,
	.ksaber-timeline--vertical .ksaber-timeline__line,
	.ksaber-timeline--alternada .ksaber-timeline__line {
		left: 14px;
	}

	.ksaber-timeline--horizontal .ksaber-timeline__point .ksaber-timeline__dot,
	.ksaber-timeline--vertical .ksaber-timeline__point .ksaber-timeline__dot,
	.ksaber-timeline--alternada .ksaber-timeline__point .ksaber-timeline__dot {
		width: 26px;
		height: 26px;
		font-size: 0.68rem;
	}
}

/* v1.1.2: acciones públicas de líneas de tiempo y modal centrado robusto. */
.ksaber-timeline__actions {
	display: flex;
	justify-content: flex-end;
	gap: 10px;
	margin: 0 0 18px;
}

.ksaber-timeline__pdf-button {
	appearance: none;
	-webkit-appearance: none;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	min-height: 42px;
	padding: 10px 16px;
	border: 1px solid #111;
	border-radius: 999px;
	background: #111;
	color: #fff;
	font: inherit;
	font-weight: 750;
	line-height: 1.1;
	text-decoration: none;
	cursor: pointer;
	transition: transform 0.18s ease, background 0.18s ease, color 0.18s ease;
}

.ksaber-timeline__pdf-button:hover,
.ksaber-timeline__pdf-button:focus-visible {
	background: #fff;
	color: #111;
	transform: translateY(-1px);
}

.ksaber-timeline__pdf-button:focus-visible {
	outline: 2px solid #111;
	outline-offset: 3px;
}

.ksaber-timeline__modal {
	position: fixed !important;
	top: 0 !important;
	right: 0 !important;
	bottom: 0 !important;
	left: 0 !important;
	width: 100vw !important;
	height: 100vh !important;
	height: 100dvh !important;
	min-height: 100vh !important;
	margin: 0 !important;
	padding: clamp(14px, 3vw, 28px) !important;
	display: none !important;
	align-items: center !important;
	justify-content: center !important;
	transform: none !important;
	z-index: 2147483000 !important;
}

.ksaber-timeline__modal.is-open {
	display: flex !important;
}

.ksaber-timeline__dialog {
	margin: auto !important;
	max-height: calc(100dvh - 32px) !important;
}

html.ksaber-timeline-modal-open,
html.ksaber-timeline-modal-open body {
	overflow: hidden;
}

@media (max-width: 700px) {
	.ksaber-timeline__actions {
		justify-content: stretch;
		margin-bottom: 14px;
	}

	.ksaber-timeline__pdf-button {
		width: 100%;
		min-height: 44px;
		padding: 11px 14px;
	}

	.ksaber-timeline__modal {
		padding: 14px !important;
		align-items: center !important;
	}

	.ksaber-timeline__dialog {
		width: min(100%, 560px) !important;
		max-height: calc(100dvh - 28px) !important;
		border-radius: 18px;
	}
}

/* v1.1.3: microinteracciones premium para líneas de tiempo. */
.ksaber-timeline-shell {
	--ksaber-timeline-ease: cubic-bezier(0.2, 0.82, 0.24, 1);
	--ksaber-timeline-bounce: cubic-bezier(0.2, 1.35, 0.34, 1);
}

.ksaber-timeline__viewport {
	scroll-behavior: smooth;
	-webkit-overflow-scrolling: touch;
	scrollbar-width: thin;
	scrollbar-color: #111 transparent;
}

.ksaber-timeline__viewport::-webkit-scrollbar {
	height: 8px;
}

.ksaber-timeline__viewport::-webkit-scrollbar-track {
	background: transparent;
}

.ksaber-timeline__viewport::-webkit-scrollbar-thumb {
	background: #111;
	border-radius: 999px;
}

.ksaber-timeline--horizontal .ksaber-timeline__point {
	scroll-snap-align: center;
}

.ksaber-timeline--horizontal .ksaber-timeline__viewport {
	scroll-snap-type: x proximity;
}

.ksaber-timeline-shell.is-animated .ksaber-timeline__line {
	transform-origin: left center;
	animation: ksaberTimelineLineDraw 0.95s var(--ksaber-timeline-ease) both;
}

.ksaber-timeline-shell.is-animated.ksaber-timeline--vertical .ksaber-timeline__line,
.ksaber-timeline-shell.is-animated.ksaber-timeline--alternada .ksaber-timeline__line {
	transform-origin: top center;
	animation-name: ksaberTimelineLineDrawY;
}

.ksaber-timeline-shell.is-animated .ksaber-timeline__point {
	opacity: 0;
	transform: translate3d(0, 18px, 0) scale(0.98);
	transition:
		opacity 0.55s var(--ksaber-timeline-ease),
		transform 0.65s var(--ksaber-timeline-bounce),
		filter 0.3s ease;
	transition-delay: calc(min(var(--ksaber-timeline-index), 8) * 0.045s);
	will-change: transform, opacity;
}

.ksaber-timeline-shell.is-animated .ksaber-timeline__point.is-even {
	transform: translate3d(24px, 18px, 0) scale(0.98);
}

.ksaber-timeline-shell.is-animated .ksaber-timeline__point.is-odd {
	transform: translate3d(-24px, 18px, 0) scale(0.98);
}

.ksaber-timeline-shell.is-animated .ksaber-timeline__point.is-visible {
	opacity: 1;
	transform: translate3d(0, 0, 0) scale(1);
}

.ksaber-timeline__point-title {
	transition:
		transform 0.22s var(--ksaber-timeline-ease),
		box-shadow 0.22s ease,
		border-color 0.22s ease,
		background 0.22s ease;
}

.ksaber-timeline__point:hover .ksaber-timeline__point-title,
.ksaber-timeline__point:focus-visible .ksaber-timeline__point-title {
	transform: translateY(-3px);
	box-shadow: 0 12px 24px rgba(0, 0, 0, 0.09);
	border-color: #111;
}

.ksaber-timeline__point.is-visited .ksaber-timeline__point-title {
	border-color: #111;
}

.ksaber-timeline__dot {
	position: relative;
}

.ksaber-timeline__dot::before {
	content: "";
	position: absolute;
	inset: -9px;
	border: 1px solid currentColor;
	border-radius: inherit;
	opacity: 0;
	transform: scale(0.62);
	pointer-events: none;
}

.ksaber-timeline__point:hover .ksaber-timeline__dot::before,
.ksaber-timeline__point:focus-visible .ksaber-timeline__dot::before,
.ksaber-timeline__point.is-active .ksaber-timeline__dot::before {
	animation: ksaberTimelineDotPulse 0.82s ease-out both;
}

.ksaber-timeline__viewport.is-scrolling .ksaber-timeline__point-title {
	transform: translateY(-1px);
}

.ksaber-timeline__modal.is-open .ksaber-timeline__modal-backdrop {
	animation: ksaberTimelineFadeIn 0.24s ease both;
}

.ksaber-timeline__modal.is-open .ksaber-timeline__dialog {
	animation: ksaberTimelineModalBounce 0.52s var(--ksaber-timeline-bounce) both;
	transform-origin: center center;
}

.ksaber-timeline__modal.is-open .ksaber-timeline__modal-body > * {
	animation: ksaberTimelineContentRise 0.48s var(--ksaber-timeline-ease) both;
}

.ksaber-timeline__pdf-button {
	position: relative;
	overflow: hidden;
}

.ksaber-timeline__pdf-button::after {
	content: "";
	position: absolute;
	top: 0;
	bottom: 0;
	left: -45%;
	width: 34%;
	background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.34), transparent);
	transform: skewX(-18deg);
	transition: left 0.55s ease;
	pointer-events: none;
}

.ksaber-timeline__pdf-button:hover::after,
.ksaber-timeline__pdf-button:focus-visible::after {
	left: 115%;
}

@keyframes ksaberTimelineLineDraw {
	from {
		transform: scaleX(0);
		opacity: 0.25;
	}
	to {
		transform: scaleX(1);
		opacity: 1;
	}
}

@keyframes ksaberTimelineLineDrawY {
	from {
		transform: scaleY(0);
		opacity: 0.25;
	}
	to {
		transform: scaleY(1);
		opacity: 1;
	}
}

@keyframes ksaberTimelineDotPulse {
	0% {
		opacity: 0.55;
		transform: scale(0.62);
	}
	100% {
		opacity: 0;
		transform: scale(1.65);
	}
}

@keyframes ksaberTimelineFadeIn {
	from { opacity: 0; }
	to { opacity: 1; }
}

@keyframes ksaberTimelineModalBounce {
	0% {
		opacity: 0;
		transform: translate3d(0, 18px, 0) scale(0.9);
	}
	58% {
		opacity: 1;
		transform: translate3d(0, -6px, 0) scale(1.025);
	}
	78% {
		transform: translate3d(0, 2px, 0) scale(0.995);
	}
	100% {
		opacity: 1;
		transform: translate3d(0, 0, 0) scale(1);
	}
}

@keyframes ksaberTimelineContentRise {
	from {
		opacity: 0;
		transform: translateY(10px);
	}
	to {
		opacity: 1;
		transform: translateY(0);
	}
}

@media (max-width: 700px) {
	.ksaber-timeline-shell.is-animated .ksaber-timeline__point.is-even,
	.ksaber-timeline-shell.is-animated .ksaber-timeline__point.is-odd {
		transform: translate3d(18px, 10px, 0) scale(0.985);
	}

	.ksaber-timeline-shell.is-animated .ksaber-timeline__point.is-visible {
		transform: translate3d(0, 0, 0) scale(1);
	}

	.ksaber-timeline__point:hover .ksaber-timeline__point-title,
	.ksaber-timeline__point:focus-visible .ksaber-timeline__point-title,
	.ksaber-timeline__viewport.is-scrolling .ksaber-timeline__point-title {
		transform: none;
	}

	.ksaber-timeline__modal.is-open .ksaber-timeline__dialog {
		animation-name: ksaberTimelineModalBounceMobile;
	}
}

@keyframes ksaberTimelineModalBounceMobile {
	0% {
		opacity: 0;
		transform: translate3d(0, 18px, 0) scale(0.94);
	}
	64% {
		opacity: 1;
		transform: translate3d(0, -4px, 0) scale(1.012);
	}
	100% {
		opacity: 1;
		transform: translate3d(0, 0, 0) scale(1);
	}
}

@media (prefers-reduced-motion: reduce) {
	.ksaber-timeline-shell.is-animated .ksaber-timeline__line,
	.ksaber-timeline-shell.is-animated .ksaber-timeline__point,
	.ksaber-timeline__modal.is-open .ksaber-timeline__modal-backdrop,
	.ksaber-timeline__modal.is-open .ksaber-timeline__dialog,
	.ksaber-timeline__modal.is-open .ksaber-timeline__modal-body > *,
	.ksaber-timeline__point:hover .ksaber-timeline__dot::before,
	.ksaber-timeline__point:focus-visible .ksaber-timeline__dot::before,
	.ksaber-timeline__point.is-active .ksaber-timeline__dot::before {
		animation: none !important;
		transition: none !important;
		transform: none !important;
		opacity: 1 !important;
	}

	.ksaber-timeline__viewport {
		scroll-behavior: auto;
	}
}

/* v1.1.4: carrusel de escritorio para líneas de tiempo horizontales y PDF sin popup bloqueado. */
.ksaber-timeline__carousel {
	position: relative;
	width: 100%;
}

.ksaber-timeline__nav {
	display: none;
}

.ksaber-timeline__carousel-status {
	margin: 10px 0 0;
	color: #666;
	font-size: 0.82rem;
	font-weight: 650;
	text-align: center;
}

@media (min-width: 701px) {
	.ksaber-timeline--horizontal {
		--ksaber-timeline-carousel-gap: 16px;
	}

	.ksaber-timeline--horizontal.is-carousel-ready .ksaber-timeline__carousel {
		display: grid;
		grid-template-columns: 46px minmax(0, 1fr) 46px;
		align-items: center;
		gap: 12px;
	}

	.ksaber-timeline--horizontal.is-carousel-ready .ksaber-timeline__viewport {
		overflow: hidden;
		padding: 38px 2px 18px;
		scroll-snap-type: none;
		scrollbar-width: none;
	}

	.ksaber-timeline--horizontal.is-carousel-ready .ksaber-timeline__viewport::-webkit-scrollbar {
		display: none;
	}

	.ksaber-timeline--horizontal.is-carousel-ready .ksaber-timeline__line {
		left: 8px;
		right: 8px;
		top: 50px;
	}

	.ksaber-timeline--horizontal.is-carousel-ready .ksaber-timeline__track {
		display: flex;
		grid-auto-flow: initial;
		grid-auto-columns: initial;
		gap: var(--ksaber-timeline-carousel-gap);
		min-width: 0;
		width: 100%;
		align-items: flex-start;
		transition: transform 0.42s cubic-bezier(0.2, 0.82, 0.24, 1);
		will-change: transform;
	}

	.ksaber-timeline--horizontal.is-carousel-ready .ksaber-timeline__point {
		flex: 0 0 calc((100% - ((var(--ksaber-timeline-items-per-view, 5) - 1) * var(--ksaber-timeline-carousel-gap))) / var(--ksaber-timeline-items-per-view, 5));
		min-width: 0;
		max-width: none;
		display: grid;
		justify-items: center;
		gap: 12px;
		padding: 0 2px;
	}

	.ksaber-timeline--horizontal.is-carousel-ready .ksaber-timeline__point-title {
		width: 100%;
		min-height: 58px;
		display: flex;
		align-items: center;
		justify-content: center;
		padding: 8px 8px;
		border: 1px solid #d7d7d7;
		border-radius: 13px;
		background: #fff;
		box-shadow: 0 8px 20px rgba(0, 0, 0, 0.045);
		font-size: clamp(0.72rem, 0.78vw, 0.84rem);
		line-height: 1.16;
		font-weight: 800;
		letter-spacing: -0.01em;
		text-align: center;
		overflow-wrap: anywhere;
	}

	.ksaber-timeline--horizontal.is-carousel-ready .ksaber-timeline__point:not(.is-in-carousel-window) {
		pointer-events: none;
	}

	.ksaber-timeline--horizontal.is-carousel-ready .ksaber-timeline__nav {
		appearance: none;
		-webkit-appearance: none;
		display: inline-flex;
		align-items: center;
		justify-content: center;
		width: 46px;
		height: 46px;
		border: 1px solid #111;
		border-radius: 999px;
		background: #fff;
		color: #111;
		font: inherit;
		font-size: 30px;
		font-weight: 800;
		line-height: 1;
		cursor: pointer;
		box-shadow: 0 10px 26px rgba(0, 0, 0, 0.08);
		transition: transform 0.2s ease, background 0.2s ease, color 0.2s ease, opacity 0.2s ease;
	}

	.ksaber-timeline--horizontal.is-carousel-ready .ksaber-timeline__nav:hover,
	.ksaber-timeline--horizontal.is-carousel-ready .ksaber-timeline__nav:focus-visible {
		background: #111;
		color: #fff;
		transform: translateY(-2px) scale(1.03);
	}

	.ksaber-timeline--horizontal.is-carousel-ready .ksaber-timeline__nav:focus-visible {
		outline: 2px solid #111;
		outline-offset: 3px;
	}

	.ksaber-timeline--horizontal.is-carousel-ready .ksaber-timeline__nav:disabled {
		opacity: 0.25;
		cursor: not-allowed;
		transform: none;
		background: #fff;
		color: #111;
	}

	.ksaber-timeline--horizontal.is-carousel-sliding .ksaber-timeline__point.is-in-carousel-window .ksaber-timeline__point-title {
		animation: ksaberTimelineCarouselCardPop 0.42s cubic-bezier(0.2, 1.18, 0.34, 1) both;
	}

	.ksaber-timeline--horizontal.is-carousel-sliding .ksaber-timeline__dot {
		animation: ksaberTimelineCarouselDotPop 0.42s cubic-bezier(0.2, 1.18, 0.34, 1) both;
	}
}

@media (min-width: 701px) and (max-width: 900px) {
	.ksaber-timeline--horizontal.is-carousel-ready .ksaber-timeline__carousel {
		grid-template-columns: 42px minmax(0, 1fr) 42px;
		gap: 8px;
	}

	.ksaber-timeline--horizontal.is-carousel-ready .ksaber-timeline__nav {
		width: 42px;
		height: 42px;
		font-size: 27px;
	}
}

@media (max-width: 700px) {
	.ksaber-timeline__carousel {
		display: block;
	}

	.ksaber-timeline__nav,
	.ksaber-timeline__carousel-status {
		display: none !important;
	}
}

@keyframes ksaberTimelineCarouselCardPop {
	0% {
		opacity: 0.45;
		transform: translateY(8px) scale(0.97);
	}
	62% {
		opacity: 1;
		transform: translateY(-3px) scale(1.025);
	}
	100% {
		opacity: 1;
		transform: translateY(0) scale(1);
	}
}

@keyframes ksaberTimelineCarouselDotPop {
	0% {
		transform: scale(0.82);
	}
	62% {
		transform: scale(1.16);
	}
	100% {
		transform: scale(1);
	}
}

@media (prefers-reduced-motion: reduce) {
	.ksaber-timeline--horizontal.is-carousel-ready .ksaber-timeline__track,
	.ksaber-timeline--horizontal.is-carousel-sliding .ksaber-timeline__point.is-in-carousel-window .ksaber-timeline__point-title,
	.ksaber-timeline--horizontal.is-carousel-sliding .ksaber-timeline__dot {
		animation: none !important;
		transition: none !important;
	}
}

/* v1.2.0: modo presentación de líneas de tiempo. */
.ksaber-timeline__presentation-button {
	appearance: none;
	-webkit-appearance: none;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-height: 42px;
	padding: 10px 16px;
	border: 1px solid #111;
	border-radius: 999px;
	background: #fff;
	color: #111;
	font: inherit;
	font-weight: 750;
	line-height: 1.1;
	cursor: pointer;
	transition: transform 0.18s ease, background 0.18s ease, color 0.18s ease;
}

.ksaber-timeline__presentation-button:hover,
.ksaber-timeline__presentation-button:focus-visible {
	background: #111;
	color: #fff;
	transform: translateY(-1px);
}

.ksaber-timeline__presentation {
	position: fixed !important;
	inset: 0 !important;
	z-index: 2147483100 !important;
	display: none !important;
	align-items: center;
	justify-content: center;
	padding: clamp(14px, 3vw, 30px);
}

.ksaber-timeline__presentation.is-open {
	display: flex !important;
}

.ksaber-timeline__presentation-backdrop {
	position: absolute;
	inset: 0;
	background:
		radial-gradient(circle at 18% 12%, rgba(255,255,255,0.12), transparent 30%),
		rgba(0, 0, 0, 0.82);
	animation: ksaberTimelineFadeIn 0.24s ease both;
}

.ksaber-timeline__presentation-dialog {
	position: relative;
	z-index: 1;
	width: min(1060px, 100%);
	max-height: calc(100dvh - 36px);
	display: grid;
	grid-template-rows: auto auto minmax(0, 1fr) auto;
	background: #fff;
	color: #111;
	border: 1px solid rgba(255,255,255,0.35);
	border-radius: 24px;
	box-shadow: 0 30px 90px rgba(0,0,0,0.42);
	overflow: hidden;
	animation: ksaberTimelineModalBounce 0.5s cubic-bezier(0.2, 1.35, 0.34, 1) both;
}

.ksaber-timeline__presentation-header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 16px;
	padding: 18px 20px;
	border-bottom: 1px solid #e5e5e5;
}

.ksaber-timeline__presentation-kicker {
	margin: 0 0 5px;
	font-size: 0.72rem;
	font-weight: 850;
	letter-spacing: 0.12em;
	text-transform: uppercase;
	color: #666;
}

.ksaber-timeline__presentation-title {
	margin: 0;
	font-size: clamp(1.05rem, 2.4vw, 1.55rem);
	line-height: 1.15;
}

.ksaber-timeline__presentation-close {
	appearance: none;
	-webkit-appearance: none;
	width: 44px;
	height: 44px;
	border: 0;
	border-radius: 999px;
	background: #111;
	color: #fff;
	font-size: 28px;
	line-height: 1;
	cursor: pointer;
}

.ksaber-timeline__presentation-progress {
	height: 5px;
	background: #ededed;
	overflow: hidden;
}

.ksaber-timeline__presentation-progress span {
	display: block;
	height: 100%;
	width: 0;
	background: #111;
	transition: width 0.35s ease;
}

.ksaber-timeline__presentation-body {
	position: relative;
	overflow: auto;
	padding: clamp(20px, 3.5vw, 42px);
}

.ksaber-timeline__presentation-body.is-entering {
	animation: ksaberTimelinePresentationSlide 0.36s cubic-bezier(0.2, 0.82, 0.24, 1) both;
}

.ksaber-timeline__presentation-number {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 44px;
	height: 44px;
	border-radius: 999px;
	background: #111;
	color: #fff;
	font-weight: 900;
	margin-bottom: 16px;
}

.ksaber-timeline__presentation-body .ksaber-timeline__event-image {
	margin: 0 0 22px;
	border-radius: 18px;
	overflow: hidden;
}

.ksaber-timeline__presentation-body .ksaber-timeline__event-image img {
	max-height: 46vh;
	object-fit: cover;
}

.ksaber-timeline__presentation-body .ksaber-timeline__event-title {
	font-size: clamp(1.65rem, 4vw, 3rem);
	max-width: 920px;
}

.ksaber-timeline__presentation-body .ksaber-timeline__event-description {
	font-size: clamp(1rem, 1.5vw, 1.17rem);
	max-width: 880px;
}

.ksaber-timeline__presentation-controls {
	display: grid;
	grid-template-columns: 1fr auto 1fr;
	align-items: center;
	gap: 14px;
	padding: 16px 20px;
	border-top: 1px solid #e5e5e5;
	background: #fafafa;
}

.ksaber-timeline__presentation-controls button {
	appearance: none;
	-webkit-appearance: none;
	min-height: 44px;
	padding: 10px 18px;
	border: 1px solid #111;
	border-radius: 999px;
	background: #111;
	color: #fff;
	font: inherit;
	font-weight: 800;
	cursor: pointer;
}

.ksaber-timeline__presentation-controls button:first-child {
	justify-self: start;
}

.ksaber-timeline__presentation-controls button:last-child {
	justify-self: end;
}

.ksaber-timeline__presentation-controls button:disabled {
	opacity: 0.3;
	cursor: not-allowed;
}

.ksaber-timeline__presentation-controls span {
	font-size: 0.86rem;
	font-weight: 750;
	color: #555;
	text-align: center;
}

html.ksaber-timeline-presentation-open,
html.ksaber-timeline-presentation-open body {
	overflow: hidden;
}

@keyframes ksaberTimelinePresentationSlide {
	from { opacity: 0; transform: translateX(18px) scale(0.985); }
	to { opacity: 1; transform: translateX(0) scale(1); }
}

@media (max-width: 700px) {
	.ksaber-timeline__presentation-button,
	.ksaber-timeline__pdf-button {
		width: 100%;
	}

	.ksaber-timeline__actions {
		flex-direction: column;
	}

	.ksaber-timeline__presentation {
		padding: 10px !important;
	}

	.ksaber-timeline__presentation-dialog {
		max-height: calc(100dvh - 20px);
		border-radius: 20px;
	}

	.ksaber-timeline__presentation-header,
	.ksaber-timeline__presentation-controls {
		padding: 13px;
	}

	.ksaber-timeline__presentation-controls {
		grid-template-columns: 1fr 1fr;
	}

	.ksaber-timeline__presentation-controls span {
		grid-column: 1 / -1;
		grid-row: 1;
	}

	.ksaber-timeline__presentation-controls button:first-child,
	.ksaber-timeline__presentation-controls button:last-child {
		justify-self: stretch;
	}
}

/* v1.2.0: pizarra interactiva Ksaber. */
.ksaber-whiteboard-launcher {
	margin: 24px 0;
}

.ksaber-whiteboard-launcher__button {
	appearance: none;
	-webkit-appearance: none;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-height: 46px;
	padding: 12px 20px;
	border: 1px solid #111;
	border-radius: 999px;
	background: #111;
	color: #fff;
	font: inherit;
	font-weight: 800;
	cursor: pointer;
	box-shadow: 0 12px 28px rgba(0,0,0,0.12);
	transition: transform 0.18s ease, background 0.18s ease, color 0.18s ease;
}

.ksaber-whiteboard-launcher__button:hover,
.ksaber-whiteboard-launcher__button:focus-visible {
	background: #fff;
	color: #111;
	transform: translateY(-1px);
}

.ksaber-whiteboard {
	position: fixed !important;
	inset: 0 !important;
	z-index: 2147483200 !important;
	display: none !important;
	grid-template-rows: auto auto minmax(0, 1fr);
	background: #fff;
	color: #111;
	font-family: inherit;
}

.ksaber-whiteboard.is-open {
	display: grid !important;
}

html.ksaber-whiteboard-open,
html.ksaber-whiteboard-open body {
	overflow: hidden;
}

.ksaber-whiteboard *,
.ksaber-whiteboard *::before,
.ksaber-whiteboard *::after {
	box-sizing: border-box;
}

.ksaber-whiteboard__topbar {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 14px;
	padding: 12px 16px;
	border-bottom: 1px solid #e5e5e5;
	background: #fff;
}

.ksaber-whiteboard__brand {
	display: flex;
	align-items: center;
	gap: 12px;
	min-width: 0;
}

.ksaber-whiteboard__logo {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 38px;
	height: 38px;
	border-radius: 12px;
	background: #111;
	color: #fff;
	font-weight: 900;
}

.ksaber-whiteboard__brand p {
	margin: 0 0 2px;
	font-size: 0.72rem;
	font-weight: 850;
	letter-spacing: 0.12em;
	text-transform: uppercase;
	color: #666;
}

.ksaber-whiteboard__brand h2 {
	margin: 0;
	font-size: clamp(1rem, 2vw, 1.3rem);
	line-height: 1.1;
}

.ksaber-whiteboard__status {
	font-size: 0.82rem;
	font-weight: 700;
	color: #555;
	text-align: center;
}

.ksaber-whiteboard__close {
	appearance: none;
	-webkit-appearance: none;
	width: 42px;
	height: 42px;
	border: 0;
	border-radius: 999px;
	background: #111;
	color: #fff;
	font-size: 28px;
	line-height: 1;
	cursor: pointer;
}

.ksaber-whiteboard__toolbar {
	display: flex;
	align-items: center;
	gap: 10px;
	padding: 10px 12px;
	border-bottom: 1px solid #e7e7e7;
	background: #fafafa;
	overflow-x: auto;
	-webkit-overflow-scrolling: touch;
}

.ksaber-whiteboard__toolgroup {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding-right: 10px;
	border-right: 1px solid #ddd;
	white-space: nowrap;
}

.ksaber-whiteboard__toolgroup:last-child {
	border-right: 0;
}

.ksaber-whiteboard__toolgroup button {
	appearance: none;
	-webkit-appearance: none;
	min-height: 36px;
	padding: 8px 11px;
	border: 1px solid #111;
	border-radius: 999px;
	background: #fff;
	color: #111;
	font: inherit;
	font-size: 0.84rem;
	font-weight: 750;
	cursor: pointer;
}

.ksaber-whiteboard__toolgroup button:hover,
.ksaber-whiteboard__toolgroup button:focus-visible,
.ksaber-whiteboard__toolgroup button.is-active {
	background: #111;
	color: #fff;
}

.ksaber-whiteboard__controls label {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	font-size: 0.78rem;
	font-weight: 750;
	color: #333;
}

.ksaber-whiteboard__controls input[type="color"] {
	width: 34px;
	height: 34px;
	padding: 0;
	border: 1px solid #bbb;
	border-radius: 999px;
	background: #fff;
}

.ksaber-whiteboard__controls input[type="range"] {
	width: 110px;
}

.ksaber-whiteboard__check {
	padding: 0 4px;
}

.ksaber-whiteboard__workspace {
	position: relative;
	min-height: 0;
	background: #fff;
	overflow: hidden;
}

.ksaber-whiteboard__hint {
	position: absolute;
	left: 14px;
	bottom: 14px;
	z-index: 2;
	max-width: min(460px, calc(100% - 28px));
	padding: 8px 12px;
	border: 1px solid #e5e5e5;
	border-radius: 999px;
	background: rgba(255,255,255,0.92);
	box-shadow: 0 10px 22px rgba(0,0,0,0.06);
	font-size: 0.78rem;
	font-weight: 700;
	color: #555;
	pointer-events: none;
}

.ksaber-whiteboard__canvas {
	display: block;
	width: 100%;
	height: 100%;
	touch-action: none;
	cursor: crosshair;
}

@media (max-width: 760px) {
	.ksaber-whiteboard {
		grid-template-rows: auto auto minmax(0, 1fr);
	}

	.ksaber-whiteboard__topbar {
		padding: 10px;
	}

	.ksaber-whiteboard__status {
		display: none;
	}

	.ksaber-whiteboard__toolbar {
		align-items: flex-start;
		padding: 8px;
		gap: 8px;
	}

	.ksaber-whiteboard__toolgroup button {
		min-height: 34px;
		padding: 7px 9px;
		font-size: 0.78rem;
	}

	.ksaber-whiteboard__hint {
		left: 10px;
		right: 10px;
		bottom: 10px;
		border-radius: 14px;
		font-size: 0.72rem;
	}
}

/* Puente global: resolver ejercicios en la pizarra */
.ksaber-pizarra-resolver-open {
	overflow: hidden !important;
}

.ksaber-pizarra-resolver {
	position: fixed;
	inset: 0;
	z-index: 999999;
	display: none;
	background: rgba(0, 0, 0, 0.72);
}

.ksaber-pizarra-resolver.is-open {
	display: block;
}

.ksaber-pizarra-resolver__backdrop {
	position: absolute;
	inset: 0;
}

.ksaber-pizarra-resolver__panel {
	position: absolute;
	inset: 18px;
	display: flex;
	flex-direction: column;
	background: #ffffff;
	border: 1px solid #111111;
	border-radius: 20px;
	overflow: hidden;
	box-shadow: 0 26px 80px rgba(0, 0, 0, 0.28);
}

.ksaber-pizarra-resolver__topbar {
	min-height: 58px;
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 14px;
	padding: 10px 14px;
	background: #ffffff;
	border-bottom: 1px solid #111111;
	color: #111111;
}

.ksaber-pizarra-resolver__topbar strong,
.ksaber-pizarra-resolver__topbar span {
	display: block;
	line-height: 1.15;
}

.ksaber-pizarra-resolver__topbar strong {
	font-size: 15px;
	font-weight: 800;
}

.ksaber-pizarra-resolver__topbar span {
	font-size: 12px;
	color: #555555;
	margin-top: 3px;
}

.ksaber-pizarra-resolver__close {
	appearance: none;
	-webkit-appearance: none;
	width: 38px;
	height: 38px;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	border: 1px solid #111111;
	border-radius: 999px;
	background: #111111;
	color: #ffffff;
	font-size: 24px;
	font-weight: 400;
	line-height: 1;
	cursor: pointer;
}

.ksaber-pizarra-resolver__frame {
	border: 0;
	width: 100%;
	min-width: 0;
	flex: 1 1 auto;
	background: #ffffff;
}

.ksaber-resolver-pizarra-btn,
[data-ksaber-resolver-pizarra] {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	border: 1px solid #111111;
	border-radius: 999px;
	background: #111111;
	color: #ffffff;
	padding: 10px 15px;
	font: inherit;
	font-weight: 750;
	text-decoration: none;
	cursor: pointer;
	transition: transform 0.18s ease, box-shadow 0.18s ease;
}

.ksaber-resolver-pizarra-btn:hover,
[data-ksaber-resolver-pizarra]:hover {
	transform: translateY(-1px);
	box-shadow: 0 10px 22px rgba(0, 0, 0, 0.14);
}

@media (max-width: 760px) {
	.ksaber-pizarra-resolver__panel {
		inset: 0;
		border: 0;
		border-radius: 0;
	}
}
