/* ═══ flow.css — the app's half of the beat flow ═══
   Claude's BeatFlow (gfx/beat.js + beat.css) owns the track: the telex
   brief, the room, the decision, the swipe rail, the pinned chips, the nav.
   This file is everything AROUND it: flow-mode layout, the term dock, the
   documents row, and the dossier sheet. */

body:has(#game.flow-mode) { height: 100dvh; display: flex; flex-direction: column; overflow: hidden; }
body:has(#game.flow-mode) .topbar { flex: 0 0 auto; }
#game.flow-mode { flex: 1; min-height: 0; height: auto; display: flex; flex-direction: column; overflow: hidden; padding-bottom: 0; }

/* The dock: in flow mode BeatFlow's chips are the status — only the term bar stays. */
.game-status { padding: 10px 2px 4px; border-bottom: 1px solid rgba(212, 169, 60, .14); }
.game-status .termbar { margin-top: 10px; }
#game.flow-mode .game-status { padding: 6px 2px 0; border-bottom: 0; }
#game.flow-mode #ledgers { display: none; }
#game.flow-mode .game-status .termbar { margin: 6px 2px 2px; }

/* The mount + the documents row under BeatFlow's nav. */
#flow { display: flex; flex-direction: column; flex: 1; min-height: 0; margin-top: 8px; }
#flow-mount { flex: 1; min-height: 0; border-radius: 6px 6px 0 0; overflow: hidden; }
#flow-mount .bf { min-height: 0; } /* his 560px floor would clip short phones */
.flow-docs .btn { width: auto; flex: 0 0 auto; padding: 10px 14px; font-size: 10px; }

/* The dossier button's alarm dot: a red star pinned to its corner. */
#btn-dossier { position: relative; }
#btn-dossier .btab-dot { left: auto; right: 6px; top: 6px; margin-top: 0; width: 9px; height: 9px; }

/* Pane headings the app injects into BeatFlow's slots. */
.bf-kicker { font: 800 10px/1 var(--sans); letter-spacing: .22em; text-transform: uppercase; color: var(--gold, #d4a93c); margin: 8px 2px 12px; }
.bf-kicker b { color: #efe6cf; }
.bf-decide-head { margin-bottom: 12px; }

/* Five ledgers, one row: his chips were sized for three — slim them to fit,
   and give the row air above and below so it never feels welded on. */
.bf-chip { gap: 4px; padding: 4px 6px; }
.bf-chip svg { width: 15px; height: 15px; }
.bf-chip .lbl { font-size: 7px; letter-spacing: .08em; }
.bf-chip .val { font-size: 13.5px; }
.bf-chips { gap: 4px; padding: 11px 8px 11px; }

/* Content: a little daylight under the chips and above the switchers. */
.bf-slot { padding-top: 12px; }
.bf-brief { padding-top: 9px; }

/* The switchers: lifted off the bottom edge, roomier top and bottom. */
.bf-nav { padding-top: 15px; padding-bottom: calc(18px + env(safe-area-inset-bottom, 0px)); }
.flow-docs { display: flex; justify-content: flex-end; gap: 8px; padding: 10px 2px calc(10px + env(safe-area-inset-bottom)); }

/* The room: Claude's adviser cards carry the meeting — the speaking ring and
   the play button ride the existing .adv-line/.adv-face/.adv-play contract. */
.bf-adv .adv-play { margin: 10px 0 0; }
.bf-slot .plain-chip, .bf-slot .intel, .bf-slot .personal { margin-bottom: 14px; }

/* The dossier: the binder demoted — full-screen reference sheet. */
.dossier-sheet { position: fixed; inset: 0; z-index: 60; max-width: 552px; margin: 0 auto; overflow-y: auto; -webkit-overflow-scrolling: touch;
  background: #0b060b; padding: 0 16px 40px; box-shadow: 0 0 60px rgba(0,0,0,.8); }
.ds-top { display: flex; align-items: center; justify-content: space-between; padding: 16px 0 10px; }
.ds-title { font: 800 11px/1 var(--head, var(--sans)); letter-spacing: .24em; color: var(--gold, #d4a93c); }

/* The kept desk: a returning player's card above the era rail. */
#resume-slot { margin: 0 0 16px; }
#resume-slot .era-card { width: 100%; max-width: 100%; cursor: pointer; border-color: var(--gold, #d4a93c); box-shadow: 0 0 24px rgba(212, 169, 60, .12); }
#resume-slot .era-card .era-title { letter-spacing: .2em; color: var(--gold, #e7c65a); }
#resume-slot .era-card:hover, #resume-slot .era-card:focus-visible { outline: 1px solid var(--gold, #d4a93c); }

/* The initiative hand: the player moves first. */
.init-drawer { margin-top: 14px; padding-top: 12px; border-top: 1px dashed rgba(255, 255, 255, .16); }
.init-open { width: 100%; border: 1px solid var(--gold, #c9a227); background: rgba(201, 162, 39, .07); color: var(--gold, #e7c65a); font: 700 11px/1 var(--head, var(--sans)); letter-spacing: .1em; padding: 12px 14px; border-radius: 8px; cursor: pointer; }
.init-open:active { transform: translateY(1px); }
.init-custom { display: flex; gap: 6px; margin-top: 8px; }
#flow input { user-select: text !important; -webkit-user-select: text !important; }
#init-text { flex: 1; min-width: 0; background: rgba(0, 0, 0, .35); border: 1px solid rgba(255, 255, 255, .18); border-radius: 8px; color: var(--paper, #f0e8d8); font: 13px/1.3 var(--sans); padding: 9px 10px; }
#init-text::placeholder { color: rgba(240, 232, 216, .35); }
.init-sign { border: 1px solid rgba(255, 255, 255, .18); background: rgba(255, 255, 255, .06); color: inherit; font: 700 10px/1 var(--head, var(--sans)); letter-spacing: .1em; padding: 0 12px; border-radius: 8px; cursor: pointer; }
.init-note { margin: 8px 0 0; font-size: 10px; opacity: .6; letter-spacing: .04em; }
.opt-btn.init { flex-wrap: wrap; }
.opt-btn.init .init-note { display: block; width: 100%; margin: 3px 0 0; font-size: 10.5px; opacity: .65; letter-spacing: .02em; }
.init-back { display: block; margin: 10px auto 0; background: none; border: none; color: inherit; opacity: .55; font: inherit; font-size: 10px; letter-spacing: .1em; cursor: pointer; }
.init-kicker { margin: 12px 0 6px; }

/* The stills overlay: the era-open newsreel, body level (the stacking lesson). */
#stills-layer { position: fixed; inset: 0; z-index: 55; pointer-events: none; opacity: 1; transition: opacity .8s ease; }
#stills-layer.fade { opacity: 0; }
