/* Not in a layer on purpose: core's block styles are unlayered and would win. */

/*
 * Tiles whose heading links: the tile is the target (see the cover below),
 * and its links keep the tile's colour.
 */
:is(.b24-gtile, .b24-label, .b24-mood, .b24-article, .b24-quote) { position: relative; }
:is(.b24-gtile, .b24-label, .b24-mood, .b24-article, .b24-quote) a { text-decoration: none; color: inherit; }

	/* ---- Hero: a drifting wall of covers and the stock number ---- */
	.b24-hero {
		position: relative; z-index: 5; display: flex;
		min-block-size: min(64vh, 640px); overflow: hidden;
		background: var(--b24-bg);
	}
	.b24-hero::after {
		content: ""; position: absolute; inset: 0;
		background: color-mix(in srgb, var(--b24-bg) calc(var(--b24-hero-shade) * 100%), transparent);
	}
	.b24-hero__wall {
		position: absolute; inset-block: -30%; inset-inline: -4%;
		display: grid; grid-template-columns: repeat(var(--b24-hero-cols), minmax(0, 1fr)); gap: 18px;
		rotate: -7deg; pointer-events: none;
	}
	.b24-hero__col {
		display: flex; flex-direction: column; gap: 18px;
		animation: b24-drift 80s linear infinite; will-change: transform;
	}
	.b24-hero__col:nth-child(even) { animation-direction: reverse; }
	.b24-hero__col:nth-child(2) { animation-delay: -22s; }
	.b24-hero__col:nth-child(3) { animation-delay: -47s; }
	.b24-hero__col:nth-child(4) { animation-delay: -9s; }
	.b24-hero__col:nth-child(5) { animation-delay: -61s; }
	.b24-hero__col img { inline-size: 100%; aspect-ratio: 1; object-fit: cover; border-radius: var(--b24-r-card); box-shadow: 0 14px 34px rgb(0 0 0 / .45); }
	@keyframes b24-drift { to { transform: translateY(calc(-50% - 9px)); } }
	.b24r-no-drift .b24-hero__col, .b24-hero.is-paused .b24-hero__col { animation-play-state: paused; }
	.b24r-no-drift .b24-hero__col { animation: none; }

	/* One picture instead of the wall. */
	.b24-hero__img { position: absolute; inset: 0; inline-size: 100%; block-size: 100%; object-fit: cover; }

	.b24-hero__in { position: relative; z-index: 2; display: flex; align-items: center; padding-block: 64px; }

	@media (max-width: 720px) {
		.b24-hero { min-block-size: 0; }
		.b24-hero__in { padding-block: 44px 24px; }
		.b24-hero__wall { gap: 10px; inset-inline: -20%; }
		.b24-hero__col { gap: 10px; }
	}

	/*
	 * A heading with a link covers its whole tile. Only on the site: in the
	 * editor the cover would catch every click meant for the tile's settings.
	 */
	:where(body:not(.editor-styles-wrapper)) :is(.b24-gtile, .b24-label, .b24-mood, .b24-article, .b24-quote) h3 a::after { content: ""; position: absolute; inset: 0; z-index: 1; }

	/* ---- Genre tiles ---- */
	.b24-genres__h { margin-block-end: 16px; font: 500 14px var(--b24-font-mono); text-transform: uppercase; letter-spacing: .12em; color: var(--b24-accent-ink); }
	.b24-gtiles { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; padding: 0; list-style: none; }
	.b24-gtile {
		isolation: isolate; overflow: hidden;
		display: flex; align-items: flex-end; justify-content: space-between; gap: 12px;
		min-block-size: 150px; padding: 20px 22px; border-radius: var(--b24-r-tile);
		background: var(--b24-s2); color: light-dark(#141416, #f6f3ec);
	}
	.b24-gtile__img { position: absolute; inset: 0; z-index: -2; inline-size: 100%; block-size: 100%; object-fit: cover; transition: transform .5s ease; }
	.b24-gtile::before {
		content: ""; position: absolute; inset: 0; z-index: -1;
		background: linear-gradient(to top, light-dark(rgb(245 242 236 / .94), rgb(14 14 16 / .88)), light-dark(rgb(245 242 236 / .4), rgb(14 14 16 / .35)));
	}
	.b24-gtile h3 { min-inline-size: 0; font-size: clamp(24px, 2.2vw, 32px); font-weight: 800; letter-spacing: -.02em; line-height: 1.05; }
	.b24-gtile::after {
		content: ""; flex: none; inline-size: 44px; block-size: 44px; border-radius: 50%;
		background: var(--b24-accent) var(--b24-arrow-dark) center / 20px no-repeat; transition: transform .2s;
	}
	.b24-gtile:hover > .b24-gtile__img { transform: scale(1.06); }
	.b24-gtile:hover::after { transform: translateX(4px); }
	@media (max-width: 900px) { .b24-gtiles { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
	@media (max-width: 720px) {
		.b24-gtiles { gap: 10px; }
		.b24-gtile { min-block-size: 110px; padding: 14px; border-radius: 16px; gap: 8px; }
		.b24-gtile h3 { font-size: 19px; }
		.b24-gtile::after { position: absolute; inset-block-start: 10px; inset-inline-end: 10px; inline-size: 32px; block-size: 32px; background-size: 16px; }
	}


	/* ---- Shop window (bento): placed by position, the first large on the left ---- */
	.b24-bento { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 16px; padding-block-start: 28px; }
	.b24-tile { position: relative; overflow: hidden; border-radius: var(--b24-r-panel); background: var(--b24-s1); }
	.b24-bento > * { grid-column: span 12; }
	.b24-bento > :nth-child(n + 3) { grid-column: span 6; }
	@media (min-width: 1241px) {
		.b24-bento { grid-template-rows: minmax(300px, auto) minmax(300px, auto); }
		.b24-bento > :nth-child(1) { grid-column: 1 / 7; grid-row: 1 / 3; }
		.b24-bento > :nth-child(2) { grid-column: 7 / 13; grid-row: 1; }
		.b24-bento > :nth-child(3) { grid-column: 7 / 10; grid-row: 2; }
		.b24-bento > :nth-child(4) { grid-column: 10 / 13; grid-row: 2; }
	}
	@media (max-width: 720px) {
		.b24-bento { padding-block-start: 16px; gap: 12px; }
		.b24-tile { border-radius: 20px; }
		.b24-bento > :nth-child(n + 3) { grid-column: span 12; }
	}

	.b24-week { display: grid; grid-template-columns: minmax(0, 11fr) minmax(0, 10fr); }
	.b24-week__stage {
		position: relative; overflow: hidden; display: flex; align-items: center; justify-content: center;
		padding: 28px 0 28px 40px; background: var(--b24-stage);
	}
	.b24-week__disc {
		position: absolute; inline-size: 74%; inset-inline-end: -22%; inset-block: auto;
		box-shadow: 0 20px 50px rgb(0 0 0 / .5); border-radius: 50%;
		transition: translate .8s cubic-bezier(.3, 0, .2, 1);
	}
	.b24-week__cover { position: relative; inline-size: 96%; aspect-ratio: 1; object-fit: cover; border-radius: 4px; box-shadow: var(--b24-shadow-cover); translate: -10% 0; }
	@media (hover: hover) { .b24-week:hover .b24-week__disc { translate: 16% 0; } }
	.b24r-no-disc .b24-week__disc { transition: none; }
	.b24-week__text { display: flex; flex-direction: column; gap: 16px; padding: 36px 36px 32px 8px; }
	.b24-week h2 { font-size: clamp(32px, 2.8vw, 46px); line-height: 1.02; letter-spacing: -.025em; overflow-wrap: break-word; }
	.b24-week h2.is-long { font-size: clamp(26px, 2.1vw, 34px); line-height: 1.06; letter-spacing: -.02em; }
	.b24-week h2.is-xlong { font-size: clamp(22px, 1.7vw, 28px); line-height: 1.1; letter-spacing: -.015em; }
	.b24-week h2 a { display: -webkit-box; -webkit-line-clamp: 4; -webkit-box-orient: vertical; overflow: hidden; text-decoration: none; }
	.b24-week__by { font-size: 19px; color: var(--b24-mut); }
	.b24-week__text p { color: var(--b24-tx2); }
	.b24-week dl { display: grid; grid-template-columns: auto 1fr; gap: 4px 16px; font-size: 15px; }
	.b24-week dt { color: var(--b24-mut); }
	.b24-week dd { font-family: var(--b24-font-mono); }
	.b24-week__buy { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; margin-block-start: auto; }
	.b24-pricebox--start { align-items: flex-start; text-align: start; }
	.b24-price--big { font-size: 32px; font-weight: 800; letter-spacing: -.02em; }
	@media (max-width: 720px) {
		.b24-week { grid-template-columns: minmax(0, 1fr); }
		.b24-week__stage { padding: 24px 24px 8px 40px; }
		.b24-week__cover { inline-size: 78%; }
		.b24-week__text { padding: 20px 20px 24px; }
	}

	.b24-tile--image { isolation: isolate; display: flex; flex-direction: column; justify-content: flex-end; min-block-size: 300px; padding: 26px; background: #141416; color-scheme: dark; color: var(--b24-ink); }
	.b24-tile__img { position: absolute; inset: 0; z-index: -2; inline-size: 100%; block-size: 100%; object-fit: cover; transition: scale .6s; }
	.b24-tile--image::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(180deg, rgb(20 20 22 / .55) 0%, rgb(20 20 22 / .9) 30%, rgb(20 20 22 / .96) 100%); }
	@media (hover: hover) { .b24-tile--image:hover > .b24-tile__img { scale: 1.04; } }
	:is(.b24-tile--image, .b24-tile--accent, .b24-tile--light) h2 { margin-block: 8px; font-size: clamp(26px, 2.2vw, 34px); line-height: 1.08; letter-spacing: -.02em; }
	:is(.b24-tile--image, .b24-tile--accent, .b24-tile--light) p { font-size: 16px; color: var(--b24-tx2); }
	.b24-tile__links { display: flex; flex-direction: column; align-items: flex-start; gap: 2px; margin-block-start: auto; padding-block-start: 16px; line-height: 1.3; }
	.b24-tile--image .b24-tile__links { margin-block-start: 12px; padding-block-start: 0; }
	.b24-tile__links a { display: inline-flex; align-items: center; gap: 8px; padding-block: 6px; font-weight: 800; color: var(--b24-accent-ink); text-decoration: none; }
	.b24-tile__links a::after, .b24-article__more::after { content: ""; inline-size: 18px; block-size: 18px; background: currentColor; mask: var(--b24-arrow) center / contain no-repeat; -webkit-mask: var(--b24-arrow) center / contain no-repeat; transition: translate .2s; }
	.b24-tile__links a:hover::after { translate: 4px 0; }
	.b24-tile--light { display: flex; flex-direction: column; padding: 26px; background: var(--b24-s2); border: 1px solid var(--b24-line); }
	.b24-tile--accent { display: flex; flex-direction: column; padding: 26px; background: var(--b24-accent); color: var(--b24-on-accent); }
	.b24-tile--accent p, .b24-tile--accent .b24-kicker { color: var(--b24-on-accent); }
	.b24-tile--accent :focus-visible { outline-color: var(--b24-on-accent); }
	.b24-tile--accent .b24-tile__links a { color: var(--b24-on-accent); padding-block: 8px; }

	.b24-showcase .b24-minitrust { display: flex; flex-wrap: wrap; gap: 10px 28px; padding: 18px 0 0; list-style: none; font-size: 15px; color: var(--b24-mut); }
	.b24-showcase .b24-minitrust li::before { content: ""; display: inline-block; inline-size: 6px; block-size: 6px; margin-inline-end: 10px; border-radius: 50%; background: var(--b24-accent); vertical-align: middle; }
	:root[data-theme="light"] .b24-showcase .b24-minitrust li::before { box-shadow: 0 0 0 1px var(--b24-ink); }

	/* ---- The crate: a horizontal shelf of tiles ---- */
	.b24-crate {
		display: grid; grid-auto-flow: column; grid-auto-columns: clamp(220px, 19vw, 280px); gap: 18px;
		overflow-x: auto; scroll-snap-type: x mandatory; padding-block-end: 14px;
		scrollbar-color: var(--b24-ctl) transparent;
	}
	.b24-crate[hidden] { display: none; }
	.b24-hint { margin-block-start: 6px; font-size: 14px; color: var(--b24-mut); }
	@media (max-width: 720px) { .b24-crate { grid-auto-columns: 64%; } }

	/* ---- Dig deeper ---- */
	.b24-tabpanel + .b24-tabpanel { margin-block-start: 48px; }
	.b24-tabpanel__title { margin-block-end: 14px; font: 500 14px var(--b24-font-mono); text-transform: uppercase; letter-spacing: .1em; color: var(--b24-mut); }
	.b24-tabs.is-ready .b24-tabpanel + .b24-tabpanel { margin-block-start: 0; }
	.b24-tabs.is-ready .b24-tabpanel__title { position: absolute; inline-size: 1px; block-size: 1px; overflow: hidden; clip-path: inset(50%); }
	.b24-labels { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 14px; }
	.b24-label, .b24-mood {
		display: flex; flex-direction: column; border: 1px solid var(--b24-line); border-radius: var(--b24-r-tile);
		background: var(--b24-s1); text-decoration: none; transition: translate .2s, border-color .2s;
	}
	.b24-label:hover, .b24-mood:hover { translate: 0 -4px; border-color: var(--b24-ctl); }
	.b24-label { justify-content: space-between; min-block-size: 190px; padding: 22px; }
	.b24-label__k { font: 500 14px var(--b24-font-mono); color: var(--b24-mut); text-transform: uppercase; letter-spacing: .08em; }
	.b24-label h3 { font-weight: 400; line-height: 1; overflow-wrap: break-word; }
	.b24-label--bold h3 { letter-spacing: -.04em; font: 800 34px var(--b24-font-sans); letter-spacing: -.04em; text-transform: uppercase; }
	.b24-label--serif h3 { font: italic 400 30px var(--b24-font-serif); }
	.b24-label--mono h3 { font: 500 40px var(--b24-font-mono); letter-spacing: .12em; }
	.b24-label--caps h3 { font: 700 24px var(--b24-font-sans); letter-spacing: .12em; text-transform: uppercase; }
	.b24-label--grand h3 { font: italic 400 38px var(--b24-font-serif); }
	.b24-label--light h3 { font: 300 30px var(--b24-font-sans); letter-spacing: .24em; text-transform: uppercase; }
	.b24-moods { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; }
	.b24-mood { justify-content: flex-end; gap: 6px; min-block-size: 200px; padding: 24px; }
	.b24-mood h3 { font: italic 400 40px/1 var(--b24-font-serif); letter-spacing: 0; }
	.b24-mood p { font-size: 15px; color: var(--b24-mut); }
	.b24-pills { display: flex; flex-wrap: wrap; gap: 12px; }
	.b24-pills__item {
		display: inline-flex; align-items: center; min-block-size: 64px; padding-inline: 26px;
		border: 1px solid var(--b24-line); border-radius: var(--b24-r-pill); background: var(--b24-s1);
		font-size: 24px; font-weight: 700; letter-spacing: -.02em; text-decoration: none;
		transition: background-color .2s, color .2s;
	}
	.b24-pills__item:hover { background: var(--b24-ink); color: var(--b24-on-ink); }
	@media (max-width: 1240px) { .b24-labels { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
	@media (max-width: 900px) { .b24-moods { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
	@media (max-width: 720px) {
		.b24-labels { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
		.b24-label { min-block-size: 140px; padding: 18px; }
		.b24-label--bold h3, .b24-label--mono h3, .b24-label--grand h3 { font-size: 28px; }
		.b24-label--serif h3, .b24-label--caps h3, .b24-label--light h3 { font-size: 22px; }
		.b24-moods { grid-template-columns: minmax(0, 1fr); gap: 10px; }
		.b24-mood { min-block-size: 130px; }
		.b24-mood h3 { font-size: 34px; }
		.b24-pills__item { min-block-size: 52px; font-size: 19px; padding-inline: 18px; }
	}

	/* ---- Stories ---- */
	.b24-ed { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: 20px; }
	.b24-article { display: flex; flex-direction: column; gap: 14px; }
	.b24-article__img { position: relative; overflow: hidden; aspect-ratio: 16 / 10; border-radius: var(--b24-r-tile); background: var(--b24-s1); }
	.b24-article__img img { inline-size: 100%; block-size: 100%; object-fit: cover; transition: scale .6s; }
	@media (hover: hover) { .b24-article:hover .b24-article__img img { scale: 1.03; } }
	.b24-article--main { gap: 14px; }
	.b24-article h3 { font-size: clamp(24px, 2.2vw, 34px); line-height: 1.12; letter-spacing: -.02em; }
	.b24-article p { color: var(--b24-tx2); }
	.b24-ed__side { display: flex; flex-direction: column; gap: 20px; }
	.b24-article--side { display: grid; grid-template-columns: 180px minmax(0, 1fr); gap: 18px; align-items: start; }
	.b24-article--side > .b24-article__img { aspect-ratio: 1; border-radius: 16px; }
	.b24-article--side h3 { font-size: 22px; }
	.b24-article--side p { font-size: 15px; }
	.b24-article__body { display: flex; flex-direction: column; gap: 4px; }
	.b24-article__body h3 { margin-block-end: 2px; }
	.b24-article .b24-article__more { display: inline-flex; align-items: center; gap: 8px; font-weight: 700; color: var(--b24-accent-ink); }
	/* Kickers in the stories are the accent, like everywhere in the design (.ar .kick). */
	.b24-article .b24-kicker { font: 500 14px var(--b24-font-mono); text-transform: uppercase; letter-spacing: .1em; color: var(--b24-accent-ink); }
	.b24-crate-sec .b24-card__grade { display: none; }
	.b24-quote { padding: 24px; border: 1px solid var(--b24-line); border-radius: var(--b24-r-tile); background: var(--b24-s1); text-decoration: none; }
	.b24-quote__t { margin-block: 8px; font: italic 400 26px/1.25 var(--b24-font-serif); letter-spacing: 0; }
	.b24-quote__sub { font-size: 15px; color: var(--b24-mut); }
	@media (max-width: 900px) { .b24-ed { grid-template-columns: minmax(0, 1fr); } }
	@media (max-width: 720px) { .b24-article--side { grid-template-columns: 110px minmax(0, 1fr); } }

/* Below the fold: not laid out until it nears the screen. */
.b24-home > :where(.b24-dig, .b24-stories, .b24-faq) { content-visibility: auto; contain-intrinsic-size: auto 640px; }

/* ---- Questions and answers ---- */
.b24-faq > * { max-inline-size: 860px; }
.b24-faq .b24-section__head { margin-block-end: 18px; }
.b24-faq h2 { font-size: clamp(30px, 3vw, 44px); letter-spacing: -.03em; line-height: 1.05; }
.b24-faq__item { border-block-end: 1px solid var(--b24-line); }
.b24-faq summary { display: flex; justify-content: space-between; gap: 16px; align-items: center; padding-block: 18px; font-size: 18px; font-weight: 700; cursor: pointer; list-style: none; }
.b24-faq summary::-webkit-details-marker { display: none; }
.b24-faq summary::after { content: ""; flex: none; inline-size: 20px; block-size: 20px; background: currentColor; mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E") center / contain no-repeat; -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E") center / contain no-repeat; transition: rotate .2s; }
.b24-faq details[open] summary::after { rotate: 180deg; }
.b24-faq__a p { padding-block-end: 18px; color: var(--b24-tx2); }
