/* SHE VEC Nakit Akış - Modern Design (Matching Original) */

/* Import fonts */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=JetBrains+Mono:wght@400;500&display=swap');

/* ============================================
   PAGE TRANSITION ANIMATIONS
   ============================================ */
/* View Transitions API support */
@view-transition {
    navigation: auto;
}

::view-transition-old(root) {
    animation: fade-out 150ms ease-out;
}

::view-transition-new(root) {
    animation: fade-in 150ms ease-in;
}

@keyframes fade-out {
    from { opacity: 1; }
    to { opacity: 0; }
}

@keyframes fade-in {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* Fallback for browsers without View Transitions API */
.page-transitioning {
    opacity: 0;
    transition: opacity 150ms ease;
}

.page-loaded {
    opacity: 1;
}

/* Page loading overlay */
.page-loading-overlay {
    position: fixed;
    top: 0;
    left: var(--sidebar-width);
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.7);
    backdrop-filter: blur(4px);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    opacity: 0;
    transition: opacity 150ms ease;
}

.page-loading-overlay.active {
    display: flex;
    opacity: 1;
}

[data-theme="dark"] .page-loading-overlay {
    background: rgba(15, 23, 42, 0.7);
}

.page-loading-spinner {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
}

.page-loading-spinner i {
    font-size: 32px;
    color: var(--primary);
    animation: spin 1s linear infinite;
}

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

.page-loading-spinner span {
    font-size: 14px;
    font-weight: 500;
    color: var(--gray-600);
}

[data-theme="dark"] .page-loading-spinner span {
    color: var(--gray-400);
}

/* Smooth content appearance */
.main-container {
    animation: content-fade-in 200ms ease-out;
}

