/*
 * Story A — chapters 01 (mocks) and 02 (#tests, the module cards).
 * patterns/story-a.php. Port of the first two <section data-ch> blocks inside
 * #how in src/features/landing/landing-page.tsx: every value below is the
 * inline style the TSX drew. The chapter shell (.id-ch, .id-ch__rail,
 * .id-ch__node, .id-ch__body, .id-eyebrow, .id-ch__title, .id-ch__lede) is in
 * base.css.
 *
 * Neither graphic changes with the 900px / 1180px breakpoints: only the shell
 * around them does (base.css).
 *
 * landing.js writes inline: transform + opacity on the graphic (data-gfx),
 * background + transform on each tile (data-tile), opacity + `translate` on
 * each module card (data-mod). Nothing here sets those on those elements
 * except the finished-state tile colours, which inline styles override.
 */

/* ---------------------------------------------------------------------------
 * 01 — mocks: one real IELTS beside a bank of mock tests
 * ------------------------------------------------------------------------ */
.id-mocks {
	display: grid;
	grid-template-columns: minmax(0, 0.78fr) minmax(0, 1.22fr);
	gap: 14px;
	align-items: stretch;
}

/* The single real test: a ticket and "1 real IELTS". */
.id-mocks__real {
	position: relative;
	border-radius: 28px;
	background: #FFFFFF;
	box-shadow: 0 1px 2px rgba(9, 20, 40, 0.05), inset 0 0 0 1px rgba(9, 20, 40, 0.06);
	padding: 22px;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	gap: 16px;
	text-align: center;
}
.id-mocks__ticket {
	position: relative;
	width: 78px;
	height: 100px;
	border-radius: 14px;
	background: #F7F9FD;
	box-shadow: inset 0 0 0 2px #D5E0F0;
	display: flex;
	flex-direction: column;
	justify-content: center;
	gap: 8px;
	padding: 0 16px;
	box-sizing: border-box;
}
.id-mocks__notch {
	position: absolute;
	top: 50%;
	width: 14px;
	height: 14px;
	margin-top: -7px;
	border-radius: 50%;
	background: #FFFFFF;
}
.id-mocks__notch--l {
	left: -7px;
	box-shadow: inset -2px 0 0 #D5E0F0;
}
.id-mocks__notch--r {
	right: -7px;
	box-shadow: inset 2px 0 0 #D5E0F0;
}
.id-mocks__rule {
	height: 5px;
	border-radius: 3px;
	background: #D5E0F0;
}
.id-mocks__rule--short {
	width: 66%;
}

/* "1" and "100s". (.id-mocks__real-text, the wrapper of "1 real IELTS", is
   unstyled, like the plain <div> it replaces.) */
.id-mocks__num {
	font-family: 'Geist Mono', monospace;
	font-size: 32px;
	font-weight: 600;
	line-height: 1;
}
.id-mocks__label {
	font-size: 13px;
	font-weight: 700;
	color: #586A87;
	margin-top: 6px;
}

/* The bank: a 10 × 6 grid of tiles and "100s of mock tests". */
.id-mocks__bank {
	border-radius: 28px;
	background: #0B1120;
	padding: 22px;
	display: flex;
	flex-direction: column;
	gap: 18px;
	box-shadow: 0 40px 70px -46px rgba(9, 20, 40, 0.8);
}
.id-mocks__tiles {
	display: grid;
	grid-template-columns: repeat(10, 1fr);
	gap: 5px;
}
/* Finished state: every tile lit, every ninth (i % 9 === 4) in sky. */
.id-mocks__tiles > span {
	aspect-ratio: 1;
	border-radius: 4px;
	background: #1668D9;
	transition: background .25s ease, transform .35s cubic-bezier(.34, 1.56, .64, 1);
}
.id-mocks__tiles > .id-mocks__tile--sky {
	background: #4DA2FF;
}
.id-mocks__stat {
	display: flex;
	align-items: baseline;
	gap: 10px;
	color: #FFFFFF;
}
.id-mocks__caption {
	font-size: 13px;
	font-weight: 700;
	color: #9AA9C4;
}

