/* ==========================================================================
 * ElAshkef HOTFIX 2026-05-13 — V2 styles
 * --------------------------------------------------------------------------
 * Companion to hotfix-2026-05-13-bugs-v2.js
 * ========================================================================== */

/* --------------------------------------------------------------------------
 * (B) Suppress Laeib's second tutorial popup. The JS also re-routes
 * showGameInfo, but this is a belt-and-braces guarantee — if another
 * script tries to spawn #game-info-popup while a unified tutorial is
 * already visible, hide it.
 * -------------------------------------------------------------------------- */
.utut-overlay ~ #game-info-popup,
#game-tutorial-overlay ~ #game-info-popup {
  display: none !important;
}

/* When user is on laeib, #game-info-popup should NEVER appear — the
 * unified tutorial is the single source of truth.
 * Body-data hook is set by major-upgrade-2026-05-13.js via _currentGameId.
 * We can't read JS state from CSS, so the JS handles this; here we just
 * make sure if it ever appears WITHOUT a tutorial, it's not styled away. */

/* --------------------------------------------------------------------------
 * (D) Draw-guess: category picker bar
 * -------------------------------------------------------------------------- */
.draw-cat-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  margin: 0 0 10px 0;
  background: rgba(232, 183, 48, 0.04);
  border: 1px solid rgba(232, 183, 48, 0.18);
  border-radius: 12px;
}

.draw-cat-bar .draw-cat-label {
  font-weight: 700;
  color: #E8B730;
  margin-inline-end: 4px;
  font-size: 0.92rem;
}

.draw-cat-bar .draw-cat-btn {
  appearance: none;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.04);
  color: rgba(255, 255, 255, 0.86);
  padding: 6px 12px;
  border-radius: 999px;
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s ease;
}
.draw-cat-bar .draw-cat-btn:hover {
  background: rgba(232, 183, 48, 0.12);
  border-color: rgba(232, 183, 48, 0.4);
  color: #fff;
}
.draw-cat-bar .draw-cat-btn.is-active {
  background: linear-gradient(135deg, #E8B730, #F5D261);
  color: #111;
  border-color: #E8B730;
  box-shadow: 0 4px 12px rgba(232, 183, 48, 0.3);
}

.draw-cat-bar .draw-cat-help {
  margin-inline-start: auto;
  appearance: none;
  background: rgba(168, 85, 247, 0.12);
  border: 1px solid rgba(168, 85, 247, 0.4);
  color: #C4B5FD;
  padding: 6px 14px;
  border-radius: 999px;
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.draw-cat-bar .draw-cat-help:hover {
  background: rgba(168, 85, 247, 0.22);
  color: #fff;
}

@media (max-width: 640px) {
  .draw-cat-bar {
    gap: 6px;
    padding: 8px 10px;
  }
  .draw-cat-bar .draw-cat-btn {
    padding: 5px 10px;
    font-size: 0.82rem;
  }
  .draw-cat-bar .draw-cat-help {
    margin-inline-start: 0;
    width: 100%;
    justify-content: center;
    margin-top: 6px;
  }
}

/* --------------------------------------------------------------------------
 * (E) Hide-modes tutorial — uses .utut-* base classes (defined in
 * hotfix-2026-05-13-bugs.css). Only add extra spacing for the tips.
 * -------------------------------------------------------------------------- */
.utut-overlay .utut-step {
  display: flex;
  gap: 14px;
  margin-bottom: 16px;
  padding: 12px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 10px;
}
.utut-overlay .utut-step-num {
  flex-shrink: 0;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: linear-gradient(135deg, #E8B730, #F5D261);
  color: #111;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.95rem;
}
.utut-overlay .utut-step-content { flex: 1; }
.utut-overlay .utut-step-title {
  font-weight: 700;
  color: #E8B730;
  margin-bottom: 6px;
  font-size: 0.98rem;
}
.utut-overlay .utut-step-title i { margin-inline-end: 6px; }
.utut-overlay .utut-step-text {
  color: rgba(255, 255, 255, 0.82);
  font-size: 0.92rem;
  line-height: 1.6;
}
.utut-overlay .utut-step-text b {
  color: #F5D261;
  font-weight: 700;
}
.utut-overlay .utut-tip {
  margin-top: 14px;
  padding: 10px 14px;
  background: rgba(34, 197, 94, 0.08);
  border: 1px solid rgba(34, 197, 94, 0.3);
  border-radius: 10px;
  color: #86EFAC;
  font-size: 0.9rem;
  line-height: 1.5;
}
.utut-overlay .utut-tip i { margin-inline-end: 6px; color: #FBBF24; }

/* --------------------------------------------------------------------------
 * Draw-guess hide-modes FAB
 * -------------------------------------------------------------------------- */
.draw-hidemodes-fab {
  position: fixed;
  bottom: 22px;
  inset-inline-end: 22px;
  width: 54px;
  height: 54px;
  border-radius: 50%;
  background: linear-gradient(135deg, #A855F7, #7E22CE);
  color: #fff;
  border: none;
  font-size: 1.4rem;
  box-shadow: 0 6px 20px rgba(168, 85, 247, 0.5);
  cursor: pointer;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
}
.draw-hidemodes-fab:hover {
  transform: scale(1.08);
  box-shadow: 0 8px 26px rgba(168, 85, 247, 0.7);
}

/* --------------------------------------------------------------------------
 * (F) HERO mobile image — last-line CSS overrides
 * The JS forces inline styles with !important, but we add CSS as a fallback
 * in case JS is delayed (e.g. flaky network on first paint).
 * -------------------------------------------------------------------------- */
@media (max-width: 768px) {
  #hero-char-img,
  .hero-character-img {
    position: absolute !important;
    top: 50% !important;
    left: 50% !important;
    /* Specificity boost: this rule must beat the inline `transform`
       built by app.js. JS layer is the actual fix; this is fallback. */
    /* transform overridden by JS via setProperty('transform', '...', 'important')
       which beats this CSS rule. */
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    max-width: 100% !important;
    max-height: 100% !important;
    object-fit: contain !important;
  }
}

/* Sizing only — JS handles the transform centering. */
@media (max-width: 768px) and (min-width: 481px) {
  #hero-char-img,
  .hero-character-img {
    width: 200px !important;
    height: 200px !important;
  }
}
@media (max-width: 480px) and (min-width: 361px) {
  #hero-char-img,
  .hero-character-img {
    width: 170px !important;
    height: 170px !important;
  }
}
@media (max-width: 360px) {
  #hero-char-img,
  .hero-character-img {
    width: 140px !important;
    height: 140px !important;
  }
}
