/* -- Global font -- */
body, .fi-body, .fi-main, .fi-topbar, .fi-sidebar,
p, span, div, h1, h2, h3, h4, h5, h6, a, button, input, select, textarea, label, td, th {
    font-family: "Inter", sans-serif !important;
}

/* -- Sidebar font (DM Sans) -- */
.fi-sidebar-item-button,
.fi-sidebar-group-label,
.fi-sidebar-header .fi-logo span,
.fi-sidebar-header .fi-logo div {
    font-family: "DM Sans", sans-serif !important;
}

/* -- Auth pages -- */
.fi-simple-layout {
    background: linear-gradient(135deg, #1e3a5f 0%, #0f2240 55%, #080e1a 100%) !important;
    position: relative;
}
.fi-simple-layout::before {
    content: "";
    position: absolute;
    inset: 0;
    background-image: radial-gradient(rgba(255,255,255,0.04) 1px, transparent 1px);
    background-size: 28px 28px;
    pointer-events: none;
}
.fi-simple-main {
    background: #ffffff !important;
    box-shadow: 0 32px 64px -12px rgba(0,0,0,0.55), 0 0 0 1px rgba(255,255,255,0.08) !important;
    border-radius: 1.25rem !important;
}
.fi-simple-layout .fi-logo { justify-content: center !important; }
.fi-simple-layout .fi-logo > div { justify-content: center !important; }
.fi-simple-header { align-items: center !important; text-align: center; }
.fi-simple-header-heading { text-align: center !important; }
.fi-simple-header-subheading { text-align: center !important; }

/* -- Sidebar -- */
.fi-sidebar {
    background-color: #f8fafc !important;
    border-right: 1px solid #e2e8f0 !important;
}
.fi-sidebar-header {
    background-color: #f8fafc !important;
    border-bottom: 1px solid #e2e8f0 !important;
    padding-top: 1rem !important;
    padding-bottom: 1rem !important;
}
.fi-sidebar-footer {
    background-color: #f8fafc !important;
    border-top: 1px solid #e2e8f0 !important;
}
.fi-sidebar-nav {
    padding-left: 0.75rem !important;
    padding-right: 0.75rem !important;
}

/* Group labels */
.fi-sidebar-group-label {
    color: #94a3b8 !important;
    font-size: 0.6rem !important;
    font-weight: 700 !important;
    letter-spacing: 0.15em !important;
    text-transform: uppercase !important;
    padding-left: 1rem !important;
}

/* Nav items */
.fi-sidebar-item-button {
    color: #334155 !important;
    border-radius: 0.5rem !important;
    font-size: 0.875rem !important;
    font-weight: 500 !important;
    transition: all 0.15s ease !important;
    position: relative !important;
}
.fi-sidebar-item-button svg {
    color: #64748b !important;
}
.fi-sidebar-item-button:hover {
    background-color: #ffffff !important;
    box-shadow: 0 1px 4px rgba(15,23,42,0.06), 0 1px 2px rgba(15,23,42,0.04) !important;
    color: #0f172a !important;
}
.fi-sidebar-item-button:hover svg {
    color: #2563eb !important;
}

/* Active nav item */
.fi-sidebar-item-button.fi-active,
.fi-sidebar-item-button[aria-current="page"] {
    background-color: #eff6ff !important;
    color: #2563eb !important;
    font-weight: 600 !important;
    border-left: 3px solid #2563eb !important;
    padding-left: calc(1rem - 3px) !important;
    border-radius: 0 0.5rem 0.5rem 0 !important;
}
.fi-sidebar-item-button.fi-active svg,
.fi-sidebar-item-button[aria-current="page"] svg {
    color: #2563eb !important;
}

/* Collapse toggle */
.fi-sidebar-close-btn svg,
.fi-icon-btn svg {
    color: #94a3b8 !important;
}

/* -- Topbar -- */
.fi-topbar {
    background-color: #ffffff !important;
    border-bottom: 1px solid #e2e8f0 !important;
    box-shadow: none !important;
}
.fi-topbar-breadcrumbs li,
.fi-topbar-breadcrumbs a {
    color: #94a3b8 !important;
    font-size: 0.8rem !important;
}
.fi-topbar-breadcrumbs li:last-child {
    color: #334155 !important;
    font-weight: 600 !important;
}

/* -- Main content background -- */
.fi-main {
    background-color: #f1f5f9 !important;
}

/* -- Panel Loading & Pending State Utilities -- */
.cursor-wait {
    cursor: wait !important;
}


#nprogress .bar,
.livewire-progress-bar {
    background-color: rgb(var(--primary-600)) !important;
    height: 3px !important;
}

#nprogress .peg {
    box-shadow: 0 0 10px rgb(var(--primary-600)), 0 0 5px rgb(var(--primary-600)) !important;
}

