/* ============================================================================
   picshr — visual language ported from weather.lnln.eu / sitarina.lnln.eu
   (see /data/workplace/weather/web/src/styles/{tokens,main}.css): Swiss-style
   hairline panels, zero border-radius, Inter + Fira Code, mono uppercase
   micro-labels, sage accent, grain + 60px grid texture. Every colour flows
   through the tokens below — no hex literals in component rules.
   ========================================================================= */

/* ── Fonts (self-hosted, same files @fontsource ships to the weather app) ── */

@font-face { font-family: "Inter"; font-style: normal; font-weight: 400; font-display: swap; src: url(/static/fonts/inter-latin-400-normal.woff2) format("woff2"); }
@font-face { font-family: "Inter"; font-style: normal; font-weight: 500; font-display: swap; src: url(/static/fonts/inter-latin-500-normal.woff2) format("woff2"); }
@font-face { font-family: "Inter"; font-style: normal; font-weight: 600; font-display: swap; src: url(/static/fonts/inter-latin-600-normal.woff2) format("woff2"); }
@font-face { font-family: "Inter"; font-style: normal; font-weight: 700; font-display: swap; src: url(/static/fonts/inter-latin-700-normal.woff2) format("woff2"); }
@font-face { font-family: "Inter"; font-style: normal; font-weight: 800; font-display: swap; src: url(/static/fonts/inter-latin-800-normal.woff2) format("woff2"); }
@font-face { font-family: "Fira Code"; font-style: normal; font-weight: 400; font-display: swap; src: url(/static/fonts/fira-code-latin-400-normal.woff2) format("woff2"); }
@font-face { font-family: "Fira Code"; font-style: normal; font-weight: 500; font-display: swap; src: url(/static/fonts/fira-code-latin-500-normal.woff2) format("woff2"); }

/* ── Design tokens (mirrors the weather app's tokens.css) ── */

:root {
  color-scheme: light;

  --accent: #56775f;
  --accent-rgb: 86, 119, 95;
  --accent-dk: #94af9b;
  --accent-dk-rgb: 148, 175, 155;

  --bg: #f5f5f5;
  --surface: #ffffff;
  --surface-2: #f0f0f0;
  --fg: #111111;
  --fg-2: rgba(17, 17, 17, 0.66);
  --fg-3: rgba(17, 17, 17, 0.6);
  --line: rgba(0, 0, 0, 0.13);
  --line-soft: rgba(0, 0, 0, 0.06);

  --a: var(--accent);
  --a-rgb: var(--accent-rgb);
  --on-accent: #ffffff;

  --ok: #2c7a57;
  --warn: #8b5e12;
  --danger: #b23a2b;

  --shadow: 0 40px 90px -40px rgba(0, 0, 0, 0.45);
  --grain-opacity: 0.035;

  --font-sans: "Inter", ui-sans-serif, system-ui, -apple-system, sans-serif;
  --font-mono: "Fira Code", ui-monospace, "SF Mono", Menlo, monospace;
  --radius: 0px;

  --topbar-h: 4rem;
  --shell-max: 90rem;
  --pad: clamp(1.25rem, 3.5vw, 3.5rem);
}

[data-theme="dark"] {
  color-scheme: dark;

  --bg: #111111;
  --surface: #1a1a1a;
  --surface-2: #1e1e1e;
  --fg: #f2f2f2;
  --fg-2: rgba(242, 242, 242, 0.64);
  --fg-3: rgba(242, 242, 242, 0.52);
  --line: rgba(255, 255, 255, 0.14);
  --line-soft: rgba(255, 255, 255, 0.07);

  --a: var(--accent-dk);
  --a-rgb: var(--accent-dk-rgb);
  --on-accent: #101a12;

  --ok: #63b98f;
  --warn: #d8a245;
  --danger: #e0705e;

  --shadow: 0 40px 90px -40px rgba(0, 0, 0, 0.9);
  --grain-opacity: 0.05;
}

/* ── LNLN UIS chrome mapping ─────────────────────────────────────────────────
   The shared UIS bar/panels (uis-sdk/assets/uis.css) read the estate-wide
   token names (--bg-primary, --text-muted, --border, …). Map them onto
   picshr's sitarina tokens so the UIS chrome follows this app's surfaces in
   BOTH themes instead of falling back to its built-in dark defaults. The
   accent family (--accent, --accent-0t1/2, --accent-ink) intentionally stays
   with the central UIS brand <style> block — that's live branding. */

