/* ── Reset ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --black:      #0a0a0a;
  --white:      #ffffff;
  --off-white:  #f4f3ef;
  --grey-light: #e2e0db;
  --grey-mid:   #999;
  --grey-dark:  #444;

  --font-display: 'Lexend Exa', sans-serif;
  --font-body:    'Inter', sans-serif;
  --font-mono:    'Space Mono', monospace;

  --font-weight-light:   300;
  --font-weight-regular: 400;
  --font-weight-medium:  500;

  --nav-h: 60px;
}

html { scroll-behavior: smooth; }

body {
  background: var(--black);
  color: var(--white);
  font-family: var(--font-body);
  font-weight: var(--font-weight-light);
  font-size: 1rem;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }
img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: center; }

p  { font-weight: var(--font-weight-light); }
strong { font-weight: var(--font-weight-medium); }

/* ── TYPE SCALE ── */
h1 {
  font-family: var(--font-display);
  font-weight: var(--font-weight-light);
  font-size: clamp(2rem, 5vw, 3.5rem);
  letter-spacing: -0.02em;
  line-height: 1.1;
}

h2 {
  font-family: var(--font-display);
  font-weight: var(--font-weight-light);
  font-size: clamp(1.5rem, 3vw, 2.25rem);
  letter-spacing: -0.02em;
  line-height: 1.2;
}

h3 {
  font-family: var(--font-body);
  font-weight: var(--font-weight-medium);
  font-size: 1.125rem;
  line-height: 1.4;
}

.meta, code, time {
  font-family: var(--font-mono);
  font-size: 0.8rem;
}

/* ── NAV ── */
nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 200;
  height: var(--nav-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 2.5rem;
  transition: background 0.4s ease;
}

nav.scrolled {
  background: rgba(10, 10, 10, 0.92);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.nav-name {
  font-family: var(--font-display);
  font-weight: var(--font-weight-light);
  font-size: 0.9rem;
  letter-spacing: -0.01em;
  color: var(--white);
}

.nav-links {
  display: flex;
  gap: 2.5rem;
}

.nav-links a {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  font-weight: var(--font-weight-regular);
  color: rgba(255,255,255,0.75);
  transition: color 0.2s;
}
.nav-links a:hover { color: var(--white); }

/* Mobile toggle */
.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
}
.nav-toggle span {
  display: block;
  width: 22px;
  height: 1px;
  background: var(--white);
  transition: transform 0.3s, opacity 0.3s;
}
.nav-toggle.open span:first-child { transform: translateY(6px) rotate(45deg); }
.nav-toggle.open span:last-child  { transform: translateY(-6px) rotate(-45deg); }

/* Mobile menu */
.mobile-menu {
  position: fixed;
  inset: 0;
  z-index: 150;
  background: var(--black);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3rem;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.35s ease;
}
.mobile-menu.open { opacity: 1; pointer-events: all; }

.mobile-link {
  font-family: var(--font-display);
  font-weight: var(--font-weight-light);
  font-size: 2.25rem;
  letter-spacing: -0.02em;
  color: var(--white);
}

/* ── HERO ── */
#home {
  position: relative;
  height: 100svh;
  display: flex;
  align-items: flex-end;
  justify-content: flex-start;
  overflow: hidden;
}

/* YouTube background player */
.hero-video-wrap {
  position: absolute;
  inset: 0;
  overflow: hidden;
  z-index: 0;
  pointer-events: none;
}

#ytPlayer {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  /* Scale to always cover the viewport regardless of aspect ratio */
  width: 100vw;
  height: 56.25vw;   /* 16:9 based on width  */
  min-height: 100vh;
  min-width: 177.78vh; /* 16:9 based on height */
  pointer-events: none;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to top,
    rgba(0,0,0,0.85) 0%,
    rgba(0,0,0,0.2) 50%,
    rgba(0,0,0,0.1) 100%
  );
  z-index: 1;
}

#home::before {
  content: '';
  position: absolute;
  inset: 0;
  background: #111;
  z-index: 0;
}

.hero-content {
  position: relative;
  z-index: 2;
  padding: 0 2.5rem 4rem;
}

