/* request 73 / 76 / 77: pre-mission comms film (src/comms.js). Request 77 laid it out again in container units (#app is a
   size container), so every 16:9-ish screen — phone held either way, tablet, desktop — gets the same proportions:
   brass monitors top-left / top-right with name plates, the new-unit strip between them, the subtitle box bottom-centre,
   Skip top-right. */
#comms { position: absolute; inset: 0; z-index: 90; background: #05080a; overflow: hidden; opacity: 0; transition: opacity .3s ease-out; font-family: var(--font, sans-serif); color: #e8f0d8; touch-action: none;
  --side: max(16px, 3cqw, env(safe-area-inset-left)); --sideR: max(16px, 3cqw, env(safe-area-inset-right)); --top: 16cqh;
  --hqw: min(28cqw, 50cqh); --mew: min(17cqw, 30cqh); --brass: #c8a85a; --gold: #ffd24a; }
#comms.in { opacity: 1; }
#comms.out { opacity: 0; transition-duration: .25s; }
#comms .cmsit { position: absolute; inset: 0; }
#comms .cmsit img { width: 100%; height: 100%; object-fit: cover; filter: saturate(.75) contrast(1.08) brightness(.72); animation: cmpan 14s ease-out forwards; transition: filter .5s; }
@keyframes cmpan { from { transform: scale(1.12); } to { transform: scale(1.0); } }
#comms .cmnoise { position: absolute; inset: 0; pointer-events: none;
  background: repeating-linear-gradient(0deg, rgba(0,0,0,.26) 0 2px, rgba(0,0,0,0) 2px 4px), radial-gradient(ellipse at center, rgba(0,0,0,0) 45%, rgba(0,0,0,.78) 100%);
  animation: cmflick 3.1s steps(1) infinite; }
@keyframes cmflick { 0%,100% { opacity: 1; } 47% { opacity: .84; } 48% { opacity: 1; } 71% { opacity: .9; } 72% { opacity: 1; } }

/* the room's frame: brass corner brackets that draw themselves in, and a scan line on boot */
#comms .cmframe { position: absolute; inset: 8px; pointer-events: none; border: 1px solid rgba(200,168,90,0); border-radius: 10px;
  box-shadow: inset 0 0 0 1px rgba(0,0,0,.6), inset 0 0 60px rgba(0,0,0,.5);
  background-image: linear-gradient(var(--brass),var(--brass)), linear-gradient(var(--brass),var(--brass)), linear-gradient(var(--brass),var(--brass)), linear-gradient(var(--brass),var(--brass)),
    linear-gradient(var(--brass),var(--brass)), linear-gradient(var(--brass),var(--brass)), linear-gradient(var(--brass),var(--brass)), linear-gradient(var(--brass),var(--brass));
  background-repeat: no-repeat;
  background-position: left top, left top, right top, right top, left bottom, left bottom, right bottom, right bottom;
  background-size: 0 3px, 3px 0, 0 3px, 3px 0, 0 3px, 3px 0, 0 3px, 3px 0;
  transition: background-size .55s ease-out .1s, border-color .6s .3s; }
#comms.in .cmframe { border-color: rgba(200,168,90,.3); background-size: 30px 3px, 3px 30px, 30px 3px, 3px 30px, 30px 3px, 3px 30px, 30px 3px, 3px 30px; }
#comms .cmframe::after { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 2px; opacity: 0; background: rgba(210,255,190,.85); box-shadow: 0 0 14px rgba(210,255,190,.8); }
#comms.boot .cmframe::after { animation: cmsweep .55s ease-in both; }
@keyframes cmsweep { 0% { top: 0; opacity: 1; } 100% { top: 100%; opacity: .2; } }

/* top row: link tag (right of the back-button corner), mission number centred, Skip top-right */
#comms .cmtag, #comms .cmloc { position: absolute; top: max(12px, env(safe-area-inset-top)); display: flex; align-items: center; gap: 8px; padding: 5px 12px;
  background: rgba(12,20,12,.78); border: 1px solid var(--brass); border-radius: 5px; box-shadow: inset 0 0 0 1px rgba(0,0,0,.6);
  font-weight: 900; font-size: clamp(12px, 2.6cqh, 17px); letter-spacing: .06em; text-shadow: 0 2px 0 #000; white-space: nowrap; }
