/* ============================================
   Digi Boox - Administratiesysteem
   Volledig herontwerp volgens referentie
   ============================================ */

/* Reset en basis */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    line-height: 1.6;
    color: #1f2937;
    background-color: #f9fafb;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

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

/* Sidebar - Donkerblauw */
.sidebar {
    width: 260px;
    background-color: #1e3a8a;
    display: flex;
    flex-direction: column;
    position: fixed;
    height: 100vh;
    overflow-y: auto;
    z-index: 1000;
    -webkit-overflow-scrolling: touch;
}

/* Scrollbar styling voor sidebar */
.sidebar::-webkit-scrollbar {
    width: 6px;
}

.sidebar::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.1);
}

.sidebar::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.3);
    border-radius: 3px;
}

.sidebar::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.5);
}

.sidebar-header {
    padding: 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.logo {
    display: flex;
    align-items: center;
    gap: 12px;
}

.logo-icon {
    width: 40px;
    height: 40px;
    background-color: rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
}

.logo-text {
    font-size: 18px;
    font-weight: 600;
    color: #ffffff;
}

.sidebar-nav {
    padding: 10px;
    flex: 1;
}

.nav-item {
    display: flex;
    align-items: center;
    padding: 12px 16px;
    margin: 4px 0;
    border-radius: 8px;
    text-decoration: none;
    color: rgba(255, 255, 255, 0.9);
    transition: all 0.2s;
    position: relative;
}

.nav-item:hover {
    background-color: rgba(255, 255, 255, 0.1);
    color: #ffffff;
}

.nav-item.active {
    background-color: rgba(255, 255, 255, 0.2);
    color: #ffffff;
    font-weight: 500;
}

.nav-icon {
    font-size: 18px;
    margin-right: 12px;
    width: 24px;
    text-align: center;
}

.nav-text {
    flex: 1;
    font-size: 14px;
}

.nav-badge {
    background-color: rgba(255, 255, 255, 0.2);
    color: white;
    border-radius: 12px;
    padding: 2px 8px;
    font-size: 12px;
    font-weight: 600;
    min-width: 20px;
    text-align: center;
}

/* Main Content Wrapper */
.main-content-wrapper {
    flex: 1;
    margin-left: 260px;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    background-color: #ffffff;
}

/* Topbar - Lichtgrijs */
.topbar {
    background-color: #e5e7eb;
    padding: 16px 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #d1d5db;
    position: sticky;
    top: 0;
    z-index: 100;
}

.topbar-left {
    display: flex;
    align-items: center;
    gap: 20px;
    flex: 1;
}

.page-title {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 16px;
    font-weight: 600;
    color: #1f2937;
}

.page-icon {
    width: 32px;
    height: 32px;
    background-color: #3b82f6;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 16px;
}

.page-name {
    color: #1f2937;
}

.search-container {
    flex: 1;
    max-width: 500px;
}

.search-input {
    width: 100%;
    padding: 10px 16px;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    font-size: 14px;
    background-color: white;
    transition: all 0.2s;
}

.search-input:focus {
    outline: none;
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.topbar-right {
    display: flex;
    align-items: center;
    gap: 12px;
}

.date-display {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    background-color: white;
    border-radius: 6px;
    border: 1px solid #d1d5db;
}

.current-date {
    font-size: 14px;
    font-weight: 500;
    color: #1f2937;
}

.topbar-icon {
    font-size: 20px;
    color: #4b5563;
    cursor: pointer;
    padding: 8px;
    border-radius: 6px;
    transition: all 0.2s;
}

.topbar-icon:hover {
    background-color: rgba(0, 0, 0, 0.05);
}

.topbar-icon-link {
    display: flex;
    align-items: center;
    text-decoration: none;
    color: #4b5563;
}

.user-menu {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 12px;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s;
}

.user-menu:hover {
    background-color: rgba(0, 0, 0, 0.05);
}

.user-name {
    font-size: 14px;
    font-weight: 500;
    color: #1f2937;
}

.dropdown-arrow {
    font-size: 10px;
    color: #6b7280;
}

.icon-btn {
    background: none;
    border: none;
    padding: 8px 16px;
    border-radius: 6px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 14px;
    color: #4b5563;
    transition: all 0.2s;
    font-weight: 500;
}

.icon-btn:hover {
    background-color: rgba(0, 0, 0, 0.05);
}

.new-btn {
    background-color: #3b82f6;
    color: white;
    font-weight: 500;
}

.new-btn:hover {
    background-color: #2563eb;
    color: white;
}

.bon-btn {
    padding: 8px 16px;
    background-color: #10b981;
    color: white;
    border-radius: 6px;
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.2s;
}

.bon-btn:hover {
    background-color: #059669;
    color: white;
}

.logout-btn {
    padding: 8px 16px;
    background-color: white;
    color: #4b5563;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.2s;
}

.logout-btn:hover {
    background-color: #f3f4f6;
    border-color: #9ca3af;
}

/* Page Content */
.page-content {
    flex: 1;
    padding: 24px;
    background-color: #f9fafb;
    min-height: calc(100vh - 60px);
}

/* Alerts */
.alert {
    padding: 14px 18px;
    margin-bottom: 20px;
    border-radius: 8px;
    font-size: 14px;
    border-left: 4px solid;
}

.alert-success {
    background-color: #d1fae5;
    color: #065f46;
    border-color: #10b981;
}

.alert-error {
    background-color: #fee2e2;
    color: #991b1b;
    border-color: #ef4444;
}

.alert-warning {
    background-color: #fef3c7;
    color: #92400e;
    border-color: #f59e0b;
}

/* Dashboard KPI Cards */
.kpi-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    margin-bottom: 24px;
}

.kpi-card {
    border-radius: 12px;
    padding: 24px;
    color: white;
    position: relative;
    overflow: hidden;
    min-height: 140px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

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

.kpi-card-red {
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
}

.kpi-card-blue {
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
}

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

.kpi-icon {
    position: absolute;
    right: 16px;
    top: 16px;
    font-size: 32px;
    opacity: 0.3;
}

.kpi-value {
    font-size: 32px;
    font-weight: 700;
    margin-bottom: 8px;
}

.kpi-label {
    font-size: 14px;
    opacity: 0.9;
    margin-bottom: 12px;
}

.kpi-sublabel {
    font-size: 12px;
    opacity: 0.8;
}

.kpi-bottom-icon {
    position: absolute;
    right: 16px;
    bottom: 16px;
    font-size: 24px;
    opacity: 0.3;
}

/* Dashboard Widgets */
.dashboard-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    margin-bottom: 24px;
}

.widget {
    background: white;
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    border: 1px solid #f0f0f0;
    transition: box-shadow 0.2s;
}

.widget:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
}

