:root {
    --slm-navy: #0f172a;
    --slm-navy-2: #111827;
    --slm-blue: #2563eb;
    --slm-blue-2: #1d4ed8;
    --slm-indigo: #4f46e5;
    --slm-purple: #7c3aed;
    --slm-teal: #0f766e;
    --slm-emerald: #10b981;
    --slm-amber: #f59e0b;
    --slm-red: #dc2626;
    --slm-slate: #64748b;
    --slm-slate-2: #475569;
    --slm-border: #e2e8f0;
    --slm-surface: #ffffff;
    --slm-muted-surface: #f8fafc;
    --slm-bg: #f1f5f9;
    --slm-bg-2: #eef2ff;
    --slm-shadow-sm: 0 1px 3px rgba(15, 23, 42, 0.08), 0 1px 2px rgba(15, 23, 42, 0.06);
    --slm-shadow: 0 12px 30px rgba(15, 23, 42, 0.08);
    --slm-shadow-lg: 0 24px 60px rgba(15, 23, 42, 0.16);
    --slm-radius: 10px;
    --slm-radius-lg: 16px;
    --slm-sidebar-width: 280px;
    --slm-sidebar-width-collapsed: 72px;
    --slm-topbar-height: 72px;
    --slm-topbar-height-mobile: 60px;
    --slm-tap-target-min: 44px;
}

* {
    box-sizing: border-box;
}

body {
    min-height: 100vh;
    font-family: "Inter", "Segoe UI", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
    background:
        radial-gradient(circle at top left, rgba(79, 70, 229, 0.08), transparent 32rem),
        radial-gradient(circle at top right, rgba(20, 184, 166, 0.08), transparent 28rem),
        var(--slm-bg);
    color: #1e293b;
    font-size: clamp(0.875rem, 2vw, 1rem);
    line-height: 1.6;
    overflow-x: hidden;
}

a {
    color: var(--slm-blue);
}

.loading-overlay {
    position: fixed;
    inset: 0;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #f8fafc, #eef2ff);
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.loading-overlay.hidden {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.loading-spinner {
    text-align: center;
}

.spinner-ring {
    width: 64px;
    height: 64px;
    border: 4px solid rgba(79, 70, 229, 0.2);
    border-top-color: var(--slm-indigo);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 1rem;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.loading-text {
    color: #475569;
    font-weight: 700;
    font-size: 0.95rem;
}

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 0.25rem 0.5rem;
    align-items: center;
    font-size: 0.9rem;
}

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

.breadcrumb-item.active {
    color: #0f172a;
    font-weight: 650;
}

.breadcrumb-item:not(.active)::after {
    content: "/";
    margin-left: 0.5rem;
    color: #cbd5e1;
}

/* Sticky bottom bar for mobile actions */
.mobile-actions-bar {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(12px);
    border-top: 1px solid var(--slm-border);
    padding: 0.75rem;
    display: none;
    gap: 0.5rem;
    z-index: 1020;
}

.mobile-actions-bar .btn {
    flex: 1;
}

@media (max-width: 767px) {
    .mobile-actions-bar {
        display: flex;
    }
    
    .app-main {
        padding-bottom: 80px;
    }
}

.app-shell {
    min-height: 100vh;
    display: flex;
}

/* Mobile-first: sidebar hidden by default, becomes fixed drawer on larger screens */
.app-sidebar {
    width: var(--slm-sidebar-width);
    height: 100vh;
    position: fixed;
    inset: 0 auto 0 0;
    z-index: 1040;
    background:
        linear-gradient(180deg, rgba(15, 23, 42, 0.98), rgba(17, 24, 39, 0.98)),
        radial-gradient(circle at top right, rgba(79, 70, 229, 0.28), transparent 18rem);
    color: #e5e7eb;
    border-right: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: 16px 0 40px rgba(15, 23, 42, 0.22);
    transition: transform 0.25s ease, width 0.25s ease;
    transform: translateX(-100%);
    overflow-y: scroll;
    overflow-x: hidden;
}

.app-sidebar.mobile-open {
    transform: translateX(0);
}

.app-sidebar-backdrop {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1035;
}

.app-sidebar-backdrop.active {
    display: block;
}

.sidebar-header {
    padding: 0.85rem 0.75rem 0.65rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.sidebar-brand {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    color: #ffffff;
    text-decoration: none;
    font-weight: 800;
    letter-spacing: -0.02em;
    font-size: 1rem;
}

.sidebar-brand-mark {
    width: 38px;
    height: 38px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    background: linear-gradient(135deg, var(--slm-indigo), var(--slm-teal));
    box-shadow: 0 10px 20px rgba(79, 70, 229, 0.35);
    flex-shrink: 0;
}

.sidebar-subtitle {
    margin: 0.35rem 0 0 2.6rem;
    color: #94a3b8;
    font-size: 0.72rem;
}

.sidebar-user {
    margin: 0.75rem 0.75rem;
    padding: 0.65rem;
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: var(--slm-radius-lg);
    background: rgba(255, 255, 255, 0.06);
}

.sidebar-user strong {
    display: block;
    color: #ffffff;
    font-size: 0.9rem;
    word-break: break-word;
}

.sidebar-user small {
    color: #cbd5e1;
    font-size: 0.8rem;
    word-break: break-all;
}

.sidebar-menu {
    padding: 0.5rem 0.5rem 1rem;
}

.sidebar-group-title {
    padding: 0.5rem 0.75rem 0.35rem;
    color: #94a3b8;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    font-size: 0.7rem;
    font-weight: 800;
}

.sidebar-link,
.sidebar-group-toggle {
    width: 100%;
    border: 0;
    color: #cbd5e1;
    background: transparent;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.65rem 0.85rem;
    border-radius: var(--slm-radius);
    text-decoration: none;
    font-weight: 650;
    font-size: 0.92rem;
    transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
    min-height: var(--slm-tap-target-min);
}

.sidebar-link:hover,
.sidebar-group-toggle:hover {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.08);
    transform: translateX(2px);
}

.sidebar-link.active,
.sidebar-group-toggle.active {
    color: #ffffff;
    background: linear-gradient(135deg, rgba(79, 70, 229, 0.95), rgba(15, 118, 110, 0.9));
    box-shadow: 0 8px 16px rgba(79, 70, 229, 0.24);
}

.sidebar-link i,
.sidebar-group-toggle i {
    width: 20px;
    text-align: center;
    flex-shrink: 0;
}

.sidebar-group-toggle {
    cursor: pointer;
}

.sidebar-chevron {
    margin-left: auto;
    transition: transform 0.2s ease;
    flex-shrink: 0;
}

.sidebar-group.open .sidebar-chevron {
    transform: rotate(90deg);
}

.sidebar-submenu {
    display: none;
    padding: 0.15rem 0 0.15rem 1.75rem;
}

.sidebar-group.open .sidebar-submenu {
    display: block;
}

.sidebar-submenu .sidebar-link {
    padding: 0.55rem 0.65rem;
    font-size: 0.88rem;
    color: #94a3b8;
    min-height: var(--slm-tap-target-min);
}

.sidebar-footer {
    margin: 0 0.75rem 0.75rem;
    padding: 0.7rem;
    border-radius: var(--slm-radius-lg);
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.14), rgba(79, 70, 229, 0.12));
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.sidebar-footer p {
    margin: 0;
    color: #cbd5e1;
    font-size: 0.82rem;
    line-height: 1.5;
}

.app-content {
    flex: 1;
    min-width: 0;
    margin-left: 0;
    transition: margin-left 0.25s ease;
    width: 100%;
}

.app-topbar {
    position: sticky;
    top: 0;
    z-index: 1030;
    min-height: var(--slm-topbar-height-mobile);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    padding: 0.65rem 1rem;
    background: rgba(248, 250, 252, 0.86);
    backdrop-filter: blur(18px);
    border-bottom: 1px solid rgba(226, 232, 240, 0.85);
}

.sidebar-toggle {
    width: 42px;
    height: 42px;
    border: 1px solid var(--slm-border);
    border-radius: 12px;
    background: #ffffff;
    color: var(--slm-slate-2);
    box-shadow: var(--slm-shadow-sm);
    min-width: var(--slm-tap-target-min);
    min-height: var(--slm-tap-target-min);
}

.topbar-title h5 {
    margin: 0;
    font-weight: 800;
    color: #0f172a;
    font-size: clamp(1rem, 2.5vw, 1.25rem);
}

.topbar-title p {
    margin: 0.15rem 0 0;
    color: var(--slm-slate);
    font-size: 0.84rem;
}

.topbar-actions {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.topbar-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    padding: 0.5rem 0.75rem;
    border-radius: 999px;
    background: #ffffff;
    border: 1px solid var(--slm-border);
    color: var(--slm-slate-2);
    font-size: 0.85rem;
    font-weight: 650;
    box-shadow: var(--slm-shadow-sm);
    min-height: var(--slm-tap-target-min);
}

.app-main {
    padding: 1rem;
    width: 100%;
}

.page-header {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 1rem;
    margin-bottom: 1rem;
}

.page-header > div:first-child {
    flex: 1;
}

.page-header .d-flex.gap-2,
.page-header .d-flex.gap-3 {
    flex-wrap: wrap;
    justify-content: center;
}

.page-header .d-flex.gap-2 > * {
    flex: 1 1 auto;
    min-width: 120px;
}

.page-title {
    margin: 0;
    color: #0f172a;
    font-weight: 850;
    letter-spacing: -0.03em;
    font-size: clamp(1.5rem, 4vw, 2.25rem);
}

.page-subtitle {
    margin: 0.35rem 0 0;
    color: var(--slm-slate);
    font-size: 0.95rem;
}

.fintech-card,
.card {
    border: 1px solid rgba(226, 232, 240, 0.9);
    border-radius: var(--slm-radius-lg);
    background: var(--slm-surface);
    box-shadow: var(--slm-shadow-sm);
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
    width: 100%;
}

.card {
    overflow: hidden;
}

.card:hover,
.fintech-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--slm-shadow);
    border-color: rgba(79, 70, 229, 0.18);
}

