:root {
	--accent-1: 70, 156, 218;
	--accent-2: 255, 205, 113;
	--accent-3: 156, 186, 180;
	--backgroundColor: 38, 38, 100;
    --ring: rgb(var(--accent-2));
	--text-color: #fff;
	--text-color-on-background: #000;
	--mouse-x: 50%;
	--mouse-y: 50%;
	--shadow-1: 0 2px 2px 0 rgba(0,0,0,0.14),0 3px 1px -2px rgba(0,0,0,0.12),0 1px 5px 0 rgba(0,0,0,0.2);
	--shadow-2: 0 4px 5px 0 rgba(0,0,0,0.14),0 1px 10px 0 rgba(0,0,0,0.12),0 2px 4px -1px rgba(0,0,0,0.3);
	--shadow-3: 0 8px 17px 2px rgba(0,0,0,0.14),0 3px 14px 2px rgba(0,0,0,0.12),0 5px 5px -3px rgba(0,0,0,0.2);
}

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

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
    letter-spacing: -0.011rem;
    line-height: 1.6;
    min-height: 100dvh;
}

p {
	font-size: 16px;
	line-height: 1.2;
	margin-bottom: 1em;
}

h1 {
	font-size: 86px;
	line-height: .9;
	margin-bottom: 0.5em;
	font-weight: bold;
}

h2 {
	font-size: 28px;
	font-weight: bold;
	line-height: 1.25;
	margin-bottom: 0.5em;
}

.thinking-indicator {
	color: #000;
	font-style: italic;
}

.thinking-indicator .char {
	animation: wave 2s infinite;
	display: inline-block;
}

.thinking-indicator .char:nth-child(1) { animation-delay: 0s; }
.thinking-indicator .char:nth-child(2) { animation-delay: 0.1s; }
.thinking-indicator .char:nth-child(3) { animation-delay: 0.2s; }
.thinking-indicator .char:nth-child(4) { animation-delay: 0.3s; }
.thinking-indicator .char:nth-child(5) { animation-delay: 0.4s; }
.thinking-indicator .char:nth-child(6) { animation-delay: 0.5s; }
.thinking-indicator .char:nth-child(7) { animation-delay: 0.6s; }
.thinking-indicator .char:nth-child(8) { animation-delay: 0.7s; }
.thinking-indicator .char:nth-child(9) { animation-delay: 0.8s; }
.thinking-indicator .char:nth-child(10) { animation-delay: 0.9s; }
.thinking-indicator .char:nth-child(11) { animation-delay: 1.0s; }

@keyframes wave {
	0%, 60%, 100% { opacity: 0.3; }
	30% { opacity: 1; }
}

h3 {
	font-size: 20px;
	line-height: 1.3;
	margin-bottom: 0.5em;
	font-weight: bold;
}

h4 {
	font-size: 18px;
	line-height: 1.35;
	margin-bottom: 0.5em;
	font-weight: bold;
}

h5 {
	font-size: 16px;
	line-height: 1.4;
	margin-bottom: 0.5em;
	font-weight: bold;
}

h6 {
	font-size: 14px;
	line-height: 1.45;
	margin-bottom: 0.5em;
	font-weight: bold;
}

ul, ol {
	font-size: 16px;
	line-height: 1.5;
	margin-bottom: 1em;
}

ul {
	list-style: disc;
	margin-left: 1.5em;
}

ol {
	list-style: decimal;
	margin-left: 1.5em;
}

li {
	line-height: 1.2;
	margin-bottom: 0;
}

button {
	border-radius: 8px;
	border: 3px solid transparent;
	box-shadow: var(--shadow-2);
	color: var(--text-color);
    cursor: pointer;
    font-size: 16px;
    font-weight: bold;
	overflow: hidden;
    padding: 10px 18px;
	position: relative;
    transition: all 0.2s;
	transform-origin: 50% 50%;

	&:before {
		background: radial-gradient(circle, rgba(var(--accent-3), 0.2) 0%, rgba(var(--accent-3), 0) 60%);
		content: "";
		left: 0;
		height: 150px;
		opacity: 0;
		pointer-events: none;
		position: absolute;
		top: 0;
		transform: translate(calc(var(--mouse-x) - 75px), calc(var(--mouse-y) - 75px));
		transform-origin: 50% 50%;
		transition: opacity .3s ease-in-out, transform .2s linear;
		width: 150px;
	}

	&:disabled {
		cursor: default;
		opacity: .1;
	}

	&:focus {
		outline: 2px solid rgb(var(--accent-2));
	}

	&.primary {
		background-color: rgb(var(--accent-1));
	}

	&.secondary {
		background-color: transparent;
		border-color: rgb(var(--accent-1));
	}

	&.tertiary {
		background-color: rgb(var(--accent-2));
		color: #000;

		&:before {
			background: radial-gradient(circle, rgba(255, 255, 255, 0.2) 0%, rgba(255, 255, 255, 0) 60%);
		}
	}

	&:not(:disabled):hover {
		box-shadow: var(--shadow-3); 
		transform: scale(1.02);

		&:before {
			opacity: 1;
		}
	}
}

