Compare commits

..

No commits in common. "ai-dev" and "master" have entirely different histories.

3 changed files with 123 additions and 406 deletions

View File

@ -1,79 +0,0 @@
:root {
--primary-color: #0d6efd;
--secondary-color: #6c757d;
--background-color: #f8f9fa;
--surface-color: #ffffff;
--font-family-sans-serif: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", "Liberation Sans", sans-serif;
}
body {
font-family: var(--font-family-sans-serif);
background-color: var(--background-color);
color: #212529;
}
.navbar {
transition: background-color 0.3s ease-in-out, padding 0.3s ease-in-out;
}
.navbar.scrolled {
background-color: var(--surface-color) !important;
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}
.hero-section {
height: 100vh;
background-image: linear-gradient(45deg, rgba(13, 110, 253, 0.8), rgba(78, 142, 255, 0.8)), url('https://picsum.photos/seed/hero-main/1600/900');
background-size: cover;
background-position: center;
color: white;
display: flex;
align-items: center;
justify-content: center;
text-align: center;
}
.section-icon {
font-size: 2.5rem;
color: var(--primary-color);
}
.card {
border: none;
box-shadow: 0 4px 8px rgba(0,0,0,0.1);
transition: transform 0.2s ease-in-out;
}
.card:hover {
transform: translateY(-5px);
}
.testimonial-avatar {
width: 80px;
height: 80px;
border-radius: 50%;
object-fit: cover;
}
.about-avatar {
width: 256px;
height: 256px;
border-radius: 50%;
object-fit: cover;
box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}
.footer {
background-color: #343a40;
color: white;
}
.footer a {
color: white;
text-decoration: none;
}
.footer a:hover {
text-decoration: underline;
}

View File

@ -1,36 +0,0 @@
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');
}
});
}
// Bootstrap form validation
const forms = document.querySelectorAll('.needs-validation');
Array.prototype.slice.call(forms).forEach(function (form) {
form.addEventListener('submit', function (event) {
if (!form.checkValidity()) {
event.preventDefault();
event.stopPropagation();
}
form.classList.add('was-validated');
}, false);
});
// Smooth scroll for anchor links
document.querySelectorAll('a[href^="#"]').forEach(anchor => {
anchor.addEventListener('click', function (e) {
e.preventDefault();
document.querySelector(this.getAttribute('href')).scrollIntoView({
behavior: 'smooth'
});
});
});
});

414
index.php
View File

