@font-face { font-family:Source; src:url(SourceSans3-Regular.ttf); font-display:swap }
@font-face { font-family:Source; src:url(SourceSans3-Semibold.ttf); font-weight:600; font-display:swap }
@font-face { font-family:Lilita; src:url(LilitaOne-Regular.ttf); font-display:swap }
:root { --plum:#360034; --raspberry:#942146; --cerise:#DE019E; --paper:#FBF6EC; color-scheme:light }
* { box-sizing:border-box }
[hidden] { display:none !important }
body { margin:0; background:var(--paper); color:var(--plum); font:18px/1.35 Source,sans-serif }
h1,h2,legend { margin:0; font:normal 30px/1.04 Lilita,sans-serif }
button,select { font:600 17px/1.15 Source,sans-serif; color:var(--plum); background:#fff; border:1px solid var(--plum); border-radius:8px; padding:10px 16px }
button { cursor:pointer; touch-action:manipulation }
button:disabled { opacity:.55; cursor:default }
button:focus-visible,select:focus-visible,summary:focus-visible,input:focus-visible { outline:3px solid var(--cerise); outline-offset:3px }
header { display:flex; align-items:center; gap:15px; padding-left:clamp(16px,4vw,70px); background:var(--plum); color:white; height:66px }
header img { width:43px; height:39px; object-fit:contain }
header h1 { font-size:29px }
#options { align-self:stretch; height:100%; min-width:85px; margin-left:auto; padding-inline:clamp(17px,3vw,40px); background:var(--plum); color:white; border:0; border-radius:0 }
#options:hover,#options:focus-visible { background:var(--raspberry) }
#options:focus-visible { outline-offset:-4px }
main { display:flex; align-items:flex-start; justify-content:center; gap:20px; width:100%; max-width:1550px; margin:0 auto; padding:clamp(15px,3vh,36px) clamp(16px,3vw,54px) }
#booth { flex:0 1 1050px; min-width:0 }
.frame,.actions,#booth > #status,#review { width:min(100%,max(400px,calc(177.77vh - 360px))); margin-inline:auto }
.frame { position:relative; isolation:isolate; overflow:hidden; background:var(--plum); aspect-ratio:16/9; border-radius:6px 32px 6px 6px }
.frame video { display:block; width:100%; height:100%; object-fit:cover; transform:scaleX(-1) }
#cover { position:absolute; inset:0; display:flex; align-items:center; overflow:hidden; background:var(--plum); color:white }
.cover-copy { position:relative; z-index:1; padding-left:7%; max-width:67% }
.cover-copy h2 { font-size:clamp(43px,7vw,100px) }
.cover-copy p { margin:10px 0 0; font-size:clamp(17px,2.1vw,27px); max-width:17em }
.film { position:absolute; right:6%; top:-26%; bottom:-23%; width:28%; display:flex; flex-direction:column; gap:5%; padding:7% 3.2%; transform:rotate(15deg); background:var(--raspberry); border-inline:2px solid rgba(255,255,255,.09) }
.film::before,.film::after { content:""; position:absolute; top:0; bottom:0; width:5%; background:repeating-linear-gradient(to bottom,transparent 0 12px,var(--paper) 12px 18px,transparent 18px 26px); opacity:.8 }
.film::before { left:3.5% }
.film::after { right:3.5% }
.film i { flex:1; border-radius:3px; background:var(--plum) }
.film i:nth-child(2) { background:var(--cerise) }
#count { position:absolute; inset:0; display:grid; place-items:center; margin:0; pointer-events:none; color:white; font:normal clamp(78px,11vw,154px)/1 Lilita,sans-serif; text-shadow:0 3px 14px var(--plum) }
#shotProgress { position:absolute; top:12px; left:12px; border-radius:6px; background:var(--plum); color:white; padding:6px 13px; font-size:19px; font-weight:600 }
.actions { display:flex; justify-content:center; flex-wrap:wrap; gap:10px; margin-top:15px }
.actions button { min-height:47px; font-size:19px; padding-inline:23px }
.actions .primary { color:white; background:var(--raspberry); border-color:var(--raspberry); min-width:180px }
.actions .primary:not(:disabled):hover { background:var(--plum) }
#status { min-height:1.35em; margin-block:8px 0; text-align:center }
#review { padding-block:clamp(8px,2vh,28px) }
#review h2 { margin:0 0 18px; font-size:clamp(33px,4vw,64px) }
.review-photos { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:clamp(8px,1.3vw,20px) }
.review-photos figure { margin:0; padding:6px; background:white }
.review-photos canvas { display:block; width:100%; height:auto; aspect-ratio:16/9; background:var(--plum) }
.review-photos figcaption { text-align:right; padding:6px 2px 0; font:600 16px Source,sans-serif }
aside { width:min(340px,42%); max-height:calc(100vh - 100px); overflow:auto; background:#fff; padding:18px 22px; border-top:6px solid var(--raspberry) }
fieldset { border:0; border-top:1px solid #EFEBEF; margin:16px 0 0; padding:9px 0 }
legend { font-size:20px }
label,small { display:block; margin:6px 0 }
select,input[type=range] { width:100% }
input { accent-color:var(--raspberry) }
fieldset button { margin:4px 4px 4px 0; font-size:15px }
ul { padding-left:20px; font-size:15px }
output { float:right }
small { color:var(--plum) }

#splash { position:fixed; z-index:20; inset:0; display:grid; place-content:center; justify-items:center; gap:24px; background:var(--plum); pointer-events:none; animation:splash-out 320ms 1040ms both }
.splash-mark img { display:block; width:clamp(76px,10vw,128px); height:auto; animation:mark-in 540ms ease-out both }
.splash-frames { display:flex; gap:6px }
.splash-frames i { width:25px; height:15px; border:2px solid var(--paper); animation:frame-in 380ms ease-out 160ms both }
.splash-frames i:nth-child(2) { animation-delay:310ms }
.splash-frames i:nth-child(3) { animation-delay:460ms }
@keyframes mark-in { from { opacity:0; transform:translateY(12px) } to { opacity:1; transform:none } }
@keyframes frame-in { from { opacity:0; transform:translateX(-11px) } to { opacity:1; transform:none } }
@keyframes splash-out { from { opacity:1 } to { opacity:0; visibility:hidden } }
@media (prefers-reduced-motion:reduce) {
  #splash,.splash-mark img,.splash-frames i { animation:none }
}
@media (orientation:portrait) {
  main { flex-direction:column; align-items:center }
  #booth { flex:none; width:100% }
  aside { width:100%; max-height:none }
  .review-photos { grid-template-columns:1fr; width:min(100%,500px,calc(50vh - 100px)); margin:auto; gap:8px }
  .review-photos figure { position:relative; padding:4px }
  .review-photos figcaption { position:absolute; bottom:8px; right:8px; padding:2px 6px; background:var(--plum); color:white; font-size:13px }
  #review h2 { text-align:center }
}
@media (max-width:600px) {
  header { height:54px }
  header img { width:36px; height:32px }
  .actions { gap:8px }
  .actions button { padding-inline:13px; font-size:17px }
  #booth { width:100% }
}
#lighting {min-width:0}
.light-toolbar {display:flex;flex-wrap:wrap}
#blackout[aria-pressed=true] {background:#360034;color:white}
#lights {list-style:none;padding:0;margin:6px 0}
#lights li {display:flex;gap:6px;align-items:center;justify-content:space-between;font-size:15px;overflow-wrap:anywhere}
#lights .forget {border:0;background:none;text-decoration:underline;font-size:14px;padding:4px}
.light-switch {display:flex;align-items:center;gap:7px;line-height:1.26;padding-block:4px}
#advanced {margin-top:12px;padding:11px 0;border-block:1px solid #EFEBEF}
#advanced summary {cursor:pointer;color:#360034;font-weight:600}
#advanced[open] summary {margin-bottom:12px}
#advanced label {font-size:16px;margin-top:8px}
#advanced input[type=range] {display:block;margin:8px 0;width:100%}
#advanced output {font-variant-numeric:tabular-nums}
#hue {appearance:none;height:16px;border-radius:4px;background:linear-gradient(to right,#f00,#ff0,#0f0,#0ff,#00f,#f0f,#f00)}
#hue::-webkit-slider-thumb {appearance:none;width:17px;height:22px;border:2px solid #360034;border-radius:5px;background:white}
#lighting .device-note {font-size:13px;line-height:1.35;margin-top:12px}
.light-color {display:flex;align-items:center;justify-content:space-between}
#colorPick {width:50%;min-height:40px;padding:3px;background:white;border:1px solid #360034;border-radius:6px;cursor:pointer}
@media (orientation:portrait) {
  main:has(#panel[hidden]) { min-height:calc(100svh - 66px); justify-content:center }
  .frame:has(#cover:not([hidden])) { aspect-ratio:1/1; max-height:calc(100svh - 205px) }
  .actions .primary { min-width:min(100%,240px) }
}
@media (orientation:portrait) and (max-width:600px) {
  main:has(#panel[hidden]) { min-height:calc(100svh - 54px) }
}
