/**
 * Controle factures Kwisatz — Styles
 *
 * @file        cc-kwisatz-controle-factures.css
 * @package     CaisseConnect
 * @subpackage  Caisses\Kwisatz\Assets\CSS
 * @since       0.98.2
 * @version     0.98.2
 */

/* === Carte dashboard « en attente » === */

.cc-carte-kwisatz-attente {
    border-left: 4px solid #e2a03f;
}

.cc-carte-kwisatz-attente .cc-carte-header h3 {
    display: flex;
    align-items: center;
    gap: 8px;
}

.cc-kwisatz-badge-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 22px;
    height: 22px;
    padding: 0 6px;
    border-radius: 11px;
    background: #e2a03f;
    color: #fff;
    font-size: 12px;
    font-weight: 600;
    line-height: 1;
}

.cc-table-kwisatz-attente .column-candidates {
    text-align: center;
    width: 120px;
}

.cc-table-kwisatz-attente .column-voir {
    width: 80px;
    text-align: center;
}

.cc-kwisatz-badge-candidates {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 20px;
    height: 20px;
    padding: 0 5px;
    border-radius: 10px;
    background: #0073aa;
    color: #fff;
    font-size: 11px;
    font-weight: 600;
}

.cc-kwisatz-badge-aucune {
    color: #999;
}

.cc-kwisatz-col-candidates {
    text-align: center;
}

/* === Metabox commande — bloc candidates === */

.cc-kwisatz-metabox-candidates {
    margin-top: 12px;
    border-top: 1px solid #e0e0e0;
    padding-top: 8px;
}

.cc-kwisatz-metabox-candidates > h3 {
    font-size: 13px;
    margin: 0 0 6px;
    cursor: pointer;
    user-select: none;
    display: flex;
    align-items: center;
    gap: 4px;
}

.cc-kwisatz-metabox-candidates > h3 .dashicons-arrow-right {
    transition: transform 0.2s;
    transform: rotate(90deg);
    font-size: 16px;
    width: 16px;
    height: 16px;
}

.cc-kwisatz-metabox-candidates > h3.collapsed .dashicons-arrow-right {
    transform: rotate(0);
}

.cc-kwisatz-candidates-container {
    display: none;
}

.cc-kwisatz-candidates-container.open {
    display: block;
}

.cc-kwisatz-metabox-detacher {
    margin-top: 8px;
}

.cc-kwisatz-table-candidates {
    font-size: 12px;
    table-layout: auto;
    border-collapse: collapse;
}

.cc-kwisatz-table-candidates.widefat td,
.cc-kwisatz-table-candidates.widefat th {
    padding: 3px 4px;
}

.cc-kwisatz-table-candidates th,
.cc-kwisatz-table-candidates td {
    padding: 3px 4px;
    border-right: 1px solid #e0e0e0;
}

.cc-kwisatz-table-candidates th:first-child,
.cc-kwisatz-table-candidates td:first-child {
    padding-left: 2px;
}

.cc-kwisatz-table-candidates th:last-child,
.cc-kwisatz-table-candidates td:last-child {
    border-right: none;
}

.cc-kwisatz-col-num {
    width: auto;
}

.cc-kwisatz-col-ref {
    width: 45px;
}

.cc-kwisatz-col-date {
    width: 65px;
}

.cc-kwisatz-aucune-candidate {
    color: #666;
    font-style: italic;
    margin: 4px 0;
}

/* === Badges candidates === */

.cc-kwisatz-badges {
    line-height: 1.6;
}

.cc-kwisatz-badge {
    display: inline-block;
    padding: 1px 4px;
    border-radius: 3px;
    font-size: 11px;
    font-weight: 500;
    white-space: nowrap;
}

.cc-kwisatz-badge--ref,
.cc-kwisatz-badge--nom,
.cc-kwisatz-badge--montant {
    background: #d4edda;
    color: #155724;
}

.cc-kwisatz-badge--ecart {
    background: #f8d7da;
    color: #721c24;
}

.cc-kwisatz-badge--rattachee {
    background: #fff3cd;
    color: #856404;
}

.cc-kwisatz-badge--detachee {
    background: #e2e3e5;
    color: #383d41;
}

/* === Actions === */

.cc-kwisatz-actions .button {
    margin: 1px 0;
}
