@import url('font.css');

:root {
  color-scheme: light;
  font-family: 'ABC Areal', Arial, sans-serif;
  font-variation-settings: 'MONO' 0, 'slnt' 0, 'DRKM' 0;
  font-size: 14px;
  font-weight: 400;
  --ink: #161616;
  --muted: #767676;
  --paper: #fff;
  --media: #f3f3f3;
  --hover-green: #29C47C;
  --telegram-blue: #29A8EB;
  --feed-top: 32px;
  --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--paper); color: var(--muted); line-height: 1.4; -webkit-font-smoothing: antialiased; }
.site-layout { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 640px) minmax(0, 1fr); grid-template-rows: min-content 1fr; width: 100%; margin: 32px auto; }
h1, h2, p, ul { margin: 0; }
h1, h2 { font-size: inherit; font-weight: 400; line-height: inherit; color: var(--ink); }
a, button { color: var(--ink); }
a { text-decoration: none; }
button { font: inherit; line-height: inherit; border: 0; padding: 0; background: none; cursor: pointer; }
a:focus-visible, button:focus-visible { outline: 2px solid var(--ink); outline-offset: 5px; border-radius: 2px; }
.sidebar { position: fixed; top: var(--feed-top); left: 32px; width: 256px; }
.profile { display: flex; flex-direction: column; gap: 24px; }
.portrait-frame { position: relative; width: 149px; aspect-ratio: 149 / 169; overflow: hidden; flex-shrink: 0; }
/* Crop the source's empty margins, keeping the original portrait and its fade. */
.portrait { position: absolute; display: block; width: 150%; height: auto; max-width: none; left: -25%; top: -6%; }
.bio { max-width: 258px; display: flex; flex-direction: column; gap: 14px; }
.built { display: grid; gap: 14px; font-size: 14px; }
.built h2 { color: var(--muted); }
.built-card { display: flex; align-items: center; gap: 12px; width: fit-content; max-width: 100%; transition: opacity 160ms var(--ease-out); }
.built-card > img { display: block; width: 48px; height: 48px; flex-shrink: 0; border-radius: 10px; }
.built-copy { display: grid; gap: 3px; }
.built-description { color: var(--muted); }
.telegram-link { --hover-green: var(--telegram-blue); }
.sidebar-bottom { position: fixed; bottom: 28px; left: 32px; width: 256px; display: flex; flex-direction: column; gap: 28px; }
.signoff { position: relative; display: block; width: 112px; height: 42px; overflow: hidden; }
.signoff img { position: absolute; width: 178px; height: auto; max-width: none; left: -32px; top: -20px; }
.contacts { display: flex; align-items: baseline; flex-wrap: wrap; column-gap: 20px; row-gap: 12px; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0; }
.copy-email { display: inline-grid; text-align: left; }
.copy-idle, .copy-result { grid-area: 1 / 1; justify-self: center; transition: opacity 200ms var(--ease-out), transform 200ms var(--ease-out); }
.copy-idle { opacity: 1; transform: translateX(0); }
.copy-result { opacity: 0; transform: translateX(-8px); pointer-events: none; }
.copy-email.is-copied .copy-idle { opacity: 0; transform: translateX(8px); pointer-events: none; }
.copy-email.is-copied .copy-result { opacity: 1; transform: translateX(0); }
.copy-email.instant .copy-idle, .copy-email.instant .copy-result { transition: none; }
.project-feed { grid-column: 2; grid-row: 1 / 3; min-width: 0; width: 100%; margin: 0; padding-bottom: 16px; }
.project { margin-bottom: 48px; }
.project:last-child { margin-bottom: 0; }
section[aria-labelledby="more"] > .project:not(:last-child) { margin-bottom: 34px; }
.more-design-title { color: var(--muted); margin-bottom: 12px; }
.project-summary { display: flex; flex-direction: column; gap: 7px; margin-bottom: 12px; }
.project-heading { display: flex; align-items: baseline; flex-wrap: wrap; column-gap: 14px; row-gap: 8px; }
.project-title { display: flex; align-items: center; gap: 8px; white-space: nowrap; }
.project-title > img { display: block; width: 20px; height: 20px; flex-shrink: 0; border-radius: 5px; }
.campus-logo { display: block; position: relative; width: 20px; height: 20px; flex-shrink: 0; overflow: hidden; }
.campus-logo img { display: block; position: absolute; width: 40px; height: 40px; max-width: none; left: -10px; top: -10px; }
.badges { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; list-style: none; padding: 0; font-size: 12px; line-height: 16px; }
.badges li { display: inline-flex; align-items: center; gap: 5px; padding: 2px 6px; background: #f4f4f4; border-radius: 3px; white-space: nowrap; }
.badges img { flex-shrink: 0; }
.project-type { color: var(--muted); font-size: 12px; }
.feature-arrow { color: #000; }
.project-media { position: relative; display: block; width: 100%; aspect-ratio: 1; background: var(--media); border-radius: 12px; overflow: hidden; }
.project-media > img { display: block; width: 100%; height: 100%; object-fit: contain; }
.media-label { position: absolute; left: 20px; bottom: 18px; color: var(--muted); font-size: 12px; }
.media-action { position: absolute; right: 20px; bottom: 18px; font-size: 12px; opacity: 0; transform: translateY(4px); transition: opacity 180ms ease, transform 180ms var(--ease-out); }
.endnote { padding-top: 6px; }
.wave { display: inline-block; }
.wave-label { position: relative; display: inline-block; transform-origin: center; transition: transform 240ms var(--ease-out); }
.wave-gradient { position: absolute; inset: 0; pointer-events: none; color: transparent; background-image: linear-gradient(90deg, #000 0%, #000 33.33%, var(--hover-green) 45%, var(--hover-green) 55%, transparent 66.67%, transparent 100%); background-size: 300% 100%; background-position: 100% 0; background-repeat: no-repeat; background-clip: text; -webkit-background-clip: text; -webkit-text-fill-color: transparent; opacity: 0; }
/* One colour pass, matching the supplied reference; no perpetual rainbow. */
@keyframes colour-pass { from { background-position: 100% 0; filter: blur(.6px); } to { background-position: 0 0; filter: blur(0); } }
@media (hover: hover) and (pointer: fine) {
  .built-card:hover { opacity: .75; }
  .wave:hover .wave-label { transform: scale(1.04); }
  .wave:hover .wave-gradient { opacity: .94; animation: colour-pass 600ms cubic-bezier(.4, 0, .2, 1) both; }
  .wave:active .wave-label { transform: scale(.97); transition-duration: 100ms; }
  .project-media:hover .media-action { opacity: 1; transform: translateY(0); }
}
.project-media:focus-visible .media-action { opacity: 1; transform: none; }
.skip { position: absolute; top: -100px; left: 24px; background: white; padding: 10px; z-index: 2; }
.skip:focus { top: 8px; }
@media (min-width: 1344px) and (max-height: 760px) {
  .sidebar { position: static; grid-column: 1; grid-row: 1; margin-left: 32px; }
  .sidebar-bottom { position: static; grid-column: 1; grid-row: 2; align-self: start; margin: 48px 0 0 32px; }
}
@media (max-width: 1343px) {
  .site-layout { display: flex; flex-direction: column; width: calc(100% - 48px); max-width: 640px; margin: 24px auto; }
  .sidebar { position: static; width: 100%; }
  .bio { width: 100%; max-width: none; }
  .portrait-frame { width: min(298px, 100%); align-self: center; }
  .profile { gap: 24px; }
  .sidebar-bottom { position: static; width: 100%; gap: 14px; margin-top: 48px; padding-bottom: 8px; }
  .project-feed { width: 100%; margin-top: 56px; padding-bottom: 0; }
  .project-heading { flex-direction: column; align-items: flex-start; gap: 10px; }
  .project { margin-bottom: 40px; }
  section[aria-labelledby="more"] > .project:not(:last-child) { margin-bottom: 28px; }
  .case-page .sidebar { display: none; }
  .case-page .project-feed { margin-top: 0; }
}
@media (max-width: 400px) {
  .site-layout { width: calc(100% - 40px); margin: 20px auto; }
  .media-label { left: 14px; bottom: 14px; }
}
@media (hover: none) { .media-action { display: none; } }
@media (prefers-reduced-motion: reduce) {
  .wave .wave-label, .wave:hover .wave-label, .wave:active .wave-label { transform: none; transition: none; }
  .wave .wave-gradient, .wave:hover .wave-gradient { animation: none; opacity: 0; }
  .media-action { transform: none; transition: opacity 150ms ease; }
  .copy-email .copy-idle, .copy-email .copy-result { transform: none; transition: opacity 150ms ease; }
}
