*, *::after, *::before { box-sizing: border-box; } :root { font-size: 18px; --color-text: #fff; --color-bg: #000; --color-link: #fff; --color-link-hover: #fff; } body { margin: 0; color: var(--color-text); background-color: var(--color-bg); font-family: area-normal,-apple-system, BlinkMacSystemFont, Segoe UI, Helvetica, Arial, sans-serif; -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; width: 100%; height: 100vh; overflow: hidden; touch-action: none; } /* Page Loader */ .js .loading::before, .js .loading::after { content: ''; position: fixed; z-index: 1000; } .js .loading::before { top: 0; left: 0; width: 100%; height: 100%; background: #f0f0f0; } .js .loading::after { top: 50%; left: 50%; width: 20vw; aspect-ratio: 0.75; transform: translate3d(-50%,-50%,0); background-color: #f0f0f0; animation: loaderAnim 1s linear infinite alternate forwards; } @keyframes loaderAnim { to { background-color: #ccc; } } a { text-decoration: none; color: var(--color-link); outline: none; cursor: pointer; opacity: 0.6; } a:hover { color: var(--color-link-hover); outline: none; opacity: 1; } /* Better focus styles from https://developer.mozilla.org/en-US/docs/Web/CSS/:focus-visible */ a:focus { /* Provide a fallback style for browsers that don't support :focus-visible */ outline: none; background: lightgrey; } a:focus:not(:focus-visible) { /* Remove the focus indicator on mouse-focus for browsers that do support :focus-visible */ background: transparent; } a:focus-visible { /* Draw a very noticeable focus style for keyboard-focus on browsers that do support :focus-visible */ outline: 2px solid red; background: transparent; } .unbutton { background: none; border: 0; padding: 0; margin: 0; font: inherit; color: inherit; cursor: pointer; } .unbutton:focus { outline: none; } main { display: grid; grid-template-areas: 'main'; position: relative; width: 100%; height: 100vh; overflow: hidden; place-items: center; } .frame { position: fixed; top: 0; left: 0; width: 100%; color: var(--color-title); padding: 1rem; font-size: 13px; font-weight: 600; display: grid; grid-template-columns: 100%; grid-template-areas: 'title' 'demos' 'credits' 'sponsor'; justify-content: start; align-content: space-between; align-items: start; z-index: 100; pointer-events: none; grid-gap: 0.5rem; } .frame a { pointer-events: auto; } .frame a:not(.frame__demo) { white-space: nowrap; overflow: hidden; position: relative; } .frame a:not(.frame__demo)::before { content: ''; height: 1px; width: 100%; background: currentColor; position: absolute; top: 90%; transition: transform 0.3s; transform-origin: 0% 50%; } .frame a:not(.frame__demo):hover::before { transform: scaleX(0); transform-origin: 100% 50%; } .frame__title { grid-area: title; display: flex; align-items: flex-end; } .frame strong { font-weight: 800; } .frame__title-main { font-size: inherit; margin: 0; font-weight: inherit; } .frame__demos { grid-area: demos; display: flex; gap: 1rem; } .frame__demo { text-decoration: none; } .frame__demo--current { font-weight: 800; color: var(--color-link-hover); } .frame__credits { grid-area: credits; display: flex; gap: 1rem; } .slider { grid-area: main; position: relative; overflow: hidden; display: grid; place-items: center; width: 100%; height: 100vh; } .slider__item { grid-area: 1 / 1 / -1 / -1; position: relative; width: 100%; aspect-ratio: 2.5 / 3; overflow: hidden; display: grid; place-items: center; pointer-events: none; transform: scale(0); opacity: 0; z-index: 3; } .slider__item--current { opacity: 1; pointer-events: auto; z-index: 50; transform: scale(0.3); z-index: 2; } .slider__item--previous { z-index: 1; opacity: 1; transform: scale(1); } .slider__item-inner { position: relative; width: 100%; height: 100%; display: grid; place-items: center; background-size: cover; background-position: 50% 50%; } .slider-nav { grid-area: main; padding: 1rem; width: 100%; line-height: 1; display: grid; grid-template-areas: 'prev next'; z-index: 2; justify-content: space-between; } .slider-nav__item { line-height: 1.5; position: relative; text-transform: uppercase; display: block; font-family: "afronaut", sans-serif; font-weight: 400; font-size: clamp(1rem,7vw,3rem); transition: opacity 0.3s; } .slider-nav__item span { display: inline-block; pointer-events: none; } .slider-nav__item:hover { opacity: 0.5; } .slider-nav__item--prev { grid-area: prev; } .slider-nav__item--next { grid-area: next; } @media screen and (min-width: 53em) { .frame { height: 100vh; grid-gap: 2rem; grid-template-columns: auto auto 1fr; grid-template-rows: auto auto; grid-template-areas: 'title demos sponsor' 'credits ... ... '; } .frame__demos { justify-self: end; } }