/* ==========================================================================
   Model Course Generator — /model-course.html
   COO Department / TDR+
   ========================================================================== */

.mc-intro {
  max-width: 840px;
  margin: 0 auto 24px;
  color: var(--text-sub);
  font-size: 0.92rem;
  line-height: 1.8;
}
.mc-intro strong { color: var(--text); font-weight: 600; }

/* ------- 2カラムレイアウト ------- */
.mc-layout {
  display: grid;
  grid-template-columns: 360px 1fr;
  gap: 32px;
  align-items: start;
  max-width: 1100px;
  margin: 0 auto 48px;
}
@media (max-width: 860px) {
  .mc-layout {
    grid-template-columns: 1fr;
    gap: 24px;
  }
}

/* ------- フォーム ------- */
.mc-form {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 22px 22px 18px;
  position: sticky;
  top: 80px;
  box-shadow: 0 2px 12px rgba(0,0,0,0.03);
}
@media (max-width: 860px) {
  .mc-form { position: static; }
}

.mc-form h2 {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text);
  margin: 0 0 14px;
  letter-spacing: 0.02em;
}

.mc-field {
  margin-bottom: 16px;
}
.mc-field > label,
.mc-field-label {
  display: block;
  font-size: 0.78rem;
  font-weight: 500;
  color: var(--text-sub);
  margin-bottom: 6px;
  letter-spacing: 0.03em;
}
.mc-field input[type="date"],
.mc-field select {
  width: 100%;
  padding: 9px 12px;
  border: 1px solid var(--border);
  border-radius: 8px;
  font-size: 0.92rem;
  color: var(--text);
  background: #fff;
  box-sizing: border-box;
  font-family: inherit;
}
.mc-field input[type="date"]:focus,
.mc-field select:focus {
  outline: none;
  border-color: var(--accent);
}

/* 人数グリッド */
.mc-group-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}
.mc-num-cell {
  display: flex;
  flex-direction: column;
  align-items: center;
}
.mc-num-cell span {
  font-size: 0.72rem;
  color: var(--text-muted);
  margin-bottom: 4px;
}
.mc-num-cell input[type="number"] {
  width: 100%;
  padding: 8px 6px;
  text-align: center;
  border: 1px solid var(--border);
  border-radius: 8px;
  font-size: 0.95rem;
  font-family: inherit;
  box-sizing: border-box;
}

/* パーク切替（セグメント） */
.mc-park-switch,
.mc-duration-switch {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  background: #f7f5f2;
  border-radius: 8px;
  padding: 4px;
}
.mc-duration-switch {
  grid-template-columns: repeat(3, 1fr);
}
.mc-park-switch button,
.mc-duration-switch button {
  padding: 8px 6px;
  border: none;
  background: transparent;
  border-radius: 6px;
  font-size: 0.82rem;
  color: var(--text-sub);
  cursor: pointer;
  font-family: inherit;
  transition: all 0.15s;
}
.mc-park-switch button.active,
.mc-duration-switch button.active {
  background: #fff;
  color: var(--text);
  font-weight: 600;
  box-shadow: 0 1px 3px rgba(0,0,0,0.08);
}

/* 好みチェックボックス */
.mc-pref-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
}
.mc-pref-grid label {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 10px;
  border: 1px solid var(--border);
  border-radius: 8px;
  font-size: 0.82rem;
  cursor: pointer;
  background: #fff;
  transition: all 0.15s;
  color: var(--text-sub);
}
.mc-pref-grid label:has(input:checked) {
  border-color: var(--accent);
  background: var(--accent-soft);
  color: var(--text);
}
.mc-pref-grid input[type="checkbox"] {
  accent-color: var(--accent);
  margin: 0;
}

/* スライダー */
.mc-field input[type="range"] {
  width: 100%;
  accent-color: var(--accent);
}
.mc-range-value {
  display: inline-block;
  margin-left: 6px;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--accent);
}

/* 送信ボタン */
.mc-submit {
  width: 100%;
  padding: 12px;
  background: var(--text);
  color: #fff;
  border: none;
  border-radius: 8px;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
  transition: background 0.15s;
  letter-spacing: 0.04em;
}
.mc-submit:hover { background: var(--accent); }
.mc-submit:disabled { opacity: 0.5; cursor: not-allowed; }