.hero-content h1 {
  font-family: var(--font-display);
  font-weight: var(--font-weight-light);
  font-size: clamp(3.5rem, 9vw, 7.5rem);
  letter-spacing: -0.02em;
  line-height: 0.95;
  color: var(--white);
  margin-bottom: 1.25rem;
}

.hero-role {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.5);
  font-weight: var(--font-weight-regular);
}

/* Scroll indicator */
.hero-scroll {
  position: absolute;
  bottom: 2rem;
  right: 2.5rem;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
}

.scroll-line {
  display: block;
  width: 1px;
  height: 50px;
  background: rgba(255,255,255,0.3);
  position: relative;
  overflow: hidden;
}
.scroll-line::after {
  content: '';
  position: absolute;
  top: -100%;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(255,255,255,0.8);
  animation: scrollDrop 1.8s ease-in-out infinite;
}
@keyframes scrollDrop {
  0%   { top: -100%; }
  100% { top: 200%; }
}

/* ── SHARED SECTION LAYOUT ── */
section:not(#home) {
  background: var(--off-white);
  color: var(--black);
}

.section-wrap {
  max-width: 1200px;
  margin: 0 auto;
  padding: 6rem 2.5rem;
}

.section-label {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-weight: var(--font-weight-regular);
  color: var(--grey-mid);
  margin-bottom: 3.5rem;
}

/* ── ABOUT ── */
#about { border-top: none; }

.about-grid {
  display: grid;
  grid-template-columns: 1fr 1.5fr;
  gap: 6rem;
  align-items: start;
}

.about-photo-wrap {
  position: sticky;
  top: calc(var(--nav-h) + 2rem);
}

.placeholder-img {
  width: 100%;
  aspect-ratio: 3/4;
  background: var(--grey-light);
  overflow: hidden;
}

.about-body p {
  font-family: var(--font-body);
  font-weight: var(--font-weight-light);
  font-size: 0.9rem;
  line-height: 1.85;
  color: var(--grey-dark);
  margin-bottom: 1.25rem;
}

/* ── WORK ── */
#work { border-top: 1px solid var(--grey-light); }

.work-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 3.5rem;
  flex-wrap: wrap;
  gap: 1.5rem;
}

.work-header .section-label { margin-bottom: 0; }

.work-tabs {
  display: flex;
  gap: 0;
  border: 1px solid var(--grey-light);
}

.tab {
  background: none;
  border: none;
  border-right: 1px solid var(--grey-light);
  padding: 0.5rem 1.25rem;
  font-family: var(--font-mono);
  font-size: 0.65rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  font-weight: var(--font-weight-regular);
  color: var(--grey-mid);
  cursor: pointer;
  transition: background 0.2s, color 0.2s;
}
.tab:last-child { border-right: none; }
.tab:hover { color: var(--black); }
.tab.active { background: var(--black); color: var(--white); }

/* Work grid */
.work-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  background: var(--grey-light);
}
.work-grid.hidden { display: none; }

/* Coming soon panel */
.work-coming-soon {
  padding: 4rem 0;
  max-width: 560px;
}
.work-coming-soon.hidden { display: none; }

.coming-soon-lead {
  font-family: var(--font-body);
  font-weight: var(--font-weight-light);
  font-size: 1rem;
  line-height: 1.75;
  color: var(--grey-dark);
  margin-bottom: 1.25rem;
}

.coming-soon-note {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--grey-mid);
}

/* Card */
.card {
  position: relative;
  background: var(--off-white);
  overflow: hidden;
  cursor: pointer;
}

.card-img {
  width: 100%;
  aspect-ratio: 16/9;
  background: var(--grey-light);
  overflow: hidden;
}

.card-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  transition: transform 0.5s ease;
}

.card:hover .card-img img { transform: scale(1.03); }

/* Portrait poster images (e.g. I Am A Killer) — show full image on dark bg */
.card-img--poster {
  background: #111;
}
.card-img--poster img {
  object-fit: contain;
  object-position: center;
}

.card-info {
  padding: 1.25rem 1.5rem 1.5rem;
}

.card-network {
  display: block;
  font-family: var(--font-mono);
  font-size: 0.6rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--grey-mid);
  font-weight: var(--font-weight-regular);
  margin-bottom: 0.5rem;
}

.card h3 {
  font-family: var(--font-body);
  font-weight: var(--font-weight-medium);
  font-size: 1rem;
  line-height: 1.3;
  color: var(--black);
}

