/* ==========================================================================
   Works page only
   ========================================================================== */

/* Hero video sits over its own poster photo (desktop only, see works.js). */
.hero__video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -2; opacity: 0; transition: opacity 0.8s; }
.hero__video.is-playing { opacity: 1; }
.hero::before { content: ""; position: absolute; inset: 0; z-index: -1; background: rgba(10, 10, 10, 0.25); }

/* ---------- Works list ---------- */
.works { padding-top: 150px; padding-bottom: 120px; }
.works__divider { margin: 34px 0 40px; }

.filters { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 40px; }
.filter {
  position: relative; min-height: 30px; padding: 0 14px;
  border-radius: var(--radius-pill); background: #1e1e1e; color: var(--color-muted);
  font-family: var(--font-mono); font-size: var(--text-mono-sm); letter-spacing: -0.02em;
  transition: color 0.3s, background-color 0.3s;
}
/* Invisible 44px tap area around the small pill. */
.filter::after { content: ""; position: absolute; inset: -7px -4px; }
.filter:hover { color: var(--color-text); }
.filter[aria-pressed="true"] { color: var(--color-text); background: #2a2a2a; font-weight: 600; }

.works__grid { display: grid; gap: 40px; }
.work-card {
  position: relative; display: block; aspect-ratio: 352 / 700;
  border: 1px solid rgba(245, 245, 245, 0.08); border-radius: var(--radius); overflow: hidden;
  background: #0d0d0d; isolation: isolate;
}
.work-card img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -2; }
.work-card::after {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: linear-gradient(to bottom, rgba(10,10,10,0.25), rgba(10,10,10,0.45) 60%, rgba(10,10,10,0.7));
  transition: background-color 0.4s;
}
.work-card:hover::after { background-color: rgba(10, 10, 10, 0.15); }
.work-card__title {
  position: absolute; inset: 0; display: grid; place-items: center; padding: var(--gutter); text-align: center;
  font-size: var(--text-h3); line-height: 1.4; letter-spacing: -0.04em; font-weight: 500;
}
.work-card__meta {
  position: absolute; left: 18px; right: 18px; bottom: 22px;
  display: flex; justify-content: space-between;
  font-family: var(--font-mono); font-size: var(--text-mono); letter-spacing: -0.01em;
}
.work-card.is-hidden { display: none; }
.works__empty { color: var(--color-muted); }

@media (min-width: 810px) {
  .works { padding-top: 160px; padding-bottom: 160px; }
  .works__grid { grid-template-columns: 1fr 1fr; gap: 40px 20px; }
  .work-card { aspect-ratio: 691 / 700; }
}

/* ---------- Floating "Start a Project" button (desktop) ---------- */
