.rlsp-page {
    --rlsp-accent: #ff7c18;
    --rlsp-accent-dark: #d95f08;
    --rlsp-ink: #152238;
    --rlsp-muted: #69778a;
    --rlsp-border: #e4eaf1;
    --rlsp-bg: #f5f7fb;
    min-height: 100%;
    padding: 22px;
    background: var(--rlsp-bg);
    color: var(--rlsp-ink);
}

.rlsp-loading,
.rlsp-alert,
.rlsp-card,
.rlsp-hero,
.rlsp-summary-card,
.rlsp-section-nav {
    background: #fff;
    border: 1px solid var(--rlsp-border);
    border-radius: 18px;
    box-shadow: 0 8px 26px rgba(18, 34, 56, .055);
}

.rlsp-loading {
    min-height: 260px;
    display: grid;
    place-items: center;
}

.rlsp-hero {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    padding: 20px 22px;
    margin-bottom: 14px;
}

.rlsp-hero-main,
.rlsp-hero-actions,
.rlsp-meta-row,
.rlsp-row-actions,
.rlsp-search-row,
.rlsp-inline-loading,
.rlsp-heading-badges,
.rlsp-request-actions {
    display: flex;
    align-items: center;
}

.rlsp-hero-main {
    gap: 15px;
    min-width: 0;
}

.rlsp-hero-actions {
    gap: 9px;
    flex-wrap: wrap;
    justify-content: flex-end;
}

.rlsp-meta-row {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    margin-top: 12px;
}

.rlsp-row-actions {
    gap: 7px;
    justify-content: center;
}

.rlsp-heading-badges {
    gap: 7px;
    flex-wrap: wrap;
}

.rlsp-request-actions {
    gap: 7px;
    justify-content: center;
}

.rlsp-inline-loading {
    justify-content: center;
    gap: 11px;
    padding: 28px;
    color: var(--rlsp-muted);
    font-weight: 700;
}

.rlsp-avatar-wrap {
    position: relative;
    width: 76px;
    height: 76px;
    flex: 0 0 auto;
}

.rlsp-avatar,
.rlsp-avatar-fallback {
    width: 76px;
    height: 76px;
    border-radius: 50%;
    border: 4px solid #fff;
    box-shadow: 0 0 0 2px rgba(255,124,24,.2), 0 10px 24px rgba(18,34,56,.11);
}

.rlsp-avatar {
    object-fit: cover;
}

.rlsp-avatar-fallback {
    place-items: center;
    background: #fff2e8;
    color: var(--rlsp-accent-dark);
    font-size: 23px;
    font-weight: 900;
}

.rlsp-online-dot {
    position: absolute;
    right: 2px;
    bottom: 4px;
    width: 15px;
    height: 15px;
    border-radius: 50%;
    background: #2eb872;
    border: 3px solid #fff;
}

.rlsp-eyebrow,
.rlsp-card-kicker {
    color: var(--rlsp-accent-dark);
    font-size: 11px;
    font-weight: 900;
    letter-spacing: .09em;
    text-transform: uppercase;
}

.rlsp-hero h1 {
    margin: 3px 0 0;
    font-size: 27px;
    line-height: 1.15;
}

.rlsp-meta-pill {
    min-height: 32px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 6px 11px;
    border: 1px solid #dde4ed;
    border-radius: 999px;
    background: #f7f9fc;
    color: #4d5d73;
    font-size: 12px;
    font-weight: 800;
    line-height: 1;
    white-space: nowrap;
}

    .rlsp-meta-pill .e-icons {
        color: #7b8797;
        font-size: 13px;
    }

.rlsp-meta-status {
    background: #edf9f3;
    border-color: #cdebdc;
    color: #19764e;
}

.rlsp-meta-status-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #24ad70;
    box-shadow: 0 0 0 3px rgba(36, 173, 112, .12);
}

.rlsp-meta-link {
    max-width: 260px;
    color: #465870;
    text-decoration: none;
    overflow: hidden;
    text-overflow: ellipsis;
}

    .rlsp-meta-link:hover {
        border-color: rgba(255, 124, 24, .4);
        background: #fff4eb;
        color: #d85e08;
    }

        .rlsp-meta-link:hover .e-icons {
            color: #d85e08;
        }

