Open History to see the last commit
1/* Theme bridge: maps our --alc-* design tokens onto Starlight's --sl-color-*
2 tokens. Each --alc-* token already adapts per `[data-theme]` (see tokens.css),
3 so most of this mapping is mode-agnostic. The walnut neutral scale is the
4 exception — its numeric steps don't flip semantically, so we override the
5 gray scale and `--sl-color-black` per-mode below. */
6
7:root {
8 --sl-font: var(--alc-font-sans);
9 --sl-font-mono: var(--alc-font-mono);
10 --sl-font-headings: var(--alc-font-serif);
11 /* Widen the docs sidebar (Starlight default is 18rem) so long generated
12 provider entries (e.g. GitHubRepositoryEventSourcePolicy) don't wrap. */
13 --sl-sidebar-width: 20rem;
14 /* The docs header is two rows: the marketing nav (64px, matching landing
15 pages pixel-for-pixel) plus the horizontal docs tab bar below it (see
16 components/starlight/Header.astro). Starlight offsets the sidebar and
17 content by --sl-nav-height, so it covers both rows. */
18 --alc-nav-row-height: 4rem;
19 --alc-tabs-height: 2.5rem;
20 --sl-nav-height: calc(var(--alc-nav-row-height) + var(--alc-tabs-height));
21 --sl-nav-pad-x: 2rem;
22 --sl-nav-pad-y: 0;
23 /* Cap the whole docs shell (sidebar + content + TOC) and center it,
24 bun.com/nextjs-style, instead of pinning the sidebar and TOC to the
25 viewport edges on wide screens. */
26 --alc-shell-max: 96rem;
27 --alc-shell-gutter: max(0rem, calc((100vw - var(--alc-shell-max)) / 2));
28 color-scheme: light;
29}
30
31/* The tab row is desktop-only (mobile navigation lives in the hamburger
32 drawer's product switcher), so collapse its reserved height on mobile —
33 otherwise the header keeps a dead 2.5rem band where the row used to be.
34 Everything offset by --sl-nav-height (sidebar pane, content top,
35 scroll-padding, menu-button centering) follows automatically. */
36@media (max-width: 50rem) {
37 :root {
38 --alc-tabs-height: 0rem;
39 }
40}
41
42/* Starlight shows the sticky "On this page" bar everywhere below 72rem —
43 including the 50–72rem range where the tab bar and left sidebar are
44 already up, which reads as stray mobile chrome on a desktop layout.
45 Align it with the rest of the chrome: mobile-only (< 50rem). The
46 right-rail TOC still appears from 72rem, as before. */
47@media (min-width: 50rem) {
48 :root {
49 --sl-mobile-toc-height: 0rem;
50 }
51 mobile-starlight-toc {
52 display: none;
53 }
54}
55
56/* Faint accent wash across the top of the whole docs page — sidebar,
57 content, and TOC alike (bun.com-style), fading into the page background.
58 The fixed sidebar goes transparent on desktop so the wash shows through
59 it; on mobile it stays an opaque overlay. */
60.page {
61 background: linear-gradient(
62 to bottom,
63 color-mix(in srgb, var(--alc-accent) 5%, transparent),
64 transparent 24rem
65 );
66}
67
68@media (min-width: 50rem) {
69 /* Shift Starlight's fixed sidebar off the viewport edge by the gutter;
70 division comes from the hairline, not a contrasting panel color. */
71 .sidebar-pane {
72 inset-inline-start: var(--alc-shell-gutter);
73 background: transparent;
74 }
75 /* …offset the main column to match (Starlight derives the content inset
76 from this var)… */
77 [data-has-sidebar] .page {
78 --sl-content-inline-start: calc(
79 var(--sl-sidebar-width) + var(--alc-shell-gutter)
80 );
81 }
82 /* …and mirror the gutter on the right so the TOC pulls in too. */
83 .main-frame {
84 padding-inline-end: var(--alc-shell-gutter);
85 }
86 /* The fixed header keeps its full-width background; its content (nav row +
87 tab bar) is capped to the same shell. */
88 .alc-docs-header {
89 max-width: var(--alc-shell-max);
90 margin-inline: auto;
91 }
92}
93
94/* Pin Starlight's floating mobile hamburger to the first header row — it
95 centers itself against the full --sl-nav-height, which is now two rows. */
96starlight-menu-button button {
97 top: calc(
98 (var(--alc-nav-row-height) - var(--sl-menu-button-size)) / 2
99 ) !important;
100}
101
102/* The tab bar already links Docs and Blog on docs pages; the nav row's own
103 Docs/Blog text links are redundant there (they stay on marketing pages). */
104.alc-nav--docs .alc-nav__link:not(.alc-nav__link--icon) {
105 display: none;
106}
107
108/* On phones the 2rem desktop gutter is too generous: the docs header has to
109 fit the brand, the Docs/Blog links, the theme toggle AND the room Starlight
110 reserves on the right for its floating hamburger. Trim it to 1rem below the
111 `md` (50rem) breakpoint. `--sl-nav-pad-x` drives the header padding, the
112 hamburger inset and Starlight's reservation together, so they stay aligned
113 and the toggle clears the hamburger. */
114@media (max-width: 50rem) {
115 :root {
116 --sl-nav-pad-x: 1rem;
117 }
118}
119
120[data-theme="dark"] {
121 color-scheme: dark;
122}
123
124:root,
125[data-theme="dark"],
126[data-theme="light"] {
127 /* Page surfaces */
128 --sl-color-bg: var(--alc-bg);
129 --sl-color-bg-nav: var(--alc-bg-nav);
130 /* Sidebar shares the page background (bun.com-style: division comes from
131 the hairline + a faint gradient wash, not a contrasting panel). */
132 --sl-color-bg-sidebar: var(--alc-bg);
133 --sl-color-bg-inline-code: var(--alc-bg-sunk);
134 --sl-color-bg-accent: var(--alc-accent);
135
136 /* Walnut neutral scale — light-mode convention: gray-1 = darkest text,
137 gray-7 = lightest surface. Starlight's hero `.tagline`, body copy,
138 and muted prose all read off this scale.
139
140 IMPORTANT: Starlight uses `--sl-color-white` as the darkest text token
141 and `--sl-color-black` as the lightest surface token in light mode
142 (the names refer to their dark-mode roles; the values flip in light).
143 The mobile sidebar pane and mobile TOC dropdown both paint their
144 background with `--sl-color-black`, so it MUST resolve to a light
145 surface — otherwise we get dark walnut text on a dark walnut panel. */
146 --sl-color-white: var(--alc-fg-1);
147 --sl-color-black: var(--alc-bg-nav);
148 --sl-color-gray-1: var(--alc-walnut-900);
149 --sl-color-gray-2: var(--alc-walnut-700);
150 --sl-color-gray-3: var(--alc-walnut-600);
151 --sl-color-gray-4: var(--alc-walnut-500);
152 --sl-color-gray-5: var(--alc-walnut-300);
153 --sl-color-gray-6: var(--alc-walnut-100);
154 --sl-color-gray-7: var(--alc-bg-nav);
155
156 /* Text */
157 --sl-color-text: var(--alc-fg-2);
158 --sl-color-text-accent: var(--alc-accent-deep);
159 --sl-color-text-invert: var(--alc-fg-invert);
160
161 /* Accent (moss) */
162 --sl-color-accent: var(--alc-accent);
163 --sl-color-accent-high: var(--alc-accent-deep);
164 --sl-color-accent-low: var(--alc-accent-12);
165 --sl-color-accent-light: var(--alc-accent-40);
166
167 /* Hairlines */
168 --sl-color-hairline-light: var(--alc-hairline);
169 --sl-color-hairline: var(--alc-hairline-2);
170 --sl-color-hairline-shade: var(--alc-hairline-3);
171
172 /* Selection */
173 --sl-color-selection-bg: var(--alc-accent-soft);
174 --sl-color-selection-text: var(--alc-fg-1);
175}
176
177/* Dark mode: flip the walnut gray scale so gray-1 = lightest text and
178 gray-7 = darkest surface (Starlight's convention, with the values inverted).
179 `--sl-color-black` is reused by Starlight as the mobile sidebar and TOC
180 panel background, so it must resolve to a surface that is *visible* against
181 the page bg — we use bg-elev-1 (one step lifted from the page). */
182[data-theme="dark"] {
183 --sl-color-white: var(--alc-fg-1);
184 --sl-color-black: var(--alc-bg-elev-1);
185 --sl-color-gray-1: var(--alc-walnut-50);
186 --sl-color-gray-2: var(--alc-walnut-200);
187 --sl-color-gray-3: var(--alc-walnut-300);
188 --sl-color-gray-4: var(--alc-walnut-400);
189 --sl-color-gray-5: var(--alc-walnut-700);
190 --sl-color-gray-6: var(--alc-walnut-800);
191 --sl-color-gray-7: var(--alc-bg-nav);
192 /* Starlight paints the selected sidebar entry with `--sl-color-text-accent`
193 as background and `--sl-color-text-invert` as text. In dark mode the
194 accent lifts to a bright lime (`--alc-accent-deep` ≈ #a3c473) — cream
195 (`--alc-fg-invert`) on lime is ~1.7:1, well below AA. Flip the invert
196 token to the dark page background so the selected pill reads as dark
197 text on lime (~10:1, AAA). */
198 --sl-color-text-invert: var(--alc-bg);
199}
200
201/* ── Headings: serif for h1/h2, sans for h3/h4 (matches alc-h* scale) ── */
202.sl-markdown-content :is(h1, h2),
203h1.hero-title,
204.hero h1 {
205 font-family: var(--alc-font-serif);
206 font-weight: 500;
207 letter-spacing: -0.015em;
208 color: var(--alc-fg-1);
209}
210.sl-markdown-content :is(h3, h4, h5, h6) {
211 font-family: var(--alc-font-sans);
212 font-weight: 600;
213 letter-spacing: -0.01em;
214 color: var(--alc-fg-1);
215}
216
217/* ── Hero "Effects" italic-serif accent ── deep moss, the design-system
218 "alc-text-accent" treatment used in the Claude landing variants. */
219.text-gradient {
220 font-family: var(--alc-font-serif);
221 font-style: italic;
222 font-weight: 500;
223 color: var(--alc-accent-deep);
224 background: none;
225 -webkit-text-fill-color: currentColor;
226}
227
228/* ── Starlight hero refinements (splash template) ── */
229.hero h1 {
230 font-family: var(--alc-font-serif);
231 font-weight: 500;
232 font-size: clamp(44px, 7vw, 76px);
233 line-height: 1.02;
234 letter-spacing: -0.02em;
235 color: var(--alc-fg-1);
236}
237.hero .tagline {
238 font-family: var(--alc-font-sans);
239 font-size: clamp(17px, 1.8vw, 20px);
240 line-height: 1.55;
241 color: var(--alc-fg-2);
242 max-width: 36rem;
243}
244.hero .actions a[data-variant="primary"] {
245 background: var(--alc-accent);
246 color: var(--alc-fg-on-accent);
247 border-color: var(--alc-accent);
248}
249.hero .actions a[data-variant="primary"]:hover {
250 background: var(--alc-accent-deep);
251 border-color: var(--alc-accent-deep);
252 color: var(--alc-fg-on-accent);
253}
254.hero .actions a[data-variant="secondary"] {
255 background: transparent;
256 color: var(--alc-fg-1);
257 border: 1px solid var(--alc-hairline-3);
258}
259.hero .actions a[data-variant="secondary"]:hover {
260 background: var(--alc-bg-elev-1);
261 border-color: var(--alc-accent);
262 color: var(--alc-fg-1);
263}
264
265/* ── Section eyebrow (mono uppercase, deep moss) ── */
266.section-eyebrow {
267 font-family: var(--alc-font-mono);
268 font-size: 12px;
269 line-height: 1;
270 letter-spacing: 0.12em;
271 text-transform: uppercase;
272 font-weight: 500;
273 color: var(--alc-accent-deep);
274 display: block;
275 margin: 0 0 0.75rem;
276}
277
278/* Serif H2 for section headers on the landing page. */
279.section-title {
280 font-family: var(--alc-font-serif);
281 font-size: clamp(28px, 3vw, 34px);
282 line-height: 1.15;
283 letter-spacing: -0.01em;
284 font-weight: 500;
285 color: var(--alc-fg-1);
286 margin: 0 0 1rem;
287}
288.section-lede {
289 font-family: var(--alc-font-sans);
290 font-size: 1rem;
291 line-height: 1.65;
292 color: var(--alc-fg-2);
293 max-width: 36rem;
294 margin: 0 auto 2.25rem;
295}
296
297/* Centered intro block above a section grid (features, providers, etc). */
298.section-intro {
299 text-align: center;
300 max-width: 48rem;
301 margin: 0 auto 3rem;
302}
303.section-intro .section-lede {
304 margin-bottom: 0;
305}
306
307/* ── Landing page ── */
308
309.landing {
310 max-width: 72rem;
311 margin: 0 auto;
312 padding: 0 1.5rem;
313}
314.landing :is(pre, .expressive-code, figure) {
315 max-width: 100%;
316 overflow-x: auto;
317}
318.landing pre code {
319 white-space: pre;
320}
321/* Allow grid/flex items to shrink below their content width so long code blocks
322 scroll internally instead of forcing the page wider than the viewport. */
323.hero-code-grid > *,
324.features > *,
325.provider-grid > * {
326 min-width: 0;
327}
328.landing {
329 overflow-x: clip;
330}
331/* Hide the auto-generated heading anchor link icon on the landing page —
332 these are marketing headings, not navigable anchors. */
333.landing .sl-anchor-link {
334 display: none;
335}
336@media (max-width: 480px) {
337 .landing {
338 padding: 0 1rem;
339 }
340}
341@media (max-width: 640px) {
342 .landing pre code {
343 font-size: 0.8rem;
344 line-height: 1.5;
345 }
346 .hero-code {
347 margin: 2.5rem 0 3rem;
348 }
349 .hero-code-grid {
350 gap: 1.25rem;
351 }
352 .hero-code-text h3 {
353 font-size: 1.35rem;
354 margin-bottom: 0.75rem;
355 }
356 .hero-code-text p {
357 font-size: 0.95rem;
358 }
359 .features {
360 gap: 1.75rem;
361 margin-bottom: 3rem;
362 }
363 .feature h3 {
364 font-size: 1.05rem;
365 }
366 .providers-section {
367 margin-bottom: 3rem;
368 }
369 .providers-section h3,
370 .cta-section h3 {
371 font-size: 1.25rem;
372 }
373 .cta-section {
374 padding: 2rem 0 2.5rem;
375 }
376}
377@media (max-width: 420px) {
378 .cta-buttons {
379 flex-direction: column;
380 align-items: stretch;
381 }
382 .cta-buttons > * {
383 justify-content: center;
384 text-align: center;
385 }
386}
387
388/* ── Hero overrides: center on mobile/tablet, keep 3 actions on one row ── */
389
390@media (max-width: 60rem) {
391 .hero .stack {
392 text-align: center;
393 }
394 .hero .copy {
395 align-items: center;
396 }
397 .hero .copy > * {
398 margin-inline: auto;
399 }
400 .hero .actions {
401 justify-content: center;
402 gap: 0.75rem;
403 }
404 .hero .actions > a {
405 padding-inline: 1rem;
406 }
407}
408
409@media (max-width: 30rem) {
410 .hero .actions {
411 gap: 0.5rem;
412 }
413 .hero .actions > a {
414 padding-inline: 0.75rem;
415 font-size: 0.9rem;
416 }
417}
418
419.hero-code {
420 margin: 2rem 0 5rem;
421}
422.hero-code-grid {
423 display: grid;
424 grid-template-columns: 1fr 1fr;
425 gap: 3rem;
426 align-items: center;
427}
428.hero-code-text h3 {
429 font-family: var(--alc-font-serif);
430 font-size: 1.75rem;
431 font-weight: 500;
432 letter-spacing: -0.015em;
433 margin: 0 0 1rem;
434 color: var(--alc-fg-1);
435}
436.hero-code-text p {
437 color: var(--alc-fg-2);
438 line-height: 1.7;
439 margin: 0 0 0.75rem;
440}
441@media (max-width: 768px) {
442 .hero-code-grid {
443 grid-template-columns: 1fr;
444 gap: 2rem;
445 }
446}
447
448/* Features grid: .feature uses display: contents so each feature's three
449 children (heading / body / code) become direct grid items of .features.
450 We then explicitly pin each child to a grid row and column. This guarantees
451 headings, paragraphs, and code blocks all align across the two columns in
452 a visual row, regardless of content height. */
453.features {
454 display: grid;
455 grid-template-columns: 1fr 1fr;
456 column-gap: 3rem;
457 row-gap: 0.75rem;
458 margin: 0 0 5rem;
459}
460.feature {
461 display: contents;
462}
463.features > .feature > * {
464 margin: 0 !important;
465 min-width: 0;
466}
467.features > .feature > :nth-child(1) {
468 /* heading row */
469 font-family: var(--alc-font-sans);
470 font-size: 1.15rem;
471 font-weight: 600;
472 color: var(--alc-fg-1);
473}
474.features > .feature > :nth-child(2) {
475 /* body row */
476 color: var(--alc-fg-2);
477 line-height: 1.6;
478 font-size: 0.95rem;
479}
480.features > .feature > :nth-child(3) {
481 /* code row – anchor to the top of the row so terminals and code blocks
482 sit directly under the paragraph, regardless of snippet height. */
483 align-self: start;
484 width: 100%;
485}
486
487/* Explicit row/column placement for each of the 6 features.
488 Visual row 1 (features 1,2) occupies grid rows 1-3,
489 visual row 2 (features 3,4) occupies rows 5-7 (row 4 is the gap),
490 visual row 3 (features 5,6) occupies rows 9-11 (row 8 is the gap). */
491.features > .feature:nth-of-type(odd) > * {
492 grid-column: 1;
493}
494.features > .feature:nth-of-type(even) > * {
495 grid-column: 2;
496}
497
498.features > .feature:nth-of-type(1) > :nth-child(1),
499.features > .feature:nth-of-type(2) > :nth-child(1) {
500 grid-row: 1;
501}
502.features > .feature:nth-of-type(1) > :nth-child(2),
503.features > .feature:nth-of-type(2) > :nth-child(2) {
504 grid-row: 2;
505}
506.features > .feature:nth-of-type(1) > :nth-child(3),
507.features > .feature:nth-of-type(2) > :nth-child(3) {
508 grid-row: 3;
509}
510
511.features > .feature:nth-of-type(3) > :nth-child(1),
512.features > .feature:nth-of-type(4) > :nth-child(1) {
513 grid-row: 5;
514}
515.features > .feature:nth-of-type(3) > :nth-child(2),
516.features > .feature:nth-of-type(4) > :nth-child(2) {
517 grid-row: 6;
518}
519.features > .feature:nth-of-type(3) > :nth-child(3),
520.features > .feature:nth-of-type(4) > :nth-child(3) {
521 grid-row: 7;
522}
523
524.features > .feature:nth-of-type(5) > :nth-child(1),
525.features > .feature:nth-of-type(6) > :nth-child(1) {
526 grid-row: 9;
527}
528.features > .feature:nth-of-type(5) > :nth-child(2),
529.features > .feature:nth-of-type(6) > :nth-child(2) {
530 grid-row: 10;
531}
532.features > .feature:nth-of-type(5) > :nth-child(3),
533.features > .feature:nth-of-type(6) > :nth-child(3) {
534 grid-row: 11;
535}
536
537/* Larger gap between visual rows via empty tracks 4 and 8. */
538.features {
539 grid-template-rows: auto auto auto /* row 1: h, p, code */
540 3rem /* gap */
541 auto auto auto /* row 2 */
542 3rem /* gap */
543 auto auto auto; /* row 3 */
544}
545
546@media (max-width: 768px) {
547 /* Collapse to single column: each .feature stacks naturally. */
548 .features {
549 grid-template-columns: 1fr;
550 grid-template-rows: none;
551 row-gap: 2.5rem;
552 }
553 .feature {
554 display: flex;
555 flex-direction: column;
556 gap: 0.75rem;
557 }
558 .features > .feature > * {
559 grid-row: auto !important;
560 grid-column: auto !important;
561 }
562}
563
564.providers-section {
565 margin: 0 0 5rem;
566 text-align: center;
567}
568.providers-section h3 {
569 font-family: var(--alc-font-serif);
570 font-size: 1.75rem;
571 font-weight: 500;
572 letter-spacing: -0.015em;
573 color: var(--alc-fg-1);
574 margin: 0 0 1rem;
575}
576.providers-section > p {
577 color: var(--alc-fg-2);
578 max-width: 36rem;
579 margin: 0 auto 2rem;
580 line-height: 1.6;
581}
582.provider-grid {
583 display: grid;
584 grid-template-columns: repeat(3, 1fr);
585 gap: 1.5rem;
586 align-items: stretch;
587}
588.provider-card {
589 display: flex;
590 flex-direction: column;
591 gap: 0.5rem;
592 background: var(--alc-bg-elev-1);
593 border: 1px solid var(--alc-hairline-2);
594 border-radius: var(--alc-radius);
595 padding: 1.5rem;
596 text-align: left;
597 height: 100%;
598 box-shadow: var(--alc-shadow-sm);
599 transition:
600 border-color var(--alc-dur) var(--alc-ease),
601 box-shadow var(--alc-dur) var(--alc-ease);
602}
603.provider-card:hover {
604 border-color: var(--alc-accent);
605 box-shadow: var(--alc-shadow);
606}
607.provider-card > * {
608 margin: 0;
609}
610.provider-card strong {
611 color: var(--alc-fg-1);
612 font-size: 1.05rem;
613 font-weight: 600;
614}
615.provider-card p {
616 color: var(--alc-fg-2);
617 font-size: 0.9rem;
618 line-height: 1.5;
619}
620@media (max-width: 768px) {
621 .provider-grid {
622 grid-template-columns: 1fr;
623 }
624}
625
626/* 4-column variant for the AB-test "Explore alternate framings" cards. */
627.explore-section .provider-grid {
628 grid-template-columns: repeat(4, 1fr);
629}
630.explore-section a.provider-card {
631 text-decoration: none;
632 color: inherit;
633}
634@media (max-width: 1024px) {
635 .explore-section .provider-grid {
636 grid-template-columns: repeat(2, 1fr);
637 }
638}
639@media (max-width: 540px) {
640 .explore-section .provider-grid {
641 grid-template-columns: 1fr;
642 }
643}
644
645.cta-section {
646 text-align: center;
647 padding: 3rem 0 4rem;
648 border-top: 1px solid var(--alc-hairline-2);
649}
650.cta-section h3 {
651 font-family: var(--alc-font-serif);
652 font-size: 1.75rem;
653 font-weight: 500;
654 letter-spacing: -0.015em;
655 color: var(--alc-fg-1);
656 margin: 0 0 1rem;
657}
658.cta-section > p {
659 color: var(--alc-fg-2);
660 max-width: 36rem;
661 margin: 0 auto 2rem;
662 line-height: 1.6;
663}
664.cta-buttons {
665 display: flex;
666 gap: 1rem;
667 justify-content: center;
668 flex-wrap: wrap;
669}
670/* Neutralize Starlight's default LinkButton margins inside .sl-markdown-content
671 so our flex container controls spacing. */
672.cta-buttons .sl-link-button,
673.cta-buttons > p {
674 margin: 0 !important;
675}
676.cta-buttons > p {
677 display: contents;
678}
679/* MDX wraps loose JSX children in <p> (and sometimes emits an empty
680 <p> sibling when JSX sits between paragraphs). Use :has() to flatten
681 any paragraph that contains an `.alc-btn`, and hide empty wrapper
682 paragraphs anywhere inside the outro CTA — the User Agent's default
683 1em block margin on those empty <p>s is what was making the
684 "Read the tutorial" row look chunky. */
685p:has(> .alc-btn) {
686 margin: 0;
687 display: contents;
688}
689.alc-cta > p:empty {
690 display: none;
691}
692
693/* ── Getting Started next-steps cards ── */
694
695.next-steps {
696 display: grid;
697 grid-template-columns: 1fr 1fr;
698 gap: 1rem;
699 margin-top: 1rem;
700}
701.next-card {
702 display: block;
703 padding: 1.25rem 1.5rem;
704 background: var(--alc-bg-elev-1);
705 border: 1px solid var(--alc-hairline-2);
706 border-radius: var(--alc-radius);
707 text-decoration: none;
708 transition:
709 border-color var(--alc-dur) var(--alc-ease),
710 box-shadow var(--alc-dur) var(--alc-ease);
711 box-shadow: var(--alc-shadow-sm);
712}
713.next-card:hover {
714 border-color: var(--alc-accent);
715 box-shadow: var(--alc-shadow);
716}
717.next-card strong {
718 display: block;
719 color: var(--alc-fg-1);
720 font-size: 1.05rem;
721 font-weight: 600;
722 margin-bottom: 0.35rem;
723}
724.next-card span {
725 color: var(--alc-fg-2);
726 font-size: 0.9rem;
727 line-height: 1.5;
728}
729@media (max-width: 600px) {
730 .next-steps {
731 grid-template-columns: 1fr;
732 }
733}
734
735/* ============================================================
736 Starlight Asides (Note / Tip / Caution / Danger)
737
738 Starlight's defaults use saturated info-blue / yellow / red
739 panels that clash with the warm parchment + moss palette.
740 Override to match the design-system callout spec from
741 claude/design-system/preview/components-callouts.html:
742 - tip: moss green
743 - note: slate teal (--alc-info)
744 - caution: honey amber (--alc-warn)
745 - danger: brick red (--alc-danger)
746 ============================================================ */
747
748.sl-markdown-content .starlight-aside {
749 border-radius: 8px;
750 border-width: 1px;
751 border-style: solid;
752 padding: 12px 14px;
753 margin: 1rem 0;
754 background: var(--aside-tint, var(--alc-bg-elev-1));
755 border-color: var(--aside-border, var(--alc-hairline-2));
756 color: var(--alc-fg-2);
757 font-family: var(--alc-font-sans);
758}
759
760.sl-markdown-content .starlight-aside__title {
761 color: var(--aside-accent, var(--alc-fg-1));
762 font-family: var(--alc-font-sans);
763 font-weight: 600;
764 font-size: 13.5px;
765 letter-spacing: 0;
766 text-transform: none;
767 display: flex;
768 align-items: center;
769 gap: 8px;
770}
771
772.sl-markdown-content .starlight-aside__icon {
773 color: var(--aside-accent, var(--alc-fg-1));
774 font-size: 1rem;
775}
776
777.sl-markdown-content .starlight-aside__content {
778 color: var(--alc-fg-2);
779 font-size: 14px;
780 line-height: 1.55;
781}
782.sl-markdown-content .starlight-aside__content > :first-child {
783 margin-top: 4px;
784}
785.sl-markdown-content .starlight-aside__content > :last-child {
786 margin-bottom: 0;
787}
788.sl-markdown-content .starlight-aside__content a {
789 color: var(--aside-accent, var(--alc-accent-deep));
790 text-decoration: underline;
791 text-underline-offset: 2px;
792}
793.sl-markdown-content .starlight-aside__content a:hover {
794 color: var(--alc-accent-deep);
795}
796/* Inline-code only — must NOT match the per-token <code> elements that
797 Expressive Code emits inside <pre>, otherwise the dark walnut code-block
798 background and bright sunrise syntax tokens get repainted to cream + walnut
799 and the whole block bleaches out. */
800.sl-markdown-content .starlight-aside__content :not(pre) > code {
801 background: var(--alc-bg-sunk);
802 border: 1px solid var(--alc-hairline);
803 color: var(--alc-fg-1);
804}
805.sl-markdown-content .starlight-aside__content strong {
806 color: var(--alc-fg-1);
807}
808
809/* ── Variants ── */
810.sl-markdown-content .starlight-aside--note {
811 --aside-accent: var(--alc-info);
812 --aside-tint: color-mix(in srgb, var(--alc-info) 14%, transparent);
813 --aside-border: color-mix(in srgb, var(--alc-info) 45%, transparent);
814}
815.sl-markdown-content .starlight-aside--tip {
816 --aside-accent: var(--alc-accent-deep);
817 --aside-tint: color-mix(in srgb, var(--alc-accent) 14%, transparent);
818 --aside-border: color-mix(in srgb, var(--alc-accent) 45%, transparent);
819}
820.sl-markdown-content .starlight-aside--caution {
821 --aside-accent: color-mix(in srgb, var(--alc-warn) 75%, var(--alc-fg-1));
822 --aside-tint: color-mix(in srgb, var(--alc-warn) 16%, transparent);
823 --aside-border: color-mix(in srgb, var(--alc-warn) 50%, transparent);
824}
825.sl-markdown-content .starlight-aside--danger {
826 --aside-accent: var(--alc-danger);
827 --aside-tint: color-mix(in srgb, var(--alc-danger) 14%, transparent);
828 --aside-border: color-mix(in srgb, var(--alc-danger) 45%, transparent);
829}
830
831/* ============================================================
832 Expressive Code frames (the file-name tab on docs code blocks)
833
834 The default Starlight rendering of the editor-style frame paints
835 the tab title with a very low-contrast walnut on a near-walnut
836 strip — practically unreadable on the cream page. Force the
837 active tab to use the bright sunrise palette so the file name
838 reads cleanly against the dark code surface.
839 ============================================================ */
840
841.expressive-code .frame {
842 --ec-frm-edBg: var(--alc-bg-code);
843 --ec-frm-edTabBarBg: var(--alc-bg-code);
844 --ec-frm-edTabBarBrdBtmCol: var(--alc-walnut-700);
845 --ec-frm-edActTabBg: var(--alc-bg-code);
846 --ec-frm-edActTabFg: var(--alc-walnut-100);
847 --ec-frm-edActTabBrdCol: var(--alc-walnut-700);
848 --ec-frm-edActTabIndTopCol: var(--alc-accent-warm);
849 --ec-frm-edActTabIndBtmCol: transparent;
850 --ec-frm-edTabsMargBlkStart: 0;
851 --ec-frm-edTabsMargInlStart: 0;
852 --ec-frm-trmTtbBg: var(--alc-bg-code);
853 --ec-frm-trmTtbBrdBtmCol: var(--alc-walnut-700);
854 --ec-frm-trmTtbFg: var(--alc-walnut-100);
855}
856
857.expressive-code .frame.has-title:not(.is-terminal) .title {
858 color: var(--alc-walnut-100);
859 font-family: var(--alc-font-mono);
860 font-weight: 500;
861}
862
863.expressive-code .frame.is-terminal .title {
864 color: var(--alc-walnut-100);
865}
866
867/* ============================================================
868 Starlight Tabs (Code/Tabs component used on Getting Started
869 for bun / npm / pnpm / yarn).
870
871 - Tab labels use a soft mushroom for inactive and deep moss
872 for the active tab; the active underline is the moss accent.
873 - Icons are sized larger (1.25em) and painted with each
874 product's official brand color via positional selectors
875 (the package-manager tab order is bun → npm → pnpm → yarn,
876 and is consistent across the docs).
877 ============================================================ */
878
879starlight-tabs [role="tablist"] {
880 border-bottom-color: var(--alc-hairline-2);
881}
882
883starlight-tabs [role="tab"] {
884 color: var(--alc-fg-3);
885 font-family: var(--alc-font-sans);
886 font-size: 14px;
887 font-weight: 500;
888 letter-spacing: 0;
889 border-bottom-color: transparent;
890 gap: 0.45rem;
891 transition:
892 color 160ms ease,
893 border-color 160ms ease;
894}
895
896starlight-tabs [role="tab"]:hover {
897 color: var(--alc-accent-deep);
898}
899
900starlight-tabs [role="tab"][aria-selected="true"] {
901 color: var(--alc-accent-deep);
902 border-bottom-color: var(--alc-accent);
903}
904
905/* Icon sizing — undo Starlight's tight 1em so the package-manager
906 marks read at glance, and lock dimensions so the SVG can't shrink
907 below this when the tab text is small. */
908starlight-tabs [role="tab"] > svg {
909 width: 1.25em;
910 height: 1.25em;
911 flex: 0 0 auto;
912 font-size: inherit;
913}
914
915/* ── Per-package brand colors ──
916 The Tabs.astro markup wraps each tab anchor in <li class="tab">,
917 so we color the SVG icon inside each LI by position. Order on
918 our docs is bun(1), npm(2), pnpm(3), yarn(4). Colors come from
919 each project's brand guidelines, tuned slightly for contrast
920 on the warm cream surface. */
921
922/* Bun: Starlight's built-in `bun` icon is a single-path silhouette —
923 painting it any single color loses the eyes, cheeks and mouth that
924 make the mascot recognizable. We hide that path and overlay the
925 official multi-color mascot from bun.com/logo.svg (saved locally as
926 /bun-logo.svg) via a background image. */
927starlight-tabs [role="tablist"] > li:nth-child(1) [role="tab"] > svg {
928 color: transparent;
929 background-image: url("/bun-logo.svg");
930 background-repeat: no-repeat;
931 background-position: center;
932 background-size: contain;
933}
934starlight-tabs [role="tablist"] > li:nth-child(2) [role="tab"] > svg {
935 color: #cb3837; /* npm — npm red */
936}
937starlight-tabs [role="tablist"] > li:nth-child(3) [role="tab"] > svg {
938 color: #f59f00; /* pnpm — orange */
939}
940starlight-tabs [role="tablist"] > li:nth-child(4) [role="tab"] > svg {
941 color: #2c8ebb; /* yarn — yarn blue */
942}
943
944/* Match Starlight's docs <header> chrome to the marketing <header>: same
945 translucent cream + backdrop-blur + hairline border. Defined in custom.css
946 (rather than scoped to a single component) so the docs layout picks it up
947 without a Page/Header override.
948
949 IMPORTANT: must be scoped to the <header> element, not bare `.header`.
950 Expressive Code emits a <div class="header"> for its terminal titlebar
951 inside every shell/sh code block, and an unscoped `.header` rule with
952 !important repaints that titlebar in cream parchment instead of the
953 intended dark walnut, leaving an ugly cream strip above shell snippets. */
954header.header {
955 /* Same surface as the page + sidebar (bun.com-style — hairlines divide,
956 not contrasting panels), translucent for the blur under scroll. */
957 background: color-mix(in srgb, var(--alc-bg) 92%, transparent) !important;
958 backdrop-filter: saturate(140%) blur(8px);
959 border-bottom: 1px solid var(--alc-hairline) !important;
960}
961
962/* ── Docs sidebar: elide long entries with an ellipsis instead of wrapping
963 onto a second line (the generated provider pages have long names like
964 GitHubRepositoryEventSourcePolicy). ── */
965.sidebar-content a {
966 display: block;
967 white-space: nowrap;
968 overflow: hidden;
969 text-overflow: ellipsis;
970}
971
972/* ── Docs sidebar restyle (redesign mockups): small-caps group headings,
973 flat sections instead of accordion rows, active page = accent bar +
974 tinted background instead of a filled pill. ── */
975
976/* Group labels read as small-caps section headings. */
977#starlight__sidebar .top-level > li > details > summary .group-label .large {
978 font-size: 11px;
979 font-weight: 600;
980 letter-spacing: 0.07em;
981 text-transform: uppercase;
982 color: var(--alc-fg-4);
983}
984#starlight__sidebar .top-level > li > details {
985 margin-top: 0.9rem;
986}
987
988/* Hub-tab groups contain only links — render them as flat, always-open
989 sections: no caret, no collapse affordance. Reference's provider groups
990 nest further groups (categories → services) and keep the caret. */
991#starlight__sidebar .top-level > li > details:not(:has(details)) > summary {
992 pointer-events: none;
993}
994#starlight__sidebar
995 .top-level
996 > li
997 > details:not(:has(details))
998 > summary
999 .caret {
1000 display: none;
1001}
1002
1003/* Entries: tighter and smaller, with a reserved rail for the accent bar. */
1004#starlight__sidebar .sidebar-content a {
1005 font-size: 13px;
1006 padding-block: 0.22rem;
1007 border-inline-start: 3px solid transparent;
1008 border-radius: 0;
1009}
1010#starlight__sidebar .sidebar-content a.large {
1011 font-size: 13px;
1012 font-weight: 400;
1013 color: var(--sl-color-gray-2);
1014}
1015#starlight__sidebar .sidebar-content a:hover {
1016 color: var(--alc-accent-deep);
1017}
1018
1019/* Nested group labels (Resources categories/services, the Reference tree)
1020 read like regular entries, not headings — only top-level group summaries
1021 get the small-caps heading treatment above. */
1022#starlight__sidebar .sidebar-content ul ul .group-label .large {
1023 font-size: 13px;
1024 font-weight: 400;
1025 color: var(--sl-color-gray-2);
1026}
1027#starlight__sidebar .sidebar-content ul ul summary:hover .group-label .large {
1028 color: var(--alc-accent-deep);
1029}
1030
1031/* Active page: left accent bar + tint, mockup-style. */
1032#starlight__sidebar .sidebar-content a[aria-current="page"] {
1033 background: var(--alc-accent-12);
1034 color: var(--alc-accent-deep);
1035 border-inline-start-color: var(--alc-accent-deep);
1036 font-weight: 500;
1037}