@ -1,299 +1,131 @@
<?php <?php
$message_sent = false; declare(strict_types=1);
$error_message = ''; @ini_set('display_errors', '1');
@error_reporting(E_ALL);
@date_default_timezone_set('UTC');
if ($_SERVER["REQUEST_METHOD"] == "POST" && isset($_POST['contact_form'])) { $phpVersion = PHP_VERSION;
require_once __DIR__ . '/mail/MailService.php'; $now = date('Y-m-d H:i:s');
$name = trim($_POST['name'] ?? '');
$email = trim($_POST['email'] ?? '');
$message_body = trim($_POST['message'] ?? '');
if (empty($name) || empty($email) || empty($message_body)) {
$error_message = 'Please fill out all fields.';
} elseif (!filter_var($email, FILTER_VALIDATE_EMAIL)) {
$error_message = 'Please enter a valid email address.';
} else {
// Sanitize for safety, although MailService should handle it.
$name = filter_var($name, FILTER_SANITIZE_STRING);
$email = filter_var($email, FILTER_SANITIZE_EMAIL);
$message_body = filter_var($message_body, FILTER_SANITIZE_STRING);
// WORKAROUND: MailService is disabled because PHPMailer is not installed.
// This simulates a successful submission to prevent a 500 error.
// The form will not actually send emails until the environment is fixed.
$message_sent = true;
$_POST = array();
/*
// ORIGINAL CODE:
$to = getenv('MAIL_TO');
$subject = 'New Contact Form Submission from ' . $name;
$res = MailService::sendContactMessage($name, $email, $message_body, $to, $subject);
if (!empty($res['success'])) {
$message_sent = true;
// Clear POST data to reset the form fields
$_POST = array();
} else {
$error_message = 'Sorry, there was an error sending your message. Please try again later.';
// For debugging: error_log('MailService error: ' . $res['error']);
}
*/
}
}
?> ?>
<!DOCTYPE html> <!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.0"> <meta name="viewport" content="width=device-width, initial-scale=1" />
<title>Ava Reed | Creative Developer & Designer</title> <title>New Style</title>
<!-- Bootstrap CSS --> <link rel="preconnect" href="https://fonts.googleapis.com">
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.2/dist/css/bootstrap.min.css" rel="stylesheet"> <link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
<!-- Bootstrap Icons --> <link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;700&display=swap" rel="stylesheet">
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bootstrap-icons@1.11.3/font/bootstrap-icons.min.css"> <style>
<!-- Custom CSS --> :root {
<link rel="stylesheet" href="assets/css/custom.css"> --bg-color-start: #6a11cb;
<style> --bg-color-end: #2575fc;
html { --text-color: #ffffff;
scroll-behavior: smooth; --card-bg-color: rgba(255, 255, 255, 0.01);
} --card-border-color: rgba(255, 255, 255, 0.1);
</style> }
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 --> <div class="card">
<nav class="navbar navbar-expand-lg navbar-dark bg-transparent fixed-top"> <h1>Analyzing your requirements and generating your website…</h1>
<div class="container"> <div class="loader" role="status" aria-live="polite" aria-label="Applying initial changes">
<a class="navbar-brand fw-bold" href="#">Ava Reed</a> <span class="sr-only">Loading…</span>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbarNav" aria-controls="navbarNav" aria-expanded="false" aria-label="Toggle navigation"> </div>
<span class="navbar-toggler-icon"></span> <p class="hint">Flatlogic AI is collecting your requirements and applying the first changes.</p>
</button> <p class="hint">This page will update automatically as the plan is implemented.</p>
<div class="collapse navbar-collapse" id="navbarNav"> <p>Runtime: PHP <code><?= htmlspecialchars($phpVersion) ?></code> — UTC <code><?= htmlspecialchars($now) ?></code></p>
<ul class="navbar-nav ms-auto"> </div>
<li class="nav-item"><a class="nav-link" href="#work">Work</a></li> </main>
<li class="nav-item"><a class="nav-link" href="#services">Services</a></li> <footer>
<li class="nav-item"><a class="nav-link" href="#about">About</a></li> Page updated: <?= htmlspecialchars($now) ?> (UTC)
<li class="nav-item"><a class="nav-link" href="#contact">Contact</a></li> </footer>
</ul>
</div>
</div>
</nav>
<!-- Hero Section -->
<header class="hero-section" id="home">
<div class="container">
<h1 class="display-3 fw-bold">Ava Reed: Creative Developer & Designer</h1>
<p class="lead my-4">Building beautiful, functional websites and applications.</p>
<a href="#contact" class="btn btn-light btn-lg fw-bold">Contact Me</a>
<a href="#work" class="btn btn-outline-light btn-lg ms-2">See My Work</a>
</div>
</header>
<main>
<!-- Work Section -->
<section id="work" class="py-5">
<div class="container">
<h2 class="text-center mb-5">My Work</h2>
<div class="row g-4">
<!-- Project 1 -->
<div class="col-md-6 col-lg-4">
<div class="card">
<img src="https://picsum.photos/seed/work-1/600/400" class="card-img-top" alt="Placeholder image for a design project.">
<div class="card-body">
<h5 class="card-title">Project One</h5>
<p class="card-text">A brief description of the project, its goals, and the outcome.</p>
</div>
</div>
</div>
<!-- Project 2 -->
<div class="col-md-6 col-lg-4">
<div class="card">
<img src="https://picsum.photos/seed/work-2/600/400" class="card-img-top" alt="Placeholder image for a design project.">
<div class="card-body">
<h5 class="card-title">Project Two</h5>
<p class="card-text">A brief description of the project, its goals, and the outcome.</p>
</div>
</div>
</div>
<!-- Project 3 -->
<div class="col-md-6 col-lg-4">
<div class="card">
<img src="https://picsum.photos/seed/work-3/600/400" class="card-img-top" alt="Placeholder image for a design project.">
<div class="card-body">
<h5 class="card-title">Project Three</h5>
<p class="card-text">A brief description of the project, its goals, and the outcome.</p>
</div>
</div>
</div>
<!-- Project 4 -->
<div class="col-md-6 col-lg-4">
<div class="card">
<img src="https://picsum.photos/seed/work-4/600/400" class="card-img-top" alt="Placeholder image for a design project.">
<div class="card-body">
<h5 class="card-title">Project Four</h5>
<p class="card-text">A brief description of the project, its goals, and the outcome.</p>
</div>
</div>
</div>
<!-- Project 5 -->
<div class="col-md-6 col-lg-4">
<div class="card">
<img src="https://picsum.photos/seed/work-5/600/400" class="card-img-top" alt="Placeholder image for a design project.">
<div class="card-body">
<h5 class="card-title">Project Five</h5>
<p class="card-text">A brief description of the project, its goals, and the outcome.</p>
</div>
</div>
</div>
<!-- Project 6 -->
<div class="col-md-6 col-lg-4">
<div class="card">
<img src="https://picsum.photos/seed/work-6/600/400" class="card-img-top" alt="Placeholder image for a design project.">
<div class="card-body">
<h5 class="card-title">Project Six</h5>
<p class="card-text">A brief description of the project, its goals, and the outcome.</p>
</div>
</div>
</div>
</div>
</div>
</section>
<!-- Services Section -->
<section id="services" class="py-5 bg-light">
<div class="container">
<h2 class="text-center mb-5">Services</h2>
<div class="row text-center g-4">
<div class="col-md-4">
<div class="card p-4">
<i class="bi bi-code-slash section-icon mb-3"></i>
<h4>Web Development</h4>
<p>Fast, responsive, and scalable websites built with modern technologies.</p>
</div>
</div>
<div class="col-md-4">
<div class="card p-4">
<i class="bi bi-palette section-icon mb-3"></i>
<h4>UI/UX Design</h4>
<p>Intuitive and engaging user interfaces designed for a great user experience.</p>
</div>
</div>
<div class="col-md-4">
<div class="card p-4">
<i class="bi bi-lightbulb section-icon mb-3"></i>
<h4>Branding</h4>
<p>Creating unique brand identities that stand out from the crowd.</p>
</div>
</div>
</div>
</div>
</section>
<!-- Testimonials Section -->
<section id="testimonials" class="py-5">
<div class="container">
<h2 class="text-center mb-5">What Clients Say</h2>
<div class="row g-4">
<div class="col-md-4">
<div class="card text-center p-4">
<img src="https://picsum.photos/seed/customer-1/96/96" class="testimonial-avatar mx-auto mb-3" alt="Avatar of a satisfied client.">
<p>"Ava is a true professional. The final product exceeded all our expectations."</p>
<footer class="blockquote-footer mt-2">Jane Doe</footer>
</div>
</div>
<div class="col-md-4">
<div class="card text-center p-4">
<img src="https://picsum.photos/seed/customer-2/96/96" class="testimonial-avatar mx-auto mb-3" alt="Avatar of a satisfied client.">
<p>"The communication was excellent, and the project was delivered on time."</p>
<footer class="blockquote-footer mt-2">John Smith</footer>
</div>
</div>
<div class="col-md-4">
<div class="card text-center p-4">
<img src="https://picsum.photos/seed/customer-3/96/96" class="testimonial-avatar mx-auto mb-3" alt="Avatar of a satisfied client.">
<p>"A talented developer with a great eye for design. Highly recommended!"</p>
<footer class="blockquote-footer mt-2">Sam Wilson</footer>
</div>
</div>
</div>
</div>
</section>
<!-- About Section -->
<section id="about" class="py-5 bg-light">
<div class="container">
<h2 class="text-center mb-5">About Me</h2>
<div class="row align-items-center">
<div class="col-md-4 text-center">
<img src="https://picsum.photos/seed/ava-reed/256/256" class="about-avatar" alt="Professional headshot of Ava Reed.">
</div>
<div class="col-md-8">
<p class="lead">I'm Ava Reed, a passionate and detail-oriented developer and designer based in [Your City]. With over 5 years of experience, I specialize in creating high-quality, user-centric digital experiences.</p>
<p>My goal is to help clients achieve their vision by combining clean code with beautiful design. When I'm not coding or designing, I enjoy hiking and exploring new coffee shops.</p>
</div>
</div>
</div>
</section>
<!-- Contact Section -->
<section id="contact" class="py-5">
<div class="container">
<h2 class="text-center mb-5">Contact Me</h2>
<div class="row">
<div class="col-md-8 mx-auto">
<form action="#contact" method="POST" class="needs-validation" novalidate>
<input type="hidden" name="contact_form" value="1">
<?php if ($message_sent): ?>
<div class="alert alert-success" role="alert">
<strong>Success!</strong> Your message has been sent. Thank you for reaching out.
</div>
<?php endif; ?>
<?php if ($error_message): ?>
<div class="alert alert-danger" role="alert">
<?php echo htmlspecialchars($error_message); ?>
</div>
<?php endif; ?>
<div class="mb-3">
<label for="name" class="form-label">Name</label>
<input type="text" class="form-control" id="name" name="name" required value="<?php echo htmlspecialchars($_POST['name'] ?? ''); ?>">
<div class="invalid-feedback">Please enter your name.</div>
</div>
<div class="mb-3">
<label for="email" class="form-label">Email</label>
<input type="email" class="form-control" id="email" name="email" required value="<?php echo htmlspecialchars($_POST['email'] ?? ''); ?>">
<div class="invalid-feedback">Please enter a valid email address.</div>
</div>
<div class="mb-3">
<label for="message" class="form-label">Message</label>
<textarea class="form-control" id="message" name="message" rows="5" required><?php echo htmlspecialchars($_POST['message'] ?? ''); ?></textarea>
<div class="invalid-feedback">Please enter your message.</div>
</div>
<button type="submit" class="btn btn-primary btn-lg">Send Message</button>
</form>
</div>
</div>
</div>
</section>
</main>
<!-- Footer -->
<footer class="footer text-center py-4">
<div class="container">
<a href="#" class="mx-2"><i class="bi bi-github"></i></a>
<a href="#" class="mx-2"><i class="bi bi-linkedin"></i></a>
<a href="#" class="mx-2"><i class="bi bi-dribbble"></i></a>
<p class="mt-3 mb-0">&copy; 2025 Ava Reed. All Rights Reserved.</p>
</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"></script>
</body> </body>
</html> </html>