@keyframes content-fade-in {
    from {
        opacity: 0;
        transform: translateY(8px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@media (max-width: 992px) {
    .page-loading-overlay {
        left: 0;
    }
}

:root {
    /* Colors - matching original */
    --primary: #6366f1;
    --primary-dark: #4f46e5;
    --primary-light: #818cf8;
    --secondary: #8b5cf6;
    --success: #10b981;
    --success-light: #34d399;
    --danger: #ef4444;
    --danger-light: #f87171;
    --warning: #f59e0b;
    --info: #3b82f6;

    /* Neutrals */
    --gray-50: #f8fafc;
    --gray-100: #f1f5f9;
    --gray-200: #e2e8f0;
    --gray-300: #cbd5e1;
    --gray-400: #94a3b8;
    --gray-500: #64748b;
    --gray-600: #475569;
    --gray-700: #334155;
    --gray-800: #1e293b;
    --gray-900: #0f172a;

    /* Sidebar */
    --sidebar-width: 280px;
    --sidebar-bg-start: #0f172a;
    --sidebar-bg-end: #0c1222;

    /* Shadows */
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
    --shadow: 0 1px 3px rgba(0, 0, 0, 0.1), 0 1px 2px rgba(0, 0, 0, 0.06);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);

    /* Border radius */
    --radius-sm: 0.375rem;
    --radius: 0.5rem;
    --radius-md: 0.75rem;
    --radius-lg: 1rem;
    --radius-xl: 1.5rem;

    /* Transitions */
    --transition-fast: 150ms ease;
    --transition: 200ms ease;
    --transition-slow: 300ms ease;
}

/* Dark Mode */
[data-theme="dark"] {
    --gray-50: #1e293b;
    --gray-100: #1e293b;
    --gray-200: #334155;
    --gray-300: #475569;
    --gray-400: #64748b;
    --gray-500: #94a3b8;
    --gray-600: #cbd5e1;
    --gray-700: #e2e8f0;
    --gray-800: #f1f5f9;
    --gray-900: #f8fafc;
}

[data-theme="dark"] body {
    background-color: #0f172a;
    color: #e2e8f0;
}

[data-theme="dark"] .top-header {
    background: rgba(15, 23, 42, 0.95);
    border-bottom-color: rgba(255, 255, 255, 0.05);
}

[data-theme="dark"] .main-container {
    background: #0f172a;
}

[data-theme="dark"] .card {
    background: #1e293b;
    border-color: rgba(255, 255, 255, 0.05);
}

[data-theme="dark"] .header-btn {
    background: #1e293b;
    border-color: #334155;
    color: #94a3b8;
}

[data-theme="dark"] .header-btn:hover {
    background: rgba(99, 102, 241, 0.15);
    border-color: var(--primary);
    color: var(--primary);
}

[data-theme="dark"] .header-clock {
    background: rgba(99, 102, 241, 0.15);
    border-color: rgba(99, 102, 241, 0.25);
}

[data-theme="dark"] .clock-time {
    color: #e2e8f0;
}

[data-theme="dark"] .clock-date {
    color: #94a3b8;
    border-left-color: #475569;
}

[data-theme="dark"] .page-title {
    color: #f1f5f9;
}

[data-theme="dark"] .search-input {
    background: #1e293b;
    border-color: var(--primary);
    color: #e2e8f0;
}

[data-theme="dark"] .table {
    color: #e2e8f0;
}

[data-theme="dark"] .table th {
    background: #1e293b;
    border-color: #334155;
}

[data-theme="dark"] .table td {
    border-color: #334155;
}

[data-theme="dark"] .form-control {
    background: #1e293b;
    border-color: #334155;
    color: #e2e8f0;
}

[data-theme="dark"] .form-control:focus {
    background: #0f172a;
    border-color: var(--primary);
}

[data-theme="dark"] .btn-outline-secondary {
    border-color: #475569;
    color: #94a3b8;
}

[data-theme="dark"] .dropdown-menu {
    background: #1e293b;
    border-color: #334155;
}

[data-theme="dark"] .dropdown-item {
    color: #e2e8f0;
}

[data-theme="dark"] .dropdown-item:hover {
    background: rgba(99, 102, 241, 0.15);
}

/* Dark Mode - Cards & Stat Cards */
[data-theme="dark"] .card,
[data-theme="dark"] .stat-card {
    background: #1e293b;
    border-color: rgba(255, 255, 255, 0.05);
    color: #e2e8f0;
}

[data-theme="dark"] .card-header {
    background: rgba(255, 255, 255, 0.02);
    border-bottom-color: rgba(255, 255, 255, 0.05);
}

[data-theme="dark"] .card-header h5,
[data-theme="dark"] .card-header h6,
[data-theme="dark"] .card-title {
    color: #f1f5f9;
}

[data-theme="dark"] .card-body {
    color: #e2e8f0;
}

[data-theme="dark"] .card-footer {
    background: rgba(255, 255, 255, 0.02);
    border-top-color: rgba(255, 255, 255, 0.05);
}

[data-theme="dark"] .stat-card .stat-value {
    color: #f1f5f9;
}

[data-theme="dark"] .stat-card .stat-label {
    color: #94a3b8;
}

/* Dark Mode - Text Colors */
[data-theme="dark"] h1,
[data-theme="dark"] h2,
[data-theme="dark"] h3,
[data-theme="dark"] h4,
[data-theme="dark"] h5,
[data-theme="dark"] h6 {
    color: #f1f5f9;
}

[data-theme="dark"] p,
[data-theme="dark"] span,
[data-theme="dark"] label {
    color: #cbd5e1;
}

[data-theme="dark"] .text-muted {
    color: #94a3b8 !important;
}

[data-theme="dark"] .text-secondary {
    color: #94a3b8 !important;
}

/* Dark Mode - Buttons */
[data-theme="dark"] .btn-light {
    background: #334155;
    border-color: #475569;
    color: #e2e8f0;
}

[data-theme="dark"] .btn-light:hover {
    background: #475569;
    border-color: #64748b;
    color: #f1f5f9;
}

[data-theme="dark"] .btn-outline-primary {
    border-color: var(--primary);
    color: var(--primary);
}

[data-theme="dark"] .btn-outline-primary:hover {
    background: var(--primary);
    color: white;
}

/* Dark Mode - Alerts */
[data-theme="dark"] .alert {
    border-color: rgba(255, 255, 255, 0.1);
}

[data-theme="dark"] .alert-success {
    background: rgba(16, 185, 129, 0.15);
    color: #34d399;
}

[data-theme="dark"] .alert-danger {
    background: rgba(239, 68, 68, 0.15);
    color: #f87171;
}

[data-theme="dark"] .alert-warning {
    background: rgba(245, 158, 11, 0.15);
    color: #fbbf24;
}

[data-theme="dark"] .alert-info {
    background: rgba(59, 130, 246, 0.15);
    color: #60a5fa;
}

/* Dark Mode - Inputs */
[data-theme="dark"] .form-select {
    background-color: #1e293b;
    border-color: #334155;
    color: #e2e8f0;
}

[data-theme="dark"] .form-select:focus {
    background-color: #0f172a;
    border-color: var(--primary);
}

[data-theme="dark"] .input-group-text {
    background: #334155;
    border-color: #334155;
    color: #94a3b8;
}

/* Dark Mode - Progress Bars */
[data-theme="dark"] .progress {
    background: #334155;
}

/* Dark Mode - Badges */
[data-theme="dark"] .badge.bg-light {
    background: #334155 !important;
    color: #e2e8f0 !important;
}

/* Dark Mode - Lists */
[data-theme="dark"] .list-group-item {
    background: #1e293b;
    border-color: #334155;
    color: #e2e8f0;
}

[data-theme="dark"] .list-group-item:hover {
    background: rgba(99, 102, 241, 0.1);
}

/* Dark Mode - Borders */
[data-theme="dark"] .border,
[data-theme="dark"] .border-top,
[data-theme="dark"] .border-bottom,
[data-theme="dark"] .border-start,
[data-theme="dark"] .border-end {
    border-color: #334155 !important;
}

/* Dark Mode - Modal */
[data-theme="dark"] .modal-content {
    background: #1e293b;
    border-color: #334155;
}

[data-theme="dark"] .modal-header {
    border-bottom-color: #334155;
}

[data-theme="dark"] .modal-footer {
    border-top-color: #334155;
}

[data-theme="dark"] .modal-title {
    color: #f1f5f9;
}

[data-theme="dark"] .btn-close {
    filter: invert(1) grayscale(100%) brightness(200%);
}

/* Dark Mode - Nav Tabs */
[data-theme="dark"] .nav-tabs {
    border-bottom-color: #334155;
}

[data-theme="dark"] .nav-tabs .nav-link {
    color: #94a3b8;
}

[data-theme="dark"] .nav-tabs .nav-link:hover {
    border-color: #475569;
    color: #e2e8f0;
}

[data-theme="dark"] .nav-tabs .nav-link.active {
    background: #1e293b;
    border-color: #334155;
    color: #f1f5f9;
}

/* Dark Mode - Pagination */
[data-theme="dark"] .page-link {
    background: #1e293b;
    border-color: #334155;
    color: #94a3b8;
}

[data-theme="dark"] .page-link:hover {
    background: rgba(99, 102, 241, 0.15);
    border-color: var(--primary);
    color: var(--primary);
}

[data-theme="dark"] .page-item.active .page-link {
    background: var(--primary);
    border-color: var(--primary);
}

[data-theme="dark"] .page-item.disabled .page-link {
    background: #0f172a;
    border-color: #334155;
    color: #475569;
}

/* Dark Mode - Popover & Tooltip */
[data-theme="dark"] .popover {
    background: #1e293b;
    border-color: #334155;
}

[data-theme="dark"] .popover-header {
    background: #334155;
    border-bottom-color: #475569;
    color: #f1f5f9;
}

[data-theme="dark"] .popover-body {
    color: #e2e8f0;
}

[data-theme="dark"] .tooltip-inner {
    background: #334155;
    color: #e2e8f0;
}

/* Dark Mode - Scrollbar */
[data-theme="dark"] ::-webkit-scrollbar-track {
    background: #0f172a;
}

[data-theme="dark"] ::-webkit-scrollbar-thumb {
    background: #475569;
}

[data-theme="dark"] ::-webkit-scrollbar-thumb:hover {
    background: #64748b;
}

/* Dark Mode - Small Text & Secondary */
[data-theme="dark"] small,
[data-theme="dark"] .small {
    color: #94a3b8;
}

/* Dark Mode - Quick Action Buttons */
[data-theme="dark"] .quick-actions .btn {
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 255, 255, 0.1);
    color: #e2e8f0;
}

[data-theme="dark"] .quick-actions .btn:hover {
    background: rgba(99, 102, 241, 0.15);
    border-color: var(--primary);
}

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

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background-color: var(--gray-100);
    color: var(--gray-800);
    font-size: 14px;
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Layout */
.wrapper {
    display: flex;
    min-height: 100vh;
}

/* ==================== SIDEBAR - PREMIUM DESIGN ==================== */
.sidebar {
    width: 240px;
    height: 100vh;
    position: fixed;
    left: 0;
    top: 0;
    background: linear-gradient(180deg, #0f172a 0%, #0a0f1a 100%);
    display: flex;
    flex-direction: column;
    z-index: 1000;
    border-right: 1px solid rgba(255, 255, 255, 0.05);
    box-shadow: 4px 0 40px rgba(0, 0, 0, 0.3);
    transition: transform var(--transition-slow);
}

.sidebar::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 200px;
    background: linear-gradient(180deg, rgba(99, 102, 241, 0.08), transparent);
    pointer-events: none;
}

.sidebar.collapsed {
    transform: translateX(-100%);
}

/* Sidebar Header - Premium Brand */
.sidebar-header {
    padding: 18px 16px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    position: relative;
}

.sidebar-brand {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.sidebar-logo {
    width: 38px;
    height: 38px;
    background: linear-gradient(135deg, var(--primary), var(--secondary), #ec4899);
    background-size: 200% 200%;
    animation: gradientShift 5s ease infinite;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 16px;
    box-shadow: 0 4px 16px rgba(99, 102, 241, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.sidebar-logo-img {
    max-width: 100%;
    max-height: 60px;
    object-fit: contain;
}

.sidebar-version {
    text-align: center;
    margin-top: -6px;
    font-size: 10px;
    font-weight: 600;
    letter-spacing: 0.5px;
    background: linear-gradient(90deg, #818cf8, #ec4899);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

@keyframes gradientShift {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}

.sidebar-brand h2 {
    font-size: 18px;
    font-weight: 800;
    color: white;
    letter-spacing: -0.3px;
    margin: 0;
}

.sidebar-brand span {
    display: block;
    font-size: 9px;
    font-weight: 600;
    letter-spacing: 0.5px;
    background: linear-gradient(90deg, #818cf8, #ec4899);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Sidebar Navigation */
.sidebar-nav {
    flex: 1;
    overflow-y: auto;
    padding: 12px 10px;
}

.sidebar-nav::-webkit-scrollbar {
    width: 3px;
}

.sidebar-nav::-webkit-scrollbar-thumb {
    background: var(--gray-700);
    border-radius: 2px;
}

/* Nav Section */
.nav-section {
    margin-bottom: 16px;
}

/* Nav Label */
.nav-label {
    font-size: 9px;
    font-weight: 800;
    color: var(--gray-500);
    text-transform: uppercase;
    letter-spacing: 1.5px;
    padding: 0 10px;
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.nav-label::after {
    content: '';
    flex: 1;
    height: 1px;
    background: rgba(255, 255, 255, 0.06);
}

/* Nav Item */
.nav-item {
    margin-bottom: 3px;
}

/* Nav Link */
.sidebar .nav-link {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 9px 12px;
    border-radius: 8px;
    color: var(--gray-400);
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.15s ease-out;
    text-decoration: none;
    position: relative;
    overflow: hidden;
}

.sidebar .nav-link::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 4px;
    background: linear-gradient(180deg, var(--primary), var(--secondary));
    transform: scaleY(0);
    transition: transform 0.15s ease-out;
    border-radius: 0 4px 4px 0;
}

.sidebar .nav-link:hover {
    color: white;
    background: rgba(255, 255, 255, 0.06);
}

.sidebar .nav-link:hover::before {
    transform: scaleY(1);
}

.sidebar .nav-link.active {
    color: white;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    box-shadow: 0 4px 24px rgba(99, 102, 241, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.sidebar .nav-link.active::before {
    display: none;
}

.sidebar .nav-link.active i {
    color: white !important;
}

.sidebar .nav-link i {
    width: 18px;
    text-align: center;
    font-size: 13px;
    transition: transform 0.15s ease-out;
}

.sidebar .nav-link:hover i {
    transform: scale(1.05);
}

.sidebar .nav-link span {
    white-space: nowrap;
}

/* Nav Badge */
.nav-badge {
    margin-left: auto;
    background: linear-gradient(135deg, var(--danger), #dc2626);
    color: white;
    font-size: 9px;
    font-weight: 800;
    padding: 2px 8px;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(239, 68, 68, 0.4);
    animation: pulse 2s infinite;
}

/* Nav Badge Soon (Coming Soon) */
.nav-badge-soon {
    margin-left: auto;
    background: rgba(100, 116, 139, 0.3);
    color: #94a3b8;
    font-size: 8px;
    font-weight: 700;
    padding: 2px 6px;
    border-radius: 8px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Disabled Nav Link */
.sidebar .nav-link.disabled {
    opacity: 0.5;
    cursor: not-allowed;
    pointer-events: none;
}

@keyframes pulse {
    0%, 100% { box-shadow: 0 2px 12px rgba(239, 68, 68, 0.4); }
    50% { box-shadow: 0 4px 20px rgba(239, 68, 68, 0.6); }
}

/* Active Indicator */
.active-indicator {
    position: absolute;
    right: 12px;
    width: 8px;
    height: 8px;
    background: white;
    border-radius: 50%;
    box-shadow: 0 0 12px rgba(255, 255, 255, 0.8);
    animation: pulse-indicator 2s infinite;
}

@keyframes pulse-indicator {
    0%, 100% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.3); opacity: 0.7; }
}

/* Sidebar Footer */
.sidebar-footer {
    padding: 14px 16px;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    background: rgba(0, 0, 0, 0.2);
}

/* Quick Stats */
.quick-stats {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin-bottom: 20px;
    padding: 16px;
    background: rgba(99, 102, 241, 0.08);
    border-radius: 12px;
    border: 1px solid rgba(99, 102, 241, 0.15);
}

.quick-stats .stat-item {
    text-align: center;
}

.quick-stats .stat-value {
    font-size: 20px;
    font-weight: 800;
    font-family: 'JetBrains Mono', monospace;
}

.quick-stats .stat-value.success {
    color: #10b981;
}

.quick-stats .stat-value.warning {
    color: #f59e0b;
}

.quick-stats .stat-label {
    font-size: 10px;
    color: rgba(255, 255, 255, 0.5);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* User Card - Sidebar */
.sidebar .user-card,
nav .user-card {
    display: flex;
    align-items: center;
    gap: 10px;
    background: #0f172a;
    padding: 12px;
    border-radius: 12px;
    margin: 0 12px;
}

.user-avatar {
    width: 36px;
    height: 36px;
    background: linear-gradient(135deg, var(--secondary), #ec4899);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 800;
    font-size: 13px;
    box-shadow: 0 3px 12px rgba(139, 92, 246, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.user-info h4 {
    font-size: 12px;
    font-weight: 700;
    color: white !important;
    margin: 0;
}

.sidebar .user-info h4,
.sidebar .user-card .user-info h4,
nav .user-info h4 {
    color: white !important;
}

.user-info p {
    font-size: 10px;
    color: var(--gray-400);
    margin: 1px 0 0 0;
}

/* Logout Button */
.logout-btn {
    margin-left: auto;
    width: 36px;
    height: 36px;
    border: none;
    background: rgba(239, 68, 68, 0.15);
    border-radius: 8px;
    color: #ef4444;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    text-decoration: none;
}

.logout-btn:hover {
    background: rgba(239, 68, 68, 0.25);
    color: #ef4444;
    transform: scale(1.05);
}

/* Version Info */
.version-info {
    margin-top: 16px;
    padding-top: 16px;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 11px;
    color: rgba(255, 255, 255, 0.3);
}

.pro-badge {
    padding: 4px 10px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    border-radius: 12px;
    color: white;
    font-weight: 600;
    font-size: 10px;
}

/* Legacy nav-header support */
.sidebar .nav-header {
    font-size: 9px;
    font-weight: 800;
    color: var(--gray-500);
    text-transform: uppercase;
    letter-spacing: 1.5px;
    padding: 0 10px;
    margin-bottom: 8px;
    margin-top: 16px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.sidebar .nav-header::after {
    content: '';
    flex: 1;
    height: 1px;
    background: rgba(255, 255, 255, 0.06);
}

/* Legacy sidebar-user support */
.sidebar-user {
    padding: 14px 16px;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    background: rgba(0, 0, 0, 0.2);
}

.sidebar-user .user-info {
    display: flex;
    align-items: center;
    gap: 10px;
}

.sidebar-user .avatar {
    width: 36px;
    height: 36px;
    background: linear-gradient(135deg, var(--secondary), #ec4899);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 800;
    font-size: 13px;
    box-shadow: 0 3px 12px rgba(139, 92, 246, 0.4);
}

.sidebar-user .user-name {
    font-size: 12px;
    font-weight: 700;
    color: white;
}

.sidebar-user .user-role {
    font-size: 10px;
    color: var(--gray-400);
}

/* ==================== MAIN CONTENT ==================== */
#content {
    flex: 1;
    margin-left: 240px;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    transition: margin-left var(--transition-slow);
}

#content.expanded {
    margin-left: 0;
}

/* Top Header - Premium Design */
.top-header {
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(20px) saturate(180%);
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    padding: 12px 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.05);
}

.header-left {
    display: flex;
    align-items: center;
    gap: 16px;
}

.page-title-box {
    display: flex;
    align-items: center;
    gap: 14px;
}

.page-title-icon {
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.15), rgba(139, 92, 246, 0.1));
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary);
    font-size: 16px;
}

.page-title-content {
    display: flex;
    flex-direction: column;
}

.page-title {
    font-size: 18px;
    font-weight: 800;
    letter-spacing: -0.3px;
    color: var(--gray-900);
    margin: 0;
}

.page-subtitle {
    font-size: 12px;
    color: var(--gray-500);
    font-weight: 500;
    margin-top: 2px;
}

.header-right {
    display: flex;
    align-items: center;
    gap: 16px;
}

/* Header Clock */
.header-clock {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 18px;
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.08), rgba(139, 92, 246, 0.05));
    border-radius: 12px;
    border: 1px solid rgba(99, 102, 241, 0.15);
}

.header-clock i {
    color: var(--primary);
    font-size: 14px;
}

.clock-time {
    font-family: 'JetBrains Mono', monospace;
    font-weight: 600;
    font-size: 14px;
    color: var(--gray-700);
}

.clock-date {
    font-size: 12px;
    color: var(--gray-500);
    border-left: 1px solid var(--gray-300);
    padding-left: 10px;
}

/* Header Button */
.header-btn {
    width: 40px;
    height: 40px;
    border: 1.5px solid var(--gray-200);
    background: white;
    border-radius: 10px;
    color: var(--gray-500);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    font-size: 15px;
    position: relative;
    text-decoration: none;
}

.header-btn:hover {
    border-color: var(--primary);
    color: var(--primary);
    background: rgba(99, 102, 241, 0.05);
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(99, 102, 241, 0.2);
}

/* Notification Dot */
.notification-wrapper {
    position: relative;
}

.notification-dot {
    position: absolute;
    top: 8px;
    right: 8px;
    width: 10px;
    height: 10px;
    background: var(--danger);
    border-radius: 50%;
    border: 2px solid white;
    animation: pulse 2s infinite;
}

/* Add Button */
.btn-add {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    font-size: 14px;
    font-weight: 700;
    border-radius: 10px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    border: none;
    color: white;
    text-decoration: none;
    transition: all 0.2s ease;
}

.btn-add:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(99, 102, 241, 0.4);
    color: white;
}

.btn-add i {
    font-size: 12px;
}

/* Theme Toggle */
.theme-toggle {
    position: relative;
    width: 56px;
    height: 28px;
    background: var(--gray-200);
    border-radius: 28px;
    cursor: pointer;
    transition: all 0.2s ease;
    border: 2px solid var(--gray-300);
}

.theme-toggle::before {
    content: "";
    position: absolute;
    top: 2px;
    left: 2px;
    width: 20px;
    height: 20px;
    background: white;
    border-radius: 50%;
    transition: all 0.2s ease;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.theme-toggle.dark {
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    border-color: var(--primary);
}

.theme-toggle.dark::before {
    transform: translateX(28px);
    background: var(--gray-900);
}

.theme-toggle i {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    font-size: 12px;
    transition: all 0.2s ease;
}

.theme-toggle .fa-sun {
    left: 8px;
    color: #f59e0b;
    opacity: 1;
}

.theme-toggle .fa-moon {
    right: 8px;
    color: var(--gray-400);
    opacity: 0.5;
}

.theme-toggle.dark .fa-sun {
    opacity: 0.5;
    color: var(--gray-400);
}

.theme-toggle.dark .fa-moon {
    opacity: 1;
    color: #f59e0b;
}

/* Header Search */
.header-search {
    position: relative;
    display: flex;
    align-items: center;
}

.header-search .search-form {
    display: none;
    align-items: center;
}

.header-search.active .header-btn {
    display: none;
}

.header-search.active .search-form {
    display: flex;
    align-items: center;
}

.search-input {
    width: 280px;
    padding: 12px 40px 12px 16px;
    border: 2px solid var(--primary);
    border-radius: 12px;
    font-size: 14px;
    outline: none;
    box-shadow: 0 0 0 4px rgba(99, 102, 241, 0.15);
    transition: all 0.2s ease;
}

.search-input:focus {
    box-shadow: 0 0 0 4px rgba(99, 102, 241, 0.25);
}

.search-input::placeholder {
    color: var(--gray-400);
}

.search-form {
    position: relative;
}

.search-close {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: var(--gray-400);
    cursor: pointer;
    font-size: 14px;
    padding: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.2s ease;
}

.search-close:hover {
    color: var(--gray-600);
}

/* Main Container */
.main-container {
    flex: 1;
    padding: 16px 20px;
    overflow-y: auto;
}

/* Page Header */
.page-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 24px;
}

.page-header h1 {
    font-size: 24px;
    font-weight: 700;
    color: var(--gray-900);
    margin: 0;
}

.page-header .subtitle {
    font-size: 14px;
    color: var(--gray-500);
    margin-top: 4px;
}

/* ==================== CARDS ==================== */
.card {
    background: #fff;
    border: 1px solid var(--gray-200);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    transition: box-shadow var(--transition);
}

.card:hover {
    box-shadow: var(--shadow);
}

.card-header {
    padding: 16px 20px;
    border-bottom: 1px solid var(--gray-100);
    background: transparent;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.card-header h5,
.card-header h6 {
    font-size: 14px;
    font-weight: 600;
    color: var(--gray-800);
    margin: 0;
    display: flex;
    align-items: center;
    gap: 8px;
}

.card-header i {
    color: var(--gray-500);
}

.card-body {
    padding: 20px;
}

.card-footer {
    padding: 12px 20px;
    border-top: 1px solid var(--gray-100);
    background: var(--gray-50);
}

/* ==================== STAT CARDS ==================== */
.stat-card {
    background: #fff;
    border: 1px solid var(--gray-200);
    border-radius: var(--radius-lg);
    padding: 20px;
    position: relative;
    overflow: hidden;
    transition: all var(--transition);
}

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

.stat-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
}

.stat-card.income::before { background: var(--success); }
.stat-card.expense::before { background: var(--danger); }
.stat-card.net::before { background: var(--primary); }
.stat-card.pending::before { background: var(--warning); }
.stat-card.info::before { background: var(--info); }

.stat-card .stat-icon {
    width: 48px;
    height: 48px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    margin-bottom: 12px;
}

.stat-card.income .stat-icon { background: rgba(16, 185, 129, 0.1); color: var(--success); }
.stat-card.expense .stat-icon { background: rgba(239, 68, 68, 0.1); color: var(--danger); }
.stat-card.net .stat-icon { background: rgba(99, 102, 241, 0.1); color: var(--primary); }
.stat-card.pending .stat-icon { background: rgba(245, 158, 11, 0.1); color: var(--warning); }
.stat-card.info .stat-icon { background: rgba(59, 130, 246, 0.1); color: var(--info); }

.stat-card .stat-label {
    font-size: 12px;
    color: var(--gray-500);
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 4px;
}

.stat-card .stat-value {
    font-size: 24px;
    font-weight: 700;
    color: var(--gray-900);
    font-family: 'JetBrains Mono', monospace;
}

.stat-card .stat-change {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 12px;
    margin-top: 8px;
}

.stat-card .stat-change.positive { color: var(--success); }
.stat-card .stat-change.negative { color: var(--danger); }

/* Legacy colored cards (Bootstrap override) */
.card.bg-primary,
.card.bg-success,
.card.bg-danger,
.card.bg-warning,
.card.bg-info {
    border: none;
}

/* ==================== TABLES ==================== */
.table {
    margin: 0;
}

.table thead th {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--gray-500);
    background: var(--gray-50);
    padding: 12px 16px;
    border-bottom: 1px solid var(--gray-200);
    white-space: nowrap;
}

.table tbody td {
    padding: 12px 16px;
    vertical-align: middle;
    border-bottom: 1px solid var(--gray-100);
    font-size: 13px;
    color: var(--gray-700);
}

.table tbody tr:hover {
    background: var(--gray-50);
}

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

/* Monospace values */
.table .amount,
.table .currency-value {
    font-family: 'JetBrains Mono', monospace;
    font-weight: 500;
}

/* Table responsive wrapper */
.table-responsive {
    margin: -20px;
    margin-top: 0;
}

.table-responsive .table {
    margin: 0;
}

/* ==================== BUTTONS ==================== */
.btn {
    font-size: 13px;
    font-weight: 500;
    padding: 8px 16px;
    border-radius: var(--radius);
    transition: all var(--transition);
    display: inline-flex;
    align-items: center;
    gap: 6px;
    border: none;
}

.btn i {
    font-size: 16px;
}

.btn-primary {
    background: var(--primary);
    color: #fff;
}

.btn-primary:hover {
    background: var(--primary-dark);
    color: #fff;
}

.btn-success {
    background: var(--success);
    color: #fff;
}

.btn-success:hover {
    background: #059669;
    color: #fff;
}

.btn-danger {
    background: var(--danger);
    color: #fff;
}

.btn-danger:hover {
    background: #dc2626;
    color: #fff;
}

.btn-secondary {
    background: var(--gray-200);
    color: var(--gray-700);
}

.btn-secondary:hover {
    background: var(--gray-300);
    color: var(--gray-800);
}

.btn-outline-primary {
    background: transparent;
    border: 1px solid var(--primary);
    color: var(--primary);
}

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

.btn-sm {
    padding: 6px 12px;
    font-size: 12px;
}

.btn-sm i {
    font-size: 14px;
}

.btn-lg {
    padding: 12px 24px;
    font-size: 15px;
}

/* ==================== FORMS ==================== */
.form-label {
    font-size: 13px;
    font-weight: 500;
    color: var(--gray-700);
    margin-bottom: 6px;
}

.form-control,
.form-select {
    font-size: 14px;
    padding: 10px 14px;
    border: 1px solid var(--gray-300);
    border-radius: var(--radius);
    transition: all var(--transition);
    background-color: #fff;
}

.form-control:focus,
.form-select:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.15);
    outline: none;
}

.form-control::placeholder {
    color: var(--gray-400);
}

.input-group .form-control {
    border-radius: var(--radius);
}

.input-group .btn {
    border-radius: var(--radius);
}

/* Form validation */
.form-control.is-invalid {
    border-color: var(--danger);
}

.form-control.is-invalid:focus {
    box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.15);
}

.invalid-feedback {
    font-size: 12px;
    color: var(--danger);
}

/* ==================== BADGES ==================== */
.badge {
    font-size: 11px;
    font-weight: 600;
    padding: 4px 8px;
    border-radius: var(--radius-sm);
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

.badge.bg-success { background: rgba(16, 185, 129, 0.15) !important; color: var(--success) !important; }
.badge.bg-danger { background: rgba(239, 68, 68, 0.15) !important; color: var(--danger) !important; }
.badge.bg-warning { background: rgba(245, 158, 11, 0.15) !important; color: var(--warning) !important; }
.badge.bg-info { background: rgba(59, 130, 246, 0.15) !important; color: var(--info) !important; }
.badge.bg-primary { background: rgba(99, 102, 241, 0.15) !important; color: var(--primary) !important; }
.badge.bg-secondary { background: var(--gray-200) !important; color: var(--gray-600) !important; }

/* Status badges */
.status-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    font-weight: 500;
    padding: 4px 10px;
    border-radius: 20px;
}

.status-badge::before {
    content: '';
    width: 6px;
    height: 6px;
    border-radius: 50%;
}

.status-badge.active::before { background: var(--success); }
.status-badge.active { background: rgba(16, 185, 129, 0.1); color: var(--success); }

.status-badge.inactive::before { background: var(--gray-400); }
.status-badge.inactive { background: var(--gray-100); color: var(--gray-500); }

.status-badge.pending::before { background: var(--warning); }
.status-badge.pending { background: rgba(245, 158, 11, 0.1); color: var(--warning); }

/* ==================== ALERTS ==================== */
.alert {
    border: none;
    border-radius: var(--radius-md);
    padding: 14px 18px;
    font-size: 13px;
    display: flex;
    align-items: flex-start;
    gap: 12px;
}

.alert i {
    font-size: 18px;
    margin-top: 1px;
}

.alert-success {
    background: rgba(16, 185, 129, 0.1);
    color: #065f46;
}

.alert-danger {
    background: rgba(239, 68, 68, 0.1);
    color: #991b1b;
}

.alert-warning {
    background: rgba(245, 158, 11, 0.1);
    color: #92400e;
}

.alert-info {
    background: rgba(59, 130, 246, 0.1);
    color: #1e40af;
}

/* ==================== LOGIN PAGE - PREMIUM ==================== */
.login-screen {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #0f172a 0%, #1e1b4b 40%, #312e81 70%, #0f172a 100%);
    position: relative;
    overflow: hidden;
}

.login-screen::before {
    content: '';
    position: absolute;
    width: 800px;
    height: 800px;
    background: radial-gradient(circle, rgba(99,102,241,0.3) 0%, transparent 70%);
    top: -200px;
    right: -200px;
    animation: loginFloat 8s ease-in-out infinite;
}

.login-screen::after {
    content: '';
    position: absolute;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(139,92,246,0.25) 0%, transparent 70%);
    bottom: -150px;
    left: -150px;
    animation: loginFloat 8s ease-in-out infinite 4s;
}

@keyframes loginFloat {
    0%, 100% { transform: translateY(0) scale(1) rotate(0deg); }
    50% { transform: translateY(-40px) scale(1.1) rotate(5deg); }
}

.login-box {
    display: flex;
    background: rgba(15, 23, 42, 0.8);
    backdrop-filter: blur(40px) saturate(180%);
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5), 0 0 100px rgba(99,102,241,0.15), inset 0 1px 0 rgba(255,255,255,0.1);
    border: 1px solid rgba(255, 255, 255, 0.08);
    max-width: 920px;
    width: 92%;
    position: relative;
    z-index: 1;
}

.login-left {
    flex: 1;
    padding: 48px;
    background: linear-gradient(135deg, rgba(99,102,241,0.08), rgba(139,92,246,0.05));
    display: flex;
    flex-direction: column;
    justify-content: center;
    border-right: 1px solid rgba(255, 255, 255, 0.08);
}

.login-brand {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 36px;
}

.login-brand-icon {
    width: 64px;
    height: 64px;
    background: linear-gradient(135deg, var(--primary), var(--secondary), #ec4899);
    background-size: 200% 200%;
    animation: gradientShift 5s ease infinite;
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
    color: white;
    box-shadow: 0 12px 40px rgba(99,102,241,0.4), inset 0 1px 0 rgba(255,255,255,0.2);
}

.login-brand h1 {
    font-size: 32px;
    font-weight: 900;
    color: white;
    letter-spacing: -1px;
    margin: 0;
}

.login-brand span {
    display: block;
    font-size: 12px;
    color: var(--primary-light);
    letter-spacing: 3px;
    text-transform: uppercase;
    font-weight: 500;
    margin-top: 2px;
}

.login-features {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.login-feature {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 16px 20px;
    background: rgba(255,255,255,0.03);
    border-radius: 12px;
    border: 1px solid rgba(255,255,255,0.05);
    transition: all 0.3s ease;
    cursor: default;
}

.login-feature:hover {
    background: rgba(255,255,255,0.08);
    transform: translateX(12px);
    border-color: rgba(99,102,241,0.4);
    box-shadow: 0 8px 32px rgba(99,102,241,0.2);
}

.login-feature i {
    font-size: 22px;
    width: 44px;
    height: 44px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    box-shadow: 0 4px 20px rgba(99, 102, 241, 0.3);
    flex-shrink: 0;
}

.login-feature h4 {
    color: white;
    font-size: 14px;
    font-weight: 700;
    margin: 0;
}

.login-feature p {
    color: var(--gray-400);
    font-size: 12px;
    margin: 2px 0 0 0;
}

.login-right {
    width: 380px;
    padding: 48px;
    background: white;
}

.login-right h2 {
    font-size: 28px;
    font-weight: 900;
    margin-bottom: 8px;
    letter-spacing: -0.5px;
    color: var(--gray-900);
}

.login-right > p {
    color: var(--gray-500);
    margin-bottom: 28px;
    font-size: 14px;
}

.login-right .form-group {
    margin-bottom: 16px;
}

.login-right .form-group label {
    display: block;
    font-size: 11px;
    font-weight: 700;
    color: var(--gray-700);
    margin-bottom: 6px;
    letter-spacing: 0.3px;
}

.login-right .form-control {
    width: 100%;
    padding: 12px 14px;
    font-size: 14px;
    border: 2px solid var(--gray-200);
    border-radius: 10px;
    background: var(--gray-50);
    transition: all 0.2s ease;
}

.login-right .form-control:focus {
    border-color: var(--primary);
    background: white;
    box-shadow: 0 0 0 4px rgba(99, 102, 241, 0.1);
    outline: none;
}

.login-right .form-control::placeholder {
    color: var(--gray-400);
}

.login-right .btn-primary {
    width: 100%;
    padding: 12px 20px;
    font-size: 14px;
    font-weight: 700;
    border-radius: 10px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    border: none;
    color: white;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-top: 8px;
}

.login-right .btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(99, 102, 241, 0.4);
}

.login-right .btn-primary i {
    font-size: 16px;
}

.login-error {
    padding: 12px 16px;
    background: rgba(239,68,68,0.1);
    border: 1px solid rgba(239,68,68,0.3);
    border-radius: 12px;
    color: var(--danger);
    margin-bottom: 20px;
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.login-demo-info {
    margin-top: 24px;
    padding-top: 24px;
    border-top: 1px solid var(--gray-200);
    text-align: center;
}

.login-demo-info p {
    font-size: 13px;
    color: var(--gray-500);
    margin: 0;
}

.login-demo-info strong {
    color: var(--primary);
}

/* Simple login (fallback) */
.login-container {
    width: 100%;
    max-width: 400px;
    padding: 20px;
    margin: auto;
}

.login-card {
    background: #fff;
    border-radius: var(--radius-xl);
    padding: 40px;
    box-shadow: var(--shadow-xl);
}

.login-header {
    text-align: center;
    margin-bottom: 32px;
}

.login-header .logo-icon {
    width: 64px;
    height: 64px;
    background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
    color: #fff;
    margin: 0 auto 16px;
}

.login-header h2 {
    font-size: 24px;
    font-weight: 700;
    color: var(--gray-900);
    margin-bottom: 4px;
}

.login-header p {
    color: var(--gray-500);
    font-size: 14px;
}

/* ==================== DROPDOWN ==================== */
.dropdown-menu {
    border: 1px solid var(--gray-200);
    box-shadow: var(--shadow-lg);
    border-radius: var(--radius-md);
    padding: 8px;
    min-width: 200px;
}

.dropdown-item {
    padding: 10px 14px;
    font-size: 13px;
    border-radius: var(--radius);
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--gray-700);
}

.dropdown-item:hover {
    background: var(--gray-100);
    color: var(--gray-900);
}

.dropdown-item i {
    font-size: 16px;
    color: var(--gray-500);
}

.dropdown-divider {
    margin: 8px 0;
    border-color: var(--gray-200);
}

/* ==================== MODAL ==================== */
.modal-content {
    border: none;
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-xl);
}

.modal-header {
    padding: 20px 24px;
    border-bottom: 1px solid var(--gray-200);
}

.modal-title {
    font-size: 18px;
    font-weight: 600;
    color: var(--gray-900);
}

.modal-body {
    padding: 24px;
}

.modal-footer {
    padding: 16px 24px;
    border-top: 1px solid var(--gray-200);
    gap: 8px;
}

/* ==================== PAGINATION ==================== */
.pagination {
    gap: 4px;
}

.page-item .page-link {
    border: none;
    border-radius: var(--radius);
    padding: 8px 14px;
    font-size: 13px;
    font-weight: 500;
    color: var(--gray-600);
}

.page-item .page-link:hover {
    background: var(--gray-100);
    color: var(--gray-900);
}

.page-item.active .page-link {
    background: var(--primary);
    color: #fff;
}

.page-item.disabled .page-link {
    background: transparent;
    color: var(--gray-400);
}

/* ==================== BALANCE BOXES ==================== */
.balance-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 16px;
}

.balance-box {
    background: var(--gray-50);
    border: 1px solid var(--gray-200);
    border-radius: var(--radius-md);
    padding: 16px;
    text-align: center;
}

.balance-box .currency {
    font-size: 11px;
    font-weight: 600;
    color: var(--gray-500);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 4px;
}

.balance-box .amount {
    font-size: 18px;
    font-weight: 700;
    font-family: 'JetBrains Mono', monospace;
}

.balance-box .amount.positive { color: var(--success); }
.balance-box .amount.negative { color: var(--danger); }

/* ==================== UTILITIES ==================== */
.text-success { color: var(--success) !important; }
.text-danger { color: var(--danger) !important; }
.text-warning { color: var(--warning) !important; }
.text-info { color: var(--info) !important; }
.text-primary { color: var(--primary) !important; }
.text-muted { color: var(--gray-500) !important; }

.bg-success-light { background: rgba(16, 185, 129, 0.1); }
.bg-danger-light { background: rgba(239, 68, 68, 0.1); }
.bg-warning-light { background: rgba(245, 158, 11, 0.1); }
.bg-info-light { background: rgba(59, 130, 246, 0.1); }
.bg-primary-light { background: rgba(99, 102, 241, 0.1); }

.font-mono {
    font-family: 'JetBrains Mono', monospace;
}

/* ==================== SCROLLBAR ==================== */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: var(--gray-100);
}

