/* ============================================================================
   Focused pages — everything a signed-out person sees, and the trial set-up.

   Built on the portal's own tokens (css/tokens.css) and sharing the component
   layer (css/components.css) with the signed-in workspace, so the trial, sign-in
   and the signed-in portal read as one product: white, black type, SIP yellow.

   Rules this sheet keeps to (the same ones the website follows):
   - One amber per screen: the action that moves you forward. The stepper, the
     highlights and the focus rings use white, not amber.
   - Big touch targets (52px) — this is used on a device held in a gloved hand
     as often as at a desk.
   - Sentence case everywhere; no tracked capitals over headings.
   ========================================================================== */

.fx {
    --fx-input: var(--sip-input);
    --fx-raise: var(--sip-raise);
    --fx-line-strong: var(--sip-line-strong);
    --fx-radius: 12px;
    --fx-gutter: clamp(16px, 4vw, 32px);

    min-height: 100vh;
    display: flex;
    flex-direction: column;
    background: var(--sip-canvas);
    color: var(--sip-text);
    -webkit-font-smoothing: antialiased;
}

.fx *,
.fx *::before,
.fx *::after {
    box-sizing: border-box;
}

/* A wizard rendered inside the signed-in shell (WizardShell Embedded): keep the .fx tokens and
   component styles, but flow in the page's own main area instead of filling the viewport. The shell's
   top bar and sidebar stay in view. */
.fx-embed {
    min-height: 0;
    display: block;
}

/* Plain text links only. Anything with a class — buttons, cards, the brand, the sign-in role
   choices — is a component that styles itself. */
.fx a:not([class]) {
    color: var(--sip-text);
    text-decoration: underline;
    text-decoration-color: var(--fx-line-strong);
    text-underline-offset: 3px;
}

    .fx a:not([class]):hover {
        color: var(--sip-text);
        text-decoration-color: var(--sip-text-2);
    }

.fx :focus-visible {
    outline: 2px solid var(--sip-text);
    outline-offset: 3px;
    border-radius: 6px;
}

/* FocusOnNavigate (Routes.razor) focuses the page's h1 after every navigation, and the skip link and
   a closing dialog focus main: announcements for screen readers, not controls, so they show no ring.
   components.css says the same for the signed-in shell, but the rule above outranks a plain
   h1:focus-visible, so this shell says it again at a higher specificity. */
.fx h1:focus,
.fx h1:focus-visible,
.fx main:focus,
.fx main:focus-visible {
    outline: none;
    box-shadow: none;
}

/* Zero specificity, so any class below can set a paragraph's margin without fighting it. */
:where(.fx) p {
    margin: 0;
}

/* ---------- top bar ---------- */

.fx-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    min-height: 64px;
    padding: 0 var(--fx-gutter);
    border-bottom: 1px solid var(--sip-hairline);
}

.fx a.fx-brand {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    color: var(--sip-text);
    text-decoration: none;
}

.fx-wordmark {
    font-weight: 700;
    font-size: 1.05rem;
    letter-spacing: 0.3em;
    margin-right: -0.3em;
}

.fx-brand-label {
    margin-left: 0.55rem;
    padding-left: 0.85rem;
    border-left: 1px solid var(--sip-hairline);
    font-size: 0.92rem;
    font-weight: 500;
    color: var(--sip-text-2);
}

.fx-top-aside {
    display: flex;
    align-items: center;
    gap: 1.1rem;
    font-size: 0.92rem;
    color: var(--sip-muted);
}

    .fx-top-aside a {
        color: var(--sip-text-2);
        text-decoration: none;
    }

        .fx-top-aside a:hover {
            color: var(--sip-text);
        }

/* The bar's own links (Help, Dashboard) read as quiet navigation, not as underlined body links. */
.fx a.fx-top-link {
    color: var(--sip-text-2);
    text-decoration: none;
}

    .fx a.fx-top-link:hover {
        color: var(--sip-text);
        text-decoration: underline;
        text-underline-offset: 3px;
    }

