/**
 * Companion Loading Animation CSS
 *
 * コンパニオンデータのローディング表示用スタイル
 */

/* ローディング表示コンテナ */
.companion-loading {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 300px;
  width: 100%;
  padding: 2rem;
}

/* ローディングスピナー */
.loading-spinner {
  width: 50px;
  height: 50px;
  border: 4px solid rgba(207, 173, 122, 0.2);
  border-top-color: #cfad7a;
  border-radius: 50%;
  animation: spinner-rotate 0.8s linear infinite;
}

/* スピナー回転アニメーション */
@keyframes spinner-rotate {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}

/* ローディングテキスト */
.loading-text {
  margin-top: 1rem;
  font-size: 0.9rem;
  color: #888;
  font-family: 'Noto Sans', sans-serif;
}

/* データ読み込み中の状態 */
[data-loading="true"] {
  min-height: 300px;
  position: relative;
}

/* フェードイン表示（データ取得完了時） */
.companion-list-loaded {
  animation: fadeInUp 0.5s ease forwards;
}

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

/* エラー表示 */
.companion-error,
.no-companions {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 200px;
  width: 100%;
  padding: 2rem;
  text-align: center;
}

.companion-error p {
  color: #d9534f;
  font-size: 0.9rem;
  font-family: 'Noto Sans', sans-serif;
}

.no-companions p {
  color: #888;
  font-size: 0.9rem;
  font-family: 'Noto Sans', sans-serif;
}

/* レスポンシブ対応 */
@media screen and (max-width: 768px) {
  .companion-loading {
    min-height: 200px;
    padding: 1rem;
  }

  .loading-spinner {
    width: 40px;
    height: 40px;
    border-width: 3px;
  }

  .loading-text {
    font-size: 0.85rem;
  }

  .companion-error,
  .no-companions {
    min-height: 150px;
    padding: 1rem;
  }

  .companion-error p,
  .no-companions p {
    font-size: 0.85rem;
  }
}