.rlsp-btn {
    min-height: 39px;
    border: 0;
    border-radius: 10px;
    padding: 0 14px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    font-weight: 800;
    cursor: pointer;
    transition: transform .15s ease, background .15s ease, border-color .15s ease;
}

    .rlsp-btn:hover {
        transform: translateY(-1px);
    }

    .rlsp-btn:disabled {
        opacity: .55;
        cursor: not-allowed;
        transform: none;
    }

.rlsp-btn-primary {
    background: var(--rlsp-accent);
    color: #fff;
    box-shadow: 0 8px 18px rgba(255,124,24,.22);
}

    .rlsp-btn-primary:hover {
        background: var(--rlsp-accent-dark);
    }

.rlsp-btn-light {
    background: #fff;
    color: var(--rlsp-ink);
    border: 1px solid var(--rlsp-border);
}

.rlsp-btn-small {
    min-height: 34px;
    padding: 0 12px;
}

.rlsp-summary-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
    margin-bottom: 14px;
}

.rlsp-summary-card {
    padding: 15px 16px;
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 0;
}

.rlsp-summary-icon {
    width: 40px;
    height: 40px;
    border-radius: 12px;
    display: grid;
    place-items: center;
    color: var(--rlsp-accent-dark);
    background: #fff2e8;
    flex: 0 0 auto;
}

.rlsp-summary-card span {
    display: block;
    color: var(--rlsp-muted);
    font-size: 12px;
    font-weight: 800;
}

.rlsp-summary-card strong {
    display: block;
    margin-top: 3px;
    font-size: 22px;
}

.rlsp-summary-card .rlsp-summary-text {
    font-size: 14px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.rlsp-section-nav {
    display: flex;
    gap: 6px;
    padding: 6px;
    margin-bottom: 14px;
    position: sticky;
    top: 8px;
    z-index: 10;
}

.rlsp-section-tab {
    min-height: 42px;
    padding: 0 15px;
    border: 0;
    border-radius: 12px;
    background: transparent;
    color: #5c6a7d;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-weight: 850;
    cursor: pointer;
}

    .rlsp-section-tab:hover {
        background: #f5f7fa;
        color: var(--rlsp-ink);
    }

    .rlsp-section-tab.is-active {
        background: #fff1e6;
        color: var(--rlsp-accent-dark);
    }

.rlsp-tab-count,
.rlsp-count-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 26px;
    min-height: 26px;
    padding: 0 8px;
    border-radius: 999px;
    background: #eef2f6;
    color: #4f5e73;
    font-size: 11px;
    font-weight: 900;
}

    .rlsp-tab-count.is-pending,
    .rlsp-count-badge.is-pending {
        background: #fff0d8;
        color: #a45d00;
    }

.rlsp-overview-layout {
    display: block;
}

.rlsp-requests-layout {
    display: grid;
    gap: 14px;
}

.rlsp-card {
    overflow: hidden;
}

.rlsp-card-header {
    padding: 17px 19px;
    border-bottom: 1px solid var(--rlsp-border);
}

    .rlsp-card-header h2 {
        margin: 4px 0 0;
        font-size: 18px;
    }

    .rlsp-card-header p {
        margin: 5px 0 0;
        color: var(--rlsp-muted);
        font-size: 13px;
    }

.rlsp-card-header-split {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
}

.rlsp-detail-list {
    padding: 7px 19px 14px;
}

.rlsp-detail-row {
    display: grid;
    grid-template-columns: 92px 1fr;
    gap: 11px;
    padding: 12px 0;
    border-bottom: 1px solid #eef2f6;
}

    .rlsp-detail-row:last-child {
        border-bottom: 0;
    }

    .rlsp-detail-row span {
        color: var(--rlsp-muted);
        font-size: 12px;
        font-weight: 750;
    }

    .rlsp-detail-row strong {
        font-size: 13px;
        word-break: break-word;
    }

.rlsp-table-wrap {
    overflow-x: auto;
}

.rlsp-empty-state {
    padding: 42px 20px;
    text-align: center;
}

    .rlsp-empty-state h3 {
        margin: 11px 0 4px;
        font-size: 17px;
    }

    .rlsp-empty-state p {
        margin: 0 auto 17px;
        color: var(--rlsp-muted);
        max-width: 420px;
    }

.rlsp-empty-icon {
    width: 52px;
    height: 52px;
    border-radius: 15px;
    margin: auto;
    display: grid;
    place-items: center;
    background: #fff2e8;
    color: var(--rlsp-accent-dark);
}