:root, [data-theme="dark"] {
  --bg-primary: var(--bg);
  --bg-secondary: var(--surface);
  --bg-tertiary: var(--surface-2);
  --bg-elevated: var(--surface);
  --text-primary: var(--fg);
  --text-secondary: var(--fg-2);
  --text-muted: var(--fg-3);
  --border: var(--line);
  --border-light: var(--line-soft);
}

/* ── Base ── */

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--font-sans);
  font-size: 1rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  font-feature-settings: "kern" 1, "liga" 1, "calt" 1;
  transition: background-color 0.35s ease, color 0.35s ease;
}

::selection { background: var(--a); color: var(--on-accent); }

::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--line); }
::-webkit-scrollbar-thumb:hover { background: var(--a); }

:focus-visible { outline: 2px solid var(--a); outline-offset: 2px; }

a { color: var(--a); text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: 3px; }

h1, h2, h3, p, dl, dd, figure { margin: 0; }

code, .mono { font-family: var(--font-mono); font-size: 0.875em; }

/* ── Texture: film grain + 60px grid ── */

.grain {
  position: fixed;
  inset: 0;
  z-index: 90;
  pointer-events: none;
  opacity: var(--grain-opacity);
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.65' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

.grid-lines {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background-image:
    linear-gradient(to right, var(--line-soft) 1px, transparent 1px),
    linear-gradient(to bottom, var(--line-soft) 1px, transparent 1px);
  background-size: 60px 60px;
}

/* ── Shared atoms ── */

.label {
  font-family: var(--font-mono);
  font-size: 0.6875rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: var(--fg-3);
}

.kbd {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 1.55rem;
  height: 1.35rem;
  padding: 0 0.35rem;
  border: 1px solid var(--line);
  background: var(--surface);
  font-family: var(--font-mono);
  font-size: 0.6875rem;
  color: var(--fg-3);
}

.sr-only {
  position: absolute !important;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

/* ── Topbar ── */

.topbar {
  position: sticky;
  top: 0;
  z-index: 50;
  height: var(--topbar-h);
  background: var(--bg);
  border-bottom: 1px solid var(--line);
  transition: background-color 0.35s ease;
}
.topbar__inner {
  max-width: var(--shell-max);
  margin-inline: auto;
  height: 100%;
  padding-inline: var(--pad);
  display: flex;
  align-items: center;
  gap: 1.25rem;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  color: var(--fg);
  text-decoration: none;
  flex-shrink: 0;
}
.brand:hover { text-decoration: none; }
.brand__mark {
  width: 2.1rem;
  height: 2.1rem;
  display: grid;
  place-items: center;
  background: var(--a);
  color: var(--on-accent);
  font-family: var(--font-mono);
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.05em;
}
.brand__name {
  font-weight: 800;
  font-size: 0.9375rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}
.topbar__nav {
  display: flex;
  align-items: center;
  gap: 1.4rem;
  margin-left: 0.5rem;
}
.topbar__nav a {
  font-family: var(--font-mono);
  font-size: 0.6875rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: var(--fg-3);
  text-decoration: none;
  padding: 0.35rem 0;
  border-bottom: 1px solid transparent;
}
.topbar__nav a:hover { color: var(--fg); }
.topbar__nav a.active { color: var(--a); border-bottom-color: var(--a); }
.topbar__spacer { flex: 1; }
.topbar__right { display: flex; align-items: center; gap: 0.6rem; flex-shrink: 0; }
.topbar__user {
  font-family: var(--font-mono);
  font-size: 0.6875rem;
  letter-spacing: 0.08em;
  color: var(--fg-3);
  max-width: 15rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
@media (max-width: 40rem) { .topbar__user { display: none; } }
.apps-grid-slot { display: inline-flex; }

/* Bordered square icon button (weather's IconBtn). */
.icon-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.1rem;
  height: 2.1rem;
  border: 1px solid var(--line);
  background: transparent;
  color: var(--fg-2);
  cursor: pointer;
  transition: color 0.2s ease, border-color 0.2s ease, background-color 0.2s ease;
}
.icon-btn:hover { color: var(--fg); border-color: var(--fg); text-decoration: none; }
.icon-btn iconify-icon { font-size: 1.05rem; }

/* ── Shell ── */

.shell {
  max-width: var(--shell-max);
  margin-inline: auto;
  padding: 2.5rem var(--pad) 4rem;
}

/* ── Pagehead (kicker + display title + lede + hairline meta row) ── */

.pagehead { margin-bottom: 2.2rem; }
.pagehead__kicker {
  margin-bottom: 1rem;
  font-family: var(--font-mono);
  font-size: 0.6875rem;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: var(--a);
}
.pagehead__title {
  font-size: clamp(1.75rem, 5.2vw, 3.75rem);
  font-weight: 800;
  line-height: 0.95;
  letter-spacing: -0.035em;
  text-transform: uppercase;
  text-wrap: balance;
}
.pagehead__lede {
  margin-top: 1.35rem;
  max-width: 40rem;
  font-size: 1.0625rem;
  line-height: 1.6;
  color: var(--fg-2);
}
.pagemeta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 1.4rem;
  margin-top: 1.9rem;
  padding-top: 1.1rem;
  border-top: 1px solid var(--line);
  font-family: var(--font-mono);
  font-size: 0.6875rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--fg-3);
}
.pagemeta__item { display: inline-flex; align-items: center; gap: 0.45rem; }
.pagemeta__item a { color: inherit; }
.pagemeta__item a:hover { color: var(--a); }

