update smth

This commit is contained in:
Flatlogic Bot 2025-09-11 16:10:10 +00:00
parent 9669af56cc
commit 1724634d99
6 changed files with 552 additions and 123 deletions

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

@ -0,0 +1,88 @@
:root {
--bs-primary-rgb: 13, 110, 253;
--bs-secondary-rgb: 111, 66, 193;
--brand-light: #f8f9fa;
--brand-dark: #212529;
--brand-surface: #ffffff;
--bs-font-sans-serif: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
--bs-border-radius: 0.5rem;
--bs-border-radius-lg: 1rem;
--bs-border-radius-sm: 0.25rem;
}
body {
background-color: var(--brand-light);
color: var(--brand-dark);
}
.navbar {
transition: background-color 0.3s ease-in-out, padding 0.3s ease-in-out;
}
.navbar.scrolled {
background-color: var(--brand-surface);
box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
padding-top: 0.5rem;
padding-bottom: 0.5rem;
}
.section-py {
padding-top: 5rem;
padding-bottom: 5rem;
}
.hero {
background: linear-gradient(to bottom, rgba(13, 110, 253, 0.05), rgba(248, 249, 250, 0.05));
padding: 8rem 0;
}
.hero h1 {
font-weight: 700;
}
.btn-primary {
padding: 0.75rem 1.5rem;
font-weight: 600;
}
.btn-secondary {
padding: 0.75rem 1.5rem;
font-weight: 600;
}
.social-proof-logos img {
height: 40px;
filter: grayscale(100%);
opacity: 0.6;
transition: filter 0.3s, opacity 0.3s;
}
.social-proof-logos img:hover {
filter: grayscale(0%);
opacity: 1;
}
.testimonial-card {
border: none;
background-color: var(--brand-surface);
}
.testimonial-card .card-body {
padding: 2rem;
}
.testimonial-card img {
width: 80px;
height: 80px;
object-fit: cover;
}
.form-control:focus {
box-shadow: 0 0 0 0.25rem rgba(var(--bs-primary-rgb), 0.25);
border-color: rgba(var(--bs-primary-rgb), 0.5);
}
.footer {
background-color: var(--brand-surface);
}

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

@ -0,0 +1,69 @@
document.addEventListener('DOMContentLoaded', function () {
// Navbar shrink on scroll
const navbar = document.querySelector('.navbar');
if (navbar) {
window.addEventListener('scroll', () => {
if (window.scrollY > 50) {
navbar.classList.add('scrolled');
} else {
navbar.classList.remove('scrolled');
}
});
}
// Smooth scroll for anchor links
document.querySelectorAll('a.smooth-scroll[href^="#"]').forEach(anchor => {
anchor.addEventListener('click', function (e) {
e.preventDefault();
const targetId = this.getAttribute('href');
const targetElement = document.querySelector(targetId);
if(targetElement){
targetElement.scrollIntoView({ behavior: 'smooth' });
}
});
});
// Pricing Toggle
const pricingToggle = document.getElementById('pricingToggle');
if(pricingToggle) {
pricingToggle.addEventListener('change', function () {
const isYearly = this.checked;
document.querySelectorAll('.price-monthly').forEach(p => p.style.display = isYearly ? 'none' : 'block');
document.querySelectorAll('.price-yearly').forEach(p => p.style.display = isYearly ? 'block' : 'none');
});
}
// Lead Form Validation
const leadForm = document.getElementById('leadForm');
if (leadForm) {
leadForm.addEventListener('submit', function (e) {
let isValid = true;
const name = document.getElementById('name');
const email = document.getElementById('email');
const message = document.getElementById('message');
// Reset validation
[name, email, message].forEach(el => {
el.classList.remove('is-invalid');
});
if (name.value.trim() === '') {
name.classList.add('is-invalid');
isValid = false;
}
if (email.value.trim() === '' || !/^[\w-\.]+@([\w-]+\.)+[\w-]{2,4}$/.test(email.value)) {
email.classList.add('is-invalid');
isValid = false;
}
if (message.value.trim() === '') {
message.classList.add('is-invalid');
isValid = false;
}
if (!isValid) {
e.preventDefault();
}
});
}
});

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.0 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 72 KiB