textarea {
	background-color: rgba(255, 255, 255, .7);
	border-radius: 8px;
	border: 2px dashed rgb(var(--accent-1));
	box-shadow: var(--shadow-1); 
    font-family: inherit;
    font-size: 16px;
    height: 120px;
    margin-bottom: 1em;
    min-height: 70px;
	overflow: hidden;
    padding: 1em;
	position: relative;
    resize: none;
    transition: border-color 0.2s, box-shadow 0.2s;
	vertical-align: top;
    width: 100%;

	&:disabled {
		background-color: #fff;
		border-radius: 8px 0 8px 8px;
		border: none;
		color: #000;
		opacity: 1;
		pointer-events: none;
	}
}

textarea:focus {
    outline: 2px solid rgb(var(--accent-2));
}

/* Content Styles */
.background-image {
	background-position: top left;
	background-size: cover;
	height: 100dvh;
	pointer-events: none;
	position: fixed;
	width: 100%;
	z-index: -1;
}

.coach {
	background-color: rgb(var(--accent-2));
	border-radius: 8px; 
	box-shadow: 0 2px 2px 0 rgba(0,0,0,0.14),0 3px 1px -2px rgba(0,0,0,0.12),0 1px 5px 0 rgba(0,0,0,0.2);
	color: #000;
	padding: 1em;
	width: calc(100% - 24px);

	& > p:last-child {
		margin-bottom: 0;
	}
}

.card {
	align-items: flex-start;
	align-self: flex-end;
	background-color: rgb(var(--backgroundColor));
	border-radius: 12px 12px 0 0;
	color: var(--text-color);
	display: flex;
	flex-direction: column;
	margin-top: auto;
	max-width: 520px;
	padding: 24px;
	transition: all .3s ease;
	transform: translateZ(0);
	width: 100%;
}

.coach-wrapper {
	align-items: flex-start;
	display: flex;
	width: calc(100% - 24px);
}

.content {
    display: flex;
    flex-direction: column;
	margin: 0 auto;
	max-width: 1200px;
	min-height: 100dvh;
	width: 100%;
}

.hidden {
	opacity: 0;
	pointer-events: none;
}

.icon {
	transform: scale(2);
	width: 60px;
}

.remove {
	display: none;
	height: 0;
	width: 0;
}

.response {
	background-color: #fff;
	border-radius: 0 8px 8px 8px;
	box-shadow: 0 2px 2px 0 rgba(0,0,0,0.14),0 3px 1px -2px rgba(0,0,0,0.12),0 1px 5px 0 rgba(0,0,0,0.2);
	color: #000;
	margin-left: 70px;
    padding: 1em;
	transition: opacity .3s ease;
	transform: translateX(-40px);
    white-space: pre-wrap;
	width: calc(100% - 54px);
	margin-bottom: 1em;
	position: relative;

	&:before {
		border-color: transparent #fff transparent transparent;
		border-style: solid;
		border-width: 0 30px 20px 0;
		content: '';
		height: 0px;
        left: 0;
		position: absolute;
        top: 0;
        transform: translateX(-30px);
		width: 0px;
	}

	& > p:last-child {
		margin-bottom: 0;
	}
}

.textarea-wrapper {
	position: relative;
	width: calc(100% - 24px);

	&:has(*:disabled) {
		&:before {
			border-color: #fff transparent transparent transparent;
			border-style: solid;
			border-width: 20px 30px 0 0;
			content: '';
			height: 0px;
			position: absolute;
			right: 0;
			top: 0;
			transform: translateX(30px);
			width: 0px;
			z-index: 1;
		}
	}
}

body:not(.next) {
	.card:first-child {
		opacity: 1;
	}
	.card:nth-child(2) {
		opacity: 0;
	}
	nav button:first-child {
		opacity: 0;
		pointer-events: none;
	}
	nav button:last-child {
		opacity: 1;
	}
}

/* Mobile styles */
@media (max-width: 767px) {
	h1 {
		font-size: 56px;
	}
	
	.content {
		flex-direction: column;
		gap: 3rem;
		margin-top: 5vh;
		padding: 0 15px 60px;
	}
	
	/* Show both cards on mobile */
	body:not(.next) .card:nth-child(2),
	body.next .card:first-child {
		opacity: 1;
	}
	
	.card[inert] {
		display: block !important;
		inset: auto !important;
		opacity: 1 !important;
		pointer-events: auto !important;
	}
	
	.card {
		max-width: 100%;
	}

	.response {
		margin-left: 30px;
		transform: none;
		width: calc(100% - 30px);
	}

	.textarea-wrapper {
		&:has(*:disabled) {
			width: calc(100% - 30px);
		}
	}
}