.fx-top-who {
    max-width: 22ch;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.fx-main {
    flex: 1;
    width: 100%;
    padding: clamp(24px, 5vw, 56px) var(--fx-gutter) 72px;
}

/* ---------- progress ---------- */

.fx-steps {
    list-style: none;
    display: grid;
    grid-template-columns: repeat(var(--fx-step-count, 4), minmax(0, 1fr));
    max-width: 680px;
    margin: 0 auto 2.25rem;
    padding: 0;
}

.fx-step {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.55rem;
    text-align: center;
    font-size: 0.86rem;
    color: var(--sip-text-2);
}

    /* The line joining this step to the one before it. */
    .fx-step + .fx-step::before {
        content: "";
        position: absolute;
        top: 14px;
        right: calc(50% + 20px);
        left: calc(-50% + 20px);
        height: 1px;
        background: var(--sip-hairline);
    }

    .fx-step.is-done + .fx-step::before {
        background: var(--sip-text-2);
    }

.fx-step-dot {
    position: relative;
    z-index: 1;
    display: grid;
    place-items: center;
    width: 29px;
    height: 29px;
    border-radius: 50%;
    border: 1px solid var(--sip-hairline);
    background: var(--sip-canvas);
    font-size: 0.8rem;
    font-weight: 600;
}

    .fx-step-dot svg {
        width: 14px;
        height: 14px;
    }

.fx-step.is-done {
    color: var(--sip-text-2);
}

    .fx-step.is-done .fx-step-dot {
        border-color: var(--sip-text-2);
        color: var(--sip-text);
    }

.fx-step.is-current {
    color: var(--sip-text);
    font-weight: 600;
}

    .fx-step.is-current .fx-step-dot {
        background: var(--sip-text);
        border-color: var(--sip-text);
        color: var(--sip-canvas);
    }

/* On a phone the labels would crush each other; show the dots and one caption instead. */
.fx-steps-caption {
    display: none;
    text-align: center;
    color: var(--sip-text-2);
    font-size: 0.9rem;
    margin: -1.5rem 0 1.5rem !important;
}

/* ---------- the panel each step lives in ---------- */

.fx-panel {
    max-width: 580px;
    margin: 0 auto;
    padding: clamp(22px, 4.5vw, 44px);
    background: var(--sip-surface);
    border: 1px solid var(--sip-hairline);
    border-radius: var(--sip-radius);
}

    .fx-panel.has-figure {
        max-width: 940px;
        display: grid;
        grid-template-columns: minmax(0, 1fr) 290px;
        gap: clamp(28px, 5vw, 64px);
        align-items: center;
    }

.fx-panel-figure {
    display: flex;
    justify-content: center;
}

.fx-kicker {
    font-size: 0.92rem;
    color: var(--sip-text-2);
    margin-bottom: 0.6rem !important;
}

.fx-h1 {
    font-size: clamp(1.65rem, 3.4vw, 2.2rem);
    line-height: 1.14;
    letter-spacing: -0.015em;
    font-weight: 600;
    margin: 0 0 0.75rem;
    text-wrap: balance;
}

.fx-h2 {
    font-size: 1rem;
    font-weight: 600;
    margin: 1.75rem 0 0.75rem;
}

.fx-lead {
    color: var(--sip-text-2);
    font-size: 1.04rem;
    line-height: 1.6;
    max-width: 48ch;
    margin-bottom: 1.75rem !important;
    text-wrap: pretty;
}

    .fx-lead strong {
        color: var(--sip-text);
        font-weight: 600;
    }

.fx-fine {
    color: var(--sip-muted);
    font-size: 0.88rem;
    line-height: 1.55;
    margin-top: 1.5rem !important;
}

/* ---------- buttons ---------- */

.fx-btn,
.fx a.fx-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.55rem;
    min-height: 52px;
    padding: 0 1.4rem;
    border-radius: var(--fx-radius);
    border: 1px solid var(--fx-line-strong);
    background: transparent;
    color: var(--sip-text);
    font: inherit;
    font-weight: 600;
    font-size: 1rem;
    line-height: 1.2;
    text-align: center;
    text-decoration: none;
    cursor: pointer;
    transition: background-color 0.15s ease, border-color 0.15s ease, color 0.15s ease, transform 0.1s ease;
}

    .fx-btn:hover,
    .fx a.fx-btn:hover {
        border-color: var(--sip-text-2);
        color: var(--sip-text);
        text-decoration: none;
    }

    .fx-btn:active {
        transform: translateY(1px);
    }

    .fx-btn svg {
        width: 18px;
        height: 18px;
        flex: none;
    }

.fx-btn-primary,
.fx a.fx-btn-primary {
    background: var(--sip-amber);
    border-color: var(--sip-amber);
    color: var(--sip-on-amber);
}

    .fx-btn-primary:hover,
    .fx a.fx-btn-primary:hover {
        background: var(--sip-amber-hover);
        border-color: var(--sip-amber-hover);
        color: var(--sip-on-amber);
    }

.fx-btn-block {
    width: 100%;
}

.fx-btn[disabled] {
    opacity: 0.55;
    cursor: default;
}

.fx-actions {
    display: flex;
    flex-direction: column;
    gap: 0.7rem;
    margin-top: 1.75rem;
}

.fx-row-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem 1.25rem;
    margin-top: 1.5rem;
}

.fx a.fx-back,
.fx-link-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0;
    border: 0;
    background: none;
    color: var(--sip-text-2);
    font: inherit;
    font-size: 0.92rem;
    text-decoration: none;
    cursor: pointer;
}

    .fx a.fx-back:hover,
    .fx-link-btn:hover {
        color: var(--sip-text);
    }

    .fx a.fx-back svg {
        width: 15px;
        height: 15px;
    }

.fx-back-row {
    margin-top: 1.4rem;
}

/* ---------- forms ---------- */

.fx-field {
    margin-bottom: 1.1rem;
}

.fx-label {
    display: block;
    font-size: 0.93rem;
    font-weight: 500;
    color: var(--sip-text);
    margin-bottom: 0.45rem;
}

.fx-optional {
    font-weight: 400;
    color: var(--sip-muted);
}

