/* ============================================================
   DIEGO LEANZA — Portfolio
   Cinematic Dark Editorial
   ============================================================ */

:root {
  --bg:        #0b0a08;
  --bg-alt:    #131110;
  --surface:   #1a1714;
  --surface-2: #211d18;
  --line:      #322c24;

  --cream:     #f3ede1;
  --cream-dim: #cabfa9;
  --muted:     #8d8474;

  --gold:      #cd9b4a;
  --gold-soft: #e6c384;
  --gold-dim:  #6e5527;

  --font-display: "Fraunces", "Iowan Old Style", Georgia, serif;
  --font-body: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;

  --container: 1240px;
  --gutter: clamp(1.5rem, 5vw, 4rem);

  --ease: cubic-bezier(.16,.84,.44,1);
}

* { box-sizing: border-box; }
html {
  scroll-behavior: smooth;
  background: var(--bg);
}
body {
  margin: 0;
  background: var(--bg);
  color: var(--cream);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; margin: 0; padding: 0; }
h1, h2, h3, h4 { font-family: var(--font-display); font-weight: 500; margin: 0; }
p { margin: 0; }
button { font-family: inherit; cursor: pointer; }

.container {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

/* Grain / vignette overlay for cinematic feel */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 999;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='120' height='120'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/></filter><rect width='100%25' height='100%25' filter='url(%23n)' opacity='0.035'/></svg>");
  mix-blend-mode: overlay;
  opacity: .5;
}

/* ---------- Reveal defaults (defensive CSS) ---------- */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity .9s var(--ease), transform .9s var(--ease);
}
.reveal.is-visible {
  opacity: 1;
  transform: none;
}
.reveal[data-split] { opacity: 1; transform: none; }
@media (max-width: 640px) {
  .reveal { transform: translateY(16px); }
}

/* ============================================================
   NAV
   ============================================================ */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 500;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.3rem var(--gutter);
  background: linear-gradient(to bottom, rgba(11,10,8,.9), rgba(11,10,8,0));
  transition: background .4s ease, padding .4s ease, border-color .4s ease;
  border-bottom: 1px solid transparent;
}
.nav.is-scrolled {
  background: rgba(11,10,8,.86);
  backdrop-filter: blur(10px);
  padding-top: .9rem;
  padding-bottom: .9rem;
  border-bottom: 1px solid var(--line);
}
.nav__brand {
  font-family: var(--font-display);
  font-size: 1.15rem;
  letter-spacing: .04em;
  color: var(--cream);
}
.nav__brand em { color: var(--gold); font-style: normal; }
.nav__links {
  display: flex;
  gap: 2.2rem;
}
.nav__links a {
  font-size: .82rem;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--cream-dim);
  position: relative;
  padding-bottom: .3rem;
  transition: color .3s ease;
}
.nav__links a::after {
  content: "";
  position: absolute;
  left: 0; bottom: 0;
  width: 0;
  height: 1px;
  background: var(--gold);
  transition: width .35s var(--ease);
}
.nav__links a:hover,
.nav__links a.is-active { color: var(--cream); }
.nav__links a:hover::after,
.nav__links a.is-active::after { width: 100%; }

.nav__toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  padding: .5rem;
}
.nav__toggle span {
  width: 22px;
  height: 1.5px;
  background: var(--cream);
  transition: transform .3s ease, opacity .3s ease;
}
.nav__toggle.is-open span:nth-child(1) { transform: translateY(6.5px) rotate(45deg); }
.nav__toggle.is-open span:nth-child(2) { opacity: 0; }
.nav__toggle.is-open span:nth-child(3) { transform: translateY(-6.5px) rotate(-45deg); }

@media (max-width: 860px) {
  .nav__toggle { display: flex; }
  .nav__links {
    position: fixed;
    top: 0; right: 0;
    height: 100vh;
    width: min(78vw, 340px);
    background: var(--surface);
    flex-direction: column;
    justify-content: center;
    align-items: flex-start;
    gap: 1.8rem;
    padding: 2rem var(--gutter);
    transform: translateX(100%);
    transition: transform .45s var(--ease);
    border-left: 1px solid var(--line);
  }
  .nav__links.is-open { transform: translateX(0); }
  .nav__links a { font-size: 1rem; }
}

