/* ─────────────────────────────────────────────
   Saleno Portfolio
   Dark & cinematic. Two typefaces, one accent.
   ───────────────────────────────────────────── */

:root {
  --bg:        #0a0a0b;
  --bg-soft:   #111114;
  --fg:        #f4efe6;
  --fg-dim:    #a9a39a;
  --fg-faint:  #5a554f;
  --accent:    #e8c39c;     /* warm cream */
  --border:    rgba(244, 239, 230, 0.08);

  --serif:     "Fraunces", "Times New Roman", serif;
  --sans:      "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;

  --max:       1280px;
  --pad:       clamp(1.25rem, 4vw, 2.5rem);

  --ease:      cubic-bezier(0.2, 0.7, 0.2, 1);
}

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

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--fg);
  font-family: var(--sans);
  font-weight: 300;
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

a {
  color: inherit;
  text-decoration: none;
  transition: color 0.25s var(--ease), opacity 0.25s var(--ease);
}
a:hover { color: var(--accent); }

img, video, iframe { max-width: 100%; display: block; }

/* ─────────── HEADER ─────────── */
.site-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 50;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1.1rem var(--pad);
  background: linear-gradient(to bottom, rgba(10,10,11,0.85), rgba(10,10,11,0));
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}
.wordmark {
  font-family: var(--serif);
  font-weight: 400;
  font-size: 1.15rem;
  letter-spacing: 0.02em;
}
.site-nav {
  display: flex;
  gap: 1.75rem;
}
.site-nav a {
  font-size: 0.82rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--fg-dim);
}
.site-nav a:hover { color: var(--fg); }

@media (max-width: 640px) {
  .site-nav { gap: 1rem; }
  .site-nav a { font-size: 0.72rem; letter-spacing: 0.06em; }
}

/* ─────────── HERO ─────────── */
.hero {
  min-height: 92vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
  padding: 0 var(--pad);
  max-width: var(--max);
  margin: 0 auto;
  position: relative;
}
/* Full-bleed Gargantua background.
   The pseudo-element breaks out of the hero's max-width via 100vw + translateX,
   so the image spans the entire viewport width while the text content stays
   within the centered content column. A dark vertical gradient sits on top so
   the type reads cleanly and the image fades smoothly into the dark page. */
.hero::before {
  content: "";
  position: absolute;
  top: 0;
  left: 50%;
  width: 100vw;
  height: 100%;
  transform: translateX(-50%);
  background-image:
    linear-gradient(
      to bottom,
      rgba(10, 10, 11, 0.35) 0%,
      rgba(10, 10, 11, 0.55) 55%,
      rgba(10, 10, 11, 1)    100%
    ),
    url("assets/photos/HHMziGPaYAAeSfR.jpg");
  background-size: cover;
  background-position: 60% center;
  background-repeat: no-repeat;
  pointer-events: none;
  z-index: -1;
}
.hero-name {
  font-family: var(--serif);
  font-weight: 300;
  font-size: clamp(4rem, 14vw, 12rem);
  line-height: 0.9;
  letter-spacing: -0.03em;
  font-style: italic;
  margin-bottom: 1.5rem;
}
.hero-tagline {
  font-family: var(--serif);
  font-weight: 300;
  font-size: clamp(1.1rem, 2vw, 1.5rem);
  color: var(--fg);
  max-width: 32ch;
  margin-bottom: 3rem;
}
.hero-meta {
  font-size: 0.78rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--fg-faint);
}

/* ─────────── SECTIONS ─────────── */
.section {
  max-width: var(--max);
  margin: 0 auto;
  padding: 6rem var(--pad) 2rem;
  border-top: 1px solid var(--border);
}
.section-head {
  margin-bottom: 3rem;
  display: flex;
  align-items: baseline;
  gap: 1.5rem;
  flex-wrap: wrap;
}
.section-head h2 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(1.5rem, 3vw, 2.25rem);
  letter-spacing: -0.01em;
}
.section-head p {
  color: var(--fg-dim);
  font-size: 0.95rem;
}

/* ─────────── SHOWREEL (Stage + Strip) ─────────── */
.showreel {
  display: flex;
  flex-direction: column;
  gap: 1.75rem;
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.8s var(--ease), transform 0.8s var(--ease);
}
.showreel.in-view {
  opacity: 1;
  transform: translateY(0);
}

