/* The pages behind the home page: sign-in, the lab's account, approving a PC, the install guide and privacy.
   Same world as site.css (loaded before this file): the night stage for the two short trust moments
   (sign in, approve a PC), the lab's daylight for the pages a person reads or works in. */

body.page-day { background: var(--day); color: var(--ink); scrollbar-color: var(--teal) var(--day); }
body.page-day .top { background: rgba(3, 27, 31, .94); }
body.page-auth { min-block-size: 100svh; display: flex; flex-direction: column; }
.day :focus-visible, .page-day main :focus-visible, .auth-card :focus-visible { outline-color: var(--teal); }

.demo-ribbon {
  margin-block-start: var(--head); padding: 8px var(--gutter);
  background: var(--yellow); color: var(--ink); font-size: .875rem; font-weight: 500; text-align: center;
}
.demo-ribbon a { font-weight: 600; }
.demo-ribbon :focus-visible { outline-color: var(--ink); }

/* ---------- reading and working pages ---------- */
.page-main { flex: 1; padding: 48px var(--gutter) 96px; }
.page-main > * { max-inline-size: var(--max); margin-inline: auto; }
.page-head { margin-block-end: 48px; }
.page-head h1 { font-weight: 280; font-size: clamp(2.25rem, 1.2rem + 4vw, 4.25rem); line-height: 1.25; text-wrap: balance; }
.page-head h1 strong { font-weight: 600; color: var(--rasp); }
.page-head p { margin-block-start: 14px; color: var(--muted); font-size: clamp(1.0625rem, 1rem + .3vw, 1.25rem); max-inline-size: 40rem; text-wrap: pretty; }
.page-main h2 { font-weight: 500; font-size: clamp(1.375rem, 1.15rem + 1vw, 1.875rem); line-height: 1.35; }
.page-main .note { color: var(--muted); font-size: .9375rem; }
.card {
  padding: 26px; border-radius: var(--r-tile); background: rgba(255, 255, 255, .82);
  box-shadow: 0 1px 0 #fff inset, 0 18px 36px -26px rgba(22, 106, 115, .4);
  outline: 1px solid #fff; outline-offset: -1px;
}
.card h2 { margin-block-end: 12px; }
.card p { color: var(--muted); }
.card p + p { margin-block-start: 8px; }