/* ============================================================
   HERO
   ============================================================ */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding: 8rem var(--gutter) 4rem;
  overflow: hidden;
}
.hero__bg {
  position: absolute;
  top: 0;
  right: 0;
  width: 62%;
  height: 100%;
  z-index: 0;
}
@media (max-width: 900px) {
  .hero__bg { width: 100%; }
}
.hero__bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 60% 24%;
  opacity: .7;
  filter: grayscale(.1) contrast(1.05);
}
.hero__bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, var(--bg) 0%, rgba(11,10,8,.65) 22%, rgba(11,10,8,.1) 52%, rgba(11,10,8,.05) 100%),
    linear-gradient(to top, var(--bg) 0%, rgba(11,10,8,0) 32%);
}
.hero__inner {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
}
.hero__eyebrow {
  display: inline-flex;
  align-items: center;
  gap: .6rem;
  font-size: .78rem;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: var(--gold-soft);
  margin-bottom: 1.6rem;
}
.hero__eyebrow::before {
  content: "";
  width: 30px;
  height: 1px;
  background: var(--gold);
}
.hero h1 {
  font-size: clamp(2.8rem, 7.4vw, 6.4rem);
  line-height: 1.12;
  letter-spacing: -.01em;
  color: var(--cream);
  max-width: 16ch;
}
.hero h1 .line {
  display: block;
  overflow: hidden;
  padding-bottom: .12em;
  margin-bottom: -.12em;
}
.hero h1 em {
  font-style: italic;
  color: var(--gold);
  font-weight: 400;
}
.hero__roles {
  margin-top: 2rem;
  display: flex;
  flex-wrap: wrap;
  gap: .6rem 1rem;
  font-size: .95rem;
  color: var(--cream-dim);
}
.hero__roles span {
  padding: .35rem .9rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  letter-spacing: .02em;
}
.hero__tagline {
  margin-top: 2.4rem;
  max-width: 46ch;
  font-size: clamp(1.05rem, 1.6vw, 1.25rem);
  color: var(--cream-dim);
  font-weight: 300;
}
.hero__scroll {
  position: absolute;
  left: var(--gutter);
  bottom: 2.4rem;
  z-index: 2;
  display: flex;
  align-items: center;
  gap: .8rem;
  font-size: .72rem;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--muted);
}
.hero__scroll .stem {
  width: 1px;
  height: 46px;
  background: linear-gradient(to bottom, var(--gold), transparent);
  animation: stemPulse 2.4s ease-in-out infinite;
}
@keyframes stemPulse {
  0%, 100% { opacity: .4; }
  50% { opacity: 1; }
}

/* ============================================================
   SECTION BASICS
   ============================================================ */
.section {
  padding: 7.5rem 0;
  position: relative;
}
.section--tight { padding: 5rem 0; }
.section-head {
  max-width: 62ch;
  margin-bottom: 3.5rem;
}
.section-kicker {
  display: block;
  font-size: .78rem;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 1rem;
}
.section-title {
  font-size: clamp(2rem, 4.2vw, 3.1rem);
  color: var(--cream);
  line-height: 1.06;
}
.section-lede {
  margin-top: 1.4rem;
  color: var(--cream-dim);
  font-size: 1.08rem;
  font-weight: 300;
  line-height: 1.7;
}
.divider {
  height: 1px;
  background: var(--line);
  margin: 0 var(--gutter);
}

/* ============================================================
   INTRO / BIO STRIP
   ============================================================ */
