﻿/* =========================================
           Widget 基礎樣式
        ========================================= */
#system-status-widget {
    position: fixed;
    top: 0px;
    right: 170px;
    z-index: 9999;
    transition: all 0.3s ease;
    white-space: nowrap;
    /* 新增：預設為半透明 (淡化) 狀態，降低視覺干擾 */
    opacity: 0.3;
}

    /* 新增：滑鼠移入整個區塊時，恢復原本的清晰度 */
    #system-status-widget:hover {
        opacity: 1;
    }

.status-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    display: inline-block;
    margin-right: 6px;
    flex-shrink: 0;
    transition: background-color 0.3s;
}

    /* 狀態顏色 */
    .status-dot.ok {
        background-color: #198754;
        box-shadow: 0 0 4px rgba(25,135,84,0.8);
    }

    .status-dot.error {
        background-color: #6c757d;
    }

    .status-dot.loading {
        background-color: #6c757d;
        animation: blink 1s infinite;
    }

@keyframes blink {
    0% {
        opacity: 1;
    }

    50% {
        opacity: 0.4;
    }

    100% {
        opacity: 1;
    }
}

/* 毛玻璃質感 */
.glass-effect {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(8px);
    border: 1px solid rgba(0,0,0,0.08);
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
}

/* =========================================
           互動元素樣式
        ========================================= */
.status-item {
    cursor: pointer;
    padding: 2px 4px;
    border-radius: 3px;
    transition: all 0.2s ease;
}

    .status-item:hover {
        background-color: rgba(0,0,0,0.04);
    }

/* 隱藏/顯示操作圖示的動畫 */
.action-icon {
    opacity: 0;
    margin-left: 4px;
    font-size: 0.8rem;
    transition: opacity 0.2s, transform 0.2s;
    transform: scale(0.8);
    color: #adb5bd;
}

.status-item:hover .action-icon {
    opacity: 1;
    transform: scale(1);
}

/* 列印程式重新整理的旋轉動畫 */
.action-icon.spin-active {
    opacity: 1;
    animation: spin 0.8s linear infinite;
    color: #0d6efd;
}

@keyframes spin {
    100% {
        transform: rotate(360deg);
    }
}

/* =========================================
           Toast 容器定位
        ========================================= */
.toast-container {
    z-index: 10000;
}
