/* ========================================
   report.css - スカウティングレポート風デザイン
   ======================================== */

:root {
  --navy: #1b2e4b;
  --navy-light: #2a4365;
  --accent-orange: #e8883a;
  --accent-orange-light: #fef3e2;
}

.report-body {
  background: #edf0f4;
}

/* ---- ヘッダーバー ---- */
.report-header {
  background: var(--navy);
  color: white;
  padding: 16px 24px;
}

.report-header-inner {
  max-width: 780px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.report-header-title {
  font-size: 1.5rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  line-height: 1.15;
}

.report-header-org {
  font-size: 0.7rem;
  opacity: 0.7;
  margin-top: 4px;
  letter-spacing: 0.04em;
}

.report-header-right {
  text-align: right;
}

.report-header-meta {
  font-size: 0.75rem;
  margin-bottom: 3px;
}

.meta-label {
  opacity: 0.6;
}

.meta-value {
  opacity: 0.9;
}

.meta-bold {
  font-weight: 700;
  opacity: 1;
}

.meta-sep {
  opacity: 0.3;
  margin: 0 6px;
}

/* ---- 画面ナビ ---- */
.screen-nav {
  max-width: 780px;
  margin: 0 auto;
  padding: 8px 24px 0;
  display: flex;
  gap: 12px;
}

.screen-nav a {
  font-size: 0.8125rem;
  color: var(--navy);
  text-decoration: none;
  opacity: 0.6;
}

.screen-nav a:hover {
  opacity: 1;
}

/* ---- コンテナ ---- */
.report-container {
  max-width: 780px;
  margin: 0 auto;
  padding: 16px 24px 40px;
}

/* ---- プロフィール + スコアカード ---- */
.profile-card {
  display: flex;
  justify-content: space-between;
  align-items: stretch;
  background: white;
  border-radius: 8px;
  border: 1.5px solid #d1d5db;
  overflow: hidden;
  margin-bottom: 16px;
}

.profile-left {
  padding: 12px 18px;
  flex: 1;
}

.profile-name {
  font-size: 1.35rem;
  font-weight: 900;
  color: var(--navy);
  letter-spacing: 0.04em;
  margin-bottom: 6px;
}

.profile-details {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.profile-detail-row {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.8125rem;
}

.detail-label {
  color: #94a3b8;
  font-weight: 600;
  min-width: 3em;
}

.detail-value {
  color: var(--text);
  font-weight: 500;
}

.profile-right {
  background: var(--navy);
  color: white;
  padding: 16px 28px;
  text-align: center;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  min-width: 160px;
}

.profile-score-label {
  font-size: 0.6875rem;
  opacity: 0.7;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 4px;
}

.profile-score-row {
  display: flex;
  align-items: baseline;
  gap: 4px;
}

.profile-score-number {
  font-size: 2.5rem;
  font-weight: 900;
  line-height: 1;
}

.profile-score-max {
  font-size: 1rem;
  opacity: 0.5;
  font-weight: 500;
}

.profile-grade {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 8px;
  font-size: 1.25rem;
  font-weight: 900;
  color: var(--navy);
  margin-top: 6px;
}

/* ---- セクション共通 ---- */
.report-section {
  background: white;
  border-radius: 8px;
  border: 1.5px solid #d1d5db;
  margin-bottom: 16px;
  overflow: hidden;
}

.section-header {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 16px;
  border-bottom: 1.5px solid #e5e7eb;
  background: #f9fafb;
}

.section-num {
  width: 28px;
  height: 28px;
  background: var(--navy);
  color: white;
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 0.875rem;
  flex-shrink: 0;
}

.section-title {
  font-size: 0.9375rem;
  font-weight: 700;
  color: var(--navy);
}

.section-body {
  padding: 16px;
}

/* ---- 1: カテゴリ別評価テーブル ---- */
.eval-table-wrap {
  overflow-x: auto;
}

.eval-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.8125rem;
}

.eval-table th {
  text-align: left;
  padding: 6px 8px;
  font-weight: 600;
  color: #94a3b8;
  font-size: 0.6875rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  border-bottom: 1px solid #e5e7eb;
}

.eval-table td {
  padding: 8px 8px;
  border-bottom: 1px solid #f1f3f5;
  vertical-align: middle;
}

.eval-table tr:last-child td {
  border-bottom: none;
}

.eval-th-name { width: 30%; }
.eval-th-dots { width: 25%; }
.eval-th-score { width: 15%; text-align: center; }
.eval-th-bar { width: 30%; }

.eval-cat-name {
  font-weight: 600;
  color: var(--navy);
}

/* ドット評価 */
.eval-dots {
  display: flex;
  gap: 3px;
}

.eval-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #e2e8f0;
}