/* ------- 結果パネル ------- */
.mc-result {
  min-height: 400px;
}
.mc-result-empty {
  background: #fff;
  border: 1px dashed var(--border);
  border-radius: 14px;
  padding: 60px 24px;
  text-align: center;
  color: var(--text-muted);
  font-size: 0.92rem;
  line-height: 1.8;
}
.mc-result-empty strong {
  display: block;
  color: var(--text-sub);
  font-size: 1rem;
  margin-bottom: 8px;
}

/* サマリーバー */
.mc-summary {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 16px 20px;
  margin-bottom: 20px;
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  align-items: center;
}
.mc-summary-item {
  display: flex;
  flex-direction: column;
  font-size: 0.82rem;
}
.mc-summary-item .label {
  color: var(--text-muted);
  font-size: 0.7rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  margin-bottom: 2px;
}
.mc-summary-item .value {
  color: var(--text);
  font-weight: 600;
  font-size: 0.95rem;
}
.mc-summary-item .value.crowd-lvl-low { color: #2a8a5f; }
.mc-summary-item .value.crowd-lvl-mid { color: #b08840; }
.mc-summary-item .value.crowd-lvl-high { color: #c23a60; }

.mc-summary-actions {
  margin-left: auto;
  display: flex;
  gap: 8px;
}
.mc-btn-mini {
  padding: 6px 12px;
  font-size: 0.78rem;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: #fff;
  color: var(--text-sub);
  cursor: pointer;
  font-family: inherit;
}
.mc-btn-mini:hover { border-color: var(--text-sub); color: var(--text); }

/* ------- タイムライン ------- */
.mc-timeline {
  position: relative;
  padding-left: 72px;
}
.mc-timeline::before {
  content: '';
  position: absolute;
  left: 56px;
  top: 8px;
  bottom: 8px;
  width: 2px;
  background: var(--border);
}
.mc-slot {
  position: relative;
  margin-bottom: 14px;
}
.mc-slot-time {
  position: absolute;
  left: -72px;
  top: 18px;
  width: 44px;
  text-align: right;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--text-sub);
  letter-spacing: 0.02em;
}
.mc-slot-dot {
  position: absolute;
  left: -22px;
  top: 22px;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: #fff;
  border: 2px solid var(--accent);
  z-index: 1;
}
.mc-slot-card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 14px 18px;
  transition: transform 0.15s, box-shadow 0.15s;
}
.mc-slot-card:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 14px rgba(0,0,0,0.05);
}
.mc-slot-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 4px;
}
.mc-slot-name {
  font-size: 0.98rem;
  font-weight: 600;
  color: var(--text);
  line-height: 1.4;
}
.mc-slot-name a {
  color: inherit;
  text-decoration: none;
  border-bottom: 1px dotted var(--border);
}
.mc-slot-name a:hover { color: var(--accent); border-bottom-color: var(--accent); }

