@font-face{font-family:"Office Type";src:local("American Typewriter"),local("AmericanTypewriter"),local("ITC American Typewriter Std Medium"),local("AmericanTypewriterStd-Med");font-style:normal;font-weight:400;font-display:swap}
@font-face{font-family:Cutive;src:url("../assets/fonts/Cutive-Regular.ttf") format("truetype");font-style:normal;font-weight:400;font-display:swap}
:root{font:15px Arial,Helvetica,sans-serif;color:#fff;background:#000;--type:"Office Type",Cutive,Georgia,serif;--ui:Tahoma,"MS Sans Serif",Arial,sans-serif;--silver:#c0c0c0;--paper:#d4d4d4;--blue:#000080;--light:#fff;--shadow:#808080}
*{box-sizing:border-box}
[hidden]{display:none!important}
html,body{width:100%;height:100%;margin:0;overflow:hidden}
body{height:100dvh}
.window,.frame{position:fixed;inset:0;width:100%;height:100%;margin:0;padding:0;border:0}
.frame{isolation:isolate;overflow:hidden;background:#272924}
#film-cut{position:absolute;inset:0;display:grid;place-items:center;padding:1.5rem;background:#000;color:white;text-align:center;font:400 clamp(20px,3vw,42px)/1.4 var(--type)}
#film-cut[data-color="white"]{background:#f8f7f2;color:#151515}
body[data-cut="true"] #subtitle-host,body[data-silent-pause="true"] #subtitle-host{visibility:hidden}
#reaction-wait{display:none;position:fixed;right:max(28px,env(safe-area-inset-right));bottom:max(28px,env(safe-area-inset-bottom));width:20px;height:20px;border-radius:50%;border:3px solid #fff9;border-top-color:#242a30;box-shadow:0 0 2px #151515;pointer-events:none}
body[data-silent-pause="true"] .frame{cursor:wait}
body[data-silent-pause="true"]:not(:has(dialog[open])) #reaction-wait{display:block;animation:waiting-turn .85s linear infinite}
@keyframes waiting-turn{to{transform:rotate(1turn)}}
@media(prefers-reduced-motion:reduce){body[data-silent-pause="true"] #reaction-wait{animation:none!important}}
body[data-phase="summary"] .frame{background:#000}
body[data-phase="summary"] .frame>*{visibility:hidden}
#film,.exposure{position:absolute;inset:0;width:100%;height:100%;display:block}
#film{image-rendering:pixelated;outline:none}
body[data-cut="true"] #skill-hud{visibility:hidden}
.exposure{pointer-events:none;background:radial-gradient(ellipse at center,transparent 58%,#00000026 100%)}
.symbol-library{position:absolute;width:0;height:0;overflow:hidden}
.visually-hidden,.progress{position:absolute!important;width:1px!important;height:1px!important;overflow:hidden!important;clip-path:inset(50%);white-space:nowrap}
.chapter{position:absolute;inset:0;display:flex;flex-direction:column;justify-content:center;align-items:center;padding:24px 24px 18vh;background:#00000030;pointer-events:none}
.series-sign{display:flex;align-items:center;gap:24px;padding:26px 34px;background:#fff;color:#181818}
.series-symbol{width:130px;height:118px;flex:none}
.chapter h2{margin:0;font:400 clamp(30px,4vw,55px)/1.3 var(--type);letter-spacing:-2px;white-space:pre-line;font-variant-ligatures:none}
.chapter p{margin:13px 0 0;font-size:13px;text-shadow:0 1px 3px #000}
.chapter.scene-title{justify-content:start;align-items:start;padding:122px 4vw 0;background:none}
.scene-title .series-sign{display:block;background:none;padding:0;color:white}
.scene-title .series-symbol{display:none}
.chapter.scene-title h2{font-size:clamp(20px,2.4vw,32px);letter-spacing:-1px;text-shadow:0 2px 6px #000,0 1px 2px #000}
.chapter.scene-title p{margin-top:7px}
#scene-transition{position:fixed;inset:0;z-index:3;display:flex;flex-direction:column;justify-content:center;align-items:center;padding:24px;text-align:center;background:#000;pointer-events:none}
#scene-transition h2{margin:0;font:400 clamp(25px,4vw,48px)/1.4 var(--type)}
body[data-phase="transition"] #subtitle-host{visibility:hidden}
body[data-phase="intro"] #subtitle-host{display:none}
#credit-name{position:absolute;left:max(18%,env(safe-area-inset-left));bottom:max(7.5%,22px);max-width:76%;font:400 clamp(21px,3.35vw,52px)/1.3 var(--type);color:#fff;text-shadow:0 1px 3px #171510,1px 2px 4px #171510;pointer-events:none}
#credit-name.cast-heading{font-size:clamp(17px,2.7vw,42px)}
@media(max-width:600px){
  #credit-name{left:max(6%,env(safe-area-inset-left));bottom:max(68px,calc(env(safe-area-inset-bottom) + 60px));max-width:88%}
}
#skip-intro{right:max(16px,env(safe-area-inset-right));bottom:max(16px,env(safe-area-inset-bottom))}
.lower-third{position:absolute;bottom:27%;left:5%;display:grid;gap:6px;color:#fff;font:400 clamp(15px,1.35vw,22px)/1.3 var(--type);text-shadow:0 1px 2px #000b}
.lower-third strong{font:400 clamp(22px,2vw,32px)/1.3 var(--type)}
.lower-third span{font:inherit}
#subtitle-host{position:fixed;inset:0;pointer-events:none;z-index:2}
#subtitle-host .console{position:absolute;left:50%;bottom:max(24px,env(safe-area-inset-bottom));transform:translateX(-50%);width:clamp(600px,39vw,940px);max-width:calc(100vw - 32px);max-height:calc(100dvh - 40px);overflow:auto;display:grid;gap:10px;padding:12px;color:#111;background:var(--silver);border:2px solid;border-color:var(--light) #404040 #404040 var(--light);box-shadow:inset 1px 1px #dfdfdf,inset -1px -1px var(--shadow);text-align:left;pointer-events:auto}
.script{min-width:0}
.script h2:empty{display:none}
.script h2{font:700 13px/1.4 var(--ui);margin:0 0 6px}
.script p{font:400 clamp(17px,1.4vw,23px)/1.3 var(--ui);margin:0;overflow-wrap:anywhere}
#subtitle-host .script{padding:8px 12px;background:var(--paper);border:2px solid;border-color:var(--shadow) var(--light) var(--light) var(--shadow);box-shadow:inset 1px 1px #404040;text-shadow:none}
body[data-shot="interview"] #subtitle-host #speaker{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap}
#subtitle-host .script:has(#line:empty){display:none}
#subtitle-host .console:has(#line:empty):has(#actions:empty){visibility:hidden}
#actions{display:flex;align-items:stretch;justify-content:center;gap:10px;flex-wrap:wrap}
#actions button{font:700 14px/1.4 var(--ui);cursor:pointer;min-height:44px;padding:9px 17px}
#subtitle-host #actions{pointer-events:auto;justify-content:flex-end}
#subtitle-host #actions button{min-width:106px;color:#111;background:var(--silver);border:2px solid;border-color:var(--light) #404040 #404040 var(--light);box-shadow:inset -1px -1px var(--shadow)}
#subtitle-host #actions button:hover{background:#d2d2d2}
#subtitle-host #actions button:active{border-color:#404040 var(--light) var(--light) #404040;box-shadow:inset 1px 1px var(--shadow)}
.overlay-button{color:white;background:#171b1bc9;border:1px solid #ffffff50}
.overlay-button:hover{background:#202627ed}
#actions button:disabled{opacity:.55;cursor:wait}
#skill-hud{position:fixed;z-index:3;top:max(12px,env(safe-area-inset-top));left:max(12px,env(safe-area-inset-left));width:clamp(220px,13vw,310px);max-width:calc(100vw - 100px);padding:6px 8px;color:#111;background:var(--silver);font-family:var(--ui);border:2px solid;border-color:var(--light) #404040 #404040 var(--light);box-shadow:inset 1px 1px #dfdfdf,inset -1px -1px var(--shadow);pointer-events:none}
.skill-heading{display:flex;align-items:baseline;justify-content:space-between;gap:12px;font-size:13px}
.skill-heading strong{font-weight:700}
#skill-value{font-variant-numeric:tabular-nums;white-space:nowrap}
#skill-bar{height:18px;margin-top:5px;background:var(--silver);border:2px solid;border-color:var(--shadow) var(--light) var(--light) var(--shadow);box-shadow:inset 1px 1px #404040;padding:2px;overflow:hidden}
#skill-fill{display:grid;grid-template-columns:repeat(20,minmax(0,1fr));gap:2px;width:100%;height:100%}
#skill-fill span.filled{background:var(--blue)}
#skill-feedback{font-size:11px;line-height:1.35;margin:6px 0 0;color:#111}
#skill-feedback:empty{margin:0}
#line.stage-direction{font-style:italic}
#skill-hud[data-outcome="good"] #skill-feedback,#recap [data-outcome="good"]{color:#145724;font-weight:700}
#skill-hud[data-outcome="bad"] #skill-feedback,#recap [data-outcome="bad"]{color:#8a1722;font-weight:700}
.overlay-button{position:fixed;z-index:4;font:600 14px/1.4 Arial,sans-serif;padding:9px 13px;min-height:44px;cursor:pointer}
#menu-toggle{top:max(16px,env(safe-area-inset-top));right:max(16px,env(safe-area-inset-right));font-size:21px;opacity:0}
body.controls-visible #menu-toggle,#menu-toggle:focus-visible,body:is([data-phase="title"],[data-phase="loading"]) #menu-toggle{opacity:1}
#reopen-decision{bottom:max(28px,env(safe-area-inset-bottom));left:50%;transform:translateX(-50%)}
dialog{padding:3px;margin:auto;width:min(660px,calc(100vw - 28px));max-height:calc(100dvh - 28px);overflow:auto;border:2px solid;border-color:#fff #222 #222 #fff;box-shadow:inset 1px 1px #dfdfdf,inset -1px -1px #808080,5px 7px 0 #0005;background:var(--silver);color:#111;font-family:Tahoma,Arial,sans-serif}
dialog::backdrop{background:transparent}
body[data-phase="choice"] #decision-dialog:not(.is-positioned){top:auto;bottom:max(3vh,12px,env(safe-area-inset-bottom));margin:0 auto}
dialog.is-positioned{position:fixed;margin:0;right:auto;bottom:auto}
.dialog-titlebar{cursor:grab;touch-action:none;user-select:none}
.dialog-titlebar.dragging{cursor:grabbing}
.dialog-titlebar{display:flex;align-items:center;justify-content:space-between;gap:12px;background:linear-gradient(90deg,#000080,#1084d0);color:#fff;padding:3px 4px 3px 7px;min-height:29px}
.dialog-titlebar h2{font:bold 13px/1.3 Tahoma,Arial,sans-serif;margin:0}
.dialog-titlebar button{flex:none;padding:0;width:23px;height:23px;border:2px solid;border-color:#fff #404040 #404040 #fff;background:var(--silver);color:#111;font:bold 20px/17px Arial;cursor:pointer}
.dialog-content{display:grid;grid-template-columns:42px minmax(0,1fr);gap:19px;padding:26px 22px 22px}
.error-icon{display:grid;place-items:center;align-self:start;margin-top:3px;width:36px;height:36px;border-radius:50%;background:#c71920;color:#fff;font:bold 37px/1 Arial;border:2px solid #fff;box-shadow:1px 1px 0 #777}
#dialog-slot .console{display:grid;gap:22px}
#dialog-slot .script h2{font:400 12px/1.4 Tahoma,Arial,sans-serif;color:#444;margin-bottom:8px}
#dialog-slot .script p{font:400 15px/1.5 Tahoma,Arial,sans-serif}
#dialog-slot #actions{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}
#dialog-slot #actions button,nav button,nav a{font:400 13px/1.45 Tahoma,Arial,sans-serif;text-align:center;color:#111;background:var(--silver);border:2px solid;border-color:#fff #404040 #404040 #fff;box-shadow:inset -1px -1px #808080;min-height:44px;padding:9px 12px;cursor:pointer}
#dialog-slot #actions button:hover,nav button:hover,nav a:hover{background:#d2d2d2}
#dialog-slot #actions button:active,nav button:active{border-color:#404040 #fff #fff #404040;box-shadow:inset 1px 1px #808080}
:focus-visible{outline:2px dashed #fff;outline-offset:3px}
dialog :focus-visible,#subtitle-host :focus-visible{outline:1px dotted #000;outline-offset:-5px}
#game-menu{width:min(355px,calc(100vw - 28px))}
#game-menu::backdrop{background:#0003}
nav{display:grid;padding:18px 17px 9px;gap:8px}
nav a{text-decoration:none;display:block}
#scene-picker{padding-bottom:16px;font:400 clamp(14px,1.15vw,18px)/1.4 var(--ui)}
#scene-picker label{font-weight:700}
#scene-list{width:100%;min-width:0;font:inherit;color:#111;background:#fff;border:2px solid;border-color:#808080 #fff #fff #808080}
#scene-list option{padding:3px 6px}
#scene-list option:checked{background:var(--blue);color:#fff}
.scene-picker-actions{display:flex;justify-content:flex-end;gap:8px}
#recap{position:fixed;z-index:3;left:50%;top:50%;transform:translate(-50%,-50%);display:flex;flex-direction:column;width:min(1080px,calc(100vw - 48px));max-height:calc(100dvh - 48px);padding:3px;background:var(--silver);color:#171717;border:2px solid;border-color:#fff #404040 #404040 #fff;box-shadow:inset 1px 1px #dfdfdf,inset -1px -1px #808080,4px 5px 0 #0008;font:400 clamp(16px,1.1vw,20px)/1.5 var(--ui)}
.recap-titlebar{display:flex;align-items:center;gap:10px;flex:none;min-height:38px;padding:4px 5px 4px 9px;background:var(--blue);color:#fff}
.recap-envelope{width:24px;height:18px;flex:none}
#recap-heading{flex:1;min-width:0;margin:0;font:700 clamp(15px,1.2vw,20px)/1.3 var(--ui)}
.recap-window-controls{display:flex;gap:4px;flex:none}
.recap-window-controls button{display:grid;place-items:center;width:30px;height:28px;padding:0;color:#111;background:var(--silver);border:2px solid;border-color:#fff #404040 #404040 #fff;box-shadow:inset -1px -1px #808080;font:700 22px/1 Arial;cursor:pointer}
.recap-window-controls #recap-menu{font-size:17px}
.recap-metadata{flex:none;display:grid;grid-template-columns:max-content minmax(0,1fr);align-items:center;gap:6px 16px;margin:0;padding:14px 18px;font-size:clamp(14px,1vw,18px)}
.recap-metadata dt{margin:0}
.recap-metadata dd{min-width:0;margin:0;padding:1px 9px;overflow-wrap:anywhere;background:#fff;border:2px solid;border-color:#808080 #fff #fff #808080;box-shadow:inset 1px 1px #404040}
.recap-message{min-height:0;flex:0 1 auto;overflow:auto;overscroll-behavior:contain;scrollbar-color:#bcbcbc #e5e5e5;scrollbar-width:auto;padding:20px clamp(18px,3vw,34px) 25px;background:#fff;color:#171717;border:2px solid;border-color:#404040 #fff #fff #404040;box-shadow:inset 1px 1px #808080}
.recap-message::-webkit-scrollbar{width:17px}
.recap-message::-webkit-scrollbar-track{background:#e5e5e5;border-left:1px solid #808080}
.recap-message::-webkit-scrollbar-thumb{background:#bcbcbc;border:2px solid;border-color:#fff #808080 #808080 #fff;box-shadow:inset -1px -1px #a0a0a0}
.recap-logo{display:flex;align-items:center;justify-content:flex-end;gap:12px;margin:0 0 20px;color:#191917}
.recap-logo svg{width:60px;height:50px;flex:none}
.recap-logo span{font:400 clamp(23px,2.1vw,29px)/1.25 var(--type);letter-spacing:-1.3px;white-space:nowrap}
.recap-message p{max-width:80ch;margin:0 0 14px;line-height:1.5}
#recap-score{font-weight:700;margin:20px 0 18px}
#recap ol{list-style:none;padding:0;margin:0}
#recap li{padding:18px 0;border-top:1px solid #b5b5b5}
#recap .recap-topic{margin:0 0 5px;font:700 1.08em/1.4 var(--ui)}
#recap .recap-choice{margin:0 0 8px;font-size:.92em;color:#3c3c3c}
#recap .outcome{display:block;margin:0 0 4px;font-size:.9em;font-weight:700}
#recap .recap-result{margin:0}
#recap .recap-postscript{margin:10px 0 16px}
#recap .recap-signoff{margin-bottom:0}
.recap-actions{flex:none;padding:13px 15px 11px}
.recap-actions #actions{justify-content:flex-end;gap:10px}
.recap-actions #actions button{min-width:164px;min-height:44px;padding:8px 18px;font:400 16px/1.3 var(--ui);color:#111;background:var(--silver);border:2px solid;border-color:#fff #404040 #404040 #fff;box-shadow:inset -1px -1px #808080}
.recap-actions #actions button:hover,.recap-window-controls button:hover{background:#d2d2d2}
.recap-actions #actions button:active,.recap-window-controls button:active{border-color:#404040 #fff #fff #404040;box-shadow:inset 1px 1px #808080}
#recap :focus-visible{outline:1px dotted #111;outline-offset:-5px}
body[data-phase="summary"] #subtitle-host,body[data-phase="summary"] #menu-toggle{display:none}
body[data-phase="error"] #subtitle-host .console{top:50%;bottom:auto;transform:translate(-50%,-50%)}
.request-bar,.request-logo{display:none}
body[data-phase="title"] #subtitle-host .console{
  --silver:#c4c4bf;
  left:max(4vw,16px,env(safe-area-inset-left));bottom:max(5vh,16px,env(safe-area-inset-bottom));
  transform:none;width:clamp(435px,33vw,540px);max-width:calc(100% - 32px);max-height:92dvh;
  display:block;padding:3px;box-shadow:inset 1px 1px #dededb,inset -1px -1px #757570,3px 4px 0 #20211970;
}
body[data-phase="title"] .request-bar{
  display:flex;align-items:center;gap:8px;padding:4px 9px;
  background:linear-gradient(90deg,#050970,#205a9d);color:white;font:700 15px/1.35 var(--ui);
}
.request-bar span{font:18px/1 Arial}
body[data-phase="title"] #subtitle-host .script{
  margin:11px 11px 0;padding:16px 21px 19px;background:#f8f6ec;color:#191917;
  border:1px solid;border-color:#74746c white white #74746c;box-shadow:inset 1px 1px #dedbcc;
}
body[data-phase="title"] .request-logo{
  display:flex;align-items:center;gap:13px;margin:0 0 15px;padding-bottom:15px;border-bottom:1px solid #c8c6b9;
}
.request-logo svg{flex:none;width:64px;height:58px}
.script .request-logo h2{margin:0;font:400 clamp(29px,2.4vw,36px)/1.25 var(--type);letter-spacing:-1.6px}
body[data-phase="title"] #speaker{font:700 clamp(16px,1.05vw,19px)/1.4 var(--ui);margin:0 0 5px}
body[data-phase="title"] #line{font:400 clamp(16px,1.05vw,19px)/1.4 var(--ui);white-space:pre-line}
body[data-phase="title"] #subtitle-host #actions{justify-content:flex-start;padding:12px 12px 10px}
body[data-phase="title"] #actions button{min-width:0;min-height:40px;padding:8px 18px;font:400 16px/1.2 var(--ui)}
body[data-phase="title"] #actions .primary{font-weight:700;box-shadow:inset -1px -1px var(--shadow),0 0 0 1px #111}
body[data-phase="title"] #menu-toggle{
  display:grid;place-items:center;width:37px;min-height:34px;padding:0;
  color:#111;background:#c4c4bf;border-color:#f8f8f3 #343431 #343431 #f8f8f3;
  box-shadow:inset 1px 1px #fff,inset -1px -1px #50504d;font-size:19px;
}
@media(max-width:680px){
  body[data-phase="title"] #subtitle-host .console{left:max(16px,env(safe-area-inset-left));bottom:max(16px,env(safe-area-inset-bottom));width:calc(100% - 32px)}
  body[data-phase="title"] #subtitle-host .script{padding:10px 12px}
  body[data-phase="title"] .request-logo{gap:9px;margin-bottom:10px;padding-bottom:10px}
  .request-logo svg{width:43px;height:37px}
  .script .request-logo h2{font-size:clamp(21px,6.6vw,27px)}
  body[data-phase="title"] #actions button{font-size:15px;padding-inline:12px}
  .series-sign{gap:12px;padding:16px}
  .series-symbol{width:70px;height:70px}
  .chapter h2{font-size:clamp(24px,6.2vw,38px);letter-spacing:-1.3px}
  .chapter p{font-size:11px}
  .chapter.scene-title{padding:120px 24px 0}
  .chapter.scene-title h2{font-size:22px}
  .lower-third{bottom:auto;top:125px}
  #subtitle-host .console{width:92vw;gap:10px;padding:10px;bottom:max(16px,env(safe-area-inset-bottom))}
  #subtitle-host .script{padding:9px 11px}
  #actions button{font-size:13px;padding:9px 12px}
  .dialog-content{grid-template-columns:30px minmax(0,1fr);gap:13px;padding:20px 14px 17px}
  .error-icon{width:29px;height:29px;font-size:29px}
  #dialog-slot #actions{grid-template-columns:minmax(0,1fr);gap:9px}
  #dialog-slot .console{gap:18px}
  #dialog-slot #actions button{font-size:14px}
  #recap{width:calc(100vw - 16px);max-height:calc(100dvh - 16px);font-size:15px}
  #recap-heading{font-size:15px}
  #recap-heading span{display:none}
  .recap-titlebar{gap:7px;min-height:44px;padding-left:7px}
  .recap-envelope{width:19px;height:15px}
  .recap-window-controls button{width:35px;height:34px}
  .recap-metadata{gap:5px 9px;padding:10px;font-size:13px}
  .recap-metadata dd{padding-inline:6px}
  .recap-message{padding:15px 16px 20px}
  .recap-logo{gap:9px;margin-bottom:18px}
  .recap-logo svg{width:45px;height:38px}
  .recap-logo span{font-size:22px;letter-spacing:-1.1px}
  .recap-actions{padding:10px 8px 8px}
  .recap-actions #actions{display:grid;grid-template-columns:1fr 1fr;gap:8px}
  .recap-actions #actions button{min-width:0;padding:9px 5px;font-size:14px}
}
@media(max-height:500px){
  .chapter{padding-bottom:30vh}
  .series-symbol{width:70px;height:70px}
  .series-sign{padding:12px 20px}
  .chapter h2{font-size:30px}
  .lower-third{bottom:auto;top:112px}
  #subtitle-host .console{bottom:12px;gap:7px;padding:8px}
  #subtitle-host .script{padding:6px 10px}
  .script p{font-size:16px}
  .dialog-content{padding-block:14px}
  #recap{max-height:calc(100dvh - 16px)}
  .recap-metadata{gap:3px 12px;padding:7px 12px;font-size:13px}
  .recap-actions{padding-block:7px}
}
@media(min-width:681px) and (min-height:501px){
  #subtitle-host .console{width:clamp(660px,48vw,1120px);padding:16px;gap:14px}
  .script h2{font-size:clamp(16px,1vw,20px)}
  .script p{font-size:clamp(21px,1.5vw,29px);line-height:1.4}
  #actions button{font-size:clamp(17px,1.1vw,22px);min-height:50px}
  dialog{width:clamp(780px,58vw,1100px);max-width:calc(100vw - 28px)}
  .dialog-titlebar{min-height:35px}
  .dialog-titlebar h2{font-size:clamp(16px,1.1vw,21px)}
  .dialog-titlebar button{width:28px;height:28px}
  #dialog-slot .script p{font-size:clamp(20px,1.4vw,27px)}
  #dialog-slot #actions button,nav button,nav a{font-size:clamp(17px,1.15vw,22px);padding:13px 16px}
  #skill-hud{width:clamp(290px,19vw,410px);padding:9px 11px}
  .skill-heading{font-size:clamp(16px,1.1vw,21px)}
  #skill-feedback{font-size:clamp(14px,.9vw,18px)}
  #skill-bar{height:23px;margin-top:8px}
  #game-menu{width:min(440px,calc(100vw - 28px))}
}