::-webkit-scrollbar-thumb {
    background: var(--gray-300);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--gray-400);
}

/* ==================== STATS GRID & CARDS ==================== */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 14px;
    margin-bottom: 18px;
}

.stat-card {
    background: white;
    border-radius: var(--radius-lg);
    padding: 16px;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.07), 0 2px 4px -2px rgba(0, 0, 0, 0.05);
    position: relative;
    overflow: hidden;
    border: 1px solid rgba(0, 0, 0, 0.04);
    transition: all 0.2s ease;
}

.stat-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: linear-gradient(180deg, var(--primary), var(--secondary));
}

.stat-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.08), 0 8px 10px -6px rgba(0, 0, 0, 0.05), 0 0 20px rgba(99, 102, 241, 0.1);
}

.stat-card.success::before {
    background: linear-gradient(180deg, var(--success), #34d399);
}

.stat-card.warning::before {
    background: linear-gradient(180deg, var(--warning), #fbbf24);
}

.stat-card.danger::before {
    background: linear-gradient(180deg, var(--danger), #f87171);
}

.stat-card.info::before {
    background: linear-gradient(180deg, var(--info), #22d3ee);
}

.stat-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    margin-bottom: 12px;
}

.stat-icon {
    width: 40px;
    height: 40px;
    border-radius: var(--radius);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    transition: all 0.2s ease;
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.12), rgba(129, 140, 248, 0.06));
    color: var(--primary);
}

.stat-card.success .stat-icon {
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.12), rgba(52, 211, 153, 0.06));
    color: var(--success);
}

