.fb-wrap {
    display: flex;
    gap: 18px;
    padding: 18px 22px;
    min-width: 1040px;
    align-items: flex-start;
}

.fb-left {
    width: 380px;
    flex: none;
}

.fb-right {
    flex: 1;
    min-width: 0;
}

.fb-card {
    background: var(--bg2);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 16px;
    box-shadow: 0 1px 4px rgba(0, 0, 0, .3);
}

.fb-card-hd {
    font-weight: 600;
    font-size: 13px;
    margin-bottom: 12px;
    color: var(--text);
}

.fb-err {
    color: #ef4444;
    font-size: 12px;
    margin-bottom: 8px;
    min-height: 0;
}

.fb-form-row {
    margin-bottom: 10px;
}

.fb-form-row.fb-inline {
    display: flex;
    gap: 8px;
    align-items: flex-end;
}

.fb-field {
    flex: 1;
    min-width: 0;
}

.fb-lbl {
    display: block;
    font-size: 11px;
    color: var(--text3);
    margin-bottom: 3px;
    font-weight: 500;
}

.fb-lbl.req::after {
    content: " *";
    color: #ef4444;
}

.fb-textarea {
    resize: vertical;
    min-height: 60px;
    font-family: var(--font);
}

.fb-board-hd {
    font-weight: 600;
    font-size: 14px;
    margin-bottom: 10px;
    color: var(--text);
}

.fb-filter-bar {
    display: flex;
    gap: 4px;
    margin-bottom: 10px;
}

.fb-filter-tab {
    height: 30px;
    padding: 0 14px;
    border-radius: var(--radius);
    border: 1px solid var(--border2);
    background: var(--bg3);
    color: var(--text2);
    font-family: var(--font);
    font-size: 12px;
    cursor: pointer;
    transition: all .12s;
}

.fb-filter-tab:hover {
    background: var(--bg4);
    color: var(--text);
}

.fb-filter-tab.active {
    background: var(--accent-glow);
    border-color: var(--accent);
    color: var(--accent);
    font-weight: 600;
}

.fb-tbl-wrap {
    overflow-x: auto;
}

.fb-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 12px;
    min-width: 700px;
}

.fb-table thead th {
    background: var(--bg2);
    border-bottom: 2px solid var(--border);
    padding: 8px 8px;
    text-align: left;
    font-weight: 600;
    color: var(--text2);
    white-space: nowrap;
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: .03em;
    position: sticky;
    top: 0;
    z-index: 1;
}

.fb-table tbody tr {
    border-bottom: 1px solid var(--border);
    transition: background .1s;
}

.fb-table tbody tr:hover {
    background: var(--bg4);
}

.fb-table tbody tr.fb-row-click {
    cursor: pointer;
}

.fb-td {
    padding: 8px 8px;
    vertical-align: middle;
}

.fb-th-id,
.fb-td-id {
    width: 44px;
}

.fb-id-badge {
    display: inline-block;
    font-family: var(--font-mono);
    font-size: 11px;
    color: var(--text3);
    background: var(--bg3);
    padding: 1px 6px;
    border-radius: 4px;
}

.fb-th-title {
    min-width: 180px;
}

.fb-title-text {
    max-width: 300px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-weight: 500;
}

.fb-th-cat,
.fb-td-cat {
    width: 100px;
}

.fb-cat-badge {
    display: inline-block;
    font-size: 11px;
    padding: 2px 8px;
    border-radius: 4px;
    background: var(--bg3);
    color: var(--text2);
}

.fb-th-pri,
.fb-td-pri {
    width: 80px;
}

.fb-pri-badge {
    display: inline-block;
    font-size: 11px;
    padding: 2px 8px;
    border-radius: 4px;
    font-weight: 600;
}

.fb-pri-high {
    color: #ef4444;
    background: rgba(239, 68, 68, .12);
}

.fb-pri-med {
    color: #f59e0b;
    background: rgba(245, 158, 11, .12);
}

.fb-pri-low {
    color: #10b981;
    background: rgba(16, 185, 129, .12);
}

.fb-th-st,
.fb-td-st {
    width: 100px;
}

.fb-st-badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    font-size: 11px;
    padding: 2px 8px;
    border-radius: 4px;
    font-weight: 500;
}

.fb-st-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    flex: none;
}

.fb-th-by,
.fb-td-by,
.fb-th-as,
.fb-td-as {
    width: 130px;
    max-width: 130px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    color: var(--text2);
}

.fb-th-date,
.fb-td-date {
    width: 80px;
    white-space: nowrap;
    color: var(--text3);
    font-size: 11px;
    font-family: var(--font-mono);
}

.fb-th-actions,
.fb-td-actions {
    width: 70px;
    text-align: right;
}

.fb-action-btn {
    width: 26px;
    height: 26px;
    border: none;
    border-radius: 4px;
    background: var(--bg3);
    color: var(--text2);
    cursor: pointer;
    font-size: 13px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: all .12s;
    margin-left: 3px;
}

.fb-action-btn:hover {
    background: var(--bg4);
    color: var(--text);
}

.fb-del-btn:hover {
    background: rgba(239, 68, 68, .15);
    color: #ef4444;
}

.fb-empty {
    text-align: center;
    color: var(--text3);
    padding: 30px;
    font-size: 12px;
}

.fb-pagination {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 10px;
    justify-content: center;
}

.fb-page-info {
    font-size: 12px;
    color: var(--text3);
}

/* Modal */
.fb-modal-err {
    color: #ef4444;
    font-size: 12px;
    margin-bottom: 10px;
    min-height: 0;
}

.fb-form-grid {
    padding: 0 4px;
}

/* Assigned toggle */
.fb-assigned-toggle {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    margin-left: auto;
    font-size: 12px;
    color: var(--text2);
    cursor: pointer;
    white-space: nowrap;
    flex: none;
}
.fb-assigned-toggle input {
    margin: 0;
    cursor: pointer;
}

/* Counter badge */
.nav-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 18px;
    height: 18px;
    padding: 0 5px;
    border-radius: 9px;
    background: #ef4444;
    color: #fff;
    font-size: 10px;
    font-weight: 700;
    line-height: 1;
    margin-left: auto;
}
