/*--------------------------------------------------------------
# Inner Circle — On the Horizon (quick stats)
# The three figures under the hero, each rising from behind a thin
# horizon line under a pale strip of sky with one small plane in it,
# then the join button.
--------------------------------------------------------------*/

/* ── Section ──
   The top padding is the strip of sky: the sky is drawn exactly that
   high above the figures, so it starts at the section's top edge and
   never reaches up into the section above. Since 28 Nov 2026 that is
   .ic-clips, which has no bottom padding: this sky is the gap between
   them. The bottom padding is the gap before .ic-parts, which has no
   top padding of its own. Below 992px the page-level rhythm in
   inner-circle-rhythm.css sets the bottom; the top stays the sky's. */
.ic-horizon {
	--ease-out: cubic-bezier(0.22, 1, 0.36, 1);
	/* The figures' size, which the line, the sky and the plane all key off */
	--ic-horizon-size: clamp(3.5rem, 7vw + 0.5rem, 7.5rem);
	/* How far the sky reaches above the figures */
	--ic-horizon-sky: 100px;

	position: relative;
	isolation: isolate;
	overflow-x: clip;
	background: var(--tpp-white);
	padding: var(--ic-horizon-sky) 0 120px;
}

.ic-horizon__container {
	width: 100%;
	max-width: var(--tpp-container-max);
	margin: 0 auto;
	padding: 0 var(--tpp-container-padding);
}


/* ──────────────────────────────────────────────
   The sky and the horizon line
   ────────────────────────────────────────────── */

.ic-horizon__stage {
	position: relative;
}

/* Pale blue, deepening towards the line, fading out at the top and the
   sides so there is no box edge. Drawn in CSS, not a photo, so it stays
   light behind the black figures. */
