/* ============================================================
   MATÍAS FUENZALIDA — Director · Writer · Screenwriter
   ============================================================ */

:root{
  /* base */
  --black:      #050403;
  --black-2:    #070504;
  --coffee:     #241611;
  --coffee-2:   #3a2214;
  --amber:      #b4661f;
  --amber-hot:  #d08434;
  --cream:      #e8e1d6;

  /* ink */
  --ink:        rgba(232,225,214,.92);
  --ink-2:      rgba(232,225,214,.62);
  --ink-3:      rgba(232,225,214,.38);
  --ink-4:      rgba(232,225,214,.16);
  --hair:       rgba(232,225,214,.13);

  /* type */
  --sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Helvetica Neue', Helvetica, Arial, sans-serif;
  --mono: ui-monospace, 'SF Mono', SFMono-Regular, 'Roboto Mono', Menlo, Consolas, monospace;

  /* motion */
  --ease: cubic-bezier(.22,1,.36,1);
  --ease-io: cubic-bezier(.65,0,.35,1);

  /* layout */
  --pad: clamp(1.25rem, 4.5vw, 4.5rem);
  --pad-t: clamp(1.1rem, 2.4vw, 2.1rem);
}

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

html{ background:var(--black); -webkit-text-size-adjust:100%; overflow-x:hidden; }

html:not(.no-smooth){ scroll-behavior:smooth; }

body{
  font-family:var(--sans);
  font-weight:300;
  color:var(--ink);
  background:var(--black);
  line-height:1.5;
  overflow-x:hidden;
  -webkit-font-smoothing:antialiased;
  -moz-osx-font-smoothing:grayscale;
  text-rendering:optimizeLegibility;
}

body.is-locked{ overflow:hidden; }
html:has(body.is-locked){ overflow:hidden; }

img,svg,picture{ display:block; max-width:100%; }
ul{ list-style:none; }
a{ color:inherit; text-decoration:none; }
button{ font:inherit; color:inherit; background:none; border:0; cursor:pointer; }

