@layer components { .btn { position: relative; display: inline-flex; align-items: center; justify-content: center; gap: 0.6rem; min-height: 3rem; padding-inline: 1.4rem; border: 1px solid transparent; border-radius: 99px; font-size: 0.98rem; font-weight: 500; line-height: 1.2; text-decoration: none; white-space: nowrap; transition: background-color 0.25s, border-color 0.25s, color 0.25s, translate 0.3s var(--ease-out); & .icon { transition: translate 0.3s var(--ease-out); } &:hover .icon--arrow-right { translate: 3px 0; } } .btn--primary { background: var(--text); color: var(--bg); &:hover { background: var(--pink-text); } } .btn--ghost { border-color: var(--line-strong); background: rgb(12 10 18 / 0.35); -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); &:hover { border-color: var(--text); } } .badge { display: inline-flex; align-items: center; padding: 0.1rem 0.5rem; border-radius: 99px; font-family: var(--font-mono); font-size: 0.68rem; letter-spacing: 0.06em; text-transform: uppercase; } .badge--draft { border: 1px dashed rgb(255 141 180 / 0.6); background: rgb(255 118 164 / 0.12); color: var(--pink-text); } .tags { display: flex; flex-wrap: wrap; gap: 0.4rem; margin: 0; padding: 0; list-style: none; } .tag { display: inline-block; padding: 0.2rem 0.65rem; border: 1px solid var(--line-strong); border-radius: 99px; font-family: var(--font-mono); font-size: 0.72rem; color: var(--muted); text-decoration: none; } a.tag { transition: color 0.2s, border-color 0.2s; &:hover { border-color: var(--pink-text); color: var(--text); } } .note { margin-top: 1.5rem; font-family: var(--font-mono); font-size: 0.85rem; color: var(--pink-text); } .empty { padding: 3rem 0; color: var(--muted); } /* Pointer-following border glow, the position comes from pointer.js */ [data-glow] { --mx: 50%; --my: 50%; position: relative; &::before { content: ""; position: absolute; inset: 0; z-index: 2; padding: 1px; border-radius: inherit; background: radial-gradient(26rem circle at var(--mx) var(--my), rgb(255 141 180 / 0.7), rgb(192 17 215 / 0.35) 40%, transparent 65%); -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0); -webkit-mask-composite: xor; mask: linear-gradient(#000 0 0) content-box exclude, linear-gradient(#000 0 0); opacity: 0; transition: opacity 0.4s; pointer-events: none; } } @media (hover: hover) and (pointer: fine) { [data-glow]:hover::before { opacity: 1; } } /* Project cards */ .project-grid { display: grid; gap: clamp(1rem, 2vw, 1.5rem); margin: 0; padding: 0; list-style: none; @media (min-width: 40em) { grid-template-columns: repeat(2, minmax(0, 1fr)); } } .card { height: 100%; border: 1px solid var(--line); border-radius: var(--radius-l); background: var(--surface); transition: border-color 0.3s, translate 0.4s var(--ease-out); } .card__link { display: flex; flex-direction: column; height: 100%; border-radius: inherit; color: inherit; text-decoration: none; &:focus-visible { outline-offset: 4px; border-radius: var(--radius-l); } } .card__media { aspect-ratio: 16 / 10; overflow: hidden; border-radius: calc(var(--radius-l) - 1px) calc(var(--radius-l) - 1px) 0 0; background: var(--surface-2); } .card__img { width: 100%; height: 100%; object-fit: cover; transition: scale 0.9s var(--ease-out); } .card__placeholder { width: 100%; height: 100%; background: radial-gradient(80% 70% at 20% 20%, rgb(255 118 164 / 0.45), transparent 70%), radial-gradient(70% 70% at 80% 80%, rgb(47 60 190 / 0.6), transparent 70%), radial-gradient(60% 60% at 60% 30%, rgb(192 17 215 / 0.4), transparent 70%), var(--surface-2); } .card__body { display: grid; align-content: start; gap: 0.6rem; padding: 1.25rem 1.4rem 1.6rem; } .card__meta { display: flex; flex-wrap: wrap; align-items: center; gap: 0.6rem; min-height: 1.4rem; font-family: var(--font-mono); font-size: 0.78rem; color: var(--muted); } .card__title { font-size: var(--step-2); } .card__summary { color: var(--muted); } .card .tags { margin-top: 0.35rem; } @media (hover: hover) and (pointer: fine) { .card:hover { border-color: transparent; & .card__img { scale: 1.045; } } } /* Filter chips */ .filter { display: flex; gap: 0.5rem; margin-bottom: clamp(1.5rem, 3vw, 2.25rem); @media (max-width: 39.99em) { margin-inline: calc(-1 * var(--gutter)); padding-inline: var(--gutter); padding-bottom: 0.25rem; overflow-x: auto; scroll-snap-type: x proximity; scrollbar-width: none; &::-webkit-scrollbar { display: none; } } @media (min-width: 40em) { flex-wrap: wrap; } } .chip { display: inline-flex; flex: none; align-items: center; gap: 0.5rem; min-height: 2.75rem; padding-inline: 1.1rem; border: 1px solid var(--line-strong); border-radius: 99px; color: var(--muted); font-size: 0.92rem; text-decoration: none; white-space: nowrap; scroll-snap-align: start; transition: color 0.2s, border-color 0.2s, background-color 0.2s; &:hover { border-color: var(--text); color: var(--text); } &[aria-current="true"] { border-color: transparent; background: var(--text); color: var(--bg); & .chip__count { color: rgb(12 10 18 / 0.6); } } } .chip__count { font-family: var(--font-mono); font-size: 0.72rem; color: var(--faint); } /* Link buttons (project links, contact) */ .link-button { display: flex; align-items: center; gap: 0.75rem; min-height: 3rem; padding: 0.6rem 0.95rem; border: 1px solid var(--line); border-radius: 0.8rem; background: rgb(243 238 248 / 0.03); color: var(--text); text-decoration: none; transition: border-color 0.2s, background-color 0.2s; & span { overflow-wrap: anywhere; } & .icon { color: var(--pink-text); } &:hover { border-color: rgb(255 141 180 / 0.6); background: rgb(255 118 164 / 0.08); } } /* Long-form text from Markdown */ .prose { max-width: 42rem; color: rgb(243 238 248 / 0.88); & > * + * { margin-top: 1.1em; } & > :first-child { margin-top: 0; } & h2 { margin-top: 2em; font-size: var(--step-3); color: var(--text); } & h3 { margin-top: 1.75em; font-size: var(--step-2); color: var(--text); } & h2 + *, & h3 + * { margin-top: 0.75em; } & a { color: var(--pink-text); transition: color 0.2s; &:hover { color: var(--text); } } & strong { font-weight: 600; color: var(--text); } & ul, & ol { padding-left: 1.25em; } & li + li { margin-top: 0.4em; } & li::marker { color: var(--pink-text); } & code { padding: 0.12em 0.4em; border-radius: 0.35rem; background: rgb(243 238 248 / 0.08); font-family: var(--font-mono); font-size: 0.86em; } & pre { padding: 1.1rem 1.25rem; overflow-x: auto; border: 1px solid var(--line); border-radius: 0.8rem; background: #0f0c16; font-size: 0.875rem; line-height: 1.6; & code { padding: 0; background: none; font-size: inherit; } } & img { border: 1px solid var(--line); border-radius: var(--radius); } & blockquote { padding-left: 1.25rem; border-left: 2px solid var(--violet-text); color: var(--muted); } & hr { height: 1px; border: 0; background: var(--line); } & table { width: 100%; border-collapse: collapse; font-size: 0.95rem; } & th, & td { padding: 0.6rem 0.75rem; border-bottom: 1px solid var(--line); text-align: left; } } .prose--wide { max-width: 52rem; } /* Forms */ .field { display: grid; gap: 0.45rem; } .field__label { font-size: 0.92rem; font-weight: 500; color: var(--muted); } .field__input { width: 100%; min-height: 3.1rem; padding: 0.8rem 1rem; border: 1px solid var(--line-strong); border-radius: 0.8rem; background: var(--surface); font-size: max(16px, 1rem); transition: border-color 0.2s, box-shadow 0.2s; &:hover { border-color: rgb(243 238 248 / 0.32); } &:focus { outline: none; border-color: var(--pink-text); box-shadow: 0 0 0 4px rgb(255 118 164 / 0.16); } } .field__input--area { min-height: 11rem; resize: vertical; } .field--invalid .field__input { border-color: var(--error); } .field__error { font-size: 0.875rem; color: var(--error); } .field--trap { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; } .form-status { padding: 1rem 1.25rem; border: 1px solid var(--line); border-radius: 0.8rem; background: var(--surface); } .form-status--ok { border-color: rgb(143 152 255 / 0.5); background: rgb(47 60 190 / 0.18); } .form-status--error { border-color: rgb(255 154 169 / 0.5); background: rgb(255 107 129 / 0.1); } /* Video */ .video { position: relative; aspect-ratio: 16 / 9; overflow: hidden; border: 1px solid var(--line); border-radius: var(--radius-l); background: radial-gradient(60% 80% at 15% 20%, rgb(255 118 164 / 0.3), transparent 70%), radial-gradient(60% 80% at 85% 80%, rgb(47 60 190 / 0.45), transparent 70%), var(--surface); & iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; } } .video--file { width: 100%; height: auto; aspect-ratio: auto; } .video__poster { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; filter: brightness(0.55) saturate(0.9); } .video__overlay { position: absolute; inset: 0; display: grid; place-content: center; justify-items: center; gap: 1rem; padding: 1rem; text-align: center; } .video__play { display: inline-flex; align-items: center; gap: 0.85rem; padding: 0.45rem 1.3rem 0.45rem 0.45rem; border: 1px solid var(--line-strong); border-radius: 99px; background: rgb(12 10 18 / 0.7); -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); font-weight: 500; text-decoration: none; transition: border-color 0.2s; &:hover { border-color: var(--text); & .video__play-icon { scale: 1.06; } } } .video__play-icon { display: grid; place-items: center; width: 3rem; height: 3rem; border-radius: 50%; background: var(--text); color: var(--bg); transition: scale 0.3s var(--ease-out); } .video__notice { max-width: 34ch; font-size: 0.8rem; color: rgb(243 238 248 / 0.75); } /* Gallery + lightbox */ .gallery { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0.75rem; margin: 0; padding: 0; list-style: none; @media (min-width: 60em) { grid-template-columns: repeat(3, minmax(0, 1fr)); } & figcaption { margin-top: 0.5rem; font-size: 0.85rem; color: var(--muted); } } .gallery__link { display: block; aspect-ratio: 4 / 3; overflow: hidden; border: 1px solid var(--line); border-radius: var(--radius); cursor: zoom-in; } .gallery__img { width: 100%; height: 100%; object-fit: cover; transition: scale 0.7s var(--ease-out); } @media (hover: hover) and (pointer: fine) { .gallery__link:hover .gallery__img { scale: 1.05; } } .lightbox { width: 100vw; max-width: none; height: 100vh; height: 100dvh; max-height: none; margin: 0; padding: 0; border: 0; background: rgb(8 6 12 / 0.94); color: var(--text); &::backdrop { background: rgb(8 6 12 / 0.6); } &[open] { animation: fade-in 0.3s var(--ease-out); } } .lightbox__figure { position: absolute; inset: 0; display: grid; place-items: center; padding: calc(4.5rem + env(safe-area-inset-top)) 1rem calc(4rem + env(safe-area-inset-bottom)); touch-action: pan-y pinch-zoom; @media (min-width: 48em) { padding-inline: 5.5rem; } } .lightbox__img { max-width: 100%; max-height: 100%; width: auto; height: auto; border-radius: 0.5rem; object-fit: contain; user-select: none; } .lightbox__btn { position: absolute; display: grid; place-items: center; width: 3rem; height: 3rem; padding: 0; border: 1px solid var(--line-strong); border-radius: 50%; background: rgb(243 238 248 / 0.08); transition: background-color 0.2s; &:hover { background: rgb(243 238 248 / 0.16); } } .lightbox__close { top: calc(1rem + env(safe-area-inset-top)); right: 1rem; } .lightbox__prev, .lightbox__next { top: 50%; translate: 0 -50%; @media (max-width: 47.99em) { top: auto; bottom: calc(1rem + env(safe-area-inset-bottom)); translate: none; } } .lightbox__prev { left: 1rem; } .lightbox__next { right: 1rem; } .lightbox__count { position: absolute; bottom: calc(1.6rem + env(safe-area-inset-bottom)); left: 50%; translate: -50% 0; font-family: var(--font-mono); font-size: 0.8rem; color: var(--muted); } }