/* BioglowRX — Food Test Lab styles (engine/lab-food-test.js) */
.ft-run { grid-template-columns: minmax(0, 1.25fr) minmax(260px, 1fr); align-items: start; }
.ft-scenewrap { padding: 4px; }
.ft-scene { max-width: 100%; touch-action: none; user-select: none; -webkit-user-select: none; }
.ft-scene .ft-hit, .ft-scene [data-drop] { cursor: pointer; }
.ft-steam path { fill: none; stroke: #b9c6d2; stroke-width: 2; stroke-linecap: round; opacity: .0; animation: ft-steam 2.6s ease-in-out infinite; }
.ft-steam path:nth-child(2) { animation-delay: .9s; } .ft-steam path:nth-child(3) { animation-delay: 1.7s; }
@keyframes ft-steam { 0% { opacity: 0; transform: translateY(6px); } 40% { opacity: .7; } 100% { opacity: 0; transform: translateY(-8px); } }
@media (prefers-reduced-motion: reduce) { .ft-steam path { animation: none; opacity: .4; } }

.ft-side { display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.ft-tip { min-height: 3.2em; color: var(--ink); }
.ft-tip .ft-sub { color: var(--muted); font-size: 13px; }
.ft-warn { display: inline-grid; place-items: center; width: 18px; height: 18px; border-radius: 50%; background: var(--streak-hot); color: #fff !important; font-size: 12px; margin-right: 2px; }

.ft-bar { border: 1px solid var(--line); border-radius: var(--radius-inner); background: var(--bg); padding: 10px 12px; min-height: 64px; }
.ft-what { margin: 0; font-size: 14px; line-height: 1.45; color: var(--ink); }
.ft-what.is-idle { color: var(--muted); }
.ft-what small { color: var(--muted); }
.ft-dropn { font: 800 18px var(--font-mono); }
.ft-btns { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 8px; }
.ft-btns .lab-btn { min-width: 0; padding: 11px 14px; font-size: 15px; min-height: 44px; }
.ft-btns .lab-btn.is-pour { flex: 1 1 160px; max-width: none; }
.ft-btns .lab-btn.is-rec { border-color: var(--accent); color: var(--accent); }
.ft-small { padding: 10px 16px; font-size: 14px; min-height: 44px; }
.ft-opts { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 8px; }
.ft-opt { display: flex; align-items: center; gap: 8px; min-height: 48px; padding: 8px 10px; border-radius: var(--radius-inner); border: 2px solid var(--line); background: var(--surface); font-weight: 700; font-size: 14px; text-align: left; color: var(--ink); }
.ft-opt:hover { border-color: var(--accent); }
.ft-opt .ft-sw { width: 22px; height: 22px; flex: none; margin: 0; }

.ft-sw { display: inline-block; width: 14px; height: 14px; border-radius: 50%; vertical-align: -2px; margin-right: 5px; border: 1px solid rgba(0,0,0,.2); }
.ft-sw.is-clear { background: linear-gradient(135deg, #f4f9fc, #dbe9f2) !important; }
.ft-sw.is-cloud { background: radial-gradient(circle at 35% 35%, #fff, #e9e9e2) !important; box-shadow: inset 0 0 0 3px rgba(255,255,255,.7); }
.ft-grad { display: inline-block; width: 34px; height: 10px; border-radius: 5px; vertical-align: 0; margin-right: 5px; background: linear-gradient(90deg, #5FA63E, #D9C232, #E58A2B, #B0432B); }

.ft-shelf .br-label { margin: 0 0 6px; }
.ft-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.ft-chip { display: flex; align-items: center; gap: 6px; min-height: 48px; padding: 4px 10px 4px 4px; border-radius: 14px; border: 2px solid var(--line); background: var(--surface); color: var(--ink); text-align: left; touch-action: none; user-select: none; -webkit-user-select: none; -webkit-touch-callout: none; cursor: grab; transition: transform .1s, border-color .12s, box-shadow .2s; }
.ft-chip svg { width: 36px; height: 36px; flex: none; }
.ft-chip span { display: flex; flex-direction: column; line-height: 1.15; }
.ft-chip b { font-size: 14px; }
.ft-chip small { font: 400 11px var(--font-mono); color: var(--muted); }
.ft-chip:active:not(:disabled) { transform: scale(.97); }
.ft-chip.is-held { border-color: var(--accent); background: color-mix(in srgb, var(--accent) 12%, var(--surface)); }
.ft-chip:disabled { opacity: .5; cursor: default; }
.ft-glow { animation: ft-glow 1.1s ease-in-out infinite; border-color: var(--accent) !important; }
@keyframes ft-glow { 0%, 100% { box-shadow: 0 0 0 0 color-mix(in srgb, var(--accent) 55%, transparent); } 50% { box-shadow: 0 0 0 6px color-mix(in srgb, var(--accent) 0%, transparent); } }
@media (prefers-reduced-motion: reduce) { .ft-glow { animation: none; box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 45%, transparent); } }
.ft-ghost { position: fixed; z-index: 70; width: 48px; height: 48px; margin: -40px 0 0 -24px; pointer-events: none; filter: drop-shadow(0 6px 10px rgba(0,0,0,.25)); }
.ft-ghost svg { width: 100%; height: 100%; }

.ft-results { margin-top: 16px; }
.ft-tablewrap { overflow-x: auto; }
.ft-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.ft-table th, .ft-table td { border: 1px solid var(--line); padding: 6px 5px; text-align: center; vertical-align: middle; }
.ft-table thead th { font-size: 12px; background: var(--bg); }
.ft-table th small, .ft-table td small { display: block; font: 400 10px var(--font-mono); color: var(--muted); }
.ft-table tbody th { text-align: left; font-size: 13px; }
.ft-table td span { font-weight: 700; font-size: 12px; }
.ft-table td .ft-sw { display: block; margin: 0 auto 3px; width: 18px; height: 18px; }
.ft-table td.is-empty { color: var(--muted); }
.ft-table td.is-new { animation: ft-cell .8s ease-out; }
@keyframes ft-cell { 0% { background: color-mix(in srgb, var(--good) 35%, transparent); } 100% { background: transparent; } }
.ft-note { width: 100%; text-align: center; font-size: 13px; color: var(--muted); margin: 6px 0 0; }
#ft-conclude:disabled { opacity: .5; }

.ft-concl { margin: 16px auto 0; max-width: 620px; padding: 14px; border: 2px solid var(--accent); border-radius: var(--radius-inner); background: var(--bg); }
.ft-concl p { margin: 0 0 8px; font-size: 15px; line-height: 1.45; }
.ft-togs, .ft-mcq { display: flex; flex-wrap: wrap; gap: 8px; }
.ft-tog { min-height: 46px; padding: 10px 14px; border-radius: var(--radius-inner); border: 2px solid var(--line); background: var(--surface); font-weight: 700; font-size: 15px; color: var(--ink); }
.ft-tog.is-wide { flex: 1 1 100%; text-align: left; font-weight: 600; font-size: 14px; }
.ft-tog[aria-pressed="true"] { border-color: var(--accent); background: color-mix(in srgb, var(--accent) 14%, var(--surface)); }
.ft-tog[aria-pressed="true"]:not(.is-wide):not([data-rk])::before { content: "✓ "; color: var(--accent); }
.ft-rn { font-family: var(--font-mono); color: var(--accent); margin-right: 4px; }
.ft-tog:disabled { cursor: default; }

.ft-why { text-align: left; max-width: 56ch; margin: 10px auto 0; padding-left: 20px; font-size: 14px; line-height: 1.5; color: var(--ink); }
.ft-why li { margin-bottom: 4px; }
.ft-fig { max-width: 380px; }

.ft-refwrap { overflow-x: auto; margin: 4px 0 10px; }
.ft-ref { width: 100%; border-collapse: collapse; font-size: 13px; }
.ft-ref th, .ft-ref td { border-bottom: 1px solid var(--line); padding: 6px 4px; text-align: left; vertical-align: top; }
.ft-ref th { font: 600 11px var(--font-mono); text-transform: uppercase; letter-spacing: .05em; color: var(--muted); }
.ft-ref small { display: block; color: var(--muted); font-size: 11px; }

@media (max-width: 700px) {
  .ft-run { grid-template-columns: 1fr; gap: 10px; }
  .ft-side .ft-tip { min-height: 2.8em; }
  .ft-chips { display: grid; grid-template-columns: 1fr 1fr; }
  .ft-chip { padding-right: 6px; min-width: 0; }
  .ft-chip span { min-width: 0; }
  .ft-chip svg { width: 32px; height: 32px; }
  .ft-chip b { font-size: 13px; }
  .ft-opts { grid-template-columns: 1fr 1fr; }
  .ft-table { font-size: 12px; }
  .ft-table th, .ft-table td { padding: 5px 3px; }
}
#ft-submit, #ft-conclude { min-height: 46px; }
