/* AI補助金マッチングアプリ カスタムスタイル */

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

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Noto Sans JP', sans-serif;
  line-height: 1.6;
}

/* ローディングアニメーション */
@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

.spinner {
  border: 4px solid #f3f3f3;
  border-top: 4px solid #000;
  border-radius: 50%;
  width: 50px;
  height: 50px;
  animation: spin 1s linear infinite;
}

/* AIローディングドット */
@keyframes bounce {
  0%, 80%, 100% { 
    transform: scale(0);
    opacity: 0.5;
  }
  40% { 
    transform: scale(1);
    opacity: 1;
  }
}

.loading-dot {
  width: 12px;
  height: 12px;
  background-color: #00FF00;
  border: 2px solid #000;
  border-radius: 50%;
  animation: bounce 1.4s infinite ease-in-out;
}

#loading-message {
  transition: opacity 0.3s ease;
}

/* ブルータリズムスタイル */
.brutalist-shadow {
  box-shadow: 12px 12px 0px 0px rgba(0, 0, 0, 1);
}

.brutalist-shadow-hover:hover {
  box-shadow: 12px 12px 0px 0px rgba(0, 255, 0, 1);
}

.brutalist-shadow-yellow:hover {
  box-shadow: 12px 12px 0px 0px rgba(255, 255, 0, 1);
}

/* プログレスバー */
.progress-bar {
  height: 8px;
  background-color: #f0f0f0;
  border: 2px solid #000;
  overflow: hidden;
}

.progress-bar-fill {
  height: 100%;
  background-color: #00FF00;
  transition: width 0.3s ease;
}

/* カードスタイル */
.grant-card {
  border: 4px solid #000;
  background-color: #fff;
  transition: all 0.2s ease;
}

.grant-card:hover {
  transform: translate(-2px, -2px);
  box-shadow: 14px 14px 0px 0px rgba(0, 0, 0, 1);
}

/* ボタンスタイル */
.btn-primary {
  background-color: #000;
  color: #fff;
  border: 2px solid #000;
  padding: 1rem 2rem;
  font-weight: bold;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-primary:hover {
  background-color: #333;
}

.btn-secondary {
  background-color: #fff;
  color: #000;
  border: 2px solid #000;
  padding: 1rem 2rem;
  font-weight: bold;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-secondary:hover {
  background-color: #f0f0f0;
}

/* フェードインアニメーション */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.fade-in {
  animation: fadeIn 0.5s ease;
}

/* 質問カードのスタイル（コンパクト版） */
.question-card {
  border: 4px solid #000;
  background-color: #fff;
  padding: 1.5rem;
  margin-bottom: 1.5rem;
}

/* ドロップダウンのスタイル */
select {
  cursor: pointer;
  transition: all 0.2s ease;
}

select:hover {
  background-color: #f9f9f9;
}

select:focus {
  outline: none;
  border-color: #00FF00;
  box-shadow: 0 0 0 3px rgba(0, 255, 0, 0.2);
}

.question-option {
  border: 2px solid #000;
  padding: 1rem;
  margin-bottom: 0.75rem;
  cursor: pointer;
  transition: all 0.2s ease;
  background-color: #fff;
}

.question-option:hover {
  background-color: #f0f0f0;
  transform: scale(1.02);
}

.question-option.selected {
  background-color: #00FF00;
  transform: scale(1.02);
}

/* 入力フィールド */
input[type="text"],
textarea {
  border: 2px solid #000;
  padding: 0.75rem;
  width: 100%;
  font-family: inherit;
  font-size: 1rem;
}

input[type="text"]:focus,
textarea:focus {
  outline: none;
  border-color: #00FF00;
}

/* レスポンシブデザイン */
@media (max-width: 768px) {
  .brutalist-shadow {
    box-shadow: 8px 8px 0px 0px rgba(0, 0, 0, 1);
  }
  
  .grant-card:hover {
    transform: translate(-1px, -1px);
    box-shadow: 10px 10px 0px 0px rgba(0, 0, 0, 1);
  }
}

/* ユーティリティクラス */
.text-mono {
  font-family: 'Courier New', monospace;
}

.border-thick {
  border-width: 4px;
}

/* トースト通知 */
.toast {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  background-color: #000;
  color: #fff;
  padding: 1rem 2rem;
  border: 2px solid #000;
  z-index: 9999;
  animation: fadeIn 0.3s ease;
}

/* モーダル */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(0, 0, 0, 0.7);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9998;
}

.modal-content {
  background-color: #fff;
  border: 4px solid #000;
  padding: 2rem;
  max-width: 90%;
  max-height: 90%;
  overflow-y: auto;
}

/* スクロールバーのスタイリング */
::-webkit-scrollbar {
  width: 12px;
}

::-webkit-scrollbar-track {
  background: #f0f0f0;
  border: 1px solid #000;
}

::-webkit-scrollbar-thumb {
  background: #000;
  border: 1px solid #000;
}

::-webkit-scrollbar-thumb:hover {
  background: #333;
}
