/* XSPA 安裝精靈（install/） */
.admin-shell--install {
    max-width: 36rem;
}

.admin-shell--install .admin-main {
    width: 100%;
}

.admin-shell--install .card--narrow {
    max-width: none;
}

.install-brand {
    margin-bottom: 1.25rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    font-size: 1rem;
    color: var(--fg);
}

.install-brand span {
    color: var(--muted);
    font-weight: 600;
    margin-left: 0.35rem;
    font-size: 0.9rem;
}

.install-steps {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin: 0 0 1.25rem;
    padding: 0;
    list-style: none;
}

.install-steps li {
    flex: 1 1 auto;
    min-width: 5.5rem;
    padding: 0.45rem 0.65rem;
    border-radius: var(--radius-sm);
    border: 1px solid var(--line);
    font-size: 0.8rem;
    text-align: center;
    color: var(--muted);
    background: rgba(255, 255, 255, 0.02);
}

.install-steps li.is-done {
    color: var(--ok);
    border-color: rgba(126, 231, 135, 0.35);
    background: rgba(126, 231, 135, 0.08);
}

.install-steps li.is-active {
    color: var(--accent);
    border-color: rgba(121, 192, 255, 0.45);
    background: var(--accent-dim);
    font-weight: 600;
}

.install-steps li.is-pending {
    opacity: 0.72;
}

.admin-shell--install input[type="email"],
.admin-shell--install input[type="number"],
.admin-shell--install select {
    width: 100%;
    max-width: 100%;
    padding: 0.5rem 0.65rem;
    border-radius: var(--radius-sm);
    border: 1px solid var(--line);
    background: var(--bg-elevated);
    color: var(--fg);
    font-size: 1rem;
    font-family: inherit;
}

.admin-shell--install input[type="text"],
.admin-shell--install input[type="password"] {
    max-width: 100%;
}

.admin-shell--install .card-title {
    font-size: 1.05rem;
    font-weight: 650;
    margin: 0 0 0.65rem;
    line-height: 1.3;
}

.admin-shell--install .install-status-list {
    margin: 0;
    padding-left: 1.15rem;
    line-height: 1.65;
}

.admin-shell--install .install-foot {
    margin-top: 1.5rem;
    padding-top: 1rem;
    border-top: 1px solid var(--line);
}

.field-hint {
    margin: 0.3rem 0 0;
    font-size: 0.78rem;
    color: var(--muted);
    line-height: 1.5;
}

.field-hint.is-ok {
    color: var(--ok);
}

.field-hint.is-bad {
    color: var(--bad);
}

.install-actions {
    margin-top: 1.1rem;
    display: flex;
    gap: 0.6rem;
    flex-wrap: wrap;
}

.install-quickfill {
    margin-bottom: 1rem;
}

.btn-ghost {
    appearance: none;
    cursor: pointer;
    padding: 0.4rem 0.75rem;
    font-size: 0.82rem;
    font-family: inherit;
    border-radius: var(--radius-sm);
    border: 1px dashed var(--line);
    background: rgba(255, 255, 255, 0.02);
    color: var(--accent);
}

.btn-ghost:hover {
    background: var(--accent-dim);
}

.btn-primary {
    display: inline-block;
    text-decoration: none;
    cursor: pointer;
    padding: 0.55rem 1.1rem;
    font-size: 0.95rem;
    font-weight: 600;
    border-radius: var(--radius-sm);
    border: 1px solid transparent;
    background: var(--accent);
    color: #0b0d12;
}

.btn-primary:hover {
    filter: brightness(1.05);
}

.install-advanced {
    margin-top: 0.85rem;
    border: 1px solid var(--line);
    border-radius: var(--radius-sm);
    padding: 0.2rem 0.75rem;
}

.install-advanced summary {
    cursor: pointer;
    padding: 0.45rem 0;
    font-size: 0.85rem;
    color: var(--muted);
}

.install-advanced[open] summary {
    color: var(--fg);
    margin-bottom: 0.4rem;
}

.admin-shell--install button.is-loading,
.admin-shell--install button[disabled] {
    opacity: 0.65;
    cursor: progress;
}

.pw-field {
    position: relative;
    display: flex;
    align-items: stretch;
}

.pw-field input {
    flex: 1 1 auto;
    padding-right: 3.5rem;
}

.pw-toggle {
    position: absolute;
    right: 0.35rem;
    top: 50%;
    transform: translateY(-50%);
    appearance: none;
    cursor: pointer;
    border: none;
    background: transparent;
    color: var(--accent);
    font-size: 0.8rem;
    font-family: inherit;
    padding: 0.25rem 0.5rem;
}

.pw-strength {
    margin-top: 0.45rem;
    display: flex;
    align-items: center;
    gap: 0.6rem;
}

.pw-strength-bar {
    flex: 1 1 auto;
    height: 6px;
    border-radius: 999px;
    background: var(--line);
    overflow: hidden;
}

.pw-strength-bar > span {
    display: block;
    height: 100%;
    width: 0;
    background: var(--bad);
    transition: width 0.2s ease, background 0.2s ease;
}

.pw-strength[data-level="weak"] .pw-strength-bar > span { background: var(--bad); }
.pw-strength[data-level="fair"] .pw-strength-bar > span { background: var(--warn); }
.pw-strength[data-level="good"] .pw-strength-bar > span { background: var(--accent); }
.pw-strength[data-level="strong"] .pw-strength-bar > span { background: var(--ok); }

.pw-strength-text {
    font-size: 0.78rem;
    color: var(--muted);
    white-space: nowrap;
}

.install-env-list {
    list-style: none;
    margin: 0.75rem 0 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.install-env-list li {
    display: grid;
    grid-template-columns: 1.5rem 1fr;
    align-items: baseline;
    gap: 0.25rem 0.5rem;
    font-size: 0.88rem;
    color: var(--fg);
}

.install-env-list .env-mark {
    grid-row: span 2;
    font-weight: 700;
}

.install-env-list li.is-ok .env-mark { color: var(--ok); }
.install-env-list li.is-fatal .env-mark { color: var(--bad); }
.install-env-list li.is-warn .env-mark { color: var(--warn); }

.install-env-list .env-hint {
    grid-column: 2;
    font-size: 0.78rem;
    color: var(--muted);
    line-height: 1.5;
}

.env-blocked {
    margin-top: 0.85rem;
    color: var(--bad);
}

.env-x {
    color: var(--bad);
    font-weight: 700;
}

.install-next {
    margin: 0.5rem 0 0;
    padding-left: 1.25rem;
    line-height: 1.7;
    font-size: 0.92rem;
}

.install-next li {
    margin-bottom: 0.35rem;
}

.install-security {
    margin-top: 1rem;
    line-height: 1.6;
}

.install-perm .perm-path {
    font-size: 0.78rem;
    color: var(--muted);
    margin-left: 0.35rem;
    font-weight: 400;
}

.install-perm-fix {
    margin-top: 0.85rem;
}

.install-perm-fix .btn-ghost {
    font-size: 0.88rem;
    padding: 0.5rem 0.9rem;
    border-style: solid;
}
