/* ============================================================
   Activity Feed Toast – styles v1.2.0
   zoospace.bg | orange #f47c20 + dark navy palette
   ============================================================ */

/* ── Container (fixed, bottom-left) ─────────────────────────── */
#aft-container {
    position: fixed;
    bottom: 24px;
    left: 20px;
    z-index: 99990;
    display: flex;
    flex-direction: column-reverse;   /* newest on bottom */
    gap: 10px;
    pointer-events: none;
    max-width: 320px;
    width: calc(100vw - 40px);
}

/* ── Single toast ────────────────────────────────────────────── */
.aft-toast {
    display: flex;
    align-items: flex-start;
    gap: 11px;
    background: #ffffff;
    border: 1px solid #f0e8df;
    border-left: 4px solid #f47c20;
    border-radius: 10px;
    padding: 11px 14px 11px 12px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.10);
    pointer-events: auto;
    cursor: default;
    position: relative;
    overflow: hidden;

    /* entry animation */
    opacity: 0;
    transform: translateX(-30px);
    animation: aft-slide-in 0.45s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

/* leaving state (added by JS) */
.aft-toast.aft-leaving {
    animation: aft-slide-out 0.38s cubic-bezier(0.55, 0, 1, 0.45) forwards;
}

/* ── Emoji icon ──────────────────────────────────────────────── */
.aft-emoji {
    font-size: 22px;
    line-height: 1;
    flex-shrink: 0;
    margin-top: 1px;
}

/* ── Text block ──────────────────────────────────────────────── */
.aft-body {
    flex: 1;
    min-width: 0;
}

.aft-message {
    font-size: 13px;
    line-height: 1.45;
    color: #1a2236;
    font-weight: 500;
    word-break: break-word;
}

.aft-message strong {
    color: #f47c20;
    font-weight: 700;
}

.aft-time {
    display: block;
    font-size: 11px;
    color: #9ca3af;
    margin-top: 3px;
    font-weight: 400;
}

/* ── Close button ────────────────────────────────────────────── */
.aft-close {
    background: none;
    border: none;
    padding: 0;
    margin: 0;
    cursor: pointer;
    color: #c0c8d6;
    font-size: 16px;
    line-height: 1;
    flex-shrink: 0;
    align-self: flex-start;
    margin-top: -1px;
    transition: color 0.15s;
}

.aft-close:hover {
    color: #6b7280;
}

/* ── Progress bar (auto-dismiss indicator) ───────────────────── */
.aft-progress {
    position: absolute;
    bottom: 0;
    left: 0;
    height: 3px;
    background: #f47c20;
    border-radius: 0 0 0 6px;
    opacity: 0.5;
    animation: aft-progress-shrink var(--aft-duration, 6s) linear forwards;
    width: 100%;
}

/* ── Keyframes ────────────────────────────────────────────────── */
@keyframes aft-slide-in {
    from {
        opacity: 0;
        transform: translateX(-30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes aft-slide-out {
    from {
        opacity: 1;
        transform: translateX(0);
        max-height: 120px;
        margin-bottom: 0;
    }
    to {
        opacity: 0;
        transform: translateX(-40px);
        max-height: 0;
        margin-bottom: -10px;
        padding-top: 0;
        padding-bottom: 0;
    }
}

@keyframes aft-progress-shrink {
    from { width: 100%; }
    to   { width: 0%; }
}

/* ── Clickable toast ─────────────────────────────────────────── */
.aft-toast.aft-clickable {
    cursor: pointer;
}

.aft-toast.aft-clickable:hover {
    border-left-color: #02c5bd;
    box-shadow: 0 6px 24px rgba(0, 0, 0, 0.14);
    transform: translateX(3px);
    transition: box-shadow 0.2s, border-color 0.2s, transform 0.2s;
}

/* ── Listing title label ─────────────────────────────────────── */
.aft-listing-title {
    display: block;
    font-size: 11.5px;
    font-weight: 600;
    color: #02c5bd;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin-top: 3px;
    max-width: 100%;
}

/* ── Mobile tweaks ───────────────────────────────────────────── */
@media (max-width: 480px) {
    #aft-container {
        bottom: 24px;
        left: 12px;
        max-width: calc(100vw - 24px);
        width: calc(100vw - 24px);
    }

    .aft-toast {
        padding: 10px 12px 10px 10px;
    }

    .aft-message {
        font-size: 12.5px;
    }

}