/* DXO Mirror - 体験会ふり返りナビ */
/* カラーパレット */
:root {
  --primary: #2C7A7B;
  --primary-light: #38B2AC;
  --primary-dark: #285E61;
  --secondary: #F6AD55;
  --secondary-light: #FBD38D;
  --background: #F7FAFC;
  --surface: #FFFFFF;
  --text-primary: #2D3748;
  --text-secondary: #718096;
  --text-muted: #A0AEC0;
  --border: #E2E8F0;
  --success: #48BB78;
  --success-light: #C6F6D5;
  --warning: #ED8936;
  --warning-light: #FEEBC8;
  --error: #F56565;
  --good-bg: #F0FFF4;
  --good-border: #9AE6B4;
  --more-bg: #FFFAF0;
  --more-border: #FBD38D;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Noto Sans JP', -apple-system, BlinkMacSystemFont, sans-serif;
  background: var(--background);
  color: var(--text-primary);
  line-height: 1.7;
  min-height: 100vh;
}

.app-container {
  max-width: 900px;
  margin: 0 auto;
  padding: 2rem 1.5rem;
}

/* ヘッダー */
.header {
  text-align: center;
  margin-bottom: 3rem;
  padding: 2rem;
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
  border-radius: 1.5rem;
  color: white;
  box-shadow: 0 10px 40px rgba(44, 122, 123, 0.3);
}

.logo {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  margin-bottom: 0.75rem;
  flex-wrap: wrap;
}

.logo-icon {
  font-size: 2.5rem;
}

.logo h1 {
  font-size: 2rem;
  font-weight: 700;
  letter-spacing: 0.05em;
}

.subtitle {
  font-size: 0.9rem;
  background: rgba(255, 255, 255, 0.2);
  padding: 0.25rem 0.75rem;
  border-radius: 1rem;
}

.tagline {
  font-size: 1rem;
  opacity: 0.95;
  margin-top: 0.5rem;
}

/* メインコンテンツ */
.main-content {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

/* セクション共通 */
section {
  background: var(--surface);
  border-radius: 1rem;
  padding: 2rem;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.06);
}

section h2 {
  font-size: 1.35rem;
  font-weight: 600;
  color: var(--primary-dark);
  margin-bottom: 1.5rem;
  padding-bottom: 0.75rem;
  border-bottom: 2px solid var(--border);
}

/* フォーム */
.form-group {
  margin-bottom: 1.5rem;
}

.form-group label {
  display: block;
  font-weight: 500;
  margin-bottom: 0.5rem;
  color: var(--text-primary);
}

select, textarea {
  width: 100%;
  padding: 0.875rem 1rem;
  font-size: 1rem;
  font-family: inherit;
  border: 2px solid var(--border);
  border-radius: 0.75rem;
  background: var(--surface);
  color: var(--text-primary);
  transition: border-color 0.2s, box-shadow 0.2s;
}

select:focus, textarea:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(44, 122, 123, 0.15);
}

textarea {
  resize: vertical;
  min-height: 200px;
}

textarea::placeholder {
  color: var(--text-muted);
}

.char-count {
  text-align: right;
  font-size: 0.85rem;
  color: var(--text-secondary);
  margin-top: 0.5rem;
}

/* ボタン */
.btn-primary, .btn-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 1rem 2rem;
  font-size: 1.1rem;
  font-weight: 600;
  font-family: inherit;
  border: none;
  border-radius: 0.75rem;
  cursor: pointer;
  transition: all 0.2s;
  width: 100%;
}

.btn-primary {
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
  color: white;
  box-shadow: 0 4px 15px rgba(44, 122, 123, 0.3);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(44, 122, 123, 0.4);
}

.btn-primary:active {
  transform: translateY(0);
}

.btn-primary:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none;
}

.btn-secondary {
  background: var(--surface);
  color: var(--primary);
  border: 2px solid var(--primary);
}

.btn-secondary:hover {
  background: var(--primary);
  color: white;
}

.btn-icon {
  font-size: 1.2rem;
}

