/* Your Body Has Submitted a Formal Complaint (public/templates/body-formal-complaint.html; the film is drawn by complaint.js on one canvas).
   Lettering from the font library, each for its joke: Big Shoulders Stencil (the title and the RECEIVED stamp, like a notice stamped by facilities), Martian Mono
   (the memo lines, the directory, the forms), Instrument Sans (what the departments say, in their bubbles: plain office type), Permanent Marker (the whiteboard and
   the legal pad, on the canvas), Gloock and Libre Caslon Text (the greeting card), Herr Von Muellerhoff (an over-grand signature under an internal memo).
   Only transform and opacity ever move; nothing that moves carries a filter. */
:root { --ink: #23262E; --paper: #FBF8F1; --pink: #E58FA8; --pinkd: #B85A78; --red: #C83A36; --navy: #22314C; --card: #FFFDF8; --gold: #D8A93A; }
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; background: #14161B; color: var(--ink); overflow: hidden; -webkit-tap-highlight-color: transparent; }
body { font-family: 'Instrument Sans', system-ui, sans-serif; }
#film { position: fixed; inset: 0; display: block; z-index: 1; }
.veil, .flash { position: fixed; inset: 0; pointer-events: none; opacity: 0; z-index: 30; }
.veil { background: #0C0D10; }
.flash { background: #F7C6D2; z-index: 31; }

/* a speech bubble at whoever is talking, edged in the colour of their department */
.bubble { position: fixed; left: 0; top: 0; z-index: 45; max-width: min(340px, 80vw); padding: 10px 14px 11px; border-radius: 16px; background: #FFFFFF; color: var(--ink); border-left: 5px solid #9AA4B2; font: 600 clamp(15px, 3.9vw, 19px)/1.32 'Instrument Sans', Arial, sans-serif; box-shadow: 0 6px 18px rgba(0, 0, 0, .28); opacity: 0; pointer-events: none; will-change: transform, opacity; }
.bubble i { position: absolute; left: 0; bottom: -7px; width: 14px; height: 14px; background: inherit; border-radius: 2px; }
.bubble.who-brain { border-left-color: #D97A90; }
.bubble.who-stomach { border-left-color: #D9785F; }
.bubble.who-liver { border-left-color: #8C514B; }
.bubble.who-eyes { border-left-color: #5A86AE; }
.bubble.who-immune { border-left-color: var(--navy); }
.nocc .bubble { visibility: hidden; }

/* the opening: an internal memo, its stamp, Play */
#intro { position: fixed; inset: 0; z-index: 60; display: none; place-items: center; padding: 24px 16px; background: radial-gradient(120% 90% at 50% 30%, #2C2F38 0%, #14161B 72%); color: var(--paper); text-align: center; }
.intro #intro { display: grid; }
.i-box { width: min(460px, 100%); }
#i-pic { width: min(360px, 86vw); height: auto; display: block; margin: 0 auto 16px; }
.i-for { margin: 0 0 8px; font: 500 14px/1.3 'Martian Mono', monospace; color: #C9C4BA; letter-spacing: .04em; }
#intro h1 { margin: 0; font: 800 clamp(32px, 9vw, 50px)/.98 'Big Shoulders Stencil', Impact, sans-serif; letter-spacing: .02em; color: #FFFFFF; text-transform: uppercase; }
#intro h1 b { display: block; font-weight: 800; color: var(--pink); }
.i-tag { margin: 14px 0 24px; font: 500 clamp(13px, 3.6vw, 15px)/1.5 'Martian Mono', monospace; color: #D9D4CA; }
.btn { appearance: none; border: 0; border-radius: 999px; padding: 15px 26px; min-height: 48px; font: 700 16px/1 'Instrument Sans', sans-serif; letter-spacing: .06em; cursor: pointer; background: var(--pink); color: #2A1018; }
.btn:hover { background: #F0A4BA; }
.btn.ghost { background: transparent; color: inherit; box-shadow: inset 0 0 0 2px currentColor; letter-spacing: 0; }
.btn.ghost:hover { background: rgba(0, 0, 0, .05); }
#b-play.wait::after { content: ' ·'; }
.i-quiet { display: block; margin: 14px auto 0; background: none; border: 0; color: #B9B4AA; font: 500 14px/1.2 'Instrument Sans', sans-serif; text-decoration: underline; cursor: pointer; padding: 8px; }

/* during the film: Pause, the words on or off, Skip; quiet, low on the left (the speaker is at the top right, from speaker.js) */
#ctl { position: fixed; left: 12px; bottom: max(14px, env(safe-area-inset-bottom)); z-index: 50; display: none; gap: 8px; flex-wrap: wrap; max-width: calc(100vw - 24px); }
.playing #ctl { display: flex; }
.greet #ctl, .editing #ctl { display: none; }
.pill { appearance: none; border: 0; border-radius: 999px; padding: 9px 14px; min-height: 38px; background: rgba(12, 13, 16, .58); color: #F4F1EA; font: 600 13px/1 'Instrument Sans', sans-serif; cursor: pointer; white-space: nowrap; }
.pill:hover { background: rgba(12, 13, 16, .78); }
#vnote { position: fixed; left: 50%; bottom: max(62px, calc(env(safe-area-inset-bottom) + 56px)); transform: translateX(-50%); z-index: 52; margin: 0; padding: 8px 14px; border-radius: 10px; background: rgba(12, 13, 16, .78); color: #F4F1EA; font: 500 13px/1.35 'Instrument Sans', sans-serif; text-align: center; max-width: calc(100vw - 32px); }

/* the greeting card: an internal memo turned get-well card; in the film it rises over the bedroom, then it stays, with Share and Watch again */
#greet-wrap { position: fixed; inset: 0; z-index: 20; display: grid; place-items: center; padding: 64px 16px 84px; opacity: 0; visibility: hidden; pointer-events: none; }
.greet #greet-wrap { opacity: 1; visibility: visible; pointer-events: auto; background: rgba(20, 22, 27, .5); overflow-y: auto; }
#greet { position: relative; width: min(440px, 100%); will-change: transform; }
.inside { position: relative; padding: 26px 24px 22px; border-radius: 6px; background: var(--card); box-shadow: 0 18px 44px rgba(0, 0, 0, .38); text-align: center; overflow: hidden; }
.inside::before { content: ''; position: absolute; left: 0; right: 0; top: 0; height: 6px; background: var(--pink); }
.g-memo { margin: 4px 0 10px; font: 500 11px/1.3 'Martian Mono', monospace; letter-spacing: .12em; color: #8A8E98; }
.g-for { margin: 0 0 4px; font: 500 15px/1.2 'Libre Caslon Text', Georgia, serif; color: #6A5A50; font-style: italic; }
#t-head { margin: 0 0 14px; font: 400 clamp(30px, 8vw, 40px)/1.05 Gloock, Georgia, serif; color: var(--pinkd); }
#greet .ln { margin: 0 0 10px; font: 400 clamp(15px, 4.1vw, 17px)/1.5 'Libre Caslon Text', Georgia, serif; color: var(--ink); white-space: pre-line; }
#t-msg { font-style: italic; }
.g-sign { margin: 12px 0 4px; font: 400 16px/1.3 'Libre Caslon Text', Georgia, serif; color: #6A5A50; }
.g-from { font: 400 clamp(38px, 10vw, 50px)/1 'Herr Von Muellerhoff', cursive; color: var(--navy); margin-left: 4px; }
#g-stamp { position: absolute; right: 14px; top: 48px; margin: 0; padding: 4px 10px; border: 3px double var(--red); border-radius: 4px; color: var(--red); font: 800 clamp(15px, 4vw, 19px)/1 'Big Shoulders Stencil', Impact, sans-serif; letter-spacing: .12em; transform: rotate(-9deg); opacity: .85; pointer-events: none; will-change: transform, opacity; }
.g-acts { display: none; justify-content: center; gap: 10px; margin-top: 16px; }
.greet .g-acts { display: flex; }
.g-acts .btn { padding: 12px 22px; min-height: 44px; font-size: 15px; letter-spacing: 0; }
.g-acts .ghost { color: var(--pinkd); }
.fine { min-height: 1.2em; margin: 8px 0 0; font: 500 13px/1.3 'Instrument Sans', sans-serif; color: #6A5A50; }

.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
/* the host's guided editor: the card at rest, with nothing playing behind it */
.editing #intro { display: none !important; }
/* less motion: the stills change with a fade, nothing slides */
.rm .bubble { transition: opacity .3s; }
@media (max-width: 420px) { .inside { padding: 22px 18px 18px; } #g-stamp { top: 40px; right: 10px; } }