.fx-input {
    display: block;
    width: 100%;
    min-height: 52px;
    padding: 0.7rem 0.95rem;
    /* The field's edge reaches 3:1 against the panel, so the field can be seen without its label. */
    border: 1px solid var(--sip-control-line);
    border-radius: 10px;
    background: var(--fx-input);
    color: var(--sip-text);
    font: inherit;
    font-size: 1rem;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

    /* --sip-muted: 4.8:1 on the field, where the old #5B5E64 was 2.9:1. */
    .fx-input::placeholder {
        color: var(--sip-muted);
        opacity: 1;
    }

    .fx-input:focus {
        outline: none;
        border-color: var(--sip-text-2);
        box-shadow: 0 0 0 3px rgba(244, 245, 246, 0.1);
    }

    .fx-input.invalid {
        border-color: rgba(255, 90, 82, 0.7);
    }

.fx-step-note {
    display: block;
}

.fx-hint {
    margin-top: 0.4rem !important;
    font-size: 0.86rem;
    line-height: 1.5;
    color: var(--sip-muted);
}

.fx .validation-message {
    margin-top: 0.4rem;
    font-size: 0.86rem;
    color: var(--sip-danger);
}

.fx .validation-errors {
    display: none; /* each field shows its own message */
}

.fx-two {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 0 0.9rem;
}

/* Codes: big, monospaced, centred — the thing being copied between device and screen. */
.fx-input-code {
    min-height: 68px;
    font-family: var(--sip-mono);
    font-size: clamp(1.55rem, 5.5vw, 2rem);
    font-weight: 500;
    letter-spacing: 0.22em;
    text-align: center;
    text-transform: uppercase;
}

.fx-input-otp {
    letter-spacing: 0.55em;
    padding-left: 1.1em; /* balance the trailing letter-spacing so the digits sit centred */
}

.fx-error {
    display: flex;
    gap: 0.6rem;
    align-items: flex-start;
    margin-bottom: 1.25rem;
    padding: 0.85rem 1rem;
    border: 1px solid rgba(255, 90, 82, 0.35);
    border-radius: 10px;
    background: rgba(255, 90, 82, 0.07);
    color: var(--sip-danger-text);
    font-size: 0.95rem;
    line-height: 1.5;
}

    .fx-error svg {
        flex: none;
        width: 18px;
        height: 18px;
        margin-top: 2px;
        color: var(--sip-danger);
    }

.fx-note {
    padding: 1rem 1.1rem;
    border: 1px solid var(--sip-hairline);
    border-radius: 12px;
    background: var(--fx-raise);
    color: var(--sip-text-2);
    font-size: 0.95rem;
    line-height: 1.55;
}

    .fx-note + .fx-note {
        margin-top: 0.75rem;
    }

    .fx-note strong {
        color: var(--sip-text);
        font-weight: 600;
    }

.fx-note-title {
    color: var(--sip-text);
    font-weight: 600;
    margin-bottom: 0.3rem !important;
}

.fx-success {
    display: flex;
    gap: 0.6rem;
    align-items: center;
    margin-bottom: 1.25rem;
    padding: 0.8rem 1rem;
    border: 1px solid rgba(63, 208, 122, 0.3);
    border-radius: 10px;
    background: rgba(63, 208, 122, 0.07);
    color: var(--sip-success-text);
    font-size: 0.95rem;
}

    .fx-success svg {
        flex: none;
        width: 18px;
        height: 18px;
        color: var(--sip-success);
    }

/* A confirmation with a title and a sentence under it ("Invitation sent to …"). */
.fx-success-block {
    align-items: flex-start;
    line-height: 1.5;
}

    .fx-success-block svg {
        margin-top: 2px;
    }

    .fx-success-block p + p {
        margin-top: 0.2rem;
    }

.fx-success-title {
    color: var(--sip-text);
    font-weight: 600;
    overflow-wrap: anywhere;
}

/* Two fields where the first holds the longer value (an email beside a name); one under the other
   on a phone, like every other pair. */
.fx-two.fx-two-lead {
    grid-template-columns: minmax(0, 3fr) minmax(0, 2fr);
}

@media (max-width: 560px) {
    .fx-two.fx-two-lead {
        grid-template-columns: minmax(0, 1fr);
    }
}

.fx-banner {
    max-width: 580px;
    margin: 0 auto 1.25rem;
}

.fx-banner-wide {
    max-width: 940px;
}

/* ---------- the invisible human check ---------- */

.fx-human-status {
    display: none;
    margin: 0.2rem 0 0.8rem;
}

[data-human-pending] .fx-human-status {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    color: var(--sip-muted);
    font-size: 0.8125rem;
}

.fx-human-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--sip-muted-decor, var(--sip-muted));
    animation: fx-human-pulse 1.2s ease-in-out infinite;
}

@keyframes fx-human-pulse {
    50% { opacity: 0.35; }
}

@media (prefers-reduced-motion: reduce) {
    .fx-human-dot { animation: none; }
}

/* ---------- step 1: choose a device ---------- */

.fx-choices {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.8rem;
}

.fx a.fx-choice,
.fx div.fx-choice {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
    min-height: 196px;
    padding: 1.35rem 1.35rem 1.2rem;
    border: 1px solid var(--sip-hairline);
    border-radius: 14px;
    background: var(--fx-input);
    color: var(--sip-text);
    text-decoration: none;
    transition: border-color 0.15s ease, background-color 0.15s ease, transform 0.15s ease;
}

    .fx a.fx-choice:hover {
        border-color: var(--sip-text-2);
        background: var(--fx-raise);
        transform: translateY(-1px);
    }

    .fx a.fx-choice.is-detected {
        border-color: var(--fx-line-strong);
    }

    /* Nothing published yet: shown, not clickable. */
    .fx div.fx-choice {
        color: var(--sip-text-2);
    }

.fx-choice-icon {
    width: 38px;
    height: 38px;
    margin-bottom: 0.85rem;
    color: var(--sip-text);
}

.fx-choice-name {
    font-size: 1.12rem;
    font-weight: 600;
}

.fx-choice-meta {
    color: var(--sip-muted);
    font-size: 0.9rem;
    line-height: 1.45;
}

.fx-choice-go {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
    margin-top: auto;
    min-height: 44px;
    padding: 0 0.95rem;
    border: 1px solid var(--fx-line-strong);
    border-radius: var(--fx-radius);
    color: var(--sip-text);
    font-size: 0.95rem;
    font-weight: 600;
}

    .fx a.fx-choice:hover .fx-choice-go,
    .fx a.fx-choice:focus-visible .fx-choice-go {
        border-color: var(--sip-text-2);
    }

    .fx a.fx-choice.is-detected .fx-choice-go {
        background: var(--sip-amber);
        border-color: var(--sip-amber);
        color: var(--sip-on-amber);
    }

    .fx-choice-go svg {
        width: 18px;
        height: 18px;
        transition: transform 0.15s ease;
    }

.fx a.fx-choice:hover .fx-choice-go svg {
    transform: translateX(3px);
}

.fx-tag {
    position: absolute;
    top: 1.2rem;
    right: 1.2rem;
    padding: 0.18rem 0.6rem;
    border: 1px solid var(--fx-line-strong);
    border-radius: 999px;
    color: var(--sip-text-2);
    font-size: 0.78rem;
    font-weight: 500;
}

/* ---------- step 1b: install ---------- */

