.update-toast {
    position: fixed;
    bottom: 24px;
    right: 24px;
    display: none;
    align-items: center;
    gap: 12px;
    padding: 12px 14px;
    background: rgba(20, 22, 38, 0.85);
    backdrop-filter: blur(16px);
    border: 1px solid rgba(200, 195, 230, 0.18);
    border-radius: 12px;
    z-index: 50;
    max-width: 320px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
    color: #e8e5f4;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}
.update-toast.visible {
    display: flex;
    animation: utSlideIn 0.5s cubic-bezier(0.22, 0.72, 0.14, 1);
}
.update-toast.dismissing {
    animation: utSlideOut 0.3s cubic-bezier(0.22, 0.72, 0.14, 1) forwards;
}
@keyframes utSlideIn {
    from { transform: translateY(24px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}
@keyframes utSlideOut {
    from { transform: translateY(0); opacity: 1; }
    to { transform: translateY(24px); opacity: 0; }
}
.ut-icon {
    flex-shrink: 0;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(184, 176, 218, 0.15);
    border: 1px solid rgba(184, 176, 218, 0.25);
    border-radius: 8px;
    color: #b8b0da;
    font-size: 14px;
    font-weight: 600;
}
.ut-body { flex: 1; min-width: 0; }
.ut-title {
    font-size: 13px;
    font-weight: 600;
    color: #e8e5f4;
    margin-bottom: 2px;
    letter-spacing: -0.01em;
}
.ut-desc {
    font-size: 12px;
    color: #a9a3c7;
    line-height: 1.4;
}
.ut-close {
    flex-shrink: 0;
    width: 24px;
    height: 24px;
    border: none;
    background: transparent;
    color: #706b8f;
    font-size: 18px;
    cursor: pointer;
    border-radius: 6px;
    transition: background 0.2s, color 0.2s;
    line-height: 1;
    padding: 0;
    font-family: inherit;
}
.ut-close:hover {
    background: rgba(200, 195, 230, 0.08);
    color: #e8e5f4;
}
@media (max-width: 600px) {
    .update-toast {
        bottom: 16px;
        right: 16px;
        left: 16px;
        max-width: none;
    }
}

.changelog-overlay {
    position: fixed;
    inset: 0;
    z-index: 220;
    display: none;
    align-items: center;
    justify-content: center;
    background: rgba(2, 3, 8, 0.7);
    backdrop-filter: blur(6px);
    animation: clFade 0.22s ease forwards;
}
.changelog-overlay.open { display: flex; }
@keyframes clFade { from { opacity: 0; } to { opacity: 1; } }

.changelog-modal {
    width: calc(100% - 40px);
    max-width: 460px;
    max-height: calc(100vh - 80px);
    overflow-y: auto;
    background: #0a0b14;
    border: 1px solid rgba(200, 195, 230, 0.16);
    border-radius: 14px;
    box-shadow: 0 32px 64px rgba(0, 0, 0, 0.55), 0 0 0 1px rgba(200, 195, 230, 0.04);
    padding: 24px 26px 22px;
    color: var(--fg-2);
    animation: clRise 0.28s cubic-bezier(0.2, 0.8, 0.2, 1) forwards;
}
@keyframes clRise {
    from { opacity: 0; transform: translateY(14px) scale(0.97); }
    to   { opacity: 1; transform: translateY(0) scale(1); }
}

.cl-head {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 14px;
}
.cl-icon {
    font-size: 22px;
    color: var(--accent);
    line-height: 1;
    text-shadow: 0 0 12px rgba(201, 193, 255, 0.4);
}
.cl-title {
    margin: 0;
    font-size: 17px;
    font-weight: 600;
    letter-spacing: -0.01em;
    color: var(--fg);
}
.cl-version {
    margin-top: 2px;
    font-size: 11px;
    color: var(--fg-3);
    font-family: 'JetBrains Mono', ui-monospace, monospace;
}
.cl-list {
    list-style: none;
    padding: 0;
    margin: 0 0 18px;
    display: flex;
    flex-direction: column;
    gap: 9px;
    font-size: 13px;
    line-height: 1.55;
    color: var(--fg-2);
}
.cl-list li {
    padding: 9px 12px;
    background: rgba(200, 195, 230, 0.04);
    border: 1px solid rgba(200, 195, 230, 0.08);
    border-radius: 8px;
}
.cl-list strong { color: var(--fg); font-weight: 500; }
.cl-list a { color: var(--accent); }
.cl-list code {
    background: rgba(200, 195, 230, 0.08);
    padding: 1px 5px;
    border-radius: 4px;
    font-family: 'JetBrains Mono', ui-monospace, monospace;
    font-size: 11.5px;
}
.cl-close {
    display: block;
    margin: 0 auto;
    padding: 10px 28px;
    border: 1px solid rgba(200, 195, 230, 0.18);
    background: linear-gradient(180deg, #b8b0da, #8a80b6);
    color: #0a0b14;
    border-radius: 9px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.12s ease, box-shadow 0.18s ease, filter 0.18s ease;
    box-shadow: 0 6px 18px rgba(138, 128, 182, 0.35);
}
.cl-close:hover {
    transform: translateY(-1px);
    filter: brightness(1.08);
    box-shadow: 0 10px 24px rgba(138, 128, 182, 0.5);
}
.cl-close:active { transform: translateY(0); }
