/* หิวดึก — สตรีมเกม (game launcher) / งานในจอ (work hub) overlays on the monitor + คู่มือ (docs/APPS.md). New UI only. */
.monov { position: fixed; z-index: 4; display: none; flex-direction: column; background: radial-gradient(120% 90% at 50% 0%, #1d2350, #0b0d22 70%); border-radius: 4px; overflow: hidden; box-shadow: 0 0 0 1px #000, 0 0 40px rgba(120,160,255,.25); color: var(--ink); }
.monov.on { display: flex; }
.monov.full { z-index: 9; border-radius: 0; padding-top: var(--safe-t); padding-bottom: var(--safe-b); }
body.hubon #dock, body.hubon #roombar, body.hubon #emopick, body.hubon #zoombox { display: none; }
body.hubon:has(.monov.full.on) #hud, body.hubon:has(.monov.full.on) #badges, body.hubon:has(.monov.full.on) #habits { display: none; }
.hub-bar { flex: 0 0 auto; display: flex; align-items: center; gap: 8px; padding: 6px 8px; background: linear-gradient(180deg, #2a2f55, #1b1f3d); font-size: 15px; min-width: 0; }
.hub-bar b { flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hub-ic { width: 26px; height: 26px; border-radius: 7px; flex: 0 0 auto; }
.hub-pill { flex: 0 0 auto; font-size: 12px; padding: 2px 9px; border-radius: 999px; background: #8be3a022; color: var(--good); border: 1px solid #8be3a055; white-space: nowrap; }
.hub-pill.gold { background: #ffcf5a1c; color: var(--gold); border-color: #ffcf5a55; }
.hub-x { flex: 0 0 auto; width: 34px; height: 32px; border-radius: 8px; border: 1px solid #ffffff22; background: #ffffff12; color: #fff; font-size: 15px; }
.hub-x:active { background: #ffffff30; }
.hub-body { flex: 1; min-height: 0; overflow-y: auto; overflow-x: hidden; padding: 10px; overscroll-behavior: contain; }

/* launcher grid */
.gh-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 10px; }
.gh-tile { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 8px 6px; border-radius: 14px; border: 1px solid var(--line); background: #ffffff0c; text-align: center; min-width: 0; }
.gh-tile:active { transform: translateY(1px); background: #ffffff1c; }
.gh-tile img { width: 100%; max-width: 88px; aspect-ratio: 1; object-fit: cover; border-radius: 16px; background: #0006; box-shadow: 0 4px 10px #0007; }
.gh-tile b { font-size: 13px; font-weight: 500; line-height: 1.25; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.gh-tile small { font-size: 11px; color: var(--dim); max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.gh-empty { grid-column: 1 / -1; display: grid; place-items: center; gap: 8px; padding: 18px 8px; text-align: center; color: var(--dim); }
.gh-empty img { width: 96px; height: 96px; border-radius: 20px; opacity: .85; }
.gh-empty p { margin: 0; font-size: 14px; }

/* work hub */
.is-list { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 10px; }
.is-tile { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 10px 8px; border-radius: 16px; border: 1px solid var(--line); background: #ffffff0c; text-align: center; min-width: 0; }
.is-tile:active { transform: translateY(1px); background: #ffffff1c; }
.is-im { position: relative; width: 72%; max-width: 96px; }
.is-im img { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 18px; box-shadow: 0 4px 12px #0008; display: block; }
.is-lock { position: absolute; right: -6px; top: -6px; width: 28px; height: 28px; display: grid; place-items: center; border-radius: 50%; background: #1b1f3d; border: 1.5px solid var(--gold); font-style: normal; font-size: 14px; }
.is-tx { display: flex; flex-direction: column; gap: 2px; min-width: 0; max-width: 100%; }
.is-tx b { font-size: 15px; font-weight: 600; }
.is-tx small { font-size: 11.5px; color: var(--dim); line-height: 1.3; }
.is-tile em { font-style: normal; font-size: 13px; font-weight: 600; color: var(--gold); padding: 2px 10px; border-radius: 999px; background: #0006; }
.is-tile.locked .is-im img { filter: grayscale(1) brightness(.65); }
.is-tile.locked em { color: var(--dim); }
.is-tile.warn em { color: #ffb3b3; }
.is-tile.off { opacity: .55; cursor: not-allowed; }
.is-tile.off em { color: var(--dim); }
/* short monitor (desktop window not full): tiles in one row, smaller text */
.monov:not(.full) .is-list { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.monov:not(.full) .is-tx small { display: none; }

/* in-game browser: link / game mode has no "open outside" button */
#webwin [data-a=ext][hidden] { display: none !important; }

/* guide button under ขนมฟรี + the guide window */
.badge.guide img.bi { width: 1.25em; height: 1.25em; vertical-align: -.25em; margin-right: .2em; }
.badge.guide { font-weight: 600; }
.card.guide { width: min(640px, 100%); }
.gd { display: flex; flex-direction: column; gap: 10px; }
.gd-chips { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; padding: 2px 0 4px; }
.gd-chips::-webkit-scrollbar { display: none; }
.gd-chip { flex: 0 0 auto; display: flex; align-items: center; gap: 5px; padding: 6px 12px; border-radius: 999px; border: 1px solid var(--line); background: #ffffff0c; font-size: 14px; white-space: nowrap; min-height: 36px; }
.gd-chip.on { background: linear-gradient(90deg, #7c8cff, #b07cff); border-color: transparent; color: #fff; font-weight: 600; }
.gd-ic { width: 1.3em; height: 1.3em; border-radius: 4px; object-fit: cover; }
img.i2.gd-ic { width: 1.6em; height: 1.6em; border-radius: .35em; object-fit: contain; filter: drop-shadow(0 1px 2px #0007); }
.gd-h img.i2.gd-ic { width: 1.5em; height: 1.5em; }
.gd-nav .btn img.i2.inl.gd-r { margin: 0 0 0 .3em; }
.gd-h { display: flex; align-items: center; gap: 8px; margin: 2px 0 6px; font-size: 18px; }
.gd-tx { font-size: 15px; line-height: 1.6; overflow-wrap: anywhere; }
.gd-tx p { margin: 0 0 10px; }
.gd-tx ul { margin: 0 0 10px; padding-left: 1.25em; }
.gd-tx li { margin: 3px 0; }
.gd-tx h4 { margin: 12px 0 6px; font-size: 15.5px; color: var(--gold); }
.gd-tx b { color: #fff; font-weight: 600; }
.gd-nav { display: flex; align-items: center; justify-content: space-between; gap: 8px; position: sticky; bottom: -16px; padding: 8px 0 2px; background: var(--panel); }
.gd-nav .btn { flex: 0 1 auto; min-width: 0; }
.gd-nav small { color: var(--dim); }
#webwin .wb-top { width: auto; padding: 0 10px; white-space: nowrap; font-size: 12px; font-weight: 700; border-radius: 14px; background: linear-gradient(#ffd36a, #f0a93a); color: #3a2400; }
#webwin .wb-top[hidden] { display: none !important; }
