Skip to content

Commit 492bb91

Browse files
Improve immersive overlay positioning and styling - left-aligned, more natural layout
1 parent 87cfa5a commit 492bb91

File tree

3 files changed

+60
-43
lines changed

3 files changed

+60
-43
lines changed

assets/built/screen.css

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

assets/built/screen.css.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

assets/css/components/immersive.css

Lines changed: 58 additions & 41 deletions
Original file line numberDiff line numberDiff line change
@@ -402,75 +402,83 @@
402402
/* About overlay */
403403
.imm-about {
404404
position: absolute;
405-
top: max(24px, env(safe-area-inset-top));
406-
left: 50%;
407-
transform: translateX(-50%);
405+
top: max(32px, env(safe-area-inset-top));
406+
left: max(32px, env(safe-area-inset-left));
408407
z-index: 8; /* below navigation rail (10) so titles appear over overlay */
409-
width: min(520px, calc(100% - 48px));
408+
width: min(420px, calc(100% - 64px));
410409
pointer-events: auto;
411-
text-align: center;
410+
text-align: left;
412411
}
413412

414413
.imm-about__inner {
415414
display: grid;
416415
gap: 0.75rem;
417-
padding: 1rem 1.25rem;
418-
border-radius: 16px;
416+
padding: 1.25rem 1.5rem;
417+
border-radius: 20px;
419418
color: #fff;
420-
background: rgba(0,0,0,0.45);
421-
border: 1px solid rgba(255,255,255,0.2);
422-
box-shadow: 0 8px 32px rgba(0,0,0,0.4);
423-
-webkit-backdrop-filter: blur(12px) saturate(110%);
424-
backdrop-filter: blur(12px) saturate(110%);
419+
background: rgba(0,0,0,0.35);
420+
border: 1px solid rgba(255,255,255,0.15);
421+
box-shadow: 0 12px 40px rgba(0,0,0,0.3);
422+
-webkit-backdrop-filter: blur(16px) saturate(120%);
423+
backdrop-filter: blur(16px) saturate(120%);
424+
max-width: 100%;
425425
}
426426

427427
.imm-about__title {
428428
margin: 0;
429-
line-height: 1.15;
429+
line-height: 1.2;
430430
font-weight: 700;
431-
font-size: clamp(1.5rem, 1.2rem + 1.5vw, 2.25rem);
432-
text-shadow: 0 2px 14px rgba(0,0,0,0.7);
431+
font-size: clamp(1.75rem, 1.5rem + 1.2vw, 2.5rem);
432+
text-shadow: 0 2px 16px rgba(0,0,0,0.8);
433+
letter-spacing: -0.025em;
433434
}
434435

435436
.imm-about__subtitle {
436437
margin: 0;
437-
opacity: 0.95;
438-
font-size: clamp(1rem, 0.9rem + 0.4vw, 1.25rem);
439-
text-shadow: 0 1px 10px rgba(0,0,0,0.6);
438+
opacity: 0.9;
439+
font-size: clamp(1.05rem, 0.95rem + 0.3vw, 1.2rem);
440+
text-shadow: 0 1px 12px rgba(0,0,0,0.7);
441+
line-height: 1.4;
442+
font-weight: 400;
440443
}
441444

442445
/* Subscribe section */
443446
.imm-about__subscribe {
444-
display: grid;
445-
grid-template-columns: 1fr auto;
446-
gap: 0.5rem;
447+
display: inline-flex;
447448
align-items: center;
448-
margin-top: 0.25rem;
449-
padding: 8px 12px;
450-
border-radius: 12px;
451-
background: rgba(255,255,255,0.1);
449+
gap: 0.75rem;
450+
margin-top: 0.5rem;
451+
padding: 10px 16px;
452+
border-radius: 32px;
453+
background: rgba(255,255,255,0.08);
454+
border: 1px solid rgba(255,255,255,0.12);
452455
cursor: pointer;
453-
transition: background-color 200ms ease;
456+
transition: all 250ms ease;
457+
font-size: 0.95rem;
458+
max-width: fit-content;
454459
}
455460

456461
.imm-about__subscribe:hover {
457-
background: rgba(255,255,255,0.15);
462+
background: rgba(255,255,255,0.12);
463+
border-color: rgba(255,255,255,0.2);
464+
transform: translateY(-1px);
458465
}
459466

460467
.imm-about__button {
461-
padding: 6px 12px;
462-
border-radius: 8px;
463-
background: rgba(255,255,255,0.2);
468+
padding: 4px 12px;
469+
border-radius: 16px;
470+
background: rgba(255,255,255,0.15);
464471
color: #fff;
465-
font-weight: 600;
466-
font-size: 0.9rem;
467-
border: 1px solid rgba(255,255,255,0.3);
472+
font-weight: 500;
473+
font-size: 0.85rem;
474+
border: 1px solid rgba(255,255,255,0.2);
468475
transition: all 200ms ease;
476+
white-space: nowrap;
469477
}
470478

471479
.imm-about__button:hover {
472-
background: rgba(255,255,255,0.3);
473-
border-color: rgba(255,255,255,0.5);
480+
background: rgba(255,255,255,0.25);
481+
border-color: rgba(255,255,255,0.35);
474482
}
475483

476484
/* Subtle clamping to keep the overlay compact */
@@ -483,15 +491,24 @@
483491
}
484492
}
485493

486-
/* Respect immersive rail positions: keep top-center to avoid rail collisions */
487-
@media (max-width: 680px) {
494+
/* Responsive positioning for smaller screens */
495+
@media (max-width: 768px) {
488496
.imm-about {
489-
top: max(16px, env(safe-area-inset-top));
490-
width: calc(100% - 24px);
497+
top: max(24px, env(safe-area-inset-top));
498+
left: max(20px, env(safe-area-inset-left));
499+
width: calc(100% - 40px);
500+
max-width: 360px;
491501
}
492502
.imm-about__inner {
493-
padding: 0.75rem 0.875rem;
494-
border-radius: 14px;
503+
padding: 1rem 1.25rem;
504+
border-radius: 16px;
505+
}
506+
.imm-about__title {
507+
font-size: clamp(1.5rem, 1.3rem + 1vw, 2rem);
508+
}
509+
.imm-about__subscribe {
510+
padding: 8px 12px;
511+
gap: 0.5rem;
495512
}
496513
}
497514

0 commit comments

Comments
 (0)