/* OTA Server custom styles */
.page-wrapper {
    min-height: 100vh;
}

/* Login page centering */
.page-body .row.justify-content-center {
    min-height: 80vh;
    align-items: center;
}

/* Progress log styling */
#progress-log {
    background: var(--tblr-bg-surface-secondary);
    border-radius: 4px;
    padding: 0.75rem;
    font-family: var(--tblr-font-monospace);
}

/* Table improvements */
.table-vcenter td {
    vertical-align: middle;
}

/* Sidebar brand */
.navbar-brand-text {
    font-weight: 600;
    letter-spacing: -0.025em;
}

/* Sidebar build info */
.sidebar-build-info {
    font-size: 0.7rem;
    opacity: 0.6;
    border-top: 1px solid var(--tblr-border-color);
    word-break: break-all;
    line-height: 1.4;
}

/* Status badges in tables */
.badge {
    font-weight: 500;
}

/* Card stats */
.card-sm .avatar {
    width: 2.5rem;
    height: 2.5rem;
}

/* CodeMirror editor container */
.editor-container {
    min-height: 400px;
}

.CodeMirror {
    border: 1px solid var(--tblr-border-color);
    border-radius: 4px;
    height: 400px;
    font-size: 14px;
}

/* Config management tab buttons */
.config-actions {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

/* Custom modal (Bootstrap-independent) */
.custom-modal-backdrop {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1050;
}

.custom-modal {
    display: none;
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 1060;
    min-width: 460px;
    max-width: 90vw;
}

.custom-modal .card {
    margin: 0;
    box-shadow: 0 0.5rem 2rem rgba(0, 0, 0, 0.3);
}

.custom-modal .card-footer {
    display: flex;
    justify-content: flex-end;
    gap: 0.5rem;
    padding: 0.75rem 1rem;
    background: var(--tblr-bg-surface-secondary);
    border-top: 1px solid var(--tblr-border-color);
}

/* Tag badges in device table */
.tag-badge {
    display: inline-flex;
    align-items: center;
    padding: 0.15rem 0.5rem;
    margin: 0.1rem;
    font-size: 0.75rem;
    font-weight: 500;
    border-radius: 9999px;
    border: 1px solid;
    white-space: nowrap;
}

.tag-badge .tag-key {
    font-weight: 600;
}

.tag-badge .tag-sep {
    margin: 0 0.2rem;
    opacity: 0.6;
}

.tag-badge .tag-val {
    font-weight: 500;
}

/* Tag color picker swatches */
.tag-color-swatch {
    width: 28px;
    height: 28px;
    border-radius: 6px;
    cursor: pointer;
    border: 2px solid transparent;
    transition: border-color 0.15s;
}

.tag-color-swatch:hover {
    border-color: var(--tblr-body-color);
}

.tag-color-swatch.selected {
    border-color: var(--tblr-body-color);
    box-shadow: 0 0 0 2px var(--tblr-bg-surface);
}

/* Tag color dot in settings table */
.tag-color-dot {
    display: inline-block;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    margin-right: 0.5rem;
    vertical-align: middle;
}
