.support-widget {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 1000;
}

.support-toggle {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background-color: #0d6efd;
    border: none;
    color: white;
    font-size: 24px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
    transition: transform 0.2s;
}

.support-toggle:hover {
    transform: scale(1.1);
}

.pulse-dot {
    position: absolute;
    top: 0;
    right: 0;
    width: 12px;
    height: 12px;
    background-color: #dc3545;
    border-radius: 50%;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% {
        transform: scale(0.95);
        box-shadow: 0 0 0 0 rgba(220, 53, 69, 0.7);
    }

    70% {
        transform: scale(1);
        box-shadow: 0 0 0 10px rgba(220, 53, 69, 0);
    }

    100% {
        transform: scale(0.95);
        box-shadow: 0 0 0 0 rgba(220, 53, 69, 0);
    }
}

.support-panel {
    display: none;
    position: absolute;
    bottom: 80px;
    right: 0;
    width: 350px;
    background: white;
    border-radius: 12px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.15);
}

.support-header {
    padding: 15px;
    border-bottom: 1px solid #eee;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.support-header h3 {
    margin: 0;
    color: #2c3e50;
    font-size: 18px;
}

.close-btn {
    background: none;
    border: none;
    font-size: 20px;
    color: #666;
    cursor: pointer;
    padding: 0;
}

.support-content {
    padding: 15px;
    max-height: 500px;
    overflow-y: auto;
}

.latest-ticket {
    margin-bottom: 20px;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 8px;
}

.ticket-status {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.9em;
    font-weight: 500;
    margin-bottom: 10px;
}

.status-new {
    background-color: #e3f2fd;
    color: #0d47a1;
}

.status-in_progress {
    background-color: #fff3e0;
    color: #e65100;
}

.status-resolved {
    background-color: #e8f5e9;
    color: #1b5e20;
}

.status-closed {
    background-color: #eeeeee;
    color: #424242;
}

.ticket-subject {
    font-weight: 500;
    color: #2c3e50;
    margin-bottom: 10px;
}

.ticket-message {
    color: #666;
    margin-bottom: 15px;
    line-height: 1.4;
}

.admin-response {
    background: #e3f2fd;
    padding: 10px;
    border-radius: 6px;
    margin-bottom: 15px;
}

.admin-response strong {
    color: #0d47a1;
    display: block;
    margin-bottom: 5px;
}

.admin-response p {
    margin: 0;
    color: #333;
}

.ticket-reply {
    margin-top: 15px;
}

.reply-input {
    width: 100%;
    min-height: 80px;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 6px;
    margin-bottom: 10px;
    resize: vertical;
}

.reply-btn {
    background-color: #0d6efd;
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 4px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: background-color 0.2s;
}

.reply-btn:hover {
    background-color: #0b5ed7;
}

.support-widget .support-actions {
    display: flex;
    gap: 12px;
    margin-top: 15px;
}

.support-widget .new-ticket-btn {
    width: 100%;
    padding: 10px 16px;
    background: #0d6efd;
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-weight: 500;
    font-size: 14px;
    transition: all 0.2s ease;
    box-shadow: 0 1px 2px rgba(13, 110, 253, 0.15);
}

.support-widget .new-ticket-btn:hover {
    background: #0b5ed7;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(13, 110, 253, 0.2);
}

.support-widget .all-tickets-btn {
    width: 100%;
    padding: 10px 16px;
    background: #fff;
    color: #495057;
    border: 1px solid #dee2e6;
    border-radius: 8px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-weight: 500;
    font-size: 14px;
    transition: all 0.2s ease;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

.support-widget .all-tickets-btn:hover {
    background: #f8f9fa;
    border-color: #ced4da;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.08);
}

.support-widget .new-ticket-btn i,
.support-widget .all-tickets-btn i {
    font-size: 14px;
}

/* Модальное окно */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 1100;
}

.modal-content {
    background-color: white;
    border-radius: 8px;
    max-width: 500px;
    margin: 50px auto;
    padding: 20px;
    position: relative;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.modal-header h3 {
    margin: 0;
    color: #2c3e50;
}

.close {
    font-size: 24px;
    color: #666;
    cursor: pointer;
}

.form-group {
    margin-bottom: 15px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    color: #2c3e50;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 4px;
}

.form-group textarea {
    min-height: 120px;
    resize: vertical;
}

.form-actions {
    text-align: right;
    margin-top: 20px;
}

.submit-btn {
    background-color: #0d6efd;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 4px;
    cursor: pointer;
    transition: background-color 0.2s;
}

.submit-btn:hover {
    background-color: #0b5ed7;
}

/* Стили для системных уведомлений */
.messages {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 2000;
    display: flex;
    flex-direction: column;
    gap: 10px;
    max-width: 400px;
}

.message {
    padding: 15px 20px;
    border-radius: 10px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
    display: flex;
    align-items: center;
    justify-content: space-between;
    animation: messageSlideIn 0.3s ease;
    transition: opacity 0.3s ease;
    opacity: 1;
}

.message--success {
    background-color: #d4edda;
    color: #155724;
    border-left: 4px solid #28a745;
}

.message--error {
    background-color: #f8d7da;
    color: #721c24;
    border-left: 4px solid #dc3545;
}

.message__close {
    background: none;
    border: none;
    font-size: 16px;
    cursor: pointer;
    color: inherit;
    opacity: 0.7;
    margin-left: 10px;
}

.message__close:hover {
    opacity: 1;
}

@keyframes messageSlideIn {
    from {
        transform: translateY(-20px);
        opacity: 0;
    }

    to {
        transform: translateY(0);
        opacity: 1;
    }
}