/* ── Panel: the one container shape. Hairline border, no shadow, no radius. ── */

.panel {
  border: 1px solid var(--line);
  background: var(--surface);
  margin-bottom: 1.5rem;
}
.panel__head {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.5rem 1rem;
  padding: 0.85rem 1.1rem;
  border-bottom: 1px solid var(--line);
}
.panel__title {
  min-width: 0;
  font-family: var(--font-mono);
  font-size: 0.6875rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: var(--fg-3);
}
.panel__actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  min-width: 0;
  flex: 1 1 auto;
  justify-content: flex-end;
}
.panel__body { padding: 1.1rem; }
.panel__body > p { margin-bottom: 0.9rem; }
.panel__body > p:last-child { margin-bottom: 0; }
.panel--danger { border-color: var(--danger); }
.panel--accent { border-color: var(--a); }

.panel__hint {
  font-size: 0.8125rem;
  color: var(--fg-3);
}

/* ── Buttons (weather's Btn: uppercase, hairline, inverts on hover) ── */

.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  padding: 0.8rem 1.4rem;
  border: 1px solid var(--fg);
  border-radius: var(--radius);
  background: transparent;
  color: var(--fg);
  font-family: var(--font-sans);
  font-size: 0.8125rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  cursor: pointer;
  text-decoration: none;
  transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}
.btn:hover { text-decoration: none; }
.btn:disabled { opacity: 0.5; cursor: not-allowed; }
.btn--default:hover:not(:disabled), .btn:not([class*="btn--"]):hover:not(:disabled) {
  background: var(--fg);
  color: var(--bg);
}
.btn--primary { background: var(--a); border-color: var(--a); color: var(--on-accent); }
.btn--primary:hover:not(:disabled) { background: transparent; color: var(--a); }
.btn--danger { border-color: var(--danger); color: var(--danger); }
.btn--danger:hover:not(:disabled) { background: var(--danger); color: var(--surface); }
.btn--sm { padding: 0.45rem 0.85rem; font-size: 0.6875rem; }
.btn iconify-icon { font-size: 1.05em; }

/* ── Forms ── */

.field { margin-bottom: 1rem; }
.field > .label { display: block; margin-bottom: 0.45rem; }
.field__hint { margin-top: 0.4rem; font-size: 0.8125rem; color: var(--fg-3); }

input[type="text"], input[type="url"], input[type="search"], input[type="email"],
input[type="number"], input[type="password"], select, textarea {
  width: 100%;
  padding: 0.65rem 0.85rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--fg);
  font-family: var(--font-sans);
  font-size: 0.9375rem;
  transition: border-color 0.2s ease;
}
input:hover, select:hover, textarea:hover { border-color: var(--fg-3); }
input:focus, select:focus, textarea:focus { outline: 2px solid var(--a); outline-offset: -1px; border-color: var(--a); }
input::placeholder, textarea::placeholder { color: var(--fg-3); }
textarea { resize: vertical; line-height: 1.5; }

.form-row {
  display: flex;
  gap: 0.6rem;
  align-items: stretch;
  flex-wrap: wrap;
}
.form-row > input, .form-row > select { flex: 1 1 12rem; width: auto; }
.form-row > .btn { flex-shrink: 0; }
.form-row + .form-row { margin-top: 0.6rem; }
.input--narrow { max-width: 16rem; }

/* ── Tables ── */

