/* Global Styles */
:root {
    --primary-color: #1e40af;
    --primary-light: #3b82f6;
    --primary-dark: #1e3a8a;
    --secondary-color: #059669;
    --secondary-light: #10b981;
    --accent-color: #f59e0b;
    --danger-color: #dc2626;
    --warning-color: #d97706;
    --info-color: #0ea5e9;
    --success-color: #059669;
    --dark-color: #1f2937;
    --light-color: #f8fafc;
    --border-color: #e5e7eb;
    --text-primary: #111827;
    --text-secondary: #6b7280;
    --text-muted: #9ca3af;
    --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
    --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
    --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
    --border-radius: 12px;
    --border-radius-sm: 8px;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    color: var(--text-primary);
    background-color: var(--light-color);
    line-height: 1.6;
}

/* Sign In Page Styles */
.signin-page {
    height: 100vh;
    overflow: hidden;
}

.signin-left {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    color: white;
    padding: 3rem;
    position: relative;
    overflow: hidden;
}

.signin-left::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 200%;
    height: 200%;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grid" width="10" height="10" patternUnits="userSpaceOnUse"><path d="M 10 0 L 0 0 0 10" fill="none" stroke="rgba(255,255,255,0.1)" stroke-width="0.5"/></pattern></defs><rect width="100" height="100" fill="url(%23grid)" /></svg>');
    opacity: 0.3;
    z-index: 1;
}

.signin-branding {
    position: relative;
    z-index: 2;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.brand-logo {
    display: flex;
    align-items: center;
    margin-bottom: 3rem;
}

.brand-logo i {
    font-size: 2.5rem;
    margin-right: 1rem;
    color: var(--accent-color);
}

.brand-logo h2 {
    font-size: 1.75rem;
    font-weight: 700;
    margin: 0;
}

.signin-branding h1 {
    font-size: 3rem;
    font-weight: 800;
    margin-bottom: 1rem;
    line-height: 1.2;
}

.signin-branding .lead {
    font-size: 1.25rem;
    margin-bottom: 2rem;
    opacity: 0.9;
}

.feature-list {
    margin-top: 3rem;
}

.feature-item {
    display: flex;
    align-items: center;
    margin-bottom: 1.5rem;
}

.feature-item i {
    font-size: 1.25rem;
    margin-right: 1rem;
    color: var(--accent-color);
    width: 24px;
}

.brand-logo-mobile {
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary-color);
}

.brand-logo-mobile i {
    font-size: 2rem;
    margin-right: 0.5rem;
    color: var(--accent-color);
}

.signin-form-container {
    width: 100%;
    max-width: 400px;
    margin: 0 auto;
    padding: 2rem;
}

.signin-header {
    text-align: center;
    margin-bottom: 2rem;
}

.signin-title {
    font-size: 2rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
}

.signin-subtitle {
    color: var(--text-secondary);
    font-size: 1rem;
}

.signin-form .form-group {
    margin-bottom: 1.5rem;
}

.signin-form .form-label {
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
}

.signin-form .input-group-text {
    background-color: #f8fafc;
    border-right: 0;
    color: var(--text-secondary);
}

.signin-form .form-control {
    border-left: 0;
    border-radius: 0 var(--border-radius-sm) var(--border-radius-sm) 0;
    padding: 0.75rem 1rem;
    font-size: 0.95rem;
}

.signin-form .input-group .form-control:focus {
    box-shadow: 0 0 0 0.2rem rgba(59, 130, 246, 0.15);
    border-color: var(--primary-light);
}

.signin-form .input-group-text:has(+ .form-control:focus) {
    border-color: var(--primary-light);
}

.signin-form .input-group {
    border-radius: var(--border-radius-sm);
    overflow: hidden;
}

.toggle-password {
    border-left: 0;
    border-radius: 0;
}

.btn-signin {
    width: 100%;
    padding: 0.875rem;
    font-weight: 600;
    font-size: 1rem;
    border-radius: var(--border-radius-sm);
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-light) 100%);
    border: none;
    transition: all 0.3s ease;
}

.btn-signin:hover {
    transform: translateY(-1px);
    box-shadow: var(--shadow-lg);
    background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary-color) 100%);
}

.signin-links {
    text-align: center;
    margin-top: 1.5rem;
}

.forgot-password {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.9rem;
}

