/*
 * SilverDESK Onboarding — Mercury aesthetic
 * Ported from .superpowers/mockups/onboarding-aesthetics.html (.merc* rules)
 * and .superpowers/mockups/onboarding-personalize-mercury.html (.screen* rules).
 *
 * Fonts: body inherits the SilverSHELL design system (Outfit). Accent
 * micro-labels use var(--ss-font-mono) (system monospace) — no web-font CDN.
 * Colors: obsidian bg #090a0d, signal-cyan #7fd2ff / #5fa0d0, ink #dfe4ea, muted #8a99a6
 */

/* ─── CSS variables (Mercury palette) ─────────────────────────────────────── */
:root {
    --ob-bg: #090a0d;
    --ob-panel: #0f1318;
    --ob-ink: #dfe4ea;
    --ob-muted: #8a99a6;
    --ob-faint: #5d6b78;
    --ob-line: rgba(255, 255, 255, 0.08);
    --ob-cyan: #7fd2ff;
    --ob-cyan-deep: #5fa0d0;
}

/* ─── Full-screen obsidian overlay (merc background + dot-grid ::before) ── */
.ob-overlay {
    position: fixed;
    inset: 0;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    /* Radial gradient from onboarding-aesthetics.html .merc rule */
    background: radial-gradient(120% 90% at 80% -10%, #1b2733 0%, #0e1116 45%, #090a0d 100%);
    font-family: 'Outfit', sans-serif;
    -webkit-font-smoothing: antialiased;
}

/* Dot-grid texture from .merc::before */
.ob-overlay::before {
    content: "";
    position: absolute;
    inset: 0;
    background-image: radial-gradient(circle at 1px 1px, rgba(255, 255, 255, 0.04) 1px, transparent 0);
    background-size: 22px 22px;
    opacity: 0.5;
    pointer-events: none;
}

/* Ambient glow from .merc .glow */
.ob-overlay::after {
    content: "";
    position: absolute;
    width: 320px;
    height: 320px;
    right: 0;
    top: -60px;
    background: radial-gradient(circle, rgba(120, 210, 255, 0.18), transparent 65%);
    filter: blur(12px);
    pointer-events: none;
}

/* ─── Glass frame card (from .screen in onboarding-personalize-mercury.html) */
.ob-frame {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: 560px;
    border: 1px solid var(--ob-line);
    border-radius: 20px;
    overflow: hidden;
    background: linear-gradient(180deg, rgba(22, 28, 36, 0.75), rgba(12, 15, 20, 0.9));
    box-shadow: 0 40px 90px -40px rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(6px);
    color: var(--ob-ink);
}

/* ─── Header chrome (.screen-head) ──────────────────────────────────────── */
.ob-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 26px;
    border-bottom: 1px solid var(--ob-line);
}

/* Brand (.brand from personalize mockup) */
.ob-brand {
    display: flex;
    align-items: center;
    gap: 9px;
    font-family: var(--ss-font-mono, monospace);
    font-size: 11px;
    letter-spacing: 0.24em;
    text-transform: uppercase;
    color: #7f95a5;
}