.card-header {
    border-bottom: 1px solid rgba(226, 232, 240, 0.9);
    background: rgba(248, 250, 252, 0.78);
    font-weight: 800;
    color: #0f172a;
}

.card-header-gradient {
    border: 0;
    color: #ffffff;
    background: linear-gradient(135deg, var(--slm-indigo), var(--slm-teal));
}

.card-body {
    padding: 1rem;
    width: 100%;
}

/* Mobile-first: single column on small screens, responsive grid on larger */
.metric-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.85rem;
    margin-bottom: 1rem;
}

.metric-card {
    position: relative;
    min-height: 140px;
    padding: 1rem;
    border-radius: var(--slm-radius-lg);
    border: 1px solid rgba(226, 232, 240, 0.9);
    background: linear-gradient(180deg, #ffffff, #f8fafc);
    box-shadow: var(--slm-shadow-sm);
    overflow: hidden;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    width: 100%;
}

.metric-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--slm-shadow);
}

.metric-card::after {
    content: "";
    position: absolute;
    right: -20px;
    top: -20px;
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: rgba(79, 70, 229, 0.08);
}

.metric-card .metric-icon {
    width: 42px;
    height: 42px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    color: #ffffff;
    box-shadow: 0 8px 16px rgba(15, 23, 42, 0.12);
    flex-shrink: 0;
}

.metric-label {
    margin: 0.7rem 0 0.25rem;
    color: var(--slm-slate);
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    font-weight: 800;
}

.metric-value {
    margin: 0;
    color: #0f172a;
    font-size: clamp(1.3rem, 3vw, 1.65rem);
    font-weight: 850;
    letter-spacing: -0.04em;
}

.metric-caption {
    margin: 0.35rem 0 0;
    color: var(--slm-slate);
    font-size: 0.84rem;
    line-height: 1.45;
}

.metric-card.blue {
    border-top: 4px solid var(--slm-blue);
}

.metric-card.green {
    border-top: 4px solid var(--slm-emerald);
}

.metric-card.amber {
    border-top: 4px solid var(--slm-amber);
}

.metric-card.red {
    border-top: 4px solid var(--slm-red);
}

.metric-card.purple {
    border-top: 4px solid var(--slm-purple);
}

.metric-card.teal {
    border-top: 4px solid var(--slm-teal);
}

.status-badge,
.badge {
    border-radius: 999px;
    padding: 0.45rem 0.7rem;
    font-size: 0.74rem;
    font-weight: 800;
    letter-spacing: 0.02em;
    white-space: nowrap;
}

.badge.bg-primary-subtle {
    color: var(--slm-blue);
    background: rgba(37, 99, 235, 0.12);
}

.badge.bg-danger-subtle {
    color: var(--slm-red);
    background: rgba(220, 38, 38, 0.12);
}

.badge.bg-warning-subtle {
    color: #b45309;
    background: rgba(245, 158, 11, 0.12);
}

.status-approved,
.badge-approved {
    color: #047857;
    background: #dcfce7;
}

.status-pending,
.badge-pending {
    color: #b45309;
    background: #fef3c7;
}

.status-rejected,
.badge-rejected {
    color: #b91c1c;
    background: #fee2e2;
}

.status-active,
.badge-active {
    color: #1d4ed8;
    background: #dbeafe;
}

.status-closed,
.badge-closed {
    color: #475569;
    background: #e2e8f0;
}

.status-paid,
.badge-paid {
    color: #047857;
    background: #d1fae5;
}

.status-overdue,
.badge-overdue {
    color: #b91c1c;
    background: #fee2e2;
}

.table-card .card-body {
    padding: 0;
}

.data-table-controls {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 0.75rem;
    padding: 1rem;
    border-bottom: 1px solid rgba(226, 232, 240, 0.9);
    background: rgba(248, 250, 252, 0.7);
}

.data-table-controls .d-flex.flex-wrap {
    gap: 0.5rem;
}

.data-table-search,
.data-table-filter,
.data-table-page-size {
    width: 100%;
    max-width: none;
}

.form-control,
.form-select {
    min-height: 46px;
    border: 1px solid var(--slm-border);
    border-radius: var(--slm-radius);
    padding: 0.65rem 0.85rem;
    color: #0f172a;
    background: #ffffff;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
    font-size: 1rem;
    width: 100%;
}

.form-control:focus,
.form-select:focus {
    border-color: rgba(79, 70, 229, 0.7);
    box-shadow: 0 0 0 4px rgba(79, 70, 229, 0.12);
}

