/* Same locked Direction 03 tokens as Studio. No separate theme. */
:root { color-scheme: light; }
* { box-sizing: border-box; }
[hidden] { display: none !important; }
body { margin: 0; min-height: 100dvh; background: var(--mc-canvas); color: var(--mc-text-primary); font: var(--mc-type-body-size)/var(--mc-type-body-line) var(--mc-font-sans); -webkit-font-smoothing: antialiased; }
.ts-header { min-height: 60px; padding: var(--mc-space-4) var(--mc-space-6); display: flex; flex-wrap: wrap; align-items: center; gap: var(--mc-space-3); border-bottom: 1px solid var(--mc-divider); }
.ts-header img { height: 22px; width: auto; max-width: 100%; }
.ts-badge { padding: var(--mc-space-1) var(--mc-space-2); background: var(--mc-surface-subtle); border-radius: var(--mc-radius-pill); color: var(--mc-text-secondary); font-size: var(--mc-type-meta-size); font-weight: 600; }
.ts-card { width: min(100%, 480px); margin: var(--mc-space-16) auto; padding: var(--mc-space-6); }
h1 { margin: 0 0 var(--mc-space-6); font-size: var(--mc-type-title-size); line-height: var(--mc-type-title-line); letter-spacing: -.03em; }
form { display: grid; gap: var(--mc-space-3); }
form p, section p { margin: 0 0 var(--mc-space-3); }
label { font-weight: 600; }
input { width: 100%; min-height: 44px; padding: var(--mc-space-3) var(--mc-space-4); font: inherit; border: 1px solid var(--mc-border); border-radius: var(--mc-radius-control); background: var(--mc-surface-subtle); color: inherit; }
#ts-code { font-size: var(--mc-type-title-size); letter-spacing: .3em; font-variant-numeric: tabular-nums; }
/* Shared button system v1.3, board match (Beta-01, 2026-10-19): the look of the Gauntlet's sign-in page. A signed-out visitor may load only /tokens.css, this sheet and /tester-sign-in.js, so the tokens
   and every rule are here, and the icons are an inline sprite in the page itself (beta/cloud/tester-auth.mjs). Values come from the one value sheet (BOARD-SPEC.md). */
:root { --mc-button-height: 44px; --mc-button-primary-height: 46px; --mc-button-padding-inline: 16px; --mc-button-label-size: 14px; --mc-button-label-line: 20px; --mc-button-label-weight: 600; --mc-button-icon-size: 18px; --mc-button-icon-gap: var(--mc-space-2); --mc-button-arrow-shift: 2px;
  --mc-btn-tint: color-mix(in srgb, var(--mc-pink) 5%, var(--mc-canvas)); --mc-btn-tint-hover: color-mix(in srgb, var(--mc-pink) 9%, var(--mc-canvas)); --mc-btn-tint-border: color-mix(in srgb, var(--mc-pink) 22%, var(--mc-canvas)); --mc-btn-selected-fill: color-mix(in srgb, var(--mc-pink) 8%, var(--mc-canvas));
  --mc-btn-danger: var(--mc-error); --mc-btn-danger-fill: color-mix(in srgb, var(--mc-error) 8%, var(--mc-canvas)); --mc-btn-danger-hover: color-mix(in srgb, var(--mc-error) 13%, var(--mc-canvas)); --mc-btn-danger-border: color-mix(in srgb, var(--mc-error) 24%, var(--mc-canvas));
  --mc-btn-shadow-primary: 0 1px 2px color-mix(in srgb, var(--mc-text-primary) 6%, transparent), 0 4px 12px color-mix(in srgb, var(--mc-pink) 18%, transparent);
  --mc-btn-shadow-primary-hover: 0 2px 4px color-mix(in srgb, var(--mc-text-primary) 6%, transparent), 0 8px 18px color-mix(in srgb, var(--mc-pink) 26%, transparent);
  --mc-btn-shadow-neutral: 0 1px 2px color-mix(in srgb, var(--mc-text-primary) 5%, transparent); --mc-btn-shadow-neutral-hover: 0 2px 8px color-mix(in srgb, var(--mc-text-primary) 9%, transparent); }