.intro {
  background: var(--bg-alt);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.intro .container { padding-top: 5.5rem; padding-bottom: 5.5rem; }
.intro__quote {
  font-family: var(--font-display);
  font-weight: 400;
  font-style: italic;
  font-size: clamp(1.4rem, 2.6vw, 2.1rem);
  line-height: 1.4;
  color: var(--cream);
  max-width: 26ch;
}
.intro__quote .gold { color: var(--gold); font-style: normal; }
.intro__stats {
  margin-top: 3rem;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 2rem;
}
.stat__num {
  font-family: var(--font-display);
  font-size: clamp(2rem, 3.2vw, 2.6rem);
  color: var(--gold-soft);
}
.stat__label {
  margin-top: .35rem;
  font-size: .82rem;
  letter-spacing: .05em;
  color: var(--muted);
}

/* ============================================================
   PILLARS (3 profiles)
   ============================================================ */
.pillars {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5px;
  background: var(--line);
  border: 1px solid var(--line);
}
.pillar {
  background: var(--bg);
  padding: 3rem 2.2rem;
  display: flex;
  flex-direction: column;
  gap: 1.4rem;
  min-height: 340px;
  transition: background .4s ease;
}
.pillar:hover { background: var(--surface); }
.pillar__num {
  font-family: var(--font-display);
  font-style: italic;
  color: var(--gold-dim);
  font-size: 1.1rem;
}
.pillar h3 {
  font-size: clamp(1.4rem, 2vw, 1.8rem);
  color: var(--cream);
}
.pillar p {
  color: var(--cream-dim);
  font-weight: 300;
  font-size: .96rem;
  line-height: 1.6;
  flex: 1;
}
.pillar__link {
  display: inline-flex;
  align-items: center;
  gap: .6rem;
  font-size: .78rem;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--gold-soft);
}
.pillar__link .arrow {
  transition: transform .3s var(--ease);
}
.pillar:hover .pillar__link .arrow { transform: translateY(4px); }

@media (max-width: 900px) {
  .pillars { grid-template-columns: 1fr; }
}

/* ============================================================
   PROFILE SECTIONS (director / guionista / docente)
   ============================================================ */
.profile {
  scroll-margin-top: 90px;
}
.profile__grid {
  display: grid;
  grid-template-columns: .85fr 1.15fr;
  gap: clamp(2rem, 5vw, 5rem);
  align-items: start;
}
@media (max-width: 900px) {
  .profile__grid { grid-template-columns: 1fr; }
}
.profile__label {
  position: sticky;
  top: 110px;
}
@media (max-width: 900px) {
  .profile__label { position: static; top: auto; margin-bottom: .5rem; }
}
.profile__index {
  font-family: var(--font-display);
  font-size: 3.6rem;
  color: var(--gold-dim);
  font-style: italic;
  line-height: 1;
}
.profile__role {
  margin-top: .8rem;
  font-size: 1.3rem;
  color: var(--cream);
}
.profile__sub {
  margin-top: .6rem;
  font-size: .85rem;
  letter-spacing: .06em;
  color: var(--muted);
  text-transform: uppercase;
}

/* Credits / clients chips */
.chips {
  margin-top: 2.4rem;
  display: flex;
  flex-wrap: wrap;
  gap: .55rem;
}
.chip {
  font-size: .78rem;
  letter-spacing: .03em;
  color: var(--cream-dim);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: .45rem 1rem;
}

/* Marquee of clients */
.marquee {
  margin-top: 3rem;
  overflow: hidden;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  padding: 1.4rem 0;
}
.marquee__track {
  display: flex;
  width: max-content;
  gap: 3.5rem;
  animation: marquee 32s linear infinite;
}
.marquee__track span {
  font-family: var(--font-display);
  font-size: 1.3rem;
  color: var(--muted);
  white-space: nowrap;
}
@keyframes marquee {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}

/* Video / works grid */
.works {
  margin-top: 1rem;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.6rem;
}
@media (max-width: 640px) {
  .works { grid-template-columns: 1fr; }
}

/* Category browser (Director Audiovisual portfolio) */
.category-browser {
  margin-top: 4.5rem;
}
.category-browser__title {
  font-size: .82rem;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 1.4rem;
}
.category-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: .6rem;
  margin-bottom: 2.4rem;
}
.cat-tab {
  background: transparent;
  border: 1px solid var(--line);
  color: var(--cream-dim);
  font-family: inherit;
  font-size: .78rem;
  letter-spacing: .08em;
  text-transform: uppercase;
  padding: .6rem 1.3rem;
  border-radius: 999px;
  transition: background .3s ease, border-color .3s ease, color .3s ease;
}
.cat-tab:hover { border-color: var(--gold-dim); color: var(--cream); }
.cat-tab.is-active {
  background: var(--gold);
  border-color: var(--gold);
  color: var(--bg);
}

