/* app.getxposed.link: the accounts dashboard. Same Exposure language as the
   daemon's pages and the marketing site (film base, colour only as light, a
   viewfinder HUD) - see internal/web/assets/xposed.css, which this borrows
   its tokens and a few components from. There is no script on this page at
   all (spec: accounts design §Dashboard, "no inline script"), so nothing
   here depends on a `js` class ever being added to <html>. */

@font-face {
  font-family: "Archivo XP";
  src: url("/_cloud/fonts/archivo-latin-wdth-normal.woff2") format("woff2-variations"),
       url("/_cloud/fonts/archivo-latin-wdth-normal.woff2") format("woff2");
  font-weight: 100 900;
  font-stretch: 62% 125%;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Martian Mono XP";
  src: url("/_cloud/fonts/martian-mono-latin-wdth-normal.woff2") format("woff2-variations"),
       url("/_cloud/fonts/martian-mono-latin-wdth-normal.woff2") format("woff2");
  font-weight: 100 800;
  font-stretch: 75% 112.5%;
  font-style: normal;
  font-display: swap;
}

:root {
  --film: #0A0B0D;
  --paper: #F3F5F7;
  --silver: #BFC4CB;
  --halation: #FF4A2E;
  --safelight: #FF9A1F;
  --signal: #E5484D;
  --dim: #8A909A;
  --rule: rgba(191, 196, 203, .16);
  --sans: "Archivo XP", system-ui, sans-serif;
  --mono: "Martian Mono XP", ui-monospace, "SFMono-Regular", Menlo, monospace;
  --halo: 0 0 .07em rgba(255, 74, 46, .55), 0 0 .2em rgba(255, 74, 46, .22);
  --gutter: clamp(20px, 5vw, 72px);
  --hud: clamp(10px, 1.4vw, 22px);
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
body {
  margin: 0;
  min-height: 100vh;
  min-height: 100svh;
  background: var(--film);
  color: var(--paper);
  font: 400 17px/1.55 var(--sans);
  font-stretch: 100%;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
h1, h2, p, ul, ol, dl, dd, table { margin: 0; }
ul, ol { padding: 0; list-style: none; }
a { color: inherit; }
::selection { background: rgba(255, 154, 31, .35); color: #fff; }
:focus-visible { outline: 2px solid var(--silver); outline-offset: 3px; }
.mono { font-family: var(--mono); font-stretch: 87%; letter-spacing: .1em; }

/* ---------- viewfinder HUD ---------- */
.hud {
  position: fixed; inset: var(--hud); z-index: 50;
  pointer-events: none;
  font: 400 10px/1.4 var(--mono); font-stretch: 87%;
  letter-spacing: .14em;
  color: var(--silver);
}
.hud .c { position: absolute; width: 20px; height: 20px; border: 0 solid rgba(243, 245, 247, .5); }
.hud .tl { left: 0; top: 0; border-left-width: 1px; border-top-width: 1px; }
.hud .tr { right: 0; top: 0; border-right-width: 1px; border-top-width: 1px; }
.hud .bl { left: 0; bottom: 0; border-left-width: 1px; border-bottom-width: 1px; }
.hud .br { right: 0; bottom: 0; border-right-width: 1px; border-bottom-width: 1px; }
.hud-tl, .hud-tr, .hud-bl, .hud-br { position: absolute; white-space: nowrap; }
.hud-tl { left: 32px; top: -1px; }
.hud-tr { right: 32px; top: -1px; }
.hud-bl { left: 32px; bottom: -2px; }
.hud-br { right: 32px; bottom: -2px; }
@media (max-width: 860px) { .hud-bl, .hud-br { display: none; } }

/* ---------- layout ---------- */
.page {
  position: relative; z-index: 1;
  width: 100%; max-width: 880px;
  margin: 0 auto;
  padding: calc(var(--hud) + 52px) var(--gutter) calc(var(--hud) + 64px);
}
.bar {
  display: flex; justify-content: space-between; align-items: baseline; gap: 16px;
  margin-bottom: clamp(32px, 7vh, 72px);
}
.mark { font-size: 30px; line-height: 1; font-weight: 900; font-stretch: 125%; letter-spacing: -.012em; text-shadow: var(--halo); }
.bar-note { font-size: 10.5px; color: var(--dim); }
.headline { font-size: clamp(34px, 5vw, 60px); line-height: 1; font-weight: 820; font-stretch: 112%; letter-spacing: -.016em; text-wrap: balance; }
.sub { max-width: 34em; margin-top: 16px; font-size: clamp(16px, 1.3vw, 18px); color: var(--silver); text-wrap: pretty; }

/* ---------- buttons and forms ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 48px; padding: 0 20px;
  border: 0; border-radius: 0;
  background: var(--paper); color: var(--film);
  font: 500 11.5px/1 var(--mono); font-stretch: 87%;
  letter-spacing: .14em; text-transform: uppercase; text-decoration: none;
  white-space: nowrap; cursor: pointer;
  transition: background-color .2s, box-shadow .3s;
}
.btn:hover { background: #fff; box-shadow: 0 0 0 1px #fff, 0 0 30px rgba(255, 74, 46, .35); }
.btn-ghost { background: transparent; color: var(--paper); box-shadow: inset 0 0 0 1px rgba(243, 245, 247, .35); }
.btn-ghost:hover { background: rgba(243, 245, 247, .07); box-shadow: inset 0 0 0 1px var(--paper); }
.btn-danger-ghost { background: transparent; color: #FF8A80; box-shadow: inset 0 0 0 1px rgba(229, 72, 77, .55); }
.btn-danger-ghost:hover { background: rgba(229, 72, 77, .08); box-shadow: inset 0 0 0 1px var(--signal); }
form.inline { display: inline; }

.signin { display: flex; flex-wrap: wrap; gap: 14px; margin-top: clamp(32px, 6vh, 56px); }

/* ---------- account status ---------- */
.status {
  margin-top: clamp(28px, 5vh, 48px);
  padding: clamp(18px, 3vw, 26px);
  border: 1px solid var(--rule);
  background: linear-gradient(180deg, rgba(255, 255, 255, .025), transparent 60%);
}
.status-email { font-size: 10.5px; color: var(--dim); }
.status-line { margin-top: 8px; font-size: clamp(17px, 2vw, 21px); }
.status-line.is-waitlist { color: var(--silver); }
.status-line.is-in b { color: var(--safelight); text-shadow: 0 0 12px rgba(255, 154, 31, .45); }

/* ---------- install instructions ---------- */
.install { margin-top: clamp(28px, 5vh, 48px); }
.steps { margin-top: 12px; display: grid; gap: 22px; }
.step { display: grid; grid-template-columns: 22px minmax(0, 1fr); gap: 14px; }
.step-num {
  display: flex; align-items: center; justify-content: center;
  width: 22px; height: 22px; margin-top: 2px;
  border: 1px solid var(--rule);
  font-size: 10.5px; color: var(--silver);
}
.step-body { min-width: 0; }
.step-cmd { display: flex; align-items: stretch; gap: 8px; }
.step-cmd pre { flex: 1 1 auto; min-width: 0; margin: 0; }
.step-note { margin-top: 10px; font-size: 13.5px; color: var(--silver); }
.step-note b { color: var(--paper); font-weight: 600; }
.install pre {
  margin: 0;
  padding: 16px 18px;
  overflow-x: auto;
  background: rgba(243, 245, 247, .04);
  border: 1px solid var(--rule);
  font: 13px/1.6 var(--mono);
  font-stretch: 87%;
  color: var(--paper);
}
code { font-family: var(--mono); font-stretch: 87%; color: var(--paper); background: rgba(243, 245, 247, .06); padding: 2px 6px; }
.install pre code { background: none; padding: 0; }

.copy-icon-btn {
  flex: 0 0 auto;
  display: inline-flex; align-items: center; justify-content: center;
  width: 48px; height: auto;
  border: 1px solid var(--rule);
  background: transparent; color: var(--silver);
  cursor: pointer;
  transition: background-color .2s, color .2s, box-shadow .2s;
}
.copy-icon-btn:hover { color: var(--paper); background: rgba(243, 245, 247, .07); box-shadow: inset 0 0 0 1px var(--paper); }
.copy-icon-btn .icon { width: 18px; height: 18px; }
.copy-icon-btn .icon-check { display: none; }
.copy-icon-btn.is-copied { color: var(--safelight); box-shadow: inset 0 0 0 1px var(--safelight); }
.copy-icon-btn.is-copied .icon-copy { display: none; }
.copy-icon-btn.is-copied .icon-check { display: block; }

/* ---------- computers ---------- */
.section-title { display: flex; align-items: baseline; gap: 10px; margin: clamp(48px, 8vh, 88px) 0 14px; font-size: 10.5px; font-weight: 400; color: var(--dim); }
.count-badge {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 20px; height: 20px; padding: 0 6px;
  border: 1px solid var(--rule);
  color: var(--silver);
  font-size: 10px;
}
.computers { display: grid; gap: 1px; background: var(--rule); border: 1px solid var(--rule); }
.computer {
  display: grid; grid-template-columns: minmax(0, 1fr) auto;
  align-items: center; gap: 16px;
  padding: 16px 18px;
  background: var(--film);
}
.computer-name { font-size: 16px; overflow-wrap: anywhere; }
.computer-meta { margin-top: 4px; font-size: 10.5px; color: var(--silver); }
.computer-meta a { color: var(--silver); text-decoration: underline; text-underline-offset: 3px; }
.computer-meta a:hover { color: var(--paper); }
.computer.is-revoked { opacity: .5; }
.computer.is-revoked .computer-meta b { color: #FF8A80; }
.empty-note { padding: 20px 0; font-size: 10.5px; color: var(--dim); }

/* ---------- plan + usage meter ---------- */
.plan-row { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-top: 8px; }
.plan-name { font-size: clamp(17px, 2vw, 21px); }
.plan-name b { color: var(--safelight); text-shadow: 0 0 12px rgba(255, 154, 31, .45); }
.plan-meta { font-size: 10.5px; color: var(--dim); }
.plan-actions { display: flex; gap: 10px; margin-top: 16px; flex-wrap: wrap; }
.meter { margin-top: 18px; }
.meter-label { display: flex; justify-content: space-between; font-size: 10.5px; color: var(--dim); margin-bottom: 6px; }
.meter-track { height: 4px; background: var(--rule); }
.meter-fill { height: 100%; background: var(--safelight); box-shadow: 0 0 10px rgba(255, 154, 31, .5); }
.meter-fill.is-over { background: var(--signal); box-shadow: 0 0 10px rgba(229, 72, 77, .5); }

/* ---------- invite a friend ---------- */
.invite-error {
  margin-bottom: 14px;
  padding: 12px 14px;
  border: 1px solid rgba(229, 72, 77, .4);
  background: rgba(229, 72, 77, .08);
  color: #FF8A80;
  font-size: 10.5px;
}
.invite-share { margin-bottom: 22px; }
.invite-share-label { margin-bottom: 8px; font-size: 10.5px; color: var(--dim); }
.invite-share .step-cmd pre { background: rgba(255, 154, 31, .05); border-color: rgba(255, 154, 31, .3); }
.referrals { display: grid; gap: 1px; background: var(--rule); border: 1px solid var(--rule); margin-bottom: 18px; }
.referral {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 12px 16px;
  background: var(--film);
  font-size: 14px;
}
.referral-email { overflow-wrap: anywhere; }
.referral-status { font-size: 10px; color: var(--silver); }
.referral-status.is-joined { color: var(--safelight); }
.invite-form { display: flex; flex-wrap: wrap; gap: 10px; }
.invite-input {
  flex: 1 1 240px; min-width: 0;
  height: 48px; padding: 0 16px;
  border: 1px solid var(--rule);
  background: rgba(243, 245, 247, .04);
  color: var(--paper);
  font: 15px var(--sans);
}
.invite-input:focus-visible { outline: 2px solid var(--silver); outline-offset: -2px; }
.invite-input::placeholder { color: var(--dim); }

.foot { margin-top: clamp(56px, 10vh, 96px); font-size: 10px; color: var(--dim); }

@media (max-width: 520px) {
  .hud-tr { display: none; }
  .computer { grid-template-columns: 1fr; }
  .step-cmd { flex-direction: column; }
  .copy-icon-btn { width: 100%; height: 40px; }
}
