:root {
  color-scheme: light;
  --ink: #202a42;
  --muted: #53617b;
  --accent: #444ac5;
  --border: #dbe0ec;
  --tint: #f2f4fb;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-padding-top: 1.5rem; }
body { margin: 0; background: #fff; color: var(--ink); line-height: 1.65; }
a { color: var(--accent); text-underline-offset: .2em; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; }

.skip-link {
  position: absolute;
  z-index: 1;
  top: -5rem;
  left: 1rem;
  padding: .6rem .9rem;
  background: #fff;
}

.skip-link:focus { top: .8rem; }
.site-header { border-bottom: 1px solid var(--border); }
.header-inner, .layout { width: min(100% - 3rem, 67rem); margin-inline: auto; }
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 1rem; min-height: 4.5rem; }
.wordmark { color: var(--ink); font-weight: 750; letter-spacing: -.035em; text-decoration: none; }
.wordmark span { margin-left: .42rem; padding-left: .58rem; border-left: 1px solid var(--border); color: var(--muted); font-size: .86rem; font-weight: 500; letter-spacing: 0; }
.open-app { padding: .35rem .7rem; border: 1px solid var(--border); border-radius: .45rem; font-size: .875rem; font-weight: 600; text-decoration: none; }
.open-app:hover { background: var(--tint); }

.layout {
  display: grid;
  grid-template-columns: minmax(0, 42rem) minmax(11rem, 1fr);
  gap: clamp(2rem, 7vw, 6rem);
  padding-block: clamp(2.3rem, 7vw, 5.2rem) 5rem;
}

main { min-width: 0; }
h1, h2 { margin: 0; letter-spacing: -.04em; line-height: 1.16; }
h1 { font-size: clamp(2.4rem, 6vw, 4rem); font-weight: 740; }
h2 { font-size: clamp(1.35rem, 3.5vw, 1.75rem); }
p { margin: .75rem 0; }
.intro { color: var(--muted); font-size: clamp(1.06rem, 2.3vw, 1.24rem); line-height: 1.55; margin: 1rem 0 2.5rem; max-width: 36rem; }
section { padding: 1.7rem 0 1.85rem; border-top: 1px solid var(--border); }
section:last-child { padding-bottom: 0; }
ol { padding-left: 1.4rem; margin: .75rem 0 1rem; }
li + li { margin-top: .42rem; }

code { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: .87em; }
:not(pre) > code { padding: .12em .3em; border-radius: .25rem; background: var(--tint); overflow-wrap: anywhere; }
pre { padding: .95rem 1rem; margin: .9rem 0; background: #1f2942; color: #f5f6ff; border-radius: .5rem; overflow-x: auto; line-height: 1.6; }
pre code { font-size: .85rem; }
.note, blockquote { margin: .9rem 0 0; padding: .8rem 1rem; background: var(--tint); border-left: 3px solid var(--accent); border-radius: 0 .38rem .38rem 0; }
.note p { margin: 0; font-size: .94rem; }
details { margin-top: .9rem; }
summary { cursor: pointer; width: fit-content; color: var(--accent); font-weight: 600; }
details p { margin-bottom: 0; }

.contents { align-self: start; position: sticky; top: 1.75rem; border-left: 1px solid var(--border); padding-left: 1.2rem; font-size: .9rem; }
.contents p { margin: 0; font-weight: 700; }
.contents ul { margin: .35rem 0 0; padding: 0; list-style: none; }
.contents a { color: var(--muted); text-decoration: none; }
.contents a:hover { color: var(--accent); text-decoration: underline; }

@media (max-width: 48rem) {
  .layout { grid-template-columns: minmax(0, 1fr); gap: 0; }
  .contents { display: none; }
}

@media (max-width: 27rem) {
  .header-inner, .layout { width: calc(100% - 2rem); }
  .header-inner { min-height: 3.8rem; }
}