.fx-install[data-mode="mobile"] .fx-when-desktop,
.fx-install[data-mode="desktop"] .fx-when-mobile {
    display: none;
}

.fx-install .fx-when-desktop {
    margin-top: 1rem;
}

.fx-qr-or {
    margin: 0 0 0.6rem !important;
    color: var(--sip-text-2);
    font-size: 0.9rem;
    font-weight: 600;
}

/* A phone-sized window never needs the QR code: it is already the device. */
@media (max-width: 560px) {
    .fx-install .fx-when-desktop {
        display: none;
    }
}

.fx-qr {
    display: grid;
    grid-template-columns: 156px minmax(0, 1fr);
    gap: 1.25rem;
    align-items: center;
    padding: 1rem;
    border: 1px solid var(--sip-hairline);
    border-radius: 14px;
    background: var(--fx-input);
}

.fx-qr-tile {
    width: 156px;
    height: 156px;
    padding: 6px;
    border-radius: 10px;
    background: #FFFFFF;
}

    .fx-qr-tile svg {
        display: block;
        width: 100%;
        height: 100%;
    }

.fx-qr-title {
    font-weight: 600;
    margin-bottom: 0.35rem !important;
}

.fx-address {
    display: inline-block;
    margin-top: 0.5rem !important;
    padding: 0.35rem 0.6rem;
    border-radius: 8px;
    background: var(--fx-raise);
    border: 1px solid var(--sip-hairline);
    font-family: var(--sip-mono);
    font-size: 0.86rem;
    color: var(--sip-text);
    word-break: break-all;
}

/* Numbered sub-steps: small, quiet, never competing with the step itself. */
.fx-numbered {
    list-style: none;
    counter-reset: fx-n;
    margin: 0;
    padding: 0;
    display: grid;
    gap: 0.85rem;
}

    /* Normal inline flow with the number positioned beside it — a grid or flex item here would
       split "tap <strong>Install</strong>" into separate cells. */
    .fx-numbered li {
        counter-increment: fx-n;
        position: relative;
        min-height: 26px;
        padding-left: 2.35rem;
        color: var(--sip-text-2);
        line-height: 1.55;
    }

        .fx-numbered li::before {
            content: counter(fx-n);
            position: absolute;
            top: -1px;
            left: 0;
            display: grid;
            place-items: center;
            width: 26px;
            height: 26px;
            border-radius: 50%;
            border: 1px solid var(--sip-hairline);
            color: var(--sip-text);
            font-size: 0.78rem;
            font-weight: 600;
        }

        .fx-numbered li strong {
            color: var(--sip-text);
            font-weight: 600;
        }

/* ---------- step 3: the device diagram ----------
   A plain diagram of SIP's own "Activate SIP" screen, using its exact labels, with the part the
   officer needs outlined. Deliberately schematic: it shows where to look, not a screenshot that
   goes stale with the next app release. */

.fx-device-figure {
    margin: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.9rem;
}

/* Pictures of the SIP app (the phone here, the cropped screen in polish.css) stay dark, like the app
   itself, on the white portal: they get the app's own text colours back. */
.fx-device,
.fx-device-crop-screen {
    --sip-text: #F4F5F6;
    --sip-text-2: #B4B7BC;
    --sip-muted: #8A8E95;
    --sip-text-rgb: 244, 245, 246;
    --fx-line-strong: #3A3D43;
    color: #F4F5F6;
}

.fx-device {
    width: 250px;
    padding: 10px;
    border-radius: 36px;
    border: 1px solid var(--fx-line-strong);
    background: #08090A;
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.45), inset 0 0 0 1px rgba(255, 255, 255, 0.03);
}

.fx-device-screen {
    overflow: hidden;
    border-radius: 27px;
    background: #111215;
    font-size: 11px;
    line-height: 1.35;
    user-select: none;
}

.fx-device-notch {
    width: 74px;
    height: 20px;
    margin: 8px auto 0;
    border-radius: 12px;
    background: #08090A;
}

.fx-device-head {
    padding: 12px 16px 14px;
    border-bottom: 1px solid var(--sip-hairline);
}

.fx-device-title {
    font-size: 16px;
    font-weight: 600;
    color: var(--sip-text);
}

.fx-device-sub {
    margin-top: 2px;
    color: var(--sip-muted);
    font-size: 10.5px;
}

.fx-device-body {
    display: grid;
    gap: 10px;
    padding: 12px 12px 18px;
}

.fx-device-card {
    padding: 10px 11px;
    border: 1px solid var(--sip-hairline);
    border-radius: 12px;
    background: #17191C;
    /* Not dimmed: every label stays readable (WCAG contrast). The highlighted part stands out by its
       bright outline and glow instead. */
    transition: box-shadow 0.2s ease, border-color 0.2s ease;
}

    .fx-device-card.is-highlight {
        opacity: 1;
        border-color: var(--sip-text);
        box-shadow: 0 0 0 3px rgba(var(--sip-text-rgb), 0.12), 0 10px 28px rgba(0, 0, 0, 0.12);
    }

.fx-device-label {
    color: var(--sip-text-2);
    font-size: 10px;
    font-weight: 600;
    margin-bottom: 6px;
}

.fx-device-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}

.fx-device-code {
    font-family: var(--sip-mono);
    font-size: 15px;
    font-weight: 500;
    letter-spacing: 0.06em;
    color: var(--sip-text);
}

.fx-device-chip {
    padding: 2px 8px;
    border: 1px solid var(--fx-line-strong);
    border-radius: 7px;
    color: var(--sip-text-2);
    font-size: 9.5px;
}

