/* Notification menu and the desktop navigation rail control. */
.ms-rail-toggle {
    appearance: none;
    display: none;
    width: 40px;
    height: 40px;
    flex: 0 0 40px;
    align-items: center;
    justify-content: center;
    padding: 0;
    border: 1px solid #d7e2f0;
    border-radius: 12px;
    background: linear-gradient(180deg, #fff, #f3f7fd);
    color: #17416e;
    box-shadow: 0 3px 10px rgba(20, 48, 82, .09), inset 0 1px 0 #fff;
    font-size: 15px;
    cursor: pointer;
    transition: color .18s ease, background .18s ease, border-color .18s ease, box-shadow .18s ease, transform .18s ease;
}
.ms-rail-toggle:hover {
    color: #145fe5;
    background: #edf4ff;
    border-color: #a9c8fb;
    box-shadow: 0 5px 14px rgba(20, 95, 229, .15);
    transform: translateY(-1px);
}
.ms-rail-toggle:focus-visible {
    outline: 3px solid rgba(26, 111, 255, .25);
    outline-offset: 2px;
}
@media (min-width: 1201px) {
    .ms-rail-toggle { display: inline-flex; }
    .ms-shell.rail-collapsed .ms-rail {
        width: 0 !important;
        overflow: hidden;
        visibility: hidden;
        border-right: 0;
    }
    .ms-shell.rail-collapsed .ms-main-wrap { margin-left: 0; }
    .ms-shell.rail-collapsed ~ .ms-footer { margin-left: 0; }
}

.ms-notifications { position: relative; display: flex; align-items: center; }
.ms-notifications > .ms-icon-btn { padding: 0; font-size: 15px; }
.ms-notification-count {
    position: absolute;
    top: -5px;
    right: -6px;
    min-width: 19px;
    height: 19px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0 5px;
    border: 2px solid #fff;
    border-radius: 999px;
    background: #e83255;
    color: #fff;
    font-size: 10px;
    font-weight: 800;
    line-height: 1;
    box-shadow: 0 2px 6px rgba(132, 20, 48, .2);
}
.ms-notification-count[hidden],
.ms-notification-panel[hidden] { display: none !important; }

.ms-notification-panel {
    position: absolute;
    z-index: 1300;
    top: calc(100% + 12px);
    right: 0;
    display: flex;
    flex-direction: column;
    width: min(390px, calc(100vw - 24px));
    max-height: min(560px, calc(100vh - 100px));
    overflow: hidden;
    border: 1px solid #dce5f0;
    border-radius: 16px;
    background: #fff;
    box-shadow: 0 18px 48px rgba(20, 41, 71, .2);
}
.ms-notification-panel-head,
.ms-notification-panel-foot {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 14px 16px;
}
.ms-notification-panel-head { border-bottom: 1px solid #edf1f6; }
.ms-notification-panel-head strong { color: #102943; font-size: 15px; }
.ms-notification-panel-head span { color: #718096; font-size: 11px; }
.ms-notification-list { overflow-y: auto; }
.ms-notification-row {
    position: relative;
    display: flex;
    align-items: center;
    gap: 8px;
    border-bottom: 1px solid #f0f3f7;
}
.ms-notification-row.unread { background: #f5f8ff; }
.ms-notification-item {
    display: flex;
    flex: 1;
    min-width: 0;
    align-items: flex-start;
    gap: 11px;
    padding: 13px 8px 13px 15px;
    color: inherit;
    text-decoration: none;
}
.ms-notification-item:hover { background: rgba(26, 111, 255, .045); }
.ms-notification-item-icon {
    display: inline-flex;
    flex: 0 0 32px;
    width: 32px;
    height: 32px;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    background: #eaf1ff;
    color: #1a6fff;
}
.ms-notification-item-copy {
    display: flex;
    min-width: 0;
    flex-direction: column;
    gap: 3px;
}
.ms-notification-item-copy strong {
    overflow: hidden;
    color: #1b2b42;
    font-size: 12px;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.ms-notification-item-copy > span {
    display: -webkit-box;
    overflow: hidden;
    color: #627187;
    font-size: 12px;
    line-height: 1.4;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}
.ms-notification-item-copy small { color: #92a0b1; font-size: 10px; }
.ms-notification-read {
    width: 30px;
    height: 30px;
    flex: 0 0 30px;
    margin-right: 10px;
    border: 1px solid #d9e5f5;
    border-radius: 9px;
    background: #fff;
    color: #3474d8;
    cursor: pointer;
}
.ms-notification-read:hover { background: #eaf1ff; }
.ms-notification-empty,
.ms-notification-loading {
    padding: 26px 16px;
    color: #728096;
    font-size: 13px;
    text-align: center;
}
.ms-notification-panel-foot {
    border-top: 1px solid #edf1f6;
    font-size: 12px;
}
.ms-notification-panel-foot a { color: #145fe5; font-weight: 700; text-decoration: none; }
.ms-notification-panel-foot button {
    padding: 0;
    border: 0;
    background: none;
    color: #64748b;
    font: inherit;
    cursor: pointer;
}
.ms-notification-panel-foot button:hover { color: #145fe5; }

@media (max-width: 600px) {
    .ms-notification-panel { right: -58px; }
}