/* Ensure select dropdowns have proper touch targets */
.form-select {
    padding: 0.75rem 0.85rem;
    background-size: 16px 16px;
}

.form-label {
    color: #334155;
    font-weight: 750;
    margin-bottom: 0.45rem;
    font-size: 0.95rem;
}

.form-text,
.help-text {
    color: var(--slm-slate);
    font-size: 0.85rem;
}

.invalid-feedback {
    color: var(--slm-red);
    font-size: 0.85rem;
    margin-top: 0.35rem;
}

.input-group-text {
    border-color: var(--slm-border);
    background: #f8fafc;
    color: var(--slm-slate);
    min-width: 44px;
    justify-content: center;
}

.input-group .form-control {
    border-left: 0;
}

.input-group .form-control:focus {
    border-left: 1px solid rgba(79, 70, 229, 0.7);
}

.input-group .input-group-text {
    border-right: 0;
}

.bg-purple {
    background-color: var(--slm-purple) !important;
}

.bg-teal {
    background-color: var(--slm-teal) !important;
}

.text-purple {
    color: var(--slm-purple) !important;
}

.text-teal {
    color: var(--slm-teal) !important;
}

.table {
    margin-bottom: 0;
    vertical-align: middle;
    width: 100%;
    max-width: 100%;
}

.table thead th {
    position: sticky;
    top: 0;
    z-index: 1;
    background: #f8fafc;
    color: #475569;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    font-weight: 850;
    border-bottom: 1px solid var(--slm-border);
    white-space: nowrap;
}

.table tbody tr {
    transition: background-color 0.18s ease;
}

.table tbody tr:nth-of-type(even) {
    background-color: rgba(248, 250, 252, 0.72);
}

.table tbody tr:hover {
    background-color: rgba(239, 246, 255, 0.9);
}

.table td {
    padding: 0.85rem 1rem;
    border-bottom: 1px solid rgba(226, 232, 240, 0.8);
    word-break: break-word;
}

/* Mobile-first: horizontal scrolling within table container */
.table-responsive {
    overflow-x: auto;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    width: 100%;
}

@media (min-width: 768px) {
    .table-responsive {
        max-height: 68vh;
    }
}

/* Prevent horizontal overflow at viewport level */
.table-responsive::-webkit-scrollbar {
    height: 6px;
}

.table-responsive::-webkit-scrollbar-track {
    background: rgba(226, 232, 240, 0.3);
}

.table-responsive::-webkit-scrollbar-thumb {
    background: rgba(100, 116, 139, 0.4);
    border-radius: 3px;
}

.table-pagination {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 0.75rem;
    padding: 1rem;
    border-top: 1px solid rgba(226, 232, 240, 0.9);
    background: rgba(248, 250, 252, 0.7);
}

.table-pagination .btn {
    min-width: var(--slm-tap-target-min);
    min-height: var(--slm-tap-target-min);
}