.stat-card.warning .stat-icon {
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.12), rgba(251, 191, 36, 0.06));
    color: var(--warning);
}

.stat-card.danger .stat-icon {
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.12), rgba(248, 113, 113, 0.06));
    color: var(--danger);
}

.stat-card.info .stat-icon {
    background: linear-gradient(135deg, rgba(6, 182, 212, 0.12), rgba(34, 211, 238, 0.06));
    color: var(--info);
}

.stat-card:hover .stat-icon {
    transform: scale(1.15) rotate(-5deg);
}

.stat-trend {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 10px;
    font-weight: 700;
    padding: 4px 10px;
    border-radius: 14px;
}

.stat-trend.up {
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.15), rgba(52, 211, 153, 0.08));
    color: var(--success);
}

.stat-trend.down {
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.15), rgba(248, 113, 113, 0.08));
    color: var(--danger);
}

.stat-value {
    font-size: 22px;
    font-weight: 800;
    font-family: 'JetBrains Mono', monospace;
    letter-spacing: -0.5px;
    color: var(--gray-900);
}

.stat-label {
    font-size: 11px;
    color: var(--gray-500);
    margin-top: 4px;
    font-weight: 600;
}

.stat-sub {
    font-size: 10px;
    color: var(--gray-400);
    margin-top: 10px;
    padding-top: 10px;
    border-top: 1px dashed var(--gray-200);
}

