/* Guille Carbonell — site styles */

:root {
  --background: #101010;
  --foreground: #f2efe9;
  --muted-foreground: #908f8c;
  --border: #404040;
  --paper: #f2efe9;
  --ink: #101010;
  --ink-muted: #6d6c6a;
  --frame: #1f1e1c;
  --font: "Helvetica Neue", Helvetica, Arial, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  background: var(--background);
  color: var(--foreground);
  font-family: var(--font);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
h1, h2, h3 { font-weight: inherit; font-size: inherit; }
:focus-visible { outline: 1px solid currentColor; outline-offset: 4px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* Header */
.site-header {
  position: absolute; inset: 0 0 auto; z-index: 20;
  display: flex; justify-content: space-between; align-items: center;
  padding: 32px 3.5%;
}
.wordmark { font-size: 13px; font-weight: 600; line-height: 1.1; }
.site-nav { display: flex; align-items: center; gap: 32px; }
.site-nav a { font-size: 11px; opacity: .7; transition: opacity .25s; }
.site-nav a:hover, .site-nav a[aria-current="page"] { opacity: 1; }
.site-nav a[aria-current="page"]::after {
  content: ""; display: block; height: 1px; margin-top: 5px; background: var(--foreground);
}
.lang-switch { margin-left: 8px; font-size: 11px; color: rgba(242, 239, 233, .45); }
.site-nav .lang-switch a { opacity: .7; }
.site-nav .lang-switch a:hover { opacity: 1; }
.lang-switch span { color: var(--foreground); }
.mobile-menu-button { display: none; width: 32px; height: 32px; align-items: center; justify-content: center; }
.mobile-menu-button span, .mobile-menu-button span::before {
  display: block; width: 22px; height: 1px; background: currentColor; position: relative; transition: transform .3s;
}
.mobile-menu-button span::before { content: ""; position: absolute; top: 7px; }
.mobile-menu-button[aria-expanded="true"] span { transform: translateY(3px) rotate(45deg); }
.mobile-menu-button[aria-expanded="true"] span::before { transform: translateY(-7px) rotate(-90deg); }

/* Hero */
.hero {
  position: relative; overflow: hidden;
  height: min(860px, 92svh); min-height: 650px;
  background: var(--frame);
  container-type: size;
}
.hero-video { position: absolute; inset: 0; pointer-events: none; }
.hero-video iframe {
  position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%);
  width: max(100cqw, 177.78cqh); height: auto; aspect-ratio: 16 / 9; border: 0;
}
.hero-scrim { position: absolute; inset: 0; background: var(--ink); opacity: .26; }
.hero-title { position: absolute; bottom: 145px; left: 3.5%; right: 3.5%; }
.hero-title h1 { font-size: 112px; font-weight: 500; line-height: .96; letter-spacing: 0; }
.hero-title .director { margin-top: 20px; font-size: 13px; letter-spacing: .22em; text-transform: uppercase; }
.hero-bottom {
  position: absolute; bottom: 38px; left: 3.5%; right: 3.5%;
  display: flex; justify-content: space-between; align-items: end;
  font-size: 10px; line-height: 1.7; text-transform: uppercase;
}

/* Play button */
.reel-button { display: inline-flex; align-items: center; gap: 14px; font-size: 10px; letter-spacing: .1em; text-transform: uppercase; }
.reel-button:hover { opacity: .7; }
.play-circle {
  width: 48px; height: 48px; display: flex; align-items: center; justify-content: center;
  border: 1px solid rgba(242, 239, 233, .65); border-radius: 50%; transition: transform .3s;
}
.reel-button:hover .play-circle { transform: scale(1.08); }

/* Sections */
.content-section { padding: 90px 3.5% 100px; }
.content-section.pt-0 { padding-top: 0; }
.section-top { display: flex; justify-content: space-between; align-items: center; gap: 25px; margin-bottom: 43px; }
.eyebrow { font-size: 10px; letter-spacing: .1em; text-transform: uppercase; }
.section-heading { font-size: 46px; font-weight: 400; line-height: 1.1; }
.text-link { display: inline-flex; align-items: center; gap: 15px; font-size: 10px; letter-spacing: .07em; text-transform: uppercase; }
.text-link svg { transition: transform .3s; }
.text-link:hover svg { transform: translate(2px, -2px); }

/* Work grids */
.work-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 48px 24px; }
.work-grid > .work-item:nth-child(3n+1) { grid-column: 1 / -1; }
.work-item { display: block; }
.work-frame { position: relative; overflow: hidden; aspect-ratio: 16 / 9; background: var(--frame); }
.work-grid > .work-item:nth-child(3n+1) .work-frame { aspect-ratio: 2.39; }
.work-frame img { width: 100%; height: 100%; object-fit: cover; transition: transform .65s, opacity .4s; }
.work-item:hover img { opacity: .9; transform: scale(1.025); }
.work-play {
  position: absolute; inset: 0; display: flex; align-items: center; justify-content: center;
  opacity: 0; transition: opacity .35s;
}
.work-play .play-circle { width: 64px; height: 64px; background: rgba(16, 16, 16, .25); }
.work-item a:hover .work-play, .work-item a:focus-visible .work-play { opacity: 1; }
@media (hover: none) { .work-play { opacity: 1; } .work-play .play-circle { width: 44px; height: 44px; } }
.asset-placeholder {
  height: 100%; display: flex; flex-direction: column; justify-content: center; align-items: center; gap: 12px;
  color: var(--muted-foreground);
}
.asset-placeholder span { font-size: 10px; letter-spacing: .15em; text-transform: uppercase; }
.project-caption { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; padding-top: 15px; }
.project-caption h3 { font-size: 12px; font-weight: 500; text-transform: uppercase; }
.project-caption p { font-size: 10px; color: var(--muted-foreground); text-align: right; }
.film-status { margin-top: 20px; color: var(--muted-foreground); }

