File size: 5,572 Bytes
7dc7b11
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
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
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8"/>
  <meta name="viewport" content="width=device-width, initial-scale=1.0"/>
  <title>JobDrop β€” Admin Login</title>
  <meta name="robots" content="noindex, nofollow"/>
  <link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap" rel="stylesheet"/>
  <style>
    *, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

    :root {
      --bg: #070b14;
      --surface: #0e1625;
      --card: #111d30;
      --purple: #7c3aed;
      --purple2: #9f5bff;
      --purple-glow: rgba(124,58,237,0.18);
      --cyan: #22d3ee;
      --text: #f0f4ff;
      --muted: #7a8fad;
      --border: #1e2f48;
      --red: #f87171;
    }

    body {
      font-family: 'Inter', sans-serif;
      background: var(--bg);
      color: var(--text);
      min-height: 100vh;
      display: flex;
      align-items: center;
      justify-content: center;
      padding: 24px;
    }

    /* glow blob */
    body::before {
      content: '';
      position: fixed;
      top: -100px;
      left: 50%;
      transform: translateX(-50%);
      width: 600px;
      height: 400px;
      background: radial-gradient(ellipse, rgba(124,58,237,0.12) 0%, transparent 70%);
      pointer-events: none;
    }

    .login-box {
      background: var(--card);
      border: 1px solid var(--border);
      border-radius: 20px;
      padding: 36px 24px;
      width: 100%;
      max-width: 420px;
      position: relative;
    }

    .brand {
      text-align: center;
      margin-bottom: 32px;
    }
    .brand .logo {
      font-size: 1.6rem;
      font-weight: 800;
      letter-spacing: -0.5px;
    }
    .brand .logo span {
      background: linear-gradient(135deg, var(--purple2), var(--cyan));
      -webkit-background-clip: text;
      -webkit-text-fill-color: transparent;
    }
    .brand p {
      margin-top: 8px;
      color: var(--muted);
      font-size: 0.85rem;
    }
    .brand .admin-badge {
      display: inline-block;
      background: var(--purple-glow);
      color: var(--purple2);
      font-size: 0.7rem;
      font-weight: 700;
      letter-spacing: 1px;
      text-transform: uppercase;
      padding: 3px 12px;
      border-radius: 100px;
      border: 1px solid rgba(124,58,237,0.3);
      margin-bottom: 10px;
    }

    label {
      display: block;
      font-size: 0.8rem;
      font-weight: 600;
      color: var(--muted);
      margin-bottom: 6px;
      text-transform: uppercase;
      letter-spacing: 0.5px;
    }
    input {
      width: 100%;
      background: var(--surface);
      border: 1px solid var(--border);
      border-radius: 10px;
      padding: 13px 14px;
      color: var(--text);
      font-family: inherit;
      font-size: 1rem;
      outline: none;
      transition: border-color 0.2s;
      margin-bottom: 18px;
      -webkit-appearance: none;
    }
    input:focus { border-color: var(--purple); }
    input::placeholder { color: var(--muted); }

    .login-btn {
      width: 100%;
      background: linear-gradient(135deg, var(--purple), var(--purple2));
      color: #fff;
      font-family: inherit;
      font-size: 1rem;
      font-weight: 700;
      padding: 14px;
      border-radius: 10px;
      border: none;
      cursor: pointer;
      transition: opacity 0.2s, box-shadow 0.2s;
      min-height: 50px;
      touch-action: manipulation;
      -webkit-tap-highlight-color: transparent;
    }
    .login-btn:hover {
      opacity: 0.9;
      box-shadow: 0 6px 24px rgba(124,58,237,0.4);
    }

    .error-msg {
      background: rgba(248,113,113,0.1);
      border: 1px solid rgba(248,113,113,0.25);
      color: var(--red);
      font-size: 0.82rem;
      padding: 10px 14px;
      border-radius: 8px;
      margin-bottom: 18px;
      display: none;
    }

    .back-link {
      text-align: center;
      margin-top: 22px;
      font-size: 0.8rem;
      color: var(--muted);
    }
    .back-link a { color: var(--purple2); text-decoration: none; }
    .back-link a:hover { text-decoration: underline; }
  </style>
</head>
<body>
  <div class="login-box">
    <div class="brand">
      <div class="admin-badge">Admin Portal</div>
      <div class="logo">Job<span>Drop</span></div>
      <p>Sign in to manage job listings</p>
    </div>

    <div class="error-msg" id="errorMsg">❌ Invalid username or password.</div>

    <label for="username">Username</label>
    <input type="text" id="username" placeholder="Enter admin username" autocomplete="off"/>

    <label for="password">Password</label>
    <input type="password" id="password" placeholder="Enter password"/>

    <button class="login-btn" onclick="doLogin()">Sign In β†’</button>

    <div class="back-link">
      <a href="index.html">← Back to Job Board</a>
    </div>
  </div>

  <script>
    // Default credentials β€” change these!
    const ADMIN_USER = 'admin';
    const ADMIN_PASS = 'jobdrop123';

    document.getElementById('password').addEventListener('keydown', e => {
      if (e.key === 'Enter') doLogin();
    });

    function doLogin() {
      const user = document.getElementById('username').value.trim();
      const pass = document.getElementById('password').value;
      const err = document.getElementById('errorMsg');

      if (user === ADMIN_USER && pass === ADMIN_PASS) {
        sessionStorage.setItem('jd_admin', '1');
        window.location.href = 'admin-dashboard.html';
      } else {
        err.style.display = 'block';
        document.getElementById('password').value = '';
      }
    }
  </script>
</body>
</html>