The best way to control Claude Code, Codex and more from any computer or phone

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