/* Sidebar icon family: quiet violet glass at rest, a restrained gold edge on interaction. */
.tool-rail {
    --rail-violet: #a895f5;
    --rail-gold-edge: rgba(221, 178, 112, .62);
}

.tool-rail .tool {
    color: #a8a5b9;
    transition: color .18s ease, background .18s ease, box-shadow .18s ease;
}

.tool-rail .tool:hover,
.tool-rail .tool:focus-visible {
    color: #e2dcff;
    background: rgba(112, 88, 196, .11);
    box-shadow: inset 0 0 0 1px rgba(221, 178, 112, .3);
}

.tool-rail .tool.active,
.tool-rail .asset-library-tool[aria-expanded="true"] {
    color: #f2efff;
    background: linear-gradient(135deg, rgba(116, 87, 238, .21), rgba(116, 87, 238, .06));
    box-shadow: inset 0 0 0 1px rgba(221, 178, 112, .43);
}

.tool-rail .tool small {
    line-height: 1.15;
    font-weight: 700;
}

.tool-rail .tool .rail-brand-icon {
    box-sizing: border-box;
    width: 31px;
    height: 31px;
    flex: 0 0 31px;
    position: relative;
    display: grid;
    place-items: center;
    border: 1px solid rgba(145, 124, 226, .3);
    border-radius: 9px;
    color: var(--rail-violet);
    background: linear-gradient(145deg, #211b35, #13131d 65%, #1b1830);
    box-shadow: 0 3px 10px rgba(0, 0, 0, .25), inset 0 1px 0 rgba(224, 216, 255, .06);
    transition: transform .18s ease, border-color .18s ease, box-shadow .18s ease, background .18s ease;
}

.tool-rail .rail-brand-icon svg {
    width: 22px;
    height: 22px;
    display: block;
    overflow: visible;
    fill: none;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-width: 1.45;
}

.tool-rail .rail-icon-line { fill: none; stroke: #b9a9f7; }
.tool-rail .rail-icon-muted { fill: none; stroke: #777098; }
.tool-rail .rail-icon-fill { fill: #8a70ee; stroke: #c8bbff; stroke-width: .8; }
.tool-rail .rail-icon-spark { fill: none; stroke: #8dd9e7; stroke-width: 1.35; }
.tool-rail .rail-icon-record { fill: #9d75e9; stroke: #d2bdff; stroke-width: 1.15; }

.tool-rail .tool:hover .rail-brand-icon,
.tool-rail .tool:focus-visible .rail-brand-icon,
.tool-rail .tool.active .rail-brand-icon,
.tool-rail .asset-library-tool[aria-expanded="true"] .rail-brand-icon {
    transform: translateY(-1px);
    border-color: var(--rail-gold-edge);
    background: linear-gradient(145deg, #2b2248, #171522 63%, #241d3d);
    box-shadow: 0 4px 13px rgba(72, 50, 155, .23), 0 0 0 1px rgba(221, 178, 112, .11), inset 0 1px 0 rgba(255, 255, 255, .09);
}

.tool-rail .tool.is-recording .rail-brand-icon {
    box-shadow: 0 0 0 2px rgba(246, 100, 49, .23), 0 0 15px rgba(237, 95, 39, .6), inset 0 1px 0 rgba(255, 230, 194, .18);
}

.tool-rail .tool.is-recording .rail-icon-record { fill: #ff5932; stroke: #ffd1a7; }

@media (prefers-reduced-motion: reduce) {
    .tool-rail .tool,
    .tool-rail .tool .rail-brand-icon { transition: none; }
}
