/* The entrance is a film selector. The original WebGL reel is the next scene. */
.cut-room {
  --room-edge: clamp(20px, 5.2vw, 88px);
  --room-line: #39332f;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: clamp(90px, 12vh, 144px) var(--room-edge) 20px;
  background: radial-gradient(ellipse at 74% 48%, #271a17 0%, #151212 38%, #0c0c0e 72%);
}

.cut-room__body {
  display: grid;
  grid-template-columns: minmax(230px, .76fr) minmax(0, 1.55fr);
  align-items: center;
  gap: clamp(24px, 5vw, 76px);
  width: 100%;
  max-width: 1550px;
  margin: auto;
}

.cut-room__intro { min-width: 0; padding-block: 20px; }
.cut-room__eyebrow { display: flex; align-items: center; gap: 9px; margin: 0 0 26px; color: var(--accent); }
.cut-room__eyebrow > span:first-child { width: 7px; height: 7px; background: currentColor; border-radius: 50%; }
.cut-room .hero__kinetic {
  font-size: clamp(72px, 9.2vw, 176px);
  line-height: .82;
  font-stretch: 74%;
  letter-spacing: -.067em;
  text-shadow: none;
}
.cut-room .hero__kinetic .ch { font-stretch: 74%; font-weight: 870; }
html:lang(fa) .cut-room .hero__kinetic { font-size: clamp(42px, 6.4vw, 105px); line-height: 1.18; white-space: normal; letter-spacing: 0; }
.cut-room__role { max-width: 24ch; color: #beb5af; font-size: clamp(17px, 1.7vw, 25px); line-height: 1.35; margin: 22px 0 24px; }
.cut-room__link { display: inline-flex; align-items: center; gap: 16px; min-height: 44px; border-bottom: 1px solid var(--accent); transition: color .2s; }
.cut-room__link:hover, .cut-room__foot a:hover { color: var(--accent); }
.cut-room__link span:last-child, .cut-room__foot a span:last-child { color: var(--accent); }

.cut-room__editor { min-width: 0; }
.cut-room__slate { display: flex; justify-content: space-between; padding: 0 0 12px; color: #c6b8ae; }
.cut-room__slate > span:last-child { font-variant-numeric: tabular-nums; }
.cut-room__stage {
  position: relative;
  isolation: isolate;
  height: clamp(338px, 54svh, 585px);
  overflow: hidden;
  direction: ltr;
  touch-action: pan-y pinch-zoom;
  border: 1px solid var(--room-line);
  background: radial-gradient(ellipse at 50% 63%, #4f332a 0%, #201917 48%, #101012 78%);
  --slide: 100%;
  --sense: 1;
}
[dir="rtl"] .cut-room__stage { --sense: -1; }
.cut-room__stage::before {
  content: '';
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(90deg, transparent 0 calc(12.5% - 1px), #e3d4c216 calc(12.5% - 1px) 12.5%), repeating-linear-gradient(0deg, transparent 0 calc(25% - 1px), #e3d4c216 calc(25% - 1px) 25%);
  mask-image: radial-gradient(ellipse, transparent 12%, #000 76%);
  pointer-events: none;
}
.cut-room__guide { position: absolute; inset: 12px; pointer-events: none; z-index: 6; }
.cut-room__guide i { position: absolute; width: 12px; height: 12px; border-color: #ddc4ad90; border-style: solid; }
.cut-room__guide i:nth-child(1) { top: 0; left: 0; border-width: 1px 0 0 1px; }
.cut-room__guide i:nth-child(2) { top: 0; right: 0; border-width: 1px 1px 0 0; }
.cut-room__guide i:nth-child(3) { bottom: 0; left: 0; border-width: 0 0 1px 1px; }
.cut-room__guide i:nth-child(4) { bottom: 0; right: 0; border-width: 0 1px 1px 0; }
.cut-room__frames { position: absolute; inset: 0; perspective: 1050px; }
.cut-frame {
  position: absolute;
  inset: 50% auto auto 50%;
  width: min(45%, calc(clamp(338px, 54svh, 585px) * .48));
  aspect-ratio: 9 / 16;
  overflow: hidden;
  background: #171419;
  border: 1px solid #e8c8a460;
  border-radius: 2px;
  box-shadow: 0 22px 55px #0009;
  transform: translate(-50%, -50%) translateZ(-180px) scale(.75);
  opacity: 0;
  pointer-events: none;
  transition: transform .65s cubic-bezier(.22,.75,.18,1), opacity .38s ease, border-color .2s ease;
}
.cut-frame img { width: 100%; height: 100%; object-fit: cover; user-select: none; }
.cut-frame[data-position="center"] { transform: translate(-50%, -50%); opacity: 1; z-index: 4; pointer-events: auto; border-color: #ead7c6a8; }
.cut-frame[data-position="before"], .cut-frame[data-position="after"] { opacity: .68; pointer-events: auto; z-index: 2; }
.cut-frame[data-position="before"] { transform: translate(-50%, -50%) translateX(calc(var(--slide) * -.88 * var(--sense))) rotateY(calc(29deg * var(--sense))) rotateZ(calc(-8deg * var(--sense))) scale(.78); }
.cut-frame[data-position="after"] { transform: translate(-50%, -50%) translateX(calc(var(--slide) * .88 * var(--sense))) rotateY(calc(-29deg * var(--sense))) rotateZ(calc(8deg * var(--sense))) scale(.78); }
.cut-frame[data-position="off"] { visibility: hidden; }
.cut-frame:hover, .cut-frame:focus-visible { opacity: 1; }
.cut-frame[data-position="off"]:hover { opacity: 0; }
.cut-frame__mark { position: absolute; inset: 8px auto auto 8px; background: #0b0b0de8; color: #fff; padding: 5px 7px; font-size: 10px; }
.cut-frame__play {
  display: grid;
  place-items: center;
  position: absolute;
  inset: auto 11px 11px auto;
  width: 52px;
  height: 52px;
  border: 1px solid #fff8;
  border-radius: 50%;
  background: #141113d9;
  color: #fff;
  font-size: 14px;
  opacity: 0;
  transition: color .2s, background .2s, opacity .2s;
}
.cut-frame[data-position="center"] .cut-frame__play { opacity: 1; }
.cut-frame:hover .cut-frame__play { background: var(--ink); color: var(--bg); }

.cut-room__monitor { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 13px 0 12px; }
.cut-room__film { min-width: 0; }
.cut-room__film p { margin: 0 0 4px; color: #bcaaa0; font-size: 10px; overflow-wrap: anywhere; }
.cut-room__film h2 { margin: 0; font-size: clamp(18px, 2.05vw, 34px); line-height: 1.1; letter-spacing: -.035em; overflow-wrap: anywhere; }
.cut-room__steps { display: flex; gap: 6px; flex: none; }
.cut-room__steps button { width: 46px; height: 44px; border: 1px solid var(--room-line); background: #100e0f; font-size: 20px; transition: border-color .2s, color .2s; }
.cut-room__steps button:hover { border-color: var(--accent); color: var(--accent); }
[dir="rtl"] .cut-room__steps button span { display: inline-block; transform: scaleX(-1); }
.cut-room__filmstrip { display: flex; gap: 5px; overflow-x: auto; padding: 4px 3px; scrollbar-width: thin; scrollbar-color: #715247 transparent; }
.cut-tick { flex: 1 0 38px; min-height: 44px; border: 1px solid var(--room-line); color: #c9b8ac; transition: color .2s, border-color .2s, background .2s; }
.cut-tick[aria-current="true"] { background: var(--accent); border-color: var(--accent); color: #15100c; }
.cut-tick:hover { border-color: var(--accent); }
.cut-room__foot { display: flex; justify-content: space-between; align-items: center; gap: 10px; margin-top: clamp(20px, 4vh, 50px); border-top: 1px solid var(--room-line); color: #bcaaa0; }
.cut-room__foot-divider { color: var(--accent); padding-inline: 5px; }
.cut-room__foot a { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; color: var(--ink); }
.has-cursor .cut-room { cursor: auto; }
body:has(.cut-room:hover) .cursor { visibility: hidden; }

.project-archive { padding: clamp(76px, 11vw, 160px) var(--g); background: #e8e0d5; color: #191615; }
.project-archive__head { display: flex; justify-content: space-between; align-items: end; gap: 14px; border-bottom: 1px solid #25232157; padding-bottom: 20px; margin-bottom: 22px; }
.project-archive__head p { margin: 0; }
.project-archive__label { color: #9e2e13; }
.project-archive__head h2 { margin: 10px 0 0; font-size: clamp(51px, 9vw, 145px); line-height: .9; letter-spacing: -.07em; }
html:lang(fa) .project-archive__head h2 { letter-spacing: 0; line-height: 1.25; }
.project-archive__grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 32px 14px; padding: 0; margin: 0; list-style: none; }
.archive-film button { display: block; width: 100%; text-align: start; }
.archive-film button:focus-visible { outline-color: #9e2e13; }
.archive-film__still { display: block; position: relative; aspect-ratio: 4 / 5; overflow: hidden; background: #181516; }
.archive-film__still img { width: 100%; height: 100%; object-fit: cover; transition: transform .45s var(--ease); }
.archive-film button:hover img { transform: scale(1.04); }
.archive-film__still > span { position: absolute; inset: 8px auto auto 8px; padding: 5px 8px; background: #0c0b0de8; color: #fff; }
.archive-film__caption { display: flex; justify-content: space-between; align-items: center; gap: 8px; padding: 10px 0 12px; border-bottom: 1px solid #25232157; }
.archive-film__caption strong { display: block; font-size: clamp(16px, 2vw, 26px); line-height: 1.15; overflow-wrap: anywhere; }
.archive-film__kind { display: block; margin-bottom: 5px; font-size: 10px; color: #5e4e48; overflow-wrap: anywhere; }
.archive-film__caption > span:last-child { color: #9e2e13; }

@media (max-width: 980px) {
  .cut-room__body { gap: 26px; grid-template-columns: minmax(0, .73fr) minmax(0, 1.3fr); }
  .cut-room .hero__kinetic { font-size: clamp(58px, 9.6vw, 102px); }
}
@media (max-width: 720px) {
  .cut-room { --room-edge: clamp(16px, 4.8vw, 33px); padding-top: 82px; padding-bottom: 9px; background: radial-gradient(ellipse at 55% 53%, #211817, #0c0c0e 74%); }
  .cut-room__body { grid-template-columns: minmax(0, 1fr); gap: 18px; }
  .cut-room__intro { padding: 0; }
  .cut-room__eyebrow { margin-bottom: 10px; }
  .cut-room .hero__kinetic { font-size: clamp(57px, 17vw, 109px); }
  html:lang(fa) .cut-room .hero__kinetic { font-size: clamp(35px, 10vw, 66px); }
  .cut-room__role { font-size: 15px; margin: 8px 0 0; max-width: none; }
  .cut-room__link { font-size: 10px; min-height: 41px; }
  .cut-room__slate { padding-bottom: 7px; }
  .cut-room__stage { height: clamp(237px, 40svh, 460px); --slide: 92%; }
  .cut-frame { width: min(48%, calc(clamp(237px, 40svh, 460px) * .48)); }
  .cut-frame__play { width: 45px; height: 45px; inset: auto 8px 8px auto; }
  .cut-room__monitor { padding: 8px 0 4px; }
  .cut-room__foot { margin-top: 14px; font-size: 10px; }
  .cut-room__foot-divider { padding-inline: 2px; }
  .project-archive__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px 10px; }
  .project-archive__head h2 { font-size: clamp(45px, 11vw, 100px); }
}
@media (max-width: 360px) {
  .cut-room__foot { letter-spacing: .06em; }
  .cut-tick { flex-basis: 34px; }
}

/* ---- Hero: portrait, CTA, trust strip ---- */
.cut-room__cta { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 26px; }
.cut-room__btn { display: inline-flex; align-items: center; gap: 12px; min-height: 48px; padding: 0 22px; background: var(--accent); color: #130c08; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; transition: transform .2s, background .2s; }
.cut-room__btn:hover { background: #ffb07a; transform: translateY(-2px); }
.cut-room__me { position: relative; width: clamp(110px, 11vw, 168px); aspect-ratio: 3 / 4; margin: 30px 0 0; overflow: hidden; border: 1px solid var(--room-line); background: #0c0c0e; }
.cut-room__me img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 22%; filter: grayscale(.35) contrast(1.05); transition: filter .4s, transform .6s; }
.cut-room__me:hover img { filter: none; transform: scale(1.05); }
.cut-room__me figcaption { position: absolute; inset: auto 0 0; display: grid; gap: 2px; padding: 22px 10px 8px; font-size: 10px; letter-spacing: .08em; color: #beb5af; background: linear-gradient(transparent, rgba(8,8,9,.92)); }
.cut-room__me figcaption b { color: #f0ebe6; font-size: 11px; }
.cut-room__trust { max-width: 1550px; width: 100%; margin: 18px auto 0; display: flex; flex-wrap: wrap; gap: 8px 14px; align-items: center; font-size: 11px; letter-spacing: .12em; color: #8d847d; text-transform: uppercase; }
.cut-room__trust b { color: #e6dfd8; font-weight: 600; }
.cut-room__trust i { color: var(--accent); font-style: normal; }
@media (max-width: 760px) { .cut-room__me { display: none; } .cut-room__btn { width: 100%; justify-content: center; } }

/* ---- Bold pass: big portrait, glow, scanline ---- */
.cut-room__me { width: clamp(150px, 15vw, 250px); margin-top: 34px; border-color: var(--accent); box-shadow: 0 0 0 6px rgba(255,122,48,.08), 0 30px 80px -20px rgba(255,122,48,.45); }
.cut-room__me::after { content: ""; position: absolute; left: 0; right: 0; height: 2px; background: linear-gradient(90deg, transparent, var(--accent), transparent); animation: meScan 3.6s ease-in-out infinite; pointer-events: none; }
@keyframes meScan { 0% { top: 4%; opacity: 0; } 12% { opacity: 1; } 88% { opacity: 1; } 100% { top: 96%; opacity: 0; } }
.cut-room__me img { filter: grayscale(.15) contrast(1.1) saturate(1.1); }
.cut-room__me figcaption b { font-size: 13px; }
@media (prefers-reduced-motion: reduce) { .cut-room__me::after { animation: none; display: none; } }
@media (max-width: 760px) {
  .cut-room__me { display: block; width: 100%; aspect-ratio: 4 / 5; margin: 26px 0 8px; }
  .cut-room__me img { object-position: 50% 30%; }
}
