/* notification.css */
.notification-container {
position: fixed;
top: 20px;
right: 20px;
z-index: 9999;
display: flex;
flex-direction: column;
gap: 10px;
}
.notification {
position: relative;
min-width: 300px;
max-width: 400px;
padding: 15px;
background: white;
border-radius: 8px;
box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
display: flex;
align-items: flex-start;
gap: 12px;
overflow: hidden;
}
.notification-icon {
font-size: 20px;
flex-shrink: 0;
}
.notification-content {
flex-grow: 1;
display: flex;
align-items: center;
gap: 12px;
justify-content: space-between;
}
.notification-body {
margin-right: auto;
}
.notification-message {
margin: 0;
font-size: 14px;
line-height: 1.5;
}
.notification-close {
background: none;
border: none;
padding: 4px;
cursor: pointer;
opacity: 0.5;
transition: opacity 0.2s;
}
.notification-close:hover {
opacity: 1;
}
.notification-progress {
position: absolute;
bottom: 0;
left: 0;
width: 100%;
height: 3px;
transform-origin: left;
}
/* Types */
.notification-success {
border-left: 4px solid var(--success-color);
}
.notification-success .notification-icon {
color: var(--success-color);
}
.notification-success .notification-progress {
background-color: var(--success-color);
}
.notification-error {
border-left: 4px solid var(--error-color);
}
.notification-error .notification-icon {
color: var(--error-color);
}
.notification-error .notification-progress {
background-color: var(--error-color);
}
.notification-warning {
border-left: 4px solid var(--warning-color);
}
.notification-warning .notification-icon {
color: var(--warning-color);
}
.notification-warning .notification-progress {
background-color: var(--warning-color);
}
.notification-info {
border-left: 4px solid var(--secondary-color);
}
.notification-info .notification-icon {
color: var(--secondary-color);
}
.notification-info .notification-progress {
background-color: var(--secondary-color);
}
/* Animations */
@keyframes notification-progress {
from {
width: 100%;
}
to {
width: 0%;
}
}
@keyframes fade-in {
from {
opacity: 0;
transform: translateX(100%);
}
to {
opacity: 1;
transform: translateX(0);
}
}
@keyframes fade-out {
from {
opacity: 1;
transform: translateX(0);
}
to {
opacity: 0;
transform: translateX(100%);
}
}
.fade-in {
animation: fade-in 0.3s ease forwards;
}
.fade-out {
animation: fade-out 0.3s ease forwards;
}
/* Media Queries */
@media (max-width: 480px) {
.notification-container {
top: auto;
bottom: 20px;
left: 20px;
right: 20px;
}
.notification {
min-width: 0;
width: 100%;
}
}
/* Reduced Motion */
@media (prefers-reduced-motion: reduce) {
.notification,
.notification-progress {
animation-duration: 0.01ms !important;
transition-duration: 0.01ms !important;
}
}