View File

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

510
index.php
View File

@ -1,131 +1,395 @@
<?php
declare(strict_types=1);
@ini_set('display_errors', '1');
@error_reporting(E_ALL);
@date_default_timezone_set('UTC');
echo '<pre>';
var_dump(require 'mail/config.php');
echo '</pre>';
$form_message = '';
$form_error = '';
$phpVersion = PHP_VERSION;
$now = date('Y-m-d H:i:s');
if ($_SERVER["REQUEST_METHOD"] == "POST") {
require_once 'db/config.php';
require_once 'mail/MailService.php';
$name = filter_input(INPUT_POST, 'name', FILTER_SANITIZE_STRING);
$email = filter_input(INPUT_POST, 'email', FILTER_SANITIZE_EMAIL);
$message = filter_input(INPUT_POST, 'message', FILTER_SANITIZE_STRING);
if (empty($name) || empty($email) || empty($message) || !filter_var($email, FILTER_VALIDATE_EMAIL)) {
$form_error = "Please fill out all fields with valid information.";
} else {
try {
$pdo = db();
$stmt = $pdo->prepare("INSERT INTO leads (name, email, message) VALUES (?, ?, ?)");
$stmt->execute([$name, $email, $message]);
$mailResult = MailService::sendContactMessage($name, $email, $message);
if ($mailResult['success']) {
$form_message = "Thank you for your message! We will get back to you shortly.";
} else {
$form_error = "Sorry, there was an error sending your message. Please try again later.";
// Optionally log the detailed error: error_log($mailResult['error']);
}
} catch (PDOException $e) {
$form_error = "Sorry, there was a database error. Please try again later.";
// Optionally log the detailed error: error_log($e->getMessage());
}
}
}
?>
<!doctype html>
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1" />
<title>New Style</title>
<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;700&display=swap" rel="stylesheet">
<style>
: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>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Nimbus - Streamline Your Success</title>
<!-- Bootstrap CSS -->
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.2/dist/css/bootstrap.min.css" rel="stylesheet">
<!-- Bootstrap Icons -->
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bootstrap-icons@1.11.3/font/bootstrap-icons.min.css">
<!-- Google Fonts (Inter) -->
<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">
<!-- Custom CSS -->
<link rel="stylesheet" href="assets/css/custom.css?v=<?php echo time(); ?>">
</head>
<body>
<main>
<div class="card">
<h1>Analyzing your requirements and generating your website…</h1>
<div class="loader" role="status" aria-live="polite" aria-label="Applying initial changes">
<span class="sr-only">Loading…</span>
</div>
<p class="hint">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>
</main>
<footer>
Page updated: <?= htmlspecialchars($now) ?> (UTC)
</footer>
<!-- Header -->
<header>
<nav class="navbar navbar-expand-lg navbar-light fixed-top py-3">
<div class="container">
<a class="navbar-brand fw-bold" href="#">Nimbus</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 smooth-scroll" href="#features">Features</a></li>
<li class="nav-item"><a class="nav-link smooth-scroll" href="#testimonials">Testimonials</a></li>
<li class="nav-item"><a class="nav-link smooth-scroll" href="#pricing">Pricing</a></li>
<li class="nav-item"><a class="nav-link smooth-scroll" href="#faq">FAQ</a></li>
</ul>
<a href="#contact" class="btn btn-primary ms-lg-3 smooth-scroll">Contact Sales</a>
</div>
</div>
</nav>
</header>
<main>
<!-- Hero Section -->
<section id="hero" class="hero text-center">
<div class="container">
<div class="row justify-content-center">
<div class="col-lg-8">
<h1 class="display-4">Streamline Your Success.</h1>
<p class="lead my-4">Nimbus is the all-in-one platform to automate workflows, manage projects, and scale your business.</p>
<a href="#contact" class="btn btn-primary btn-lg smooth-scroll">Get Started Free</a>
<a href="#" class="btn btn-outline-secondary btn-lg ms-2">Watch Demo</a>
</div>
</div>
<img src="./assets/pasted-20250911-115131-dbff0810.png" class="img-fluid rounded-3 shadow-lg mt-5" alt="Abstract blue and white digital art representing cloud data streams.">
</div>
</section>
<!-- Social Proof -->
<section id="social-proof" class="py-5">
<div class="container text-center">
<h6 class="text-muted mb-4">TRUSTED BY LEADING COMPANIES WORLDWIDE</h6>
<div class="d-flex flex-wrap justify-content-center align-items-center social-proof-logos">
<img src="https://via.placeholder.com/150x50/CCCCCC/FFFFFF?text=CompanyA" alt="Company A Logo" class="mx-4 my-2">
<img src="https://via.placeholder.com/150x50/CCCCCC/FFFFFF?text=CompanyB" alt="Company B Logo" class="mx-4 my-2">
<img src="https://via.placeholder.com/150x50/CCCCCC/FFFFFF?text=CompanyC" alt="Company C Logo" class="mx-4 my-2">
<img src="https://via.placeholder.com/150x50/CCCCCC/FFFFFF?text=CompanyD" alt="Company D Logo" class="mx-4 my-2">
<img src="https://via.placeholder.com/150x50/CCCCCC/FFFFFF?text=CompanyE" alt="Company E Logo" class="mx-4 my-2">
</div>
</div>
</section>
<!-- Product Mock -->
<section id="product-mock" class="section-py">
<div class="container text-center">
<img src="https://picsum.photos/seed/nimbus-dashboard/1200/800" class="img-fluid rounded-3 shadow-lg" alt="A clean and modern dashboard UI for the Nimbus application.">
</div>
</section>
<!-- Features Section -->
<section id="features" class="section-py bg-white">
<div class="container">
<div class="text-center mb-5">
<h2 class="fw-bold">Everything you need, nothing you don't.</h2>
<p class="lead text-muted">Focus on what matters with our core features.</p>
</div>
<div class="row g-4">
<div class="col-md-4">
<div class="text-center p-4">
<i class="bi bi-bar-chart-line-fill fs-1 text-primary"></i>
<h4 class="mt-3">Automated Workflows</h4>
<p>Set up triggers and actions to automate repetitive tasks and save countless hours.</p>
</div>
</div>
<div class="col-md-4">
<div class="text-center p-4">
<i class="bi bi-kanban-fill fs-1 text-primary"></i>
<h4 class="mt-3">Project Management</h4>
<p>Visualize your progress with kanban boards, task lists, and team assignments.</p>
</div>
</div>
<div class="col-md-4">
<div class="text-center p-4">
<i class="bi bi-people-fill fs-1 text-primary"></i>
<h4 class="mt-3">Team Collaboration</h4>
<p>Communicate seamlessly with integrated chat, file sharing, and real-time updates.</p>
</div>
</div>
</div>
</div>
</section>
<!-- Testimonials Section -->
<section id="testimonials" class="section-py">
<div class="container">
<div class="text-center mb-5">
<h2 class="fw-bold">Loved by teams everywhere</h2>
</div>
<div class="row g-4">
<div class="col-lg-4">
<div class="card h-100 testimonial-card rounded-lg shadow-sm">
<div class="card-body text-center">
<img src="https://picsum.photos/seed/avatar1/96/96" class="rounded-circle mb-3" alt="A portrait of a satisfied Nimbus customer.">
<p class="fst-italic">"Nimbus transformed how we manage projects. We're more organized and efficient than ever before."</p>
<h6 class="fw-bold mt-4 mb-0">Alex Johnson</h6>
<small class="text-muted">CEO, Innovate Inc.</small>
</div>
</div>
</div>
<div class="col-lg-4">
<div class="card h-100 testimonial-card rounded-lg shadow-sm">
<div class="card-body text-center">
<img src="https://picsum.photos/seed/avatar2/96/96" class="rounded-circle mb-3" alt="A portrait of a satisfied Nimbus customer.">
<p class="fst-italic">"The automation features are a game-changer. We've saved at least 10 hours per week."</p>
<h6 class="fw-bold mt-4 mb-0">Samantha Bee</h6>
<small class="text-muted">Marketing Director, Creative Co.</small>
</div>
</div>
</div>
<div class="col-lg-4">
<div class="card h-100 testimonial-card rounded-lg shadow-sm">
<div class="card-body text-center">
<img src="https://picsum.photos/seed/avatar3/96/96" class="rounded-circle mb-3" alt="A portrait of a satisfied Nimbus customer.">
<p class="fst-italic">"The user interface is so intuitive. My team was able to get started with minimal training."</p>
<h6 class="fw-bold mt-4 mb-0">David Chen</h6>
<small class="text-muted">Head of Operations, Logistics Pro</small>
</div>
</div>
</div>
</div>
</div>
</section>
<!-- Pricing Section -->
<section id="pricing" class="section-py bg-white">
<div class="container">
<div class="text-center mb-5">
<h2 class="fw-bold">Find the right plan for you</h2>
<div class="form-check form-switch d-inline-block mt-3 fs-5">
<label class="form-check-label" for="pricingToggle">Monthly</label>
<input class="form-check-input" type="checkbox" id="pricingToggle">
<label class="form-check-label" for="pricingToggle">Yearly (Save 20%)</label>
</div>
</div>
<div class="row g-4 justify-content-center">
<!-- Basic Plan -->
<div class="col-lg-4">
<div class="card h-100 text-center rounded-lg shadow-sm">
<div class="card-body p-5">
<h5 class="card-title">Basic</h5>
<div class="price-monthly">
<span class="display-4 fw-bold">$29</span>
<span class="text-muted">/ month</span>
</div>
<div class="price-yearly" style="display: none;">
<span class="display-4 fw-bold">$278</span>
<span class="text-muted">/ year</span>
</div>
<ul class="list-unstyled my-4">
<li>Up to 5 users</li>
<li>Core Features</li>
<li>10GB Storage</li>
<li>Community Support</li>
</ul>
<a href="#contact" class="btn btn-outline-primary w-100 smooth-scroll">Choose Plan</a>
</div>
</div>
</div>
<!-- Pro Plan -->
<div class="col-lg-4">
<div class="card h-100 text-center rounded-lg shadow border-primary">
<div class="card-header bg-primary text-white">Most Popular</div>
<div class="card-body p-5">
<h5 class="card-title">Pro</h5>
<div class="price-monthly">
<span class="display-4 fw-bold">$79</span>
<span class="text-muted">/ month</span>
</div>
<div class="price-yearly" style="display: none;">
<span class="display-4 fw-bold">$758</span>
<span class="text-muted">/ year</span>
</div>
<ul class="list-unstyled my-4">
<li>Up to 25 users</li>
<li>Advanced Features</li>
<li>100GB Storage</li>
<li>Priority Support</li>
</ul>
<a href="#contact" class="btn btn-primary w-100 smooth-scroll">Choose Plan</a>
</div>
</div>
</div>
<!-- Enterprise Plan -->
<div class="col-lg-4">
<div class="card h-100 text-center rounded-lg shadow-sm">
<div class="card-body p-5">
<h5 class="card-title">Enterprise</h5>
<div class="price-monthly">
<span class="display-4 fw-bold">Custom</span>
</div>
<div class="price-yearly" style="display: none;">
<span class="display-4 fw-bold">Custom</span>
</div>
<ul class="list-unstyled my-4">
<li>Unlimited users</li>
<li>Dedicated Infrastructure</li>
<li>Unlimited Storage</li>
<li>24/7 Dedicated Support</li>
</ul>
<a href="#contact" class="btn btn-outline-primary w-100 smooth-scroll">Contact Us</a>
</div>
</div>
</div>
</div>
</div>
</section>
<!-- FAQ Section -->
<section id="faq" class="section-py">
<div class="container">
<div class="text-center mb-5">
<h2 class="fw-bold">Frequently Asked Questions</h2>
</div>
<div class="row justify-content-center">
<div class="col-lg-8">
<div class="accordion" id="faqAccordion">
<div class="accordion-item">
<h2 class="accordion-header" id="headingOne">
<button class="accordion-button" type="button" data-bs-toggle="collapse" data-bs-target="#collapseOne">
Is there a free trial available?
</button>
</h2>
<div id="collapseOne" class="accordion-collapse collapse show" data-bs-parent="#faqAccordion">
<div class="accordion-body">
Yes, we offer a 14-day free trial on our Pro plan. No credit card required.
</div>
</div>
</div>
<div class="accordion-item">
<h2 class="accordion-header" id="headingTwo">
<button class="accordion-button collapsed" type="button" data-bs-toggle="collapse" data-bs-target="#collapseTwo">
Can I change my plan later?
</button>
</h2>
<div id="collapseTwo" class="accordion-collapse collapse" data-bs-parent="#faqAccordion">
<div class="accordion-body">
Absolutely. You can upgrade, downgrade, or cancel your plan at any time from your account settings.
</div>
</div>
</div>
<div class="accordion-item">
<h2 class="accordion-header" id="headingThree">
<button class="accordion-button collapsed" type="button" data-bs-toggle="collapse" data-bs-target="#collapseThree">
What payment methods do you accept?
</button>
</h2>
<div id="collapseThree" class="accordion-collapse collapse" data-bs-parent="#faqAccordion">
<div class="accordion-body">
We accept all major credit cards, including Visa, Mastercard, and American Express. For Enterprise plans, we also support invoicing.
</div>
</div>
</div>
<div class="accordion-item">
<h2 class="accordion-header" id="headingFour">
<button class="accordion-button collapsed" type="button" data-bs-toggle="collapse" data-bs-target="#collapseFour">
Is my data secure?
</button>
</h2>
<div id="collapseFour" class="accordion-collapse collapse" data-bs-parent="#faqAccordion">
<div class="accordion-body">
Data security is our top priority. We use industry-standard encryption and security practices to keep your data safe.
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</section>
<!-- Contact Form Section -->
<section id="contact" class="section-py bg-white">
<div class="container">
<div class="row justify-content-center">
<div class="col-lg-6 text-center">
<h2 class="fw-bold">Ready to Grow?</h2>
<p class="lead text-muted mb-5">Fill out the form below and a member of our team will get back to you shortly.</p>
<div class="alert alert-info">This is for testing purposes only Flatlogic does not guarantee usage of the mail server. Please set up your own SMTP in <code>.env</code> (MAIL_/SMTP_ vars).</div>
<?php if ($form_message): ?>
<div class="alert alert-success"><?php echo $form_message; ?></div>
<?php endif; ?>
<?php if ($form_error): ?>
<div class="alert alert-danger"><?php echo $form_error; ?></div>
<?php endif; ?>
<form id="leadForm" method="POST" action="index.php#contact" novalidate>
<div class="mb-3">
<input type="text" class="form-control form-control-lg" id="name" name="name" placeholder="Your Name" required>
<div class="invalid-feedback">Please enter your name.</div>
</div>
<div class="mb-3">
<input type="email" class="form-control form-control-lg" id="email" name="email" placeholder="Work Email" required>
<div class="invalid-feedback">Please enter a valid email address.</div>
</div>
<div class="mb-3">
<textarea class="form-control form-control-lg" id="message" name="message" rows="4" placeholder="Your Message" required></textarea>
<div class="invalid-feedback">Please enter a message.</div>
</div>
<button type="submit" class="btn btn-primary btn-lg w-100">Submit Request</button>
</form>
</div>
</div>
</div>
</section>
</main>
<!-- Footer -->
<footer class="footer py-4">
<div class="container">
<div class="d-flex justify-content-between align-items-center">
<span class="text-muted">&copy; <?php echo date("Y"); ?> Nimbus, Inc.</span>
<div>
<a href="#" class="text-muted me-3">Privacy Policy</a>
<a href="#" class="text-muted">Terms of Service</a>
</div>
</div>
</div>
</footer>
<!-- Bootstrap JS -->
<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.3.2/dist/js/bootstrap.bundle.min.js"></script>
<!-- Custom JS -->
<script src="assets/js/main.js?v=<?php echo time(); ?>"></script>
</body>
</html>
</html>