﻿/* ============================================================
   ADMIN REVIEW PAGE
   ============================================================ */

:root {
    --primary: #6d28ff;
    --primary-light: #f0eaff;
    --primary-border: #ddd2ff;
    --text-dark: #101828;
    --text: #344054;
    --text-light: #667085;
    --border: #dfe5ee;
    --background: #f6f8fb;
    --white: #ffffff;
    --green: #00a63c;
    --green-light: #effcf3;
    --green-border: #8ee9ad;
    --orange: #d97706;
    --orange-light: #fff8e8;
    --orange-border: #ffd166;
    --red: #e60000;
}


/* ============================================================
   GLOBAL
   ============================================================ */

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    background: var(--background);
    color: var(--text);
    font-family: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    font-size: 14px;
}

a {
    color: inherit;
    text-decoration: none;
}

button,
textarea {
    font-family: inherit;
}


/* ============================================================
   TOP ADMIN BAR
   ============================================================ */

.admin-topbar {
    height: 50px;
    background: #fff;
    border-bottom: 1px solid #dce1e8;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 32px;
    position: sticky;
    top: 0;
    z-index: 100;
}

.admin-brand {
    display: flex;
    align-items: center;
    gap: 10px;
}

.brand-icon {
    width: 16px;
    height: 16px;
    color: var(--primary);
}

    .brand-icon svg {
        width: 100%;
        height: 100%;
        fill: none;
        stroke: currentColor;
        stroke-width: 2;
    }

.brand-name {
    font-size: 14px;
    font-weight: 700;
    color: #172033;
}

.brand-divider {
    width: 1px;
    height: 20px;
    background: #d9dee7;
    margin: 0 4px;
}

.admin-label {
    color: #64748b;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 1px;
}

.admin-user {
    display: flex;
    align-items: center;
    gap: 9px;
    color: #64748b;
    font-family: monospace;
    font-size: 13px;
}

.admin-avatar {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #eee8ff;
    color: var(--primary);
    font-size: 10px;
    font-weight: 700;
}


/* ============================================================
   BREADCRUMB
   ============================================================ */

.breadcrumb-bar {
    height: 44px;
    background: #fff;
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 0 32px;
    color: #60708a;
    font-size: 13px;
}

.back-link {
    display: flex;
    align-items: center;
    gap: 7px;
    color: var(--primary);
    font-weight: 500;
}

    .back-link svg {
        width: 15px;
        height: 15px;
        fill: none;
        stroke: currentColor;
        stroke-width: 2;
    }

.breadcrumb-separator {
    color: #c4ccd7;
}

.breadcrumb-current {
    color: #64748b;
}


/* ============================================================
   MAIN CONTAINER
   ============================================================ */

.admin-review-container {
    width: calc(100% - 60px);
    max-width: 1240px;
    margin: 20px auto 50px;
}


/* ============================================================
   CARD
   ============================================================ */

.card {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: 14px;
    box-shadow: 0 1px 2px rgba(16, 24, 40, 0.05), 0 2px 5px rgba(16, 24, 40, 0.03);
    overflow: hidden;
}


/* ============================================================
   APPLICATION HEADER
   ============================================================ */

.application-header {
    min-height: 90px;
    padding: 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 16px;
}

.application-heading {
    display: flex;
    align-items: center;
    gap: 16px;
}

.organization-icon {
    width: 48px;
    height: 48px;
    border-radius: 14px;
    background: #eee8ff;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary);
}

    .organization-icon svg {
        width: 23px;
        height: 23px;
        fill: none;
        stroke: currentColor;
        stroke-width: 1.7;
    }

.application-title-row {
    display: flex;
    align-items: center;
    gap: 10px;
}

    .application-title-row h1 {
        margin: 0;
        color: #101828;
        font-size: 18px;
        font-weight: 700;
    }

.status-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    border-radius: 7px;
    padding: 5px 9px;
    font-size: 12px;
    font-weight: 600;
}

    .status-badge.pending {
        color: #b45309;
        background: #fffaf0;
        border: 1px solid #f7ca66;
    }

.status-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    border: 1px solid currentColor;
}

.application-meta {
    margin-top: 8px;
    display: flex;
    align-items: center;
    gap: 9px;
    color: #64748b;
    font-family: monospace;
    font-size: 11px;
}

.application-type {
    display: flex;
    align-items: center;
    gap: 10px;
}

    .application-type span {
        color: #718096;
        font-size: 9px;
        font-weight: 700;
        letter-spacing: 1px;
    }

    .application-type strong {
        padding: 7px 11px;
        border: 1px solid #d8e0eb;
        border-radius: 6px;
        background: #f9fafb;
        color: #344054;
        font-size: 12px;
    }


