﻿/* Platform Guide shell integration.
   Presentation only: authorization remains enforced by destination controllers. */

.platform-help-launcher {
    position: fixed;
    right: 1.25rem;
    bottom: 1.25rem;
    z-index: 1035;
    display: inline-flex;
    align-items: center;
    gap: .6rem;
    min-height: 46px;
    padding: .5rem .85rem .5rem .55rem;
    border: 1px solid rgba(148, 163, 184, .35);
    border-radius: 999px;
    background: rgba(15, 23, 42, .96);
    color: #fff;
    box-shadow: 0 16px 44px rgba(15, 23, 42, .22);
    font-weight: 750;
    transition: transform .18s ease, box-shadow .18s ease, background-color .18s ease;
}

    .platform-help-launcher:hover,
    .platform-help-launcher:focus-visible {
        color: #fff;
        background: #111c30;
        transform: translateY(-2px);
        box-shadow: 0 20px 52px rgba(15, 23, 42, .28);
    }

    .platform-help-launcher:focus-visible,
    .platform-help-panel__close:focus-visible,
    .platform-help-action:focus-visible {
        outline: 3px solid rgba(59, 130, 246, .35);
        outline-offset: 3px;
    }

.platform-help-launcher__icon {
    display: grid;
    width: 34px;
    height: 34px;
    place-items: center;
    border-radius: 50%;
    background: linear-gradient(145deg, #2563eb, #4f46e5);
    font-size: 1rem;
    font-weight: 900;
}

.platform-help-backdrop {
    position: fixed;
    inset: 0;
    z-index: 1040;
    background: rgba(15, 23, 42, .3);
    opacity: 0;
    visibility: hidden;
    backdrop-filter: blur(2px);
    transition: opacity .2s ease, visibility .2s ease;
}

.platform-help-panel {
    position: fixed;
    top: 0;
    right: 0;
    z-index: 1045;
    width: min(430px, 100vw);
    height: 100dvh;
    display: flex;
    flex-direction: column;
    background: #fff;
    border-left: 1px solid #e2e8f0;
    box-shadow: -24px 0 70px rgba(15, 23, 42, .16);
    transform: translateX(102%);
    visibility: hidden;
    transition: transform .24s cubic-bezier(.2,.8,.2,1), visibility .24s ease;
}

    .platform-help-panel.is-open,
    .platform-help-backdrop.is-open {
        visibility: visible;
    }

    .platform-help-panel.is-open {
        transform: translateX(0);
    }

.platform-help-backdrop.is-open {
    opacity: 1;
}

html.platform-help-open {
    overflow: hidden;
}

.platform-help-panel__header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
    padding: 1.4rem 1.4rem 1.15rem;
    border-bottom: 1px solid #e2e8f0;
    background: linear-gradient(145deg, #f8fafc, #eef4ff);
}

.platform-help-panel__eyebrow,
.platform-help-section__label {
    display: block;
    margin-bottom: .4rem;
    color: #2563eb;
    font-size: .72rem;
    font-weight: 850;
    letter-spacing: .1em;
    text-transform: uppercase;
}

.platform-help-panel__header h2 {
    margin: 0;
    color: #0f172a;
    font-size: 1.35rem;
    font-weight: 850;
}

.platform-help-panel__close {
    display: grid;
    flex: 0 0 auto;
    width: 38px;
    height: 38px;
    place-items: center;
    border: 1px solid #dbe3ee;
    border-radius: 12px;
    background: #fff;
    color: #334155;
    font-size: 1.4rem;
}

.platform-help-panel__body {
    overflow-y: auto;
    padding: 1.25rem;
}

.platform-help-context {
    display: flex;
    gap: .8rem;
    padding: 1rem;
    border: 1px solid #c7d7fe;
    border-radius: 16px;
    background: #f4f7ff;
}

.platform-help-context__status {
    flex: 0 0 auto;
    width: 10px;
    height: 10px;
    margin-top: .35rem;
    border-radius: 50%;
    background: #22c55e;
    box-shadow: 0 0 0 5px rgba(34, 197, 94, .12);
}

.platform-help-context strong,
.platform-help-context span {
    display: block;
}

.platform-help-context strong {
    color: #0f172a;
}

.platform-help-context span {
    margin-top: .2rem;
    color: #526176;
    font-size: .88rem;
    line-height: 1.55;
}

.platform-help-section {
    margin-top: 1.4rem;
}

.platform-help-route {
    margin: 0;
    border: 1px solid #e2e8f0;
    border-radius: 16px;
    overflow: hidden;
}

    .platform-help-route div {
        display: grid;
        grid-template-columns: 90px 1fr;
        gap: 1rem;
        padding: .75rem .9rem;
        border-bottom: 1px solid #edf1f6;
    }

        .platform-help-route div:last-child {
            border-bottom: 0;
        }

    .platform-help-route dt {
        color: #64748b;
        font-size: .8rem;
    }

    .platform-help-route dd {
        margin: 0;
        color: #1e293b;
        font-size: .85rem;
        font-weight: 700;
        overflow-wrap: anywhere;
    }

.platform-help-action {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    margin-top: .7rem;
    padding: .95rem 1rem;
    border: 1px solid #dce4ef;
    border-radius: 16px;
    background: #fff;
    color: #0f172a;
    text-decoration: none;
    transition: transform .16s ease, border-color .16s ease, box-shadow .16s ease;
}

    .platform-help-action:hover {
        color: #0f172a;
        border-color: #a9c1f7;
        transform: translateY(-1px);
        box-shadow: 0 12px 30px rgba(15, 23, 42, .08);
    }

.platform-help-action--primary {
    border-color: #bfd0fb;
    background: linear-gradient(145deg, #f5f8ff, #fff);
}

.platform-help-action strong,
.platform-help-action small {
    display: block;
}

.platform-help-action small {
    margin-top: .2rem;
    color: #64748b;
    line-height: 1.4;
}

.platform-help-assurance {
    margin-top: 1.5rem;
    padding: 1rem;
    border-radius: 16px;
    background: #0f172a;
    color: #fff;
}

    .platform-help-assurance p {
        margin: .35rem 0 0;
        color: #cbd5e1;
        font-size: .84rem;
        line-height: 1.55;
    }

.sidebar-link-description {
    display: block;
    margin-top: .08rem;
    color: inherit;
    font-size: .68rem;
    font-weight: 550;
    opacity: .68;
}

[data-sidebar-state="collapsed"] .sidebar-link-description {
    display: none;
}

@media (max-width: 575.98px) {
    .platform-help-launcher__label {
        display: none;
    }

    .platform-help-launcher {
        right: .9rem;
        bottom: .9rem;
        padding: .45rem;
    }

    .platform-help-panel {
        width: 100vw;
    }
}

@media (prefers-reduced-motion: reduce) {
    .platform-help-launcher,
    .platform-help-backdrop,
    .platform-help-panel,
    .platform-help-action {
        scroll-behavior: auto;
        transition: none !important;
    }
}
