/* index.php用のメインスタイル */
.main-container {
  padding: 0 0 20px 0;
  max-width: 100%;
  margin: 0 auto;
}

/* タブナビゲーション */
.category-tabs {
  display: flex;
  overflow-x: auto;
  gap: 2px;
  padding: 10px 10px 0;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none; /* Firefox */
}

.category-tabs::-webkit-scrollbar {
  display: none; /* Chrome, Safari, Edge */
}

.tab {
  height: 30px;
  width: 45px;
  border-radius: 8px 8px 0 0;
  border: 1px solid #D0D0D0;
  border-bottom: none;
  color: #333333;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  cursor: pointer;
  flex-shrink: 0;
  text-decoration: none;
  transition: all 0.3s ease;
  padding: 8px 4px;
  font-size: 12px;
}

.tab-show {
  height: 30px;
  width: 120px;
  border-radius: 8px 8px 0 0;
  border: 1px solid #D0D0D0;
  border-bottom: none;
  color: #333333;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  cursor: pointer;
  flex-shrink: 0;
  text-decoration: none;
  transition: all 0.3s ease;
  padding: 8px 4px;
  font-size: 12px;
}

.tab.active {
  background-color: #36C4B7;
  color: #FFFFFF;
  border-bottom: 1px solid #FFFFFF;
}

.tab-show.active {
  background-color: #36C4B7;
  color: #FFFFFF;
  border-bottom: 1px solid #FFFFFF;
}

.tab.all-tab {
  font-size: 18px;
  font-family: Helvetica, Arial, sans-serif;
}

.tab-icon {
  height: 32px;
  width: 32px;
  display: flex;
  justify-content: center;
  align-items: center;
  margin-bottom: 6px;
}

.tab-show-icon {
  display: flex;
  justify-content: center;
  align-items: center;
}

.tab img {
  height: 36px;
  width: 36px;
  object-fit: contain;
}

.tab-label {
  text-align: center;
  font-size: 11px;
  margin-top: 4px;
}

/* タブの下のバー */
.tab-bar {
  height: 1px;
  width: 100%;
  background-color: #36C4B7;
  margin-bottom: 20px;
  padding: 0 10px;
  box-sizing: border-box;
}

/* プロンプトグリッド - マソンリーレイアウト */
.prompts-grid {
  width: 100%;
  max-width: 1116px;
  margin: 24px auto 0 auto;
  box-sizing: border-box;
  padding: 0 20px;
    
  /* マソンリーレイアウト（Pinterest風）の設定 */
  column-count: 2; /* モバイルデフォルト: 2列 */
  column-gap: 10px;
  vertical-align: top; /* 上部揃え */
}

/* 各カードアイテムの設定 */
.prompts-grid .result-item {
  break-inside: avoid; /* カード内での改列を避ける */
  margin-bottom: 10px; /* カード間の縦方向の余白 */
  display: inline-block; /* vertical-alignを有効にする */
  vertical-align: top; /* 上部揃え */
  width: 100%;
}

/* タブレット表示（3列） */
@media (min-width: 768px) {
  .prompts-grid {
    column-count: 3;
  }
}

/* デスクトップ表示（4列） */
@media (min-width: 1024px) {
  .prompts-grid {
    column-count: 4;
  }
}

/* ローディングインジケーター */
.loading-indicator {
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 20px 0;
  width: 100%;
}

.spinner {
  width: 40px;
  height: 40px;
  border: 4px solid rgba(0, 0, 0, 0.1);
  border-radius: 50%;
  border-top-color: #2fada6;
  animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}