/* Card expand / collapse */
.card-details {
  overflow: hidden;
  max-height: 0;
  opacity: 0;
  transition: max-height 0.4s ease, opacity 0.3s ease;
}

.card.expanded .card-details {
  max-height: 220px;
  opacity: 1;
}

.card-meta {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  letter-spacing: 0.04em;
  color: var(--grey-mid);
  line-height: 1.6;
  margin-top: 0.85rem;
  margin-bottom: 0.25rem;
}

.card-genre {
  font-family: var(--font-mono);
  font-size: 0.6rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--grey-mid);
  line-height: 1.6;
}

.card-desc {
  font-family: var(--font-body);
  font-weight: var(--font-weight-light);
  font-size: 0.8rem;
  font-style: italic;
  line-height: 1.6;
  color: var(--grey-dark);
}

.award-tag {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 0.55rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  border: 1px solid currentColor;
  padding: 0.1rem 0.4rem;
  margin-left: 0.3rem;
  vertical-align: middle;
  color: var(--grey-mid);
}

/* Award tag displayed as its own line below the title */
.card-award {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 0.55rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  border: 1px solid var(--grey-mid);
  padding: 0.1rem 0.45rem;
  color: var(--grey-mid);
  margin-top: 0.4rem;
}

/* Watch button */
.card-watch {
  display: inline-block;
  margin-top: 0.85rem;
  background: none;
  border: 1px solid var(--black);
  padding: 0.35rem 0.9rem;
  font-family: var(--font-mono);
  font-size: 0.6rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  cursor: pointer;
  color: var(--black);
  transition: background 0.2s, color 0.2s;
}
.card-watch:hover {
  background: var(--black);
  color: var(--white);
}

/* ── CONTACT ── */
#contact { border-top: 1px solid var(--grey-light); }

.contact-wrap { padding-bottom: 8rem; }

.contact-body {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.contact-link {
  font-family: var(--font-display);
  font-weight: var(--font-weight-light);
  font-size: clamp(1.5rem, 3.5vw, 2.5rem);
  letter-spacing: -0.02em;
  color: var(--black);
  display: block;
  transition: opacity 0.2s;
}
.contact-link:hover { opacity: 0.4; }

.contact-location {
  font-family: var(--font-display);
  font-weight: var(--font-weight-light);
  font-size: clamp(1.5rem, 3.5vw, 2.5rem);
  letter-spacing: -0.02em;
  color: var(--grey-mid);
  display: block;
}

/* ── MODAL ── */
.modal {
  position: fixed;
  inset: 0;
  z-index: 500;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}
.modal.open {
  opacity: 1;
  pointer-events: all;
}

.modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.92);
}

.modal-content {
  position: relative;
  z-index: 1;
  width: min(900px, 92vw);
}

.modal-close {
  position: absolute;
  top: -2.5rem;
  right: 0;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.25rem;
  opacity: 0.6;
  transition: opacity 0.2s;
}
.modal-close:hover { opacity: 1; }

.modal-iframe-wrap {
  position: relative;
  width: 100%;
  aspect-ratio: 16/9;
  background: #000;
}

.modal-iframe-wrap iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: none;
}

/* ── FOOTER ── */
footer {
  background: var(--off-white);
  border-top: 1px solid var(--grey-light);
  padding: 1.5rem 2.5rem;
  font-family: var(--font-mono);
  font-size: 0.65rem;
  letter-spacing: 0.06em;
  color: var(--grey-mid);
}

/* ── RESPONSIVE ── */
@media (max-width: 900px) {
  .work-grid { grid-template-columns: repeat(2, 1fr); }
  .about-grid { grid-template-columns: 1fr; gap: 3rem; }
  .about-photo-wrap { position: static; max-width: 320px; }
}

@media (max-width: 640px) {
  nav { padding: 0 1.5rem; }
  .nav-links { display: none; }
  .nav-toggle { display: flex; }
  .hero-content { padding: 0 1.5rem 3.5rem; }
  .section-wrap { padding: 4rem 1.5rem; }
  .work-grid { grid-template-columns: 1fr; }
  .work-header { flex-direction: column; align-items: flex-start; }
footer { padding: 1.25rem 1.5rem; }
}