.rlsp-empty-compact {
    padding: 28px;
}

.rlsp-person-cell,
.rlsp-history-client {
    width: 100%;
    padding: 0;
    border: 0;
    background: transparent;
    color: inherit;
    display: flex;
    align-items: center;
    gap: 10px;
    text-align: left;
    cursor: pointer;
}

    .rlsp-person-cell strong,
    .rlsp-person-cell small,
    .rlsp-history-client strong,
    .rlsp-history-client small {
        display: block;
    }

    .rlsp-person-cell small,
    .rlsp-history-client small {
        margin-top: 2px;
        color: var(--rlsp-muted);
        font-size: 11px;
        font-weight: 700;
    }

.rlsp-client-mini-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    flex: 0 0 auto;
    background: #eef2f6;
    color: #435269;
    font-size: 11px;
    font-weight: 900;
}

.rlsp-status,
.rlsp-request-status,
.rlsp-history-event {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 5px 10px;
    border-radius: 999px;
    background: #eef2f6;
    color: #64748b;
    font-size: 11px;
    font-weight: 900;
    white-space: nowrap;
}

    .rlsp-status.is-active,
    .rlsp-request-status.is-approved,
    .rlsp-history-event.is-active {
        background: #e7f8ef;
        color: #177a50;
    }

    .rlsp-request-status.is-pending {
        background: #fff1d8;
        color: #9a5a00;
    }

    .rlsp-request-status.is-rejected,
    .rlsp-history-event.is-removed {
        background: #fff0f1;
        color: #b42e38;
    }

    .rlsp-history-event.is-returned {
        background: #eaf2ff;
        color: #2863b7;
    }

    .rlsp-history-event.is-withdrawn {
        background: #f3edff;
        color: #7246b7;
    }

.rlsp-icon-btn {
    width: 35px;
    height: 35px;
    display: grid;
    place-items: center;
    border-radius: 9px;
    border: 1px solid var(--rlsp-border);
    background: #fff;
    color: #435269;
    cursor: pointer;
}

    .rlsp-icon-btn:hover {
        border-color: rgba(255,124,24,.45);
        color: var(--rlsp-accent-dark);
    }

.rlsp-icon-btn-danger {
    color: #c23b43;
}

    .rlsp-icon-btn-danger:hover {
        border-color: #f3b7bb;
        background: #fff4f5;
        color: #a8232b;
    }

.rlsp-action-btn {
    min-height: 32px;
    padding: 0 11px;
    border-radius: 9px;
    border: 1px solid transparent;
    font-weight: 850;
    cursor: pointer;
}

    .rlsp-action-btn.is-approve {
        background: #eaf8f1;
        border-color: #bce6d1;
        color: #17784e;
    }

    .rlsp-action-btn.is-reject {
        background: #fff1f2;
        border-color: #f1c0c4;
        color: #ae2c36;
    }

.rlsp-reviewed-label {
    color: var(--rlsp-muted);
    font-size: 12px;
    font-weight: 750;
}

.rlsp-history-list {
    padding: 18px 20px 20px;
}

.rlsp-history-item {
    display: grid;
    grid-template-columns: 24px 1fr;
    gap: 12px;
    min-height: 112px;
}

.rlsp-history-line {
    position: relative;
    display: flex;
    justify-content: center;
}

.rlsp-history-dot {
    position: relative;
    z-index: 2;
    width: 13px;
    height: 13px;
    margin-top: 18px;
    border-radius: 50%;
    background: #aab4c1;
    box-shadow: 0 0 0 5px #eef2f6;
}

    .rlsp-history-dot.is-active {
        background: #25a66a;
        box-shadow: 0 0 0 5px #e7f8ef;
    }

    .rlsp-history-dot.is-returned {
        background: #3b7ddd;
        box-shadow: 0 0 0 5px #eaf2ff;
    }

    .rlsp-history-dot.is-withdrawn {
        background: #8154c8;
        box-shadow: 0 0 0 5px #f3edff;
    }

    .rlsp-history-dot.is-removed {
        background: #d64b55;
        box-shadow: 0 0 0 5px #fff0f1;
    }

.rlsp-history-rail {
    position: absolute;
    top: 31px;
    bottom: -8px;
    width: 2px;
    background: #e4e9ef;
}

.rlsp-history-item:last-child .rlsp-history-rail {
    display: none;
}