#comms .cmtag { left: max(76px, calc(env(safe-area-inset-left) + 70px)); }
#comms .cmloc { left: 50%; transform: translateX(-50%); color: #f4e6bc; }
#comms .cmdot { width: 10px; height: 10px; border-radius: 50%; background: #ff3b2e; box-shadow: 0 0 8px #ff3b2e; animation: cmblink 1s steps(1) infinite; }
@keyframes cmblink { 50% { opacity: .15; } }
#comms .cmskip { position: absolute; top: max(10px, env(safe-area-inset-top)); right: var(--sideR); min-width: 76px; min-height: 44px; padding: 6px 16px; z-index: 3;
  font: 900 clamp(14px, 2.6cqh, 17px) var(--font, sans-serif); color: #f4ead0; letter-spacing: .06em; cursor: pointer;
  background: linear-gradient(#3a4426, #222a16); border: 2px solid var(--brass); border-radius: 6px; box-shadow: inset 0 1px 0 rgba(255,240,190,.25), 0 3px 0 #0b0e07; text-shadow: 0 2px 0 #000; transition: transform .1s, filter .15s; }
#comms .cmskip:hover { filter: brightness(1.2); }
#comms .cmskip:active { transform: translateY(2px) scale(.97); box-shadow: inset 0 1px 0 rgba(255,240,190,.2), 0 1px 0 #0b0e07; }

/* the incoming call */
#comms .cmcall { position: absolute; left: 50%; top: 47%; transform: translate(-50%, -50%); display: none; flex-direction: column; align-items: center; gap: 6px; text-align: center; max-width: 80%;
  padding: 16px 28px 14px; background: rgba(10,18,10,.6); border: 1px solid rgba(200,168,90,.55); border-radius: 8px; animation: cmpop .35s ease-out both; }
#comms.ring .cmcall { display: flex; }
@keyframes cmpop { from { opacity: 0; transform: translate(-50%, -46%) scale(.94); } to { opacity: 1; transform: translate(-50%, -50%) scale(1); } }
#comms .cmring { width: clamp(64px, 20cqh, 120px); aspect-ratio: 1; border-radius: 50%; overflow: hidden; border: 3px solid var(--gold); animation: cmpulse .7s ease-in-out infinite; }
#comms .cmring img { width: 100%; height: 100%; object-fit: cover; }
@keyframes cmpulse { 0%,100% { box-shadow: 0 0 0 0 rgba(255,210,74,.7); } 50% { box-shadow: 0 0 0 14px rgba(255,210,74,0); } }
#comms .cmcall b { font-weight: 900; font-size: clamp(16px, 4.2cqh, 30px); letter-spacing: .08em; color: var(--gold); text-shadow: 0 2px 0 #000, 0 0 12px rgba(0,0,0,.8); }
#comms .cmcall span { font-weight: 900; font-size: clamp(14px, 2.9cqh, 20px); text-shadow: 0 2px 0 #000; }
#comms .cmcall i { font-style: normal; font-size: clamp(12px, 2.2cqh, 15px); opacity: .85; animation: cmblink 1s steps(1) infinite; }
#comms.ring .cmsit img { filter: saturate(.2) brightness(.35) blur(2px); }
#comms.boot .cmnoise { animation: cmboot .55s steps(6) forwards; background-color: rgba(220,230,210,.45); }
@keyframes cmboot { 0% { opacity: 1; transform: scaleY(.02); } 30% { opacity: 1; transform: scaleY(1); } 100% { opacity: .9; background-color: rgba(220,230,210,0); } }

