File size: 1,634 Bytes
cdf301a
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
'use client';

import { useRouter } from 'next/navigation';

export default function Custom404() {
  const router = useRouter();

  const handleGoBack = () => {
    router.back();
  };

  return (
    <div style={styles.container}>
      <h1 className='pulse-and-fade' style={styles.heading}>404 - Page Not Found</h1>
      <p className='pulse-and-fade' style={styles.message}>
        Oops! The page you're looking for doesn't exist. Let’s get you back on track!
      </p>
      <div className='pulse-and-fade' style={styles.buttons}>
        <button onClick={handleGoBack} style={styles.button}>
          Go Back
        </button>
        <button onClick={() => router.push('/')} style={styles.button}>
          Go to Home
        </button>
      </div>
    </div>
  );
}

const styles = {
  container: {
    display: 'flex',
    flexDirection: 'column',
    justifyContent: 'center',
    alignItems: 'center',
    height: '100vh',
    backgroundColor: 'var(--background)',
    color: 'var(--foreground)',
    textAlign: 'center',
  },
  heading: {
    fontSize: '48px',
    fontWeight: 'bold',
    marginBottom: '20px',
  },
  message: {
    fontSize: '18px',
    marginBottom: '30px',
    maxWidth: '400px',
    color: 'var(--foreground)',
  },
  buttons: {
    display: 'flex',
    gap: '15px',
  },
  button: {
    padding: '10px 20px',
    fontSize: '16px',
    borderRadius: '5px',
    border: 'none',
    cursor: 'pointer',
    backgroundColor: 'var(--button-background)',
    color: 'var(--foreground)',
    transition: 'background-color 0.3s',
  },
  buttonHover: {
    backgroundColor: 'var(--button-hover)',
  },
};