.widget-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 1px solid #e5e7eb;
}

.widget-title {
    font-size: 16px;
    font-weight: 600;
    color: #1f2937;
}

.widget-content {
    font-size: 14px;
    color: #4b5563;
}

/* Chart Container */
.chart-container {
    background: white;
    border-radius: 12px;
    padding: 24px;
    margin-bottom: 24px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    border: 1px solid #f0f0f0;
}

.chart-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.chart-title {
    font-size: 18px;
    font-weight: 600;
    color: #1f2937;
}

.chart-year {
    font-size: 14px;
    color: #6b7280;
}

.chart-wrapper {
    position: relative;
    height: 300px;
}

/* Invoice List */
.invoice-list {
    background: white;
    border-radius: 12px;
    padding: 24px;
    margin-bottom: 24px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    border: 1px solid #f0f0f0;
}

.invoice-list-title {
    font-size: 18px;
    font-weight: 600;
    color: #1f2937;
    margin-bottom: 16px;
}

.invoice-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px;
    background: #f9fafb;
    border-radius: 8px;
    margin-bottom: 12px;
}

.invoice-item-left {
    display: flex;
    align-items: center;
    gap: 12px;
    flex: 1;
}

.invoice-status-icon {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 18px;
    flex-shrink: 0;
}

.invoice-status-paid {
    background: #10b981;
}

.invoice-status-unpaid {
    background: #ef4444;
}

.invoice-status-pending {
    background: #f59e0b;
}

.invoice-info {
    flex: 1;
}

.invoice-customer {
    font-weight: 600;
    color: #1f2937;
    margin-bottom: 4px;
}

.invoice-number {
    font-size: 12px;
    color: #6b7280;
}

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

.invoice-amount {
    font-weight: 600;
    color: #1f2937;
    margin-bottom: 4px;
}

