:root {
  color-scheme: light dark;
  --accent: #5b47e0;
  --accent-soft: rgba(91, 71, 224, 0.10);
  --bg: #f8f8fc;
  --text: #171717;
  --muted: #74716a;
  --line: rgba(23, 23, 23, 0.12);
  --panel: rgba(255, 255, 255, 0.72);
  --panel-strong: rgba(255, 255, 255, 0.86);
  --panel-border: rgba(23, 23, 23, 0.08);
  --shadow: rgba(40, 35, 70, 0.055);
  --code-bg: rgba(91, 71, 224, 0.085);
  --chip-bg: rgba(23, 23, 23, 0.055);
  --body-glow: rgba(91, 71, 224, 0.10);
  --body-wash: rgba(91, 71, 224, 0.035);
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", sans-serif;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

@media (prefers-color-scheme: dark) {
  :root {
    --accent: #a89bff;
    --accent-soft: rgba(168, 155, 255, 0.14);
    --bg: #121117;
    --text: #f0edf9;
    --muted: #bab8cc;
    --line: rgba(240, 237, 249, 0.16);
    --panel: rgba(37, 34, 48, 0.68);
    --panel-strong: rgba(47, 43, 62, 0.82);
    --panel-border: rgba(240, 237, 249, 0.10);
    --shadow: rgba(0, 0, 0, 0.18);
    --code-bg: rgba(168, 155, 255, 0.13);
    --chip-bg: rgba(240, 237, 249, 0.08);
    --body-glow: rgba(168, 155, 255, 0.025);
    --body-wash: transparent;
  }
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  color: var(--text);
  background:
    radial-gradient(circle at 86% -80px, var(--body-glow), transparent 250px),
    linear-gradient(180deg, var(--body-wash), transparent 300px),
    var(--bg);
}

main {
  width: min(720px, 100%);
  margin: 0 auto;
  padding: 30px 22px max(88px, calc(env(safe-area-inset-bottom) + 48px));
  line-height: 1.68;
}

.eyebrow {
  margin: 0 0 10px;
  color: var(--accent);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

h1 {
  margin: 0;
  font-size: clamp(22px, 5vw, 26px);
  line-height: 1.22;
  letter-spacing: 0;
}

.lead {
  margin: 14px 0 0;
  color: var(--muted);
  font-size: 16px;
  line-height: 1.62;
}

.meta {
  margin: 12px 0 24px;
  color: var(--muted);
  font-size: 13px;
}

.notice,
section {
  margin-top: 14px;
  padding: 19px 18px;
  background: var(--panel);
  border: 1px solid var(--panel-border);
  border-radius: 20px;
  box-shadow: 0 12px 34px var(--shadow);
  -webkit-backdrop-filter: blur(18px);
  backdrop-filter: blur(18px);
}

.notice {
  color: var(--muted);
}

h2 {
  margin: 0 0 12px;
  font-size: 18px;
  line-height: 1.32;
}

h3 {
  margin: 20px 0 8px;
  font-size: 16px;
  line-height: 1.38;
}

p,
li {
  font-size: 16px;
  letter-spacing: 0;
}

p {
  margin: 0 0 12px;
}

p:last-child,
ul:last-child,
ol:last-child {
  margin-bottom: 0;
}

ul,
ol {
  margin: 0 0 12px;
  padding-left: 22px;
}

li + li {
  margin-top: 7px;
}

table {
  display: block;
  width: 100%;
  min-width: 100%;
  overflow-x: auto;
  overflow-y: hidden;
  border-collapse: separate;
  border-spacing: 0;
  border-radius: 14px;
  font-size: 14px;
  background: var(--panel);
  border: 1px solid var(--panel-border);
  box-shadow: inset 0 -1px 0 var(--line);
  -webkit-overflow-scrolling: touch;
}

tbody {
  display: table;
  min-width: 620px;
  width: 100%;
  background: var(--panel);
}

thead,
tr {
  background: var(--panel);
}

th,
td {
  padding: 12px 10px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
  background: var(--panel);
}

th {
  color: var(--muted);
  font-weight: 700;
  background: var(--panel-strong);
}

tr:last-child td {
  border-bottom: 0;
}

code {
  padding: 2px 6px;
  border-radius: 7px;
  background: var(--code-bg);
  font-family: "SF Mono", ui-monospace, Menlo, monospace;
  font-size: 0.92em;
}

pre {
  overflow-x: auto;
  margin: 10px 0 0;
  padding: 14px;
  border-radius: 14px;
  background: var(--code-bg);
  border: 1px solid var(--panel-border);
  -webkit-overflow-scrolling: touch;
}

pre code {
  padding: 0;
  background: transparent;
  white-space: pre;
}

blockquote {
  margin: 14px 0;
  padding: 4px 0 4px 14px;
  border-left: 3px solid var(--accent);
  color: var(--muted);
}

hr {
  border: 0;
  border-top: 1px solid var(--line);
  margin: 22px 0;
}

a {
  color: var(--accent);
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

.footer {
  margin-top: 30px;
  color: var(--muted);
  font-size: 13px;
  text-align: center;
}

.compact-list {
  display: grid;
  gap: 10px;
  margin-top: 12px;
}

.compact-item {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  padding-top: 10px;
  border-top: 1px solid var(--line);
}

.compact-item:first-child {
  padding-top: 0;
  border-top: 0;
}

.mark {
  flex: none;
  width: 22px;
  height: 22px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  color: var(--accent);
  background: var(--accent-soft);
  font-size: 12px;
  font-weight: 700;
  margin-top: 2px;
}

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}

.chip {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 4px 10px;
  border-radius: 999px;
  background: var(--chip-bg);
  color: var(--muted);
  font-size: 13px;
  font-weight: 600;
}

.section-note {
  margin-top: 10px;
  color: var(--muted);
  font-size: 14px;
}

@media (max-width: 420px) {
  main {
    padding-left: 18px;
    padding-right: 18px;
  }

  section,
  .notice {
    padding: 18px 16px;
    border-radius: 18px;
  }

  h1 {
    font-size: 24px;
  }
}

nav { font-size: 14px; line-height: 1.9; margin: 18px 0 24px; overflow-wrap: anywhere; }
.help-shot { margin: 22px auto; max-width: 270px; }
.help-shot img { display: block; width: 100%; border-radius: 22px; border: 1px solid var(--line); }
.help-shot figcaption { color: var(--muted); font-size: 13px; margin-top: 10px; }

/* Shared documentation layout: public navigation is omitted from bundled HTML. */
.document { max-width: 780px; line-height: 1.75; overflow-wrap: anywhere; }
.document > h1 { font-size: clamp(26px, 5vw, 36px); line-height: 1.25; margin-bottom: 22px; }
.document section { margin-top: 34px; padding: 0; border: 0; border-radius: 0; background: none; box-shadow: none; -webkit-backdrop-filter: none; backdrop-filter: none; }
.document section + section { border-top: 1px solid var(--line); padding-top: 26px; }
.document h2 { font-size: 21px; line-height: 1.4; scroll-margin-top: 90px; }
.document p + p { margin-top: 14px; }
.document li { margin-bottom: 8px; }
.website { background: var(--bg); }
.site-header { position: sticky; top: 0; z-index: 10; background: var(--bg); border-bottom: 1px solid var(--line); }
.header-inner { max-width: 1120px; min-height: 68px; margin: auto; padding: 10px 24px; display: flex; align-items: center; gap: 20px; }
.site-brand { font-size: 19px; font-weight: 750; text-decoration: none; color: var(--text); white-space: nowrap; }
.header-inner > .language-menu, .support-link { margin-left: auto; }
.header-inner details { position: relative; }
.header-inner summary { display: flex; min-width: 44px; min-height: 44px; padding: 9px; align-items: center; gap: 8px; border-radius: 10px; cursor: pointer; color: var(--text); list-style: none; }
.header-inner summary::-webkit-details-marker { display: none; }
.header-inner summary:hover, .header-inner details[open] > summary { background: var(--accent-soft); }
.header-inner summary svg { width: 24px; height: 24px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; flex: none; }
.control-label { font-size: 14px; }
.dropdown { position: absolute; top: calc(100% + 8px); left: 0; min-width: 260px; max-width: min(340px, calc(100vw - 40px)); max-height: calc(100dvh - 110px); overflow: auto; margin: 0; padding: 8px; border: 1px solid var(--line); border-radius: 14px; background: var(--bg); box-shadow: 0 14px 36px var(--shadow); }
.language-menu .dropdown { left: auto; right: 0; min-width: 190px; }
.dropdown a { display: block; padding: 11px 14px; min-height: 44px; border-radius: 8px; color: var(--text); text-decoration: none; line-height: 1.5; }
.dropdown a:hover, .dropdown a[aria-current="page"] { color: var(--accent); background: var(--accent-soft); }
.site-footer { max-width: 1040px; margin: auto; padding: 0 24px max(40px, env(safe-area-inset-bottom)); }
.site-footer nav { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px 22px; padding-top: 24px; border-top: 1px solid var(--line); }
.site-footer a { padding: 8px 0; }
.guide-grid { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 12px; }
.guide-card { display: flex; gap: 12px; justify-content: space-between; align-items: center; padding: 20px; min-height: 76px; border: 1px solid var(--line); border-radius: 14px; text-decoration: none; font-weight: 600; background: var(--panel); }
.guide-card:hover { background: var(--accent-soft); border-color: var(--accent); }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.skip-link { position: fixed; left: 12px; top: -70px; z-index: 30; padding: 12px; background: var(--bg); }
.skip-link:focus { top: 8px; }
a:focus-visible, summary:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; }
.embedded .document { padding-top: 22px; }
.embedded .document > h1 { font-size: 26px; }
@media (max-width: 600px) {
 .header-inner { min-height: 60px; padding: 8px 16px; gap: 10px; }
 .control-label { display: none; }
 .guide-grid { grid-template-columns: 1fr; }
 .document { padding-top: 26px; }
 .guide-card { padding: 18px; min-height: 66px; }
 .support-link { font-size: 14px; max-width: 48%; text-align: right; }
 .site-footer nav { justify-content: flex-start; }
}