/* Dark Mode - Stats */
[data-theme="dark"] .stat-card {
    background: #1e293b;
    border-color: rgba(255, 255, 255, 0.05);
}

[data-theme="dark"] .stat-value {
    color: #f1f5f9;
}

[data-theme="dark"] .stat-label {
    color: #94a3b8;
}

[data-theme="dark"] .stat-sub {
    color: #64748b;
    border-top-color: #334155;
}

/* ==================== QUICK ACTIONS ==================== */
.quick-actions {
    display: flex;
    gap: 8px;
    margin-bottom: 16px;
    flex-wrap: wrap;
    padding: 12px 14px;
    background: white;
    border-radius: var(--radius);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.07), 0 2px 4px -2px rgba(0, 0, 0, 0.05);
    border: 1px solid rgba(0, 0, 0, 0.04);
}

.quick-action-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 14px;
    background: linear-gradient(135deg, var(--gray-50), white);
    border: 1.5px solid var(--gray-200);
    border-radius: var(--radius);
    font-size: 11px;
    font-weight: 600;
    color: var(--gray-700);
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
}

.quick-action-btn:hover {
    border-color: var(--primary);
    color: var(--primary);
    background: white;
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(99, 102, 241, 0.12);
}

.quick-action-btn:active {
    transform: translateY(-1px);
}

.quick-action-btn i {
    color: var(--primary);
    font-size: 12px;
    width: 22px;
    height: 22px;
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.1), rgba(139, 92, 246, 0.05));
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.quick-action-btn:hover i {
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: white;
}

/* Dark Mode - Quick Actions */
[data-theme="dark"] .quick-actions {
    background: #1e293b;
    border-color: rgba(255, 255, 255, 0.05);
}

[data-theme="dark"] .quick-action-btn {
    background: rgba(99, 102, 241, 0.1);
    border-color: #334155;
    color: #e2e8f0;
}

[data-theme="dark"] .quick-action-btn:hover {
    background: rgba(99, 102, 241, 0.2);
    border-color: var(--primary);
}

/* ==================== TABLES - PREMIUM ==================== */
table {
    width: 100%;
    border-collapse: collapse;
}

table th,
table td {
    padding: 10px 12px;
    text-align: left;
}

table th {
    font-size: 10px;
    font-weight: 700;
    color: var(--gray-500);
    text-transform: uppercase;
    letter-spacing: 0.8px;
    background: linear-gradient(180deg, var(--gray-50), var(--gray-100));
    border-bottom: 1.5px solid var(--gray-200);
}

table td {
    font-size: 12px;
    color: var(--gray-700);
    border-bottom: 1px solid var(--gray-100);
    transition: all 0.1s ease;
}

table tbody tr {
    transition: all 0.1s ease;
}

table tbody tr:hover {
    background: linear-gradient(90deg, rgba(99, 102, 241, 0.04), rgba(139, 92, 246, 0.02), transparent);
}

table tbody tr:hover td {
    color: var(--gray-900);
}

/* Amount Formatting */
.amount {
    font-family: 'JetBrains Mono', monospace;
    font-weight: 700;
    font-size: 12px;
}

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

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

.mono {
    font-family: 'JetBrains Mono', monospace;
}

/* Dark Mode - Tables */
[data-theme="dark"] table th {
    background: rgba(99, 102, 241, 0.15);
    color: #94a3b8;
    border-bottom-color: #334155;
}

[data-theme="dark"] table td {
    color: #cbd5e1;
    border-bottom-color: #334155;
}

[data-theme="dark"] table tbody tr:hover {
    background: rgba(99, 102, 241, 0.1);
}

/* ==================== BADGES - PREMIUM ==================== */
.badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 10px;
    border-radius: 16px;
    font-size: 10px;
    font-weight: 600;
    transition: all 0.1s ease;
    letter-spacing: 0.2px;
}

.badge.success {
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.15), rgba(52, 211, 153, 0.08));
    color: var(--success);
    border: 1px solid rgba(16, 185, 129, 0.2);
}

.badge.warning {
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.15), rgba(251, 191, 36, 0.08));
    color: var(--warning);
    border: 1px solid rgba(245, 158, 11, 0.2);
}

.badge.danger {
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.15), rgba(248, 113, 113, 0.08));
    color: var(--danger);
    border: 1px solid rgba(239, 68, 68, 0.2);
}

.badge.info {
    background: linear-gradient(135deg, rgba(6, 182, 212, 0.15), rgba(34, 211, 238, 0.08));
    color: var(--info);
    border: 1px solid rgba(6, 182, 212, 0.2);
}

.badge.primary {
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.15), rgba(129, 140, 248, 0.08));
    color: var(--primary);
    border: 1px solid rgba(99, 102, 241, 0.2);
}

.badge.secondary {
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.15), rgba(167, 139, 250, 0.08));
    color: var(--secondary);
    border: 1px solid rgba(139, 92, 246, 0.2);
}

.badge.gray {
    background: var(--gray-100);
    color: var(--gray-600);
    border: 1px solid var(--gray-200);
}

/* ==================== ACTION BUTTONS ==================== */
.actions {
    display: flex;
    gap: 6px;
}

.action-btn {
    width: 32px;
    height: 32px;
    border: 1.5px solid var(--gray-200);
    background: white;
    border-radius: 8px;
    color: var(--gray-500);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    font-size: 12px;
    text-decoration: none;
}

.action-btn:hover {
    border-color: var(--primary);
    color: var(--primary);
    background: rgba(99, 102, 241, 0.05);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.15);
}

.action-btn.danger:hover {
    border-color: var(--danger);
    color: var(--danger);
    background: rgba(239, 68, 68, 0.05);
    box-shadow: 0 4px 12px rgba(239, 68, 68, 0.15);
}

/* Dark Mode - Action Buttons */
[data-theme="dark"] .action-btn {
    background: #334155;
    border-color: #475569;
    color: #94a3b8;
}

[data-theme="dark"] .action-btn:hover {
    background: rgba(99, 102, 241, 0.15);
    border-color: var(--primary);
    color: var(--primary);
}

/* ==================== ACCOUNT ICON ==================== */
.account-icon {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    color: white;
}

