/* TCMS Frontend Styles */

/* Sidebar */
.sidebar {
    display: flex;
    flex-direction: column;
}

.sidebar-item {
    cursor: pointer;
    transition: all 0.2s;
    background: var(--bs-dark);
}

.sidebar-item:hover {
    background: var(--bs-secondary);
}

/* Signal Cards */
.signal-card {
    transition: all 0.3s;
}

.signal-card.border-success {
    border-left: 4px solid var(--bs-success) !important;
}

.signal-card .answer {
    line-height: 1.6;
    white-space: pre-wrap;
    word-break: break-word;
}

.signal-card .screenshot img {
    cursor: pointer;
    transition: transform 0.2s;
    max-height: 400px;
    object-fit: contain;
}

.signal-card .screenshot img:hover {
    transform: scale(1.02);
}

/* Highlight animation */
.signal-card.highlight {
    animation: highlight 1.5s ease;
}

@keyframes highlight {
    0%, 100% { background-color: var(--bs-dark); }
    50% { background-color: rgba(13, 110, 253, 0.2); }
}

/* New item slide down */
.signal-card.new {
    animation: slideDown 0.5s ease;
}

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

/* Cursor */
.cursor-pointer {
    cursor: pointer;
}

/* Timer box */
#timerBox {
    min-width: 35px;
    text-align: center;
}

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--bs-dark);
}

::-webkit-scrollbar-thumb {
    background: var(--bs-secondary);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--bs-gray);
}

/* Light theme adjustments */
[data-bs-theme="light"] .sidebar-item {
    background: var(--bs-light);
}

[data-bs-theme="light"] .sidebar-item:hover {
    background: var(--bs-gray-200);
}

/* Debug info */
.debug-info {
    padding-top: 0.5rem;
    border-top: 1px dashed var(--bs-secondary);
}

/* Mobile */
@media (max-width: 768px) {
    .d-flex.vh-100 {
        flex-direction: column !important;
    }

    .sidebar {
        width: 100% !important;
        max-height: 40vh;
    }

    .flex-grow-1 {
        height: 60vh;
    }
}

/* Form controls in dark theme */
[data-bs-theme="dark"] .form-control,
[data-bs-theme="dark"] .form-select {
    background-color: var(--bs-gray-800);
    border-color: var(--bs-gray-700);
    color: var(--bs-light);
}

[data-bs-theme="dark"] .form-control:focus,
[data-bs-theme="dark"] .form-select:focus {
    background-color: var(--bs-gray-800);
    border-color: var(--bs-primary);
    color: var(--bs-light);
}

/* Modal image */
#imageModal .modal-body {
    background: transparent;
}

#modalImage {
    max-height: 90vh;
    object-fit: contain;
}
