/* authorities-panel.css — Phase 5.2.A
 * Factum form's Authority Library panel. Reuses al-* classes from
 * authority-library.css for typeahead + dropdown + base chip styles.
 * Adds factum-specific chip variants (suggested vs explicit) and the
 * Suggested-authorities chip with proposition popover.
 */

.ap-section { margin: 16px 0; }

.ap-help {
    font-size: 11px;
    color: var(--slate);
    margin-bottom: 4px;
}

/* Chip variants — extends .al-chip from authority-library.css */
.ap-chip {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 3px 4px 3px 10px;
    background: var(--cream);
    border: 1px solid var(--al-pane-border, var(--border));
    border-radius: 12px;
    font-size: 11px;
    color: var(--navy);
    user-select: none;
}
.ap-chip.suggested {
    background: var(--white);
    border-style: dashed;
    color: var(--slate);
}
.ap-chip.explicit {
    background: rgba(30, 64, 175, 0.10);
    border-color: #1e40af;
    color: #1e40af;
}
.ap-chip.curated {
    background: rgba(22, 163, 74, 0.08);
    border-color: #16a34a;
    color: #15803d;
}
.ap-chip.affirmed {
    background: rgba(22, 163, 74, 0.18);
    font-weight: 600;
}
.ap-chip.affirmed::before { content: "✓ "; }
.ap-legend {
    font-size: 10.5px;
    color: var(--slate);
    margin-top: 4px;
    line-height: 1.5;
}
.ap-chip-x {
    margin-left: 2px;
    width: 14px;
    height: 14px;
    border: none;
    background: none;
    cursor: pointer;
    color: inherit;
    font-size: 14px;
    line-height: 1;
    padding: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
}
.ap-chip-x:hover { background: rgba(0, 0, 0, 0.08); }

/* Suggested authorities chip — clickable, opens popover */
.ap-auth-chip {
    cursor: pointer;
}
.ap-auth-chip:hover {
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.08);
}

/* Popover above suggested-authorities chips */
.ap-popover {
    position: absolute;
    background: var(--white);
    border: 1px solid var(--al-pane-border, var(--border));
    border-radius: 4px;
    box-shadow: 0 8px 24px rgba(15, 26, 46, 0.12);
    padding: 12px;
    max-width: 420px;
    z-index: 9300;
    font-size: 12px;
    color: var(--navy);
}
.ap-popover .ap-pop-title {
    font-weight: 600;
    margin-bottom: 6px;
    font-size: 13px;
}
.ap-popover .ap-pop-sub {
    color: var(--slate);
    margin-bottom: 6px;
    font-size: 11px;
}
.ap-popover .ap-pop-block { margin-top: 8px; }
.ap-popover .ap-pop-label {
    font-size: 10px;
    text-transform: uppercase;
    letter-spacing: 0.4px;
    color: var(--slate);
    font-weight: 600;
    margin-bottom: 2px;
}

/* Status mini-spinner inline */
.ap-loading {
    display: inline-block;
    font-size: 11px;
    color: var(--slate);
    font-style: italic;
}