/* The inline sprite sits at the top of the page and takes no room. */
.ts-sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
/* The form stack: 8px from a label to its field, 12px from a field to the button that belongs to it, 16px under an introduction, 24px between groups. A group is .ts-field. */
.ts-card form { display: flex; flex-direction: column; align-items: stretch; gap: 0; }
.ts-card form > p { margin: 0 0 var(--mc-space-4); }
.ts-field { display: flex; flex-direction: column; align-items: stretch; }
.ts-field > label { margin: 0 0 var(--mc-space-2); font: 600 var(--mc-type-label-size)/var(--mc-type-label-line) var(--mc-font-sans); }
.ts-field > input { min-height: 46px; padding: var(--mc-space-3); background: var(--mc-canvas); }
.ts-field > .ts-button { margin-top: var(--mc-space-3); }
.ts-field + .ts-link { margin-top: var(--mc-space-6); }
#ts-signed-in > p { margin: 0 0 var(--mc-space-4); }
.ts-card .ts-actions { flex-direction: column; flex-wrap: nowrap; align-items: stretch; gap: var(--mc-space-3); margin: 0; }
/* Buttons: as wide as the form column, 44px (primary 46px), 12px radius, label 600 14/20, 8px between an icon and its label, 120ms over colour, border and shadow only. */
.ts-button, .ts-link { box-sizing: border-box; display: inline-flex; justify-content: center; align-items: center; gap: var(--mc-button-icon-gap); width: 100%; min-height: var(--mc-button-height); padding: 8px var(--mc-button-padding-inline); border: 1px solid transparent; border-radius: var(--mc-radius-control); font: var(--mc-button-label-weight) var(--mc-button-label-size)/var(--mc-button-label-line) var(--mc-font-sans); letter-spacing: normal; text-align: center; text-decoration: none; white-space: normal; overflow-wrap: anywhere; cursor: pointer; transition: background-color var(--mc-duration-fast) var(--mc-ease-standard), border-color var(--mc-duration-fast) var(--mc-ease-standard), color var(--mc-duration-fast) var(--mc-ease-standard), box-shadow var(--mc-duration-fast) var(--mc-ease-standard); }
/* Secondary (Sign out): white, a thin border, the soft neutral shadow. */
.ts-button { border-color: var(--mc-border); background: var(--mc-canvas); color: var(--mc-text-primary); box-shadow: var(--mc-btn-shadow-neutral); }
.ts-button:hover:where(:not(:disabled)) { border-color: var(--mc-divider-strong); box-shadow: var(--mc-btn-shadow-neutral-hover); }
.ts-button:active:where(:not(:disabled)) { background: var(--mc-pressed-neutral); box-shadow: none; }
/* Primary (Email me a code, Sign in, Open the beta): Clerk Pink, BLACK text and icons, the soft pink shadow. One per step. */
.ts-primary { min-height: var(--mc-button-primary-height); border-color: transparent; background: var(--mc-pink); color: var(--mc-text-on-pink); box-shadow: var(--mc-btn-shadow-primary); }
.ts-primary:hover:where(:not(:disabled)) { border-color: transparent; background: var(--mc-pink-hover); box-shadow: var(--mc-btn-shadow-primary-hover); }
.ts-primary:active:where(:not(:disabled)) { background: var(--mc-pink-pressed); box-shadow: none; }
/* Text action (Use a different email): no fill, secondary text, a leading arrow. */
.ts-link { border-color: transparent; background: transparent; color: var(--mc-text-secondary); box-shadow: none; }
.ts-link:hover:where(:not(:disabled)) { background: var(--mc-hover-neutral); }
.ts-link:active:where(:not(:disabled)) { background: var(--mc-pressed-neutral); }
/* Icons: a leading 18px icon before the label, a trailing 16px arrow after it. The arrow moves 2px on a fine pointer, never with reduced motion; the label never moves. */
.ts-ico { width: var(--mc-button-icon-size); height: var(--mc-button-icon-size); flex: 0 0 auto; fill: none; stroke: currentColor; stroke-width: 1.75; stroke-linecap: round; stroke-linejoin: round; pointer-events: none; }
.ts-ico--trail { width: 16px; height: 16px; transition: transform var(--mc-duration-fast) var(--mc-ease-standard); }
@media (hover: hover) and (pointer: fine) and (prefers-reduced-motion: no-preference) { .ts-button:hover:where(:not(:disabled)) > .ts-ico--trail { transform: translateX(var(--mc-button-arrow-shift)); } }
/* Busy. The page script (an exact edit of its busy() function) swaps the submit button's label for its working label ("Sending…", "Signing in…") and sets aria-busy while a request is in flight; every control is
   disabled meanwhile, so nothing can be sent twice. A busy primary keeps its pink, its black text and its size, and shows a turning loader in place of its icon. The text action waits, greyed. */
