/* API Workbench additions on top of SB Admin 2. */

/* SB Admin's auth images point at source.unsplash.com, which the CSP blocks; use bundled illustrations. */
.bg-login-image,
.bg-register-image,
.bg-password-image,
.bg-landing-image {
    background: #f8f9fc url("../sb-admin/img/undraw_rocket-P7HF_br.svg") center / 70% no-repeat;
}
.bg-register-image { background-image: url("../sb-admin/img/undraw_posting_photo-FGvghKm.svg"); }

.sidebar .nav-item .nav-link.disabled {
    opacity: .45;
    cursor: not-allowed;
}

.font-monospace, .text-monospace { font-family: SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace; }

pre.code-view {
    max-height: 32rem;
    overflow: auto;
    white-space: pre-wrap;
    word-break: break-all;
    background: #f8f9fc;
    border: 1px solid #e3e6f0;
    border-radius: .35rem;
    padding: .75rem;
    font-size: .8rem;
}

.method-badge { min-width: 4.2rem; display: inline-block; text-align: center; font-family: SFMono-Regular, Menlo, Consolas, monospace; }
.method-GET { background-color: #1cc88a; color: #fff; }
.method-POST { background-color: #f6c23e; color: #212529; }
.method-PUT { background-color: #4e73df; color: #fff; }
.method-PATCH { background-color: #6f42c1; color: #fff; }
.method-DELETE { background-color: #e74a3b; color: #fff; }
.method-HEAD, .method-OPTIONS { background-color: #858796; color: #fff; }

.is-loading { pointer-events: none; opacity: .7; }

/* ---------- Request Builder ---------- */
.builder .method-select { min-width: 7rem; }
.builder .url-field { min-width: 0; }
.builder .url-input,
.builder .url-highlight {
    font-size: .9rem;
    border-radius: 0;
    height: calc(1.5em + .75rem + 2px);
}
.builder .url-input {
    position: relative;
    background: transparent;
    color: transparent;
    caret-color: #3a3b45;
    z-index: 2;
}
.builder .url-input::placeholder { color: #b7b9cc; }
.builder .url-highlight {
    position: absolute;
    inset: 0;
    overflow: hidden;
    white-space: pre;
    color: #3a3b45;
    pointer-events: none;
    z-index: 1;
}
.builder .url-var { color: #e74a3b; background: #fdecea; border-radius: 3px; }
.builder .env-peek { position: absolute; right: 0; top: 100%; z-index: 20; width: 22rem; max-height: 18rem; overflow: auto; }
.builder .col-md-6.d-flex { position: relative; }
.builder .request-tab-strip { border-bottom: 0; }
.builder .request-tab-strip .nav-link { white-space: nowrap; }
.builder .kv-table td { padding: .15rem; }
.builder .tree { max-height: 70vh; overflow: auto; }
.builder .tree summary { cursor: pointer; list-style: none; }
.builder .tree-row { padding: .1rem .2rem; border-radius: .25rem; }
.builder .tree-row:hover { background: #f8f9fc; }
.builder li.dragging { opacity: .4; }
.builder .method-badge { min-width: 3.4rem; font-size: .65rem; }
.json-view .json-key { color: #224abe; }
.json-view .json-string { color: #13855c; }
.json-view .json-number { color: #be2617; }
.json-view .json-bool, .json-view .json-null { color: #6f42c1; font-weight: 600; }
.markdown-body img { max-width: 100%; }
