/* ── Admin: Contracts tab (/admin/contracts) ─────────────────────────
   Builds on the shared admin table/modal styles in admin.css and the
   reg-* helpers reused across the registrations/contact-messages tabs. */

/* This page's UI copy is Hebrew - re-establish RTL inside the LTR-pinned
   .admin-main (same scoped-island pattern as the curriculum tree).
   LTR-sensitive values (phones, emails, IDs, links) keep their dir="ltr"
   attributes in the template. */
.ct-page {
    direction: rtl;
    text-align: right;
}

/* Mirror the search box adornments (admin.css positions them physically). */
.ct-page .admin-search .fa-search {
    left: auto;
    right: 10px;
}

.ct-page .search-clear {
    right: auto;
    left: 6px;
}

.ct-row {
    cursor: pointer;
}

.ct-col-created,
.ct-col-actions {
    white-space: nowrap;
}

/* Status pill */

.ct-status {
    display: inline-block;
    padding: 2px 10px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 600;
    white-space: nowrap;
}

.ct-status--pending {
    background: rgba(255, 163, 4, 0.14);
    color: #9A6B00;
}

.ct-status--signed {
    background: rgba(31, 157, 85, 0.12);
    color: #1F7A44;
}

.ct-status--cancelled {
    background: rgba(90, 91, 106, 0.12);
    color: #5A5B6A;
}

/* Signing-link validity, under the status pill. A pending link is only good
   for 12 days, so the list says when it runs out and turns warm once it has. */

.ct-link-expiry {
    margin-top: 4px;
    font-size: 11.5px;
    color: #8E8F9E;
    white-space: nowrap;
}

.ct-link-expiry--over {
    color: #B23C17;
    font-weight: 600;
}

/* Same warning, as an inline chip inside the detail table. */
.ct-detail-table .ct-link-expiry {
    display: inline-block;
    margin-top: 0;
    margin-inline-start: 6px;
}

/* Explainer above the link row in the detail modal. */
.ct-link-note {
    margin: 8px 0;
    font-size: 12.5px;
    line-height: 1.5;
    color: #5A5B6A;
}

.ct-link-note--over {
    padding: 8px 10px;
    border-radius: 8px;
    background: rgba(196, 85, 26, 0.08);
    color: #B23C17;
}

/* Course pill (mirrors contact-msg course pills) */

.ct-course-pill {
    display: inline-block;
    padding: 2px 10px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 600;
    white-space: nowrap;
    background: #EEF2F7;
    color: #5B6470;
}

.ct-course-pill--developer {
    background: #E8F0FE;
    color: #0071E3;
}

.ct-course-pill--architect {
    background: #F3E8FE;
    color: #8B34C9;
}

.ct-course-pill--bundle {
    background: #FFF4E0;
    color: #B06C00;
}

/* The ex-VAT legend (.exvat-legend, admin-money.css) sits between the filter
   bar and the table, explaining the short `(₪12,288)` under every amount in the
   מחיר column. Only the margins are local - the type and colour are shared with
   every other screen that prints the same parentheses. */
.ct-exvat-legend {
    margin: 0 0 6px;
}

/* Struck-through list price shown next to a discounted amount in the table. */
.ct-list-price {
    margin-inline-start: 6px;
    font-size: 11.5px;
    color: #8E8F9E;
    text-decoration: line-through;
    white-space: nowrap;
}


/* Create / edit modal */

.ct-modal {
    max-width: 640px;
    width: min(640px, calc(100vw - 32px));
}


/* Post-create panel (signing link handoff) */


.ct-created-panel__link-row {
    display: flex;
    gap: 8px;
    align-items: center;
}

.ct-created-panel__link {
    flex: 1;
    font-size: 12.5px;
    direction: ltr;
    text-align: left;
}


/* Detail modal */

.ct-detail-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 14px;
}

.ct-detail-name {
    font-size: 17px;
    font-weight: 600;
}

.ct-detail-table {
    width: 100%;
    margin-bottom: 6px;
}

.ct-signature-box {
    margin-top: 6px;
    padding: 10px;
    border: 1px solid #E8EEF8;
    border-radius: 10px;
    background: #FFFFFF;
    text-align: center;
}

.ct-signature-box img {
    max-width: 100%;
    max-height: 160px;
}

