/* Custom styles for AI Model Comparison Tool */

/* Black background for the entire page */
body {
    background-color: black !important;
}

/* CRITICAL DROPDOWN Z-INDEX OVERRIDE */
.navbar .dropdown-menu {
    z-index: 999999 !important;
    position: absolute !important;
}

.navbar .nav-item.dropdown {
    z-index: 999999 !important;
    position: relative !important;
}

.navbar {
    z-index: 99999 !important;
}

.ai-response-card {
    transition: transform 0.2s ease-in-out, box-shadow 0.2s ease-in-out;
}

.ai-response-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.response-content {
    font-size: 0.95rem;
    line-height: 1.6;
    max-height: 400px;
    overflow-y: auto;
}

.response-content::-webkit-scrollbar {
    width: 6px;
}

.response-content::-webkit-scrollbar-track {
    background: var(--bs-secondary-bg);
    border-radius: 3px;
}

.response-content::-webkit-scrollbar-thumb {
    background: var(--bs-secondary);
    border-radius: 3px;
}

.response-content::-webkit-scrollbar-thumb:hover {
    background: var(--bs-secondary-color);
}

/* Attachment button styling - slightly larger */
.attachment-btn {
    width: 36px !important;
    height: 36px !important;
    padding: 0 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    background-color: #dc3545 !important;
    border-color: #dc3545 !important;
    color: white !important;
}

.attachment-btn:hover {
    background-color: #c82333 !important;
    border-color: #bd2130 !important;
    color: white !important;
}

/* Voice input button styling - slightly larger */
.voice-btn {
    width: 36px !important;
    height: 36px !important;
    padding: 0 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
}

/* Advanced Query Options button - slightly larger */
.btn-outline-light {
    padding: 0.5rem 0.8rem !important;
    font-size: 0.9rem !important;
}

/* Patent Pending buttons - slightly larger */
.btn-outline-warning {
    padding: 0.4rem 0.7rem !important;
    font-size: 0.85rem !important;
}

/* Mobile responsive fixes for AI model names */
@media (max-width: 767px) {
    .ai-model-option {
        padding: 0.6rem 0.8rem !important;
        margin-bottom: 0.4rem !important;
    }
    
    .ai-model-option .ai-model-name {
        font-size: 0.9rem !important;
        line-height: 1.2 !important;
        word-wrap: break-word !important;
        overflow-wrap: break-word !important;
    }
    
    .ai-model-option .ai-model-description {
        font-size: 0.8rem !important;
        line-height: 1.1 !important;
        word-wrap: break-word !important;
        overflow-wrap: break-word !important;
    }
    
    /* Ensure model selection container has proper spacing */
    .model-selection-container {
        padding: 0.5rem !important;
        max-width: 100% !important;
        overflow-x: hidden !important;
    }
    
    /* Fix checkbox positioning on mobile */
    .ai-model-option input[type="checkbox"] {
        flex-shrink: 0 !important;
        margin-right: 0.6rem !important;
    }
    
    /* Better text wrapping for model badges */
    .badge {
        font-size: 0.7rem !important;
        padding: 0.2rem 0.4rem !important;
        white-space: nowrap !important;
    }
    
    /* Mobile-only button size adjustments */
    .attachment-btn {
        width: 28px !important;
        height: 28px !important;
        font-size: 0.65rem !important;
    }
    
    .voice-btn {
        width: 28px !important;
        height: 28px !important;
        font-size: 0.65rem !important;
    }
    
    .compact-btn {
        padding: 0.1rem 0.25rem !important;
        font-size: 0.55rem !important;
        height: 18px !important;
    }
    
    .btn-outline-light {
        padding: 0.35rem 0.6rem !important;
        font-size: 0.75rem !important;
    }
    
    .btn-outline-warning {
        padding: 0.3rem 0.5rem !important;
        font-size: 0.7rem !important;
    }
}

.attachment-btn:active,
.attachment-btn:focus {
    background-color: #bd2130 !important;
    border-color: #b21f2d !important;
    color: white !important;
    box-shadow: 0 0 0 0.2rem rgba(220, 53, 69, 0.25) !important;
}

.voice-input-container {
    margin-top: 8px;
}

/* Attachment preview styling */
.attachment-preview {
    font-size: 0.875rem;
}

.attachment-preview .btn-sm {
    width: 24px;
    height: 24px;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Loading animation */
.loading-dots {
    display: inline-block;
}

.loading-dots::after {
    content: '';
    animation: loading-dots 1.5s steps(4, end) infinite;
}

@keyframes loading-dots {
    0%, 20% { content: ''; }
    40% { content: '.'; }
    60% { content: '..'; }
    80%, 100% { content: '...'; }
}

/* Character counter */
#charCount {
    font-weight: 500;
}

.char-warning {
    color: var(--bs-warning) !important;
}

.char-danger {
    color: var(--bs-danger) !important;
}

/* Genesis Core Brain-Microchip Icon Animations */
@keyframes blink {
    0%, 50% { opacity: 1; }
    51%, 100% { opacity: 0.3; }
}

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

/* Genesis Core title uses default Bootstrap styling */

/* Responsive improvements */
@media (max-width: 768px) {
    .display-4, .genesis-title {
        font-size: 2rem;
    }
    
    .ai-response-card {
        margin-bottom: 1rem;
    }
    
    .response-content {
        max-height: 300px;
    }
}

/* Quality indicators */
.quality-excellent { border-left: 4px solid var(--bs-success); }
.quality-good { border-left: 4px solid var(--bs-info); }
.quality-fair { border-left: 4px solid var(--bs-warning); }
.quality-poor { border-left: 4px solid var(--bs-danger); }

/* Service-specific styling */
.service-gpt4 { border-left: 4px solid var(--bs-success); }
.service-claude { border-left: 4px solid var(--bs-info); }
.service-gemini { border-left: 4px solid var(--bs-warning); }

/* Smooth transitions */
.card {
    transition: all 0.3s ease;
}

.btn {
    transition: all 0.2s ease;
}

/* Focus states for accessibility */
.form-control:focus {
    box-shadow: 0 0 0 0.2rem rgba(var(--bs-primary-rgb), 0.25);
}

/* Custom alerts */
.alert {
    border: none;
    border-radius: 8px;
}

/* Loading modal improvements */
.modal-content {
    border-radius: 12px;
}

.spinner-border {
    width: 3rem;
    height: 3rem;
}
