mirror of
https://github.com/hanzoai/site.git
synced 2026-11-21 01:07:08 +00:00
Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01P5YBdv4vL6q1MbG8BDxRdW
72 lines
5.2 KiB
CSS
72 lines
5.2 KiB
CSS
/* Gateway's pinned chapters (prefix gwc-). Greys only. See GwChapters.jsx. */
|
|
.gwc { position: relative; height: calc(var(--n) * 80svh + 20svh); --e: cubic-bezier(.16, 1, .3, 1); }
|
|
.gwc-stage { position: sticky; top: 0; height: 100svh; }
|
|
.gwc-in { width: min(100% - 48px, 1440px); height: 100%; margin-inline: auto; box-sizing: border-box; padding: 88px 0 40px; display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: 24px; align-items: center; }
|
|
.gwc-vis { grid-column: 1 / span 7; position: relative; height: min(58svh, 520px); min-height: 0; }
|
|
.gwc-copy { grid-column: 8 / -1; position: relative; align-self: center; padding-left: clamp(0px, 2vw, 32px); }
|
|
|
|
.js .gwc-arts { display: grid; }
|
|
.js .gwc-art { grid-area: 1 / 1; opacity: 0; transform: translate3d(0, 32px, 0); pointer-events: none; transition: opacity .38s var(--e), transform .8s var(--e); }
|
|
.js .gwc-art[data-past] { transform: translate3d(0, -32px, 0); }
|
|
.js .gwc-art[data-on] { opacity: 1; transform: none; pointer-events: auto; transition-delay: .1s; }
|
|
.gwc-t { margin: 0; font-weight: 497; font-size: 32px; line-height: 1.1; letter-spacing: -.03em; text-wrap: balance; max-width: 16ch; }
|
|
.gwc-t > span { display: block; padding-bottom: .08em; margin-bottom: -.08em; }
|
|
.js .gwc-t > span { clip-path: inset(0 0 100% 0); transition: clip-path .95s var(--e); }
|
|
.js .gwc-art[data-on] .gwc-t > span { clip-path: inset(0 0 0 0); transition-delay: .12s; }
|
|
.gwc .gwc-n { margin: 14px 0 22px; color: light-dark(#737373, var(--text-tertiary)); }
|
|
.gwc-d { margin: 0; font-size: 16px; line-height: 1.6; color: var(--soft); text-wrap: pretty; max-width: 46ch; }
|
|
|
|
/* the dots: the title shows on hover or focus, a press answers, a click jumps */
|
|
.gwc-dots { display: flex; gap: 2px; margin-top: 40px; margin-left: -14px; }
|
|
.gwc-dots button { position: relative; width: 44px; height: 44px; display: grid; place-items: center; border: 0; padding: 0; background: none; cursor: pointer; border-radius: 12px; transition: transform 90ms cubic-bezier(0, 0, .2, 1); }
|
|
.gwc-dots button:active { transform: scale(.9); }
|
|
.gwc-dots i { width: 8px; height: 8px; border-radius: 999px; background: light-dark(rgba(0, 0, 0, .16), var(--border-focus)); transition: transform .3s var(--e), background-color .15s cubic-bezier(0, 0, .2, 1); }
|
|
.gwc-dots button[aria-current] i { background: var(--ink); transform: scale(1.5); }
|
|
.gwc-tip { position: absolute; left: 50%; bottom: calc(100% + 2px); padding: 7px 10px; border-radius: 8px; background: var(--ink); color: light-dark(#fafafa, var(--primary-foreground)); font: 500 12px/1.2 var(--mono); white-space: nowrap; opacity: 0; visibility: hidden; transform: translate(-50%, 6px); pointer-events: none; transition: opacity .15s cubic-bezier(0, 0, .2, 1), transform .3s var(--e), visibility 0s .15s; z-index: 2; }
|
|
.gwc-dots button:focus-visible { outline: 2px solid var(--ink); outline-offset: -4px; }
|
|
.gwc-dots button:focus-visible .gwc-tip { opacity: 1; visibility: visible; transform: translate(-50%, 0); transition-delay: 0s; }
|
|
@media (hover: hover) {
|
|
.gwc-dots button:hover i { background: light-dark(#525252, var(--muted-foreground)); transform: scale(1.35); }
|
|
.gwc-dots button:hover .gwc-tip { opacity: 1; visibility: visible; transform: translate(-50%, 0); transition-delay: 0s; }
|
|
}
|
|
|
|
.gwc-dots button { transition: transform 90ms cubic-bezier(0, 0, .2, 1), background-color .15s cubic-bezier(0, 0, .2, 1); }
|
|
@media (hover: hover) { .gwc-dots button:hover { background: light-dark(#f5f5f5, var(--muted)); } }
|
|
/* a dot previewing another chapter's scene: the window takes a hairline ink ring, so the preview reads as a preview */
|
|
.gwc-vis { border-radius: 24px; transition: box-shadow .15s cubic-bezier(0, 0, .2, 1); }
|
|
.gwc-vis[data-peek] { box-shadow: 0 0 0 1.5px var(--ink); }
|
|
|
|
.gwc-vis > * { width: 100%; height: 100%; box-sizing: border-box; }
|
|
|
|
/* phone: the same pinned stage, stacked. A short scene at the top (about 40svh, inside the gutters) and the chapter's
|
|
words below it, swapped in place as the section scrolls, so no words ever slide under the scene. With scripts off the
|
|
chapters simply stack. */
|
|
@media (max-width: 900px) {
|
|
.gwc { height: auto; }
|
|
.gwc-stage { position: static; height: auto; }
|
|
.gwc-in { display: block; padding: 0; width: min(100% - 32px, 1440px); }
|
|
.gwc-vis { height: 40svh; min-height: 220px; margin-bottom: 20px; }
|
|
.gwc-copy { padding: 0; }
|
|
.gwc-art { padding: 28px 0 0; }
|
|
.gwc-t { font-size: 21px; }
|
|
.gwc .gwc-n { margin: 10px 0 12px; }
|
|
.gwc-d { font-size: 15px; line-height: 1.55; }
|
|
.gwc-dots { display: none; }
|
|
.js .gwc { height: calc(var(--n) * 72svh + 28svh); }
|
|
.js .gwc-stage { position: sticky; top: 0; height: 100svh; }
|
|
.js .gwc-in { display: flex; flex-direction: column; height: 100%; box-sizing: border-box; padding: 72px 0 16px; }
|
|
.js .gwc-vis { flex: none; }
|
|
.js .gwc-copy { flex: 1; min-height: 0; overflow: hidden; }
|
|
.js .gwc-art { padding: 0; }
|
|
.js .gwc-t > span { clip-path: none; }
|
|
}
|
|
@media (max-width: 400px) {
|
|
.gwc-vis { height: 36svh; }
|
|
.gwc-d { font-size: 14px; line-height: 1.5; }
|
|
.gwc-t { font-size: 19px; }
|
|
}
|
|
@media (prefers-reduced-motion: reduce) {
|
|
.js .gwc-art, .js .gwc-t > span { transition: none !important; transform: none !important; }
|
|
.js .gwc-t > span { clip-path: none; }
|
|
}
|