* {
	box-sizing: border-box;
}

html,
body {
	margin: 0;
	min-height: 100%;
	font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
	background-color: #101820;
}

body {
	display: flex;
	justify-content: center;
	align-items: center;
	min-height: 100vh;
	padding: 0;
}

/* Pantalla de transición */
.transition-overlay {
	position: fixed;
	top: 0;
	left: 0;
	width: 100vw;
	height: 100vh;
	background: #f5f5f5;
	z-index: 9999;
	display: flex;
	align-items: center;
	justify-content: center;
	opacity: 0;
	pointer-events: none;
	transition: opacity 0.125s ease-in-out;
}

.transition-overlay.is-active {
	opacity: 1;
	pointer-events: all;
}

.transition-overlay__mascot {
	width: 90%;
	max-width: 600px;
	height: auto;
	animation: mascot-pulse 0.25s ease-in-out;
}

@keyframes mascot-pulse {
	0% {
		transform: scale(0.95);
		opacity: 0.8;
	}
	50% {
		transform: scale(1);
		opacity: 1;
	}
	100% {
		transform: scale(0.95);
		opacity: 0.8;
	}
}



/* Vista simple del estudiante */
.student-view {
	position: fixed;
	top: 0;
	left: 0;
	width: 100vw;
	height: 100vh;
	background: #101820 url("recursos/f-espera.png") center / contain no-repeat;
	color: #ffffff;
	z-index: 900;
	display: flex;
	flex-direction: column;
}

.student-view:not([hidden]) {
	display: flex;
	align-items: center;
	justify-content: center;
}

.student-view__back-container {
	position: absolute;
	bottom: 20px;
	left: 0;
	right: 0;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: clamp(16px, 4%, 32px);
	z-index: 2;
}

.student-view__back {
	border: none;
	background: transparent;
	padding: 0;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
}

.student-view__back img {
	width: clamp(32px, 10%, 56px);
	height: auto;
}

/* Overlay muy sencillo para elegir rol; se mantiene neutral para no interferir con el diseño existente */
.role-overlay {
	position: fixed;
	top: 0;
	left: 0;
	width: 100vw;
	height: 100vh;
	background: rgba(0, 0, 0, 0.6);
	z-index: 1000;
}

.role-overlay:not([hidden]) {
	display: flex;
	align-items: center;
	justify-content: center;
}

.role-overlay__content {
	background: #ffffff;
	border-radius: 16px;
	padding: 24px 20px;
	max-width: 320px;
	width: 90%;
	text-align: center;
}

.role-overlay__title {
	margin: 0 0 16px;
	font-size: 20px;
	color: #222222;
}

.role-overlay__buttons {
	display: flex;
	gap: 12px;
	justify-content: center;
}

.role-overlay__btn {
	flex: 1 1 0;
	padding: 10px 12px;
	border-radius: 999px;
	border: none;
	background: #ffcc00;
	color: #222222;
	font-weight: 600;
	cursor: pointer;
}

.role-overlay__btn:hover {
	background: #ffd633;
}

/* Overlay para mostrar el recordatorio en la vista del estudiante */
.reminder-overlay {
	position: fixed;
	top: 0;
	left: 0;
	width: 100vw;
	height: 100vh;
	background-color: transparent;
	z-index: 2000;
	display: flex;
	align-items: center;
	justify-content: center;
	overflow: hidden;
}

.reminder-overlay:not([hidden]) {
	display: flex;
}

.reminder-overlay img[data-reminder-image] {
	width: 100%;
	height: 100%;
	object-fit: contain;
	display: none; /* solo se muestra cuando hay imagen válida */
}

/* Modal para que el profesor elija el tiempo del recordatorio */
.time-modal {
	position: fixed;
	top: 0;
	left: 0;
	width: 100vw;
	height: 100vh;
	background: rgba(0, 0, 0, 0.6);
	z-index: 1002;
}