.table-scroll { overflow-x: auto; }
.tbl { width: 100%; border-collapse: collapse; font-size: 0.875rem; }
.tbl th {
  text-align: left;
  padding: 0.6rem 0.9rem;
  border-bottom: 1px solid var(--line);
  font-family: var(--font-mono);
  font-size: 0.6875rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--fg-3);
  white-space: nowrap;
}
.tbl td { padding: 0.7rem 0.9rem; border-bottom: 1px solid var(--line-soft); vertical-align: top; }
.tbl tr:last-child td { border-bottom: 0; }
.cell-right { text-align: right; }
.cell-break { word-break: break-all; }
.inline-form { display: inline-block; margin: 0; }

/* ── Chips (weather's SeverityChip: bordered box, dot, mono uppercase) ── */

.chip {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.25rem 0.6rem;
  border: 1px solid var(--line);
  background: var(--surface);
  font-family: var(--font-mono);
  font-size: 0.6875rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--fg-3);
}
.chip::before {
  content: "";
  width: 0.4rem;
  height: 0.4rem;
  border-radius: 9999px;
  background: currentColor;
}
.chip--public { color: var(--a); border-color: rgba(var(--a-rgb), 0.5); }
.chip--ok { color: var(--ok); }
.chip--danger { color: var(--danger); }

/* ── Notices (fresh key, saved, purged) ── */

.notice {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  border: 1px solid var(--line);
  border-left: 3px solid var(--a);
  background: var(--surface);
  padding: 1rem 1.1rem;
  margin-bottom: 1.5rem;
}
.notice--ok { border-left-color: var(--ok); }
.notice--warn { border-left-color: var(--warn); }
.notice--danger { border-left-color: var(--danger); }
.notice__title {
  font-family: var(--font-mono);
  font-size: 0.6875rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: var(--fg-3);
}
.notice__body { font-size: 0.9375rem; color: var(--fg-2); }

/* ── Empty state ── */

.empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
  padding: 3rem 1.5rem;
  text-align: center;
}
.empty-state iconify-icon { font-size: 1.75rem; color: var(--fg-3); }
.empty-state__message { max-width: 24rem; font-size: 0.9375rem; color: var(--fg-2); }

/* ── Progress ── */

.progress { width: 100%; height: 0.5rem; background: var(--surface-2); border: 1px solid var(--line); }
.progress__bar { height: 100%; background: var(--a); transition: width 0.4s ease; }

/* ── Toasts (bottom-right, hairline, accent edge) ── */

.toasts {
  position: fixed;
  bottom: 1.25rem;
  right: 1.25rem;
  z-index: 100;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  max-width: min(22rem, calc(100vw - 2.5rem));
}
.toast {
  border: 1px solid var(--line);
  border-left: 3px solid var(--a);
  background: var(--surface);
  box-shadow: var(--shadow);
  padding: 0.7rem 1rem;
  font-size: 0.875rem;
  color: var(--fg);
  animation: toast-in 0.25s ease;
}
.toast--ok { border-left-color: var(--ok); }
.toast--warn { border-left-color: var(--warn); }
.toast--error { border-left-color: var(--danger); }
@keyframes toast-in { from { transform: translateY(0.5rem); opacity: 0; } to { transform: none; opacity: 1; } }

/* ── Dashboard: filter row ── */

.filterbar .form-row > input:first-child { flex: 2 1 16rem; }
.filterbar select { flex: 0 1 10rem; }

/* ── Dashboard: drop zone ── */

.drop-zone {
  border: 1px dashed var(--line);
  background: transparent;
  text-align: center;
  padding: 2rem 1.5rem;
  margin-bottom: 1.5rem;
  cursor: pointer;
  transition: border-color 0.2s ease, background-color 0.2s ease;
  color: var(--fg-3);
  font-size: 0.9375rem;
}
.drop-zone:hover, .drop-zone:focus-visible { border-color: var(--fg-3); }
.drop-zone.is-drag { border-color: var(--a); background: rgba(var(--a-rgb), 0.06); }
.drop-zone p { margin: 0; }
.drop-zone .btn { margin-inline: 0.35rem; }
.drop-status { margin-top: 0.5rem; font-family: var(--font-mono); font-size: 0.6875rem; text-transform: uppercase; letter-spacing: 0.1em; }

/* ── Dashboard: screenshot grid ── */

