/* RAWDRAW HQ metaverse: map, actors, floor stack. Shared by the ERP page and the mockup. */
.om-map { position: relative; z-index: 0; isolation: isolate; flex: none; user-select: none; }
.om-bg { position: absolute; inset: 0; width: 100%; height: 100%; display: block; filter: drop-shadow(0 26px 34px rgba(60, 20, 20, .14)); pointer-events: none; }
.om-occ { position: absolute; inset: 0; background-size: 100% 100%; pointer-events: none; }
.om-fx, .om-say-layer { position: absolute; inset: 0; pointer-events: none; }
.om-say-layer { z-index: 5000; }
.om-fx { z-index: 4000; }

/* actors: the element sits on the feet point */
.om-a { position: absolute; width: 0; height: 0; cursor: pointer; }
.om-spr { position: absolute; width: var(--sw); height: var(--sh); left: calc(var(--sw) / -2); top: calc(var(--sh) * -0.96); background-repeat: no-repeat; }
.om-spr.flip { transform: scaleX(-1); }
.om-prop { position: absolute; pointer-events: none; background: no-repeat 0 0 / 100% 100%; }
.om-prop.flip { transform: scaleX(-1); }
/* foot shadow: a small, wide, blurred ellipse that rides with the character.
   It shrinks and fades on the passing frames of the walk (body lifted) and spreads when seated. */
.om-sh { position: absolute; left: calc(var(--sw) * -0.2); top: calc(var(--sw) * -0.038); width: calc(var(--sw) * 0.4); height: calc(var(--sw) * 0.1); border-radius: 50%;
  background: radial-gradient(closest-side, rgba(46, 20, 10, .56), rgba(46, 20, 10, .3) 58%, rgba(46, 20, 10, 0));
  filter: blur(calc(var(--sw) * 0.016)); transform-origin: 50% 50%; pointer-events: none; transition: transform .12s ease-out, opacity .12s ease-out; }
.om-a.walk .om-sh { transform: scale(1.04, 1); }
.om-a.walk[data-step="1"] .om-sh { transform: scale(.84, .8); opacity: .7; }
.om-a.sit .om-sh { transform: scale(1.16, 1.05); opacity: .55; }
.om-a.om-in .om-sh { animation: om-sh-in .5s ease both; }
@keyframes om-sh-in { from { opacity: 0; transform: scale(.4, .4); } }
.om-a.om-in { animation: om-in .5s ease both; }
.om-a.om-out { animation: om-out .32s ease both; }
@keyframes om-out { to { opacity: 0; transform: translateY(-3px) scale(.97); } }

