/* Nuboc IP LLC. All rights reserved. */

/* =============================================================================
   Right rail — utility column ("the workbench edge")
   Mirrors the left sidebar's signal language with right-edge active marker.
   ============================================================================= */

.nax-rail {
    position: fixed;
    top: var(--nax-topbar-h);
    right: 0;
    bottom: 0;
    width: var(--nax-rail-w);
    background: var(--nax-chrome);
    border-left: none;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 10px 0 14px;
    gap: 2px;
    z-index: var(--nax-z-sidebar);
    color: var(--nax-chrome-mute);
}

.nax-rail-btn {
    position: relative;
    display: grid;
    place-items: center;
    width: 34px;
    height: 34px;
    border: none;
    background: transparent;
    color: var(--nax-chrome-mute);
    border-radius: 6px;
    cursor: pointer;
    transition: color var(--nax-t), background var(--nax-t);
}
.nax-rail-btn::after {
    /* Right-edge signal marker — symmetry with the sidebar's left bar */
    content: "";
    position: absolute;
    right: -7px;
    top: 7px; bottom: 7px;
    width: 2px;
    background: var(--nax-signal);
    border-radius: 2px 0 0 2px;
    transform: scaleY(0);
    transition: transform var(--nax-t-med);
}
.nax-rail-btn:hover {
    color: var(--nax-chrome-text);
    background: rgba(255, 255, 255, .03);
}
.nax-rail-btn.is-active {
    color: var(--nax-signal);
    background: rgba(138, 170, 240, .07);
}
.nax-rail-btn.is-active::after {
    transform: scaleY(1);
}

/* Hover label — slides out to the LEFT (we're on the right edge) */
.nax-rail-btn::before {
    content: attr(aria-label);
    position: absolute;
    right: calc(100% + 12px);
    top: 50%;
    transform: translateY(-50%) translateX(6px);
    height: 28px;
    line-height: 28px;
    padding: 0 12px;
    background: var(--nax-chrome-3);
    color: var(--nax-chrome-text);
    border: 1px solid var(--nax-chrome-line-2);
    border-radius: 4px;
    font-family: var(--nax-font-sans);
    font-size: 0.745rem;
    font-weight: 500;
    letter-spacing: .005em;
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    box-shadow: 0 0 0 1px rgba(0,0,0,.35), 0 8px 24px rgba(0,0,0,.5);
    transition: opacity var(--nax-t), transform var(--nax-t);
    z-index: 10;
}
.nax-rail-btn:hover::before {
    opacity: 1;
    transform: translateY(-50%) translateX(0);
}

.nax-rail-spacer { flex: 1; }

/* Decorative signal tick at the bottom — mirrors sidebar footer */
.nax-rail::after {
    content: "";
    width: 18px;
    height: 1px;
    background: var(--nax-signal-line);
    margin: 6px 0 -6px;
    align-self: center;
    opacity: .8;
}

/* Rail items rendered as links (e.g. Lock screen) — keep the button look and
   stop global anchor styling (underline / accent colour) leaking in. */
a.nax-rail-btn,
a.nax-rail-btn:hover {
    text-decoration: none;
}