/* Paper (light) section */
.paper-section { background: var(--paper); color: var(--ink); }
.paper-section .work-frame { background: #e3dfd7; }
.paper-section .asset-placeholder { color: var(--ink-muted); }
.paper-section .project-caption p, .paper-section .film-status { color: var(--ink-muted); }
.narrative-intro { display: flex; justify-content: space-between; gap: 40px; margin: 38px 0 60px; }
.narrative-intro h2 { max-width: 700px; font-size: 70px; font-weight: 400; line-height: 1.02; }
.narrative-intro p { align-self: end; max-width: 290px; font-size: 13px; line-height: 1.8; }
.film-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 45px 24px; }
.film-grid .work-frame { aspect-ratio: 2; }

/* Bio */
.bio-layout { display: grid; grid-template-columns: 1fr 1fr; align-items: center; gap: 9%; }
.portrait { aspect-ratio: 4 / 5; overflow: hidden; background: var(--frame); }
.portrait img { width: 100%; height: 100%; object-fit: cover; object-position: 32% 50%; filter: grayscale(1); }
.bio-copy .eyebrow { display: block; margin-bottom: 30px; }
.bio-copy p { margin-bottom: 1.2em; font-size: 14px; line-height: 1.85; color: var(--muted-foreground); }
.bio-copy p.lead { font-size: 22px; line-height: 1.45; color: var(--foreground); }
.bio-links { display: flex; gap: 35px; margin-top: 32px; }

/* Contact band + footer */
.contact-band { padding: 80px 3.5% 45px; background: var(--paper); color: var(--ink); }
.contact-band h2 { margin: 25px 0 45px; font-size: 114px; font-weight: 400; line-height: 1; }
.contact-row { display: flex; justify-content: space-between; gap: 30px; font-size: 12px; }
.contact-row .place { margin-top: 16px; font-size: 12px; }
.contact-socials { display: flex; flex-wrap: wrap; gap: 24px; }
.contact-socials a:hover { opacity: .6; }
.reveal-email {
  display: inline-flex; align-items: center; gap: 12px; padding: 0;
  font-size: 10px; letter-spacing: .07em; text-transform: uppercase; opacity: .75;
}
.reveal-email::after { content: ""; width: 22px; height: 1px; background: currentColor; opacity: .5; transition: width .3s; }
.reveal-email:hover { opacity: 1; }
.reveal-email:hover::after { width: 34px; }
.contact-email { display: inline-flex; flex-wrap: wrap; align-items: center; gap: 16px; font-size: 12px; }
.contact-email a { border-bottom: 1px solid; padding-bottom: 2px; }
.copy-email { font-size: 9px; letter-spacing: .07em; text-transform: uppercase; opacity: .55; }
.copy-email:hover { opacity: 1; }
.footer { display: flex; justify-content: space-between; gap: 15px; margin-top: 85px; font-size: 9px; opacity: .55; text-transform: uppercase; }

/* Inner pages */
.page-top { padding: 165px 3.5% 55px; }
.page-title { margin: 25px 0; font-size: 88px; font-weight: 400; line-height: 1; }
.page-description { max-width: 580px; font-size: 14px; line-height: 1.8; color: var(--muted-foreground); }
.detail-image { aspect-ratio: 2.39; margin: 0 3.5%; overflow: hidden; background: var(--frame); position: relative; }
.detail-image img { width: 100%; height: 100%; object-fit: cover; }
.detail-image .play-overlay {
  position: absolute; inset: 0; display: flex; align-items: center; justify-content: center;
  background: rgba(16, 16, 16, .15); transition: background .3s;
}
.detail-image .play-overlay:hover { background: rgba(16, 16, 16, .3); }
.detail-image .play-overlay .play-circle { width: 72px; height: 72px; }
.detail-info { display: grid; grid-template-columns: 1fr 2fr; gap: 60px; padding: 65px 3.5% 90px; }
.detail-info dt { margin-bottom: 8px; font-size: 10px; text-transform: uppercase; opacity: .6; }
.detail-info dd { margin: 0 0 25px; font-size: 13px; }
.detail-info .reel-button { margin-top: 10px; }
.detail-copy h2 { margin: 0 0 20px; font-size: 28px; font-weight: 400; }
.detail-copy p { margin-bottom: 40px; font-size: 14px; line-height: 1.8; color: var(--muted-foreground); }
.detail-copy .still { width: 100%; margin-bottom: 24px; }
.detail-copy .text-link { margin-top: 10px; }
.project-nav { display: flex; justify-content: space-between; gap: 20px; padding: 0 3.5% 90px; }

