:root {
    color-scheme: light;
    --page: #f6f7f7;
    --surface: #fbfcfc;
    --surface-muted: #f2f4f5;
    --ink: #20252a;
    --ink-soft: #596169;
    --ink-faint: #79828a;
    --line: #d8dde0;
    --line-strong: #c9d0d4;
    --action: #30363b;
    --action-hover: #24292d;
    --error: #8d4b4b;
    --error-soft: #f8eeee;
    --success: #4c6258;
    --success-soft: #edf3ef;
    --radius: 10px;
    --font-sans: "IBM Plex Sans", "Segoe UI", Arial, sans-serif;
    --font-mono: "IBM Plex Mono", Consolas, monospace;
}

* {
    box-sizing: border-box;
}

html {
    min-width: 320px;
    background: var(--page);
}

body {
    margin: 0;
    color: var(--ink);
    font-family: var(--font-sans);
    font-size: 14px;
    line-height: 1.45;
    -webkit-font-smoothing: antialiased;
}

button,
input {
    font: inherit;
}

a {
    color: inherit;
}

.registration-page,
.status-page {
    position: relative;
    isolation: isolate;
    min-height: 100dvh;
    overflow: hidden;
    background:
        radial-gradient(circle at 50% 18%, rgba(255, 255, 255, .96), transparent 56%),
        var(--page);
}

.registration-page::before,
.status-page::before {
    position: fixed;
    inset: 0;
    z-index: -2;
    content: "";
    pointer-events: none;
    background:
        linear-gradient(180deg, rgba(255, 255, 255, .7), transparent 44%),
        radial-gradient(circle at 50% 100%, rgba(217, 223, 226, .38), transparent 58%);
}

.registration-page::after,
.status-page::after {
    position: fixed;
    inset: 0;
    z-index: -1;
    content: "";
    pointer-events: none;
    background: linear-gradient(90deg, rgba(255, 255, 255, .15), transparent 24%, transparent 76%, rgba(255, 255, 255, .15));
}

