261 lines
8.7 KiB
PHP
261 lines
8.7 KiB
PHP
<?php
|
|
declare(strict_types=1);
|
|
require_once __DIR__ . '/db/config.php';
|
|
$settings = get_company_settings();
|
|
$baseUrl = get_base_url();
|
|
?>
|
|
<!doctype html>
|
|
<html lang="en">
|
|
<head>
|
|
<meta charset="utf-8">
|
|
<meta name="viewport" content="width=device-width, initial-scale=1">
|
|
<title><?= htmlspecialchars($settings['company_name']) ?> - Welcome</title>
|
|
<meta name="description" content="Welcome to <?= htmlspecialchars($settings['company_name']) ?> POS System. Manage your business efficiently.">
|
|
<?php if (!empty($settings['favicon_url'])): ?>
|
|
<link rel="icon" href="<?= $baseUrl . htmlspecialchars($settings['favicon_url']) ?>?v=<?= time() ?>">
|
|
<?php endif; ?>
|
|
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0/dist/css/bootstrap.min.css" rel="stylesheet">
|
|
<link href="https://cdn.jsdelivr.net/npm/bootstrap-icons@1.10.5/font/bootstrap-icons.css" rel="stylesheet">
|
|
<link rel="preconnect" href="https://fonts.googleapis.com">
|
|
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
|
|
<link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;600;700&display=swap" rel="stylesheet">
|
|
<style>
|
|
:root {
|
|
--primary-gradient: linear-gradient(135deg, #6366f1 0%, #a855f7 100%);
|
|
--accent-color: #f43f5e;
|
|
--bg-soft: #f8fafc;
|
|
--card-shadow: 0 20px 25px -5px rgb(0 0 0 / 0.1), 0 8px 10px -6px rgb(0 0 0 / 0.1);
|
|
}
|
|
body {
|
|
font-family: 'Inter', sans-serif;
|
|
background-color: var(--bg-soft);
|
|
color: #1e293b;
|
|
min-height: 100vh;
|
|
display: flex;
|
|
flex-direction: column;
|
|
position: relative;
|
|
overflow-x: hidden;
|
|
}
|
|
/* Background Decorations */
|
|
.shape {
|
|
position: absolute;
|
|
z-index: -1;
|
|
filter: blur(80px);
|
|
opacity: 0.4;
|
|
border-radius: 50%;
|
|
}
|
|
.shape-1 {
|
|
width: 400px;
|
|
height: 400px;
|
|
background: #6366f1;
|
|
top: -100px;
|
|
right: -100px;
|
|
}
|
|
.shape-2 {
|
|
width: 300px;
|
|
height: 300px;
|
|
background: #a855f7;
|
|
bottom: -50px;
|
|
left: -50px;
|
|
}
|
|
|
|
.main-container {
|
|
flex: 1;
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
padding: 2rem;
|
|
}
|
|
|
|
.hero-card {
|
|
background: rgba(255, 255, 255, 0.9);
|
|
backdrop-filter: blur(12px);
|
|
border-radius: 32px;
|
|
border: 1px solid rgba(255, 255, 255, 0.5);
|
|
box-shadow: var(--card-shadow);
|
|
padding: 3rem;
|
|
max-width: 1000px;
|
|
width: 100%;
|
|
text-align: center;
|
|
}
|
|
|
|
.logo-wrapper {
|
|
background: #f1f5f9;
|
|
display: inline-flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
padding: 1.5rem;
|
|
border-radius: 24px;
|
|
margin-bottom: 2rem;
|
|
box-shadow: inset 0 2px 4px 0 rgba(0, 0, 0, 0.05);
|
|
}
|
|
|
|
.company-logo {
|
|
max-height: 120px;
|
|
width: auto;
|
|
display: block;
|
|
filter: drop-shadow(0 4px 6px rgba(0,0,0,0.1));
|
|
}
|
|
|
|
.welcome-title {
|
|
font-weight: 800;
|
|
font-size: 2.5rem;
|
|
margin-bottom: 1rem;
|
|
background: var(--primary-gradient);
|
|
-webkit-background-clip: text;
|
|
-webkit-text-fill-color: transparent;
|
|
}
|
|
|
|
.welcome-subtitle {
|
|
font-size: 1.1rem;
|
|
color: #64748b;
|
|
margin-bottom: 3rem;
|
|
}
|
|
|
|
.portal-grid {
|
|
display: grid;
|
|
grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
|
|
gap: 2rem;
|
|
}
|
|
|
|
.portal-card {
|
|
background: #ffffff;
|
|
border-radius: 24px;
|
|
padding: 2.5rem;
|
|
text-decoration: none;
|
|
color: inherit;
|
|
transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
|
|
border: 1px solid #f1f5f9;
|
|
display: flex;
|
|
flex-direction: column;
|
|
align-items: center;
|
|
position: relative;
|
|
overflow: hidden;
|
|
}
|
|
|
|
.portal-card:hover {
|
|
transform: translateY(-10px);
|
|
box-shadow: 0 25px 50px -12px rgb(0 0 0 / 0.15);
|
|
border-color: #e2e8f0;
|
|
}
|
|
|
|
.portal-card i {
|
|
font-size: 3.5rem;
|
|
margin-bottom: 1.5rem;
|
|
transition: transform 0.3s ease;
|
|
}
|
|
|
|
.portal-card:hover i {
|
|
transform: scale(1.1) rotate(5deg);
|
|
}
|
|
|
|
.portal-card.pos i { color: #6366f1; }
|
|
.portal-card.admin i { color: #ec4899; }
|
|
.portal-card.feedback i { color: #f59e0b; }
|
|
|
|
.portal-card h3 {
|
|
font-weight: 700;
|
|
font-size: 1.25rem;
|
|
margin-bottom: 0.5rem;
|
|
}
|
|
|
|
.portal-card p {
|
|
font-size: 0.9rem;
|
|
color: #64748b;
|
|
margin-bottom: 0;
|
|
}
|
|
|
|
.footer {
|
|
padding: 2rem;
|
|
text-align: center;
|
|
color: #94a3b8;
|
|
font-size: 0.875rem;
|
|
}
|
|
|
|
.floating-object {
|
|
position: absolute;
|
|
width: 40px;
|
|
height: 40px;
|
|
background: var(--primary-gradient);
|
|
border-radius: 8px;
|
|
opacity: 0.1;
|
|
animation: float 6s ease-in-out infinite;
|
|
}
|
|
|
|
@keyframes float {
|
|
0%, 100% { transform: translateY(0) rotate(0); }
|
|
50% { transform: translateY(-20px) rotate(15deg); }
|
|
}
|
|
|
|
@media (max-width: 768px) {
|
|
.hero-card { padding: 2rem 1.5rem; }
|
|
.welcome-title { font-size: 2rem; }
|
|
}
|
|
</style>
|
|
</head>
|
|
<body>
|
|
|
|
<div class="shape shape-1"></div>
|
|
<div class="shape shape-2"></div>
|
|
|
|
<div class="main-container">
|
|
<div class="hero-card">
|
|
|
|
<div class="logo-wrapper">
|
|
<?php if (!empty($settings['logo_url'])): ?>
|
|
<img src="<?= $baseUrl . htmlspecialchars($settings['logo_url']) ?>?v=<?= time() ?>" alt="Logo" class="company-logo">
|
|
<?php else: ?>
|
|
<i class="bi bi-grid-1x2-fill fs-1 text-primary"></i>
|
|
<?php endif; ?>
|
|
</div>
|
|
|
|
<h1 class="welcome-title"><?= htmlspecialchars($settings['company_name']) ?></h1>
|
|
<p class="welcome-subtitle">Your all-in-one business management solution.</p>
|
|
|
|
<div class="portal-grid">
|
|
<!-- POS Terminal -->
|
|
<a href="pos.php" class="portal-card pos">
|
|
<div class="floating-object" style="top: 10%; right: 10%;"></div>
|
|
<i class="bi bi-pc-display-horizontal"></i>
|
|
<h3>POS Terminal</h3>
|
|
<p>Process sales, manage orders, and handle payments.</p>
|
|
</a>
|
|
|
|
<!-- Management Console -->
|
|
<a href="admin/" class="portal-card admin">
|
|
<div class="floating-object" style="bottom: 10%; left: 10%; animation-delay: 2s; background: linear-gradient(135deg, #ec4899 0%, #f43f5e 100%);"></div>
|
|
<i class="bi bi-speedometer2"></i>
|
|
<h3>Admin Dashboard</h3>
|
|
<p>Inventory, reports, staff management, and settings.</p>
|
|
</a>
|
|
|
|
<!-- Customer Feedback -->
|
|
<a href="online_order.php" class="portal-card" style="background: linear-gradient(135deg, #10b981 0%, #059669 100%);">
|
|
<i class="bi bi-cart"></i>
|
|
<h3>Online Order</h3>
|
|
<p>Place an order for pickup or delivery.</p>
|
|
</a>
|
|
<a href="rate.php" class="portal-card feedback">
|
|
<div class="floating-object" style="top: 20%; left: 20%; animation-delay: 1s; background: linear-gradient(135deg, #f59e0b 0%, #fbbf24 100%);"></div>
|
|
<i class="bi bi-star"></i>
|
|
<h3>Rate Our Service</h3>
|
|
<p>Tell us about your experience and rate our staff.</p>
|
|
</a>
|
|
</div>
|
|
|
|
<div class="mt-5 pt-4">
|
|
<p class="text-muted small">
|
|
<i class="bi bi-info-circle me-1"></i> Authorized staff access only.
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
</div>
|
|
|
|
<div class="footer">
|
|
<p class="mb-1">© <?= date('Y') ?> <?= htmlspecialchars($settings['company_name']) ?>. All rights reserved.</p>
|
|
<p class="mb-0">Powered By Flatlogic POS Solution</p>
|
|
</div>
|
|
|
|
</body>
|
|
</html>
|