.ic-horizon__stage::before {
	content: '';
	position: absolute;
	z-index: -1;
	top: calc(var(--ic-horizon-sky) * -1);
	right: 0;
	left: 0;
	height: calc(var(--ic-horizon-sky) + var(--ic-horizon-size) * 1.1);
	background: linear-gradient(180deg, rgba(232, 240, 246, 0), #EDF3F8 55%, #DFEAF2);
	-webkit-mask: linear-gradient(90deg, transparent, #000 14%, #000 86%, transparent);
	mask: linear-gradient(90deg, transparent, #000 14%, #000 86%, transparent);
}

/* The line itself, at the foot of the figures */
.ic-horizon__stage::after {
	content: '';
	position: absolute;
	top: calc(var(--ic-horizon-size) * 1.1);
	right: 0;
	left: 0;
	height: 1px;
	background: linear-gradient(90deg, transparent, rgba(26, 26, 26, 0.3) 14%, rgba(26, 26, 26, 0.3) 86%, transparent);
}

/* A small plane high in the sky, just right of centre */
.ic-horizon__plane {
	position: absolute;
	z-index: -1;
	top: calc(var(--ic-horizon-size) * -0.55);
	left: 60%;
	width: 20px;
	height: 20px;
	color: #9DB0BE;
	opacity: 0;
	transform: rotate(80deg) translateY(10px);
	transition:
		opacity 1.2s ease 0.6s,
		transform 2.6s var(--ease-out) 0.6s;
}

.ic-horizon.is-visible .ic-horizon__plane {
	opacity: 1;
	transform: rotate(80deg);
}


/* ──────────────────────────────────────────────
   The figures
   ────────────────────────────────────────────── */

/* As many equal columns as there are figures (three, or two if the
   sessions count is ever left out) */
.ic-horizon__stats {
	display: grid;
	grid-auto-columns: minmax(0, 1fr);
	grid-auto-flow: column;
	margin: 0;
	padding: 0;
	list-style: none;
	text-align: center;
}

.ic-horizon__stat {
	margin: 0;
}

/* Four figures (since the Facebook group's "24/7" joined on 26 Nov 2026):
   a little smaller, with air between the columns, so they don't crowd each
   other. Phones get their own size and gap below. */
.ic-horizon--four {
	--ic-horizon-size: clamp(3rem, 5.6vw + 0.4rem, 6.25rem);
}

.ic-horizon--four .ic-horizon__stats {
	column-gap: clamp(24px, 3vw, 48px);
}

/* Exactly one figure tall, its bottom on the line. Clipped top and
   bottom only, not at the sides, so a wide figure like "120 min" can
   spill past its column; the clip is what hides each figure below the
   line until it rises. */
.ic-horizon__num {
	display: block;
	height: calc(var(--ic-horizon-size) * 1.1);
	padding-top: calc(var(--ic-horizon-size) * 0.1);
	clip-path: inset(0 -60% 0 -60%);
	font-family: var(--tpp-font-heading);
	font-size: var(--ic-horizon-size);
	font-weight: 700;
	line-height: 1;
	letter-spacing: -0.055em;
	color: var(--tpp-black);
	white-space: nowrap;
}

.ic-horizon__figure {
	display: inline-block;
	transform: translateY(105%);
	transition: transform 1.1s var(--ease-out);
	transition-delay: calc(0.15s + var(--stat-index, 0) * 0.14s);
}

.ic-horizon.is-visible .ic-horizon__figure {
	transform: none;
}

/* The "/" in "24/7". At full size it drops below the line the digits sit
   on and runs into them under the tight letter-spacing, so it's a little
   smaller, lifted onto the line, with a sliver of room either side. */
.ic-horizon__slash {
	display: inline-block;
	margin: 0 0.04em 0 0.02em;
	font-size: 0.8em;
	letter-spacing: 0;
	transform: translateY(-0.07em);
}

.ic-horizon__unit {
	font-size: 0.42em;
	letter-spacing: -0.02em;
	color: var(--tpp-text-light);
}

/* The site's body font, set as the small-caps label the lounge pass uses
   (.ic-lounge__fact dt) */
.ic-horizon__label {
	display: block;
	padding-top: 18px;
	font-family: var(--tpp-font-body);
	font-size: 0.6875rem;
	font-weight: 600;
	line-height: 1.4;
	letter-spacing: 0.1em;
	text-transform: uppercase;
	text-wrap: balance;
	color: var(--tpp-text-light);
}


/* ──────────────────────────────────────────────
   Join button
   ────────────────────────────────────────────── */

.ic-horizon__actions {
	display: flex;
	justify-content: center;
	margin-top: 40px;
	opacity: 0;
	transform: translateY(16px);
	transition:
		opacity 0.7s var(--ease-out) 0.6s,
		transform 0.7s var(--ease-out) 0.6s;
}

.ic-horizon.is-visible .ic-horizon__actions {
	opacity: 1;
	transform: none;
}

.ic-horizon__join {
	display: inline-flex;
	align-items: center;
	gap: 12px;
	padding: 8px 8px 8px 22px;
	border-radius: var(--tpp-radius-pill);
	background: var(--tpp-black);
	font-family: var(--tpp-font-body);
	font-size: 0.9375rem;
	font-weight: 600;
	line-height: 1.2;
	text-decoration: none;
	white-space: nowrap;
	transition: background 0.25s ease;
}

/* style.css sets every link state to color: inherit, so each is restated */
.ic-horizon__join,
.ic-horizon__join:visited,
.ic-horizon__join:hover,
.ic-horizon__join:focus,
.ic-horizon__join:active {
	color: var(--tpp-white);
}

.ic-horizon__join:hover {
	background: #000000;
}

.ic-horizon__join:focus-visible {
	outline: 2px solid var(--tpp-black);
	outline-offset: 3px;
}

.ic-horizon__join-icon {
	display: grid;
	place-items: center;
	flex: none;
	width: 34px;
	height: 34px;
	border-radius: 50%;
	background: var(--tpp-accent);
	color: var(--tpp-black);
}

.ic-horizon__join-icon svg {
	width: 15px;
	height: 15px;
}


/* ──────────────────────────────────────────────
   Responsive
   ────────────────────────────────────────────── */

/* Tablet (≤991px) — a shorter sky */
@media screen and (max-width: 991px) {
	.ic-horizon {
		--ic-horizon-sky: 84px;
	}

	.ic-horizon__actions {
		margin-top: 36px;
	}
}

/* Mobile (≤767px) — smaller; four figures go two by two in boxes */
@media screen and (max-width: 767px) {
	.ic-horizon {
		--ic-horizon-size: clamp(2.25rem, 12vw, 3.25rem);
		--ic-horizon-sky: 64px;
	}

	.ic-horizon__label {
		padding-top: 14px;
		font-size: 0.625rem;
		letter-spacing: 0.06em;
	}

	.ic-horizon__actions {
		margin-top: 32px;
	}

	/* Four figures on phones (since the Facebook group's "24/7" joined on
	   26 Nov 2026): two by two, each in its own rounded box, rather than
	   four squeezed into one row. The sky, the horizon line and the plane
	   belong to the one-row layout, so they step aside here; each figure
	   still rises into view, inside its box. */
	.ic-horizon--four {
		--ic-horizon-size: clamp(2.25rem, 10.5vw, 3rem);
		--ic-horizon-sky: 48px;
	}

	.ic-horizon--four .ic-horizon__stage::before,
	.ic-horizon--four .ic-horizon__stage::after,
	.ic-horizon--four .ic-horizon__plane {
		display: none;
	}

	.ic-horizon--four .ic-horizon__stats {
		grid-template-columns: repeat(2, minmax(0, 1fr));
		grid-auto-flow: row;
		gap: 12px;
	}

	.ic-horizon--four .ic-horizon__stat {
		padding: 22px 12px 20px;
		border: 1px solid #DFEAF2;
		border-radius: 20px;
		background: linear-gradient(180deg, #F3F7FA, var(--tpp-white) 75%);
	}

	.ic-horizon--four .ic-horizon__label {
		padding-top: 12px;
		font-size: 0.6875rem;
	}
}

/* Small mobile (≤480px) — the button runs the full width */
@media screen and (max-width: 480px) {
	.ic-horizon__join {
		width: 100%;
		justify-content: space-between;
	}
}


/* ──────────────────────────────────────────────
   Reduced motion — figures up, plane in place, button shown
   ────────────────────────────────────────────── */

@media (prefers-reduced-motion: reduce) {
	.ic-horizon__figure,
	.ic-horizon__plane,
	.ic-horizon__actions {
		transition: none;
	}
}