/* buttons that live on light ground */
.btn-line { min-block-size: 44px; padding: 8px 18px; color: var(--teal); background: rgba(22, 106, 115, .1); font-size: .9375rem; transition: background-color .2s; }
.btn-line:hover { background: rgba(22, 106, 115, .16); }
.btn-danger-quiet { min-block-size: 44px; padding: 6px 16px; color: #9B1C1C; background: rgba(180, 35, 24, .08); font-size: .9375rem; border: 0; font-family: inherit; cursor: pointer; transition: background-color .2s; }
.btn-danger-quiet:hover { background: rgba(180, 35, 24, .14); }

/* ---------- forms ---------- */
.field { display: grid; gap: 6px; }
.field + .field { margin-block-start: 16px; }
.field label { font-weight: 500; font-size: .9375rem; }
.field input {
  inline-size: 100%; min-block-size: 52px; padding: 10px 16px; border-radius: 14px;
  font: 400 1rem/1.4 var(--sans); color: var(--ink); background: #fff;
  border: 1px solid #7B979E; transition: border-color .2s, box-shadow .2s;
}
.field input[dir="ltr"] { text-align: left; }
.field input:focus { outline: 2px solid var(--teal); outline-offset: 2px; border-color: var(--teal); }
.field .hint { font-size: .8125rem; color: var(--muted); }
.form-actions { margin-block-start: 22px; }
.form-actions .cta { inline-size: 100%; justify-content: center; padding-inline: 24px; }
button.cta { border: 0; cursor: pointer; }

/* ---------- sign in and approve a PC: one card on the night stage ---------- */
.auth-stage {
  position: relative; isolation: isolate; flex: 1;
  display: grid; place-items: center; padding: 40px var(--gutter) 64px;
}
.auth-stage::before {
  content: ''; position: absolute; z-index: -1; inset: 0; pointer-events: none;
  background:
    radial-gradient(40% 40% at 50% 18%, rgba(63, 199, 211, .22), transparent 70%),
    radial-gradient(40% 40% at 100% 100%, rgba(255, 92, 143, .1), transparent 72%);
}
.auth-card {
  inline-size: min(100%, 460px); padding: 32px 26px; border-radius: 26px;
  background: #fff; color: var(--ink);
  box-shadow: 0 50px 90px -40px rgba(0, 0, 0, .75), 0 0 0 1px rgba(255, 255, 255, .6);
}
.auth-card .mark { display: flex; align-items: center; gap: 10px; margin-block-end: 22px; font-weight: 600; }
.auth-card .mark img { border-radius: 9px; }
.auth-card h1 { font-weight: 300; font-size: clamp(1.75rem, 1.4rem + 1.4vw, 2.375rem); line-height: 1.3; }
.auth-card h1 strong { font-weight: 600; color: var(--rasp); }
.auth-card .sub { margin-block: 8px 24px; color: var(--muted); }
.auth-links { margin-block-start: 22px; display: grid; gap: 10px; font-size: .9375rem; color: var(--muted); }
.auth-links a { color: var(--teal); font-weight: 500; }
.auth-sep { margin-block: 22px 0; padding-block-start: 18px; border-block-start: 1px solid var(--line); }

.facts { display: grid; gap: 0; margin: 0 0 24px; border-radius: 16px; background: var(--day); }
.facts > div { display: flex; justify-content: space-between; gap: 16px; padding: 14px 18px; }
.facts > div + div { border-block-start: 1px solid var(--line); }
.facts dt { color: var(--muted); font-weight: 400; }
.facts dd { margin: 0; font-weight: 600; text-align: end; }
.choice { display: grid; gap: 10px; }
.choice .cta { inline-size: 100%; justify-content: center; padding-inline: 24px; }
.cta-plain { color: var(--teal); background: rgba(22, 106, 115, .1); }
.cta-plain:hover { background: rgba(22, 106, 115, .16); }
.warn-line { margin-block-start: 18px; font-size: .875rem; color: var(--muted); }

/* the answer replaces the question (no script: the link targets the answer) */
.state { display: none; text-align: center; }
.state:target { display: block; }
.state:focus { outline: none; }
.auth-card:has(.state:target) .ask { display: none; }
.state .badge { inline-size: 64px; block-size: 64px; margin: 4px auto 18px; display: grid; place-items: center; border-radius: 50%; }
.state .badge svg { inline-size: 30px; block-size: 30px; fill: none; stroke: currentColor; stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }
.state.ok .badge { color: #fff; background: #1F7A5A; }
.state.no .badge { color: #fff; background: var(--muted); }
.state p { color: var(--muted); }
.code-sm { font-size: 1.0625rem; margin: 0; padding: 4px 12px; background: #fff; }
.facts .match dd { display: flex; align-items: center; }
.code { display: inline-block; margin-block: 14px 6px; padding: 10px 20px; border-radius: 12px; background: var(--day); font: 600 1.375rem/1.2 var(--sans); letter-spacing: .12em; direction: ltr; }

/* ---------- the account ---------- */
.account-grid { display: grid; gap: 16px; }
.status { display: inline-flex; align-items: center; gap: 8px; padding: 4px 12px; border-radius: 999px; font-size: .875rem; font-weight: 600; color: var(--teal); background: rgba(63, 199, 211, .18); }
.status::before { content: ''; inline-size: 8px; block-size: 8px; border-radius: 50%; background: var(--teal-light); }
.big-date { margin-block: 10px 6px; font-weight: 300; font-size: clamp(1.75rem, 1.3rem + 1.6vw, 2.5rem); line-height: 1.25; color: var(--ink); }
.download { background: var(--night); color: var(--on-night); outline-color: rgba(255, 255, 255, .06); position: relative; overflow: hidden; }
.download p { color: var(--on-night-muted); }
.download .product { display: flex; align-items: center; gap: 14px; margin-block-end: 18px; }
.download .product img { border-radius: 12px; }
.download .product .product-name { display: block; margin: 0; font-size: 1.25rem; font-weight: 600; color: var(--on-night); }
.download .product .todo { color: var(--ink); }
.download .note { color: var(--on-night-muted); }
.page-day main .download :focus-visible { outline-color: var(--teal-light); }
.download .product span { font-size: .9375rem; color: var(--on-night-muted); }
.download .cta { margin-block: 18px 12px; }
.download a.more { color: var(--teal-light); font-weight: 500; }
.download .todo { font-size: .8125rem; }
.devices { list-style: none; padding: 0; margin-block: 6px 14px; }
.devices li { display: flex; align-items: center; gap: 14px; padding-block: 14px; }
.devices li + li { border-block-start: 1px solid var(--line); }
.devices .ic { flex: none; inline-size: 44px; block-size: 44px; display: grid; place-items: center; border-radius: 12px; color: #fff; background: var(--teal); }
.devices .ic svg { inline-size: 22px; block-size: 22px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.devices .who { flex: 1; min-inline-size: 0; }
.devices .who b { display: block; font-weight: 600; }
.devices .who span { font-size: .875rem; color: var(--muted); }

/* ---------- the install guide ---------- */
.install { list-style: none; padding: 0; counter-reset: s; display: grid; gap: 20px; }
.install > li { counter-increment: s; display: grid; gap: 18px; padding: 26px; border-radius: var(--r-tile); background: rgba(255, 255, 255, .82); box-shadow: 0 1px 0 #fff inset, 0 18px 36px -26px rgba(22, 106, 115, .4); }
.install h2 { display: flex; align-items: center; gap: 14px; }
.install h2::before {
  content: counter(s); flex: none; inline-size: 40px; block-size: 40px; display: grid; place-items: center; border-radius: 50%;
  font: 600 1.0625rem/1 var(--sans); color: #fff; background: var(--rasp);
}
.install p { color: var(--muted); max-inline-size: 36rem; }
.install p + p { margin-block-start: 8px; }
.install .visual { border-radius: 18px; background: var(--day); padding: 18px; display: grid; place-items: center; }
.file-pill { display: inline-flex; align-items: center; gap: 12px; padding: 12px 18px; border-radius: 14px; background: #fff; box-shadow: 0 10px 24px -16px rgba(22, 106, 115, .5); direction: ltr; font: 500 .9375rem/1.3 var(--sans); }
.file-pill img { border-radius: 8px; }

/* Windows' blue warning, drawn as a guide (labelled on the page) */
.smartscreen { inline-size: min(100%, 420px); padding: 22px 22px 18px; background: #0B5CAB; color: #fff; direction: ltr; text-align: left; font-family: 'Segoe UI', var(--sans); border-radius: 4px; box-shadow: 0 24px 40px -24px rgba(0, 0, 0, .6); }
.smartscreen .t { font-size: 1.375rem; font-weight: 300; margin-block-end: 10px; }
.smartscreen .d { font-size: .8125rem; line-height: 1.5; opacity: .92; }
.smartscreen .link { display: inline-block; margin-block: 10px 18px; font-size: .8125rem; text-decoration: underline; }
.smartscreen .bar { display: flex; justify-content: flex-end; gap: 8px; }
.smartscreen .b { padding: 6px 18px; font-size: .8125rem; border: 1px solid rgba(255, 255, 255, .9); }
.smartscreen .b.hl, .smartscreen .link.hl { outline: 3px solid var(--yellow); outline-offset: 3px; }
.smartscreen { position: relative; }
.guide-tag { position: absolute; inset-block-start: 8px; inset-inline-end: 8px; padding: 2px 8px; border-radius: 4px; background: var(--yellow); color: var(--ink); font: 600 .75rem/1.4 var(--sans); }
.guide-label { margin-block-start: 10px; font-size: .8125rem; color: var(--muted); text-align: center; }
.two-shots { display: grid; gap: 16px; }

/* ---------- privacy ---------- */
.columns { display: grid; gap: 16px; }
.ticks { list-style: none; padding: 0; margin-block-start: 6px; }
.ticks li { display: flex; gap: 12px; padding-block: 10px; }
.ticks li + li { border-block-start: 1px solid var(--line); }
.ticks svg { flex: none; inline-size: 22px; block-size: 22px; margin-block-start: 3px; fill: none; stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }
.ticks.never svg { stroke: #9B1C1C; }
.ticks.only svg { stroke: #1F7A5A; }
.ticks b { font-weight: 600; }
.ticks span { color: var(--muted); }
.card.never { background: #fff; }
.prose { margin-block-start: 48px; display: grid; gap: 28px; }
.prose section { max-inline-size: 44rem; }
.prose p { color: var(--muted); margin-block-start: 8px; }

@media (min-width: 900px) {
  .page-main { padding-block: 72px 120px; }
  .page-head h1 { font-weight: 200; }
  .auth-card h1 { font-weight: 300; }
  .account-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .install > li { grid-template-columns: minmax(0, 6fr) minmax(0, 5fr); align-items: center; gap: 36px; padding: 34px; }
  .two-shots { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .install > li.wide { grid-template-columns: minmax(0, 1fr); }
  .install > li.wide .smartscreen { inline-size: min(100%, 460px); }
  .columns { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .auth-card { padding: 40px 36px; }
}

.after-head { margin-block-start: var(--head); }

/* ---------- live pages (wired to the server) ---------- */
.form-alert { min-block-size: 1.2em; margin-block-start: 12px; font-size: .9375rem; font-weight: 500; color: #9B1C1C; }
.form-alert:empty { margin: 0; min-block-size: 0; }
#pw-status, #dl-status { color: var(--muted); }
.download #dl-status { color: var(--on-night-muted); }
button.cta:disabled { opacity: .55; cursor: not-allowed; box-shadow: none; }
button.cta[aria-busy="true"] { opacity: .7; cursor: progress; }
.is-loading .loading-line, .is-loading #sub-date, .is-loading #sub-status { color: transparent; background: rgba(22, 106, 115, .08); border-radius: 8px; }
.status[data-state="grace"] { color: #9A3412; background: #FBE7DC; }
.status[data-state="grace"]::before { background: #E8590C; }
.status[data-state="read_only"], .status[data-state="stopped"] { color: var(--muted); background: rgba(78, 106, 114, .12); }
.status[data-state="read_only"]::before, .status[data-state="stopped"]::before { background: var(--muted); }
.devices .empty { color: var(--muted); padding-block: 10px; }
.devices li.removed .ic { background: #8FA6AC; }
.devices li.removed .who b { color: var(--muted); }
.sha { overflow-wrap: anywhere; }
.sha code { font: 500 .75rem/1.5 ui-monospace, Consolas, monospace; color: var(--on-night); }
dialog#remove-dialog {
  inline-size: min(92vw, 420px); padding: 26px; border: 0; border-radius: 22px;
  color: var(--ink); background: #fff; box-shadow: 0 40px 80px -30px rgba(3, 27, 31, .6);
}
dialog#remove-dialog::backdrop { background: rgba(3, 27, 31, .55); }
dialog#remove-dialog h2 { font-weight: 500; font-size: 1.25rem; margin-block-end: 8px; }
dialog#remove-dialog p { color: var(--muted); }
.dialog-actions { display: flex; gap: 10px; margin-block-start: 18px; }
