:root {
	--card-height: 40vw;
	--card-margin: 4vw;
	--card-top-offset: 1em;
	--numcards: 5;
	--outline-width: 0px;
}

#cards {
	
}

#card_1 {
	--index: 1;
}

#card_2 {
	--index: 2;
}

#card_3 {
	--index: 3;
}

#card_4 {
	--index: 4;
}

#card_5 {
	--index: 5;
}
.cards {
	position: sticky;
	top: 90px;
	padding-top: calc(var(--index) * var(--card-top-offset));
}

@supports (animation-timeline: works) {

	@scroll-timeline cards-element-scrolls-in-body {
		source: selector(body);
		scroll-offsets:
			/* Start when the start edge touches the top of the scrollport */
			selector(#cards) start 1,
			/* End when the start edge touches the start of the scrollport */
			selector(#cards) start 0
		;
		start: selector(#cards) start 1; /* Start when the start edge touches the top of the scrollport */
		end: selector(#cards) start 0; /* End when the start edge touches the start of the scrollport */
		time-range: 5s;
	}

	.cards {
		--index0: calc(var(--index) - 1); /* 0-based index */
		--reverse-index: calc(var(--numcards) - var(--index0)); /* reverse index */
		--reverse-index0: calc(var(--reverse-index) - 1); /* 0-based reverse index */
	}
	
	.card__content {
		transform-origin: 50% 0%;
		will-change: transform;

		--duration: calc(var(--reverse-index0) * 1s);
		--delay: calc(var(--index0) * 1s);

		animation: var(--duration) linear scale var(--delay) forwards;
		animation-timeline: cards-element-scrolls-in-body;
	}

	@keyframes scale {
		to {
			transform:
				scale(calc(
					1.1
					-
					calc(0.1 * var(--reverse-index))
				));
		}
	}
}


/** PAGE STYLING **/

* { /* Poor Man's Reset */
	box-sizing: border-box;
	margin: 0;
	padding: 0;
}

main {
	width: 80vw;
	margin: 0 auto;
}

#cards {
	list-style: none;
	outline: calc(var(--outline-width) * 10) solid blue;
	
	display: grid;
	grid-template-columns: 1fr;
	grid-template-rows: repeat(var(--numcards), var(--card-height));
	gap: var(--card-margin);
}

.cards {
	outline: var(--outline-width) solid hotpink; 
}

.card__content {
	box-shadow: 1em 1em 3em rgba(1, 170, 218, 0.5);
	background: rgb(8, 20, 36);
	color: rgb(255, 255, 255);
	border-radius: 3em;
	overflow: hidden;

	display: grid;
	grid-template-areas: "text img";
	/*grid-template-columns: 1fr 1fr;*/
	grid-template-rows: auto;

	align-items: stretch;
	outline: var(--outline-width) solid lime;
}

.card__content > div {
	grid-area: text;
	width: 80%;
	place-self: center;
	text-align: left;

	display: grid;
	gap: 1em;
	place-items: start;
}

.card__content > figure {
	grid-area: img;
	overflow: hidden; margin: 0px;
}

.card__content > figure > img {
	width: 100%;
	height: 100%;
	object-fit: cover; float: right;
}

.uniq-card h2{ font-size: 35px; color: #fff;}
.uniq-card li{ list-style: circle; font-size: 18px; 
    line-height: 30px;}
.uniq-card{}
.uniq-card{}
.why-dev { width: 100%;}
.outerbox ul { display: inline;}
.whybox ul li{ list-style: none; display: inline;}