.table-pagination .btn-group {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.progress {
    height: 10px;
    border-radius: 999px;
    background: #e2e8f0;
    overflow: hidden;
    width: 100%;
}

.progress-bar {
    background: linear-gradient(90deg, var(--slm-blue), var(--slm-teal));
}

.chart-card {
    padding: 1rem;
    border: 1px solid rgba(226, 232, 240, 0.9);
    border-radius: var(--slm-radius-lg);
    background: #ffffff;
    box-shadow: var(--slm-shadow-sm);
    width: 100%;
}

.chart-title {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.5rem;
    margin-bottom: 0.9rem;
}

.chart-title h6 {
    margin: 0;
    color: #0f172a;
    font-weight: 850;
}

.chart-bar {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.35rem;
    margin: 0.75rem 0;
}

.chart-bar-label {
    color: var(--slm-slate);
    font-size: 0.88rem;
    font-weight: 700;
}

.chart-track {
    height: 12px;
    border-radius: 999px;
    background: #e2e8f0;
    overflow: hidden;
    width: 100%;
}

.chart-fill {
    height: 100%;
    border-radius: 999px;
    background: linear-gradient(90deg, var(--slm-blue), var(--slm-teal));
}

.chart-value {
    color: #0f172a;
    font-size: 0.88rem;
    font-weight: 800;
    text-align: left;
}

.action-card {
    display: grid;
    gap: 0.75rem;
    width: 100%;
}

.action-tile {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    padding: 1rem;
    border: 1px solid var(--slm-border);
    border-radius: var(--slm-radius-lg);
    background: linear-gradient(135deg, #ffffff, #f8fafc);
    color: #0f172a;
    text-decoration: none;
    box-shadow: var(--slm-shadow-sm);
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
    min-height: var(--slm-tap-target-min);
}

.action-tile:hover {
    transform: translateY(-3px);
    box-shadow: var(--slm-shadow);
    border-color: rgba(79, 70, 229, 0.25);
    color: #0f172a;
}

.action-tile-icon {
    width: 44px;
    height: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    color: #ffffff;
    background: linear-gradient(135deg, var(--slm-indigo), var(--slm-teal));
    flex-shrink: 0;
}

.btn {
    border-radius: var(--slm-radius);
    padding: 0.7rem 1rem;
    font-weight: 750;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
    min-height: var(--slm-tap-target-min);
    min-width: var(--slm-tap-target-min);
}

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

.btn-primary {
    border: 0;
    background: linear-gradient(135deg, var(--slm-blue), var(--slm-indigo));
    box-shadow: 0 10px 24px rgba(37, 99, 235, 0.22);
}

.btn-primary:hover {
    background: linear-gradient(135deg, var(--slm-indigo), var(--slm-purple));
    box-shadow: 0 14px 30px rgba(79, 70, 229, 0.26);
}

.btn-success {
    border: 0;
    background: linear-gradient(135deg, var(--slm-emerald), var(--slm-teal));
    box-shadow: 0 10px 24px rgba(16, 185, 129, 0.18);
}

.btn-danger {
    border: 0;
    background: linear-gradient(135deg, var(--slm-red), #ef4444);
    box-shadow: 0 10px 24px rgba(220, 38, 38, 0.18);
}

.btn-warning {
    border: 0;
    background: linear-gradient(135deg, #f59e0b, #d97706);
    color: #ffffff;
}

.btn-info {
    border: 0;
    background: linear-gradient(135deg, #0ea5e9, var(--slm-blue));
    color: #ffffff;
}

.btn-outline-primary {
    color: var(--slm-blue);
    border-color: rgba(37, 99, 235, 0.28);
}

.btn-outline-primary:hover {
    color: #ffffff;
    background: var(--slm-blue);
    border-color: var(--slm-blue);
}

.section-card {
    padding: 1rem;
    border: 1px solid rgba(226, 232, 240, 0.9);
    border-radius: var(--slm-radius-lg);
    background: linear-gradient(135deg, #ffffff, #f8fafc);
    box-shadow: var(--slm-shadow-sm);
    width: 100%;
}

.section-title {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    margin-bottom: 1rem;
    color: #0f172a;
    font-weight: 850;
}

.section-icon {
    width: 36px;
    height: 36px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    color: #ffffff;
    background: linear-gradient(135deg, var(--slm-indigo), var(--slm-teal));
}

.profile-avatar,
.borrower-avatar {
    width: 96px;
    height: 96px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 24px;
    background: linear-gradient(135deg, rgba(37, 99, 235, 0.12), rgba(15, 118, 110, 0.12));
    color: var(--slm-blue);
    flex-shrink: 0;
}

.avatar-img {
    width: 96px;
    height: 96px;
    object-fit: cover;
    border-radius: 24px;
    border: 3px solid #ffffff;
    box-shadow: var(--slm-shadow);
}

/* Mobile-first: single column on small screens */
.detail-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1rem;
}

.detail-item {
    padding: 1rem;
    border: 1px solid var(--slm-border);
    border-radius: var(--slm-radius-lg);
    background: #ffffff;
}

.detail-label {
    margin: 0 0 0.25rem;
    color: var(--slm-slate);
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    font-weight: 800;
}

.detail-value {
    margin: 0;
    color: #0f172a;
    font-weight: 800;
    font-size: 1.05rem;
}

.auth-layout,
.landing-layout {
    background:
        radial-gradient(circle at 10% 10%, rgba(79, 70, 229, 0.16), transparent 32rem),
        radial-gradient(circle at 90% 20%, rgba(20, 184, 166, 0.12), transparent 30rem),
        linear-gradient(135deg, #f8fafc 0%, #eef2ff 52%, #ecfeff 100%);
    overflow-x: hidden;
}

.auth-layout .app-sidebar,
.auth-layout .app-topbar,
.landing-layout .app-sidebar,
.landing-layout .app-topbar {
    display: none;
}

.auth-layout .app-content,
.landing-layout .app-content {
    margin-left: 0;
}

.auth-main,
.landing-main {
    padding: 0;
    min-height: 100vh;
}

.auth-main {
    display: grid;
    place-items: center;
    padding: 1rem;
    width: 100%;
}

.auth-page-shell {
    width: 100%;
    max-width: 1120px;
}

/* Mobile-first: single column on small screens */
.auth-card,
.registration-card {
    border: 1px solid rgba(226, 232, 240, 0.95);
    border-radius: 24px;
    background: rgba(255, 255, 255, 0.96);
    box-shadow: var(--slm-shadow-lg);
    overflow: hidden;
    display: grid;
    grid-template-columns: 1fr;
    min-height: 520px;
    width: 100%;
}

.auth-visual {
    position: relative;
    padding: 1.5rem;
    color: #ffffff;
    overflow: hidden;
    background:
        radial-gradient(circle at 20% 15%, rgba(255, 255, 255, 0.22), transparent 16rem),
        radial-gradient(circle at 80% 85%, rgba(15, 118, 110, 0.36), transparent 18rem),
        linear-gradient(135deg, var(--slm-indigo), var(--slm-purple) 55%, var(--slm-teal));
}

.auth-visual::before,
.auth-visual::after {
    content: "";
    position: absolute;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.08);
}

.auth-visual::before {
    width: 180px;
    height: 180px;
    right: -50px;
    top: 60px;
}

.auth-visual::after {
    width: 140px;
    height: 140px;
    left: -30px;
    bottom: 80px;
}

.auth-visual-content {
    position: relative;
    z-index: 1;
    min-height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.auth-visual .auth-brand,
.auth-visual .auth-brand-mark {
    color: #ffffff;
}

.auth-visual .auth-brand-mark {
    background: rgba(255, 255, 255, 0.18);
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.18);
}

.landing-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.45rem 0.75rem;
    border-radius: 999px;
    background: rgba(79, 70, 229, 0.08);
    color: var(--slm-indigo);
    font-size: 0.8rem;
    font-weight: 850;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    margin-bottom: 1rem;
}

.landing-title {
    max-width: 760px;
    margin: 0;
    color: #0f172a;
    font-size: clamp(1.75rem, 5vw, 2.75rem);
    font-weight: 900;
    line-height: 1.1;
    letter-spacing: -0.05em;
}

.landing-subtitle {
    max-width: 680px;
    margin: 1rem 0 0;
    color: #475569;
    font-size: clamp(0.95rem, 2vw, 1.15rem);
    line-height: 1.7;
}

.landing-actions {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    margin-top: 1.5rem;
}

.landing-actions .btn {
    width: 100%;
}

.landing-hero-proof {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    margin-top: 1.5rem;
}

.auth-form-panel {
    padding: 1.25rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(248, 250, 252, 0.98));
}

.auth-form-heading {
    margin-bottom: 0.35rem;
    color: #0f172a;
    font-weight: 850;
    letter-spacing: -0.04em;
    font-size: 1.5rem;
}

.auth-form-subtitle {
    margin-bottom: 1.25rem;
    color: var(--slm-slate);
    font-size: 0.95rem;
}

.field-group {
    margin-bottom: 1rem;
}

.input-with-icon {
    display: flex;
    align-items: stretch;
    border: 1px solid var(--slm-border);
    border-radius: var(--slm-radius-lg);
    background: #ffffff;
    overflow: hidden;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.input-with-icon:focus-within {
    border-color: rgba(79, 70, 229, 0.7);
    box-shadow: 0 0 0 4px rgba(79, 70, 229, 0.12);
}

.input-icon {
    width: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--slm-slate);
    background: #f8fafc;
    border-right: 1px solid var(--slm-border);
    flex-shrink: 0;
}

.input-with-icon .form-control {
    border: 0;
    border-left: 0;
    border-radius: 0;
    box-shadow: none;
    min-height: 48px;
    font-size: 1rem;
}

.btn-auth {
    width: 100%;
    min-height: 48px;
    border: 0;
    border-radius: var(--slm-radius-lg);
    background: linear-gradient(135deg, var(--slm-indigo), var(--slm-teal));
    box-shadow: 0 12px 24px rgba(79, 70, 229, 0.2);
}

.btn-auth:hover {
    background: linear-gradient(135deg, var(--slm-purple), var(--slm-indigo));
    box-shadow: 0 18px 38px rgba(79, 70, 229, 0.3);
    color: #ffffff;
}

.auth-switch,
.auth-footer-link {
    color: var(--slm-slate);
    text-decoration: none;
    font-weight: 700;
}

.auth-switch a,
.auth-footer-link {
    color: var(--slm-indigo);
}

.auth-switch a:hover,
.auth-footer-link:hover {
    color: var(--slm-purple);
}

.auth-error-list {
    padding: 0.9rem 1rem;
    margin-bottom: 1.25rem;
}

.auth-error-list ul {
    margin: 0;
    padding-left: 1.2rem;
}

.landing-main {
    background:
        radial-gradient(circle at 10% 15%, rgba(79, 70, 229, 0.14), transparent 34rem),
        radial-gradient(circle at 88% 12%, rgba(20, 184, 166, 0.12), transparent 30rem),
        linear-gradient(135deg, #f8fafc 0%, #eef2ff 48%, #ecfeff 100%);
}

.landing-hero {
    position: relative;
    overflow: hidden;
    padding: clamp(2.5rem, 6vw, 4rem) 0;
}

.landing-hero::before {
    content: "";
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(79, 70, 229, 0.05) 1px, transparent 1px),
        linear-gradient(90deg, rgba(79, 70, 229, 0.05) 1px, transparent 1px);
    background-size: 42px 42px;
    mask-image: linear-gradient(to bottom, rgba(0, 0, 0, 0.8), transparent 78%);
}

.landing-hero-content {
    position: relative;
    z-index: 1;
}

/* Mobile-first: stacked on small screens */
.landing-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
    align-items: center;
}

.landing-logo {
    width: 76px;
    height: 76px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 24px;
    color: #ffffff;
    background: linear-gradient(135deg, var(--slm-indigo), var(--slm-teal));
    box-shadow: 0 18px 40px rgba(79, 70, 229, 0.28);
    font-size: 2rem;
    margin-bottom: 1.5rem;
}

.landing-title {
    max-width: 760px;
    margin: 0;
    color: #0f172a;
    font-size: clamp(1.75rem, 5vw, 2.75rem);
    font-weight: 900;
    line-height: 1.1;
    letter-spacing: -0.05em;
}

.landing-subtitle {
    max-width: 680px;
    margin: 1rem 0 0;
    color: var(--slm-slate);
    font-size: clamp(0.95rem, 2vw, 1.15rem);
    line-height: 1.7;
}

.landing-actions {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    margin-top: 1.5rem;
}

.landing-actions .btn {
    width: 100%;
}

.landing-panel {
    border: 1px solid rgba(226, 232, 240, 0.95);
    border-radius: 28px;
    background: rgba(255, 255, 255, 0.86);
    box-shadow: var(--slm-shadow-lg);
    backdrop-filter: blur(16px);
    overflow: hidden;
}

.landing-panel-header {
    padding: 1.25rem 1.35rem;
    border-bottom: 1px solid rgba(226, 232, 240, 0.9);
    background: rgba(248, 250, 252, 0.86);
}

.landing-panel-header h3 {
    margin: 0;
    color: #0f172a;
    font-weight: 850;
    letter-spacing: -0.03em;
}

.landing-panel-header p {
    margin: 0.3rem 0 0;
    color: var(--slm-slate);
}

.landing-panel-body {
    padding: 1.25rem;
}

.landing-feature {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    padding: 1rem;
    border: 1px solid var(--slm-border);
    border-radius: var(--slm-radius-lg);
    background: linear-gradient(135deg, #ffffff, #f8fafc);
    box-shadow: var(--slm-shadow-sm);
    margin-bottom: 0.85rem;
}

.landing-feature:last-child {
    margin-bottom: 0;
}

.landing-feature-icon {
    flex: 0 0 auto;
    width: 46px;
    height: 46px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 15px;
    color: #ffffff;
    background: linear-gradient(135deg, var(--slm-indigo), var(--slm-teal));
}

.landing-feature strong {
    display: block;
    margin-bottom: 0.25rem;
    color: #0f172a;
    font-weight: 850;
}

.landing-feature p {
    margin: 0;
    color: var(--slm-slate);
    line-height: 1.6;
}

.landing-metrics {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1rem;
}

.landing-metric {
    padding: 1rem;
    border-radius: var(--slm-radius-lg);
    background: linear-gradient(180deg, #ffffff, #f8fafc);
    border: 1px solid var(--slm-border);
    box-shadow: var(--slm-shadow-sm);
    width: 100%;
}

.landing-metric-number {
    display: block;
    margin-bottom: 0.2rem;
    color: #0f172a;
    font-size: 1.5rem;
    font-weight: 850;
    letter-spacing: -0.04em;
}

.landing-metric-label {
    color: var(--slm-slate);
    font-size: 0.8rem;
    font-weight: 750;
}

/* Desktop two-column landing grid */
@media (min-width: 1025px) {
    .landing-grid {
        grid-template-columns: minmax(0, 1.02fr) minmax(380px, 0.98fr);
    }
    
    .landing-actions {
        flex-direction: row;
    }
    
    .landing-actions .btn {
        width: auto;
    }
}

@media (prefers-reduced-motion: reduce) {
    .auth-card,
    .landing-panel,
    .landing-feature,
    .landing-metric,
    .service-card,
    .product-card,
    .testimonial-card,
    .step-card,
    .benefit-card,
    .reveal {
        transition: none;
        animation: none;
    }
}

html {
    scroll-behavior: smooth;
}

.landing-layout {
    overflow-x: hidden;
}

.landing-nav {
    position: sticky;
    top: 0;
    z-index: 1020;
    border-bottom: 1px solid rgba(226, 232, 240, 0.8);
    background: rgba(255, 255, 255, 0.82);
    backdrop-filter: blur(18px);
}

.landing-nav-inner {
    min-height: 64px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
}

.nav-brand {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    color: #0f172a;
    font-weight: 850;
    text-decoration: none;
    letter-spacing: -0.03em;
}

.nav-brand-mark {
    width: 40px;
    height: 40px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    color: #ffffff;
    background: linear-gradient(135deg, var(--slm-indigo), var(--slm-teal));
}

.nav-menu {
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 0.25rem;
    margin: 0;
    padding: 0;
    list-style: none;
    position: absolute;
    left: 1rem;
    right: 1rem;
    top: calc(100% + 0.5rem);
    padding: 0.75rem;
    border: 1px solid rgba(226, 232, 240, 0.95);
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.96);
    box-shadow: var(--slm-shadow-lg);
    z-index: 1020;
}

.nav-menu.open {
    display: flex;
}

.nav-menu a {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1rem;
    border-radius: 12px;
    color: #475569;
    font-weight: 750;
    text-decoration: none;
    font-size: 0.95rem;
    min-height: var(--slm-tap-target-min);
    transition: color 0.2s ease, background 0.2s ease;
}

.nav-menu a:hover {
    color: var(--slm-indigo);
    background: rgba(79, 70, 229, 0.08);
}

.nav-actions {
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 0.5rem;
    position: absolute;
    left: 1rem;
    right: 1rem;
    top: calc(100% + 0.5rem);
    padding: 0.75rem;
    border: 1px solid rgba(226, 232, 240, 0.95);
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.96);
    box-shadow: var(--slm-shadow-lg);
    z-index: 1020;
}

.nav-actions.open {
    display: flex;
}

.nav-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    border: 1px solid var(--slm-border);
    border-radius: 12px;
    background: #ffffff;
    color: #0f172a;
    flex-shrink: 0;
}

.landing-hero {
    position: relative;
    padding: clamp(2.5rem, 6vw, 4rem) 0 2rem;
    overflow: hidden;
}

.landing-hero::before {
    content: "";
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle at 18% 20%, rgba(79, 70, 229, 0.15), transparent 18rem),
        radial-gradient(circle at 78% 12%, rgba(15, 118, 110, 0.12), transparent 18rem),
        linear-gradient(135deg, rgba(238, 242, 255, 0.8), rgba(236, 254, 255, 0.6));
    z-index: 0;
}