.invoice-date {
    font-size: 12px;
    color: #6b7280;
}

/* Bottom Cards */
.bottom-cards {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

.bottom-card {
    background: white;
    border-radius: 12px;
    padding: 24px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    border: 1px solid #f0f0f0;
    transition: box-shadow 0.2s, transform 0.2s;
}

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

.bottom-card-title {
    font-size: 16px;
    font-weight: 600;
    color: #1f2937;
    margin-bottom: 8px;
}

.bottom-card-year {
    font-size: 14px;
    color: #6b7280;
    margin-bottom: 16px;
}

.bottom-card-total {
    font-size: 24px;
    font-weight: 700;
    color: #1f2937;
    margin-bottom: 16px;
}

.bottom-card-item {
    display: flex;
    justify-content: space-between;
    margin-bottom: 8px;
    font-size: 14px;
}

.bottom-card-item-label {
    color: #6b7280;
}

.bottom-card-item-value {
    font-weight: 600;
    color: #1f2937;
}

.bottom-card-item-value.green {
    color: #10b981;
}

.bottom-card-item-value.red {
    color: #ef4444;
}

.bottom-card-divider {
    border-top: 2px solid #e5e7eb;
    margin-top: 12px;
    padding-top: 12px;
}

.bottom-card-result {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.bottom-card-result-label {
    font-size: 16px;
    font-weight: 600;
    color: #1f2937;
}

.bottom-card-result-value {
    font-size: 18px;
    font-weight: 700;
}

.bottom-card-result-value.green {
    color: #10b981;
}

.bottom-card-result-value.red {
    color: #ef4444;
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 10px 20px;
    border-radius: 8px;
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    border: none;
    cursor: pointer;
    transition: all 0.2s;
    text-align: center;
}

.btn-primary {
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
    color: white;
    box-shadow: 0 2px 4px rgba(59, 130, 246, 0.2);
}

.btn-primary:hover {
    background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(59, 130, 246, 0.4);
}

.btn-secondary {
    background-color: #f3f4f6;
    color: #4b5563;
    border: 1px solid #d1d5db;
}

.btn-secondary:hover {
    background-color: #e5e7eb;
}

.btn-danger {
    background-color: #ef4444;
    color: white;
}

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

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

/* Forms */
.form {
    background: white;
    padding: 24px;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    border: 1px solid #f0f0f0;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 6px;
    font-size: 14px;
    font-weight: 500;
    color: #374151;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    font-size: 14px;
    transition: all 0.2s;
    font-family: inherit;
    background-color: #ffffff;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
    background-color: #ffffff;
}

.form-group input:hover,
.form-group select:hover,
.form-group textarea:hover {
    border-color: #9ca3af;
}

.form-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 16px;
}

.form-group-small {
    max-width: 150px;
}

.form-actions {
    display: flex;
    gap: 12px;
    margin-top: 24px;
    padding-top: 20px;
    border-top: 1px solid #e5e7eb;
}

.form-help {
    font-size: 12px;
    color: #6b7280;
    margin-top: 4px;
}

/* Tables */
.data-table {
    width: 100%;
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    border: 1px solid #f0f0f0;
}

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

.data-table thead {
    background: linear-gradient(135deg, #f3f4f6 0%, #e5e7eb 100%);
}

.data-table th {
    padding: 14px 16px;
    text-align: left;
    font-size: 12px;
    font-weight: 600;
    color: #6b7280;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-bottom: 2px solid #e5e7eb;
}

.data-table td {
    padding: 14px 16px;
    border-bottom: 1px solid #f3f4f6;
    font-size: 14px;
    color: #374151;
}

.data-table tbody tr:hover {
    background-color: #f9fafb;
}

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

/* Page Header */
.page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
    padding-bottom: 16px;
    border-bottom: 2px solid #e5e7eb;
}

.page-header h2 {
    font-size: 24px;
    font-weight: 600;
    color: #1f2937;
}

/* Cards */
.card {
    background: white;
    border-radius: 12px;
    padding: 24px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    border: 1px solid #f0f0f0;
    margin-bottom: 20px;
    transition: box-shadow 0.2s, transform 0.2s;
}

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

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 1px solid #e5e7eb;
}

.card-title {
    font-size: 18px;
    font-weight: 600;
    color: #1f2937;
}