.account-icon.tl {
    background: linear-gradient(135deg, #10b981, #059669);
}

.account-icon.usd {
    background: linear-gradient(135deg, #3b82f6, #1d4ed8);
}

.account-icon.eur {
    background: linear-gradient(135deg, #8b5cf6, #7c3aed);
}

/* ==================== GRID LAYOUTS ==================== */
.grid-2 {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 14px;
}

.grid-3 {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 14px;
}

.grid-4 {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 12px;
}

/* ==================== MODAL - PREMIUM ==================== */
/* Use custom-modal classes to avoid Bootstrap modal conflicts */
.custom-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(15, 23, 42, 0.6);
    backdrop-filter: blur(4px);
    z-index: 2000;
    display: none;
    align-items: center;
    justify-content: center;
}

.custom-modal-overlay.active {
    display: flex;
}

.custom-modal {
    background: white;
    border-radius: var(--radius-lg);
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    max-width: 500px;
    width: 95%;
    max-height: 90vh;
    overflow: hidden;
    animation: modalSlideIn 0.3s ease;
}

/* Legacy support - keep old classes for other pages */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(15, 23, 42, 0.6);
    backdrop-filter: blur(4px);
    z-index: 2000;
    display: none;
    align-items: center;
    justify-content: center;
}

.modal-overlay.active {
    display: flex;
}

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: translateY(-20px) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.modal-header {
    padding: 16px 20px;
    border-bottom: 1px solid var(--gray-100);
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: linear-gradient(135deg, rgba(248, 250, 252, 1), rgba(241, 245, 249, 0.8));
}

.modal-title {
    font-size: 16px;
    font-weight: 700;
    color: var(--gray-900);
    display: flex;
    align-items: center;
    gap: 10px;
}

.modal-title i {
    color: var(--primary);
}

.modal-close {
    width: 32px;
    height: 32px;
    border: none;
    background: transparent;
    color: var(--gray-400);
    cursor: pointer;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}

.modal-close:hover {
    background: var(--gray-100);
    color: var(--gray-600);
}

.modal-body {
    padding: 20px;
    overflow-y: auto;
    max-height: 60vh;
}

.modal-footer {
    padding: 16px 20px;
    border-top: 1px solid var(--gray-100);
    display: flex;
    gap: 10px;
    justify-content: flex-end;
    background: var(--gray-50);
}

/* Dark Mode - Modal */
[data-theme="dark"] .custom-modal,
[data-theme="dark"] .modal-overlay .custom-modal,
[data-theme="dark"] .modal {
    background: #1e293b !important;
    border: 1px solid #334155 !important;
    color: #e2e8f0 !important;
}

[data-theme="dark"] .modal-header,
[data-theme="dark"] .custom-modal .modal-header,
[data-theme="dark"] .modal-overlay .modal-header {
    background: rgba(99, 102, 241, 0.1) !important;
    border-bottom-color: #334155 !important;
}

[data-theme="dark"] .modal-title,
[data-theme="dark"] .custom-modal .modal-title,
[data-theme="dark"] .modal-overlay .modal-title {
    color: #f1f5f9 !important;
}

[data-theme="dark"] .modal-footer,
[data-theme="dark"] .custom-modal .modal-footer,
[data-theme="dark"] .modal-overlay .modal-footer {
    background: rgba(15, 23, 42, 0.5) !important;
    border-top-color: #334155 !important;
}

[data-theme="dark"] .modal-body,
[data-theme="dark"] .custom-modal .modal-body,
[data-theme="dark"] .modal-overlay .modal-body {
    background: #1e293b !important;
}

[data-theme="dark"] .modal-close,
[data-theme="dark"] .custom-modal .modal-close,
[data-theme="dark"] .modal-overlay .modal-close {
    color: #94a3b8 !important;
}

[data-theme="dark"] .modal-close:hover,
[data-theme="dark"] .custom-modal .modal-close:hover,
[data-theme="dark"] .modal-overlay .modal-close:hover {
    background: #334155 !important;
    color: #f1f5f9 !important;
}

/* Dark Mode - Modal Form Elements */
[data-theme="dark"] .custom-modal .info-section,
[data-theme="dark"] .modal-overlay .info-section {
    background: #0f172a;
    border-color: #334155;
}

[data-theme="dark"] .custom-modal .bank-section,
[data-theme="dark"] .modal-overlay .bank-section {
    background: linear-gradient(135deg, rgba(16,185,129,0.1), rgba(6,182,212,0.1));
    border-color: #334155;
}

[data-theme="dark"] .custom-modal .category-btn,
[data-theme="dark"] .modal-overlay .category-btn {
    background: #0f172a;
    border-color: #334155;
    color: #e2e8f0;
}

[data-theme="dark"] .custom-modal .category-btn:hover,
[data-theme="dark"] .modal-overlay .category-btn:hover {
    border-color: var(--primary);
    background: rgba(99, 102, 241, 0.1);
}

[data-theme="dark"] .custom-modal .category-btn.active,
[data-theme="dark"] .modal-overlay .category-btn.active {
    border-color: var(--primary);
    background: rgba(99, 102, 241, 0.15);
}

[data-theme="dark"] .custom-modal .form-control,
[data-theme="dark"] .modal-overlay .form-control,
[data-theme="dark"] .custom-modal-overlay .form-control,
[data-theme="dark"] .custom-modal .form-select,
[data-theme="dark"] .modal-overlay .form-select,
[data-theme="dark"] .custom-modal-overlay .form-select,
[data-theme="dark"] .custom-modal input[type="text"],
[data-theme="dark"] .custom-modal input[type="email"],
[data-theme="dark"] .custom-modal input[type="password"],
[data-theme="dark"] .custom-modal input[type="number"],
[data-theme="dark"] .custom-modal input[type="date"],
[data-theme="dark"] .custom-modal select,
[data-theme="dark"] .modal-overlay input[type="text"],
[data-theme="dark"] .modal-overlay input[type="email"],
[data-theme="dark"] .modal-overlay input[type="password"],
[data-theme="dark"] .modal-overlay input[type="number"],
[data-theme="dark"] .modal-overlay input[type="date"],
[data-theme="dark"] .modal-overlay select,
[data-theme="dark"] .custom-modal-overlay input[type="text"],
[data-theme="dark"] .custom-modal-overlay input[type="email"],
[data-theme="dark"] .custom-modal-overlay input[type="password"],
[data-theme="dark"] .custom-modal-overlay input[type="number"],
[data-theme="dark"] .custom-modal-overlay input[type="date"],
[data-theme="dark"] .custom-modal-overlay select {
    background: #0f172a !important;
    border-color: #334155 !important;
    color: #e2e8f0 !important;
}

[data-theme="dark"] .custom-modal .form-control:focus,
[data-theme="dark"] .modal-overlay .form-control:focus,
[data-theme="dark"] .custom-modal .form-select:focus,
[data-theme="dark"] .modal-overlay .form-select:focus,
[data-theme="dark"] .custom-modal input:focus,
[data-theme="dark"] .custom-modal select:focus,
[data-theme="dark"] .modal-overlay input:focus,
[data-theme="dark"] .modal-overlay select:focus {
    background: #1e293b !important;
    border-color: var(--primary) !important;
}

[data-theme="dark"] .custom-modal .form-control::placeholder,
[data-theme="dark"] .modal-overlay .form-control::placeholder {
    color: #64748b;
}

/* Chrome/Safari autofill override for dark mode */
[data-theme="dark"] input:-webkit-autofill,
[data-theme="dark"] input:-webkit-autofill:hover,
[data-theme="dark"] input:-webkit-autofill:focus,
[data-theme="dark"] input:-webkit-autofill:active,
[data-theme="dark"] select:-webkit-autofill,
[data-theme="dark"] textarea:-webkit-autofill {
    -webkit-box-shadow: 0 0 0 1000px #0f172a inset !important;
    -webkit-text-fill-color: #e2e8f0 !important;
    box-shadow: 0 0 0 1000px #0f172a inset !important;
    caret-color: #e2e8f0 !important;
    transition: background-color 5000s ease-in-out 0s;
}

[data-theme="dark"] .custom-modal label,
[data-theme="dark"] .modal-overlay label,
[data-theme="dark"] .custom-modal-overlay label {
    color: #94a3b8;
}

/* Dark mode disabled inputs */
[data-theme="dark"] input:disabled,
[data-theme="dark"] input[disabled],
[data-theme="dark"] select:disabled,
[data-theme="dark"] select[disabled],
[data-theme="dark"] .form-control:disabled,
[data-theme="dark"] .form-control[disabled],
[data-theme="dark"] .form-select:disabled,
[data-theme="dark"] .form-select[disabled] {
    background: #1e293b !important;
    border-color: #334155 !important;
    color: #64748b !important;
    opacity: 0.7;
    cursor: not-allowed;
}

[data-theme="dark"] .custom-modal .info-section h4,
[data-theme="dark"] .modal-overlay .info-section h4 {
    color: #94a3b8;
}

[data-theme="dark"] .custom-modal .info-section h4.primary,
[data-theme="dark"] .modal-overlay .info-section h4.primary {
    color: var(--primary);
}

[data-theme="dark"] .custom-modal .info-section h4.success,
[data-theme="dark"] .modal-overlay .info-section h4.success {
    color: var(--success);
}

[data-theme="dark"] .custom-modal .info-section h4.warning,
[data-theme="dark"] .modal-overlay .info-section h4.warning {
    color: var(--warning);
}

[data-theme="dark"] .custom-modal .info-section h4.info,
[data-theme="dark"] .modal-overlay .info-section h4.info {
    color: var(--info);
}

/* Dark Mode - Modal Tables */
[data-theme="dark"] .custom-modal table,
[data-theme="dark"] .modal-overlay table {
    background: #1e293b !important;
}

[data-theme="dark"] .custom-modal table thead,
[data-theme="dark"] .modal-overlay table thead {
    background: #0f172a !important;
}

[data-theme="dark"] .custom-modal table thead th,
[data-theme="dark"] .modal-overlay table thead th {
    background: #0f172a !important;
    color: #94a3b8 !important;
    border-color: #334155 !important;
}

[data-theme="dark"] .custom-modal table tbody tr,
[data-theme="dark"] .modal-overlay table tbody tr {
    background: #1e293b !important;
    border-color: #334155 !important;
}

[data-theme="dark"] .custom-modal table tbody tr:hover,
[data-theme="dark"] .modal-overlay table tbody tr:hover {
    background: #334155 !important;
}

[data-theme="dark"] .custom-modal table tbody td,
[data-theme="dark"] .modal-overlay table tbody td {
    color: #e2e8f0 !important;
    border-color: #334155 !important;
}

/* Dark Mode - Modal Checkbox */
[data-theme="dark"] .custom-modal .form-check span,
[data-theme="dark"] .modal-overlay .form-check span,
[data-theme="dark"] .custom-modal .form-check-label,
[data-theme="dark"] .modal-overlay .form-check-label {
    color: #94a3b8 !important;
}

/* ==================== BUTTONS - PREMIUM ==================== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 10px 18px;
    border: none;
    border-radius: var(--radius);
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
    letter-spacing: 0.2px;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: white;
    box-shadow: 0 4px 20px rgba(99, 102, 241, 0.3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(99, 102, 241, 0.4);
    color: white;
}

.btn-secondary {
    background: white;
    color: var(--gray-700);
    border: 2px solid var(--gray-200);
}

.btn-secondary:hover {
    background: var(--gray-50);
    border-color: var(--primary);
    color: var(--primary);
}

.btn-success {
    background: linear-gradient(135deg, var(--success), #059669);
    color: white;
    box-shadow: 0 4px 20px rgba(16, 185, 129, 0.3);
}

.btn-success:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(16, 185, 129, 0.4);
}

.btn-danger {
    background: linear-gradient(135deg, var(--danger), #dc2626);
    color: white;
    box-shadow: 0 4px 20px rgba(239, 68, 68, 0.3);
}

.btn-danger:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(239, 68, 68, 0.4);
}

/* Dark Mode - Buttons */
[data-theme="dark"] .btn-secondary {
    background: #334155;
    border-color: #475569;
    color: #e2e8f0;
}

[data-theme="dark"] .btn-secondary:hover {
    background: rgba(99, 102, 241, 0.15);
    border-color: var(--primary);
    color: var(--primary);
}

/* ==================== CARD HEADER TITLE ==================== */
.card-title {
    font-size: 13px;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--gray-900);
    letter-spacing: -0.2px;
    margin: 0;
}

.card-title i {
    color: white;
    font-size: 11px;
    width: 26px;
    height: 26px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 10px rgba(99, 102, 241, 0.3);
}

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

/* Dark Mode - Card Title */
[data-theme="dark"] .card-title {
    color: #f1f5f9;
}

/* ==================== FORM ELEMENTS ==================== */
.form-group {
    margin-bottom: 14px;
}

.form-group label {
    display: block;
    font-size: 11px;
    font-weight: 700;
    color: var(--gray-700);
    margin-bottom: 6px;
    letter-spacing: 0.3px;
}

[data-theme="dark"] .form-group label {
    color: #94a3b8;
}

/* ==================== RESPONSIVE - STATS ==================== */
@media (max-width: 1200px) {
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .stats-grid {
        grid-template-columns: 1fr;
    }

    .grid-2,
    .grid-3,
    .grid-4 {
        grid-template-columns: 1fr;
    }

    .quick-actions {
        flex-direction: column;
    }

    .quick-action-btn {
        width: 100%;
        justify-content: center;
    }
}

/* ==================== STATS GRID 5 COLUMNS ==================== */
.stats-grid-5 {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 16px;
    margin-bottom: 24px;
}

/* Gradient Stat Cards */
.stat-card-gradient {
    border-radius: var(--radius-lg);
    color: white;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
    transition: all 0.2s ease;
}

.stat-card-gradient:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.2);
}

