/* Matt Eddy — personal site */

:root {
  --ink: #212121;
  --ink-soft: #5a5a5a;
  --ink-faint: #9a9a9a;
  --paper: #ffffff;
  --line: #e5e5e5;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
  font-family: "Lato", -apple-system, BlinkMacSystemFont, "Helvetica Neue", Helvetica, Arial, sans-serif;
  background: var(--paper);
  color: var(--ink);
  line-height: 1.6667;
  font-size: 11pt;
  -webkit-font-smoothing: antialiased;
}

a { color: var(--ink); }
a:hover { color: var(--ink-soft); }

/* ===== Page shell — NYT-style width ===== */

header, main, footer {
  max-width: 1200px;
  margin-left: auto;
  margin-right: auto;
  padding-left: 24px;
  padding-right: 24px;
}

/* ===== Top nav — right-justified, sentence case, no borders ===== */

header {
  padding-top: 28px;
}

nav ul {
  list-style: none;
  display: flex;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 6px 26px;
}

nav a {
  text-decoration: none;
  font-size: 12pt;
  font-weight: 300;
  color: var(--ink-soft);
}

nav a:hover { color: var(--ink); }

nav a.current {
  color: var(--ink);
  font-weight: 600;
}

/* ===== Site name — left, top of body ===== */

.site-name {
  font-size: 30pt;
  font-weight: 300;
  letter-spacing: 0.01em;
  margin-bottom: 6px;
}

.site-name a {
  text-decoration: none;
  color: var(--ink);
}

/* ===== Content ===== */

main {
  padding-top: 28px;
  padding-bottom: 80px;
}

.content {
  margin-top: 44px;
}

/* Home */

.home-grid {
  display: grid;
  grid-template-columns: 300px 1fr;
  gap: 56px;
  align-items: start;
}

.home-grid img {
  width: 100%;
  display: block;
}

.bio p {
  margin-bottom: 18px;
  font-size: 11pt;
  font-weight: 400;
  line-height: 1.6667;
  max-width: 640px;
}

/* Poster grids */

.poster-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}

.poster-grid.three {
  grid-template-columns: repeat(3, 1fr);
  max-width: 860px;
}

.poster-grid img {
  width: 100%;
  aspect-ratio: 2 / 3;
  object-fit: cover;
  display: block;
  box-shadow: 0 1px 4px rgba(0,0,0,0.12);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.poster-grid img:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 24px rgba(0,0,0,0.18);
}

/* Video grid */

.video-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
}

.video-grid .video {
  position: relative;
  aspect-ratio: 16 / 9;
  background: #000;
}

.video-grid iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

/* Teaching */

.teaching-block img {
  width: 100%;
  max-width: 400px;
  display: block;
}

/* Contact */

.contact-block .email {
  font-size: 12pt;
  font-weight: 700;
  margin-bottom: 44px;
}

.contact-block h2 {
  font-size: 12pt;
  font-weight: 700;
  color: var(--ink);
  margin-bottom: 2px;
}

.contact-block .rep {
  margin-bottom: 30px;
  font-weight: 400;
  font-size: 11pt;
  line-height: 1.6;
}

.social {
  display: flex;
  gap: 17px;
  margin: 0 0 56px;
}

.social a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  text-decoration: none;
  color: #fff;
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.social a:hover {
  opacity: 0.85;
  transform: translateY(-2px);
}

.social a.x { background: #000000; }
.social a.instagram { background: #E4405F; }
.social a.facebook { background: #1877F2; }
.social a.imdb { background: #D6A411; }

.social svg {
  width: 16px;
  height: 16px;
  fill: currentColor;
}

/* ===== Footer ===== */

footer {
  border-top: 1px solid var(--line);
  padding-top: 20px;
  padding-bottom: 28px;
  font-size: 9pt;
  letter-spacing: 0.05em;
  color: var(--ink-faint);
}

footer a {
  color: var(--ink-faint);
}

/* ===== Mobile ===== */

@media (max-width: 760px) {
  header { padding-top: 20px; }
  .site-name { font-size: 27pt; }
  nav ul { gap: 4px 18px; }
  main { padding-top: 24px; padding-bottom: 56px; }
  .content { margin-top: 32px; }
  .home-grid {
    grid-template-columns: 1fr;
    gap: 32px;
  }
  .home-grid img {
    max-width: 280px;
  }
  .poster-grid { grid-template-columns: repeat(2, 1fr); gap: 16px; }
  .poster-grid.three { grid-template-columns: repeat(2, 1fr); }
  .video-grid { grid-template-columns: 1fr; }
}
