2026-07-12 13:21:10 +00:00
|
|
|
<!DOCTYPE html>
|
|
|
|
|
<html lang="sv">
|
|
|
|
|
<head>
|
2026-07-12 17:17:26 +00:00
|
|
|
<meta charset="UTF-8">
|
|
|
|
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
|
|
|
|
<title>BOC — Business Operations Center</title>
|
|
|
|
|
<link rel="stylesheet" href="assets/boc.css">
|
|
|
|
|
<style>
|
|
|
|
|
.login-container {
|
|
|
|
|
min-height: 100vh;
|
|
|
|
|
display: flex;
|
|
|
|
|
align-items: center;
|
|
|
|
|
justify-content: center;
|
|
|
|
|
background: linear-gradient(135deg, #FDF8F3 0%, #F5EDE4 100%);
|
|
|
|
|
}
|
|
|
|
|
.login-box {
|
|
|
|
|
background: white;
|
|
|
|
|
padding: 3rem;
|
|
|
|
|
border-radius: 16px;
|
|
|
|
|
box-shadow: 0 20px 60px rgba(0,0,0,0.1);
|
|
|
|
|
width: 100%;
|
|
|
|
|
max-width: 420px;
|
|
|
|
|
text-align: center;
|
|
|
|
|
}
|
|
|
|
|
.login-logo {
|
|
|
|
|
width: 80px;
|
|
|
|
|
height: 80px;
|
|
|
|
|
background: #C96A3A;
|
|
|
|
|
border-radius: 20px;
|
|
|
|
|
display: flex;
|
|
|
|
|
align-items: center;
|
|
|
|
|
justify-content: center;
|
|
|
|
|
margin: 0 auto 1.5rem;
|
|
|
|
|
font-size: 2rem;
|
|
|
|
|
color: white;
|
|
|
|
|
}
|
|
|
|
|
.login-box h1 {
|
|
|
|
|
color: #1A1A2E;
|
|
|
|
|
font-size: 1.75rem;
|
|
|
|
|
margin-bottom: 0.5rem;
|
|
|
|
|
}
|
|
|
|
|
.login-box p {
|
|
|
|
|
color: #6B7280;
|
|
|
|
|
margin-bottom: 2rem;
|
|
|
|
|
}
|
|
|
|
|
.form-group {
|
|
|
|
|
margin-bottom: 1.25rem;
|
|
|
|
|
text-align: left;
|
|
|
|
|
}
|
|
|
|
|
.form-group label {
|
|
|
|
|
display: block;
|
|
|
|
|
margin-bottom: 0.5rem;
|
|
|
|
|
color: #374151;
|
|
|
|
|
font-weight: 500;
|
|
|
|
|
font-size: 0.875rem;
|
|
|
|
|
}
|
|
|
|
|
.form-group input {
|
|
|
|
|
width: 100%;
|
|
|
|
|
padding: 0.875rem 1rem;
|
|
|
|
|
border: 2px solid #E5E7EB;
|
|
|
|
|
border-radius: 10px;
|
|
|
|
|
font-size: 1rem;
|
|
|
|
|
transition: all 0.2s;
|
|
|
|
|
box-sizing: border-box;
|
|
|
|
|
}
|
|
|
|
|
.form-group input:focus {
|
|
|
|
|
outline: none;
|
|
|
|
|
border-color: #C96A3A;
|
|
|
|
|
box-shadow: 0 0 0 3px rgba(201,106,58,0.1);
|
|
|
|
|
}
|
|
|
|
|
.btn-login {
|
|
|
|
|
width: 100%;
|
|
|
|
|
padding: 1rem;
|
|
|
|
|
background: #C96A3A;
|
|
|
|
|
color: white;
|
|
|
|
|
border: none;
|
|
|
|
|
border-radius: 10px;
|
|
|
|
|
font-size: 1rem;
|
|
|
|
|
font-weight: 600;
|
|
|
|
|
cursor: pointer;
|
|
|
|
|
transition: all 0.2s;
|
|
|
|
|
margin-top: 0.5rem;
|
|
|
|
|
}
|
|
|
|
|
.btn-login:hover {
|
|
|
|
|
background: #B85A2E;
|
|
|
|
|
transform: translateY(-1px);
|
|
|
|
|
box-shadow: 0 4px 12px rgba(201,106,58,0.3);
|
|
|
|
|
}
|
|
|
|
|
.login-footer {
|
|
|
|
|
margin-top: 2rem;
|
|
|
|
|
padding-top: 1.5rem;
|
|
|
|
|
border-top: 1px solid #E5E7EB;
|
|
|
|
|
font-size: 0.75rem;
|
|
|
|
|
color: #9CA3AF;
|
|
|
|
|
}
|
|
|
|
|
.error-msg {
|
|
|
|
|
background: #FEE2E2;
|
|
|
|
|
color: #DC2626;
|
|
|
|
|
padding: 0.75rem;
|
|
|
|
|
border-radius: 8px;
|
|
|
|
|
margin-bottom: 1rem;
|
|
|
|
|
font-size: 0.875rem;
|
|
|
|
|
display: none;
|
|
|
|
|
}
|
|
|
|
|
.error-msg.show {
|
|
|
|
|
display: block;
|
|
|
|
|
}
|
|
|
|
|
</style>
|
2026-07-12 13:21:10 +00:00
|
|
|
</head>
|
|
|
|
|
<body>
|
2026-07-12 17:17:26 +00:00
|
|
|
<div class="login-container">
|
|
|
|
|
<div class="login-box">
|
|
|
|
|
<div class="login-logo">🏢</div>
|
|
|
|
|
<h1>Business Operations Center</h1>
|
|
|
|
|
<p>Logga in för att hantera ditt företag</p>
|
|
|
|
|
|
|
|
|
|
<div class="error-msg" id="error"></div>
|
|
|
|
|
|
|
|
|
|
<form id="loginForm">
|
|
|
|
|
<div class="form-group">
|
|
|
|
|
<label for="email">E-post</label>
|
|
|
|
|
<input type="email" id="email" name="email" placeholder="namn@foretag.se" required>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="form-group">
|
|
|
|
|
<label for="password">Lösenord</label>
|
|
|
|
|
<input type="password" id="password" name="password" placeholder="••••••••" required>
|
|
|
|
|
</div>
|
|
|
|
|
<button type="submit" class="btn-login">Logga in</button>
|
|
|
|
|
</form>
|
|
|
|
|
|
|
|
|
|
<div class="login-footer">
|
|
|
|
|
Landvex Inc · AAMOS Platform<br>
|
|
|
|
|
<a href="https://aamos.systems" style="color:#C96A3A;text-decoration:none;">aamos.systems</a>
|
|
|
|
|
</div>
|
2026-07-12 13:21:10 +00:00
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
|
2026-07-12 17:17:26 +00:00
|
|
|
<script>
|
|
|
|
|
document.getElementById('loginForm').addEventListener('submit', async (e) => {
|
|
|
|
|
e.preventDefault();
|
|
|
|
|
const error = document.getElementById('error');
|
|
|
|
|
error.classList.remove('show');
|
|
|
|
|
|
|
|
|
|
const email = document.getElementById('email').value;
|
|
|
|
|
const password = document.getElementById('password').value;
|
|
|
|
|
|
|
|
|
|
try {
|
|
|
|
|
const res = await fetch('/api/v1/auth/login', {
|
|
|
|
|
method: 'POST',
|
|
|
|
|
headers: { 'Content-Type': 'application/json' },
|
|
|
|
|
body: JSON.stringify({ email, password })
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
const data = await res.json();
|
|
|
|
|
|
|
|
|
|
if (data.token) {
|
|
|
|
|
localStorage.setItem('boc_token', data.token);
|
|
|
|
|
localStorage.setItem('boc_user', JSON.stringify(data.user));
|
|
|
|
|
window.location.href = '/dashboard.html';
|
|
|
|
|
} else {
|
|
|
|
|
error.textContent = data.error || 'Inloggning misslyckades';
|
|
|
|
|
error.classList.add('show');
|
|
|
|
|
}
|
|
|
|
|
} catch (err) {
|
|
|
|
|
error.textContent = 'Anslutningsfel. Försök igen.';
|
|
|
|
|
error.classList.add('show');
|
|
|
|
|
}
|
2026-07-12 13:21:10 +00:00
|
|
|
});
|
2026-07-12 17:17:26 +00:00
|
|
|
</script>
|
2026-07-12 13:21:10 +00:00
|
|
|
</body>
|
|
|
|
|
</html>
|