/* Glowing dot (.dot from both mockups) */
.ob-dot {
    display: inline-block;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: linear-gradient(180deg, #cfe9ff, #62a8d6);
    box-shadow: 0 0 12px rgba(120, 200, 255, 0.8);
    flex-shrink: 0;
}

/* Progress bars (.bars + .bars i / .bars i.on from both mockups) */
.ob-bars {
    display: flex;
    gap: 5px;
    width: 160px;
}

.ob-bars i {
    height: 3px;
    border-radius: 3px;
    flex: 1;
    background: #26313b;
    font-style: normal;
}

.ob-bars i.on {
    background: linear-gradient(90deg, #bfe4ff, #5fa0d0);
}

/* Skip link (.ghost / .skip from both mockups) */
.ob-skip {
    background: none;
    border: none;
    padding: 0;
    cursor: pointer;
    font-size: 12.5px;
    color: var(--ob-faint);
    font-family: inherit;
    transition: color 0.18s;
}

.ob-skip:hover {
    color: var(--ob-muted);
}

/* ─── Body ──────────────────────────────────────────────────────────────── */
.ob-body {
    padding: 32px 30px 28px;
    min-height: 200px;
}

/* ─── Steps ─────────────────────────────────────────────────────────────── */
.ob-step {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

/* Gradient heading from .merc h3 */
.ob-h {
    font-family: 'Outfit', sans-serif;
    font-size: 36px;
    line-height: 1.06;
    font-weight: 300;
    letter-spacing: -0.02em;
    margin: 0 0 8px;
    background: linear-gradient(180deg, #ffffff 10%, #9fb4c4 120%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.ob-h b {
    font-weight: 600;
}

/* Body copy from .merc p */
.ob-p {
    color: var(--ob-muted);
    font-size: 14.5px;
    line-height: 1.6;
    max-width: 90%;
    margin: 0;
}

/* Finish spark (the ✦ icon in the Aurora mockup, adapted for Mercury) */
.ob-spark {
    font-size: 40px;
    margin-bottom: 6px;
    background: linear-gradient(135deg, #bfe4ff, #7fd2ff);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    line-height: 1;
}

/* ─── Footer chrome (.screen-foot) ──────────────────────────────────────── */
.ob-foot {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 18px 26px;
    border-top: 1px solid var(--ob-line);
    gap: 12px;
}

.ob-spacer {
    flex: 1;
}

/* Primary CTA (.cta / .btn from both mockups) */
.ob-cta {
    padding: 13px 22px;
    border: none;
    border-radius: 11px;
    cursor: pointer;
    font-weight: 600;
    font-size: 13.5px;
    font-family: inherit;
    background: linear-gradient(180deg, #e9f4ff, #bcd6e8);
    color: #0d1620;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: opacity 0.18s, transform 0.12s;
}

.ob-cta:hover {
    opacity: 0.9;
    transform: translateY(-1px);
}

.ob-cta:active {
    transform: translateY(0);
}

/* Ghost back button (.btn.ghost from personalize mockup) */
.ob-ghost {
    padding: 11px 18px;
    border: 1px solid var(--ob-line);
    border-radius: 11px;
    cursor: pointer;
    font-size: 13px;
    font-family: inherit;
    font-weight: 500;
    background: transparent;
    color: var(--ob-muted);
    transition: border-color 0.18s, color 0.18s;
}

.ob-ghost:hover {
    border-color: rgba(127, 210, 255, 0.35);
    color: var(--ob-ink);
}

/* ─── B1 Profile step — form inputs ────────────────────────────────────────── */
.ob-label {
    font-family: var(--ss-font-mono, monospace);
    font-size: 10.5px;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--ob-faint);
    margin-bottom: -4px;
}

.ob-input {
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--ob-line);
    border-radius: 9px;
    color: var(--ob-ink);
    font-family: 'Outfit', sans-serif;
    font-size: 14px;
    padding: 10px 14px;
    outline: none;
    transition: border-color 0.18s, box-shadow 0.18s;
    width: 100%;
    box-sizing: border-box;
}

.ob-input:focus {
    border-color: var(--ob-cyan-deep);
    box-shadow: 0 0 0 3px rgba(95, 160, 208, 0.18);
}

.ob-input::placeholder {
    color: var(--ob-faint);
}

.ob-error {
    color: #e07070;
    font-size: 13px;
    margin: 0;
}

/* ─── B3 Apps step ──────────────────────────────────────────────────────────── */
.ob-applist {
    display: flex;
    flex-direction: column;
    gap: 0;
}

.ob-approw {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 0;
    border-bottom: 1px solid var(--ob-line);
    font-size: 14px;
    color: var(--ob-ink);
}

.ob-approw:last-child {
    border-bottom: none;
}

.ob-toggle {
    width: 42px;
    height: 24px;
    border: 0;
    border-radius: 100px;
    background: #26313b;
    position: relative;
    cursor: pointer;
    padding: 0;
    transition: background 0.18s;
    flex-shrink: 0;
}

.ob-toggle.on {
    background: linear-gradient(90deg, var(--ob-cyan), var(--ob-cyan-deep));
}

.ob-toggle::after {
    content: "";
    position: absolute;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: #fff;
    top: 3px;
    left: 3px;
    transition: left 0.15s;
}

.ob-toggle.on::after {
    left: 21px;
}

/* ─── B5 Layout step — wireframe cards ──────────────────────────────────────── */
.ob-layouts {
    display: flex;
    gap: 14px;
    margin-top: 4px;
}

.ob-lay {
    flex: 1;
    background: transparent;
    border: 1px solid var(--ob-line);
    border-radius: 12px;
    padding: 12px;
    cursor: pointer;
    color: var(--ob-muted);
    font-family: inherit;
    text-align: left;
    transition: border-color 0.18s, background 0.18s;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.ob-lay:hover {
    border-color: rgba(127, 210, 255, 0.3);
    color: var(--ob-ink);
}

.ob-lay.sel {
    border-color: var(--ob-cyan-deep);
    background: rgba(95, 160, 208, 0.08);
    color: var(--ob-ink);
}

.ob-lay h4 {
    font-size: 12.5px;
    font-weight: 500;
    margin: 0;
}

/* Mini wireframe shared base */
.ob-wf {
    height: 90px;
    border-radius: 7px;
    overflow: hidden;
    background: #0b0e12;
    border: 1px solid var(--ob-line);
    display: flex;
    position: relative;
}

/* Shared sub-element colours */
.ob-wf .ico { background: #2b3742; border-radius: 3px; }
.ob-wf .acc { background: linear-gradient(135deg, var(--ob-cyan), var(--ob-cyan-deep)); border-radius: 3px; }
.ob-wf .pane { background: #11161c; border-radius: 4px; }

/* Classic: left activity bar */
.ob-wf-classic .rail {
    width: 22px;
    background: #0e141a;
    border-right: 1px solid var(--ob-line);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    padding: 7px 0;
}
.ob-wf-classic .rail .ico,
.ob-wf-classic .rail .acc { width: 11px; height: 11px; }
.ob-wf-classic .main {
    flex: 1;
    padding: 8px;
    display: flex;
    flex-direction: column;
    gap: 6px;
}
.ob-wf-classic .main .pane { height: 11px; width: 55%; }
.ob-wf-classic .main .pane.big { flex: 1; width: 100%; }

/* Hub: top bar + grid */
.ob-wf-hub { flex-direction: column; }
.ob-wf-hub .top {
    height: 22px;
    background: #0e141a;
    border-bottom: 1px solid var(--ob-line);
    display: flex;
    align-items: center;
    gap: 5px;
    padding: 0 8px;
}
.ob-wf-hub .top .ico,
.ob-wf-hub .top .acc { width: 10px; height: 10px; }
.ob-wf-hub .top .sp { flex: 1; }
.ob-wf-hub .body {
    flex: 1;
    padding: 8px;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 5px;
}
.ob-wf-hub .body .pane { border-radius: 4px; }

/* Dock: canvas + bottom pill */
.ob-wf-dock { flex-direction: column; position: relative; }
.ob-wf-dock .canvas {
    flex: 1;
    padding: 8px;
    display: flex;
    flex-direction: column;
    gap: 6px;
}
.ob-wf-dock .canvas .pane { height: 11px; width: 50%; }
.ob-wf-dock .canvas .pane.big { flex: 1; width: 100%; }
.ob-wf-dock .dock {
    position: absolute;
    bottom: 7px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 5px;
    padding: 5px 7px;
    border-radius: 100px;
    background: rgba(255, 255, 255, 0.07);
    border: 1px solid var(--ob-line);
}
.ob-wf-dock .dock .ico,
.ob-wf-dock .dock .acc { width: 11px; height: 11px; border-radius: 4px; }
