@font-face {
  font-family: Geist;
  src: url("assets/geist.woff2") format("woff2");
  font-weight: 400 800;
  font-display: swap;
}

@font-face {
  font-family: "IBM Plex Mono";
  src: url("assets/ibm-plex-mono.woff2") format("woff2");
  font-display: swap;
}

:root {
  color-scheme: light;
  --paper: #f7f6f2;
  --ink: #1c1e1c;
  --muted: #54564e;
  --line: #d6d5cd;
  --orange: #df522d;
  --accent-ink: #ab371d;
  --mono: "IBM Plex Mono", monospace;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--paper); color: var(--ink); font: 400 16px/1.5 Geist, sans-serif; }
a { color: inherit; text-decoration: none; }
button { color: inherit; font: inherit; cursor: pointer; }
img { display: block; width: 100%; }
p, h1, h2, h3 { margin: 0; }
:focus-visible { outline: 2px solid var(--accent-ink); outline-offset: 4px; }
::selection { background: #ffb79c; color: var(--ink); }

.shell { width: min(100% - 112px, 1320px); margin-inline: auto; }
.skip, .sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.skip:focus { z-index: 5; top: 12px; left: 12px; width: auto; height: auto; padding: 10px 14px; background: var(--paper); clip-path: none; }

.site-header, .site-footer {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  min-height: 78px;
  border-bottom: 1px solid var(--line);
}

.wordmark { display: inline-flex; justify-self: start; align-items: center; gap: 10px; font-size: 15px; font-weight: 700; letter-spacing: -.035em; }
.brand-mark { flex: none; width: 20px; height: 20px; border: 1px solid var(--ink); border-radius: 50%; position: relative; }
.brand-mark::after { content: ""; position: absolute; inset: 4px; background: var(--orange); border-radius: 50%; }
.site-header nav { display: flex; gap: 36px; font-size: 14px; font-weight: 550; }
.site-header nav a:hover, .site-footer a:hover { color: var(--accent-ink); }
.header-actions { display: flex; align-items: center; justify-self: end; gap: 14px; }
.language-link { padding: 8px 5px; font: 12px var(--mono); color: var(--muted); }
.language-link:hover { color: var(--accent-ink); }
.contact-link { padding: 9px 15px; display: flex; gap: 14px; align-items: center; border: 1px solid var(--line); border-radius: 3px; font-size: 13px; font-weight: 650; }
.contact-link span { color: var(--accent-ink); }
.contact-link:hover { border-color: var(--ink); }

.hero { display: grid; grid-template-columns: .92fr 1.08fr; align-items: center; gap: clamp(28px, 5vw, 86px); padding-block: clamp(42px, 5.4vw, 90px) clamp(44px, 5vw, 76px); }
.hero-copy { padding-bottom: 28px; }
.eyebrow { display: flex; align-items: center; gap: 9px; color: var(--accent-ink); font: 400 11px/1.45 var(--mono); letter-spacing: .11em; text-transform: uppercase; }
.signal { flex: none; width: 7px; height: 7px; background: var(--orange); border-radius: 50%; }
h1, h2 { font-weight: 700; letter-spacing: -.062em; }
h1 { margin-block: 16px 0; font-size: clamp(34px, 4.6vw, 74px); line-height: 1.05; letter-spacing: -.055em; }
.period { color: var(--orange); }
.primary-action { display: inline-flex; align-items: center; gap: 18px; margin-top: 27px; padding: 11px 15px; border-radius: 3px; background: var(--ink); color: var(--paper); font-size: 13px; font-weight: 600; }
.primary-action span { font-size: 16px; line-height: 1; color: #ff9e81; }
.primary-action:hover { background: #3a3c37; }

.hero-media { min-width: 0; }
.viewfinder { position: relative; isolation: isolate; overflow: hidden; aspect-ratio: 1.45; background: #162723; border-radius: 4px; }
.hero-slides, .hero-slide, .hero-slide img, .hero-slide video, .hero-fallback { position: absolute; inset: 0; width: 100%; height: 100%; }
.hero-slide img, .hero-slide video, .hero-fallback { object-fit: cover; }
.hero-slide { opacity: 0; transition: opacity .65s ease; overflow: hidden; }
.hero-slide.is-active { opacity: 1; }
.hero-slide video { opacity: 0; transition: opacity .35s ease; }
.hero-slide video.is-playing { opacity: 1; }
.hero-slide.is-active img { animation: drift 8s ease-out both paused; }
.hero-slide.is-moving img { animation-play-state: running; }
@keyframes drift { from { transform: scale(1); } to { transform: scale(1.08) translate(-.7%, .4%); } }

.corner { position: absolute; z-index: 1; width: 13px; height: 13px; border: 0 solid #fff9ec; opacity: .8; pointer-events: none; }
.top-left { top: 15px; left: 15px; border-top-width: 1px; border-left-width: 1px; }
.top-right { top: 15px; right: 15px; border-top-width: 1px; border-right-width: 1px; }
.bottom-left { bottom: 15px; left: 15px; border-bottom-width: 1px; border-left-width: 1px; }
.bottom-right { bottom: 15px; right: 15px; border-bottom-width: 1px; border-right-width: 1px; }
.preview-label { position: absolute; z-index: 1; bottom: 19px; left: 22px; padding: 5px 8px; background: #171916da; color: #fff; font: 10px var(--mono); letter-spacing: .045em; text-transform: uppercase; border-radius: 2px; }
.hero-toolbar { display: flex; align-items: center; gap: 15px; min-height: 47px; }
.frame-count { font: 11px var(--mono); color: var(--muted); white-space: nowrap; }
.frame-progress { display: flex; flex: 1; gap: 4px; }
.frame-progress span { display: block; flex: 1; height: 2px; background: var(--line); }
.frame-progress span.is-active { background: var(--orange); }
.frame-controls { display: flex; gap: 5px; }
.frame-controls button { display: grid; place-items: center; width: 33px; height: 33px; padding: 0; border: 1px solid var(--line); border-radius: 3px; background: transparent; font-size: 17px; line-height: 1; }
.frame-controls button:hover { border-color: var(--ink); }
.pause-icon { width: 8px; height: 11px; border-inline: 2px solid; }
.play-icon { width: 0; height: 0; border: 5px solid transparent; border-left: 8px solid; border-right-width: 0; }

.section { border-top: 1px solid var(--line); padding-block: 31px 72px; scroll-margin-top: 16px; }
h2 { font-size: clamp(45px, 5.35vw, 82px); line-height: .99; }
.section h2, .contact h2 { margin-top: 10px; }

.preview-note { margin-top: 14px; color: var(--muted); font: 11px var(--mono); }

.work-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr)); gap: 32px 22px; margin-top: 22px; }
.project-card { min-width: 0; }
.card-button { display: block; width: 100%; padding: 0 0 14px; border: 0; border-bottom: 1px solid var(--line); background: transparent; text-align: left; }
.card-image { position: relative; display: block; overflow: hidden; aspect-ratio: 1.53; background: #242724; border-radius: 3px; }
.card-image img { height: 100%; object-fit: cover; transition: transform .45s ease; }
.card-button:hover img { transform: scale(1.045); }
.card-arrow { position: absolute; top: 11px; right: 11px; display: grid; place-items: center; width: 34px; height: 34px; color: var(--ink); background: var(--paper); border-radius: 2px; line-height: 1; transition: background .2s, color .2s; }
.card-button:hover .card-arrow { background: var(--ink); color: var(--paper); }
.card-meta { display: block; margin-top: 13px; color: var(--accent-ink); font: 10px var(--mono); letter-spacing: .09em; text-transform: uppercase; }
.card-title { display: block; margin-top: 4px; font-size: clamp(18px, 2vw, 28px); font-weight: 650; line-height: 1.16; letter-spacing: -.05em; }
.empty-message { color: var(--muted); grid-column: 1 / -1; }

.about { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; padding-bottom: 76px; }
.about-copy { padding-top: 19px; }
.bio { max-width: 34ch; font-size: clamp(21px, 2.4vw, 34px); letter-spacing: -.045em; line-height: 1.25; }
.experience-list { list-style: none; padding: 0; margin: 10px 0 0; }
.experience-list li { border-top: 1px solid var(--line); padding: 12px 0; }
#experience { margin-top: 26px; }
.experience-list p { margin-top: 5px; color: var(--muted); }
.experience-title { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 6px 18px; }
.experience-title span { font: 12px var(--mono); color: var(--muted); }

.contact { background: #ece9df; padding: clamp(24px, 4vw, 56px); border-radius: 4px; }
.contact-layout { display: grid; grid-template-columns: 1fr 1fr; align-items: end; gap: 28px; }
.contact-details { padding-bottom: 3px; color: var(--muted); }
.contact-links { display: flex; flex-wrap: wrap; gap: 8px; }
.contact-links a { padding: 9px 13px; border: 1px solid #b7b5ac; border-radius: 3px; font-size: 14px; font-weight: 600; color: var(--ink); overflow-wrap: anywhere; }
.contact-links a:hover { background: var(--ink); color: var(--paper); }
.contact-links a span { margin-left: 8px; }

.site-footer { grid-template-columns: 1fr auto; min-height: 75px; border: 0; }
.site-footer > a:last-child { font: 11px var(--mono); }

.project-dialog { width: min(780px, 100% - 32px); max-height: 90dvh; border: 1px solid var(--line); border-radius: 5px; padding: clamp(16px, 4vw, 30px); background: var(--paper); color: var(--ink); overscroll-behavior: contain; }
.project-dialog::backdrop { background: #171916b8; }
body:has(.project-dialog[open]) { overflow: hidden; }
.dialog-bar { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.close-button { border: 1px solid var(--line); border-radius: 3px; background: transparent; width: 40px; height: 40px; font-size: 25px; line-height: 1; }
.close-button:hover { border-color: var(--ink); }
.project-dialog h2 { font-size: clamp(30px, 6vw, 58px); margin: 8px 0 19px; }
.project-media { display: grid; gap: 10px; }
.project-media img { height: auto; max-height: 72vh; object-fit: contain; background: var(--ink); }
.project-media iframe, .project-media video { display: block; width: 100%; aspect-ratio: 16 / 9; border: 0; background: var(--ink); }
.project-details { margin-top: 16px; color: var(--muted); }
.project-details a { display: inline-block; margin-top: 12px; color: var(--accent-ink); text-decoration: underline; text-underline-offset: 4px; }

@media (max-width: 1050px) {
  .shell { width: calc(100% - 72px); }
  .hero { gap: 32px; }
  .hero-copy { padding-bottom: 14px; }
}

@media (max-width: 720px) {
  .shell { width: calc(100% - 36px); }
  .site-header { min-height: 64px; gap: 12px; grid-template-columns: minmax(0, 1fr) auto auto; }
  .site-header nav { gap: 15px; font-size: 13px; }
  .wordmark { gap: 6px; font-size: 13px; }
  .brand-mark { width: 17px; height: 17px; }
  .brand-mark::after { inset: 3px; }
  .contact-link { padding: 7px; gap: 4px; font-size: 11px; white-space: nowrap; }
  .hero { grid-template-columns: 1fr; gap: 26px; padding-block: 42px 26px; }
  .hero-copy { padding: 0; }
  h1 { font-size: clamp(34px, 10vw, 54px); margin-top: 12px; }
  .primary-action { margin-top: 18px; }
  .viewfinder { aspect-ratio: 1.52; }
  .section { padding-block: 25px 48px; }
  .work-grid { gap: 22px 12px; }
  .about, .contact-layout { grid-template-columns: 1fr; gap: 22px; }
  .about-copy { padding: 0; }
}

@media (max-width: 425px) {
  .site-header { gap: 8px; }
  .site-header nav { gap: 10px; }
  .site-header .wordmark { font-size: 12px; }
  .header-actions { gap: 5px; }
  .language-link { padding-inline: 3px; font-size: 11px; }
  .contact-link span { display: none; }
  .frame-controls button { width: 36px; height: 36px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 0s !important; transition-duration: 0s !important; }
}

.hero:has(.hero-media[hidden]) { grid-template-columns: 1fr; }
