version 0

This commit is contained in:
Flatlogic Bot 2025-10-08 16:03:18 +00:00
parent 74009ca607
commit 3584573aa8
7 changed files with 335 additions and 157 deletions

72
assets/css/custom.css Normal file
View File

@ -0,0 +1,72 @@
/* General Body Styles */
body {
font-family: 'Inter', sans-serif;
background-color: #F9FAFB;
color: #111827;
}
/* Typography */
h1, h2, h3, h4, h5, h6 {
font-family: 'Georgia', serif;
}
/* Hero Section */
.hero {
background: linear-gradient(45deg, #4F46E5, #10B981);
color: white;
padding: 100px 0;
}
.hero h1 {
font-size: 3.5rem;
font-weight: bold;
}
.hero p {
font-size: 1.25rem;
}
/* Section Padding */
.section {
padding: 80px 0;
}
/* Card Styles */
.card {
border: none;
border-radius: 0.5rem;
box-shadow: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
}
/* Button Styles */
.btn-primary {
background-color: #4F46E5;
border-color: #4F46E5;
padding: 12px 24px;
border-radius: 0.5rem;
}
.btn-primary:hover {
background-color: #4338CA;
border-color: #4338CA;
}
.btn-secondary {
background-color: #10B981;
border-color: #10B981;
padding: 12px 24px;
border-radius: 0.5rem;
}
.btn-secondary:hover {
background-color: #059669;
border-color: #059669;
}
/* Contact Form */
.contact-form {
background: white;
padding: 40px;
border-radius: 0.5rem;
box-shadow: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
}

10
assets/js/main.js Normal file
View File

@ -0,0 +1,10 @@
// Smooth scrolling for anchor links
document.querySelectorAll('a[href^="#"]').forEach(anchor => {
anchor.addEventListener('click', function (e) {
e.preventDefault();
document.querySelector(this.getAttribute('href')).scrollIntoView({
behavior: 'smooth'
});
});
});

39
contact.php Normal file
View File

@ -0,0 +1,39 @@
<?php
session_start();
if ($_SERVER["REQUEST_METHOD"] == "POST") {
require_once 'db/config.php';
$name = trim($_POST['name']);
$email = trim($_POST['email']);
$message = trim($_POST['message']);
if (empty($name) || empty($email) || empty($message) || !filter_var($email, FILTER_VALIDATE_EMAIL)) {
$_SESSION['error'] = "Please fill out all fields with valid information.";
header("Location: /#contact");
exit();
}
try {
$pdo = db();
$sql = "INSERT INTO contact_submissions (name, email, message) VALUES (?, ?, ?)";
$stmt = $pdo->prepare($sql);
$stmt->execute([$name, $email, $message]);
$_SESSION['success'] = "Thank you for your message. We will get back to you shortly.";
// Optionally send an email notification
// require_once 'mail/MailService.php';
// MailService::sendContactMessage($name, $email, $message);
} catch (PDOException $e) {
// In a real app, you would log this error
$_SESSION['error'] = "Sorry, there was an error submitting your message. Please try again later.";
}
header("Location: /#contact");
exit();
} else {
header("Location: /");
exit();
}

View File

@ -1,17 +1,40 @@
<?php <?php
// Generated by setup_mariadb_project.sh — edit as needed. // Database configuration
define('DB_HOST', '127.0.0.1'); define('DB_HOST', '127.0.0.1');
define('DB_NAME', 'app_30953'); define('DB_PORT', '3306');
define('DB_USER', 'app_30953'); define('DB_NAME', 'app');
define('DB_PASS', 'e45f2778-db1f-450c-99c6-29efb4601472'); define('DB_USER', 'app');
define('DB_PASSWORD', 'app');
function db() { function db() {
static $pdo; static $pdo;
if (!$pdo) { if ($pdo) {
$pdo = new PDO('mysql:host='.DB_HOST.';dbname='.DB_NAME.';charset=utf8mb4', DB_USER, DB_PASS, [ return $pdo;
}
$dsn = 'mysql:host=' . DB_HOST . ';port=' . DB_PORT . ';dbname=' . DB_NAME . ';charset=utf8mb4';
$options = [
PDO::ATTR_ERRMODE => PDO::ERRMODE_EXCEPTION, PDO::ATTR_ERRMODE => PDO::ERRMODE_EXCEPTION,
PDO::ATTR_DEFAULT_FETCH_MODE => PDO::FETCH_ASSOC, PDO::ATTR_DEFAULT_FETCH_MODE => PDO::FETCH_ASSOC,
]); PDO::ATTR_EMULATE_PREPARES => false,
} ];
try {
$pdo = new PDO($dsn, DB_USER, DB_PASSWORD, $options);
return $pdo; return $pdo;
} catch (PDOException $e) {
// In a real app, you would log this error and show a generic error page.
// For development, it's okay to show the error.
throw new PDOException($e->getMessage(), (int)$e->getCode());
}
}
// Run migrations
try {
$pdo = db();
$migration_files = glob(__DIR__ . '/migrations/*.sql');
foreach ($migration_files as $file) {
$sql = file_get_contents($file);
$pdo->exec($sql);
}
} catch (PDOException $e) {
// Handle migration errors
} }

View File

@ -0,0 +1,7 @@
CREATE TABLE IF NOT EXISTS contact_submissions (
id INT AUTO_INCREMENT PRIMARY KEY,
name VARCHAR(255) NOT NULL,
email VARCHAR(255) NOT NULL,
message TEXT NOT NULL,
created_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP
);

285
index.php
View File

@ -1,150 +1,159 @@
<?php <?php session_start(); ?>
declare(strict_types=1); <!DOCTYPE html>
@ini_set('display_errors', '1');
@error_reporting(E_ALL);
@date_default_timezone_set('UTC');
$phpVersion = PHP_VERSION;
$now = date('Y-m-d H:i:s');
?>
<!doctype html>
<html lang="en"> <html lang="en">
<head> <head>
<meta charset="utf-8" /> <meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1" /> <meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>New Style</title> <title>Compliance AI - Your Partner in Automated Compliance</title>
<?php <meta name="description" content="Compliance AI offers a cutting-edge SaaS platform to automate and streamline your compliance processes. Built with Flatlogic Generator.">
// Read project preview data from environment <meta name="keywords" content="compliance saas, ai compliance, regulatory technology, automated compliance, risk management, policy management, compliance reporting, flatlogic generator">
$projectDescription = $_SERVER['PROJECT_DESCRIPTION'] ?? ''; <meta property="og:title" content="Compliance AI - Your Partner in Automated Compliance">
$projectImageUrl = $_SERVER['PROJECT_IMAGE_URL'] ?? ''; <meta property="og:description" content="Compliance AI offers a cutting-edge SaaS platform to automate and streamline your compliance processes.">
?> <meta property="og:image" content="<?php echo htmlspecialchars($_SERVER['PROJECT_IMAGE_URL'] ?? ''); ?>">
<?php if ($projectDescription): ?> <meta name="twitter:card" content="summary_large_image">
<!-- Meta description --> <meta name="twitter:image" content="<?php echo htmlspecialchars($_SERVER['PROJECT_IMAGE_URL'] ?? ''); ?>">
<meta name="description" content='<?= htmlspecialchars($projectDescription) ?>' />
<!-- Open Graph meta tags --> <link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.2/dist/css/bootstrap.min.css" rel="stylesheet">
<meta property="og:description" content="<?= htmlspecialchars($projectDescription) ?>" />
<!-- Twitter meta tags -->
<meta property="twitter:description" content="<?= htmlspecialchars($projectDescription) ?>" />
<?php endif; ?>
<?php if ($projectImageUrl): ?>
<!-- Open Graph image -->
<meta property="og:image" content="<?= htmlspecialchars($projectImageUrl) ?>" />
<!-- Twitter image -->
<meta property="twitter:image" content="<?= htmlspecialchars($projectImageUrl) ?>" />
<?php endif; ?>
<link rel="preconnect" href="https://fonts.googleapis.com"> <link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin> <link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
<link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;700&display=swap" rel="stylesheet"> <link href="https://fonts.googleapis.com/css2?family=Georgia&family=Inter:wght@400;700&display=swap" rel="stylesheet">
<style> <link rel="stylesheet" href="assets/css/custom.css?v=<?php echo time(); ?>">
:root {
--bg-color-start: #6a11cb;
--bg-color-end: #2575fc;
--text-color: #ffffff;
--card-bg-color: rgba(255, 255, 255, 0.01);
--card-border-color: rgba(255, 255, 255, 0.1);
}
body {
margin: 0;
font-family: 'Inter', sans-serif;
background: linear-gradient(45deg, var(--bg-color-start), var(--bg-color-end));
color: var(--text-color);
display: flex;
justify-content: center;
align-items: center;
min-height: 100vh;
text-align: center;
overflow: hidden;
position: relative;
}
body::before {
content: '';
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
background-image: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" width="100" height="100" viewBox="0 0 100 100"><path d="M-10 10L110 10M10 -10L10 110" stroke-width="1" stroke="rgba(255,255,255,0.05)"/></svg>');
animation: bg-pan 20s linear infinite;
z-index: -1;
}
@keyframes bg-pan {
0% { background-position: 0% 0%; }
100% { background-position: 100% 100%; }
}
main {
padding: 2rem;
}
.card {
background: var(--card-bg-color);
border: 1px solid var(--card-border-color);
border-radius: 16px;
padding: 2rem;
backdrop-filter: blur(20px);
-webkit-backdrop-filter: blur(20px);
box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.1);
}
.loader {
margin: 1.25rem auto 1.25rem;
width: 48px;
height: 48px;
border: 3px solid rgba(255, 255, 255, 0.25);
border-top-color: #fff;
border-radius: 50%;
animation: spin 1s linear infinite;
}
@keyframes spin {
from { transform: rotate(0deg); }
to { transform: rotate(360deg); }
}
.hint {
opacity: 0.9;
}
.sr-only {
position: absolute;
width: 1px; height: 1px;
padding: 0; margin: -1px;
overflow: hidden;
clip: rect(0, 0, 0, 0);
white-space: nowrap; border: 0;
}
h1 {
font-size: 3rem;
font-weight: 700;
margin: 0 0 1rem;
letter-spacing: -1px;
}
p {
margin: 0.5rem 0;
font-size: 1.1rem;
}
code {
background: rgba(0,0,0,0.2);
padding: 2px 6px;
border-radius: 4px;
font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}
footer {
position: absolute;
bottom: 1rem;
font-size: 0.8rem;
opacity: 0.7;
}
</style>
</head> </head>
<body> <body>
<main>
<!-- Navbar -->
<nav class="navbar navbar-expand-lg navbar-light bg-light sticky-top">
<div class="container">
<a class="navbar-brand" href="#">Compliance AI</a>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbarNav" aria-controls="navbarNav" aria-expanded="false" aria-label="Toggle navigation">
<span class="navbar-toggler-icon"></span>
</button>
<div class="collapse navbar-collapse" id="navbarNav">
<ul class="navbar-nav ms-auto">
<li class="nav-item"><a class="nav-link" href="#about">About</a></li>
<li class="nav-item"><a class="nav-link" href="#portfolio">Portfolio</a></li>
<li class="nav-item"><a class="nav-link" href="#testimonials">Testimonials</a></li>
<li class="nav-item"><a class="nav-link" href="#contact">Contact</a></li>
<li class="nav-item"><a class="nav-link" href="/privacy.php">Privacy</a></li>
</ul>
</div>
</div>
</nav>
<!-- Hero Section -->
<header class="hero text-center">
<div class="container">
<h1>Automate Your Compliance. Unleash Your Growth.</h1>
<p class="lead my-4">The intelligent platform that simplifies compliance, so you can focus on what matters.</p>
<a href="#contact" class="btn btn-light btn-lg">Request a Demo</a>
</div>
</header>
<!-- About Section -->
<section id="about" class="section">
<div class="container text-center">
<h2>About Compliance AI</h2>
<p class="lead">We are a team of experts dedicated to simplifying regulatory compliance through the power of artificial intelligence. Our platform helps you navigate the complex landscape of rules and regulations with ease.</p>
</div>
</section>
<!-- Portfolio Section -->
<section id="portfolio" class="section bg-white">
<div class="container">
<h2 class="text-center mb-5">See Our Platform in Action</h2>
<div class="row g-4">
<div class="col-md-6">
<div class="card"> <div class="card">
<h1>Analyzing your requirements and generating your website…</h1> <img src="https://picsum.photos/seed/p1/800/600" class="card-img-top" alt="Dashboard showing compliance metrics.">
<div class="loader" role="status" aria-live="polite" aria-label="Applying initial changes"> <div class="card-body">
<span class="sr-only">Loading…</span> <h5 class="card-title">Intuitive Dashboards</h5>
<p class="card-text">Visualize your compliance posture at a glance with our clean and informative dashboards.</p>
</div> </div>
<p class="hint"><?= ($_SERVER['HTTP_HOST'] ?? '') === 'appwizzy.com' ? 'AppWizzy' : 'Flatlogic' ?> AI is collecting your requirements and applying the first changes.</p>
<p class="hint">This page will update automatically as the plan is implemented.</p>
<p>Runtime: PHP <code><?= htmlspecialchars($phpVersion) ?></code> — UTC <code><?= htmlspecialchars($now) ?></code></p>
</div> </div>
</main> </div>
<footer> <div class="col-md-6">
Page updated: <?= htmlspecialchars($now) ?> (UTC) <div class="card">
<img src="https://picsum.photos/seed/p2/800/600" class="card-img-top" alt="Automated reporting feature.">
<div class="card-body">
<h5 class="card-title">Automated Reporting</h5>
<p class="card-text">Generate comprehensive compliance reports automatically, saving you time and effort.</p>
</div>
</div>
</div>
</div>
</div>
</section>
<!-- Testimonials Section -->
<section id="testimonials" class="section">
<div class="container">
<h2 class="text-center mb-5">What Our Clients Say</h2>
<div class="row">
<div class="col-md-4">
<div class="card p-4 text-center">
<p>"Compliance AI has transformed how we handle regulatory requirements. It's a game-changer."</p>
<footer class="blockquote-footer mt-2">Jane Doe, CEO at TechCorp</footer>
</div>
</div>
<div class="col-md-4">
<div class="card p-4 text-center">
<p>"The platform is incredibly user-friendly and the support team is top-notch."</p>
<footer class="blockquote-footer mt-2">John Smith, Compliance Officer at Innovate Ltd.</footer>
</div>
</div>
<div class="col-md-4">
<div class="card p-4 text-center">
<p>"We've saved countless hours on compliance tasks since implementing Compliance AI."</p>
<footer class="blockquote-footer mt-2">Sam Wilson, Founder at StartUp Co.</footer>
</div>
</div>
</div>
</div>
</section>
<!-- Contact Section -->
<section id="contact" class="section bg-white">
<div class="container">
<div class="row justify-content-center">
<div class="col-lg-8">
<h2 class="text-center mb-5">Get in Touch</h2>
<div class="contact-form">
<?php if (isset($_SESSION['success'])): ?>
<div class="alert alert-success"><?php echo $_SESSION['success']; unset($_SESSION['success']); ?></div>
<?php endif; ?>
<?php if (isset($_SESSION['error'])): ?>
<div class="alert alert-danger"><?php echo $_SESSION['error']; unset($_SESSION['error']); ?></div>
<?php endif; ?>
<form action="contact.php" method="POST">
<div class="mb-3">
<label for="name" class="form-label">Name</label>
<input type="text" class="form-control" id="name" name="name" required>
</div>
<div class="mb-3">
<label for="email" class="form-label">Email address</label>
<input type="email" class="form-control" id="email" name="email" required>
</div>
<div class="mb-3">
<label for="message" class="form-label">Message</label>
<textarea class="form-control" id="message" name="message" rows="5" required></textarea>
</div>
<button type="submit" class="btn btn-primary w-100">Send Message</button>
</form>
</div>
</div>
</div>
</div>
</section>
<!-- Footer -->
<footer class="bg-dark text-white text-center py-4">
<div class="container">
<p>&copy; <?php echo date('Y'); ?> Compliance AI. All Rights Reserved.</p>
<p><a href="/privacy.php" class="text-white">Privacy Policy</a></p>
</div>
</footer> </footer>
<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.3.2/dist/js/bootstrap.bundle.min.js"></script>
<script src="assets/js/main.js?v=<?php echo time(); ?>"></script>
</body> </body>
</html> </html>

18
privacy.php Normal file
View File

@ -0,0 +1,18 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Privacy Policy - Compliance AI</title>
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.2/dist/css/bootstrap.min.css" rel="stylesheet">
<link rel="stylesheet" href="assets/css/custom.css?v=<?php echo time(); ?>">
</head>
<body>
<div class="container py-5">
<h1>Privacy Policy</h1>
<p>This is a placeholder for your privacy policy.</p>
<p>Information on how you collect, use, and disclose user data will go here.</p>
<a href="/">Back to Home</a>
</div>
</body>
</html>