/* Container for Toast/Modal */
.gk-notice-container {
    position: fixed;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 99999;
    display: flex;
    flex-direction: column;
    gap: 10px;
    width: 90%;
    max-width: 400px;
    pointer-events: none; /* اجازه کلیک روی پشت */
}

/* The Notice Card */
.gk-notice-item {
    background: #fff;
    border-radius: 12px;
    padding: 16px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.15);
    display: flex;
    align-items: flex-start;
    gap: 12px;
    animation: gkSlideDown 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    pointer-events: auto;
    direction: rtl;
    border-right: 4px solid transparent;
    overflow: hidden;
    position: relative;
}

/* Types */
.gk-notice-item.is-success { border-right-color: #52c41a; }
.gk-notice-item.is-error { border-right-color: #ff4d4f; }
.gk-notice-item.is-info { border-right-color: #1890ff; }

/* Icon */
.gk-notice-icon {
    flex-shrink: 0;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
}
.is-success .gk-notice-icon { color: #52c41a; }
.is-error .gk-notice-icon { color: #ff4d4f; }

/* Content */
.gk-notice-content {
    flex: 1;
    font-size: 14px;
    color: #333;
    line-height: 1.6;
}
.gk-notice-title {
    font-weight: 700;
    margin-bottom: 4px;
    display: block;
    color: #000;
}

/* Close Button */
.gk-notice-close {
    background: none;
    border: none;
    color: #999;
    cursor: pointer;
    padding: 0;
    font-size: 18px;
    line-height: 1;
}
.gk-notice-close:hover { color: #333; }

/* Progress Bar (برای بسته شدن خودکار) */
.gk-notice-progress {
    position: absolute;
    bottom: 0;
    right: 0;
    height: 3px;
    background: rgba(0,0,0,0.05);
    width: 100%;
}
.gk-notice-progress span {
    display: block;
    height: 100%;
    background: currentColor; /* رنگ ارث بری از والد */
    width: 100%;
    animation: gkProgress 5s linear forwards;
}
.is-success .gk-notice-progress span { background: #52c41a; }
.is-error .gk-notice-progress span { background: #ff4d4f; }

/* Action Buttons (برای وقتی به سبد اضافه شد) */
.gk-notice-actions {
    margin-top: 10px;
    display: flex;
    gap: 10px;
}
.gk-notice-btn {
    font-size: 12px;
    padding: 6px 12px;
    border-radius: 6px;
    text-decoration: none;
    font-weight: bold;
    transition: 0.2s;
}
.gk-btn-cart {
    background: #52c41a;
    color: #fff;
}
.gk-btn-cart:hover { background: #389e0d; color: #fff; }
.gk-btn-outline {
    border: 1px solid #d9d9d9;
    color: #666;
}
.gk-btn-outline:hover { border-color: #999; color: #333; }

/* Animations */
@keyframes gkSlideDown {
    from { opacity: 0; transform: translateY(-20px) scale(0.9); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}
@keyframes gkProgress {
    from { width: 100%; }
    to { width: 0%; }
}
.gk-notice-hide {
    animation: gkSlideUp 0.3s forwards;
}
@keyframes gkSlideUp {
    to { opacity: 0; transform: translateY(-20px); }
}