.eval-dot.filled {
  background: var(--navy);
}

.eval-dot.half {
  background: linear-gradient(90deg, var(--navy) 50%, #e2e8f0 50%);
}

.eval-score-cell {
  text-align: center;
  font-weight: 700;
  color: var(--navy);
  font-size: 0.875rem;
}

.eval-bar-wrap {
  display: flex;
  align-items: center;
  gap: 8px;
}

.eval-bar {
  flex: 1;
  height: 6px;
  background: #e2e8f0;
  border-radius: 3px;
  overflow: hidden;
}

.eval-bar-fill {
  height: 100%;
  border-radius: 3px;
  transition: width 0.6s ease;
}

.eval-bar-fill.high    { background: #22c55e; }
.eval-bar-fill.mid     { background: #f59e0b; }
.eval-bar-fill.low     { background: #ef4444; }

.eval-percent {
  font-size: 0.75rem;
  font-weight: 600;
  color: #64748b;
  min-width: 32px;
  text-align: right;
}

/* レーダーチャート */
.radar-wrap {
  text-align: center;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid #e5e7eb;
}

.radar-canvas {
  max-width: 100%;
}

/* ---- セクションサブタイトル ---- */
.section-subtitle {
  font-size: 0.6875rem;
  color: #94a3b8;
  font-weight: 400;
}

/* ---- 雰囲気分析（HOW） ---- */
.atmosphere-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}

.atmosphere-card {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 6px;
  padding: 12px 10px 10px;
  text-align: center;
}

.atmosphere-name {
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--navy);
  margin-bottom: 6px;
}

.atmosphere-dots {
  display: flex;
  justify-content: center;
  gap: 4px;
  margin-bottom: 6px;
}

.atmosphere-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: #e2e8f0;
}

.atmosphere-dot.filled {
  background: var(--accent-orange);
}

.atmosphere-score {
  font-size: 1.125rem;
  font-weight: 800;
  color: var(--navy);
  margin-bottom: 4px;
}

.atmosphere-score-max {
  font-size: 0.6875rem;
  font-weight: 400;
  color: #94a3b8;
}

.atmosphere-comment {
  font-size: 0.625rem;
  color: #64748b;
  line-height: 1.4;
  text-align: left;
  margin-top: 4px;
}

/* ---- 2: テクニック（コンパクト） ---- */
.technique-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.technique-card {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 20px;
  padding: 5px 12px 5px 6px;
}

.technique-icon {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--navy);
  color: white;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 0.625rem;
  flex-shrink: 0;
}

.technique-name {
  font-size: 0.6875rem;
  color: #64748b;
  font-weight: 500;
  white-space: nowrap;
}

.technique-count {
  font-size: 0.8125rem;
  font-weight: 800;
  color: var(--navy);
}

.technique-count-unit {
  font-size: 0.5625rem;
  font-weight: 500;
  color: #94a3b8;
}

.technique-examples {
  display: none;
}

/* ---- 3: 話す比率 ---- */
.talk-ratio-bar {
  display: flex;
  height: 36px;
  border-radius: 6px;
  overflow: hidden;
  border: 1px solid #d1d5db;
}

.talk-staff {
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--accent-orange);
  color: white;
  font-size: 0.8125rem;
  font-weight: 700;
  min-width: 50px;
  transition: width 0.8s ease;
}