.fx-device-field {
    padding: 7px 8px;
    border: 1px solid var(--sip-hairline);
    border-radius: 7px;
    background: #0E0F11;
    font-size: 10px;
    color: #8A8E95;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}

    .fx-device-field.is-filled {
        color: var(--sip-text);
        font-family: var(--sip-mono);
    }

/* "Scan QR code" (outlined, with a QR glyph), then "or" before the paste box. */
.fx-device-button.is-outline {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    margin-top: 0;
    border: 1px solid var(--fx-line-strong);
    background: transparent;
    color: var(--sip-text);
}

.fx-device-qr {
    width: 11px;
    height: 11px;
    fill: currentColor;
}

.fx-device-or {
    margin: 5px 0;
    color: var(--sip-muted);
    font-size: 9.5px;
    text-align: center;
}

.fx-device-button {
    margin-top: 8px;
    padding: 7px;
    border-radius: 8px;
    background: var(--sip-amber);
    color: var(--sip-on-amber);
    font-size: 10.5px;
    font-weight: 600;
    text-align: center;
}

.fx-device-caption {
    max-width: 250px;
    text-align: center;
    color: var(--sip-text-2);
    font-size: 0.88rem;
    line-height: 1.5;
}

/* ---------- step 3b: the activation code ---------- */

.fx-codebox {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 0.9rem 1rem;
    padding: 1.1rem 1.1rem 1.1rem 1.35rem;
    border: 1px solid var(--fx-line-strong);
    border-radius: 14px;
    background: var(--fx-input);
}

.fx-codebox-value {
    font-family: var(--sip-mono);
    font-size: clamp(1.25rem, 4.4vw, 1.75rem);
    font-weight: 500;
    letter-spacing: 0.07em;
    color: var(--sip-text);
    word-break: break-all;
}

.fx-copy {
    min-height: 44px;
    padding: 0 1rem;
    font-size: 0.95rem;
}

    .fx-copy.is-copied {
        border-color: rgba(63, 208, 122, 0.5);
        color: var(--sip-success-text);
    }

/* Hairline facts: label left, value right. */
.fx-facts {
    margin: 1.25rem 0 0;
    border-top: 1px solid var(--sip-hairline);
}

    .fx-facts > div {
        display: flex;
        justify-content: space-between;
        gap: 1rem;
        padding: 0.75rem 0;
        border-bottom: 1px solid var(--sip-hairline);
        font-size: 0.95rem;
    }

    .fx-facts dt {
        color: var(--sip-muted);
        font-weight: 400;
    }

    .fx-facts dd {
        margin: 0;
        color: var(--sip-text);
        text-align: right;
        overflow-wrap: anywhere;
    }

.fx-mono {
    font-family: var(--sip-mono);
    letter-spacing: 0.04em;
}

.fx-help {
    margin-top: 1.1rem;
    border-top: 1px solid var(--sip-hairline);
    padding-top: 1rem;
}

    .fx-help summary {
        cursor: pointer;
        color: var(--sip-text-2);
        font-size: 0.93rem;
        list-style: none;
    }

        .fx-help summary::-webkit-details-marker {
            display: none;
        }

        .fx-help summary::after {
            content: "+";
            margin-left: 0.5rem;
            color: var(--sip-muted);
        }

    .fx-help[open] summary::after {
        content: "−";
    }

    .fx-help ul {
        margin: 0.8rem 0 0;
        padding-left: 1.1rem;
        color: var(--sip-text-2);
        font-size: 0.93rem;
        line-height: 1.6;
    }

        .fx-help ul li + li {
            margin-top: 0.35rem;
        }

/* ---------- step 2b: waiting for the email ---------- */

.fx-waiting {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    margin-top: 1.25rem !important;
    color: var(--sip-muted);
    font-size: 0.9rem;
    line-height: 1.5;
}

.fx-pulse {
    flex: none;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--sip-success);
    animation: fx-pulse 1.8s ease-in-out infinite;
}

@keyframes fx-pulse {
    0%, 100% {
        opacity: 0.25;
    }

    50% {
        opacity: 1;
    }
}

/* ---------- step 4: team ---------- */

.fx-count {
    display: inline-flex;
    align-items: stretch;
    border: 1px solid var(--sip-hairline);
    border-radius: 10px;
    background: var(--fx-input);
    overflow: hidden;
}

    .fx-count button {
        width: 48px;
        border: 0;
        background: transparent;
        color: var(--sip-text);
        font-size: 1.2rem;
        cursor: pointer;
    }

        .fx-count button:hover {
            background: var(--fx-raise);
        }

    .fx-count input {
        width: 64px;
        min-height: 50px;
        border: 0;
        border-left: 1px solid var(--sip-hairline);
        border-right: 1px solid var(--sip-hairline);
        background: transparent;
        color: var(--sip-text);
        font: inherit;
        font-weight: 600;
        text-align: center;
        -moz-appearance: textfield;
    }

        .fx-count input::-webkit-outer-spin-button,
        .fx-count input::-webkit-inner-spin-button {
            -webkit-appearance: none;
            margin: 0;
        }

        .fx-count input:focus {
            outline: none;
            background: var(--fx-raise);
        }

.fx-people {
    list-style: none;
    margin: 0;
    padding: 0;
    border-top: 1px solid var(--sip-hairline);
}

    .fx-people li {
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 1rem;
        padding: 0.8rem 0;
        border-bottom: 1px solid var(--sip-hairline);
    }

.fx-person {
    min-width: 0;
}

.fx-person-name {
    font-weight: 500;
    overflow-wrap: anywhere;
}

.fx-person-meta {
    color: var(--sip-muted);
    font-size: 0.86rem;
    overflow-wrap: anywhere;
}

.fx-chip {
    flex: none;
    padding: 0.2rem 0.65rem;
    border: 1px solid var(--sip-hairline);
    border-radius: 999px;
    color: var(--sip-text-2);
    font-size: 0.8rem;
    white-space: nowrap;
}

    .fx-chip.is-ok {
        border-color: rgba(63, 208, 122, 0.35);
        color: var(--sip-success-text);
    }