.ambient-background {
    position: fixed;
    inset: 0;
    z-index: 0;
    display: block;
    width: 100%;
    height: 100%;
    overflow: hidden;
    pointer-events: none;
    opacity: .97;
    -webkit-mask-image: linear-gradient(to bottom, rgba(0, 0, 0, .28) 0, rgba(0, 0, 0, .72) 16%, #000 36%, #000 100%);
    mask-image: linear-gradient(to bottom, rgba(0, 0, 0, .28) 0, rgba(0, 0, 0, .72) 16%, #000 36%, #000 100%);
}

.skip-link {
    position: fixed;
    top: 12px;
    left: 12px;
    z-index: 20;
    padding: 9px 13px;
    border-radius: 6px;
    background: var(--action);
    color: #f8f9f9;
    font-weight: 600;
    text-decoration: none;
    transform: translateY(-160%);
}

.skip-link:focus {
    transform: translateY(0);
}

.registration-shell {
    position: absolute;
    top: 50%;
    left: 50%;
    display: grid;
    grid-template-rows: 54px minmax(0, 1fr) 40px;
    width: min(1080px, calc(100% - 48px));
    height: min(580px, calc(100dvh - 36px));
    min-height: 540px;
    overflow: hidden;
    border: 1px solid rgba(185, 193, 198, .88);
    border-radius: var(--radius);
    background: var(--surface);
    box-shadow:
        0 1px 2px rgba(38, 46, 52, .04),
        0 24px 64px rgba(57, 68, 76, .11);
    transform: translate(-50%, -50%);
    z-index: 2;
}

.site-header,
.site-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.site-header {
    justify-content: flex-start;
    padding: 0 26px;
    border-bottom: 1px solid var(--line);
    background: rgba(251, 252, 252, .94);
}

.site-header h1 {
    margin: 0;
    font-size: 17px;
    font-weight: 600;
    letter-spacing: -.025em;
    line-height: 1;
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 11px;
    color: var(--ink);
    text-decoration: none;
}

.brand-mark {
    display: grid;
    width: 32px;
    height: 32px;
    place-items: center;
    border-radius: 7px;
    background: var(--action);
}

.brand-mark svg {
    width: 19px;
    fill: none;
    stroke: #f7f8f8;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-width: 1.7;
}

.brand strong,
.brand small {
    display: block;
}

.brand strong {
    font-size: 14px;
    font-weight: 600;
    letter-spacing: -.01em;
}

.brand small {
    margin-top: 1px;
    color: var(--ink-faint);
    font-family: var(--font-mono);
    font-size: 8px;
    font-weight: 500;
    letter-spacing: .12em;
    text-transform: uppercase;
}

.support-link {
    color: var(--ink-soft);
    font-size: 12px;
    font-weight: 500;
    text-underline-offset: 3px;
}

.support-link:hover {
    color: var(--ink);
}

.registration-body {
    display: grid;
    min-height: 0;
    grid-template-columns: 292px minmax(0, 1fr);
}

.intro-panel {
    position: relative;
    display: flex;
    min-height: 0;
    flex-direction: column;
    justify-content: space-between;
    overflow: hidden;
    padding: 29px 26px 25px;
    border-right: 1px solid var(--line);
    background: var(--surface-muted);
}

.intro-panel::before {
    position: absolute;
    inset: 0;
    content: "";
    pointer-events: none;
    background-image: radial-gradient(circle, rgba(77, 87, 95, .13) 1px, transparent 1.1px);
    background-size: 18px 18px;
    opacity: .34;
    -webkit-mask-image: linear-gradient(145deg, transparent 12%, #000 70%);
    mask-image: linear-gradient(145deg, transparent 12%, #000 70%);
}

.intro-panel::after {
    position: absolute;
    right: -76px;
    bottom: -86px;
    width: 220px;
    height: 220px;
    border: 1px solid rgba(160, 169, 175, .24);
    border-radius: 50%;
    box-shadow:
        0 0 0 34px rgba(183, 190, 195, .08),
        0 0 0 70px rgba(183, 190, 195, .05);
    content: "";
    pointer-events: none;
}

.intro-content,
.privacy-note {
    position: relative;
    z-index: 1;
}

.eyebrow,
.requirements-title,
.activation-code span {
    color: var(--ink-faint);
    font-family: var(--font-mono);
    font-size: 9px;
    font-weight: 500;
    letter-spacing: .12em;
    text-transform: uppercase;
}

h1,
h2,
p {
    margin-top: 0;
}

.intro-copy {
    max-width: 230px;
    margin: 13px 0 24px;
    color: var(--ink-soft);
    font-size: 13px;
    line-height: 1.55;
}

.requirements {
    border-top: 1px solid var(--line-strong);
    padding-top: 16px;
}

.requirements dl {
    display: grid;
    gap: 12px;
    margin: 12px 0 0;
}

.requirements dl > div {
    display: grid;
    grid-template-columns: 78px minmax(0, 1fr);
    gap: 9px;
}

.requirements dt {
    color: var(--ink);
    font-size: 11px;
    font-weight: 600;
}

.requirements dd {
    margin: 0;
    color: var(--ink-soft);
    font-size: 11px;
    line-height: 1.38;
}

.privacy-note {
    display: grid;
    grid-template-columns: 20px minmax(0, 1fr);
    gap: 10px;
    align-items: start;
    padding-top: 15px;
    border-top: 1px solid var(--line-strong);
}

.privacy-note svg {
    width: 18px;
    fill: none;
    stroke: var(--ink-soft);
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-width: 1.5;
}

.privacy-note p {
    margin-bottom: 0;
    color: var(--ink-soft);
    font-size: 10px;
    line-height: 1.4;
}

.privacy-note strong {
    color: var(--ink);
    font-size: 11px;
    font-weight: 600;
}

.form-panel {
    min-width: 0;
    overflow: hidden;
    padding: 26px 30px 20px;
    background: var(--surface);
}

.form-heading {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    margin-bottom: 18px;
}

.form-heading h2 {
    margin: 5px 0 0;
    font-size: 22px;
    font-weight: 600;
    letter-spacing: -.035em;
    line-height: 1.15;
}

.required-note {
    padding-top: 3px;
    color: var(--ink-faint);
    font-size: 10px;
}

.required-note i {
    color: var(--error);
    font-style: normal;
}

.field-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 11px 14px;
}

.field {
    position: relative;
    display: grid;
    min-width: 0;
    gap: 4px;
}

.field-company {
    grid-column: 1 / -1;
}

.field label,
.label-row {
    min-height: 16px;
}

.field label {
    color: #3f464c;
    font-size: 10px;
    font-weight: 600;
}

.field label span {
    color: var(--error);
}

.label-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
}

.help-trigger {
    min-width: 0;
    padding: 0;
    border: 0;
    border-bottom: 1px solid #9ca5ab;
    background: transparent;
    color: var(--ink-soft);
    cursor: pointer;
    font-size: 9px;
    line-height: 1.2;
}

.help-trigger:hover,
.help-trigger:focus-visible {
    border-color: var(--ink);
    color: var(--ink);
}

.field input {
    width: 100%;
    height: 39px;
    padding: 0 12px;
    border: 1px solid var(--line-strong);
    border-radius: 6px;
    outline: 0;
    background: #fdfefe;
    color: var(--ink);
    font-size: 12px;
    transition:
        border-color 150ms ease,
        box-shadow 150ms ease,
        background-color 150ms ease;
}

.field input::placeholder {
    color: #899198;
    opacity: 1;
}

.field input:hover {
    border-color: #aab2b7;
}

.field input:focus {
    border-color: #626d75;
    box-shadow: 0 0 0 3px rgba(78, 90, 99, .12);
}

.field input[aria-invalid="true"] {
    border-color: var(--error);
    background: #fffafa;
}

.field-error {
    min-height: 0;
    color: var(--error);
    font-size: 9px;
    line-height: 1.2;
}

.field-error:empty {
    display: none;
}

.form-actions {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 15px;
}

.button {
    display: inline-flex;
    min-height: 38px;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 0 16px;
    border: 1px solid transparent;
    border-radius: 6px;
    cursor: pointer;
    font-size: 11px;
    font-weight: 600;
    line-height: 1;
    text-decoration: none;
    transition:
        background-color 150ms ease,
        border-color 150ms ease,
        transform 150ms ease;
}

.button:active {
    transform: translateY(1px);
}

.button svg {
    width: 15px;
    fill: none;
    stroke: currentColor;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-width: 1.7;
}

.button-primary {
    border-color: var(--action);
    background: var(--action);
    color: #f8f9f9;
}

.button-primary:hover,
.button-primary:focus-visible {
    border-color: var(--action-hover);
    background: var(--action-hover);
}

.button-secondary {
    border-color: transparent;
    background: transparent;
    color: var(--ink-soft);
}

.button-secondary:hover,
.button-secondary:focus-visible {
    background: var(--surface-muted);
    color: var(--ink);
}

.form-disclaimer {
    max-width: 530px;
    margin: 10px 0 0;
    color: var(--ink-faint);
    font-size: 9px;
    line-height: 1.45;
}

.form-feedback,
.alert {
    margin-bottom: 12px;
    border-radius: 6px;
    font-size: 11px;
}

.form-feedback {
    padding: 9px 11px;
    border: 1px solid #d7bebe;
    background: var(--error-soft);
    color: #753c3c;
}

.alert {
    display: grid;
    grid-template-columns: 18px minmax(0, 1fr);
    gap: 9px;
    padding: 9px 11px;
    border: 1px solid #ddc7c7;
    background: var(--error-soft);
    color: #6f3f3f;
}

.alert svg {
    width: 16px;
    fill: none;
    stroke: currentColor;
    stroke-linecap: round;
    stroke-width: 1.6;
}

.alert strong {
    font-size: 11px;
}

.alert p {
    margin: 1px 0 0;
    font-size: 10px;
}

.site-footer {
    padding: 0 26px;
    border-top: 1px solid var(--line);
    background: #f7f8f8;
    color: var(--ink-faint);
    font-size: 9px;
}

.site-footer p {
    margin: 0;
}

.site-footer div {
    display: flex;
    gap: 18px;
}

.site-footer a {
    text-underline-offset: 3px;
}

.help-dialog {
    width: min(520px, calc(100% - 32px));
    padding: 0;
    overflow: hidden;
    border: 1px solid var(--line-strong);
    border-radius: var(--radius);
    background: var(--surface);
    color: var(--ink);
    box-shadow: 0 24px 80px rgba(34, 42, 48, .22);
}

.help-dialog::backdrop {
    background: rgba(35, 42, 47, .46);
    backdrop-filter: blur(3px);
}

.dialog-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 18px 20px;
    border-bottom: 1px solid var(--line);
}

.dialog-header h2 {
    margin: 3px 0 0;
    font-size: 18px;
}

.dialog-close {
    width: 34px;
    height: 34px;
    border: 0;
    border-radius: 6px;
    background: var(--surface-muted);
    color: var(--ink-soft);
    cursor: pointer;
    font-size: 22px;
}

.help-dialog img {
    display: block;
    width: 100%;
    height: auto;
}

.status-page {
    display: grid;
    place-items: center;
}

.status-wrap {
    position: relative;
    z-index: 2;
    width: min(620px, calc(100% - 40px));
}

.status-wrap > .brand {
    margin: 0 0 14px;
}

.status-card {
    position: relative;
    overflow: hidden;
    padding: 52px 54px 48px;
    border: 1px solid var(--line-strong);
    border-radius: var(--radius);
    background: rgba(251, 252, 252, .96);
    box-shadow: 0 24px 64px rgba(57, 68, 76, .11);
    text-align: center;
}

.status-card::before {
    position: absolute;
    top: 0;
    right: 0;
    width: 160px;
    height: 120px;
    content: "";
    pointer-events: none;
    background-image: radial-gradient(circle, rgba(71, 82, 91, .13) 1px, transparent 1.1px);
    background-size: 16px 16px;
    -webkit-mask-image: linear-gradient(135deg, #000, transparent 75%);
    mask-image: linear-gradient(135deg, #000, transparent 75%);
}

.status-icon {
    display: grid;
    width: 46px;
    height: 46px;
    margin: 0 auto 18px;
    place-items: center;
    border: 1px solid #cbd7d0;
    border-radius: 8px;
    background: var(--success-soft);
    color: var(--success);
}

.status-icon.error {
    border-color: #dfcaca;
    background: var(--error-soft);
    color: var(--error);
}

.status-icon svg {
    width: 23px;
    fill: none;
    stroke: currentColor;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-width: 1.7;
}

.status-card h1 {
    margin: 8px 0 10px;
    font-size: 28px;
    font-weight: 600;
    letter-spacing: -.04em;
    line-height: 1.1;
}

.status-card > p {
    max-width: 430px;
    margin: 0 auto 20px;
    color: var(--ink-soft);
    font-size: 12px;
}

.activation-code {
    display: grid;
    max-width: 390px;
    gap: 5px;
    margin: 0 auto 20px;
    padding: 13px;
    border: 1px solid var(--line);
    border-radius: 6px;
    background: var(--surface-muted);
}

.activation-code code {
    color: var(--ink);
    font-family: var(--font-mono);
    font-size: 15px;
}

.status-card .button {
    min-height: 39px;
}

.status-card .status-support {
    margin-top: 16px;
    margin-bottom: 0;
    font-size: 10px;
}

.status-support a {
    color: var(--ink);
    font-weight: 500;
    text-underline-offset: 3px;
}

@media (min-width: 901px) and (max-height: 620px) {
    .registration-shell {
        height: calc(100dvh - 24px);
        min-height: 0;
        grid-template-rows: 50px minmax(0, 1fr) 34px;
    }

    .registration-body {
        grid-template-columns: 270px minmax(0, 1fr);
    }

    .intro-panel {
        padding: 21px 23px 18px;
    }

    .intro-copy {
        margin-bottom: 16px;
    }

    .requirements dl {
        gap: 8px;
    }

    .form-panel {
        padding: 18px 25px 14px;
    }

    .form-heading {
        margin-bottom: 10px;
    }

    .field-grid {
        gap: 7px 12px;
    }

    .field input {
        height: 35px;
    }

    .form-actions {
        margin-top: 10px;
    }

    .form-disclaimer {
        margin-top: 6px;
    }
}

@media (max-width: 900px) {
    .registration-page {
        min-height: 100dvh;
        overflow: auto;
        padding: 18px;
    }

    .registration-shell {
        position: relative;
        top: auto;
        left: auto;
        width: min(680px, 100%);
        height: auto;
        min-height: 0;
        margin: 0 auto;
        grid-template-rows: auto;
        transform: none;
    }

    .site-header,
    .site-footer {
        min-height: 58px;
        padding: 0 20px;
    }

    .registration-body {
        grid-template-columns: 1fr;
    }

    .intro-panel {
        min-height: 290px;
        padding: 26px 24px 22px;
        border-right: 0;
        border-bottom: 1px solid var(--line);
    }

    .intro-copy {
        max-width: 410px;
    }

    .requirements {
        max-width: 420px;
    }

    .privacy-note {
        margin-top: 24px;
    }

    .form-panel {
        overflow: visible;
        padding: 26px 24px;
    }

    .site-footer {
        flex-wrap: wrap;
        gap: 7px 20px;
        padding-top: 12px;
        padding-bottom: 12px;
    }

    .status-page {
        min-height: 100dvh;
        overflow: auto;
        padding: 24px 0;
    }
}

@media (max-width: 580px) {
    .registration-page {
        padding: 10px;
    }

    .site-header {
        min-height: 52px;
    }

    .registration-body {
        display: block;
    }

    .intro-panel {
        min-height: 0;
    }

    .requirements dl > div {
        grid-template-columns: 72px minmax(0, 1fr);
    }

    .field-grid {
        grid-template-columns: 1fr;
    }

    .field-company {
        grid-column: auto;
    }

    .form-heading {
        gap: 14px;
    }

    .form-heading h2 {
        font-size: 20px;
    }

    .form-actions {
        align-items: stretch;
        flex-direction: column;
    }

    .button {
        width: 100%;
    }

    .site-footer {
        align-items: flex-start;
        flex-direction: column;
    }

    .site-footer div {
        flex-wrap: wrap;
        gap: 8px 15px;
    }

    .status-wrap {
        width: min(100% - 20px, 620px);
    }

    .status-card {
        padding: 40px 24px 36px;
    }

    .status-card h1 {
        font-size: 24px;
    }

    .ambient-background {
        opacity: .82;
    }
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        scroll-behavior: auto !important;
        transition-duration: .01ms !important;
    }

}