@keyframes ts-spin { to { transform: rotate(360deg); } }
.ts-ico--spin { display: none; }
.ts-primary:disabled { cursor: progress; }
.ts-primary[aria-busy="true"] > .ts-ico--spin { display: inline-block; animation: ts-spin 1s linear infinite; }
.ts-primary[aria-busy="true"] > .ts-ico--lead:not(.ts-ico--spin), .ts-primary[aria-busy="true"] > .ts-ico--trail { display: none; }
.ts-link:disabled { color: var(--mc-text-disabled); cursor: progress; }
/* Keyboard focus, last on purpose so it wins over the soft shadows: one strong ring on every control, a 2px --mc-pink-text outline at a 2px offset with a 3px soft halo. */
input:focus-visible, .ts-button:focus-visible, .ts-link:focus-visible, a:focus-visible { outline: 2px solid var(--mc-pink-text); outline-offset: 2px; box-shadow: 0 0 0 3px var(--mc-focus-ring); }
@media (prefers-reduced-motion: reduce) { .ts-button, .ts-link, .ts-ico--trail { transition: none; } .ts-primary[aria-busy="true"] > .ts-ico--spin { animation: none; } }
@media (forced-colors: active) { .ts-button { border-color: ButtonText; } input:focus-visible, .ts-button:focus-visible, .ts-link:focus-visible, a:focus-visible { outline: 2px solid Highlight; box-shadow: none; } }
.ts-actions { display: flex; flex-wrap: wrap; gap: var(--mc-space-3); }
#ts-status { min-height: 1.5em; margin: var(--mc-space-4) 0 0; overflow-wrap: anywhere; }
#ts-status.ts-error { color: var(--mc-error); }
.ts-help { margin: var(--mc-space-6) 0 0; color: var(--mc-text-secondary); }
@media (max-width: 600px) { .ts-card { margin-block: var(--mc-space-8); } }
/* Privacy notice page (Beta-01): the sign-in page frame, wider, for a long text. No script, no inline style. */
.pv-card { width: min(100%, 760px); }
.pv-card h1 { margin-bottom: var(--mc-space-4); }
.pv-card h2 { margin: var(--mc-space-8) 0 var(--mc-space-3); font-size: var(--mc-type-section-size); line-height: var(--mc-type-section-line); letter-spacing: -.018em; }
.pv-card h3 { margin: var(--mc-space-6) 0 var(--mc-space-2); font-size: var(--mc-type-body-size); line-height: var(--mc-type-body-line); }
.pv-card p, .pv-card li { margin: 0 0 var(--mc-space-3); }
.pv-card ul, .pv-card ol { margin: 0 0 var(--mc-space-3); padding-left: var(--mc-space-6); }
.pv-card code { font-family: var(--mc-font-mono); font-size: .92em; padding: 0 var(--mc-space-1); background: var(--mc-surface-subtle); border-radius: var(--mc-radius-small); }
.pv-card a { color: var(--mc-pink-text); }
.pv-draft { margin: 0 0 var(--mc-space-6); padding: var(--mc-space-3) var(--mc-space-4); border: 1px solid var(--mc-border); border-radius: var(--mc-radius-control); background: var(--mc-surface-subtle); font-weight: 600; }
