/* FiveM-Style Native Reference Theme */

.nativedb-layout {
    display: grid;
    grid-template-columns: 320px 1fr;
    gap: 0;
    height: calc(100vh - 120px);
    min-height: 560px;
    margin: 0;
    border: 1px solid #262933;
    border-radius: 6px;
    background: #111318;
    overflow: hidden;
}

@media (max-width: 850px) {
    .nativedb-layout {
        grid-template-columns: 1fr;
        height: auto;
    }
}

/* SIDEBAR */
.nativedb-sidebar {
    display: flex;
    flex-direction: column;
    border-right: 1px solid #262933;
    background: #14171f;
    overflow: hidden;
}

.nativedb-sidebar-top {
    padding: 10px;
    border-bottom: 1px solid #262933;
    background: #181b24;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.nativedb-search-input {
    width: 100%;
    background: #0d0f14;
    border: 1px solid #2d3342;
    color: #e5e9f0;
    padding: 7px 10px;
    border-radius: 4px;
    font-size: 0.82rem;
    outline: none;
    box-sizing: border-box;
    font-family: inherit;
}

.nativedb-search-input:focus {
    border-color: #4c78a8;
}

.nativedb-cat-select {
    width: 100%;
    background: #0d0f14;
    border: 1px solid #2d3342;
    color: #e5e9f0;
    padding: 5px 8px;
    border-radius: 4px;
    font-size: 0.78rem;
    outline: none;
    box-sizing: border-box;
    cursor: pointer;
}

.nativedb-count-bar {
    font-size: 0.72rem;
    color: #7b88a1;
    display: flex;
    justify-content: space-between;
    padding: 2px 2px 0 2px;
}

.nativedb-items-scroll {
    flex: 1;
    overflow-y: auto;
    padding: 4px 6px;
}

.nativedb-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 5px 8px;
    margin-bottom: 1px;
    border-radius: 3px;
    cursor: pointer;
    font-size: 0.78rem;
    font-family: monospace, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    color: #cdd4e0;
    transition: background 0.1s;
    user-select: none;
}

.nativedb-item:hover {
    background: #1e2330;
    color: #88c0d0;
}

.nativedb-item.active {
    background: #283042;
    color: #ffffff;
    font-weight: 600;
}

.nativedb-item-name {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    margin-right: 8px;
}

.nativedb-item-badge {
    font-size: 0.68rem;
    padding: 1px 5px;
    border-radius: 3px;
    background: #0d0f14;
    color: #7b88a1;
    flex-shrink: 0;
}

/* MAIN DETAIL PANE */
.nativedb-detail-pane {
    display: flex;
    flex-direction: column;
    overflow-y: auto;
    padding: 24px 28px;
    background: #111318;
    color: #d8dee9;
}

.nativedb-detail-header {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding-bottom: 14px;
    border-bottom: 1px solid #232733;
    margin-bottom: 18px;
}

.nativedb-title-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.nativedb-title {
    font-size: 1.25rem;
    font-weight: 700;
    font-family: monospace;
    color: #e5e9f0;
    margin: 0;
}

.nativedb-meta-tags {
    display: flex;
    align-items: center;
    gap: 6px;
}

.nativedb-tag {
    font-size: 0.72rem;
    padding: 2px 7px;
    border-radius: 3px;
    font-family: monospace;
    font-weight: 600;
}

.nativedb-tag-cat {
    background: #1e2330;
    color: #81a1c1;
    border: 1px solid #2e364a;
}

.nativedb-tag-ret {
    background: #1a2924;
    color: #a3be8c;
    border: 1px solid #2a4038;
}

.nativedb-tag-hash {
    background: #252219;
    color: #ebcb8b;
    border: 1px solid #423b28;
    cursor: pointer;
}

.nativedb-tag-hash:hover {
    border-color: #ebcb8b;
}

/* CODE SIGNATURE */
.nativedb-code-block {
    background: #090a0d;
    border: 1px solid #232733;
    border-radius: 5px;
    padding: 12px 16px;
    margin-bottom: 20px;
    position: relative;
}

.nativedb-code {
    font-family: monospace;
    font-size: 0.85rem;
    color: #e5e9f0;
    line-height: 1.45;
    margin: 0;
    white-space: pre-wrap;
}

.nativedb-copy-btn {
    position: absolute;
    top: 8px;
    right: 8px;
    background: #1e2330;
    border: 1px solid #2e364a;
    color: #cdd4e0;
    padding: 3px 8px;
    border-radius: 3px;
    font-size: 0.72rem;
    cursor: pointer;
    font-family: inherit;
}

.nativedb-copy-btn:hover {
    background: #3b4252;
    color: #fff;
}

/* SECTION TITLES */
.nativedb-section-header {
    font-size: 0.82rem;
    font-weight: 600;
    color: #81a1c1;
    margin: 16px 0 8px 0;
}

/* PARAMETERS LIST (FiveM Style) */
.nativedb-params-list {
    margin: 0 0 16px 0;
    padding: 0;
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.nativedb-param-item {
    display: flex;
    align-items: baseline;
    gap: 8px;
    font-size: 0.82rem;
    padding: 4px 8px;
    background: #161922;
    border-radius: 3px;
    border-left: 2px solid #5e81ac;
}

.nativedb-param-name {
    font-family: monospace;
    color: #88c0d0;
    font-weight: 600;
}

.nativedb-param-type {
    font-family: monospace;
    color: #b48ead;
    font-size: 0.78rem;
}

.nativedb-param-desc {
    color: #9aa5b8;
    font-size: 0.78rem;
}

/* RETURN VALUE BOX */
.nativedb-return-box {
    font-size: 0.82rem;
    padding: 6px 10px;
    background: #161922;
    border-radius: 3px;
    border-left: 2px solid #a3be8c;
    margin-bottom: 16px;
    color: #cdd4e0;
    font-family: monospace;
}
