fix: mobile overflow — constrain pre blocks within viewport, allow internal scroll

This commit is contained in:
swaits committed 2026-04-08 17:31:25 -06:00
1 parent b68dd4d0e3
commit 6a35d3b844
1 file changed
+11 -2
+11 -2
View File
@@ -49,12 +49,21 @@
border-radius: 3px;
}
/* All pre blocks: stay within viewport, scroll content */
/* Prevent any content from blowing out the viewport width */
body {
overflow-x: hidden;
}
/* Pre blocks scroll their own content horizontally */
pre {
max-width: 100%;
overflow-x: auto;
}
/* Flex children containing pre blocks must be allowed to shrink */
li > div {
min-width: 0;
}
/* Shiki code blocks — match site card background */
.astro-code {
background-color: var(--color-bg-card) !important;