.works--catalog {
  grid-template-columns: repeat(3, 1fr);
}
@media (max-width: 980px) { .works--catalog { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 640px) { .works--catalog { grid-template-columns: 1fr; } }

.work-card[hidden] { display: none; }

.work-card__platform {
  position: absolute;
  top: .7rem;
  left: .7rem;
  z-index: 1;
  font-size: .64rem;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--cream);
  background: rgba(11,10,8,.55);
  padding: .28rem .6rem;
  border-radius: 999px;
  backdrop-filter: blur(4px);
}

.work-card__media[data-vimeo] {
  background: linear-gradient(135deg, var(--surface-2), var(--surface));
  display: flex;
  align-items: center;
  justify-content: center;
}
.work-card__media[data-vimeo]::before {
  content: "V";
  font-family: var(--font-display);
  font-style: italic;
  font-size: 3.2rem;
  color: var(--line);
}

.work-card--disabled .work-card__media {
  cursor: default;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--surface-2);
}
.placeholder-label {
  font-size: .74rem;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--muted);
}
.work-card {
  background: var(--surface);
  border: 1px solid var(--line);
}
.work-card__media {
  position: relative;
  aspect-ratio: 16/9;
  background: var(--surface-2);
  overflow: hidden;
  cursor: pointer;
}
.work-card__media img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform .6s var(--ease);
}
.work-card__media:hover img { transform: scale(1.06); }
.work-card__media iframe {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  border: 0;
}
.play-btn {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}
.play-btn::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(11,10,8,.65), rgba(11,10,8,.1));
}
.play-btn__circle {
  position: relative;
  z-index: 1;
  width: 58px; height: 58px;
  border-radius: 50%;
  border: 1px solid var(--gold-soft);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform .35s var(--ease), background .35s ease;
}
.work-card__media:hover .play-btn__circle {
  background: var(--gold);
  transform: scale(1.08);
}
.play-btn__circle svg { width: 16px; height: 16px; fill: var(--cream); }
.work-card__body {
  padding: 1.2rem 1.4rem 1.4rem;
}
.work-card__body h4 {
  font-size: 1.05rem;
  color: var(--cream);
}
.work-card__body p {
  margin-top: .35rem;
  font-size: .82rem;
  color: var(--muted);
}

/* Simple credit cards (no video) */
.credit-cards {
  margin-top: 2.4rem;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.2rem;
}
@media (max-width: 760px) {
  .credit-cards { grid-template-columns: 1fr; }
}
.credit-card {
  border: 1px solid var(--line);
  padding: 1.6rem 1.4rem;
  background: var(--surface);
}
.credit-card__plat {
  font-size: .72rem;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--gold);
}
.credit-card h4 {
  margin-top: .7rem;
  font-size: 1.15rem;
  color: var(--cream);
}
.credit-card p {
  margin-top: .5rem;
  font-size: .85rem;
  color: var(--muted);
}

/* Audioseries cards (Pocket FM — cover + listen link) */
.audio-cards {
  margin-top: 1.6rem;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.4rem;
}
@media (max-width: 760px) {
  .audio-cards { grid-template-columns: 1fr; }
}
.audio-card {
  display: block;
  border: 1px solid var(--line);
  background: var(--surface);
  overflow: hidden;
  transition: border-color .3s ease, transform .35s var(--ease);
}
.audio-card:hover {
  border-color: var(--gold-dim);
  transform: translateY(-3px);
}
.audio-card__cover {
  aspect-ratio: 1 / 1;
  overflow: hidden;
}
.audio-card__cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .6s var(--ease);
}
.audio-card:hover .audio-card__cover img { transform: scale(1.06); }
.audio-card__body {
  padding: 1.2rem 1.4rem 1.4rem;
}
.audio-card h4 {
  margin-top: .7rem;
  font-size: 1.1rem;
  color: var(--cream);
}
.audio-card__body p {
  margin-top: .4rem;
  font-size: .85rem;
  color: var(--muted);
}
.audio-card__cta {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  margin-top: 1rem;
  font-size: .76rem;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--gold-soft);
}
.audio-card:hover .audio-card__cta { color: var(--gold); }