/* 結果セクション */
.result-section {
  animation: fadeIn 0.5s ease;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

.result-header {
  display: flex;
  justify-content: center;
  margin-bottom: 2rem;
}

.overall-score {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 1.5rem 3rem;
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
  border-radius: 1rem;
  color: white;
}

.score-label {
  font-size: 0.9rem;
  opacity: 0.9;
}

.score-value {
  font-size: 3.5rem;
  font-weight: 700;
  line-height: 1;
  margin: 0.5rem 0;
}

.score-max {
  font-size: 1rem;
  opacity: 0.8;
}

/* チャート */
.chart-container {
  max-width: 450px;
  margin: 0 auto 2rem;
  padding: 1rem;
}

/* 総評ボックス */
.summary-box {
  background: linear-gradient(135deg, #EDF2F7 0%, #E2E8F0 100%);
  padding: 1.5rem;
  border-radius: 1rem;
  margin-bottom: 2rem;
  border-left: 4px solid var(--primary);
}

.summary-box h3 {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 0.75rem;
  color: var(--primary-dark);
}

.summary-box p {
  line-height: 1.8;
  color: var(--text-primary);
}

.no-data {
  color: var(--text-muted);
  font-style: italic;
  text-align: center;
  padding: 1rem;
}

/* フィードバックカード */
.feedback-container {
  display: grid;
  gap: 1.5rem;
  margin-bottom: 2rem;
}

@media (min-width: 640px) {
  .feedback-container {
    grid-template-columns: 1fr 1fr;
  }
}

.feedback-card {
  padding: 1.5rem;
  border-radius: 1rem;
  border: 2px solid;
}

.feedback-card.good {
  background: var(--good-bg);
  border-color: var(--good-border);
}

.feedback-card.more {
  background: var(--more-bg);
  border-color: var(--more-border);
}

.feedback-card h3 {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 1rem;
  color: var(--text-primary);
}

.feedback-content {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.feedback-item {
  background: rgba(255, 255, 255, 0.7);
  padding: 1rem;
  border-radius: 0.5rem;
}

.feedback-quote {
  font-style: italic;
  color: var(--text-secondary);
  padding-left: 1rem;
  border-left: 3px solid var(--primary-light);
  margin-bottom: 0.75rem;
  font-size: 0.95rem;
}

.feedback-explanation, .feedback-suggestion {
  font-size: 0.95rem;
  line-height: 1.6;
}

.feedback-issue {
  color: var(--warning);
  font-weight: 500;
  margin-bottom: 0.5rem;
}

.feedback-suggestion {
  color: var(--primary-dark);
}

.suggestion-label {
  font-weight: 600;
  color: var(--primary);
}

/* 詳細スコア */
.detailed-scores {
  margin-bottom: 2rem;
}

.detailed-scores h3 {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 1rem;
  color: var(--text-primary);
}

.scores-grid {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.score-item {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.score-item-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.score-name {
  font-weight: 500;
  color: var(--text-primary);
}

.score-number {
  font-weight: 700;
  color: var(--primary);
}

.score-bar {
  height: 8px;
  background: var(--border);
  border-radius: 4px;
  overflow: hidden;
}

.score-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--primary) 0%, var(--primary-light) 100%);
  border-radius: 4px;
  transition: width 0.8s ease;
}

.score-description {
  font-size: 0.85rem;
  color: var(--text-secondary);
}

/* ローディング */
.loading-section {
  text-align: center;
  padding: 4rem 2rem;
}

.loading-spinner {
  width: 60px;
  height: 60px;
  border: 4px solid var(--border);
  border-top-color: var(--primary);
  border-radius: 50%;
  animation: spin 1s linear infinite;
  margin: 0 auto 1.5rem;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.loading-section p {
  color: var(--text-secondary);
  font-size: 1rem;
}

/* フッター */
.footer {
  text-align: center;
  margin-top: 3rem;
  padding: 2rem;
  color: var(--text-secondary);
  font-size: 0.9rem;
}

.footer-note {
  margin-top: 0.5rem;
  font-size: 0.8rem;
  color: var(--text-muted);
}

/* ユーティリティ */
.hidden {
  display: none !important;
}

/* レスポンシブ */
@media (max-width: 640px) {
  .app-container {
    padding: 1rem;
  }

  .header {
    padding: 1.5rem;
    border-radius: 1rem;
  }

  .logo h1 {
    font-size: 1.5rem;
  }

  .logo-icon {
    font-size: 2rem;
  }

  section {
    padding: 1.5rem;
  }

  .score-value {
    font-size: 2.5rem;
  }

  .chart-container {
    max-width: 100%;
  }
}