/* Sólo se muestra como flex cuando NO está hidden */
.time-modal:not([hidden]) {
	display: flex;
	align-items: center;
	justify-content: center;
}

.time-modal__content {
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: flex-end;
	background: transparent url("recursos/f-tiempo.png") center / contain no-repeat;
	border-radius: 16px;
	padding: 48px 32px 36px;
	max-width: 460px;
	width: min(100%, 460px);
	aspect-ratio: 4 / 3;
	text-align: center;
}

.time-modal__title {
	margin: 0 0 8px;
	font-size: 20px;
	color: #222222;
}

.time-modal__subtitle {
	margin: 0 0 16px;
	font-size: 14px;
	color: #555555;
}

.time-modal__buttons {
	display: flex;
	flex-direction: column;
	gap: 8px;
	align-items: center;
	margin-bottom: 8px;
	width: 100%;
	max-width: 360px;
}

.time-modal__btn {
	flex: 0 0 auto;
	width: 100%;
	max-width: 260px;
	padding: 0;
	border: none;
	background: transparent;
	cursor: pointer;
}

.time-modal__btn:hover {
	opacity: 0.9;
}

.time-modal__btn img {
	width: 100%;
	height: auto;
	display: block;
}

.time-modal__cancel {
	border: none;
	background: transparent;
	color: #666666;
	font-size: 14px;
	cursor: pointer;
	margin-top: 4px;
}

/* Modal de confirmaci f3n para el profesor */
.sent-modal {
	position: fixed;
	top: 0;
	left: 0;
	width: 100vw;
	height: 100vh;
	background: rgba(0, 0, 0, 0.4);
	z-index: 1003;
}

.sent-modal:not([hidden]) {
	display: flex;
	align-items: center;
	justify-content: center;
}

.sent-modal__content {
	background: #ffffff;
	border-radius: 12px;
	padding: 16px 20px;
	max-width: 260px;
	width: 80%;
	text-align: center;
}

.sent-modal__text {
	margin: 0;
	font-size: 16px;
	color: #222222;
}

.app {
	width: 100%;
	max-width: 415px;
	height: 100vh;
	max-height: 100vh;
	aspect-ratio: 1125 / 2436;
	position: relative;
	overflow: hidden;
	background-color: #101820;
	border-radius: 24px;
}

.screen {
	position: absolute;
	inset: 0;
	display: flex;
	flex-direction: column;
	width: 100%;
	max-width: 100%;
	height: 100%;
	opacity: 0;
	pointer-events: none;
	transition: opacity 200ms ease;
	overflow: hidden;
}

.screen.is-active {
	opacity: 1;
	pointer-events: auto;
}

.home-screen {
	background: #101820 url("recursos/fondo-inicio.png") center / contain no-repeat;
	padding: clamp(20px, 6%, 40px) clamp(12px, 4%, 24px);
	gap: 0;
}

.home-screen .screen__section:first-child {
	flex: 0.5 1 0;
}

.home-screen .screen__section--mascot {
	flex: 1 1 0;
	margin-top: -20px;
}

.home-screen .screen__section--cta {
	flex: 1 1 0;
	margin-top: -40px;
}

.home-screen .screen__section--back {
	flex: 0.3 1 0;
	margin-top: -100px;
}

.home__back {
	border: none;
	background: transparent;
	padding: 0;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
	margin-top: -80px;
}

.home__back img {
	width: clamp(32px, 10%, 56px);
	height: auto;
}

.screen__section {
	flex: 1 1 0;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: clamp(12px, 6%, 28px);
	width: 100%;
	max-width: 100%;
}

.screen__section img {
	max-width: 100%;
	max-height: 100%;
	object-fit: contain;
}

.screen__section--mascot img {
	width: clamp(220px, 64%, 360px);
}

.screen__section--cta {
	justify-content: center;
}

.screen__section--cta img {
	width: clamp(180px, 58%, 320px);
}

