/* TWR GOGGLES OS (2.2): the goggles HUD, talking-character cards, the goggles page and the TWR
   collection page. Flat: no glow, no shadows, no text effects. Colour: the app accent (green-yellow). */
:root { --gos: var(--accent, #e8ff47); --gos-ink: #0c0e11; --gos-bg: rgba(12, 14, 17, .78); --gos-bg2: rgba(12, 14, 17, .92); --gos-line: rgba(232, 255, 71, .55); }

/* ------------------------------------------------------------------ HUD */
.gos { position: fixed; inset: 0; z-index: 25; pointer-events: none; font-family: var(--font); color: var(--text); overflow: hidden; --gos-top: 0px; }
.gos.preview { position: absolute; }
.gos[hidden] { display: none !important; }
.gos * { box-sizing: border-box; }
.gos .gos-safe { position: absolute; left: 0; top: 0; width: 0; height: 0; padding: env(safe-area-inset-top) env(safe-area-inset-right) env(safe-area-inset-bottom) env(safe-area-inset-left); visibility: hidden; }

/* the goggles: white scratched metal cut to the screen, a dip with the name, a yellow lens frame */
.gos .gos-frame { position: absolute; inset: 0; }
.gos .gos-metal { position: absolute; left: 0; top: 0; display: block; pointer-events: none; }
.gos .gos-metal-body > path:first-child { pointer-events: visiblePainted; }
.gos .gos-dip { position: absolute; left: calc(50% - var(--dipw) / 2); width: var(--dipw); top: var(--fst); height: calc(var(--ft) - var(--fst) + var(--dipd)); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; color: #1a1f25; pointer-events: none; }
.gos .gos-dip b { font-weight: 800; font-size: min(13px, calc(var(--dipw) / 11.5)); letter-spacing: .14em; white-space: nowrap; line-height: 1.1; }
.gos .gos-dip .gos-tier { background: #14181d; color: var(--gos); font: 800 8.5px var(--mono); letter-spacing: .14em; padding: 1px 8px; border-radius: 99px; line-height: 1.5; }
.gos .gos-dip .gos-tier.std { background: transparent; color: #14181d; border: 1px solid #14181d; }
.gos .gos-rimt { position: absolute; top: var(--fst); height: calc(var(--ft) - var(--fst)); display: flex; align-items: center; gap: 7px; font: 800 10.5px var(--mono); color: #2a3036; white-space: nowrap; pointer-events: none; }
.gos .gos-rimt.l { left: calc(var(--fl) / 2 + 13px); }
.gos .gos-rimt.r { right: calc(var(--fr) / 2 + 13px); }
.gos .gos-rimt [data-r="bat"] { display: inline-flex; align-items: center; gap: 5px; }
.gos .gos-ratio { display: none; color: #6c737b; }
.gos.preview .gos-ratio { display: inline; }
.gos .gos-bat { display: inline-block; width: 20px; height: 10px; border: 1.5px solid #2a3036; border-radius: 2px; position: relative; }
.gos .gos-bat::after { content: ''; position: absolute; right: -4px; top: 2px; width: 2px; height: 4px; background: #2a3036; border-radius: 0 1px 1px 0; }
.gos .gos-bat span { position: absolute; left: 1px; top: 1px; bottom: 1px; background: #2a3036; border-radius: 1px; }

/* compass across the top of the lens */
.gos .gos-compass { position: absolute; top: var(--ctop); left: calc(50% - var(--cw) / 2); width: var(--cw); height: 28px; overflow: hidden; border-top: 1px solid var(--gos-line); border-bottom: 1px solid var(--gos-line); background: rgba(12, 14, 17, .4); border-radius: 6px; }
.gos .gos-tape { position: absolute; left: 0; top: 0; height: 100%; width: 0; }
.gos .gos-tape i { position: absolute; bottom: 0; width: 1px; height: 5px; background: rgba(232, 255, 71, .65); }
.gos .gos-tape i.md { height: 8px; }
.gos .gos-tape i.mj { height: 11px; width: 2px; margin-left: -.5px; background: var(--gos); }
.gos .gos-tape em { position: absolute; top: 3px; transform: translateX(-50%); font: 700 8px var(--mono); color: rgba(233, 236, 240, .85); font-style: normal; }
.gos .gos-tape em.cd { font-size: 10px; top: 2px; color: var(--gos); font-weight: 800; }
.gos .gos-tape u { position: absolute; bottom: 9px; width: 7px; height: 7px; margin-left: -3.5px; transform: rotate(45deg); background: var(--gos); border: 1px solid #0c0e11; }
.gos .gos-tape u.h { background: #ffffff; }
.gos .gos-cmark { position: absolute; left: 50%; bottom: 0; height: 12px; width: 2px; margin-left: -1px; background: #ffffff; }
.gos .gos-compass b { position: absolute; left: 50%; top: 2px; transform: translateX(-50%); background: #0c0e11; color: var(--gos); font: 800 10px var(--mono); padding: 0 6px; border-radius: 4px; border: 1px solid var(--gos-line); white-space: nowrap; }
.gos .gos-compass.nohdg .gos-tape { opacity: .35; }

/* readout widgets: drawers on the left and right of the lens */
.gos .gos-wcol { position: absolute; top: max(var(--chrome), var(--it, 0px)); bottom: calc(var(--fb) + var(--ib, 0px) + 8px); width: min(236px, calc(50% - var(--fl) - 12px)); display: flex; flex-direction: column; gap: 6px; overflow-y: auto; scrollbar-width: none; pointer-events: none; }
.gos .gos-wcol::-webkit-scrollbar { display: none; }
.gos .gos-wcol.l { left: calc(var(--fl) + 8px); align-items: flex-start; }
.gos .gos-wcol.r { right: calc(var(--fr) + 8px); align-items: flex-end; }
.gos .gos-w { pointer-events: auto; width: 100%; flex: none; background: rgba(12, 14, 17, .66); border: 1px solid var(--gos-line); border-radius: 10px; overflow: hidden; }
.gos .gos-w:not(.open) { width: auto; max-width: 100%; }
.gos .gos-wcol.l .gos-w { border-left: 3px solid var(--gos); }
.gos .gos-wcol.r .gos-w { border-right: 3px solid var(--gos); }
.gos .gos-wh { display: flex; align-items: center; gap: 8px; width: 100%; background: none; border: 0; color: var(--gos); font: 800 10px var(--mono); letter-spacing: .14em; padding: 6px 9px; cursor: pointer; text-align: left; touch-action: manipulation; }
.gos .gos-wh .lock { font-size: 8px; border: 1px solid var(--gos); border-radius: 99px; padding: 0 5px; letter-spacing: .06em; }
.gos .gos-wh .gos-wx { margin-left: auto; font-size: 14px; line-height: 1; padding-left: 6px; }
.gos .gos-wb { display: grid; grid-template-rows: 0fr; transition: grid-template-rows .22s ease; }
.gos .gos-w.open .gos-wb { grid-template-rows: 1fr; }
.gos .gos-wi { overflow: hidden; min-height: 0; padding: 0 9px; }
.gos .gos-w.open .gos-wi { padding-bottom: 7px; }
.gos .gos-wr[hidden] { display: none; }
.gos .gos-wr { display: flex; gap: 8px; font: 600 11px var(--mono); color: #dfe5c4; padding: 3px 0; border-top: 1px solid rgba(232, 255, 71, .14); }
.gos .gos-wr b { color: var(--gos); flex: none; min-width: 38px; font-weight: 800; }
.gos .gos-wr span { min-width: 0; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; word-break: break-word; }
.gos .gos-wn { margin: 5px 0 2px; font-size: 11px; color: #c9cfd6; white-space: pre-wrap; }
.gos .gos-wn a, .gos .gos-wl { color: var(--gos); font: 800 11px var(--font); }
.gos .gos-wl { display: inline-block; margin-top: 4px; }
.gos .gos-w.locked .gos-wh { color: #c9cfd6; }

/* controls on the bottom rim */
.gos .gos-rim { position: absolute; left: 50%; transform: translateX(-50%); bottom: calc(var(--fsb) + (var(--fb) - var(--fsb) - 46px) / 2); display: flex; gap: 5px; pointer-events: auto; }
.gos .gos-key { width: min(42px, calc((100vw - 60px) / var(--nk, 7) - 5px)); height: 46px; border-radius: 9px; border: 1px solid #0c0e11; background: #14181d; color: var(--gos); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; font: 800 7.5px var(--mono); letter-spacing: .04em; padding: 0; cursor: pointer; position: relative; touch-action: manipulation; }
.gos .gos-key svg { width: 19px; height: 19px; flex: none; }
.gos .gos-key span:not(.lock) { white-space: nowrap; }
.gos .gos-key.on { background: var(--gos); color: var(--gos-ink); border-color: var(--gos); }
.gos .gos-key .lock { position: absolute; top: 1px; right: 2px; font-size: 6.5px; }
.gos .gos-key[data-dock="show"] { display: none; width: 58px; }
.gos.hud-off .gos-key { display: none; }
.gos.hud-off .gos-key[data-dock="show"] { display: flex; }
.gos.hud-off .gos-compass, .gos.hud-off .gos-wcol, .gos.hud-off .gos-panel { display: none !important; }
.gos[data-profile="phone-landscape"] .gos-rim { bottom: calc(var(--fsb) + (var(--fb) - var(--fsb) - 40px) / 2); }
.gos[data-profile="phone-landscape"] .gos-key { height: 40px; width: 44px; }
.gos[data-profile="phone-landscape"] .gos-key span:not(.lock) { display: none; }

/* panels open inside the lens */
.gos .gos-panel { position: absolute; pointer-events: auto; top: var(--chrome); bottom: calc(var(--fb) + 8px); left: max(calc(var(--fl) + 8px), calc(50% - 250px)); right: max(calc(var(--fr) + 8px), calc(50% - 250px)); background: rgba(12, 14, 17, .96); border: 1.5px solid var(--gos); border-radius: 14px; display: flex; flex-direction: column; overflow: hidden; touch-action: auto; z-index: 2; }
.gos .gos-cap { position: absolute; left: 50%; transform: translateX(-50%); bottom: calc(var(--fb) + var(--ib, 0px) + 10px); max-width: min(86%, 620px); background: rgba(12, 14, 17, .94); border: 1px solid var(--gos); border-radius: 12px; padding: 7px 12px; font-size: 13px; font-weight: 600; text-align: center; z-index: 3; }
.gos .gos-cap small { display: block; color: var(--gos); font: 700 10px var(--mono); letter-spacing: .1em; margin-bottom: 1px; }

/* boot: the goggles close in, the yellow frame draws, the readouts come on */
.gos .gos-boot { position: absolute; left: 50%; top: 46%; transform: translate(-50%, -50%); display: flex; flex-direction: column; align-items: center; gap: 4px; color: var(--gos); text-align: center; z-index: 4; }
.gos .gos-boot small { font: 800 11px var(--mono); letter-spacing: .3em; color: #e9ecf0; }
.gos .gos-boot b { font: 800 clamp(16px, 5vw, 24px) var(--font); letter-spacing: .16em; white-space: nowrap; }
.gos .gos-boot span { font: 700 10px var(--mono); letter-spacing: .2em; border: 1px solid var(--gos); border-radius: 99px; padding: 2px 10px; }
.gos.booting .gos-frame { animation: gosClose .65s cubic-bezier(.2, .8, .2, 1) both; transform-origin: 50% 50%; }
.gos.booting .gos-yline { stroke-dasharray: 1; animation: gosDraw .8s .5s ease-out both; }
.gos.booting .gos-yband { animation: gosFade .5s 1s both; }
.gos.booting .gos-dip > *, .gos.booting .gos-rimt, .gos.booting .gos-compass, .gos.booting .gos-wcol, .gos.booting .gos-rim { animation: gosFade .35s 1.25s both; }
.gos.booting .gos-boot { animation: gosBoot 1.9s both; }
@keyframes gosClose { from { transform: scale(1.3); opacity: 0; } to { transform: none; opacity: 1; } }
@keyframes gosDraw { from { stroke-dashoffset: 1; } to { stroke-dashoffset: 0; } }
@keyframes gosFade { from { opacity: 0; } to { opacity: 1; } }
@keyframes gosBoot { 0%, 25% { opacity: 0; } 35%, 80% { opacity: 1; } 100% { opacity: 0; } }

/* first-run walkthrough */
.gos .gos-tour { position: absolute; inset: 0; pointer-events: auto; z-index: 6; }
.gos .gos-tdim { position: absolute; background: rgba(6, 8, 10, .64); }
.gos .gos-tring { position: absolute; border: 2px solid var(--gos); border-radius: 12px; pointer-events: none; }
.gos .gos-tcard { position: absolute; background: #0c0e11; border: 1.5px solid var(--gos); border-radius: 14px; padding: 12px 14px 10px; }
.gos .gos-tcard h4 { margin: 2px 0 4px; font-size: 16px; color: var(--text); }
.gos .gos-tcard p { margin: 0 0 10px; font-size: 13px; line-height: 1.45; color: #d4d9df; }
.gos .gos-tstep { font: 800 10px var(--mono); letter-spacing: .16em; color: var(--gos); }
.gos .gos-trow { display: flex; gap: 6px; align-items: center; }
.gos .gos-tdots { display: flex; gap: 4px; justify-content: center; margin-top: 8px; }
.gos .gos-tdots i { width: 6px; height: 6px; border-radius: 50%; background: #39414b; }
.gos .gos-tdots i.on { background: var(--gos); }
@media (prefers-reduced-motion: reduce) { .gos .gos-wb { transition: none; } }

/* the page's own controls move inside the lens while the goggles are on */
body.gos-framed #hudTop { top: var(--gf-top) !important; left: calc(var(--gf-side) + 8px) !important; right: calc(var(--gf-right) + 8px) !important; }
body.gos-framed #hudBottom { bottom: calc(var(--gf-bottom) + 8px) !important; }
body.gos-framed #overlay { padding-bottom: calc(var(--gf-bottom) + 10px) !important; }
body.gos-framed .hint { top: 44% !important; }

/* 2.4: metal per tier - text on the rim follows the metal */
.gos { --metal-ink: #1a1f25; --metal-ink2: #2a3036; }
.gos.metal-gunmetal, .gos.metal-black { --metal-ink: #e9ecf0; --metal-ink2: #c9cfd6; }
.gos.metal-gold { --metal-ink: #221b06; --metal-ink2: #3a2f0e; }
.gos .gos-dip { color: var(--metal-ink); }
.gos .gos-rimt { color: var(--metal-ink2); }
.gos .gos-bat { border-color: var(--metal-ink2); }
.gos .gos-bat::after, .gos .gos-bat span { background: var(--metal-ink2); }
.gos.metal-gunmetal .gos-dip .gos-tier.std, .gos.metal-black .gos-dip .gos-tier.std { color: var(--gos); border-color: var(--gos); }
.gos.metal-gunmetal .gos-key, .gos.metal-black .gos-key { border-color: #3a4048; }
/* 2.4: the HUD turned inside its own layer when the device cannot lock its orientation */
.gos-rot { position: fixed; z-index: 25; transform-origin: 50% 50%; pointer-events: none; }
.gos-rot > * { pointer-events: auto; }
.gos-rot > .gos { pointer-events: none; }
.gos .gos-ori button { font-size: 10.5px; }
/* 2.4: virtual flight under the goggles frame */
.gos-flight { position: fixed; inset: 0; z-index: 24; background: #a9bfd1; }
.gos-flight canvas { display: block; width: 100%; height: 100%; touch-action: none; }
.gos-flight .gos-fly-bar { position: absolute; left: 50%; transform: translateX(-50%); bottom: calc(var(--gf-bottom, 60px) + 12px); display: flex; gap: 6px; z-index: 2; }
.gos-flight .gos-fly-bar button { background: #0c0e11; color: #e8ff47; border: 1px solid #e8ff47; border-radius: 8px; padding: 7px 10px; font: 800 10.5px var(--mono); letter-spacing: .08em; cursor: pointer; }
.gos-flight .gos-fly-bar button.land { background: #e8ff47; color: #0c0e11; }
.gos-flight .gos-fly-bar button.on { background: #e8ff47; color: #0c0e11; }
.gos-flight .gos-fly-read { position: absolute; left: 50%; transform: translateX(-50%); bottom: calc(var(--gf-bottom, 60px) + 52px); background: rgba(12, 14, 17, .7); color: #e8ff47; font: 800 11px var(--mono); padding: 3px 9px; border-radius: 6px; white-space: nowrap; }
.gos.flying .gos-wcol { opacity: .92; }
/* 2.4: glasses display - black is see-through in optical display glasses */
body.gos-glasses { background: #000 !important; }

/* 2.4: building with the goggles on - readouts step aside, the frame stays */
.gos.building .gos-wcol, .gos.building .gos-compass, .gos.building .gos-panel { display: none !important; }
.gos.building .gos-key:not([data-dock="build"]):not([data-dock="settings"]) { opacity: .45; }
.gos.building .gos-key[data-dock="build"] { background: var(--gos); color: var(--gos-ink); }
/* 2.4: microworld game bar and tabletop controls */
.mg-bar { position: fixed; z-index: 26; left: 50%; transform: translateX(-50%); top: calc(var(--gf-top, 64px) + 44px); display: flex; flex-wrap: wrap; gap: 6px; align-items: center; justify-content: center; max-width: min(94vw, 560px); background: rgba(12, 14, 17, .9); border: 1.5px solid var(--gos, #e8ff47); border-radius: 12px; padding: 6px 10px; color: #e9ecf0; font-size: 12px; }
.mg-bar > b { color: var(--gos, #e8ff47); letter-spacing: .06em; }
.mg-bar .mg-sub { color: #9aa3ad; font-size: 11px; }
.mg-bar .mg-stat { font: 800 12px var(--mono, monospace); }
.mg-bar .mg-stat i { font-style: normal; color: #9aa3ad; font-size: 9px; margin-right: 4px; letter-spacing: .1em; }
.mg-bar .mg-stat.warn { color: #ff8a65; }
.mg-bar button { background: none; color: var(--gos, #e8ff47); border: 1px solid rgba(232, 255, 71, .55); border-radius: 8px; padding: 3px 9px; font: 700 11px var(--font, sans-serif); cursor: pointer; }
.mg-bar button.mg-go { background: var(--gos, #e8ff47); color: #0c0e11; }
.mg-bar .mg-drop { flex-basis: 100%; border-top: 1px solid rgba(232, 255, 71, .25); padding-top: 6px; max-height: 40vh; overflow: auto; }
.mg-bar .mg-hint { border-left: 2px solid var(--gos, #e8ff47); padding: 2px 8px; margin: 3px 0; }
.mg-bar .mg-lb { display: flex; gap: 8px; align-items: center; padding: 2px 0; }
.mg-bar .mg-lb i { font-style: normal; color: var(--gos, #e8ff47); width: 16px; }
.mg-bar .mg-lb span { flex: 1; }
.mg-bar .mg-res b { font-size: 20px; color: var(--gos, #e8ff47); }
.table-bar { left: 50%; transform: translateX(-50%); bottom: calc(var(--gf-bottom, 0px) + 64px); display: flex; gap: 6px; }
.table-bar .btn { background: rgba(12, 14, 17, .86); }

/* panel contents */
.gos .gos-ph { display: flex; align-items: center; gap: 8px; padding: 10px 12px; border-bottom: 1px solid var(--gos-line); }
.gos .gos-ph h3 { margin: 0; font-size: 13px; letter-spacing: .16em; text-transform: uppercase; color: var(--gos); flex: 1; }
.gos .gos-ph button { background: none; border: 1px solid var(--gos-line); color: var(--gos); border-radius: 8px; padding: 3px 9px; font-weight: 800; cursor: pointer; }
.gos .gos-pb { flex: 1; overflow: auto; padding: 10px 12px 14px; -webkit-overflow-scrolling: touch; }
.gos .gos-tabs { display: flex; gap: 4px; flex-wrap: wrap; margin-bottom: 10px; }
.gos .gos-tabs button { background: none; border: 1px solid var(--gos-line); color: var(--text); border-radius: 99px; padding: 4px 10px; font: 700 11px var(--font); cursor: pointer; }
.gos .gos-tabs button.on { background: var(--gos); color: var(--gos-ink); border-color: var(--gos); }
.gos-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(104px, 1fr)); gap: 8px; }
.gos-item { border: 1px solid var(--line2); border-radius: 12px; overflow: hidden; background: rgba(20, 24, 29, .9); cursor: pointer; position: relative; text-align: left; padding: 0; color: var(--text); font: inherit; }
.gos-item .im { aspect-ratio: 1; background: #1b2027 center/cover no-repeat; display: flex; align-items: center; justify-content: center; color: var(--muted); font-size: 11px; }
.gos-item .tx { padding: 6px 7px 7px; font-size: 11px; }
.gos-item .tx b { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-size: 12px; }
.gos-item .tag { position: absolute; left: 5px; top: 5px; background: var(--gos); color: var(--gos-ink); font: 800 9px var(--mono); padding: 1px 6px; border-radius: 99px; letter-spacing: .06em; }
.gos-item .tag.v1 { background: #0c0e11; color: var(--gos); border: 1px solid var(--gos); }
.gos-item .qty { position: absolute; right: 5px; top: 5px; background: #0c0e11; color: var(--text); font: 700 10px var(--mono); padding: 1px 6px; border-radius: 99px; border: 1px solid var(--line2); }
.gos-sec { font: 800 10px var(--mono); letter-spacing: .16em; color: var(--gos); text-transform: uppercase; margin: 12px 0 6px; display: flex; justify-content: space-between; gap: 8px; }
.gos-sec span { color: var(--muted); letter-spacing: .04em; }
.gos-empty { color: var(--muted); font-size: 12px; padding: 8px 0; }
.gos-row { display: flex; gap: 8px; align-items: center; }
.gos-card { border: 1px solid var(--line2); border-radius: 12px; padding: 10px; margin-bottom: 8px; background: rgba(20, 24, 29, .9); }
.gos-card.lock { opacity: .75; }
.gos-card h4 { margin: 0 0 4px; font-size: 14px; color: var(--text); text-transform: none; letter-spacing: 0; }
.gos-bar { height: 6px; border-radius: 6px; background: #2a313b; overflow: hidden; margin: 6px 0; }
.gos-bar span { display: block; height: 100%; background: var(--gos); }
.gos-hint { border-left: 2px solid var(--gos); padding: 4px 8px; margin: 5px 0; font-size: 12px; }
.gos-hint.locked { border-left-color: var(--line2); color: var(--muted); }
.gos-btn2 { background: var(--gos); color: var(--gos-ink); border: 1px solid var(--gos); border-radius: 8px; padding: 6px 11px; font: 700 12px var(--font); cursor: pointer; text-decoration: none !important; display: inline-flex; align-items: center; gap: 5px; }
.gos-btn2.ghost { background: none; color: var(--gos); border-color: var(--gos-line); }
.gos-map { height: 300px; border-radius: 12px; overflow: hidden; border: 1px solid var(--line2); }
.gos-map .leaflet-tile-pane { filter: invert(1) hue-rotate(180deg) brightness(.82) contrast(.92) saturate(.35); }
.gos-stat { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
.gos-stat div { border: 1px solid var(--line2); border-radius: 10px; padding: 8px; }
.gos-stat b { display: block; color: var(--gos); font-size: 16px; }
.gos-stat span { font-size: 10px; color: var(--muted); text-transform: uppercase; letter-spacing: .08em; }
.gos-detail .im { width: 100%; aspect-ratio: 1; border-radius: 12px; background: #1b2027 center/contain no-repeat; margin-bottom: 8px; border: 1px solid var(--line2); }
.gos-attrs { display: flex; flex-wrap: wrap; gap: 4px; margin: 6px 0; }
.gos-attrs span { border: 1px solid var(--line2); border-radius: 99px; padding: 2px 8px; font-size: 11px; }
.gos-attrs span b { color: var(--gos); font-weight: 700; margin-right: 4px; }
.gos-cmds { font-size: 12px; } .gos-cmds div { padding: 4px 0; border-bottom: 1px solid var(--line); } .gos-cmds b { color: var(--gos); }

/* ------------------------------------------------------------------ talk card */
.talk-card { position: fixed; z-index: 40; left: 50%; transform: translateX(-50%); bottom: calc(12px + env(safe-area-inset-bottom)); width: min(560px, calc(100vw - 20px)); background: rgba(12, 14, 17, .95); border: 1.5px solid var(--accent); border-radius: 16px; padding: 12px; color: var(--text); pointer-events: auto; touch-action: auto; }
.talk-head { display: flex; align-items: flex-start; gap: 8px; }
.talk-head > div { flex: 1; } .talk-head b { color: var(--accent); font-size: 15px; display: block; } .talk-head span { font-size: 12px; color: var(--muted); }
.talk-x { background: none; border: 1px solid var(--line2); color: var(--text); border-radius: 8px; width: 32px; height: 32px; font-size: 18px; cursor: pointer; }
.talk-say { margin: 8px 0; font-size: 14px; line-height: 1.45; min-height: 40px; max-height: 30vh; overflow: auto; }
.talk-topics { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 8px; }
.talk-chip { border: 1px solid var(--accent); background: none; color: var(--accent); border-radius: 99px; padding: 5px 11px; font: 700 12px var(--font); cursor: pointer; }
.talk-ask { display: flex; gap: 6px; }
.talk-ask input { flex: 1; }
.talk-mic, .talk-send { border: 1px solid var(--accent); background: none; color: var(--accent); border-radius: 8px; padding: 0 12px; font: 800 11px var(--font); cursor: pointer; }
.talk-send { background: var(--accent); color: var(--accent-ink); }
.talk-mic.on { background: var(--accent); color: var(--accent-ink); }

/* ------------------------------------------------------------------ goggles page + collection page */
.gpage { max-width: 1020px; margin: 0 auto; padding: 18px 16px 48px; }
.gpage .gtop { display: flex; align-items: center; gap: 10px; margin-bottom: 18px; flex-wrap: wrap; }
.gpage .gtop .wl-mark { border: 0; padding: 0; background: none; }
.gpage .gtop .sp { flex: 1; }
.ghero { display: grid; grid-template-columns: 1.1fr 1fr; gap: 22px; align-items: center; margin-bottom: 22px; }
@media (max-width: 780px) { .ghero { grid-template-columns: 1fr; } }
.ghero h1 { font-size: 34px; line-height: 1.05; letter-spacing: -.02em; margin: 6px 0 10px; }
.ghero h1 .acc { color: var(--accent); }
.ghero p { color: #c9ced6; }
.gsets { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
@media (max-width: 560px) { .gsets { grid-template-columns: 1fr; } }
.gset { border: 1px solid var(--line2); border-radius: 16px; overflow: hidden; background: var(--surface); }
.gset.premium { border-color: var(--accent); }
.gset .im { aspect-ratio: 16 / 10; background: #0f1216 center/cover no-repeat; border-bottom: 1px solid var(--line); }
.gset .b { padding: 12px 14px; }
.gset .tier { display: inline-block; font: 800 10px var(--mono); letter-spacing: .14em; padding: 2px 8px; border-radius: 99px; border: 1px solid var(--accent); color: var(--accent); }
.gset.premium .tier { background: var(--accent); color: var(--accent-ink); }
.gset h3 { margin: 8px 0 6px; }
.gset ul { margin: 0; padding-left: 18px; font-size: 13px; color: #c9ced6; }
.gset ul li { margin: 3px 0; }
.gsteps { counter-reset: s; display: grid; gap: 10px; }
.gstep { border: 1px solid var(--line2); border-radius: 14px; padding: 14px; background: var(--surface); position: relative; padding-left: 52px; }
.gstep::before { counter-increment: s; content: counter(s); position: absolute; left: 14px; top: 14px; width: 26px; height: 26px; border-radius: 50%; border: 1.5px solid var(--accent); color: var(--accent); font: 800 13px var(--mono); display: flex; align-items: center; justify-content: center; }
.gstep.done::before { background: var(--accent); color: var(--accent-ink); content: 'OK'; font-size: 9px; }
.gstep h3 { margin: 2px 0 6px; }
.gwallet { border: 1px solid var(--line); border-radius: 12px; padding: 10px; margin-top: 8px; background: var(--bg); }
.gwallet .addr { font: 600 12px var(--mono); word-break: break-all; }
.gwallet .st { display: flex; flex-wrap: wrap; gap: 6px; margin: 6px 0; }
.gpill { border: 1px solid var(--line2); border-radius: 99px; padding: 2px 9px; font-size: 11px; font-weight: 700; }
.gpill.ok { border-color: var(--ok); color: var(--ok); } .gpill.acc { border-color: var(--accent); color: var(--accent); } .gpill.no { color: var(--muted); }
.gowned { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; margin-top: 8px; }
.gowned .gset .im { aspect-ratio: 16 / 10; }

.cstats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin: 12px 0 18px; }
@media (max-width: 760px) { .cstats { grid-template-columns: 1fr 1fr; } }
.cstat { border: 1px solid var(--line2); border-radius: 14px; padding: 12px 14px; background: var(--surface); }
.cstat.hi { border-color: var(--accent); }
.cstat span { display: block; font: 700 10px var(--mono); letter-spacing: .12em; color: var(--muted); text-transform: uppercase; }
.cstat b { display: block; font-size: 24px; letter-spacing: -.01em; margin-top: 4px; }
.cstat.hi b { color: var(--accent); }
.cstat small { display: block; color: var(--muted); font-size: 12px; margin-top: 2px; }
.cpanel { border: 1px solid var(--line2); border-radius: 16px; padding: 14px; background: var(--surface); margin-bottom: 14px; }
.cpanel h2 { font-size: 15px; margin: 0 0 10px; display: flex; justify-content: space-between; gap: 8px; align-items: baseline; flex-wrap: wrap; }
.cpanel h2 small { font-weight: 500; color: var(--muted); font-size: 12px; }
.cchart { width: 100%; height: 220px; display: block; }
.ctoggle { display: inline-flex; border: 1px solid var(--line2); border-radius: 99px; overflow: hidden; }
.ctoggle button { background: none; border: 0; color: var(--muted); padding: 4px 10px; font: 700 11px var(--font); cursor: pointer; }
.ctoggle button.on { background: var(--accent); color: var(--accent-ink); }
.ctable { width: 100%; border-collapse: collapse; font-size: 13px; }
.ctable th { text-align: left; font: 700 10px var(--mono); letter-spacing: .1em; color: var(--muted); text-transform: uppercase; padding: 6px 6px; border-bottom: 1px solid var(--line); }
.ctable td { padding: 7px 6px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.ctable td.n { text-align: right; font-family: var(--mono); font-size: 12px; white-space: nowrap; }
.ctable tr:last-child td { border-bottom: 0; }
.ctok { display: flex; gap: 8px; align-items: center; }
.ctok i { width: 34px; height: 34px; border-radius: 8px; background: #1b2027 center/cover no-repeat; flex: none; border: 1px solid var(--line); }
.cgrid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
@media (max-width: 860px) { .cgrid2 { grid-template-columns: 1fr; } }
.ctip { position: fixed; pointer-events: none; z-index: 60; background: #0c0e11; border: 1px solid var(--accent); border-radius: 8px; padding: 6px 9px; font-size: 12px; white-space: nowrap; }
.cgallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); gap: 8px; }
.cgallery a { border: 1px solid var(--line); border-radius: 12px; overflow: hidden; color: var(--text); text-decoration: none !important; background: var(--bg); }
.cgallery a i { display: block; aspect-ratio: 1; background: #1b2027 center/cover no-repeat; }
.cgallery a span { display: block; padding: 6px 8px; font-size: 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cnote { font-size: 12px; color: var(--muted); }
/* 2.4: profile, studio, creators pages */
.pf-av { width: 72px; height: 72px; border-radius: 50%; background: #1b2027 center/cover no-repeat; border: 2px solid var(--accent); display: flex; align-items: center; justify-content: center; font: 800 28px var(--font); color: var(--accent); flex: none; }
.st-tabs { display: flex; gap: 6px; flex-wrap: wrap; margin: 6px 0 14px; }
.st-tabs button { background: none; border: 1px solid var(--line2); color: var(--text); border-radius: 99px; padding: 6px 14px; font-weight: 700; cursor: pointer; }
.st-tabs button.on { background: var(--accent); color: var(--accent-ink, #0c0e11); border-color: var(--accent); }
.st-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; }
.st-grid .card { padding: 8px; }
.st-grid .card i { display: block; aspect-ratio: 1; border-radius: 8px; background: #1b2027 center/cover no-repeat; margin-bottom: 6px; }

/* 2.4: messages sit above the rim keys while the goggles are on */
body.gos-framed .toasts { bottom: calc(96px + env(safe-area-inset-bottom, 0px)); }
