/* The Modules page, in the IDEs' Windows 10 look (web/ide/index.html). */
:root {
  --ui-font: "Segoe UI", system-ui, -apple-system, "Helvetica Neue", Arial, sans-serif;
  --code-font: "Cascadia Mono", Consolas, Menlo, monospace;
  --chrome: #f0f0f0;
  --chrome-border: #d9d9d9;
  --muted: #5f5f5f;
  --hot: #e5f3ff;
  --accent: #0078d7;
  --danger: #c42b1c;
  --ok: #107c10;
  --control: #e1e1e1;
  --control-border: #adadad;
  --field-border: #7a7a7a;
  --deep: #12344f;
  --star: #e8a600;
  color-scheme: light;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html, body { margin: 0; min-height: 100%; background: #fff; color: #000; font: 13px/1.5 var(--ui-font); }
button, select, input, textarea { font: inherit; color: inherit; }
a { color: #0063b1; }
code, pre { font-family: var(--code-font); font-size: 12px; }
code { background: #f3f3f3; padding: 0 3px; }
pre { background: #f3f3f3; border: 1px solid var(--chrome-border); padding: 6px 8px; overflow: auto; max-height: 30em; }
pre code { background: none; padding: 0; }
h1 { font-size: 18px; margin: 0; font-weight: 600; }
h2 { font-size: 15px; margin: 16px 0 6px; font-weight: 600; }
h3, h4, h5, h6 { font-size: 13px; margin: 12px 0 4px; }
.muted { color: var(--muted); }
.error { color: var(--danger); }
.good { color: var(--ok); }
.small { font-size: 12px; }

button, .button {
  min-height: 24px; padding: 0 10px; border: 1px solid var(--control-border); border-radius: 0;
  background: var(--control); line-height: 22px; white-space: nowrap; cursor: default; }
button:hover:not(:disabled) { background: #e5f1fb; border-color: var(--accent); }
button:active:not(:disabled) { background: #cce4f7; border-color: #005499; }
button:disabled { background: #ccc; border-color: #bfbfbf; color: #838383; }
button.primary { background: var(--accent); border-color: var(--accent); color: #fff; }
button.primary:hover:not(:disabled) { background: #1a86d9; color: #fff; }
button.danger { color: var(--danger); }
button.link { border: 0; background: none; color: #0063b1; padding: 0; min-height: 0; text-decoration: underline; }
button.link:hover:not(:disabled) { background: none; }
input[type=text], input[type=search], textarea, select {
  border: 1px solid var(--field-border); background: #fff; padding: 2px 6px; border-radius: 0; }
input:focus, textarea:focus, select:focus { border-color: var(--accent); outline: none; }
textarea { width: 100%; resize: vertical; min-height: 5em; }
:focus-visible { outline: 1px dotted #000; outline-offset: 1px; }

#bar { position: sticky; top: 0; z-index: 2; display: flex; flex-wrap: wrap; align-items: center; gap: 6px 12px;
  padding: 6px 12px; background: var(--chrome); border-bottom: 1px solid var(--chrome-border); }
#tabs { display: flex; gap: 2px; }
#tabs button { border-color: transparent; background: none; position: relative; }
#tabs button[aria-selected=true] { background: #fff; border-color: var(--chrome-border); font-weight: 600; }
#search { flex: 1 1 14em; min-width: 10em; }
#search-box { width: 100%; height: 26px; }
#account { display: flex; gap: 6px; align-items: center; }
.dot { display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: var(--danger); margin-left: 4px;
  vertical-align: top; }

#toast { position: sticky; top: 40px; z-index: 2; margin: 0; padding: 6px 12px; background: #fff4ce;
  border-bottom: 1px solid #e6d28a; }
#toast button { margin-left: 8px; }
#view { padding: 12px 16px 40px; max-width: 980px; outline: none; }

.toolbar { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin: 0 0 10px; }
.chips button[aria-pressed=true] { background: #cce4f7; border-color: #005499; }
.list { list-style: none; margin: 0; padding: 0; }
.row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 2px 12px; padding: 8px 6px;
  border-bottom: 1px solid var(--chrome-border); }
.row:hover { background: #f7fbff; }
.row .name { font-weight: 600; font-family: var(--code-font); font-size: 13px; }
.row button.name { border: 0; background: none; padding: 0; min-height: 0; color: #0063b1; text-align: left; }
.row .side { text-align: right; white-space: nowrap; }
.row .line { grid-column: 1 / -1; }
.stars { color: var(--star); letter-spacing: 1px; }
.platforms span { display: inline-block; border: 1px solid var(--chrome-border); padding: 0 4px; margin-right: 3px;
  font-size: 11px; }
.badge { display: inline-block; padding: 0 6px; font-size: 11px; border: 1px solid; margin-left: 6px; }
.badge.public, .badge.ready, .badge.ok { color: var(--ok); }
.badge.checking, .badge.preview { color: #8a6d00; }
.badge.failed, .badge.hidden, .badge.harmful { color: var(--danger); }
.badge.withdrawn, .badge.private, .badge.deleted { color: var(--muted); }
.harmful-row { background: #fde7e9; }

.head { display: flex; flex-wrap: wrap; gap: 8px 16px; align-items: flex-start; justify-content: space-between; }
.head .actions { display: flex; gap: 6px; }
.facts { margin: 4px 0; }
.subtabs { display: flex; gap: 2px; border-bottom: 1px solid var(--chrome-border); margin: 12px 0; }
.subtabs button { border-color: transparent; background: none; }
.subtabs button[aria-selected=true] { border-color: var(--chrome-border); border-bottom-color: #fff; background: #fff;
  margin-bottom: -1px; font-weight: 600; }
.readme { max-width: 46em; }
.readme img { max-width: 100%; }
.readme table { border-collapse: collapse; margin: 0 0 10px; }
.readme th, .readme td { border: 1px solid var(--chrome-border); padding: 3px 8px; text-align: left; vertical-align: top; }
.readme th { background: var(--chrome); }
.readme code.target { outline: 2px solid var(--accent); outline-offset: 1px; background: var(--hot); }
/* The commands a module gives a program, first on its page, each name
   leading to the README's part about it. */
.command-list { list-style: none; margin: 0 0 12px; padding: 6px 10px; border: 1px solid var(--chrome-border); background: #fafafa; }
.command-list li { margin: 3px 0; }
.command-list > li > code { background: none; padding: 0; }
.command-list button.link { font: inherit; font-weight: 600; text-decoration: none; }
.command-list .members { margin-left: 2em; }
.files li button { font-family: var(--code-font); }
.comment { border-left: 3px solid var(--chrome-border); padding: 4px 10px; margin: 10px 0; }
.comment .who { font-weight: 600; }
.comment .replies { margin-left: 18px; }
.comment p { margin: 4px 0; }
.form { display: grid; grid-template-columns: max-content minmax(0, 1fr); gap: 8px 12px; align-items: start;
  max-width: 46em; }
.form label { padding-top: 3px; }
.form .full { grid-column: 1 / -1; }
.problems { color: var(--danger); }
.notice { border: 1px solid #e6d28a; background: #fff8dc; padding: 8px 12px; margin: 8px 0; }
.empty { padding: 20px 0; color: var(--muted); }
.diff { font-family: var(--code-font); font-size: 12px; white-space: pre; overflow: auto; max-height: 30em;
  border: 1px solid var(--chrome-border); }
.diff .add { background: #dfd; }
.diff .del { background: #fdd; }
.rate button { border: 0; background: none; color: var(--star); font-size: 18px; padding: 0 1px; min-height: 0; }
.rate button.off { color: #bbb; }
.signin { max-width: 36em; padding: 20px 0; }
.signin p { margin: 8px 0; }

dialog { border: 1px solid #888; padding: 16px 18px; max-width: min(36em, 92vw); box-shadow: 0 8px 24px rgba(0, 0, 0, .25); }
dialog::backdrop { background: rgba(0, 0, 0, .25); }
dialog h1 { font-size: 15px; margin-bottom: 8px; }
dialog .buttons { display: flex; flex-wrap: wrap; gap: 6px; justify-content: flex-end; margin-top: 14px; }
dialog ul { max-height: 14em; overflow: auto; }