#nprogress .spinner-icon {
    border-top-color: rgb(var(--primary-600)) !important;
    border-left-color: rgb(var(--primary-600)) !important;
}

/* Table loading overlay smooth transition */
.fi-ta-loading {
    transition: opacity 0.2s ease-in-out;
}

/* -- Transactions Report: "Your reports" empty state -- */
.portal-reports-empty {
    color: #64748b;
    font-size: 0.875rem;
    text-align: center;
    padding: 1rem 0;
}

/* -- Transaction details modal -- */
.portal-modal-empty {
    color: #64748b;
    font-size: 0.875rem;
    text-align: center;
    padding: 1rem 0;
}

.portal-modal-sections {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

.portal-modal-section-title {
    color: #64748b;
    font-weight: 600;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    margin: 0 0 0.6rem;
}

.portal-modal-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.9rem 1.5rem;
}

.portal-modal-field {
    min-width: 0;
}

.portal-modal-label {
    color: #94a3b8;
    font-size: 0.75rem;
    margin: 0 0 0.15rem;
}

.portal-modal-value {
    color: #0f172a;
    font-size: 0.875rem;
    font-weight: 500;
    margin: 0;
    word-break: break-word;
}

@media (max-width: 480px) {
    .portal-modal-grid {
        grid-template-columns: 1fr;
    }
}

/* -- Transactions Report: "Your reports" table --
   Same visual language as the Search Transactions / Admin Users tables:
   uppercase muted header, 1px row dividers, subtle row hover. */
.portal-reports-table-wrap {
    width: 100%;
    overflow-x: auto;
    border: 1px solid #e2e8f0;
    border-radius: 0.5rem;
}

.portal-reports-table {
    width: 100%;
    min-width: 46rem;
    border-collapse: collapse;
    table-layout: fixed;
}

.portal-reports-table th,
.portal-reports-table td {
    padding: 14px 16px;
    vertical-align: middle;
    text-align: left;
}

.portal-reports-table thead th {
    color: #64748b;
    font-weight: 600;
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    background-color: #f8fafc;
    border-bottom: 1px solid #e2e8f0;
    white-space: nowrap;
}

.portal-reports-table tbody tr {
    height: 56px;
    border-bottom: 1px solid #e2e8f0;
}

.portal-reports-table tbody tr:last-child {
    border-bottom: none;
}

.portal-reports-table tbody tr:hover {
    background-color: #f8fafc;
}

.portal-reports-table tbody td {
    color: #0f172a;
    font-size: 0.875rem;
}

.portal-reports-table tbody .portal-reports-col-vendor,
.portal-reports-table tbody .portal-reports-col-filter,
.portal-reports-table tbody .portal-reports-col-records,
.portal-reports-table tbody .portal-reports-col-requested {
    color: #64748b;
}

.portal-reports-align-end {
    text-align: right;
}

.portal-reports-col-report {
    width: 28%;
}

.portal-reports-col-vendor,
.portal-reports-col-filter {
    width: 14%;
}

.portal-reports-col-records {
    width: 10%;
}

.portal-reports-col-requested {
    width: 16%;
}

.portal-reports-col-status {
    width: 10%;
}

.portal-reports-col-download {
    width: 8%;
}

.portal-report-cell-with-icon {
    display: flex;
    align-items: center;
    flex-wrap: nowrap;
    gap: 0.5rem;
    min-width: 0;
}

.portal-report-cell-with-icon > span {
    white-space: nowrap;
}

.portal-report-format-icon {
    flex-shrink: 0;
    width: 0.9rem;
    height: 0.9rem;
    color: #64748b;
}

.portal-report-format-icon svg {
    display: block;
    width: 100%;
    height: 100%;
}

.portal-report-row-failed-note {
    color: #b91c1c;
    font-size: 0.75rem;
    margin: 0.25rem 0 0;
}

@media (max-width: 768px) {
    .portal-reports-col-vendor,
    .portal-reports-col-filter {
        display: none;
    }
}