/* Detail View */
.detail-view {
    background: white;
    border-radius: 12px;
    padding: 24px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    border: 1px solid #f0f0f0;
}

.detail-section {
    margin-bottom: 32px;
}

.detail-section:last-child {
    margin-bottom: 0;
}

.detail-section h3 {
    font-size: 16px;
    font-weight: 600;
    color: #1f2937;
    margin-bottom: 16px;
    padding-bottom: 8px;
    border-bottom: 2px solid #e5e7eb;
}

.detail-table {
    width: 100%;
}

.detail-table th {
    text-align: left;
    padding: 10px 16px 10px 0;
    font-weight: 500;
    color: #6b7280;
    font-size: 14px;
    width: 200px;
}

.detail-table td {
    padding: 10px 0;
    color: #374151;
    font-size: 14px;
}

/* Filter Form */
.filter-form {
    background: white;
    padding: 20px;
    border-radius: 12px;
    margin-bottom: 24px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    border: 1px solid #f0f0f0;
}

/* Section */
.section {
    background: white;
    border-radius: 12px;
    padding: 24px;
    margin-bottom: 24px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    border: 1px solid #f0f0f0;
    transition: box-shadow 0.2s;
}

.section:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
}

.section h3 {
    font-size: 18px;
    font-weight: 600;
    color: #1f2937;
    margin-bottom: 16px;
}

.section h4 {
    font-size: 16px;
    font-weight: 600;
    color: #1f2937;
    margin-bottom: 12px;
    margin-top: 20px;
}

.section h4:first-child {
    margin-top: 0;
}

/* Status Badges */
.status-badge {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 500;
}

.status-concept {
    background-color: #fef3c7;
    color: #92400e;
}

.status-verstuurd {
    background-color: #dbeafe;
    color: #1e40af;
}

.status-betaald {
    background-color: #d1fae5;
    color: #065f46;
}

.status-gedeeltelijk-betaald {
    background-color: #fef3c7;
    color: #92400e;
}

.status-achterstallig {
    background-color: #fee2e2;
    color: #991b1b;
}

.status-geaccepteerd {
    background-color: #d1fae5;
    color: #065f46;
}

.status-geweigerd {
    background-color: #fee2e2;
    color: #991b1b;
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 40px 20px;
    color: #6b7280;
}

.empty-state p {
    margin-bottom: 16px;
    font-size: 14px;
}

/* Mobile Menu Toggle */
.mobile-menu-toggle {
    display: none;
    position: fixed;
    top: 12px;
    left: 12px;
    z-index: 1001;
    background: #1e3a8a;
    color: white;
    border: none;
    padding: 0;
    border-radius: 10px;
    cursor: pointer;
    font-size: 24px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.3);
    transition: all 0.3s;
    width: 48px;
    height: 48px;
    align-items: center;
    justify-content: center;
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
}

.mobile-menu-toggle:active {
    transform: scale(0.95);
    box-shadow: 0 2px 6px rgba(0,0,0,0.2);
}

.mobile-menu-toggle:hover {
    background: #1e40af;
    box-shadow: 0 6px 16px rgba(0,0,0,0.4);
}

.mobile-menu-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6);
    z-index: 999;
    backdrop-filter: blur(2px);
    -webkit-backdrop-filter: blur(2px);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.mobile-menu-overlay.active {
    display: block;
    opacity: 1;
}