.rlsp-history-body {
    min-width: 0;
    padding: 12px 14px 14px;
    margin-bottom: 10px;
    border: 1px solid var(--rlsp-border);
    border-radius: 14px;
    background: #fff;
}

.rlsp-history-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 14px;
}

.rlsp-history-client {
    width: auto;
}

.rlsp-history-meta {
    display: flex;
    gap: 18px;
    flex-wrap: wrap;
    margin: 11px 0;
    color: var(--rlsp-muted);
    font-size: 12px;
}

.rlsp-history-reason {
    display: grid;
    grid-template-columns: 68px 1fr;
    gap: 10px;
    padding: 10px 12px;
    border-radius: 10px;
    background: #f7f9fc;
}

    .rlsp-history-reason span {
        color: var(--rlsp-muted);
        font-size: 12px;
        font-weight: 750;
    }

    .rlsp-history-reason strong {
        font-size: 12px;
    }

.rlsp-dialog-body {
    padding: 4px 2px 12px;
}

.rlsp-search-row {
    gap: 10px;
}

.rlsp-search-field {
    min-height: 44px;
    flex: 1;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 0 14px;
    border: 1px solid var(--rlsp-border);
    border-radius: 11px;
    background: #fff;
}

    .rlsp-search-field:focus-within {
        border-color: rgba(255,124,24,.65);
        box-shadow: 0 0 0 4px rgba(255,124,24,.1);
    }

    .rlsp-search-field input {
        width: 100%;
        border: 0;
        outline: 0;
        font: inherit;
    }

.rlsp-search-help {
    margin: 8px 0 16px;
    color: var(--rlsp-muted);
    font-size: 12px;
}

.rlsp-alert {
    padding: 14px 16px;
    margin-bottom: 14px;
    display: flex;
    gap: 8px;
    flex-direction: column;
}

.rlsp-alert-danger {
    border-color: #f1b7bb;
    background: #fff6f7;
    color: #9f2730;
}

.rlsp-alert-success {
    border-color: #b8e5cf;
    background: #f2fbf7;
    color: #18724c;
}

::deep .rlsp-grid.e-grid {
    border: 0 !important;
    border-radius: 0 !important;
    box-shadow: none !important;
}

::deep .rlsp-grid .e-gridheader {
    border-top: 0 !important;
}

::deep .rlsp-grid .e-headercell {
    background: #f7f9fc !important;
}

::deep .rlsp-grid .e-headercelldiv {
    font-size: 11px !important;
    letter-spacing: .045em;
}

::deep .rlsp-grid .e-rowcell {
    padding-top: 11px !important;
    padding-bottom: 11px !important;
}

::deep .rlsp-search-grid.e-grid {
    border: 1px solid var(--rlsp-border) !important;
    border-radius: 12px !important;
    overflow: hidden;
}

::deep .rlsp-assign-dialog .e-dlg-header-content {
    border-bottom: 1px solid var(--rlsp-border) !important;
}

::deep .rlsp-assign-dialog .e-dlg-header {
    font-weight: 900 !important;
}

::deep .rlsp-assign-dialog .e-dlg-content {
    padding: 18px !important;
}

