-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.html
More file actions
238 lines (216 loc) · 10.8 KB
/
index.html
File metadata and controls
238 lines (216 loc) · 10.8 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1" />
<title>My Simple Website</title>
<meta name="description" content="Shalini Sudarsan" />
<!-- Favicon (optional) -->
<link rel="icon" href="data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 100'><text y='0.9em' font-size='90'>✨</text></svg>">
<style>
:root {
--bg: #0f172a; /* slate-900 */
--surface: #111827; /* gray-900 */
--muted: #94a3b8; /* slate-400 */
--text: #e5e7eb; /* gray-200 */
--brand: #38bdf8; /* sky-400 */
--brand-strong: #0ea5e9;/* sky-500 */
--ring: rgba(56,189,248,.45);
--card: #0b1220; /* deep card */
}
/* CSS Reset (modern, minimal) */
*,*::before,*::after{box-sizing:border-box}
*{margin:0}
html:focus-within{scroll-behavior:smooth}
body{min-height:100vh;text-rendering:optimizeLegibility;line-height:1.6;background:radial-gradient(1200px 800px at 10% -10%, rgba(56,189,248,.08), transparent 40%),
radial-gradient(1000px 600px at 100% 0%, rgba(14,165,233,.06), transparent 40%), var(--bg);color:var(--text);font-family: ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Ubuntu, Cantarell, Noto Sans, Arial, 'Apple Color Emoji','Segoe UI Emoji';}
img,picture,svg,video,canvas{display:block;max-width:100%}
input,button,textarea,select{font:inherit;color:inherit}
a{color:inherit;text-decoration:none}
::selection{background:var(--brand);color:#001018}
/* Layout */
.container{width:min(1100px, 92%);margin-inline:auto}
header{
position:sticky;top:0;z-index:40;background:linear-gradient(180deg, rgba(15,23,42,.85), rgba(15,23,42,.65) 60%, transparent);backdrop-filter: saturate(120%) blur(8px);
border-bottom:1px solid rgba(148,163,184,.12)
}
nav{display:flex;align-items:center;justify-content:space-between;gap:1rem;padding:0.85rem 0}
.logo{display:flex;align-items:center;gap:.6rem;font-weight:700;letter-spacing:.2px}
.logo-badge{display:grid;place-items:center;width:34px;height:34px;border-radius:10px;background:linear-gradient(135deg, var(--brand), var(--brand-strong)); box-shadow:0 6px 30px rgba(56,189,248,.3)}
.logo-badge span{filter:drop-shadow(0 2px 4px rgba(0,0,0,.35))}
.nav-links{display:flex;gap:1rem;align-items:center}
.nav-links a{padding:.5rem .75rem;border-radius:10px;opacity:.9}
.nav-links a:hover{background:rgba(148,163,184,.12);opacity:1}
.cta{display:inline-flex;align-items:center;gap:.5rem;background:linear-gradient(135deg, var(--brand), var(--brand-strong));color:#001018;border:none;border-radius:12px;padding:.65rem .95rem;font-weight:600;box-shadow:0 10px 30px rgba(56,189,248,.25);cursor:pointer}
.cta:hover{transform:translateY(-1px)}
/* Mobile menu */
.menu-btn{display:none;border:1px solid rgba(148,163,184,.25);background:transparent;border-radius:10px;padding:.5rem .65rem}
@media (max-width: 820px){
.nav-links{display:none}
.menu-btn{display:inline-flex}
}
/* Hero */
.hero{padding:7rem 0 4rem; position:relative;overflow:hidden}
.hero h1{font-size:clamp(2rem, 3vw + 1rem, 3.4rem);line-height:1.15;letter-spacing:.3px}
.hero p{max-width:60ch;margin-top:1rem;color:var(--muted)}
.hero-actions{display:flex;gap:.9rem;flex-wrap:wrap;margin-top:1.25rem}
/* Cards / Sections */
section{padding:4rem 0;border-top:1px solid rgba(148,163,184,.12)}
.grid{display:grid;gap:1rem;grid-template-columns:repeat(12, 1fr)}
.card{grid-column:span 4; background:linear-gradient(180deg, rgba(255,255,255,.03), rgba(255,255,255,.015));border:1px solid rgba(148,163,184,.12);border-radius:18px;padding:1rem}
.card h3{margin-bottom:.25rem}
.card p{color:var(--muted)}
@media (max-width: 900px){ .card{grid-column:span 6} }
@media (max-width: 640px){ .card{grid-column:span 12} }
/* Showcase */
.showcase{display:grid;gap:1rem;grid-template-columns:1.2fr 1fr;align-items:center}
.showcase .preview{background:linear-gradient(180deg, rgba(56,189,248,.08), rgba(14,165,233,.03));border:1px solid rgba(56,189,248,.25);border-radius:18px;padding:1rem}
@media (max-width: 900px){ .showcase{grid-template-columns:1fr;}}
/* Contact */
form{display:grid;gap:.75rem;max-width:560px}
label{font-weight:600}
input, textarea{background:var(--card);border:1px solid rgba(148,163,184,.18);border-radius:12px;padding:.7rem .8rem}
input:focus, textarea:focus{outline:2px solid var(--ring); border-color: transparent}
textarea{min-height:120px}
.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}
footer{padding:3rem 0;color:var(--muted);border-top:1px solid rgba(148,163,184,.12)}
</style>
</head>
<body>
<header>
<div class="container">
<nav aria-label="Primary">
<a href="#top" class="logo">
<span class="logo-badge"><span aria-hidden>★</span></span>
<span>MySite</span>
</a>
<div class="nav-links" role="menubar">
<a role="menuitem" href="#features">Features</a>
<a role="menuitem" href="#showcase">Showcase</a>
<a role="menuitem" href="#contact">Contact</a>
<a role="menuitem" class="cta" href="#contact">Get Started</a>
</div>
<button class="menu-btn" aria-expanded="false" aria-controls="mobileMenu" id="menuBtn">Menu</button>
</nav>
<div id="mobileMenu" hidden>
<div class="container" style="padding: .5rem 0 1rem;">
<a href="#features" style="display:block;padding:.6rem 0">Features</a>
<a href="#showcase" style="display:block;padding:.6rem 0">Showcase</a>
<a href="#contact" style="display:block;padding:.6rem 0">Contact</a>
</div>
</div>
</div>
</header>
<main id="top">
<!-- HERO -->
<section class="hero">
<div class="container">
<h1>Build something simple—and ship it today.</h1>
<p>
This is a minimal, modern one‑page website template. Drop in your own text and images, and you’re live. No frameworks required.
</p>
<div class="hero-actions">
<a class="cta" href="#features">See Features</a>
<a class="cta" href="#contact" style="background:transparent;border:1px solid rgba(148,163,184,.35);color:var(--text);box-shadow:none">Contact Us</a>
</div>
</div>
</section>
<!-- FEATURES -->
<section id="features">
<div class="container">
<h2 style="font-size:1.6rem;margin-bottom:1rem">Features</h2>
<div class="grid">
<article class="card">
<h3>Fast</h3>
<p>Lightweight HTML, CSS, and a sprinkle of JavaScript. Loads fast, even on slow networks.</p>
</article>
<article class="card">
<h3>Responsive</h3>
<p>Looks great on phones, tablets, and desktops without extra work.</p>
</article>
<article class="card">
<h3>Accessible</h3>
<p>Semantic markup, focus styles, and high contrast colors out of the box.</p>
</article>
</div>
</div>
</section>
<!-- SHOWCASE -->
<section id="showcase">
<div class="container">
<div class="showcase">
<div class="preview" aria-label="Screenshot placeholder" role="img">
<svg viewBox="0 0 800 500" width="100%" height="100%" xmlns="http://www.w3.org/2000/svg">
<defs>
<linearGradient id="g" x1="0" y1="0" x2="1" y2="1">
<stop offset="0%" stop-color="rgba(56,189,248,.25)"/>
<stop offset="100%" stop-color="rgba(14,165,233,.1)"/>
</linearGradient>
</defs>
<rect width="100%" height="100%" fill="url(#g)"/>
<g fill="rgba(255,255,255,.7)">
<rect x="60" y="60" width="680" height="40" rx="8"/>
<rect x="60" y="120" width="520" height="20" rx="6"/>
<rect x="60" y="160" width="520" height="20" rx="6"/>
<rect x="60" y="200" width="320" height="20" rx="6"/>
<rect x="60" y="260" width="680" height="180" rx="14"/>
</g>
</svg>
</div>
<div>
<h2 style="font-size:1.6rem;margin-bottom:.5rem">Show your work</h2>
<p style="color:var(--muted)">Swap the SVG with your screenshot or image. You can also embed a YouTube video or an iframe here.</p>
<ul style="margin-top:1rem; color:var(--muted)">
<li>Drag in an <code><img></code> or paste a URL.</li>
<li>Update text to match your product or portfolio.</li>
<li>Remove sections you don’t need.</li>
</ul>
</div>
</div>
</div>
</section>
<!-- CONTACT -->
<section id="contact">
<div class="container">
<h2 style="font-size:1.6rem;margin-bottom:1rem">Contact</h2>
<form name="contact" aria-labelledby="contact-heading" onsubmit="onSubmit(event)">
<h3 id="contact-heading" class="sr-only">Send us a message</h3>
<label for="name">Name</label>
<input id="name" name="name" placeholder="Jane Doe" required />
<label for="email">Email</label>
<input id="email" name="email" type="email" placeholder="jane@example.com" required />
<label for="message">Message</label>
<textarea id="message" name="message" placeholder="Tell us a bit about your project…" required></textarea>
<button class="cta" type="submit">Send</button>
<p id="formStatus" role="status" aria-live="polite" style="color:var(--muted)"></p>
</form>
</div>
</section>
</main>
<footer>
<div class="container">
<p>© <span id="year"></span> MySite. Built with ❤️ and vanilla HTML/CSS/JS.</p>
</div>
</footer>
<script>
// Mobile menu toggle
const btn = document.getElementById('menuBtn');
const menu = document.getElementById('mobileMenu');
btn?.addEventListener('click', () => {
const isOpen = btn.getAttribute('aria-expanded') === 'true';
btn.setAttribute('aria-expanded', String(!isOpen));
menu.hidden = isOpen;
});
// Set current year in footer
document.getElementById('year').textContent = new Date().getFullYear();
// Basic form handler (demo only)
function onSubmit(e){
e.preventDefault();
const data = Object.fromEntries(new FormData(e.target).entries());
// In a real site, POST `data` to your backend or a service like Formspree/Netlify
document.getElementById('formStatus').textContent = `Thanks, ${data.name}! We'll get back to you at ${data.email}.`;
e.target.reset();
}
</script>
</body>
</html>