/* ========== Article ========== */

.section-article h2 {
	margin-top: 2em;
	scroll-margin-top: 80px;
}
.section-article h3 {
	margin-top: 1.6em;
}
.section-article h2 + p,
.section-article h3 + p,
.section-article h3 + ul {
	margin-top: 0.6em;
}
.section-article h1 {
	margin-bottom: 0.6em;
}
.section-article .typography-intro {
	margin-bottom: 1em;
}
.section-article p + p,
.section-article ul + p,
.section-article pre + p {
	margin-top: 0.8em;
}
.section-article .article-list {
	margin: 0.8em 0 0 1.25em;
}
.section-article .article-list li {
	margin-bottom: 0.6em;
}

/* ========== Go Further ========== */

.section-article.bg-light .column > h2:first-child {
	margin-top: 0;
}
.section-article ul.links + p,
.section-article.bg-light p + p {
	margin-top: 1.6em;
}
.section-article p + ul.links {
	margin-top: 0.6em;
}

/* ========== Hero Image ========== */

.section-article .article-hero {
	box-sizing: border-box;
	margin: 2.5em 0;
	padding: 56px 64px;
	border-radius: 18px;
	background-color: var(--bg-light-override, #f5f5f7);
}
/* The image has a white background: blend it into the gray panel in light mode, and use a white panel in dark mode */
.section-article .article-hero img {
	mix-blend-mode: multiply;
}
body[data-color-scheme="dark"] .section-article .article-hero {
	background-color: #fff;
}
body[data-color-scheme="dark"] .section-article .article-hero img {
	mix-blend-mode: normal;
}
/* Collapse the copy spacing on either side so the figure margin is the only gap */
.section-article .row:has(+ .article-hero) .column > :last-child {
	margin-bottom: 0;
}
.section-article .article-hero + .row .column > h2:first-child {
	margin-top: 0;
}
.section-content .row:has(+ .article-hero) > .column {
	padding-bottom: 0;
}
.section-content .article-hero + .row > .column {
	padding-top: 0;
}
.section-article .article-hero img {
	display: block;
}
@media only screen and (max-width: 734px) {
	.section-article .article-hero {
		width: 100vw;
		margin-inline-start: calc(50% - 50vw);
		padding: 32px 24px;
		border-radius: 0;
	}
}

/* ========== SDK Examples ========== */

.section-article .grid-sdk {
	margin-top: 3em;
}
.section-article .grid-sdk img {
	display: block;
	border-radius: 12px;
}
.section-article .grid-sdk h5 {
	margin-top: 0;
}
/* When stacked, put the heading and copy above each example image */
@media only screen and (max-width: 1068px) {
	.section-article .grid-sdk .grid-item:first-child {
		order: 2;
	}
}

/* ========== Code ========== */

.section-article code {
	font-family: "SF Mono", SFMono-Regular, ui-monospace, Menlo, monospace;
	font-size: 0.9em;
	overflow-wrap: anywhere;
}
.section-article pre.code-block {
	margin: 1em 0;
	padding: 1em 1.25em;
	border-radius: 12px;
	background-color: #f5f5f7;
	overflow-x: auto;
}
.section-article pre.code-block code {
	overflow-wrap: normal;
}
body[data-color-scheme="dark"] .section-article pre.code-block,
.theme-dark .section-article pre.code-block {
	background-color: rgba(255, 255, 255, 0.08);
}