.landing-hero-content {
    position: relative;
    z-index: 1;
}

/* Mobile-first: stacked on small screens */
.landing-hero-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
    align-items: center;
}

.landing-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.45rem 0.75rem;
    border-radius: 999px;
    background: rgba(79, 70, 229, 0.08);
    color: var(--slm-indigo);
    font-size: 0.8rem;
    font-weight: 850;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    margin-bottom: 1rem;
}

.landing-title {
    max-width: 760px;
    margin: 0;
    color: #0f172a;
    font-size: clamp(1.75rem, 5vw, 2.75rem);
    font-weight: 900;
    line-height: 1.1;
    letter-spacing: -0.05em;
}

.landing-subtitle {
    max-width: 680px;
    margin: 1rem 0 0;
    color: #475569;
    font-size: clamp(0.95rem, 2vw, 1.15rem);
    line-height: 1.7;
}

.landing-actions {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    margin-top: 1.5rem;
}

.landing-actions .btn {
    width: 100%;
}

.landing-hero-proof {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    margin-top: 1.5rem;
}

.landing-proof-item {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.6rem 0.85rem;
    border: 1px solid rgba(226, 232, 240, 0.9);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.72);
    color: #475569;
    font-weight: 750;
    box-shadow: var(--slm-shadow-sm);
    min-height: var(--slm-tap-target-min);
}

