Website: fix screenshot aspect ratio, embed the live demo, GitHub button in hero
The screenshot img tags carry width/height attributes; with only a CSS width the height attribute won (240x2532 — stretched). height:auto fixes it. New #demo section runs the GitHub-Pages demo in a phone frame right on the page; nav gets a Demo link and the hero a GitHub star button.
This commit is contained in:
1 parent
becd2357ff
commit
ae399cd1dd
4 files changed
+29
-3
No files matched your search
+12
-2
@@ -75,11 +75,21 @@ h2 { font-size: clamp(26px, 4.5vw, 34px); letter-spacing: -.02em; margin: 6px 0
|
||||
.shots { display: flex; gap: 16px; overflow-x: auto; padding: 8px 2px 18px; scroll-snap-type: x mandatory; }
|
||||
.shots figure { flex: 0 0 auto; scroll-snap-align: center; text-align: center; }
|
||||
.shots img {
|
||||
width: min(240px, 62vw); border-radius: 22px; border: 1px solid var(--line);
|
||||
display: block; background: var(--card);
|
||||
width: min(240px, 62vw); height: auto; border-radius: 22px;
|
||||
border: 1px solid var(--line); display: block; background: var(--card);
|
||||
}
|
||||
.shots figcaption { color: var(--faint); font-size: 13px; margin-top: 8px; }
|
||||
|
||||
/* ---------- embedded live demo ---------- */
|
||||
.demo-wrap { display: flex; justify-content: center; padding: 10px 0 6px; }
|
||||
.phone {
|
||||
width: 384px; max-width: 92vw; height: min(720px, 78vh); border-radius: 42px;
|
||||
border: 10px solid #1c1f26; overflow: hidden; background: #000;
|
||||
box-shadow: 0 34px 90px rgba(0, 0, 0, .55);
|
||||
}
|
||||
.phone iframe { width: 100%; height: 100%; border: 0; display: block; }
|
||||
.demo-note { text-align: center; color: var(--faint); font-size: 13.5px; margin-top: 14px; }
|
||||
|
||||
/* ---------- flavors ---------- */
|
||||
.duo { display: grid; grid-template-columns: repeat(auto-fit, minmax(290px, 1fr)); gap: 16px; }
|
||||
.card {
|
||||
|
||||
Reference in new issue
Block a user