@font-face {
  font-family: "Source Sans 3";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/fonts/source-sans-3-latin-400-normal.woff2") format("woff2");
}

@font-face {
  font-family: "Source Sans 3";
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("/fonts/source-sans-3-latin-500-normal.woff2") format("woff2");
}

:root {
  color-scheme: dark;
  --bg: #000;
  --ink: #f5f5f5;
  --muted: #c8c8c8;
  --line: #2a2a2a;
  --card: #0c0c0c;
  --focus: #fff;
  --danger: #ffc9c2;
  --sans: "Source Sans 3", "Segoe UI", sans-serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 1.0625rem;
  line-height: 1.45;
}

main {
  width: min(1080px, calc(100% - 2rem));
  margin-inline: auto;
  padding: 1.25rem 0 6rem;
}

.grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.85rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.tile {
  display: flex;
  flex-direction: column;
  height: 100%;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--card);
  color: inherit;
  text-decoration: none;
}

.tile:focus {
  outline: none;
}

.tile:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 3px;
}

.shot {
  display: block;
  aspect-ratio: 16 / 10;
  background: #111;
  border-bottom: 1px solid var(--line);
}

.shot img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
}

.tile-body {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  padding: 0.85rem 0.95rem 1rem;
}

.tile h2 {
  margin: 0;
  font-size: 1.15rem;
  font-weight: 500;
  letter-spacing: 0;
}

.tile p {
  margin: 0;
  color: var(--muted);
}

.go {
  display: inline-block;
  margin-top: 0.55rem;
  color: var(--muted);
  overflow-wrap: anywhere;
}

.tile:hover .go,
.tile:focus-visible .go {
  color: var(--ink);
  text-decoration: underline;
  text-underline-offset: 0.18em;
}

.missing {
  padding-top: 4rem;
}

.home-link {
  color: var(--ink);
}

.home-link:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 3px;
}

.linkedin {
  position: fixed;
  z-index: 20;
  left: max(0.55rem, env(safe-area-inset-left));
  bottom: max(0.7rem, env(safe-area-inset-bottom));
  display: grid;
  width: 44px;
  height: 44px;
  place-items: center;
  color: #8a8a8a;
  text-decoration: none;
}

.linkedin:hover {
  color: #f2f2f2;
}

.linkedin:focus {
  outline: none;
}

.linkedin:focus-visible {
  color: #f2f2f2;
  outline: 3px solid var(--focus);
  outline-offset: 2px;
  border-radius: 8px;
}

.linkedin svg {
  display: block;
}

@media (prefers-reduced-motion: no-preference) {
  .linkedin {
    transition: color 0.15s ease;
  }
}

.contact-open {
  position: fixed;
  right: max(1rem, env(safe-area-inset-right));
  bottom: max(1rem, env(safe-area-inset-bottom));
  z-index: 20;
  min-height: 44px;
  padding: 0.65rem 1.1rem;
  border: 0;
  border-radius: 999px;
  background: #fff;
  color: #000;
  font: inherit;
  font-weight: 500;
  cursor: pointer;
}

.contact-open:focus {
  outline: none;
}

.contact-open:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 3px;
}

.panel {
  position: fixed;
  right: max(1rem, env(safe-area-inset-right));
  bottom: calc(max(1rem, env(safe-area-inset-bottom)) + 3.4rem);
  z-index: 21;
  width: min(22rem, calc(100vw - 2rem));
  padding: 1rem;
  border: 1px solid #333;
  border-radius: 12px;
  background: #111;
  color: var(--ink);
}

.panel label {
  display: block;
  margin-bottom: 0.4rem;
}

.panel input[type="text"] {
  width: 100%;
  min-height: 44px;
  padding: 0.55rem 0.7rem;
  border: 1px solid #3a3a3a;
  border-radius: 8px;
  background: #000;
  color: var(--ink);
  font: inherit;
}

.panel input:focus {
  outline: none;
}

.panel input:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 2px;
}

.honeypot {
  position: absolute;
  left: -10000px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.error {
  min-height: 1.4em;
  margin: 0.55rem 0 0;
  color: var(--danger);
}

.panel button {
  min-height: 44px;
  margin-top: 0.75rem;
  padding: 0.5rem 1rem;
  border: 0;
  border-radius: 8px;
  font: inherit;
  font-weight: 500;
  cursor: pointer;
}

.panel button:focus {
  outline: none;
}

.panel button:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 3px;
}

.panel button[type="submit"] {
  background: #fff;
  color: #000;
}

.panel .close {
  background: transparent;
  color: var(--ink);
}

.done {
  margin: 0;
}

.done:focus {
  outline: none;
}

.done:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 3px;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

@media (min-width: 720px) {
  main {
    padding-top: 2rem;
  }

  .grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (min-width: 1040px) {
  .grid {
    grid-template-columns: 1fr 1fr 1fr;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
}
