:root {
    --bg-color: #0f172a;
    --text-primary: #f8fafc;
    --text-secondary: #94a3b8;
    --accent: #3b82f6;
    --glass-bg: rgba(30, 41, 59, 0.7);
    --glass-border: rgba(255, 255, 255, 0.1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-color);
    color: var(--text-primary);
    min-height: 100vh;
    background-image: 
        radial-gradient(at 0% 0%, rgba(59, 130, 246, 0.15) 0px, transparent 50%),
        radial-gradient(at 100% 100%, rgba(139, 92, 246, 0.15) 0px, transparent 50%);
    background-attachment: fixed;
}

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

header {
    margin-bottom: 3rem;
}

header h1 {
    font-size: 2.5rem;
    font-weight: 700;
    background: linear-gradient(to right, #60a5fa, #a78bfa);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 0.5rem;
}

header p {
    color: var(--text-secondary);
    font-size: 1.1rem;
}

.glass {
    background: var(--glass-bg);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid var(--glass-border);
    border-radius: 1rem;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
}

.summary-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin-bottom: 3rem;
}

.card {
    padding: 1.25rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    overflow: hidden;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    border-color: rgba(255, 255, 255, 0.2);
}

.card-icon {
    font-size: 2rem;
    background: rgba(255, 255, 255, 0.05);
    padding: 0.8rem;
    border-radius: 1rem;
    flex-shrink: 0;
}

.card-content {
    min-width: 0;
    flex: 1;
}

.card-content h3 {
    font-size: 0.75rem;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 0.25rem;
    line-height: 1.3;
}

.card-content .value {
    font-size: 1.2rem;
    font-weight: 700;
    word-break: break-word;
    line-height: 1.2;
}

.recent-transactions {
    padding: 2rem;
}

.recent-transactions h2 {
    margin-bottom: 1.5rem;
    font-size: 1.5rem;
    font-weight: 600;
}

.table-container {
    overflow-x: auto;
}

table {
    width: 100%;
    border-collapse: collapse;
}

th, td {
    padding: 1rem;
    text-align: left;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

th {
    color: var(--text-secondary);
    font-weight: 500;
    font-size: 0.875rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

tbody tr {
    transition: background-color 0.2s ease;
}

tbody tr:hover {
    background-color: rgba(255, 255, 255, 0.03);
}

.text-right {
    text-align: right;
}

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

.loading {
    color: var(--text-secondary);
    padding: 3rem !important;
    font-style: italic;
}

.table-header-flex {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.table-header-flex h2 {
    margin-bottom: 0;
}

.filter-section {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.glass-input, .glass-btn {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--text-primary);
    padding: 0.5rem 1rem;
    border-radius: 0.5rem;
    font-family: inherit;
    font-size: 0.875rem;
    outline: none;
    transition: all 0.3s ease;
}

.glass-input:focus, .glass-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.2);
}

.glass-input::-webkit-calendar-picker-indicator {
    filter: invert(1);
    cursor: pointer;
}

.glass-btn {
    cursor: pointer;
    background: var(--accent);
    border: none;
    font-weight: 600;
}

.glass-btn:hover {
    background: #2563eb;
    box-shadow: 0 0 10px rgba(59, 130, 246, 0.5);
}

.glass-nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 1.5rem;
    margin-bottom: 2rem;
    flex-wrap: wrap;
    gap: 1rem;
}

.nav-logo h2 {
    font-size: 1.25rem;
    font-weight: 700;
    margin: 0;
    color: var(--text-primary);
}

.nav-links {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 0.5rem;
}

.nav-links a {
    text-decoration: none;
    color: var(--text-secondary);
    font-weight: 500;
    padding: 0.5rem 0.8rem;
    border-radius: 0.5rem;
    transition: all 0.3s ease;
    white-space: nowrap;
    font-size: 0.9rem;
}

.nav-links a:hover, .nav-links a.active {
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.1);
}

.chart-container {
    padding: 2rem;
    margin-bottom: 2rem;
    position: relative;
    height: 400px;
    width: 100%;
}

@media (max-width: 768px) {
    .dashboard-container {
        padding: 1rem;
    }
    .summary-cards {
        grid-template-columns: 1fr;
    }
}

@media print {
    body {
        background: white !important;
        color: black !important;
        background-image: none !important;
    }
    .dashboard-container {
        padding: 0;
        max-width: 100%;
    }
    .hide-on-print {
        display: none !important;
    }
    .print-header {
        display: block !important;
    }
    .glass {
        border: none;
        box-shadow: none;
        backdrop-filter: none;
        background: transparent;
        padding: 0 !important;
    }
    table {
        border: 1px solid #000;
        width: 100%;
    }
    th, td {
        border: 1px solid #000;
        color: black !important;
        padding: 8px;
    }
    th {
        background-color: #f3f4f6 !important;
        -webkit-print-color-adjust: exact;
        print-color-adjust: exact;
        font-weight: bold;
    }
    tfoot td {
        background-color: #f3f4f6 !important;
        -webkit-print-color-adjust: exact;
        print-color-adjust: exact;
    }
}
