/* Hithub Arena homepage: a cricket ground's boundary boards in daylight. */

.hithub-home {
	margin: 0;
	background: var(--chalk);
	color: var(--ink);
	font: 400 1.0625rem/1.6 var(--font-body);
	overflow-x: clip;
	scrollbar-color: var(--grass) var(--chalk);
}
.hithub-home *, .hithub-home *::before, .hithub-home *::after { box-sizing: border-box; }
:where(.hithub-home) a { color: inherit; text-underline-offset: 4px; } /* zero-specificity so .btn colours win */
.hithub-home #ast-scroll-top { display: none; } /* Astra's widget prints even with its CSS dropped. */
.grass a:focus-visible, .board--grass a:focus-visible, .board--blue a:focus-visible { outline-color: #fff; }
.hero__board a:focus-visible { outline-color: var(--ink); }

/* The ball's canvas floats above the page and never takes a click. */
.ball-canvas { position: fixed; inset: 0; width: 100%; height: 100%; z-index: 30; pointer-events: none; }

/* Hero */
.ch-hero {
	position: relative;
	min-height: 100svh;
	padding-top: var(--bar-h);
	display: flex; flex-direction: column;
	overflow: hidden;
}
/* The 30-yard circle, chalked across the field. */
.ch-hero::before {
	content: ""; position: absolute;
	width: max(110vw, 900px); aspect-ratio: 1; border-radius: 50%;
	right: -46vw; top: -30%;
	border: 2px solid rgba(255, 255, 255, .4);
	pointer-events: none;
}
@media (min-width: 900px) {
	.ch-hero::before { width: 66vw; right: -28vw; top: -6%; } /* Keeps the arc clear of the headline. */
}
.hero__copy { position: relative; flex: 1; padding: clamp(24px, 5vh, 64px) var(--gutter) clamp(24px, 4vh, 48px); display: flex; flex-direction: column; justify-content: center; }
.hero__title {
	font: 600 clamp(2.5rem, min(13.5vw, 15.5vh), 8.5rem)/1 var(--font-display);
	margin: 0 0 clamp(16px, 3vh, 32px);
}
.hero__line { display: block; overflow: hidden; padding-bottom: .1em; margin-bottom: -.1em; } /* Room for the descenders while the lines slide in. */
.hero__line > span { display: block; }
.hero__line--accent { color: var(--sign); }
.hero__lede { max-width: 38ch; font-size: clamp(1.0625rem, 1.6vw, 1.25rem); font-weight: 500; margin: 0; text-wrap: pretty; }

/* The yellow boundary board along the bottom of the field: the working booking action. */
.hero__board {
	position: relative;
	background: var(--sign); color: var(--ink);
	padding: 20px var(--gutter);
	display: grid; gap: 12px;
}
.hero__board-title { font: 700 1rem/1 var(--font-body); margin: 0; }
.slots { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 28px; min-height: 56px; }
.slots__slot {
	display: inline-flex; align-items: center; min-height: 44px;
	font: 600 clamp(2.25rem, 4.5vw, 3.5rem)/1 var(--font-display);
	font-variant-numeric: tabular-nums;
	text-decoration: none; white-space: nowrap;
	transition: color .25s var(--ease), transform .25s var(--ease);
}
.slots__slot:hover { color: var(--grass-2); transform: translateY(-2px); }
.slots__fallback { font: 600 clamp(1.5rem, 3vw, 2.25rem)/1.1 var(--font-display); margin: 0; }
.hero__actions { display: flex; align-items: center; gap: 20px; flex-wrap: wrap; }
.hero__wa { display: inline-block; padding: 12px 0; font-weight: 700; }
@media (min-width: 900px) {
	.hero__board { grid-template-columns: auto 1fr auto; align-items: center; gap: 40px; }
}

/* Pinned on large screens: one long run of boards, the ball rolling on the grass along the rope. */
.js-pin .ch-games { height: 100svh; padding: calc(var(--bar-h) + 24px) 0 0; display: flex; flex-direction: column; }
.js-pin .ch-games .section-title { margin-bottom: auto; }
.js-pin .boards { display: flex; flex: none; width: max-content; padding: 0; will-change: transform; }
/* Long and low, so two or more prices read side by side. */
.js-pin .board { width: min(46vw, 42.5rem); height: min(50vh, 27.5rem); }
.js-pin .rope { display: block; flex: none; height: 88px; position: relative; }
.js-pin .rope::before { content: ""; position: absolute; left: 0; right: 0; bottom: 8px; height: 3px; border-radius: 2px; background: var(--sign); }

/* The big line */
.ch-line { padding: clamp(120px, 26vh, 240px) var(--gutter); }
/* Proof */
.ch-proof { padding: clamp(80px, 14vh, 144px) var(--gutter); }
.proof__grid { display: grid; gap: clamp(32px, 5vw, 72px); margin-top: clamp(32px, 6vh, 64px); }
@media (min-width: 900px) { .proof__grid { grid-template-columns: minmax(280px, 1fr) 2.4fr; align-items: start; } }

/* The rating is the headline fact: an emerald panel the eye lands on first. */
.score { background: var(--grass); color: #fff; padding: clamp(24px, 3vw, 40px); display: grid; gap: 8px; justify-items: start; }
.score__value { font: 600 clamp(4.5rem, 8vw, 7rem)/1 var(--font-display); margin: 0; font-variant-numeric: tabular-nums; }
.score__stars { width: 140px; height: auto; fill: var(--sign); margin-bottom: 12px; }
.score__count { margin: 0; font-weight: 500; }
.score__link { display: inline-block; padding: 8px 0; margin-top: 8px; font-weight: 600; color: #fff; text-decoration-color: var(--sign); text-decoration-thickness: 2px; }
.score__link:hover { color: var(--sign); }

/* One featured quote, then the rest at one size, so length never decides loudness. */
.quotes { display: grid; gap: clamp(28px, 3vw, 40px) clamp(32px, 4vw, 56px); }
@media (min-width: 768px) { .quotes { grid-template-columns: 1fr 1fr; } .quote--lead { grid-column: 1 / -1; } }
.quote { margin: 0; display: grid; gap: 12px; align-content: start; }
.quote + .quote { border-top: 1px solid var(--line); padding-top: clamp(20px, 2vw, 28px); }
.quote blockquote { margin: 0; font-size: 1.125rem; line-height: 1.5; quotes: "“" "”"; }
.quote blockquote p { margin: 0; text-wrap: pretty; }
.quote blockquote p::before { content: open-quote; }
.quote blockquote p::after { content: close-quote; }
.quote--lead blockquote { font: 600 clamp(1.625rem, 3vw, 2.5rem)/1.2 var(--font-display); color: var(--grass); }
@media (min-width: 768px) { .quote:last-child:nth-child(even) { grid-column: 1 / -1; } } /* An odd count of supporting quotes leaves no empty cell. */
.quote figcaption { font-weight: 600; font-size: .9375rem; color: var(--ink-soft); }

/* My bookings: a yellow band */
.ch-club {
	background: var(--blue);
	color: #fff;
	padding: clamp(48px, 8vh, 80px) var(--gutter);
	display: grid; gap: 20px; justify-items: start;
}
.club__title { font: 600 clamp(2rem, 4vw, 3.25rem)/1.04 var(--font-display); margin: 0; max-width: 16ch; }
.club__text { margin: 0; max-width: 52ch; font-weight: 500; }
.club__ref { font-weight: 700; font-variant-numeric: tabular-nums; white-space: nowrap; }
@media (min-width: 900px) { .ch-club { grid-template-columns: 1fr 1fr auto; align-items: end; gap: 48px; } }

/* Find us */
.ch-find { padding: clamp(80px, 14vh, 144px) var(--gutter); display: grid; gap: 40px; }
.find__where { display: grid; gap: 16px; justify-items: start; }
.find__address, .find__hours { margin: 0; font-size: 1.1875rem; max-width: 44ch; }
.find__hours { font-weight: 600; }
.find__links { margin: 0; padding: 0; list-style: none; display: grid; gap: 12px; }
.find__links a { display: inline-block; padding: 6px 0; font: 600 clamp(1.375rem, 2.4vw, 2rem)/1.2 var(--font-display); text-decoration-thickness: 1px; text-decoration-color: var(--blue); }
.find__links a:hover { color: var(--blue); }
@media (min-width: 900px) { .ch-find { grid-template-columns: 1.4fr 1fr; align-items: end; } }

/* Final call: the stumps wait here for the ball. */
.ch-final {
	min-height: 100svh;
	padding: calc(var(--bar-h) + 40px) var(--gutter) 24px;
	display: grid; column-gap: 40px;
}
.final__main { align-self: center; }
.final__title { font: 600 clamp(3rem, 8.5vw, 7.5rem)/1.02 var(--font-display); margin: 0 0 32px; max-width: 9ch; }
.final__actions { display: flex; flex-wrap: wrap; gap: 12px; }
.final__stumps { height: clamp(120px, 22vh, 260px); margin-top: 32px; }
@media (min-width: 900px) {
	.ch-final { grid-template-columns: 1fr minmax(160px, 22vw); }
	.final__stumps { align-self: end; height: clamp(180px, 34vh, 340px); margin: 0; }
}

@media (max-width: 767px) { .hithub-home .btn--ink { min-height: 48px; } }

@media (prefers-reduced-motion: reduce) {
	[data-words] .word { opacity: 1; }
	.hithub-home *, .hithub-home *::before, .hithub-home *::after { transition: none !important; }
}

/* Landscape phones: the hero, its slots and its button all fit one short screen. */
@media (max-height: 500px) and (min-width: 560px) {
	.hithub-home .ch-hero { min-height: 100svh; }
	.hero__copy { padding-block: 12px; }
	.hero__title { font-size: clamp(2rem, 13vh, 3.25rem); margin-bottom: 8px; }
	.hero__line { display: inline; overflow: visible; }
	.hero__line > span { display: inline; }
	.hero__lede { font-size: 1rem; max-width: 60ch; }
	.hero__board { grid-template-columns: auto 1fr auto; align-items: center; gap: 20px; padding-block: 8px; }
	.slots { min-height: 44px; }
	.slots__slot { font-size: 2rem; }
	.slots__fallback { font-size: 1.25rem; }
}
