* { margin: 0; padding: 0; box-sizing: border-box; }
        body { font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif; background: #F3F4F6; }
        body.employee-view { background: #A8B796; }
        .container { min-height: 100vh; padding: 1rem; }
        .card { background: white; border-radius: 1rem; box-shadow: 0 10px 40px rgba(0,0,0,0.1); padding: 2rem; max-width: 500px; margin: 0 auto; }
        body.employee-view .card { background: #F6EAD2; box-shadow: 0 4px 12px rgba(0,0,0,0.15); }
        .btn { padding: 1rem; border: none; border-radius: 0.5rem; font-size: 1rem; font-weight: 600; cursor: pointer; width: 100%; margin: 0.5rem 0; transition: all 0.2s; }
        .btn:disabled { opacity: 0.5; cursor: not-allowed; }
        .btn-primary { background: #4F46E5; color: white; }
        .btn-primary:hover:not(:disabled) { background: #4338CA; }
        .btn-success { background: #10B981; color: white; }
        .btn-success:hover:not(:disabled) { background: #059669; }
        body.employee-view .btn-success { background: #CBB59D; color: #2C3E50; }
        body.employee-view .btn-success:hover:not(:disabled) { background: #B79A82; }
        .btn-danger { background: #EF4444; color: white; }
        .btn-danger:hover:not(:disabled) { background: #DC2626; }
        .btn-warning { background: #F59E0B; color: white; }
        .btn-warning:hover:not(:disabled) { background: #D97706; }
        .btn-info { background: #3B82F6; color: white; }
        .btn-info:hover:not(:disabled) { background: #2563EB; }
        body.employee-view .btn-info { background: #5A6B7A; color: white; }
        body.employee-view .btn-info:hover:not(:disabled) { background: #4A5568; }
        .input, input[type="date"], input[type="number"], select { width: 100%; padding: 0.75rem; border: 2px solid #CBB59D; border-radius: 0.5rem; font-size: 1rem; background: white; box-sizing: border-box; }
        input[type="text"], input[type="date"], input[type="number"], select { height: 48px; }
        .input:focus { outline: none; border-color: #4F46E5; }
        input[type="date"] { -webkit-appearance: none; -moz-appearance: none; appearance: none; min-width: 0; }
        .input-pin { font-size: 1.5rem; text-align: center; letter-spacing: 0.25rem; }
        .clock { background: #A67C52; color: white; padding: 2rem; border-radius: 1rem; text-align: center; margin: 1rem 0; }
        body.employee-view .clock { background: #A67C52; color: #F5EBDC; } 
        .clock.pause { background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%); }
        .time-display { font-size: 3rem; font-weight: bold; margin-bottom: 0.5rem; }
        .date-display { font-size: 0.875rem; opacity: 0.9; color: #E8D9B6; }
        .grid { display: grid; gap: 1rem; }
        .grid-2 { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
        .stats { background: linear-gradient(135deg, #667eea 0%, #764ba2 100%); color: white; padding: 1.5rem; border-radius: 1rem; text-align: center; }
        .stat-value { font-size: 2rem; font-weight: bold; }
        .stat-label { font-size: 0.875rem; opacity: 0.9; margin-top: 0.25rem; }
        .entry { background: #F9FAFB; padding: 1rem; border-radius: 1rem; margin: 0.5rem 0; }
        body.employee-view .entry { background: #D7C4A3; }
        .entry-row { display: flex; justify-content: space-between; font-size: 0.875rem; margin: 0.25rem 0; }
        .text-center { text-align: center; }
        .text-sm { font-size: 0.875rem; }
        .text-gray { color: #6B7280; }
        .mt-4 { margin-top: 1rem; }
        .mb-4 { margin-bottom: 1rem; }
        .privacy-text { font-size: 0.875rem; line-height: 1.7; color: #374151; }
        .privacy-text h3 { font-size: 1.1rem; margin-top: 1.5rem; margin-bottom: 0.75rem; color: #1F2937; }
        .privacy-text h4 { font-size: 1rem; margin-top: 1rem; margin-bottom: 0.5rem; color: #374151; }
        .privacy-text ul { margin-left: 1.5rem; margin-top: 0.5rem; }
        .privacy-text li { margin: 0.5rem 0; }
        .checkbox-label { margin-left: 0.5rem; cursor: pointer; }
        h1 { font-size: 2rem; margin-bottom: 0.5rem; }
        h2 { font-size: 1.5rem; margin-bottom: 1rem; }
        h3 { font-size: 1.25rem; margin: 1rem 0; }
        body.employee-view h1,
        body.employee-view h2,
        body.employee-view h3 { color: #2C3E50; }
        .logout-btn {
            position: fixed;
            top: 1rem;
            right: 1rem;
            background: #6B7280;
            color: white;
            padding: 0.5rem;
            border-radius: 0.5rem;
            cursor: pointer;
            border: none;
            width: 2.5rem;
            height: 2.5rem;
            font-size: 1.2rem;
            z-index: 100;
        }
        .refresh-btn {
            position: fixed;
            top: 1rem;
            right: 4.5rem;
            background: #A67C52;
            color: white;
            padding: 0.5rem;
            border-radius: 0.5rem;
            cursor: pointer;
            border: none;
            width: 2.5rem;
            height: 2.5rem;
            font-size: 1.2rem;
            z-index: 100;
        }‚
        .admin-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 1.5rem; }
        table { width: 100%; border-collapse: collapse; }
        th, td { padding: 0.75rem; text-align: left; border-bottom: 1px solid #A67C52; }
        th { background: #CBB59D; font-weight: 600; font-size: 0.875rem; }
        tr:hover { background: #E8D9B6; }
        td { font-size: 0.875rem; }
        .badge { padding: 0.25rem 0.75rem; border-radius: 9999px; font-size: 0.75rem; font-weight: 500; display: inline-block; }
        .badge-success { background: #D1FAE5; color: #065F46; }
        .badge-gray { background: #E5E7EB; color: #374151; }
        .loading { text-align: center; padding: 2rem; }
        .spinner { border: 4px solid #f3f3f3; border-top: 4px solid #4F46E5; border-radius: 50%; width: 40px; height: 40px; animation: spin 1s linear infinite; margin: 0 auto; }
        @keyframes spin { 0% { transform: rotate(0deg); } 100% { transform: rotate(360deg); } }
        .db-status { padding: 0.5rem 1rem; border-radius: 0.5rem; font-size: 0.75rem; margin-top: 1rem; text-align: center; }
        .db-connected { background: #D1FAE5; color: #065F46; }
        .modal { display: none; position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0,0,0,0.7); z-index: 1000; align-items: center; justify-content: center; }
        .modal.active { display: flex; }
        .modal-content { background: #F5EBDC; border-radius: 1rem; padding: 2rem; max-width: 600px; width: 90%; max-height: 90vh; overflow-y: auto; }
        .modal-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 1.5rem; }
        .modal-close { background: #8B5A3C; color: white; border: none; border-radius: 0.5rem; padding: 0.5rem 1rem; cursor: pointer; font-size: 1.25rem; font-weight: bold; }
        .modal-close:hover { background: #6D4830; }
        .form-group { margin-bottom: 1rem; }
        .form-label { display: block; font-weight: 600; margin-bottom: 0.5rem; font-size: 0.875rem; }
        .break-item { background: #E8D9B6; padding: 1rem; border-radius: 0.5rem; margin-bottom: 0.5rem; display: flex; justify-content: space-between; align-items: center; gap: 1rem; }
        .break-inputs { display: flex; gap: 0.5rem; flex: 1; }
        .warning-badge { display: inline-block; background: #FEF3C7; color: #92400E; padding: 0.25rem 0.75rem; border-radius: 0.5rem; font-size: 0.75rem; font-weight: 600; margin-left: 0.5rem; }
        .warning-badge-danger { background: #FEE2E2; color: #991B1B; }
        .date-picker { background: #D7C4A3; border: 2px solid #A67C52; border-radius: 1rem; padding: 1rem; margin: 1.5rem 0; box-shadow: 0 4px 6px rgba(0,0,0,0.05); }
        .date-picker-header { display: flex; justify-content: space-between; align-items: center; gap: 0.5rem; margin-bottom: 1rem; }
        .date-picker-nav { background: linear-gradient(135deg, #A67C52 0%, #8B5A3C 100%); color: white; border: none; border-radius: 0.5rem; padding: 0.5rem 0.75rem; cursor: pointer; font-size: 0.75rem; font-weight: 600; min-width: 70px; transition: all 0.2s; box-shadow: 0 2px 4px rgba(166,124,82,0.3); }
        .date-picker-nav:hover { transform: translateY(-2px); box-shadow: 0 4px 8px rgba(166,124,82,0.4); }
        .date-picker-title { font-weight: 600; font-size: 0.95rem; text-align: center; flex: 1; color: #1F2937; }
        .date-input { width: 92%; margin: 0 auto; display: block; padding: 0.5rem; border: 2px solid #E5E7EB; border-radius: 0.5rem; font-size: 1rem; box-sizing: border-box; text-align: center; background: #F9FAFB; transition: all 0.2s; }
        .date-input:focus { outline: none; border-color: #4F46E5; background: white; box-shadow: 0 0 0 3px rgba(79,70,229,0.1); }
        .today-btn { background: linear-gradient(135deg, #A67C52 0%, #8B5A3C 100%); color: white; border: none; padding: 0.875rem; border-radius: 0.75rem; width: 100%; font-weight: 600; cursor: pointer; margin-top: 1rem; font-size: 1rem; transition: all 0.2s; box-shadow: 0 2px 4px rgba(166,124,82,0.3); }
        .today-btn:hover { transform: translateY(-2px); box-shadow: 0 4px 8px rgba(166,124,82,0.4); }
        .pull-to-refresh {
            position: fixed;
            top: 0;
            left: 50%;
            transform: translateX(-50%) translateY(-60px);
            background: #A67C52;
            color: white;
            padding: 0.75rem 1.5rem;
            border-radius: 2rem;
            font-weight: 600;
            font-size: 0.875rem;
            z-index: 9999;
            transition: transform 0.3s ease;
            box-shadow: 0 4px 12px rgba(0,0,0,0.2);
        }

        .pull-to-refresh.visible {
            transform: translateX(-50%) translateY(80px);
        }

        .pull-to-refresh.loading {
            background: #8B5A3C;
        }
        /* Smooth Animations */
        * { transition: background-color 0.2s ease, transform 0.2s ease, opacity 0.2s ease; }
        
        .btn { transform: scale(1); }
        .btn:hover:not(:disabled) { transform: scale(1.02); box-shadow: 0 4px 12px rgba(0,0,0,0.15); }
        .btn:active:not(:disabled) { transform: scale(0.98); }
        
        .card { animation: fadeInUp 0.4s ease-out; }
        @keyframes fadeInUp {
            from { opacity: 0; transform: translateY(20px); }
            to { opacity: 1; transform: translateY(0); }
        }
        
        .entry { animation: slideIn 0.3s ease-out; }
        @keyframes slideIn {
            from { opacity: 0; transform: translateX(-10px); }
            to { opacity: 1; transform: translateX(0); }
        }
        @media (max-width: 768px) {
            .logout-btn { 
                position: fixed; 
                top: 0.5rem; 
                right: 0.5rem;
                z-index: 1000;
            }
            .refresh-btn { 
                position: fixed; 
                top: 0.5rem; 
                right: 3.5rem;
                z-index: 1000;
            }
        }
        /* =========================
           RESPONSIVE DESIGN
           ========================= */
        
        /* Mobile - iPhone (bis 480px) */
        @media (max-width: 480px) {
            .container {
                padding: 0.5rem;
            }
            
            .card {
                padding: 1rem;
                margin: 0.5rem;
                border-radius: 0.5rem;
            }
            
            h1 {
                font-size: 1.5rem;
            }
            
            h2 {
                font-size: 1.25rem;
            }
            
            h3 {
                font-size: 1rem;
            }
            
            .btn {
                padding: 0.75rem 1rem;
                font-size: 0.875rem;
            }
            
            .input {
                padding: 0.75rem;
                font-size: 1rem;
            }
            
            .grid-2 {
                grid-template-columns: 1fr;
            }
            
            table {
                font-size: 0.75rem;
            }
            
            th, td {
                padding: 0.5rem 0.25rem;
            }
            
            .modal-content {
                margin: 0.5rem;
                padding: 1rem;
                max-height: 90vh;
            }
            /* Tabellen horizontal scrollbar */
            .table-container {
                overflow-x: auto;
                -webkit-overflow-scrolling: touch;
            }
            
            table {
                min-width: 600px;
            }
        }
        
        /* Tablet - iPad (481px bis 1024px) */
        @media (min-width: 481px) and (max-width: 1024px) {
            .container {
                padding: 1rem;
            }
            
            .card {
                padding: 1.5rem;
                max-width: 100%;
            }
            
            .modal-content {
                max-width: 90%;
            }
        }
        
        /* Desktop - Laptop (über 1024px) */
        @media (min-width: 1025px) {
            .container {
                padding: 2rem;
            }
            
            .card {
                max-width: 1200px;
                margin: 0 auto;
            }
            
            .modal-content {
                max-width: 600px;
            }
        }