/* ─────────────────────────────────────────────────────────────────
   css/builder-bulk-lock.css

   Styles for two adoption-moat features:
     1. Lock-board   (board-lock.js)   — .board-locked class, 🔒 pill
     2. Bulk edit    (bulk-edit.js)    — .bulk-mode + .bulk-selected,
                                        floating action bar

   Lives in its own file because css/builder.css was at 989 / 1000
   when these features shipped. Keeping each surface its own file
   keeps every CSS bundle GREEN.

   LABEL: PRODUCTION-READY.
───────────────────────────────────────────────────────────────── */

/* ── Lock state ────────────────────────────────────────────────── */
.board-locked .tile-delete { display: none !important; }
.board-locked .tile {
  cursor: not-allowed;
  opacity: 0.92;
  border-style: dashed;
}
.board-locked .add-tile-btn {
  opacity: 0.4;
  pointer-events: none;
}
.topbar-lock-btn[aria-pressed="true"] {
  background: #FFE6E6;
  color: #A22A2A;
  border-color: #E8B8B8;
}

/* ── Bulk-mode grid ────────────────────────────────────────────── */
body.bulk-mode-on { padding-bottom: 80px; }       /* room for action bar */
.tile-grid.bulk-mode .tile-delete { display: none !important; }
.tile-grid.bulk-mode .tile {
  cursor: pointer;
}
.tile-grid.bulk-mode .tile:not(.bulk-selected) {
  opacity: 0.55;
}
.tile-grid.bulk-mode .tile.bulk-selected {
  outline: 3px solid var(--amber, #E8A838);
  box-shadow: 0 0 0 2px rgba(232, 168, 56, 0.35), 0 6px 18px rgba(0, 0, 0, 0.12);
  position: relative;
  opacity: 1;
}
.tile-grid.bulk-mode .tile.bulk-selected::after {
  content: '✓';
  position: absolute;
  top: 6px; right: 6px;
  background: var(--amber, #E8A838);
  color: #fff;
  font-size: 0.85rem;
  font-weight: 700;
  width: 22px; height: 22px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.18);
}
.topbar-bulk-btn.active {
  background: var(--amber, #E8A838);
  color: #fff;
  border-color: var(--amber, #E8A838);
}

/* ── Bulk action bar (fixed at bottom) ─────────────────────────── */
.bulk-bar {
  position: fixed;
  bottom: 0; left: 0; right: 0;
  z-index: 8500;
  background: #23211D;
  color: #F5EDE0;
  padding: 0.7rem 1rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
  box-shadow: 0 -8px 24px rgba(0, 0, 0, 0.25);
}
.bulk-bar-count {
  font-weight: 700;
  font-size: 0.92rem;
  color: var(--amber, #E8A838);
  min-width: 90px;
}
.bulk-bar-btn {
  padding: 0.5rem 0.8rem;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: rgba(255, 255, 255, 0.06);
  color: #F5EDE0;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
}
.bulk-bar-btn:hover:not(:disabled) {
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.3);
}
.bulk-bar-btn:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}
.bulk-bar-btn.danger {
  border-color: rgba(220, 80, 80, 0.4);
  color: #FFB8B8;
}
.bulk-bar-btn.danger:hover:not(:disabled) {
  background: rgba(220, 80, 80, 0.18);
}
.bulk-bar-cancel {
  margin-left: auto;
  border-color: rgba(255, 255, 255, 0.3);
}
select.bulk-bar-btn {
  padding: 0.5rem 0.6rem;
  appearance: none;
  -webkit-appearance: none;
  background: rgba(255, 255, 255, 0.06) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 8 6'%3E%3Cpath d='M0 0l4 6 4-6z' fill='%23F5EDE0'/%3E%3C/svg%3E") no-repeat right 0.6rem center / 8px 6px;
  padding-right: 1.6rem;
}

@media (max-width: 640px) {
  .bulk-bar {
    padding: 0.55rem 0.6rem;
    gap: 0.35rem;
  }
  .bulk-bar-count { min-width: 70px; font-size: 0.8rem }
  .bulk-bar-btn { padding: 0.4rem 0.55rem; font-size: 0.78rem }
  body.bulk-mode-on { padding-bottom: 130px }
}
