/* ===== カラー変数（サイト共通） ===== */
:root {
  --bg:       #F4F4F2;
  --card:     #FFFFFF;
  --text:     #1A1A18;
  --sub:      #6B6B67;
  --muted:    #A0A09C;
  --border:   #E8E8E5;
  --pink:     #E83E6C;
  --pink-bg:  #FDE8EF;
  --pink-dark:#C0185A;
  --radius:   12px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
body { background: var(--bg); font-family: -apple-system, BlinkMacSystemFont, 'Hiragino Sans', sans-serif; color: var(--text); }

/* ===== 常駐ボタン ===== */
#conciergeBtn {
  position: fixed;
  bottom: 70px;
  right: 20px;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--pink);
  color: #fff;
  border: none;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(232,62,108,0.4);
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s;
  overflow: hidden;
  padding: 0;
}
#conciergeBtn:hover { background: var(--pink-dark); }
#conciergeBtn img {
  width: 80%;
  height: 80%;
  object-fit: cover;
  border-radius: 50%;
}

/* ===== オーバーレイ ===== */
#conciergeOverlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.5);
  z-index: 150;
  align-items: flex-end;
  justify-content: center;
}
#conciergeOverlay.open { display: flex; }

/* ===== シート ===== */
#conciergeSheet {
  background: var(--card);
  border-radius: 16px 16px 0 0;
  width: 100%;
  max-width: 520px;
  max-height: 90vh;
  overflow-y: auto;
  animation: slideUp 0.25s ease;
  display: flex;
  flex-direction: column;
}
@keyframes slideUp { from { transform: translateY(100%); } to { transform: translateY(0); } }

/* ===== ヘッダー ===== */
.cv-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 16px 10px;
  border-bottom: 0.5px solid var(--border);
  flex-shrink: 0;
}
.cv-header-title { font-size: 14px; font-weight: 600; color: var(--text); }
.cv-close-btn {
  background: none;
  border: none;
  cursor: pointer;
  color: var(--muted);
  font-size: 20px;
  line-height: 1;
  padding: 2px 6px;
}

/* ===== チャットエリア ===== */
.cv-chat {
  flex: 1;
  overflow-y: auto;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

/* バブル：bot */
.cv-bubble-bot {
  display: flex;
  align-items: flex-start;
  gap: 8px;
}
.cv-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--pink);
  color: #fff;
  font-size: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.cv-bubble-text {
  background: var(--bg);
  border-radius: 0 12px 12px 12px;
  padding: 10px 12px;
  font-size: 13px;
  line-height: 1.6;
  color: var(--text);
  max-width: calc(100% - 48px);
}

/* バブル：user（選択済み表示用） */
.cv-bubble-user {
  display: flex;
  justify-content: flex-end;
}
.cv-bubble-user-text {
  background: var(--pink);
  color: #fff;
  border-radius: 12px 0 12px 12px;
  padding: 8px 12px;
  font-size: 13px;
  max-width: 80%;
}

/* ===== 選択肢エリア ===== */
.cv-choices {
  padding: 0 16px 8px;
  flex-shrink: 0;
}

/* グループラベル */
.cv-group-label {
  font-size: 10px;
  color: var(--muted);
  margin: 10px 0 6px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* チップ */
.cv-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 4px;
}
.cv-chip {
  padding: 6px 12px;
  border-radius: 20px;
  font-size: 13px;
  background: var(--card);
  color: var(--text);
  border: 1px solid var(--border);
  cursor: pointer;
  transition: all 0.15s;
  user-select: none;
}
.cv-chip:hover { border-color: var(--pink); color: var(--pink); }
.cv-chip.selected { background: var(--pink-bg); border-color: var(--pink); color: var(--pink-dark); font-weight: 500; }

/* もっと見るボタン */
.cv-more-btn {
  font-size: 12px;
  color: var(--muted);
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px 0;
  margin-top: 2px;
  text-decoration: underline;
}
.cv-more-chips { display: none; }
.cv-more-chips.open { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 6px; }

/* ===== アクションボタンエリア ===== */
.cv-actions {
  padding: 10px 16px 16px;
  display: flex;
  gap: 8px;
  flex-shrink: 0;
  border-top: 0.5px solid var(--border);
}
.cv-btn-skip {
  flex: 1;
  padding: 11px 0;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: var(--card);
  color: var(--sub);
  font-size: 14px;
  cursor: pointer;
}
.cv-btn-next {
  flex: 2;
  padding: 11px 0;
  border-radius: 8px;
  border: none;
  background: var(--pink);
  color: #fff;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
}
.cv-btn-next:disabled { background: var(--border); color: var(--muted); cursor: default; }
.cv-btn-next:not(:disabled):hover { background: var(--pink-dark); }

