/* Modern Tools Page Styles - Updated tools.css */

/* ページヘッダー */
.page-header {
  text-align: center;
  margin-bottom: 3rem;
  padding: 2rem 0;
}

.page-header h1 {
  font-size: 2.5rem;
  color: var(--primary-color);
  margin-bottom: 0.5rem;
  font-weight: 700;
}

.page-header p {
  font-size: 1.2rem;
  color: #666;
  max-width: 600px;
  margin: 0 auto;
}

/* カテゴリセクション */
.category-section {
  margin-bottom: 4rem;
}

.category-header {
  display: flex;
  align-items: center;
  margin-bottom: 2rem;
  padding-bottom: 1rem;
  border-bottom: 3px solid var(--primary-color);
}

.category-icon {
  font-size: 2rem;
  margin-right: 1rem;
}

.category-title {
  font-size: 1.8rem;
  color: var(--primary-color);
  font-weight: 600;
}

/* ツールグリッド - 既存のクラス名を更新 */
.tools-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(350px, 350px));
  gap: 2rem;
  justify-content: center;
}

/* 既存のtool-itemを新しいデザインに更新 */
.tool-item, .tool-card {
  background: var(--card-bg);
  border-radius: var(--border-radius);
  overflow: hidden;
  box-shadow: var(--card-shadow);
  transition: all var(--transition-speed);
  text-decoration: none;
  color: inherit;
  display: block;
  position: relative;
  border: none; /* 古いボーダーを削除 */
  padding: 0; /* 古いパディングを削除 */
}

.tool-item:hover, .tool-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

/* 画像表示の更新 - アスペクト比保持に変更 */
.tool-image, .tool-img {
  width: 100%;
  height: 200px;
  background: linear-gradient(135deg, #f5f7fa, #c3cfe2);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 3rem;
  color: #888;
  position: relative;
  overflow: hidden;
}

.tool-image img, .tool-img {
  width: 100%;
  height: 100%;
  object-fit: contain; /* coverからcontainに変更 */
  object-position: center;
  transition: transform var(--transition-speed);
}

.tool-item:hover .tool-image img, 
.tool-card:hover .tool-image img,
.tool-item:hover .tool-img,
.tool-card:hover .tool-img {
  transform: scale(1.05);
}

.image-fallback {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  font-size: 3rem;
  color: #888;
}

.tool-content {
  padding: 1.5rem;
}

/* 既存のh2, h3タイトルスタイルを更新 */
.tool-item h2, .tool-item h3, .tool-title {
  font-size: 1.3rem;
  font-weight: 600;
  color: var(--text-color);
  margin: 0 0 1rem 0; /* margin-bottomを増やしてレイアウト調整 */
  line-height: 1.3;
}

/* 説明文のスタイルを削除（使用しないため非表示） */
.tool-item p, .tool-description {
  display: none; /* 説明文を完全に非表示 */
}

.tool-meta {
  display: flex;
  justify-content: flex-end; /* リンクアイコンを右寄せ */
  align-items: center;
  padding-top: 0; /* パディングを削除してスペース調整 */
  border-top: none; /* ボーダーを削除 */
}

.tool-price {
  font-weight: 600;
  color: var(--secondary-color);
  font-size: 1.1rem;
}

.tool-link-icon {
  color: var(--primary-color);
  font-size: 1.2rem;
  opacity: 0.7;
  transition: opacity var(--transition-speed);
}

.tool-item:hover .tool-link-icon,
.tool-card:hover .tool-link-icon {
  opacity: 1;
}

/* 状態バッジ */
.status-badge {
  position: absolute;
  top: 1rem;
  right: 1rem;
  background: rgba(46, 204, 113, 0.9);
  color: white;
  padding: 0.3rem 0.8rem;
  border-radius: 20px;
  font-size: 0.8rem;
  font-weight: 500;
  z-index: 10;
}

.status-badge.discontinued {
  background: rgba(231, 76, 60, 0.9);
}

/* 非公開ツールのスタイル */
.tool-item.discontinued, .tool-card.discontinued {
  background: #f5f5f5;
  opacity: 0.7;
  cursor: not-allowed;
}

.tool-item.discontinued:hover, .tool-card.discontinued:hover {
  transform: none;
  box-shadow: var(--card-shadow);
}

.tool-item.discontinued .tool-image, 
.tool-card.discontinued .tool-image,
.tool-item.discontinued .tool-img {
  background: linear-gradient(135deg, #e0e0e0, #bdbdbd);
  filter: grayscale(100%);
}

.tool-item.discontinued .tool-image img, 
.tool-card.discontinued .tool-image img,
.tool-item.discontinued .tool-img {
  filter: grayscale(100%);
}

.tool-item.discontinued h2,
.tool-item.discontinued h3,
.tool-card.discontinued .tool-title {
  color: #888;
}

.tool-item.discontinued p,
.tool-card.discontinued .tool-description {
  color: #999;
}

.tool-item.discontinued .tool-price,
.tool-card.discontinued .tool-price {
  color: #999;
}

.tool-item.discontinued .tool-link-icon,
.tool-card.discontinued .tool-link-icon {
  color: #999;
}

/* 古いスタイルの削除・上書き */
.tool-item a {
  color: inherit;
  text-decoration: none;
  display: block;
  height: 100%;
}

/* レスポンシブ */
@media (max-width: 768px) {
  .tools-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }
  
  .page-header h1 {
    font-size: 2rem;
  }
  
  .category-header {
    flex-direction: column;
    text-align: center;
  }
  
  .category-icon {
    margin-right: 0;
    margin-bottom: 0.5rem;
  }
}

/* アニメーション効果 */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.tool-item, .tool-card {
  animation: fadeInUp 0.6s ease-out;
}

.tool-item:nth-child(1), .tool-card:nth-child(1) { animation-delay: 0.1s; }
.tool-item:nth-child(2), .tool-card:nth-child(2) { animation-delay: 0.2s; }
.tool-item:nth-child(3), .tool-card:nth-child(3) { animation-delay: 0.3s; }
.tool-item:nth-child(4), .tool-card:nth-child(4) { animation-delay: 0.4s; }
.tool-item:nth-child(5), .tool-card:nth-child(5) { animation-delay: 0.5s; }