.film-workspace { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); gap: 1rem; align-items: start; }
.film-workspace textarea { display: block; background: var(--deep); color: var(--white); border-color: #52716a; padding: .8rem; }
.film-workspace textarea::placeholder { color: #a8bcb2; opacity: 1; }
.film-actions { display: flex; flex-wrap: wrap; gap: .6rem; margin-top: .75rem; }
.film-arc .panel-head { margin-bottom: .5rem; }
.beat-graph { display: grid; grid-template-columns: repeat(9, minmax(0, 1fr)); gap: .25rem; margin-top: .8rem; }
.beat-node { display: grid; grid-template-rows: 98px auto; gap: .28rem; width: 100%; padding: .2rem 0; font-size: .875rem; border: 0; background: transparent; color: var(--ink); text-align: center; }
.beat-node:disabled { opacity: 1; cursor: default; }
.beat-node .track { display: flex; flex-direction: column; justify-content: end; border-bottom: 1px solid #9ab5a8; }
.beat-node .bar { --step: 10%; height: calc(attr(data-intensity type(<number>), 5) * var(--step)); border-radius: .4rem .4rem 0 0; background: #80af9e; }
.beat-node:nth-child(8) .bar { background: #cf7343; }
.beat-node:hover:not(:disabled) .bar, .beat-node:focus-visible .bar { filter: brightness(.74); }
.beat-node .number { font-variant-numeric: tabular-nums; font-weight: 700; color: var(--muted); }
.cast-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .7rem; }
.cast-card { padding: 1rem; background: var(--white); border: 1px solid var(--line); border-radius: .8rem; }
.cast-card .panel-head { margin-bottom: .5rem; }
.cast-card .scene-fields { margin-top: 0; }
.cast-card label:first-child { grid-column: 1 / -1; }
.cast-checks { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem .8rem; margin: .95rem 0; padding: .55rem .8rem; border: 1px solid var(--line); border-radius: .5rem; }
.cast-checks legend { padding: 0 .2rem; font-size: .875rem; font-weight: 700; }
.cast-checks label { display: flex; gap: .3rem; align-items: center; font-size: .9rem; }
.cast-checks input[type=checkbox] { width: auto; accent-color: #24735d; }
.film-beats-note { margin: -.3rem 0 .95rem; }
.beat-note { margin-top: .65rem; color: var(--muted); }
.shot-fields { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .6rem; margin-top: .75rem; }
.shot-fields label { display: grid; gap: .25rem; font-size: .875rem; font-weight: 700; }
#film-project .section-head .film-actions { margin-top: 0; }
@supports not (height: calc(attr(data-intensity type(<number>), 5) * 10%)) {
  .beat-node:nth-child(1) .bar, .beat-node:nth-child(9) .bar { height: 20%; }
  .beat-node:nth-child(2) .bar, .beat-node:nth-child(7) .bar { height: 40%; }
  .beat-node:nth-child(3) .bar { height: 60%; }
  .beat-node:nth-child(4) .bar, .beat-node:nth-child(6) .bar { height: 70%; }
  .beat-node:nth-child(5) .bar { height: 80%; }
  .beat-node:nth-child(8) .bar { height: 100%; }
}
@media (max-width: 890px) { .film-workspace { grid-template-columns: 1fr; } }
@media (max-width: 550px) { .cast-list, .shot-fields { grid-template-columns: 1fr; } }

.film-signin { display: inline-block; margin-top: .65rem; color: var(--jade); font-size: .9rem; }
.film-example { display: grid; grid-template-columns: minmax(0, .82fr) minmax(0, 1.18fr); align-items: center; gap: 1.4rem; margin: 1rem 0 2rem; padding: clamp(1rem, 3vw, 1.7rem); border: 1px solid var(--line); border-radius: 1.15rem; background: var(--white); }
.example-copy > p:not(.section-name) { margin-top: .8rem; max-width: 45ch; }
.example-copy .button { margin-top: .9rem; }
.film-example video, #cut-preview { display: block; width: 100%; max-height: 430px; aspect-ratio: 16/9; background: var(--deep); border-radius: .7rem; }
.film-live { min-height: 0; color: var(--muted); margin: .5rem 0; font-size: .9rem; }
.film-live:empty { display: none; }
.film-revision { margin-top: 1.2rem; }
.film-revision label { font-weight: 750; }
.revision-row { display: flex; gap: .7rem; align-items: end; margin-top: .45rem; }
.shot-card { display: grid; align-content: start; gap: .55rem; min-width: 0; border-radius: .7rem; padding: .75rem; border: 1px solid var(--line); }
.shot-card .shot-image, .shot-card video { width: 100%; aspect-ratio: 16/9; object-fit: cover; background: var(--deep); border-radius: .45rem; }
.shot-card img, .cast-card img { display: block; }
.cast-card img { width: min(155px, 50%); aspect-ratio: 4/5; object-fit: cover; border-radius: .5rem; margin-bottom: .65rem; }
.asset-actions { display: flex; flex-wrap: wrap; gap: .38rem; align-items: center; }
.asset-actions .button { min-height: 38px; font-size: .825rem; white-space: normal; text-align: center; }
.asset-actions input { max-width: 100%; }
.asset-actions .quiet-control { min-height: 36px; border: 0; background: transparent; color: var(--muted); text-decoration: underline; font-size: .825rem; }
.shot-card .help { margin-top: 0; }
.shot-label { color: var(--muted); font-size: .875rem; font-weight: 700; }
.shot-card details { font-size: .875rem; color: var(--muted); }
.shot-card pre { white-space: pre-wrap; overflow-wrap: anywhere; margin: .45rem 0 0; color: var(--ink); }
.soundtrack { display: grid; gap: .45rem; font-weight: 700; margin: .85rem 0 0; justify-items: start; }
#cut-preview { margin-top: .9rem; max-width: 750px; }
@media (max-width: 695px) {
  .film-example { grid-template-columns: 1fr; }
  .revision-row { flex-wrap: wrap; }
}

.local-file { cursor: pointer; }
.local-file:has(input:focus-visible) .button { outline: 3px solid #268772; outline-offset: 2px; }
.local-file:has(input:disabled) { opacity: .65; cursor: wait; }
