@charset "utf-8";
/* ===============================
    パッキンコードカテゴリー専用CSS
    category_packing.css
   =============================== */

.packing-code-block {
  padding: 40px 20px;
  margin-bottom: 30px;
  background: #f7f9fc;
  border-radius: 8px;
}

.packing-code-block h1 {
  font-size: 28px;
  color: #2b3e7c;
  margin-bottom: 25px;
  border-left: 8px solid #3b5998;
  padding-left: 15px;
  line-height: 1.5;
  font-weight: bold;
  background: #f0f4f9;
  text-align: left;
  width: auto;  
}

.packing-code-block h2 {
  font-size: 24px;
  color: #3b5998;
  margin-bottom: 15px;
  border-bottom: 2px solid #627aad;
  padding-bottom: 8px;
  background: none;
  text-align: left;
  width: auto;
}

.packing-code-block h3 {
  font-size: 20px;
  color: #627aad;
  margin-top: 25px;
  margin-bottom: 10px;
  background: none;
  text-align: left;
  width: auto;
}

.packing-code-block p {
  font-size: 16px;
  color: #333;
  line-height: 1.8;
  margin-bottom: 15px;
}

.packing-code-block ul {
  padding-left: 20px;
  margin-bottom: 20px;
}

.packing-code-block ul li {
  font-size: 16px;
  line-height: 1.7;
  color: #333;
  list-style: disc;
  margin-bottom: 8px;
}

.packing-code-block a {
  color: #3b5998;
  text-decoration: underline;
}

.packing-code-block a:hover {
  color: #ff9900;
}

/* 目次リストのスタイル */
.packing-code-index-list {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-start; /* 左右に均等配置 */
  max-width: 960px; 
  padding: 10px 0;
  margin: 20px auto;
  border: 1px solid #aaccff; /* 枠線を青系に */
  background-color: #f7fbff; /* 背景色をより薄い青に */
  list-style: none !important; /* リストの点などを消す */
}
.packing-code-index-list li {
  flex: 0 0 calc(100% / 6 - 1%); /* flex-grow:0 (引き伸ばさない), flex-shrink:0 (縮まない), flex-basis: 計算幅 */
  max-width: calc(100% / 6 - 1%); /* アイテムの最大幅をflex-basisに合わせる */
  margin: 5px 0.5%; /* 上下マージン5px, 左右マージン0.5% */
  text-align: center;
  list-style: none !important; /* ★重要：親 ul から継承されても確実に点を消す★ */
}

.packing-code-index-list li a {
  display: block; /* ブロック要素にしてクリック領域を広げる */
  padding: 8px 0;
  background-color: #e0f0ff; /* 各項目リンクの背景色（明るい青） */
  border: 1px solid #cceeff; /* 各項目リンクのボーダー色 */
  border-radius: 5px;
  color: #3b5998; /* 文字色（ヘッダーの青系） */
  text-decoration: none;
  font-weight: bold;
  font-size: 16px;
  transition: background-color 0.3s ease, color 0.3s ease;
}

.packing-code-index-list li a:hover {
  background-color: #aaccff; /* ホバー時の背景色（少し濃い青） */
  color: #fff; /* ホバー時の文字色（白） */
  text-decoration: none;
}

