.top, main { max-width: 1180px; }
.top { padding-top: 28px; }
.studio-actions { gap: 18px; }
.studio-actions .link, .booth-link { font-size: .875rem; }
.active { background: var(--coral); color: #fff; }
main { padding-top: 52px; }
.eyebrow { font-size: .75rem; font-weight: 700; letter-spacing: .14em; color: var(--muted); margin: 0 0 15px; }
.page-heading { display: flex; justify-content: space-between; align-items: flex-start; gap: 20px; }
.page-heading h1 { font-size: clamp(2.6rem, 5vw, 4rem); }
.page-heading .lede { max-width: 66ch; }
.page-heading > button { white-space: nowrap; margin-top: 38px; }
.project-bar { display: flex; align-items: center; justify-content: space-between; gap: 18px; padding: 18px 0; border-top: 1px solid var(--line); }
.project-name { font-size: .75rem; color: var(--muted); width: min(100%, 320px); flex-shrink: 0; }
.project-name input { display: block; font: 600 1rem var(--sans); color: var(--ink); padding: 4px 0; background: none; border: 0; width: 100%; }
.project-tools { display: flex; gap: 16px; align-items: center; font-size: .875rem; flex-wrap: wrap; }
#save-state { color: var(--muted); }
.steps { display: grid; grid-template-columns: repeat(4, 1fr); border-bottom: 1px solid var(--line); margin: 12px 0 30px; }
.steps button { padding: 18px 10px; font: 600 1rem var(--sans); color: var(--muted); background: transparent; border: 0; border-bottom: 3px solid transparent; cursor: pointer; }
.steps button[aria-current="step"] { color: var(--ink); border-color: var(--coral); }
button:disabled, input:disabled, select:disabled { cursor: default; opacity: .5; }
.steps button:disabled { opacity: .45; }
.idea-grid { display: grid; grid-template-columns: .9fr 1.1fr; gap: 44px; }
.voice-card { border: 1px solid #e7d7ce; border-radius: 20px; background: #f2e9e1; text-align: center; padding: 32px 28px; display: flex; flex-direction: column; align-items: center; }
.voice-card h2 { font-size: 2rem; }
.voice-card p { color: var(--muted); margin: 0 0 24px; }
.voice-card .hint { font-size: .875rem; margin: 12px 0; }
.voice-card audio { width: 100%; max-width: 320px; margin: 14px 0; }
.voice-art { display: flex; align-items: center; justify-content: center; gap: 6px; width: 120px; height: 120px; background: #faf6f1; border: 1px solid #e9d9ce; border-radius: 50%; margin: 8px 0 28px; }
.voice-art span { height: 16px; width: 5px; background: var(--coral); border-radius: 6px; }
.voice-art span:nth-child(2n) { height: 32px; }
.voice-art span:nth-child(3n) { height: 46px; }
.voice-art span:nth-child(5) { height: 62px; }
.recording .voice-art span { animation: wave .7s ease-in-out infinite alternate; }
.recording .voice-art span:nth-child(2n) { animation-delay: .3s; }
@keyframes wave { to { transform: scaleY(.4); } }
.idea-fields { padding-top: 5px; }
.idea-fields textarea { min-height: 195px; }
.settings-row { display: flex; gap: 20px; margin: 24px 0; }
.settings-row label { flex: 1; font-size: .875rem; font-weight: 600; }
select { display: block; width: 100%; min-width: 0; margin-top: 8px; padding-right: 32px; appearance: none; background-image: linear-gradient(45deg, transparent 50%, #656763 50%), linear-gradient(135deg, #656763 50%, transparent 50%); background-position: calc(100% - 20px) 50%, calc(100% - 15px) 50%; background-size: 5px 5px; background-repeat: no-repeat; }
.privacy-note { padding: 22px 0; margin-top: 20px; color: var(--muted); font-size: .875rem; max-width: 100ch; }
.privacy-note strong { color: var(--ink); }
.device-note { border-top: 1px solid var(--line); padding-top: 22px; margin-top: 36px; font-size: .875rem; color: var(--muted); max-width: 100ch; }
.section-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 24px; margin: 22px 0; }
.section-top .lede { margin-bottom: 0; }
.section-top > button, .section-top > label { flex-shrink: 0; }
.file-button { display: inline-block; position: relative; border: 1px dashed #96978f; padding: 12px 16px; border-radius: 10px; font-size: .875rem; font-weight: 600; cursor: pointer; background: #ffffff70; text-align: center; }
.file-button input { position: absolute; opacity: 0; width: 100%; height: 100%; inset: 0; cursor: pointer; }
.file-button:has(:focus-visible) { outline: 3px solid var(--coral); }
.file-button:has(:disabled) { opacity: .5; }
.scene-options { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin: 22px 0; }
.scene-option { padding: 20px; background: var(--card); border: 1px solid var(--line); border-radius: 14px; }
.scene-option label { font-weight: 600; }
.scene-option textarea { min-height: 150px; font-size: .875rem; margin: 12px 0; }
.scene-option button { padding: 12px 18px; font-size: .875rem; }
.asset-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 18px; margin: 24px 0; }
.asset-card { padding: 8px; background: var(--card); border: 1px solid var(--line); border-radius: 14px; min-width: 0; }
.asset-card.selected { border-color: var(--coral); box-shadow: 0 0 0 2px var(--coral); }
.image-choice { width: 100%; border: 0; background: var(--paper); border-radius: 8px; padding: 0; cursor: pointer; overflow: hidden; display: block; }
.image-choice img { width: 100%; height: 230px; object-fit: contain; display: block; }
.asset-caption { display: flex; align-items: start; justify-content: space-between; gap: 8px; padding: 10px 4px 4px; font-size: .875rem; }
.asset-caption strong { display: block; }
.asset-caption span { color: var(--muted); }
.asset-tools { display: flex; gap: 10px; padding: 4px; flex-wrap: wrap; font-size: .875rem; }
.asset-tools a { text-decoration: underline; }
.asset-card .link { padding: 0; }
.step-footer { display: flex; justify-content: space-between; gap: 20px; margin-top: 32px; padding-top: 24px; border-top: 1px solid var(--line); }
.character { background: #fff9; border: 1px solid var(--line); padding: 24px; border-radius: 16px; margin: 22px 0; }
.character-name { font: 400 1.7rem var(--serif); border: 0; background: transparent; color: var(--ink); width: 100%; margin-bottom: 12px; }
.character-description { font-size: .875rem; min-height: 75px; margin-bottom: 16px; }
.character-tools { display: flex; align-items: flex-end; flex-wrap: wrap; gap: 14px; }
.character-tools label { font-size: .875rem; }
.character-tools .secondary { padding: 13px 18px; }
.review-images { display: flex; gap: 10px; overflow-x: auto; margin: 24px 0 10px; }
.review-images figure { margin: 0; min-width: 110px; max-width: 140px; }
.review-images img { width: 110px; height: 130px; object-fit: cover; border-radius: 8px; }
.review-images figcaption { font-size: .875rem; }
#style, #sound { min-height: 82px; }
.shots { margin: 24px 0; display: grid; gap: 18px; }
.shots label { display: block; font-weight: 600; margin-bottom: 8px; }
.shots textarea { min-height: 86px; }
.prompt-details { margin: 20px 0; }
.prompt-details pre { white-space: pre-wrap; overflow-wrap: anywhere; font: .875rem/1.6 var(--sans); background: white; border: 1px solid var(--line); padding: 20px; border-radius: 12px; }
.work-status, .message, .storage-warning { padding: 16px 20px; border-radius: 10px; margin-bottom: 20px; background: #f2e9e1; }
.storage-warning { color: #7b3e12; background: #fff1d8; }
.library { margin-bottom: 24px; }
.library .section-top { margin-top: 0; }
.project-row { display: flex; gap: 16px; align-items: center; padding: 14px 0; border-bottom: 1px solid var(--line); }
.project-row .open-project { flex: 1; text-align: left; font: 600 1rem var(--sans); border: 0; background: none; color: var(--ink); cursor: pointer; }
.project-row small { display: block; font-size: .875rem; color: var(--muted); font-weight: 400; }
.library > .file-button { margin-top: 20px; }
.video-results { margin-top: 28px; display: grid; gap: 24px; }
.video-result video { width: 100%; max-height: 560px; background: #202222; border-radius: 14px; }
.video-result .asset-tools { padding-top: 12px; }
#video-progress { margin-top: 26px; }
#gate-error { margin-top: 18px; }
@media (max-width: 760px) {
  main { padding-top: 32px; }
  .top { align-items: flex-start; }
  .studio-actions { gap: 8px 14px; margin-left: 0; }
  .idea-grid { grid-template-columns: 1fr; gap: 28px; }
  .voice-card { padding: 26px 20px; }
  .voice-art { width: 88px; height: 88px; margin-bottom: 20px; }
  .page-heading { flex-wrap: wrap; }
  .page-heading > button { margin-top: 0; margin-bottom: 22px; }
  .page-heading .lede { margin-bottom: 0; }
  .project-bar { align-items: flex-start; flex-direction: column; }
  .project-tools { gap: 8px 14px; }
  .steps button { font-size: .875rem; padding: 16px 4px; }
  .scene-options { grid-template-columns: 1fr; }
  .section-top { flex-wrap: wrap; gap: 16px; }
  .scene-option textarea { min-height: 105px; }
  .asset-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
  .image-choice img { height: 180px; }
  .character { padding: 18px; }
  .character-tools { align-items: stretch; flex-direction: column; }
  .step-footer { align-items: center; }
  .step-footer .primary { padding: 14px 18px; line-height: 1.3; }
  .settings-row { gap: 12px; }
  .settings-row select { font-size: .875rem; padding-left: 10px; }
}
@media (prefers-reduced-motion: reduce) { .recording .voice-art span { animation: none; } }