/* Desktop: two-column layout for hero */
@media (min-width: 1025px) {
    .landing-hero {
        padding: clamp(4rem, 7vw, 6rem) 0;
    }
    
    .landing-hero-grid {
        grid-template-columns: minmax(0, 1.02fr) minmax(380px, 0.98fr);
        gap: 3rem;
    }
    
    .landing-title {
        font-size: clamp(2.25rem, 5vw, 3.25rem);
    }
    
    .landing-actions {
        flex-direction: row;
    }
    
    .landing-actions .btn {
        width: auto;
    }
    
    .landing-hero-proof {
        flex-direction: row;
    }
    
    .dashboard-preview {
        transform: perspective(1200px) rotateY(-7deg) rotateX(3deg);
    }
}

.dashboard-preview {
    position: relative;
    border: 1px solid rgba(226, 232, 240, 0.9);
    border-radius: 24px;
    background: rgba(255, 255, 255, 0.86);
    box-shadow: 0 20px 50px rgba(15, 23, 42, 0.12);
    backdrop-filter: blur(18px);
    overflow: hidden;
    max-width: 100%;
}

.dashboard-preview::before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(79, 70, 229, 0.06), transparent 42%);
    pointer-events: none;
}

.preview-topbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.85rem 1rem;
    border-bottom: 1px solid rgba(226, 232, 240, 0.9);
    background: rgba(248, 250, 252, 0.86);
}

.preview-dots {
    display: flex;
    gap: 0.4rem;
}

.preview-dots span {
    width: 10px;
    height: 10px;
    border-radius: 999px;
    background: #cbd5e1;
}