@media (max-width: 1000px) {
    .rlsp-overview-layout {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 760px) {
    .rlsp-page {
        padding: 12px;
    }

    .rlsp-hero {
        align-items: flex-start;
        flex-direction: column;
    }

    .rlsp-hero-actions {
        width: 100%;
        justify-content: flex-start;
    }

    .rlsp-summary-grid {
        grid-template-columns: 1fr;
    }

    .rlsp-section-nav {
        overflow-x: auto;
        position: static;
    }

    .rlsp-section-tab {
        flex: 0 0 auto;
    }

    .rlsp-card-header-split,
    .rlsp-history-top {
        align-items: flex-start;
        flex-direction: column;
    }

    .rlsp-search-row {
        align-items: stretch;
        flex-direction: column;
    }

        .rlsp-search-row .rlsp-btn {
            width: 100%;
        }

    .rlsp-history-list {
        padding: 14px 12px;
    }

    .rlsp-history-item {
        grid-template-columns: 18px 1fr;
        gap: 9px;
    }

    .rlsp-history-reason {
        grid-template-columns: 1fr;
    }
}

/* Remove assignment dialog */
.rlsp-removal-summary {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 13px;
    margin-bottom: 16px;
    border: 1px solid var(--rlsp-border);
    border-radius: 13px;
    background: #f8fafc;
}

    .rlsp-removal-summary > div:last-child {
        min-width: 0;
    }

    .rlsp-removal-summary span,
    .rlsp-removal-summary strong,
    .rlsp-removal-summary small {
        display: block;
    }

    .rlsp-removal-summary span {
        color: var(--rlsp-muted);
        font-size: 11px;
        font-weight: 800;
        text-transform: uppercase;
        letter-spacing: .05em;
    }

    .rlsp-removal-summary strong {
        margin-top: 3px;
        color: var(--rlsp-ink);
        font-size: 15px;
    }

    .rlsp-removal-summary small {
        margin-top: 2px;
        color: var(--rlsp-muted);
        font-size: 12px;
    }

.rlsp-field-label {
    display: block;
    margin: 0 0 7px;
    color: #334155;
    font-size: 13px;
    font-weight: 850;
}

.rlsp-reason-input {
    box-sizing: border-box;
    width: 100%;
    min-height: 112px;
    resize: vertical;
    padding: 12px 13px;
    border: 1px solid var(--rlsp-border);
    border-radius: 11px;
    background: #fff;
    color: var(--rlsp-ink);
    outline: none;
    font: inherit;
    line-height: 1.45;
}

    .rlsp-reason-input:focus {
        border-color: rgba(255, 124, 24, .68);
        box-shadow: 0 0 0 4px rgba(255, 124, 24, .10);
    }

    .rlsp-reason-input::placeholder {
        color: #9aa6b5;
    }

.rlsp-field-help {
    margin-top: 7px;
    color: var(--rlsp-muted);
    font-size: 12px;
}

.rlsp-inline-error {
    margin-top: 12px;
    padding: 10px 12px;
    border: 1px solid #f2c0c4;
    border-radius: 10px;
    background: #fff4f5;
    color: #a92832;
    font-size: 12px;
    font-weight: 750;
}

.rlsp-dialog-actions {
    display: flex;
    justify-content: flex-end;
    gap: 9px;
    margin-top: 18px;
}

.rlsp-btn-danger {
    background: #c93642;
    color: #fff;
    box-shadow: 0 8px 18px rgba(201, 54, 66, .18);
}

    .rlsp-btn-danger:hover {
        background: #ab2833;
    }

::deep .rlsp-unassign-dialog .e-dlg-header-content {
    border-bottom: 1px solid var(--rlsp-border) !important;
}

::deep .rlsp-unassign-dialog .e-dlg-header {
    font-weight: 900 !important;
}

::deep .rlsp-unassign-dialog .e-dlg-content {
    padding: 18px !important;
}

@media (max-width: 560px) {
    .rlsp-dialog-actions {
        flex-direction: column-reverse;
    }

        .rlsp-dialog-actions .rlsp-btn {
            width: 100%;
        }
}


.rlsp-overview-layout .rlsp-clients-card {
    width: 100%;
}

@media (max-width: 900px) {
    .rlsp-meta-link {
        max-width: 210px;
    }
}

@media (max-width: 620px) {
    .rlsp-meta-row {
        align-items: flex-start;
    }

    .rlsp-meta-pill,
    .rlsp-meta-link {
        max-width: 100%;
    }
}


/* Request reviewer */
.rlsp-review-info {
    display: flex;
    align-items: flex-start;
    gap: 9px;
    min-width: 0;
}

.rlsp-review-avatar {
    width: 34px;
    height: 34px;
    flex: 0 0 auto;
    display: grid;
    place-items: center;
    border-radius: 50%;
    background: #eef2f6;
    color: #46566c;
    font-size: 10px;
    font-weight: 900;
}

.rlsp-review-content {
    min-width: 0;
}

    .rlsp-review-content strong,
    .rlsp-review-content span,
    .rlsp-review-content small {
        display: block;
    }

    .rlsp-review-content strong {
        color: #25344a;
        font-size: 12px;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .rlsp-review-content span {
        margin-top: 2px;
        color: var(--rlsp-muted);
        font-size: 11px;
        white-space: nowrap;
    }

    .rlsp-review-content small {
        max-width: 220px;
        margin-top: 4px;
        color: #7a8798;
        font-size: 10px;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

.rlsp-not-reviewed {
    color: #94a0af;
    font-size: 12px;
    font-weight: 700;
}