/* 下部CTAリンクのスタイル */
.packing-code-cta-link {
  display: block;
  width: fit-content;
  margin: 25px auto;
  padding: 12px 25px;
  background: linear-gradient(to bottom, #e6f3ff, #cce6ff); /* 淡いブルーのグラデーション */
  color: #003366;
  text-decoration: none;
  font-weight: bold;
  font-size: 18px;
  border-radius: 8px;
  border: 1px solid #aaccee;
  box-shadow: 0 2px 4px rgba(0,0,0,0.15);
  transition: all 0.3s ease;
  letter-spacing: 0.05em;
  text-align: center;
}

.packing-code-cta-link:hover {
  background: linear-gradient(to bottom, #d0e9ff, #a9d4ff); /* ホバー時も優しいブルーで */
  transform: translateY(-2px);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
}

/* A～Zテーブルスタイル */
.packing-code-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 20px;
  margin-bottom: 30px;
  font-size: 14px;
  table-layout: fixed; /* 列幅を固定する */
  border: 1px solid #cceeff; /* テーブル全体のボーダー色（少し明るめ） */
  box-sizing: border-box; /* パディングとボーダーを幅に含める */
}

.packing-code-table caption {
  caption-side: top; /* キャプションをテーブルの上に配置 */
  text-align: left; /* キャプションを左寄せ */
  font-size: 1.1em;
  font-weight: bold;
  margin-bottom: 5px;
  color: #3b5998;
}

.packing-code-table th,
.packing-code-table td {
  border: 1px solid #e0f0ff; /* セルごとのボーダー色（さらに明るい青系） */
  padding: 8px 5px;
  text-align: center; /* デフォルトで中央揃え */
  vertical-align: top; /* 垂直方向は上揃え */
  white-space: normal; /* 基本的にテキストを折り返す */
}

.packing-code-table th {
  background-color: #dbe9ff; /* ヘッダーの背景色（明るい青系） */
  color: #2b3e7c; /* ヘッダーの文字色（濃い青系） */
  font-weight: bold; /* ヘッダーは太字に */
  font-style: normal;
}

/* 各行の交互の背景色 */
.packing-code-table tbody tr:nth-child(odd) {
  background-color: #f7fbff; /* 奇数行の背景色（ごく薄い青） */
}

.packing-code-table tbody tr:nth-child(even) {
  background-color: #ffffff; /* 偶数行の背景色（白） */
}

/* 1列目のスタイル - 型式・記号 */
.packing-code-table th:nth-child(1) {
  width: 10%; 
  text-align: center; /* ヘッダーは中央寄せ */
  white-space: normal;
}
.packing-code-table td:nth-child(1) {
  width: 10%;
  text-align: left; /* データは左寄せ */
  white-space: normal;
}

/* 2列目のスタイル - 種類 */
.packing-code-table th:nth-child(2) {
  width: 25%; 
  text-align: center; /* ヘッダーは中央寄せ */
  white-space: normal;
}
.packing-code-table td:nth-child(2) {
  width: 25%;
  text-align: left; /* データは左寄せ */
  white-space: normal;
}

/* 3列目のスタイル - 備考 */
.packing-code-table th:nth-child(3) {
  width: 38%; 
  text-align: center; /* ヘッダーは中央寄せ */
  white-space: normal;
}
.packing-code-table td:nth-child(3) {
  width: 38%;
  text-align: left; /* データは左寄せ */
  white-space: normal;
}

/* 4列目のスタイル - メーカー、ブランド、規格等 */
.packing-code-table th:nth-child(4) {
  width: 27%; 
  text-align: center; /* ヘッダーは中央寄せ */
  white-space: normal;
}
.packing-code-table td:nth-child(4) {
  width: 27%;
  text-align: left; /* データは左寄せ */
  white-space: normal;
}

/* 1～9テーブルスタイル */
.packing-code-table-1 {
  width: 100%;
  border-collapse: collapse;
  margin-top: 20px;
  margin-bottom: 30px;
  font-size: 14px;
  table-layout: fixed; /* 列幅を固定する */
  border: 1px solid #cceeff; /* テーブル全体のボーダー色（少し明るめ） */
  box-sizing: border-box; /* パディングとボーダーを幅に含める */
}

.packing-code-table-1 caption {
  caption-side: top; /* キャプションをテーブルの上に配置 */
  text-align: left; /* キャプションを左寄せ */
  font-size: 1.1em;
  font-weight: bold;
  margin-bottom: 5px;
  color: #3b5998;
}

.packing-code-table-1 th,
.packing-code-table-1 td {
  border: 1px solid #e0f0ff; /* セルごとのボーダー色（さらに明るい青系） */
  padding: 8px 5px;
  text-align: center; /* デフォルトで中央揃え */
  vertical-align: top; /* 垂直方向は上揃え */
  white-space: normal; /* 基本的にテキストを折り返す */
}

.packing-code-table-1 th {
  background-color: #dbe9ff; /* ヘッダーの背景色（明るい青系） */
  color: #2b3e7c; /* ヘッダーの文字色（濃い青系） */
  font-weight: bold; /* ヘッダーは太字に */
  font-style: normal;
}

/* 各行の交互の背景色 */
.packing-code-table-1 tbody tr:nth-child(odd) {
  background-color: #f7fbff; /* 奇数行の背景色（ごく薄い青） */
}

.packing-code-table-1 tbody tr:nth-child(even) {
  background-color: #ffffff; /* 偶数行の背景色（白） */
}

/* 1列目のスタイル - 数字 */
.packing-code-table-1 th:nth-child(1) {
  width: 7%; 
  text-align: center; /* ヘッダーは中央寄せ */
  white-space: normal;
}
.packing-code-table-1 td:nth-child(1) {
  width: 7%;
  text-align: left; /* データは左寄せ */
  white-space: normal;
}

/* 2列目のスタイル - 型式・記号 */
.packing-code-table-1 th:nth-child(2) {
  width: 12%; 
  text-align: center; /* ヘッダーは中央寄せ */
  white-space: normal;
}
.packing-code-table-1 td:nth-child(2) {
  width: 12%;
  text-align: left; /* データは左寄せ */
  white-space: normal;
}

/* 3列目のスタイル - 種類 */
.packing-code-table-1 th:nth-child(3) {
  width: 20%; 
  text-align: center; /* ヘッダーは中央寄せ */
  white-space: normal;
}
.packing-code-table-1 td:nth-child(3) {
  width: 20%;
  text-align: left; /* データは左寄せ */
  white-space: normal;
}

/* 4列目のスタイル - 備考 */
.packing-code-table-1 th:nth-child(4) {
  width: 36%; 
  text-align: center; /* ヘッダーは中央寄せ */
  white-space: normal;
}
.packing-code-table-1 td:nth-child(4) {
  width: 36%;
  text-align: left; /* データは左寄せ */
  white-space: normal;
}

/* 5列目のスタイル - メーカー、ブランド、規格等 */
.packing-code-table-1 th:nth-child(5) {
  width: 25%; 
  text-align: center; /* ヘッダーは中央寄せ */
  white-space: normal;
}
.packing-code-table-1 td:nth-child(5) {
  width: 25%;
  text-align: left; /* データは左寄せ */
  white-space: normal;
}
.back-to-index {
  display: block;
  margin: 2em 0 0.5em;
  font-weight: bold;
  color: #3366cc;
  text-decoration: none;
  font-size: 1rem;
}

.back-to-index {
  display: inline-block;
  margin-top: 20px;
  font-size: 16px;
  font-weight: bold;
  color: #003366;
  text-decoration: none;
  border: 2px solid #aaccee;
  padding: 10px 14px;
  border-radius: 6px;
  background-color: #eef7ff;
  transition: background-color 0.3s ease;
}

.back-to-index:hover {
  background-color: #cce6ff;
}
/* =======================================
   モバイル向けスタイル (max-width: 600px)
   ======================================= */
@media screen and (max-width: 600px){
  .packing-code-block {
    padding: 30px 15px;
    margin-bottom: 20px;
    background: #ffffff;
    border-radius: 0;
  }

  .packing-code-block h1 {
    font-size: 22px;
    padding-left: 12px;
    margin-bottom: 20px;
    border-left: 6px solid #3b5998;
  }
  
  .packing-code-block h2 {
    font-size: 20px;
    margin-bottom: 12px;
    border-bottom: 1px solid #627aad;
    padding-bottom: 6px;
  }

  .packing-code-block h3 {
    font-size: 18px;
    margin-top: 20px;
    margin-bottom: 8px;
  }

  .packing-code-block p {
    font-size: 15px;
    margin-bottom: 12px;
  }

  .packing-code-block ul {
    padding-left: 18px;
    margin-bottom: 15px;
  }

  .packing-code-block ul li {
    font-size: 15px;
    margin-bottom: 6px;
  }

  /* 目次リストのスタイル (モバイル) */
  .packing-code-index-list {
    flex-direction: row;       /* ← columnをrowに戻す */
    justify-content: flex-start;
  }
  .packing-code-index-list li {
    flex: 0 0 30%;
    max-width: 30%;
    margin: 5px 1% !important; /* 少し余白を調整 */
  }
  .packing-code-index-list li a {
    font-size: 15px;
    padding: 10px 0;
  }

  /* テーブルスタイル (モバイル) */
  .packing-code-table {
    font-size: 12px;
    width: auto; /* コンテンツに合わせて幅を自動調整（横スクロール前提） */
    min-width: 400px; /* 小さくなりすぎないように最小幅を設定 */
  }

  .packing-code-table th,
  .packing-code-table td {
    padding: 6px 3px;
    white-space: normal; /* モバイルでは基本的にテキストを折り返す */
  }

  /* 各列の幅をモバイルに合わせて調整（合計100%に近くなるように調整） */
  .packing-code-table th:nth-child(1),
  .packing-code-table td:nth-child(1) {
    width: 25%;
    min-width: 80px;
  }
  .packing-code-table th:nth-child(2),
  .packing-code-table td:nth-child(2) {
    width: 20%;
    min-width: 60px;
  }
  .packing-code-table th:nth-child(3),
  .packing-code-table td:nth-child(3) {
    width: 35%;
    min-width: 100px;
  }
  .packing-code-table th:nth-child(4),
  .packing-code-table td:nth-child(4) {
    width: 20%;
    min-width: 80px;
  }
  
    /* モバイル用：テーブル全体をスクロール対応にする */
  .packing-code-table-1 {
    display: block;
    overflow-x: auto;
    width: 100%;
  }

  .packing-code-table-1 table {
    min-width: 600px; /* 横スクロールを発生させる */
    border-collapse: collapse;
  }

  /* 各列の幅を調整（合計100%になるよう配分） */
  .packing-code-table-1 th:nth-child(1),
  .packing-code-table-1 td:nth-child(1) {
    width: 10%;
    min-width: 50px;
  }

  .packing-code-table-1 th:nth-child(2),
  .packing-code-table-1 td:nth-child(2) {
    width: 20%;
    min-width: 80px;
  }

  .packing-code-table-1 th:nth-child(3),
  .packing-code-table-1 td:nth-child(3) {
    width: 25%;
    min-width: 100px;
  }

  .packing-code-table-1 th:nth-child(4),
  .packing-code-table-1 td:nth-child(4) {
    width: 25%;
    min-width: 120px;
  }

  .packing-code-table-1 th:nth-child(5),
  .packing-code-table-1 td:nth-child(5) {
    width: 20%;
    min-width: 100px;
  }

  /* ヘッダーとデータの調整 */
  .packing-code-table-1 th,
  .packing-code-table-1 td {
    font-size: 14px;
    padding: 6px 8px;
    white-space: normal;
  }
  .back-to-index {
    display: block;
    font-size: 14px;
    padding: 8px 12px;
    text-align: center;
  }
}