/* Layered on app.css, which carries the palette, type and code styling. */

.doc-head { padding: 56px 0 36px; }
.doc-head h1 { margin-top: 24px; }
.lede.small { font-size: 16px; }

/* Two pages, not a JS toggle: each is linkable, shareable and indexable, which
   a tab switcher inside one page is not. */
.tabs { display: flex; gap: 4px; margin: 22px 0 0; }
.tabs a {
  padding: 8px 14px; border-radius: 8px 8px 0 0;
  font-size: 14.5px; font-weight: 500; text-decoration: none;
  color: var(--muted); border: 1px solid transparent; border-bottom: 0;
}
.tabs a:hover { color: var(--ink); }
.tabs a.on {
  color: var(--ink); background: var(--panel);
  border-color: var(--line);
}
.tabs { border-bottom: 1px solid var(--line); }
.tabs a.on { margin-bottom: -1px; background: var(--bg); }

/* The editor is the whole page; everything else is a result of it. */
.editor { background: var(--panel); border: 1px solid var(--line); border-radius: 12px; overflow: hidden; }
.editor-top, .editor-bottom {
  display: flex; align-items: center; gap: 12px; flex-wrap: wrap;
  padding: 12px 14px;
}
.editor-top { border-bottom: 1px solid var(--line); }
.editor-bottom { border-top: 1px solid var(--line); }
.editor-actions { margin-left: auto; display: flex; align-items: center; gap: 12px; }
.label { font-size: 12px; text-transform: uppercase; letter-spacing: .07em; color: var(--muted); font-weight: 600; }
.size { font-family: ui-monospace, monospace; font-size: 12px; color: var(--muted); }
.size.over { color: var(--accent); font-weight: 600; }

#json {
  display: block; width: 100%; min-height: 260px; resize: vertical;
  border: 0; outline: 0; padding: 16px 18px;
  background: var(--code-bg); color: var(--code-ink);
  font-family: ui-monospace, "SF Mono", Menlo, monospace;
  font-size: 13.5px; line-height: 1.6; tab-size: 2;
}
#json:focus-visible { box-shadow: inset 0 0 0 2px var(--accent); }

.hint { font-size: 13px; color: var(--muted); }
.ghostbtn {
  background: none; color: var(--ink);
  border: 1px solid var(--line); border-radius: 7px;
  padding: 8px 13px; font: inherit; font-size: 13px; cursor: pointer;
}
.ghostbtn:hover { border-color: var(--accent); color: var(--accent); }

.error {
  border-left: 3px solid var(--accent); background: var(--accent-soft);
  padding: 14px 16px; border-radius: 0 8px 8px 0; margin-top: 14px;
  font-size: 15px; color: var(--ink);
}
.error b { display: block; margin-bottom: 4px; }
.error code { font-size: 12.5px; }

.exports { display: flex; gap: 10px; flex-wrap: wrap; }
.scroller { overflow-x: auto; }
td.mono a { text-decoration: none; }
td.mono a:hover { text-decoration: underline; }

/* The runners are the recommendation; db.json and MSW are for people who
   already know they want them. */
.ghostbtn.primary { background: var(--accent); color: #fff; border-color: transparent; }
.ghostbtn.primary:hover { color: #fff; opacity: .9; }