.fx-divider {
    height: 1px;
    margin: 2rem 0 0;
    border: 0;
    background: var(--sip-hairline);
    opacity: 1;
}

/* ---------- done ---------- */

.fx-done-mark {
    display: grid;
    place-items: center;
    width: 60px;
    height: 60px;
    margin-bottom: 1.4rem;
    border-radius: 50%;
    border: 1px solid rgba(63, 208, 122, 0.4);
    background: rgba(63, 208, 122, 0.08);
    color: var(--sip-success);
}

    .fx-done-mark svg {
        width: 28px;
        height: 28px;
    }

.fx-next {
    list-style: none;
    margin: 0.25rem 0 0;
    padding: 0;
    border-top: 1px solid var(--sip-hairline);
}

    .fx-next li {
        padding: 0.9rem 0;
        border-bottom: 1px solid var(--sip-hairline);
        color: var(--sip-text-2);
        line-height: 1.55;
    }

        .fx-next li strong {
            display: block;
            color: var(--sip-text);
            font-weight: 600;
            margin-bottom: 0.15rem;
        }

/* The next steps with an icon tile beside each (the end of the trial set-up). */
.fx-next-icons li {
    display: grid;
    grid-template-columns: 36px minmax(0, 1fr);
    gap: 0.9rem;
    align-items: start;
}

.fx-next-icon {
    display: grid;
    place-items: center;
    width: 36px;
    height: 36px;
    border: 1px solid var(--sip-hairline);
    border-radius: 10px;
    background: var(--fx-raise);
    color: var(--sip-text-2);
}

    .fx-next-icon svg {
        width: 18px;
        height: 18px;
    }

/* How much of an allowance is used: a line of text and a thin bar, in neutral greys. */
.fx-meter {
    margin: 0 0 0.5rem;
    padding: 0.85rem 1rem;
    border: 1px solid var(--sip-hairline);
    border-radius: 12px;
    background: var(--fx-raise);
}

.fx-meter-head {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 0.25rem 1rem;
    font-size: 0.92rem;
    color: var(--sip-text-2);
}

    .fx-meter-head strong {
        color: var(--sip-text);
        font-weight: 600;
    }

.fx-meter-aside {
    color: var(--sip-muted);
}

.fx-meter-track {
    height: 6px;
    margin-top: 0.6rem;
    border-radius: 999px;
    background: var(--sip-hairline);
    overflow: hidden;
}

    .fx-meter-track > span {
        display: block;
        height: 100%;
        border-radius: inherit;
        background: var(--sip-text-2);
    }

/* ---------- portal front door and download page ---------- */

.fx-home {
    max-width: 880px;
    margin: 0 auto;
}

.fx-home-head {
    margin-bottom: 2rem;
}

.fx-doors {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 0.9rem;
}

/* The trial: full width, text beside its button — the one thing most visitors came for.
   Doubled class so it outranks the base .fx-door rule that follows it. */
.fx-door.fx-door-feature {
    grid-column: 1 / -1;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    gap: 1.5rem;
    padding: 1.8rem;
}

    .fx-door.fx-door-feature .fx-btn {
        align-self: center;
        margin-top: 0;
        flex: none;
    }

.fx-door {
    display: flex;
    flex-direction: column;
    gap: 0.55rem;
    padding: 1.6rem;
    border: 1px solid var(--sip-hairline);
    border-radius: 14px;
    background: var(--sip-surface);
}

    .fx-door h2 {
        font-size: 1.15rem;
        font-weight: 600;
        margin: 0;
    }

    .fx-door p {
        color: var(--sip-text-2);
        line-height: 1.55;
    }

    .fx-door .fx-door-text {
        display: flex;
        flex-direction: column;
        gap: 0.4rem;
        max-width: 52ch;
    }

    .fx-door .fx-btn {
        align-self: flex-start;
        margin-top: 0.9rem;
    }

/* Sign in / Download: the button sits at the foot, so the two cards line up. */
.fx-door:not(.fx-door-feature) .fx-btn:last-child {
    margin-top: auto;
}

/* ---------- signed-out Account pages (sign-in, register, reset) ---------- */

.fx-auth-main {
    flex: 1;
    width: 100%;
    padding: clamp(8px, 4vw, 40px) var(--fx-gutter) 64px;
}

/* ---------- small screens ---------- */

@media (max-width: 820px) {
    .fx-panel.has-figure {
        display: block;
        max-width: 580px;
    }

    /* On a phone, where most activations happen, the diagram stays: compact, after the step. */
    .fx-panel-figure {
        margin-top: 1.75rem;
        padding-top: 1.5rem;
        border-top: 1px solid var(--sip-hairline);
    }

    /* A picture that only lengthens the page on a phone (FigureOnPhone="false"). */
    .fx-panel.figure-wide-only .fx-panel-figure {
        display: none;
    }

    .fx-device {
        width: 210px;
        padding: 8px;
        border-radius: 30px;
        box-shadow: 0 16px 36px rgba(0, 0, 0, 0.45), inset 0 0 0 1px rgba(255, 255, 255, 0.03);
    }

    .fx-device-screen {
        border-radius: 23px;
        font-size: 10px;
    }

    .fx-device-notch {
        width: 62px;
        height: 16px;
        margin-top: 6px;
    }

    .fx-device-head {
        padding: 10px 14px 12px;
    }

    .fx-device-title {
        font-size: 14px;
    }

    .fx-device-body {
        gap: 8px;
        padding: 10px 10px 14px;
    }

    .fx-device-code {
        font-size: 13px;
    }

    .fx-device-caption {
        max-width: 320px;
    }

    .fx-doors {
        grid-template-columns: minmax(0, 1fr);
    }

    .fx-door.fx-door-feature {
        flex-direction: column;
        align-items: flex-start;
    }

        .fx-door.fx-door-feature .fx-btn {
            align-self: flex-start;
        }
}

