/* Observer API Management UI Styles */

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

#app-content {
    flex: 1;
}

footer {
    margin-top: auto;
}

/* Navigation */
.navbar-brand {
    font-weight: bold;
}

.nav-link.active {
    border-bottom: 2px solid #fff;
}

/* Cards */
.card {
    box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);
    margin-bottom: 1rem;
}

.card-header {
    background-color: #f8f9fa;
    font-weight: 600;
}

/* Tables */
.table-hover tbody tr:hover {
    background-color: rgba(0, 0, 0, 0.025);
}

/* Code blocks */
.config-content {
    background-color: #f8f9fa;
    border: 1px solid #dee2e6;
    border-radius: 0.25rem;
    padding: 1rem;
    font-family: 'Courier New', monospace;
    font-size: 0.875rem;
    white-space: pre-wrap;
    word-wrap: break-word;
    max-height: 500px;
    overflow-y: auto;
}

/* Badges */
.status-badge {
    font-size: 0.875rem;
}

/* Loading */
#loading-spinner {
    min-height: 300px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

/* Diff viewer */
.diff-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

.diff-panel {
    border: 1px solid #dee2e6;
    border-radius: 0.25rem;
    padding: 1rem;
    background-color: #f8f9fa;
}

/* Responsive */
@media (max-width: 768px) {
    .diff-container {
        grid-template-columns: 1fr;
    }
}

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

.text-monospace {
    font-family: 'Courier New', monospace;
}

/* Configuration Filter Buttons */
.btn-group .btn-outline-info.active {
    background-color: #0dcaf0;
    border-color: #0dcaf0;
    color: #000;
}

.btn-group .btn-outline-warning.active {
    background-color: #ffc107;
    border-color: #ffc107;
    color: #000;
}

.btn-group .btn-outline-secondary.active {
    background-color: #6c757d;
    border-color: #6c757d;
    color: #fff;
}

/* Filter button badges */
.btn-group .btn .badge {
    font-size: 0.7rem;
    padding: 0.2em 0.4em;
    vertical-align: middle;
}

/* Filter button hover effects */
.btn-outline-info:hover:not(.active) {
    background-color: rgba(13, 202, 240, 0.1);
}

.btn-outline-warning:hover:not(.active) {
    background-color: rgba(255, 193, 7, 0.1);
}

/* Responsive filter controls */
@media (max-width: 768px) {
    .card-header .d-flex.flex-wrap {
        flex-direction: column;
        align-items: stretch !important;
    }

    .card-header .btn-group {
        width: 100%;
        margin-bottom: 0.5rem;
    }

    .card-header .btn-group .btn {
        flex: 1;
    }
}

/* =========================================
   Global Search Styles
   ========================================= */

/* Navbar search input */
#nav-search-form .form-control {
    width: 200px;
    transition: width 0.3s ease;
}

#nav-search-form .form-control:focus {
    width: 280px;
    background-color: #343a40 !important;
}

#nav-search-form .form-control::placeholder {
    color: #adb5bd;
    font-size: 0.875rem;
}

/* Search results */
.search-result-item {
    cursor: pointer;
    transition: background-color 0.15s ease;
}

.search-result-item:hover {
    background-color: #f8f9fa;
}

.search-result-item h6 {
    color: #212529;
}

.search-result-item code {
    font-size: 0.8rem;
    background-color: #e9ecef;
    padding: 0.1rem 0.3rem;
    border-radius: 3px;
}

/* Quick search buttons */
.quick-search {
    transition: transform 0.1s ease;
}

.quick-search:hover {
    transform: translateY(-2px);
}

/* Category cards in search results */
.search-result-item .bi {
    width: 1.2em;
}

/* Responsive search */
@media (max-width: 768px) {
    #nav-search-form {
        display: none !important;
    }

    #nav-search-form .form-control,
    #nav-search-form .form-control:focus {
        width: 100%;
    }
}

@media (max-width: 992px) {
    #nav-search-form .form-control {
        width: 150px;
    }

    #nav-search-form .form-control:focus {
        width: 200px;
    }
}