.screen__section--back {
	flex: 0 0 auto;
	padding: clamp(8px, 2%, 16px);
	justify-content: center;
	margin-top: -60px;
}

.home-screen .screen__section--back {
	margin-top: -60px;
}

.home-screen .screen__section--cta {
	margin-top: -40px;
}

.home-role-buttons {
	display: flex;
	justify-content: center;
	gap: clamp(12px, 4%, 20px);
	margin-bottom: clamp(8px, 2%, 16px);
	margin-top: -40px;
}

.home-role-buttons .screen__button img {
	width: clamp(140px, 44%, 220px);
	max-width: 100%;
	height: auto;
}

/* Refuerzo para que cualquier elemento con [hidden] realmente no se vea, incluido el btn Comenzar */
[hidden] {
	display: none !important;
}

.screen__button {
	border: none;
	background: transparent;
	padding: 0;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
}

.screen__button:focus-visible,
.tutorial__btn:focus-visible {
	outline: 2px solid #fff38a;
	outline-offset: 4px;
}

.tutorial-screen {
	background: #101820 url("recursos/f-tutorial.png") center / contain no-repeat;
	padding: clamp(20px, 6%, 40px) clamp(12px, 4%, 24px);
	gap: clamp(16px, 6%, 32px);
}

.tutorial-screen .screen__section--back {
	margin-top: -20px;
}

.tutorial-screen .tutorial__nav {
	margin-top: -20px;
}

.tutorial__back {
	border: none;
	background: transparent;
	padding: 0;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
	margin-top: clamp(12px, 3%, 20px);
}

.tutorial__back img {
	width: clamp(32px, 10%, 56px);
	height: auto;
}

.tutorial__section-top {
	flex: 0.7;
}

.tutorial__track {
	display: flex;
	align-items: center;
	width: 100%;
	transition: transform 240ms ease;
}

.tutorial__track.is-instant {
	transition: none;
}

.tutorial__track.is-animating {
	opacity: 0.9;
}

.tutorial__slide {
	flex: 0 0 100%;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: clamp(8px, 4%, 16px);
	margin-inline: 0;
}

.tutorial__slide img {
	width: 92%; /* Reduced width to create internal padding */
	height: auto;
	object-fit: contain;
	pointer-events: none;
}
.tutorial__section-track {
	flex: 1.6;
	align-items: center;
	justify-content: center;
	width: clamp(240px, 82%, 520px);
	max-width: 100%;
	overflow: hidden;
	margin: 0 auto;
}

.tutorial__section-nav {
	flex: 0.7;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
}

.tutorial__nav {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: clamp(12px, 4%, 24px);
	width: clamp(240px, 82%, 520px);
	max-width: 100%;
}

.tutorial__btn {
	border: none;
	background: transparent;
	padding: 0;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
}

.tutorial__btn img {
	width: clamp(92px, 28%, 148px);
	height: auto;
	display: block;
	max-width: 100%;
}

.third-screen {
	background: #101820 url("recursos/f-3.png") center / contain no-repeat;
	padding: clamp(20px, 6%, 40px) clamp(12px, 4%, 24px);
	display: flex;
	flex-direction: column;
	gap: clamp(16px, 4%, 32px);
}

.third-header {
	display: flex;
	align-items: center;
	justify-content: space-around;
	gap: clamp(8px, 2%, 12px);
	padding: 0 clamp(12px, 4%, 24px);
	margin-top: 20px;
	flex: 0 0 auto;
	width: 100%;
	max-width: 100%;
	height: clamp(48px, 12%, 72px);
}

.third-header__spacer {
	flex: 1 1 auto;
}

.third__back,
.third__menu {
	border: none;
	background: transparent;
	padding: 0;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
	flex: 0 0 auto;
	width: clamp(40px, 12%, 64px);
	height: clamp(40px, 12%, 64px);
}

.third__back img,
.third__menu img {
	width: 100%;
	height: auto;
	max-width: 100%;
	display: block;
}