.mc-slot-meta {
  font-size: 0.78rem;
  color: var(--text-muted);
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 6px;
}
.mc-slot-meta span { white-space: nowrap; }
.mc-slot-meta .wait-long { color: #c23a60; font-weight: 600; }
.mc-slot-meta .wait-mid { color: #b08840; font-weight: 600; }
.mc-slot-meta .wait-short { color: #2a8a5f; font-weight: 600; }

.mc-slot-reason {
  font-size: 0.82rem;
  color: var(--text-sub);
  line-height: 1.6;
  margin-top: 8px;
  padding-top: 8px;
  border-top: 1px solid var(--border-light);
}

/* スロットタイプ別タグ */
.mc-tag {
  display: inline-block;
  font-size: 0.68rem;
  padding: 2px 8px;
  border-radius: 10px;
  font-weight: 600;
  letter-spacing: 0.04em;
  flex-shrink: 0;
}
.mc-tag.type-attraction { background: #eaf1f7; color: #3870a0; }
.mc-tag.type-dpa { background: #f4e9f0; color: #a02f6b; }
.mc-tag.type-dining { background: #f7efe4; color: #9c6a2a; }
.mc-tag.type-show { background: #efe9f7; color: #6a4aa8; }
.mc-tag.type-parade { background: #f7e9ef; color: #a83a7a; }
.mc-tag.type-rest { background: #eef5ee; color: #2a7a5f; }
.mc-tag.type-entry { background: #f7e4e4; color: #c23a60; }
.mc-tag.type-shop { background: #f2efe8; color: #8a7a4a; }
.mc-tag.type-chargreet { background: #fef3c7; color: #92400e; }
.mc-tag.type-photo { background: #ecfdf5; color: #065f46; }
.mc-tag.type-park-entry { background: #dbeafe; color: #1d4ed8; }
.mc-tag.type-park-exit { background: #f3f4f6; color: #4b5563; }
.mc-tag.type-dpa-purchase { background: #fce7f3; color: #be185d; }
.mc-tag.type-snack { background: #fef3c7; color: #b45309; }

/* スロットカラー（左ボーダー） */
.mc-slot-card[data-type="dpa"] { border-left: 3px solid #a02f6b; }
.mc-slot-card[data-type="dining"] { border-left: 3px solid #9c6a2a; }
.mc-slot-card[data-type="snack"] { border-left: 3px solid #b8860b; }
.mc-slot-card[data-type="show"],
.mc-slot-card[data-type="parade"] { border-left: 3px solid #6a4aa8; }
.mc-slot-card[data-type="rest"] { border-left: 3px solid #2a7a5f; }
.mc-slot-card[data-type="entry"] { border-left: 3px solid #c23a60; }
.mc-slot-card[data-type="chargreet"] { border-left: 3px solid #d97706; }
.mc-slot-card[data-type="photo"] { border-left: 3px solid #059669; }
.mc-slot-card[data-type="park-entry"] { border-left: 4px solid #1d4ed8; background: #eff6ff; }
.mc-slot-card[data-type="park-exit"] { border-left: 4px solid #6b7280; background: #f9fafb; }
.mc-slot-card[data-type="dpa-purchase"] { border-left: 4px solid #be185d; background: linear-gradient(135deg, #fdf2f8, #fff); }

/* ------- 固定（ピン）機能 ------- */
.mc-slot-head-right {
  display: flex;
  gap: 6px;
  align-items: center;
  flex-shrink: 0;
}
.mc-pin-btn {
  padding: 3px 10px;
  font-size: 0.68rem;
  font-weight: 600;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: #fff;
  color: var(--text-muted);
  cursor: pointer;
  font-family: inherit;
  transition: all 0.15s;
  white-space: nowrap;
}
.mc-pin-btn:hover { border-color: var(--accent); color: var(--accent); }
.mc-pin-btn.pinned {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
}
.mc-slot-pinned .mc-slot-card {
  border-color: var(--accent);
  box-shadow: 0 0 0 1px var(--accent);
}
.mc-slot-pinned .mc-slot-dot {
  background: var(--accent);
  border-color: var(--accent);
}

/* ------- 再生成エリア ------- */
.mc-regen-area {
  text-align: center;
  margin-top: 24px;
  padding: 20px;
}
.mc-regen-btn {
  display: inline-block;
  padding: 12px 32px;
  background: var(--text);
  color: #fff;
  border: none;
  border-radius: 8px;
  font-size: 0.92rem;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
  transition: background 0.15s;
  letter-spacing: 0.02em;
}
.mc-regen-btn:hover { background: var(--accent); }
.mc-regen-hint {
  font-size: 0.72rem;
  color: var(--text-muted);
  margin-top: 8px;
}
.mc-pin-status {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--accent);
  margin-bottom: 8px;
}
.mc-regen-counter {
  font-size: 0.68rem;
  color: var(--text-muted);
  margin-top: 4px;
}

/* ------- DPA提案バナー ------- */
.mc-dpa-suggestion {
  background: linear-gradient(135deg, #fdf2f8, #fce7f3);
  border: 1px solid #f9a8d4;
  border-radius: 10px;
  padding: 14px 18px;
  margin: 16px 0;
  font-size: 0.82rem;
  color: #831843;
  line-height: 1.7;
}
.mc-dpa-suggestion strong {
  font-weight: 600;
  color: #9d174d;
}

/* ------- コース統計バー ------- */
.mc-stats-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  background: #f8fafc;
  border: 1px solid var(--border-light);
  border-radius: 10px;
  padding: 12px 18px;
  margin: 12px 0;
  font-size: 0.78rem;
}
.mc-stat {
  display: flex;
  flex-direction: column;
  align-items: center;
}
.mc-stat-val {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text);
  font-family: "Inter", sans-serif;
}
.mc-stat-label {
  font-size: 0.65rem;
  color: var(--text-muted);
  margin-top: 2px;
}

/* ------- 子連れ休憩提案 ------- */
.mc-kids-tip {
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  border-radius: 10px;
  padding: 12px 18px;
  margin: 12px 0;
  font-size: 0.78rem;
  color: #1e40af;
  line-height: 1.7;
}

/* ------- セクションヘッダー ------- */
.mc-section-header {
  position: relative;
  margin: 20px 0 8px;
  padding: 0;
}
.mc-section-label {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--text-sub);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 3px 12px;
  border-radius: 4px;
  background: #f1f5f9;
  border-left: 3px solid var(--accent);
}
.mc-section-header[data-section="park-entry"] .mc-section-label { border-left-color: #1d4ed8; background: #dbeafe; color: #1e40af; }
.mc-section-header[data-section="park-exit"] .mc-section-label { border-left-color: #6b7280; background: #f3f4f6; color: #4b5563; }
.mc-section-header[data-section="dpa-purchase"] .mc-section-label { border-left-color: #be185d; background: #fce7f3; color: #9d174d; }
.mc-section-header[data-section="attraction"] .mc-section-label,
.mc-section-header[data-section="dpa"] .mc-section-label { border-left-color: #3870a0; background: #eaf1f7; color: #3870a0; }
.mc-section-header[data-section="dining"] .mc-section-label,
.mc-section-header[data-section="snack"] .mc-section-label { border-left-color: #9c6a2a; background: #f7efe4; color: #9c6a2a; }
.mc-section-header[data-section="show"] .mc-section-label,
.mc-section-header[data-section="parade"] .mc-section-label,
.mc-section-header[data-section="entry"] .mc-section-label { border-left-color: #6a4aa8; background: #efe9f7; color: #6a4aa8; }
.mc-section-header[data-section="chargreet"] .mc-section-label { border-left-color: #d97706; background: #fef3c7; color: #92400e; }
.mc-section-header[data-section="photo"] .mc-section-label { border-left-color: #059669; background: #ecfdf5; color: #065f46; }
.mc-section-header[data-section="rest"] .mc-section-label { border-left-color: #2a7a5f; background: #eef5ee; color: #2a7a5f; }
.mc-section-header[data-section="shop"] .mc-section-label { border-left-color: #8a7a4a; background: #f2efe8; color: #8a7a4a; }

/* ------- 絶叫系除外表示 ------- */
.mc-thrill-excluded {
  background: #fef2f2;
  border: 1px solid #fecaca;
  border-radius: 10px;
  padding: 12px 18px;
  margin-top: 12px;
  font-size: 0.78rem;
  color: #991b1b;
  line-height: 1.7;
}
.mc-thrill-excluded strong {
  font-weight: 600;
  color: #b91c1c;
}

/* ------- 好み設定表示 ------- */
.mc-pref-summary {
  font-size: 0.82rem !important;
  font-weight: 500 !important;
}

/* ------- 印刷用 ------- */
@media print {
  .site-header, .site-footer, .mc-form, .mc-regen-area,
  .mc-submit, .mc-pin-btn, .mc-btn-mini, .mc-ai-section,
  .breadcrumb, .menu-toggle { display: none !important; }
  .mc-layout { grid-template-columns: 1fr !important; }
  .mc-result { min-height: auto; }
  .mc-slot-card { break-inside: avoid; }
  .mc-summary { break-inside: avoid; }
  body { font-size: 11pt; }
  .mc-slot-card:hover { transform: none; box-shadow: none; }
}

/* ------- 備考ブロック ------- */
.mc-notes {
  background: #fafaf7;
  border: 1px solid var(--border-light);
  border-radius: 10px;
  padding: 16px 20px;
  margin-top: 24px;
}
.mc-notes h3 {
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--text);
  margin: 0 0 10px;
}
.mc-notes ul {
  margin: 0;
  padding-left: 18px;
  font-size: 0.82rem;
  line-height: 1.8;
  color: var(--text-sub);
}

/* 待ち時間許容スイッチ（3段階） */
.mc-wait-switch {
  grid-template-columns: repeat(3, 1fr);
}

/* 身長制限で除外されたアトラクション表示 */
.mc-excluded {
  background: #fef2f2;
  border: 1px solid #fecaca;
  border-radius: 10px;
  padding: 14px 18px;
  margin-top: 20px;
  font-size: 0.82rem;
  color: #991b1b;
  line-height: 1.7;
}
.mc-excluded strong {
  display: block;
  font-size: 0.78rem;
  font-weight: 600;
  color: #b91c1c;
  margin-bottom: 4px;
}

/* レスポンシブ微調整 */
@media (max-width: 600px) {
  .mc-timeline { padding-left: 60px; }
  .mc-timeline::before { left: 46px; }
  .mc-slot-time { left: -60px; width: 36px; text-align: right; font-size: 0.72rem; }
  .mc-slot-dot { left: -18px; width: 10px; height: 10px; }
  .mc-slot-card { padding: 12px 14px; }
  .mc-slot-name { font-size: 0.92rem; }
  .mc-summary { padding: 14px 16px; gap: 14px; }
  .mc-summary-actions { margin-left: 0; width: 100%; }
}

/* ==========================================================================
   AIプランナー セクション
   ========================================================================== */

.mc-ai-section {
  max-width: 840px;
  margin: 32px auto 0;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 24px;
  box-shadow: 0 2px 12px rgba(0,0,0,0.03);
}

.mc-ai-header h2 {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text);
  margin: 0 0 4px;
}
.mc-ai-header p {
  font-size: 0.82rem;
  color: var(--text-muted);
  margin: 0 0 16px;
}

.mc-ai-examples {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 16px;
}

.mc-ai-example {
  border: 1px solid var(--border);
  border-radius: 20px;
  background: #fff;
  padding: 6px 14px;
  font-size: 0.75rem;
  color: var(--text-sub);
  cursor: pointer;
  font-family: inherit;
  transition: border-color 0.15s, color 0.15s;
}
.mc-ai-example:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.mc-ai-messages {
  min-height: 100px;
  max-height: 400px;
  overflow-y: auto;
}

.mc-ai-msg {
  margin-bottom: 12px;
  padding: 10px 14px;
  border-radius: 10px;
  font-size: 0.85rem;
  line-height: 1.7;
}
.mc-ai-msg.user {
  background: var(--accent-soft, #eaf1f7);
  color: var(--text);
  text-align: right;
}
.mc-ai-msg.bot {
  background: #f7f5f2;
  color: var(--text-sub);
}
.mc-ai-msg.bot a {
  color: var(--accent);
}

.mc-ai-input-wrap {
  display: flex;
  gap: 8px;
  margin-top: 12px;
}

.mc-ai-input-wrap input {
  flex: 1;
  padding: 10px;
  border: 1px solid var(--border);
  border-radius: 8px;
  font-size: 0.88rem;
  font-family: inherit;
  color: var(--text);
  box-sizing: border-box;
}
.mc-ai-input-wrap input:focus {
  outline: none;
  border-color: var(--accent);
}

#mc-ai-send {
  background: var(--accent);
  color: #fff;
  border: none;
  padding: 10px 20px;
  border-radius: 8px;
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
  transition: opacity 0.15s;
}
#mc-ai-send:hover {
  opacity: 0.85;
}

@media (max-width: 600px) {
  .mc-ai-section { padding: 16px; }
  .mc-ai-example { font-size: 0.7rem; padding: 5px 10px; }
}

/* ==========================================================================
   ホテル提案セクション
   ========================================================================== */

.mc-hotel-suggestion {
  background: #fafaf7;
  border: 1px solid var(--border-light, #e5e5e0);
  border-radius: 10px;
  padding: 20px 22px;
  margin-top: 28px;
}
.mc-hotel-title {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text);
  margin: 0 0 4px;
}
.mc-hotel-lead {
  font-size: 0.82rem;
  color: var(--text-muted);
  margin: 0 0 16px;
  line-height: 1.6;
}
.mc-hotel-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 12px;
}
.mc-hotel-card {
  background: #fff;
  border: 1px solid var(--border, #e0ddd8);
  border-radius: 8px;
  padding: 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.mc-hotel-name {
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--text);
  line-height: 1.4;
}
.mc-hotel-category {
  font-size: 0.72rem;
  color: var(--text-muted);
  letter-spacing: 0.03em;
}
.mc-hotel-link {
  display: inline-block;
  margin-top: 8px;
  font-size: 0.78rem;
  color: var(--accent, #3870a0);
  text-decoration: none;
  border-bottom: 1px dotted var(--accent, #3870a0);
  align-self: flex-start;
  transition: color 0.15s;
}
.mc-hotel-link:hover {
  color: var(--text);
  border-bottom-color: var(--text);
}

@media (max-width: 600px) {
  .mc-hotel-suggestion { padding: 16px; }
  .mc-hotel-list { grid-template-columns: 1fr; }
}
@media print {
  .mc-hotel-suggestion { display: none !important; }
}
