/* PixalCream Studios - legal pages (404 and privacy). Uses the shared tokens from site.css. */

/* the scripts show and hide parts with the hidden attribute; classes that set display must not beat it */
.probe [hidden], .store[hidden], .store [hidden], .lost-where[hidden], .lost-guess[hidden] { display: none !important; }

/* ---------- 404: the path you asked for, and the "did you mean" line ---------- */
.lost-where { margin: 1.25rem 0 0; color: var(--muted); font-size: .9375rem; max-width: 45rem; overflow-wrap: anywhere; }
.lost-where code, .lost-code { font-family: Consolas, "Cascadia Mono", ui-monospace, monospace; font-size: .875rem; color: var(--accent-2);
  background: rgba(78, 201, 255, .08); border: 1px solid rgba(78, 201, 255, .25); border-radius: .375rem; padding: .0625rem .375rem; }
.lost-guess { margin: .625rem 0 0; font-size: 1.0625rem; color: var(--text); }
.lost-guess a { font-weight: 700; }

/* ---------- 404: the probe game ---------- */
.probe { max-width: 60rem; }
.probe-screen { position: relative; }
.probe-stage { position: relative; aspect-ratio: 16 / 9; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden;
  background: radial-gradient(ellipse 70% 60% at 50% 50%, rgba(30, 44, 90, .35), transparent 70%), #02040a; }
.probe-stage canvas { display: block; width: 100%; height: 100%; touch-action: none; cursor: crosshair; }
.probe-stage canvas:focus { outline: none; }
.probe-stage canvas:focus-visible { outline: 2px solid var(--accent-2); outline-offset: -4px; }
.probe-stage.is-off { display: grid; place-items: center; padding: 1.5rem; text-align: center; color: var(--muted); }

.probe-overlay { position: absolute; inset: 0; display: grid; place-items: center; padding: 1rem; background: rgba(2, 4, 10, .62); }
.probe-overlay[hidden] { display: none; }
.probe-card { max-width: 26rem; text-align: center; padding: 1.25rem 1.5rem; border: 1px solid var(--line); border-radius: var(--radius); background: rgba(8, 12, 22, .94); }
.probe-card h3 { margin: 0 0 .375rem; font-size: 1.375rem; }
.probe-card p { margin: 0 0 1rem; color: #c3cde2; font-size: .9688rem; }
.probe-card .cta { justify-content: center; }

.probe-stats { display: flex; flex-wrap: wrap; gap: .5rem 1.25rem; margin: .875rem 0 0; padding: 0; list-style: none; font-size: .9375rem; color: var(--muted); }
.probe-stats b { color: var(--text); font-variant-numeric: tabular-nums; }
.probe-fuel { display: inline-flex; align-items: center; gap: .5rem; }
.probe-fuel i { display: inline-block; width: 6rem; height: .5rem; border-radius: 1rem; background: var(--line); overflow: hidden; position: relative; }
.probe-fuel i::after { content: ""; position: absolute; inset: 0 auto 0 0; width: var(--fuel, 100%); background: var(--accent); border-radius: 1rem; }
.probe-fuel.low i::after { background: #ff5a5a; }

.probe-pad { display: flex; flex-wrap: wrap; gap: .625rem; margin: 1rem 0 0; }
.probe-pad button { min-width: 3.25rem; min-height: 3.25rem; padding: .5rem 1rem; border-radius: .875rem; border: 1px solid var(--line);
  background: var(--panel); color: var(--text); font: inherit; font-weight: 700; cursor: pointer; touch-action: none; user-select: none; -webkit-user-select: none; }
.probe-pad button:hover { border-color: var(--accent-2); }
.probe-pad button.held, .probe-pad button[aria-pressed="true"] { border-color: var(--accent); background: rgba(255, 138, 61, .16); }
.probe-pad .pad-gap { flex: 1 1 0; min-width: .25rem; }
.probe-pad .pad-small { font-weight: 400; color: var(--muted); }

.probe-status { min-height: 1.65em; margin: .75rem 0 0; color: var(--accent-2); font-weight: 700; }
.probe-keys { margin: .625rem 0 0; color: var(--muted); font-size: .9062rem; }
kbd { display: inline-block; min-width: 1.5em; padding: 0 .375rem; border: 1px solid var(--line); border-bottom-width: 2px; border-radius: .3125rem;
  background: rgba(14, 21, 38, .9); color: var(--text); font: 700 .8125rem/1.6 Consolas, ui-monospace, monospace; text-align: center; }

/* ---------- 404: every page ---------- */
.lost-pages { grid-template-columns: repeat(auto-fit, minmax(min(100%, 15rem), 1fr)); }
.lost-pages a.card { display: block; color: var(--text); }
.lost-pages a.card:hover { text-decoration: none; border-color: var(--accent); }
.lost-pages a.card.is-guess { border-color: var(--accent-2); box-shadow: 0 0 0 1px rgba(78, 201, 255, .35); }
.lost-pages .card h3 { font-size: 1.125rem; }
.lost-pages .card p { font-size: .9375rem; }

/* ---------- privacy: what your browser holds ---------- */
.store { max-width: 47.5rem; margin-top: 1.5rem; padding: 1.25rem 1.375rem; border: 1px solid var(--line); border-radius: var(--radius); background: var(--panel); }
.store h3 { margin: 0 0 .5rem; font-size: 1.1875rem; }
.store-list { list-style: none; margin: .75rem 0 0; padding: 0; }
.store-list li { display: flex; flex-wrap: wrap; gap: .25rem 1rem; padding: .5rem 0; border-bottom: 1px solid var(--line); font-size: .9375rem; color: #b6c1d9; }
.store-list li:last-child { border-bottom: 0; }
.store-list code { font-family: Consolas, ui-monospace, monospace; color: var(--accent-2); overflow-wrap: anywhere; }
.store-list .val { color: var(--muted); overflow-wrap: anywhere; min-width: 0; flex: 1 1 12rem; }
.store-empty { color: var(--muted); margin: .75rem 0 0; }
.store .cta { margin-top: 1rem; }
.store .btn.danger { background: transparent; color: #ffb3a1; border: 1px solid rgba(255, 120, 90, .55); }
.store .btn.danger:hover { box-shadow: none; border-color: #ff7a5a; }
.store-note { margin: .75rem 0 0; color: var(--muted); font-size: .875rem; min-height: 1.4em; }

.howto { margin: 1rem 0 0; padding-left: 1.25rem; color: #c3cde2; max-width: 47.5rem; }
.howto li { margin: .375rem 0; }
.howto b { color: var(--text); }

.privacy-cards .card h3 { font-size: 1.125rem; }
.updated { margin: 1rem 0 0; color: var(--muted); font-size: .875rem; }

.fineprint { margin: 2.5rem 0 0; font-size: .75rem; color: #5d6a86; letter-spacing: .02em; display: inline-block; }
.fineprint.live { cursor: pointer; border-radius: .25rem; }
.fineprint.live:hover { color: var(--muted); }
.fineprint.live:focus-visible { outline: 2px solid var(--accent-2); outline-offset: 3px; }
.fineprint.seen { color: var(--accent-2); }

@media (max-width: 560px) {
  .probe-pad button { flex: 1 1 4rem; padding: .5rem .375rem; white-space: nowrap; font-size: .9375rem; }
  .probe-pad .pad-gap { display: none; }
  .probe-fuel i { width: 4.5rem; }
  .probe-card { padding: 1rem; }
  .probe-card p { margin-bottom: .75rem; font-size: .9062rem; }
  .probe-card h3 { font-size: 1.1875rem; }
}
/* phones: the 16:9 field is too small to hold the message card, so the card sits under the field */
@media (max-width: 640px) {
  .probe-overlay { position: static; background: none; padding: .75rem 0 0; }
  .probe-card { max-width: none; }
}

/* ---------- privacy: every note, by name ---------- */
.keytable-wrap { max-width: 56rem; margin-top: 1rem; overflow-x: auto; }
.keytable { width: 100%; border-collapse: collapse; font-size: .9375rem; color: #c3cde2; }
.keytable th, .keytable td { text-align: left; vertical-align: top; padding: .5rem .75rem; border-bottom: 1px solid var(--line); }
.keytable thead th { font-size: .75rem; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); font-weight: 600; }
.keytable tbody th { font-weight: 400; white-space: nowrap; }
.keytable td:first-child { color: var(--muted); white-space: nowrap; }
.keytable code { overflow-wrap: anywhere; }
@media (max-width: 560px) {
  .keytable thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
  .keytable, .keytable tbody, .keytable tr, .keytable th, .keytable td { display: block; width: 100%; }
  .keytable tr { padding: .5rem 0; border-bottom: 1px solid var(--line); }
  .keytable th, .keytable td { border: 0; padding: .125rem 0; white-space: normal; }
  .keytable tbody th { white-space: normal; }
}
