/* Карточки-расследования (investigate, блок 7 урока 2). Подключается рядом с css/media.css там,
   где рисуются шаги ученика (index.html). Картинки в квадратных рамках фиксированной пропорции:
   перерисовка шага не прыгает по высоте, пока картинка берётся из кэша. */
.inv-progress { margin: 12px 4px; font-weight: 700; color: #4a5270; }
.inv-closed { display: flex; flex-wrap: wrap; gap: 6px; margin: 0 0 10px; }
.inv-closed span { background: #eef2ff; color: #3450d2; border-radius: 10px; padding: 4px 10px;
  font-size: 14px; font-weight: 600; }
.inv-case { background: #fff; border-radius: 18px; padding: 14px; box-shadow: 0 2px 8px rgba(28,35,64,.08); }
.inv-head { font-size: 18px; font-weight: 800; margin-bottom: 10px; }
.inv-groups { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.inv-group { border: 3px solid #e3e8f7; border-radius: 14px; padding: 6px; }
.inv-group-label { font-weight: 800; color: #3450d2; margin-bottom: 4px; }
.inv-thumbs { display: grid; grid-template-columns: repeat(3, 1fr); gap: 5px; }
.inv-thumb { padding: 0; border: 0; background: #f2f4fb; border-radius: 10px; overflow: hidden;
  aspect-ratio: 1 / 1; cursor: zoom-in; }
.inv-thumb img, .inv-new img { width: 100%; height: 100%; object-fit: cover; display: block; }
.inv-new-label { margin: 10px 0 6px; font-weight: 700; }
/* 220 px, не 320: картинки дела и три плашки должны сойтись в один экран 900×1000 без прокрутки
   (плюс док плашек снизу закреплён — вместе решают «промотайте экран» с прогона 13.09) */
.inv-new { width: min(100%, 220px); aspect-ratio: 1 / 1; margin: 0 auto; border-radius: 14px; overflow: hidden;
  background: #f2f4fb; border: 4px solid #f5a623; cursor: zoom-in; }
.inv-new.loading { background: linear-gradient(90deg, #eef1fa, #f8f9fd, #eef1fa); background-size: 200% 100%;
  animation: inv-shimmer 1.2s linear infinite; }
@keyframes inv-shimmer { from { background-position: 200% 0; } to { background-position: 0 0; } }
.inv-img-error { width: 100%; height: 100%; background: #fff4f0; color: #c0392b; font-size: 17px;
  font-weight: 700; padding: 16px; }
/* низ экрана закреплён (900×1000 без прокрутки — прогон 13.09 просил «промотать вниз»): плашки,
   собранная фраза и ответ в деле всегда под рукой, скроллятся только картинки дела над доком. */
.inv-dock { position: sticky; bottom: 0; z-index: 5; margin: 14px -6px 0; padding: 8px 6px 10px;
  background: rgba(240,244,255,.96); border-radius: 18px 18px 0 0; box-shadow: 0 -4px 14px rgba(28,35,64,.08);
  max-height: 62vh; overflow-y: auto; }
.inv-slots { display: flex; flex-direction: column; gap: 10px; }
.inv-slots.waiting { opacity: .5; }
.inv-slot { background: #fff; border-radius: 16px; padding: 12px; }
.inv-slot-title { font-weight: 800; margin-bottom: 6px; }
.inv-options { display: flex; flex-direction: column; gap: 6px; }
.inv-opt { text-align: left; background: #fff; border: 3px solid #dfe5f5; border-radius: 12px; padding: 10px 14px;
  font-size: 16px; font-weight: 500; color: #3a4160; }
.inv-opt.picked { border-color: #27ae60; background: #f0fbf4; }
.inv-opt.sending { border-color: #f5a623; background: #fff8ec; }
.inv-opt:disabled { cursor: default; }
.inv-ready, .inv-next { margin-top: 12px; }
.inv-confirm, .inv-reveal, .inv-explains { background: #fff; border-radius: 18px; padding: 18px; }
.inv-explains { margin-top: 16px; }
.inv-confirm-head { font-weight: 800; font-size: 18px; margin-bottom: 8px; }
.inv-phrase { margin: 8px 0; font-size: 18px; }
.inv-phrase-title { color: #7a839f; }
.inv-buttons { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 14px; }
.inv-buttons .btn-big { flex: 1 1 160px; width: auto; }
.inv-buttons .btn-big:disabled { opacity: .5; cursor: default; }
.inv-answer { margin-top: 14px; font-size: 24px; font-weight: 800; color: #3450d2; text-align: center; }
.inv-explains h3 { margin-top: 0; }
/* ниже оверлея замка (30): «Стоп» закрывает и увеличенную картинку */
.inv-zoom { position: fixed; inset: 0; z-index: 28; background: rgba(20,24,40,.85); display: flex;
  align-items: center; justify-content: center; padding: 16px; cursor: zoom-out; }
.inv-zoom img { max-width: 100%; max-height: 100%; border-radius: 14px; }
@media (max-width: 480px) {
  .inv-groups { grid-template-columns: 1fr; }
  .inv-new { width: 100%; }
}