.preview-dots span:nth-child(1) { background: #ef4444; }
.preview-dots span:nth-child(2) { background: #f59e0b; }
.preview-dots span:nth-child(3) { background: #10b981; }

.preview-title {
    margin: 0;
    color: #0f172a;
    font-size: 0.9rem;
    font-weight: 850;
}

.preview-body {
    padding: 1rem;
}

/* Mobile-first: single column on small screens */
.preview-metrics {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.75rem;
}

.preview-card {
    padding: 0.85rem;
    border: 1px solid rgba(226, 232, 240, 0.9);
    border-radius: 16px;
    background: linear-gradient(180deg, #ffffff, #f8fafc);
    box-shadow: var(--slm-shadow-sm);
}

.preview-card strong {
    display: block;
    margin-bottom: 0.25rem;
    color: #0f172a;
    font-size: 1.2rem;
    font-weight: 900;
    letter-spacing: -0.03em;
}

.preview-card span {
    color: #64748b;
    font-size: 0.75rem;
    font-weight: 750;
}

/* Mobile-first: stacked chart rows on small screens */
.preview-chart-row {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.3rem;
    margin: 0.6rem 0;
    font-size: 0.78rem;
}

@media (min-width: 768px) {
    .preview-metrics {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
    
    .preview-chart-row {
        grid-template-columns: 92px 1fr 58px;
        align-items: center;
        gap: 0.7rem;
    }
}

@media (min-width: 1025px) {
    .dashboard-preview {
        transform: perspective(1200px) rotateY(-7deg) rotateX(3deg);
    }
    
    .preview-card strong {
        font-size: 1.35rem;
    }
}

.preview-track {
    height: 10px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.14);
    overflow: hidden;
}

.preview-fill {
    display: block;
    height: 100%;
    border-radius: 999px;
    background: linear-gradient(90deg, var(--slm-indigo), var(--slm-teal));
}

.landing-section {
    position: relative;
    padding: clamp(2.5rem, 5vw, 4rem) 0;
    scroll-margin-top: 64px;
    width: 100%;
}

.landing-section-alt {
    background: linear-gradient(180deg, rgba(248, 250, 252, 0.8), rgba(255, 255, 255, 0.9));
}

.section-heading {
    max-width: 760px;
    margin: 0 auto 2rem;
    text-align: center;
}

.section-kicker {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    margin-bottom: 0.6rem;
    color: var(--slm-indigo);
    font-size: 0.75rem;
    font-weight: 900;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.section-heading h2 {
    margin: 0;
    color: #0f172a;
    font-size: clamp(1.5rem, 3.5vw, 2.25rem);
    font-weight: 900;
    line-height: 1.1;
    letter-spacing: -0.04em;
}

.section-heading p {
    margin: 0.8rem 0 0;
    color: #64748b;
    font-size: 0.95rem;
    line-height: 1.6;
}

/* Mobile-first: single column on small screens */
.feature-grid,
.product-grid,
.testimonial-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1rem;
}

.service-card,
.product-card,
.testimonial-card,
.benefit-card,
.step-card,
.faq-item,
.contact-panel {
    border: 1px solid rgba(226, 232, 240, 0.9);
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.92);
    box-shadow: var(--slm-shadow-sm);
    transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease;
    width: 100%;
}

.service-card,
.product-card,
.testimonial-card,
.benefit-card,
.step-card {
    padding: 1.1rem;
}

.service-card:hover,
.product-card:hover,
.testimonial-card:hover,
.benefit-card:hover,
.step-card:hover {
    transform: translateY(-4px);
    border-color: rgba(79, 70, 229, 0.22);
    box-shadow: var(--slm-shadow-lg);
}

.service-icon,
.product-icon,
.step-icon {
    width: 46px;
    height: 46px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 14px;
    color: #ffffff;
    background: linear-gradient(135deg, var(--slm-indigo), var(--slm-teal));
    box-shadow: 0 10px 20px rgba(79, 70, 229, 0.22);
    margin-bottom: 0.85rem;
    flex-shrink: 0;
}

.service-card h3,
.product-card h3,
.step-card h3 {
    margin: 0 0 0.5rem;
    color: #0f172a;
    font-size: 1.1rem;
    font-weight: 900;
    letter-spacing: -0.02em;
}

.service-card p,
.product-card p,
.step-card p,
.benefit-card p {
    margin: 0;
    color: #64748b;
    line-height: 1.55;
    font-size: 0.9rem;
}

.benefit-row {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
    align-items: center;
    width: 100%;
}

.benefit-visual {
    min-height: 280px;
    border-radius: 24px;
    background:
        radial-gradient(circle at 20% 20%, rgba(79, 70, 229, 0.18), transparent 16rem),
        radial-gradient(circle at 80% 70%, rgba(16, 185, 129, 0.14), transparent 16rem),
        linear-gradient(135deg, #0f172a, #1e3a8a);
    color: #ffffff;
    padding: 1.5rem;
    position: relative;
    overflow: hidden;
    width: 100%;
}

.benefit-visual {
    min-height: 420px;
    border-radius: 30px;
    background:
        radial-gradient(circle at 20% 20%, rgba(79, 70, 229, 0.22), transparent 16rem),
        radial-gradient(circle at 80% 70%, rgba(16, 185, 129, 0.18), transparent 18rem),
        linear-gradient(135deg, #0f172a, #1e3a8a);
    color: #ffffff;
    padding: 2rem;
    position: relative;
    overflow: hidden;
}

.benefit-visual::before {
    content: "";
    position: absolute;
    inset: 1.5rem;
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: 24px;
}

.benefit-visual-card {
    position: relative;
    z-index: 1;
    margin-top: 5rem;
    padding: 1.25rem;
    border-radius: 22px;
    background: rgba(255, 255, 255, 0.12);
    border: 1px solid rgba(255, 255, 255, 0.18);
    backdrop-filter: blur(12px);
}

.benefit-visual-card strong {
    display: block;
    margin-bottom: 0.45rem;
    font-size: 2.4rem;
    font-weight: 900;
    letter-spacing: -0.05em;
}

.benefit-visual-card span {
    color: rgba(255, 255, 255, 0.78);
    font-weight: 700;
}

.benefit-grid {
    display: grid;
    gap: 1rem;
}

.benefit-card {
    display: flex;
    gap: 1rem;
    align-items: flex-start;
    padding: 1.15rem;
}

.benefit-card .service-icon {
    flex: 0 0 auto;
    width: 48px;
    height: 48px;
    margin: 0;
    border-radius: 16px;
}

.product-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

.product-card {
    position: relative;
    overflow: hidden;
}

.product-card::after {
    content: "";
    position: absolute;
    right: -36px;
    top: -36px;
    width: 100px;
    height: 100px;
    border-radius: 999px;
    background: rgba(79, 70, 229, 0.08);
}

.steps {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 1rem;
    counter-reset: steps;
}

.step-card {
    position: relative;
}

.step-card::before {
    counter-increment: steps;
    content: "0" counter(steps);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    margin-bottom: 1rem;
    border-radius: 15px;
    color: #ffffff;
    background: linear-gradient(135deg, var(--slm-indigo), var(--slm-teal));
    font-weight: 900;
}

.stats-strip {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 1rem;
    margin-top: 2rem;
}

.stat-card {
    padding: 1.4rem;
    border-radius: 24px;
    background: linear-gradient(135deg, #0f172a, #1e3a8a);
    color: #ffffff;
    box-shadow: var(--slm-shadow-lg);
}

.stat-card strong {
    display: block;
    margin-bottom: 0.35rem;
    font-size: 2rem;
    font-weight: 900;
    letter-spacing: -0.05em;
}

.stat-card span {
    color: rgba(255, 255, 255, 0.76);
    font-weight: 750;
}

.testimonial-card {
    position: relative;
}

.testimonial-card p {
    color: #475569;
    line-height: 1.7;
}

.testimonial-author {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    margin-top: 1.2rem;
}

.testimonial-avatar {
    width: 46px;
    height: 46px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 16px;
    color: #ffffff;
    background: linear-gradient(135deg, var(--slm-indigo), var(--slm-teal));
    font-weight: 900;
}

.testimonial-author strong {
    display: block;
    color: #0f172a;
}

.testimonial-author span {
    color: #64748b;
    font-size: 0.86rem;
}

/* Mobile-first FAQ grid - stacked on small screens */
.faq-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1rem;
}

.faq-question {
    width: 100%;
    border: 0;
    background: transparent;
    color: #0f172a;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    padding: 1rem;
    font-weight: 900;
    text-align: left;
    min-height: var(--slm-tap-target-min);
}

.faq-question i {
    color: var(--slm-indigo);
    flex-shrink: 0;
}

.faq-answer {
    display: none;
    padding: 0 1rem 1rem;
    color: #64748b;
    line-height: 1.7;
}

.faq-item.open .faq-answer {
    display: block;
}

/* Mobile-first contact panel - stacked on small screens */
.contact-panel {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
    padding: 1.25rem;
    background:
        radial-gradient(circle at 0% 0%, rgba(79, 70, 229, 0.08), transparent 12rem),
        rgba(255, 255, 255, 0.94);
    width: 100%;
}

.contact-info,
.contact-methods {
    display: grid;
    gap: 1rem;
}

.contact-method {
    display: flex;
    gap: 0.9rem;
    align-items: flex-start;
    padding: 1rem;
    border-radius: 20px;
    background: #f8fafc;
    border: 1px solid rgba(226, 232, 240, 0.9);
}

.contact-method i {
    width: 42px;
    height: 42px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 14px;
    color: #ffffff;
    background: linear-gradient(135deg, var(--slm-indigo), var(--slm-teal));
}

.contact-method strong {
    display: block;
    margin-bottom: 0.2rem;
    color: #0f172a;
}

.contact-method span,
.contact-method a {
    color: #64748b;
    text-decoration: none;
}

.landing-footer {
    padding: 2rem 0;
    background: #0f172a;
    color: #cbd5e1;
}

/* Mobile-first footer - single column on small screens */
.footer-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
}

.footer-brand {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    color: #ffffff;
    font-weight: 900;
    text-decoration: none;
    font-size: 1rem;
}

.footer-grid h5 {
    margin: 0 0 0.75rem;
    color: #ffffff;
    font-weight: 900;
    font-size: 1rem;
}

.footer-grid p,
.footer-grid a {
    color: #94a3b8;
    line-height: 1.7;
    font-size: 0.9rem;
}

.footer-grid a {
    display: block;
    text-decoration: none;
    min-height: var(--slm-tap-target-min);
    padding: 0.25rem 0;
}

.footer-grid a:hover {
    color: #ffffff;
}

.footer-bottom {
    margin-top: 1.5rem;
    padding-top: 1rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    color: #94a3b8;
    font-size: 0.85rem;
}

.floating-shape {
    position: absolute;
    border-radius: 999px;
    background: rgba(79, 70, 229, 0.08);
    filter: blur(1px);
    animation: floatShape 8s ease-in-out infinite;
}

.shape-a {
    width: 160px;
    height: 160px;
    right: 8%;
    top: 18%;
}

.shape-b {
    width: 90px;
    height: 90px;
    left: 8%;
    bottom: 18%;
    animation-delay: 1.5s;
}

@keyframes floatShape {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-18px); }
}

.reveal {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.65s ease, transform 0.65s ease;
}

.reveal.in-view {
    opacity: 1;
    transform: translateY(0);
}

.password-toggle {
    position: absolute;
    right: 0.35rem;
    top: 50%;
    transform: translateY(-50%);
    width: 40px;
    height: 40px;
    border: 0;
    border-radius: 12px;
    background: transparent;
    color: #64748b;
}

.password-input .form-control {
    padding-right: 3.4rem;
}

.auth-check-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 1rem;
}

.auth-check-row label {
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
    margin: 0;
    color: #475569;
    font-weight: 750;
    cursor: pointer;
}

.auth-footer-link {
    color: var(--slm-indigo);
}

.auth-trust-row {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0.75rem;
    margin-top: 1.25rem;
}

.auth-trust-item {
    padding: 0.85rem;
    border-radius: 18px;
    background: rgba(248, 250, 252, 0.86);
    border: 1px solid rgba(226, 232, 240, 0.9);
}

.auth-trust-item i {
    display: block;
    margin-bottom: 0.45rem;
    color: var(--slm-indigo);
}

.auth-trust-item strong {
    display: block;
    color: #0f172a;
    font-size: 0.86rem;
}

.auth-trust-item span {
    color: #64748b;
    font-size: 0.78rem;
}

.auth-progress-dots {
    display: flex;
    gap: 0.45rem;
    margin-bottom: 1.25rem;
}

.auth-progress-dot {
    width: 100%;
    height: 6px;
    border-radius: 999px;
    background: #e2e8f0;
}

.auth-progress-dot.active {
    background: linear-gradient(90deg, var(--slm-indigo), var(--slm-teal));
}

.auth-progress-dot.complete {
    background: var(--slm-emerald);
}

.form-section {
    padding: 1rem 0;
    border-bottom: 1px solid rgba(226, 232, 240, 0.85);
}

.form-section:last-child {
    border-bottom: 0;
}

.form-section-title {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    margin-bottom: 1rem;
    color: #0f172a;
    font-weight: 900;
    letter-spacing: -0.025em;
}

.form-section-title i {
    color: var(--slm-indigo);
}

.form-section-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1rem;
}