/* Stage: the featured video, large 16:9 */
.showreel-stage {
  position: relative;
  aspect-ratio: 16 / 9;
  background: var(--bg-soft);
  overflow: hidden;
  border-radius: 2px;
  cursor: pointer;
  transition: opacity 0.3s var(--ease);
}
.showreel-stage.is-swapping {
  opacity: 0;
}
.showreel-stage img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: brightness(0.82);
  transition: filter 0.4s var(--ease), transform 0.7s var(--ease);
}
.showreel-stage:hover img {
  filter: brightness(1);
  transform: scale(1.015);
}
.showreel-stage iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}
.showreel-stage-gradient {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 45%;
  background: linear-gradient(to top, rgba(8, 8, 9, 0.9) 0%, rgba(8, 8, 9, 0) 100%);
  pointer-events: none;
  z-index: 1;
}
.showreel-stage-title {
  position: absolute;
  bottom: 1.5rem;
  left: 1.75rem;
  z-index: 2;
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(1.1rem, 2vw, 1.65rem);
  letter-spacing: -0.01em;
  color: var(--fg);
  pointer-events: none;
  max-width: 70%;
}
.showreel-stage-year {
  position: absolute;
  bottom: 1.85rem;
  right: 1.75rem;
  z-index: 2;
  font-size: 0.78rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--fg-dim);
  pointer-events: none;
}

/* Strip wrapper: holds the scroll area and the nav arrows */
.showreel-strip-wrap {
  position: relative;
}

/* Minimalist chevron buttons floating over the strip edges */
.showreel-nav {
  position: absolute;
  top: calc(50% - 18px); /* Nudge up so the button centers on the thumb image,
                            not on the (image + meta) combo */
  transform: translateY(-50%);
  z-index: 5;
  width: 42px;
  height: 42px;
  padding: 0;
  margin: 0;
  border-radius: 50%;
  background: rgba(10, 10, 11, 0.7);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border: 1px solid rgba(244, 239, 230, 0.08);
  color: var(--fg);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity 0.3s var(--ease),
              background 0.3s var(--ease),
              border-color 0.3s var(--ease),
              color 0.3s var(--ease);
}
.showreel-nav:hover:not(:disabled) {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--bg);
}
.showreel-nav:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}
.showreel-nav:disabled {
  opacity: 0.2;
  cursor: default;
  pointer-events: none;
}
.showreel-nav-left  { left:  -10px; }
.showreel-nav-right { right: -10px; }

@media (max-width: 720px) {
  .showreel-nav {
    width: 36px;
    height: 36px;
  }
  .showreel-nav-left  { left:  4px; }
  .showreel-nav-right { right: 4px; }
}

/* Strip: the horizontal carousel of other videos */
.showreel-strip {
  display: flex;
  gap: 1rem;
  overflow-x: auto;
  overflow-y: hidden;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  padding-bottom: 0.75rem;
  -webkit-overflow-scrolling: touch;
}
.showreel-strip::-webkit-scrollbar {
  height: 4px;
}
.showreel-strip::-webkit-scrollbar-track {
  background: rgba(244, 239, 230, 0.04);
  border-radius: 2px;
}
.showreel-strip::-webkit-scrollbar-thumb {
  background: rgba(244, 239, 230, 0.14);
  border-radius: 2px;
}
.showreel-strip::-webkit-scrollbar-thumb:hover {
  background: rgba(244, 239, 230, 0.22);
}

.showreel-thumb {
  flex: 0 0 auto;
  width: clamp(180px, 22vw, 260px);
  cursor: pointer;
  scroll-snap-align: start;
  transition: transform 0.3s var(--ease);
}
.showreel-thumb:hover {
  transform: translateY(-3px);
}
.showreel-thumb-img {
  position: relative;
  aspect-ratio: 16 / 9;
  background: var(--bg-soft);
  overflow: hidden;
  border-radius: 2px;
}
.showreel-thumb-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: brightness(0.72);
  transition: filter 0.3s var(--ease);
}
.showreel-thumb:hover .showreel-thumb-img img {
  filter: brightness(1);
}

@media (max-width: 720px) {
  .showreel-thumb {
    width: 160px;
  }
}

/* ─────────── play-icon (shared by Stage and Shorts) ─────────── */
.play-icon {
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  width: 64px; height: 64px;
  border-radius: 50%;
  background: rgba(10, 10, 11, 0.6);
  backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.3s var(--ease), transform 0.3s var(--ease);
  pointer-events: none;
  z-index: 2;
}
.showreel-stage .play-icon {
  width: 88px;
  height: 88px;
}
.showreel-stage:hover .play-icon,
.shorts-card:hover .play-icon {
  background: var(--accent);
  transform: translate(-50%, -50%) scale(1.08);
}
.play-icon::after {
  content: "";
  width: 0; height: 0;
  border-style: solid;
  border-width: 10px 0 10px 16px;
  border-color: transparent transparent transparent var(--fg);
  margin-left: 4px;
  transition: border-color 0.3s var(--ease);
}
.showreel-stage .play-icon::after {
  border-width: 14px 0 14px 22px;
  margin-left: 6px;
}
.showreel-stage:hover .play-icon::after,
.shorts-card:hover .play-icon::after {
  border-color: transparent transparent transparent var(--bg);
}

