/* xovv.io secondary pages (404, privacy and security).
   Built on the tokens and base classes in site.css; load this after it.
   All stay in the default dark tone. 404 and privacy run no JavaScript; the
   security page runs only the live checks (e2ee-check.js, checks.js). */

/* Shell: keep the footer at the bottom on short pages */
body.pg {
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
}
body.pg > main { flex: 1 0 auto; }
body.pg > main:focus { outline: none; }
/* Keep the skip link fully off-screen until focused (its base offset leaves a sliver visible under the nav) */
.pg .skip:not(:focus) { transform: translate(-50%, calc(-100% - 96px)); }
.foot nav a[aria-current] { color: var(--fg, #F6F6F8); }

/* ---------- 404 ---------- */
.nf { display: grid; align-items: center; }
.nf-in {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 360px);
  gap: var(--gutter, clamp(32px, 6vw, 80px));
  align-items: center;
  width: 100%;
  padding-block: clamp(72px, 11vw, 136px);
}
.nf-text { display: grid; justify-items: start; }
.nf-text .chapter { max-width: 14ch; }
.nf-text .body { margin-top: 20px; color: var(--fg-2, #D4D4DB); }
.nf-text .btn { margin-top: 32px; }
.nf-plate { display: block; width: 100%; height: auto; overflow: visible; }
.nf-num {
  font-family: var(--mono, 'DM Mono', 'DM Mono Fallback', ui-monospace, monospace);
  font-size: 20px;
  font-weight: 400;
  fill: var(--blue, #2563EB);
  fill-opacity: .75;
}

@media (max-width: 640px) {
  .nf-in { grid-template-columns: minmax(0, 1fr); gap: 36px; padding-block: 56px 72px; }
  .nf-plate { order: -1; max-width: 200px; }
}

/* ---------- Privacy ---------- */
.doc {
  font-size: var(--t-body, 17px);
  padding-block: clamp(64px, 10vw, 128px) var(--section, clamp(88px, 11vw, 144px));
}
.doc-head, .doc-sections { max-width: calc(72px + 64ch); }
.doc-head { padding-bottom: clamp(40px, 5vw, 56px); }
.doc-date { margin-top: 18px; }
.doc-date time { font-family: var(--mono, 'DM Mono', 'DM Mono Fallback', ui-monospace, monospace); font-size: 12px; letter-spacing: .04em; }
.doc-head .lead { margin-top: 28px; max-width: 56ch; }
.doc-scope { margin-top: 16px; max-width: 56ch; font-size: var(--t-small, 15px); line-height: 1.55; color: var(--fg-3); }

.doc-sections { border-bottom: 1px solid var(--line, rgba(255,255,255,.11)); }
.doc-sec {
  display: grid;
  grid-template-columns: 56px minmax(0, 64ch);
  column-gap: 16px;
  padding-block: 36px;
  border-top: 1px solid var(--line, rgba(255,255,255,.11));
}
.doc-num {
  font-family: var(--mono, 'DM Mono', 'DM Mono Fallback', ui-monospace, monospace);
  font-size: 12px;
  letter-spacing: .04em;
  color: var(--accent-text, #6C98F7);
  padding-top: 8px;
}
.doc-body { display: grid; gap: 14px; min-width: 0; }
.doc-body h2 {
  font-size: clamp(20px, 2.2vw, 24px);
  line-height: 1.25;
  letter-spacing: -.015em;
  font-weight: 500;
  margin-bottom: 4px;
}
.doc-body p, .doc-body li {
  font-size: 1em;
  line-height: 1.65;
  color: var(--fg-2, #D4D4DB);
  max-width: 64ch;
}
.doc-body ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.doc-body li { position: relative; padding-left: 24px; }
.doc-body li::before {
  content: '';
  position: absolute;
  left: 2px;
  top: .82em;
  width: 10px;
  height: 1px;
  background: var(--fg-4, #7C7C87);
}
.doc-body a {
  color: var(--accent-text, #6C98F7);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
  text-decoration-color: rgba(108, 152, 247, .45);
  transition: text-decoration-color var(--t, 220ms) var(--ease-out, ease);
}
@media (hover: hover) and (pointer: fine) {
  .doc-body a:hover { text-decoration-color: currentColor; }
}
.doc-body strong { font-weight: 500; color: var(--fg, #F6F6F8); }

@media (max-width: 600px) {
  .doc-sec { grid-template-columns: minmax(0, 1fr); row-gap: 10px; padding-block: 28px; }
  .doc-num { padding-top: 0; }
}

@media (prefers-reduced-motion: reduce) {
  .doc-body a { transition: none; }
}

/* ---------- Security ---------- */
.sec { padding-block: clamp(64px, 10vw, 128px) var(--section, clamp(88px, 11vw, 144px)); }
.sec-head .chapter { max-width: 18ch; }
.sec-head .lead { margin-top: 24px; max-width: 60ch; }
.sec-summary { display: inline-flex; align-items: center; gap: 10px; margin-top: 32px; padding: 10px 16px; border-radius: 999px; background: var(--frost-fill); border: 1px solid var(--frost-stroke); box-shadow: inset 0 1px 0 var(--frost-edge); font-family: var(--mono); font-size: 12px; line-height: 1.4; color: var(--fg-2); }
.sec-summary .dot { flex: none; width: 8px; height: 8px; border-radius: 50%; background: var(--fg-4); box-shadow: 0 0 0 4px transparent; transition: background .3s, box-shadow .3s; }
.sec-summary.ok .dot { background: var(--ok); box-shadow: 0 0 0 4px rgba(52,211,153,.14); }
.sec-groups { margin-top: clamp(56px, 8vw, 88px); display: grid; gap: clamp(48px, 6vw, 72px); }
.sec-group { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 16px var(--gutter, clamp(32px, 6vw, 80px)); }
.sec-group-head .meta { margin-top: 10px; max-width: 32ch; font-size: var(--t-small, 15px); }
.sec-rows { border-bottom: 1px solid var(--line, rgba(255,255,255,.11)); }
.check-row { display: grid; grid-template-columns: 20px minmax(0, 1fr) minmax(13ch, auto); gap: 20px; padding-block: 22px; border-top: 1px solid var(--line, rgba(255,255,255,.11)); align-items: baseline; }
.check-row .dot { align-self: start; justify-self: center; margin-top: 9px; }
.check-row .what h3 { font-size: var(--t-title, 18px); line-height: 1.35; }
.check-row .what > p { margin-top: 3px; font-size: var(--t-small, 15px); line-height: 1.5; color: var(--fg-3); }
.check-row .val { text-align: right; }
.sec-cards { margin-top: clamp(72px, 9vw, 104px); display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
.sec-card { display: grid; align-content: start; gap: 12px; padding: clamp(24px, 3vw, 32px); border-radius: 20px; background: var(--frost-fill); border: 1px solid var(--frost-stroke); box-shadow: inset 0 1px 0 var(--frost-edge); }
.sec-card h2 { font-size: 22px; line-height: 1.25; letter-spacing: -.01em; }
.sec-card p { font-size: var(--t-small, 15px); line-height: 1.6; color: var(--fg-3); }
.sec-card a { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; justify-self: start; color: var(--accent-text); text-decoration: none; font-size: var(--t-small, 15px); }
.sec-card a svg { width: 14px; height: 14px; transition: transform var(--t, 220ms) var(--ease-out, ease-out); }
@media (hover: hover) and (pointer: fine) { .sec-card a:hover svg { transform: translateX(3px); } }
@media (max-width: 860px) {
  .sec-group { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 640px) {
  .sec-cards { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 480px) {
  .sec-summary { border-radius: 16px; }
}
/* Phones: the value sits above the title, so an open detail never separates them
   and the detail gets the full width. */
@media (max-width: 640px) {
  .check-row { grid-template-columns: 20px minmax(0, 1fr); gap: 6px 14px; }
  .check-row .val { grid-column: 2; grid-row: 1; text-align: left; }
  .check-row .what { grid-column: 2; grid-row: 2; }
  .check-row .dot { grid-row: 1; margin-top: 4px; }
}