.third__options {
	flex: 1 1 auto;
	display: flex;
	flex-direction: column;
	gap: clamp(12px, 4%, 20px);
	margin-top: -40px;
}

.third__btn {
	flex: 1 1 0;
	border: none;
	background: transparent;
	padding: 0;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
}

.third__btn img {
	width: clamp(180px, 58%, 320px);
	height: auto;
	display: block;
	max-width: 100%;
}

.screen-4-1 {
	background: #101820 url("recursos/f-3.png") center / contain no-repeat;
	padding: clamp(20px, 6%, 40px) clamp(12px, 4%, 24px);
	display: flex;
	flex-direction: column;
}

.screen-4-2 {
	background: #101820 url("recursos/f-4-2.png") center / contain no-repeat;
	padding: clamp(20px, 6%, 40px) clamp(12px, 4%, 24px);
	display: flex;
	flex-direction: column;
}

.screen-4-2 .third__options {
	margin-top: -40px;
}

.screen-4-3 {
	background: #101820 url("recursos/f-4-3.png") center / contain no-repeat;
	padding: clamp(20px, 6%, 40px) clamp(12px, 4%, 24px);
	display: flex;
	flex-direction: column;
}

.screen-4-3 .third__options {
	margin-top: -40px;
}
.screen-4-3-1 {
	background: #101820 url("recursos/f-4-1-3.png") center / contain no-repeat;
	padding: clamp(20px, 6%, 40px) clamp(12px, 4%, 24px);
	display: flex;
	flex-direction: column;
}

.screen-4-3-2 {
	background: #101820 url("recursos/f-4-1-3.png") center / contain no-repeat;
	padding: clamp(20px, 6%, 40px) clamp(12px, 4%, 24px);
	display: flex;
	flex-direction: column;
}

.screen-4-3-3 {
	background: #101820 url("recursos/f-4-1-3.png") center / contain no-repeat;
	padding: clamp(20px, 6%, 40px) clamp(12px, 4%, 24px);
	display: flex;
	flex-direction: column;
}
.four-content {
	flex: 1 1 auto;
	display: flex;
	flex-direction: column;
	justify-content: flex-start;
	height: 100%;
	overflow: hidden;
}

.four-header {
	display: flex;
	align-items: center;
	justify-content: space-around;
	gap: clamp(8px, 2%, 12px);
	padding: clamp(8px, 2%, 16px) clamp(12px, 4%, 24px);
	margin-bottom: clamp(8px, 2%, 12px);
	margin-top: 25px;
	flex: 0 0 auto;
	width: 100%;
	max-width: 100%;
	height: clamp(48px, 12%, 72px);
}

.four-header__back,
.four-header__menu {
	border: none;
	background: transparent;
	padding: 0;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
	flex: 0 0 auto;
	width: clamp(40px, 12%, 64px);
	height: clamp(40px, 12%, 64px);
}

.four-header__back img,
.four-header__menu img {
	width: 100%;
	height: auto;
	max-width: 100%;
	display: block;
}

.four-header__image {
	flex: 1 1 auto;
	display: flex;
	align-items: center;
	justify-content: center;
	max-width: 100%;
	height: 100%;
}

.four-header__image img {
	height: 100%;
	width: auto;
	max-width: 100%;
	object-fit: contain;
}

.screen-4-1-1 {
	background: #101820 url("recursos/f-4-1-1.png") center / contain no-repeat;
	padding: clamp(20px, 6%, 40px) clamp(12px, 4%, 24px);
	display: flex;
	flex-direction: column;
}

.screen-4-3-2 {
	background: #101820 url("recursos/f-4-1-3.png") center / contain no-repeat;
	padding: clamp(20px, 6%, 40px) clamp(12px, 4%, 24px);
	display: flex;
	flex-direction: column;
}

.screen-4-3-3 {
	background: #101820 url("recursos/f-4-1-3.png") center / contain no-repeat;
	padding: clamp(20px, 6%, 40px) clamp(12px, 4%, 24px);
	display: flex;
	flex-direction: column;
}