.stat-card-gradient.blue {
    background: linear-gradient(135deg, #3b82f6, #1d4ed8);
}

.stat-card-gradient.purple {
    background: linear-gradient(135deg, #8b5cf6, #7c3aed);
}

.stat-card-gradient.green {
    background: linear-gradient(135deg, #10b981, #059669);
}

.stat-card-gradient.orange {
    background: linear-gradient(135deg, #f59e0b, #d97706);
}

.stat-card-gradient.red {
    background: linear-gradient(135deg, #ef4444, #dc2626);
}

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

.stat-card-label {
    font-size: 11px;
    opacity: 0.8;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.stat-card-value {
    font-size: 28px;
    font-weight: 800;
    margin-top: 4px;
    font-family: 'JetBrains Mono', monospace;
}

.stat-card-sub {
    font-size: 11px;
    opacity: 0.7;
}

/* Check Type Icon */
.check-type-icon {
    width: 36px;
    height: 36px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.check-type-icon.cek {
    background: rgba(59, 130, 246, 0.1);
    color: var(--primary);
}

.check-type-icon.senet {
    background: rgba(139, 92, 246, 0.1);
    color: var(--secondary);
}

/* Button Group Filter */
.btn-group-filter {
    display: flex;
    gap: 4px;
}

/* Action Button Variants */
.action-btn.success {
    background: rgba(16, 185, 129, 0.1);
    color: var(--success);
    border-color: rgba(16, 185, 129, 0.2);
}

.action-btn.success:hover {
    background: var(--success);
    color: white;
    border-color: var(--success);
}

/* Badge Secondary */
.badge.secondary {
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.15), rgba(167, 139, 250, 0.08));
    color: var(--secondary);
    border: 1px solid rgba(139, 92, 246, 0.2);
}

/* Button Sizes */
.btn-sm {
    padding: 7px 12px;
    font-size: 11px;
}

/* Responsive - 5 Grid */
@media (max-width: 1200px) {
    .stats-grid-5 {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 768px) {
    .stats-grid-5 {
        grid-template-columns: repeat(2, 1fr);
    }

    .stat-card-value {
        font-size: 22px;
    }
}

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

/* ==================== RESPONSIVE ==================== */
@media (max-width: 1024px) {
    .login-box {
        flex-direction: column;
    }

    .login-left {
        display: none;
    }

    .login-right {
        width: 100%;
        padding: 48px 32px;
    }
}

@media (max-width: 768px) {
    .sidebar {
        transform: translateX(-100%);
    }

    .sidebar.active {
        transform: translateX(0);
    }

    #content {
        margin-left: 0;
    }

    .main-container {
        padding: 16px;
    }

    .stat-card .stat-value {
        font-size: 20px;
    }
}

/* ==================== EMPTY STATE ==================== */
.empty-state {
    text-align: center;
    padding: 48px 24px;
}

.empty-state .empty-icon {
    width: 64px;
    height: 64px;
    background: var(--gray-100);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 16px;
    font-size: 24px;
    color: var(--gray-400);
}

.empty-state h4 {
    font-size: 16px;
    font-weight: 600;
    color: var(--gray-700);
    margin-bottom: 8px;
}

.empty-state p {
    font-size: 14px;
    color: var(--gray-500);
    margin-bottom: 20px;
}

/* ==================== LOADING ==================== */
.loading-spinner {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 2px solid var(--gray-200);
    border-top-color: var(--primary);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

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

/* Override Bootstrap */
.navbar {
    padding: 0;
}

.navbar.bg-white {
    background: #fff !important;
}

.container-fluid.py-4 {
    padding: 24px !important;
}

/* ==================== NOTIFICATION DROPDOWN ==================== */
.notification-dropdown {
    position: absolute;
    top: calc(100% + 12px);
    right: 0;
    width: 360px;
    background: white;
    border-radius: 16px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
    border: 1px solid var(--gray-100);
    z-index: 100;
    overflow: hidden;
    display: none;
    animation: dropdownFadeIn 0.2s ease;
}

.notification-dropdown.active {
    display: block;
}

@keyframes dropdownFadeIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.notification-header {
    padding: 16px 20px;
    border-bottom: 1px solid var(--gray-100);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.notification-title {
    font-weight: 700;
    font-size: 15px;
    color: var(--gray-800);
}

.notification-count {
    background: var(--danger);
    color: white;
    padding: 2px 10px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 700;
}

.notification-list {
    max-height: 320px;
    overflow-y: auto;
}

.notification-item {
    padding: 16px 20px;
    border-bottom: 1px solid var(--gray-50);
    display: flex;
    gap: 14px;
    cursor: pointer;
    transition: background 0.2s ease;
}

.notification-item:hover {
    background: var(--gray-50);
}

.notification-item:last-child {
    border-bottom: none;
}

.notification-icon {
    width: 40px;
    height: 40px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 14px;
}

.notification-item.warning .notification-icon {
    background: rgba(245, 158, 11, 0.15);
    color: var(--warning);
}

.notification-item.info .notification-icon {
    background: rgba(6, 182, 212, 0.15);
    color: var(--info);
}

.notification-item.success .notification-icon {
    background: rgba(16, 185, 129, 0.15);
    color: var(--success);
}

.notification-content {
    flex: 1;
}

.notification-item-title {
    font-weight: 600;
    font-size: 14px;
    color: var(--gray-800);
    margin-bottom: 2px;
}

.notification-message {
    font-size: 13px;
    color: var(--gray-500);
}

.notification-time {
    font-size: 11px;
    color: var(--gray-400);
    margin-top: 4px;
}

.notification-footer {
    padding: 12px 20px;
    border-top: 1px solid var(--gray-100);
    text-align: center;
}

.notification-view-all {
    background: none;
    border: none;
    color: var(--primary);
    font-weight: 600;
    font-size: 13px;
    cursor: pointer;
    transition: color 0.2s ease;
}

.notification-view-all:hover {
    color: var(--primary-dark);
}

/* Notification Overlay (click outside to close) */
.notification-overlay {
    position: fixed;
    inset: 0;
    z-index: 50;
}

/* Dark Mode Notification Dropdown */
[data-theme="dark"] .notification-dropdown {
    background: #1e293b;
    border-color: #334155;
}

[data-theme="dark"] .notification-header {
    border-bottom-color: #334155;
}

[data-theme="dark"] .notification-title {
    color: #e2e8f0;
}

[data-theme="dark"] .notification-item {
    border-bottom-color: #334155;
}

[data-theme="dark"] .notification-item:hover {
    background: rgba(99, 102, 241, 0.1);
}

[data-theme="dark"] .notification-item-title {
    color: #e2e8f0;
}

[data-theme="dark"] .notification-message {
    color: #94a3b8;
}

[data-theme="dark"] .notification-time {
    color: #64748b;
}

[data-theme="dark"] .notification-footer {
    border-top-color: #334155;
}

/* ==================== DASHBOARD DARK MODE ==================== */
/* Today Card */
[data-theme="dark"] .today-card,
[data-theme="dark"] .currency-card,
[data-theme="dark"] .alerts-card,
[data-theme="dark"] .stat-card-v2,
[data-theme="dark"] .kpi-card,
[data-theme="dark"] .sparkline-card,
[data-theme="dark"] .top-list-card,
[data-theme="dark"] .chart-card,
[data-theme="dark"] .todo-card,
[data-theme="dark"] .timeline-card,
[data-theme="dark"] .upcoming-card {
    background: #1e293b;
    border-color: rgba(255, 255, 255, 0.05);
}

/* Card Headers & Labels */
[data-theme="dark"] .today-card .header,
[data-theme="dark"] .currency-card .header .title,
[data-theme="dark"] .alerts-card .header .title {
    color: #94a3b8;
}

[data-theme="dark"] .today-card .header span,
[data-theme="dark"] .currency-card .time {
    color: #94a3b8;
}

/* Today Box */
[data-theme="dark"] .today-box {
    background: rgba(255, 255, 255, 0.03);
}

[data-theme="dark"] .today-box.income {
    background: rgba(16, 185, 129, 0.15);
}

[data-theme="dark"] .today-box.expense {
    background: rgba(239, 68, 68, 0.15);
}

[data-theme="dark"] .today-box .label {
    color: #94a3b8;
}

[data-theme="dark"] .today-box .count {
    color: #64748b;
}

/* Currency Row */
[data-theme="dark"] .currency-row {
    border-bottom-color: rgba(255, 255, 255, 0.05);
}

[data-theme="dark"] .currency-row .code {
    color: #e2e8f0;
}

[data-theme="dark"] .currency-row .rate {
    color: #f1f5f9;
}

/* Alert Items */
[data-theme="dark"] .alert-item {
    color: #cbd5e1;
}

/* Stat Card V2 */
[data-theme="dark"] .stat-card-v2 .value {
    color: #f1f5f9;
}

[data-theme="dark"] .stat-card-v2 .label {
    color: #e2e8f0;
}

[data-theme="dark"] .stat-card-v2 .sub {
    color: #94a3b8;
}

/* KPI Card */
[data-theme="dark"] .kpi-card .label {
    color: #e2e8f0;
}

[data-theme="dark"] .kpi-card .sub {
    color: #94a3b8;
}

[data-theme="dark"] .kpi-card .progress-bar {
    background: #334155;
}

/* Sparkline Card */
[data-theme="dark"] .sparkline-card .title {
    color: #e2e8f0;
}

/* Top List Card */
[data-theme="dark"] .top-list-card .title {
    color: #e2e8f0;
}

[data-theme="dark"] .top-list-item {
    border-bottom-color: rgba(255, 255, 255, 0.05);
}

[data-theme="dark"] .top-list-item .rank {
    background: #334155;
    color: #94a3b8;
}

[data-theme="dark"] .top-list-item .name {
    color: #cbd5e1;
}

[data-theme="dark"] .top-list-item .value {
    color: #e2e8f0;
}

/* Chart Card */
[data-theme="dark"] .chart-card .header .title {
    color: #e2e8f0;
}

[data-theme="dark"] .chart-card .header .title i {
    color: #94a3b8;
}

[data-theme="dark"] .chart-card select {
    background: #334155;
    border-color: #475569;
    color: #e2e8f0;
}

/* Todo Card */
[data-theme="dark"] .todo-card .header .title {
    color: #e2e8f0;
}

[data-theme="dark"] .todo-card .header .title i {
    color: #94a3b8;
}

[data-theme="dark"] .todo-item {
    border-bottom-color: rgba(255, 255, 255, 0.05);
}

[data-theme="dark"] .todo-item .checkbox {
    border-color: #475569;
}

[data-theme="dark"] .todo-item .checkbox:hover {
    border-color: var(--primary);
}

[data-theme="dark"] .todo-item .text {
    color: #cbd5e1;
}

[data-theme="dark"] .todo-item .text.done {
    color: #64748b;
}

[data-theme="dark"] .todo-item .delete {
    color: #64748b;
}

[data-theme="dark"] .todo-item .delete:hover {
    color: var(--danger);
}

/* Timeline Card */
[data-theme="dark"] .timeline-card .header {
    color: #e2e8f0;
}

[data-theme="dark"] .timeline-card .header i {
    color: #94a3b8;
}

[data-theme="dark"] .timeline-item {
    border-bottom-color: rgba(255, 255, 255, 0.05);
}

[data-theme="dark"] .timeline-item .desc {
    color: #e2e8f0;
}

[data-theme="dark"] .timeline-item .time {
    color: #64748b;
}

/* Upcoming Card */
[data-theme="dark"] .upcoming-card .header {
    color: #e2e8f0;
}

[data-theme="dark"] .upcoming-card .header i {
    color: #94a3b8;
}

[data-theme="dark"] .upcoming-card th {
    color: #94a3b8;
    border-bottom-color: rgba(255, 255, 255, 0.1);
}

[data-theme="dark"] .upcoming-card td {
    border-bottom-color: rgba(255, 255, 255, 0.05);
}

[data-theme="dark"] .upcoming-card .date {
    color: #94a3b8;
}

[data-theme="dark"] .upcoming-card .company {
    color: #cbd5e1;
}

[data-theme="dark"] .upcoming-card .action .btn-check {
    background: rgba(16, 185, 129, 0.15);
}

/* Quick Actions */
[data-theme="dark"] .quick-actions .btn-secondary {
    background: #334155;
    border-color: #475569;
    color: #e2e8f0;
}

[data-theme="dark"] .quick-actions .btn-secondary:hover {
    background: rgba(99, 102, 241, 0.15);
    border-color: var(--primary);
    color: var(--primary);
}

/* Empty State */
[data-theme="dark"] .empty-state {
    color: #64748b;
}

[data-theme="dark"] .empty-state i {
    color: #475569;
}

/* ==================== MOBILE RESPONSIVE DESIGN ==================== */

/* Mobile Menu Toggle Button */
.mobile-menu-toggle {
    display: none;
    width: 44px;
    height: 44px;
    border: none;
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    border-radius: 12px;
    color: white;
    font-size: 18px;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.3);
    margin-right: 12px;
    flex-shrink: 0;
}

.mobile-menu-toggle:hover {
    transform: scale(1.05);
    box-shadow: 0 6px 20px rgba(99, 102, 241, 0.4);
}

.mobile-menu-toggle:active {
    transform: scale(0.98);
}

/* Mobile Overlay */
.sidebar-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(15, 23, 42, 0.6);
    backdrop-filter: blur(4px);
    z-index: 999;
    opacity: 0;
    pointer-events: none;  /* BU SATIRI EKLEYİN */
    transition: opacity 0.3s ease;
}

.sidebar-overlay.active {
    opacity: 1;
    pointer-events: auto;  /* BU SATIRI EKLEYİN */
}


/* Tablet Breakpoint - 1200px */
@media (max-width: 1200px) {
    .sidebar {
        width: 260px;
    }

    #content {
        margin-left: 260px;
    }

    .dashboard-grid {
        grid-template-columns: repeat(2, 1fr) !important;
    }

    .stats-row {
        grid-template-columns: repeat(2, 1fr) !important;
    }
}

/* Tablet Breakpoint - 992px */
@media (max-width: 992px) {
    /* Show mobile menu toggle */
    .mobile-menu-toggle {
        display: flex;
        align-items: center;
        justify-content: center;
    }

    /* Show overlay */
    .sidebar-overlay {
        display: block;
    }

    /* Sidebar as overlay */
    .sidebar {
        position: fixed;
        left: 0;
        top: 0;
        width: 280px;
        height: 100vh;
        z-index: 1000;
        transform: translateX(-100%);
        transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    }

    .sidebar.active {
        transform: translateX(0);
        box-shadow: 10px 0 40px rgba(0, 0, 0, 0.3);
    }

    /* Main content full width */
    #content {
        margin-left: 0;
        width: 100%;
    }

    /* Header adjustments */
    .top-header {
        padding: 12px 16px;
    }

    .header-left {
        flex: 1;
        min-width: 0;
    }

    .page-title-box {
        flex: 1;
        min-width: 0;
    }

    .page-title {
        font-size: 16px;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    .page-subtitle {
        display: none;
    }

    /* Hide clock on tablet */
    .header-clock {
        display: none;
    }

    /* Dashboard grids */
    .dashboard-grid {
        grid-template-columns: 1fr !important;
    }

    .stats-row {
        grid-template-columns: repeat(2, 1fr) !important;
    }

    /* Main container padding */
    .main-container {
        padding: 16px;
    }

    /* Cards */
    .card {
        margin-bottom: 16px;
    }

    /* Tables */
    .table-responsive {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }
}

/* Mobile Breakpoint - 768px */
@media (max-width: 768px) {
    /* Header */
    .top-header {
        padding: 10px 12px;
        flex-wrap: wrap;
        gap: 10px;
    }

    .header-left {
        order: 1;
        flex: 1;
    }

    .header-right {
        order: 2;
        gap: 8px;
    }

    .page-title-icon {
        width: 36px;
        height: 36px;
        font-size: 14px;
    }

    .page-title {
        font-size: 15px;
    }

    /* Header buttons */
    .header-btn {
        width: 38px;
        height: 38px;
        font-size: 14px;
    }

    /* Hide new record button text */
    .btn-new-record span {
        display: none;
    }

    .btn-new-record {
        width: 38px;
        height: 38px;
        padding: 0;
    }

    /* Stats row */
    .stats-row {
        grid-template-columns: 1fr !important;
        gap: 12px !important;
    }

    /* Stat cards */
    .stat-card-v2 {
        padding: 16px;
    }

    .stat-card-v2 .value {
        font-size: 24px;
    }

    /* Main container */
    .main-container {
        padding: 12px;
    }

    /* Quick actions */
    .quick-actions {
        flex-direction: column;
        gap: 8px;
    }

    .quick-actions .btn {
        width: 100%;
        justify-content: center;
    }

    /* Filter bar */
    .filter-bar {
        flex-direction: column;
        gap: 12px;
    }

    .filter-bar .form-group {
        width: 100%;
    }

    .filter-bar .btn-group {
        width: 100%;
        display: flex;
    }

    .filter-bar .btn-group .btn {
        flex: 1;
    }

    /* Tables */
    .table th,
    .table td {
        padding: 10px 8px;
        font-size: 12px;
    }

    /* Hide less important columns on mobile */
    .table .hide-mobile {
        display: none;
    }

    /* Cards */
    .card-header {
        padding: 12px 16px;
    }

    .card-body {
        padding: 12px 16px;
    }

    /* Form groups */
    .row > [class*="col-md-"],
    .row > [class*="col-lg-"] {
        margin-bottom: 12px;
    }

    /* Modal */
    .modal-dialog {
        margin: 10px;
        max-height: calc(100vh - 20px);
    }

    .modal-content {
        max-height: calc(100vh - 20px);
        overflow-y: auto;
    }

    /* Notification dropdown */
    .notification-dropdown {
        width: calc(100vw - 24px);
        right: -60px;
        max-width: 360px;
    }

    /* Dashboard cards */
    .today-card,
    .currency-card,
    .alerts-card {
        padding: 16px;
    }

    .today-box {
        padding: 12px;
    }

    .today-box .value {
        font-size: 18px;
    }

    /* KPI Cards */
    .kpi-card {
        padding: 14px;
    }

    .kpi-card .value {
        font-size: 22px;
    }

    /* Chart cards */
    .chart-card .chart-container {
        height: 200px !important;
    }

    /* Timeline card */
    .timeline-item {
        padding: 12px 0;
    }

    /* Top list card */
    .top-list-item {
        padding: 10px 0;
    }
}

/* Small Mobile Breakpoint - 480px */
@media (max-width: 480px) {
    /* Mobile menu toggle */
    .mobile-menu-toggle {
        width: 40px;
        height: 40px;
        font-size: 16px;
        margin-right: 10px;
    }

    /* Header */
    .top-header {
        padding: 8px 10px;
    }

    .page-title-icon {
        width: 32px;
        height: 32px;
        font-size: 12px;
    }

    .page-title {
        font-size: 14px;
    }

    /* Header buttons */
    .header-btn {
        width: 36px;
        height: 36px;
        font-size: 13px;
    }

    /* Theme toggle */
    .theme-toggle {
        width: 48px;
        height: 24px;
    }

    .theme-toggle::before {
        width: 18px;
        height: 18px;
    }

    .theme-toggle.dark::before {
        transform: translateX(24px);
    }

    /* Stats */
    .stat-card-v2 .value {
        font-size: 20px;
    }

    .stat-card-v2 .label {
        font-size: 11px;
    }

    /* Main container */
    .main-container {
        padding: 10px;
    }

    /* Cards */
    .card-header {
        padding: 10px 12px;
    }

    .card-body {
        padding: 10px 12px;
    }

    /* Table cells */
    .table th,
    .table td {
        padding: 8px 6px;
        font-size: 11px;
    }

    /* Buttons */
    .btn {
        padding: 8px 14px;
        font-size: 12px;
    }

    .btn-sm {
        padding: 6px 10px;
        font-size: 11px;
    }

    /* Form controls */
    .form-control,
    .form-select {
        padding: 10px 12px;
        font-size: 14px; /* Prevents zoom on iOS */
    }

    /* Today box */
    .today-box .value {
        font-size: 16px;
    }

    .today-box .label {
        font-size: 10px;
    }

    /* Currency row */
    .currency-row .rate {
        font-size: 14px;
    }

    /* KPI Card */
    .kpi-card .value {
        font-size: 18px;
    }

    /* Notification dropdown */
    .notification-dropdown {
        width: calc(100vw - 20px);
        right: -70px;
    }

    .notification-item {
        padding: 12px 14px;
    }

    .notification-icon {
        width: 32px;
        height: 32px;
    }
}

/* Touch-friendly button sizes */
@media (hover: none) and (pointer: coarse) {
    .btn,
    .header-btn,
    .action-btn,
    .nav-link {
        min-height: 44px;
    }

    .form-control,
    .form-select {
        min-height: 44px;
    }

    /* Larger tap targets */
    .table td .btn-group .btn {
        padding: 8px 12px;
    }
}

/* Landscape mobile */
@media (max-width: 768px) and (orientation: landscape) {
    .sidebar.active {
        width: 260px;
    }

    .main-container {
        padding: 10px 16px;
    }

    .stats-row {
        grid-template-columns: repeat(2, 1fr) !important;
    }
}

/* Print styles */
@media print {
    .sidebar,
    .top-header,
    .mobile-menu-toggle,
    .sidebar-overlay {
        display: none !important;
    }

    #content {
        margin-left: 0 !important;
    }

    .main-container {
        padding: 0 !important;
    }

    .card {
        break-inside: avoid;
        box-shadow: none;
        border: 1px solid #ddd;
    }
}

/* ==================== MOBILE HEADER FIX - 2 ROW LAYOUT ==================== */
@media (max-width: 768px) {
    /* Header 2 satır düzeni */
    .top-header {
        padding: 8px 12px !important;
        flex-wrap: wrap !important;
        gap: 8px !important;
    }

    .header-left {
        order: 1;
        flex: 1;
        min-width: 0;
    }

    .header-right {
        order: 2;
        width: 100% !important;
        justify-content: space-between !important;
        padding-top: 8px;
        border-top: 1px solid var(--gray-100);
        gap: 6px !important;
    }

    /* Sayfa icon'u gizle */
    .page-title-icon {
        display: none !important;
    }

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

    .page-title {
        font-size: 14px !important;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    /* Header butonları küçült */
    .header-btn {
        width: 34px !important;
        height: 34px !important;
        font-size: 13px !important;
        flex-shrink: 0;
    }

    /* Yeni Kayıt butonu - sadece icon */
    .btn-add span {
        display: none !important;
    }

    .btn-add {
        width: 34px !important;
        height: 34px !important;
        padding: 0 !important;
        justify-content: center;
    }

    .btn-add i {
        margin: 0 !important;
    }

    /* Theme toggle küçült */
    .theme-toggle {
        width: 44px !important;
        height: 22px !important;
    }

    .theme-toggle::before {
        width: 16px !important;
        height: 16px !important;
    }

    .theme-toggle.dark::before {
        transform: translateX(22px) !important;
    }

    .theme-toggle i {
        font-size: 9px !important;
    }

    .theme-toggle .fa-sun {
        left: 5px !important;
    }

    .theme-toggle .fa-moon {
        right: 5px !important;
    }
}

/* Dark mode header border */
[data-theme="dark"] .header-right {
    border-top-color: #334155;
}

/* ============================================
   PREMIUM MODAL - DARK MODE STYLES (N3 Style)
   ============================================ */
[data-theme="dark"] .premium-modal {
    background: rgba(30, 41, 59, 0.95) !important;
    border: 1px solid #334155 !important;
    backdrop-filter: blur(20px);
}

[data-theme="dark"] .premium-modal .modal-header {
    border-color: #334155 !important;
}

[data-theme="dark"] .premium-modal .modal-body {
    background: transparent;
}

[data-theme="dark"] .premium-modal .modal-footer {
    background: rgba(15, 23, 42, 0.5) !important;
    border-color: #334155 !important;
}

[data-theme="dark"] .premium-modal .form-control,
[data-theme="dark"] .premium-modal .form-select {
    background: #1e293b !important;
    border-color: #334155 !important;
    color: #f8fafc !important;
}

[data-theme="dark"] .premium-modal .form-control::placeholder {
    color: #64748b !important;
}

[data-theme="dark"] .premium-modal .form-group label {
    color: #94a3b8 !important;
}

[data-theme="dark"] .premium-modal .modal-close {
    background: rgba(255, 255, 255, 0.1) !important;
    color: white !important;
}

[data-theme="dark"] .premium-modal .modal-close:hover {
    background: rgba(255, 255, 255, 0.2) !important;
}

[data-theme="dark"] .premium-modal .btn-secondary {
    background: #334155 !important;
    border-color: #475569 !important;
    color: #f8fafc !important;
}

[data-theme="dark"] .premium-modal .btn-secondary:hover {
    background: #475569 !important;
}

/* ============================================
   SCROLL TO TOP BUTTON
   ============================================ */
.scroll-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, #f97316, #ea580c);
    color: white;
    border: none;
    border-radius: 12px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    box-shadow: 0 4px 15px rgba(249, 115, 22, 0.4);
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    transition: all 0.3s ease;
    z-index: 1000;
}

.scroll-to-top.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.scroll-to-top:hover {
    background: linear-gradient(135deg, #ea580c, #c2410c);
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(249, 115, 22, 0.5);
}

.scroll-to-top:active {
    transform: translateY(-1px);
}

.scroll-to-top i {
    transition: transform 0.2s ease;
}

.scroll-to-top:hover i {
    transform: translateY(-2px);
}

/* Dark mode scroll to top */
[data-theme="dark"] .scroll-to-top {
    background: linear-gradient(135deg, #f97316, #ea580c);
    box-shadow: 0 4px 15px rgba(249, 115, 22, 0.3);
}

/* Mobile responsive */
@media (max-width: 768px) {
    .scroll-to-top {
        bottom: 20px;
        right: 20px;
        width: 44px;
        height: 44px;
        font-size: 16px;
    }
}
