/* Green the Desert v6 as a building game: the Build screen's HUD over the full-screen 3D farm (js/farm-game.js).
   Flat dark glass in both themes, no shadows or gradients, green #00FF6F for what is picked or passing. */
.fg { position: absolute; inset: 0; overflow: hidden; color: #fff; background: #0a0a0b}
.fg .mx-scene.fg-scene { position: absolute; inset: 0; top: 0; width: 100%; height: 100%; z-index: 0; background: #c9a25a}
.fg .fg-scene .s3d { position: absolute; inset: 0}
.fg-glass { background: rgba(12, 12, 14, 0.8); border: 1px solid rgba(255, 255, 255, 0.09); border-radius: 18px; backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px)}
.fg-lab { display: flex; align-items: center; gap: 6px; font-size: 11.5px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: #a1a1a6}

/* the top bar: back, the mission, its seven steps, tutorials, the mentor, the learner */
.fg-top { position: absolute; inset-inline: 16px; top: 14px; height: 60px; z-index: 10; display: flex; align-items: center; gap: 12px; pointer-events: none}
.fg-top > * { pointer-events: auto}
.fg-ib, .fg-me { width: 52px; height: 52px; border-radius: 16px; display: grid; place-items: center; background: rgba(12, 12, 14, 0.8); border: 1px solid rgba(255, 255, 255, 0.09); color: #fff; backdrop-filter: blur(12px)}
.fg-me { padding: 0; overflow: hidden}
.fg-ttl { padding: 8px 16px; border-radius: 16px; background: rgba(12, 12, 14, 0.8); border: 1px solid rgba(255, 255, 255, 0.09); backdrop-filter: blur(12px)}
.fg-ttl h1 { margin: 0; font-size: 19px; font-weight: 700; letter-spacing: -.01em; line-height: 1.2}
.fg-ttl small { display: block; font-size: 12.5px; color: #c7c7cc}
.fg-steps { margin-inline: auto; display: flex; gap: 6px; padding: 8px 10px; border-radius: 16px; background: rgba(12, 12, 14, 0.8); border: 1px solid rgba(255, 255, 255, 0.09); backdrop-filter: blur(12px)}
.fg-steps button { width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; font-size: 13.5px; font-weight: 700; color: #c7c7cc; background: rgba(255, 255, 255, 0.06); border: 1px solid rgba(255, 255, 255, 0.1)}
.fg-steps button.done { color: #0a0a0b; background: #00FF6F; border-color: #00FF6F}
.fg-steps button.now { color: #fff; border: 2px solid #00FF6F; background: rgba(0, 255, 111, 0.16)}
.fg-steps button.lock { color: #8e8e93}
.fg-tr { display: flex; gap: 8px; align-items: center}
.fg-hb { height: 52px; padding: 0 16px; border-radius: 16px; display: flex; align-items: center; gap: 8px; font-size: 14.5px; font-weight: 600; color: #fff; background: rgba(12, 12, 14, 0.8); border: 1px solid rgba(255, 255, 255, 0.09); backdrop-filter: blur(12px)}
.fg-hb .mface { width: 26px; height: 26px}

/* the quest */
.fg-quest { position: absolute; inset-inline-start: 16px; top: 88px; width: 300px; z-index: 6; padding: 14px 16px}
.fg-quest h2 { margin: 6px 0 10px; font-size: 17px; line-height: 1.3; font-weight: 700}
.fg-chips { display: flex; flex-wrap: wrap; gap: 6px}
.fg-chip { display: inline-flex; align-items: center; gap: 5px; height: 28px; padding: 0 10px; border-radius: 999px; font-size: 12.5px; font-weight: 600; color: #e5e5ea; background: rgba(255, 255, 255, 0.07)}
.fg-chip.ok { color: #0a0a0b; background: #00FF6F}
.fg-chip.no { color: #fff; background: #C2185B}
.fg-note { display: block; margin-top: 8px; font-size: 12px; color: #a1a1a6}

/* the minimap */
.fg-mini { position: absolute; inset-inline-end: 16px; top: 88px; width: 300px; z-index: 6; padding: 10px 10px 10px}
.fg-mini.plan { width: auto; padding: 8px}
.fg-mh { display: flex; align-items: center; justify-content: space-between; padding: 2px 4px 8px}
.fg-mini.plan .fg-mh { padding: 0}
.fg-mh b { font-size: 14px}
.fg-chipb { display: inline-flex; align-items: center; gap: 6px; height: 30px; padding: 0 12px; border-radius: 999px; font-size: 12.5px; font-weight: 600; color: #fff; background: rgba(255, 255, 255, 0.08); border: 1px solid rgba(255, 255, 255, 0.1)}
.fg-mapin { border-radius: 12px; overflow: hidden; cursor: crosshair; background: #d8b98a}
.fg-mapin .g2d, .fg-mapin svg { background: #d8b98a !important}
.fg-mapin .g-soil { fill: #e3c79a; stroke: rgba(120, 84, 30, 0.45)}
.fg-mapin .g-village { fill: #efe6d6}
.fg-mapin .g-road { fill: #55555a}
.fg-mapin .g-bg { fill: #d8b98a}
.fg-mapin rect[fill^="url(#g"], .fg-mapin .g-windi { display: none}
.fg-mapin svg { display: block; width: 100%; height: auto}
.fg-mapin .g2d-scale, .fg-mapin .g2d-north, .fg-mapin .g2d-xy, .fg-mapin svg text, .fg-mapin .g-minor { display: none}
.fg-cam-r { fill: rgba(0, 255, 111, 0.22); stroke: #00FF6F; stroke-width: 1.6}
.fg-cam-a { fill: #00FF6F; stroke: #0a0a0b; stroke-width: 1}

/* the hint */
.fg-hint { position: absolute; left: 50%; transform: translateX(-50%); bottom: 200px; z-index: 6; display: flex; align-items: center; gap: 8px; height: 38px; padding: 0 16px; border-radius: 999px; font-size: 13.5px; color: #e5e5ea; white-space: nowrap}

/* the bottom row: coins, the hotbar, Test the year */
.fg-bottom { position: absolute; inset-inline: 16px; bottom: 16px; z-index: 8; display: flex; align-items: flex-end; gap: 12px}
.fg-coins { width: 196px; flex: none; display: flex; align-items: center; gap: 12px; padding: 14px}
.fg-coins > div { flex: 1; min-width: 0}
.fg-coins b { display: block; font-size: 16px}
.fg-coins small { display: block; margin-top: 4px; font-size: 12px; color: #a1a1a6}
.fg-cbar { display: block; height: 8px; margin-top: 8px; border-radius: 999px; background: rgba(255, 255, 255, 0.1); overflow: hidden}
.fg-cbar i { display: block; height: 100%; border-radius: 999px; background: #FFD60A}
.fg-coins.over .fg-cbar i { background: #FF4FA3}
.fg-coins.over b { color: #FF80C0}
.fg-hotbar { flex: 0 1 auto; margin-inline: auto; min-width: 0; display: flex; align-items: stretch; gap: 12px; padding: 12px}
.fg-slots { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; padding-top: 8px; margin-top: -8px}
.fg-slot { position: relative; flex: none; width: 92px; height: 150px; padding: 8px 6px 8px; border-radius: 14px; display: flex; flex-direction: column; align-items: center; gap: 4px; color: #fff; background: rgba(255, 255, 255, 0.05); border: 1px solid rgba(255, 255, 255, 0.08); transition: transform .15s ease, border-color .15s ease, background .15s ease}
.fg-slot:hover { background: rgba(255, 255, 255, 0.09)}
.fg-slot.on { border: 2px solid #00FF6F; background: rgba(0, 255, 111, 0.12); transform: translateY(-6px)}
.fg-slot kbd { position: absolute; top: 6px; inset-inline-start: 6px; min-width: 18px; height: 18px; border-radius: 6px; font: 700 11px/18px inherit; color: #c7c7cc; background: rgba(255, 255, 255, 0.1); text-align: center}
.fg-slot .fg-n { position: absolute; top: 6px; inset-inline-end: 6px; min-width: 20px; height: 20px; padding: 0 5px; border-radius: 999px; font: normal 700 11.5px/20px inherit; color: #0a0a0b; background: #00FF6F}
.fg-th { width: 72px; height: 72px; display: grid; place-items: center; color: #c7c7cc}
.fg-th img { width: 100%; height: 100%; object-fit: contain; pointer-events: none}
.fg-slot b { font-size: 12.5px; font-weight: 600; line-height: 1.15; text-align: center; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical}
.fg-price { margin-top: auto; display: inline-flex; align-items: center; gap: 4px; font-size: 12.5px; font-weight: 700; color: #FFD60A}
.fg-slot.dear .fg-price { color: #FF80C0}
.fg-div { width: 1px; background: rgba(255, 255, 255, 0.1); flex: none}
.fg-sets { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 8px}
.fg-sets > div { display: flex; flex-wrap: wrap; gap: 6px}
.fg-set { display: inline-flex; align-items: center; gap: 6px; height: 36px; padding: 0 10px; border-radius: 10px; font-size: 12.5px; color: #e5e5ea; background: rgba(255, 255, 255, 0.05); border: 1px solid rgba(255, 255, 255, 0.08)}
.fg-set b { font-weight: 600}
.fg-set i { font-style: normal; font-size: 11.5px; color: #a1a1a6}
.fg-set.on { border-color: rgba(0, 255, 111, 0.6)}
.fg-set.on i { color: #00FF6F}
.fg-go { flex: none; height: 74px; padding: 0 28px; border-radius: 20px; font-size: 18px; gap: 10px}

/* the toolbar beside the picked part */
.fg-ctx { position: absolute; z-index: 9; display: flex; align-items: center; gap: 8px; padding: 8px 8px 8px 14px; border-radius: 16px; white-space: nowrap}
.fg-ctx b { font-size: 14px}
.fg-ctx small { font-size: 12.5px; color: #a1a1a6}
.fg-size { display: inline-flex; align-items: center; gap: 6px; height: 36px; padding: 0 6px; border-radius: 10px; background: rgba(255, 255, 255, 0.06)}
.fg-size button { width: 26px; height: 26px; border-radius: 8px; display: grid; place-items: center; color: #fff; background: rgba(255, 255, 255, 0.08)}
.fg-size b { font-size: 13px; min-width: 64px; text-align: center}
.fg-cb { width: 36px; height: 36px; border-radius: 10px; display: grid; place-items: center; color: #fff; background: rgba(255, 255, 255, 0.08)}
.fg-cb.del { color: #FF80C0}
.fg-coin { flex: none}

/* the big map: the plan over the 3D farm seen from above */
.fg-topwrap { position: absolute; inset: 88px 332px 214px 332px; z-index: 4}
.fg-topgrid { position: absolute; inset: 0}
.fg.plan .fg-hint { display: none}
[dir="rtl"] .fg-hint, [dir="rtl"] .fg-steps { direction: rtl}
/* the farm settings: one slot in the hotbar, the toggles in a small panel above it */
.fg-slot.fg-gear .fg-th { color: #e5e5ea}
.fg-slot.fg-gear .fg-price { color: #a1a1a6; font-weight: 600}
.fg-setpop { display: grid; gap: 6px; margin-top: 8px}
.fg-setpop .fg-set { width: 100%; justify-content: flex-start; height: 40px}
.fg-setpop .fg-set i { margin-inline-start: auto}

/* Test: the year plays on the farm; one short result card; the charts behind Details */
.fg-tbottom { position: absolute; left: 50%; transform: translateX(-50%); bottom: 16px; z-index: 8; width: 760px}
.fg-start, .fg-timeline, .fg-result { padding: 18px 20px}
.fg-start { display: flex; align-items: center; gap: 16px}
.fg-start > div { flex: 1}
.fg-start h2, .fg-result h2 { margin: 0; font-size: 21px; font-weight: 700; letter-spacing: -.01em}
.fg-start p, .fg-result p { margin: 4px 0 0; font-size: 14.5px; color: #c7c7cc; line-height: 1.4}
.fg-ri { width: 44px; height: 44px; flex: none; border-radius: 50%; display: grid; place-items: center; color: #0a0a0b; background: #FFD60A}
.fg-ri.ok { background: #00FF6F}
.fg-ri.big { width: 56px; height: 56px; background: #00FF6F}
.fg-rgo { height: 56px; padding: 0 22px; border-radius: 16px; font-size: 16px; gap: 8px; flex: none}
.fg-timeline { display: flex; align-items: center; gap: 16px}
.fg-pl { flex: none; min-width: 300px; display: flex; flex-direction: column; gap: 2px; font-size: 13.5px; color: #c7c7cc}
.fg-pl b { font-size: 16px; color: #fff}
.fg-pbar { flex: 1; height: 10px; border-radius: 999px; background: rgba(255, 255, 255, 0.1); overflow: hidden}
.fg-pbar i { display: block; height: 100%; border-radius: 999px; background: #00FF6F; transition: width .14s linear}
.fg-result { display: grid; grid-template-columns: minmax(0, 1fr); gap: 14px; align-items: start}
.fg-result > * { grid-column: 1 / -1; min-width: 0}
.fg-result .fg-rh > div { min-width: 0; flex: 1}
.fg-result .fg-chip { height: auto; min-height: 28px; padding-block: 5px; max-width: 100%; line-height: 1.35}
.fg-result .fg-chip svg, .fg-result .fi-vs > svg { flex-shrink: 0}
.fg-rh { display: flex; gap: 14px; align-items: flex-start; grid-column: 1}
.fg-result .fg-chips { grid-column: 1}
.fg-result .fg-rgo { grid-column: 1; grid-row: auto; justify-self: start}
.fg-idea { color: #e5e5ea !important}
.fg-pred { grid-column: 1 / -1; display: flex; gap: 8px; align-items: center; margin: 0; font-size: 13.5px; color: #c7c7cc}
.fg-pred.warn { color: #FFD60A}
.fg-ra { grid-column: 1 / -1; display: flex; gap: 8px; flex-wrap: wrap}
.fg-details { position: absolute; left: 50%; transform: translateX(-50%); top: 88px; z-index: 9; width: 780px; max-height: 640px; overflow: auto; padding: 16px 18px}
.fg-dh { display: flex; align-items: center; justify-content: space-between; margin-bottom: 8px}
.fg-dh b { font-size: 16px}
.fg-details .f6-csvg { height: 300px}

/* the other steps in the game frame: their content in a glass column between the goal card and the side list */
.fg.page .fg-page { position: absolute; inset-inline-start: 332px; width: 784px; top: 88px; bottom: 116px; z-index: 6; display: flex; flex-direction: column}
.fg.page .fg-page > .mx-panel, .fg.page .fg-page > .mx-info, .fg.page .fg-page > .mx-out, .fg.page .fg-page > section, .fg.page .fg-page > div { position: relative; inset: auto; top: auto; left: auto; right: auto; width: auto; height: auto; max-height: 100%; min-height: 0; flex: 0 1 auto; overflow: auto; border-radius: 18px; background: rgba(12, 12, 14, 0.82); border: 1px solid rgba(255, 255, 255, 0.09); backdrop-filter: blur(12px)}
.fg.page .fg-page .f6-brief { width: auto; max-height: 100%}
.fg.page .fg-quest { width: 300px}
.fg-side { position: absolute; inset-inline-end: 16px; top: 88px; width: 300px; max-height: 620px; z-index: 6; padding: 14px 12px; display: flex; flex-direction: column}
.fg-side h3 { margin: 0 4px 8px; display: flex; align-items: baseline; justify-content: space-between; gap: 8px; font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: #a1a1a6}
.fg-side h3 small { font-size: 12px; font-weight: 500; letter-spacing: 0; text-transform: none; color: #8e8e93}
.fg-sl { overflow: auto; min-height: 0}
.fg-pbottom { position: absolute; inset-inline: 16px; bottom: 16px; z-index: 8; display: flex; align-items: center; gap: 12px}
.fg-pbottom .sp { flex: 1}
.fg-say { flex: 1; min-width: 0; display: flex; align-items: center; gap: 12px; padding: 12px 16px; min-height: 74px; font-size: 14px; line-height: 1.4; color: #e5e5ea}
.fg-say .mface { width: 40px; height: 40px; flex: none}
.fg-say #st-msg { max-height: 60px; overflow: auto}
.fg-tools { flex: none; display: flex; gap: 6px; padding: 8px; align-self: stretch; align-items: center}
.fg-tools .mx-tool { width: auto; height: 56px; padding: 0 12px; display: flex; flex-direction: row; align-items: center; gap: 8px; border-radius: 12px; font-size: 13px; color: #fff; background: rgba(255, 255, 255, 0.06); border: 1px solid rgba(255, 255, 255, 0.08)}
.fg-tools .mx-tool span { display: grid; place-items: center}
.fg-tools .mx-tool.on { border-color: #00FF6F}
.fg.page .mx-scene.fg-scene.dim::after { background: rgba(8, 8, 8, 0.45)}
.fg-confetti { position: absolute; inset: 0; z-index: 20; pointer-events: none; overflow: hidden}
.fg-confetti i { position: absolute; top: -20px; width: 10px; height: 16px; border-radius: 2px; animation: fg-fall 2.4s cubic-bezier(.3, .6, .5, 1) forwards}
@keyframes fg-fall { 0% { transform: translateY(0) rotate(0); opacity: 1} 100% { transform: translateY(1150px) rotate(540deg); opacity: 0}}
@media (prefers-reduced-motion: reduce) { .fg-confetti { display: none}}
.fg .g2d-sel { display: none}

/* the light theme: the same HUD on white glass, ink text (green stays for what is picked or passing) */
[data-theme="light"] .fg { color: #1d1d1f}
[data-theme="light"] .fg-glass, [data-theme="light"] .fg-ib, [data-theme="light"] .fg-me, [data-theme="light"] .fg-ttl, [data-theme="light"] .fg-steps, [data-theme="light"] .fg-hb { background: rgba(255, 255, 255, 0.94); border-color: rgba(0, 0, 0, 0.09); color: #1d1d1f}
[data-theme="light"] .fg.page .fg-page > .mx-panel, [data-theme="light"] .fg.page .fg-page > .mx-info, [data-theme="light"] .fg.page .fg-page > .mx-out, [data-theme="light"] .fg.page .fg-page > section, [data-theme="light"] .fg.page .fg-page > div { background: rgba(255, 255, 255, 0.95); border-color: rgba(0, 0, 0, 0.09)}
[data-theme="light"] .fg-ttl small, [data-theme="light"] .fg-note, [data-theme="light"] .fg-lab, [data-theme="light"] .fg-coins small, [data-theme="light"] .fg-ctx small, [data-theme="light"] .fg-side h3, [data-theme="light"] .fg-side h3 small { color: #6e6e73}
[data-theme="light"] .fg-steps button { color: #3a3a3c; background: rgba(0, 0, 0, 0.04); border-color: rgba(0, 0, 0, 0.12)}
[data-theme="light"] .fg-steps button.lock { color: #6e6e73}
[data-theme="light"] .fg-steps button.now { color: #1d1d1f; background: rgba(0, 255, 111, 0.18)}
[data-theme="light"] .fg-steps button.done { color: #0a0a0b}
[data-theme="light"] .fg-chip { color: #1d1d1f; background: rgba(0, 0, 0, 0.06)}
[data-theme="light"] .fg-chip.ok { color: #0a0a0b; background: #00FF6F}
[data-theme="light"] .fg-chip.no { color: #fff; background: #C2185B}
[data-theme="light"] .fg-slot, [data-theme="light"] .fg-set, [data-theme="light"] .fg-tools .mx-tool { color: #1d1d1f; background: rgba(0, 0, 0, 0.035); border-color: rgba(0, 0, 0, 0.09)}
[data-theme="light"] .fg-slot.on { background: rgba(0, 255, 111, 0.16); border-color: #00c957}
[data-theme="light"] .fg-slot kbd { color: #3a3a3c; background: rgba(0, 0, 0, 0.07)}
[data-theme="light"] .fg-price { color: #7a5c00}
[data-theme="light"] .fg-slot.dear .fg-price, [data-theme="light"] .fg-coins.over b { color: #C2185B}
[data-theme="light"] .fg-th, [data-theme="light"] .fg-slot.fg-gear .fg-th { color: #3a3a3c}
[data-theme="light"] .fg-chipb, [data-theme="light"] .fg-cb, [data-theme="light"] .fg-size button { color: #1d1d1f; background: rgba(0, 0, 0, 0.05); border-color: rgba(0, 0, 0, 0.1)}
[data-theme="light"] .fg-cb.del { color: #C2185B}
[data-theme="light"] .fg-size { background: rgba(0, 0, 0, 0.04)}
[data-theme="light"] .fg-start p, [data-theme="light"] .fg-result p, [data-theme="light"] .fg-pl, [data-theme="light"] .fg-say, [data-theme="light"] .fg-hint, [data-theme="light"] .fg-pred, [data-theme="light"] .fg-set i { color: #3a3a3c}
[data-theme="light"] .fg-idea, [data-theme="light"] .fg-pl b { color: #1d1d1f !important}
[data-theme="light"] .fg-pred.warn { color: #7a5c00}
[data-theme="light"] .fg-cbar, [data-theme="light"] .fg-pbar { background: rgba(0, 0, 0, 0.08)}
[data-theme="light"] .fg-div { background: rgba(0, 0, 0, 0.1)}
/* the films and tutorials, from one button in the top bar */
.fg-tutpop { display: grid; gap: 6px; margin-top: 8px}
.fg-tutpop button { display: flex; align-items: center; gap: 10px; height: 44px; padding: 0 12px; border-radius: 10px; font-size: 14px; font-weight: 600; text-align: start}
/* the minimap keeps its own box, under its title */
.fg-mapin { position: relative; height: 196px}
.fg-mapin .g2d { position: absolute; inset: 0; width: 100%; height: 100%}
.fg-mapin svg { width: 100%; height: 100%}

/* V6G-09: the mission's own header (80 px) and footer (80 px) are back; the game sits between them */
.fg-quest { top: 92px; padding: 14px 14px 12px; max-height: 660px; display: flex; flex-direction: column}
.fg-mini { top: 92px}
.fg-mini .fg-mapin { height: 176px}
.fg-hint { bottom: 262px}
.fg-bottom { bottom: 92px; align-items: stretch}
.fg-tbottom { bottom: 92px}
.fg-details { top: 92px; max-height: 600px}
.fg-topwrap { inset: 92px 332px 268px 332px}
.fg.page .fg-page { top: 92px; bottom: 172px}
.fg-side { top: 92px; max-height: 560px}
.fg-pbottom { bottom: 92px}
/* the seven steps, by name */
.fg-stl { margin-top: 14px}
.fg-sts { display: grid; gap: 3px; margin-top: 6px}
.fg-st { display: flex; align-items: center; gap: 9px; min-height: 34px; padding: 4px 8px; border-radius: 10px; font-size: 13.5px; color: #e5e5ea; text-align: start; border: 1px solid transparent}
.fg-st i { width: 22px; height: 22px; flex: none; border-radius: 50%; display: grid; place-items: center; font: normal 700 11.5px/1 inherit; color: #c7c7cc; background: rgba(255, 255, 255, 0.08)}
.fg-st span { flex: 1; min-width: 0}
.fg-st em { font-style: normal; font-size: 11px; font-weight: 700; color: #0a0a0b; background: #00FF6F; border-radius: 999px; padding: 2px 7px}
.fg-st.now { border-color: rgba(0, 255, 111, 0.55); background: rgba(0, 255, 111, 0.08); color: #fff; font-weight: 600}
.fg-st.done i { color: #0a0a0b; background: #00FF6F}
.fg-st.lock { color: #8e8e93}
.fg-st:disabled { cursor: not-allowed; opacity: 1 }
.f6 .mx-go:disabled { cursor: not-allowed; opacity: .45; animation: none }
.fg-askb { margin-top: 10px; display: flex; align-items: center; justify-content: center; gap: 8px; height: 42px; border-radius: 12px; font-size: 14px; font-weight: 600; color: #fff; background: rgba(255, 255, 255, 0.07); border: 1px solid rgba(255, 255, 255, 0.1)}
.fg-askb .mface { width: 24px; height: 24px}
/* the budget card */
.fg-coins { width: 220px; flex-direction: column; align-items: stretch; gap: 4px; padding: 14px}
.fg-coins b { font-size: 17px; margin-top: 2px}
.fg-coins .fg-cbar { margin-top: 4px}
.fg-coins small.tnum { margin-top: 0}
.fg-link { margin-top: auto; display: inline-flex; align-items: center; gap: 6px; font-size: 12.5px; font-weight: 600; color: #e5e5ea; text-align: start; padding-top: 6px}
.fg-bt { display: grid; gap: 4px; margin: 10px 0 6px}
.fg-brow { display: flex; justify-content: space-between; gap: 12px; font-size: 13px}
.fg-brow.sum { border-top: 1px solid rgba(127, 127, 127, 0.3); padding-top: 4px; font-weight: 700}
.fg-fx { font-size: 12px; opacity: .85}
/* the hotbar: parts, then the farm settings, all by name */
.fg-slot { width: 84px; height: 148px}
.fg-th { width: 62px; height: 62px}
.fg-price { font-size: 12px}
.fg-sets { flex: none; width: 300px}
.fg-sets > div { display: grid; grid-template-columns: 1fr 1fr; gap: 6px}
.fg-set { height: 40px; padding: 0 8px; font-size: 12px; justify-content: flex-start}
.fg-set b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0}
.fg-set i { margin-inline-start: auto; flex: none}
[data-theme="light"] .fg-st { color: #1d1d1f}
[data-theme="light"] .fg-st i { color: #3a3a3c; background: rgba(0, 0, 0, 0.06)}
[data-theme="light"] .fg-st.now { color: #1d1d1f; background: rgba(0, 255, 111, 0.12)}
[data-theme="light"] .fg-st.lock { color: #6e6e73}
[data-theme="light"] .fg-askb, [data-theme="light"] .fg-link { color: #1d1d1f; background: rgba(0, 0, 0, 0.04); border-color: rgba(0, 0, 0, 0.1)}
[data-theme="light"] .fg-link { background: none}
.fg-slot.full .fg-price { color: #00FF6F}
[data-theme="light"] .fg-slot.full .fg-price { color: #1d1d1f}
/* the farm's footer holds one more button (Tutorials beside Mission intro): the main button and the rewards make room */
.fg .mx-foot .mx-go { min-width: 220px; padding: 0 22px}
.fg .mx-foot .mx-rw { gap: 16px; padding-inline-start: 16px}

/* V6G-14: how close the farm is to solving the mission, and hints for every step (js/farm-help.js) */
.fh-meter { display: inline-flex; gap: 3px; align-items: center}
.fh-meter i { width: 14px; height: 5px; border-radius: 3px; background: rgba(255, 255, 255, 0.16)}
.mx-pill.fh-pill { display: inline-flex; align-items: center; gap: 7px; width: auto; padding: 0 10px; background: none; white-space: nowrap}
.fh-pill .fh-meter i { width: 9px; height: 4px}
.fh-pill.untested { border-color: #3a3a3c; color: #c7c7cc}
.fh-pill.far, .fh-close.far b { color: #FF9F5A} .fh-pill.far { border-color: rgba(255, 127, 36, 0.55)}
.fh-pill.closer, .fh-close.closer b { color: #FFD15C} .fh-pill.closer { border-color: rgba(255, 197, 61, 0.55)}
.fh-pill.almost, .fh-pill.solved, .fh-close.almost b, .fh-close.solved b { color: var(--accent)} .fh-pill.almost, .fh-pill.solved { border-color: var(--accent-line)}
.far .fh-meter i.on { background: #FF7F24} .closer .fh-meter i.on { background: #FFC53D} .almost .fh-meter i.on, .solved .fh-meter i.on { background: var(--accent)}
.fh-close { margin-top: 10px; padding: 10px 12px; border-radius: 12px; border: 1px solid rgba(255, 255, 255, 0.1); display: flex; flex-direction: column; gap: 4px}
.fh-ch { display: flex; align-items: center; justify-content: space-between; gap: 10px}
.fh-ch b { font-size: 15px; font-weight: 700; color: #f5f5f7}
.fh-close .fh-meter i { width: 16px; height: 6px}
.fh-sub { font-size: 12px; color: #a1a1a6; line-height: 1.35}
.fg-helpr { display: flex; gap: 8px; margin-top: 10px}
.fg-helpr .fg-askb { flex: 1; margin-top: 0}
.fg-hintb { height: 42px; padding: 0 14px; display: inline-flex; align-items: center; gap: 6px; border-radius: 12px; font-size: 14px; font-weight: 600; color: var(--accent); background: none; border: 1px solid var(--accent-line); cursor: pointer}
.fg-hintb em { font-style: normal; font-size: 11.5px; color: #a1a1a6; font-weight: 600}
.fg-hintb[aria-expanded="true"], .fg-hintb:hover { border-color: var(--accent)}
.pop.fh-popw { padding: 0}
.fh-pop { padding: 14px 16px; display: flex; flex-direction: column; gap: 10px}
.fh-ph { display: flex; align-items: center; justify-content: space-between; gap: 10px}
.fh-ph b { font-size: 14.5px}
.fh-dots { display: inline-flex; gap: 4px} .fh-dots i { width: 7px; height: 7px; border-radius: 50%; background: rgba(255, 255, 255, 0.18)} .fh-dots i.on { background: var(--accent)}
.fh-h { padding: 10px 12px; border-radius: 12px; border: 1px solid rgba(255, 255, 255, 0.1)}
.fh-h small { display: inline-flex; align-items: center; gap: 6px; font-size: 11.5px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: var(--accent)}
.fh-h p { margin: 5px 0 0; font-size: 14px; line-height: 1.45}
.fh-more, .fh-ask { height: 40px; justify-content: center}
.fh-all { margin: 0; font-size: 13px; color: #c7c7cc}
.fh-note { margin: 0; display: flex; gap: 6px; align-items: flex-start; font-size: 11.5px; line-height: 1.4; color: #8e8e93}
[data-theme="light"] .fh-meter i, [data-theme="light"] .fh-dots i { background: rgba(0, 0, 0, 0.12)}
[data-theme="light"] .fh-close, [data-theme="light"] .fh-h { border-color: rgba(0, 0, 0, 0.1)}
[data-theme="light"] .fh-ch b { color: #1d1d1f} [data-theme="light"] .fh-sub, [data-theme="light"] .fg-hintb em { color: #6e6e73}
[data-theme="light"] .fh-pill.far, [data-theme="light"] .fh-close.far b { color: #C2410C} [data-theme="light"] .fh-pill.closer, [data-theme="light"] .fh-close.closer b { color: #A16207}
[data-theme="light"] .fh-pill.untested { border-color: #dbdbdc; color: #46464d}
[data-theme="light"] .fg-hintb, [data-theme="light"] .fh-h small { color: #1d1d1f} [data-theme="light"] .fg-hintb .ico, [data-theme="light"] .fh-h small .ico { color: var(--accent)}
[data-theme="light"] .fh-all { color: #46464d} [data-theme="light"] .fh-note { color: #6e6e73}
/* the same status on the Missions tile and the Home mission card */
.badge.fh-tag.far { color: #FF9F5A} .badge.fh-tag.closer { color: #FFD15C} .badge.fh-tag.almost, .badge.fh-tag.solved { color: var(--accent)}
.fh-home { margin-inline-start: 10px; font-weight: 600} .fh-home.far { color: #FF9F5A} .fh-home.closer { color: #FFD15C} .fh-home.almost, .fh-home.solved { color: var(--accent)}
[data-theme="light"] .badge.fh-tag.far, [data-theme="light"] .fh-home.far { color: #C2410C} [data-theme="light"] .badge.fh-tag.closer, [data-theme="light"] .fh-home.closer { color: #A16207}

/* V6G-18: the goal card and the map, one column at the left; Hint and Ask the mentor at the top right */
.fg-lcol { position: absolute; inset-inline-start: 16px; top: 92px; width: 300px; z-index: 6; display: flex; flex-direction: column; gap: 10px}
.fg-lcol > .fg-quest, .fg-lcol > .fg-mini { position: relative; inset: auto; top: auto; width: 300px}
.fg-lcol > .fg-quest { max-height: 560px}
.fg-lcol > .fg-mini { padding: 8px 10px 10px}
.fg-lcol > .fg-mini .fg-mh { padding: 0 2px 6px}
.fg-lcol > .fg-mini .fg-mapin { height: 128px}
.fg-lcol > .fg-mini.plan { width: auto; align-self: flex-start}
.fg-help { position: absolute; inset-inline-end: 16px; top: 92px; width: 300px; z-index: 6; padding: 10px; display: flex; gap: 8px}
.fg-help .fg-askb { flex: 1; margin-top: 0}
.fg.page .fg-side { top: 160px; max-height: 500px}

/* Keep on-demand help compact beside the active task. */
.fg-help { width: auto; padding: 0; border: 0; background: transparent; backdrop-filter: none }
