/* ==========================================================================
   MILE — enterprise sign-in
   Fluent-inspired: mica-neutral ground, one communication-blue accent,
   restrained type, real whitespace. No display-size headlines, no colour slabs.
   ========================================================================== */

:root {
    --ms-accent: #0F6CBD;
    --ms-accent-hover: #115EA3;
    --ms-accent-pressed: #0E4775;
    --ms-ink: #1B1B1F;
    --ms-ink-2: #424250;
    --ms-ink-3: #6B6B76;
    --ms-line: #E1E1E5;
    --ms-line-strong: #8A8A94;
    --ms-surface: #FFFFFF;
    --ms-ground: #F5F5F7;
    --ms-danger: #B10E1C;
}

html, body {
    height: 100%;
    margin: 0;
    background: var(--ms-ground);
    color: var(--ms-ink);
    font-family: "Segoe UI Variable Text", "Segoe UI", -apple-system, BlinkMacSystemFont, Roboto, "Helvetica Neue", Arial, sans-serif;
    -webkit-font-smoothing: antialiased;
}

.ms-shell {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 32px 20px;
    box-sizing: border-box;
    overflow: hidden;
}

/* Mica-like ground: barely-there blue bias, no gradient slab */
.ms-wash {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(1100px 620px at 18% -10%, rgba(15, 108, 189, 0.10), transparent 60%),
        radial-gradient(900px 520px at 105% 110%, rgba(15, 108, 189, 0.07), transparent 62%),
        var(--ms-ground);
}

.ms-stage {
    position: relative;
    width: 100%;
    max-width: 452px;
}

/* ---------- card ---------- */
.ms-card {
    background: var(--ms-surface);
    border: 1px solid var(--ms-line);
    border-radius: 8px;
    padding: 40px 44px 32px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, .09), 0 1px 2px rgba(0, 0, 0, .06);
}

/* ---------- brand ---------- */
.ms-brand {
    display: flex;
    align-items: center;
    gap: 10px;
}

.ms-mark {
    width: 30px;
    height: 30px;
    border-radius: 5px;
    background: var(--ms-accent);
    color: #fff;
    font-size: 16px;
    font-weight: 700;
    line-height: 30px;
    text-align: center;
    letter-spacing: .01em;
}

.ms-word {
    font-size: 19px;
    font-weight: 600;
    letter-spacing: .14em;
    color: var(--ms-ink);
}

.ms-tagline {
    margin: 8px 0 30px;
    font-size: 12.5px;
    color: var(--ms-ink-3);
    letter-spacing: .01em;
}

/* ---------- heading ---------- */
.ms-title {
    margin: 0 0 6px;
    font-family: "Segoe UI Variable Display", "Segoe UI", sans-serif;
    font-size: 24px;
    font-weight: 600;
    letter-spacing: -.01em;
    color: var(--ms-ink);
}

.ms-sub {
    margin: 0 0 26px;
    font-size: 14px;
    color: var(--ms-ink-2);
}

/* ---------- unit chip (step 2) ---------- */
.ms-unit {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin: 0 0 24px;
    padding: 5px 12px 5px 6px;
    border: 1px solid var(--ms-line);
    border-radius: 999px;
    background: #FAFAFC;
    font-size: 13px;
    color: var(--ms-ink-2);
    text-decoration: none;
}

.ms-unit:hover { background: #F2F2F6; color: var(--ms-ink); }

.ms-unit-mark {
    width: 20px; height: 20px; border-radius: 50%;
    background: var(--ms-accent); color: #fff;
    font-size: 11px; font-weight: 700; line-height: 20px; text-align: center;
}

.ms-unit-back { color: var(--ms-ink-3); font-size: 12px; }

/* ---------- fields ---------- */
.ms-field { margin-bottom: 18px; }

.ms-label {
    display: block;
    margin-bottom: 6px;
    font-size: 13px;
    font-weight: 600;
    color: var(--ms-ink-2);
}

.ms-input {
    width: 100%;
    height: 40px;
    padding: 0 12px;
    box-sizing: border-box;
    font-size: 14.5px;
    font-family: inherit;
    color: var(--ms-ink);
    background: #fff;
    border: 1px solid var(--ms-line-strong);
    border-radius: 4px;
    outline: none;
    transition: border-color .12s ease, box-shadow .12s ease;
}

.ms-input::placeholder { color: #9A9AA4; }

.ms-input:hover { border-color: #5A5A66; }

/* Fluent focus: accent underline that grows from the bottom edge */
.ms-input:focus {
    border-color: var(--ms-accent);
    box-shadow: inset 0 -2px 0 0 var(--ms-accent);
}

.ms-error {
    display: block;
    margin-top: 6px;
    font-size: 12.5px;
    color: var(--ms-danger);
}

/* ---------- alert ---------- */
.ms-alert {
    margin: 0 0 18px;
    padding: 10px 12px;
    border-radius: 4px;
    background: #FDF3F4;
    border: 1px solid #F1C7CB;
}

.ms-alert-text, .ms-alert-text ul {
    margin: 0; padding: 0; list-style: none;
    font-size: 13px; color: var(--ms-danger);
}

/* ---------- actions ---------- */
.ms-actions {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    margin-top: 26px;
}

.ms-btn {
    min-width: 108px;
    height: 40px;
    padding: 0 20px;
    font-family: inherit;
    font-size: 14.5px;
    font-weight: 600;
    border-radius: 4px;
    border: 1px solid transparent;
    cursor: pointer;
    transition: background-color .12s ease, border-color .12s ease;
}

.ms-btn-primary { background: var(--ms-accent); color: #fff; }
.ms-btn-primary:hover { background: var(--ms-accent-hover); }
.ms-btn-primary:active { background: var(--ms-accent-pressed); }

.ms-btn-secondary {
    background: #fff;
    color: var(--ms-ink);
    border-color: var(--ms-line-strong);
}
.ms-btn-secondary:hover { background: #F5F5F7; }

/* ---------- helper ---------- */
.ms-help {
    margin-top: 30px;
    padding-top: 18px;
    border-top: 1px solid var(--ms-line);
}

.ms-help-title {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: var(--ms-ink-2);
    margin-bottom: 3px;
}

.ms-help-text { font-size: 12.5px; color: var(--ms-ink-3); }

/* ---------- step indicator ---------- */
.ms-steps {
    display: flex;
    align-items: center;
    gap: 7px;
    margin: 18px 2px 0;
}

.ms-step {
    width: 22px; height: 3px; border-radius: 2px; background: #D8D8DE;
}

.ms-step-on { background: var(--ms-accent); }

.ms-step-label {
    margin-left: 6px;
    font-size: 12px;
    color: var(--ms-ink-3);
}

/* ---------- footer ---------- */
.ms-foot {
    margin-top: 22px;
    text-align: center;
    font-size: 12px;
    color: var(--ms-ink-3);
}

.ms-dot { margin: 0 8px; color: #C6C6CE; }

@media (max-width: 520px) {
    .ms-card { padding: 30px 24px 26px; }
    .ms-stage { max-width: 100%; }
}
