/* Customer page: phone-first, client-led branding. Replace --client with the client's brand colour once approved. */
:root {
  --client: #1D3B66; --client-weak: #EEF2F7; --client-fg: #FFFFFF;
  --bg: #FFFFFF; --fg: #1B2328; --muted: #5D6A72; --line: #DCE3E7;
  --ok: #256C43; --bad: #A6261D; --bad-weak: #FBEAE8;
  --font: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --mono: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root { --bg: #11181C; --fg: #E6ECEF; --muted: #9AA8B0; --line: #2A363D; --client-weak: #1B2840; --bad-weak: #3A1A18; --bad: #F19189; --ok: #6BC491; color-scheme: dark; }
}
* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  background: var(--bg); color: var(--fg); font: 17px/1.5 var(--font);
  min-height: 100vh; display: flex; flex-direction: column;
}
.top {
  background: var(--client); color: var(--client-fg);
  padding: calc(16px + env(safe-area-inset-top, 0px)) max(20px, env(safe-area-inset-right, 0px)) 16px max(20px, env(safe-area-inset-left, 0px));
}
.brand { display: flex; align-items: center; gap: 10px; min-height: 30px; }
.brand img { height: 30px; width: auto; display: block; }
.wordmark { font-size: 22px; font-weight: 700; letter-spacing: .02em; }
.sub { margin: 2px 0 0; font-size: 13px; opacity: .85; }
main {
  flex: 1; width: 100%; max-width: 520px; margin: 0 auto;
  padding: 24px max(20px, env(safe-area-inset-right, 0px)) 24px max(20px, env(safe-area-inset-left, 0px));
  display: flex; flex-direction: column; gap: 16px;
}
h1 { font-size: 24px; line-height: 1.25; margin: 0; text-wrap: balance; }
p { margin: 0; }
.muted { color: var(--muted); font-size: 15px; }
.btn {
  font: inherit; font-weight: 600; font-size: 17px; width: 100%; min-height: 54px; padding: 14px;
  border-radius: 12px; border: 0; background: var(--client); color: var(--client-fg); cursor: pointer;
  display: flex; align-items: center; justify-content: center; text-align: center; position: relative; overflow: hidden;
}
.btn.alt { background: var(--client-weak); color: var(--client); }
@media (prefers-color-scheme: dark) { .btn.alt { color: #C7D6EE; } }
.btn:disabled { opacity: .45; cursor: not-allowed; }
.btn:focus-visible, input:focus-visible { outline: 3px solid var(--client); outline-offset: 2px; }
.btn input[type=file] { position: absolute; inset: 0; opacity: 0; cursor: pointer; font-size: 0; }
.code {
  font: 600 30px/1 var(--mono); letter-spacing: .35em; text-align: center; padding: 14px 10px;
  width: 100%; border: 2px solid var(--line); border-radius: 12px; background: var(--bg); color: var(--fg);
}
.err { color: var(--bad); background: var(--bad-weak); border-radius: 10px; padding: 10px 12px; font-size: 15px; }
.files { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--line); }
.files li { display: flex; gap: 10px; align-items: center; padding: 10px 0; border-bottom: 1px solid var(--line); font-size: 15px; }
.files .name { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.files .size { color: var(--muted); font-family: var(--mono); font-size: 13px; }
.files button { font: inherit; font-size: 14px; background: none; border: 0; color: var(--client); padding: 4px; cursor: pointer; }
@media (prefers-color-scheme: dark) { .files button { color: #C7D6EE; } }
.bar { height: 6px; background: var(--line); border-radius: 3px; overflow: hidden; width: 70px; }
.bar i { display: block; height: 100%; width: 0; background: var(--client); transition: width .2s; }
.tick { width: 64px; height: 64px; border-radius: 50%; background: var(--ok); color: #fff; display: flex; align-items: center; justify-content: center; font-size: 34px; align-self: center; }
.center { text-align: center; }
.foot {
  font-size: 12px; color: var(--muted); border-top: 1px solid var(--line);
  padding: 14px max(20px, env(safe-area-inset-right, 0px)) calc(14px + env(safe-area-inset-bottom, 0px)) max(20px, env(safe-area-inset-left, 0px));
  display: flex; flex-direction: column; gap: 4px; max-width: 520px; width: 100%; margin: 0 auto;
}
.foot a { color: inherit; }
.practice { margin: 8px 0 0; background: #FBEFD9; color: #6B4100; border-radius: 6px; padding: 6px 10px; font-size: 13px; font-weight: 600; }