/* ─────────── video-meta (shared by Shorts cards) ─────────── */
.video-meta {
  margin-top: 0.85rem;
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 0.65rem;
}
.video-title {
  font-family: var(--serif);
  font-weight: 400;
  font-size: 1rem;
  letter-spacing: 0;
}
.video-year {
  font-size: 0.74rem;
  letter-spacing: 0.12em;
  color: var(--fg-faint);
}

/* ─────────── SHORTS GRID (vertical 9:16) ─────────── */
.shorts-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 280px));
  gap: 2.5rem 2rem;
  justify-content: center;
}
.shorts-card {
  cursor: pointer;
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.8s var(--ease), transform 0.8s var(--ease);
}
.shorts-card.in-view {
  opacity: 1;
  transform: translateY(0);
}
.shorts-thumb {
  position: relative;
  aspect-ratio: 9 / 16;
  background: var(--bg-soft);
  overflow: hidden;
  border-radius: 2px;
}
.shorts-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s var(--ease), filter 0.6s var(--ease);
  filter: brightness(0.85);
}
.shorts-card:hover .shorts-thumb img {
  transform: scale(1.03);
  filter: brightness(1);
}
.shorts-thumb iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}
.shorts-card .play-icon {
  width: 52px;
  height: 52px;
}
.shorts-card .play-icon::after {
  border-width: 8px 0 8px 13px;
}

/* ─────────── PHOTO GRID (editorial mix) ───────────
   Two-column grid by default. Photos marked .is-hero
   span the full content width for emphasis. Source
   photos are shown in their natural landscape ratio
   so nothing is cropped. */
.photo-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.25rem;
  align-items: start;
}
.photo-card {
  grid-column: span 1;
  cursor: zoom-in;
  overflow: hidden;
  background: var(--bg-soft);
  border-radius: 2px;
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.8s var(--ease), transform 0.8s var(--ease);
}
.photo-card.in-view {
  opacity: 1;
  transform: translateY(0);
}
.photo-card img {
  width: 100%;
  height: auto;
  display: block;
  transition: transform 0.6s var(--ease), filter 0.6s var(--ease);
  filter: brightness(0.9);
}
.photo-card:hover img {
  transform: scale(1.02);
  filter: brightness(1);
}

/* Heroes: break out and take the full row */
.photo-card.is-hero {
  grid-column: 1 / -1;
}

/* Mobile: collapse to single column so heroes and pairs alike read full-width */
@media (max-width: 720px) {
  .photo-grid {
    grid-template-columns: 1fr;
    gap: 1rem;
  }
}

/* ─────────── ABOUT ─────────── */
.about-body {
  max-width: 60ch;
  font-family: var(--serif);
  font-weight: 300;
  font-size: 1.15rem;
  line-height: 1.6;
  color: var(--fg);
}
.about-body p + p { margin-top: 1.25rem; }

/* ─────────── CONTACT ─────────── */
.contact-list {
  list-style: none;
  display: grid;
  gap: 0.85rem;
}
.contact-list li {
  display: grid;
  grid-template-columns: 120px 1fr;
  align-items: baseline;
  padding-bottom: 0.85rem;
  border-bottom: 1px solid var(--border);
  max-width: 480px;
}
.contact-list .label {
  font-size: 0.78rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--fg-faint);
}
.contact-list a {
  font-family: var(--serif);
  font-weight: 400;
  font-size: 1.1rem;
}

/* ─────────── FOOTER ─────────── */
.site-footer {
  margin-top: 6rem;
  padding: 2rem var(--pad) 3rem;
  text-align: center;
  font-size: 0.78rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--fg-faint);
}

/* ─────────── LIGHTBOX ─────────── */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 100;
  background: rgba(8, 8, 9, 0.96);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 4rem var(--pad);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.35s var(--ease);
}
.lightbox.open {
  opacity: 1;
  pointer-events: auto;
}
.lightbox-img {
  max-width: min(1100px, 100%);
  max-height: 82vh;
  width: auto;
  height: auto;
  object-fit: contain;
  border-radius: 2px;
}
.lightbox-caption {
  margin-top: 1.25rem;
  font-family: var(--serif);
  font-size: 0.95rem;
  color: var(--fg-dim);
  text-align: center;
}
.lightbox-close {
  position: absolute;
  top: 1.5rem;
  right: 1.5rem;
  width: 44px;
  height: 44px;
  border: 0;
  background: transparent;
  color: var(--fg);
  font-size: 2rem;
  line-height: 1;
  cursor: pointer;
  opacity: 0.7;
  transition: opacity 0.25s var(--ease);
}
.lightbox-close:hover { opacity: 1; }

/* ─────────── REDUCED MOTION ─────────── */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
  html { scroll-behavior: auto; }
  .video-card, .photo-card { opacity: 1; transform: none; }
}
