/* Custom styles for Stock Screener Dashboard */

body {
    background-color: #f8f9fa;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

.feather-lg {
    width: 2rem;
    height: 2rem;
    opacity: 0.8;
}

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

.card-header {
    background-color: #fff;
    border-bottom: 1px solid #e9ecef;
    font-weight: 600;
}

.navbar-brand i {
    margin-right: 0.5rem;
}

/* Stock pick cards */
.stock-pick-card {
    border-left: 4px solid #007bff;
    margin-bottom: 1rem;
    transition: transform 0.2s;
}

.stock-pick-card:hover {
    transform: translateX(2px);
}

.stock-symbol {
    font-weight: bold;
    font-size: 1.1rem;
    color: #007bff;
}

.mispricing-score {
    font-size: 1.2rem;
    font-weight: bold;
}

.score-high {
    color: #28a745;
}

.score-medium {
    color: #ffc107;
}

.score-low {
    color: #6c757d;
}

/* Progress bars for signals */
.signal-bar {
    height: 0.5rem;
    border-radius: 0.25rem;
    background-color: #e9ecef;
    overflow: hidden;
    margin-bottom: 0.25rem;
}

.signal-fill {
    height: 100%;
    background-color: #007bff;
    transition: width 0.3s ease;
}

/* Metric displays */
.metric-value {
    font-size: 1.5rem;
    font-weight: bold;
    margin-bottom: 0.25rem;
}

.metric-label {
    font-size: 0.875rem;
    color: #6c757d;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Status indicators */
.status-indicator {
    display: inline-block;
    width: 0.75rem;
    height: 0.75rem;
    border-radius: 50%;
    margin-right: 0.5rem;
}

.status-open {
    background-color: #28a745;
}

.status-closed {
    background-color: #dc3545;
}

.status-unknown {
    background-color: #6c757d;
}

/* Loading states */
.loading-overlay {
    position: relative;
}

.loading-overlay::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(255, 255, 255, 0.8);
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Risk parameters styling */
.risk-params {
    background-color: #f8f9fa;
    border-radius: 0.375rem;
    padding: 0.75rem;
    margin-top: 0.5rem;
}

.risk-param {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.25rem;
}

.risk-param:last-child {
    margin-bottom: 0;
}

.risk-label {
    font-size: 0.875rem;
    color: #6c757d;
}

.risk-value {
    font-weight: 600;
    color: #495057;
}

/* Backtest results styling */
.backtest-metric {
    text-align: center;
    padding: 0.75rem;
    border-radius: 0.375rem;
    background-color: #f8f9fa;
    margin-bottom: 0.75rem;
}

.backtest-value {
    font-size: 1.25rem;
    font-weight: bold;
    margin-bottom: 0.25rem;
}

.backtest-label {
    font-size: 0.75rem;
    color: #6c757d;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Configuration display */
.config-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.375rem 0;
    border-bottom: 1px solid #e9ecef;
}

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

.config-label {
    font-size: 0.875rem;
    color: #6c757d;
}

.config-value {
    font-weight: 600;
    color: #495057;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .card-header .d-flex {
        flex-direction: column;
        gap: 0.5rem;
    }
    
    .navbar-text {
        display: none;
    }
    
    .feather-lg {
        width: 1.5rem;
        height: 1.5rem;
    }
}

/* Animation classes */
.fade-in {
    animation: fadeIn 0.5s ease-in;
}

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

/* Spinning animation for refresh button */
@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

/* Utility classes */
.text-mono {
    font-family: 'Courier New', monospace;
}

.border-start-primary {
    border-left: 3px solid #007bff !important;
}

.border-start-success {
    border-left: 3px solid #28a745 !important;
}

.border-start-warning {
    border-left: 3px solid #ffc107 !important;
}

.border-start-danger {
    border-left: 3px solid #dc3545 !important;
}