/* Responsive */
@media (max-width: 1200px) {
    .kpi-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .bottom-cards {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    /* Mobile Menu */
    .mobile-menu-toggle {
        display: flex !important;
    }
    
    .sidebar {
        transform: translateX(-100%);
        transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
        box-shadow: 4px 0 20px rgba(0,0,0,0.3);
        width: 280px;
        z-index: 1000;
    }
    
    .sidebar.open {
        transform: translateX(0);
    }
    
    .main-content-wrapper {
        margin-left: 0;
        width: 100%;
    }
    
    /* Topbar spacing voor menu button */
    .topbar {
        padding-left: 70px;
    }
    
    /* Topbar Mobile */
    .topbar {
        padding: 12px 16px 12px 70px;
        flex-wrap: wrap;
        position: relative;
    }
    
    .topbar-left {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
        width: 100%;
        margin-bottom: 12px;
    }
    
    .page-title {
        font-size: 14px;
    }
    
    .page-icon {
        width: 28px;
        height: 28px;
        font-size: 14px;
    }
    
    .search-container {
        max-width: 100%;
        width: 100%;
    }
    
    .topbar-right {
        width: 100%;
        justify-content: space-between;
        flex-wrap: wrap;
        gap: 8px;
    }
    
    .date-display {
        order: 1;
    }
    
    .topbar-icon-link {
        order: 2;
    }
    
    .user-menu {
        order: 3;
    }
    
    .bon-btn {
        order: 4;
        flex: 1;
        text-align: center;
    }
    
    .logout-btn {
        order: 5;
        flex: 1;
        text-align: center;
    }
    
    /* Page Content Mobile */
    .page-content {
        padding: 16px;
    }
    
    .page-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
        padding-bottom: 12px;
    }
    
    .page-header h2 {
        font-size: 20px;
    }
    
    /* KPI Cards Mobile */
    .kpi-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }
    
    .kpi-card {
        min-height: 120px;
        padding: 20px;
    }
    
    .kpi-value {
        font-size: 28px;
    }
    
    /* Bottom Cards Mobile */
    .bottom-cards {
        grid-template-columns: 1fr;
        gap: 16px;
    }
    
    /* Dashboard Grid Mobile */
    .dashboard-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }
    
    /* Forms Mobile */
    .form-row {
        grid-template-columns: 1fr;
        gap: 12px;
    }
    
    .form {
        padding: 20px;
    }
    
    .filter-form {
        padding: 16px;
    }
    
    /* Tables Mobile */
    .data-table {
        overflow-x: auto;
        display: block;
    }
    
    .data-table table {
        min-width: 800px;
    }
    
    .data-table th,
    .data-table td {
        padding: 10px 8px;
        font-size: 13px;
    }
    
    /* Cards Mobile */
    .card,
    .section,
    .widget,
    .chart-container,
    .invoice-list {
        padding: 16px;
        border-radius: 10px;
    }
    
    /* Buttons Mobile */
    .btn {
        padding: 10px 16px;
        font-size: 13px;
        width: 100%;
        text-align: center;
    }
    
    .btn-sm {
        padding: 6px 10px;
        font-size: 12px;
    }
    
    .form-actions {
        flex-direction: column;
    }
    
    .form-actions .btn {
        width: 100%;
    }
    
    /* Chart Mobile */
    .chart-wrapper {
        height: 250px;
    }
    
    .chart-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }
    
    /* Invoice List Mobile */
    .invoice-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }
    
    .invoice-item-right {
        text-align: left;
        width: 100%;
    }
    
    /* Detail View Mobile */
    .detail-view {
        padding: 16px;
    }
    
    .detail-table {
        font-size: 14px;
    }
    
    .detail-table th {
        width: 140px;
        padding: 8px 12px 8px 0;
    }
    
    .detail-table td {
        padding: 8px 0;
    }
}

@media (max-width: 480px) {
    .kpi-value {
        font-size: 24px;
    }
    
    .kpi-label {
        font-size: 12px;
    }
    
    .kpi-sublabel {
        font-size: 11px;
    }
    
    .page-header h2 {
        font-size: 18px;
    }
    
    .card-title,
    .widget-title,
    .section h3 {
        font-size: 16px;
    }
    
    .bottom-card-title {
        font-size: 14px;
    }
    
    .bottom-card-total {
        font-size: 20px;
    }
}

/* Login Page */
.login-container {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #dbeafe 0%, #bfdbfe 100%);
}

.login-box {
    background: white;
    padding: 40px;
    border-radius: 12px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
    width: 100%;
    max-width: 400px;
}

.login-box h1 {
    text-align: center;
    margin-bottom: 10px;
    color: #1f2937;
    font-size: 24px;
}

.login-box h2 {
    text-align: center;
    margin-bottom: 24px;
    color: #6b7280;
    font-size: 18px;
    font-weight: 400;
}

/* Utility Classes */
.text-right {
    text-align: right;
}

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

.mt-1 { margin-top: 8px; }
.mt-2 { margin-top: 16px; }
.mt-3 { margin-top: 24px; }
.mb-1 { margin-bottom: 8px; }
.mb-2 { margin-bottom: 16px; }
.mb-3 { margin-bottom: 24px; }