/* doors: elevator leaves slide into the wall over a lit cab; glass door frames slide along the glass */
.om-door { position: absolute; inset: 0; pointer-events: none; }
.om-door .om-leaf, .om-door .om-patch { position: absolute; inset: 0; background-size: 100% 100%; background-repeat: no-repeat; }
.om-door .om-leaf { transition: transform .62s cubic-bezier(.45, 0, .2, 1); will-change: transform; }
.om-door.open .om-leaf { transform: translate(var(--dx), var(--dy)); }
.om-cab { background: none; }
/* the cab interior, drawn square and skewed to the doorway's slant (top & bottom edges fall ~26.5deg) */
.om-cab .om-cabin { position: absolute; left: 5.99%; top: 47.32%; width: 3.91%; height: 16.61%; transform-origin: 0 0; transform: skewY(-26.5deg);
  background:
    linear-gradient(90deg, rgba(38, 26, 18, .55), rgba(38, 26, 18, 0) 24%),
    linear-gradient(180deg, #fffaf0 0, #fff4dd 4%, rgba(255, 244, 221, 0) 12%),
    linear-gradient(180deg, transparent 56.5%, rgba(255, 255, 255, .7) 57%, rgba(110, 86, 62, .75) 58.6%, transparent 59.2%),
    linear-gradient(180deg, transparent 85%, #7a6250 85.4%, #5a4738 100%),
    repeating-linear-gradient(90deg, transparent 0 32%, rgba(95, 72, 50, .32) 32% 33.2%, rgba(255, 255, 255, .28) 33.2% 34.4%),
    linear-gradient(90deg, #cdb291, #ead6ba 48%, #dcc3a3);
  box-shadow: inset 0 0 0 1px rgba(60, 40, 25, .35), inset 0 6px 10px -6px rgba(255, 255, 240, .9); }
.om-map[data-sky='night'] .om-cab .om-cabin { filter: saturate(1.1) brightness(1.04); }
@keyframes om-in { from { opacity: 0; transform: translateY(-6px) scale(.96); } }
.om-name { position: absolute; left: 0; top: calc(var(--sh) * -0.96 - 4px); transform: translate(-50%, -100%); white-space: nowrap; font-size: 11px; font-weight: 750; color: #fff; background: rgba(34, 20, 26, .86); padding: 3px 8px; border-radius: 7px; opacity: 0; transition: opacity .15s; pointer-events: none; }
.om-a:hover .om-name { opacity: 1; }
.om-a:hover .om-spr { filter: drop-shadow(0 0 2px #fff) drop-shadow(0 0 6px rgba(255, 120, 80, .7)); }
.om-a.om-focus::before { content: ''; position: absolute; left: calc(var(--sw) * -0.3); top: calc(var(--sh) * -0.07); width: calc(var(--sw) * 0.6); height: calc(var(--sh) * 0.14); border-radius: 50%; border: 2px solid #ff6b4a; animation: om-ring 1.1s ease-out 3; }
@keyframes om-ring { from { opacity: 1; transform: scale(.6); } to { opacity: 0; transform: scale(1.7); } }

/* speech bubbles */
.om-b { position: absolute; transform: translate(-50%, -100%); white-space: nowrap; display: flex; align-items: center; gap: 5px; background: rgba(255, 255, 255, .96); border-radius: 9px; padding: 3px 8px 3px 7px; font-size: 10.5px; font-weight: 700; color: #22141a; box-shadow: 0 6px 16px -8px rgba(40, 10, 20, .55); }
.om-b.on { animation: om-pop .32s cubic-bezier(.34, 1.56, .64, 1) both; }
.om-b { transition: margin-top .25s ease; }
.om-b::after { content: ''; position: absolute; left: 50%; bottom: -4px; margin-left: -4px; border: 4px solid transparent; border-bottom: 0; border-top-color: rgba(255, 255, 255, .96); }
.om-b i { width: 6px; height: 6px; border-radius: 50%; background: #b9aaae; flex: none; }
.om-b.ok i { background: #19a463; } .om-b.wait i { background: #e8930c; } .om-b.block i { background: #e0283f; box-shadow: 0 0 0 3px #ffe1e4; }
.om-b em { font-style: normal; color: #7d6f74; font-weight: 650; }
.om-b.zz::before { content: 'z Z'; position: absolute; right: -16px; top: -12px; font-size: 12px; font-weight: 900; color: #8b5cf6; letter-spacing: 1px; animation: om-z 1.8s ease-in-out infinite; }
@keyframes om-pop { from { opacity: 0; transform: translate(-50%, -80%) scale(.85); } }
@keyframes om-z { 0%, 100% { opacity: .2; transform: translateY(4px); } 50% { opacity: 1; transform: translateY(-3px); } }

/* object tags */
.om-tag { position: absolute; transform: translate(-50%, -100%); z-index: 3000; pointer-events: none; background: rgba(255, 255, 255, .93); border-radius: 9px; padding: 3px 8px 4px; font-size: 10.5px; white-space: nowrap; box-shadow: 0 6px 14px -9px rgba(40, 10, 20, .5); }
.om-tag b { font-weight: 780; } .om-tag small { display: block; font-size: 9.5px; font-weight: 600; color: #8d7f84; }
.om-tag .n { position: absolute; top: -7px; right: -7px; min-width: 17px; height: 17px; padding: 0 4px; border-radius: 9px; display: grid; place-items: center; font-size: 9.5px; font-weight: 800; color: #fff; background: #e0283f; border: 2px solid #fff; }
.om-tag .n.a { background: #e8930c; } .om-tag .n.g { background: #19a463; }

/* effects */
.om-ding { position: absolute; width: 64px; height: 64px; margin: -50px 0 0 -32px; border-radius: 50%; background: radial-gradient(rgba(255, 200, 120, .8), transparent 70%); animation: om-ding 1.1s ease-out both; }
@keyframes om-ding { from { opacity: 0; transform: scale(.4); } 30% { opacity: 1; } to { opacity: 0; transform: scale(1.7); } }
.om-burst { position: absolute; width: 0; height: 0; }
.om-burst i { position: absolute; width: 7px; height: 7px; border-radius: 2px; background: var(--c); animation: om-burst 1.1s cubic-bezier(.2, .7, .3, 1) both; transform: rotate(var(--a)) translateY(0); }
@keyframes om-burst { to { opacity: 0; transform: rotate(var(--a)) translateY(-46px) rotate(200deg); } }

/* debug */
.om-dbg { position: absolute; z-index: 6000; pointer-events: none; }
svg.om-dbg { inset: 0; width: 100%; height: 100%; }
.om-dot { width: 8px; height: 8px; margin: -4px 0 0 -4px; border-radius: 50%; background: #2f68f5; font-size: 9px; font-weight: 800; color: #2f68f5; text-indent: 10px; line-height: 8px; white-space: nowrap; }
.om-dot.v { background: #19a463; }

/* ------------------------------------------------------------ floor stack */
.fs { position: absolute; z-index: 20; width: var(--fs-w); height: 230px; transform-origin: 0 0; font-family: inherit; }
.fs-kick { position: absolute; left: 2px; top: -2px; font-size: 9.5px; font-weight: 850; letter-spacing: .2em; color: #b3a5a9; }
.fs-shaft { position: absolute; left: 39px; top: 58px; width: 2px; height: 108px; border-radius: 2px; background: repeating-linear-gradient(#e2d6d8 0 4px, transparent 4px 7px); }
.fs-cab { position: absolute; left: 34px; width: 12px; height: 16px; border-radius: 4px; background: linear-gradient(160deg, #fff, var(--fc, #e0283f) 160%); border: 2px solid var(--fc, #e0283f); box-shadow: 0 3px 8px -2px var(--fc, #e0283f); transition: top .55s cubic-bezier(.6, 0, .3, 1), border-color .3s; z-index: 60; }
.fs-cab span { position: absolute; left: 14px; top: -6px; width: 22px; height: 22px; border-radius: 50%; background: #fff 0 0 / 0 0 no-repeat; box-shadow: 0 3px 8px -3px rgba(40, 10, 20, .5); opacity: 0; transform: scale(.5); transition: .25s; }
.fs-cab.riding span { opacity: 1; transform: none; background-size: 53px 66px; background-position: -15px -11px; border: 2px solid #fff; }
.fs-cab.riding { animation: fs-cab .5s ease-in-out infinite alternate; }
@keyframes fs-cab { to { box-shadow: 0 0 0 4px rgba(255, 255, 255, .7), 0 4px 14px -2px var(--fc); } }

.fs-plate { position: absolute; pointer-events: none; width: 136px; height: 94px; transition: transform .42s cubic-bezier(.34, 1.56, .64, 1), opacity .3s, filter .3s; opacity: .8; }
.fs-row { all: unset; position: absolute; left: 0; z-index: 70; cursor: pointer; border-radius: 12px; -webkit-tap-highlight-color: transparent; }
.fs-row:focus-visible { box-shadow: inset 0 0 0 2px var(--fc); }
.fs-plate .fs-svg { display: block; overflow: visible; pointer-events: none; }
.fs-plate .fs-img { filter: saturate(.15) brightness(1.12); opacity: .55; transition: filter .3s, opacity .3s; }
.fs-plate .fs-tint { opacity: .5; transition: opacity .3s; }
.fs-plate .fs-rim { opacity: .55; transition: opacity .3s; }
.fs-plate .fs-ring { opacity: 0; transition: opacity .3s; }
.fs-plate .fs-thick { opacity: .55; transition: opacity .3s; }
.fs-plate .fs-shine { transform: translateX(0); }
.fs-plate.dim { opacity: .5; }
.fs-plate.on, .fs-plate.hov { opacity: 1; }
.fs-plate.on .fs-img, .fs-plate.hov .fs-img { filter: none; opacity: 1; }
.fs-plate.on .fs-rim, .fs-plate.hov .fs-rim { opacity: 0; }
.fs-plate.on .fs-tint, .fs-plate.hov .fs-tint { opacity: 0; }
.fs-plate.on .fs-thick, .fs-plate.hov .fs-thick { opacity: 1; }
.fs-plate.on .fs-ring { opacity: .9; }
.fs-plate.on { transform: translate(15px, -3px); filter: drop-shadow(0 10px 14px color-mix(in srgb, var(--fc) 45%, transparent)); }
.fs-plate.hov { transform: translate(11px, -6px); filter: drop-shadow(0 12px 16px color-mix(in srgb, var(--fc) 40%, transparent)); }
.fs-plate.on.hov { transform: translate(17px, -7px); }
.fs-plate.hov .fs-shine { animation: fs-shine .9s ease .05s both; }
@keyframes fs-shine { from { transform: translateX(0); } to { transform: translateX(300px); } }


.fs-lbl { position: absolute; left: 0; width: 32px; text-align: right; line-height: 1; pointer-events: none; transition: transform .35s cubic-bezier(.34, 1.56, .64, 1); }
.fs-lbl b { display: block; font-size: 16px; font-weight: 850; letter-spacing: -.04em; color: #bfb0b3; transition: color .25s; }
.fs-lbl small { display: block; margin-top: 2px; font-size: 7px; font-weight: 800; letter-spacing: .14em; color: #d6cbcd; transition: color .25s; }
.fs-lbl.on b { color: var(--fc); } .fs-lbl.on small { color: var(--fd); }
.fs-lbl.on { transform: translateX(-2px) scale(1.12); transform-origin: right center; }
.fs-ct { position: absolute; display: flex; align-items: center; gap: 3px; pointer-events: none; transition: transform .42s cubic-bezier(.34, 1.56, .64, 1), opacity .3s; opacity: .55; }
.fs-ct .p { min-width: 18px; height: 16px; padding: 0 5px; border-radius: 8px; display: grid; place-items: center; font-size: 9.5px; font-weight: 800; color: #8d7f84; background: rgba(255, 255, 255, .92); box-shadow: 0 2px 6px -3px rgba(40, 10, 20, .4); }
.fs-ct .al { width: 7px; height: 7px; border-radius: 50%; background: #e0283f; box-shadow: 0 0 0 0 rgba(224, 40, 63, .5); animation: fs-al 1.6s infinite; }
@keyframes fs-al { 70% { box-shadow: 0 0 0 6px rgba(224, 40, 63, 0); } }
.fs-ct.on { opacity: 1; transform: translateX(15px); } .fs-ct.on .p { color: #fff; background: var(--fc); }

/* concept bubble */
.fs-bubble { position: absolute; left: calc(100% + 6px); width: 252px; pointer-events: none; opacity: 0; transform: translateX(-10px) scale(.94); transform-origin: 0 30px; transition: opacity .2s, transform .2s, top .32s cubic-bezier(.34, 1.4, .64, 1); z-index: 80; }
.fs-bubble.show { opacity: 1; transform: none; }
.fs-bubble.pop { animation: fs-pop .45s cubic-bezier(.34, 1.56, .64, 1) both; }
@keyframes fs-pop { from { opacity: 0; transform: translateX(-14px) scale(.86); } }
.fb-in { position: relative; background: #fff; border-radius: 16px; padding: 12px 14px 11px; box-shadow: 0 1px 0 rgba(255, 255, 255, .9) inset, 0 18px 40px -16px color-mix(in srgb, var(--fc) 55%, rgba(40, 10, 20, .6)), 0 0 0 1px color-mix(in srgb, var(--fc) 22%, transparent); overflow: hidden; }
.fb-in::before { content: ''; position: absolute; inset: 0 0 auto 0; height: 4px; background: linear-gradient(90deg, var(--fd), var(--fc)); }
.fs-bubble::before { content: ''; position: absolute; left: -7px; top: 26px; width: 14px; height: 14px; background: #fff; transform: rotate(45deg); border-radius: 3px; box-shadow: -1px 1px 0 color-mix(in srgb, var(--fc) 22%, transparent); }
.fb-top { display: flex; align-items: center; gap: 9px; }
.fb-ic { width: 34px; height: 34px; border-radius: 11px; display: grid; place-items: center; color: #fff; background: linear-gradient(140deg, var(--fc), var(--fd)); box-shadow: 0 6px 12px -6px var(--fc); flex: none; }
.fb-ic svg { width: 19px; height: 19px; }
.fb-h { min-width: 0; flex: 1; }
.fb-k { font-size: 9.5px; font-weight: 850; letter-spacing: .16em; color: var(--fd); }
.fb-t { font-size: 16px; font-weight: 850; letter-spacing: -.035em; color: #22141a; margin-top: 1px; }
.fb-now { font-size: 9.5px; font-weight: 800; color: var(--fd); background: var(--fl); padding: 3px 7px; border-radius: 7px; white-space: nowrap; }
.fb-c { margin: 8px 0 0; font-size: 11.5px; line-height: 1.45; color: #5d4f54; }
.fb-c b { color: var(--fd); font-weight: 800; margin-right: 3px; }
.fb-ppl { display: flex; align-items: center; margin-top: 9px; }
.fb-head { width: 26px; height: 26px; border-radius: 50%; border: 2px solid #fff; margin-right: -7px; background: var(--fl) no-repeat; background-size: 62px 78px; background-position: -18px -14px; box-shadow: 0 2px 6px -3px rgba(40, 10, 20, .5); }
.fb-ppl span { margin-left: 13px; font-size: 11px; font-weight: 650; color: #7d6f74; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.fb-st { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 9px; }
.fb-st span { font-size: 10.5px; font-weight: 750; padding: 3px 8px; border-radius: 7px; background: #f6f1f1; color: #4a3a40; }
.fb-st span.r { background: #ffe8eb; color: #c81e36; } .fb-st span.a { background: #fff3d9; color: #9a5d00; } .fb-st span.g { background: #e6f7ee; color: #127a49; }
.fb-go { display: flex; align-items: center; justify-content: space-between; margin-top: 10px; padding-top: 9px; border-top: 1px dashed #eee3e4; font-size: 11px; color: #8d7f84; font-weight: 650; }
.fb-go b { color: var(--fd); font-weight: 800; }
.fb-go kbd { font: inherit; font-size: 10px; font-weight: 800; color: var(--fd); background: var(--fl); border-radius: 5px; padding: 1px 6px; }
@media (prefers-reduced-motion: reduce) { .fs-plate, .fs-bubble, .fs-cab, .om-b { transition: none !important; animation: none !important; } }

/* ------------------------------------------------------------ ERP page (/office) */
.hq { --hq-h: clamp(540px, calc(100vh - 250px), 940px); display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.hq-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.hq-title { display: flex; align-items: center; gap: 14px; min-width: 0; }
.hq-ic { width: 46px; height: 46px; border-radius: 15px; display: grid; place-items: center; color: #fff; background: linear-gradient(140deg, var(--fc), var(--fd)); box-shadow: 0 10px 20px -10px var(--fc); flex: none; transition: background .4s; }
.hq-ic svg { width: 24px; height: 24px; }
.hq-kick { font-size: 11px; font-weight: 850; letter-spacing: .16em; color: var(--on-scene-muted, #8d7f84); }
.hq-title h1 { margin: 2px 0 0; font-size: 28px; font-weight: 880; letter-spacing: -.04em; color: var(--on-scene, #22141a); display: flex; align-items: center; gap: 10px; }
.hq-chip { font-size: 12px; font-weight: 800; letter-spacing: 0; padding: 4px 10px; border-radius: 9px; background: var(--fl); color: var(--fd); }
.hq-title p { margin: 3px 0 0; font-size: 13px; color: var(--on-scene-muted, #8d7f84); }
.hq-floors { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; }
.hq-floors button { position: relative; display: flex; align-items: center; gap: 7px; padding: 7px 12px 7px 9px; border-radius: 12px; border: 1px solid var(--glass-border, #efe6e6); background: var(--glass, #fff); color: var(--ink, #22141a); font: inherit; font-size: 12px; font-weight: 700; cursor: pointer; transition: transform .25s var(--ease-spring, ease), box-shadow .25s; }
.hq-floors button b { font-size: 12px; font-weight: 850; padding: 2px 6px; border-radius: 7px; color: var(--c); background: color-mix(in srgb, var(--c) 12%, #fff); }
.hq-floors button:hover { transform: translateY(-2px); box-shadow: 0 10px 20px -14px var(--c); }
.hq-floors button.on { border-color: color-mix(in srgb, var(--c) 60%, #fff); box-shadow: 0 10px 22px -14px var(--c); }
.hq-floors button.on b { color: #fff; background: var(--c); }
.hq-floors button i { position: absolute; top: -3px; right: -3px; width: 9px; height: 9px; border-radius: 50%; background: #e0283f; border: 2px solid #fff; }
.hq-link { font-size: 12px; font-weight: 750; padding: 8px 12px; border-radius: 12px; color: #fff; background: var(--dark-pill, #22141a); text-decoration: none; }
.hq-body { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 14px; min-width: 0; }
.hq-card { background: var(--glass, #fff); border: 1px solid var(--glass-border, #efe6e6); border-radius: var(--radius, 18px); box-shadow: var(--glass-shadow); padding: 14px 16px; color: var(--ink, #22141a); min-width: 0; }
.hq-card h3 { margin: 0 0 8px; font-size: 13.5px; font-weight: 800; display: flex; justify-content: space-between; align-items: baseline; gap: 8px; }
.hq-card h3 small { font-size: 11px; color: var(--muted, #8d7f84); font-weight: 650; }
.hq-stagecard { padding: 12px; display: flex; flex-direction: column; gap: 10px; }
.hq-ticker { overflow: hidden; height: 30px; border-radius: 10px; background: linear-gradient(90deg, #fff1f1, #fff8f2); border: 1px solid #ffe2de; display: flex; align-items: center; }
.hq-ticker b { position: relative; z-index: 2; flex: none; height: 100%; display: grid; place-items: center; padding: 0 11px; font-size: 11px; font-weight: 800; color: #fff; background: #e0283f; }
.hq-ticker .tk { flex: none; white-space: nowrap; font-size: 12.5px; font-weight: 650; color: #4a3a40; animation: hq-tick 40s linear infinite; padding-left: 100%; }
@keyframes hq-tick { to { transform: translateX(-100%); } }
.hq-stage { position: relative; height: var(--hq-h); border-radius: 14px; overflow: hidden; display: flex; align-items: center; justify-content: center; background: radial-gradient(60% 60% at 52% 58%, color-mix(in srgb, var(--fc) 10%, #fff), #f8f4f3 74%); transition: background .5s; }
.om-map.out-up { animation: hq-outUp .22s ease-in both; } .om-map.in-up { animation: hq-inUp .5s cubic-bezier(.2, .8, .2, 1) both; }
.om-map.out-down { animation: hq-outDown .22s ease-in both; } .om-map.in-down { animation: hq-inDown .5s cubic-bezier(.2, .8, .2, 1) both; }
@keyframes hq-outUp { to { opacity: 0; transform: translateY(26px) scale(.98); } } @keyframes hq-inUp { from { opacity: 0; transform: translateY(-34px) scale(.98); } }
@keyframes hq-outDown { to { opacity: 0; transform: translateY(-26px) scale(.98); } } @keyframes hq-inDown { from { opacity: 0; transform: translateY(34px) scale(.98); } }
.hq-toast { position: absolute; left: 50%; top: 14px; z-index: 30; display: flex; align-items: center; gap: 10px; padding: 8px 16px 8px 8px; border-radius: 14px; background: #fff; box-shadow: 0 14px 30px -14px rgba(40, 10, 20, .5); opacity: 0; pointer-events: none; transform: translateX(-50%); color: #22141a; }
.hq-toast.show { animation: hq-toast 1.8s ease both; }
.hq-toast .no { width: 36px; height: 36px; border-radius: 11px; display: grid; place-items: center; font-size: 15px; font-weight: 900; color: #fff; background: linear-gradient(140deg, var(--fc), var(--fd)); }
.hq-toast b { display: block; font-size: 14px; font-weight: 850; } .hq-toast small { font-size: 11px; font-weight: 750; color: var(--fd); letter-spacing: .1em; }
@keyframes hq-toast { 0% { opacity: 0; transform: translate(-50%, -10px); } 15%, 75% { opacity: 1; transform: translate(-50%, 0); } 100% { opacity: 0; transform: translate(-50%, -6px); } }
.hq-legend { position: absolute; right: 12px; bottom: 10px; display: flex; gap: 12px; font-size: 11px; font-weight: 650; color: #8d7f84; background: rgba(255, 255, 255, .9); padding: 5px 10px; border-radius: 9px; z-index: 25; }
.hq-legend i { display: inline-block; width: 8px; height: 8px; border-radius: 50%; margin-right: 5px; vertical-align: -1px; }
.hq-veil { position: absolute; inset: 0; z-index: 50; display: grid; place-items: center; background: #f8f4f3; font-size: 13px; font-weight: 700; color: #8d7f84; transition: opacity .4s; }
.hq-veil.off { opacity: 0; pointer-events: none; }
.hq-side { display: flex; flex-direction: column; gap: 12px; min-width: 0; height: calc(var(--hq-h) + 64px); }
.hq-wait { background: linear-gradient(135deg, #fff1f2, #fff); border-color: #ffe0e3; color: #22141a; }
.hq-wait .big { font-size: 28px; font-weight: 880; color: #e0283f; } .hq-wait.done .big { color: #19a463; }
.hq-wait p { margin: 2px 0 0; font-size: 12px; color: #4a3a40; line-height: 1.45; }
.hq-wait a { display: inline-block; margin-top: 6px; font-size: 12px; font-weight: 800; color: #c81e36; text-decoration: none; }
.hq-three { display: grid; grid-template-columns: repeat(3, 1fr); text-align: center; }
.hq-three b { display: block; font-size: 22px; font-weight: 880; color: #e2620f; } .hq-three b.r { color: #e0283f; } .hq-three b.k { color: #8b5cf6; }
.hq-three span { font-size: 11px; color: var(--muted, #8d7f84); font-weight: 650; }
.hq-grow { flex: 1; min-height: 0; display: flex; flex-direction: column; }
.hq-ppl { display: grid; gap: 1px; overflow: auto; min-height: 0; }
.hq-ppl .pp { all: unset; cursor: pointer; display: grid; grid-template-columns: 30px 1fr auto; gap: 8px; align-items: center; padding: 5px 4px; border-radius: 10px; }
.hq-ppl .pp:hover { background: color-mix(in srgb, var(--fc) 6%, transparent); }
.hq-ppl .av { width: 30px; height: 30px; border-radius: 50%; background: #f6efef no-repeat; background-size: 72px 90px; background-position: -21px -16px; }
.hq-ppl b { display: block; font-size: 12px; } .hq-ppl span { display: block; font-size: 10.5px; color: var(--muted, #8d7f84); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 170px; }
.hq-ppl em { font-style: normal; font-size: 10px; font-weight: 800; padding: 2px 6px; border-radius: 6px; color: #fff; }
.hq-log { height: 178px; overflow: hidden; flex: none; }
.hq-log > div { display: grid; grid-template-columns: 38px 1fr; gap: 6px; font-size: 11.5px; margin-bottom: 6px; animation: hq-in .35s ease both; }
@keyframes hq-in { from { opacity: 0; transform: translateY(4px); } }
.hq-log span { color: var(--muted, #8d7f84); font-variant-numeric: tabular-nums; } .hq-log .mut { margin: 0; font-size: 12px; color: var(--muted, #8d7f84); }
.hq-note { margin: 0; font-size: 11.5px; color: var(--on-scene-muted, #8d7f84); }
@container main (max-width: 1100px) { .hq-body { grid-template-columns: 1fr; } .hq-side { height: auto; } .hq-grow { max-height: 360px; } }

/* ------------------------------------------------------------ character gallery (/office/characters) */
.cg-pills { display: flex; gap: 6px; flex-wrap: wrap; }
.cg-pills a { font-size: 12.5px; font-weight: 700; padding: 8px 13px; border-radius: 11px; border: 1px solid var(--glass-border, #efe6e6); background: var(--glass, #fff); color: var(--ink, #22141a); text-decoration: none; }
.cg-pills a.on { background: var(--dark-pill, #22141a); color: #fff; border-color: transparent; }
.cg-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(440px, 100%), 1fr)); gap: 14px; margin-top: 14px; }
.cg-card { position: relative; overflow: hidden; background: var(--glass, #fff); border: 1px solid var(--glass-border, #efe6e6); border-radius: 20px; padding: 16px 16px 14px; box-shadow: var(--glass-shadow); color: var(--ink, #22141a); }
.cg-card::before { content: ''; position: absolute; inset: 0 0 auto 0; height: 4px; background: linear-gradient(90deg, var(--fd), var(--fc)); }
.cg-h { display: flex; align-items: center; gap: 10px; }
.cg-av { width: 40px; height: 40px; border-radius: 50%; background: var(--fl) no-repeat; background-size: 96px 120px; background-position: -28px -22px; border: 2px solid #fff; box-shadow: 0 3px 8px -4px rgba(40, 10, 20, .5); flex: none; }
.cg-h b { font-size: 16px; font-weight: 850; letter-spacing: -.03em; } .cg-h small { display: block; font-size: 11.5px; color: var(--muted, #8d7f84); font-weight: 600; }
.cg-chip { margin-left: auto; font-size: 10.5px; font-weight: 850; letter-spacing: .1em; padding: 4px 9px; border-radius: 8px; color: var(--fd); background: var(--fl); white-space: nowrap; }
.cg-sec { margin-top: 12px; font-size: 10.5px; font-weight: 850; letter-spacing: .14em; color: var(--muted, #b3a5a9); }
.cg-row { display: grid; gap: 6px; margin-top: 6px; } .cg-row.dirs { grid-template-columns: repeat(4, 1fr) 1.15fr; } .cg-row.acts { grid-template-columns: repeat(4, 1fr); }
.cg-tile { position: relative; border-radius: 13px; background: radial-gradient(80% 70% at 50% 70%, #fff, #f8f2f1); border: 1px solid #f3eaea; aspect-ratio: 4 / 5; overflow: hidden; }
.cg-tile img { position: absolute; left: 50%; bottom: 9%; height: 92%; transform: translateX(-50%); }
.cg-tile span { position: absolute; left: 7px; top: 6px; font-size: 10px; font-weight: 800; color: #4a3a40; background: rgba(255, 255, 255, .9); padding: 2px 6px; border-radius: 6px; }
.cg-tile.key { background: radial-gradient(80% 70% at 50% 70%, #fff, var(--fl)); border-color: color-mix(in srgb, var(--fc) 30%, #fff); } .cg-tile.key span { color: #fff; background: var(--fc); }
.cg-tile.dim { opacity: .25; filter: grayscale(1); }

/* ---------------------------------------------------------------- day / night (follows the ERP light/dark switch)
   night: dark mode, every lamp on, the city glittering behind the glass, a busier late shift
   day:   light mode, clear morning sky, clouds drifting past the windows */
.om-sky { position: absolute; inset: 0; pointer-events: none; overflow: hidden; -webkit-mask-size: 100% 100%; mask-size: 100% 100%; -webkit-mask-repeat: no-repeat; mask-repeat: no-repeat; }
.om-sky i, .om-sky b { position: absolute; inset: 0; }
.om-sky.night i { background-size: 100% 100%; background-repeat: no-repeat; mix-blend-mode: screen; filter: drop-shadow(0 0 1.5px rgba(255, 214, 150, .9)); animation: om-twinkle 3.4s ease-in-out infinite alternate; }
.om-sky.night i:nth-child(2) { animation-duration: 4.9s; animation-delay: -1.7s; }
.om-sky.night i:nth-child(3) { animation-duration: 2.7s; animation-delay: -.8s; }
.om-sky.night b { background: linear-gradient(112deg, transparent 42%, rgba(160, 200, 255, .14) 49%, rgba(255, 255, 255, .2) 50%, transparent 57%) 0 0 / 260% 100% no-repeat; animation: om-gleam 11s linear infinite; }
@keyframes om-twinkle { 0%, 20% { opacity: 0; } 70%, 100% { opacity: 1; } }
@keyframes om-gleam { 0% { background-position: 120% 0; } 55%, 100% { background-position: -40% 0; } }
.om-sky.day i { opacity: .8; background-repeat: repeat; animation: om-cloud 60s linear infinite; filter: blur(.6px); }
.om-sky.day i:nth-child(1) { background-image: radial-gradient(ellipse 30px 8px at 40px 22px, #fff 0, rgba(255, 255, 255, .9) 40%, transparent 72%), radial-gradient(ellipse 18px 6px at 56px 17px, #fff 0, transparent 70%), radial-gradient(ellipse 26px 7px at 170px 61px, rgba(255, 255, 255, .95) 0, transparent 72%); background-size: 260px 84px; }
.om-sky.day i:nth-child(2) { background-image: radial-gradient(ellipse 22px 6px at 90px 12px, rgba(255, 255, 255, .9) 0, transparent 72%), radial-gradient(ellipse 36px 9px at 230px 48px, rgba(255, 255, 255, .85) 0, transparent 72%); background-size: 330px 70px; animation-duration: 95s; opacity: .6; }
.om-sky.day b { background: linear-gradient(115deg, transparent 40%, rgba(255, 255, 255, .5) 50%, transparent 60%) 0 0 / 260% 100% no-repeat; animation: om-gleam 14s ease-in-out infinite; mix-blend-mode: soft-light; }
@keyframes om-cloud { to { background-position-x: 520px, 520px, 520px; } }
.om-sky.day i:nth-child(2) { animation-name: om-cloud2; } @keyframes om-cloud2 { to { background-position-x: 660px, 660px; } }

.om-map[data-sky='night'] .om-bg { filter: drop-shadow(0 30px 40px rgba(0, 4, 20, .55)) drop-shadow(0 0 22px rgba(255, 190, 110, .10)); }
.om-map[data-sky='day'] .om-bg { filter: drop-shadow(0 26px 34px rgba(40, 70, 110, .14)); }
.om-map[data-sky='night'] .om-sh { background: radial-gradient(closest-side, rgba(8, 4, 2, .62), rgba(8, 4, 2, .3) 60%, transparent); }
.hq-stage[data-sky='night'] { background:
  radial-gradient(1.2px 1.2px at 12% 18%, rgba(255, 255, 255, .7), transparent), radial-gradient(1px 1px at 27% 8%, rgba(255, 255, 255, .55), transparent),
  radial-gradient(1px 1px at 71% 12%, rgba(255, 255, 255, .6), transparent), radial-gradient(1.3px 1.3px at 86% 26%, rgba(255, 255, 255, .5), transparent),
  radial-gradient(1px 1px at 8% 72%, rgba(255, 255, 255, .4), transparent), radial-gradient(1px 1px at 93% 78%, rgba(255, 255, 255, .45), transparent),
  radial-gradient(55% 50% at 52% 60%, rgba(255, 170, 90, .16), transparent 70%),
  radial-gradient(80% 80% at 50% 50%, #1a2350 0%, #0d1330 58%, #070a1a 100%); }
.hq-stage[data-sky='day'] { background: radial-gradient(42% 40% at 90% 6%, rgba(255, 236, 190, .55), transparent 70%), radial-gradient(60% 60% at 52% 58%, #ffffff, #edf5fc 76%); }
.hq-stage[data-sky='night'] .hq-legend { background: rgba(12, 16, 38, .78); color: #c9cde6; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .08); }
.hq-stage[data-sky='night'] .hq-veil { background: #0d1330; color: #c9cde6; }
.fs[data-sky='night'] .fs-kick { color: rgba(220, 226, 255, .45); }
.fs[data-sky='night'] .fs-shaft { background: repeating-linear-gradient(rgba(220, 226, 255, .28) 0 4px, transparent 4px 7px); }
.fs[data-sky='night'] .fs-lbl b { color: rgba(220, 226, 255, .42); } .fs[data-sky='night'] .fs-lbl small { color: rgba(220, 226, 255, .3); }
.fs[data-sky='night'] .fs-lbl.on b { color: color-mix(in srgb, var(--fc) 70%, #fff); } .fs[data-sky='night'] .fs-lbl.on small { color: color-mix(in srgb, var(--fc) 45%, #fff); }
.fs[data-sky='night'] .fs-plate .fs-img { filter: saturate(.5) brightness(.9); }
.fs[data-sky='night'] .fs-plate.on .fs-img, .fs[data-sky='night'] .fs-plate.hov .fs-img { filter: none; }
.fs[data-sky='night'] .fs-plate.on { filter: drop-shadow(0 10px 16px color-mix(in srgb, var(--fc) 55%, transparent)) drop-shadow(0 0 10px rgba(255, 190, 110, .25)); }
@media (prefers-reduced-motion: reduce) { .om-sky i, .om-sky b { animation: none !important; } }
