@charset "UTF-8";

/* ==========================================================================
   トピックス（お知らせ一覧）ページ用スタイル (njm_topics.css)
   ========================================================================== */


/* ==========================================
   1. セクション＆カードリスト
   ========================================== */
/* セクション全体 */
.topics-section {
  padding: 40px 0 80px;
}

/* トピックスカード一覧リスト */
.topics-list {
  display: flex;
  flex-direction: column;
  gap: 40px;
}

/* 個別トピックスカード */
.topic-card {
  background-color: #fff;
  border: 1px solid #e0e0e0;
  border-radius: 8px;
  padding: 28px 32px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.03);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  scroll-margin-top: 100px; /* IDアンカーリンク時のスクロール位置補正 */
}

/* トピックスカード（ホバー時） */
.topic-card:hover {
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.08);
}


/* ==========================================
   2. ヘッダー情報（日付・タイトル）
   ========================================== */
/* 日付メタデータエリア */
.topic-meta {
  margin-bottom: 12px;
}

/* 日付バッジ */
.topic-date {
  display: inline-block;
  background-color: #004d00; 
  color: #ffffff;
  font-size: 0.875rem;
  font-weight: 600;
  padding: 4px 12px;
  border-radius: 4px;
  letter-spacing: 0.05em;
}

/* 記事タイトル */
.topic-title {
  font-size: 1.375rem;
  font-weight: 700;
  line-height: 1.4;
  color: #1a1a1a;
  margin-bottom: 20px;
  padding-bottom: 12px;
  border-bottom: 2px solid #eef2f7;
}


/* ==========================================
   3. メディア＆本文コンテンツエリア
   ========================================== */
/* 記事コンテンツ（メディア ＋ テキスト領域） */
.topic-body {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

/* メディア（画像）エリア共通 */
.topic-media {
  flex-shrink: 0;
  width: 100%;
}

.topic-media img {
  width: 100%;
  height: auto;
  object-fit: cover;
  border-radius: 6px;
  border: 1px solid #eaeaea;
  display: block;
}

/* 画像が1枚の時 */
.topic-media.single-image a {
  display: block;
  transition: opacity 0.2s ease;
}

.topic-media.single-image a:hover {
  opacity: 0.85;
}

/* 画像が複数枚の時 */
.topic-media.multi-image {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(80px, 1fr)); /* 自動で均等割り */
  gap: 10px;
}

.topic-media.multi-image img {
  width: 100%;
  height: 120px; /* 高さを揃えると綺麗に見えます */
  object-fit: cover;
}

/* 本文テキストエリア */
.topic-text {
  flex-grow: 1;
  font-size: 0.95rem;
  line-height: 1.75;
  color: #333333;
}

.topic-text p {
  margin-bottom: 0.8em;
}

.topic-text p:last-child {
  margin-bottom: 0;
}

/* 仕様・設備リスト */
.spec-list {
  list-style: none;
  padding: 12px 16px;
  margin: 12px 0 0;
  background-color: #f8f9fa;
  border-left: 4px solid #004d00;
  border-radius: 0 4px 4px 0;
}

.spec-list li {
  position: relative;
  padding-left: 1rem;
  margin-bottom: 6px;
  font-size: 0.9rem;
}

.spec-list li:last-child {
  margin-bottom: 0;
}

.spec-list li::before {
  content: "■";
  position: absolute;
  left: 0;
  color: #008000; 
  font-size: 0.75rem;
  top: 1px;
}

/* PCサイズ用レイアウト調整（768px以上） */
@media (min-width: 768px) {
  .topic-body {
    flex-direction: row;
    align-items: flex-start;
  }

  .topic-media {
    width: 280px;
  }
}


/* ==========================================
   4. レスポンシブ調整
   ========================================== */
/* スマートフォンサイズ（767px以下） */
@media (max-width: 767px) {
  .topic-card {
    padding: 20px 18px;
  }

  .topic-title {
    font-size: 1.15rem;
  }

/* スマホ時は高さを少し抑える場合 */
  .topic-media.multi-image img {
    height: 100px;
  }
}