@media (max-width: 560px) {
    .fx-step-label {
        display: none;
    }

    .fx-steps {
        margin-bottom: 2.1rem;
    }

    .fx-steps-caption {
        display: block;
    }

    .fx-panel {
        border-radius: 14px;
    }

    .fx-choices,
    .fx-two {
        grid-template-columns: minmax(0, 1fr);
    }

    .fx a.fx-choice,
    .fx div.fx-choice {
        min-height: 0;
    }

    .fx-qr {
        grid-template-columns: minmax(0, 1fr);
        justify-items: center;
        text-align: center;
    }

    .fx-brand-label {
        display: none;
    }

    .fx-top-who {
        display: none;
    }

    .fx-row-actions {
        flex-direction: column-reverse;
        align-items: stretch;
    }

        .fx-row-actions .fx-btn {
            width: 100%;
        }
}

@media (prefers-reduced-motion: reduce) {
    .fx *,
    .fx *::before,
    .fx *::after {
        animation: none !important;
        transition: none !important;
    }
}

/* ---------- small buttons in the top bar ---------- */

.fx-btn-sm,
.fx a.fx-btn-sm {
    min-height: 38px;
    padding: 0 0.95rem;
    font-size: 0.9rem;
    border-radius: 10px;
}

@media (max-width: 560px) {
    /* The way back to the website stays on a phone, shortened to "website". */
    .fx-top-site-sip {
        display: none;
    }
}

@media (max-width: 560px) {
    .fx-codebox {
        justify-content: center;
        text-align: center;
    }

        .fx-codebox .fx-copy {
            width: 100%;
        }
}

/* The form-bot honeypot (FormGuardFields): off screen and out of everyone's way but a bot's. */
.fx-hp {
    position: absolute !important;
    left: -10000px !important;
    width: 1px !important;
    height: 1px !important;
    overflow: hidden !important;
}

/* The team link: a read-only field (selectable when the clipboard is unavailable) and Copy. */
.fx-linkbox {
    flex-wrap: nowrap;
    padding: 0.55rem 0.55rem 0.55rem 1rem;
}

.fx-linkbox-value {
    flex: 1 1 auto;
    min-width: 0;
    border: 0;
    background: transparent;
    color: var(--sip-text);
    font-family: var(--sip-mono);
    font-size: 0.9rem;
    text-overflow: ellipsis;
}

    .fx-linkbox-value:focus {
        outline: none;
    }

.fx-help form {
    margin-top: 0.9rem;
}

/* ---------- wizard chrome: exit, sign-out, step links, footer ---------- */

/* "Exit" at the top right: the way back to where the wizard was started. */
.fx a.fx-top-exit {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    min-height: 40px;
    padding: 0 0.75rem;
    border: 1px solid var(--fx-line-strong);
    border-radius: 10px;
    color: var(--sip-text);
    font-weight: 500;
    text-decoration: none;
}

    .fx a.fx-top-exit:hover {
        border-color: var(--sip-text-2);
    }

    .fx a.fx-top-exit svg {
        width: 16px;
        height: 16px;
    }

.fx-top-signout {
    display: inline-flex;
    margin: 0;
}

/* A button that reads as one of the bar's links ("Not you? Sign out"). */
.fx-link-button {
    padding: 0;
    border: 0;
    background: none;
    color: var(--sip-text-2);
    font: inherit;
    text-decoration: underline;
    text-decoration-color: var(--fx-line-strong);
    text-underline-offset: 3px;
    cursor: pointer;
}

    .fx-link-button:hover {
        color: var(--sip-text);
        text-decoration-color: var(--sip-text-2);
    }

/* A finished step is a link back to it. */
.fx a.fx-step-label {
    color: inherit;
    text-decoration: underline;
    text-decoration-color: var(--fx-line-strong);
    text-underline-offset: 3px;
}

    .fx a.fx-step-label:hover {
        color: var(--sip-text);
        text-decoration-color: var(--sip-text-2);
    }

/* Back and Continue under the step. */
.fx-panel-footer {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem 1rem;
    margin-top: 1.75rem;
    padding-top: 1.25rem;
    border-top: 1px solid var(--sip-hairline);
}

    .fx-panel-footer > :last-child:not(:first-child) {
        margin-left: auto;
    }

@media (max-width: 560px) {
    .fx-top-aside {
        gap: 0.75rem;
    }

    .fx-top-signout .fx-link-button {
        font-size: 0.86rem;
    }

    /* On a phone the step's buttons stay in reach at the bottom of the screen. */
    .fx-panel-footer {
        position: sticky;
        bottom: 0;
        z-index: 5;
        margin: 1.5rem calc(-1 * clamp(22px, 4.5vw, 44px)) calc(-1 * clamp(22px, 4.5vw, 44px));
        padding: 0.85rem clamp(22px, 4.5vw, 44px) calc(0.85rem + env(safe-area-inset-bottom, 0px));
        border-radius: 0 0 14px 14px;
        background: linear-gradient(to bottom, rgba(250, 250, 249, 0.9), var(--sip-surface) 40%);
        -webkit-backdrop-filter: blur(6px);
        backdrop-filter: blur(6px);
    }

        .fx-panel-footer > .fx-btn {
            flex: 1 1 auto;
        }
}

/* The page's own skip link target in the focused shell. */
.fx-main:focus,
.fx-auth-main:focus {
    outline: none;
}

/* ---------- help page ---------- */

/* One page, grouped by task: a contents panel of four labelled groups, then each group's topics.
   The panel is as wide as the page; the topics keep a narrower reading width. */
.fx-help-page {
    max-width: 880px;
    margin: 0 auto;
}

    .fx-help-page > .fx-lead {
        max-width: 60ch;
    }

@media (prefers-reduced-motion: no-preference) {
    html:has(.fx-help-page) {
        scroll-behavior: smooth;
    }
}