.password-meter {
    height: 8px;
    border-radius: 999px;
    background: #e2e8f0;
    overflow: hidden;
    margin: 0.75rem 0 0.45rem;
}

.password-meter-fill {
    width: 0;
    height: 100%;
    border-radius: inherit;
    background: #ef4444;
    transition: width 0.25s ease, background 0.25s ease;
}

.password-meter-fill.medium {
    background: #f59e0b;
}

.password-meter-fill.strong {
    background: #10b981;
}

.password-meter-label {
    color: #64748b;
    font-size: 0.78rem;
    font-weight: 750;
}

.password-checks {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.45rem 0.75rem;
    margin-top: 0.75rem;
}

.password-check {
    display: flex;
    align-items: center;
    gap: 0.45rem;
    color: #64748b;
    font-size: 0.78rem;
    font-weight: 700;
}

.password-check.valid {
    color: #047857;
}

.password-check.valid i::before {
    content: "\f00c";
}

.auth-note-card {
    margin-top: 1rem;
    padding: 1rem;
    border-radius: 18px;
    background: rgba(79, 70, 229, 0.08);
    border: 1px solid rgba(79, 70, 229, 0.14);
    color: #475569;
    line-height: 1.6;
}

/* ========================================
   MOBILE-FIRST RESPONSIVE BREAKPOINTS
   Small phones: 320px-480px (default/base)
   Large phones: 481px-767px
   Tablets: 768px-1024px
   Laptops: 1025px-1440px
   Large desktops: 1441px+
   ======================================== */

/* Large phones: 481px - 767px */
@media (min-width: 481px) {
    .page-title {
        font-size: clamp(1.75rem, 4vw, 2.25rem);
    }
    
    .profile-avatar,
    .borrower-avatar {
        width: 112px;
        height: 112px;
    }
    
    .avatar-img {
        width: 112px;
        height: 112px;
    }
}

/* Tablets: 768px - 1024px */
@media (min-width: 768px) {
    .app-main {
        padding: 1.25rem;
    }
    
    .page-header {
        flex-direction: row;
        align-items: flex-start;
        justify-content: space-between;
        gap: 1rem;
    }
    
    .page-header .d-flex.gap-2,
    .page-header .d-flex.gap-3 {
        flex-wrap: nowrap;
        justify-content: flex-end;
    }
    
    .page-header .d-flex.gap-2 > * {
        flex: 0 1 auto;
        min-width: auto;
    }
    
    .metric-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 1rem;
    }
    
    .detail-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 1rem;
    }
    
    .chart-bar {
        grid-template-columns: 120px 1fr 70px;
        align-items: center;
        gap: 0.75rem;
    }
    
    .chart-title {
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
        gap: 1rem;
    }
    
    .chart-value {
        text-align: right;
    }
    
    .data-table-controls {
        flex-direction: row;
        align-items: center;
    }
    
    .data-table-search,
    .data-table-filter,
    .data-table-page-size {
        width: auto;
    }
    
    .table-pagination {
        flex-direction: row;
        align-items: center;
    }
    
    .form-section-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 1rem;
    }
    
    .password-checks {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
    
    .auth-trust-row {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
    
    .preview-metrics {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
    
    .feature-grid,
    .product-grid,
    .testimonial-grid,
    .steps,
    .stats-strip,
    .faq-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

/* Laptops: 1025px - 1440px */
@media (min-width: 1025px) {
    .app-sidebar {
        transform: translateX(0);
    }
    
    .app-content {
        margin-left: var(--slm-sidebar-width);
    }
    
    .app-topbar {
        min-height: var(--slm-topbar-height);
        padding: 0.85rem 1.5rem;
    }
    
    /* Desktop landing navigation - inline menu */
    .landing-nav .nav-menu,
    .landing-nav .nav-actions {
        display: flex !important;
        position: static;
        flex-direction: row;
        align-items: center;
        padding: 0;
        border: 0;
        border-radius: 0;
        background: transparent;
        box-shadow: none;
        gap: 0.35rem;
    }
    
    .landing-nav .nav-menu a,
    .landing-nav .nav-actions .btn {
        width: auto;
        min-width: auto;
    }
    
    .landing-nav .nav-toggle {
        display: none;
    }
    
    .metric-grid {
        grid-template-columns: repeat(4, minmax(0, 1fr));
        gap: 1rem;
    }
    
    .contact-panel,
    .benefit-row,
    .landing-hero-grid {
        grid-template-columns: minmax(0, 0.95fr) minmax(380px, 0.98fr);
    }
    
    .footer-grid {
        grid-template-columns: 1.4fr repeat(3, minmax(0, 1fr));
    }
    
    .product-grid {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }
    
    .feature-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
    
    .testimonial-grid,
    .steps,
    .stats-strip,
    .faq-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

/* Large desktops: 1441px and above */
@media (min-width: 1441px) {
    .metric-grid {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }
    
    .feature-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
    
    .product-grid {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }
    
    .footer-grid {
        grid-template-columns: 1.4fr repeat(3, minmax(0, 1fr));
    }
    
    .testimonial-grid,
    .steps,
    .stats-strip,
    .faq-grid {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }
}

/* Mobile table: show data-labels on small screens */
@media (max-width: 767px) {
    .data-table thead {
        display: none;
    }
    
    .data-table,
    .data-table tbody,
    .data-table tr,
    .data-table td {
        display: block;
        width: 100%;
    }
    
    .data-table tr {
        margin-bottom: 1rem;
        border: 1px solid var(--slm-border);
        border-radius: var(--slm-radius);
        background: #ffffff;
        padding: 0.75rem;
    }
    
    .data-table td {
        text-align: right;
        padding: 0.5rem 0.75rem;
        border: 0;
        position: relative;
    }
    
    .data-table td.text-end {
        text-align: right;
    }
    
    .data-table td::before {
        content: attr(data-label);
        position: absolute;
        left: 0.75rem;
        width: auto;
        font-weight: 700;
        color: #475569;
        text-transform: uppercase;
        font-size: 0.7rem;
        letter-spacing: 0.05em;
    }
}

/* Tablets/Touch devices: up to 1024px - hide sidebar, show mobile toggle */
@media (max-width: 1024px) {
    .app-sidebar {
        transform: translateX(-100%);
    }
    
    .app-sidebar.mobile-open {
        transform: translateX(0);
    }
    
    .app-content {
        margin-left: 0;
    }
}