/* the two monitors: brass frame with four screws, the screen with scanlines, a name plate with its lamp and signal bars */
#comms .cmfeed { position: absolute; top: var(--top); box-sizing: border-box; width: var(--hqw); padding: 9px 9px 8px; border-radius: 7px; transform-origin: 50% 0;
  background:
    radial-gradient(circle, #2a1f0a 0 1.4px, #f2dc9c 1.9px 2.9px, #5c4718 3.3px, transparent 3.8px) left 1px top 1px / 9px 9px no-repeat,
    radial-gradient(circle, #2a1f0a 0 1.4px, #f2dc9c 1.9px 2.9px, #5c4718 3.3px, transparent 3.8px) right 1px top 1px / 9px 9px no-repeat,
    radial-gradient(circle, #2a1f0a 0 1.4px, #f2dc9c 1.9px 2.9px, #5c4718 3.3px, transparent 3.8px) left 1px bottom 1px / 9px 9px no-repeat,
    radial-gradient(circle, #2a1f0a 0 1.4px, #f2dc9c 1.9px 2.9px, #5c4718 3.3px, transparent 3.8px) right 1px bottom 1px / 9px 9px no-repeat,
    linear-gradient(155deg, #9c8042 0%, #d6b968 22%, #7a6028 55%, #b49450 80%, #6c5424 100%);
  border: 1px solid #2a2010; box-shadow: 0 8px 22px rgba(0,0,0,.65), inset 0 1px 0 rgba(255,240,190,.45);
  transition: transform .25s ease-out, box-shadow .25s; }
#comms .cmhq { left: var(--side); }
#comms .cmme { right: var(--sideR); width: var(--mew); }
#comms .cmscr { position: relative; aspect-ratio: 3 / 2; overflow: hidden; background: #000; border: 2px solid #1b1d12; border-radius: 4px; transition: border-color .25s, box-shadow .25s; }
#comms .cmme .cmscr { aspect-ratio: 4 / 5; }
#comms .cmscr video, #comms .cmscr img { width: 100%; height: 100%; object-fit: cover; display: block; filter: brightness(.68) saturate(.85); transition: filter .25s; }
#comms .cmscr::after { content: ""; position: absolute; inset: 0; pointer-events: none;
  background: repeating-linear-gradient(0deg, rgba(0,0,0,.2) 0 1px, rgba(0,0,0,0) 1px 3px), linear-gradient(160deg, rgba(255,255,255,.12), rgba(255,255,255,0) 32%), radial-gradient(ellipse at center, rgba(0,0,0,0) 55%, rgba(0,0,0,.55) 100%); }
#comms .cmplate { margin-top: 6px; padding: 3px 7px 4px; background: linear-gradient(#222c1b, #121810); border: 1px solid var(--brass); border-radius: 4px; box-shadow: inset 0 0 0 1px rgba(0,0,0,.55); }
#comms .cmst { display: flex; align-items: center; gap: 5px; font-weight: 900; font-size: 11px; line-height: 1.2; letter-spacing: .08em; color: #a9b98a; white-space: nowrap; }
#comms .cmlamp { flex: 0 0 auto; width: 8px; height: 8px; border-radius: 50%; background: #3b6a33; box-shadow: inset 0 -1px 1px rgba(0,0,0,.5); transition: background .2s, box-shadow .2s; }
#comms .cmbars { margin-left: auto; display: flex; align-items: flex-end; gap: 2px; height: 10px; }
#comms .cmbars i { width: 3px; background: #7fbf62; border-radius: 1px; }
#comms .cmbars i:nth-child(1) { height: 3px; } #comms .cmbars i:nth-child(2) { height: 5px; } #comms .cmbars i:nth-child(3) { height: 7px; } #comms .cmbars i:nth-child(4) { height: 10px; opacity: .45; }
#comms .cmname { margin-top: 1px; font-weight: 900; font-size: clamp(12px, 2.5cqh, 17px); line-height: 1.2; color: #ffe6a0; text-shadow: 0 1px 0 #000; overflow-wrap: anywhere;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
/* whoever is talking: gold screen edge, lit screen, lamp on */
#comms.talkhq .cmhq, #comms.talkme .cmme { transform: scale(1.03); box-shadow: 0 10px 26px rgba(0,0,0,.7), 0 0 18px rgba(255,210,74,.35), inset 0 1px 0 rgba(255,240,190,.45); }
#comms.talkhq .cmhq .cmscr, #comms.talkme .cmme .cmscr { border-color: var(--gold); }
#comms.talkhq .cmhq .cmscr :is(video, img), #comms.talkme .cmme .cmscr img { filter: none; }
#comms.talkhq .cmhq .cmlamp, #comms.talkme .cmme .cmlamp { background: #7dff5c; box-shadow: 0 0 8px #7dff5c; animation: cmblink .8s steps(1) infinite; }
#comms.live .cmlamp { background: #4f9a42; }
#comms.ring .cmfeed, #comms.ring .cmunits, #comms.boot .cmunits { opacity: 0; }
#comms.boot .cmfeed { animation: cmon .5s ease-out both; }
#comms.boot .cmme { animation-delay: .08s; }
@keyframes cmon { from { opacity: 0; transform: scaleY(.04); filter: brightness(2); } to { opacity: 1; transform: scaleY(1); filter: none; } }

/* the new-unit strip between the monitors: one card size, one gap, centred; the key card lights up and grows */
#comms .cmunits { position: absolute; top: var(--top); left: calc(var(--side) + var(--hqw) + 2cqw); right: calc(var(--sideR) + var(--mew) + 2cqw);
  display: flex; flex-direction: column; align-items: center; gap: max(6px, 1.4cqh); pointer-events: none; transition: opacity .3s; }
#comms .cmuh { padding: 3px 12px; background: rgba(12,20,12,.8); border: 1px solid var(--brass); border-radius: 4px; font-weight: 900; font-size: clamp(12px, 2.3cqh, 15px); letter-spacing: .08em; color: var(--gold); text-shadow: 0 1px 0 #000; white-space: nowrap; }
#comms.live .cmuh { animation: cmfade .35s .1s ease-out both; }
#comms .cmurow { display: flex; justify-content: center; align-items: flex-start; gap: max(6px, 1.2cqw); width: 100%; }
#comms .cmurow .cmu { position: relative; flex: 0 1 min(12cqw, 23cqh); min-width: 0; box-sizing: border-box; aspect-ratio: 4 / 5; border: 2px solid #5d6b4a; border-radius: 6px; overflow: hidden; background: #000;
  box-shadow: 0 4px 14px rgba(0,0,0,.6); filter: brightness(.85); opacity: 0; transform-origin: 50% 30%;
  transition: transform .3s ease-out, border-color .3s, filter .3s, box-shadow .3s; }
#comms.live .cmurow .cmu { animation: cmcard .4s calc(.2s + var(--i, 0) * .09s) ease-out forwards; }
@keyframes cmcard { from { opacity: 0; translate: 0 10px; } to { opacity: 1; translate: 0 0; } }
@keyframes cmfade { from { opacity: 0; } to { opacity: 1; } }
#comms .cmu img { width: 100%; height: 100%; object-fit: cover; display: block; }
#comms .cmun { position: absolute; left: 0; right: 0; bottom: 0; padding: 10px 3px 3px; background: linear-gradient(rgba(0,0,0,0), rgba(0,0,0,.92) 45%); font-weight: 900; font-size: clamp(11px, 2cqh, 14px); line-height: 1.15; text-align: center; text-shadow: 0 1px 0 #000; overflow-wrap: anywhere; }
#comms .cmurow .cmu.key { border-color: var(--brass); }
#comms .cmuk { position: absolute; top: 3px; left: 3px; padding: 1px 5px; font-style: normal; font-weight: 900; font-size: 10px; line-height: 1.3; background: var(--gold); color: #1a1406; border-radius: 3px; }
#comms.unitlive .cmurow .cmu.key { transform: scale(1.1); border-color: var(--gold); filter: none; box-shadow: 0 0 18px rgba(255,210,74,.55); z-index: 1; }
#comms.unitlive .cmurow .cmu:not(.key) { filter: brightness(.55); }
#comms.talkunit .cmu.key { box-shadow: 0 0 22px rgba(255,210,74,.85); }
#comms.talkunit .cmu.key::after { content: ""; position: absolute; top: 5px; right: 5px; width: 9px; height: 9px; border-radius: 50%; background: #7dff5c; box-shadow: 0 0 8px #7dff5c; animation: cmblink .8s steps(1) infinite; }

/* the subtitle box: fixed bottom-centre, dark green glass with a thin brass edge, the speaker on a tag at its top-left */
#comms .cmsub { position: absolute; left: 50%; bottom: max(14px, 4.5cqh, env(safe-area-inset-bottom)); transform: translateX(-50%); box-sizing: border-box; width: min(64cqw, 880px); min-height: calc(1.5em + max(26px, 4.8cqh));
  padding: max(14px, 2.8cqh) max(16px, 2.4cqw) max(10px, 2cqh); background: rgba(14,30,18,.8); border: 1px solid var(--brass); border-radius: 6px;
  box-shadow: inset 0 0 0 1px rgba(0,0,0,.5), 0 6px 20px rgba(0,0,0,.55); opacity: 0; transition: opacity .3s;
  font-size: clamp(14px, 3.3cqh, 23px); line-height: 1.5; text-align: left; text-shadow: 0 2px 0 #000; overflow-wrap: anywhere; }
#comms .cmsub::before, #comms .cmsub::after { content: ""; position: absolute; width: 12px; height: 12px; border: 2px solid var(--gold); pointer-events: none; }
#comms .cmsub::before { right: -2px; top: -2px; border-left: 0; border-bottom: 0; }
#comms .cmsub::after { right: -2px; bottom: -2px; border-left: 0; border-top: 0; }
#comms.sub .cmsub { opacity: 1; }
#comms .cmsub b { position: absolute; top: 0; left: max(12px, 1.6cqw); transform: translateY(-55%); max-width: calc(100% - 28px); padding: 2px 10px; box-sizing: border-box;
  background: linear-gradient(#e0c474, #a2833e); color: #1b1406; border: 1px solid #3a2c10; border-radius: 3px; font-weight: 900; font-size: clamp(11px, 2.3cqh, 15px); line-height: 1.35;
  text-shadow: none; letter-spacing: .04em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
#comms.talkunit .cmsub b { background: linear-gradient(#bfe08a, #6e9a3e); }
#comms .cmsub span { display: block; }
#comms .cmsub.swap span { animation: cmline .28s ease-out both; }
@keyframes cmline { from { opacity: 0; translate: 0 4px; } to { opacity: 1; translate: 0 0; } }

/* request 76/77: the mission target hint and the key-unit loss line */
/* request 78: the mission board — brass frame, screws, fine scanlines, title bar with the mission's name, objectives with boxes */
#tgthint { position: absolute; top: 27%; left: 50%; width: min(44%, 470px); box-sizing: border-box; transform: translate(-50%, -10px) scale(.96); z-index: 40; pointer-events: auto; cursor: pointer;
  padding: 0 14px 10px; color: #f2ead2; font-family: var(--font, sans-serif); text-shadow: 0 1px 0 #000; opacity: 0; transition: opacity .22s, transform .28s cubic-bezier(.3,1.5,.5,1);
  background: linear-gradient(180deg, rgba(36,44,28,.96), rgba(16,20,12,.95)); border: 3px solid #b98f3e; border-radius: 10px;
  box-shadow: inset 0 0 0 2px #3b2e12, inset 0 0 0 4px rgba(255,214,120,.22), inset 0 0 24px rgba(0,0,0,.6), 0 8px 22px rgba(0,0,0,.6); overflow: hidden; }
#tgthint::after { content: ""; position: absolute; inset: 0; pointer-events: none; border-radius: 7px;
  background: repeating-linear-gradient(180deg, rgba(255,255,255,.035) 0 1px, transparent 1px 3px); mix-blend-mode: screen; }
#tgthint.in { opacity: 1; transform: translate(-50%, 0) scale(1); }
#tgthint .mb-head { display: flex; align-items: center; gap: 8px; margin: 0 -14px 6px; padding: 4px 6px 4px 18px; min-height: 44px; box-sizing: border-box;
  background: linear-gradient(180deg, #5b4a22, #3a2e14); border-bottom: 2px solid #b98f3e; box-shadow: inset 0 1px 0 rgba(255,230,160,.35); }
#tgthint .mb-ht { flex: 1; min-width: 0; display: flex; flex-direction: column; line-height: 1.15; }
#tgthint .mb-tag { color: #e6c873; font-weight: 900; font-size: 12px; letter-spacing: .12em; }
#tgthint .mb-name { color: #ffd24a; font-weight: 900; font-size: 17px; overflow-wrap: anywhere; text-shadow: 0 2px 0 #000; }
#tgthint .mb-x { flex: none; width: 44px; height: 44px; border-radius: 8px; border: 2px solid #b98f3e; background: linear-gradient(180deg, #4a4024, #241d0c); color: #ffe39a;
  font: 900 18px/1 var(--font, sans-serif); cursor: pointer; box-shadow: inset 0 1px 0 rgba(255,230,160,.3), 0 2px 0 #000; }
#tgthint .mb-x:hover { filter: brightness(1.2); }
#tgthint .mb-x:active { transform: scale(.92); }
#tgthint .mb-list { list-style: none; margin: 0; padding: 0 2px; display: flex; flex-direction: column; gap: 5px; }
#tgthint .mb-list li { display: flex; align-items: flex-start; gap: 8px; font-weight: 900; font-size: 15px; line-height: 1.25; }
#tgthint .mb-list li span { flex: 1; min-width: 0; overflow-wrap: anywhere; }
#tgthint .mb-box { flex: none; width: 16px; height: 16px; margin-top: 1px; border: 2px solid #c9a24a; border-radius: 3px; background: rgba(0,0,0,.45);
  color: #8fe08f; font: 900 13px/16px var(--font, sans-serif); text-align: center; font-style: normal; box-shadow: inset 0 0 0 1px #000; }
#tgthint li.now span { color: #ffe08a; }
#tgthint li.done span { color: #a8b89a; text-decoration: line-through; text-decoration-color: rgba(143,224,143,.7); }
#tgthint li.done .mb-box { border-color: #8fe08f; }
#tgthint li.later { opacity: .55; }
#tgthint .mb-star { flex: none; font-style: normal; color: #ffd24a; font-size: 14px; }
#tgthint .mb-warn { margin-top: 7px; padding: 4px 8px; border-radius: 5px; background: rgba(120,30,10,.45); box-shadow: inset 0 0 0 1px rgba(255,138,92,.55);
  color: #ffb08c; font-weight: 900; font-size: 13px; line-height: 1.25; overflow-wrap: anywhere; }
#tgthint .mb-foot { margin-top: 5px; text-align: center; font-size: 12px; opacity: .65; }
#tgthint .mb-screw { position: absolute; width: 8px; height: 8px; border-radius: 50%; z-index: 2; pointer-events: none;
  background: radial-gradient(circle at 35% 35%, #fff2c0, #b98f3e 45%, #4a3810 80%); box-shadow: 0 1px 1px #000; }
#tgthint .mb-screw::after { content: ""; position: absolute; left: 1px; right: 1px; top: 3.5px; height: 1px; background: #3a2a08; transform: rotate(35deg); }
#tgthint .mb-screw.a { left: 5px; top: 5px; } #tgthint .mb-screw.b { right: 5px; top: auto; bottom: 5px; }
#tgthint .mb-screw.c { left: 5px; bottom: 5px; } #tgthint .mb-screw.d { right: 54px; top: 5px; }
@container app (max-height: 520px) {
  #tgthint { top: 19%; padding: 0 10px 6px; width: min(48%, 400px); }
  #tgthint .mb-head { margin: 0 -10px 4px; padding-left: 14px; }
  #tgthint .mb-name { font-size: 14px; }
  #tgthint .mb-tag { font-size: 10px; }
  #tgthint .mb-list { gap: 3px; }
  #tgthint .mb-list li { font-size: 12.5px; gap: 6px; }
  #tgthint .mb-box { width: 13px; height: 13px; font-size: 11px; line-height: 13px; }
  #tgthint .mb-warn { margin-top: 4px; padding: 2px 6px; font-size: 11.5px; }
  #tgthint .mb-foot { display: none; }
}
.rwhy { margin: 4px auto 0; color: #ff7a5a; font-weight: 900; font-size: clamp(14px, 1.6vw, 20px); text-shadow: 0 2px 0 #000; text-align: center; }

/* request 77: the opening camera show — letterbox bars, the MISSION TARGET label, a tag over the target, Skip */
#app.tgcine-on #mmwrap, #app.tgcine-on #clockbar, #app.tgcine-on #sidebar, #app.tgcine-on #selinfo { opacity: 0; visibility: hidden; }
#tgcine { position: absolute; inset: 0; z-index: 85; pointer-events: auto; touch-action: none; font-family: var(--font, sans-serif); }
#tgcine .tcbar { position: absolute; left: 0; right: 0; height: max(48px, 11cqh); display: flex; align-items: center; justify-content: center; background: #000; transition: transform .45s cubic-bezier(.2,.8,.2,1); }
#tgcine .tctop { top: 0; transform: translateY(-100%); box-shadow: 0 1px 0 rgba(200,168,90,.35); }
#tgcine .tcbot { bottom: 0; transform: translateY(100%); box-shadow: 0 -1px 0 rgba(200,168,90,.35); padding: 0 calc(max(16px, env(safe-area-inset-right)) + 96px); }
#tgcine.in .tcbar { transform: none; }
#tgcine .tclabel { padding: 2px 16px; color: #ffd24a; font-weight: 900; font-size: clamp(14px, 3cqh, 22px); letter-spacing: .22em; border-top: 1px solid #c8a85a; border-bottom: 1px solid #c8a85a; text-shadow: 0 2px 0 #000; white-space: nowrap; }
#tgcine .tccap { color: #f2ead2; font-weight: 900; font-size: clamp(14px, 2.8cqh, 20px); text-align: center; text-shadow: 0 2px 0 #000; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; animation: cmfade .4s ease-out both; }
#tgcine.s2 .tccap { color: #ffe28a; animation: cmline .35s ease-out both; }
#tgcine .tcskip { position: absolute; right: max(16px, env(safe-area-inset-right)); top: 50%; transform: translateY(-50%); min-width: 72px; min-height: 44px; padding: 4px 14px;
  font: 900 clamp(14px, 2.6cqh, 16px) var(--font, sans-serif); color: #f4ead0; cursor: pointer; background: linear-gradient(#3a4426, #222a16); border: 2px solid #c8a85a; border-radius: 6px; text-shadow: 0 2px 0 #000; }
#tgcine .tcskip:active { transform: translateY(-50%) scale(.96); }
#tgcine .tctag { position: absolute; left: 0; top: 0; display: flex; flex-direction: column; align-items: center; pointer-events: none; opacity: 0; transition: opacity .35s; will-change: transform; }
#tgcine.in .tctag { opacity: 1; }
#tgcine.s2 .tctag, #tgcine.out .tctag { opacity: 0; }
#tgcine .tctag b { padding: 3px 12px; background: rgba(60,10,4,.88); border: 2px solid #ff6a42; border-radius: 4px; color: #fff3e6; font-weight: 900; font-size: clamp(13px, 2.7cqh, 18px); white-space: nowrap; text-shadow: 0 2px 0 #000; box-shadow: 0 0 14px rgba(255,90,50,.45); }
#tgcine .tcmark { width: 0; height: 0; margin-top: 3px; border-left: 10px solid transparent; border-right: 10px solid transparent; border-top: 14px solid #ff6a42; animation: tcbob .7s ease-in-out infinite alternate; }
@keyframes tcbob { from { translate: 0 0; } to { translate: 0 6px; } }
