/* Admin feature-page primitives over the Obsidian palette. */

.adm-page {
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.adm-head {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.adm-head .eyebrow {
    font-size: 0.68rem;
    text-transform: uppercase;
    letter-spacing: 0.16em;
    color: var(--obs-accent, #2eb6b9);
    font-weight: 600;
}

.adm-head h1 {
    margin: 0;
    font-size: 1.6rem;
    font-weight: 700;
}

.adm-head .lede {
    margin: 0;
    color: var(--obs-text-dim, #8a8a96);
    font-size: 0.92rem;
}

/* KPI grid */
.adm-kpis {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
    gap: 14px;
}

/* Filter chips */
.adm-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.adm-chip {
    padding: 7px 14px;
    border-radius: 999px;
    border: 1px solid var(--obs-border, #26262e);
    background: transparent;
    color: var(--obs-text-dim, #b7b7c2);
    font-size: 0.82rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.12s ease;
}

.adm-chip:hover {
    color: var(--obs-text, #e9e9ee);
    border-color: var(--obs-text-dim, #555);
}

.adm-chip.is-active {
    background: rgba(46, 182, 185, 0.15);
    border-color: var(--obs-accent, #2eb6b9);
    color: var(--obs-accent, #2eb6b9);
}

/* Status pill */
.adm-pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 3px 10px;
    border-radius: 999px;
    font-size: 0.74rem;
    font-weight: 600;
    text-transform: capitalize;
    white-space: nowrap;
    border: 1px solid transparent;
}

.adm-pill.is-new { background: rgba(46, 182, 185, 0.14); color: #57d6d9; }
.adm-pill.is-accepted { background: rgba(120, 140, 255, 0.14); color: #9aa8ff; }
.adm-pill.is-paid { background: rgba(96, 200, 140, 0.14); color: #7fdca8; }
.adm-pill.is-prep { background: rgba(240, 190, 90, 0.14); color: #ecc66e; }
.adm-pill.is-out { background: rgba(150, 130, 255, 0.14); color: #b3a4ff; }
.adm-pill.is-done { background: rgba(96, 200, 140, 0.16); color: #7fdca8; }
.adm-pill.is-cancel { background: rgba(240, 110, 110, 0.14); color: #f08a8a; }
.adm-pill.is-neutral { background: rgba(255, 255, 255, 0.06); color: #b7b7c2; }

/* Inline action buttons */
.adm-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.adm-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 7px 13px;
    border-radius: 9px;
    border: 1px solid var(--obs-border, #26262e);
    background: transparent;
    color: var(--obs-text, #e9e9ee);
    font-size: 0.82rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.12s ease;
}

.adm-btn:hover:not(:disabled) { background: rgba(255, 255, 255, 0.05); }
.adm-btn:disabled { opacity: 0.45; cursor: not-allowed; }
.adm-btn--ok { border-color: rgba(96, 200, 140, 0.5); color: #7fdca8; }
.adm-btn--ok:hover:not(:disabled) { background: rgba(96, 200, 140, 0.12); }
.adm-btn--danger { border-color: rgba(240, 110, 110, 0.5); color: #f08a8a; }
.adm-btn--danger:hover:not(:disabled) { background: rgba(240, 110, 110, 0.12); }
.adm-btn--primary { border-color: var(--obs-accent, #2eb6b9); color: var(--obs-accent, #2eb6b9); }
.adm-btn--primary:hover:not(:disabled) { background: rgba(46, 182, 185, 0.12); }

/* Error / state banners */
.adm-state {
    display: grid;
    place-items: center;
    text-align: center;
    padding: 48px 16px;
    color: var(--obs-text-dim, #8a8a96);
    gap: 8px;
}

.adm-state i { font-size: 1.8rem; opacity: 0.6; }

.adm-state--error { color: #f08a8a; }

/* Drawer (verification / dispute detail) */
.adm-scrim {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.55);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.18s ease;
    z-index: 50;
}

.adm-scrim.is-open { opacity: 1; pointer-events: auto; }

.adm-drawer {
    position: fixed;
    inset: 0 0 0 auto;
    width: min(460px, 92vw);
    background: var(--obs-surface, #131318);
    border-left: 1px solid var(--obs-border, #26262e);
    transform: translateX(100%);
    transition: transform 0.2s ease;
    z-index: 51;
    display: flex;
    flex-direction: column;
}

.adm-drawer.is-open { transform: translateX(0); }

.adm-drawer__head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    padding: 18px 20px;
    border-bottom: 1px solid var(--obs-border, #26262e);
}

.adm-drawer__head h2 { margin: 4px 0 0; font-size: 1.15rem; }

.adm-drawer__eyebrow {
    font-size: 0.68rem;
    text-transform: uppercase;
    letter-spacing: 0.14em;
    color: var(--obs-accent, #2eb6b9);
}

.adm-drawer__close {
    background: none;
    border: 0;
    color: var(--obs-text-dim, #8a8a96);
    font-size: 1.1rem;
    cursor: pointer;
}

.adm-drawer__body {
    flex: 1;
    overflow-y: auto;
    padding: 18px 20px;
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.adm-drawer__actions {
    display: flex;
    gap: 10px;
    padding: 16px 20px;
    border-top: 1px solid var(--obs-border, #26262e);
}

.adm-section__label {
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: var(--obs-text-dim, #8a8a96);
    margin-bottom: 8px;
}

.adm-kv {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    padding: 5px 0;
    font-size: 0.86rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.04);
}

.adm-kv__k { color: var(--obs-text-dim, #8a8a96); }
.adm-kv__v { text-align: right; }

.adm-doc {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 10px;
    border: 1px solid var(--obs-border, #26262e);
    border-radius: 8px;
    margin-bottom: 6px;
    font-size: 0.84rem;
    text-decoration: none;
    color: var(--obs-text, #e9e9ee);
}

.adm-doc:hover { background: rgba(255, 255, 255, 0.04); }
.adm-doc i { color: var(--obs-accent, #2eb6b9); }

.adm-field {
    width: 100%;
    padding: 9px 11px;
    border-radius: 9px;
    border: 1px solid var(--obs-border, #26262e);
    background: var(--obs-bg, #0a0a0a);
    color: var(--obs-text, #e9e9ee);
    font-size: 0.86rem;
    font-family: inherit;
}

.adm-grid-id { font-family: "JetBrains Mono", monospace; font-size: 0.8rem; }
.adm-muted { color: var(--obs-text-dim, #8a8a96); }
.adm-strong { font-weight: 700; }