.talk-patient {
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--navy);
  color: white;
  font-size: 0.8125rem;
  font-weight: 700;
  flex: 1;
}

.talk-labels {
  display: flex;
  justify-content: space-between;
  font-size: 0.75rem;
  color: #94a3b8;
  margin-top: 6px;
}

/* ---- 4: フィードバック ---- */
.feedback-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.feedback-card {
  border: 1px solid #e2e8f0;
  border-radius: 6px;
  overflow: hidden;
}

.feedback-card-title {
  padding: 6px 12px;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.feedback-card-title.good-title {
  background: #f0fdf4;
  color: #16a34a;
  border-bottom: 2px solid #22c55e;
}

.feedback-card-title.improve-title {
  background: #fffbeb;
  color: #d97706;
  border-bottom: 2px solid #f59e0b;
}

.feedback-list {
  list-style: none;
  padding: 10px 12px;
}

.feedback-item {
  display: flex;
  gap: 8px;
  padding: 5px 0;
  font-size: 0.8125rem;
  line-height: 1.5;
}

.feedback-icon {
  flex-shrink: 0;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.625rem;
  margin-top: 2px;
}

.feedback-icon.good {
  background: #dcfce7;
  color: #16a34a;
}

.feedback-icon.improve {
  background: #fef3c7;
  color: #d97706;
}

/* ---- 5: 代表との違い ---- */
.insight-card {
  border: 1px solid #e2e8f0;
  border-radius: 6px;
  padding: 12px 14px;
  margin-bottom: 10px;
}

.insight-card:last-child {
  margin-bottom: 0;
}

.insight-card.rep-diff {
  border-left: 4px solid var(--accent-orange);
  background: var(--accent-orange-light);
}

.insight-card.improved-talk {
  border-left: 4px solid var(--navy);
  background: #f0f4f8;
}

.insight-label {
  font-size: 0.6875rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #64748b;
  margin-bottom: 6px;
}

.insight-text {
  font-size: 0.8125rem;
  line-height: 1.7;
  color: var(--text);
  white-space: pre-line;
}

/* ---- 6: 次回課題 ---- */
.next-tasks-list {
  list-style: none;
  padding: 0;
  counter-reset: task;
}

.next-task-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 8px 0;
  border-bottom: 1px solid #f1f3f5;
  font-size: 0.8125rem;
  line-height: 1.5;
}

.next-task-item:last-child {
  border-bottom: none;
}

.task-number {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--accent-orange);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 0.6875rem;
  flex-shrink: 0;
  margin-top: 1px;
}

/* ---- 7: 総合所見 ---- */
.overall-box {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.overall-comment {
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--navy);
  line-height: 1.7;
  padding: 10px 14px;
  background: #f0f4f8;
  border-radius: 6px;
  border-left: 4px solid var(--navy);
}

.advice-box {
  font-size: 0.8125rem;
  line-height: 1.7;
  color: var(--text);
  padding: 10px 14px;
  background: #f9fafb;
  border-radius: 6px;
  border: 1px solid #e2e8f0;
}

/* ---- フッター ---- */
.report-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 0;
  margin-top: 8px;
  border-top: 1.5px solid #d1d5db;
  font-size: 0.6875rem;
  color: #94a3b8;
}

.footer-conf {
  font-weight: 700;
  letter-spacing: 0.06em;
}

/* ---- アクションボタン ---- */
.action-buttons {
  display: flex;
  gap: 10px;
  margin-top: 16px;
}

.action-buttons .btn {
  flex: 1;
}

/* ---- レスポンシブ ---- */
@media (max-width: 600px) {
  .report-header-inner {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
  }

  .report-header-right {
    text-align: left;
  }

  .profile-card {
    flex-direction: column;
  }

  .profile-right {
    padding: 12px;
    flex-direction: row;
    gap: 12px;
  }

  .feedback-grid {
    grid-template-columns: 1fr;
  }

  .atmosphere-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .report-container {
    padding: 12px;
  }
}
