/* Стили для системы быстрых действий */

/* Плавающая кнопка действий (FAB) */
.quick-actions-fab {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background-color: #3498db;
    color: white;
    border: none;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    transition: all 0.3s ease;
    font-size: 1.5rem;
}

.quick-actions-fab:hover {
    background-color: #2980b9;
    transform: scale(1.1);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.4);
}

.quick-actions-fab.active {
    background-color: #2980b9;
    transform: rotate(45deg);
}

.quick-actions-fab .fab-icon {
    display: block;
    line-height: 1;
}

/* Меню быстрых действий */
.quick-actions-menu {
    position: fixed;
    bottom: 80px;
    right: 2rem;
    background: white;
    border-radius: 8px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
    min-width: 250px;
    max-width: 350px;
    max-height: 70vh;
    overflow-y: auto;
    z-index: 999;
    animation: slideUp 0.3s ease;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.quick-actions-menu-content {
    padding: 0.5rem;
}

.quick-actions-group {
    margin-bottom: 0.5rem;
}

.quick-actions-group:not(:last-child) {
    border-bottom: 1px solid #e0e0e0;
    padding-bottom: 0.5rem;
    margin-bottom: 0.5rem;
}

.quick-actions-item {
    width: 100%;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 1rem;
    background: none;
    border: none;
    text-align: left;
    cursor: pointer;
    border-radius: 4px;
    transition: background-color 0.2s;
    font-size: 0.9rem;
    color: #333;
}

.quick-actions-item:hover {
    background-color: #f0f0f0;
}

.quick-actions-icon {
    font-size: 1.2rem;
    flex-shrink: 0;
}

.quick-actions-label {
    flex: 1;
}

.quick-actions-hotkey {
    font-size: 0.75rem;
    color: #999;
    background: #f5f5f5;
    padding: 0.2rem 0.4rem;
    border-radius: 3px;
    font-family: monospace;
}

/* Панель быстрых действий */

/* Контекстное меню */
.context-menu {
    position: fixed;
    background: white;
    border-radius: 4px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    min-width: 200px;
    z-index: 10000;
    padding: 0.25rem 0;
    animation: fadeIn 0.2s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: scale(0.95);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

.context-menu-group {
    padding: 0.25rem 0;
}

.context-menu-group:not(:last-child) {
    border-bottom: 1px solid #e0e0e0;
    margin-bottom: 0.25rem;
    padding-bottom: 0.5rem;
}

.context-menu-item {
    width: 100%;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.5rem 1rem;
    background: none;
    border: none;
    text-align: left;
    cursor: pointer;
    font-size: 0.9rem;
    color: #333;
    transition: background-color 0.15s;
}

.context-menu-item:hover:not(.disabled) {
    background-color: #f0f0f0;
}

.context-menu-item.disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.context-menu-icon {
    font-size: 1rem;
    flex-shrink: 0;
    width: 20px;
    text-align: center;
}

.context-menu-label {
    flex: 1;
}

.context-menu-hotkey {
    font-size: 0.75rem;
    color: #999;
    background: #f5f5f5;
    padding: 0.15rem 0.3rem;
    border-radius: 3px;
    font-family: monospace;
}

/* Адаптивность */
@media (max-width: 768px) {
    .quick-actions-fab {
        bottom: 1rem;
        right: 1rem;
        width: 48px;
        height: 48px;
        font-size: 1.2rem;
    }
    
    .quick-actions-menu {
        bottom: 60px;
        right: 1rem;
        min-width: 200px;
        max-width: calc(100vw - 2rem);
    }
    
}

/* Скрытие FAB на мобильных (кроме ТСД) */
@media (max-width: 768px) {
    body:not(.tsd-page) .quick-actions-fab {
        display: none !important;
    }
}
