


:root { --dock-h: 96px; }


.dock-wrap {
    position: relative;            
    flex: 0 0 auto;
    z-index: 1300;
    display: flex; justify-content: center;
    padding: 8px 12px;            
    pointer-events: auto;
    opacity: 0; transition: opacity .15s ease;
}
.dock-wrap.dock-ready { opacity: 1; }


.dock-wrap:has(.dock-group:hover),
.dock-wrap:has(.dock-group:focus-within),
.dock-wrap:has(.dock-notif-pop) {
    z-index: 1600;
}

.dock {
    position: relative; z-index: 1; pointer-events: auto;
    flex: 0 0 auto; max-width: 100%;
    display: flex; align-items: stretch; gap: 7px;
    padding: 8px 10px;
    background: var(--bg-surface, #ffffff);
    border: 1px solid var(--border-1, #e6e9ee);
    border-radius: 16px;
    box-shadow: 0 18px 50px -12px rgba(8, 24, 40, .28);   
}


.dock-pill {
    position: absolute; top: 8px; left: 0;
    height: calc(100% - 16px);
    background: var(--brand-soft, #eaf1f8);
    box-shadow: inset 0 0 0 1.5px color-mix(in srgb, var(--brand, #0a4174) 30%, transparent);
    border-radius: 11px;
    transition: transform .32s cubic-bezier(.16,1,.3,1), width .32s cubic-bezier(.16,1,.3,1), opacity .2s ease;
    pointer-events: none; z-index: 0; opacity: 0;
}

.dock-item {
    position: relative; z-index: 1;
    flex: 0 0 auto; min-width: 54px; max-width: 140px;
    display: flex; flex-direction: column; align-items: center; gap: 6px;
    padding: 9px 8px 8px;
    border: 0; background: none; cursor: pointer;
    border-radius: 10px;
    color: var(--fg-3, #6b7280);
    font-family: inherit;
    text-decoration: none;   
    touch-action: none;   
    transition: color .2s ease, background .14s ease, transform .18s cubic-bezier(.16,1,.3,1);
}
.dock-item:hover { color: var(--fg-1, #0f172a); background: var(--bg-sunken, #f1f5f9); transform: translateY(-3px); }
.dock-item:active { transform: translateY(-1px); }
.dock-item.is-active { color: var(--brand, #0a4174); }
.dock-item.is-active:hover { background: transparent; }
.dock-item:focus-visible, .dock-group-btn:focus-visible, .dock-pop-item:focus-visible {
    outline: 2px solid var(--brand, #0a4174); outline-offset: 2px;
}

.dock-icon { display: flex; align-items: center; justify-content: center; position: relative; }
.dock-icon svg {
    width: 28px; height: 28px; stroke-width: 1.2;
    transition: transform .28s cubic-bezier(.16,1,.3,1);
}
.dock-item:hover .dock-icon svg { transform: scale(1.12); }
.dock-item.is-active .dock-icon svg { transform: translateY(-1px) scale(1.06); }


.dock-badge {
    position: absolute; top: -5px; left: calc(50% + 7px);
    min-width: 16px; height: 16px; padding: 0 4px;
    display: flex; align-items: center; justify-content: center;
    background: var(--brand, #0a4174); color: #fff;
    font-size: 10px; font-weight: 600; line-height: 1; border-radius: 999px;
    box-shadow: 0 0 0 2px var(--bg-surface, #fff);
    pointer-events: none;
}
.dock-opt-dots { position: relative; }
.dock-opt-dots .dock-badge { top: -7px; left: calc(50% + 6px); }

.dock-notif .dock-badge { background: var(--error-600, #e5484d); }


.dock-dot {
    position: absolute; top: -3px; right: calc(50% + 7px);
    width: 8px; height: 8px; border-radius: 50%;
    background: var(--error-600, #e5484d);
    box-shadow: 0 0 0 2px var(--bg-surface, #fff);
    pointer-events: none;
}

.dock-label {
    font-size: 11.5px; font-weight: 600; line-height: 1.15;
    text-align: center; max-width: 134px;
    white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}


.dock-tip {
    position: absolute; bottom: calc(100% + 11px); left: 50%;
    transform: translateX(-50%) translateY(4px);
    padding: 5px 10px; border-radius: 8px;
    background: var(--slate-800, #1f2937); color: #fff;
    font-size: 12px; font-weight: 600; white-space: nowrap;
    box-shadow: 0 8px 20px -6px rgba(8,24,40,.5);
    opacity: 0; pointer-events: none; z-index: 30;
    transition: opacity .13s ease, transform .13s ease;
}
.dock-tip::after {
    content: ''; position: absolute; top: 100%; left: 50%; transform: translateX(-50%);
    border: 5px solid transparent; border-top-color: var(--slate-800, #1f2937);
}
.dock-item:hover .dock-tip { opacity: 1; transform: translateX(-50%) translateY(0); }

.dock-sep {
    flex: 0 0 auto; width: 1px; margin: 8px 7px; align-self: stretch;
    background: var(--border-1, #e6e9ee);
}


.dock-item.dock-held, .dock-pop-item.dock-held {
    transform: scale(.92) !important;
    transition: transform .12s cubic-bezier(.16,1,.3,1) !important;
}
.dock-item.dock-held { background: var(--bg-sunken, #f1f5f9); }
.dock-pop-item.dock-held { background: var(--bg-sunken, #f1f5f9); }


@keyframes dock-pin {
    0%   { transform: translateY(0) scale(1);      background: var(--brand-soft, #eaf1f8); }
    24%  { transform: translateY(-5px) scale(1.09); background: var(--brand-soft, #eaf1f8); }
    100% { transform: translateY(0) scale(1);      background: transparent; }
}
@keyframes dock-pin-ring {
    0%   { box-shadow: 0 0 0 0 var(--brand, #0a4174); opacity: .45; }
    100% { box-shadow: 0 0 0 11px transparent; opacity: 0; }
}
.dock-item.just-added { animation: dock-pin 1s cubic-bezier(.16,1,.3,1); }
.dock-item.just-added .dock-icon::after {
    content: ''; position: absolute; inset: -4px; border-radius: 10px;
    animation: dock-pin-ring .9s cubic-bezier(.16,1,.3,1) forwards;
}
.dock-item.just-added .dock-label { color: var(--brand, #0a4174); }


.dock-group { position: relative; z-index: 2; flex: 0 0 auto; display: flex; }
.dock-group-label { display: inline-flex; align-items: center; gap: 3px; }
.dock-group-label svg { opacity: .65; transition: transform .2s ease; flex: 0 0 auto; }
.dock-group:hover .dock-group-label svg,
.dock-group:focus-within .dock-group-label svg { transform: rotate(180deg); opacity: 1; }
.dock-group:hover .dock-group-btn,
.dock-group:focus-within .dock-group-btn { color: var(--fg-1, #0f172a); background: var(--bg-sunken, #f1f5f9); }
.dock-group-btn.is-active { color: var(--brand, #0a4174); }

.dock-gpop {
    position: absolute; bottom: calc(100% + 11px); left: 0;   
    width: max-content; min-width: 208px; max-width: min(320px, calc(100vw - 24px));
    background: var(--bg-surface, #fff);
    border: 1px solid var(--border-1, #e6e9ee);
    border-radius: 14px;
    box-shadow: 0 18px 50px -12px rgba(8, 24, 40, .28);
    padding: 6px;
    opacity: 0; transform: translateY(8px) scale(.98);
    transform-origin: bottom left;
    pointer-events: none; z-index: 40;
    transition: opacity .22s cubic-bezier(.16,1,.3,1) .2s, transform .22s cubic-bezier(.16,1,.3,1) .2s;
}
.dock-group:hover .dock-gpop,
.dock-group:focus-within .dock-gpop {
    opacity: 1; transform: translateY(0) scale(1); pointer-events: auto;
    transition-delay: 0s;
}

.dock-more .dock-gpop { left: auto; right: 0; transform: translateY(8px) scale(.98); transform-origin: bottom right; }
.dock-more:hover .dock-gpop,
.dock-more:focus-within .dock-gpop { transform: translateY(0) scale(1); }
.dock-more .dock-gpop::after { left: auto; right: 20px; transform: none; }

.dock-gpop::before { content: ''; position: absolute; top: 100%; left: 0; right: 0; height: 14px; }

.dock-gpop::after {
    content: ''; position: absolute; top: 100%; left: 34px; transform: none;
    border: 7px solid transparent; border-top-color: var(--bg-surface, #fff);
    filter: drop-shadow(0 1px 0 var(--border-1, #e6e9ee));
}
.dock-gpop .dock-pop-label { padding: 6px 8px 5px; }
.dock-gpop-list { display: flex; flex-direction: column; gap: 1px; }
.dock-gpop-list .dock-pop-item { width: 100%; }


.dock-gpop-wide { min-width: 264px; max-width: min(360px, calc(100vw - 24px)); padding: 6px; }
.dock-gpop-scroll { max-height: min(64vh, 520px); overflow-y: auto; overflow-x: hidden; }
.dock-more .dock-icon svg { stroke-width: 1.5; }


.dock-pop-scroll, .dock-gpop-scroll { scrollbar-width: thin; scrollbar-color: var(--border-2, #cbd5e1) transparent; }
.dock-pop-scroll::-webkit-scrollbar, .dock-gpop-scroll::-webkit-scrollbar { width: 3px; }
.dock-pop-scroll::-webkit-scrollbar-track, .dock-gpop-scroll::-webkit-scrollbar-track { background: transparent; }
.dock-pop-scroll::-webkit-scrollbar-thumb, .dock-gpop-scroll::-webkit-scrollbar-thumb { background: var(--border-2, #cbd5e1); border-radius: 999px; }
.dock-pop-scroll::-webkit-scrollbar-thumb:hover, .dock-gpop-scroll::-webkit-scrollbar-thumb:hover { background: var(--fg-4, #94a3b8); }


.dock-pop-group { padding: 2px 4px; }
.dock-pop-label {
    font-size: 10.5px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase;
    color: var(--fg-4, #9aa3af); padding: 6px 8px 3px;
}
.dock-pop-item {
    position: relative;
    
    display: flex; align-items: center; justify-content: flex-start; gap: 11px; min-width: 0;
    padding: 7px 9px; border: 0; background: none; cursor: pointer;
    border-radius: 9px; text-align: left; width: 100%;
    color: var(--fg-2, #334155); font-family: inherit;
    text-decoration: none;   
    transition: background .12s ease, color .12s ease;
}
.dock-pop-item:hover { background: var(--bg-sunken, #f1f5f9); color: var(--fg-1, #0f172a); }
.dock-pop-item.is-active { background: var(--brand-soft, #eaf1f8); color: var(--brand, #0a4174); }
.dock-pop-item svg { width: 21px; height: 21px; stroke-width: 1.3; flex: 0 0 auto; }
.dock-pop-item > span:not(.dock-pop-badge) {
    flex: 0 1 auto; min-width: 0;
    font-size: 14px; font-weight: 500; line-height: 1.2;
    white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.dock-pop-badge {
    margin-left: auto; flex: 0 0 auto;
    min-width: 20px; height: 20px; padding: 0 6px;
    display: flex; align-items: center; justify-content: center;
    background: var(--brand, #0a4174); color: #fff;
    font-size: 12px; font-weight: 600; line-height: 1; border-radius: 999px;
}

.dock-pin-hint {
    float: right; font-size: 9.5px; font-weight: 600; letter-spacing: 0; text-transform: none;
    color: var(--fg-4, #9aa3af); background: var(--bg-sunken, #f1f5f9); padding: 1px 6px; border-radius: 999px;
}


.dock-item.is-dragging-out, .dock-group.is-dragging-out { opacity: .35; }
.dock.is-customizing .dock-item:hover { transform: none; background: transparent; }
.dock.is-customizing .dock-gpop { display: none !important; }

.dock-gpop .dock-pop-item { touch-action: none; }

.dock-drag-ghost {
    position: fixed; z-index: 2000; left: 0; top: 0;
    transform: translate(-50%, -130%);
    display: flex; flex-direction: column; align-items: center; gap: 4px;
    padding: 9px 13px; border-radius: 13px;
    background: var(--bg-surface, #fff); color: var(--fg-1, #0f172a);
    box-shadow: 0 14px 32px -8px rgba(8,24,40,.45); border: 1px solid var(--border-1, #e6e9ee);
    pointer-events: none; font-size: 11.5px; font-weight: 600;
}
.dock-drag-ghost svg { width: 24px; height: 24px; }
.dock-drag-ghost.is-removing {
    background: color-mix(in srgb, var(--error-600, #dc2626) 12%, var(--bg-surface, #fff));
    color: var(--error-600, #dc2626); border-color: var(--error-600, #dc2626);
}
.dock-drag-ghost.is-adding { border-color: var(--brand, #0a4174); color: var(--brand, #0a4174); background: var(--brand-soft, #eaf1f8); }
.dock-drag-ghost.is-reorder { border-color: var(--brand, #0a4174); }
.dock-drag-hint {
    position: fixed; left: 50%; bottom: 116px; transform: translateX(-50%);
    white-space: nowrap; padding: 7px 14px; border-radius: 999px;
    background: var(--fg-1, #0f172a); color: #fff; font-size: 12px; font-weight: 600;
    box-shadow: 0 18px 50px -12px rgba(8,24,40,.28); pointer-events: none; z-index: 2001;
}
.dock-drag-hint.is-armed { background: var(--error-600, #dc2626); }
.dock-drop-mark {
    position: absolute; top: 8px; bottom: 8px; width: 3px; border-radius: 2px;
    background: var(--brand, #0a4174); z-index: 6; pointer-events: none;
    box-shadow: 0 0 0 3px var(--brand-soft, #eaf1f8);
}


.dock-sep-end { margin-left: 2px; }
.dock-notif { position: relative; z-index: 3; flex: 0 0 auto; display: flex; align-items: stretch; }
.dock-notif-btn { position: relative; }
.dock-notif-dot {   
    position: absolute; top: -2px; right: -2px;
    width: 7px; height: 7px; border-radius: 50%;
    background: var(--error-600, #e5484d);
    box-shadow: 0 0 0 2px var(--bg-surface, #fff);
}
.dock-notif-scrim { position: fixed; inset: 0; z-index: 60; background: transparent; }
.dock-notif-pop { position: absolute; bottom: calc(100% + 12px); right: 0; z-index: 61; }
.dock-notif-pop .notif-menu {
    width: 420px; max-width: min(420px, calc(100vw - 24px));
    background: var(--bg-surface, #fff); border: 1px solid var(--border-1, #e6e9ee);
    border-radius: 16px; box-shadow: 0 18px 50px -12px rgba(8, 24, 40, .28); overflow: hidden;
}

.dock-notif-pop .notif-grab { display: none; }
.dock-notif-pop .notif-head { padding: 14px 16px 10px; border-bottom: 1px solid var(--border-1, #e6e9ee); }
.dock-notif-pop .notif-head-row { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.dock-notif-pop .notif-title { font-size: 15px; font-weight: 700; color: var(--fg-1, #0f172a); display: flex; align-items: center; gap: 8px; }
.dock-notif-pop .notif-count { font-size: 11px; font-weight: 600; color: var(--brand, #0a4174); background: var(--brand-soft, #eaf1f8); padding: 2px 8px; border-radius: 999px; }
.dock-notif-pop .notif-head-actions { display: inline-flex; align-items: center; gap: 2px; flex: 0 0 auto; }
.dock-notif-pop .notif-icon-btn {
    width: 28px; height: 28px; border: none; background: transparent; border-radius: 7px; cursor: pointer;
    color: var(--fg-3, #6b7280); display: inline-flex; align-items: center; justify-content: center; font-family: inherit;
}
.dock-notif-pop .notif-icon-btn:hover { background: var(--bg-sunken, #f1f5f9); color: var(--fg-1, #0f172a); }
.dock-notif-pop .notif-icon-btn.is-on { color: var(--success-600, #15803d); }
.dock-notif-pop .notif-icon-btn svg { width: 16px; height: 16px; }
.dock-notif-pop .notif-body { max-height: min(60vh, 560px); overflow-y: auto; padding: 6px; }

.dock-notif-pop .notif-body { scrollbar-width: thin; scrollbar-color: var(--border-2, #cbd5e1) transparent; }
.dock-notif-pop .notif-body::-webkit-scrollbar { width: 5px; }
.dock-notif-pop .notif-body::-webkit-scrollbar-thumb { background: var(--border-2, #cbd5e1); border-radius: 999px; }
.dock-notif-pop .notif-body::-webkit-scrollbar-thumb:hover { background: var(--fg-4, #94a3b8); }
.dock-notif-empty { text-align: center; color: var(--fg-4, #9aa3af); font-size: 13px; padding: 28px 12px; }


.dock-notif-pop .notif-search { position: relative; display: flex; align-items: center; margin-top: 10px; }
.dock-notif-pop .notif-search > svg {
    position: absolute; left: 11px; width: 16px; height: 16px;
    color: var(--fg-4, #9aa3af); pointer-events: none; flex: 0 0 auto;
}
.dock-notif-pop .notif-search-input {
    width: 100%; padding: 9px 32px 9px 34px;
    border: 1px solid var(--border-1, #e6e9ee); border-radius: 10px;
    background: var(--bg-sunken, #f8fafc); color: var(--fg-1, #0f172a);
    font-size: 13.5px; font-family: inherit; outline: none;
    transition: border-color .14s ease, background .14s ease;
}
.dock-notif-pop .notif-search-input:focus { border-color: var(--brand, #0a4174); background: var(--bg-surface, #fff); }
.dock-notif-pop .notif-search-input::placeholder { color: var(--fg-4, #9aa3af); }
.dock-notif-pop .notif-search-clear {
    position: absolute; right: 6px; width: 24px; height: 24px;
    display: inline-flex; align-items: center; justify-content: center;
    border: none; background: transparent; border-radius: 7px; cursor: pointer;
    color: var(--fg-4, #9aa3af); font-family: inherit;
}
.dock-notif-pop .notif-search-clear:hover { background: var(--bg-sunken, #f1f5f9); color: var(--fg-1, #0f172a); }
.dock-notif-pop .notif-search-clear svg { width: 14px; height: 14px; }


.dock-notif-pop .notif-sentinel { height: 1px; }
.dock-notif-pop .notif-loading, .dock-notif-pop .notif-end {
    display: flex; align-items: center; justify-content: center; gap: 8px;
    padding: 12px; color: var(--fg-4, #9aa3af); font-size: 12px; text-align: center;
}
.dock-notif-pop .notif-loadmore {
    width: 100%; padding: 9px; margin-top: 2px;
    border: none; background: transparent; border-radius: 9px;
    font-size: 12.5px; font-weight: 600; color: var(--brand, #0a4174);
    cursor: pointer; font-family: inherit;
    display: flex; align-items: center; justify-content: center; gap: 6px;
}
.dock-notif-pop .notif-loadmore:hover { background: var(--brand-soft, #eaf1f8); }
.dock-notif-pop .notif-row {
    position: relative; width: 100%; display: flex; gap: 11px; align-items: flex-start; text-align: left;
    padding: 10px 12px; border: none; background: transparent; border-radius: 11px; cursor: pointer;
    font-family: inherit; color: var(--fg-1, #0f172a);
}
.dock-notif-pop .notif-row:hover { background: var(--bg-sunken, #f1f5f9); }
.dock-notif-pop .notif-row.unread { background: var(--brand-soft, #eaf1f8); }
.dock-notif-pop .notif-row-icon { flex: 0 0 auto; width: 32px; height: 32px; border-radius: 9px; display: inline-flex; align-items: center; justify-content: center; }
.dock-notif-pop .notif-row-icon .mud-icon-root { font-size: 18px; }
.dock-notif-pop .notif-row-icon.tone-brand   { background: var(--brand-soft, #eaf1f8);  color: var(--brand, #0a4174); }
.dock-notif-pop .notif-row-icon.tone-success { background: rgba(22, 163, 74, .12);  color: #15803d; }
.dock-notif-pop .notif-row-icon.tone-warning { background: rgba(245, 158, 11, .16); color: #b45309; }
.dock-notif-pop .notif-row-icon.tone-error   { background: rgba(239, 68, 68, .12);  color: #b91c1c; }
.dock-notif-pop .notif-row-icon.tone-info    { background: rgba(14, 165, 233, .12); color: #075985; }
.dock-notif-pop .notif-row-icon.tone-neutral { background: var(--slate-100, #f1f5f9); color: var(--fg-2, #334155); }
.dock-notif-pop .notif-row-meta { display: flex; flex-direction: column; gap: 2px; min-width: 0; flex: 1 1 auto; }
.dock-notif-pop .notif-row-title { font-size: 13.5px; font-weight: 600; color: var(--fg-1, #0f172a); line-height: 1.3; }
.dock-notif-pop .notif-row-title .notif-code { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: .92em; }
.dock-notif-pop .notif-row-body {
    font-size: 12.5px; color: var(--fg-3, #6b7280); line-height: 1.4; word-break: break-word;
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.dock-notif-pop .notif-row-time { font-size: 11px; color: var(--fg-4, #9aa3af); margin-top: 2px; }
.dock-notif-pop .notif-row-dot { position: absolute; top: 14px; right: 12px; width: 8px; height: 8px; border-radius: 50%; background: var(--brand, #0a4174); }


.dock-notif-pop .notif-row-source { display: flex; align-items: center; gap: 6px; min-width: 0; margin-bottom: 1px; }
.dock-notif-pop .notif-src-sys {
    flex: 0 0 auto; width: 16px; height: 16px; border-radius: 5px;
    display: inline-flex; align-items: center; justify-content: center;
    background: var(--slate-100, #eceff3); color: var(--fg-3, #6b7280);
}
.dock-notif-pop .notif-src-sys .mud-icon-root { font-size: 11px; width: 11px; height: 11px; }
.dock-notif-pop .notif-src-av {
    flex: 0 0 auto; width: 16px; height: 16px; border-radius: 50%;
    display: inline-flex; align-items: center; justify-content: center;
    color: #fff; font-size: 8.5px; font-weight: 700; letter-spacing: .01em;
}
.dock-notif-pop .notif-src-name {
    font-size: 11.5px; font-weight: 700; color: var(--fg-2, #334155);
    white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.dock-notif-pop .notif-row-ctx {
    display: flex; align-items: center; gap: 5px; min-width: 0;
    font-size: 12px; font-weight: 600; color: var(--fg-2, #334155);
}
.dock-notif-pop .notif-row-ctx .mud-icon-root { font-size: 13px; width: 13px; height: 13px; color: var(--fg-3, #6b7280); flex: 0 0 auto; }
.dock-notif-pop .notif-ctx-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dock-notif-pop .notif-foot { padding: 8px; border-top: 1px solid var(--border-1, #e6e9ee); }
.dock-notif-pop .notif-foot-btn { width: 100%; padding: 9px; border: none; background: transparent; border-radius: 9px; font-size: 13px; font-weight: 600; color: var(--brand, #0a4174); cursor: pointer; font-family: inherit; }
.dock-notif-pop .notif-foot-btn:hover { background: var(--brand-soft, #eaf1f8); }


.dock-opt { position: relative; z-index: 2; flex: 0 0 auto; }

.dock-opt-scrim { display: none; }
.dock-opt-btn {
    width: auto; min-width: 64px; height: 100%;
    display: flex; flex-direction: column; align-items: center; gap: 6px;
    padding: 9px 6px 8px;
    border: 0; background: none; cursor: pointer;
    border-radius: 10px; color: var(--fg-3, #6b7280); font-family: inherit;
    transition: color .2s ease, background .14s ease;
}
.dock-opt.has-active .dock-opt-btn { color: var(--brand, #0a4174); }
.dock-opt-dots { display: flex; gap: 3px; height: 28px; align-items: center; justify-content: center; }
.dock-opt-dots i { width: 5px; height: 5px; border-radius: 999px; background: currentColor; }
.dock-opt-btn .dock-label { font-size: 12.5px; font-weight: 600; }

.dock-pop {
    position: absolute; bottom: calc(100% + 12px); right: 0;
    width: min(460px, calc(100vw - 28px));
    background: var(--bg-surface, #fff);
    border: 1px solid var(--border-1, #e6e9ee);
    border-radius: 16px;
    box-shadow: 0 18px 50px -12px rgba(8, 24, 40, .28);
    opacity: 0; transform: translateY(8px) scale(.98); transform-origin: bottom right;
    pointer-events: none;
    transition: opacity .26s cubic-bezier(.16,1,.3,1), transform .26s cubic-bezier(.16,1,.3,1);
}
.dock-pop-scroll { overflow-y: auto; overflow-x: hidden; padding: 8px; max-height: 60vh; }
.dock-opt.open .dock-pop { opacity: 1; transform: translateY(0) scale(1); pointer-events: auto; }
.dock-pop-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 1px; }

.dock-sheet-backdrop { display: none; }


@media (prefers-reduced-motion: reduce) {
    .dock-pill, .dock-item, .dock-icon svg, .dock-gpop, .dock-pop, .dock-tip { transition: none !important; }
    .dock-item.just-added, .dock-item.just-added .dock-icon::after { animation: none !important; }
    .dock-item:hover { transform: none; }
    .dock-notif-pop { animation: none !important; }
}


@keyframes dock-notif-sheet-up {
    from { transform: translateY(28px); opacity: .55; }
    to   { transform: translateY(0);    opacity: 1; }
}


@keyframes dock-tab-pop {
    0%   { transform: scale(1); }
    45%  { transform: scale(1.16) translateY(-1.5px); }
    100% { transform: scale(1); }
}
@media (prefers-reduced-motion: reduce) {
    .dock-item.is-active .dock-icon { animation: none !important; }
    .dock-liquid { transition: none !important; }
}


@media (max-width: 560px) {
    
    :root { --dock-h: calc(68px + env(safe-area-inset-bottom)); }
    
    .dock-wrap { padding: 0; }   
    .dock {
        width: 100%; gap: 0; align-items: stretch; max-width: none;
        box-sizing: border-box;   
        padding: 6px 2px calc(8px + env(safe-area-inset-bottom));
        border-radius: 16px 16px 0 0; border-bottom: 0;
        box-shadow: 0 -6px 26px -10px rgba(8,24,40,.32);
    }
    .dock-pill, .dock-sep, .dock-tip { display: none; }

    
    .dock-item, .dock-opt-btn, .dock-pop-item, .dock-notif-btn { touch-action: manipulation; }

    
    .dock-item, .dock-opt, .dock-opt-btn, .dock-notif { flex: 1 1 0; width: auto; min-width: 0; max-width: none; box-sizing: border-box; }
    .dock-notif { align-items: stretch; }
    .dock-notif-btn { width: 100%; }
    
    
    .dock-notif-scrim { background: rgba(15, 23, 42, .45); animation: vm-scrim-fade .22s ease; }
    .dock-notif-pop {
        position: fixed; left: 0; right: 0; bottom: 0;
        top: max(14px, env(safe-area-inset-top));   
        display: flex;
        animation: dock-notif-sheet-up .3s cubic-bezier(.16, 1, .3, 1);
    }
    .dock-notif-pop .notif-menu {
        width: 100%; max-width: none; height: 100%;
        display: flex; flex-direction: column;
        border: 0; border-radius: 18px 18px 0 0;
        padding-bottom: env(safe-area-inset-bottom);
        box-shadow: 0 -18px 60px -12px rgba(8, 24, 40, .45);
    }
    
    .dock-notif-pop .notif-grab {
        display: flex; align-items: center; justify-content: center;
        flex: 0 0 auto; height: 36px;
        touch-action: none; cursor: grab;
    }
    .dock-notif-pop .notif-grab span {
        width: 44px; height: 4px; border-radius: 999px;
        background: var(--border-2, #cbd5e1);
    }
    .dock-notif-pop .notif-head { flex: 0 0 auto; padding-top: 2px; }
    
    .dock-notif-pop .notif-title { font-size: 17px; }
    .dock-notif-pop .notif-head-actions { gap: 6px; }
    .dock-notif-pop .notif-icon-btn { width: 40px; height: 40px; border-radius: 10px; }
    .dock-notif-pop .notif-icon-btn svg { width: 22px; height: 22px; }
    .dock-notif-pop .notif-body {
        flex: 1 1 auto; min-height: 0;   
        max-height: none;
        overscroll-behavior: contain;    
        -webkit-overflow-scrolling: touch;
    }
    .dock-notif-pop .notif-foot { flex: 0 0 auto; }
    .dock-notif-pop .notif-search-input { font-size: 16px; }   
    .dock-notif-pop .dock-notif-empty { padding: 48px 16px; }
    .dock-opt { display: flex; align-items: stretch; }   
    .dock-item, .dock-opt-btn {
        
        min-height: 54px; height: auto; padding: 8px 0 6px; gap: 4px; border-radius: 12px; justify-content: center;
    }
    .dock-opt.has-active .dock-opt-btn { background: transparent; color: var(--fg-3, #6b7280); }
    .dock-opt-btn:active { background: var(--bg-sunken, #f1f5f9); }
    .dock-item:hover { transform: none; background: transparent; color: var(--fg-3, #6b7280); }
    .dock-item:hover .dock-icon svg { transform: none; }
    
    .dock-icon svg { width: 26px; height: 26px; stroke-width: 1.5; }
    .dock-item.is-active .dock-icon svg { stroke-width: 1.8; }   
    .dock-label, .dock-opt-btn .dock-label { font-size: 10.5px; font-weight: 600; max-width: 100%; }

    
    .dock-item .dock-icon { transition: transform .18s ease; }
    .dock-item .dock-icon svg { transition: stroke-width .18s ease; }
    .dock-item .dock-label { transition: color .18s ease; }
    .dock-item { transition: color .18s ease; }
    .dock-item.is-active .dock-icon { animation: dock-tab-pop .32s cubic-bezier(.34, 1.56, .64, 1); }

    .dock-item.is-active { color: var(--brand, #0a4174); }
    

    
    .dock-liquid {
        position: absolute; pointer-events: none;
        top: 8px; bottom: calc(10px + env(safe-area-inset-bottom));
        left: 2px; width: calc((100% - 4px) / var(--dn, 5));
        transform: translateX(calc(var(--di, 0) * 100%));
        transition: transform .45s cubic-bezier(.3, 1.4, .5, 1);
    }
    .dock-liquid::before {
        content: ''; position: absolute; inset: 0 6px;
        border-radius: 14px;
        background: color-mix(in srgb, var(--brand, #0a4174) 12%, transparent);
    }

    
    .dock { position: static; }
    
    .dock-opt { position: static; z-index: auto; }
    
    .dock-opt-scrim {
        display: block; position: fixed; inset: 0;
        background: rgba(15, 23, 42, .45);
        border: 0; padding: 0;
        animation: vm-scrim-fade .22s ease;   
        
        z-index: 50;
    }
    .dock-pop {
        position: fixed; left: 8px; right: 8px; bottom: calc(var(--dock-h, 68px) + 10px); width: auto;
        border-radius: 16px; transform: translateY(10px) scale(.99); opacity: 0;
        transition: transform .24s cubic-bezier(.16,1,.3,1), opacity .2s ease;
        box-shadow: 0 14px 44px -10px rgba(8,24,40,.42); z-index: 1320;
    }
    .dock-opt.open .dock-pop { transform: translateY(0) scale(1) !important; opacity: 1 !important; pointer-events: auto; }
    
    .dock-pop-scroll {
        max-height: 78vh;
        max-height: calc(100dvh - var(--dock-h, 68px) - env(safe-area-inset-top, 0px) - 44px);
        padding: 8px;
    }
}