.forgot-password:hover {
    color: var(--primary-dark);
    text-decoration: underline;
}

.signup-link {
    margin-top: 1rem;
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.signup-link a {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 500;
}

/* Dashboard Styles */
.dashboard-page {
    background-color: #f8fafc;
    min-height: 100vh;
}

.dashboard-navbar {
    background-color: white;
    border-bottom: 1px solid var(--border-color);
    box-shadow: var(--shadow-sm);
    padding: 1rem 0;
}

.navbar-brand {
    display: flex;
    align-items: center;
    font-weight: 700;
    color: var(--text-primary) !important;
    text-decoration: none;
}

.navbar-brand i {
    font-size: 1.5rem;
    color: var(--primary-color);
    margin-right: 0.75rem;
}

.navbar-brand small {
    font-weight: 400;
}

.nav-link {
    color: var(--text-secondary) !important;
    font-weight: 500;
    padding: 0.5rem 1rem !important;
    border-radius: var(--border-radius-sm);
    margin: 0 0.25rem;
    transition: all 0.2s ease;
}

.nav-link:hover,
.nav-link.active {
    color: var(--primary-color) !important;
    background-color: rgba(59, 130, 246, 0.1);
}

.user-dropdown {
    display: flex;
    align-items: center;
    padding: 0.5rem 1rem !important;
}

.user-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    margin-right: 0.5rem;
    object-fit: cover;
}

.dashboard-content {
    padding: 2rem;
    max-width: 1400px;
    margin: 0 auto;
}

.dashboard-header {
    margin-bottom: 2rem;
}

.dashboard-title {
    font-size: 2.25rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
}

.dashboard-subtitle {
    color: var(--text-secondary);
    font-size: 1.1rem;
}

.btn-add-fund {
    background: linear-gradient(135deg, var(--secondary-color) 0%, var(--secondary-light) 100%);
    border: none;
    padding: 0.75rem 1.5rem;
    font-weight: 600;
    border-radius: var(--border-radius-sm);
    transition: all 0.3s ease;
}

.btn-add-fund:hover {
    transform: translateY(-1px);
    box-shadow: var(--shadow-md);
    background: linear-gradient(135deg, #047857 0%, var(--secondary-color) 100%);
}

/* Statistics Cards */
.stat-card {
    background: white;
    padding: 1.5rem;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-sm);
    display: flex;
    align-items: center;
    transition: all 0.3s ease;
    border: 1px solid var(--border-color);
}

.stat-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.stat-icon {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 1rem;
    flex-shrink: 0;
}

.stat-icon i {
    font-size: 1.5rem;
    color: white;
}

.stat-icon.bg-primary { background: linear-gradient(135deg, var(--primary-color), var(--primary-light)); }
.stat-icon.bg-success { background: linear-gradient(135deg, var(--success-color), var(--secondary-light)); }
.stat-icon.bg-info { background: linear-gradient(135deg, var(--info-color), #38bdf8); }
.stat-icon.bg-warning { background: linear-gradient(135deg, var(--warning-color), var(--accent-color)); }

.stat-content {
    flex-grow: 1;
}

.stat-number {
    font-size: 2rem;
    font-weight: 700;
    color: var(--text-primary);
    margin: 0;
    line-height: 1;
}

.stat-label {
    color: var(--text-secondary);
    font-size: 0.9rem;
    margin: 0.25rem 0 0 0;
    font-weight: 500;
}

/* Funds Section */
.funds-section {
    margin-top: 2rem;
}

.section-header {
    margin-bottom: 1.5rem;
}

.section-title {
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
}

.section-subtitle {
    color: var(--text-secondary);
    font-size: 1rem;
}

/* Fund Cards */
.fund-card {
    background: white;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border-color);
    transition: all 0.3s ease;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.fund-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.fund-card-header {
    padding: 1.25rem 1.25rem 0;
    display: flex;
    justify-content: between;
    align-items: center;
}

.fund-status {
    display: flex;
    align-items: center;
    font-size: 0.875rem;
    font-weight: 500;
}

.fund-status i {
    font-size: 0.5rem;
    margin-right: 0.5rem;
}

.fund-status.active {
    color: var(--success-color);
}

.fund-status.pending {
    color: var(--warning-color);
}

.fund-status.inactive {
    color: var(--text-muted);
}

.fund-card-body {
    padding: 1.25rem;
    flex-grow: 1;
}

.fund-name {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 0.75rem;
}

.fund-description {
    color: var(--text-secondary);
    font-size: 0.9rem;
    line-height: 1.5;
    margin-bottom: 1.5rem;
}

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

.metric {
    display: flex;
    flex-direction: column;
}

.metric-label {
    font-size: 0.8rem;
    color: var(--text-muted);
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 0.25rem;
}

.metric-value {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-primary);
}

.metric-value.positive {
    color: var(--success-color);
}

.metric-value.negative {
    color: var(--danger-color);
}

.fund-card-footer {
    padding: 0 1.25rem 1.25rem;
    border-top: 1px solid #f1f5f9;
    margin-top: auto;
    padding-top: 1rem;
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 4rem 2rem;
    background: white;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border-color);
}