/* ---------------------------------------------------------------------------
 * 02 — mods (#tests): Listening, Reading, Writing, Speaking
 * ------------------------------------------------------------------------ */
.id-mods {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 12px;
}

/* Hover (lift + coloured ring) comes from id-lh4..id-lh7 in base.css. */
.id-mods__card {
	border-radius: 24px;
	background: #FFFFFF;
	box-shadow: 0 1px 2px rgba(9, 20, 40, 0.05), inset 0 0 0 1px rgba(9, 20, 40, 0.06);
	padding: 16px;
	display: flex;
	flex-direction: column;
	gap: 16px;
	transition: transform .3s cubic-bezier(.16, 1, .3, 1), box-shadow .3s;
}

.id-mods__art {
	height: 72px;
	border-radius: 16px;
}

/* Listening: an equaliser of 18 bars (per-bar animation-delay in the markup). */
.id-mods__art--listen {
	background: #EEF4FD;
	display: flex;
	align-items: center;
	gap: 3px;
	padding: 0 16px;
}
.id-mods__art--listen > span {
	flex: 1;
	height: 74%;
	border-radius: 2px;
	background: #1668D9;
	transform-origin: center;
	animation: id-eq 1.15s ease-in-out infinite;
}

/* Reading: lines of text with a highlighter scanning down. */
.id-mods__art--read {
	position: relative;
	background: #FBF0EA;
	padding: 11px 16px;
	box-sizing: border-box;
	display: flex;
	flex-direction: column;
	justify-content: space-between;
	overflow: hidden;
}
.id-mods__scan {
	position: absolute;
	left: 10px;
	right: 10px;
	top: 6px;
	height: 14px;
	border-radius: 5px;
	background: rgba(196, 83, 27, 0.2);
	animation: id-scan 3.6s cubic-bezier(.65, 0, .35, 1) infinite;
}
.id-mods__line {
	position: relative;
	height: 4px;
	border-radius: 2px;
	background: #C4531B;
	opacity: .55;
}
.id-mods__line--84 {
	width: 84%;
}
.id-mods__line--62 {
	width: 62%;
}
.id-mods__line--90 {
	width: 90%;
}

/* Writing: three lines typing themselves out. */
.id-mods__art--write {
	background: #E9F6EF;
	padding: 14px 16px;
	box-sizing: border-box;
	display: flex;
	flex-direction: column;
	justify-content: center;
	gap: 9px;
}
.id-mods__type {
	height: 5px;
	border-radius: 3px;
	background: #0E8F5E;
	transform-origin: 0 50%;
	animation: id-type 3.2s cubic-bezier(.65, 0, .35, 1) infinite;
}
.id-mods__type--2 {
	width: 76%;
	animation-delay: .45s;
}
.id-mods__type--3 {
	width: 50%;
	animation-delay: .9s;
}

/* Speaking: a mic with two rings pulsing out of it. */
.id-mods__art--speak {
	background: #F1ECFA;
	display: flex;
	align-items: center;
	justify-content: center;
}
.id-mods__mic {
	position: relative;
	width: 30px;
	height: 30px;
	border-radius: 50%;
	background: #6D3FCB;
	display: grid;
	place-items: center;
}
.id-mods__mic-body {
	width: 8px;
	height: 13px;
	border-radius: 4px;
	background: #FFFFFF;
}
.id-mods__ring {
	position: absolute;
	inset: 0;
	border-radius: 50%;
	box-shadow: 0 0 0 2px #6D3FCB;
	animation: id-ring 2s ease-out infinite;
}
.id-mods__ring--late {
	animation-delay: 1s;
}

/* Name and count under each graphic. */
.id-mods__meta {
	display: flex;
	align-items: baseline;
	justify-content: space-between;
	gap: 8px;
	padding: 0 4px 2px;
}
.id-mods__name {
	font-size: 17px;
	font-weight: 800;
}
.id-mods__count {
	font-family: 'Geist Mono', monospace;
	font-size: 12px;
	font-weight: 600;
	color: #1668D9;
}
.id-mods__count--read {
	color: #C4531B;
}
.id-mods__count--write {
	color: #0A6E48;
}
.id-mods__count--speak {
	color: #6D3FCB;
}
