:root {
  --red: #c61c25;
  --black: #050505;
  --white: #ffffff;
  --warm-white: #f7f5f0;
  --sidebar: 224px;
  --gap: 4px;
  --grid-row: 4px;
}

* { box-sizing: border-box; }
html { min-width: 320px; scroll-behavior: smooth; scroll-padding-top: 0; }
body { margin: 0; min-width: 320px; overflow-x: hidden; background: var(--black); color: var(--white); font-family: "Helvetica Neue", Helvetica, Arial, sans-serif; text-rendering: optimizeLegibility; }
button, a { font: inherit; }
button { color: inherit; }
a { color: inherit; }
[hidden] { display: none !important; }

.skip-link { position: fixed; z-index: 100; top: 8px; left: 8px; padding: 9px 13px; background: #fff; color: #000; transform: translateY(-160%); }
.skip-link:focus { transform: none; }

.sidebar {
  position: fixed;
  z-index: 30;
  inset: 0 auto 0 0;
  width: var(--sidebar);
  padding: 30px 22px 24px;
  display: flex;
  flex-direction: column;
  background: var(--white);
  color: #0a0a0a;
  border-right: 1px solid #dedede;
}
.signature { display: block; width: 164px; transform: rotate(-3deg); transform-origin: left center; }
.signature img { display: block; width: 100%; height: auto; }
.signature-subtitle { margin: 10px 0 0; color: rgba(0,0,0,.52); font-size: 8px; letter-spacing: .13em; }
.language-switch { display: flex; align-items: center; gap: 5px; margin-top: 18px; color: rgba(0,0,0,.35); font-size: 9px; font-weight: 800; letter-spacing: .12em; }
.language-switch button { border: 0; padding: 0; background: transparent; color: rgba(0,0,0,.38); cursor: pointer; }
.language-switch button.active { color: var(--red); }
.sidebar nav { display: grid; gap: 16px; margin-top: 46px; }
.sidebar nav a { position: relative; width: fit-content; color: rgba(0,0,0,.58); text-decoration: none; font-size: 11px; font-weight: 780; letter-spacing: .075em; line-height: 1.12; text-transform: uppercase; }
.sidebar nav a:hover, .sidebar nav a:focus-visible, .sidebar nav a.active { color: #000; }
.sidebar nav a.active::before { content: ""; position: absolute; left: -13px; top: .48em; width: 7px; height: 2px; background: var(--red); }
.catalog-status { margin: auto 0 0; color: rgba(0,0,0,.38); font-size: 8px; line-height: 1.5; letter-spacing: .09em; }
.catalog-status span { display: inline-block; width: 6px; height: 6px; margin-right: 6px; border-radius: 50%; background: #4eb56a; }
.menu-toggle { display: none; }

.portfolio-page { margin-left: var(--sidebar); }
.portfolio-section { position: relative; min-height: 240px; padding: 52px 24px 58px; scroll-margin-top: 0; }
.section-direction, .section-about { background: var(--black); color: #fff; }
.section-editing, .section-statement { background: var(--white); color: #080808; }
.section-clients, .section-contact { background: var(--red); color: #050505; }
.section-header { display: flex; align-items: flex-start; justify-content: space-between; gap: 26px; margin-bottom: 26px; }
.section-title { display: block; width: auto; height: var(--title-height-desktop, 82px); max-width: none; object-fit: contain; object-position: left center; }
.section-clients .section-title { transform: rotate(-.5deg); transform-origin: left center; }
.section-meta { flex: 0 0 auto; margin: 9px 0 0; max-width: 190px; font-size: 8px; font-weight: 800; letter-spacing: .12em; line-height: 1.3; text-align: right; text-transform: uppercase; opacity: .58; }
.section-meta strong { font-size: 12px; }

.gallery-toolbar { position: relative; z-index: 8; min-height: 44px; display: flex; align-items: center; justify-content: space-between; gap: 14px; margin: 0 -2px 4px; padding: 6px 2px 8px; background: inherit; }
.filters { display: flex; flex-wrap: wrap; gap: 5px; }
.filters button, .outline-button { border: 1px solid currentColor; border-radius: 0; background: transparent; padding: 6px 9px; cursor: pointer; color: currentColor; font-size: 8px; font-weight: 800; letter-spacing: .09em; text-transform: uppercase; opacity: .72; }
.filters button:hover:not(.active), .filters button:focus-visible:not(.active) { border-color: var(--red); color: var(--red); opacity: 1; }
.filters button.active { border-color: var(--red); background: transparent; color: var(--red); opacity: 1; }
.gallery-count { margin: 0; flex: 0 0 auto; font-size: 8px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; opacity: .48; }

.film-grid {
  display: grid;
  grid-template-columns: repeat(20, minmax(0, 1fr));
  grid-auto-flow: dense;
  grid-auto-rows: var(--grid-row);
  gap: var(--gap);
  align-items: start;
  background: #000;
}
.film-grid.preserve-narrative-order { grid-auto-flow: row; }
.sequence-break { grid-column: 1 / -1; height: 0; min-height: 0; margin: 0; padding: 0; pointer-events: none; }
.sequence-cluster { grid-column: 1 / -1; width: 100%; display: grid; grid-auto-rows: 4px; grid-auto-flow: dense; gap: 4px; align-items: start; justify-self: center; }
.sequence-cluster.opening { grid-template-columns: repeat(20, minmax(0, 1fr)); }
.sequence-cluster.fenatran { max-width: 960px; grid-template-columns: repeat(8, minmax(0, 1fr)); }
.sequence-cluster.latbus-2026 { grid-template-columns: repeat(14, minmax(0, 1fr)); }
.sequence-cluster .film-card.vertical-large { grid-column: span 4; }
.sequence-cluster .film-card.vertical-small { grid-column: span 2; }
.film-card { position: relative; min-width: 0; overflow: hidden; border: 0; border-radius: 0; padding: 0; background: #090909; cursor: pointer; isolation: isolate; }
.film-card.horizontal-small { grid-column: span 4; }
.film-card.horizontal-large { grid-column: span 8; }
.film-card.vertical-small { grid-column: span 2; }
.film-card.vertical-large { grid-column: span 4; }
.film-card img { width: 100%; height: 100%; display: block; object-fit: contain; background: #050505; transition: transform .35s cubic-bezier(.2,.7,.2,1), filter .2s ease; }
.featured-autoplay-layer { position: absolute; z-index: 0; inset: 0; overflow: hidden; background: #050505; opacity: 0; pointer-events: none; transition: opacity .3s ease, transform .35s cubic-bezier(.2,.7,.2,1), filter .2s ease; }
.featured-autoplay-layer.ready { opacity: 1; }
.featured-autoplay-layer iframe { position: absolute; top: 50%; left: 50%; width: 100%; height: 100%; display: block; border: 0; transform: translate(-50%, -50%); pointer-events: none; }
.film-card::after { content: ""; position: absolute; inset: 0; z-index: 1; background: linear-gradient(to top, rgba(0,0,0,.86), rgba(0,0,0,0) 62%); opacity: 0; transition: opacity .18s ease; }
.film-info { position: absolute; z-index: 2; inset: auto 9px 8px; color: #fff; opacity: 0; transform: translateY(6px); transition: opacity .18s ease, transform .18s ease; text-align: left; pointer-events: none; }
.film-info strong { display: block; max-width: 44ch; font-size: 10px; line-height: 1.16; }
.film-info span { display: block; margin-top: 3px; color: rgba(255,255,255,.7); font-size: 7px; letter-spacing: .07em; text-transform: uppercase; }
.film-card:hover img, .film-card:focus-visible img, .film-card.open img,
.film-card:hover .featured-autoplay-layer, .film-card:focus-visible .featured-autoplay-layer, .film-card.open .featured-autoplay-layer { transform: scale(1.01); filter: brightness(.88); }
.film-card:hover::after, .film-card:focus-visible::after, .film-card.open::after, .film-card:hover .film-info, .film-card:focus-visible .film-info, .film-card.open .film-info { opacity: 1; transform: none; }

.section-intro { max-width: 650px; margin: -6px 0 26px; font-size: 13px; line-height: 1.45; }
.client-tags { display: flex; flex-wrap: wrap; align-items: center; gap: 7px; padding-bottom: 34px; }
.client-tag,
.client-tag.collaborator,
.client-tag.standard,
.client-tag.major {
  min-height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(0,0,0,.54);
  border-radius: 0;
  background: transparent;
  color: #050505;
  padding: 9px 11px;
  cursor: pointer;
  font-size: 10px;
  font-weight: 750;
  line-height: 1;
  opacity: 1;
}
.client-tag:hover, .client-tag:focus-visible, .client-tag.active { background: #050505; color: var(--red); opacity: 1; }
.client-results { border-top: 1px solid rgba(0,0,0,.34); padding-top: 24px; }
.client-results-header { display: flex; justify-content: space-between; align-items: end; gap: 18px; }
.client-results-header h2 { margin: 0; font-size: clamp(25px, 3vw, 48px); line-height: .96; letter-spacing: -.025em; }
.micro-label { margin: 0 0 7px; font-size: 8px; font-weight: 800; letter-spacing: .13em; text-transform: uppercase; opacity: .52; }
.client-selection-count { margin: 9px 0 20px; font-size: 10px; opacity: .62; }
.client-film-grid:empty { display: none; }

.statement-copy { max-width: 850px; margin: 0 auto; padding: 18px 24px 52px; font-family: Georgia, "Times New Roman", serif; }
.statement-copy p { margin: 0 0 1.45em; color: #111; font-size: clamp(18px, 1.45vw, 21px); line-height: 1.58; letter-spacing: 0; }
.statement-copy p:last-child { margin-bottom: 0; }
.statement-signature { display: block; width: 220px; height: auto; margin: 18px 0 0 auto; }

.about-layout { display: grid; grid-template-columns: minmax(280px, .88fr) minmax(340px, 1.12fr); gap: clamp(30px, 5vw, 76px); align-items: center; max-width: 1160px; }
.about-portrait, .about-support figure { margin: 0; }
.about-portrait img, .about-support img { display: block; width: 100%; height: auto; object-fit: contain; }
.about-content { align-self: center; }
.about-copy { max-width: 630px; margin: 0; color: rgba(255,255,255,.76); font-family: Georgia, "Times New Roman", serif; font-size: clamp(14px, 1.15vw, 17px); line-height: 1.64; letter-spacing: 0; }
.about-support { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) minmax(160px, .72fr); gap: 4px; margin-top: 46px; align-items: end; }
.about-future-space { min-height: 180px; border: 1px solid rgba(255,255,255,.13); background: #050505; }

.section-contact { min-height: 68vh; display: flex; flex-direction: column; }
.contact-links { display: grid; gap: 12px; margin: auto 0 4vh; max-width: 1000px; }
.contact-links a { display: grid; grid-template-columns: 22px max-content; align-items: center; gap: 12px; width: fit-content; text-decoration: none; color: #050505; }
.contact-links a:hover strong, .contact-links a:focus-visible strong { text-decoration: underline; text-underline-offset: 5px; }
.contact-links strong { display: block; font-size: clamp(15px, 1.45vw, 21px); font-weight: 750; line-height: 1.15; letter-spacing: -.01em; white-space: nowrap; }
.contact-icon { width: 22px; height: 22px; display: grid; place-items: center; }
.contact-links svg { display: block; width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }

.project-view { position: fixed; z-index: 60; inset: 0; display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(350px, .65fr); overflow: auto; background: #090909; color: #fff; }
.project-close { position: fixed; z-index: 62; top: 16px; right: 18px; width: 42px; height: 42px; border: 1px solid rgba(255,255,255,.34); border-radius: 50%; background: rgba(0,0,0,.55); color: #fff; font-size: 28px; line-height: 1; cursor: pointer; }
.project-language-switch { position: fixed; z-index: 62; top: 28px; right: 76px; display: flex; align-items: center; gap: 5px; color: rgba(255,255,255,.3); font-size: 9px; font-weight: 800; letter-spacing: .12em; }
.project-language-switch button { border: 0; padding: 0; background: transparent; color: rgba(255,255,255,.48); cursor: pointer; }
.project-language-switch button.active { color: var(--red); }
.project-language-switch button:focus-visible { outline: 1px solid #fff; outline-offset: 4px; }
.project-media { position: sticky; top: 0; min-height: 100vh; display: grid; grid-template-rows: minmax(0, 1fr) auto; place-items: center; background: #030303; padding: 40px 24px 24px; }
.project-player { width: 100%; max-height: 90vh; aspect-ratio: 16 / 9; display: grid; place-items: center; }
.project-player.vertical { width: auto; height: min(86vh, 900px); aspect-ratio: 9 / 16; }
.project-player img, .project-player iframe { width: 100%; height: 100%; display: block; border: 0; object-fit: contain; }
.project-player-status { position: absolute; left: 50%; bottom: 26px; z-index: 2; transform: translateX(-50%); width: min(520px, calc(100% - 48px)); padding: 9px 12px; background: rgba(0,0,0,.72); color: rgba(255,255,255,.78); font-size: 9px; line-height: 1.45; letter-spacing: .08em; text-align: center; text-transform: uppercase; pointer-events: none; }
.project-player-status.error { bottom: 70px; color: #f0c66d; border: 1px solid rgba(240,198,109,.55); }
.player-unavailable { width: min(520px, calc(100% - 48px)); color: rgba(255,255,255,.68); font-size: 12px; line-height: 1.55; text-align: center; }
.load-player { position: absolute; left: 50%; bottom: 28px; transform: translateX(-50%); border: 1px solid rgba(255,255,255,.4); background: rgba(0,0,0,.66); color: #fff; padding: 9px 12px; cursor: pointer; font-size: 9px; font-weight: 800; letter-spacing: .1em; }
.project-media-controls { width: 100%; min-height: 34px; display: flex; align-items: end; justify-content: flex-start; padding-top: 10px; }
.project-sound { min-height: 34px; border: 1px solid rgba(255,255,255,.38); border-radius: 0; background: transparent; color: rgba(255,255,255,.78); padding: 8px 11px; cursor: pointer; font-size: 9px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; }
.project-sound:hover, .project-sound:focus-visible { border-color: #fff; color: #fff; }
.project-copy { min-height: 100vh; padding: 80px 36px 0; scroll-padding-bottom: calc(var(--project-navigation-height, 140px) + 64px); border-left: 1px solid rgba(255,255,255,.14); box-sizing: border-box; }
.project-copy h1 { margin: 0; font-size: clamp(34px, 4vw, 62px); line-height: .94; letter-spacing: -.035em; }
.project-meta { margin: 18px 0 0; color: rgba(255,255,255,.55); font-size: 10px; letter-spacing: .08em; line-height: 1.6; text-transform: uppercase; }
.project-description { margin-top: 45px; white-space: pre-line; font-size: 14px; line-height: 1.55; }
.project-credits { display: grid; gap: 7px; margin-top: 28px; padding-top: 20px; border-top: 1px solid rgba(255,255,255,.18); }
.credit-row { display: grid; grid-template-columns: 120px 1fr; gap: 12px; font-size: 11px; line-height: 1.4; }
.credit-row strong { color: rgba(255,255,255,.5); font-size: 9px; letter-spacing: .08em; text-transform: uppercase; }
.project-full-credits { margin-top: 28px; border-top: 1px solid rgba(255,255,255,.18); border-bottom: 1px solid rgba(255,255,255,.18); }
.project-full-credits summary { padding: 16px 0; cursor: pointer; color: rgba(255,255,255,.76); font-size: 9px; font-weight: 800; letter-spacing: .11em; list-style-position: outside; }
.project-full-credits[open] summary { color: var(--red); }
.project-full-credits-content { display: grid; gap: 8px; padding: 2px 0 20px; }
.full-credits-department { margin: 18px 0 2px; color: #fff; font-size: 10px; font-weight: 850; letter-spacing: .12em; text-transform: uppercase; }
.full-credits-department:first-child { margin-top: 0; }
.project-dedication { margin: 30px 0 0; padding: 18px 0 18px 18px; border-left: 2px solid var(--red); color: rgba(255,255,255,.82); font-size: 12px; font-style: italic; line-height: 1.55; }
.project-review { margin-top: 28px; padding: 12px; border: 1px solid #d6a43a; color: #f0c66d; font-size: 10px; line-height: 1.45; white-space: pre-line; }
.project-origins { margin-top: 35px; padding-top: 18px; border-top: 1px solid rgba(255,255,255,.18); }
.project-origins h2 { margin: 0 0 10px; font-size: 9px; letter-spacing: .12em; text-transform: uppercase; color: rgba(255,255,255,.55); }
.project-origins a, .project-origins span { display: block; width: fit-content; margin: 5px 0; color: rgba(255,255,255,.68); font-size: 10px; }
.external-link { display: inline-block; margin-top: 28px; font-size: 10px; font-weight: 800; letter-spacing: .09em; }
.project-navigation-spacer { width: 100%; height: calc(var(--project-navigation-height, 140px) + 64px); pointer-events: none; }
.project-navigation { position: fixed; z-index: 61; right: 0; bottom: 0; width: max(350px, 32.5vw); margin: 0; padding: 12px 36px calc(14px + env(safe-area-inset-bottom)); border-top: 1px solid rgba(255,255,255,.18); background: rgba(9,9,9,.96); box-sizing: border-box; backdrop-filter: blur(9px); }
.project-navigation-context { margin: 0 0 12px; color: rgba(255,255,255,.48); font-size: 8px; font-weight: 800; letter-spacing: .12em; line-height: 1.4; text-transform: uppercase; }
.project-navigation-buttons { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.project-navigation button { min-height: 70px; display: flex; flex-direction: column; justify-content: space-between; gap: 9px; border: 1px solid rgba(255,255,255,.26); border-radius: 0; background: transparent; color: #fff; padding: 10px; cursor: pointer; text-align: left; }
.project-navigation button:last-child { text-align: right; align-items: flex-end; }
.project-navigation button strong { font-size: 9px; letter-spacing: .1em; }
.project-navigation button span { max-width: 26ch; color: rgba(255,255,255,.62); font-size: 9px; line-height: 1.3; }
.project-navigation button:hover:not(:disabled), .project-navigation button:focus-visible:not(:disabled) { border-color: var(--red); color: var(--red); outline: 2px solid transparent; }
.project-navigation button:disabled { cursor: default; opacity: .22; }
body.modal-open { overflow: hidden; }

@media (max-width: 1100px) {
  :root { --sidebar: 188px; }
  .sidebar { padding-inline: 17px; }
  .signature { width: 142px; }
  .section-title { height: var(--title-height-tablet, 58px); }
  .film-grid { grid-template-columns: repeat(16, minmax(0, 1fr)); }
  .film-card.horizontal-small { grid-column: span 4; }
  .film-card.horizontal-large { grid-column: span 8; }
  .film-card.vertical-small { grid-column: span 2; }
  .film-card.vertical-large { grid-column: span 4; }
  .sequence-cluster.opening { grid-template-columns: repeat(16, minmax(0, 1fr)); }
  .sequence-cluster.latbus-2026 { grid-template-columns: repeat(8, minmax(0, 1fr)); }
}

@media (max-width: 760px) {
  :root { --sidebar: 0px; }
  html { scroll-padding-top: 68px; }
  .sidebar { position: fixed; inset: 0 0 auto 0; width: 100%; height: 68px; padding: 8px 12px; flex-direction: row; align-items: center; border-right: 0; border-bottom: 1px solid #ddd; }
  .signature { width: 96px; transform: none; }
  .signature-subtitle, .catalog-status { display: none; }
  .language-switch { margin: 0 0 0 12px; }
  .menu-toggle { display: block; margin-left: auto; border: 1px solid rgba(0,0,0,.28); background: transparent; padding: 8px 10px; color: #000; font-size: 9px; font-weight: 800; letter-spacing: .09em; }
  .sidebar nav { position: absolute; top: 100%; left: 0; right: 0; display: none; gap: 14px; margin: 0; padding: 20px 18px 22px; background: #fff; border-bottom: 1px solid #ddd; box-shadow: 0 9px 20px rgba(0,0,0,.12); }
  .sidebar nav.open { display: grid; }
  .sidebar nav a.active::before { left: -10px; width: 5px; }
  .portfolio-page { margin: 68px 0 0; }
  .portfolio-section { padding: 34px 8px 42px; scroll-margin-top: 0; }
  .section-header { align-items: center; margin-bottom: 20px; }
  .section-title { height: var(--title-height-mobile, 38px); max-width: calc(100vw - 16px); }
  .section-meta { max-width: 75px; font-size: 6px; }
  .section-meta strong { font-size: 9px; }
  .section-direction .section-header, .section-editing .section-header { display: block; }
  .section-direction .section-meta, .section-editing .section-meta { max-width: none; margin-top: 8px; text-align: left; }
  .section-clients .section-header { display: block; }
  .section-clients .section-meta { max-width: none; margin-top: 9px; text-align: left; }
  .gallery-toolbar { display: block; padding: 6px 0 8px; }
  .gallery-count { margin-top: 7px; }
  .film-grid { grid-template-columns: repeat(8, minmax(0, 1fr)); }
  .film-card.horizontal-small { grid-column: span 4; }
  .film-card.horizontal-large { grid-column: span 8; }
  .film-card.vertical-small { grid-column: span 2; }
  .film-card.vertical-large { grid-column: span 4; }
  .sequence-cluster.opening { grid-template-columns: repeat(8, minmax(0, 1fr)); }
  .film-info { inset: auto 6px 6px; }
  .film-info strong { font-size: 9px; }
  .film-info span { font-size: 6px; }
  .client-tags { gap: 5px; }
  .client-results-header { align-items: start; }
  .statement-copy { padding: 10px 12px 34px; }
  .statement-copy p { font-size: 18px; line-height: 1.58; }
  .statement-signature { width: 174px; margin-top: 16px; }
  .about-layout { grid-template-columns: 1fr; gap: 24px; }
  .about-portrait { width: min(78vw, 430px); }
  .about-copy { font-size: 15px; line-height: 1.62; }
  .about-support { grid-template-columns: 1fr; margin-top: 28px; }
  .about-future-space { min-height: 110px; }
  .section-contact { min-height: 62vh; }
  .contact-links { gap: 11px; }
  .contact-links a { grid-template-columns: 20px max-content; gap: 10px; }
  .contact-links strong { font-size: 15px; }
  .contact-icon { width: 20px; height: 20px; }
  .contact-links svg { width: 18px; height: 18px; }
  .project-view { grid-template-columns: 1fr; }
  .project-media { position: relative; min-height: 58vh; padding: 28px 10px 14px; }
  .project-player.vertical { height: 56vh; }
  .project-copy { min-height: 0; padding: 42px 18px 0; scroll-padding-bottom: calc(var(--project-navigation-height, 120px) + 56px); border-left: 0; border-top: 1px solid rgba(255,255,255,.14); }
  .project-close { top: 82px; right: 12px; }
  .project-language-switch { top: 98px; right: 66px; }
  .credit-row { grid-template-columns: 1fr; gap: 3px; }
  .project-navigation { width: 100%; padding: 9px 10px calc(10px + env(safe-area-inset-bottom)); }
  .project-navigation-context { margin-bottom: 7px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .project-navigation-buttons { grid-template-columns: 1fr 1fr; }
  .project-navigation button, .project-navigation button:last-child { min-height: 58px; text-align: left; align-items: flex-start; }
  .project-navigation button:last-child { text-align: right; align-items: flex-end; }
  .project-navigation-spacer { height: calc(var(--project-navigation-height, 120px) + 56px); }
}

@media (hover: none) {
  .film-card.open::after, .film-card.open .film-info { opacity: 1; transform: none; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
  .featured-autoplay-layer { display: none !important; }
}