.screen-4-2-1 {
	background: #101820 url("recursos/f-4-1-2.png") center / contain no-repeat;
	padding: clamp(20px, 6%, 40px) clamp(12px, 4%, 24px);
	display: flex;
	flex-direction: column;
}

.screen-4-2-2 {
	background: #101820 url("recursos/f-4-1-2.png") center / contain no-repeat;
	padding: clamp(20px, 6%, 40px) clamp(12px, 4%, 24px);
	display: flex;
	flex-direction: column;
}

.screen-4-2-3 {
	background: #101820 url("recursos/f-4-1-2.png") center / contain no-repeat;
	padding: clamp(20px, 6%, 40px) clamp(12px, 4%, 24px);
	display: flex;
	flex-direction: column;
}

.screen-4-1-2 {
	background: #101820 url("recursos/f-4-1-1.png") center / contain no-repeat;
	padding: clamp(20px, 6%, 40px) clamp(12px, 4%, 24px);
	display: flex;
	flex-direction: column;
}

.screen-4-1-3 {
	background: #101820 url("recursos/f-4-1-1.png") center / contain no-repeat;
	padding: clamp(20px, 6%, 40px) clamp(12px, 4%, 24px);
	display: flex;
	flex-direction: column;
}

.screen-4-3-1 {
	background: #101820 url("recursos/f-4-1-3.png") center / contain no-repeat;
	padding: clamp(20px, 6%, 40px) clamp(12px, 4%, 24px);
	display: flex;
	flex-direction: column;
}

.screen-4-3-2 {
	background: #101820 url("recursos/f-4-1-3.png") center / contain no-repeat;
	padding: clamp(20px, 6%, 40px) clamp(12px, 4%, 24px);
	display: flex;
	flex-direction: column;
}

.screen-4-3-3 {
	background: #101820 url("recursos/f-4-1-3.png") center / contain no-repeat;
	padding: clamp(20px, 6%, 40px) clamp(12px, 4%, 24px);
	display: flex;
	flex-direction: column;
}

.four11-content {
	flex: 1 1 auto;
	display: flex;
	flex-direction: column;
	justify-content: flex-start;
	height: 100%;
	overflow: hidden;
}

.four11-header {
	display: flex;
	align-items: center;
	justify-content: space-around;
	gap: clamp(8px, 2%, 12px);
	padding: clamp(8px, 2%, 16px) clamp(12px, 4%, 24px);
	margin-bottom: clamp(8px, 2%, 12px);
	margin-top: 5px;
	flex: 0 0 auto;
	width: 100%;
	max-width: 100%;
	height: clamp(48px, 12%, 72px);
}

.four11-header__back,
.four11-header__menu {
	border: none;
	background: transparent;
	padding: 0;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
	flex: 0 0 auto;
	width: clamp(40px, 12%, 64px);
	height: clamp(40px, 12%, 64px);
}

.four11-header__back img,
.four11-header__menu img {
	width: 100%;
	height: auto;
	max-width: 100%;
	display: block;
}

.four11-header__image {
	flex: 1 1 auto;
	display: flex;
	align-items: center;
	justify-content: center;
	max-width: 100%;
	height: 100%;
}

.four11-header__image img {
	height: 100%;
	width: auto;
	max-width: 100%;
	object-fit: contain;
}

.four11-grid {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: clamp(8px, 3%, 16px);
	padding: clamp(8px, 2%, 16px);
	flex: 1 1 auto;
	align-content: center;
	justify-items: center;
}

.four11-btn {
	border: none;
	background: transparent;
	padding: 0;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	max-width: clamp(120px, 37%, 190px);
}

.four11-btn img {
	width: 100%;
	height: auto;
	display: block;
}

.four11-grid .four11-btn:nth-child(3) {
	grid-column: 1 / -1;
	justify-self: center;
}

.screen__button {