/* Nestmark — public site (support + privacy). Static, no scripts, no web fonts
   (nothing is loaded from other sites). Colors are the extension's brand tokens;
   each page's summary is set as a real Nestmark "Yellow" highlight (shared/styles.js). */

:root {
  --ink: #16181d;
  --muted: #5b6270;
  --line: #e9e3d2;
  --paper: #fffefa;
  --band: #fff8e1;
  --band-line: #f1e6c2;
  --teal: #0f766e;
  --teal-strong: #115e59;
  --mark-bg: #fef3c7;
  --mark-fg: #92400e;
  --code-bg: #f4f1e8;
  --serif: Charter, 'Bitstream Charter', 'Iowan Old Style', 'Sitka Text', Cambria, Georgia, serif;
  --sans: system-ui, -apple-system, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}

@media (prefers-color-scheme: dark) {
  :root {
    --ink: #ebe8df;
    --muted: #a3a9b4;
    --line: #2c2f36;
    --paper: #131417;
    --band: #1c1b16;
    --band-line: #2e2b20;
    --teal: #5eead4;
    --teal-strong: #99f6e4;
    --mark-bg: #fde68a;
    --mark-fg: #422006;
    --code-bg: #22242a;
  }
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font: 18px/1.65 var(--serif);
}

.wrap {
  max-width: 44rem;
  margin: 0 auto;
  padding: 0 24px;
}

/* ---- masthead: the extension's cream band, Pip and the wordmark */
.masthead {
  background: var(--band);
  border-bottom: 1px solid var(--band-line);
}
.masthead .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 64px;
  font-family: var(--sans);
}
.brand {
  color: inherit;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 18px;
  letter-spacing: -0.01em;
}
.brand img { border-radius: 9px; }
nav { display: flex; gap: 4px; }
nav a {
  color: var(--ink);
  text-decoration: none;
  font-size: 15px;
  font-weight: 600;
  padding: 6px 10px;
  border-radius: 7px;
}
nav a:hover { background: var(--band-line); }
nav a[aria-current="page"] {
  color: var(--teal-strong);
  box-shadow: inset 0 -2px 0 var(--teal);
  border-radius: 0;
}

/* ---- document */
.doc { padding-top: 40px; padding-bottom: 24px; }

h1, h2, h3 {
  font-family: var(--sans);
  line-height: 1.2;
  letter-spacing: -0.015em;
}
h1 {
  font-size: clamp(30px, 5vw, 40px);
  margin: 0 0 10px;
}
h2 {
  font-size: 21px;
  margin: 44px 0 10px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
}

h3 {
  font-size: 17px;
  margin: 26px 0 6px;
}

p, ul, ol { margin: 0 0 16px; }
ul, ol { padding-left: 1.3em; }
ol li::marker { font-family: var(--sans); font-weight: 700; }
li { margin-bottom: 6px; }
li::marker { color: var(--teal); }

.meta {
  font-family: var(--sans);
  font-size: 14px;
  color: var(--muted);
  margin-bottom: 28px;
}
.meta strong { color: var(--ink); font-weight: 600; }

/* The short version, marked the way Nestmark marks text. */
.summary { font-size: 20px; line-height: 1.6; }
.summary strong {
  background: var(--mark-bg);
  color: var(--mark-fg);
  font-weight: 700;
  padding: 0 3px;
  border-radius: 3px;
  -webkit-box-decoration-break: clone;
  box-decoration-break: clone;
}

a {
  color: var(--teal-strong);
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}
a:hover { text-decoration-thickness: 2px; }
a:focus-visible {
  outline: 2px solid var(--teal);
  outline-offset: 2px;
  border-radius: 2px;
}

code {
  font-family: var(--mono);
  font-size: 0.8em;
  background: var(--code-bg);
  padding: 1px 5px;
  border-radius: 4px;
  overflow-wrap: anywhere;
}

/* ---- permissions table */
.table { margin: 8px 0 20px; }
table {
  width: 100%;
  border-collapse: collapse;
  font-size: 16px;
  line-height: 1.55;
}
th {
  font-family: var(--sans);
  font-size: 13px;
  text-align: left;
  color: var(--muted);
  font-weight: 600;
  padding: 0 12px 8px 0;
  border-bottom: 1px solid var(--line);
}
td {
  vertical-align: top;
  padding: 12px 12px 12px 0;
  border-bottom: 1px solid var(--line);
}
td:first-child { width: 34%; font-family: var(--sans); font-size: 15px; font-weight: 600; }
td:first-child code { font-size: 0.9em; }

footer {
  font-family: var(--sans);
  font-size: 13px;
  color: var(--muted);
  padding-top: 8px;
  padding-bottom: 40px;
}

/* ---- phones: 16px gutters, table rows become labelled blocks */
@media (max-width: 600px) {
  body { font-size: 17px; }
  .wrap { padding: 0 16px; }
  .doc { padding-top: 28px; }
  .summary { font-size: 18px; }
  thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
  table, tbody, tr, td { display: block; width: 100%; }
  tr { padding: 12px 0; border-bottom: 1px solid var(--line); }
  td, td:first-child { width: auto; border: 0; padding: 2px 0; }
  td + td::before {
    content: attr(data-label);
    display: block;
    font-family: var(--sans);
    font-size: 12px;
    color: var(--muted);
    margin-top: 4px;
  }
}

@media print {
  :root { --ink: #000; --muted: #444; --paper: #fff; --band: #fff; --teal-strong: #000; }
  .masthead { border-bottom: 1px solid #999; }
  nav, footer { display: none; }
  .doc a[href^="http"]::after { content: " (" attr(href) ")"; font-size: 0.85em; }
}