/* ============================================================
   TWO COLUMN LAYOUT
   ============================================================ */

.review-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 304px;
    gap: 20px;
    align-items: start;
}

.review-main {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.review-sidebar {
    display: flex;
    flex-direction: column;
    gap: 16px;
    position: sticky;
    top: 70px;
}


/* ============================================================
   SECTION HEADER
   ============================================================ */

.section-header {
    height: 44px;
    padding: 0 20px;
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.section-title {
    display: flex;
    align-items: center;
    gap: 9px;
    color: #60708a;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 1px;
}

    .section-title svg {
        width: 15px;
        height: 15px;
        fill: none;
        stroke: currentColor;
        stroke-width: 1.7;
    }

.section-count {
    color: #64748b;
    font-family: monospace;
    font-size: 11px;
}


/* ============================================================
   INFORMATION CARDS
   ============================================================ */

.info-grid {
    display: grid;
    gap: 30px;
    padding: 23px 20px;
}

    .info-grid.three-columns {
        grid-template-columns: repeat(3, 1fr);
    }

    .info-grid.two-columns {
        grid-template-columns: repeat(2, 1fr);
        padding: 22px 20px 8px;
    }

.info-item {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.info-label {
    color: #60708a;
    font-size: 9px;
    font-weight: 700;
    letter-spacing: 1px;
}

.info-value {
    color: #172033;
    font-size: 14px;
}

.email-value {
    color: #172033;
}

.organization-content {
    padding-bottom: 22px;
}

.description-block {
    padding: 8px 20px 0;
}

    .description-block p {
        margin: 9px 0 0;
        color: #40516b;
        font-size: 14px;
        line-height: 1.7;
    }

.online-presence {
    padding: 20px 20px 0;
    display: flex;
    flex-direction: column;
    gap: 9px;
}

.social-link {
    display: flex;
    align-items: center;
    gap: 9px;
    width: fit-content;
    color: var(--primary);
    font-family: monospace;
    font-size: 12px;
}

.social-icon {
    width: 15px;
    text-align: center;
    font-family: Arial, sans-serif;
    font-weight: 700;
}


/* ============================================================
   DOCUMENTS
   ============================================================ */

.documents-list {
    padding: 10px 12px 12px;
}

.document-row {
    min-height: 62px;
    border: 1px solid #dce4ef;
    border-radius: 10px;
    margin: 0 0 8px;
    padding: 9px 14px;
    display: flex;
    align-items: center;
    gap: 12px;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

    .document-row:last-child {
        margin-bottom: 0;
    }

    .document-row:hover {
        border-color: #c8baff;
        box-shadow: 0 2px 6px rgba(109, 40, 255, 0.06);
    }

.document-icon {
    width: 36px;
    height: 36px;
    border: 1px solid #dbe3ee;
    border-radius: 9px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #3b82f6;
}

    .document-icon svg {
        width: 18px;
        height: 18px;
        fill: none;
        stroke: currentColor;
        stroke-width: 1.6;
    }

.document-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 3px;
}

    .document-info strong {
        color: #101828;
        font-size: 12px;
    }

    .document-info span {
        color: #64748b;
        font-family: monospace;
        font-size: 10px;
    }

.document-date {
    color: #64748b;
    font-family: monospace;
    font-size: 10px;
}

.view-document {
    height: 34px;
    padding: 0 12px;
    display: flex;
    align-items: center;
    gap: 6px;
    border: 1px solid #d9ceff;
    border-radius: 8px;
    color: var(--primary);
    font-size: 11px;
    font-weight: 600;
}

    .view-document:hover {
        background: #f7f4ff;
    }

    .view-document svg {
        width: 14px;
        height: 14px;
        fill: none;
        stroke: currentColor;
        stroke-width: 1.7;
    }


/* ============================================================
   VERIFICATION RESULTS
   ============================================================ */

.verification-summary-count {
    display: flex;
    gap: 7px;
    font-size: 11px;
}

.passed-count {
    color: var(--green);
    font-weight: 600;
}

.warning-count {
    color: #d97706;
    font-weight: 600;
}

.verification-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
    padding: 20px 12px;
}

.verification-box {
    min-height: 98px;
    border-radius: 10px;
    padding: 14px 16px;
    border: 1px solid;
}

    .verification-box.success {
        background: #f5fff8;
        border-color: #8ee9ad;
    }

    .verification-box.warning {
        background: #fffaf0;
        border-color: #ffd166;
    }

.verification-box-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.verification-name {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 12px;
    font-weight: 600;
    color: var(--green);
}

.warning .verification-name {
    color: #d97706;
}

.verification-icon {
    width: 16px;
    height: 16px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    font-size: 10px;
    border: 1.5px solid currentColor;
}

.verification-box p {
    margin: 10px 0 0;
    color: #61718a;
    font-size: 12px;
    line-height: 1.6;
}


/* ============================================================
   RISK FLAGS
   ============================================================ */

.risk-list {
    padding: 20px 12px;
}

.risk-item {
    border: 1px solid #dce4ef;
    border-radius: 10px;
    padding: 16px;
    margin-bottom: 12px;
}

    .risk-item:last-child {
        margin-bottom: 0;
    }

    .risk-item.unresolved {
        background: #fffdf8;
        border-color: #ffd166;
    }

    .risk-item.resolved {
        background: #fbfcfe;
    }

.risk-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 15px;
}

.risk-title {
    display: flex;
    align-items: center;
    gap: 9px;
}

    .risk-title strong {
        color: #172033;
        font-size: 14px;
    }

.risk-severity {
    padding: 4px 7px;
    border-radius: 4px;
    font-size: 10px;
}

    .risk-severity.low {
        background: #eef8ff;
        color: #2563eb;
        border: 1px solid #b8d9ff;
    }

    .risk-severity.medium {
        background: #fff7df;
        color: #d97706;
        border: 1px solid #ffd166;
    }

.risk-status {
    padding: 5px 9px;
    border-radius: 5px;
    font-size: 10px;
    font-weight: 600;
    white-space: nowrap;
}

.resolved-status {
    color: var(--green);
    background: #effcf3;
    border: 1px solid #9be6b5;
}

.manual-status {
    color: #b45309;
    background: #fff7e5;
    border: 1px solid #f6c75d;
}

.unresolved-status {
    color: #64748b;
    background: #f3f5f8;
    border: 1px solid #dce2ea;
}

.risk-item p {
    margin: 10px 0 0;
    color: #52637d;
    font-size: 13px;
    line-height: 1.65;
}


/* ============================================================
   HISTORY
   ============================================================ */

.timeline {
    padding: 20px 22px 24px;
}

.timeline-item {
    position: relative;
    display: grid;
    grid-template-columns: 40px minmax(0, 1fr);
    column-gap: 12px;
    min-height: 88px;
}

.timeline-number {
    width: 36px;
    height: 36px;
    border: 2px solid #dfe6ef;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #fff;
    color: #64748b;
    font-size: 12px;
    position: relative;
    z-index: 2;
}

.timeline-item:last-child .timeline-number {
    border-color: #bca8ff;
    background: #f4efff;
    color: var(--primary);
}

.timeline-line {
    position: absolute;
    left: 18px;
    top: 36px;
    bottom: 0;
    width: 1px;
    background: #dce3ed;
}

.timeline-item:last-child .timeline-line {
    display: none;
}

.timeline-content {
    padding-top: 2px;
    padding-bottom: 25px;
}

.timeline-heading {
    display: flex;
    justify-content: space-between;
    gap: 20px;
}

    .timeline-heading strong {
        color: #172033;
        font-size: 14px;
    }

    .timeline-heading time {
        color: #64748b;
        font-family: monospace;
        font-size: 10px;
        white-space: nowrap;
    }

.performed-by {
    margin-top: 5px;
    color: var(--primary);
    font-size: 11px;
}

.timeline-content p {
    margin: 7px 0 0;
    color: #64748b;
    font-size: 12px;
    line-height: 1.55;
}


/* ============================================================
   ADMIN DECISION
   ============================================================ */

.decision-content {
    padding: 20px;
}

.decision-form {
    display: flex;
    flex-direction: column;
}

    .decision-form label {
        margin-bottom: 8px;
        color: #60708a;
        font-size: 10px;
        font-weight: 700;
        letter-spacing: 1px;
    }

    .decision-form textarea {
        width: 100%;
        min-height: 104px;
        resize: vertical;
        padding: 13px 14px;
        border: 1px solid #d8e0eb;
        border-radius: 10px;
        outline: none;
        background: #fafbfd;
        color: #344054;
        font-size: 13px;
        margin-bottom: 14px;
    }

        .decision-form textarea::placeholder {
            color: #8290a5;
        }

        .decision-form textarea:focus {
            border-color: #bca8ff;
            box-shadow: 0 0 0 3px rgba(109, 40, 255, 0.08);
        }

.reject-form {
    margin-top: 14px;
}

.decision-button {
    height: 40px;
    border: 0;
    border-radius: 9px;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.12s ease, opacity 0.12s ease;
}

    .decision-button:hover {
        opacity: 0.92;
    }

    .decision-button:active {
        transform: scale(0.99);
    }

    .decision-button svg {
        width: 16px;
        height: 16px;
        fill: none;
        stroke: currentColor;
        stroke-width: 1.8;
    }

.approve-button {
    background: #00a63c;
}

.reject-button {
    background: #ed0000;
}


/* ============================================================
   SIDEBAR
   ============================================================ */

.confidence-card {
    padding: 20px;
    text-align: center;
}

.confidence-status {
    display: flex;
    justify-content: center;
    margin-bottom: 20px;
}

.confidence-circle {
    width: 102px;
    height: 102px;
    margin: 0 auto 15px;
    border-radius: 50%;
    background: conic-gradient( #16a34a 0deg, #16a34a calc((var(--confidence, 87) / 100) * 360deg), #dce8df calc((var(--confidence, 87) / 100) * 360deg), #dce8df 360deg );
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

    .confidence-circle::before {
        content: "";
        position: absolute;
        width: 84px;
        height: 84px;
        background: white;
        border-radius: 50%;
    }

.confidence-inner {
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
}

    .confidence-inner strong {
        color: #172033;
        font-size: 21px;
        line-height: 1;
    }

    .confidence-inner span {
        margin-top: 4px;
        color: #8290a5;
        font-size: 10px;
    }

.confidence-label {
    color: #60708a;
    font-size: 9px;
    font-weight: 700;
    letter-spacing: 1px;
}

.confidence-description {
    margin-top: 6px;
    color: #8290a5;
    font-size: 11px;
}

.sidebar-divider {
    height: 1px;
    background: var(--border);
    margin: 17px 0;
}

.decision-label {
    color: #60708a;
    font-size: 9px;
    font-weight: 700;
    letter-spacing: 1px;
}

.system-decision {
    margin-top: 7px;
    color: var(--green);
    font-size: 13px;
    font-weight: 700;
}


/* ============================================================
   SIDEBAR CARDS
   ============================================================ */

.sidebar-card {
    padding: 20px;
}

.sidebar-card-title {
    color: #60708a;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 1px;
    margin-bottom: 18px;
}

.summary-list,
.risk-summary-list,
.application-info-list {
    display: flex;
    flex-direction: column;
    gap: 13px;
}

    .summary-list > div,
    .risk-summary-list > div {
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 10px;
    }

    .summary-list span,
    .risk-summary-list span {
        color: #586981;
        font-size: 12px;
    }

    .summary-list strong,
    .risk-summary-list strong {
        font-size: 11px;
        white-space: nowrap;
    }

.summary-pass {
    color: var(--green);
}

.summary-status {
    color: #d97706;
}

.orange-text {
    color: #d97706;
}

.green-text {
    color: var(--green);
}

.application-info-list > div {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.application-info-list span {
    color: #718096;
    font-size: 8px;
    font-weight: 700;
    letter-spacing: 1px;
}

.application-info-list strong {
    color: #172033;
    font-size: 11px;
    font-weight: 500;
}


/* ============================================================
   EMPTY STATE
   ============================================================ */

.empty-state {
    padding: 28px 20px;
    text-align: center;
    color: #8290a5;
    font-size: 13px;
}


/* ============================================================
   RESPONSIVE
   ============================================================ */

@media (max-width: 1050px) {

    .review-layout {
        grid-template-columns: 1fr;
    }

    .review-sidebar {
        position: static;
        display: grid;
        grid-template-columns: repeat(2, 1fr);
    }

    .confidence-card {
        grid-column: span 2;
    }
}


@media (max-width: 750px) {

    .admin-topbar {
        padding: 0 16px;
    }

    .admin-label,
    .brand-divider,
    .admin-user > span {
        display: none;
    }

    .breadcrumb-bar {
        padding: 0 16px;
        overflow-x: auto;
        white-space: nowrap;
    }

    .admin-review-container {
        width: calc(100% - 24px);
        margin-top: 12px;
    }

    .application-header {
        align-items: flex-start;
        flex-direction: column;
        gap: 15px;
    }

    .application-type {
        align-self: flex-end;
    }

    .info-grid.three-columns,
    .info-grid.two-columns {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .verification-grid {
        grid-template-columns: 1fr;
    }

    .review-sidebar {
        grid-template-columns: 1fr;
    }

    .confidence-card {
        grid-column: auto;
    }

    .document-row {
        align-items: flex-start;
        flex-wrap: wrap;
    }

    .document-date {
        margin-left: 48px;
    }

    .view-document {
        margin-left: auto;
    }

    .risk-top {
        align-items: flex-start;
        flex-direction: column;
    }

    .timeline-heading {
        flex-direction: column;
        gap: 5px;
    }
}
