Improvement: Enhanced blog layout
This commit is contained in:
1 parent
d98780d007
commit
3dbcb6b309
4 files changed
+228
-67
No files matched your search
@@ -0,0 +1,35 @@
|
|||||||
|
<!DOCTYPE html>
|
||||||
|
<html lang="en">
|
||||||
|
<head>
|
||||||
|
<meta charset="UTF-8">
|
||||||
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||||
|
<title>Hermes Website</title>
|
||||||
|
<link rel="stylesheet" href="style.css">
|
||||||
|
</head>
|
||||||
|
<body>
|
||||||
|
<header>
|
||||||
|
<h1>Welcome to Hermes</h1>
|
||||||
|
<nav>
|
||||||
|
<ul>
|
||||||
|
<li><a href="#home">Home</a></li>
|
||||||
|
<li><a href="#about">About</a></li>
|
||||||
|
<li><a href="#contact">Contact</a></li>
|
||||||
|
</ul>
|
||||||
|
</nav>
|
||||||
|
</header>
|
||||||
|
<main>
|
||||||
|
<section id="home">
|
||||||
|
<h2>Modern Web Presence</h2>
|
||||||
|
<p>This is a basic landing page structure created by Hermes Agent.</p>
|
||||||
|
</section>
|
||||||
|
<section id="about">
|
||||||
|
<h2>About Us</h2>
|
||||||
|
<p>We are building innovative solutions.</p>
|
||||||
|
</section>
|
||||||
|
<section id="contact">
|
||||||
|
<h2>Get in Touch</h2>
|
||||||
|
<p>Email us at contact@hermes.dev</p>
|
||||||
|
</section>
|
||||||
|
</main>
|
||||||
|
</body>
|
||||||
|
</html>
|
||||||
@@ -0,0 +1,54 @@
|
|||||||
|
body {
|
||||||
|
font-family: Arial, sans-serif;
|
||||||
|
margin: 0;
|
||||||
|
padding: 0;
|
||||||
|
background-color: #f4f4f9;
|
||||||
|
color: #333;
|
||||||
|
}
|
||||||
|
|
||||||
|
header {
|
||||||
|
background-color: #2c3e50;
|
||||||
|
color: white;
|
||||||
|
padding: 1em 0;
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
header h1 {
|
||||||
|
margin: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
nav ul {
|
||||||
|
list-style: none;
|
||||||
|
padding: 0;
|
||||||
|
margin: 0;
|
||||||
|
display: flex;
|
||||||
|
justify-content: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
nav ul li a {
|
||||||
|
color: white;
|
||||||
|
text-decoration: none;
|
||||||
|
padding: 0.5em 1em;
|
||||||
|
display: block;
|
||||||
|
}
|
||||||
|
|
||||||
|
nav ul li a:hover {
|
||||||
|
background-color: #34495e;
|
||||||
|
}
|
||||||
|
|
||||||
|
main {
|
||||||
|
padding: 20px;
|
||||||
|
max-width: 800px;
|
||||||
|
margin: 20px auto;
|
||||||
|
background-color: white;
|
||||||
|
box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
|
||||||
|
}
|
||||||
|
|
||||||
|
section {
|
||||||
|
padding: 15px 0;
|
||||||
|
border-bottom: 1px solid #eee;
|
||||||
|
}
|
||||||
|
|
||||||
|
section:last-child {
|
||||||
|
border-bottom: none;
|
||||||
|
}
|
||||||
+42
-33
@@ -3,55 +3,64 @@
|
|||||||
<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.0">
|
||||||
<title>My Placeholder Blog</title>
|
<title>Modern Blog - My Name</title>
|
||||||
<link rel="stylesheet" href="style.css">
|
<link rel="stylesheet" href="style.css">
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
<header>
|
<header class="header">
|
||||||
<h1>Welcome to My Blog</h1>
|
<div class="container">
|
||||||
<nav>
|
<h1>My Modern Blog</h1>
|
||||||
<ul>
|
<nav>
|
||||||
<li><a href="#home">Home</a></li>
|
<ul>
|
||||||
<li><a href="#about">About</a></li>
|
<li><a href="#home">Home</a></li>
|
||||||
<li><a href="#posts">Posts</a></li>
|
<li><a href="#about">About</a></li>
|
||||||
<li><a href="#contact">Contact</a></li>
|
<li><a href="#posts">Posts</a></li>
|
||||||
</ul>
|
<li><a href="#contact">Contact</a></li>
|
||||||
</nav>
|
</ul>
|
||||||
|
</nav>
|
||||||
|
</div>
|
||||||
</header>
|
</header>
|
||||||
|
|
||||||
<main>
|
<main class="container">
|
||||||
<section id="home">
|
<section id="home" class="hero-section">
|
||||||
<h2>Latest Posts</h2>
|
<h2>Latest Articles</h2>
|
||||||
<article class="post">
|
<div class="post-grid">
|
||||||
<h3>First Post Title</h3>
|
<article class="post-card">
|
||||||
<p>This is placeholder content for the first blog post. We can add more detailed text here later.</p>
|
<h3>First Post Title</h3>
|
||||||
<small>Published on: October 26, 2026</small>
|
<p>Dive into the latest insights and discoveries. This is placeholder content for the most recent article.</p>
|
||||||
</article>
|
<small class="meta">Published on: October 26, 2026</small>
|
||||||
<article class="post">
|
</article>
|
||||||
<h3>Another Placeholder Article</h3>
|
<article class="post-card">
|
||||||
<p>Placeholder content for a second article. This section will hold more detailed information about the topics we plan to cover.</p>
|
<h3>Another Placeholder Article</h3>
|
||||||
<small>Published on: October 25, 2026</small>
|
<p>Explore deeper topics and gain new perspectives. This section holds more detailed information.</p>
|
||||||
</article>
|
<small class="meta">Published on: October 25, 2026</small>
|
||||||
|
</article>
|
||||||
|
</div>
|
||||||
</section>
|
</section>
|
||||||
|
|
||||||
<section id="about">
|
<section id="about" class="content-section">
|
||||||
<h2>About Me</h2>
|
<h2>About Me</h2>
|
||||||
<p>This is where I will write about myself, my interests, and what this blog is all about.</p>
|
<p>Welcome to my corner of the internet! I share thoughts on technology, life, and creative pursuits. Feel free to explore!</p>
|
||||||
</section>
|
</section>
|
||||||
|
|
||||||
<section id="posts">
|
<section id="posts" class="content-section">
|
||||||
<h2>All Posts</h2>
|
<h2>All Posts</h2>
|
||||||
<!-- More posts will be listed here -->
|
<div class="post-list">
|
||||||
|
<!-- More posts will be listed here -->
|
||||||
|
<p>No other posts found yet.</p>
|
||||||
|
</div>
|
||||||
</section>
|
</section>
|
||||||
|
|
||||||
<section id="contact">
|
<section id="contact" class="content-section">
|
||||||
<h2>Contact Me</h2>
|
<h2>Get In Touch</h2>
|
||||||
<p>You can reach me at your_email@example.com or connect on social media.</p>
|
<p>I'm always open to new ideas. Reach me at <a href="mailto:your_email@example.com">your_email@example.com</a> or connect on social media.</p>
|
||||||
</section>
|
</section>
|
||||||
</main>
|
</main>
|
||||||
|
|
||||||
<footer>
|
<footer class="footer">
|
||||||
<p>© 2026 My Placeholder Blog. All rights reserved.</p>
|
<div class="container">
|
||||||
|
<p>© 2026 My Modern Blog. All rights reserved.</p>
|
||||||
|
</div>
|
||||||
</footer>
|
</footer>
|
||||||
</body>
|
</body>
|
||||||
</html>
|
</html>
|
||||||
+97
-34
@@ -1,20 +1,42 @@
|
|||||||
body {
|
/* --- General Reset & Variables --- */
|
||||||
font-family: Arial, sans-serif;
|
* {
|
||||||
|
box-sizing: border-box;
|
||||||
margin: 0;
|
margin: 0;
|
||||||
padding: 0;
|
padding: 0;
|
||||||
background-color: #f4f4f9;
|
}
|
||||||
|
|
||||||
|
body {
|
||||||
|
font-family: 'Helvetica Neue', Arial, sans-serif;
|
||||||
|
line-height: 1.6;
|
||||||
|
background-color: #f9f9fb;
|
||||||
color: #333;
|
color: #333;
|
||||||
}
|
}
|
||||||
|
|
||||||
header {
|
.container {
|
||||||
background-color: #333;
|
width: 90%;
|
||||||
color: white;
|
max-width: 1200px;
|
||||||
padding: 1em 0;
|
margin: 0 auto;
|
||||||
text-align: center;
|
padding: 0 15px;
|
||||||
}
|
}
|
||||||
|
|
||||||
header h1 {
|
/* --- Header & Navigation --- */
|
||||||
|
.header {
|
||||||
|
background-color: #2c3e50; /* Darker, professional color */
|
||||||
|
color: white;
|
||||||
|
padding: 1rem 0;
|
||||||
|
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
|
||||||
|
}
|
||||||
|
|
||||||
|
.header .container {
|
||||||
|
display: flex;
|
||||||
|
justify-content: space-between;
|
||||||
|
align-items: center;
|
||||||
|
flex-wrap: wrap; /* For responsiveness */
|
||||||
|
}
|
||||||
|
|
||||||
|
.header h1 {
|
||||||
margin: 0;
|
margin: 0;
|
||||||
|
font-size: 1.8rem;
|
||||||
}
|
}
|
||||||
|
|
||||||
nav ul {
|
nav ul {
|
||||||
@@ -22,47 +44,88 @@ nav ul {
|
|||||||
padding: 0;
|
padding: 0;
|
||||||
margin: 0;
|
margin: 0;
|
||||||
display: flex;
|
display: flex;
|
||||||
justify-content: center;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
nav ul li a {
|
nav ul li a {
|
||||||
color: white;
|
color: white;
|
||||||
text-decoration: none;
|
text-decoration: none;
|
||||||
padding: 0 15px;
|
padding: 10px 15px;
|
||||||
|
transition: background-color 0.3s;
|
||||||
}
|
}
|
||||||
|
|
||||||
nav ul li a:hover {
|
nav ul li a:hover {
|
||||||
color: #4CAF50;
|
background-color: #34495e;
|
||||||
|
border-radius: 4px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* --- Main Content --- */
|
||||||
main {
|
main {
|
||||||
padding: 20px;
|
padding: 30px 0;
|
||||||
max-width: 900px;
|
min-height: 60vh;
|
||||||
margin: 20px auto;
|
|
||||||
background-color: white;
|
|
||||||
box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
h2 {
|
.content-section {
|
||||||
border-bottom: 2px solid #eee;
|
margin-bottom: 40px;
|
||||||
|
padding: 20px 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.content-section h2 {
|
||||||
|
color: #2c3e50;
|
||||||
|
border-bottom: 3px solid #3498db; /* Highlight color */
|
||||||
padding-bottom: 10px;
|
padding-bottom: 10px;
|
||||||
color: #333;
|
margin-bottom: 20px;
|
||||||
|
font-size: 2rem;
|
||||||
}
|
}
|
||||||
|
|
||||||
.post {
|
.hero-section {
|
||||||
margin-bottom: 30px;
|
|
||||||
padding-bottom: 15px;
|
|
||||||
border-bottom: 1px dashed #ccc;
|
|
||||||
}
|
|
||||||
|
|
||||||
.post h3 {
|
|
||||||
color: #333;
|
|
||||||
}
|
|
||||||
|
|
||||||
footer {
|
|
||||||
text-align: center;
|
text-align: center;
|
||||||
padding: 1em 0;
|
padding: 40px 0;
|
||||||
background-color: #333;
|
background-color: #ecf0f1;
|
||||||
|
border-radius: 8px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.post-grid {
|
||||||
|
display: grid;
|
||||||
|
grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
|
||||||
|
gap: 25px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.post-card {
|
||||||
|
background-color: white;
|
||||||
|
border: 1px solid #ddd;
|
||||||
|
border-radius: 8px;
|
||||||
|
padding: 20px;
|
||||||
|
box-shadow: 0 4px 8px rgba(0, 0, 0, 0.05);
|
||||||
|
transition: transform 0.3s ease;
|
||||||
|
}
|
||||||
|
|
||||||
|
.post-card:hover {
|
||||||
|
transform: translateY(-5px);
|
||||||
|
box-shadow: 0 6px 12px rgba(0, 0, 0, 0.1);
|
||||||
|
}
|
||||||
|
|
||||||
|
.post-card h3 {
|
||||||
|
color: #2980b9;
|
||||||
|
margin-top: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.meta {
|
||||||
|
display: block;
|
||||||
|
margin-top: 15px;
|
||||||
|
font-size: 0.9em;
|
||||||
|
color: #7f8c8d;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* --- Footer --- */
|
||||||
|
.footer {
|
||||||
|
background-color: #34495e;
|
||||||
color: white;
|
color: white;
|
||||||
margin-top: 20px;
|
text-align: center;
|
||||||
|
padding: 1.5rem 0;
|
||||||
|
margin-top: 30px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.footer .container {
|
||||||
|
display: flex;
|
||||||
|
justify-content: center;
|
||||||
}
|
}
|
||||||
Reference in new issue
Block a user