/* ================================================================
   AVESTA ADMIN — Windows 10 Action Center Toast System
   Professional, Square-Edge, Premium Glassmorphism
   ================================================================ */

:root {
    --win-toast-bg-dark: rgba(31, 31, 31, 0.85);
    --win-toast-bg-light: rgba(255, 255, 255, 0.9);
    --win-toast-blur: saturate(180%) blur(15px);
    --win-accent: #0078d4;
    --win-success: #107c10;
    --win-error: #e81123;
    --win-warning: #ffb900;
}

#avesta-toast-container {
    position: fixed;
    bottom: 50px; /* Taskbar üstü */
    right: 12px;
    z-index: 100000;
    display: flex;
    flex-direction: column-reverse;
    gap: 12px;
    pointer-events: none;
    width: 360px;
    max-width: calc(100vw - 24px);
}

.avt {
    pointer-events: all;
    background: var(--win-toast-bg-light);
    backdrop-filter: var(--win-toast-blur);
    -webkit-backdrop-filter: var(--win-toast-blur);
    border: 1px solid rgba(0, 0, 0, 0.1);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.15);
    padding: 16px;
    display: grid;
    grid-template-columns: 48px 1fr 24px;
    gap: 12px;
    position: relative;
    border-radius: 0; /* Windows 10 Keskin Kenar */
    transform: translateX(400px);
    opacity: 0;
    transition: transform 0.4s cubic-bezier(0.1, 0.9, 0.2, 1), opacity 0.3s ease;
    user-select: none;
    overflow: hidden;
}

/* Accent Line (Left) */
.avt::before {
    content: '';
    position: absolute;
    left: 0; top: 0; bottom: 0;
    width: 4px;
    background: var(--win-accent);
}

.avt.avt-show {
    transform: translateX(0);
    opacity: 1;
}

.avt.avt-hide {
    transform: translateX(400px);
    opacity: 0;
}

/* Types */
.avt-success::before { background: var(--win-success); }
.avt-error::before   { background: var(--win-error); }
.avt-warning::before { background: var(--win-warning); }
.avt-info::before    { background: var(--win-accent); }

/* Icon Section */
.avt-icon {
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.03);
}
.avt-success .avt-icon svg { color: var(--win-success); }
.avt-error   .avt-icon svg { color: var(--win-error); }
.avt-warning .avt-icon svg { color: var(--win-warning); }
.avt-info    .avt-icon svg { color: var(--win-accent); }

/* Body Section */
.avt-body {
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-width: 0;
}

.avt-title {
    font-size: 0.9rem;
    font-weight: 700;
    color: #000;
    margin-bottom: 2px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.avt-msg {
    font-size: 0.8rem;
    color: #444;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Close Button */
.avt-close {
    background: none;
    border: none;
    padding: 0;
    cursor: pointer;
    color: #888;
    display: flex;
    align-items: center;
    justify-content: center;
    height: 24px;
    width: 24px;
    transition: all 0.2s;
}
.avt-close:hover {
    color: #000;
    background: rgba(0,0,0,0.05);
}

/* Progress Bar (Bottom) */
.avt-progress {
    position: absolute;
    bottom: 0;
    left: 4px; /* Border genişliği kadar içerden */
    right: 0;
    height: 2px;
    background: rgba(0,0,0,0.05);
    transform-origin: left;
}
.avt-success .avt-progress-bar { background: var(--win-success); }
.avt-error   .avt-progress-bar { background: var(--win-error); }
.avt-warning .avt-progress-bar { background: var(--win-warning); }
.avt-info    .avt-progress-bar { background: var(--win-accent); }

.avt-progress-bar {
    height: 100%;
    width: 100%;
    transform-origin: left;
}

/* Dark Mode Support */
[data-theme="dark"] .avt {
    background: var(--win-toast-bg-dark);
    border-color: rgba(255, 255, 255, 0.1);
}
[data-theme="dark"] .avt-title { color: #fff; }
[data-theme="dark"] .avt-msg { color: #ccc; }
[data-theme="dark"] .avt-close:hover { color: #fff; background: rgba(255,255,255,0.1); }
[data-theme="dark"] .avt-icon { background: rgba(255, 255, 255, 0.05); }

/* Animation Overlay for "Wow" Effect */
@keyframes winToastIn {
    from { transform: translateX(100%); opacity: 0; }
    to { transform: translateX(0); opacity: 1; }
}