::selection{ background:var(--amber); color:#0a0705; }

:focus-visible{
  outline:1px solid var(--amber-hot);
  outline-offset:6px;
}

.skip{
  position:fixed; top:-100px; left:var(--pad); z-index:200;
  padding:.7rem 1.1rem; font-size:.7rem; letter-spacing:.18em;
  text-transform:uppercase; background:var(--cream); color:#0a0705;
}
.skip:focus{ top:1rem; }

/* ─────────── film grain + vignette ─────────── */

.grain{
  position:fixed; inset:-150%;
  z-index:90; pointer-events:none;
  opacity:.055;
  background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='260' height='260'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  animation:grain 1.1s steps(6) infinite;
  will-change:transform;
}
@keyframes grain{
  0%  { transform:translate3d(0,0,0) }
  20% { transform:translate3d(-3%,2%,0) }
  40% { transform:translate3d(2%,-3%,0) }
  60% { transform:translate3d(-2%,-2%,0) }
  80% { transform:translate3d(3%,1%,0) }
  100%{ transform:translate3d(0,0,0) }
}

.vignette{
  position:fixed; inset:0; z-index:89; pointer-events:none;
  background:radial-gradient(120% 90% at 50% 50%, transparent 42%, rgba(0,0,0,.42) 100%);
}

/* opening curtain */
.curtain{
  position:fixed; inset:0; z-index:150;
  background:var(--black);
  pointer-events:none;
  transition:opacity 1s var(--ease);
}
body.is-ready .curtain{ opacity:0; }

/* ─────────── masked line reveal ─────────── */

.mask{ display:block; overflow:hidden; padding-bottom:.06em; }
.mask__i{
  display:block;
  transform:translate3d(0,110%,0);
  transition:transform 1.15s var(--ease);
}

/* ============================================================
   HEADER
   ============================================================ */

.head{
  position:fixed; top:0; left:0; right:0; z-index:80;
  display:flex; align-items:center; justify-content:space-between;
  padding:var(--pad-t) var(--pad);
  padding-top:max(var(--pad-t), env(safe-area-inset-top));
  opacity:0;
  transition:opacity 1.4s var(--ease) .9s;
}
/* keeps the header legible over bright frames without a solid bar */
.head::before{
  content:''; position:absolute; inset:0; z-index:-1;
  background:linear-gradient(to bottom, rgba(5,4,3,.62), transparent);
  pointer-events:none;
}
body.is-ready .head{ opacity:1; }
body.is-open .head{ opacity:0; transition-delay:0s; transition-duration:.35s; pointer-events:none; }

.head__mark{
  font-size:.72rem; font-weight:400;
  letter-spacing:.3em; text-transform:uppercase;
  color:var(--cream);
}

.head__idx{
  font-family:var(--mono);
  font-size:.62rem; letter-spacing:.24em;
  color:var(--cream); opacity:0;
  transition:opacity .8s var(--ease);
}
.head__idx.on{ opacity:.55; }

.head__menu{
  display:flex; align-items:center; gap:.75rem;
  font-size:.72rem; letter-spacing:.3em; text-transform:uppercase;
  color:var(--cream);
}
.head__bars{ display:block; width:22px; }
.head__bars i{
  display:block; height:1px; background:var(--cream);
  transform-origin:right;
  transition:transform .7s var(--ease);
}
.head__bars i:last-child{ margin-top:5px; transform:scaleX(.55); }
.head__menu:hover .head__bars i:last-child{ transform:scaleX(1); }
.head__menu:hover .head__bars i:first-child{ transform:scaleX(.55); }

@media (max-width:640px){
  .head__idx{ display:none; }
  .head__bars{ display:none; }
}

/* ============================================================
   MENU OVERLAY
   ============================================================ */

.overlay{
  position:fixed; inset:0; z-index:120;
  display:flex; flex-direction:column; justify-content:center;
  padding:var(--pad);
  padding-top:max(var(--pad), env(safe-area-inset-top));
  padding-bottom:max(var(--pad), env(safe-area-inset-bottom));
  opacity:0; visibility:hidden;
  transition:opacity .75s var(--ease), visibility 0s linear .75s;
}
body.is-open .overlay{
  opacity:1; visibility:visible;
  transition:opacity .8s var(--ease), visibility 0s;
}

.overlay__bg{
  position:absolute; inset:0; z-index:-1;
  background:
    radial-gradient(64% 86% at 112% 54%, rgba(224,146,58,.55) 0%, rgba(176,98,28,.26) 24%, transparent 56%),
    radial-gradient(90% 70% at 88% 108%, rgba(5,4,3,.9) 0%, rgba(5,4,3,.4) 38%, transparent 70%),
    radial-gradient(80% 100% at 4% 44%, rgba(0,0,0,.92) 0%, rgba(0,0,0,.5) 34%, transparent 68%),
    linear-gradient(102deg, #020101 0%, #050403 26%, #120b06 48%, #2b190c 70%, #5d3311 88%, #8a4d15 100%);
  transform:scale(1.06);
  filter:blur(14px);
  opacity:0;
  transition:transform 1.1s var(--ease), filter 1.1s var(--ease), opacity .8s var(--ease);
}
body.is-open .overlay__bg{ transform:scale(1); filter:blur(0); opacity:1; }

.overlay__close{
  position:absolute; top:var(--pad-t); left:var(--pad);
  top:max(var(--pad-t), env(safe-area-inset-top));
  display:flex; align-items:center; gap:.7rem;
  font-size:.72rem; letter-spacing:.3em; text-transform:uppercase;
  color:var(--ink-2);
  transition:color .5s var(--ease);
}
.overlay__close:hover{ color:var(--cream); }
.overlay__close svg{
  width:15px; height:15px; overflow:visible;
  fill:none; stroke:currentColor; stroke-width:1.1;
  transition:transform .8s var(--ease);
}
.overlay__close:hover svg{ transform:rotate(90deg); }

/* nav */
.overlay__nav{ padding-left:clamp(0rem,3vw,3rem); }

.overlay__nav a{
  position:relative;
  display:flex; align-items:center; gap:clamp(.85rem,1.8vw,1.9rem);
  padding:clamp(.3rem,1.1vh,.7rem) 0;
  width:max-content; max-width:100%;
}

.overlay__nav em{
  font-family:var(--mono); font-style:normal;
  font-size:.6rem; letter-spacing:.2em;
  color:var(--ink-3);
  transition:color .6s var(--ease);
}

.overlay__nav span{
  font-size:clamp(2rem,7.6vw,6.4rem);
  font-weight:300;
  line-height:1.04;
  letter-spacing:.05em;
  text-transform:uppercase;
  color:rgba(232,225,214,.66);
  transition:color .7s var(--ease), transform .7s var(--ease);
}

/* cinematic strike-through */
.overlay__nav i{
  position:absolute; left:0; right:0; top:52%;
  height:1px; background:var(--cream);
  transform:scaleX(0); transform-origin:left;
  transition:transform .8s var(--ease);
}
.overlay__nav a:hover i,
.overlay__nav a:focus-visible i{ transform:scaleX(1); }
.overlay__nav a:hover span,
.overlay__nav a:focus-visible span{ color:var(--cream); }
.overlay__nav a:hover em,
.overlay__nav a:focus-visible em{ color:var(--cream); }

/* staggered entrance */
.ov-item{
  opacity:0;
  transform:translate3d(0,34px,0);
  transition:opacity .9s var(--ease), transform 1s var(--ease);
}
body.is-open .ov-item{ opacity:1; transform:none; }
body.is-open .ov-item:nth-child(1){ transition-delay:.20s }
body.is-open .ov-item:nth-child(2){ transition-delay:.28s }
body.is-open .ov-item:nth-child(3){ transition-delay:.36s }
body.is-open .ov-item:nth-child(4){ transition-delay:.44s }
body.is-open .overlay__meta.ov-item{ transition-delay:.52s }
body.is-open .overlay__social.ov-item{ transition-delay:.58s }

.overlay__meta{
  position:absolute; left:var(--pad); bottom:max(var(--pad), env(safe-area-inset-bottom));
  display:flex; flex-direction:column; gap:.35rem;
  font-family:var(--mono); font-size:.6rem;
  letter-spacing:.2em; text-transform:uppercase;
  color:var(--ink-3);
}

.overlay__social{
  position:absolute; right:var(--pad); bottom:max(var(--pad), env(safe-area-inset-bottom));
  display:flex; flex-wrap:wrap; justify-content:flex-end;
  gap:.35rem clamp(.9rem,2vw,1.7rem);
}
.overlay__social a{
  position:relative;
  font-size:.66rem; letter-spacing:.22em; text-transform:uppercase;
  color:rgba(245,235,222,.55);
  transition:color .5s var(--ease);
}
.overlay__social a::after{
  content:''; position:absolute; left:0; right:0; bottom:-5px;
  height:1px; background:currentColor;
  transform:scaleX(0); transform-origin:left;
  transition:transform .6s var(--ease);
}
.overlay__social a:hover{ color:#fff; }
.overlay__social a:hover::after{ transform:scaleX(1); }

@media (max-width:640px){
  .overlay__meta{ display:none; }
  .overlay__nav{ padding-left:0; }
  .overlay__nav span{ font-size:clamp(1.55rem,7.9vw,2.6rem); letter-spacing:.04em; }

  /* social row gets real breathing room and tappable targets */
  .overlay__social{
    left:var(--pad); right:var(--pad);
    justify-content:flex-start;
    gap:.2rem 1.5rem;
    padding-top:1.1rem;
    border-top:1px solid rgba(232,225,214,.14);
  }
  .overlay__social a{
    display:block; padding:.45rem 0;
    font-size:.64rem; letter-spacing:.18em;
  }
  .overlay__social a::after{ bottom:2px; }
}

/* ============================================================
   HERO
   ============================================================ */

.hero{
  position:relative;
  min-height:100vh; min-height:100svh;
  display:flex; flex-direction:column; justify-content:center;
  padding:calc(var(--pad) * 2.4) var(--pad) var(--pad);
  overflow:hidden;
}

.hero__media{
  position:absolute; inset:0; z-index:0;
  overflow:hidden;
  opacity:0;
  transform:scale(1.04);
  transition:opacity 1.8s var(--ease), transform 2.6s var(--ease);
}
body.is-ready .hero__media{ opacity:1; transform:scale(1); }

.hero__media img{
  /* absolute, not height:100% — the <picture> wrapper has no height to inherit */
  position:absolute; inset:0;
  width:100%; height:100%;
  object-fit:cover;
  /* pushes the figures off-centre so the name is not fighting a silhouette */
  object-position:38% 40%;
  filter:saturate(.84) contrast(1.05) brightness(.78);
}

.hero__scrim{
  position:absolute; inset:0; z-index:1;
  background:
    radial-gradient(96% 62% at 50% 112%, rgba(196,116,40,.34) 0%, rgba(122,63,23,.2) 34%, transparent 72%),
    radial-gradient(78% 58% at 50% 44%, rgba(5,4,3,.72) 0%, rgba(5,4,3,.5) 46%, transparent 78%),
    linear-gradient(to bottom, rgba(5,4,3,.86) 0%, rgba(5,4,3,.5) 24%, rgba(8,5,4,.46) 52%, rgba(20,12,8,.78) 82%, rgba(5,4,3,.94) 100%);
}

.hero__inner{
  position:relative; z-index:2;
  text-align:center;
  margin:auto 0;
}

.hero__eyebrow{
  font-family:var(--mono);
  font-size:.6rem;
  letter-spacing:.34em; text-transform:uppercase;
  color:rgba(232,225,214,.5);
  margin-bottom:clamp(1.6rem,4.5vh,3.4rem);
}

.hero__name{
  font-weight:300;
  text-transform:uppercase;
  letter-spacing:.05em;
  line-height:1;
  color:var(--cream);
  /* tracking pushes the last glyph right — nudge back for optical centering */
  text-indent:.05em;
  /* sized for the longest line (CÁRCAMO, 7 glyphs) — recheck if the name changes */
  font-size:clamp(2.6rem, 14.5vw, 5.2rem);
}

.hero__role{
  margin-top:clamp(1.5rem,4vh,2.8rem);
  font-size:clamp(.6rem,1.5vw,.8rem);
  letter-spacing:.3em; text-transform:uppercase;
  color:rgba(232,225,214,.72);
  text-indent:.3em;
}

.hero__cta{
  display:flex; flex-wrap:wrap; align-items:center; justify-content:center;
  gap:clamp(1.6rem,4vw,3.4rem);
  margin-top:clamp(2.6rem,7vh,4.4rem);
}

.cta{
  position:relative;
  display:inline-flex; align-items:center; gap:1rem;
  padding-bottom:.6rem;
  font-size:.68rem; letter-spacing:.28em; text-transform:uppercase;
  color:var(--ink-2);
  opacity:0; transform:translate3d(0,14px,0);
  transition:opacity 1s var(--ease), transform 1s var(--ease), color .5s var(--ease);
}
body.is-ready .cta{ opacity:1; transform:none; transition-delay:1.85s; }
body.is-ready .cta--ghost{ transition-delay:1.98s; }
.cta::before{
  content:''; position:absolute; left:0; right:0; bottom:0;
  height:1px; background:currentColor; opacity:.35;
  transition:opacity .6s var(--ease);
}
.cta svg{
  width:30px; height:8px; overflow:visible;
  fill:none; stroke:currentColor; stroke-width:1;
  transition:transform .7s var(--ease);
}
.cta:hover{ color:var(--cream); }
.cta:hover::before{ opacity:1; }
.cta:hover svg{ transform:translateX(7px); }

.cta--ghost{ color:rgba(232,225,214,.56); }
.cta--ghost::before{ opacity:.24; }
.cta__play{
  width:9px; height:9px;
  fill:currentColor; stroke:none;
  transition:opacity .6s var(--ease);
  opacity:.7;
}
.cta--ghost:hover .cta__play{ transform:none; opacity:1; }

.hero__foot{
  position:relative; z-index:2;
  display:flex; align-items:center; justify-content:space-between;
  font-family:var(--mono);
  font-size:.58rem; letter-spacing:.24em; text-transform:uppercase;
  color:rgba(232,225,214,.45);
  opacity:0;
  transition:opacity 1.4s var(--ease) 2.3s;
  padding-bottom:env(safe-area-inset-bottom);
}
body.is-ready .hero__foot{ opacity:1; }

.hero__scroll{ display:flex; align-items:center; gap:.6rem; }
.hero__scroll i{
  display:block; width:1px; height:26px;
  background:linear-gradient(to bottom, var(--ink-3), transparent);
  animation:drop 2.6s var(--ease-io) infinite;
}
@keyframes drop{
  0%,100%{ transform:scaleY(.3); transform-origin:top; opacity:.3 }
  45%    { transform:scaleY(1);  transform-origin:top; opacity:1 }
  46%,99%{ transform:scaleY(0);  transform-origin:bottom; opacity:0 }
}

/* hero sequence */
body.is-ready .hero__eyebrow .mask__i{ transform:none; transition-delay:.55s; }
body.is-ready .hero__name .mask:nth-child(1) .mask__i{ transform:none; transition-delay:.75s; }
body.is-ready .hero__name .mask:nth-child(2) .mask__i{ transform:none; transition-delay:.9s; }
body.is-ready .hero__role .mask__i{ transform:none; transition-delay:1.4s; }

@media (min-width:700px){
  .hero__name{
    font-size:clamp(4.5rem, 12.6vw, 13rem);
    letter-spacing:.1em; text-indent:.1em;
    line-height:.96;
  }
  .hero__role{ letter-spacing:.42em; text-indent:.42em; }
}

/* ============================================================
   INTERTITLE
   ============================================================ */

.rule{
  height:1px; background:var(--hair);
  transform:scaleX(0); transform-origin:left;
  transition:transform 1.4s var(--ease);
}
.rule.in{ transform:scaleX(1); }

.title-card{
  padding:clamp(5rem,16vh,11rem) var(--pad) clamp(3.5rem,10vh,7rem);
}

.title-card__row{
  display:flex; flex-wrap:wrap; align-items:flex-end;
  justify-content:space-between; gap:2rem;
  padding-top:clamp(2.5rem,7vh,5rem);
}

.title-card__h{
  font-weight:300; text-transform:uppercase;
  font-size:clamp(1.5rem,4.6vw,3.4rem);
  letter-spacing:.16em; line-height:1;
  color:var(--cream);
}

.title-card__p{
  max-width:26ch;
  font-size:.78rem; line-height:2;
  letter-spacing:.09em;
  color:var(--ink-3);
}

/* ============================================================
   WORKS
   ============================================================ */

.work{
  position:relative;
  min-height:100vh; min-height:100svh;
  display:flex; align-items:flex-end;
  overflow:hidden;
}

.work__media{
  position:absolute; inset:0; overflow:hidden;
  opacity:.85;
  transform:scale(1.03);
  transition:opacity 1.6s var(--ease), transform 1.8s var(--ease);
}
.work__media.in{ opacity:1; transform:scale(1); }

.work__zoom{
  position:absolute; inset:0;
  transition:transform 1.6s var(--ease);
  will-change:transform;
}
@media (hover:hover){
  .work:hover .work__zoom{ transform:scale(1.02); }
}

.work__media img{
  position:absolute; top:-7%; left:0;
  width:100%; height:114%;
  object-fit:cover;
  will-change:transform;
  /* faint desaturation keeps the palette coherent across the three films */
  filter:saturate(.94) contrast(1.02);
}

.work__scrim{
  position:absolute; inset:0;
  background:
    linear-gradient(to top, rgba(5,4,3,.96) 0%, rgba(5,4,3,.82) 16%, rgba(5,4,3,.34) 44%, rgba(5,4,3,.08) 70%, rgba(5,4,3,.34) 100%),
    linear-gradient(to right, rgba(5,4,3,.5) 0%, rgba(5,4,3,.12) 46%, transparent 60%);
}

.work__body{
  position:relative; z-index:2;
  width:100%;
  padding:var(--pad);
  padding-bottom:max(calc(var(--pad) * 1.25), env(safe-area-inset-bottom));
  max-width:min(56rem, 100%);
}

.work__no{
  display:inline-block;
  font-family:var(--mono);
  font-size:.58rem; letter-spacing:.26em; text-transform:uppercase;
  color:rgba(232,225,214,.55);
  padding-bottom:.5rem;
  border-bottom:1px solid rgba(232,225,214,.22);
  margin-bottom:clamp(1.5rem,4.5vh,2.8rem);
}

.work__meta{
  font-family:var(--mono);
  font-size:.6rem; letter-spacing:.2em; text-transform:uppercase;
  color:rgba(232,225,214,.55);
  margin-bottom:clamp(.9rem,2vh,1.3rem);
}

.work__title{
  font-weight:300; text-transform:uppercase;
  font-size:clamp(2.1rem,7.6vw,6.6rem);
  letter-spacing:.06em; line-height:.98;
  color:var(--cream);
}

.work__desc{
  margin-top:clamp(1.1rem,2.6vh,1.7rem);
  max-width:44ch;
  font-size:clamp(.86rem,1.5vw,1rem);
  line-height:1.85;
  color:var(--ink-2);
}

.work__link{
  position:relative;
  display:inline-flex; align-items:center; gap:.9rem;
  margin-top:clamp(1.8rem,4.5vh,2.8rem);
  padding-bottom:.55rem;
  font-size:.66rem; letter-spacing:.28em; text-transform:uppercase;
  color:var(--ink-2);
  transition:color .5s var(--ease);
}
.work__link::before{
  content:''; position:absolute; left:0; right:0; bottom:0;
  height:1px; background:currentColor; opacity:.3;
  transition:opacity .5s var(--ease);
}
.work__link svg{
  width:30px; height:8px; overflow:visible;
  fill:none; stroke:currentColor; stroke-width:1;
  transition:transform .7s var(--ease);
}
.work__link:hover{ color:var(--cream); }
.work__link:hover::before{ opacity:1; }
.work__link:hover svg{ transform:translateX(7px); }

@media (min-width:900px){
  .work__body{ padding-bottom:clamp(3.5rem,9vh,6rem); }
}

/* portrait crops: keep each subject inside the frame */
@media (max-width:760px){
  #work-1 .work__media img{ object-position:64% center; }
  #work-2 .work__media img{ object-position:40% center; }
  #work-3 .work__media img{ object-position:68% center; }
  .hero__media img{ object-position:58% 38%; }
  /* phone browser chrome eats the bottom — lift the text block off it */
  .work__body{ padding-bottom:calc(var(--pad) * 1.5 + env(safe-area-inset-bottom)); }
}

/* ============================================================
   FILM SHEET  (project overlay)
   ============================================================ */

.sheet{
  position:fixed; inset:0; z-index:130;
  display:grid;
  grid-template-columns:1fr;
  grid-template-rows:minmax(0,42vh) minmax(0,1fr);
  background:linear-gradient(150deg, #050403 0%, #0b0705 46%, #1a0f08 82%, #2a170c 100%);
  opacity:0; visibility:hidden;
  transition:opacity .7s var(--ease), visibility 0s linear .7s;
}
.sheet.is-open{
  opacity:1; visibility:visible;
  transition:opacity .8s var(--ease), visibility 0s;
}

.sheet__close{
  position:absolute; z-index:3;
  top:max(var(--pad-t), env(safe-area-inset-top)); left:var(--pad);
  display:flex; align-items:center; gap:.7rem;
  padding:.4rem .8rem .4rem 0;
  font-size:.68rem; letter-spacing:.28em; text-transform:uppercase;
  color:var(--cream);
  text-shadow:0 1px 14px rgba(5,4,3,.9);
  transition:color .5s var(--ease);
}
.sheet__close svg{
  width:14px; height:14px; overflow:visible;
  fill:none; stroke:currentColor; stroke-width:1.1;
  transition:transform .8s var(--ease);
}
.sheet__close:hover svg{ transform:rotate(90deg); }

.sheet__media{ position:relative; overflow:hidden; }
.sheet__media::after{
  content:''; position:absolute; inset:0;
  background:
    linear-gradient(to bottom, rgba(5,4,3,.6) 0%, transparent 34%, rgba(5,4,3,.28) 100%);
}
.sheet__media img{
  /* absolute, not height:100% — the <picture> wrapper has no height to inherit */
  position:absolute; inset:0;
  width:100%; height:100%;
  object-fit:cover; object-position:center;
  transform:scale(1.05);
  transition:transform 1.6s var(--ease);
  filter:saturate(.92) contrast(1.02);
}
.sheet.is-open .sheet__media img{ transform:scale(1); }

.sheet__body{
  position:relative;
  min-height:0;
  display:flex;
}

.sheet__scroll{
  width:100%;
  overflow-y:auto;
  -webkit-overflow-scrolling:touch;
  overscroll-behavior:contain;
  padding:clamp(2rem,5vh,3.4rem) var(--pad)
          calc(clamp(2rem,5vh,3.4rem) + env(safe-area-inset-bottom));
}

/* staggered content */
.sheet__scroll > *{
  opacity:0; transform:translate3d(0,20px,0);
  transition:opacity .9s var(--ease), transform 1s var(--ease);
}
.sheet.is-open .sheet__scroll > *{ opacity:1; transform:none; }
.sheet.is-open .sheet__scroll > *:nth-child(1){ transition-delay:.20s }
.sheet.is-open .sheet__scroll > *:nth-child(2){ transition-delay:.27s }
.sheet.is-open .sheet__scroll > *:nth-child(3){ transition-delay:.34s }
.sheet.is-open .sheet__scroll > *:nth-child(4){ transition-delay:.41s }
.sheet.is-open .sheet__scroll > *:nth-child(5){ transition-delay:.46s }
.sheet.is-open .sheet__scroll > *:nth-child(6){ transition-delay:.51s }
.sheet.is-open .sheet__scroll > *:nth-child(7){ transition-delay:.56s }
.sheet.is-open .sheet__scroll > *:nth-child(8){ transition-delay:.61s }

.sheet__eyebrow{
  font-family:var(--mono);
  font-size:.58rem; letter-spacing:.26em; text-transform:uppercase;
  color:rgba(232,225,214,.5);
}

.sheet__title{
  margin-top:clamp(.9rem,2.4vh,1.5rem);
  font-weight:300; text-transform:uppercase;
  font-size:clamp(1.9rem,5.4vw,4.2rem);
  letter-spacing:.06em; line-height:1;
  color:var(--cream);
}

/* archive-style spec table */
.sheet__specs{
  margin-top:clamp(1.8rem,4.5vh,3rem);
  border-top:1px solid var(--hair);
  max-width:34rem;
}
.sheet__specs > div{
  display:flex; gap:1.5rem;
  padding:.82rem 0;
  border-bottom:1px solid var(--hair);
}
.sheet__specs dt{
  flex:0 0 7.5rem;
  font-family:var(--mono);
  font-size:.58rem; letter-spacing:.22em; text-transform:uppercase;
  color:rgba(232,225,214,.42);
  padding-top:.18em;
}
.sheet__specs dd{
  font-size:.86rem; letter-spacing:.04em;
  color:rgba(232,225,214,.88);
}

.sheet__label{
  margin-top:clamp(2rem,5vh,3.2rem);
  font-family:var(--mono);
  font-size:.56rem; letter-spacing:.24em; text-transform:uppercase;
  color:rgba(232,225,214,.4);
}

.sheet__logline{
  margin-top:.9rem;
  max-width:36ch;
  font-size:clamp(1.05rem,2vw,1.45rem);
  font-weight:300; line-height:1.62;
  color:var(--cream);
  text-wrap:pretty;
}

.sheet__note{
  margin-top:.9rem;
  max-width:44ch;
  font-size:.9rem; line-height:1.85;
  color:rgba(232,225,214,.6);
  text-wrap:pretty;
}

.sheet__mail{
  position:relative;
  display:inline-block;
  align-self:flex-start;  /* desktop sheet body is a column flex — don't stretch */
  margin-top:clamp(2.4rem,6vh,3.6rem);
  padding-bottom:.5rem;
  font-size:.66rem; letter-spacing:.26em; text-transform:uppercase;
  color:rgba(232,225,214,.62);
  transition:color .5s var(--ease);
}
.sheet__mail::before{
  content:''; position:absolute; left:0; right:0; bottom:0;
  height:1px; background:currentColor; opacity:.35;
  transition:opacity .5s var(--ease);
}
.sheet__mail:hover{ color:var(--cream); }
.sheet__mail:hover::before{ opacity:1; }

/* reel sheet — no image, pure type */
.sheet--plain{
  grid-template-rows:1fr;
  background:
    radial-gradient(80% 90% at 108% 60%, rgba(190,110,36,.24) 0%, transparent 58%),
    linear-gradient(150deg, #050403 0%, #0b0705 52%, #1a0f08 100%);
}
.reel{
  align-self:center;
  padding:var(--pad);
  padding-bottom:calc(var(--pad) + env(safe-area-inset-bottom));
  max-width:44rem;
  margin:0 auto;
  opacity:0; transform:translate3d(0,20px,0);
  transition:opacity .9s var(--ease) .2s, transform 1s var(--ease) .2s;
}
.sheet--plain.is-open .reel{ opacity:1; transform:none; }
.reel__title{
  margin-top:clamp(1.2rem,3vh,2rem);
  font-weight:300; text-transform:uppercase;
  font-size:clamp(1.8rem,5.6vw,3.8rem);
  letter-spacing:.07em; line-height:1.08;
  color:var(--cream);
}
.reel__note{
  margin-top:clamp(1.4rem,3.5vh,2.2rem);
  max-width:34ch;
  font-size:.88rem; line-height:1.85;
  color:rgba(232,225,214,.55);
}

@media (min-width:900px){
  .sheet{
    grid-template-columns:minmax(0,55fr) minmax(0,45fr);
    grid-template-rows:1fr;
  }
  .sheet__media::after{
    background:linear-gradient(to right, rgba(5,4,3,.34) 0%, transparent 30%, rgba(5,4,3,.42) 100%);
  }
  .sheet__scroll{
    display:flex; flex-direction:column; justify-content:center;
    padding:calc(var(--pad) * 1.6) clamp(2.5rem,4.5vw,5rem);
  }
  .sheet__close{ left:calc(var(--pad) * .9); }
  .sheet--plain .reel{ padding-left:clamp(3rem,8vw,8rem); }
}

/* ============================================================
   ABOUT
   ============================================================ */

.about{
  padding:clamp(6rem,18vh,13rem) var(--pad);
}

.about__grid{
  display:grid; gap:clamp(2.5rem,6vw,5rem);
  padding-top:clamp(3rem,9vh,6rem);
}

.about__label{
  font-family:var(--mono);
  font-size:.6rem; letter-spacing:.28em; text-transform:uppercase;
  color:rgba(232,225,214,.5);
}

.about__text{
  font-size:clamp(1.05rem,2.4vw,1.72rem);
  font-weight:300;
  line-height:1.72;
  letter-spacing:.005em;
  color:var(--cream);
  max-width:32ch;
  text-wrap:pretty;
}

.about__list{
  margin-top:clamp(3rem,8vh,5rem);
  max-width:26rem;
}
.about__list li{
  padding:1.05rem 0;
  border-top:1px solid var(--hair);
  font-size:.78rem; letter-spacing:.12em;
  color:rgba(232,225,214,.55);
}
.about__list li:last-child{ border-bottom:1px solid var(--hair); }

@media (min-width:860px){
  .about__grid{ grid-template-columns:14rem 1fr; }
  .about__label{ padding-top:.55rem; }
  .about__text{ max-width:34ch; }
}

/* ============================================================
   SIGN-OFF
   ============================================================ */

.sign{
  padding:clamp(4rem,12vh,8rem) var(--pad);
  padding-bottom:max(clamp(2rem,6vh,3.5rem), env(safe-area-inset-bottom));
}

.sign__note{
  margin-top:clamp(3rem,9vh,6rem);
  font-size:.8rem; letter-spacing:.13em; line-height:1.8;
  color:rgba(232,225,214,.5);
  max-width:34ch;
}

.sign__mail{
  position:relative;
  display:inline-block;
  margin-top:clamp(1.6rem,4vh,2.6rem);
  font-size:clamp(1.5rem,5.6vw,3.9rem);
  font-weight:300; letter-spacing:.02em;
  line-height:1.1;
  color:var(--cream);
}
.sign__mail::after{
  content:''; position:absolute; left:0; right:0; bottom:-.14em;
  height:1px; background:currentColor;
  transform:scaleX(0); transform-origin:left;
  transition:transform .9s var(--ease);
}
.sign__mail:hover::after{ transform:scaleX(1); }

.sign__bottom{
  display:flex; flex-wrap:wrap; align-items:flex-end;
  justify-content:space-between; gap:2rem;
  margin-top:clamp(5rem,15vh,10rem);
}

.sign__social{
  display:flex; flex-wrap:wrap; gap:.6rem clamp(1rem,2.2vw,2rem);
}
.sign__social a{
  position:relative;
  font-size:.66rem; letter-spacing:.22em; text-transform:uppercase;
  color:rgba(232,225,214,.48);
  transition:color .5s var(--ease);
}
.sign__social a::after{
  content:''; position:absolute; left:0; right:0; bottom:-5px;
  height:1px; background:currentColor;
  transform:scaleX(0); transform-origin:left;
  transition:transform .6s var(--ease);
}
.sign__social a:hover{ color:var(--cream); }
.sign__social a:hover::after{ transform:scaleX(1); }

.sign__cr{
  font-family:var(--mono);
  font-size:.58rem; letter-spacing:.16em;
  color:rgba(232,225,214,.3);
}

/* ============================================================
   SCROLL REVEAL
   ============================================================ */

[data-reveal]{
  opacity:0;
  transform:translate3d(0,26px,0);
  transition:opacity 1.1s var(--ease), transform 1.2s var(--ease);
}
[data-reveal].in{ opacity:1; transform:none; }

.work__meta[data-reveal].in{ transition-delay:.08s }
.work__title[data-reveal].in{ transition-delay:.16s }
.work__desc[data-reveal].in{ transition-delay:.26s }
.work__link[data-reveal].in{ transition-delay:.36s }
.about__list li:nth-child(2).in{ transition-delay:.1s }
.about__list li:nth-child(3).in{ transition-delay:.2s }
.title-card__p.in{ transition-delay:.14s }
.sign__mail.in{ transition-delay:.12s }

/* ============================================================
   REDUCED MOTION
   ============================================================ */

@media (prefers-reduced-motion:reduce){
  html{ scroll-behavior:auto; }
  *,*::before,*::after{
    animation-duration:.01ms !important;
    animation-iteration-count:1 !important;
    transition-duration:.01ms !important;
    transition-delay:0ms !important;
  }
  .grain{ animation:none; }
  .mask__i,[data-reveal],.ov-item,.cta,
  .hero__media,.work__media,.reel,.sheet__scroll > *{
    transform:none !important; opacity:1 !important;
  }
  .rule{ transform:scaleX(1) !important; }
  .work__zoom,.sheet__media img{ transform:none !important; }
}