/* External link card (vimeo reel) */
.link-card {
  margin-top: 2.4rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  border: 1px solid var(--line);
  padding: 1.6rem 1.8rem;
  transition: border-color .3s ease, background .3s ease;
}
.link-card:hover { border-color: var(--gold-dim); background: var(--surface); }
.link-card__text h4 { font-size: 1.1rem; color: var(--cream); }
.link-card__text p { margin-top: .3rem; font-size: .85rem; color: var(--muted); }
.link-card__icon {
  flex-shrink: 0;
  width: 42px; height: 42px;
  border-radius: 50%;
  border: 1px solid var(--gold-dim);
  display: flex; align-items: center; justify-content: center;
  transition: transform .3s var(--ease), border-color .3s ease;
}
.link-card:hover .link-card__icon { transform: translate(3px,-3px); border-color: var(--gold); }
.link-card__icon svg { width: 15px; height: 15px; stroke: var(--gold-soft); }

/* Formación list (docente) */
.formation {
  margin-top: 2.6rem;
  display: flex;
  flex-direction: column;
}
.formation li {
  display: grid;
  grid-template-columns: 120px 1fr;
  gap: 1.2rem;
  padding: 1.1rem 0;
  border-top: 1px solid var(--line);
}
.formation li:last-child { border-bottom: 1px solid var(--line); }
.formation .yr {
  font-size: .78rem;
  letter-spacing: .05em;
  color: var(--gold);
  padding-top: .15rem;
}
.formation h4 { font-size: 1rem; color: var(--cream); }
.formation p { margin-top: .3rem; font-size: .85rem; color: var(--muted); }

/* Subject tags for docente */
.subjects {
  margin-top: 2.4rem;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: .9rem 1.4rem;
}
@media (max-width: 600px) { .subjects { grid-template-columns: 1fr; } }
.subjects li {
  display: flex;
  align-items: baseline;
  gap: .7rem;
  font-size: .95rem;
  color: var(--cream-dim);
  padding-bottom: .8rem;
  border-bottom: 1px solid var(--line);
}
.subjects li::before {
  content: "";
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--gold);
  flex-shrink: 0;
}

/* AI callout */
.callout {
  margin-top: 2.6rem;
  padding: 1.8rem 2rem;
  border-left: 2px solid var(--gold);
  background: var(--surface);
}
.callout p {
  font-family: var(--font-display);
  font-style: italic;
  font-size: 1.15rem;
  color: var(--gold-soft);
  line-height: 1.55;
}

/* ============================================================
   CONTACT
   ============================================================ */
.contact {
  background: var(--bg-alt);
  border-top: 1px solid var(--line);
  padding: 8rem 0 4rem;
  text-align: center;
}
.contact__kicker {
  font-size: .78rem;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--gold);
}
.contact h2 {
  margin-top: 1.2rem;
  font-size: clamp(2.2rem, 6vw, 4.4rem);
  color: var(--cream);
  line-height: 1.05;
}
.contact h2 em { color: var(--gold); font-style: italic; }
.contact__email {
  margin-top: 2.4rem;
  display: inline-flex;
  align-items: center;
  gap: .8rem;
  font-family: var(--font-display);
  font-size: clamp(1.2rem, 2.6vw, 1.7rem);
  color: var(--cream);
  border-bottom: 1px solid var(--gold-dim);
  padding-bottom: .5rem;
  transition: color .3s ease, border-color .3s ease;
}
.contact__email:hover { color: var(--gold-soft); border-color: var(--gold); }
.contact__links {
  margin-top: 2.6rem;
  display: flex;
  justify-content: center;
  gap: 1.8rem;
  flex-wrap: wrap;
}
.contact__links a {
  font-size: .82rem;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--cream-dim);
  transition: color .3s ease;
}
.contact__links a:hover { color: var(--gold); }