/* ===== ローディング ===== */
.cv-loading {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  color: var(--muted);
}
.cv-dots span {
  display: inline-block;
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--muted);
  animation: dotBlink 1.2s infinite;
}
.cv-dots span:nth-child(2) { animation-delay: 0.2s; }
.cv-dots span:nth-child(3) { animation-delay: 0.4s; }
@keyframes dotBlink { 0%,80%,100%{opacity:0.2} 40%{opacity:1} }

/* ===== 結果エリア ===== */
.cv-result-section { margin-bottom: 16px; }
.cv-result-label {
  font-size: 11px;
  font-weight: 600;
  color: var(--muted);
  margin-bottom: 8px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* 作品カード */
.cv-works { display: flex; flex-direction: column; gap: 10px; }
.cv-work-card {
  display: flex;
  gap: 10px;
  background: var(--bg);
  border-radius: 8px;
  padding: 10px;
  cursor: pointer;
  transition: background 0.15s;
}
.cv-work-card:hover { background: #ECEAE8; }
.cv-work-thumb {
  width: 64px;
  height: 86px;
  object-fit: cover;
  border-radius: 4px;
  flex-shrink: 0;
  background: var(--border);
}
.cv-work-info { flex: 1; min-width: 0; }
.cv-work-title {
  font-size: 12px;
  font-weight: 500;
  line-height: 1.5;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin-bottom: 5px;
}
.cv-work-badges { display: flex; flex-wrap: wrap; gap: 4px; }
.cv-svc-badge {
  font-size: 10px;
  padding: 2px 6px;
  border-radius: 3px;
}
.svc-fanza_tv      { background: #E6F1FB; color: #0C447C; }
.svc-fanza_tv_plus { background: #EAF3DE; color: #27500A; }
.svc-miratch       { background: #FAEEDA; color: #633806; }
.svc-miratch_dx    { background: #FAECE7; color: #712B13; }
.svc-vr_ch         { background: #EEEDFE; color: #3C3489; }

/* シリーズカード */
.cv-series { display: flex; flex-direction: column; gap: 8px; }
.cv-series-card {
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--bg);
  border-radius: 8px;
  padding: 10px;
  text-decoration: none;
  color: var(--text);
  transition: background 0.15s;
}
.cv-series-card:hover { background: #ECEAE8; }
.cv-series-thumb {
  width: 48px;
  height: 64px;
  object-fit: cover;
  border-radius: 4px;
  flex-shrink: 0;
  background: var(--border);
}
.cv-series-name { font-size: 12px; font-weight: 500; line-height: 1.5; flex: 1; min-width: 0; }
.cv-series-arrow { color: var(--muted); font-size: 14px; flex-shrink: 0; }

/* リトライボタン */
.cv-retry-btn {
  width: 100%;
  margin-top: 12px;
  padding: 11px 0;
  border-radius: 8px;
  border: 1px solid var(--pink);
  background: var(--card);
  color: var(--pink);
  font-size: 14px;
  cursor: pointer;
}
.cv-retry-btn:hover { background: var(--pink-bg); }

/* 女優カード */
.cv-actresses { display: flex; gap: 12px; flex-wrap: wrap; }
.cv-actress-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  text-decoration: none;
  color: var(--text);
  width: calc(33% - 8px);
}
.cv-actress-card:hover .cv-actress-name { color: var(--pink); }
.cv-actress-thumb {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  object-fit: cover;
  background: var(--border);
}
.cv-actress-no-img { background: var(--border); }
.cv-actress-name {
  font-size: 12px;
  text-align: center;
  line-height: 1.4;
  color: var(--text);
}

/* サービス絞り込み */
.cv-result-btns { display: flex; flex-direction: column; gap: 10px; margin-top: 12px; }
.cv-svc-filter-label { font-size: 11px; color: var(--muted); margin-bottom: 6px; }
.cv-svc-filter-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.cv-svc-chip {
  font-size: 11px;
  padding: 4px 10px;
  border-radius: 20px;
  border: 1px solid var(--border);
  background: var(--card);
  color: var(--sub);
  cursor: pointer;
  transition: all 0.15s;
}
.cv-svc-chip:hover { border-color: var(--pink); color: var(--pink); }
.cv-svc-chip.selected { background: var(--pink-bg); border-color: var(--pink); color: var(--pink-dark); font-weight: 500; }

/* やり直しボタン */
.cv-restart-btn {
  width: 100%;
  padding: 9px 0;
  border-radius: 8px;
  border: none;
  background: none;
  color: var(--muted);
  font-size: 13px;
  cursor: pointer;
  text-align: center;
}
.cv-restart-btn:hover { color: var(--sub); }

/* ===== PC ===== */
@media (min-width: 768px) {
  #conciergeOverlay { align-items: center; }
  #conciergeSheet { border-radius: 12px; max-height: 80vh; }
}

/* ===== デモ用ページ背景 ===== */
.demo-page {
  min-height: 100vh;
  padding: 40px 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 12px;
}
.demo-page p { font-size: 14px; color: var(--sub); }