/* Video popup */
.popup-player {
  position: fixed; inset: 0; z-index: 60;
  display: flex; align-items: center; justify-content: center;
  padding: 60px 4vw; background: rgba(8, 8, 8, .94);
  opacity: 0; visibility: hidden; transition: opacity .3s, visibility .3s;
}
.popup-player.open { opacity: 1; visibility: visible; }
.popup-frame { width: min(1400px, 100%); max-height: 100%; aspect-ratio: 16 / 9; background: #000; }
.popup-frame iframe { display: block; width: 100%; height: 100%; border: 0; }
.player-close {
  position: absolute; top: 18px; right: 18px; z-index: 5;
  width: 44px; height: 44px; font-size: 26px; line-height: 1; opacity: .8;
}
.player-close:hover { opacity: 1; }
body.no-scroll { overflow: hidden; }

/* Scroll reveal (only when JS is running) */
.js .reveal { opacity: 0; transform: translateY(24px); transition: opacity .9s ease, transform .9s ease; }
.js .reveal.is-visible { opacity: 1; transform: none; }

@media (min-width: 1600px) {
  .hero-title h1 { font-size: 145px; }
}

@media (max-width: 900px) {
  .hero-title h1 { font-size: 78px; }
  .site-nav { gap: 20px; }
  .hero { min-height: 600px; }
  .narrative-intro h2 { font-size: 52px; }
  .contact-band h2 { font-size: 85px; }
  .page-title { font-size: 68px; }
}

@media (max-width: 600px) {
  .site-header { padding: 25px 6%; }
  .mobile-menu-button { display: inline-flex; }
  .site-nav { display: none; }
  .site-nav.mobile-open {
    display: flex; flex-direction: column; align-items: flex-start; gap: 24px;
    position: absolute; top: 80px; left: 0; right: 0; padding: 30px 6%;
    background: var(--background);
  }
  .site-nav.mobile-open a { font-size: 14px; }
  .hero { height: 85svh; min-height: 560px; }
  .hero-title { bottom: 160px; left: 6%; right: 6%; }
  .hero-title h1 { max-width: 340px; font-size: 55px; line-height: 1.03; }
  .hero-title .director { font-size: 11px; }
  .hero-bottom { bottom: 28px; left: 6%; right: 6%; font-size: 8px; }
  .play-circle { width: 36px; height: 36px; }
  .content-section { padding: 60px 6%; }
  .section-top { align-items: end; margin-bottom: 30px; }
  .section-heading { font-size: 32px; }
  .section-top .text-link { gap: 6px; font-size: 8px; }
  .work-grid, .film-grid { grid-template-columns: 1fr; gap: 30px; }
  .work-grid > .work-item:nth-child(3n+1) { grid-column: auto; }
  .work-grid > .work-item:nth-child(3n+1) .work-frame { aspect-ratio: 16 / 9; }
  .project-caption { gap: 10px; }
  .project-caption h3 { font-size: 10px; }
  .project-caption p { font-size: 9px; }
  .narrative-intro { flex-direction: column; gap: 15px; margin: 30px 0 35px; }
  .narrative-intro h2 { font-size: 43px; }
  .narrative-intro p { align-self: flex-start; max-width: 100%; }
  .bio-layout { grid-template-columns: 1fr; gap: 35px; }
  .portrait { max-height: 420px; }
  .bio-copy p.lead { font-size: 18px; }
  .contact-band { padding: 55px 6% 28px; }
  .contact-band h2 { font-size: 63px; }
  .contact-row { flex-direction: column; gap: 28px; }
  .contact-socials { gap: 20px; font-size: 11px; }
  .footer { margin-top: 65px; font-size: 8px; }
  .page-top { padding: 130px 6% 35px; }
  .page-title { font-size: 52px; }
  .detail-image { aspect-ratio: 16 / 9; margin: 0 6%; }
  .detail-info { grid-template-columns: 1fr; gap: 20px; padding: 40px 6% 60px; }
  .project-nav { padding: 0 6% 60px; }
  .popup-player { padding: 60px 0; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; animation: none !important; }
  .js .reveal { opacity: 1; transform: none; }
}