.footer {
  padding: 2.4rem var(--gutter) 3rem;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
  font-size: .76rem;
  color: var(--muted);
  background: var(--bg-alt);
}

/* Utility */
.sr-only {
  position: absolute;
  width: 1px; height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
}

/* ============================================================
   BACKSTAGE — gallery page
   ============================================================ */
.backstage-hero {
  padding: 9.5rem 0 3rem;
}
.backstage-hero .section-title { max-width: 20ch; }
.backstage-hero__count {
  margin-top: 1.2rem;
  font-size: .82rem;
  letter-spacing: .06em;
  color: var(--muted);
}

.gallery {
  columns: 4 260px;
  column-gap: 1.1rem;
  padding: 0 var(--gutter) 6rem;
}
@media (max-width: 700px) {
  .gallery { columns: 2 180px; }
}
.gallery__item {
  break-inside: avoid;
  margin-bottom: 1.1rem;
  position: relative;
  overflow: hidden;
  cursor: zoom-in;
  background: var(--surface);
}
.gallery__item img {
  width: 100%;
  display: block;
  transition: transform .6s var(--ease);
}
.gallery__item:hover img { transform: scale(1.05); }
.gallery__item figcaption {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  padding: 1.6rem .9rem .8rem;
  background: linear-gradient(to top, rgba(11,10,8,.92), rgba(11,10,8,0));
  font-size: .78rem;
  color: var(--cream-dim);
  opacity: 0;
  transform: translateY(6px);
  transition: opacity .35s ease, transform .35s ease;
}
.gallery__item:hover figcaption {
  opacity: 1;
  transform: translateY(0);
}

/* Lightbox */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(6,5,4,.95);
  opacity: 0;
  visibility: hidden;
  transition: opacity .3s ease, visibility 0s linear .3s;
}
.lightbox.is-open {
  opacity: 1;
  visibility: visible;
  transition: opacity .3s ease, visibility 0s linear 0s;
}
.lightbox__content {
  margin: 0;
  max-width: min(90vw, 1200px);
  max-height: 86vh;
  display: flex;
  flex-direction: column;
  align-items: center;
}
.lightbox__content img {
  max-width: 100%;
  max-height: 76vh;
  width: auto;
  object-fit: contain;
}
.lightbox__content figcaption {
  margin-top: 1rem;
  font-size: .85rem;
  color: var(--cream-dim);
  text-align: center;
}
.lightbox__close,
.lightbox__prev,
.lightbox__next {
  position: absolute;
  background: transparent;
  border: 1px solid var(--line);
  border-radius: 50%;
  color: var(--cream);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: border-color .3s ease, background .3s ease;
}
.lightbox__close:hover,
.lightbox__prev:hover,
.lightbox__next:hover {
  border-color: var(--gold);
  background: var(--surface);
}
.lightbox__close {
  top: 1.5rem; right: 1.5rem;
  width: 44px; height: 44px;
}
.lightbox__close svg { width: 16px; height: 16px; }
.lightbox__prev,
.lightbox__next {
  top: 50%;
  transform: translateY(-50%);
  width: 52px; height: 52px;
}
.lightbox__prev { left: 1.5rem; }
.lightbox__next { right: 1.5rem; }
.lightbox__prev svg,
.lightbox__next svg { width: 20px; height: 20px; }
.lightbox__counter {
  position: absolute;
  bottom: 1.6rem;
  left: 50%;
  transform: translateX(-50%);
  font-size: .78rem;
  letter-spacing: .08em;
  color: var(--muted);
}
@media (max-width: 700px) {
  .lightbox__prev, .lightbox__next { width: 40px; height: 40px; }
  .lightbox__prev { left: .6rem; }
  .lightbox__next { right: .6rem; }
  .lightbox__close { top: .8rem; right: .8rem; }
}
