/* Custom styles for Resolved */

:root {
    --primary-color: #0d6efd;
    --secondary-color: #6c757d;
    --success-color: #198754;
    --warning-color: #ffc107;
    --danger-color: #dc3545;
}

/* Speech-to-text button styling */
#speechButton {
    border-radius: 20px;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

#speechButton:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.15);
}

#speechButton.btn-danger {
    animation: pulse 1.5s infinite;
}

@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

/* Speech status styling */
#speechStatus .alert {
    border-radius: 8px;
    border: none;
    font-size: 0.9rem;
}

#speechStatus .alert-info {
    background-color: #e3f2fd;
    color: #1976d2;
}

#speechStatus .alert-danger {
    background-color: #ffebee;
    color: #d32f2f;
}

/* Textarea focus state when speech is active */
#description:focus {
    border-color: #0d6efd;
    box-shadow: 0 0 0 0.2rem rgba(13, 110, 253, 0.25);
}

/* Responsive adjustments for speech button */
@media (max-width: 768px) {
    #speechButton {
        width: 32px;
        height: 32px;
        top: 8px;
        right: 8px;
    }
    
    #speechButton i {
        font-size: 0.9rem;
    }
}

/* Identity information styling */
.alert-info {
    border-left: 4px solid #0dcaf0;
    background-color: #f8f9fa;
}

.alert-info h6 {
    color: #0a58ca;
    margin-bottom: 10px;
}

.alert-info code {
    background-color: #e9ecef;
    color: #495057;
    padding: 2px 6px;
    border-radius: 3px;
    font-size: 0.9em;
}

.alert-info .badge {
    font-size: 0.75em;
    margin-left: 5px;
}

.alert-info .text-muted {
    font-size: 0.85em;
    word-break: break-all;
}

body {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

main {
    flex: 1;
}

.navbar-brand {
    font-weight: bold;
    font-size: 1.5rem;
}

.card {
    border-radius: 10px;
    border: none;
    box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);
}

.card:hover {
    box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
    transition: box-shadow 0.3s ease-in-out;
}

code {
    background-color: #f8f9fa;
    padding: 0.2rem 0.4rem;
    border-radius: 3px;
    font-size: 87.5%;
}

.badge {
    padding: 0.35em 0.65em;
    font-weight: 500;
}

.table th {
    border-bottom: 2px solid #dee2e6;
    font-weight: 600;
}

.btn-sm {
    padding: 0.25rem 0.75rem;
}

/* Ticket status colors */
.ticket-open {
    border-left: 4px solid var(--warning-color);
}

.ticket-resolved {
    border-left: 4px solid var(--success-color);
}

.ticket-critical {
    border-left: 4px solid var(--danger-color);
}

/* Loading spinner */
.spinner-border {
    width: 1rem;
    height: 1rem;
    border-width: 0.15em;
}

/* Email autocomplete styles */
.suggestion-item {
    transition: all 0.2s ease;
    border-bottom: 1px solid #f0f0f0;
}

.suggestion-item:last-child {
    border-bottom: none;
}

.suggestion-item:hover {
    background-color: var(--primary-color) !important;
    color: white !important;
}

.suggestion-item.selected {
    background-color: var(--primary-color);
    color: white;
}

#emailSuggestions {
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    border: 1px solid #dee2e6;
    border-top: none;
}

/* Company branding */
.company-title {
    color: var(--primary-color);
    font-weight: 600;
}

/* Email validation styling */
.email-validation-success {
    color: var(--success-color);
    font-weight: 500;
}

.email-validation-warning {
    color: var(--warning-color);
    font-weight: 500;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .table-responsive {
        font-size: 0.875rem;
    }
    
    .card-body {
        padding: 1rem;
    }
    
    #emailSuggestions {
        max-height: 150px;
    }
}