/* Cogwhistle's Gop Shop and Infirmary (js/arena/town/town-lockup-card.js): the card over the game for the cell door's
   bail and lockpicking, a chat through the bars, and the Infirmary's bill. A workshop plate like the dice and the shops'
   cards (ART_STYLE.md section 9): riveted, its buttons off square, potion green for the good, danger red for a snap */
#twlock { position: fixed; z-index: 90; left: 50%; bottom: 150px; transform: translateX(-50%); box-sizing: border-box; width: min(440px, calc(100% - 24px));
  padding: 22px 14px 14px; border-radius: 10px; border: 3px solid var(--wk-ink, #0a0612);
  background: var(--wk-stripes, none), var(--wk-plate, linear-gradient(170deg, #3a4048, #2a2e36)); box-shadow: var(--wk-drop, 0 6px 0 #0a0612);
  color: var(--wk-paper, #f0ece0); font: 500 14px var(--f-ui, system-ui, sans-serif); display: none; }
#twlock.show { display: block; }
/* (slim, down at the bottom out of the way, for a card that stays up while there's something to watch: the club's dances) */
#twlock.lkslim { bottom: 12px; padding: 16px 12px 10px; width: min(360px, calc(100% - 24px)); }
#twlock.lkslim .lktext { display: none; }
#twlock.lkslim .twtalkbye { display: none; }
#twlock::after { content: ""; position: absolute; top: 6px; left: 7px; right: 7px; height: 12px; pointer-events: none;
  background: var(--wk-rivet-dot) left center / 12px 12px no-repeat, var(--wk-rivet-dot) right center / 12px 12px no-repeat; }
#twlock .twtalkwho { font: 400 18px var(--f-head, serif); color: var(--wk-brass, #f2b632); text-shadow: 2px 2px 0 var(--wk-ink, #0a0612);
  padding-bottom: 8px; margin: 0 0 10px; border-bottom: 3px dashed var(--wk-ink, #0a0612); }
.lktext { margin: 0 4px 10px; line-height: 1.35; }
.lknote { margin: 0 4px 10px; text-align: center; font-weight: 600; opacity: 0.9; }
.lkgood { color: var(--wk-potion, #7aff2a); }
.lkbad { color: #ff8a7a; }
.lkrow { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.lkrow .twtalkbye, .lkrow .lkbtn:only-child { grid-column: 1 / -1; min-height: 44px; }
#twlock .lkbtn { text-transform: none; letter-spacing: 0; font-size: 14px; }
#twlock .lkbtn:disabled { opacity: 0.5; filter: grayscale(0.6); cursor: default; }
#twlock .twtalkbye { position: relative; border-radius: 10px; border: 3px solid var(--wk-ink, #0a0612); background: rgba(80, 30, 20, 0.9); color: var(--wk-paper, #f0ece0);
  box-shadow: var(--wk-drop-sm, 0 4px 0 #0a0612); font: 800 14px var(--f-ui, system-ui, sans-serif); cursor: pointer; }
#twlock.picking .lkrow { grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); }
#twlock.picking .lkrow .twtalkbye { grid-column: auto; }
/* (the lock: a pin for each, set in green; the track with its glowing sweet spot and the needle sweeping it) */
.lkpins { display: flex; justify-content: center; gap: 10px; margin: 2px 0 10px; }
.lkpin { width: 16px; height: 28px; border-radius: 4px; border: 3px solid var(--wk-ink, #0a0612); background: var(--wk-iron, #1e1e24); }
.lkpin.now { background: var(--wk-brass, #c8902a); }
.lkpin.set { background: var(--wk-potion, #7aff2a); box-shadow: 0 0 10px rgba(122, 255, 42, 0.6); }
.lktrack { position: relative; height: 34px; margin: 0 4px 10px; border-radius: 8px; border: 3px solid var(--wk-ink, #0a0612); background: rgba(10, 6, 18, 0.6); overflow: hidden; }
.lkzone { position: absolute; top: 0; bottom: 0; background: rgba(42, 224, 255, 0.45); box-shadow: inset 0 0 10px rgba(42, 224, 255, 0.9); }
.lkneedle { position: absolute; top: -2px; bottom: -2px; width: 6px; margin-left: -3px; left: 0; background: var(--wk-brass, #c8902a); border: 2px solid var(--wk-ink, #0a0612); border-radius: 3px; }
#twlock .lklift { min-height: 56px; }
/* (Sergeant Crumb's watch card: the jobs on offer, and handing in yer badge, asked twice: town-watch-card.js) */
#twlock .lkjob { font-size: 13px; opacity: 0.85; margin-bottom: 6px; }
#twlock .lkleave { background: rgba(110, 30, 20, 0.95); }
@media (max-width: 720px) { #twlock { bottom: 210px; } }
body.touchplaying #twlock { bottom: calc(190px + env(safe-area-inset-bottom, 0px)); }
/* (a phone on its side has no room under the card for the touch controls: it goes to the top, tighter) */
@media (max-height: 500px) { #twlock, body.touchplaying #twlock { top: 6px; bottom: auto; padding-top: 16px; } .lktext { display: none; } }
@media (max-width: 380px) { .lkrow { grid-template-columns: minmax(0, 1fr); } #twlock.picking .lkrow { grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); } }