.empty-icon {
    font-size: 4rem;
    color: var(--text-muted);
    margin-bottom: 1.5rem;
}

.empty-state h3 {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 0.75rem;
}

.empty-state p {
    color: var(--text-secondary);
    font-size: 1rem;
    margin-bottom: 2rem;
}

/* Modal Styles */
.modal-header {
    border-bottom: 1px solid var(--border-color);
    padding: 1.5rem;
}

.modal-title {
    font-weight: 600;
    color: var(--text-primary);
}

.modal-body {
    padding: 1.5rem;
}

.add-fund-options {
    margin: 1.5rem 0;
}

.option-card {
    background: #f8fafc;
    border: 2px solid var(--border-color);
    border-radius: var(--border-radius);
    padding: 1.5rem;
    text-align: center;
    transition: all 0.3s ease;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.option-card:hover {
    border-color: var(--primary-color);
    background: rgba(59, 130, 246, 0.05);
}

.option-icon {
    font-size: 2.5rem;
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.option-card h5 {
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 0.75rem;
}

.option-card p {
    color: var(--text-secondary);
    font-size: 0.9rem;
    margin-bottom: 1.5rem;
    flex-grow: 1;
}

.option-card .btn {
    margin-top: auto;
}

/* Responsive Design */
@media (max-width: 768px) {
    .dashboard-content {
        padding: 1rem;
    }

    .dashboard-title {
        font-size: 1.75rem;
    }

    .fund-metrics {
        grid-template-columns: 1fr;
        gap: 0.75rem;
    }

    .stat-card {
        text-align: center;
        flex-direction: column;
    }

    .stat-icon {
        margin-right: 0;
        margin-bottom: 1rem;
    }

    .signin-form-container {
        padding: 1rem;
    }

    .signin-title {
        font-size: 1.75rem;
    }
}

/* Utility Classes */
.text-gradient {
    background: linear-gradient(135deg, var(--primary-color), var(--primary-light));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.btn-outline-primary {
    border-color: var(--primary-color);
    color: var(--primary-color);
}

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

.alert-info {
    background-color: #eff6ff;
    border-color: #bfdbfe;
    color: #1e40af;
}

/* Animation Classes */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.fade-in {
    animation: fadeIn 0.6s ease-out;
}

.slide-in {
    animation: slideIn 0.4s ease-out;
}

@keyframes slideIn {
    from { opacity: 0; transform: translateX(-20px); }
    to { opacity: 1; transform: translateX(0); }
}

/* -----------------------------------------
 FUND Cards design
 -------------------------------------------- */
.fund-card {
  background: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 12px;
  transition: all 0.2s ease-in-out;
}

.fund-card:hover {
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
  transform: translateY(-2px);
}

/* Title */
.fund-card h5 {
  font-size: 1.05rem;
  font-weight: 600;
  color: #111827;
}

/* Approval Badge */
.fund-card .badge {
  font-size: 0.7rem;
  font-weight: 500;
  border-radius: 6px;
  padding: 0.35rem 0.5rem;
}

/* List Info */
.fund-card ul li {
  font-size: 0.85rem;
  color: #4b5563;
  display: flex;
  align-items: center;
}

.fund-card ul li i {
  font-size: 0.85rem;
}

/* Metrics Section */
.fund-card small {
  display: block;
  font-size: 0.75rem;
  color: #6b7280;
}

.fund-card .fw-bold {
  font-size: 0.95rem;
  margin-top: 2px;
}

/* Annualized Return Highlight */
.fund-card .text-success {
  color: #16a34a !important; /* deep green like screenshot */
}
