/* Free time tab (Backlog) and the "Got a gap?" picker. */

/* ---------- Header ---------- */
#backlog-root { display: flex; flex-direction: column; gap: 16px; }
.bl-head {
  display: flex; align-items: flex-start; gap: 12px;
}
.bl-head > div { flex: 1; min-width: 0; }
.bl-addbtn {
  margin-left: auto; flex: none;
  width: 44px; height: 44px; border-radius: 999px;
  border: 0; background: var(--surface-2);
  color: var(--ink); cursor: pointer;
  display: flex; align-items: center; justify-content: center;
}
.bl-addbtn svg { width: 18px; height: 18px; }
.bl-addbtn:active { transform: scale(0.97); }
.bl-loading { color: var(--ink-60); font-size: 15px; padding: 24px 0; text-align: center; }

/* ---------- List: iOS inset-grouped ---------- */
.bl-empty { border-radius: var(--r-card); padding: 28px 20px; text-align: center; }
.bl-empty p { margin: 0 0 6px; font-size: 17px; font-weight: 600; color: var(--ink); }
.bl-empty .bl-emptysub { font-size: 13px; font-weight: 400; color: var(--ink-60); margin: 0; }

.bl-list {
  display: flex; flex-direction: column;
  border-radius: var(--r-card);
  overflow: hidden;
}
.bl-row {
  display: flex; align-items: center; gap: 10px;
  padding: 12px 12px 12px 16px;
  border-bottom: 0.5px solid var(--separator);
}
.bl-row:last-child { border-bottom: none; }
.bl-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 6px; }
.bl-what {
  font-size: 17px; font-weight: 500; color: var(--ink);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.bl-meta { display: flex; align-items: center; gap: 8px; }
.bl-sizechip {
  font-size: 13px; font-weight: 600; color: var(--me-ink);
  background: var(--me-tint); border-radius: var(--r-ctl); padding: 3px 8px;
  font-variant-numeric: tabular-nums;
}
.bl-tag {
  height: 26px; padding: 0 10px; border-radius: var(--r-ctl);
  border: 0; background: var(--surface-2);
  font-size: 13px; font-weight: 600; color: var(--ink);
  cursor: pointer; font-family: var(--font-text);
}
.bl-tag.none { color: var(--ink-60); }
.bl-del {
  width: 32px; height: 32px; border-radius: 999px; flex: none;
  border: 0; background: transparent; color: var(--ink-30);
  cursor: pointer; display: flex; align-items: center; justify-content: center;
}
.bl-del svg { width: 12px; height: 12px; }
.bl-del:active { transform: scale(0.9); color: var(--destructive); }

/* ---------- Add sheet ---------- */
.bl-add { display: flex; flex-direction: column; gap: 14px; }
.bl-input {
  min-height: 48px; border-radius: var(--r-ctl); padding: 0 14px;
  border: 0; background: var(--surface-2);
  font-family: var(--font-text); font-size: 17px; color: var(--ink);
}
.bl-input::placeholder { color: var(--ink-30); }
.bl-sizes { display: flex; gap: 8px; }
.bl-size {
  flex: 1; height: 44px; border-radius: 999px;
  border: 0; background: var(--surface-2);
  font-family: var(--font-text); font-size: 15px; font-weight: 600; color: var(--ink);
  cursor: pointer;
}
.bl-size.on { background: var(--me-tint); color: var(--me-ink); }
.bl-save { margin-top: 2px; }

/* Full state: drop one first */
.bl-full { display: flex; flex-direction: column; gap: 4px; max-height: 40vh; overflow-y: auto; }
.bl-fullrow {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 4px; border-bottom: 0.5px solid var(--separator);
}
.bl-fullrow:last-child { border-bottom: none; }
.bl-fullwhat {
  flex: 1; min-width: 0; font-size: 15px; color: var(--ink);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.bl-drop {
  height: 34px; padding: 0 16px; border-radius: 999px; flex: none;
  border: 0; background: var(--surface-2);
  font-family: var(--font-text); font-size: 13px; font-weight: 600; color: var(--destructive);
  cursor: pointer;
}

/* ---------- "Got a gap?" card, moved to the top of Free time ---------- */
.gap-card {
  padding: 16px;
  display: flex; flex-direction: column; gap: 12px;
}
.gap-head { display: flex; align-items: center; }
.gap-title { font-size: 17px; font-weight: 600; color: var(--ink); }
.gap-sizes { display: flex; gap: 8px; }
.gap-size {
  flex: 1; height: 44px; border-radius: 999px;
  border: 0; background: var(--surface-2);
  font-family: var(--font-text); font-size: 15px; font-weight: 600; color: var(--ink);
  cursor: pointer;
}
.gap-size.on { background: var(--me-tint); color: var(--me-ink); }
.gap-tags { display: flex; gap: 8px; flex-wrap: wrap; }
.gap-tag {
  height: 32px; padding: 0 14px; border-radius: 999px;
  border: 0; background: var(--surface-2);
  font-family: var(--font-text); font-size: 13px; font-weight: 600; color: var(--ink-60);
  cursor: pointer;
}
.gap-tag.on { background: var(--me-tint); color: var(--me-ink); }
.gap-results { display: flex; flex-direction: column; gap: 8px; }
.gap-hint { margin: 0; font-size: 13px; color: var(--ink-60); }
.gap-pick {
  display: flex; align-items: center; gap: 10px;
  min-height: 48px; border-radius: var(--r-ctl); padding: 8px 12px;
  border: 0; background: var(--surface-2);
  font-family: var(--font-text); cursor: pointer; text-align: left;
}
.gap-pickwhat {
  flex: 1; min-width: 0; font-size: 15px; font-weight: 500; color: var(--ink);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.gap-pick.sel { box-shadow: inset 0 0 0 1.5px var(--me-ink); }
.gap-shuffle {
  align-self: flex-start; height: 36px; padding: 0 16px; border-radius: 999px;
  border: 0; background: var(--surface-2);
  font-family: var(--font-text); font-size: 13px; font-weight: 600; color: var(--ink);
  cursor: pointer;
}