.fx-toc {
    margin: 0 0 2.75rem;
    padding: 1.25rem 1.4rem 1.35rem;
    border: 1px solid var(--sip-hairline);
    border-radius: var(--fx-radius);
    background: var(--sip-surface);
    scroll-margin-top: 1.5rem;
}

.fx-toc-title {
    margin: 0 0 1rem;
    font-size: 1rem;
    font-weight: 600;
    color: var(--sip-text);
}

.fx-toc-groups {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1.4rem 2rem;
}

/* Small labels for the four groups, in the contents panel and above each group's topics. */
.fx-toc-group h3,
.fx-help-group-title {
    margin: 0 0 0.45rem;
    font-size: 0.84rem;
    font-weight: 600;
    color: var(--sip-muted);
}

.fx-toc ul {
    display: grid;
    gap: 0.1rem;
    margin: 0;
    padding: 0;
    list-style: none;
}

.fx-toc a {
    display: inline-flex;
    align-items: center;
    min-height: 34px;
}

.fx-help-group + .fx-help-group {
    margin-top: 3rem;
}

.fx-help-group-title {
    margin-bottom: 0.75rem;
}

.fx-faq {
    max-width: 720px;
    padding: 1.5rem 0;
    border-top: 1px solid var(--sip-hairline);
    scroll-margin-top: 1.5rem;
}

    .fx-faq h2,
    .fx-faq h3 {
        margin: 0 0 0.75rem;
        font-size: 1.2rem;
        line-height: 1.35;
        font-weight: 600;
    }

    .fx-faq h4 {
        margin: 1.4rem 0 0;
        font-size: 1rem;
        font-weight: 600;
        color: var(--sip-text);
    }

    .fx-faq p,
    .fx-faq li {
        color: var(--sip-text-2);
        line-height: 1.6;
    }

    .fx-faq > * + * {
        margin-top: 0.75rem;
    }

    .fx-faq ul {
        margin-bottom: 0;
        padding-left: 1.2rem;
    }

        .fx-faq li + li {
            margin-top: 0.5rem;
        }

    .fx-faq .fx-numbered {
        gap: 0.6rem;
    }

        .fx-faq .fx-numbered li + li {
            margin-top: 0;
        }

    .fx-faq strong {
        color: var(--sip-text);
        font-weight: 600;
    }

    .fx-faq .fx-note {
        margin-top: 1rem;
    }

        .fx-faq .fx-note p {
            font-size: 0.95rem;
        }

            .fx-faq .fx-note p + p {
                margin-top: 0.4rem;
            }

/* The example device code: a small, quiet box, never wider than the screen. */
.fx-code-sample {
    display: inline-flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 0.35rem 0.85rem;
    max-width: 100%;
    padding: 0.6rem 0.9rem;
    border: 1px solid var(--sip-hairline);
    border-radius: 10px;
    background: var(--fx-raise);
}

    .fx-code-sample span:first-child {
        font-size: 0.82rem;
        color: var(--sip-muted);
    }

    .fx-code-sample .fx-mono {
        font-size: 1.05rem;
        font-weight: 500;
        color: var(--sip-text);
    }

.fx-help-back {
    margin-top: 1.25rem;
    font-size: 0.88rem;
}

.fx-faq .fx-btn {
    margin-top: 1.1rem;
}

@media (max-width: 640px) {
    .fx-toc {
        padding: 1.1rem 1.1rem 1.2rem;
    }

    .fx-toc-groups {
        grid-template-columns: minmax(0, 1fr);
        gap: 1.1rem;
    }

    .fx-toc a {
        min-height: 44px;
    }

    .fx-faq .fx-btn {
        width: 100%;
    }
}

/* ---------- error and not-found pages ---------- */

.fx-status-page {
    max-width: 560px;
    margin: 0 auto;
    text-align: center;
}

.fx-status-icon {
    display: grid;
    place-items: center;
    width: 56px;
    height: 56px;
    margin: 0 auto 1.4rem;
    border-radius: 50%;
    border: 1px solid var(--sip-hairline);
    background: var(--sip-surface);
    color: var(--sip-text-2);
}

    .fx-status-icon svg {
        width: 26px;
        height: 26px;
    }

.fx-status-page .fx-lead {
    margin-left: auto;
    margin-right: auto;
}

.fx-status-actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.7rem;
    margin-top: 1.75rem;
}

/* A reference to quote to support: small, monospaced, copyable. */
.fx-reference {
    display: inline-flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 0.5rem 0.75rem;
    margin-top: 2rem !important;
    padding: 0.6rem 0.75rem;
    border: 1px solid var(--sip-hairline);
    border-radius: 10px;
    background: var(--fx-raise);
    color: var(--sip-muted);
    font-size: 0.88rem;
}

    .fx-reference code {
        color: var(--sip-text);
        font-family: var(--sip-mono);
        font-size: 0.85rem;
        word-break: break-all;
    }

    .fx-reference .fx-copy {
        min-height: 36px;
    }

/* ---------- registration and "Invite a colleague" (trial rules, October 2026) ---------- */

/* The country, state and organisation type lists: the field's own look, with the platform's arrow. */
select.fx-input {
    appearance: auto;
    cursor: pointer;
}

/* The prewritten colleague message: read-only, wrapping, tall enough to read without scrolling on a desk. */
.fx-textarea {
    min-height: 15rem;
    resize: vertical;
    white-space: pre-wrap;
    line-height: 1.5;
}

.fx-invite + .fx-invite,
.fx-invite {
    margin-top: 1.25rem;
}


/* The activation code on the activation-link page (Activate.razor): its QR code to scan from the
   screen, and the code to copy, on a card of its own. */
.fx-shown-code {
    margin: 1.25rem 0 0.75rem;
    padding: 1.25rem;
    border: 1px solid var(--sip-hairline);
    border-radius: var(--fx-radius);
    background: var(--sip-card);
}
