/* ===== ユーザー制作LANE（作品） ===== */
.work-create-btn {
  display: block; width: calc(100% - 24px); margin: 12px;
  padding: 12px; border-radius: 12px; border: 2px dashed #06c755;
  background: rgba(6, 199, 85, 0.08); color: #04963f;
  font-weight: 700; font-size: 14px; cursor: pointer;
}
.work-create-btn:hover { background: rgba(6, 199, 85, 0.16); }
.works-section-title {
  padding: 14px 16px 6px; font-size: 12px; font-weight: 700;
  color: var(--text-muted, #888); letter-spacing: 0.04em;
}
.work-item {
  display: flex; gap: 10px; padding: 10px 14px; cursor: pointer;
  align-items: center;
}
.work-item:hover { background: rgba(127, 127, 127, 0.08); }
.work-item-avatars { display: flex; flex-shrink: 0; }
.work-item-avatars img {
  width: 38px; height: 38px; border-radius: 50%; object-fit: cover;
  border: 2px solid #fff; margin-left: -10px; background: #ccc;
}
.work-item-avatars img:first-child { margin-left: 0; }
.work-item-avatars .work-avatar-fallback {
  width: 38px; height: 38px; border-radius: 50%; margin-left: -10px;
  border: 2px solid #fff; display: flex; align-items: center; justify-content: center;
  color: #fff; font-weight: 700; font-size: 15px;
}
.work-item-avatars .work-avatar-fallback:first-child { margin-left: 0; }
.work-item-body { flex: 1; min-width: 0; }
.work-item-title {
  font-size: 14px; font-weight: 700; white-space: nowrap;
  overflow: hidden; text-overflow: ellipsis;
}
.work-item-meta {
  font-size: 11.5px; color: var(--text-muted, #888);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.work-status-badge {
  font-size: 10.5px; font-weight: 700; padding: 2px 8px; border-radius: 999px;
  background: #e5e7eb; color: #555; flex-shrink: 0;
}
.work-status-badge.published { background: #06c755; color: #fff; }
.works-empty {
  padding: 18px 16px; font-size: 12.5px; color: var(--text-muted, #888);
}

/* ===== プレイヤー ===== */
#work-player {
  display: flex; flex-direction: column; height: 100%; min-height: 0;
  background: #8ea6c1;
}
#work-player[hidden] { display: none; }
.wp-head {
  display: flex; align-items: center; gap: 8px; padding: 10px 12px;
  background: rgba(255, 255, 255, 0.92); border-bottom: 1px solid rgba(0,0,0,0.08);
}
.wp-head-meta { flex: 1; min-width: 0; }
.wp-head-meta h2 {
  font-size: 15px; margin: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.wp-author { font-size: 11px; color: var(--text-muted, #888); }
.wp-head button {
  border: none; background: none; cursor: pointer; font-size: 13px;
  padding: 6px 8px; border-radius: 8px; white-space: nowrap;
}
.wp-head button:hover { background: rgba(0,0,0,0.06); }
.wp-messages {
  flex: 1; overflow-y: auto; padding: 14px 12px; min-height: 0;
}
.wp-row { display: flex; gap: 8px; margin-bottom: 12px; align-items: flex-start; }
.wp-row.mine { flex-direction: row-reverse; }
.wp-avatar {
  width: 36px; height: 36px; border-radius: 50%; object-fit: cover;
  flex-shrink: 0; background: #ccc;
}
.wp-avatar-fallback {
  width: 36px; height: 36px; border-radius: 50%; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
  color: #fff; font-weight: 700; font-size: 14px;
}
.wp-bubble-wrap { max-width: 74%; }
.wp-name { font-size: 11px; color: #fff; margin: 0 0 3px 2px; text-shadow: 0 1px 2px rgba(0,0,0,0.25); }
.wp-row.mine .wp-name { text-align: right; margin: 0 2px 3px 0; }
.wp-bubble {
  background: #fff; border-radius: 14px; padding: 9px 12px;
  font-size: 14px; line-height: 1.55; white-space: pre-wrap; word-break: break-word;
  box-shadow: 0 1px 2px rgba(0,0,0,0.12);
}
.wp-row.mine .wp-bubble { background: #06c755; color: #fff; }
.wp-bubble.choice-picked { background: #06c755; color: #fff; }
.wp-system {
  text-align: center; color: #fff; font-size: 12px; margin: 14px 0;
  text-shadow: 0 1px 2px rgba(0,0,0,0.3);
}
.wp-choices {
  padding: 10px 12px; display: flex; flex-direction: column; gap: 8px;
  background: rgba(255,255,255,0.92);
}
.wp-choices[hidden] { display: none; }
.wp-choice-btn {
  padding: 12px; border-radius: 12px; border: 1.5px solid #06c755;
  background: #fff; color: #04963f; font-size: 14px; font-weight: 700;
  cursor: pointer; text-align: left;
}
.wp-choice-btn:hover { background: rgba(6,199,85,0.1); }
.wp-foot {
  padding: 10px 12px; background: rgba(255,255,255,0.92);
  display: flex; align-items: center; gap: 10px;
}
.wp-foot .btn-line-primary { flex: 1; }
.wp-end-label { flex: 1; text-align: center; font-size: 13px; color: #555; }

/* ===== エディタ ===== */
.works-editor-card { width: min(860px, 96vw); max-height: 92vh; display: flex; flex-direction: column; }
.works-editor-card .modal-body { overflow-y: auto; }
.we-char-list {
  display: flex; flex-wrap: wrap; gap: 6px; max-height: 168px; overflow-y: auto;
  border: 1px solid rgba(127,127,127,0.3); border-radius: 10px; padding: 8px; margin-bottom: 12px;
}
.we-char-chip {
  display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px 4px 4px;
  border-radius: 999px; border: 1.5px solid rgba(127,127,127,0.35);
  font-size: 12.5px; cursor: pointer; background: none; color: inherit;
}
.we-char-chip img { width: 24px; height: 24px; border-radius: 50%; object-fit: cover; }
.we-char-chip.selected { border-color: #06c755; background: rgba(6,199,85,0.12); font-weight: 700; }
.we-steps-head {
  display: flex; align-items: center; gap: 8px; margin: 10px 0 8px;
  font-weight: 700; font-size: 13.5px;
}
.we-steps-head .spacer { flex: 1; }
.we-add-btn {
  padding: 6px 12px; border-radius: 999px; border: 1.5px solid #06c755;
  background: #fff; color: #04963f; font-weight: 700; font-size: 12.5px; cursor: pointer;
}
.we-step {
  border: 1px solid rgba(127,127,127,0.3); border-radius: 12px;
  padding: 10px; margin-bottom: 10px; background: rgba(127,127,127,0.04);
}
.we-step-head { display: flex; align-items: center; gap: 6px; margin-bottom: 8px; }
.we-step-no {
  font-size: 11px; font-weight: 700; background: #374151; color: #fff;
  border-radius: 6px; padding: 2px 7px;
}
.we-step-type { font-size: 11.5px; font-weight: 700; color: #04963f; }
.we-step-type.choice { color: #b45309; }
.we-step-head .spacer { flex: 1; }
.we-mini-btn {
  border: 1px solid rgba(127,127,127,0.4); background: none; color: inherit;
  border-radius: 7px; padding: 3px 9px; font-size: 12px; cursor: pointer;
}
.we-mini-btn:hover { background: rgba(127,127,127,0.12); }
.we-step select, .we-step textarea, .we-step input[type="text"] {
  width: 100%; box-sizing: border-box; border: 1px solid rgba(127,127,127,0.4);
  border-radius: 8px; padding: 7px 9px; font-size: 13.5px; margin-bottom: 6px;
  background: var(--input-bg, #fff); color: inherit;
}
.we-step textarea { min-height: 54px; resize: vertical; }
.we-opt-row { display: flex; gap: 6px; align-items: center; margin-bottom: 6px; }
.we-opt-row input[type="text"] { flex: 1; margin-bottom: 0; }
.we-opt-row select { width: 128px; flex-shrink: 0; margin-bottom: 0; }
.we-error {
  color: #dc2626; font-size: 12.5px; padding: 8px 2px 0; white-space: pre-wrap;
}
.btn-line-outline.danger { color: #dc2626; border-color: #dc2626; }