.shot-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(15rem, 1fr));
  gap: 1rem;
}
.shot {
  border: 1px solid var(--line);
  background: var(--surface);
  display: flex;
  flex-direction: column;
  transition: border-color 0.2s ease;
}
.shot:hover { border-color: var(--fg); }
.shot-img {
  display: flex;
  aspect-ratio: 16 / 10;
  background: var(--surface-2);
  align-items: center;
  justify-content: center;
  overflow: hidden;
  border-bottom: 1px solid var(--line);
}
.shot-img img { width: 100%; height: 100%; object-fit: cover; }
.shot-meta {
  padding: 0.7rem 0.9rem;
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  font-family: var(--font-mono);
  font-size: 0.6875rem;
  letter-spacing: 0.04em;
  color: var(--fg-3);
}
.shot-meta__top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.5rem;
  text-transform: uppercase;
  color: var(--fg-2);
}
.shot-meta__actions { display: inline-flex; align-items: center; gap: 0.5rem; }
.shot-copy {
  display: inline-flex;
  background: none;
  border: none;
  padding: 0.15rem;
  color: var(--fg-3);
  cursor: pointer;
  font-size: 1rem;
}
.shot-copy:hover { color: var(--a); }
.shot-src { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* ── Settings ── */

.settings-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(18rem, 1fr));
  gap: 1.5rem;
}
.settings-grid .panel { margin-bottom: 1.5rem; }

.key-display { display: flex; gap: 0.6rem; align-items: stretch; margin: 0.6rem 0; }
.key-display input { flex: 1; font-family: var(--font-mono); font-size: 0.8125rem; }

.install-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(20rem, 1fr));
  gap: 1rem;
}
.install-item { border: 1px solid var(--line); background: var(--surface-2); padding: 1.1rem; }
.install-item h3 {
  font-family: var(--font-mono);
  font-size: 0.6875rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: var(--fg-3);
}
.install-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: wrap;
  margin-bottom: 0.75rem;
}
.install-note { margin: 0 0 0.75rem; font-size: 0.8125rem; color: var(--fg-3); }
.install-steps {
  margin: 0.5rem 0 0;
  padding-left: 1.25rem;
  line-height: 1.65;
  font-size: 0.875rem;
  color: var(--fg-2);
}
.install-steps li { margin-bottom: 0.5rem; }
.install-steps code { background: var(--surface); border: 1px solid var(--line-soft); padding: 1px 5px; }
.env-block {
  background: var(--surface);
  border: 1px solid var(--line);
  padding: 0.75rem;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  margin: 0.5rem 0 0;
  overflow-x: auto;
}

/* ── Login ── */

.login-shell {
  min-height: 100dvh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--pad);
}
.login-card {
  width: 100%;
  max-width: 24rem;
  border: 1px solid var(--line);
  background: var(--surface);
  padding: 2.5rem 2rem;
  box-shadow: var(--shadow);
}
.login-card .brand { margin-bottom: 0.9rem; }
.login-kicker {
  font-family: var(--font-mono);
  font-size: 0.6875rem;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: var(--a);
  margin-bottom: 0.6rem;
}
.login-lede { font-size: 0.9375rem; color: var(--fg-2); margin-bottom: 1.5rem; }
.login-card .btn { width: 100%; justify-content: center; }
.login-card .notice { margin-bottom: 1rem; }

/* ── Share view ── */

.share-wrap { max-width: 69rem; margin-inline: auto; }
.share-img {
  border: 1px solid var(--line);
  background: var(--surface);
  padding: 0.75rem;
  margin-bottom: 1rem;
}
.share-img img { display: block; max-width: 100%; height: auto; margin-inline: auto; }
.share-actions { display: flex; gap: 0.6rem; flex-wrap: wrap; margin-bottom: 1.5rem; }
.ocr-block {
  white-space: pre-wrap;
  word-break: break-word;
  background: var(--surface-2);
  border: 1px solid var(--line-soft);
  padding: 1rem;
  font-family: var(--font-mono);
  font-size: 0.8125rem;
  margin: 0;
}

/* ── Connect (extension pairing) ── */

.connect-wrap { max-width: 34rem; margin-inline: auto; }
.pair-code {
  font-family: var(--font-mono);
  font-size: clamp(1.75rem, 6vw, 2.5rem);
  font-weight: 700;
  letter-spacing: 0.14em;
  text-align: center;
  color: var(--a);
  border: 1px solid var(--line);
  background: var(--surface-2);
  padding: 1.1rem;
  margin-bottom: 1rem;
  user-select: all;
}
.pair-code-input {
  font-family: var(--font-mono);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  max-width: 12rem;
}
.pair-details { margin: 0 0 1rem; font-size: 0.875rem; }
.pair-details > div { display: flex; gap: 0.75rem; margin-bottom: 0.25rem; }
.pair-details dt {
  font-family: var(--font-mono);
  font-size: 0.6875rem;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--fg-3);
  min-width: 4.5rem;
  padding-top: 0.15rem;
}
.pair-details dd { color: var(--fg-2); }

/* ── Motion safety ── */

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
}
